/* ============================================================
   CAFESWEETS.NET — Bioluminescent Patisserie
   Palette: Abyssal Neon Electric
   ============================================================ */

:root {
    --abyss: #0A0A14;
    --deep: #12121F;
    --mid-void: #1E1E32;
    --cyan: #00F5FF;
    --magenta: #FF00B3;
    --yellow: #F5FF00;
    --white: #FFFFFF;
    --muted: #8888A8;

    --glow-cyan: 0 0 12px rgba(0, 245, 255, 0.6);
    --glow-magenta: 0 0 12px rgba(255, 0, 179, 0.6);
    --glow-yellow: 0 0 12px rgba(245, 255, 0, 0.6);

    --ff-display: 'Bebas Neue', 'Impact', sans-serif;
    --ff-body: 'Space Grotesk', 'Inter', system-ui, sans-serif;
    --ff-mono: 'JetBrains Mono', 'Courier New', monospace;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--abyss);
    color: var(--muted);
    font-family: var(--ff-body);
    font-weight: 400;
    overflow-x: hidden;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    cursor: default;
}

/* ============================================================
   FLOATING NAV PILL
   ============================================================ */

.floating-nav {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(-12px);
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 14px 28px;
    border-radius: 100px;
    background: rgba(10, 10, 20, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(0, 245, 255, 0.18);
    box-shadow:
        0 0 24px rgba(0, 245, 255, 0.12),
        inset 0 0 0 1px rgba(255, 255, 255, 0.02);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.floating-nav.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.nav-link {
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: 0.18em;
    color: var(--magenta);
    text-decoration: none;
    text-transform: uppercase;
    text-shadow: 0 0 8px rgba(255, 0, 179, 0.4);
    transition: color 0.25s ease, text-shadow 0.25s ease;
}

.nav-link:hover {
    color: var(--cyan);
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.7);
}

.nav-divider {
    width: 1px;
    height: 10px;
    background: rgba(136, 136, 168, 0.4);
}

/* ============================================================
   HERO
   ============================================================ */

.hero {
    position: relative;
    height: 100vh;
    min-height: 720px;
    background:
        radial-gradient(ellipse at 30% 40%, #12121F 0%, #0A0A14 60%, #050509 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-fish-wrap {
    width: min(720px, 80vw);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -58%);
    z-index: 1;
    filter: drop-shadow(0 0 18px rgba(0, 245, 255, 0.45));
}

.hero-fish {
    width: 100%;
    height: auto;
    display: block;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.hero-fish.is-ready {
    opacity: 1;
}

.fish-path {
    fill: none;
    vector-effect: non-scaling-stroke;
}

.hero-brand-wrap {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-top: 280px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 1.2s ease 1.6s, transform 1.2s ease 1.6s;
}

.hero-brand-wrap.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.hero-brand {
    font-family: var(--ff-display);
    font-size: clamp(64px, 12vw, 180px);
    font-weight: 400;
    color: var(--white);
    letter-spacing: 0.15em;
    line-height: 0.9;
    text-shadow:
        0 0 24px rgba(255, 255, 255, 0.2),
        0 0 48px rgba(0, 245, 255, 0.25);
}

.hero-tagline {
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: 0.32em;
    color: var(--magenta);
    margin-top: 24px;
    text-shadow: 0 0 10px rgba(255, 0, 179, 0.5);
}

.hero-meta {
    display: inline-block;
    margin-top: 14px;
    font-family: var(--ff-mono);
    font-size: 10px;
    letter-spacing: 0.25em;
    color: var(--muted);
}

.hero-corner {
    position: absolute;
    width: 64px;
    height: 64px;
    pointer-events: none;
    z-index: 3;
}

.hero-corner::before,
.hero-corner::after {
    content: '';
    position: absolute;
    background: var(--cyan);
    box-shadow: 0 0 8px rgba(0, 245, 255, 0.55);
}

.hero-corner.top-left {
    top: 32px;
    left: 32px;
}
.hero-corner.top-right {
    top: 32px;
    right: 32px;
    transform: rotate(90deg);
}
.hero-corner.bottom-left {
    bottom: 32px;
    left: 32px;
    transform: rotate(-90deg);
}
.hero-corner.bottom-right {
    bottom: 32px;
    right: 32px;
    transform: rotate(180deg);
}

.hero-corner::before {
    top: 0;
    left: 0;
    width: 1px;
    height: 32px;
}
.hero-corner::after {
    top: 0;
    left: 0;
    width: 32px;
    height: 1px;
}

.hero-scroll-cue {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--ff-mono);
    font-size: 10px;
    letter-spacing: 0.32em;
    color: var(--muted);
    opacity: 0;
    animation: scrollCueFade 1s ease 3.2s forwards, scrollCuePulse 2.8s ease-in-out 4s infinite;
}

@keyframes scrollCueFade {
    from { opacity: 0; transform: translate(-50%, 8px); }
    to { opacity: 0.6; transform: translate(-50%, 0); }
}

@keyframes scrollCuePulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

/* ============================================================
   CORAL DIVIDERS
   ============================================================ */

.divider-coral {
    width: 100%;
    max-width: 1200px;
    margin: 80px auto;
    height: 120px;
    padding: 0 48px;
    filter: drop-shadow(0 0 6px rgba(0, 245, 255, 0.35));
}

.divider-coral svg {
    width: 100%;
    height: 100%;
}

.divider-coral-mirror {
    transform: scaleY(-1);
    filter: drop-shadow(0 0 6px rgba(255, 0, 179, 0.35));
}

.coral-path {
    fill: none;
    stroke-linecap: round;
    vector-effect: non-scaling-stroke;
}

/* ============================================================
   COLLECTIONS / MASONRY
   ============================================================ */

.collections {
    padding: 40px 24px 80px 48px;
    position: relative;
}

.collections-header {
    max-width: 720px;
    margin: 0 auto 64px;
    padding: 0 16px;
    text-align: center;
}

.section-eyebrow {
    display: inline-block;
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: 0.28em;
    color: var(--magenta);
    text-shadow: 0 0 8px rgba(255, 0, 179, 0.45);
    margin-bottom: 18px;
}

.section-title {
    font-family: var(--ff-display);
    font-size: clamp(56px, 8vw, 120px);
    font-weight: 400;
    letter-spacing: 0.15em;
    color: var(--cyan);
    text-shadow:
        0 0 16px rgba(0, 245, 255, 0.5),
        0 0 36px rgba(0, 245, 255, 0.18);
    line-height: 0.95;
    margin-bottom: 24px;
}

.section-desc {
    font-family: var(--ff-body);
    font-size: 14px;
    line-height: 1.6;
    color: var(--muted);
    max-width: 480px;
    margin: 0 auto;
}

.masonry {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-auto-flow: dense;
    gap: 16px;
    max-width: 1400px;
    margin: 0 auto;
}

.card {
    --glow: var(--cyan);
    position: relative;
    background:
        radial-gradient(ellipse at 80% 20%, var(--mid-void) 0%, var(--deep) 50%, var(--abyss) 100%);
    overflow: hidden;
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.9s ease, transform 0.9s ease, box-shadow 0.5s ease;
    will-change: transform;
}

.card.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

.card[data-glow="cyan"] {
    --glow: var(--cyan);
    --glow-rgb: 0, 245, 255;
}
.card[data-glow="magenta"] {
    --glow: var(--magenta);
    --glow-rgb: 255, 0, 179;
}
.card[data-glow="yellow"] {
    --glow: var(--yellow);
    --glow-rgb: 245, 255, 0;
}

/* Alternating edge glows */
.card:nth-child(odd)::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: var(--glow);
    box-shadow: 0 0 12px var(--glow);
    opacity: 0.85;
}

