/* ═══════════════════════════════════════════════════════════════════════════
   LUMEN PRO — public_html v3 overrides
   Loaded AFTER app.css. Re-skins existing class names (.bottom-nav,
   .input-field, .btn-neon, .card, .package-card, .gradient-text, .topbar,
   .bottom-sheet, .toast, .spinner, .otp-input, .lang-option) so the legacy
   PHP markup picks up the Lumen Pro visual language with zero markup change.
   ═══════════════════════════════════════════════════════════════════════════ */

/* Re-bind the legacy --accent-glow, --gradient-main, --gradient-alt to the
   new palette so anything that already references them inherits the new look. */
:root {
    --accent-glow:     rgba(124, 58, 237, 0.22);
    --gradient-main:   linear-gradient(135deg, #7C3AED 0%, #EC4899 60%, #F59E0B 100%);
    --gradient-alt:    linear-gradient(135deg, #6366F1 0%, #7C3AED 100%);
}
html[data-theme="dark"] {
    --accent-glow:     rgba(196, 181, 253, 0.42);
}

/* ─── Body + typography ──────────────────────────────────────────────────── */
body {
    font-family: var(--font-body, 'Inter', system-ui, sans-serif);
    background: var(--bg-primary);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 { font-family: var(--font-display, 'Cabinet Grotesk', 'Outfit', system-ui, sans-serif); letter-spacing: -0.02em; }

/* Brand logo / gradient text — inherit Lumen gradient */
.gradient-text {
    background: var(--gradient-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

/* ─── Top bar — translucent glass with Lumen tokens ──────────────────────── */
#topBar, .topbar {
    background: color-mix(in oklch, var(--bg-primary) 82%, transparent) !important;
    backdrop-filter: blur(16px) saturate(160%);
    -webkit-backdrop-filter: blur(16px) saturate(160%);
    border-bottom: 1px solid var(--border) !important;
    height: var(--topbar-h, 56px);
}
#topBar a.no-underline,
#topBar .logo {
    display: inline-flex; align-items: center; gap: 8px;
    text-decoration: none;
    font-family: var(--font-display); font-weight: 800;
    font-size: 17px; letter-spacing: -0.02em; color: var(--text-primary);
}
/* Logo mark is rendered by markup as <span class="logo-mark">R</span> — do NOT
   add a ::before pseudo here, otherwise the brand renders TWO R icons. */
#topBar #themeToggleBtn {
    background: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    width: 36px; height: 36px;
    border-radius: 12px;
}

/* ─── Bottom navigation — Lumen blur + accent indicator ──────────────────── */
.bottom-nav {
    height: calc(var(--bottom-nav-h, 68px) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    background: rgba(255, 255, 255, 0.86);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-top: 1px solid var(--border);
}
html[data-theme="dark"] .bottom-nav { background: rgba(20, 19, 46, 0.86); }

.bottom-nav a, .bottom-nav button {
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    color: var(--text-muted);
    font-size: 10px; font-weight: 600;
    padding: 8px 12px; flex: 1;
    transition: color var(--dur, 220ms) var(--ease, cubic-bezier(0.4, 0, 0.2, 1));
}
.bottom-nav a.active, .bottom-nav button.active { color: var(--accent); }
.bottom-nav a svg, .bottom-nav button svg { width: 22px; height: 22px; stroke-width: 1.7; }

/* Cart badge — Lumen pink */
.bottom-nav .cart-badge {
    background: var(--pink) !important;
    box-shadow: 0 4px 12px var(--pink-glow);
}

/* ─── Buttons — Lumen primary/ghost/secondary ────────────────────────────── */
.btn-neon {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 22px;
    border-radius: var(--radius);
    background: var(--gradient-cta);
    color: #fff;
    font-family: var(--font-body); font-weight: 700; font-size: var(--fs-base, 14px);
    letter-spacing: -0.01em;
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
    box-shadow: var(--shadow-cta);
    width: 100%;
    border: none; cursor: pointer;
    white-space: nowrap;
}
.btn-neon:hover:not(:disabled):not([disabled]) {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(124,58,237,0.4), 0 16px 48px rgba(236,72,153,0.22);
}
.btn-neon:active:not(:disabled):not([disabled]) { transform: translateY(1px); }
.btn-neon:disabled, .btn-neon[disabled] {
    opacity: 0.55; cursor: not-allowed;
    transform: none !important; box-shadow: none !important;
}

.btn-ghost {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 20px;
    border-radius: var(--radius);
    background: var(--bg-card);
    color: var(--text-primary);
    font-weight: 600; font-size: var(--fs-base, 14px);
    border: 1px solid var(--border);
    transition: background var(--dur) var(--ease);
    width: 100%; cursor: pointer;
}
.btn-ghost:hover { background: var(--bg-card-hover); }

/* ─── Input field — Lumen glass-input ────────────────────────────────────── */
.input-field, input[type="text"].input-field, input[type="email"].input-field, input[type="number"].input-field, input[type="tel"].input-field, input[type="password"].input-field {
    width: 100%;
    padding: 14px 16px;
    border-radius: var(--radius);
    background: var(--bg-input);
    border: 1.5px solid var(--border);
    font-size: var(--fs-md, 16px);
    font-family: var(--font-body);
    color: var(--text-primary);
    outline: none;
    transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.input-field:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
}
.input-field::placeholder { color: var(--text-muted); }

.input-label {
    display: block;
    font-size: var(--fs-xs, 11px); font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.08em;
    margin-bottom: 8px;
}

/* OTP digit boxes */
.otp-input {
    width: 48px; height: 56px;
    text-align: center;
    font-family: var(--font-mono); font-variant-numeric: tabular-nums;
    font-size: 22px; font-weight: 800;
    border-radius: var(--radius);
    background: var(--bg-input);
    border: 1.5px solid var(--border);
    color: var(--text-primary);
    outline: none;
    transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.otp-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
}

/* ─── Cards (.card, .package-card) ───────────────────────────────────────── */
.card {
    background: var(--bg-card) !important;
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.card:hover { box-shadow: var(--shadow-md); }

.package-card {
    background: var(--bg-card) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-lg);
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.package-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-glow) !important;
}
.package-card.selected {
    border-color: var(--accent) !important;
    background: color-mix(in oklch, var(--accent) 8%, var(--bg-card)) !important;
    box-shadow: var(--shadow-glow) !important;
}

/* ─── Bottom sheet — Lumen elevation ─────────────────────────────────────── */
.bottom-sheet {
    background: var(--bg-card) !important;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    box-shadow: var(--shadow-xl);
    border-top: 1px solid var(--border);
}
.bottom-sheet-handle {
    background: var(--border-strong) !important;
    border-radius: var(--radius-full);
    width: 38px; height: 4px;
}

.lang-option {
    display: flex; align-items: center; gap: 12px;
    padding: 14px 16px;
    border-radius: var(--radius);
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-primary);
    transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
    cursor: pointer; text-decoration: none;
}
.lang-option:hover { background: var(--bg-card-hover); }
.lang-option.active {
    border-color: var(--accent);
    background: color-mix(in oklch, var(--accent) 6%, var(--bg-card));
}
.lang-option .flag {
    width: 32px; height: 32px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--bg-input); border-radius: 10px;
    font-size: 20px;
}

