/* ==========================================================================
   hwagryul.com — 화결 · flower crystal
   A holographic chrysanthemum pressed between two sheets of navy steel.
   ========================================================================== */

:root {
    --abyss: #0a0f1e;
    --midnight: #111a2e;
    --gunmetal: #1c2a3e;
    --frost: #e8eef4;
    --steel-mist: #8fa3b8;
    --silver: #c4d4e4;
    --holo-teal: #4d8fac;
    --prismatic: #b8a9d4;
    --crystal-rose: #e0c3fc;
    --bloom-copper: #d4a574;
    --sky: #a8d8ea;

    --grain-opacity: 0.04;
    --flip-duration: 0.8s;
    --flip-bezier: cubic-bezier(0.4, 0, 0.2, 1);
    --scroll-bezier: cubic-bezier(0.25, 0.46, 0.45, 0.94);

    --font-display: 'Jost', 'Futura', 'IBM Plex Sans', system-ui, sans-serif;
    --font-body: 'Outfit', 'Inter', system-ui, sans-serif;
    --font-mono: 'IBM Plex Mono', 'SFMono-Regular', Menlo, monospace;
}

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

html {
    scroll-behavior: smooth;
    background: var(--abyss);
    color: var(--frost);
}

body {
    position: relative;
    min-height: 100vh;
    font-family: var(--font-body);
    font-weight: 300;
    line-height: 1.72;
    letter-spacing: 0.005em;
    color: var(--steel-mist);
    background: radial-gradient(ellipse at center top, #101a33 0%, var(--abyss) 60%, #06091a 100%);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }

/* --------------------------------------------------------------------------
   Grain texture overlay — brushed titanium feel
   -------------------------------------------------------------------------- */
.grain-filter {
    position: absolute;
    width: 0;
    height: 0;
    pointer-events: none;
}

.grain-overlay {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 80;
    opacity: 0;
    mix-blend-mode: overlay;
    background:
        repeating-conic-gradient(from 0deg at 50% 50%, rgba(255, 255, 255, 0.01) 0deg 10deg, rgba(0, 0, 0, 0.015) 10deg 20deg),
        url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.92 0 0 0 0 0.94 0 0 0 0 0.98 0 0 0 0.5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
    background-size: auto, 220px 220px;
    transition: opacity 1.2s ease;
}
.grain-overlay.active { opacity: var(--grain-opacity); }

/* --------------------------------------------------------------------------
   Ambient aurora — holographic light leaks drifting across the navy void
   -------------------------------------------------------------------------- */
.aurora-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.light-leak {
    position: absolute;
    width: 70vmax;
    height: 70vmax;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0;
    mix-blend-mode: screen;
    will-change: transform, opacity;
}

.light-leak.leak-1 {
    top: -20%;
    left: -15%;
    background: radial-gradient(circle, rgba(77, 143, 172, 0.55) 0%, rgba(77, 143, 172, 0) 65%);
    animation: drift-1 28s ease-in-out infinite, fade-in 3s ease 0.6s forwards;
}

.light-leak.leak-2 {
    top: 20%;
    right: -25%;
    background: radial-gradient(circle, rgba(184, 169, 212, 0.45) 0%, rgba(184, 169, 212, 0) 65%);
    animation: drift-2 34s ease-in-out infinite, fade-in 3s ease 1.2s forwards;
}

.light-leak.leak-3 {
    bottom: -25%;
    left: 20%;
    background: radial-gradient(circle, rgba(224, 195, 252, 0.35) 0%, rgba(224, 195, 252, 0) 65%);
    animation: drift-3 30s ease-in-out infinite, fade-in 3s ease 1.8s forwards;
}

.light-leak.leak-4 {
    bottom: 10%;
    right: 10%;
    background: radial-gradient(circle, rgba(168, 216, 234, 0.3) 0%, rgba(168, 216, 234, 0) 65%);
    animation: drift-4 22s ease-in-out infinite, fade-in 3s ease 2.4s forwards;
}

body.deep-in .light-leak { filter: blur(100px); }
body.deep-in .light-leak.leak-1 { opacity: 0.18 !important; }
body.deep-in .light-leak.leak-2 { opacity: 0.2 !important; }
body.deep-in .light-leak.leak-3 { opacity: 0.16 !important; }
body.deep-in .light-leak.leak-4 { opacity: 0.14 !important; }

@keyframes fade-in {
    to { opacity: 0.12; }
}

@keyframes drift-1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(20vw, 15vh) scale(1.1); }
}

