body { background: #0F0B07; color: #F3EDE0; }
.rc { min-height: 100vh; display: flex; flex-direction: column; background: radial-gradient(900px 560px at 50% -10%, rgba(226,180,45,.18), transparent 60%), radial-gradient(700px 500px at 0% 110%, rgba(140,90,40,.22), transparent 60%), linear-gradient(178deg, #19120B, #0D0905); }
.rc-hdr { display: flex; align-items: center; gap: 14px; padding: 16px clamp(16px, 3vw, 32px); border-bottom: 1px solid rgba(255,236,200,.07); flex-wrap: wrap; }
.rc-hdr img { width: 38px; height: 38px; object-fit: contain; }
.rc-hdr .eyebrow { color: #E2B42D; font-size: 9.5px; }
.rc-hdr b { font-size: 16px; } .rc-hdr b span { color: #C9BFAB; font-weight: 500; }
.rc-hdr .right { margin-left: auto; display: flex; align-items: center; gap: 12px; font-family: var(--mono); font-size: 11px; color: #8E846F; }
.link { color: #E2B42D; text-decoration: none; font-weight: 700; font-family: var(--sans); font-size: 12.5px; }

/* ── masyarakat phone ── */
.phone-wrap { flex: 1; display: grid; place-items: center; padding: 28px 16px 48px; }
.phone { width: min(440px, 100%); border-radius: 36px; padding: 26px 24px 24px; background: linear-gradient(160deg, rgba(255,248,235,.09), rgba(255,248,235,.02) 60%); border: 1px solid rgba(255,236,200,.14); box-shadow: 0 40px 90px -40px rgba(0,0,0,.9), inset 0 1px 0 rgba(255,255,255,.12); display: flex; flex-direction: column; align-items: center; gap: 18px; }
.phone .top { width: 100%; display: flex; justify-content: space-between; font-family: var(--mono); font-size: 10.5px; letter-spacing: .12em; color: #E2B42D; }
.phone .top span:last-child { color: #8E846F; }
.orb { position: relative; width: 220px; height: 220px; display: grid; place-items: center; margin: 6px 0; }
.orb .ring { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(226,180,45,.5); opacity: 0; }
.orb.ringing .ring { animation: ring 1.4s ease-out infinite; }
.orb.active .ring { animation: ring 2.6s ease-out infinite; }
.orb .ring:nth-child(2) { animation-delay: .45s !important; } .orb .ring:nth-child(3) { animation-delay: .9s !important; }
@keyframes ring { 0% { transform: scale(.75); opacity: .9; } 100% { transform: scale(1.25); opacity: 0; } }
.orb .core { width: 168px; height: 168px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 30%, rgba(226,180,45,.26), rgba(32,24,14,.95) 72%); border: 1px solid rgba(226,180,45,.38); box-shadow: 0 30px 60px -24px rgba(226,180,45,.35), inset 0 1px 0 rgba(255,255,255,.18); transition: transform .08s; }
.orb .core img { width: 104px; height: 104px; object-fit: contain; }
.phone h2 { margin: 0; font-size: 26px; font-weight: 800; letter-spacing: -.02em; text-align: center; }
.phone .sub { margin: -10px 0 0; font-size: 13.5px; color: #C9BFAB; text-align: center; min-height: 20px; }
.timer { font-family: var(--mono); font-size: 13px; color: #E2B42D; }
.caption { width: 100%; border-radius: 18px; padding: 14px 16px; background: rgba(226,180,45,.08); border: 1px solid rgba(226,180,45,.22); }
.caption .eyebrow { color: #E2B42D; display: flex; justify-content: space-between; }
.caption p { margin: 8px 0 0; font-size: 15.5px; line-height: 1.5; color: #F3EDE0; }
.caption.you { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.1); }
.caption.you .eyebrow { color: #C9BFAB; }
.call-btn { width: 100%; height: 58px; border-radius: 999px; font-size: 17px; font-weight: 800; }
.end-btn { width: 72px; height: 72px; border-radius: 50%; background: #D93A35; color: #fff; display: grid; place-items: center; box-shadow: 0 14px 30px -10px rgba(217,58,53,.7); }
.end-btn svg { width: 30px; height: 30px; }
.ctrls { display: flex; align-items: center; justify-content: center; gap: 18px; width: 100%; }
.round { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); color: #F3EDE0; font-size: 20px; }
.round.on { background: rgba(226,180,45,.22); border-color: rgba(226,180,45,.5); }
.round.off { background: rgba(255,255,255,.03); color: #8E846F; }
.round-wrap { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; color: #8E846F; }
.typed { display: flex; gap: 8px; width: 100%; }
.typed input { flex: 1; height: 44px; border-radius: 999px; padding: 0 16px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.12); color: #F3EDE0; outline: none; min-width: 0; }
.typed input:focus { border-color: rgba(226,180,45,.5); }
.samples { width: 100%; }
.samples summary { cursor: pointer; font-size: 12px; color: #8E846F; text-align: center; list-style: none; }
.samples div { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; justify-content: center; }
.samples button { font-size: 12px; padding: 6px 12px; border-radius: 999px; border: 1px solid rgba(226,180,45,.3); color: #E2B42D; }
.fine { font-size: 12px; line-height: 1.5; color: #8E846F; text-align: center; margin: 0; }
.notice { width: 100%; font-size: 12.5px; color: #FFD7CF; background: rgba(229,72,77,.1); border: 1px solid rgba(229,72,77,.3); border-radius: 12px; padding: 10px 12px; }
.receipt { width: 100%; border-radius: 18px; padding: 16px; background: rgba(95,191,122,.08); border: 1px solid rgba(95,191,122,.3); display: flex; flex-direction: column; gap: 6px; }
.receipt .eyebrow { color: #7FD69A; }
.receipt b { font-family: var(--mono); font-size: 13px; word-break: break-all; }
.receipt p { margin: 0; font-size: 13px; color: #C9BFAB; line-height: 1.5; }
.hist { width: 100%; max-height: 220px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }
.hist div { font-size: 13px; line-height: 1.45; } .hist div b { font-family: var(--mono); font-size: 10px; letter-spacing: .1em; margin-right: 6px; } .hist .ai b { color: #E2B42D; } .hist .user b { color: #C9BFAB; }

/* ── konsol ── */
.k-grid { flex: 1; display: grid; grid-template-columns: 280px minmax(0, 1fr) 380px; gap: 16px; padding: 18px clamp(16px, 2.4vw, 28px) 28px; min-height: 0; }
@media (max-width: 1200px) { .k-grid { grid-template-columns: 240px minmax(0, 1fr); } .k-grid .k-right { grid-column: 1 / -1; } }
@media (max-width: 780px) { .k-grid { grid-template-columns: 1fr; } }
.kp { border-radius: 22px; background: linear-gradient(160deg, rgba(255,255,255,.06), rgba(255,255,255,.02)); border: 1px solid rgba(255,255,255,.09); padding: 16px; }
.kp .eyebrow { color: #8E846F; }
.k-col { display: flex; flex-direction: column; gap: 14px; min-height: 0; }
.sess { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.sess button { text-align: left; padding: 12px; border-radius: 14px; background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.07); display: flex; flex-direction: column; gap: 4px; }
.sess button.on { border-color: rgba(226,180,45,.55); background: rgba(226,180,45,.08); }
.sess .r1 { display: flex; justify-content: space-between; align-items: center; font-family: var(--mono); font-size: 11.5px; font-weight: 700; }
.sess .r2 { font-size: 12.5px; color: #C9BFAB; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.k-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.k-head h1 { margin: 4px 0 0; font-size: 26px; font-weight: 800; letter-spacing: -.02em; }
.k-head .eyebrow { color: #E2B42D; }
.tag { font-family: var(--mono); font-size: 11px; padding: 5px 10px; border-radius: 999px; border: 1px solid rgba(255,255,255,.14); color: #C9BFAB; display: inline-flex; gap: 6px; align-items: center; }
.k-tr { flex: 1; min-height: 380px; display: flex; flex-direction: column; border-radius: 22px; background: linear-gradient(160deg, rgba(255,255,255,.05), rgba(255,255,255,.015)); border: 1px solid rgba(255,255,255,.09); overflow: hidden; }
.k-tr .hd { display: flex; justify-content: space-between; padding: 12px 18px; border-bottom: 1px solid rgba(255,255,255,.07); font-family: var(--mono); font-size: 11px; color: #8E846F; }
.k-tr .bd { flex: 1; overflow-y: auto; padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; max-height: calc(100vh - 260px); }
.bub { max-width: 86%; padding: 11px 14px; border-radius: 16px; font-size: 14.5px; line-height: 1.5; }
.bub small { display: block; font-family: var(--mono); font-size: 9.5px; letter-spacing: .12em; margin-bottom: 4px; }
.bub.ai { align-self: flex-start; background: rgba(226,180,45,.09); border: 1px solid rgba(226,180,45,.22); } .bub.ai small { color: #E2B42D; }
.bub.user { align-self: flex-end; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.09); } .bub.user small { color: #C9BFAB; }
.bub.interim { opacity: .6; font-style: italic; }
.k-empty { color: #8E846F; font-size: 14px; line-height: 1.6; padding: 24px; text-align: center; margin: auto; max-width: 420px; }
.cls h3 { margin: 10px 0 2px; font-size: 20px; font-weight: 800; }
.cls .jenis { font-size: 13.5px; color: #C9BFAB; }
.cls .pasal { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.cls .pasal span { font-size: 11.5px; padding: 4px 9px; border-radius: 8px; background: rgba(226,180,45,.1); color: #F5D46A; border: 1px solid rgba(226,180,45,.22); }
.urgbar { display: flex; gap: 4px; margin-top: 12px; align-items: center; font-family: var(--mono); font-size: 11px; color: #8E846F; }
.urgbar i { width: 22px; height: 7px; border-radius: 3px; background: rgba(255,255,255,.12); }
.urgbar i.on { background: #E2B42D; } .urgbar i.hot { background: #F26B5B; }
.fields { display: flex; flex-direction: column; gap: 9px; margin-top: 12px; }
.fields div { display: grid; grid-template-columns: 92px 1fr; gap: 8px; align-items: baseline; font-size: 12.5px; }
.fields span:nth-child(2) { color: #8E846F; }
.saran { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.saran div { display: flex; gap: 10px; font-size: 13px; line-height: 1.45; } .saran b { font-family: var(--mono); font-size: 11px; color: #E2B42D; }
.alert { margin-top: 10px; font-size: 12.5px; color: #FFD7CF; background: rgba(229,72,77,.1); border-left: 2px solid #E5484D; padding: 8px 10px; border-radius: 0 8px 8px 0; }

/* doc viewer */
.viewer { flex: 1; padding: 24px 16px 60px; }
.viewer .bar { max-width: 210mm; margin: 0 auto 16px; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; }
.modal-bg { position: fixed; inset: 0; z-index: 50; background: rgba(8,5,3,.7); backdrop-filter: blur(6px); overflow-y: auto; padding: 30px 16px; }
.modal-bg .bar { max-width: 210mm; margin: 0 auto 14px; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; }

/* motion */
.orb.idle .core { animation: breathe 4.5s ease-in-out infinite; }
.orb.ended .core { filter: saturate(.6); transition: filter .8s; }
.orb .core { transition: transform .12s linear, filter .6s; }
.end-btn { transition: transform .2s var(--ease-out), box-shadow .2s; }
.end-btn:hover { transform: scale(1.06); box-shadow: 0 18px 36px -10px rgba(217,58,53,.85); }
.round:hover { border-color: rgba(226,180,45,.5); }
.call-btn { animation: fadeUp .6s var(--ease-out) .15s both; }
.sess button { transition: border-color .25s, background .25s, transform .2s var(--ease-out); }
.sess button:hover { transform: translateX(2px); }
.urgbar i { transition: background .6s var(--ease-out); }
.urgbar i:nth-child(2) { transition-delay: .05s; } .urgbar i:nth-child(3) { transition-delay: .1s; } .urgbar i:nth-child(4) { transition-delay: .15s; } .urgbar i:nth-child(5) { transition-delay: .2s; }
.fields .filled { animation: flash 1.4s var(--ease-out); border-radius: 6px; }
.kp { transition: border-color .5s var(--ease-out); }
.kp.working { border-color: rgba(226,180,45,.35); }
.k-tr .bd { scroll-behavior: smooth; }
.phone .top, .phone .timer { animation: fadeIn .5s var(--ease-out) both; }

.me { display: inline-flex; align-items: center; gap: 10px; padding-left: 14px; border-left: 1px solid rgba(255,255,255,.1); font-family: var(--sans); }
.me .av { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(160deg, #E8CB6E, #B48A2C); color: #1A140A; font-weight: 800; font-size: 11px; }
.me b { display: block; font-size: 12.5px; color: #F3EDE0; } .me small { font-size: 10.5px; color: #8E846F; }
.logout { height: 32px; padding: 0 14px; border-radius: 999px; font-family: var(--sans); font-size: 12px; font-weight: 700; color: #C9BFAB; border: 1px solid rgba(255,255,255,.16); transition: color .2s, border-color .2s, background .2s; }
.logout:hover { color: #fff; border-color: rgba(226,180,45,.6); background: rgba(226,180,45,.1); }
@media (max-width: 700px) { .me span:last-child { display: none; } }

/* caller's pause window before the officer responds */
.waitbar { width: 100%; display: flex; flex-direction: column; gap: 8px; font-size: 12.5px; color: #C9BFAB; text-align: center; }
.waitbar b { color: #E2B42D; font-family: var(--mono); }
.waitbar i { display: block; height: 3px; border-radius: 3px; background: rgba(255,255,255,.08); overflow: hidden; }
.waitbar em { display: block; height: 100%; background: linear-gradient(90deg, #C99A2E, #E2B42D); border-radius: 3px; transition: width .08s linear; }