/* ─── Toast ──────────────────────────────────────────────────────────────── */
.toast {
    position: fixed;
    bottom: calc(var(--bottom-nav-h, 68px) + 16px + var(--safe-bottom));
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    padding: 12px 20px;
    border-radius: var(--radius);
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-size: 13px; font-weight: 600;
    box-shadow: var(--shadow-md);
    opacity: 0;
    transition: all var(--dur) var(--ease);
    pointer-events: none; z-index: 100;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.toast-success, .toast-success { border-left: 4px solid var(--success); }
.toast.toast-error,   .toast-error   { border-left: 4px solid var(--danger); }
.toast.toast-info,    .toast-info    { border-left: 4px solid var(--info); }

/* ─── Spinner ────────────────────────────────────────────────────────────── */
.spinner {
    width: 18px; height: 18px;
    border: 2px solid var(--accent-glow);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: lp-spin 0.7s linear infinite;
    display: inline-block;
}
.spinner.spinner-sm { width: 14px; height: 14px; border-width: 2px; }
.spinner.spinner-lg { width: 28px; height: 28px; border-width: 3px; }
@keyframes lp-spin { to { transform: rotate(360deg); } }

/* ─── Step indicator (used by checkout 4-step flow) ──────────────────────── */
.step-indicator, .checkout-steps {
    display: flex; align-items: center; gap: 6px;
    padding: 14px 0;
}
.step-dot {
    width: 24px; height: 24px;
    border-radius: 50%;
    background: var(--bg-input);
    color: var(--text-muted);
    font-family: var(--font-mono); font-variant-numeric: tabular-nums;
    font-size: 11px; font-weight: 800;
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.step-dot.done, .step-dot.current {
    background: var(--gradient-cta); color: #fff;
}
.step-line {
    flex: 1; height: 2px;
    background: var(--border);
    border-radius: 1px;
}
.step-line.done { background: var(--accent); }

/* ─── Pill / chip helpers ────────────────────────────────────────────────── */
.lp-pill {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 11px; border-radius: var(--radius-full);
    font-size: var(--fs-xs, 11px); font-weight: 700;
    background: var(--bg-card); border: 1px solid var(--border);
    color: var(--text-secondary);
}
.lp-pill--success { background: var(--success-bg); color: var(--success); border-color: transparent; }
.lp-pill--accent  { background: var(--accent-glow); color: var(--accent); border-color: transparent; }
.lp-pill--warm    { background: var(--amber-glow); color: var(--amber); border-color: transparent; }

/* ─── Hero / aurora reusable backgrounds ─────────────────────────────────── */
.lp-hero {
    position: relative; isolation: isolate; overflow: hidden;
    padding: 28px 22px;
    border-radius: var(--radius-xl);
    background: var(--bg-card);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}
.lp-hero::before {
    content:''; position:absolute; inset: -2px;
    background: var(--gradient-mesh);
    z-index: -1;
}
.lp-hero--gradient {
    background: var(--gradient-cta);
    color: #fff;
    box-shadow: var(--shadow-cta);
    border: none;
}
.lp-hero--gradient::before {
    background:
        radial-gradient(circle at 20% 20%, rgba(255,255,255,0.18) 0%, transparent 55%),
        radial-gradient(circle at 80% 80%, rgba(0,0,0,0.18) 0%, transparent 55%);
}

.lp-aurora {
    position: absolute; inset: 0; pointer-events: none; z-index: 0;
    background: var(--gradient-mesh);
    border-radius: inherit;
}

/* ─── Typography utilities echoing Lumen ─────────────────────────────────── */
.lp-eyebrow {
    font-family: var(--font-body); font-weight: 800;
    font-size: 11px; text-transform: uppercase;
    letter-spacing: 0.14em; color: var(--text-muted);
    display: inline-block;
}
.lp-grad-text {
    background: var(--gradient-main);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ─── Service tile (used on home + free-tools) ───────────────────────────── */
.lp-service-tile {
    display: flex; align-items: center; gap: 14px;
    padding: 18px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    cursor: pointer; text-decoration: none;
    color: inherit;
    width: 100%;
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.lp-service-tile:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.lp-service-tile .lp-service-icon {
    width: 48px; height: 48px; border-radius: 14px;
    background: var(--accent-glow); color: var(--accent);
    display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.lp-service-tile .lp-service-icon svg { width: 24px; height: 24px; }
.lp-service-tile .lp-service-body { flex: 1; min-width: 0; }
.lp-service-tile .lp-service-title { font-weight: 700; font-size: 15px; color: var(--text-primary); }
.lp-service-tile .lp-service-desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.lp-service-tile .lp-service-price { text-align: right; flex-shrink: 0; }
.lp-service-tile .lp-service-price-from { font-size: 10px; color: var(--text-muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; }
.lp-service-tile .lp-service-price-num { font-family: var(--font-mono); font-weight: 800; font-size: 16px; color: var(--text-primary); }

/* ─── Live ticker pill ───────────────────────────────────────────────────── */
.lp-ticker {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 12px 7px 9px;
    border-radius: var(--radius-full);
    background: var(--bg-card); border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    font-size: 12px; font-weight: 600; color: var(--text-secondary);
}
.lp-ticker .lp-ticker-dot {
    width: 22px; height: 22px; border-radius: 50%;
    background: var(--gradient-cta);
    flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 800; font-size: 10px;
}

/* ─── Result / order cards (orders.php, checkout summary) ────────────────── */
.lp-summary {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 18px;
    box-shadow: var(--shadow-sm);
}
.lp-summary .lp-summary-row {
    display: flex; justify-content: space-between;
    font-size: 13px;
    padding: 6px 0;
}
.lp-summary .lp-summary-row.lp-total {
    margin-top: 8px; padding-top: 12px;
    border-top: 1px dashed var(--border);
    font-weight: 800; font-size: 16px;
}
.lp-summary .lp-summary-row .lp-num {
    font-family: var(--font-mono); font-variant-numeric: tabular-nums;
}

/* ─── Architect score ring ───────────────────────────────────────────────── */
.lp-score {
    position: relative; width: 140px; height: 140px;
    margin: 0 auto;
}
.lp-score .lp-score-num {
    position: absolute; inset: 0;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    font-family: var(--font-display); font-variant-numeric: tabular-nums;
    font-size: 42px; font-weight: 900; line-height: 1;
}
.lp-score .lp-score-lbl {
    font-size: 10px; font-weight: 800; color: var(--text-muted);
    text-transform: uppercase; letter-spacing: 0.08em;
    margin-top: 4px;
}

/* ─── Bento grid helpers ─────────────────────────────────────────────────── */
.lp-bento { display: grid; gap: 16px; }
.lp-bento-2 { grid-template-columns: 1fr 1fr; }
.lp-bento-3 { grid-template-columns: repeat(3, 1fr); }
.lp-bento-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 720px) {
    .lp-bento-3, .lp-bento-4 { grid-template-columns: 1fr 1fr; }
}

/* ─── Sticky footer CTA (mobile checkout / package) ──────────────────────── */
.lp-sticky-cta {
    position: fixed; bottom: var(--bottom-nav-h, 68px); left: 0; right: 0;
    padding: 14px 16px calc(14px + var(--safe-bottom));
    background: color-mix(in oklch, var(--bg-primary) 92%, transparent);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    border-top: 1px solid var(--border);
    z-index: 30;
}

/* ─── Page-content padding to leave room for bottom-nav ──────────────────── */
.page-content { padding-bottom: calc(var(--bottom-nav-h, 68px) + var(--safe-bottom) + 24px); }

/* ─── Containers ─────────────────────────────────────────────────────────── */
.lp-container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 720px) { .lp-container { padding: 0 16px; } }

/* ─── Misc light/dark touch-ups for legacy markup ────────────────────────── */
.text-accent { color: var(--accent) !important; }
.text-violet-400, .text-violet-500 { color: var(--accent-light) !important; }
.text-pink-400, .text-pink-500 { color: var(--pink) !important; }
.text-amber-400, .text-amber-500 { color: var(--amber) !important; }
.text-emerald-400, .text-emerald-500, .text-green-400, .text-green-500 { color: var(--success) !important; }
.text-red-400, .text-red-500 { color: var(--danger) !important; }
.text-blue-400, .text-blue-500 { color: var(--info) !important; }

.bg-violet-500\/15, .bg-violet-500\/20, .bg-violet-500\/10 { background: var(--accent-glow) !important; }
.bg-pink-500\/15, .bg-pink-500\/20 { background: var(--pink-glow) !important; }
.bg-amber-500\/15, .bg-amber-500\/20 { background: var(--amber-glow) !important; }

/* ─── Auth-gate icon / lock chrome ───────────────────────────────────────── */
.bottom-sheet svg { color: inherit; }
