/* =====================================================================
   Kasirin — tampilan publik & akun
   Ditulis tangan, tanpa framework: satu berkas ~14 KB, tanpa permintaan
   tambahan ke server lain. Tujuannya halaman pertama terasa instan.
   ===================================================================== */

:root {
    --brand: #4f46e5;
    --brand-600: #4338ca;
    --brand-50: #eef2ff;
    --ink: #0f172a;
    --ink-2: #334155;
    --muted: #64748b;
    --line: #e2e8f0;
    --bg: #f8fafc;
    --card: #ffffff;
    --ok: #059669;
    --ok-bg: #ecfdf5;
    --warn: #b45309;
    --warn-bg: #fffbeb;
    --bad: #dc2626;
    --bad-bg: #fef2f2;
    --radius: 16px;
    --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px -12px rgba(15, 23, 42, .18);
    --max: 1140px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand-600); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.02em; }
h1 { font-size: clamp(2rem, 4.4vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2.2rem); }
h3 { font-size: 1.125rem; }
p { margin: 0 0 1em; }
small { font-size: .8125rem; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.tight { margin: 0; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.spread { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 40px; }

/* ---------- Header ---------- */
.nav {
    position: sticky; top: 0; z-index: 50;
    background: rgba(255, 255, 255, .86);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 750; font-size: 1.125rem; color: var(--ink); letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand-mark {
    width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center;
    background: linear-gradient(135deg, var(--brand), #7c3aed); color: #fff; font-weight: 800; font-size: 15px;
    box-shadow: 0 4px 12px -4px rgba(79, 70, 229, .6);
}
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--ink-2); font-size: .9375rem; font-weight: 500; }
.nav-links a:hover { color: var(--brand-600); text-decoration: none; }
@media (max-width: 720px) { .nav-links .hide-sm { display: none; } }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 18px; border-radius: 10px; border: 1px solid transparent;
    font: inherit; font-weight: 600; font-size: .9375rem; cursor: pointer;
    transition: transform .06s ease, box-shadow .15s ease, background .15s ease;
    text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 6px 16px -6px rgba(79, 70, 229, .7); }
.btn-primary:hover { background: var(--brand-600); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: #cbd5e1; background: #f8fafc; }
.btn-danger { background: var(--bad); color: #fff; }
.btn-sm { padding: 7px 12px; font-size: .8125rem; border-radius: 8px; }
.btn-lg { padding: 14px 24px; font-size: 1rem; border-radius: 12px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 72px 0 40px; }
.hero::before {
    content: ""; position: absolute; inset: -20% -10% auto; height: 640px; z-index: -1;
    background:
        radial-gradient(560px 280px at 15% 20%, rgba(79, 70, 229, .16), transparent 70%),
        radial-gradient(520px 260px at 85% 10%, rgba(14, 165, 233, .14), transparent 70%),
        radial-gradient(420px 240px at 60% 60%, rgba(16, 185, 129, .10), transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 32px; } .hero { padding-top: 48px; } }
.eyebrow {
    display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px;
    background: #fff; border: 1px solid var(--line); color: var(--ink-2);
    font-size: .8125rem; font-weight: 600; box-shadow: var(--shadow); margin-bottom: 18px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgba(5, 150, 105, .15); }
.hero h1 { margin-bottom: 16px; }
.hero h1 .grad {
    background: linear-gradient(120deg, var(--brand), #7c3aed 55%, #0ea5e9);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub { font-size: 1.125rem; color: var(--ink-2); max-width: 33em; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin: 26px 0 18px; }
.trust { display: flex; gap: 18px; flex-wrap: wrap; color: var(--muted); font-size: .875rem; }
.trust span { display: inline-flex; align-items: center; gap: 6px; }

/* Mockup dashboard (dibuat dari div, bukan gambar: ringan & tajam) */
.mockup {
    background: #fff; border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
    box-shadow: 0 30px 60px -30px rgba(15, 23, 42, .35), 0 2px 6px rgba(15, 23, 42, .06);
    transform: perspective(1400px) rotateY(-4deg) rotateX(2deg);
}
@media (max-width: 900px) { .mockup { transform: none; } }
.mockup-bar { display: flex; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #fbfcfe; }
.mockup-bar i { width: 9px; height: 9px; border-radius: 50%; background: #e2e8f0; }
.mockup-body { display: grid; grid-template-columns: 64px 1fr; min-height: 300px; }
.mockup-side { background: #0f172a; padding: 14px 10px; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.mockup-side i { width: 26px; height: 26px; border-radius: 8px; background: rgba(255,255,255,.12); }
.mockup-side i:first-child { background: var(--brand); }
.mockup-main { padding: 16px; background: #f8fafc; }
.mock-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.mock-kpi { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px; }
.mock-kpi b { display: block; font-size: 13px; }
.mock-kpi span { font-size: 10px; color: var(--muted); }
.mock-chart { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px; height: 150px; display: flex; align-items: flex-end; gap: 7px; }
.mock-chart i { flex: 1; border-radius: 4px 4px 2px 2px; background: linear-gradient(180deg, #818cf8, #4f46e5); opacity: .85; }

/* ---------- Sections ---------- */
section { padding: 64px 0; }
.section-head { max-width: 640px; margin: 0 auto 40px; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.0625rem; }
.kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 700; color: var(--brand-600); margin-bottom: 10px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr; } .grid-2 { grid-template-columns: 1fr; } }

.feature {
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 24px; box-shadow: var(--shadow);
}
.feature .ico {
    width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center;
    background: var(--brand-50); color: var(--brand-600); margin-bottom: 14px;
}
.feature h3 { margin-bottom: 6px; }
.feature p { color: var(--muted); margin: 0; font-size: .9375rem; }

.steps { counter-reset: s; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding: 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.step::before {
    counter-increment: s; content: counter(s);
    position: absolute; top: -14px; left: 24px; width: 28px; height: 28px; border-radius: 50%;
    background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 700;
}
.step h3 { margin: 6px 0 6px; font-size: 1rem; }
.step p { color: var(--muted); margin: 0; font-size: .9375rem; }

/* ---------- Pricing ---------- */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
@media (max-width: 980px) { .price-grid { grid-template-columns: 1fr; } }
.price {
    background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 26px;
    display: flex; flex-direction: column; box-shadow: var(--shadow); position: relative;
}
.price.pop { border: 2px solid var(--brand); box-shadow: 0 24px 48px -24px rgba(79, 70, 229, .45); }
.price .tag {
    position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
    background: var(--brand); color: #fff; font-size: .6875rem; font-weight: 700;
    padding: 4px 10px; border-radius: 999px; letter-spacing: .04em; text-transform: uppercase;
}
.price h3 { font-size: 1.0625rem; margin-bottom: 2px; }
.price .tagline { color: var(--muted); font-size: .875rem; min-height: 2.6em; }
.price .amount { font-size: 2rem; font-weight: 800; letter-spacing: -.03em; margin: 12px 0 2px; }
.price .amount small { font-size: .8125rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.price ul { list-style: none; padding: 0; margin: 18px 0 24px; display: grid; gap: 9px; font-size: .9375rem; color: var(--ink-2); }
.price ul li { display: flex; gap: 9px; align-items: flex-start; }
.price ul li::before { content: "✓"; color: var(--ok); font-weight: 800; flex: 0 0 auto; }
.price .btn { margin-top: auto; }
.price .yearly { font-size: .8125rem; color: var(--muted); margin-top: 10px; text-align: center; }

/* ---------- FAQ ---------- */
.faq { max-width: 780px; margin: 0 auto; display: grid; gap: 10px; }
details.q { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; }
details.q summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
details.q summary::-webkit-details-marker { display: none; }
details.q summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 1.25rem; line-height: 1; }
details.q[open] summary::after { content: "–"; }
details.q p { margin: 12px 0 0; color: var(--muted); font-size: .9375rem; }

/* ---------- CTA ---------- */
.cta {
    background: linear-gradient(135deg, #1e1b4b, #312e81 45%, #4f46e5);
    color: #fff; border-radius: 22px; padding: 48px; text-align: center; position: relative; overflow: hidden;
}
.cta::after {
    content: ""; position: absolute; inset: auto -10% -60% -10%; height: 240px;
    background: radial-gradient(closest-side, rgba(255,255,255,.18), transparent);
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, .78); max-width: 34em; margin: 0 auto 24px; }
.cta .btn-primary { background: #fff; color: var(--brand-600); box-shadow: none; }

/* ---------- Footer ---------- */
footer.site { border-top: 1px solid var(--line); background: #fff; padding: 40px 0 32px; margin-top: 40px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 24px; }
@media (max-width: 800px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
.foot-grid h4 { font-size: .8125rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-bottom: 12px; }
.foot-grid a { display: block; color: var(--ink-2); font-size: .9375rem; padding: 3px 0; }
.foot-bottom { border-top: 1px solid var(--line); margin-top: 32px; padding-top: 20px; color: var(--muted); font-size: .8125rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- Forms ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 24px; }
.auth-wrap { min-height: calc(100vh - 64px); display: grid; place-items: center; padding: 40px 20px; }
.auth-card { width: 100%; max-width: 440px; padding: 32px; }
.auth-card.wide { max-width: 720px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: .875rem; font-weight: 600; margin-bottom: 6px; color: var(--ink-2); }
.field .hint { font-size: .8125rem; color: var(--muted); margin-top: 5px; }
.input, select.input, textarea.input {
    width: 100%; padding: 11px 13px; border: 1px solid #cbd5e1; border-radius: 10px;
    font: inherit; font-size: .9375rem; color: var(--ink); background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(79, 70, 229, .14); }
.input-group { display: flex; align-items: stretch; }
.input-group .input { border-radius: 10px 0 0 10px; }
.input-group .suffix {
    display: flex; align-items: center; padding: 0 13px; background: #f1f5f9;
    border: 1px solid #cbd5e1; border-left: 0; border-radius: 0 10px 10px 0; color: var(--muted); font-size: .875rem;
}
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .875rem; color: var(--ink-2); }
.check input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--brand); }
.alert { padding: 12px 14px; border-radius: 10px; font-size: .875rem; margin-bottom: 18px; border: 1px solid transparent; }
.alert-bad { background: var(--bad-bg); color: #991b1b; border-color: #fecaca; }
.alert-ok { background: var(--ok-bg); color: #065f46; border-color: #a7f3d0; }
.alert-warn { background: var(--warn-bg); color: #92400e; border-color: #fde68a; }

/* ---------- Tables / badges ---------- */
.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--line); background: #fff; }
table.tbl { width: 100%; border-collapse: collapse; font-size: .875rem; }
table.tbl th { text-align: left; padding: 11px 14px; background: #f8fafc; color: var(--muted); font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; border-bottom: 1px solid var(--line); }
table.tbl td { padding: 12px 14px; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
table.tbl tr:last-child td { border-bottom: 0; }
table.tbl tr:hover td { background: #fcfdff; }
.badge { display: inline-flex; align-items: center; padding: 3px 9px; border-radius: 999px; font-size: .75rem; font-weight: 600; white-space: nowrap; }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-bad { background: var(--bad-bg); color: var(--bad); }
.badge-info { background: var(--brand-50); color: var(--brand-600); }
.badge-muted { background: #f1f5f9; color: var(--muted); }

/* ---------- Akun ---------- */
.store-card { padding: 20px; display: grid; gap: 12px; }
.store-card .name { font-weight: 700; font-size: 1.0625rem; }
.kv { display: grid; grid-template-columns: 110px 1fr; gap: 6px 12px; font-size: .875rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 500; }

@media (max-width: 560px) {
    .auth-card { padding: 24px; }
    section { padding: 44px 0; }
    .cta { padding: 32px 20px; }
}

/* ---------- Cetak tagihan ---------- */
@media print {
    .nav, footer.site, .no-print { display: none !important; }
    body { background: #fff; }
    .card { box-shadow: none; border: 0; }
}

/* ---------- Simulasi kasir di landing ---------- */
.sim { display: grid; grid-template-columns: 1.15fr .85fr; gap: 20px; max-width: 920px; margin: 0 auto; }
.sim-left, .sim-cart { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.sim-cart { display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow); }
.sim-label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin-bottom: 10px; }
.sim-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.sim-prod {
    display: flex; flex-direction: column; gap: 4px; text-align: left; cursor: pointer;
    padding: 12px; border-radius: 12px; border: 1px solid var(--line); background: #fff;
    font: inherit; transition: border-color .12s, box-shadow .12s, transform .06s;
}
.sim-prod:hover { border-color: var(--brand); box-shadow: 0 6px 16px -10px rgba(79,70,229,.5); }
.sim-prod:active { transform: translateY(1px); }
.sim-prod span { font-size: 12.5px; color: var(--ink-2); }
.sim-prod b { font-size: 13.5px; letter-spacing: -.01em; }
.sim-cart-head { display: flex; align-items: center; justify-content: space-between; font-weight: 700; font-size: 14px; }
.sim-badge { background: var(--brand-50); color: var(--brand-600); border-radius: 999px; padding: 2px 9px; font-size: 11px; font-weight: 700; }
.sim-rows { min-height: 118px; display: flex; flex-direction: column; gap: 6px; }
.sim-row { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; border-bottom: 1px dashed var(--line); padding-bottom: 5px; }
.sim-empty { color: var(--muted); font-size: 13px; }
.sim-total { display: flex; justify-content: space-between; align-items: center; border-top: 2px solid var(--line); padding-top: 10px; font-size: 15px; }
.sim-pay { display: flex; flex-direction: column; gap: 8px; }
.sim-cash { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--muted); }
.sim-receipt { background: #f8fafc; border: 1px dashed var(--line); border-radius: 10px; padding: 12px; font-size: 12.5px; }
.sim-receipt-head { font-weight: 800; text-align: center; margin-bottom: 8px; letter-spacing: .06em; text-transform: uppercase; font-size: 10.5px; color: var(--muted); }
.sim-receipt-row { display: flex; justify-content: space-between; padding: 2px 0; }
.sim-receipt-foot { margin-top: 8px; border-top: 1px dashed var(--line); padding-top: 8px; text-align: center; color: var(--muted); font-size: 11.5px; line-height: 1.5; }
@media (max-width: 860px) {
    .sim { grid-template-columns: 1fr; }
    .sim-grid { grid-template-columns: repeat(2, 1fr); }
}
