/* =========================================================
   Etalase Live — gaya tampilan v2
   Palet : krem lembut + pink rose
   Huruf : Figtree
   Tata letak: sidebar (laptop) + menu bawah (HP)
   ========================================================= */

:root {
  --bg: #FAF6F2;        /* latar krem */
  --bg-2: #F3ECE5;      /* krem lebih tua: chip netral, area cekung */
  --surface: #FFFFFF;   /* kartu */
  --line: #EFE6DE;      /* garis halus */
  --line-2: #E4D8CE;    /* garis input & chip */
  --ink: #2B2326;       /* teks utama */
  --ink-2: #54484D;     /* teks kedua */
  --muted: #7A6C71;     /* teks keterangan */
  --pink: #C2417A;      /* aksen utama */
  --pink-600: #A63366;  /* hover */
  --pink-50: #FDF3F7;
  --pink-100: #FBE5EE;
  --pink-200: #F4C8D9;
  --pink-ink: #9A2C5D;  /* teks di atas pink muda */
  --green: #2F855A;
  --red: #B42318;
  --red-50: #FDECEA;

  --font: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --shadow-sm: 0 1px 2px rgba(74, 32, 48, .04), 0 4px 14px rgba(74, 32, 48, .05);
  --shadow-md: 0 12px 30px rgba(74, 32, 48, .09);
  --shadow-lg: 0 24px 60px rgba(120, 40, 80, .16);
  --ring: 0 0 0 4px rgba(194, 65, 122, .15);
  --sidebar-w: 256px;
  --topbar-h: 58px;
  --tabbar-h: 68px;

  /* Bootstrap */
  --bs-body-bg: var(--bg);
  --bs-body-color: var(--ink);
  --bs-body-font-family: var(--font);
  --bs-border-color: var(--line);
  --bs-primary: #C2417A;
  --bs-primary-rgb: 194, 65, 122;
  --bs-link-color: #C2417A;
  --bs-link-color-rgb: 194, 65, 122;
  --bs-link-hover-color: #A63366;
  --bs-link-hover-color-rgb: 166, 51, 102;
  --bs-secondary-color: var(--muted);
  --bs-emphasis-color: var(--ink);
  --bs-heading-color: var(--ink);
  --bs-focus-ring-color: rgba(194, 65, 122, .25);
  --bs-border-radius: 14px;
}

/* ---------- Dasar ---------- */
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
}
@media (min-width: 992px) { body { padding-bottom: 0; } }
h1, h2, h3 { letter-spacing: -.02em; }
a { color: var(--pink); text-underline-offset: 3px; }
a:hover { color: var(--pink-600); }
::selection { background: var(--pink-100); color: var(--ink); }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
mark { background: var(--pink-100); color: var(--pink-ink); padding: 0 2px; border-radius: 4px; }
kbd {
  background: var(--surface); color: var(--ink-2);
  border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 6px;
  font-family: var(--font); font-size: .74rem; font-weight: 700;
  padding: 1px 6px; box-shadow: none;
}
.muted { color: var(--muted) !important; }
.small-2 { font-size: .86rem; }
.min-w-0 { min-width: 0; }
.flex-none { flex: none; }
.text-danger-2 { color: var(--red); }

/* ---------- Tombol ---------- */
.btn {
  --bs-btn-font-weight: 600;
  --bs-btn-font-size: .94rem;
  --bs-btn-padding-y: .62rem;
  --bs-btn-padding-x: 1.15rem;
  --bs-btn-border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  white-space: nowrap;
}
.btn-sm { --bs-btn-padding-y: .4rem; --bs-btn-padding-x: .85rem; --bs-btn-font-size: .85rem; --bs-btn-border-radius: 999px; }
.btn-lg { --bs-btn-padding-y: .82rem; --bs-btn-padding-x: 1.4rem; --bs-btn-font-size: 1rem; --bs-btn-border-radius: 999px; }
.btn-pink {
  --bs-btn-color: #fff; --bs-btn-bg: var(--pink); --bs-btn-border-color: var(--pink);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--pink-600); --bs-btn-hover-border-color: var(--pink-600);
  --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--pink-600); --bs-btn-active-border-color: var(--pink-600);
  --bs-btn-focus-shadow-rgb: 194, 65, 122;
  --bs-btn-disabled-color: #fff; --bs-btn-disabled-bg: var(--pink-200); --bs-btn-disabled-border-color: var(--pink-200);
  box-shadow: 0 6px 16px rgba(194, 65, 122, .22);
}
.btn-pink:disabled { box-shadow: none; }
.btn-soft {
  --bs-btn-color: var(--pink-ink); --bs-btn-bg: var(--pink-50); --bs-btn-border-color: var(--pink-100);
  --bs-btn-hover-color: var(--pink-ink); --bs-btn-hover-bg: var(--pink-100); --bs-btn-hover-border-color: var(--pink-200);
  --bs-btn-active-color: var(--pink-ink); --bs-btn-active-bg: var(--pink-100); --bs-btn-active-border-color: var(--pink-200);
  --bs-btn-focus-shadow-rgb: 194, 65, 122;
}
.btn-white {
  --bs-btn-color: var(--pink-ink); --bs-btn-bg: #fff; --bs-btn-border-color: var(--pink-100);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: var(--pink); --bs-btn-hover-border-color: var(--pink);
  --bs-btn-active-color: #fff; --bs-btn-active-bg: var(--pink-600); --bs-btn-active-border-color: var(--pink-600);
  --bs-btn-focus-shadow-rgb: 194, 65, 122;
}
.btn-line {
  --bs-btn-color: var(--ink); --bs-btn-bg: #fff; --bs-btn-border-color: var(--line-2);
  --bs-btn-hover-color: var(--pink-ink); --bs-btn-hover-bg: var(--pink-50); --bs-btn-hover-border-color: var(--pink-200);
  --bs-btn-active-color: var(--pink-ink); --bs-btn-active-bg: var(--pink-100); --bs-btn-active-border-color: var(--pink-200);
  --bs-btn-focus-shadow-rgb: 194, 65, 122;
}
.btn-ghost {
  --bs-btn-color: var(--muted); --bs-btn-bg: transparent; --bs-btn-border-color: transparent;
  --bs-btn-hover-color: var(--pink-ink); --bs-btn-hover-bg: var(--pink-50); --bs-btn-hover-border-color: transparent;
  --bs-btn-active-color: var(--pink-ink); --bs-btn-active-bg: var(--pink-100); --bs-btn-active-border-color: transparent;
  --bs-btn-focus-shadow-rgb: 194, 65, 122;
}
.btn-danger-x {
  --bs-btn-color: #fff; --bs-btn-bg: var(--red); --bs-btn-border-color: var(--red);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: #912018; --bs-btn-hover-border-color: #912018;
  --bs-btn-active-color: #fff; --bs-btn-active-bg: #912018; --bs-btn-active-border-color: #912018;
  --bs-btn-focus-shadow-rgb: 180, 35, 24;
}
.btn-icon { width: 40px; height: 40px; padding: 0; gap: 0; --bs-btn-border-radius: 12px; }
.btn-close:focus { box-shadow: var(--ring); }

