/* =============================================================================
   PayAccess — application stylesheet
   Shared design system for the public site (dark) and the admin panel (light).
   No external CSS framework or icon font is required.
   ========================================================================== */

:root {
    --brand: #4f46e5;
    --brand-2: #8b5cf6;
    --brand-soft: rgba(99, 102, 241, .14);
    --radius-lg: 22px;
    --radius: 16px;
    --radius-sm: 11px;
    --ok: #10b981;
    --warn: #f59e0b;
    --bad: #ef4444;
    --info: #3b82f6;
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    --tr: .18s ease;
}

/* ---------- themes ------------------------------------------------------- */
.site-body,
.auth-body {
    --bg: #070b14;
    --surface: rgba(17, 28, 51, .74);
    --surface-solid: #101a2f;
    --surface-2: rgba(148, 163, 184, .08);
    --text: #e8eefb;
    --muted: #93a5c1;
    --line: rgba(148, 163, 184, .18);
    --input-bg: rgba(6, 12, 26, .6);
    --shadow: 0 26px 70px rgba(2, 6, 18, .55);
    --ok-text: #34d399;
    --warn-text: #fbbf24;
    --bad-text: #f87171;
    --info-text: #7dd3fc;
}

.admin-body {
    --bg: #f4f6fb;
    --surface: #ffffff;
    --surface-solid: #ffffff;
    --surface-2: #f6f8fc;
    --text: #0f172a;
    --muted: #64748b;
    --line: #e5e9f2;
    --input-bg: #ffffff;
    --shadow: 0 2px 12px rgba(15, 23, 42, .06);
    --ok-text: #047857;
    --warn-text: #b45309;
    --bad-text: #b91c1c;
    --info-text: #2563eb;
}

/* ---------- base --------------------------------------------------------- */
* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; letter-spacing: -.02em; font-weight: 700; }
h1 { font-size: clamp(2rem, 4vw, 2.9rem); }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1em; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
button { font: inherit; }
input, select, textarea { font: inherit; color: inherit; }
code { font-family: var(--mono); font-size: .88em; background: var(--surface-2); padding: 2px 6px; border-radius: 6px; }

.icon { display: inline-block; vertical-align: middle; flex: none; }
.brand-mark { border-radius: 12px; flex: none; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }
.tiny { font-size: .76rem; }
.strong { font-weight: 700; }
.mono { font-family: var(--mono); }
.center { text-align: center; }
.right { text-align: right; }
.link { color: var(--brand-2); }
.stack > * + * { margin-top: 14px; }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 22px; }

