/* ================================================================
   SAVVYSAVE — GLOBAL DESIGN SYSTEM
   Konsep: "Dubbing Deck" — panel perangkat rekam analog.
   Palet gelap chassis walnut, aksen REC oranye-merah, label krem,
   highlight kuningan. Tipografi bergaya panel alat + label kaset.
================================================================ */

:root {
    --bg: #17140f;
    --bg-alt: #1b1811;
    --panel: #221e16;
    --panel-2: #1a160f;
    --line: #37301f;
    --line-soft: rgba(236,224,196,0.09);
    --cream: #ece0c4;
    --white: #f4eedc;
    --muted: #a89c7c;
    --muted-2: #6d6450;
    --rec: #e2492a;
    --rec-dark: #a3331b;
    --rec-dim: rgba(226,73,42,0.14);
    --rec-glow: rgba(226,73,42,0.45);
    --brass: #c9a24b;
    --brass-dim: rgba(201,162,75,0.15);
    --teal: #3f7d70;
    --teal-dim: rgba(63,125,112,0.16);

    --r-xl: 20px;
    --r-lg: 15px;
    --r-md: 10px;
    --r-sm: 7px;

    --font-display: 'Big Shoulders Display', 'Rajdhani', sans-serif;
    --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;

    --nav-h: 74px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--white);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    padding-top: var(--nav-h);
}

/* brushed-panel texture + warm chassis vignette */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image: repeating-linear-gradient(
        180deg,
        rgba(255,247,224,0.018) 0px,
        rgba(255,247,224,0.018) 1px,
        transparent 1px,
        transparent 3px
    );
    mask-image: radial-gradient(ellipse 75% 65% at 50% 0%, #000 25%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 0%, #000 25%, transparent 80%);
}
body::after {
    content: '';
    position: fixed;
    top: -32%;
    left: 50%;
    transform: translateX(-50%);
    width: 900px;
    height: 640px;
    background: radial-gradient(closest-side, var(--rec-dim), transparent 72%);
    z-index: 0;
    pointer-events: none;
    opacity: 0.8;
}

a { text-decoration: none; color: inherit; }

:focus-visible { outline: 2px solid var(--rec); outline-offset: 3px; border-radius: 4px; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--panel-2); }
::-webkit-scrollbar-thumb { background: var(--rec-dark); border-radius: 10px; }

.wrap {
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px 60px;
    position: relative;
    z-index: 1;
}

@keyframes riseIn {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spinRev { to { transform: rotate(-360deg); } }
@keyframes pulseDot {
    0% { box-shadow: 0 0 0 0 var(--rec-glow); }
    70% { box-shadow: 0 0 0 8px rgba(226,73,42,0); }
    100% { box-shadow: 0 0 0 0 rgba(226,73,42,0); }
}
@keyframes vuIdle {
    0%, 100% { transform: scaleY(0.3); }
    50% { transform: scaleY(0.85); }
}

/* ================================================================
   NAVBAR — deck fascia strip
================================================================ */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--nav-h);
    z-index: 100;
    background: rgba(23,20,15,0.78);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line-soft);
}
.navbar-inner {
    max-width: 1040px;
    margin: 0 auto;
    height: 100%;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}