@keyframes drift-2 {
    0%, 100% { transform: translate(0, 0) scale(1.05); }
    50% { transform: translate(-15vw, 20vh) scale(0.95); }
}

@keyframes drift-3 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(18vw, -18vh) scale(1.15); }
}

@keyframes drift-4 {
    0%, 100% { transform: translate(0, 0) scale(0.95); }
    50% { transform: translate(-20vw, -12vh) scale(1.1); }
}

/* --------------------------------------------------------------------------
   Crystalline particles — tiny diamonds drifting downward
   -------------------------------------------------------------------------- */
.particle-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 3;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 8px;
    height: 8px;
    border: 1px solid rgba(77, 143, 172, 0.35);
    transform: rotate(45deg);
    background: radial-gradient(circle at 30% 30%, rgba(232, 238, 244, 0.2), transparent 65%);
    will-change: transform, opacity;
    opacity: 0.45;
}

.particle.bright {
    border-color: rgba(184, 169, 212, 0.55);
    box-shadow: 0 0 8px rgba(168, 216, 234, 0.4);
}

/* --------------------------------------------------------------------------
   Facet indicator — vertical dots on right edge
   -------------------------------------------------------------------------- */
.facet-indicator {
    position: fixed;
    top: 50%;
    right: 32px;
    transform: translateY(-50%);
    z-index: 60;
    opacity: 0;
    transition: opacity 0.8s ease 1.8s;
}
.facet-indicator.visible { opacity: 1; }

.facet-indicator ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-items: flex-end;
}

.facet-dot {
    position: relative;
    width: 44px;
    height: 18px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.facet-dot::after {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: 1px solid var(--steel-mist);
    background: transparent;
    transition: all 0.4s ease;
}

.facet-dot.active::after {
    width: 12px;
    height: 12px;
    border-color: var(--holo-teal);
    background: linear-gradient(135deg, var(--holo-teal), var(--prismatic), var(--crystal-rose));
    box-shadow: 0 0 14px rgba(77, 143, 172, 0.6), 0 0 28px rgba(184, 169, 212, 0.35);
    animation: dot-pulse 3s ease-in-out infinite;
}

@keyframes dot-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.3); }
}

.dot-label {
    position: absolute;
    right: 28px;
    top: 50%;
    transform: translateY(-50%) translateX(6px);
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--silver);
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.facet-dot:hover .dot-label,
.facet-dot.active .dot-label {
    opacity: 0.9;
    transform: translateY(-50%) translateX(0);
}

/* --------------------------------------------------------------------------
   Shared facet scaffolding
   -------------------------------------------------------------------------- */
.journey {
    position: relative;
    z-index: 2;
}

.facet {
    position: relative;
    width: 100%;
    padding: 0 clamp(24px, 6vw, 120px);
}

.facet-header {
    max-width: 720px;
    margin: 0 auto clamp(48px, 8vh, 120px);
    text-align: center;
}

.meta-label,
.meta-value {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: clamp(0.7rem, 0.85vw, 0.85rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--holo-teal);
}

.meta-divider {
    display: inline-block;
    width: 32px;
    height: 1px;
    background: var(--holo-teal);
    opacity: 0.5;
    vertical-align: middle;
    margin: 0 12px;
}

.facet-title {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(2.8rem, 7vw, 6rem);
    line-height: 0.98;
    letter-spacing: -0.03em;
    color: var(--frost);
    margin: 18px 0 24px;
}

