/* ==========================================================================
   Neuro Healing — gaya aplikasi
   ========================================================================== */

@font-face { font-family: 'Montserrat'; font-weight: 400; font-display: swap; src: url('../fonts/Montserrat-Regular.ttf') format('truetype'); }
@font-face { font-family: 'Montserrat'; font-weight: 500; font-display: swap; src: url('../fonts/Montserrat-Medium.ttf') format('truetype'); }
@font-face { font-family: 'Montserrat'; font-weight: 600; font-display: swap; src: url('../fonts/Montserrat-SemiBold.ttf') format('truetype'); }
@font-face { font-family: 'Montserrat'; font-weight: 700; font-display: swap; src: url('../fonts/Montserrat-Bold.ttf') format('truetype'); }
@font-face { font-family: 'Montserrat'; font-weight: 800; font-display: swap; src: url('../fonts/Montserrat-ExtraBold.ttf') format('truetype'); }

:root {
  --primary: #004368;
  --primary-2: #0a758d;
  --primary-50: #E6F0F5;
  --primary-100: #CCE1EB;
  --grad: linear-gradient(135deg, #004368 0%, #0a758d 100%);
  --bg: #F2F5F8;
  --card: #FFFFFF;
  --text: #0F1B2D;
  --text-2: #374151;
  --muted: #6B7280;
  --muted-2: #9CA3AF;
  --border: #E6EBF1;
  --border-2: #D7DEE7;
  --success: #10B981;
  --danger: #EF4444;
  --warning: #F59E0B;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(15, 27, 45, .04), 0 6px 18px rgba(15, 27, 45, .06);
  --shadow-lg: 0 18px 50px rgba(15, 27, 45, .18);
  --nav-h: 66px;
  --sidebar-w: 252px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4, p { margin: 0; }
.ic { flex-shrink: 0; display: inline-block; vertical-align: middle; }

/* Bahasa: hanya tampilkan teks sesuai pilihan */
html[data-lang="id"] [data-l="en"],
html[data-lang="en"] [data-l="id"] { display: none !important; }

/* ── Kerangka ──────────────────────────────────────────────────────────── */
.page { min-height: 100vh; animation: pageIn .25s ease-out both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.has-nav .page { padding-bottom: calc(var(--nav-h) + var(--safe-b) + 12px); }

.wrap { width: 100%; max-width: 760px; margin: 0 auto; padding: 16px; }
.wrap.wide { max-width: 1080px; }
.wrap.narrow { max-width: 520px; }
.stack > * + * { margin-top: 12px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; } .mt-20 { margin-top: 20px; } .mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; } .mb-12 { margin-bottom: 12px; } .mb-16 { margin-bottom: 16px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.hidden { display: none !important; }
.row { display: flex; align-items: center; gap: 10px; }
.row.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.clamp-1 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pre { white-space: pre-wrap; }

/* ── Header ────────────────────────────────────────────────────────────── */
.appbar {
  position: relative;
  background: var(--grad);
  color: #fff;
  padding: calc(16px + var(--safe-t)) 18px 26px;
  border-radius: 0 0 24px 24px;
  overflow: hidden;
}
.appbar::before, .appbar::after {
  content: ''; position: absolute; border-radius: 50%; pointer-events: none;
  background: rgba(255, 255, 255, .07);
}
.appbar::before { width: 220px; height: 220px; right: -70px; top: -110px; }
.appbar::after { width: 140px; height: 140px; right: 70px; bottom: -90px; background: rgba(255, 255, 255, .05); }
.appbar-in { position: relative; z-index: 1; display: flex; align-items: center; gap: 12px; max-width: 1080px; margin: 0 auto; }
.appbar-tt { flex: 1; min-width: 0; }
.appbar h1 { font-size: 20px; font-weight: 800; letter-spacing: -.2px; line-height: 1.25; }
.appbar p { font-size: 12px; opacity: .82; margin-top: 3px; line-height: 1.45; }
.back-btn {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, .16); color: #fff;
  transition: background .15s;
}
.back-btn:active { background: rgba(255, 255, 255, .28); }
.appbar .pill-stat { background: rgba(255, 255, 255, .18); border-radius: 12px; padding: 6px 14px; text-align: center; line-height: 1.2; }
.appbar .pill-stat b { display: block; font-size: 20px; }
.appbar .pill-stat small { font-size: 10px; opacity: .8; }

/* ── Kartu & daftar ────────────────────────────────────────────────────── */
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 16px; }
.card.pad-lg { padding: 20px; }
.card + .card { margin-top: 12px; }
.section-title { display: flex; align-items: center; justify-content: space-between; margin: 22px 0 10px; }
.section-title h2 { font-size: 15px; font-weight: 700; }
.section-title a { font-size: 12px; font-weight: 600; color: var(--primary-2); }
.label-up { font-size: 11px; font-weight: 600; color: var(--muted-2); text-transform: uppercase; letter-spacing: .5px; }

.list { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.list-item {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px; width: 100%; text-align: left;
  background: none; border: 0;
  transition: background .15s;
}
.list-item + .list-item { border-top: 1px solid #F1F4F7; }
a.list-item:active, button.list-item:active { background: #F6F8FA; }
@media (hover: hover) { a.list-item:hover, button.list-item:hover { background: #F8FAFC; } }
.list-item .tt { font-weight: 700; font-size: 14px; }
.list-item .st { font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.list-item .chev { color: var(--primary-2); }
.list-item.disabled { opacity: .55; }

.icon-box {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  display: grid; place-items: center;
  background: var(--primary-50); color: var(--primary);
}
.icon-box.sm { width: 38px; height: 38px; border-radius: 10px; }
.icon-box.lg { width: 56px; height: 56px; border-radius: 16px; }
.icon-box.danger { background: #FEE2E2; color: var(--danger); }
.icon-box.warn { background: #FEF3C7; color: #D97706; }
.icon-box.gray { background: #F3F4F6; color: var(--muted-2); }

.info-row { padding: 12px 16px; }
.info-row + .info-row { border-top: 1px solid #F1F4F7; }
.info-row .k { font-size: 10.5px; font-weight: 600; color: var(--muted-2); text-transform: uppercase; letter-spacing: .5px; }
.info-row .v { font-size: 13px; font-weight: 600; margin-top: 2px; word-break: break-word; }

.badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 10.5px; font-weight: 700; line-height: 1;
  padding: 5px 9px; border-radius: 999px;
  background: var(--primary-50); color: var(--primary);
}
.badge.solid { background: var(--primary); color: #fff; }
.badge.gray { background: #F3F4F6; color: #4B5563; }
.badge.red { background: #FEE2E2; color: #DC2626; }
.badge.glass { background: rgba(255, 255, 255, .92); color: var(--primary); }

.divider { height: 1px; background: #F1F4F7; margin: 12px 0; border: 0; }

/* ── Tombol ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 50px; padding: 0 20px; width: 100%;
  border: 0; border-radius: 12px;
  background: var(--grad); color: #fff;
  font-weight: 700; font-size: 14px; letter-spacing: .2px;
  box-shadow: 0 6px 16px rgba(0, 67, 104, .22);
  transition: transform .12s, box-shadow .2s, opacity .2s;
}
.btn:active { transform: scale(.98); }
.btn[disabled], .btn.loading { opacity: .65; pointer-events: none; box-shadow: none; }
.btn.loading::after {
  content: ''; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .5); border-top-color: #fff;
  animation: spin .7s linear infinite;
}
.btn.light { background: #F3F4F6; color: var(--text-2); box-shadow: none; }
.btn.outline { background: #fff; color: var(--primary); border: 1.5px solid var(--primary-100); box-shadow: none; }
.btn.danger { background: linear-gradient(135deg, #EF4444, #DC2626); box-shadow: 0 6px 16px rgba(239, 68, 68, .25); }
.btn.gray { background: #6B7280; box-shadow: none; }
.btn.sm { height: 38px; font-size: 12px; padding: 0 14px; width: auto; border-radius: 10px; }
.btn-row { display: flex; gap: 10px; }
.btn-row > * { flex: 1; }
.link-btn { background: none; border: 0; padding: 0; color: var(--primary-2); font-weight: 700; font-size: 12px; display: inline-flex; align-items: center; gap: 4px; }
.chip-btn { border: 0; border-radius: 8px; padding: 6px 10px; font-size: 11.5px; font-weight: 600; background: #F3F4F6; color: var(--text-2); display: inline-flex; align-items: center; gap: 5px; }
.chip-btn.red { background: #FEE2E2; color: #DC2626; }

/* ── Form ──────────────────────────────────────────────────────────────── */
.field { margin-bottom: 14px; }
.field > label, .field .lbl { display: block; font-size: 12px; font-weight: 600; color: var(--primary); margin-bottom: 6px; }
.field .lbl .req { color: var(--danger); }
.input-wrap { position: relative; }
.input-wrap > .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--primary-2); pointer-events: none; }
.input, .select, .textarea {
  width: 100%; height: 50px; padding: 0 14px;
  border: 1.5px solid var(--border-2); border-radius: 12px;
  background: #fff; font-size: 14px; font-weight: 500; color: var(--text);
  outline: none; transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
.input-wrap > .ic + .input { padding-left: 46px; }
.input::placeholder, .textarea::placeholder { color: #A7B1BE; font-weight: 400; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--primary-2); box-shadow: 0 0 0 4px rgba(10, 117, 141, .12); }
.textarea { height: auto; min-height: 90px; padding: 12px 14px; resize: vertical; line-height: 1.5; }
.select {
  padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%230a758d' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.input.sm, .select.sm { height: 44px; font-size: 13px; }
.pass-toggle {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  width: 42px; height: 42px; border: 0; background: none; color: var(--primary-2);
  display: grid; place-items: center;
}
.pass-toggle .ic-off { display: none; }
.pass-toggle.on .ic-on { display: none; }
.pass-toggle.on .ic-off { display: inline-block; }
.input.has-toggle { padding-right: 48px; }

.check-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--border);
  background: #F9FAFB; cursor: pointer; user-select: none;
}
.check-row input { width: 20px; height: 20px; accent-color: var(--primary); margin: 0; }
.check-row span { font-weight: 600; font-size: 13px; color: var(--text-2); }

.seg { display: flex; gap: 8px; }
.seg > label, .seg > button {
  flex: 1; min-height: 44px; display: flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--border); border-radius: 12px; background: #F9FAFB;
  font-weight: 600; font-size: 13px; color: var(--muted); cursor: pointer; text-align: center; padding: 8px;
}
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg > label.on, .seg > button.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.seg.soft > label.on, .seg.soft > button.on { background: var(--primary-50); border-color: var(--primary-2); color: var(--primary); }

.upload-box {
  width: 100%; height: 170px; border-radius: 14px;
  border: 1.5px dashed rgba(10, 117, 141, .5); background: var(--primary-50);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  color: var(--primary); cursor: pointer; overflow: hidden; position: relative;
}
.upload-box img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.upload-box .change { position: absolute; right: 8px; bottom: 8px; background: rgba(0, 0, 0, .55); color: #fff; border-radius: 999px; padding: 5px 10px; font-size: 11px; font-weight: 600; display: flex; gap: 4px; align-items: center; }
.upload-box .circle { width: 56px; height: 56px; border-radius: 50%; background: rgba(10, 117, 141, .14); display: grid; place-items: center; }
.upload-box b { font-size: 13px; }
.upload-box small { font-size: 11px; color: var(--muted-2); }

/* ── Navigasi bawah (ponsel) ───────────────────────────────────────────── */
.bnav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 900;
  height: calc(var(--nav-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(4, 1fr);
  background: rgba(255, 255, 255, .96);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-top: 1px solid #EEF1F4;
  box-shadow: 0 -4px 20px rgba(15, 27, 45, .06);
}
.bnav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: #8A97A6; }
.bnav-ic { width: 52px; height: 30px; border-radius: 999px; display: grid; place-items: center; transition: background .2s, color .2s; }
.bnav-lb { font-size: 10px; font-weight: 600; }
.bnav a.active { color: var(--primary); }
.bnav a.active .bnav-ic { background: var(--primary-50); }
.bnav a.active .bnav-lb { font-weight: 700; }

/* ── Sidebar (laptop) ──────────────────────────────────────────────────── */
.sidebar { display: none; }
@media (min-width: 1024px) {
  .bnav { display: none; }
  .has-nav .page { padding-bottom: 32px; margin-left: var(--sidebar-w); }
  .sidebar {
    display: flex; flex-direction: column;
    position: fixed; top: 0; left: 0; bottom: 0; width: var(--sidebar-w); z-index: 900;
    background: #fff; border-right: 1px solid #ECEFF3; padding: 20px 14px; overflow-y: auto;
  }
  .sb-brand { display: flex; align-items: center; gap: 10px; padding: 0 6px 20px; }
  .sb-brand img { border-radius: 12px; }
  .sb-brand b { display: block; font-size: 14px; font-weight: 800; color: var(--primary); }
  .sb-brand small { display: block; font-size: 10.5px; color: var(--muted-2); }
  .sb-user { display: flex; align-items: center; gap: 10px; background: var(--primary-50); border-radius: 14px; padding: 12px; margin-bottom: 18px; }
  .sb-user small { display: block; font-size: 10px; color: var(--muted); }
  .sb-user b { display: block; font-size: 13px; line-height: 1.3; }
  .sb-menu a { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px; margin-bottom: 4px; color: #374151; font-weight: 600; font-size: 13px; transition: background .15s; }
  .sb-menu a .ic { color: var(--primary-2); }
  .sb-menu a:hover { background: #F4F7FA; }
  .sb-menu a.active { background: var(--grad); color: #fff; font-weight: 700; box-shadow: 0 6px 14px rgba(0, 67, 104, .2); }
  .sb-menu a.active .ic { color: #fff; }
  .sb-sep { font-size: 9.5px; font-weight: 700; color: var(--muted-2); letter-spacing: 1px; padding: 16px 14px 8px; border-top: 1px solid #F1F3F6; margin-top: 10px; }
  .sb-foot { margin-top: auto; padding: 16px 14px 0; font-size: 11px; color: var(--muted-2); }
}

/* ── Avatar ────────────────────────────────────────────────────────────── */
.avatar { width: 84px; height: 84px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 30px; flex-shrink: 0; }
.avatar.sm { width: 38px; height: 38px; font-size: 14px; }

/* ── Scroll horizontal (kartu klinik/dokter) ───────────────────────────── */
.hscroll { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 2px 16px 6px; margin: 0 -16px; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }
.hscroll > * { scroll-snap-align: start; flex-shrink: 0; }

.photo-card { position: relative; border-radius: 16px; overflow: hidden; background: #DDE5EC; box-shadow: var(--shadow); }
.photo-card > img { width: 100%; height: 100%; object-fit: cover; }
.photo-card .shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0, 30, 50, .85), rgba(0, 30, 50, .1) 55%, transparent); }
.photo-card .shade.brand { background: linear-gradient(to top, var(--primary), rgba(0, 67, 104, .15) 60%, transparent); }
.photo-card .cap { position: absolute; left: 10px; right: 10px; bottom: 10px; color: #fff; }
.photo-card .cap b { display: block; font-size: 12px; font-weight: 700; line-height: 1.3; }
.photo-card .cap small { display: block; font-size: 10px; opacity: .82; margin-top: 2px; }
.photo-card .tag { position: absolute; top: 10px; left: 10px; }
.photo-card .tag-r { position: absolute; top: 10px; right: 10px; }
.photo-card.clinic { width: 180px; height: 150px; }
.photo-card.person { width: 128px; height: 176px; }
.photo-card.person .cap .badge { margin-top: 5px; background: rgba(255, 255, 255, .2); color: #fff; border: 1px solid rgba(255, 255, 255, .35); font-size: 9px; }

/* ── Spinner, skeleton, kosong ─────────────────────────────────────────── */
@keyframes spin { to { transform: rotate(360deg); } }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--primary-100); border-top-color: var(--primary); animation: spin .8s linear infinite; }
.loading-box { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 48px 16px; color: var(--muted-2); font-size: 13px; }
.empty { text-align: center; padding: 48px 24px; }
.empty-ic { width: 76px; height: 76px; border-radius: 50%; background: #E9EEF3; color: #A9B6C4; display: grid; place-items: center; margin: 0 auto 14px; }
.empty h3 { font-size: 15px; font-weight: 700; color: #475569; }
.empty p { font-size: 12.5px; color: var(--muted-2); margin-top: 6px; line-height: 1.6; }

/* ── Toast ─────────────────────────────────────────────────────────────── */
.toast-wrap { position: fixed; left: 0; right: 0; bottom: calc(var(--nav-h) + var(--safe-b) + 12px); z-index: 99990; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 0 16px; pointer-events: none; }
body:not(.has-nav) .toast-wrap { bottom: calc(20px + var(--safe-b)); }
@media (min-width: 1024px) { .toast-wrap { bottom: 24px; align-items: flex-end; } }
.toast {
  pointer-events: auto; max-width: 420px; width: auto;
  display: flex; align-items: flex-start; gap: 10px;
  background: #0F1B2D; color: #fff; border-radius: 14px; padding: 12px 16px;
  font-size: 13px; font-weight: 500; line-height: 1.45; box-shadow: var(--shadow-lg);
  animation: toastIn .25s ease-out both;
}
.toast.out { animation: toastOut .2s ease-in both; }
.toast .ti { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; font-size: 12px; font-weight: 800; margin-top: 1px; }
.toast.success .ti { background: var(--success); }
.toast.error .ti { background: var(--danger); }
.toast.info .ti { background: var(--primary-2); }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(8px); } }

/* ── Loading bar saat pindah halaman ───────────────────────────────────── */
.loadbar { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 99999; background: linear-gradient(90deg, #5EC8E0, #fff); box-shadow: 0 0 8px rgba(94, 200, 224, .8); opacity: 0; transition: width .3s ease, opacity .3s; }
.loadbar.go { opacity: 1; width: 80%; transition: width 8s cubic-bezier(.1, .8, .2, 1), opacity .2s; }

/* ── Modal & bottom sheet ──────────────────────────────────────────────── */
.modal { position: fixed; inset: 0; z-index: 9000; display: none; }
.modal.open { display: flex; flex-direction: column; justify-content: flex-end; }
.modal-bg { position: absolute; inset: 0; background: rgba(15, 23, 42, .55); animation: fadeIn .2s both; }
.modal-panel {
  position: relative; background: #fff; width: 100%;
  border-radius: 24px 24px 0 0; max-height: 88vh; display: flex; flex-direction: column;
  padding-bottom: var(--safe-b); animation: sheetUp .28s cubic-bezier(.2, .9, .3, 1) both;
}
.modal-grab { width: 40px; height: 4px; border-radius: 2px; background: #E5E7EB; margin: 10px auto 0; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid #F1F4F7; }
.modal-head h3 { font-size: 16px; font-weight: 700; }
.modal-x { width: 34px; height: 34px; border-radius: 50%; border: 0; background: #F3F4F6; display: grid; place-items: center; color: var(--muted); }
.modal-body { padding: 16px 18px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.modal-foot { padding: 12px 18px 18px; border-top: 1px solid #F1F4F7; }
@media (min-width: 640px) {
  .modal.open { justify-content: center; align-items: center; padding: 24px; }
  .modal-panel { max-width: 520px; border-radius: 22px; max-height: 86vh; animation: popIn .22s ease-out both; }
  .modal-grab { display: none; }
}
@keyframes fadeIn { from { opacity: 0; } }
@keyframes sheetUp { from { transform: translateY(100%); } }
@keyframes popIn { from { opacity: 0; transform: translateY(14px) scale(.97); } }

.dialog-ic { width: 60px; height: 60px; border-radius: 50%; margin: 6px auto 12px; display: grid; place-items: center; background: var(--primary-50); color: var(--primary); }
.dialog-ic.danger { background: #FEE2E2; color: var(--danger); }
.dialog-msg { text-align: center; font-size: 14px; color: var(--text-2); line-height: 1.6; }

body.no-scroll { overflow: hidden; }

/* ── Pemilih bahasa ────────────────────────────────────────────────────── */
.lang-toggle { display: inline-flex; background: rgba(255, 255, 255, .16); border-radius: 999px; padding: 3px; flex-shrink: 0; }
.lang-toggle button { border: 0; background: none; color: #fff; font-size: 11.5px; font-weight: 700; padding: 6px 12px; border-radius: 999px; }
html[data-lang="id"] .lang-toggle [data-set-lang="id"],
html[data-lang="en"] .lang-toggle [data-set-lang="en"] { background: #fff; color: var(--primary); }

/* ── Halaman login/register ────────────────────────────────────────────── */
.auth { min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); }
.auth-hero { background: var(--grad); color: #fff; text-align: center; padding: calc(44px + var(--safe-t)) 24px 72px; position: relative; overflow: hidden; }
.auth-hero::before { content: ''; position: absolute; width: 320px; height: 320px; border-radius: 50%; background: rgba(255, 255, 255, .07); top: -160px; right: -90px; }
.auth-hero::after { content: ''; position: absolute; width: 200px; height: 200px; border-radius: 50%; background: rgba(255, 255, 255, .05); bottom: -110px; left: -60px; }
.auth-logo { width: 96px; height: 96px; border-radius: 26px; margin: 0 auto 14px; background: #fff; padding: 8px; box-shadow: 0 12px 30px rgba(0, 0, 0, .2); position: relative; z-index: 1; }
.auth-logo img { width: 100%; height: 100%; object-fit: contain; border-radius: 18px; }
.auth-hero h1 { font-size: 24px; font-weight: 800; position: relative; z-index: 1; }
.auth-hero p { font-size: 13px; opacity: .85; margin-top: 4px; position: relative; z-index: 1; }
.auth-card { width: calc(100% - 32px); max-width: 460px; margin: -44px auto 24px; padding: 24px 20px; position: relative; z-index: 2; }
.auth-card h2 { font-size: 18px; font-weight: 800; color: var(--primary); margin-bottom: 4px; }
.auth-card .sub { font-size: 12.5px; color: var(--muted); margin-bottom: 18px; }
.auth-alt { text-align: center; font-size: 13px; color: var(--muted); margin-top: 18px; }
.auth-alt a { color: var(--primary); font-weight: 700; }

/* ── Beranda ───────────────────────────────────────────────────────────── */
.home-head { background: var(--grad); color: #fff; padding: calc(16px + var(--safe-t)) 18px 64px; border-radius: 0 0 28px 28px; position: relative; overflow: hidden; }
.home-head::before { content: ''; position: absolute; width: 260px; height: 260px; border-radius: 50%; background: rgba(255, 255, 255, .07); top: -130px; right: -60px; }
.home-head .in { max-width: 1080px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; position: relative; z-index: 1; }
.home-head small { font-size: 12.5px; opacity: .85; }
.home-head h1 { font-size: 19px; font-weight: 800; margin-top: 2px; line-height: 1.25; }
.home-head img { width: 50px; height: 50px; border-radius: 50%; background: #fff; border: 2px solid rgba(255, 255, 255, .6); object-fit: cover; }
.home-body { margin-top: -48px; position: relative; z-index: 2; padding-top: 0; }

.slider { position: relative; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); background: #DDE5EC; }
.slider-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; scroll-behavior: smooth; }
.slider-track::-webkit-scrollbar { display: none; }
.slide { position: relative; flex: 0 0 100%; height: 180px; scroll-snap-align: start; }
.slide img { width: 100%; height: 100%; object-fit: cover; }
.slide .shade { position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 30%, rgba(0, 45, 70, .92)); }
.slide .cap { position: absolute; left: 14px; right: 14px; bottom: 26px; color: #fff; }
.slide .cap .badge { margin-bottom: 6px; }
.slide .cap b { display: block; font-size: 14px; font-weight: 700; line-height: 1.35; }
.dots { position: absolute; left: 0; right: 0; bottom: 10px; display: flex; justify-content: center; gap: 5px; }
.dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(255, 255, 255, .5); transition: width .3s, background .3s; }
.dots i.on { width: 18px; background: #fff; }
@media (min-width: 1024px) { .slide { height: 280px; } }

.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 16px 10px; }
.quick a { display: flex; flex-direction: column; align-items: center; gap: 7px; text-align: center; font-size: 10.5px; font-weight: 600; color: var(--text-2); line-height: 1.3; }
.quick .qi { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; color: #fff; box-shadow: 0 8px 16px -6px var(--qc, rgba(0, 0, 0, .3)); transition: transform .15s; }
.quick a:active .qi { transform: scale(.94); }

.services { display: grid; grid-template-columns: repeat(4, 1fr); padding: 6px 4px; }
.services a { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 2px; text-align: center; font-size: 10px; font-weight: 600; color: var(--text-2); line-height: 1.3; border-radius: 12px; }
.services a:active { background: #F6F8FA; }
.services .si { width: 50px; height: 50px; border-radius: 15px; background: var(--primary-50); color: var(--primary); display: grid; place-items: center; }
@media (min-width: 1024px) { .services { grid-template-columns: repeat(8, 1fr); } }

.art-item { display: flex; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); min-height: 110px; }
.art-item + .art-item { margin-top: 10px; }
.art-item > img { width: 112px; object-fit: cover; flex-shrink: 0; background: #DDE5EC; }
.art-item .bd { flex: 1; min-width: 0; padding: 11px 12px; display: flex; flex-direction: column; gap: 4px; }
.art-item .meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 10px; color: var(--muted-2); }
.art-item h3 { font-size: 12.5px; font-weight: 700; line-height: 1.4; flex: 1; }
.art-item .more { font-size: 10.5px; font-weight: 700; color: var(--primary-2); display: flex; align-items: center; gap: 4px; }
@media (min-width: 900px) {
  .art-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .art-grid .art-item + .art-item { margin-top: 0; }
}

/* ── Klinik / orang / artikel detail ───────────────────────────────────── */
.hero-img { position: relative; height: 290px; background: #C9D5DF; overflow: hidden; }
.hero-img > img { width: 100%; height: 100%; object-fit: cover; }
.hero-img .shade { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0, 0, 0, .4), transparent 35%, transparent 50%, var(--primary)); }
.hero-img .back-btn { position: absolute; top: calc(14px + var(--safe-t)); left: 16px; background: rgba(0, 0, 0, .35); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.hero-img .cap { position: absolute; left: 16px; right: 16px; bottom: 18px; color: #fff; }
.hero-img .cap h1 { font-size: 22px; font-weight: 800; line-height: 1.25; }
.hero-img .cap p { font-size: 12px; opacity: .88; display: flex; gap: 5px; align-items: flex-start; margin-top: 5px; }
.hero-img .status { position: absolute; top: calc(16px + var(--safe-t)); right: 16px; }
@media (min-width: 1024px) { .hero-img { height: 360px; border-radius: 0 0 24px 24px; } }

.person-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.person-grid .photo-card { height: 230px; }
.person-grid .cap b { font-size: 13px; }
@media (min-width: 640px) { .person-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .person-grid { grid-template-columns: repeat(4, 1fr); } }

.clinic-card { display: block; height: 196px; }
.clinic-card + .clinic-card { margin-top: 12px; }
.clinic-card .cap b { font-size: 15px; font-weight: 800; }
.clinic-card .cap small { font-size: 11.5px; display: flex; gap: 4px; align-items: center; }
.clinic-card .go { position: absolute; right: 12px; bottom: 12px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .35); color: #fff; }
.clinic-card .cap { right: 52px; }

.stats { display: flex; }
.stats > div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px 8px; text-align: center; }
.stats > div + div { border-left: 1px solid #F1F4F7; }
.stats small { font-size: 10px; color: var(--muted-2); }
.stats b { font-size: 11.5px; font-weight: 700; }
.chips { display: flex; flex-wrap: wrap; gap: 4px; justify-content: center; }
.chips span { font-size: 10px; font-weight: 600; color: var(--primary); background: var(--primary-50); border: 1px solid var(--primary-100); border-radius: 6px; padding: 3px 7px; }

.rich { font-size: 14px; color: var(--text-2); line-height: 1.8; word-break: break-word; }
.rich img { height: auto; border-radius: 10px; margin: 10px 0; }
.rich p { margin: 0 0 12px; }
.rich ul, .rich ol { padding-left: 20px; }
.rich a { color: var(--primary-2); text-decoration: underline; }
.rich table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.rich td, .rich th { border: 1px solid var(--border); padding: 6px; }

/* ── Halaman iframe (detail screening, QEEG, games) ────────────────────── */
.frame-page { display: flex; flex-direction: column; height: 100vh; height: 100dvh; }
.frame-page .appbar { border-radius: 0; padding-bottom: 18px; flex-shrink: 0; }
.has-nav.frame-body .frame-page { height: calc(100dvh - var(--nav-h) - var(--safe-b)); }
.has-nav.frame-body .page { padding-bottom: 0; }
@media (min-width: 1024px) { .has-nav.frame-body .frame-page { height: 100dvh; } }
.frame-box { flex: 1; position: relative; background: #fff; }
.frame-box iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.frame-box .loading-box { position: absolute; inset: 0; justify-content: center; background: rgba(255, 255, 255, .92); z-index: 2; }

/* ── Timeline ──────────────────────────────────────────────────────────── */
.timeline { position: relative; padding-left: 28px; }
.timeline::before { content: ''; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: #DDE3EA; border-radius: 2px; }
.tl-item { position: relative; }
.tl-item + .tl-item { margin-top: 12px; }
.tl-dot { position: absolute; left: -26px; top: 16px; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--c, var(--primary)); }
.tl-card { background: #fff; border-radius: 14px; padding: 14px; box-shadow: var(--shadow); border-left: 3px solid var(--c, var(--primary)); }
.tl-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 11px; color: var(--muted-2); margin-bottom: 6px; }
.tl-card h3 { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.tl-card .line { font-size: 12px; color: var(--text-2); margin-top: 2px; }
.tl-sub { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; margin-top: 8px; }
.tl-actions { display: flex; gap: 8px; border-top: 1px solid #F1F4F7; margin-top: 10px; padding-top: 10px; }

/* ── Riwayat screening ─────────────────────────────────────────────────── */
.scr-card { display: flex; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow); }
.scr-card + .scr-card { margin-top: 12px; }
.scr-card .bar { width: 5px; background: var(--grad); flex-shrink: 0; }
.scr-card .bd { flex: 1; min-width: 0; padding: 14px; }
.scr-card .score { border-radius: 12px; background: var(--primary-50); color: var(--primary); text-align: center; padding: 6px 14px; min-width: 64px; }
.scr-card .score small { display: block; font-size: 9px; font-weight: 700; letter-spacing: .6px; }
.scr-card .score b { display: block; font-size: 18px; line-height: 1.2; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex-shrink: 0; }

/* ── Kuis ──────────────────────────────────────────────────────────────── */
.note { border-radius: 12px; padding: 12px 14px; font-size: 12.5px; line-height: 1.6; }
.note.gray { background: #F3F5F8; color: var(--text-2); }
.note.blue { background: #E8F2FD; color: #1565C0; border-left: 3px solid #2196F3; }
.note.yellow { background: #FFF8E1; color: #856404; border-left: 3px solid #FFC107; }
.note.teal { background: var(--primary-50); color: var(--primary); border-left: 3px solid var(--primary-2); }
.note b { font-weight: 700; }
.note h3 { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 6px; }

.q-card { background: #fff; border-radius: 16px; padding: 16px; box-shadow: var(--shadow); }
.q-card + .q-card { margin-top: 14px; }
.q-num { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.q-num .n { width: 30px; height: 30px; border-radius: 10px; background: var(--primary-50); color: var(--primary); font-weight: 800; font-size: 13px; display: grid; place-items: center; flex-shrink: 0; }
.q-num.done .n { background: var(--primary); color: #fff; }
.q-num b { font-size: 13px; font-weight: 700; color: var(--primary); }
.q-text { font-size: 14px; color: var(--text); line-height: 1.55; margin-bottom: 12px; }
.q-sub { font-size: 13px; font-weight: 600; margin: 4px 0 10px; line-height: 1.5; }
.q-sep { border-top: 1px solid #EEF1F4; margin-top: 14px; padding-top: 14px; }

.opts { display: flex; flex-direction: column; gap: 8px; }
.opt { position: relative; display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--border); background: #fff; cursor: pointer; transition: border-color .15s, background .15s; font-size: 13.5px; line-height: 1.5; }
.opt input { position: absolute; opacity: 0; pointer-events: none; }
.opt .radio { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #B6C0CC; flex-shrink: 0; margin-top: 1px; display: grid; place-items: center; transition: border-color .15s; }
.opt .radio::after { content: ''; width: 10px; height: 10px; border-radius: 50%; background: #fff; transform: scale(0); transition: transform .15s; }
.opt.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.opt.on .radio { border-color: #fff; }
.opt.on .radio::after { transform: scale(1); }
@media (hover: hover) { .opt:hover { border-color: var(--primary-2); } }
.opts.row4 { flex-direction: row; flex-wrap: wrap; }
.opts.row4 .opt { flex: 1 1 calc(25% - 8px); min-width: 70px; justify-content: center; text-align: center; padding: 10px 6px; font-size: 11.5px; }
.opts.row4 .opt .radio { display: none; }

.score-pick { display: flex; gap: 8px; }
.score-pick label { width: 48px; height: 44px; border-radius: 10px; border: 1.5px solid var(--border-2); display: grid; place-items: center; font-weight: 700; font-size: 17px; cursor: pointer; background: #fff; }
.score-pick input { position: absolute; opacity: 0; pointer-events: none; }
.score-pick label.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.stepper { display: flex; align-items: center; gap: 10px; }
.stepper button { width: 44px; height: 44px; border-radius: 10px; border: 0; background: var(--primary); color: #fff; font-size: 22px; font-weight: 700; display: grid; place-items: center; }
.stepper output { min-width: 70px; height: 44px; border-radius: 10px; border: 1.5px solid var(--border-2); background: #F7F9FB; display: grid; place-items: center; font-weight: 800; font-size: 18px; }
.stepper output small { font-size: 13px; font-weight: 600; color: var(--muted); }
.stepper.unset output { color: var(--muted-2); }

.sec-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding-bottom: 10px; margin-bottom: 14px; border-bottom: 2px solid var(--primary); }
.sec-head h2 { font-size: 15px; font-weight: 800; color: var(--primary); }
.sec-head .sc { font-weight: 800; color: var(--primary); font-size: 15px; white-space: nowrap; }
.item-box { border: 1px solid var(--border); border-radius: 12px; padding: 12px; background: #FCFDFE; }
.item-box + .item-box { margin-top: 12px; }
.item-box .lb { font-size: 13.5px; font-weight: 600; line-height: 1.5; }
.item-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.ref-img { width: 100%; max-height: 190px; object-fit: contain; background: #fff; border-radius: 10px; margin: 8px 0; }
.ref-img.sm { width: 66%; max-width: 280px; margin: 0 0 8px; }
.word-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.word-chips span { background: var(--primary); color: #fff; font-weight: 700; padding: 8px 12px; border-radius: 10px; font-size: 14px; }

.draw-btn { width: 100%; margin-top: 10px; padding: 11px; border-radius: 10px; border: 1.5px dashed var(--primary-2); background: var(--primary-50); color: var(--primary); font-weight: 600; font-size: 13px; }
.draw-btn.done { border-style: solid; border-color: var(--success); background: #ECFDF5; color: #047857; }
.draw-preview { margin-top: 8px; border-radius: 10px; border: 1px solid var(--border-2); background: #fff; height: 160px; width: 100%; object-fit: contain; }
.draw-modal { position: fixed; inset: 0; z-index: 9500; background: #EEF2F6; display: none; flex-direction: column; }
.draw-modal.open { display: flex; }
.draw-modal header { display: flex; align-items: center; gap: 12px; padding: calc(14px + var(--safe-t)) 16px 14px; background: #fff; border-bottom: 1px solid var(--border); }
.draw-modal header b { flex: 1; font-size: 14px; }
.draw-modal .cv { flex: 1; margin: 14px; border-radius: 14px; overflow: hidden; border: 1.5px solid var(--border-2); background: #fff; position: relative; }
.draw-modal canvas { width: 100%; height: 100%; touch-action: none; display: block; cursor: crosshair; }
.draw-modal footer { display: flex; gap: 10px; padding: 4px 14px calc(18px + var(--safe-b)); }

.result-card { background: #fff; border-radius: 18px; padding: 20px; box-shadow: var(--shadow); border-top: 5px solid var(--rc, var(--primary)); }
.result-card .badge { background: var(--rc, var(--primary)); color: #fff; font-size: 12px; padding: 7px 12px; }
.result-card .total { font-size: 26px; font-weight: 800; margin: 10px 0 6px; }
.result-card p { color: var(--text-2); font-size: 13.5px; line-height: 1.6; }
.legend > div { display: flex; align-items: center; gap: 10px; font-size: 12px; margin-top: 7px; }
.legend i { width: 12px; height: 12px; border-radius: 50%; flex-shrink: 0; }

.progress-sticky { position: sticky; top: 0; z-index: 50; background: rgba(242, 245, 248, .94); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); padding: 10px 16px; border-bottom: 1px solid var(--border); }
.progress-sticky .in { max-width: 728px; margin: 0 auto; display: flex; align-items: center; gap: 10px; font-size: 11.5px; font-weight: 600; color: var(--muted); }
.pbar { flex: 1; height: 6px; border-radius: 3px; background: #DDE3EA; overflow: hidden; }
.pbar i { display: block; height: 100%; width: 0; background: var(--grad); border-radius: 3px; transition: width .3s; }

/* ── Pemutar audio ─────────────────────────────────────────────────────── */
.player { display: flex; flex-direction: column; align-items: center; padding: 26px 20px; }
.disc { width: 170px; height: 170px; border-radius: 50%; background: radial-gradient(circle at 50% 50%, #22385e 0 22%, #0b1730 23% 100%); display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 67, 104, .35), inset 0 0 0 10px rgba(255, 255, 255, .03), inset 0 0 0 22px rgba(255, 255, 255, .02); margin-bottom: 18px; }
.disc::after { content: ''; width: 34px; height: 34px; border-radius: 50%; background: var(--grad); box-shadow: 0 0 0 6px rgba(255, 255, 255, .08); }
.disc.spin { animation: spin 5s linear infinite; }
.player h2 { font-size: 17px; font-weight: 700; text-align: center; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; background: #F3F4F6; border-radius: 999px; padding: 6px 14px; font-size: 12px; font-weight: 600; color: var(--muted); margin: 10px 0 16px; }
.seek { display: flex; align-items: center; gap: 10px; width: 100%; font-size: 11px; font-weight: 600; color: var(--muted-2); }
.seek span { min-width: 40px; text-align: center; font-variant-numeric: tabular-nums; }
.seek-bar { flex: 1; height: 28px; display: flex; align-items: center; cursor: pointer; touch-action: none; }
.seek-bar .rail { position: relative; width: 100%; height: 5px; border-radius: 3px; background: #E5E7EB; }
.seek-bar .fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 3px; background: var(--grad); width: 0; }
.seek-bar .knob { position: absolute; top: 50%; left: 0; width: 16px; height: 16px; border-radius: 50%; background: var(--primary); transform: translate(-50%, -50%); box-shadow: 0 2px 6px rgba(0, 67, 104, .4); }
.controls { display: flex; align-items: center; gap: 28px; margin-top: 18px; }
.ctrl-stop { width: 50px; height: 50px; border-radius: 50%; border: 1px solid var(--border); background: #F3F4F6; display: grid; place-items: center; }
.ctrl-stop i { width: 16px; height: 16px; border-radius: 3px; background: var(--danger); }
.ctrl-stop:disabled { opacity: .35; }
.ctrl-play { width: 76px; height: 76px; border-radius: 50%; border: 0; background: var(--grad); color: #fff; display: grid; place-items: center; box-shadow: 0 8px 22px rgba(0, 67, 104, .38); transition: transform .12s; }
.ctrl-play:active { transform: scale(.95); }
.ctrl-spacer { width: 50px; }

/* ── Panduan audio ─────────────────────────────────────────────────────── */
.guide { display: flex; gap: 10px; border-radius: 12px; padding: 12px; border-left: 3px solid var(--ga); background: var(--gb); }
.guide + .guide { margin-top: 8px; }
.guide .gi { font-size: 22px; line-height: 1.2; }
.guide b { display: block; font-size: 13px; color: var(--ga); }
.guide strong { display: block; font-size: 11.5px; font-weight: 600; margin: 1px 0 4px; }
.guide p { font-size: 11.5px; color: var(--text-2); line-height: 1.55; }
.collapse-head { display: flex; align-items: center; gap: 12px; padding: 16px; width: 100%; background: none; border: 0; text-align: left; }
.collapse-head .arrow { color: var(--primary-2); transition: transform .2s; }
.collapse.open .collapse-head .arrow { transform: rotate(90deg); }
.collapse-body { display: none; padding: 0 16px 16px; border-top: 1px solid #F1F4F7; }
.collapse.open .collapse-body { display: block; }

/* ── Booking ───────────────────────────────────────────────────────────── */
.picker { display: flex; align-items: center; gap: 10px; width: 100%; padding: 13px 14px; border-radius: 12px; background: #F9FAFB; border: 1.5px solid var(--border); text-align: left; font-weight: 600; font-size: 13px; color: var(--muted-2); }
.picker.set { color: var(--text); border-color: var(--primary-2); }
.picker .ic { color: var(--primary-2); }
.picked { display: flex; align-items: center; gap: 12px; margin-top: 10px; padding: 10px; border-radius: 12px; background: var(--primary-50); border: 1.5px solid var(--primary-100); }
.picked img { width: 52px; height: 52px; border-radius: 10px; object-fit: cover; background: #DDE5EC; }
.picked img.round { border-radius: 50%; }
.picked b { display: block; font-size: 13px; }
.picked small { display: block; font-size: 11px; color: var(--muted); margin-top: 2px; }
.step-off { opacity: .45; pointer-events: none; filter: grayscale(.3); }
.slots { display: flex; flex-wrap: wrap; gap: 8px; }
.slot { min-width: 70px; padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--border-2); background: #fff; font-weight: 700; font-size: 12.5px; text-align: center; line-height: 1.2; }
.slot.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.slot:disabled { background: #F3F4F6; color: #C7CDD4; border-color: var(--border); }
.slot small { display: block; font-size: 9px; color: var(--danger); font-weight: 600; margin-top: 2px; }
.pick-list .pick { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px; border-radius: 14px; border: 2px solid var(--border); background: #fff; text-align: left; }
.pick-list .pick + .pick { margin-top: 10px; }
.pick-list .pick.on { border-color: var(--primary-2); background: var(--primary-50); }
.pick-list .pick img { width: 60px; height: 60px; border-radius: 10px; object-fit: cover; background: #DDE5EC; flex-shrink: 0; }
.pick-list .pick img.round { border-radius: 50%; }
.pick-list .pick b { display: block; font-size: 14px; }
.pick-list .pick small { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.5; }
.pick-list .pick .ok { color: var(--primary-2); margin-left: auto; visibility: hidden; }
.pick-list .pick.on .ok { visibility: visible; }

/* ── Tekanan darah ─────────────────────────────────────────────────────── */
.bp-item { display: flex; align-items: flex-start; gap: 12px; background: #fff; border-radius: 16px; padding: 14px; box-shadow: var(--shadow); }
.bp-item + .bp-item { margin-top: 10px; }
.bp-item .bar { width: 4px; align-self: stretch; border-radius: 2px; background: var(--c); }
.bp-item .val { font-size: 20px; font-weight: 800; color: var(--c); }
.bp-item .val small { font-size: 12px; font-weight: 500; }
.bp-item .tag { display: inline-block; font-size: 11px; font-weight: 600; color: var(--c); background: var(--cb); padding: 3px 9px; border-radius: 999px; margin: 3px 0 4px; }
.bp-preview { border-radius: 12px; padding: 14px; background: var(--cb); border: 1px solid var(--cl); }
.bp-preview .badge { background: var(--c); color: #fff; }
.bp-preview .val { font-size: 20px; font-weight: 800; color: var(--c); margin: 8px 0 4px; }
.icon-btn { width: 38px; height: 38px; border-radius: 10px; border: 0; background: #FEF2F2; color: var(--danger); display: grid; place-items: center; flex-shrink: 0; }

/* ── Akun ──────────────────────────────────────────────────────────────── */
.profile-card { text-align: center; padding: 24px 16px; margin-top: -40px; position: relative; z-index: 2; }
.profile-card .avatar { margin: 0 auto; position: relative; box-shadow: 0 0 0 5px #fff, 0 8px 20px rgba(0, 67, 104, .25); }
.profile-card .online { position: absolute; right: 2px; bottom: 4px; width: 18px; height: 18px; border-radius: 50%; background: #00C48C; border: 3px solid #fff; }
.profile-card h2 { font-size: 17px; font-weight: 800; margin-top: 14px; }
.profile-card p { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.appbar.tall { padding-bottom: 60px; }

/* ── Status transaksi ──────────────────────────────────────────────────── */
.status-badge { color: #fff; font-size: 11px; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: var(--c, #9CA3AF); white-space: nowrap; }

/* ── Desktop ───────────────────────────────────────────────────────────── */
@media (min-width: 1024px) {
  .appbar { padding-top: 22px; padding-bottom: 30px; }
  .appbar h1 { font-size: 22px; }
  .wrap { padding: 20px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