.card:nth-child(even)::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: var(--glow);
    box-shadow: 0 0 12px var(--glow);
    opacity: 0.85;
}

/* 45-degree corner accent lines */
.card::before {
    content: '';
    position: absolute;
    top: -6px;
    right: -6px;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, transparent 0%, transparent 47%, var(--glow) 49%, var(--glow) 51%, transparent 53%, transparent 100%);
    opacity: 0.6;
    pointer-events: none;
}

.card:hover {
    box-shadow:
        0 0 32px rgba(var(--glow-rgb), 0.25),
        inset 0 0 0 1px rgba(var(--glow-rgb), 0.12);
}

.card-inner {
    position: relative;
    padding: 28px;
    height: 100%;
    display: flex;
    flex-direction: column;
    z-index: 1;
}

/* Card sizes */
.card-tall {
    grid-column: span 1;
    aspect-ratio: 2 / 3;
    min-height: 480px;
}

.card-wide {
    grid-column: span 2;
    aspect-ratio: 16 / 5;
    min-height: 220px;
}

.card-wide-tall {
    aspect-ratio: 16 / 7;
    min-height: 320px;
}

.card-square {
    grid-column: span 1;
    aspect-ratio: 1 / 1;
    min-height: 280px;
}

.card-code {
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: 0.22em;
    color: var(--magenta);
    text-shadow: 0 0 8px rgba(255, 0, 179, 0.4);
    margin-bottom: 16px;
}

