/**
 * Product Studio (/projects)
 *
 * Built on the house design spec in night-life-design-framework.md: a navy
 * canvas, teal as the structural accent, gold as the action colour, white for
 * headings and cream for body text, glass cards, pill buttons and an 80px
 * section rhythm. Every colour lives in the tokens below; nothing else in this
 * file hard-codes one.
 */

:root {
    --studio-navy: #081226;
    --studio-navy-raised: #0d1b33;
    --studio-cream: #f2e9db;
    --studio-teal: #27d1b6;
    --studio-gold: #ffba49;
    --studio-white: #ffffff;

    --studio-glass: rgba(255, 255, 255, 0.05);
    --studio-glass-strong: rgba(255, 255, 255, 0.08);
    --studio-glass-border: rgba(255, 255, 255, 0.1);
    --studio-teal-soft: rgba(39, 209, 182, 0.12);
    --studio-gold-soft: rgba(255, 186, 73, 0.14);

    --studio-radius-card: 20px;
    --studio-radius-pill: 50px;
    --studio-section-y: 80px;
    --studio-font: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---------------------------------------------------------------- Canvas */

body.studio-body {
    background: var(--studio-navy);
    color: var(--studio-cream);
    font-family: var(--studio-font);
    min-height: 100vh;
    position: relative;
}

body.studio-body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: radial-gradient(60vw 60vw at 30% -10%, var(--studio-teal-soft), transparent 70%);
}

.studio-skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--studio-gold);
    color: var(--studio-navy);
    padding: 0.6rem 1rem;
    border-radius: 0 0 0.5rem 0;
    font-weight: 700;
    z-index: 1080;
}

.studio-skip-link:focus {
    left: 0;
}

.studio-section { padding: var(--studio-section-y) 0; }
.studio-section--tight { padding: calc(var(--studio-section-y) / 2) 0; }
.studio-band { background: rgba(0, 0, 0, 0.15); }

/* ------------------------------------------------------------ Typography */

.studio-eyebrow {
    display: block;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--studio-teal);
    margin-bottom: 0.5rem;
}

.studio-h1 {
    color: var(--studio-white);
    font-weight: 700;
    font-size: clamp(2.25rem, 4.5vw + 1rem, 4rem);
    line-height: 1.08;
    margin-bottom: 1rem;
}

.studio-h2 {
    color: var(--studio-gold);
    font-weight: 700;
    font-size: clamp(1.5rem, 1.5vw + 1rem, 2rem);
    margin-bottom: 0.75rem;
}

.studio-h3 {
    color: var(--studio-white);
    font-weight: 700;
    font-size: 1.35rem;
    margin-bottom: 0.5rem;
}

.studio-lead {
    font-size: 1.1rem;
    color: var(--studio-cream);
    max-width: 44rem;
}

.studio-body-text { color: var(--studio-cream); }
.studio-muted { color: rgba(242, 233, 219, 0.7); }

.studio-neon-teal {
    color: var(--studio-teal);
    font-style: italic;
    text-shadow: 0 0 10px rgba(39, 209, 182, 0.5), 0 0 20px rgba(39, 209, 182, 0.3);
}

a.studio-link { color: var(--studio-teal); text-decoration: none; }
a.studio-link:hover { color: var(--studio-gold); text-decoration: underline; }

/* --------------------------------------------------------------- Buttons */

.studio-btn-gold,
.studio-btn-ghost,
.studio-btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: var(--studio-radius-pill);
    padding: 0.75rem 1.6rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
    border: 2px solid transparent;
    cursor: pointer;
}

.studio-btn-gold { background: var(--studio-gold); color: var(--studio-navy); }
.studio-btn-gold:hover { color: var(--studio-navy); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(255, 186, 73, 0.25); }