.nav-brand { display: flex; align-items: center; gap: 12px; }
.nav-logo {
    width: 38px; height: 38px;
    border-radius: 8px;
    background: linear-gradient(155deg, #241f16, #14110c);
    border: 1px solid rgba(226,73,42,0.4);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    position: relative;
    box-shadow: inset 0 0 0 1px rgba(255,247,224,0.04);
}
.nav-logo::before {
    content: '';
    position: absolute; top: 5px; right: 5px;
    width: 5px; height: 5px; border-radius: 50%;
    background: var(--rec);
    animation: pulseDot 2.2s infinite;
}
.nav-logo i {
    font-size: 16px;
    background: linear-gradient(135deg, var(--cream), var(--rec));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.nav-brand .name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 20px;
    letter-spacing: 0.2px;
    text-transform: uppercase;
}
.nav-brand .name span { color: var(--rec); }

.nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
}
.nav-links a {
    position: relative;
    font-size: 13px;
    font-weight: 600;
    color: var(--muted);
    padding: 9px 15px;
    border-radius: var(--r-sm);
    transition: color 0.25s, background 0.25s;
    letter-spacing: 0.1px;
}
.nav-links a:hover { color: var(--cream); background: rgba(255,247,224,0.04); }
.nav-links a.active { color: var(--cream); background: var(--rec-dim); }
.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: 2px; left: 50%; transform: translateX(-50%);
    width: 14px; height: 2px;
    background: var(--rec);
    border-radius: 2px;
}
.nav-cta {
    display: flex; align-items: center; gap: 10px;
}
.nav-status {
    display: none;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    color: var(--muted-2);
    font-family: var(--font-mono);
    padding: 7px 12px;
    border: 1px solid var(--line);
    border-radius: var(--r-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.nav-status .dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--rec);
    animation: pulseDot 2s infinite;
}
.nav-burger {
    display: none;
    width: 38px; height: 38px;
    border-radius: var(--r-sm);
    border: 1px solid var(--line);
    background: transparent;
    color: var(--cream);
    align-items: center; justify-content: center;
    cursor: pointer;
    font-size: 16px;
}

@media (min-width: 860px) { .nav-status { display: flex; } }

@media (max-width: 780px) {
    .nav-links {
        position: fixed;
        top: var(--nav-h); left: 0; right: 0;
        background: rgba(20,17,12,0.98);
        border-bottom: 1px solid var(--line-soft);
        flex-direction: column;
        align-items: stretch;
        padding: 10px 16px 16px;
        gap: 4px;
        transform: translateY(-12px);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.28s ease, opacity 0.28s ease;
    }
    .nav-links.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
    .nav-links a { padding: 13px 14px; border-radius: var(--r-sm); }
    .nav-burger { display: flex; }
}

/* ================================================================
   BUTTONS
================================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 14px;
    padding: 14px 26px;
    border-radius: var(--r-md);
    border: none;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.25s, filter 0.2s, background 0.2s, border-color 0.2s;
}
.btn-primary {
    background: linear-gradient(135deg, var(--rec), var(--rec-dark));
    color: var(--white);
    box-shadow: 0 6px 24px rgba(163,51,27,0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 30px rgba(163,51,27,0.45); filter: brightness(1.06); }
.btn-primary:active { transform: scale(0.97); }
.btn-ghost {
    background: transparent;
    border: 1px solid var(--line);
    color: var(--cream);
}
.btn-ghost:hover { border-color: var(--rec); background: var(--rec-dim); }

/* ================================================================
   PANEL — deck fascia card w/ rivets
================================================================ */
.ring-wrap {
    position: relative;
    border-radius: var(--r-xl);
    padding: 1.5px;
    overflow: hidden;
    box-shadow: 0 24px 55px rgba(0,0,0,0.5);
}
.ring-wrap::before {
    content: '';
    position: absolute;
    inset: -60%;
    background: conic-gradient(from 0deg, transparent 0%, var(--rec) 14%, var(--brass) 26%, transparent 42%, transparent 100%);
    animation: spin 9s linear infinite;
    opacity: 0.55;
}
.ring-wrap.is-busy::before { animation-duration: 1.6s; opacity: 0.9; }
.panel {
    position: relative;
    background: linear-gradient(165deg, var(--panel), var(--panel-2));
    border-radius: calc(var(--r-xl) - 1.5px);
}
.panel::before, .panel::after {
    content: '';
    position: absolute;
    top: 10px; width: 4px; height: 4px; border-radius: 50%;
    background: rgba(236,224,196,0.14);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.3);
}
.panel::before { left: 10px; }
.panel::after { right: 10px; }