.card-title {
    font-family: var(--ff-body);
    font-weight: 700;
    font-size: 24px;
    letter-spacing: -0.02em;
    line-height: 1.15;
    color: #E8E8F0;
    margin-bottom: 12px;
}

.card-desc {
    font-family: var(--ff-body);
    font-weight: 400;
    font-size: 13px;
    line-height: 1.55;
    color: var(--muted);
    max-width: 320px;
    margin-bottom: auto;
}

.card-meta-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid rgba(136, 136, 168, 0.15);
}

.card-price {
    font-family: var(--ff-mono);
    font-size: 12px;
    letter-spacing: 0.18em;
    color: var(--magenta);
    text-shadow: 0 0 6px rgba(255, 0, 179, 0.4);
}

.card-edition {
    font-family: var(--ff-mono);
    font-size: 10px;
    letter-spacing: 0.28em;
    color: var(--muted);
}

.card-display-letter {
    position: absolute;
    right: -12px;
    bottom: -28px;
    font-family: var(--ff-display);
    font-size: 180px;
    letter-spacing: 0.05em;
    line-height: 1;
    color: var(--cyan);
    opacity: 0.07;
    pointer-events: none;
    z-index: 0;
}

.card-display-letter-large {
    font-size: 260px;
    right: -24px;
    bottom: -64px;
}

/* Void cards */
.card-void {
    background: #050509;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-void .card-inner {
    display: none;
}

.void-fish,
.void-coral {
    width: 65%;
    height: 65%;
    filter: drop-shadow(0 0 8px rgba(var(--glow-rgb), 0.55));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.void-fish.is-drawn,
.void-coral.is-drawn {
    opacity: 1;
}

.void-fish-path,
.void-coral-path {
    fill: none;
    stroke-linecap: round;
    vector-effect: non-scaling-stroke;
}

.void-label {
    position: absolute;
    bottom: 16px;
    right: 18px;
    font-family: var(--ff-mono);
    font-size: 9px;
    letter-spacing: 0.32em;
    color: var(--muted);
    text-shadow: 0 0 6px rgba(var(--glow-rgb), 0.4);
}

/* Yellow accent card */
.card-accent-yellow {
    background:
        radial-gradient(ellipse at 20% 80%, rgba(245, 255, 0, 0.04) 0%, var(--deep) 50%, var(--abyss) 100%);
}

.card-accent-yellow .card-title {
    color: var(--yellow);
    text-shadow: 0 0 12px rgba(245, 255, 0, 0.45);
}

/* Drifting animation for already-drawn fish */
@keyframes fishDrift {
    0%, 100% { transform: translate(-8px, 4px); }
    50% { transform: translate(8px, -4px); }
}

.void-fish.is-drifting,
.void-coral.is-drifting {
    animation: fishDrift 6s ease-in-out infinite;
}

/* ============================================================
   ATELIER
   ============================================================ */

.atelier {
    padding: 80px 48px;
    max-width: 1400px;
    margin: 0 auto;
}

.atelier-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 64px;
    align-items: center;
}

.atelier-text .section-eyebrow {
    margin-bottom: 24px;
}

.atelier-title {
    font-family: var(--ff-display);
    font-size: clamp(56px, 8vw, 120px);
    font-weight: 400;
    letter-spacing: 0.15em;
    color: var(--white);
    text-shadow:
        0 0 20px rgba(255, 255, 255, 0.18),
        0 0 48px rgba(0, 245, 255, 0.2);
    line-height: 0.95;
    margin-bottom: 40px;
}

.atelier-body {
    font-family: var(--ff-body);
    font-size: 15px;
    line-height: 1.7;
    color: var(--muted);
    max-width: 460px;
    margin-bottom: 22px;
}

.atelier-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    margin-top: 32px;
    font-family: var(--ff-mono);
    font-size: 11px;
    letter-spacing: 0.22em;
    color: var(--cyan);
    text-shadow: 0 0 8px rgba(0, 245, 255, 0.4);
}

.atelier-meta-sep {
    color: var(--muted);
    text-shadow: none;
}