.facet-lede {
    font-family: var(--font-body);
    font-weight: 300;
    font-size: clamp(1rem, 1.2vw, 1.15rem);
    line-height: 1.72;
    color: var(--steel-mist);
    max-width: 560px;
    margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Facet 0 — The Aperture
   -------------------------------------------------------------------------- */
.facet-aperture {
    height: 100vh;
    min-height: 680px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    text-align: center;
}

.aperture-meta {
    position: absolute;
    top: 40px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: meta-fade 1s ease 0.2s forwards;
}

@keyframes meta-fade {
    to { opacity: 1; }
}

.aperture-wrapper {
    position: relative;
    max-width: 1280px;
    width: 100%;
}

.logotype {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(4rem, 10vw, 9rem);
    letter-spacing: -0.04em;
    line-height: 1;
    margin: 0;
    color: var(--frost);
    display: inline-flex;
    justify-content: center;
    flex-wrap: nowrap;
}

.logotype .char {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px);
    background: linear-gradient(
        135deg,
        #0a0f1e 0%,
        #1a3a5c 15%,
        #4d8fac 30%,
        #a8d8ea 45%,
        #e0c3fc 55%,
        #b8a9d4 70%,
        #4d8fac 85%,
        #0a0f1e 100%
    );
    background-size: 300% 300%;
    background-position: 0% 0%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: holographicShift 8s ease-in-out infinite;
    transition: background-position 0.4s ease;
}

.logotype .char.revealed {
    animation: char-arrive 0.6s var(--scroll-bezier) forwards, holographicShift 8s ease-in-out 0.6s infinite;
}

@keyframes char-arrive {
    0%  { opacity: 0; transform: translateY(20px); filter: blur(8px); background-position: 0% 0%; }
    40% { background-position: 120% 120%; filter: blur(0); }
    100% { opacity: 1; transform: translateY(0); filter: blur(0); background-position: 50% 50%; }
}

@keyframes holographicShift {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.horizon-line {
    width: 0;
    height: 1px;
    background: var(--holo-teal);
    opacity: 0.4;
    margin: 48px auto 32px;
    transition: width 2s var(--scroll-bezier);
}
.horizon-line.extended { width: 80%; }

.subtitle {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.8s ease 1.4s;
}
.subtitle.visible { opacity: 1; }

.subtitle .han {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1rem, 1.6vw, 1.4rem);
    color: var(--silver);
    letter-spacing: 0.3em;
}

.subtitle .gloss {
    font-family: var(--font-mono);
    font-size: clamp(0.7rem, 0.9vw, 0.85rem);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--steel-mist);
    opacity: 0.75;
}

.scroll-hint {
    position: absolute;
    bottom: 44px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--steel-mist);
    opacity: 0;
    animation: hint-pulse 2.8s ease-in-out infinite, hint-fade 1.2s ease 2.2s forwards;
}

.hint-chevron {
    font-family: var(--font-display);
    font-size: 1rem;
    animation: chevron-bob 2.2s ease-in-out infinite;
}

@keyframes hint-pulse {
    0%, 100% { color: rgba(143, 163, 184, 0.4); }
    50% { color: rgba(168, 216, 234, 0.7); }
}

@keyframes hint-fade {
    to { opacity: 1; }
}

@keyframes chevron-bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* --------------------------------------------------------------------------
   Facet 1 — The Bloom (2x3 offset card grid)
   -------------------------------------------------------------------------- */
.facet-bloom {
    min-height: 200vh;
    padding-top: clamp(100px, 16vh, 180px);
    padding-bottom: clamp(100px, 14vh, 160px);
}

.bloom-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(32px, 4vw, 72px) clamp(24px, 3vw, 56px);
    max-width: 1320px;
    margin: 0 auto;
    perspective: 1200px;
}

.flip-card {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s var(--scroll-bezier), transform 0.8s var(--scroll-bezier);
}
.flip-card.entered { opacity: 1; transform: translateY(0); }