/* ---------- Form ---------- */
.form-control, .form-select {
  background-color: #fff;
  border: 1px solid var(--line-2);
  border-radius: 14px;
  padding: .7rem .95rem;
  color: var(--ink);
  font-size: .98rem;
}
.form-select { padding-right: 2.5rem; }
.form-control-sm { padding: .45rem .75rem; font-size: .9rem; border-radius: 12px; }
.form-control-lg { padding: .82rem 1rem; font-size: 1.02rem; border-radius: 14px; }
.form-control::placeholder { color: #A39499; }
.form-control:focus, .form-select:focus { border-color: var(--pink); box-shadow: var(--ring); color: var(--ink); }
.form-control.is-invalid, .form-select.is-invalid { border-color: var(--red); }
.form-control.is-invalid:focus { box-shadow: 0 0 0 4px rgba(180, 35, 24, .12); }
.invalid-feedback { color: var(--red); font-weight: 500; }
.form-label { font-weight: 600; font-size: .9rem; margin-bottom: .4rem; color: var(--ink); }
.form-text { color: var(--muted); font-size: .84rem; }
.form-check-input { border-color: #CDBFC4; }
.form-check-input:checked { background-color: var(--pink); border-color: var(--pink); }
.form-check-input:focus { border-color: var(--pink); box-shadow: var(--ring); }
.form-switch { padding-left: 3.2em; }
.form-switch .form-check-input { width: 2.4em; height: 1.3em; margin-top: .12em; margin-left: -3.2em; }
.form-switch .form-check-input:focus:not(:checked) {
  --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23F4C8D9'/%3e%3c/svg%3e");
}
input[type=search]::-webkit-search-cancel-button { -webkit-appearance: none; display: none; }
input[type=number].no-spin { -moz-appearance: textfield; appearance: textfield; }
input[type=number].no-spin::-webkit-outer-spin-button,
input[type=number].no-spin::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* =========================================================
   KERANGKA APLIKASI
   ========================================================= */
.app { min-height: 100vh; }
@media (min-width: 992px) { .app { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); } }

.logo {
  flex: none; display: block;
  width: 40px; height: 40px; border-radius: 22.6%; /* sama dengan sudut di logo-mark.svg */
  box-shadow: 0 6px 16px rgba(194, 65, 122, .28);
}

/* Sidebar (laptop) */
.sidebar { display: none; }
@media (min-width: 992px) {
  .sidebar {
    display: flex; flex-direction: column;
    position: sticky; top: 0; height: 100vh;
    padding: 22px 16px 16px;
    background: var(--surface); border-right: 1px solid var(--line);
  }
}
.side-brand { display: flex; align-items: center; gap: 12px; padding: 0 8px 22px; color: var(--ink); text-decoration: none; }
.side-brand:hover { color: var(--ink); }
.side-brand b { display: block; font-weight: 800; font-size: 1.08rem; letter-spacing: -.015em; line-height: 1.2; }
.side-brand small { display: block; color: var(--muted); font-size: .8rem; }
.side-label { font-size: .78rem; font-weight: 600; color: var(--muted); padding: 14px 12px 6px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 12px;
  color: var(--ink-2); font-weight: 600; font-size: .95rem; text-decoration: none;
}
.side-nav a .bi { font-size: 1.1rem; color: var(--muted); }
.side-nav a:hover { background: var(--bg); color: var(--ink); }
.side-nav a.active { background: var(--pink-50); color: var(--pink-ink); }
.side-nav a.active .bi { color: var(--pink); }
.side-foot { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 16px; background: var(--bg); }
.side-foot b { display: block; font-size: .9rem; font-weight: 700; line-height: 1.2; }
.side-foot small { display: block; font-size: .78rem; color: var(--muted); }
.avatar { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--pink-100); color: var(--pink-ink); font-weight: 800; }

/* Bar atas & menu bawah (HP) */
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 10px;
  height: var(--topbar-h); padding: 0 12px 0 16px;
  background: rgba(250, 246, 242, .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar .logo { width: 32px; height: 32px; box-shadow: 0 3px 8px rgba(194, 65, 122, .22); }
.topbar-title { font-weight: 800; font-size: 1.05rem; letter-spacing: -.015em; }
@media (min-width: 992px) { .topbar { display: none; } }
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  display: grid; grid-template-columns: repeat(4, 1fr);
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  padding: 6px 8px env(safe-area-inset-bottom);
  background: rgba(255, 255, 255, .96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
}
@media (min-width: 992px) { .tabbar { display: none; } }
.tabbar a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  color: var(--muted); font-size: .72rem; font-weight: 600; text-decoration: none;
}
.tabbar .ic { display: grid; place-items: center; width: 48px; height: 28px; border-radius: 999px; font-size: 1.15rem; transition: background .15s; }
.tabbar a.active { color: var(--pink-ink); }
.tabbar a.active .ic { background: var(--pink-100); color: var(--pink); }

/* Konten */
.app-main { min-width: 0; padding: 20px 16px 32px; }
@media (min-width: 992px) { .app-main { padding: 32px 40px 48px; } }
.page { max-width: 1100px; margin: 0 auto; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px; margin-bottom: 22px; }
.page-head h1 { font-size: 1.55rem; font-weight: 800; line-height: 1.15; margin: 0; }
.page-head p { margin: .3rem 0 0; color: var(--muted); max-width: 62ch; }
@media (min-width: 992px) { .page-head h1 { font-size: 1.85rem; } }
.crumb { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px; color: var(--muted); font-weight: 600; font-size: .9rem; text-decoration: none; }
.crumb:hover { color: var(--pink-ink); }
.hint { display: flex; gap: 8px; align-items: flex-start; margin: 14px 4px 0; color: var(--muted); font-size: .86rem; }
.hint .bi { color: var(--pink); }