/* ---------- buttons ------------------------------------------------------ */
.btn {
    --btn-bg: var(--surface-2);
    --btn-fg: var(--text);
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 18px; border-radius: var(--radius-sm); border: 1px solid transparent;
    background: var(--btn-bg); color: var(--btn-fg); font-weight: 600; font-size: .95rem;
    cursor: pointer; transition: transform var(--tr), box-shadow var(--tr), background var(--tr), opacity var(--tr);
    text-align: center; line-height: 1.25; text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn.is-disabled { opacity: .55; cursor: not-allowed; transform: none; }

.btn--primary {
    background: linear-gradient(135deg, var(--brand) 0%, var(--brand-2) 100%);
    color: #fff;
    box-shadow: 0 12px 28px rgba(79, 70, 229, .34);
}
.btn--primary:hover { filter: brightness(1.06); box-shadow: 0 16px 34px rgba(79, 70, 229, .42); }

.site-body .btn--ghost,
.auth-body .btn--ghost {
    background: rgba(148, 163, 184, .08);
    border-color: var(--line);
    color: var(--text);
}
.admin-body .btn--ghost {
    background: #fff;
    border-color: var(--line);
    color: var(--text);
}
.btn--ghost:hover { border-color: rgba(99, 102, 241, .5); }

.btn--danger { background: rgba(239, 68, 68, .12); color: var(--bad-text); border-color: rgba(239, 68, 68, .28); }
.btn--danger:hover { background: rgba(239, 68, 68, .18); border-color: rgba(239, 68, 68, .45); }

.btn--youtube { background: #ff0033; color: #fff; box-shadow: 0 12px 26px rgba(255, 0, 51, .28); }
.btn--youtube:hover { filter: brightness(1.08); }

.btn--block { width: 100%; }
.btn--lg { padding: 15px 22px; font-size: 1rem; border-radius: 13px; }
.btn--sm { padding: 8px 13px; font-size: .85rem; border-radius: 9px; }
.btn--xs { padding: 5px 10px; font-size: .78rem; border-radius: 8px; gap: 5px; }

.icon-btn {
    display: inline-grid; place-items: center; width: 36px; height: 36px;
    border-radius: 10px; border: 1px solid var(--line); background: transparent;
    color: var(--muted); cursor: pointer; transition: var(--tr);
}
.icon-btn:hover { color: var(--text); border-color: rgba(99, 102, 241, .45); }
.icon-btn--xs { width: 24px; height: 24px; border-radius: 6px; border-color: transparent; }

/* ---------- badges, chips, avatars --------------------------------------- */
.badge {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 4px 10px; border-radius: 999px; font-size: .76rem;
    font-weight: 700; letter-spacing: .01em; border: 1px solid transparent;
}
.badge--success { background: rgba(16, 185, 129, .13); color: var(--ok-text); border-color: rgba(16, 185, 129, .25); }
.badge--pending { background: rgba(245, 158, 11, .13); color: var(--warn-text); border-color: rgba(245, 158, 11, .26); }
.badge--failed  { background: rgba(239, 68, 68, .12); color: var(--bad-text); border-color: rgba(239, 68, 68, .25); }
.badge--warning { background: rgba(245, 158, 11, .13); color: var(--warn-text); border-color: rgba(245, 158, 11, .26); }
.badge--info    { background: rgba(59, 130, 246, .13); color: var(--info-text); border-color: rgba(59, 130, 246, .25); }
.badge--muted   { background: var(--surface-2); color: var(--muted); border-color: var(--line); }

.chip {
    display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px;
    border-radius: 999px; font-size: .78rem; font-weight: 600;
    background: var(--surface-2); border: 1px solid var(--line); color: var(--muted);
}
.chip--secure { color: var(--ok-text); border-color: rgba(16, 185, 129, .3); background: rgba(16, 185, 129, .1); }
.chip--live { color: #fff; background: rgba(239, 68, 68, .82); border-color: transparent; }

.avatar {
    display: inline-grid; place-items: center; width: 38px; height: 38px;
    border-radius: 12px; font-size: .82rem; font-weight: 700; letter-spacing: .02em;
    background: linear-gradient(135deg, rgba(99, 102, 241, .9), rgba(139, 92, 246, .9));
    color: #fff; flex: none;
}
.avatar--sm { width: 32px; height: 32px; border-radius: 10px; font-size: .74rem; }
.avatar--lg { width: 54px; height: 54px; border-radius: 16px; font-size: 1.05rem; }

/* ---------- cards, alerts ------------------------------------------------ */
.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}
.card--pad { padding: 26px; }
.card__head {
    display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
    margin-bottom: 18px;
}
.card__head h2 { font-size: 1.05rem; margin: 0 0 2px; display: flex; align-items: center; gap: 8px; }
.card__head p { margin: 0; }
.card__head--pad { padding: 22px 24px 0; }

.alert {
    display: flex; align-items: flex-start; gap: 10px;
    padding: 12px 15px; border-radius: var(--radius-sm);
    font-size: .9rem; border: 1px solid var(--line);
    background: var(--surface-2);
}
.alert > span, .alert > div { flex: 1; }
.alert p { margin: 4px 0 0; }
.alert--success { background: rgba(16, 185, 129, .1); border-color: rgba(16, 185, 129, .3); color: var(--ok-text); }
.alert--danger  { background: rgba(239, 68, 68, .1); border-color: rgba(239, 68, 68, .3); color: var(--bad-text); }
.alert--warning { background: rgba(245, 158, 11, .1); border-color: rgba(245, 158, 11, .32); color: var(--warn-text); }
.alert--info    { background: rgba(59, 130, 246, .1); border-color: rgba(59, 130, 246, .3); color: var(--info-text); }
.alert--lg { align-items: center; padding: 16px 18px; }
.alert--lg strong { display: block; }
.alert--lg p { color: var(--muted); margin: 2px 0 0; font-size: .87rem; }

.flash-stack { display: grid; gap: 10px; margin-bottom: 20px; }
.site-main .flash-stack { padding-top: 18px; }
.flash-stack .alert { backdrop-filter: blur(10px); }

/* ---------- forms -------------------------------------------------------- */
.form { display: grid; gap: 16px; }
.field { display: grid; gap: 7px; align-content: start; }
.field > label { font-size: .84rem; font-weight: 600; color: var(--text); }
.field--inline { gap: 0; }
.field--full { grid-column: 1 / -1; }

.input,
.field__control input,
.field__control select,
select.input,
textarea.input {
    width: 100%; padding: 11px 14px; border-radius: var(--radius-sm);
    border: 1px solid var(--line); background: var(--input-bg); color: var(--text);
    transition: border-color var(--tr), box-shadow var(--tr);
    font-size: .94rem; min-height: 44px;
}
.input::placeholder { color: var(--muted); opacity: .75; }
.input:focus,
.field__control input:focus {
    outline: none; border-color: rgba(99, 102, 241, .7);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, .16);
}
.admin-body .input,
.admin-body .field__control input { background: #fff; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; padding-right: 34px; }

.field__control { position: relative; display: flex; align-items: center; }
.field__control > .icon { position: absolute; left: 13px; color: var(--muted); pointer-events: none; }
.field__control input { padding-left: 40px; padding-right: 40px; }
.field__reveal {
    position: absolute; right: 6px; display: grid; place-items: center;
    width: 32px; height: 32px; border: 0; border-radius: 8px;
    background: transparent; color: var(--muted); cursor: pointer;
}
.field__reveal:hover { color: var(--text); background: var(--surface-2); }
.field__error { color: var(--bad-text); font-size: .8rem; display: flex; align-items: center; gap: 5px; margin: 0; }
.hint { font-size: .78rem; color: var(--muted); margin: 0; }
.hint code { background: transparent; padding: 0; }

.form__foot { display: flex; align-items: center; gap: 7px; font-size: .78rem; color: var(--muted); margin: 0; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }

.checkbox { display: flex; align-items: flex-start; gap: 9px; font-size: .86rem; color: var(--muted); cursor: pointer; }
.checkbox input { width: 16px; height: 16px; margin-top: 2px; accent-color: var(--brand); }

.input-prefix { position: relative; display: flex; align-items: center; }
.input-prefix > span {
    position: absolute; left: 13px; color: var(--muted); font-weight: 600; pointer-events: none;
}
.input-prefix .input { padding-left: 34px; }

.color-input { display: flex; align-items: center; gap: 10px; }
.color-input input[type="color"] {
    width: 44px; height: 40px; padding: 3px; border-radius: 10px;
    border: 1px solid var(--line); background: var(--input-bg); cursor: pointer;
}

.switch { display: flex; align-items: center; gap: 11px; cursor: pointer; font-size: .88rem; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch__track {
    width: 44px; height: 25px; border-radius: 999px; background: rgba(148, 163, 184, .35);
    position: relative; transition: background var(--tr); flex: none;
}
.switch__thumb {
    position: absolute; top: 3px; left: 3px; width: 19px; height: 19px;
    border-radius: 50%; background: #fff; transition: transform var(--tr);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .3);
}
.switch input:checked + .switch__track { background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
.switch input:checked + .switch__track .switch__thumb { transform: translateX(19px); }
.switch input:focus-visible + .switch__track { box-shadow: 0 0 0 3px rgba(99, 102, 241, .3); }
.switch__label { color: var(--text); }

.copy-row { display: flex; gap: 8px; align-items: center; }
.copy-row .input { font-size: .82rem; }

/* =============================================================================
   PUBLIC SITE
   ========================================================================== */
.site-body { position: relative; min-height: 100vh; display: flex; flex-direction: column; overflow-x: hidden; }

.site-aurora {
    position: fixed; inset: -20% -10% auto -10%; height: 780px; z-index: -1;
    background:
        radial-gradient(40% 55% at 18% 20%, rgba(99, 102, 241, .34), transparent 70%),
        radial-gradient(38% 48% at 82% 8%, rgba(139, 92, 246, .3), transparent 72%),
        radial-gradient(30% 40% at 60% 60%, rgba(14, 165, 233, .16), transparent 70%);
    filter: blur(6px);
    pointer-events: none;
}

.site-header {
    position: sticky; top: 0; z-index: 40;
    backdrop-filter: blur(18px);
    background: rgba(7, 11, 20, .72);
    border-bottom: 1px solid var(--line);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; height: 70px; }

.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 700; font-size: 1.05rem; }
.brand:hover { text-decoration: none; }
.brand__logo { max-height: 40px; width: auto; object-fit: contain; }
.brand__name { letter-spacing: -.01em; }

.site-nav { display: flex; align-items: center; gap: 6px; font-size: .9rem; }
.site-nav > a {
    padding: 8px 12px; border-radius: 9px; color: var(--muted);
    display: inline-flex; align-items: center; gap: 6px; transition: var(--tr);
}
.site-nav > a:hover { color: var(--text); background: var(--surface-2); text-decoration: none; }
.site-nav__admin { border: 1px solid var(--line); }

.site-main { flex: 1; }
.site-footer { border-top: 1px solid var(--line); padding: 26px 0; margin-top: 40px; font-size: .84rem; color: var(--muted); }
.site-footer__inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.site-footer__links { display: flex; flex-wrap: wrap; gap: 16px; }
.site-footer__links a { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.site-footer__links a:hover { color: var(--text); }

/* hero */
.hero { padding: 54px 0 20px; }
.hero__grid { display: grid; grid-template-columns: 1.08fr .92fr; gap: 54px; align-items: start; }
.hero__copy { padding-top: 12px; }

.eyebrow {
    display: inline-flex; align-items: center; gap: 7px;
    font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
    color: #c4b5fd; margin-bottom: 16px;
}
.eyebrow--success { color: var(--ok-text); }

.hero__title { font-size: clamp(2.2rem, 4.6vw, 3.35rem); margin: 0 0 14px; letter-spacing: -.035em; }
.hero__title-accent {
    display: block;
    background: linear-gradient(120deg, #a5b4fc, #c4b5fd 45%, #67e8f9);
    -webkit-background-clip: text; background-clip: text; color: transparent;
    font-size: .62em;
}
.hero__lede { font-size: 1.05rem; color: var(--muted); max-width: 32em; margin-bottom: 22px; }

.hero__features { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; }
.hero__features li { display: flex; align-items: center; gap: 10px; color: #cbd5e1; font-size: .93rem; }
.hero__features .icon { color: var(--ok-text); }

.preview {
    position: relative; border-radius: var(--radius); overflow: hidden;
    border: 1px solid var(--line); box-shadow: var(--shadow); max-width: 430px;
}
.preview__img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; opacity: .55; filter: saturate(.7); }
.preview__overlay {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 12px;
    background: linear-gradient(180deg, rgba(7, 11, 20, .1), rgba(7, 11, 20, .78));
}
.preview__play {
    display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
    background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .3);
    backdrop-filter: blur(6px); color: #fff;
}
.preview__text { font-size: .8rem; color: #e2e8f0; letter-spacing: .01em; }

.hero__card { position: sticky; top: 92px; }
.paycard { padding: 26px; }
.paycard__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
.paycard__label { margin: 0; font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .09em; font-weight: 700; }
.paycard__price { margin: 4px 0 0; font-size: 2rem; font-weight: 800; letter-spacing: -.03em; }
.paycard__period { font-size: .78rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }

.trust { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; margin-top: 14px; font-size: .78rem; color: var(--muted); }
.trust span { display: inline-flex; align-items: center; gap: 6px; }

/* sections */
.section { padding: 62px 0; }
.section--muted { background: linear-gradient(180deg, rgba(148, 163, 184, .04), transparent); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section--tight { padding-top: 42px; }
.section__inner { display: grid; gap: 34px; }
.section__inner--narrow { max-width: 780px; margin: 0 auto; }
.section__head { max-width: 620px; }
.section__head h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
.section__head p { color: var(--muted); margin: 0; }

.grid { display: grid; gap: 18px; }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.feature {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 22px; backdrop-filter: blur(10px);
}
.feature__icon {
    display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px;
    background: var(--brand-soft); color: #a5b4fc; margin-bottom: 14px;
}
.feature h3 { margin-bottom: 6px; }
.feature p { margin: 0; color: var(--muted); font-size: .9rem; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: step; }
.step { position: relative; padding: 24px; border-radius: var(--radius); border: 1px dashed var(--line); background: rgba(148, 163, 184, .04); }
.step__num {
    display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
    background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff;
    font-weight: 700; font-size: .9rem; margin-bottom: 14px;
}
.step h3 { font-size: 1rem; }
.step p { margin: 0; color: var(--muted); font-size: .88rem; }

.faq {
    border: 1px solid var(--line); border-radius: var(--radius-sm);
    background: var(--surface); padding: 4px 18px; margin-bottom: 10px;
}
.faq summary {
    cursor: pointer; padding: 15px 0; font-weight: 600; font-size: .95rem;
    list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.2rem; color: var(--muted); transition: transform var(--tr); }
.faq[open] summary::after { content: "−"; }
.faq p { margin: 0 0 16px; color: var(--muted); font-size: .9rem; }
.faq a { color: #a5b4fc; text-decoration: underline; }

.cta {
    display: flex; align-items: center; justify-content: space-between; gap: 22px; flex-wrap: wrap;
    padding: 30px; border-radius: var(--radius-lg);
    background: linear-gradient(120deg, rgba(99, 102, 241, .2), rgba(139, 92, 246, .12));
    border: 1px solid rgba(139, 92, 246, .32);
}
.cta h2 { margin-bottom: 4px; }
.cta p { margin: 0; color: var(--muted); }

/* success page */
.success-wrap { display: grid; gap: 30px; max-width: 1060px; margin: 0 auto; }
.success-hero { text-align: center; max-width: 640px; margin: 0 auto; }
.success-hero__badge {
    display: grid; place-items: center; width: 74px; height: 74px; margin: 0 auto 18px;
    border-radius: 50%; color: #04120c;
    background: linear-gradient(135deg, #6ee7b7, #34d399);
    box-shadow: 0 18px 40px rgba(16, 185, 129, .35);
    animation: pop .5s ease-out;
}
@keyframes pop { 0% { transform: scale(.5); opacity: 0; } 70% { transform: scale(1.08); } 100% { transform: scale(1); opacity: 1; } }
.success-hero h1 { margin-bottom: 8px; }
.success-hero p { color: var(--muted); }

.success-grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: 20px; align-items: start; }
.video-card { display: grid; gap: 14px; }
.video-card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.video-embed { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.video-card__foot p { margin: 0; display: flex; align-items: center; gap: 7px; }

.receipt { align-self: start; }
@media (min-width: 1001px) {
    .receipt { position: sticky; top: 92px; }
}
.receipt__title { font-size: .95rem; display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.receipt__list { margin: 0; display: grid; gap: 0; }
.receipt__list > div {
    display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
    padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: .86rem;
}
.receipt__list > div:last-child { border-bottom: 0; }
.receipt__list dt { color: var(--muted); }
.receipt__list dd { margin: 0; text-align: right; word-break: break-word; }
.receipt__actions { margin-top: 16px; display: grid; gap: 10px; }
.receipt__actions p { margin: 0; }

.success-next { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.success-next__item { padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); }
.success-next__icon {
    display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px;
    background: var(--brand-soft); color: #a5b4fc; margin-bottom: 12px;
}
.success-next__item h3 { font-size: .96rem; margin-bottom: 5px; }
.success-next__item p { margin: 0; color: var(--muted); font-size: .86rem; }
.success-next__item a { color: #a5b4fc; text-decoration: underline; }

/* states (locked / error) */
.state { text-align: center; display: grid; gap: 12px; justify-items: center; padding: 44px 30px; }
.state h1 { font-size: 1.7rem; margin: 0; }
.state p { color: var(--muted); max-width: 46ch; margin: 0; }
.state__icon {
    display: grid; place-items: center; width: 74px; height: 74px; border-radius: 22px;
    background: var(--brand-soft); color: #a5b4fc; margin-bottom: 4px;
}
.state__code { font-size: 3.4rem; font-weight: 800; letter-spacing: -.05em; color: rgba(148, 163, 184, .35); line-height: 1; }
.state__actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }
.state--success .state__icon { background: rgba(16, 185, 129, .14); color: var(--ok-text); }
.state--success h2 { margin: 0; font-size: 1.15rem; }
.state--success p { font-size: .88rem; }
.state--locked .state__icon { background: rgba(245, 158, 11, .14); color: var(--warn-text); }
.state--error .state__icon { background: rgba(239, 68, 68, .13); color: var(--bad-text); }
.state--error h1 { color: var(--text); }

/* body-class hooks (site-home, site-success, site-locked, site-restore, site-demo)
   exist so individual pages can be tweaked without touching the layout. */

/* restore */
.restore-grid { display: grid; grid-template-columns: 1fr .9fr; gap: 34px; align-items: start; }
.restore-copy h1 { margin-top: 6px; }
.restore-copy p { color: var(--muted); }
.checklist { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 8px; font-size: .9rem; }
.checklist li { display: flex; align-items: center; gap: 9px; color: #cbd5e1; }
.checklist .icon { color: var(--ok-text); }

/* demo */
.demo-banner {
    display: flex; align-items: center; gap: 9px; margin-bottom: 16px;
    padding: 11px 15px; border-radius: var(--radius-sm);
    background: rgba(59, 130, 246, .1); border: 1px solid rgba(59, 130, 246, .3);
    color: var(--info-text); font-size: .86rem;
}
.demo-card { display: grid; gap: 18px; }
.demo-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.demo-card__head h1 { margin: 0; }
.demo-card__head p { margin: 0 0 2px; }
.demo-actions { display: grid; gap: 10px; }

/* =============================================================================
   ADMIN PANEL
   ========================================================================== */
.admin-body { background: var(--bg); }

.admin-shell { display: flex; min-height: 100vh; }

.sidebar {
    width: 264px; position: fixed; inset: 0 auto 0 0; z-index: 60;
    display: flex; flex-direction: column; gap: 18px;
    padding: 22px 16px; overflow-y: auto;
    background: linear-gradient(180deg, #0b1224 0%, #0a1020 100%);
    color: #cbd5e1; border-right: 1px solid rgba(148, 163, 184, .12);
}
.sidebar__brand { display: flex; align-items: center; gap: 11px; padding: 4px 8px 16px; border-bottom: 1px solid rgba(148, 163, 184, .12); }
.sidebar__logo { max-height: 36px; max-width: 44px; object-fit: contain; border-radius: 8px; background: rgba(255, 255, 255, .06); padding: 4px; }
.sidebar__brand-text { display: grid; line-height: 1.25; }
.sidebar__brand-text strong { color: #fff; font-size: .95rem; }
.sidebar__brand-text span { font-size: .72rem; color: #7c8db5; text-transform: uppercase; letter-spacing: .08em; }

.sidebar__nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.sidebar__link {
    display: flex; align-items: center; gap: 11px; padding: 10px 12px;
    border-radius: 10px; color: #9fb0d0; font-size: .9rem; transition: var(--tr);
}
.sidebar__link:hover { background: rgba(148, 163, 184, .1); color: #fff; text-decoration: none; }
.sidebar__link.is-active {
    background: linear-gradient(135deg, rgba(99, 102, 241, .28), rgba(139, 92, 246, .2));
    color: #fff; box-shadow: inset 0 0 0 1px rgba(139, 92, 246, .35);
}
.sidebar__divider {
    font-size: .68rem; text-transform: uppercase; letter-spacing: .1em;
    color: #64748b; padding: 18px 12px 6px;
}
.sidebar__foot { border-top: 1px solid rgba(148, 163, 184, .12); padding-top: 14px; display: grid; gap: 10px; }
.sidebar__user { display: flex; align-items: center; gap: 10px; padding: 0 4px 4px; }
.sidebar__user div { display: grid; line-height: 1.3; min-width: 0; }
.sidebar__user strong { color: #e2e8f0; font-size: .85rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar__user span { font-size: .74rem; color: #7c8db5; }
.sidebar__foot .btn--ghost { background: rgba(148, 163, 184, .08); border-color: rgba(148, 163, 184, .18); color: #cbd5e1; }
.sidebar__version { margin: 0; text-align: center; font-size: .68rem; color: #4b5a75; }

.admin-main { flex: 1; margin-left: 264px; display: flex; flex-direction: column; min-height: 100vh; min-width: 0; }
.admin-overlay { position: fixed; inset: 0; background: rgba(2, 6, 18, .55); z-index: 55; }

.topbar {
    position: sticky; top: 0; z-index: 30;
    display: flex; align-items: center; gap: 14px;
    padding: 14px 26px; border-bottom: 1px solid var(--line);
    background: rgba(244, 246, 251, .92); backdrop-filter: blur(12px);
}
.topbar__burger { display: none; color: var(--text); }
.topbar__titles { display: grid; line-height: 1.2; }
.topbar__eyebrow { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.topbar__titles h1 { font-size: 1.15rem; margin: 0; letter-spacing: -.01em; }
.topbar__actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.topbar__avatar {
    display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px;
    background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff;
    font-weight: 700; font-size: .78rem;
}
.topbar__avatar:hover { text-decoration: none; filter: brightness(1.05); }

.admin-content { padding: 24px 26px 30px; display: flex; flex-direction: column; gap: 20px; flex: 1; }
.admin-footer { margin-top: auto; padding-top: 18px; display: flex; justify-content: space-between; gap: 14px; font-size: .76rem; color: var(--muted); }

.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 16px; box-shadow: var(--shadow); }
.stat__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.stat__label { font-size: .78rem; color: var(--muted); font-weight: 600; }
.stat__icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; }
.stat__icon--indigo { background: rgba(99, 102, 241, .12); color: #4f46e5; }
.stat__icon--emerald { background: rgba(16, 185, 129, .12); color: #059669; }
.stat__icon--sky { background: rgba(14, 165, 233, .12); color: #0284c7; }
.stat__icon--amber { background: rgba(245, 158, 11, .14); color: #b45309; }
.stat__value { font-size: 1.65rem; font-weight: 800; margin: 12px 0 2px; letter-spacing: -.03em; }
.stat__hint { margin: 0; font-size: .76rem; color: var(--muted); }

.admin-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 16px; align-items: stretch; }
.chart-card { display: flex; flex-direction: column; }
.chart { display: flex; align-items: flex-end; gap: 8px; height: 190px; padding: 8px 0 0; }
.chart__col { flex: 1; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 7px; min-width: 0; }
.chart__bar { width: 100%; max-width: 36px; min-height: 4px; border-radius: 7px 7px 3px 3px; background: rgba(99, 102, 241, .12); transition: var(--tr); }
.chart__bar.is-filled { background: linear-gradient(180deg, #818cf8, #6366f1); box-shadow: 0 6px 14px rgba(99, 102, 241, .22); }
.chart__col:hover .chart__bar { filter: brightness(1.08); }
.chart__label { font-size: .66rem; color: var(--muted); }

.store-card { display: flex; flex-direction: column; gap: 14px; }
.store-card__logo {
    display: flex; align-items: center; gap: 12px; padding: 12px;
    border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--line);
}
.store-card__logo img { max-height: 46px; max-width: 76px; object-fit: contain; }
.store-card__logo p { margin: 0; }
.store-card__logo strong { font-size: .92rem; }
.mini-list { margin: 0; display: grid; gap: 0; }
.mini-list > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: .85rem; }
.mini-list > div:last-child { border-bottom: 0; }
.mini-list dt { color: var(--muted); }
.mini-list dd { margin: 0; }

/* tables */
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.data-table thead th {
    text-align: left; padding: 12px 16px; font-size: .74rem; text-transform: uppercase;
    letter-spacing: .06em; color: var(--muted); background: var(--surface-2);
    border-bottom: 1px solid var(--line); white-space: nowrap; font-weight: 700;
}
.data-table thead th a { color: inherit; display: inline-flex; align-items: center; gap: 6px; }
.data-table thead th a:hover { color: var(--brand); text-decoration: none; }
.data-table tbody td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table tbody tr:nth-child(even) { background: rgba(148, 163, 184, .04); }
.data-table tbody tr:hover { background: rgba(99, 102, 241, .06); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table .right, .data-table th.right { text-align: right; }
.sort-off { color: var(--line); font-size: .85em; }
.sort-on { color: var(--brand); font-weight: 700; }
.person { display: flex; align-items: center; gap: 11px; }
.person div { display: grid; line-height: 1.3; min-width: 0; }
.person strong { font-size: .88rem; }
.person .small { overflow: hidden; text-overflow: ellipsis; }

.filters { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.filters__form { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: 1; }
.filters__form .field--inline { flex: 1 1 220px; min-width: 150px; }
.filters__form .input { min-height: 40px; padding-top: 8px; padding-bottom: 8px; font-size: .86rem; }
.filters__form input[type="date"] { min-width: 130px; }
.table-meta { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 12px 18px; font-size: .82rem; color: var(--muted); border-bottom: 1px solid var(--line); }
.table-meta strong { color: var(--text); }

.empty { padding: 48px 24px; text-align: center; color: var(--muted); display: grid; justify-items: center; gap: 6px; }
.empty .icon { color: rgba(148, 163, 184, .5); margin-bottom: 4px; }
.empty h3 { margin: 0; color: var(--text); font-size: 1rem; }
.empty p { margin: 0 0 12px; font-size: .88rem; }

.pagination { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 14px 18px; border-top: 1px solid var(--line); }
.page-btn {
    display: inline-flex; align-items: center; gap: 5px; padding: 7px 11px; border-radius: 8px;
    border: 1px solid var(--line); font-size: .82rem; color: var(--muted); background: var(--surface);
}
.page-btn:hover { border-color: rgba(99, 102, 241, .45); color: var(--text); text-decoration: none; }
.page-btn.is-active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 700; }
.page-btn.is-disabled { opacity: .45; pointer-events: none; }
.pagination__meta { margin-left: auto; font-size: .78rem; color: var(--muted); }

.row-actions { display: inline-flex; gap: 6px; align-items: center; justify-content: flex-end; }
.inline-form { display: inline; margin: 0; }

/* detail pages */
.back-link { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 2px; }
.detail-hero { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 24px; flex-wrap: wrap; }
.detail-hero__main { display: flex; align-items: center; gap: 14px; }
.detail-hero__main h2 { margin: 0; font-size: 1.15rem; }
.detail-hero__main p { margin: 2px 0 0; font-size: .86rem; }
.detail-hero__side { text-align: right; display: grid; gap: 4px; justify-items: end; }
.detail-hero__amount { margin: 0; font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; }

.detail-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 16px; align-items: start; }
.detail-grid--narrow { grid-template-columns: 1.1fr .9fr; max-width: 980px; }
.detail-list { display: grid; gap: 0; margin: 0; }
.detail-list > div { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: .86rem; }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; text-align: right; word-break: break-word; max-width: 65%; }

.timeline { list-style: none; margin: 0; padding: 0 0 0 6px; display: grid; gap: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.timeline__item { position: relative; padding: 0 0 18px 32px; }
.timeline__item:last-child { padding-bottom: 0; }
.timeline__dot {
    position: absolute; left: 5px; top: 5px; width: 13px; height: 13px; border-radius: 50%;
    background: #fff; border: 3px solid var(--brand);
}
.timeline__title { margin: 0; font-weight: 600; font-size: .88rem; }
.timeline__item p { margin: 2px 0; }

/* settings */
.tabs { display: flex; gap: 6px; overflow-x: auto; padding: 5px; border-radius: 13px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); }
.tabs a { display: inline-flex; align-items: center; gap: 7px; padding: 8px 13px; border-radius: 9px; font-size: .85rem; color: var(--muted); white-space: nowrap; }
.tabs a:hover { background: var(--surface-2); color: var(--text); text-decoration: none; }

.settings-form { display: grid; gap: 16px; }
.settings-form .card { scroll-margin-top: 90px; }

.logo-upload { display: grid; grid-template-columns: 150px 1fr; gap: 18px; align-items: start; margin-bottom: 22px; }
.logo-upload__preview {
    height: 120px; border-radius: var(--radius); border: 1px dashed var(--line);
    background: var(--surface-2); display: grid; place-items: center; gap: 6px; padding: 10px; text-align: center;
}
.logo-upload__preview img { max-height: 96px; max-width: 100%; object-fit: contain; }
.logo-upload__body { display: grid; gap: 10px; }

.dropzone {
    display: grid; gap: 4px; justify-items: center; text-align: center;
    padding: 22px 18px; border-radius: var(--radius); border: 1.5px dashed rgba(99, 102, 241, .45);
    background: rgba(99, 102, 241, .05); cursor: pointer; color: var(--muted);
    transition: var(--tr);
}
.dropzone:hover, .dropzone.is-dragover { border-color: var(--brand); background: rgba(99, 102, 241, .1); }
.dropzone .icon { color: var(--brand); margin-bottom: 4px; }
.dropzone strong { color: var(--text); font-size: .92rem; }
.dropzone span { font-size: .8rem; }

.save-bar {
    position: sticky; bottom: 14px; z-index: 20;
    display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
    padding: 12px 16px; border-radius: var(--radius); border: 1px solid var(--line);
    background: rgba(255, 255, 255, .92); backdrop-filter: blur(14px);
    box-shadow: 0 12px 30px rgba(15, 23, 42, .12);
}
.save-bar > span { display: inline-flex; align-items: center; gap: 7px; }
.save-bar__actions { display: flex; gap: 8px; align-items: center; }

.video-preview { position: relative; margin-top: 8px; max-width: 320px; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--line); }
.video-preview img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.video-preview__badge {
    position: absolute; left: 10px; bottom: 10px; display: inline-flex; align-items: center; gap: 5px;
    padding: 4px 9px; border-radius: 999px; font-size: .72rem; color: #fff;
    background: rgba(2, 6, 18, .72); backdrop-filter: blur(4px);
}

/* =============================================================================
   AUTH (admin login)
   ========================================================================== */
.auth-body { min-height: 100vh; display: grid; place-items: center; padding: 28px; position: relative; overflow: hidden; }
.auth-aurora {
    position: fixed; inset: 0; z-index: -1;
    background:
        radial-gradient(45% 45% at 25% 20%, rgba(99, 102, 241, .35), transparent 70%),
        radial-gradient(40% 40% at 80% 80%, rgba(139, 92, 246, .28), transparent 70%);
}
.auth-card {
    width: 100%; max-width: 420px; padding: 34px 30px;
    border-radius: 24px; border: 1px solid var(--line);
    background: rgba(16, 26, 47, .82); backdrop-filter: blur(20px);
    box-shadow: 0 30px 80px rgba(2, 6, 18, .6);
}
.auth-brand { display: flex; align-items: center; gap: 11px; margin-bottom: 22px; font-weight: 700; }
.auth-brand__logo { max-height: 46px; max-width: 150px; object-fit: contain; }
.auth-card h1 { font-size: 1.45rem; margin-bottom: 4px; }
.auth-card > p { font-size: .88rem; margin-bottom: 20px; }
.auth-foot { margin: 22px 0 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: .82rem; }
.auth-foot a { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.auth-foot a:hover { color: var(--text); }

/* =============================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1120px) {
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .admin-grid { grid-template-columns: 1fr; }
}

@media (max-width: 1000px) {
    .hero__grid { grid-template-columns: 1fr; gap: 34px; }
    .hero__card { position: static; }
    .preview { max-width: 100%; }
    .success-grid, .restore-grid, .detail-grid, .detail-grid--narrow { grid-template-columns: 1fr; }
    .grid--3, .steps, .success-next { grid-template-columns: 1fr; }
    .form-grid { grid-template-columns: 1fr; }
    .logo-upload { grid-template-columns: 1fr; }
    .logo-upload__preview { height: 140px; }

    .sidebar { transform: translateX(-100%); transition: transform .22s ease; box-shadow: 0 20px 60px rgba(0, 0, 0, .45); }
    .sidebar.is-open { transform: translateX(0); }
    .admin-main { margin-left: 0; }
    .topbar__burger { display: inline-grid; }
    .admin-content { padding: 18px 16px 24px; }
    .topbar { padding: 12px 16px; }
}

@media (max-width: 620px) {
    .site-nav { gap: 2px; font-size: .84rem; }
    .site-nav > a { padding: 7px 8px; }
    .site-nav > a:not(.site-nav__admin) span { display: none; }
    .site-nav__admin span { display: none; }
    .brand__name { display: none; }
    .hero { padding-top: 34px; }
    .section { padding: 44px 0; }
    .card--pad, .paycard { padding: 20px; }
    .success-hero__badge { width: 62px; height: 62px; }
    .stat-grid { grid-template-columns: 1fr; }
    .filters__form .field--inline { flex: 1 1 100%; }
    .filters { padding: 14px; }
    .table-meta { padding: 10px 14px; }
    .save-bar { position: static; }
    .detail-hero { align-items: flex-start; }
    .detail-hero__side { text-align: left; justify-items: start; }
    .data-table thead th, .data-table tbody td { padding: 10px 12px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* Print: receipts / payment detail */
@media print {
    .site-header, .site-footer, .sidebar, .topbar, .save-bar, .filters, .pagination, .btn, .icon-btn { display: none !important; }
    .admin-main { margin: 0; }
    body { background: #fff; color: #000; }
    .card { box-shadow: none; border-color: #ddd; background: #fff; }
}