.studio-btn-ghost { background: transparent; color: var(--studio-teal); border-color: var(--studio-teal); font-weight: 600; }
.studio-btn-ghost:hover { background: var(--studio-teal-soft); color: var(--studio-teal); transform: translateY(-2px); }

.studio-btn-outline {
    background: transparent;
    color: var(--studio-white);
    border: 1px solid var(--studio-glass-border);
    padding: 0.35rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 500;
}
.studio-btn-outline:hover { color: var(--studio-white); border-color: var(--studio-teal); }

/* ----------------------------------------------------------------- Cards */

.studio-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--studio-glass);
    border: 1px solid var(--studio-glass-border);
    border-radius: var(--studio-radius-card);
    /* No backdrop-filter here, on purpose. This class is on 30-odd boxes per
       page, and behind each one is flat navy and a single soft gradient, so a
       10px blur changes nothing you can see (checked side by side). It still
       cost Safari a separate blurred layer per box, all redrawn on every
       scroll frame because the gradient behind them is position: fixed. That
       made the studio slow in Safari while Chrome looked fine. The nav keeps
       its blur: it is one element, with content scrolling under it. */
    overflow: hidden;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.studio-card:hover {
    transform: translateY(-10px);
    border-color: var(--studio-teal);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3), 0 0 20px rgba(39, 209, 182, 0.1);
    color: inherit;
}