/* Zigzag: odd cards displaced downward to echo chrysanthemum petal rhythm */
.flip-card[data-i="1"],
.flip-card[data-i="3"],
.flip-card[data-i="5"] {
    transform: translateY(120px);
}
.flip-card[data-i="1"].entered,
.flip-card[data-i="3"].entered,
.flip-card[data-i="5"].entered {
    transform: translateY(60px);
}

.flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform var(--flip-duration) var(--flip-bezier), box-shadow 0.6s ease;
}

.flip-card.flipped .flip-inner {
    transform: rotateY(180deg);
}

.flip-card.flash .flip-inner {
    box-shadow: 0 0 40px rgba(77, 143, 172, 0.35), 0 0 80px rgba(184, 169, 212, 0.22);
}

.flip-face {
    position: absolute;
    inset: 0;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border: 1px solid rgba(77, 143, 172, 0.18);
    border-radius: 2px;
    padding: clamp(20px, 2.5vw, 36px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.flip-front {
    background:
        linear-gradient(160deg, rgba(17, 26, 46, 1) 0%, rgba(17, 26, 46, 0.92) 60%, rgba(28, 42, 62, 0.9) 100%),
        radial-gradient(circle at 20% 0%, rgba(77, 143, 172, 0.2), transparent 60%);
}

.flip-front::before {
    content: '';
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    bottom: 14px;
    border: 1px solid rgba(143, 163, 184, 0.08);
    pointer-events: none;
}

.flip-back {
    transform: rotateY(180deg);
    background: linear-gradient(160deg, var(--gunmetal) 0%, #223254 100%);
    border-color: rgba(184, 169, 212, 0.35);
    box-shadow: inset 0 0 40px rgba(184, 169, 212, 0.08);
    justify-content: space-between;
}

.card-illustration {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
}

.botanical {
    width: 100%;
    height: 100%;
    max-width: 260px;
    max-height: 260px;
    overflow: visible;
}

.botanical .draw {
    fill: none;
    stroke: var(--holo-teal);
    stroke-width: 1;
    stroke-opacity: 0.75;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 900;
    stroke-dashoffset: 900;
    transition: stroke-dashoffset 2.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.botanical.drawn .draw {
    stroke-dashoffset: 0;
}

.botanical.filled .draw {
    stroke: url(#holoStroke);
    stroke-opacity: 1;
    animation: stroke-shimmer 6s linear infinite;
}

@keyframes stroke-shimmer {
    0%, 100% { filter: drop-shadow(0 0 3px rgba(77, 143, 172, 0.45)); }
    50% { filter: drop-shadow(0 0 6px rgba(224, 195, 252, 0.55)); }
}

.card-meta {
    margin-top: auto;
    text-align: left;
}

.card-index {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--holo-teal);
    margin-bottom: 10px;
}

.card-title {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(1.5rem, 2vw, 2rem);
    line-height: 1.05;
    letter-spacing: -0.02em;
    color: var(--frost);
    margin-bottom: 6px;
}

.card-tag {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--silver);
    opacity: 0.75;
}

.back-label {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--prismatic);
}

.back-body {
    font-family: var(--font-body);
    font-weight: 300;
    font-size: clamp(0.92rem, 1.1vw, 1.05rem);
    line-height: 1.72;
    color: var(--silver);
    margin: 16px 0;
}

.back-body em {
    font-style: normal;
    background: linear-gradient(135deg, var(--holo-teal), var(--prismatic), var(--crystal-rose));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    font-weight: 400;
}

.back-signature {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--steel-mist);
    opacity: 0.6;
    border-top: 1px solid rgba(184, 169, 212, 0.2);
    padding-top: 14px;
}

/* --------------------------------------------------------------------------
   Facet 2 — The Grain (horizontal within vertical)
   -------------------------------------------------------------------------- */
.facet-grain {
    height: 450vh;
    position: relative;
    padding: 0;
}

.grain-sticky {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.grain-header {
    padding: clamp(48px, 8vh, 96px) clamp(24px, 6vw, 120px) clamp(20px, 3vh, 40px);
    max-width: 720px;
    flex-shrink: 0;
}

.grain-header .facet-title {
    font-size: clamp(2.2rem, 5vw, 4.2rem);
    margin: 14px 0 16px;
}

.grain-header .facet-lede {
    font-size: clamp(0.95rem, 1.1vw, 1.05rem);
    margin: 0;
}

.grain-track {
    flex: 1;
    overflow: hidden;
    display: flex;
    align-items: center;
    padding: 0 clamp(24px, 6vw, 120px);
    min-height: 0;
}

.grain-row {
    display: flex;
    align-items: center;
    gap: clamp(40px, 4vw, 96px);
    will-change: transform;
    transform: translateX(0);
}

.grain-card {
    flex: 0 0 clamp(280px, 62vw, 720px);
    aspect-ratio: 4 / 3;
    max-height: 62vh;
    padding: clamp(24px, 3vw, 48px);
    background: linear-gradient(155deg, var(--midnight) 0%, #0f1a36 55%, var(--gunmetal) 100%);
    border: 1px solid rgba(77, 143, 172, 0.18);
    position: relative;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    grid-template-rows: auto 1fr auto;
    gap: 20px 36px;
    overflow: hidden;
}

.grain-card::before {
    content: '';
    position: absolute;
    top: 12px; left: 12px; right: 12px; bottom: 12px;
    border: 1px solid rgba(184, 169, 212, 0.08);
    pointer-events: none;
}

.grain-idx {
    grid-column: 2 / 3;
    grid-row: 1;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--holo-teal);
    align-self: start;
    text-align: right;
}

.grain-illustration {
    grid-column: 1 / 2;
    grid-row: 1 / 4;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
}

.botanical-large {
    width: 100%;
    height: 100%;
    max-width: 420px;
    max-height: 420px;
}

.botanical-large .draw {
    fill: none;
    stroke: var(--holo-teal);
    stroke-width: 1.2;
    stroke-opacity: 0.7;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1800;
    stroke-dashoffset: 1800;
    transition: stroke-dashoffset 2.5s cubic-bezier(0.4, 0, 0.2, 1), stroke 1s ease, stroke-opacity 1s ease;
}

.botanical-large.drawn .draw { stroke-dashoffset: 0; }

.botanical-large.filled .draw {
    stroke-opacity: 1;
    filter: drop-shadow(0 0 6px rgba(184, 169, 212, 0.35));
}

.grain-title {
    grid-column: 2 / 3;
    grid-row: 2;
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(1.8rem, 3.2vw, 2.8rem);
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--frost);
    align-self: end;
    margin-bottom: 12px;
}

.grain-body {
    grid-column: 2 / 3;
    grid-row: 3;
    font-family: var(--font-body);
    font-weight: 300;
    font-size: clamp(0.92rem, 1.1vw, 1.05rem);
    line-height: 1.72;
    color: var(--steel-mist);
    max-width: 48ch;
    align-self: end;
}

/* --------------------------------------------------------------------------
   Facet 3 — The Resolution (convergence)
   -------------------------------------------------------------------------- */
.facet-resolution {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(80px, 12vh, 140px) clamp(24px, 6vw, 120px);
    position: relative;
}

.resolution-wrapper {
    position: relative;
    width: 100%;
    max-width: 1080px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.converge-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    aspect-ratio: 1;
    border: 1px solid rgba(77, 143, 172, 0.25);
    border-radius: 50%;
    pointer-events: none;
    animation: ring-rotate 80s linear infinite;
}

.converge-ring-2 {
    width: 80%;
    border-color: rgba(184, 169, 212, 0.2);
    border-style: dashed;
    animation: ring-rotate 60s linear reverse infinite;
}

@keyframes ring-rotate {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

.resolution-card {
    position: relative;
    width: clamp(320px, 68vw, 620px);
    aspect-ratio: 4 / 5;
    padding: clamp(32px, 4.5vw, 72px);
    background: linear-gradient(160deg, var(--midnight) 0%, #151f3c 60%, var(--gunmetal) 100%);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    opacity: 0;
    transform: scale(0.85);
    transition: opacity 1.4s var(--scroll-bezier), transform 1.4s var(--scroll-bezier);
    overflow: hidden;
}
.resolution-card.revealed { opacity: 1; transform: scale(1); }

.resolution-border {
    position: absolute;
    inset: 0;
    padding: 1px;
    background: linear-gradient(
        135deg,
        #0a0f1e 0%,
        #1a3a5c 15%,
        #4d8fac 30%,
        #a8d8ea 45%,
        #e0c3fc 55%,
        #b8a9d4 70%,
        #4d8fac 85%,
        #0a0f1e 100%
    );
    background-size: 300% 300%;
    animation: holographicShift 8s ease-in-out infinite;
    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.resolution-title {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: clamp(2.2rem, 4.8vw, 3.6rem);
    line-height: 1.04;
    letter-spacing: -0.03em;
    margin: 20px 0 0;
    background: linear-gradient(
        135deg,
        #0a0f1e 0%,
        #1a3a5c 15%,
        #4d8fac 30%,
        #a8d8ea 45%,
        #e0c3fc 55%,
        #b8a9d4 70%,
        #4d8fac 85%,
        #0a0f1e 100%
    );
    background-size: 300% 300%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    animation: holographicShift 8s ease-in-out infinite;
}

.resolution-body {
    font-family: var(--font-body);
    font-weight: 300;
    font-size: clamp(0.95rem, 1.15vw, 1.1rem);
    line-height: 1.72;
    color: var(--silver);
    max-width: 46ch;
    margin-top: 28px;
}

.resolution-footer {
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid rgba(143, 163, 184, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--steel-mist);
}

.resolution-footer .foot-l { color: var(--prismatic); }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    .bloom-grid { grid-template-columns: repeat(2, 1fr); }
    .flip-card[data-i="1"],
    .flip-card[data-i="3"],
    .flip-card[data-i="5"] { transform: translateY(60px); }
    .flip-card[data-i="1"].entered,
    .flip-card[data-i="3"].entered,
    .flip-card[data-i="5"].entered { transform: translateY(0); }
    .facet-indicator { right: 20px; }
    .dot-label { display: none; }
}

@media (max-width: 768px) {
    .facet-indicator {
        top: auto;
        right: 50%;
        bottom: 18px;
        transform: translateX(50%);
    }
    .facet-indicator ul {
        flex-direction: row;
        gap: 18px;
    }
    .facet-dot { width: 22px; height: 22px; justify-content: center; }
    .dot-label { display: none; }

    .bloom-grid { grid-template-columns: 1fr; gap: 24px; }
    .flip-card { aspect-ratio: 4 / 5; }
    .flip-card[data-i="1"],
    .flip-card[data-i="3"],
    .flip-card[data-i="5"] { transform: translateY(40px); }
    .flip-card[data-i="1"].entered,
    .flip-card[data-i="3"].entered,
    .flip-card[data-i="5"].entered { transform: translateY(0); }

    .facet-grain { height: auto; }
    .grain-sticky { position: relative; height: auto; }
    .grain-track { padding: 0 20px 60px; }
    .grain-row {
        flex-direction: column;
        transform: none !important;
        gap: 32px;
    }
    .grain-card {
        flex: 0 0 auto;
        width: 100%;
        aspect-ratio: auto;
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto auto;
        gap: 16px;
    }
    .grain-idx { grid-column: 1; grid-row: 1; text-align: left; }
    .grain-illustration { grid-column: 1; grid-row: 2; max-height: 320px; }
    .grain-title { grid-column: 1; grid-row: 3; }
    .grain-body { grid-column: 1; grid-row: 4; }

    .resolution-card {
        width: 100%;
        aspect-ratio: auto;
        min-height: 60vh;
    }
}
