/* ===================== BarberQ — App (PWA Pelanggan) ===================== */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Work+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@500&display=swap');

:root{
    --gold:#F3B000; --gold-dark:#C98C00; --gold-light:#FFE9B3;
    --ink:#17140F; --ink-soft:#221E17;
    --cream:#FFFCF5; --white:#FFFFFF;
    --gray:#6E675D; --gray-light:#E9E4DA; --gray-lighter:#F5F2EA;
    --radius-sm:10px; --radius-md:16px; --radius-lg:24px;
    --shadow: 0 10px 30px -12px rgba(23,20,15,.22);
    --font-display:'Bebas Neue', sans-serif;
    --font-body:'Work Sans', sans-serif;
    --font-mono:'JetBrains Mono', monospace;
}
*{box-sizing:border-box; margin:0; padding:0;}
html{
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    touch-action: manipulation; /* cegah double-tap zoom, kerasa kayak app asli */
}
body{
    font-family:var(--font-body);
    background: var(--gray-lighter);
    color: var(--ink);
    overscroll-behavior-y: contain; /* cegah efek pull-to-refresh/bounce browser */
}
a{ text-decoration:none; color:inherit; }
img{ max-width:100%; }
button{ font-family:inherit; }

.app-container{
    max-width:480px;
    margin-inline:auto;
    min-height:100vh;
    background: var(--gray-lighter);
    position:relative;
}
.app-container.with-nav{ padding-bottom:84px; } /* jarak buat halaman yang punya bottom nav */