/* Kartu */
.card-x { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-sm); }
.card-pad { padding: 20px; }
@media (min-width: 768px) { .card-pad { padding: 24px; } }
.card-title { font-size: 1.05rem; font-weight: 700; margin: 0; letter-spacing: -.01em; }
.card-sub { font-size: .87rem; color: var(--muted); margin: .25rem 0 0; }
.sub-title { font-size: .95rem; font-weight: 700; margin: 0 0 12px; }

/* Keadaan kosong */
.empty-state { padding: 44px 24px; text-align: center; }
.empty-state h2 { font-size: 1.1rem; font-weight: 700; margin: 14px 0 6px; }
.empty-state p { color: var(--muted); margin: 0 auto 16px; max-width: 42ch; }
.empty-ic { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; background: var(--pink-50); color: var(--pink); font-size: 1.5rem; }

/* ---------- Dropdown, modal, offcanvas, toast ---------- */
.dropdown-menu {
  --bs-dropdown-bg: #fff;
  --bs-dropdown-border-color: var(--line);
  --bs-dropdown-border-radius: 16px;
  --bs-dropdown-link-color: var(--ink);
  --bs-dropdown-link-hover-color: var(--pink-ink);
  --bs-dropdown-link-hover-bg: var(--pink-50);
  --bs-dropdown-link-active-color: var(--pink-ink);
  --bs-dropdown-link-active-bg: var(--pink-100);
  --bs-dropdown-font-size: .92rem;
  --bs-dropdown-divider-bg: var(--line);
  padding: 6px; box-shadow: var(--shadow-md);
}
.dropdown-item { display: flex; align-items: center; gap: .6rem; border-radius: 10px; padding: .52rem .75rem; }
.dropdown-item .bi { color: var(--muted); }
.dropdown-item.text-danger, .dropdown-item.text-danger .bi { color: var(--red) !important; }
.dropdown-item.text-danger:hover { background: var(--red-50); }
.modal-content { background: #fff; border: 0; border-radius: 24px; box-shadow: var(--shadow-lg); }
.modal-header { border-bottom: 0; padding: 22px 24px 6px; }
.modal-title { font-weight: 800; font-size: 1.2rem; letter-spacing: -.015em; }
.modal-body { padding: 14px 24px 20px; }
.modal-footer { border-top: 1px solid var(--line); padding: 14px 24px; gap: 8px; }
.modal-footer > * { margin: 0; }
.modal-backdrop { --bs-backdrop-bg: #2B2326; --bs-backdrop-opacity: .35; }
.offcanvas-backdrop { --bs-backdrop-bg: #2B2326; }
.offcanvas-backdrop.show { opacity: .35; }
.app-toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + 16px + env(safe-area-inset-bottom)); z-index: 2000;
  display: flex; align-items: center; gap: .55rem;
  max-width: calc(100vw - 32px);
  background: var(--ink); color: #fff;
  padding: .72rem 1.15rem; border-radius: 999px;
  font-weight: 600; font-size: .9rem;
  box-shadow: var(--shadow-md);
  opacity: 0; transform: translate(-50%, 14px); pointer-events: none;
  transition: opacity .2s, transform .2s;
}
.app-toast .bi { color: var(--pink-200); }
.app-toast.show { opacity: 1; transform: translate(-50%, 0); }
@media (min-width: 992px) { .app-toast { bottom: 28px; } }

/* =========================================================
   NOMOR ETALASE
   ========================================================= */
.no-tile {
  position: relative; flex: none;
  width: 64px; height: 64px; border-radius: 18px;
  display: grid; place-items: center;
  background: var(--pink-50); border: 1px solid var(--pink-100);
  color: var(--pink-ink);
  font-weight: 800; font-size: 1.6rem; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums;
}
.no-tile .ic {
  position: absolute; right: -5px; bottom: -5px;
  width: 26px; height: 26px; border-radius: 9px;
  display: grid; place-items: center;
  background: #fff; border: 1px solid var(--line); color: var(--muted);
  font-size: .78rem; box-shadow: var(--shadow-sm);
}
.no-tile-lg { width: 76px; height: 76px; border-radius: 22px; font-size: 2rem; }
.no-xs {
  display: inline-grid; place-items: center;
  min-width: 28px; height: 26px; padding: 0 7px; border-radius: 8px;
  background: var(--pink-50); border: 1px solid var(--pink-100);
  color: var(--pink-ink); font-weight: 800; font-size: .8rem; text-decoration: none;
}
a.no-xs:hover { background: var(--pink); border-color: var(--pink); color: #fff; }
.no-xs.is-off { background: var(--bg-2); border-color: var(--line-2); color: var(--muted); }

/* =========================================================
   HALAMAN LIVE
   ========================================================= */
.live-wrap { max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
@media (min-width: 1200px) { .live-wrap { grid-template-columns: minmax(0, 1fr) 360px; } }
.live-hello h1 { font-size: 1.55rem; font-weight: 800; margin: 0; }
.live-hello p { color: var(--muted); margin: .25rem 0 0; }
@media (min-width: 992px) { .live-hello h1 { font-size: 1.85rem; } }

.search-sticky {
  position: sticky; top: var(--topbar-h); z-index: 30;
  margin: 0 -16px; padding: 14px 16px 10px;
  background: var(--bg);
}
@media (min-width: 992px) { .search-sticky { top: 0; margin: 0; padding: 18px 0 12px; } }
.search { position: relative; }
.search > .bi-search { position: absolute; left: 19px; top: 50%; transform: translateY(-50%); font-size: 1.15rem; color: var(--pink); pointer-events: none; }
.search input {
  width: 100%; height: 58px; padding: 0 56px 0 52px;
  background: #fff; color: var(--ink);
  border: 1px solid var(--line-2); border-radius: 18px;
  box-shadow: var(--shadow-sm);
  font-size: 1.08rem; font-weight: 500;
}
.search input::placeholder { color: #A39499; font-weight: 400; }
.search input:focus { outline: none; border-color: var(--pink); box-shadow: var(--ring), var(--shadow-sm); }
.kbd-hint { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); pointer-events: none; }
.search-clear {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border: 0; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--bg); color: var(--muted);
}
.search-clear:hover { background: var(--pink-50); color: var(--pink-ink); }
.search input:placeholder-shown ~ .search-clear { display: none; }
.search input:not(:placeholder-shown) ~ .kbd-hint { display: none !important; }

.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px; margin: 0 -2px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 15px; border-radius: 999px;
  border: 1px solid var(--line-2); background: #fff; color: var(--ink-2);
  font-size: .87rem; font-weight: 600; line-height: 1.2; white-space: nowrap;
}
.chip:hover { border-color: var(--pink-200); color: var(--pink-ink); }
.chip[aria-pressed="true"] { background: var(--pink); border-color: var(--pink); color: #fff; box-shadow: 0 4px 12px rgba(194, 65, 122, .22); }

.recent { display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: .83rem; color: var(--muted); overflow-x: auto; scrollbar-width: none; white-space: nowrap; }
.recent::-webkit-scrollbar { display: none; }
.recent > span { margin-right: 2px; }
.recent button { flex: none; border: 0; border-radius: 8px; padding: 3px 10px; background: var(--bg-2); color: var(--ink-2); font-weight: 600; }
.recent button:hover { background: var(--pink-100); color: var(--pink-ink); }

/* Jawaban cepat */
.answer {
  margin-top: 14px; padding: 18px 20px 20px;
  border-radius: 24px; border: 1px solid var(--pink-100);
  background: linear-gradient(135deg, #FBE2EC 0%, #FDF0F5 55%, #FFF8F3 100%);
  animation: muncul .22s ease-out;
}
.answer + .answer { margin-top: 10px; }
.answer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.answer-name { font-size: 1.4rem; font-weight: 800; line-height: 1.2; letter-spacing: -.02em; }
.answer-line { margin-top: 2px; color: var(--pink-ink); font-weight: 600; font-size: .92rem; }
.answer-nums { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.num-btn {
  width: 52px; height: 52px; border-radius: 16px;
  display: grid; place-items: center;
  border: 1px solid var(--pink-200); background: #fff; color: var(--pink-ink);
  font-weight: 800; font-size: 1.35rem; letter-spacing: -.02em;
  box-shadow: 0 4px 10px rgba(194, 65, 122, .10);
  transition: transform .15s ease, background .15s, color .15s;
}
.num-btn:hover { background: var(--pink); border-color: var(--pink); color: #fff; transform: translateY(-2px); }
@media (max-width: 575.98px) {
  .answer { padding: 16px; }
  .answer-nums { gap: 8px; }
  .num-btn { width: 44px; height: 44px; border-radius: 14px; font-size: 1.2rem; }
  .search input { font-size: 1rem; }
}
@keyframes muncul { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.result-meta { display: flex; justify-content: space-between; align-items: center; margin: 20px 4px 10px; font-size: .88rem; color: var(--muted); }

/* Daftar etalase (gaya keranjang TikTok) */
.items { display: flex; flex-direction: column; gap: 10px; }
.item {
  display: flex; align-items: center; gap: 16px;
  width: 100%; padding: 12px 16px 12px 12px;
  border: 1px solid var(--line); border-radius: 20px; background: #fff;
  color: inherit; text-align: left; font: inherit;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s;
}
.item:hover { border-color: var(--pink-200); box-shadow: var(--shadow-md); }
.item:hover .item-cta { background: var(--pink); color: #fff; }
.item[aria-current="true"] { border-color: var(--pink); box-shadow: var(--ring); }
.item:focus-visible { outline: 2px solid var(--pink); outline-offset: 2px; }
.item-body { flex: 1; min-width: 0; }
.item-name { display: block; font-weight: 700; font-size: 1.02rem; line-height: 1.3; }
.item-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 4px; font-size: .82rem; color: var(--muted); }
.tag-soft { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 7px; background: var(--bg-2); color: var(--ink-2); font-weight: 600; font-size: .76rem; }
.item-hits { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.hit { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; background: var(--pink-100); color: var(--pink-ink); font-size: .78rem; font-weight: 700; }
.hit-more { align-self: center; font-size: .78rem; color: var(--muted); }
.item-cta { flex: none; align-items: center; padding: 8px 15px; border-radius: 999px; background: var(--pink-50); color: var(--pink-ink); font-size: .84rem; font-weight: 700; transition: background .15s, color .15s; }
.item-go { flex: none; color: var(--muted); }

/* Panel detail */
.detail-col { display: none; }
@media (min-width: 1200px) { .detail-col { display: block; } }
.detail { background: #fff; border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow-sm); }
.detail-col .detail { position: sticky; top: 24px; max-height: calc(100vh - 48px); overflow: auto; margin-top: 18px; }
.detail-empty { padding: 32px 26px; }
.detail-empty h2 { font-size: 1.1rem; font-weight: 700; margin: 16px 0 6px; }
.detail-empty p { color: var(--muted); margin-bottom: 20px; }
.keys { list-style: none; padding: 16px 0 0; margin: 0; display: grid; gap: 10px; font-size: .88rem; color: var(--muted); border-top: 1px dashed var(--line-2); }
.keys kbd { margin-right: 8px; }
.dt-head { display: flex; align-items: center; gap: 16px; padding: 22px 22px 18px; }
.dt-name { font-size: 1.2rem; font-weight: 800; line-height: 1.25; margin: 0 0 6px; letter-spacing: -.015em; }
.dt-body { padding: 0 22px 22px; }
.dt-desc { margin: 0 0 18px; padding: 12px 14px; border-radius: 14px; background: var(--bg); color: var(--ink-2); font-size: .88rem; }
.vfilter { position: relative; margin-bottom: 18px; }
.vfilter .bi { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: .9rem; }
.vfilter input { padding-left: 36px; }
.vgroup + .vgroup { margin-top: 20px; padding-top: 18px; border-top: 1px dashed var(--line-2); }
.vgroup-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.vgroup-title { font-size: 1rem; font-weight: 700; margin: 0; }
.vgroup-sum { font-size: .8rem; color: var(--muted); }
.vsub { font-size: .78rem; font-weight: 700; color: var(--muted); margin: 12px 0 8px; }
.vsub span { font-weight: 500; margin-left: 2px; }
.vchips { display: flex; flex-wrap: wrap; gap: 8px; }
.vgroup-head + .vchips { margin-top: 12px; }
.vchip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--line-2); background: #fff; color: var(--ink);
  font-size: .88rem; font-weight: 500; line-height: 1.2;
}
.vchip.is-hit { background: var(--pink); border-color: var(--pink); color: #fff; font-weight: 700; box-shadow: 0 4px 12px rgba(194, 65, 122, .22); }

.offcanvas.sheet {
  --bs-offcanvas-height: auto;
  --bs-offcanvas-bg: #fff;
  --bs-offcanvas-border-width: 0;
  max-height: 88vh;
  border-radius: 28px 28px 0 0;
  box-shadow: var(--shadow-lg);
}
.sheet-handle { display: block; flex: none; width: 44px; height: 5px; border-radius: 999px; background: var(--line-2); margin: 10px auto 0; }
.sheet .offcanvas-body { padding: 0 0 env(safe-area-inset-bottom); overflow-y: auto; }
.sheet .dt-head { padding-top: 16px; }

/* =========================================================
   HALAMAN KELOLA
   ========================================================= */
.table-card { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-sm); }
.toolbar { display: grid; grid-template-columns: minmax(0, 1fr) 200px 200px; gap: 10px; padding: 16px; border-bottom: 1px solid var(--line); }
@media (max-width: 743.98px) {
  .toolbar { grid-template-columns: 1fr 1fr; padding: 14px; }
  .toolbar .form-select { font-size: .88rem; padding-left: .8rem; padding-right: 2rem; background-position: right .65rem center; }
  .toolbar .tb-search { grid-column: 1 / -1; }
}
.tb-search { position: relative; }
.tb-search .bi { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.tb-search input { padding-left: 40px; }

/* Baris etalase */
.thead, .trow {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 130px 180px 44px;
  gap: 16px; align-items: center; padding: 12px 20px;
}
.thead { font-size: .78rem; font-weight: 700; color: var(--muted); background: var(--bg); border-bottom: 1px solid var(--line); }
.trow + .trow { border-top: 1px solid var(--line); }
.trow:last-child { border-radius: 0 0 22px 22px; }
.trow:hover { background: #FFFCFA; }
.no-input {
  width: 54px; height: 46px; border-radius: 14px;
  border: 1px solid var(--pink-100); background: var(--pink-50);
  color: var(--pink-ink); font-weight: 800; font-size: 1.15rem; text-align: center;
  font-family: var(--font);
}
.no-input:hover { border-color: var(--pink-200); }
.no-input:focus { outline: none; border-color: var(--pink); background: #fff; box-shadow: var(--ring); }
.no-input.is-dup { border-color: var(--red); background: var(--red-50); color: var(--red); }
.trow.is-off .no-input { background: var(--bg-2); border-color: var(--line-2); color: var(--muted); }
.t-name { font-weight: 700; color: var(--ink); text-decoration: none; line-height: 1.3; }
a.t-name:hover { color: var(--pink-ink); text-decoration: underline; }
.trow.is-off .t-name { color: var(--muted); }
.t-sub { display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: .84rem; color: var(--muted); }
.count-pill { display: inline-flex; padding: 3px 10px; border-radius: 999px; background: var(--bg-2); color: var(--ink-2); font-size: .82rem; font-weight: 600; }
.dup-msg { margin-top: 3px; font-size: .8rem; font-weight: 600; color: var(--red); }
.c-tog .form-check { display: flex; align-items: center; gap: 10px; padding-left: 0; margin: 0; }
.c-tog .form-check-input { margin: 0; float: none; }
.c-tog .form-check-label { font-size: .86rem; color: var(--ink-2); font-weight: 500; }
.trow.is-off .c-tog .form-check-label { color: var(--muted); }
@media (max-width: 743.98px) {
  .thead { display: none; }
  .trow {
    grid-template-columns: 54px minmax(0, 1fr) auto;
    grid-template-areas: "no main act" "no var tog";
    column-gap: 14px; row-gap: 8px; align-items: start; padding: 14px 16px;
  }
  .trow .c-no { grid-area: no; }
  .trow .c-main { grid-area: main; }
  .trow .c-var { grid-area: var; align-self: center; }
  .trow .c-tog { grid-area: tog; justify-self: end; align-self: center; }
  .trow .c-act { grid-area: act; justify-self: end; margin: -6px -8px 0 0; }
}

/* Form etalase */
.dropzone {
  display: flex; align-items: center; gap: 14px; margin: 0;
  padding: 14px 16px; border-radius: 18px;
  border: 1.5px dashed var(--pink-200); background: var(--pink-50);
  color: var(--muted); font-size: .87rem; cursor: pointer;
}
.dropzone:hover { background: var(--pink-100); }
.dropzone strong { display: block; color: var(--ink); font-weight: 700; }
.dz-ic { flex: none; width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: #fff; color: var(--pink); font-size: 1.25rem; box-shadow: var(--shadow-sm); }
.jenis-block { border: 1px solid var(--line); border-radius: 20px; padding: 16px; background: #FFFCFA; }
.jenis-block + .jenis-block { margin-top: 14px; }
.jb-head { display: flex; align-items: center; gap: 10px; }
.jb-title { font-size: 1rem; font-weight: 700; margin: 0; }
.jb-sum { font-size: .82rem; color: var(--muted); }
.jb-empty { margin: 14px 0 2px; font-size: .88rem; color: var(--muted); }
.jb-chips { margin-top: 4px; }
.ac-wrap { position: relative; }
.ac-wrap > .bi { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--pink); pointer-events: none; }
.ac-wrap > input { padding-left: 40px; }
.ac-menu {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 40;
  max-height: 320px; overflow: auto; padding: 6px;
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--shadow-md);
}
.ac-item {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  width: 100%; padding: .55rem .75rem; border: 0; border-radius: 10px;
  background: transparent; color: var(--ink); text-align: left; font-size: .93rem;
}
.ac-item:hover, .ac-item.is-on { background: var(--pink-50); }
.ac-item .grp { color: var(--muted); font-size: .8rem; }
.ac-item.is-new { color: var(--pink-ink); font-weight: 600; }
.ac-note { padding: .5rem .75rem .3rem; margin-top: 4px; border-top: 1px solid var(--line); font-size: .8rem; color: var(--muted); }
.quick { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 12px 0 2px; }
.quick button {
  border: 1px dashed var(--pink-200); border-radius: 999px; padding: 3px 12px;
  background: #fff; color: var(--pink-ink); font-size: .8rem; font-weight: 600;
}
.quick button:hover { background: var(--pink-50); border-style: solid; }
.echip {
  display: inline-flex; align-items: center; gap: 2px; padding-left: 13px;
  border: 1px solid var(--line-2); border-radius: 999px; background: #fff;
  font-size: .87rem; font-weight: 500;
}
.echip .rm { border: 0; background: transparent; color: var(--muted); padding: 6px 10px 6px 4px; line-height: 1; border-radius: 0 999px 999px 0; font-size: 1rem; }
.echip .rm:hover { color: var(--red); }
.echip.is-flash { animation: kilat 1.1s ease-out; }
@keyframes kilat { from { background: var(--pink-100); border-color: var(--pink); } to { background: #fff; } }
.save-bar {
  position: sticky; bottom: calc(var(--tabbar-h) + 10px + env(safe-area-inset-bottom)); z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin-top: 22px; padding: 12px 14px 12px 20px;
  background: rgba(255, 255, 255, .96); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--line); border-radius: 999px;
  box-shadow: var(--shadow-md);
}
@media (min-width: 992px) { .save-bar { bottom: 18px; } }
@media (max-width: 575.98px) { .save-bar { padding: 10px 10px 10px 18px; } }
.match-list { min-height: 220px; max-height: 300px; overflow: auto; padding: 8px 14px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--bg); }
.m-row { display: grid; grid-template-columns: minmax(0, .8fr) 16px minmax(0, 1.2fr); gap: 8px; align-items: center; padding: 7px 0; font-size: .88rem; }
.m-row + .m-row { border-top: 1px solid var(--line); }
.m-row .bi-arrow-right { color: var(--muted); }
.m-in { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.m-out { font-weight: 600; }
.m-out.ok { color: var(--green); }
.m-out.mirip { color: #9A5B12; }
.m-out.baru { color: var(--pink-ink); }
.m-out.ada { color: var(--muted); font-weight: 500; }

/* Halaman varian */
.tabs-pill { display: inline-flex; flex-wrap: nowrap; gap: 2px; padding: 4px; margin-bottom: 16px; background: var(--bg-2); border-radius: 999px; max-width: 100%; overflow-x: auto; }
.tabs-pill .nav-link { border-radius: 999px; padding: .45rem 1rem; color: var(--ink-2); font-weight: 600; font-size: .9rem; white-space: nowrap; }
.tabs-pill .nav-link:hover { color: var(--pink-ink); }
.tabs-pill .nav-link.active { background: #fff; color: var(--pink-ink); box-shadow: var(--shadow-sm); }
.tabs-pill .nav-link .n { margin-left: 6px; font-size: .76rem; color: var(--muted); font-weight: 600; }
.vr-head, .vr-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.3fr) 44px; gap: 16px; align-items: center; padding: 11px 20px; }
.vr-head { font-size: .78rem; font-weight: 700; color: var(--muted); background: var(--bg); border-bottom: 1px solid var(--line); }
.vr-group { display: flex; align-items: baseline; gap: 10px; padding: 16px 20px 6px; font-weight: 700; border-top: 1px solid var(--line); }
.vr-head + .vr-group { border-top: 0; }
.vr-row + .vr-row { border-top: 1px solid var(--line); }
.vr-row:hover { background: #FFFCFA; }
.v-name { font-weight: 600; }
.alias { display: inline-block; margin: 2px 4px 2px 0; padding: 2px 8px; border-radius: 7px; background: var(--bg-2); color: var(--ink-2); font-size: .8rem; font-weight: 500; }
.used { display: flex; flex-wrap: wrap; gap: 6px; }
.kw-preview { display: flex; flex-wrap: wrap; gap: 6px; min-height: 48px; padding: 12px; border-radius: 14px; background: var(--bg); }
.kw-preview span { padding: 3px 10px; border-radius: 999px; background: #fff; border: 1px solid var(--line-2); font-size: .82rem; }
@media (max-width: 743.98px) {
  .vr-head { display: none; }
  .vr-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name act" "alias act" "used act"; row-gap: 6px; padding: 12px 16px; }
  .vr-row .c-name { grid-area: name; }
  .vr-row .c-alias { grid-area: alias; }
  .vr-row .c-used { grid-area: used; }
  .vr-row .c-act { grid-area: act; align-self: start; }
  .vr-group { padding: 14px 16px 4px; }
}

/* Pengaturan */
.set-list .item-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.set-list .item-row + .item-row { border-top: 1px solid var(--line); }
.set-ic { flex: none; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--pink-50); color: var(--pink); }
.set-list .grip { color: #B9AAAF; cursor: grab; }
.alias-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: center; padding: 8px 0; }
.alias-row + .alias-row { border-top: 1px solid var(--line); }
.divider { border: 0; border-top: 1px solid var(--line); opacity: 1; margin: 24px 0; }

/* =========================================================
   LOGIN
   ========================================================= */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 992px) { .auth { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
body.page-auth { padding-bottom: 0; }
.auth-form { width: 100%; max-width: 420px; margin: 0 auto; padding: 40px 24px; display: flex; flex-direction: column; justify-content: center; }
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; color: var(--ink); text-decoration: none; }
.auth-brand b { font-weight: 800; font-size: 1.1rem; letter-spacing: -.015em; }
.auth-title { font-size: 2rem; font-weight: 800; line-height: 1.1; margin: 0 0 .4rem; letter-spacing: -.025em; }
.alert-soft { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; margin-bottom: 18px; border-radius: 14px; background: var(--red-50); color: var(--red); font-size: .9rem; font-weight: 500; }
.pw-wrap { position: relative; }
.pw-wrap .form-control { padding-right: 52px; }
.pw-toggle { position: absolute; right: 6px; top: 6px; width: 42px; height: 42px; border: 0; border-radius: 12px; display: grid; place-items: center; background: transparent; color: var(--muted); }
.pw-toggle:hover { background: var(--pink-50); color: var(--pink-ink); }
.auth-side { display: none; }
@media (min-width: 992px) {
  .auth-side {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    padding: 48px; margin: 16px; border-radius: 32px;
    background:
      radial-gradient(circle at 20% 15%, rgba(255, 255, 255, .7), transparent 45%),
      linear-gradient(160deg, #F6CADB 0%, #FBE6EE 55%, #FDF3EE 100%);
  }
}
.phone { width: 300px; padding: 12px; border-radius: 42px; background: #fff; box-shadow: var(--shadow-lg); }
.phone-screen { padding: 18px 14px 16px; border-radius: 32px; background: var(--bg); }
.phone-search { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 14px; border: 1px solid var(--pink); border-radius: 14px; background: #fff; font-weight: 500; box-shadow: var(--ring); }
.phone-search .bi { color: var(--pink); }
.caret { display: inline-block; width: 2px; height: 20px; background: var(--pink); margin-left: -7px; animation: kedip 1s steps(1) infinite; }
@keyframes kedip { 50% { opacity: 0; } }
.phone .answer { margin-top: 12px; padding: 14px; border-radius: 18px; animation: none; }
.phone .answer-name { font-size: 1.05rem; }
.phone .answer-line { font-size: .8rem; }
.phone .answer-nums { gap: 5px; margin-top: 10px; }
.phone .num-btn { width: 30px; height: 30px; border-radius: 9px; font-size: .85rem; }
.phone .item { margin-top: 10px; padding: 8px; gap: 10px; border-radius: 16px; }
.phone .no-tile { width: 44px; height: 44px; border-radius: 13px; font-size: 1.15rem; }
.phone .item-name { font-size: .85rem; }
.phone .hit { font-size: .7rem; padding: 2px 8px; }
.auth-cap { max-width: 340px; margin: 30px 0 0; text-align: center; font-size: 1.3rem; font-weight: 700; line-height: 1.3; letter-spacing: -.015em; color: var(--pink-ink); }

/* =========================================================
   HALAMAN DAFTAR DESAIN (index)
   ========================================================= */
.hub { max-width: 920px; margin: 0 auto; padding: 40px 16px 64px; }
.hub h1 { font-size: 2.3rem; font-weight: 800; line-height: 1.1; margin: 26px 0 10px; letter-spacing: -.03em; }
.hub h2 { font-size: 1.1rem; font-weight: 700; margin: 40px 0 12px; }
.hub-lead { color: var(--muted); max-width: 62ch; margin: 0; }
.hub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.hub-card { display: flex; gap: 14px; padding: 18px; border-radius: 20px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-sm); color: var(--ink); text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.hub-card:hover { border-color: var(--pink-200); box-shadow: var(--shadow-md); color: var(--ink); }
.hub-card .set-ic { width: 42px; height: 42px; border-radius: 13px; font-size: 1.1rem; }
.hub-card strong { display: block; font-weight: 700; }
.hub-card small { display: block; color: var(--muted); font-size: .86rem; line-height: 1.45; margin-top: 2px; }
.try { display: flex; flex-wrap: wrap; gap: 8px; }
.try a { display: inline-flex; flex-direction: column; padding: 10px 16px; border-radius: 16px; background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.try a:hover { border-color: var(--pink-200); background: var(--pink-50); }
.try b { font-weight: 700; }
.try small { color: var(--muted); font-size: .8rem; }
.swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.sw { padding: 10px; border-radius: 16px; background: #fff; border: 1px solid var(--line); font-size: .84rem; }
.sw i { display: block; height: 56px; border-radius: 11px; margin-bottom: 8px; border: 1px solid rgba(43, 35, 38, .06); }
.sw b { display: block; }
.sw span { color: var(--muted); }

/* ---------- Gerak dikurangi ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* =========================================================
   TAMBAHAN VERSI PHP
   ========================================================= */
/* Foto produk: foto + nomor di pojok kiri atas (seperti TikTok) */
.no-tile.has-photo { background: var(--bg-2); border-color: var(--line); }
.no-tile.has-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.no-badge {
  position: absolute; top: -6px; left: -6px;
  min-width: 26px; height: 26px; padding: 0 7px; border-radius: 9px;
  display: grid; place-items: center;
  background: var(--pink); color: #fff;
  font-size: .85rem; font-weight: 800; letter-spacing: -.01em;
  box-shadow: 0 3px 8px rgba(194, 65, 122, .35);
}
.no-tile-lg .no-badge { min-width: 30px; height: 30px; font-size: 1rem; border-radius: 10px; }
.dz-img { flex: none; width: 56px; height: 56px; border-radius: 14px; object-fit: cover; border: 1px solid var(--line); background: #fff; }
.dropzone > .min-w-0 > span { display: block; }

/* Login & setup */
.alert-ok { background: #E9F6EF; color: var(--green); }
.auth-single { grid-template-columns: minmax(0, 1fr) !important; }

/* Pengaturan */
.kat-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.kat-form .form-control { grid-column: 1 / -1; }
.spinner-border-sm { --bs-spinner-width: .9rem; --bs-spinner-height: .9rem; --bs-spinner-border-width: .15em; }

/* Tombol nonaktif tetap rapi (tanpa bingkai) */
.btn-ghost { --bs-btn-disabled-color: var(--muted); --bs-btn-disabled-bg: transparent; --bs-btn-disabled-border-color: transparent; --bs-btn-disabled-opacity: .35; }
.btn-soft { --bs-btn-disabled-color: var(--pink-ink); --bs-btn-disabled-bg: var(--pink-50); --bs-btn-disabled-border-color: var(--pink-100); }
.btn-line { --bs-btn-disabled-color: var(--muted); --bs-btn-disabled-bg: #fff; --bs-btn-disabled-border-color: var(--line-2); }
.btn-white { --bs-btn-disabled-color: var(--pink-ink); --bs-btn-disabled-bg: #fff; --bs-btn-disabled-border-color: var(--pink-100); }
.btn-danger-x { --bs-btn-disabled-color: #fff; --bs-btn-disabled-bg: var(--red); --bs-btn-disabled-border-color: var(--red); }


/* =========================================================
   iPAD & LAYAR SENTUH
   Lebar acuan: iPad mini 744, iPad 820, iPad Pro 1024 (tegak);
   1133–1194 (miring), iPad Pro 13" 1366 (miring).
   ========================================================= */
button, a, .item, .chip, .vchip, label { -webkit-tap-highlight-color: transparent; }
.sidebar { height: 100dvh; }
@supports not (height: 100dvh) { .sidebar { height: 100vh; } }

/* Kolom khusus tablet (mulai 744px) */
@media (min-width: 744px) {
  .col-tab-5 { flex: 0 0 auto; width: 41.6667%; }
  .col-tab-6 { flex: 0 0 auto; width: 50%; }
  .col-tab-7 { flex: 0 0 auto; width: 58.3333%; }
  .app-main { padding: 24px 24px 36px; }
}

/* Menu bawah dirapatkan ke tengah di layar lebar */
@media (min-width: 576px) {
  .tabbar { grid-template-columns: repeat(4, minmax(0, 132px)); justify-content: center; gap: 8px; }
}

/* Sidebar lebih ramping di iPad miring */
@media (min-width: 992px) and (max-width: 1279.98px) {
  :root { --sidebar-w: 224px; }
  .app-main { padding: 28px 28px 40px; }
  .side-brand small { display: none; }
}

/* ---------- Halaman live: daftar + panel varian berdampingan ---------- */
@media (min-width: 744px) {
  .live-wrap { grid-template-columns: minmax(0, 1fr) 320px; gap: 20px; }
  .detail-col { display: block; }
  .search-sticky { margin: 0; padding: 14px 0 10px; }
  .detail-col .detail {
    position: sticky; margin-top: 0;
    top: calc(var(--topbar-h) + 16px);
    max-height: calc(100vh - var(--topbar-h) - var(--tabbar-h) - 32px);
    max-height: calc(100dvh - var(--topbar-h) - var(--tabbar-h) - 32px);
    overflow: auto; overscroll-behavior: contain;
  }
  .item-cta { display: none !important; }
  .item-go { display: inline-block !important; }
  .item { padding: 12px 14px 12px 12px; gap: 14px; }
  .answer-nums { gap: 8px; }
  .num-btn { width: 48px; height: 48px; border-radius: 15px; font-size: 1.25rem; }
  .dt-head { padding: 20px 20px 16px; }
  .dt-body { padding: 0 20px 20px; }
}
@media (min-width: 992px) {
  .live-wrap { grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; }
  .detail-col .detail { top: 24px; max-height: calc(100vh - 48px); max-height: calc(100dvh - 48px); }
}
@media (min-width: 1280px) {
  .live-wrap { grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; }
  .item-cta { display: inline-flex !important; }
  .item-go { display: none !important; }
  .num-btn { width: 52px; height: 52px; border-radius: 16px; font-size: 1.35rem; }
}

/* ---------- Login: ilustrasi juga tampil di iPad tegak ---------- */
@media (min-width: 744px) {
  .auth { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .auth-side { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; margin: 16px; border-radius: 32px;
    background: radial-gradient(circle at 20% 15%, rgba(255, 255, 255, .7), transparent 45%), linear-gradient(160deg, #F6CADB 0%, #FBE6EE 55%, #FDF3EE 100%); }
  .auth-form { padding: 40px 32px; }
}
@media (min-width: 744px) and (max-width: 991.98px) {
  .phone { width: 280px; }
  .auth-cap { font-size: 1.1rem; max-width: 280px; }
}

/* ---------- Layar sentuh: target sentuh lebih besar ---------- */
@media (pointer: coarse) {
  /* 16px mencegah Safari iPad/iPhone memperbesar layar saat mengetik */
  .form-control, .form-select, .form-control-sm, .form-control-lg, .search input { font-size: 16px; }
  .toolbar .form-select { font-size: 16px; padding-left: .8rem; padding-right: 2rem; }
  .chip { min-height: 40px; padding: 8px 16px; }
  .recent button { padding: 6px 12px; }
  .vchip { min-height: 40px; padding: 8px 15px; font-size: .92rem; }
  .btn-icon { width: 44px; height: 44px; }
  .btn-sm { --bs-btn-padding-y: .55rem; --bs-btn-padding-x: 1rem; }
  .search-clear { width: 44px; height: 44px; }
  .echip { min-height: 40px; padding-left: 14px; font-size: .9rem; }
  .echip .rm { padding: 10px 13px 10px 6px; }
  .quick button { padding: 7px 14px; font-size: .84rem; }
  .ac-item { padding: .8rem .85rem; font-size: 1rem; }
  .dropdown-item { padding: .75rem .9rem; }
  .no-input { width: 58px; height: 50px; }
  .form-switch .form-check-input { width: 2.9em; height: 1.6em; margin-top: 0; }
  .c-tog .form-check { min-height: 44px; }
  .form-check-input[type=checkbox]:not([role=switch]) { width: 1.3em; height: 1.3em; }
  .item { min-height: 88px; }
}

/* ---------- Layar sentuh: tanpa efek hover yang "nyangkut" ---------- */
@media (hover: none) {
  .kbd-hint, .kbd-tip, .keys { display: none !important; }
  .item:hover { border-color: var(--line); box-shadow: var(--shadow-sm); }
  .item:hover .item-cta { background: var(--pink-50); color: var(--pink-ink); }
  .item[aria-current="true"], .item[aria-current="true"]:hover { border-color: var(--pink); box-shadow: var(--ring); }
  .item:active { transform: scale(.985); }
  .item { transition: border-color .15s, box-shadow .15s, transform .1s; }
  .num-btn:hover { background: #fff; color: var(--pink-ink); border-color: var(--pink-200); transform: none; }
  .num-btn:active { background: var(--pink); color: #fff; border-color: var(--pink); }
  .chip:hover { border-color: var(--line-2); color: var(--ink-2); }
  .chip[aria-pressed="true"]:hover { border-color: var(--pink); color: #fff; }
  .trow:hover, .vr-row:hover { background: transparent; }
}

/* Penyesuaian akhir iPad */
.side-foot b, .side-foot small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (min-width: 744px) {
  .chips { flex-wrap: wrap; overflow: visible; }
}
@media (min-width: 744px) and (max-width: 991.98px) {
  .salin-long { display: none !important; }
  .answer { padding: 16px 18px 18px; }
  .answer-name { font-size: 1.25rem; }
  .num-btn { width: 44px; height: 44px; border-radius: 14px; font-size: 1.15rem; }
}
.jb-head .btn-icon { margin-right: -6px; }
@media (min-width: 744px) and (max-width: 991.98px) {
  .phone .num-btn { width: 28px; height: 28px; border-radius: 9px; font-size: .8rem; }
}

/* Pemeriksaan server di halaman setup */
.checks { padding: 14px 16px; border-radius: 16px; background: #fff; border: 1px solid var(--line); }
.checks-title { font-size: .82rem; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.check { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; font-size: .88rem; }
.check b { font-weight: 600; }
.check small { display: block; color: var(--muted); font-size: .8rem; }
.check.is-ok .bi { color: var(--green); }
.check.is-warn .bi { color: #B7791F; }
.check.is-bad .bi { color: var(--red); }