/* ================================================================
   TOAST NOTIFICATIONS
================================================================ */
#toastContainer {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 340px;
    width: calc(100% - 40px);
}
.toast {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #1c1811;
    border: 1px solid var(--line);
    border-left: 3px solid var(--rec);
    border-radius: var(--r-md);
    padding: 14px 16px;
    box-shadow: 0 12px 28px rgba(0,0,0,0.45);
    animation: toastIn 0.35s cubic-bezier(.2,.8,.3,1) both;
    overflow: hidden;
}
.toast.out { animation: toastOut 0.3s ease forwards; }
.toast.success { border-left-color: var(--teal); }
.toast.warn { border-left-color: var(--brass); }
@keyframes toastIn { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: translateX(0); } }
@keyframes toastOut { to { opacity: 0; transform: translateX(30px); } }
.toast i.icon { color: var(--rec); font-size: 16px; margin-top: 1px; }
.toast.success i.icon { color: var(--teal); }
.toast.warn i.icon { color: var(--brass); }
.toast .msg { font-size: 13px; font-weight: 500; color: var(--cream); line-height: 1.4; }
.toast .bar {
    position: absolute; left: 0; bottom: 0; height: 2px;
    background: var(--rec);
    animation: toastBar 3.4s linear forwards;
}
@keyframes toastBar { from { width: 100%; } to { width: 0%; } }

@media (max-width: 500px) {
    #toastContainer { right: 12px; left: 12px; max-width: unset; width: auto; bottom: 12px; }
}

/* ================================================================
   FOOTER
================================================================ */
.site-footer {
    max-width: 900px;
    margin: 60px auto 0;
    padding: 26px 20px 40px;
    position: relative; z-index: 1;
}
.footer-top {
    padding-top: 26px;
    border-top: 1px solid var(--line-soft);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 18px;
}
.footer-dev { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.footer-dev .label { font-size: 12px; color: var(--muted-2); font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.5px; }
.footer-dev .name { font-family: var(--font-display); font-weight: 700; color: var(--cream); font-size: 16px; }

.footer-socials { display: flex; gap: 10px; flex-wrap: wrap; }
.footer-socials a {
    display: flex; align-items: center; gap: 7px;
    padding: 9px 16px; border-radius: var(--r-sm);
    background: rgba(255,247,224,0.02);
    border: 1px solid var(--line);
    font-size: 12.5px; font-weight: 500; color: var(--muted);
    transition: background 0.25s, border-color 0.25s, color 0.25s, transform 0.2s;
}
.footer-socials a:hover { background: var(--rec-dim); border-color: var(--rec); color: var(--cream); transform: translateY(-2px); }
.footer-socials a i { font-size: 15px; }

.footer-nav {
    display: flex; flex-wrap: wrap; gap: 8px 18px;
    font-size: 13px; color: var(--muted-2); margin-bottom: 18px;
}
.footer-nav a { color: var(--muted); transition: color 0.2s; }
.footer-nav a:hover { color: var(--rec); }

.watermark { text-align: center; font-size: 11px; color: #453d2c; letter-spacing: 0.3px; font-family: var(--font-mono); }
.watermark a { color: var(--rec); }

/* ================================================================
   PAGE HERO (shared across sub pages)
================================================================ */
.page-hero { text-align: center; padding: 44px 0 34px; position: relative; z-index: 1; }
.eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 11.5px; font-weight: 700; letter-spacing: 0.8px; text-transform: uppercase;
    color: var(--rec);
    background: var(--rec-dim);
    border: 1px solid rgba(226,73,42,0.28);
    padding: 6px 16px; border-radius: var(--r-sm); margin-bottom: 16px;
    font-family: var(--font-mono);
}
.eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--rec); animation: pulseDot 1.8s infinite; }
.page-hero h1 {
    font-family: var(--font-display);
    font-size: 38px; font-weight: 700; letter-spacing: 0.2px;
    color: var(--cream);
    line-height: 1.18;
    text-transform: uppercase;
}
.page-hero h1 .accent { color: var(--rec); }
.page-hero p { color: var(--muted); font-size: 14.5px; margin-top: 12px; max-width: 480px; margin-inline: auto; font-family: var(--font-body); }

@media (max-width: 550px) {
    .page-hero h1 { font-size: 28px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}