/* ---------- App top bar ---------- */
.app-topbar{
    background: var(--ink);
    color: var(--white);
    padding:20px 20px 26px;
    border-radius: 0 0 24px 24px;
    position:relative;
    overflow:hidden;
}
.app-topbar::before{
    content:"";
    position:absolute; inset:0;
    background: radial-gradient(circle at 90% -10%, rgba(243,176,0,.3), transparent 55%);
}
.app-topbar .row{ position:relative; display:flex; justify-content:space-between; align-items:center; }
.app-topbar .greet span{ display:block; font-size:.78rem; color:var(--gray-lighter); }
.app-topbar .greet strong{ font-family:var(--font-display); font-size:1.5rem; letter-spacing:.02em; }
.avatar-circle{
    width:44px; height:44px; border-radius:50%;
    background: var(--gold); color: var(--ink);
    display:flex; align-items:center; justify-content:center;
    font-weight:800; font-family:var(--font-mono);
}
.status-shop{
    position:relative;
    margin-top:18px;
    background: rgba(255,255,255,.08);
    border:1px solid rgba(255,255,255,.14);
    border-radius: var(--radius-md);
    padding:14px 16px;
    display:flex; justify-content:space-between; align-items:center;
}
.status-shop .dot{
    width:9px; height:9px; border-radius:50%;
    display:inline-block; margin-right:6px;
}
.status-shop .dot.open{ background:#3FCB63; box-shadow:0 0 0 4px rgba(63,203,99,.2); }
.status-shop .dot.closed{ background:#E5564B; box-shadow:0 0 0 4px rgba(229,86,75,.2); }
.status-shop .label{ font-size:.8rem; font-weight:700; }
.status-shop .hours{ font-size:.76rem; color:var(--gray-lighter); font-family:var(--font-mono); }

/* ---------- Content ---------- */
.app-content{ padding:20px; }
.section-title{
    display:flex; justify-content:space-between; align-items:center;
    margin:22px 0 12px;
}
.section-title h3{ font-size:1.02rem; font-weight:800; }
.section-title a{ font-size:.78rem; color: var(--gold-dark); font-weight:700; }

/* Quick action grid */
.quick-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-top:16px; margin-bottom:20px; }
.quick-item{
    background: var(--white); border:1px solid var(--gray-light);
    border-radius: var(--radius-md); padding:16px 8px; text-align:center;
    display:flex; flex-direction:column; align-items:center; gap:8px;
}
.quick-item .ic{
    width:42px; height:42px; border-radius:12px; background: var(--gold-light);
    display:flex; align-items:center; justify-content:center;
}
.quick-item .ic svg{ width:20px; height:20px; }
.quick-item span{ font-size:.72rem; font-weight:700; }

/* Cards */
.card{
    background: var(--white); border:1px solid var(--gray-light);
    border-radius: var(--radius-md); padding:18px; margin-bottom:14px;
}
.booking-card{
    display:flex; flex-direction:column; gap:10px;
}
.booking-card .top-row{ display:flex; justify-content:space-between; align-items:flex-start; }
.booking-card .kode{ font-family:var(--font-mono); font-size:.75rem; color:var(--gray); }
.booking-card h4{ font-size:1.02rem; margin-top:2px; }
.booking-card .meta-row{
    display:flex; flex-wrap:wrap; gap:8px; font-size:.78rem; color:var(--gray);
    border-top:1px dashed var(--gray-light); padding-top:10px;
}
.booking-card .meta-row span{ display:flex; align-items:center; gap:4px; }
.booking-card .pay-row{ display:flex; justify-content:space-between; align-items:center; font-size:.8rem; }
.booking-card .pay-row .amount{ font-family:var(--font-display); font-size:1.2rem; color:var(--gold-dark); }
.booking-card a.proof-link{ font-size:.76rem; color:var(--gold-dark); font-weight:700; text-decoration:underline; }

/* Buttons */
.btn{
    display:inline-flex; align-items:center; justify-content:center; gap:8px;
    padding:14px 18px; border-radius: var(--radius-sm);
    font-weight:700; font-size:.92rem; border:1.5px solid transparent; cursor:pointer;
    transition: transform .15s ease, background .15s ease;
}
.btn-primary{ background: var(--gold); color: var(--ink); }
.btn-primary:hover{ background: var(--gold-dark); }
.btn-outline{ background:transparent; border-color:var(--gray-light); color:var(--ink); }
.btn-dark{ background: var(--ink); color:var(--white); }
.btn-block{ width:100%; }
.btn[disabled]{ opacity:.5; }

/* Forms */
.form-group{ margin-bottom:16px; }
.form-group label{ display:block; font-weight:700; font-size:.83rem; margin-bottom:7px; }
.form-group input, .form-group select, .form-group textarea{
    width:100%; padding:13px 14px; border:1.5px solid var(--gray-light);
    border-radius: var(--radius-sm); font-family:inherit; font-size:16px; background:var(--cream);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus{
    outline:none; border-color: var(--gold); background:var(--white);
}
.form-group .hint{ font-size:.74rem; color:var(--gray); margin-top:5px; display:block; }

/* Payment method selector */
.pay-options{ display:flex; flex-direction:column; gap:10px; }
.pay-option{
    border:1.5px solid var(--gray-light); border-radius: var(--radius-md);
    padding:14px 16px; display:flex; align-items:center; gap:12px; cursor:pointer;
    transition: border-color .15s ease, background .15s ease;
}
.pay-option:has(input:checked){ border-color: var(--gold); background: #FFFBF0; }
.pay-option input[type="radio"]{ width:18px; height:18px; accent-color: var(--gold-dark); }
.pay-option .ic{
    width:38px; height:38px; border-radius:10px; background: var(--gold-light);
    display:flex; align-items:center; justify-content:center; flex:0 0 38px;
}
.pay-option .ic svg{ width:18px; height:18px; }
.pay-option .txt strong{ display:block; font-size:.88rem; }
.pay-option .txt span{ font-size:.74rem; color:var(--gray); }

.pay-detail-box{
    display:none; background: var(--ink); color:var(--white);
    border-radius: var(--radius-md); padding:16px; margin-top:10px;
}
.pay-detail-box.show{ display:block; }
.pay-detail-box .rek-row{
    display:flex; justify-content:space-between; align-items:center;
    background: rgba(255,255,255,.06); border-radius:10px; padding:10px 12px; margin-bottom:8px;
}
.pay-detail-box .rek-row strong{ color: var(--gold); font-family:var(--font-mono); }

.file-drop{
    border:1.5px dashed var(--gray-light); border-radius: var(--radius-md);
    padding:20px; text-align:center; background:var(--cream); cursor:pointer;
}
.file-drop svg{ width:26px; height:26px; margin-bottom:6px; color:var(--gray); }
.file-drop span{ display:block; font-size:.8rem; color:var(--gray); }
.file-drop input[type="file"]{ display:none; }
.file-preview{ margin-top:10px; max-height:160px; border-radius:10px; overflow:hidden; display:none; }
.file-preview.show{ display:block; }
.file-preview img{ width:100%; object-fit:cover; }

.alert{ padding:13px 16px; border-radius:var(--radius-sm); margin-bottom:16px; font-size:.85rem; font-weight:600; border-left:4px solid;}
.alert-success{ background:#EFFBF0; border-color:#2E9E4A; color:#1E6B31; }
.alert-error{ background:#FDF0EF; border-color:#C0392B; color:#8E2A1F; }
.alert-info{ background:#FFF8E6; border-color:var(--gold); color:#8A6100; }

.badge{ display:inline-block; padding:4px 11px; border-radius:20px; font-size:.72rem; font-weight:700; }
.badge-wait{ background:#FDF3D8; color:#8A6100; }
.badge-confirm{ background:#DCEEFF; color:#1B5A96; }
.badge-done{ background:#DFF6E1; color:#1E7A2F; }
.badge-cancel{ background:#FBE1DF; color:#A6321F; }

.empty-state{ text-align:center; padding:50px 20px; color:var(--gray); }
.empty-state svg{ width:48px; height:48px; margin-bottom:12px; color:var(--gray-light); }
.empty-state p{ font-size:.88rem; }

/* ---------- Bottom nav ---------- */
.bottom-nav{
    position:fixed; bottom:0; left:0; right:0;
    max-width:480px; margin-inline:auto;
    background: var(--white);
    border-top:1px solid var(--gray-light);
    display:flex; justify-content:space-around; align-items:center;
    padding:10px 6px calc(10px + env(safe-area-inset-bottom));
    z-index:100;
    box-shadow: 0 -6px 20px -10px rgba(23,20,15,.15);
}
.bottom-nav a{
    display:flex; flex-direction:column; align-items:center; gap:4px;
    font-size:.66rem; font-weight:700; color: var(--gray);
    padding:6px 10px; border-radius:10px;
}
.bottom-nav a svg{ width:22px; height:22px; }
.bottom-nav a.active{ color: var(--gold-dark); }
.bottom-nav a.fab{
    background: var(--ink); color: var(--gold);
    width:52px; height:52px; border-radius:50%;
    margin-top:-26px; box-shadow: var(--shadow);
    justify-content:center;
}
.bottom-nav a.fab svg{ width:24px; height:24px; }
.bottom-nav a.fab span{ display:none; }

/* ---------- Auth screens (login/register) ---------- */
.auth-wrap{
    min-height:100vh; min-height:100dvh; display:flex; flex-direction:column; justify-content:center;
    background: var(--ink); padding:28px 24px;
    background-image: radial-gradient(circle at 85% 15%, rgba(243,176,0,.22), transparent 50%);
}
.auth-logo, .brand-mark{
    width:64px; height:64px; border-radius:50%; margin:0 auto 18px;
    background: conic-gradient(var(--ink) 0 25%, var(--gold) 0 50%, var(--ink) 0 75%, var(--gold) 0 100%);
    box-shadow: inset 0 0 0 3px var(--white), 0 0 0 2px var(--ink);
}
.auth-card{
    background: var(--white); border-radius: var(--radius-lg);
    padding:34px 26px; box-shadow: var(--shadow);
    max-width:400px; width:100%; margin-inline:auto;
}
.auth-card h2{ font-family:var(--font-display); font-size:1.9rem; text-align:center; }
.auth-card p.sub{ text-align:center; color:var(--gray); font-size:.86rem; margin-bottom:22px; }
.auth-switch{ text-align:center; font-size:.85rem; margin-top:16px; color:var(--gray); }
.auth-switch a{ color: var(--gold-dark); font-weight:700; }

/* Install landing (before login) */
.install-hero{
    min-height:100vh; background: var(--ink); color:var(--white);
    display:flex; flex-direction:column; align-items:center; justify-content:center;
    text-align:center; padding:36px 26px;
    background-image: radial-gradient(circle at 80% 10%, rgba(243,176,0,.28), transparent 50%);
}
.install-hero .mark, .install-hero .brand-mark{
    width:84px; height:84px; border-radius:50%; margin-bottom:22px;
    background: conic-gradient(var(--ink) 0 25%, var(--gold) 0 50%, var(--ink) 0 75%, var(--gold) 0 100%);
    box-shadow: inset 0 0 0 4px var(--white), 0 0 0 3px var(--ink);
}
.install-hero h1{ font-family:var(--font-display); font-size:2.3rem; letter-spacing:.02em; margin-bottom:10px; }
.install-hero p{ color:var(--gray-lighter); max-width:340px; margin-bottom:28px; font-size:.95rem; }
.install-hero .steps{ text-align:left; max-width:320px; width:100%; margin-bottom:30px; }
.install-hero .steps div{ display:flex; gap:12px; margin-bottom:14px; align-items:flex-start; }
.install-hero .steps .num{
    width:26px; height:26px; border-radius:50%; background:var(--gold); color:var(--ink);
    font-family:var(--font-mono); font-weight:800; font-size:.78rem;
    display:flex; align-items:center; justify-content:center; flex:0 0 26px;
}
.install-hero .steps p{ margin:0; color:var(--white); font-size:.86rem; font-weight:600; }
.install-hero .actions{ display:flex; flex-direction:column; gap:12px; width:100%; max-width:320px; }

@media (max-width: 380px){
    .quick-grid{ gap:8px; }
}