/* ===================================================================
   S T Y L E . C S S (FINAL - SESUAI GAMBAR 2)
   =================================================================== */

body { font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; margin: 0; padding: 0; background-color: #45b29d; color: white; overflow-x: hidden; }

/* --- Header --- */
.header { display: flex; justify-content: space-between; align-items: center; padding: 15px 25px; background-color: rgba(0,0,0,0.15); font-size: 1.1rem; }
.header a { color: white; text-decoration: none; font-weight: 600; display: flex; align-items: center; gap: 8px; }

/* --- Container & Layout --- */
.container { max-width: 1200px; margin: 25px auto; padding: 0 20px; }
.layout-split { display: flex; gap: 30px; align-items: flex-start; }
.col-left { flex: 1; min-width: 300px; }
/* Kolom kanan dibuat sedikit lebih lebar agar lega */
.col-right { flex: 1.3; min-width: 320px; }

/* --- Typography & Headings --- */
h2, h3 { margin-top: 0; margin-bottom: 15px; font-weight: 600; font-size: 1.3rem; }
h2 { border-bottom: 1px solid rgba(255,255,255,0.3); padding-bottom: 10px; }
h3 { margin-top: 25px; } /* Jarak antar section di kanan */

/* --- Form Elements (General) --- */
.form-group { margin-bottom: 15px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 500; font-size: 0.95rem; }

/* Style Universal untuk Input & Select agar seragam */
input[type="text"], input[type="tel"], input[type="number"], select {
    width: 100%;
    padding: 10px 12px; /* Padding pas */
    border: 1px solid #ced4da; /* Border abu halus seperti di gambar 2 */
    border-radius: 6px; /* Sudut agak membulat */
    background-color: #fff; /* Latar putih bersih */
    color: #495057; /* Teks abu gelap */
    font-size: 1rem;
    height: 42px; /* TINGGI FIX agar semua sejajar */
    box-sizing: border-box; /* Wajib */
    outline: none; transition: border-color 0.15s;
}
input:focus, select:focus { border-color: #f06292; box-shadow: 0 0 0 2px rgba(240,98,146,0.25); }
input[readonly] { background-color: #e9ecef; cursor: pointer; }

/* --- KHUSUS KOLOM KANAN (SESUAI GAMBAR 2) --- */

/* Group Diskon: Sejajar dan Rapi */
.form-group-diskon { display: flex; gap: 10px; margin-bottom: 20px; }
.form-group-diskon select { flex: 3; } /* Select lebih lebar */
.form-group-diskon input { flex: 2; text-align: right; } /* Input jumlah di kanan */

/* Box Putih Rincian (Subtotal & Diskon) */
#summaryBox {
    background-color: #fff; /* Latar Putih */
    color: #333; /* Teks Gelap */
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 20px;
    border: 1px solid #e9ecef; /* Border sangat halus */
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.summary-row { display: flex; justify-content: space-between; font-size: 1.05rem; margin-bottom: 8px; color: #555; }
.summary-row:last-child { margin-bottom: 0; }
.summary-row span:last-child { font-weight: 600; color: #333; } /* Nilai di kanan tebal */
.summary-row.diskon span:last-child { color: #dc3545; } /* Nilai diskon MERAH */

/* Box Total Besar (Pink Magenta) */
.total-box {
    background-color: #d81b60; /* Pink Magenta Tua (Sesuai Gambar 2) */
    color: white;
    padding: 20px 25px;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}
.total-box .label-total { font-size: 1.4rem; font-weight: 600; text-transform: uppercase; }
.total-box .amount-total { text-align: right; line-height: 1; }
.total-box .amount-total small { font-size: 1rem; font-weight: normal; opacity: 0.8; margin-right: 5px; } /* Rp kecil */
.total-box .amount-total span { font-size: 2.2rem; font-weight: 700; } /* Angka Besar */

/* --- List Pesanan --- */
.list-item { background-color: white; color: #333; padding: 12px; border-radius: 8px; margin-bottom: 8px; display: flex; align-items: center; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.item-icon-kode { width: 40px; height: 40px; border-radius: 6px; background: #fce4ec; color: #c2185b; display: flex; align-items: center; justify-content: center; font-weight: 700; margin-right: 12px; font-size: 1rem; }
.item-details { flex-grow: 1; }
.item-name { font-weight: 600; color: #333; font-size: 1rem; }
.item-price { font-size: 0.85rem; color: #777; }
.btn-hapus { background-color: #ef5350; color: white; border: none; padding: 6px 10px; border-radius: 4px; cursor: pointer; font-size: 0.85rem; }

/* --- Buttons --- */
.btn { width: 100%; padding: 12px; border: none; border-radius: 6px; font-size: 1.1rem; font-weight: 600; color: white; cursor: pointer; text-align: center; transition: background 0.2s; }
.btn-pink { background-color: #ec407a; } .btn-pink:hover { background-color: #d81b60; }
.btn-pink-dark { background-color: #ab003c; } /* Untuk tombol tambah */
.btn-blue { background-color: #42a5f5; }
.btn-green { background-color: #66bb6a; }

/* --- Modals --- */
.modal-backdrop { display: none; position: fixed; top:0; left:0; width:100%; height:100%; background: rgba(0,0,0,0.5); z-index: 99; }
.modal { display: none; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: white; color: #333; width: 90%; max-width: 450px; border-radius: 8px; z-index: 100; box-shadow: 0 5px 15px rgba(0,0,0,0.3); flex-direction: column; max-height: 90vh; }
.modal.show, .modal-backdrop.show { display: flex; }
.modal-header { padding: 15px; border-bottom: 1px solid #eee; display: flex; justify-content: space-between; align-items: center; }
.modal-header h3 { margin: 0; font-size: 1.2rem; color: #333; border: none; }
.modal-close { font-size: 1.5rem; cursor: pointer; color: #999; }
.modal-body { padding: 15px; overflow-y: auto; }
.modal-footer { padding: 15px; border-top: 1px solid #eee; text-align: right; background: #f8f9fa; }
.modal-list-item { padding: 12px; border-bottom: 1px solid #eee; cursor: pointer; display: flex; justify-content: space-between; }
.modal-list-item:hover { background: #f0f0f0; }
.modal .form-group label { color: #555; }

/* --- Responsive --- */
@media (max-width: 768px) {
    .layout-split { flex-direction: column; gap: 20px; }
    .col-left, .col-right { width: 100%; }
    .total-box { flex-direction: column; align-items: flex-start; gap: 5px; }
    .total-box .amount-total { text-align: left; }
}