body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f4f7f6;
    margin: 0;
    padding: 0px;
    color: #333;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    padding: 0px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    border-radius: 8px;
}

header h1 {
    text-align: center;
    color: #4CAF50;
    margin-bottom: 4px;
}

h2 {
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 2px;
    margin-top: 0;
}

#product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 5px;
}

.product-item {
    border: 1px solid #ddd;
    border-radius: 1px;
    padding: 5px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.product-item h3 {
    margin: 10px 0 5px 0;
    font-size: 1em;
}

.product-item p {
    margin: 0;
    color: #666;
    font-weight: bold;
}

#cart-section {
    margin-top: 4px;
	padding-right: 12px;
	padding-left: 12px;
}

#cart-items {
    list-style: none;
    padding: 0;
	min-height: 200px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    padding: 0 12px;
    border-bottom: 1px solid #eee;
}

.cart-total {
    text-align: right;
    margin-top: 20px;
    font-size: 1.2em;
}
/*
#reset-button {
    display: block;
    width: 100%;
    padding: 12px;
    margin-top: 20px;
    background-color: #f44336;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1em;
    cursor: pointer;
}

#reset-button:hover {
    background-color: #d32f2f;
}*/
/* untuk Modal Pembayaran */
/* ... (kode CSS sebelumnya) ... */

/* Gaya untuk Tombol Aksi Keranjang */
.cart-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 20px;
}

.cart-actions button {
    display: block;
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 5px;
    font-size: 1em;
    cursor: pointer;
    color: white;
}

#pay-button {
    background-color: #007bff; /* Biru */
}
#pay-button:hover {
    background-color: #0056b3;
}

#reset-button {
    background-color: #f44336; /* Merah */
}
#reset-button:hover {
    background-color: #d32f2f;
}


/* Gaya untuk Modal Pembayaran */
.modal {
    display: none; /* Sembunyi secara default */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
}

.modal.show {
    display: flex; /* Tampilkan saat class .show ditambahkan */
}

.modal-content {
    background-color: #fefefe;
    margin: auto;
    padding: 30px;
    border: 1px solid #888;
    width: 90%;
    max-width: 400px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    position: relative;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.close-button {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-button:hover {
    color: black;
}

.payment-details, .payment-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}
.payment-details p, .payment-summary p {
    margin: 0;
    font-size: 1.1em;
}
.payment-details h3, .payment-summary h3 {
    margin: 0;
    color: #4CAF50;
}

.payment-input {
    margin: 25px 0;
}
.payment-input label {
    display: block;
    margin-bottom: 8px;
}
.payment-input input {
    width: 100%;
    padding: 12px;
    font-size: 1.2em;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box;
}

#confirm-payment-button {
    width: 100%;
    padding: 15px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    cursor: pointer;
}
#confirm-payment-button:hover {
    background-color: #45a049;
}

/* ... (kode CSS sebelumnya) ... */

/* Gaya Navigasi */
header nav {
    text-align: center;
    margin-bottom: 2px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}
header nav a {
    text-decoration: none;
    color: #007bff;
    margin: 0 10px;
    font-weight: bold;
}

/* Gaya Halaman Riwayat */
#transaction-list {
    list-style: none;
    padding: 0;
}

.transaction-item {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.transaction-item .info {
    flex-grow: 1;
}

.transaction-item .info p {
    margin: 4px 0;
}

.transaction-item .actions button {
    padding: 8px 12px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* Gaya untuk Modal Struk */
.modal-content.receipt {
    max-width: 350px; /* Ukuran struk kasir */
    font-family: 'Courier New', Courier, monospace;
}

#receipt-content {
    border-bottom: 1px dashed #333;
    padding-bottom: 15px;
    margin-bottom: 15px;
}
#receipt-content h2 {
    text-align: center;
    margin: 0 0 15px 0;
}
#receipt-content p {
    margin: 2px 0;
    font-size: 0.9em;
}
#receipt-content .item-list {
    margin: 15px 0;
}
#receipt-content .receipt-item {
    display: flex;
    justify-content: space-between;
}
#receipt-content .total-section {
    border-top: 1px dashed #333;
    padding-top: 10px;
    margin-top: 10px;
}
#receipt-content .total-line {
    display: flex;
    justify-content: space-between;
    font-weight: bold;
}

#print-receipt-button {
    width: 100%;
    padding: 12px;
    background-color: #4CAF50;
    color: white;
    border: none;
    cursor: pointer;
}
td.price-cell {
  text-align: right;
  padding-right: 12px;
}
.price-header,
.price-cell {
  text-align: right;
  padding-right: 12px;
}
.table-wrapper {
    max-height: 300px; /* tinggi scroll area */
    overflow-y: auto;
    border: 1px solid #ccc;
}
.product-table {
	width: 100%;
	border-collapse: collapse;
}
  .product-table th,
  .product-table td {
    padding: 8px;
    border: 1px solid #ccc;
    background: #fff;
  }

  .product-table thead th {
    position: sticky;
    top: 0;
    background: #f9f9f9;
    z-index: 1;
  }
.product-table tbody tr:hover td {
  background: #f1f1f1;
}
/* Print Styles */
@media print {
    body * {
        visibility: hidden;
    }
    #receipt-modal, #receipt-content, #receipt-content * {
        visibility: visible;
    }
    #receipt-modal {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        box-shadow: none;
        border: none;
    }
    .modal-content.receipt {
        max-width: 100%;
        border: none;
        box-shadow: none;
    }
    .close-button, #print-receipt-button {
        display: none;
    }
}