/* ----------------------------- */
/* PALET & GLOBAL STYLE (BARU)   */
/* ----------------------------- */

:root {
  --primary: #7A8E76;        /* sage green */
  --primary-dark: #4F5C47;   /* deep olive */
  --accent: #D9C28E;         /* champagne gold */
  --background: #F7F5EE;     /* soft cream */
  --border: #D9D2C8;         /* warm neutral */
  --text: #3B2A1C;           /* dark café brown */
  --radius-lg: 24px;
  --radius-md: 18px;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--background);
  color: var(--text);
  padding: 0;
  margin: 0;
}

/* ----------------------------- */
/* LOGO & BUTTON GLOBAL          */
/* ----------------------------- */

.logo-square {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--primary);
}

/* tombol utama (Tambah, Bayar, dll) */
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-color: var(--primary);
  border-radius: 14px;
  padding: 10px 18px;
  color: #fff;
  font-weight: 600;
  box-shadow: 0 3px 6px rgba(0,0,0,0.15);
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-dark), #343F32);
  border-color: var(--primary-dark);
}

.pos-logo {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  object-fit: cover;
}

/* ----------------------------- */
/* NAVBAR BUTTONS (POS.PHP)      */
/* ----------------------------- */

.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(1) {
  /* LAPORAN - gold */
  background: var(--accent);
  border-color: var(--accent);
  color: var(--text);
  font-weight: 600;
}
.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(1):hover {
  background: #C5AF7C;
  border-color: #C5AF7C;
}

.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(2) {
  /* KELOLA PRODUK - dark olive */
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: #fff;
  font-weight: 600;
}
.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(2):hover {
  background: #363F32;
  border-color: #363F32;
}

.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(3) {
  /* KELUAR - muted brick */
  background: #9F6B52;
  border-color: #9F6B52;
  color: #fff;
  font-weight: 600;
}
.navbar .d-flex.gap-2 > a.btn-outline-dark:nth-child(3):hover {
  background: #6E4736;
  border-color: #6E4736;
}

/* ----------------------------- */
/* CARD LOGIN / KONTEN           */
/* ----------------------------- */

.login-card {
  border-radius: var(--radius-lg);
  padding: 25px 28px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  background: #fff;
}

/* ----------------------------- */
/* SEARCH BOX                    */
/* ----------------------------- */

.search-box input {
  border-radius: 18px;
  padding: 10px 16px;
  border: 2px solid var(--border);
  background: #fff;
}

.search-box .input-group-text {
  border-radius: 18px 0 0 18px;
  background: #fff;
  border: 2px solid var(--border);
  border-right: none;
}

/* ----------------------------- */
/* PRODUK LIST (HANYA INI SCROLL)*/
/* ----------------------------- */

.product-list-container {
  /* tinggi disesuaikan supaya batas bawah sejajar tombol BAYAR */
  height: calc(100vh - 70px);
  overflow-y: auto;
  padding-right: 6px;
}

.product-list-container::-webkit-scrollbar {
  width: 8px;
}
.product-list-container::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 8px;
}
.product-list-container::-webkit-scrollbar-track {
  background: #E5DFD6;
}

/* ----------------------------- */
/* KARTU PRODUK                  */
/* ----------------------------- */

.product-card {
  border-radius: var(--radius-md);
  border: 1.8px solid var(--border);
  padding: 12px;
  background: #fff;
  transition: .2s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.18);
}

.product-img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid var(--border);
}

.product-name {
  font-weight: 600;
  font-size: 16px;
}

.product-price {
  font-weight: 700;
  font-size: 17px;
  color: var(--primary);
}

/* ----------------------------- */
/* PANEL KERANJANG (KANAN)       */
/* ----------------------------- */

.cart-panel {
  border-left: 4px solid var(--primary);
  background: #fff;
  padding: 18px;
  height: 100vh;
  position: sticky;
  top: 0;
  box-shadow: -6px 0 16px rgba(0,0,0,0.08);
}

/* LIST ITEM KERANJANG (SCROLL HANYA DI SINI) */
.cart-items-scroll {
  max-height: 45vh;
  overflow-y: auto;
  padding-right: 4px;
}

.cart-items-scroll::-webkit-scrollbar {
  width: 6px;
}

.cart-items-scroll::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 8px;
}

.cart-item {
  background: #F7F2EA;
  border-radius: 14px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  margin-bottom: 10px;
}

.cart-total-box {
  background: #EFE5D6;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 16px;
  margin-top: 12px;
}

.cart-total-box h4 {
  font-weight: 700;
}

/* FOOTER TOTAL CHECKOUT BUTTON */
.checkout-btn {
  width: 100%;
  padding: 14px;
  border-radius: 18px;
  font-size: 17px;
  font-weight: 700;
}

/* ----------------------------- */
/* KELOLA PRODUK - TABEL SCROLL  */
/* ----------------------------- */

.product-table-scroll {
  max-height: calc(100vh - 230px);
  overflow-y: auto;
}

.product-table-scroll table {
  margin-bottom: 0;
}

.product-table-scroll thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #F0E7DD;
}

/* ========================================= */
/*  BUTTON LAPORAN: KEMBALI & STRUK          */
/* ========================================= */

/* Tombol "Kembali ke Kasir" – pakai warna utama tema */
.btn-kembali {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff !important;
  font-weight: 600;
  border-radius: 999px;
  padding: 8px 26px;
  box-shadow: 0 3px 6px rgba(0,0,0,0.15);
  transition: .2s ease;
  text-decoration: none !important;    /* tambah */
}


.btn-kembali:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: #fff !important;
}

/* Tombol "Struk" – aksen latte, tetap pill */
.btn-struk {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--text) !important;
  font-weight: 600;
  border-radius: 999px;
  padding: 6px 20px;
  box-shadow: 0 3px 6px rgba(0,0,0,0.15);
  transition: .2s ease;
  text-decoration: none !important;   /* <<< tambah ini */
}
.btn-struk:hover {
  background: #c5af7c;
  border-color: #c5af7c;
  color: var(--text) !important;
  text-decoration: none !important;   /* <<< dan ini */
}