.studio-card-media {
    background: linear-gradient(135deg, var(--studio-navy-raised), rgba(39, 209, 182, 0.25));
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.studio-card-media img { width: 100%; height: 100%; object-fit: cover; }
.studio-card-media--contain img { object-fit: contain; padding: 1rem; }

.studio-card-icon { font-size: 2.5rem; color: var(--studio-gold); }

.studio-card-typographic {
    padding: 1.5rem;
    text-align: center;
    font-weight: 700;
    color: var(--studio-white);
    font-size: 1.1rem;
    line-height: 1.3;
}

.studio-card-body { padding: 1.35rem; display: flex; flex-direction: column; gap: 0.5rem; flex-grow: 1; }
.studio-card-title { color: var(--studio-white); font-weight: 700; font-size: 1.15rem; margin: 0; }
.studio-card-line { color: var(--studio-cream); font-size: 0.95rem; margin: 0; }
.studio-card-footer { margin-top: auto; padding-top: 0.5rem; color: var(--studio-teal); font-weight: 600; font-size: 0.9rem; }

.studio-card--featured .studio-card-media { aspect-ratio: 16 / 9; }

/* ------------------------------------------------------- Pills and chips */

.studio-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border-radius: var(--studio-radius-pill);
    padding: 0.2rem 0.7rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.studio-status--live { background: rgba(39, 209, 182, 0.18); color: var(--studio-teal); }
.studio-status--soon { background: var(--studio-gold-soft); color: var(--studio-gold); }
.studio-status--works { background: rgba(255, 255, 255, 0.1); color: var(--studio-cream); }
.studio-status--concept { background: rgba(139, 92, 246, 0.18); color: #c4b5fd; }
.studio-status--retired { background: rgba(255, 255, 255, 0.07); color: rgba(242, 233, 219, 0.75); }

.studio-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(242, 233, 219, 0.65);
    border: 1px solid var(--studio-glass-border);
    border-radius: var(--studio-radius-pill);
    padding: 0.12rem 0.55rem;
}

.studio-tag--on { color: var(--studio-teal); border-color: rgba(39, 209, 182, 0.4); }

.studio-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border-radius: var(--studio-radius-pill);
    border: 1px solid var(--studio-glass-border);
    background: var(--studio-glass);
    color: var(--studio-cream);
    padding: 0.4rem 0.9rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.studio-chip:hover { border-color: var(--studio-teal); color: var(--studio-white); }
.studio-chip[aria-pressed="true"],
.studio-chip[aria-current="true"] { background: var(--studio-teal); border-color: var(--studio-teal); color: var(--studio-navy); }
.studio-chip-count { opacity: 0.7; font-weight: 500; }

.studio-filter-group { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.studio-filter-label { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(242, 233, 219, 0.6); font-weight: 700; margin-right: 0.25rem; }

/* ---------------------------------------------------------------- Frames */

.studio-frame { display: block; margin: 0; }

.studio-frame-phone img {
    border: 12px solid #1a1a1a;
    border-radius: 40px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    background: var(--studio-navy-raised);
    max-width: 300px;
    width: 100%;
    height: auto;
    display: block;
}

.studio-frame-browser img {
    border: 1px solid var(--studio-glass-border);
    border-top: 26px solid #1d2637;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
    width: 100%;
    height: auto;
    display: block;
}

.studio-frame-photo img {
    border: 6px solid var(--studio-cream);
    border-radius: 6px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
    transform: rotate(-1.2deg);
    width: 100%;
    height: auto;
    display: block;
}

.studio-frame-plain img {
    border-radius: 14px;
    border: 1px solid var(--studio-glass-border);
    width: 100%;
    height: auto;
    display: block;
}

.studio-frame figcaption {
    margin-top: 0.6rem;
    font-size: 0.85rem;
    color: rgba(242, 233, 219, 0.7);
}

.studio-frame-stack { display: flex; flex-wrap: wrap; gap: 1.25rem; align-items: flex-start; }
.studio-frame-stack .studio-frame { flex: 1 1 220px; max-width: 320px; }

/* -------------------------------------------------------------- Chapters */

.studio-chapter { padding: 2.5rem 0; border-top: 1px solid var(--studio-glass-border); }
.studio-chapter:first-of-type { border-top: 0; }
.studio-chapter-icon { color: var(--studio-teal); font-size: 1.1rem; margin-right: 0.4rem; }

/* ------------------------------------------------------- Earlier-work rows */

.studio-list-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--studio-glass);
    border: 1px solid var(--studio-glass-border);
    border-radius: 12px;
    padding: 0.85rem 1rem;
    margin-bottom: 0.65rem;
    text-decoration: none;
    color: var(--studio-cream);
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.studio-list-row:hover { border-color: var(--studio-teal); color: var(--studio-white); transform: translateX(3px); }
.studio-list-name { font-weight: 700; color: var(--studio-white); }

details.studio-details > summary {
    cursor: pointer;
    font-weight: 700;
    color: var(--studio-white);
    padding: 0.75rem 0;
    list-style: none;
}
details.studio-details > summary::-webkit-details-marker { display: none; }
details.studio-details > summary::before { content: "▸ "; color: var(--studio-teal); }
details.studio-details[open] > summary::before { content: "▾ "; }

/* ------------------------------------------------------------ CTA banner */

.studio-cta-banner {
    background: linear-gradient(45deg, rgba(39, 209, 182, 0.1), rgba(8, 18, 38, 0.9));
    border: 1px solid rgba(39, 209, 182, 0.3);
    border-radius: 30px;
    padding: 2.5rem;
}

/* ----------------------------------------------------------------- Stats */

.studio-stats { display: flex; flex-wrap: wrap; gap: 1.75rem; color: var(--studio-cream); }
.studio-stat-number { color: var(--studio-gold); font-weight: 700; font-size: 1.5rem; display: block; line-height: 1.1; }
.studio-stat-label { font-size: 0.85rem; color: rgba(242, 233, 219, 0.7); }

/* ----------------------------------------------------------------- Forms */

.studio-form .form-label { color: var(--studio-white); font-weight: 700; }
.studio-form .form-control,
.studio-form .form-select {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--studio-glass-border);
    color: var(--studio-white);
    border-radius: 12px;
    padding: 0.7rem 0.9rem;
}
.studio-form .form-control::placeholder { color: rgba(242, 233, 219, 0.45); }
.studio-form .form-control:focus,
.studio-form .form-select:focus {
    background: rgba(255, 255, 255, 0.09);
    border-color: var(--studio-teal);
    color: var(--studio-white);
    box-shadow: 0 0 0 0.2rem rgba(39, 209, 182, 0.2);
}
.studio-form .form-check-input { background-color: rgba(255, 255, 255, 0.08); border-color: var(--studio-glass-border); }
.studio-form .form-check-input:checked { background-color: var(--studio-teal); border-color: var(--studio-teal); }
.studio-form .form-check-label { color: var(--studio-cream); }
.studio-form .invalid-feedback { color: #ffb4b4; }
.studio-honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.studio-alert {
    border-radius: 14px;
    padding: 1rem 1.15rem;
    border: 1px solid rgba(39, 209, 182, 0.4);
    background: var(--studio-teal-soft);
    color: var(--studio-white);
}

/* ------------------------------------------------------------------- Nav */

.studio-nav {
    background: rgba(8, 18, 38, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--studio-glass-border);
}

.studio-nav .navbar-brand,
.studio-nav .nav-link { color: var(--studio-cream); }
.studio-nav .nav-link:hover,
.studio-nav .nav-link.active { color: var(--studio-teal); }
.studio-nav .navbar-brand span { color: var(--studio-white); }
.studio-nav .navbar-toggler { border-color: var(--studio-glass-border); }

/* ---------------------------------------------------------------- Footer */

.studio-footer {
    border-top: 1px solid var(--studio-glass-border);
    background: rgba(0, 0, 0, 0.25);
    padding: 2.5rem 0;
    color: rgba(242, 233, 219, 0.7);
}

/* -------------------------------------------------------- Preview banner */

.studio-preview-banner {
    position: sticky;
    top: 0;
    z-index: 1040;
    background: var(--studio-gold);
    color: var(--studio-navy);
    font-weight: 700;
    text-align: center;
    padding: 0.5rem 1rem;
}

.studio-preview-banner a { color: var(--studio-navy); }

/* ----------------------------------------------------- Motion and focus */

.studio-hero-icons { position: relative; min-height: 320px; }
.studio-hero-ring {
    width: 200px;
    height: 200px;
    border: 2px dashed var(--studio-teal);
    border-radius: 50%;
    position: absolute;
    inset: 0;
    margin: auto;
}
.studio-float {
    position: absolute;
    font-size: 2.5rem;
    filter: drop-shadow(0 0 10px rgba(39, 209, 182, 0.6));
}
.studio-float--1 { top: 8%; left: 12%; color: var(--studio-gold); }
.studio-float--2 { top: 14%; right: 14%; color: var(--studio-teal); }
.studio-float--3 { bottom: 16%; left: 16%; color: var(--studio-teal); }
.studio-float--4 { bottom: 8%; right: 12%; color: var(--studio-gold); }

html.js .studio-reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.5s ease, transform 0.5s ease; }
html.js .studio-reveal.studio-reveal--shown { opacity: 1; transform: none; }

@media (prefers-reduced-motion: no-preference) {
    .studio-float { animation: studio-float 6s ease-in-out infinite; }
    .studio-float--2 { animation-delay: 1s; }
    .studio-float--3 { animation-delay: 2s; }
    .studio-float--4 { animation-delay: 3s; }
}

@keyframes studio-float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@media (prefers-reduced-motion: reduce) {
    .studio-card:hover, .studio-btn-gold:hover, .studio-btn-ghost:hover, .studio-list-row:hover { transform: none; }
    html.js .studio-reveal { opacity: 1; transform: none; transition: none; }
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
    outline: 3px solid var(--studio-gold);
    outline-offset: 2px;
}

@media (max-width: 575.98px) {
    :root { --studio-section-y: 48px; }
    .studio-cta-banner { padding: 1.5rem; border-radius: 20px; }
    .studio-frame-stack .studio-frame { flex-basis: 100%; max-width: 100%; }
}