.atelier-figure {
    position: relative;
    aspect-ratio: 5 / 4;
    background:
        radial-gradient(ellipse at center, var(--mid-void) 0%, var(--deep) 55%, var(--abyss) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.atelier-figure::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 1px;
    height: 100%;
    background: var(--cyan);
    box-shadow: 0 0 12px rgba(0, 245, 255, 0.55);
}

.atelier-figure::after {
    content: '';
    position: absolute;
    right: 0;
    bottom: 0;
    height: 1px;
    width: 100%;
    background: var(--magenta);
    box-shadow: 0 0 12px rgba(255, 0, 179, 0.55);
}

.atelier-fish {
    width: 75%;
    height: 75%;
    filter: drop-shadow(0 0 14px rgba(0, 245, 255, 0.5));
    opacity: 0;
    transition: opacity 0.5s ease;
}

.atelier-fish.is-drawn {
    opacity: 1;
}

.atelier-fish-path {
    fill: none;
    stroke-linecap: round;
    vector-effect: non-scaling-stroke;
}

.atelier-letters {
    position: absolute;
    top: 24px;
    right: 28px;
    font-family: var(--ff-display);
    font-size: 56px;
    letter-spacing: 0.12em;
    color: var(--magenta);
    opacity: 0.5;
    text-shadow: 0 0 12px rgba(255, 0, 179, 0.5);
}

/* ============================================================
   CONTACT
   ============================================================ */

.contact {
    padding: 80px 48px 120px;
    max-width: 920px;
    margin: 0 auto;
    text-align: center;
    position: relative;
}

.contact-title {
    font-family: var(--ff-display);
    font-size: clamp(56px, 9vw, 140px);
    font-weight: 400;
    letter-spacing: 0.15em;
    color: var(--cyan);
    line-height: 0.95;
    margin: 18px 0 56px;
    text-shadow:
        0 0 18px rgba(0, 245, 255, 0.55),
        0 0 48px rgba(0, 245, 255, 0.15);
}

.contact-rows {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-width: 640px;
    margin: 0 auto;
}

.contact-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid rgba(136, 136, 168, 0.18);
}

.contact-label {
    font-family: var(--ff-mono);
    font-size: 10px;
    letter-spacing: 0.32em;
    color: var(--magenta);
    text-shadow: 0 0 6px rgba(255, 0, 179, 0.35);
}

.contact-value {
    font-family: var(--ff-body);
    font-size: 14px;
    color: #E8E8F0;
    letter-spacing: 0.05em;
}

.contact-fade {
    margin-top: 80px;
    width: 100%;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.55;
    filter: drop-shadow(0 0 6px rgba(0, 245, 255, 0.35));
}

.contact-fade svg {
    width: 100%;
    height: auto;
    display: block;
    mask-image: linear-gradient(to bottom, #000 0%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, transparent 100%);
}

.contact-footnote {
    margin-top: 36px;
    font-family: var(--ff-mono);
    font-size: 10px;
    letter-spacing: 0.28em;
    color: var(--muted);
}

/* ============================================================
   PARALLAX OFFSETS (applied by JS)
   ============================================================ */

.masonry .card:nth-child(3n+1) {
    transform: translateY(var(--col-a-offset, 0px));
}

.masonry .card:nth-child(3n+2) {
    transform: translateY(var(--col-b-offset, 0px));
}

.masonry .card.is-revealed:nth-child(3n+1) {
    transform: translateY(calc(0px + var(--col-a-offset, 0px)));
}

.masonry .card.is-revealed:nth-child(3n+2) {
    transform: translateY(calc(0px + var(--col-b-offset, 0px)));
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
    .masonry {
        grid-template-columns: repeat(2, 1fr);
    }
    .card-wide { grid-column: span 2; }
    .card-tall { aspect-ratio: 3 / 4; min-height: 380px; }

    .atelier-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .collections {
        padding: 40px 24px 80px;
    }
}

@media (max-width: 640px) {
    .masonry {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .card-wide,
    .card-tall,
    .card-square {
        grid-column: span 1;
        aspect-ratio: auto;
        min-height: 280px;
    }
    .card-wide-tall { min-height: 320px; }

    .floating-nav {
        gap: 12px;
        padding: 12px 20px;
    }

    .nav-link { font-size: 10px; }

    .collections,
    .atelier,
    .contact {
        padding-left: 20px;
        padding-right: 20px;
    }

    .divider-coral {
        margin: 56px auto;
        padding: 0 20px;
        height: 72px;
    }

    .contact-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .hero-brand-wrap {
        margin-top: 160px;
        padding: 0 20px;
    }
}
