/* bada.style — Vaporwave Fashion Editorial Timeline */

/* ===== RESET & BASE ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    color: #4a3d5c;
    background: linear-gradient(135deg, #f0eaf5 0%, #f5e8ee 40%, #e8dff5 100%);
    background-attachment: fixed;
    line-height: 1.72;
    letter-spacing: 0.01em;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* ===== DOT GRID BACKGROUND ===== */
.dot-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, #b8a9d4 1px, transparent 1px);
    background-size: 40px 40px;
    opacity: 0.06;
    pointer-events: none;
    z-index: 0;
}

/* ===== NAV CLUSTER ===== */
.nav-cluster {
    position: fixed;
    top: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    z-index: 100;
}

.nav-domain {
    font-family: 'Libre Baskerville', serif;
    font-weight: 400;
    font-style: italic;
    font-size: 0.85rem;
    color: #4a3d5c;
    writing-mode: vertical-rl;
    letter-spacing: 0.08em;
    text-shadow: 1px 0 rgba(212, 114, 140, 0.3), -1px 0 rgba(126, 184, 201, 0.3);
}

.nav-icon {
    font-size: 0.9rem;
    opacity: 0.6;
    line-height: 1;
}

/* ===== TIMELINE SPINE ===== */
.timeline-spine {
    position: absolute;
    top: 0;
    left: 33%;
    width: 2px;
    height: 100%;
    z-index: 1;
    overflow: visible;
}

#spineLineBg,
#spineProgress {
    vector-effect: non-scaling-stroke;
}

#spineProgress {
    stroke-dasharray: var(--spine-length, 10000);
    stroke-dashoffset: var(--spine-offset, 10000);
    transition: stroke-dashoffset 0.05s linear;
}

/* ===== TIMELINE MARKERS ===== */
.timeline-marker {
    position: absolute;
    left: 33%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    z-index: 10;
}

.timeline-marker-dawn {
    top: 80px;
}

.timeline-marker-dusk {
    bottom: 40px;
}

.marker-diamond {
    width: 12px;
    height: 12px;
    background: #e8b4a0;
    transform: rotate(45deg);
    border: 1px solid #d4728c;
}

.marker-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #9b8ab8;
}

.marker-time {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    color: #9b8ab8;
}

.section-dusk .marker-label,
.timeline-marker-dusk .marker-label {
    color: #c9bdd9;
}

/* ===== HERO SECTION ===== */
.hero {
    display: grid;
    grid-template-columns: 33% 67%;
    min-height: 100vh;
    position: relative;
    z-index: 2;
    padding-top: 120px;
}

.hero-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 30px 40px 60px;
    align-items: flex-end;
}

.hero-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    font-size: clamp(3rem, 8vw, 6rem);
    letter-spacing: 0.15em;
    color: #2d2040;
    text-shadow: 1px 0 rgba(212, 114, 140, 0.4), -1px 0 rgba(126, 184, 201, 0.4);
    line-height: 1.1;
    text-align: right;
}

.hero-subtitle {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    color: #4a3d5c;
    margin-top: 20px;
    font-style: italic;
    text-align: right;
}

.hero-image {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

/* ===== PHOTO CONTAINERS ===== */
.photo-container {
    position: relative;
    display: inline-block;
}

.photo-wrapper {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
}

.photo-placeholder {
    display: block;
    border-radius: 6px;
    overflow: hidden;
}

.photo-placeholder svg {
    display: block;
    width: 100%;
    height: auto;
}

.hero-photo svg {
    width: 100%;
    max-width: 500px;
    height: auto;
}

/* ===== SCAN LINES ===== */
.scan-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(45, 32, 64, 0.03) 2px,
        rgba(45, 32, 64, 0.03) 4px
    );
    pointer-events: none;
    border-radius: 6px;
}

/* ===== CHROMATIC OVERLAY ===== */
.chromatic-overlay {
    position: absolute;
    top: 0;
    left: 2px;
    width: 100%;
    height: 100%;
    background: rgba(212, 114, 140, 0.08);
    mix-blend-mode: multiply;
    pointer-events: none;
    border-radius: 6px;
}

/* ===== TARGETING BRACKETS ===== */
.targeting-brackets {
    position: absolute;
    top: -8px;
    left: -8px;
    right: -8px;
    bottom: -8px;
    pointer-events: none;
    z-index: 5;
}

.bracket {
    position: absolute;
    width: 16px;
    height: 16px;
    border-color: #b8a9d4;
    border-style: solid;
    border-width: 0;
    transition: transform 300ms ease-out;
}

.bracket-tl {
    top: 0;
    left: 0;
    border-top-width: 1px;
    border-left-width: 1px;
}

.bracket-tr {
    top: 0;
    right: 0;
    border-top-width: 1px;
    border-right-width: 1px;
}

.bracket-bl {
    bottom: 0;
    left: 0;
    border-bottom-width: 1px;
    border-left-width: 1px;
}

.bracket-br {
    bottom: 0;
    right: 0;
    border-bottom-width: 1px;
    border-right-width: 1px;
}

.photo-container:hover .bracket-tl {
    transform: translate(-4px, -4px);
}
.photo-container:hover .bracket-tr {
    transform: translate(4px, -4px);
}
.photo-container:hover .bracket-bl {
    transform: translate(-4px, 4px);
}
.photo-container:hover .bracket-br {
    transform: translate(4px, 4px);
}

.photo-container:hover .photo-wrapper {
    filter: saturate(0.85);
    transition: filter 400ms ease;
}

/* ===== COORDINATE LABELS ===== */
.coordinate-label {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    color: #9b8ab8;
    letter-spacing: 0.08em;
    margin-top: 6px;
    text-align: right;
}

.coordinate-label-dark {
    color: #b8a9d4;
}

/* ===== SCANNING BAR ===== */
.scanning-bar {
    width: 100%;
    height: 3px;
    background: rgba(184, 169, 212, 0.2);
    margin-top: 4px;
    border-radius: 2px;
    overflow: hidden;
}

.scanning-bar-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #d4728c, #7eb8c9);
    border-radius: 2px;
    transition: width 1.5s ease-out;
}

.scanning-bar-fill.active {
    width: 100%;
}

/* Pulsing animation for scanning bars */
@keyframes scanPulse {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

.scanning-bar-fill.active {
    animation: scanPulse 2s ease-in-out infinite;
}

/* ===== SCAN-LINE DIVIDERS ===== */
.scanline-divider {
    width: 60%;
    max-width: 400px;
    margin: 60px auto;
    display: flex;
    flex-direction: column;
    gap: 3px;
    position: relative;
    z-index: 2;
}

.scanline-divider::before,
.scanline-divider::after,
.scanline-divider {
    background: none;
}

.scanline-divider {
    height: 19px;
    background-image:
        linear-gradient(to right, rgba(184, 169, 212, 0.2), rgba(184, 169, 212, 0.2)),
        linear-gradient(to right, rgba(184, 169, 212, 0.4), rgba(184, 169, 212, 0.4)),
        linear-gradient(to right, rgba(184, 169, 212, 0.6), rgba(184, 169, 212, 0.6)),
        linear-gradient(to right, rgba(184, 169, 212, 0.4), rgba(184, 169, 212, 0.4)),
        linear-gradient(to right, rgba(184, 169, 212, 0.2), rgba(184, 169, 212, 0.2));
    background-size: 100% 1px;
    background-position: 0 0, 0 4px, 0 8px, 0 12px, 0 16px;
    background-repeat: no-repeat;
}

.scanline-divider-dark {
    background-image:
        linear-gradient(to right, rgba(212, 114, 140, 0.2), rgba(212, 114, 140, 0.2)),
        linear-gradient(to right, rgba(212, 114, 140, 0.4), rgba(212, 114, 140, 0.4)),
        linear-gradient(to right, rgba(212, 114, 140, 0.6), rgba(212, 114, 140, 0.6)),
        linear-gradient(to right, rgba(212, 114, 140, 0.4), rgba(212, 114, 140, 0.4)),
        linear-gradient(to right, rgba(212, 114, 140, 0.2), rgba(212, 114, 140, 0.2));
    background-size: 100% 1px;
    background-position: 0 0, 0 4px, 0 8px, 0 12px, 0 16px;
    background-repeat: no-repeat;
}

/* ===== TIMELINE SECTIONS ===== */
.timeline-section {
    position: relative;
    z-index: 2;
    padding: 40px 0;
}

/* ===== TIMELINE NODES ===== */
.timeline-node {
    position: relative;
    display: grid;
    margin-bottom: 80px;
    padding: 20px;
    border: 1px solid transparent;
}

.timeline-node.border-animated {
    animation: borderDraw 1.2s ease-out forwards;
}

.timeline-node[data-speed="slow"].border-animated {
    animation-duration: 1.5s;
}

@keyframes borderDraw {
    0% {
        border-image: conic-gradient(#d4728c 0deg, transparent 0deg) 1;
    }
    25% {
        border-image: conic-gradient(#d4728c 90deg, transparent 90deg) 1;
    }
    50% {
        border-image: conic-gradient(#d4728c 180deg, transparent 180deg) 1;
    }
    75% {
        border-image: conic-gradient(#d4728c 270deg, transparent 270deg) 1;
    }
    100% {
        border-image: conic-gradient(#d4c5e8 360deg, transparent 360deg) 1;
        border-color: #d4c5e8;
    }
}

.timeline-node.border-complete {
    border-color: #d4c5e8;
    animation: none;
}

.node-right {
    grid-template-columns: 1fr;
    margin-left: 35%;
    margin-right: 5%;
}

.node-left {
    grid-template-columns: 1fr;
    margin-left: 5%;
    margin-right: 67%;
}

/* ===== NODE CONNECTOR ===== */
.node-connector {
    position: absolute;
    display: flex;
    align-items: center;
    z-index: 3;
}

.node-right .node-connector {
    left: -20px;
    top: 50px;
    transform: translateX(-100%);
    flex-direction: row;
    width: calc(33vw - 35vw + 20px);
}

.node-left .node-connector {
    right: -20px;
    top: 50px;
    transform: translateX(100%);
    flex-direction: row-reverse;
    width: calc(33vw - 5vw - 28vw + 20px);
}

.connector-line {
    flex: 1;
    height: 1px;
    background: #d4c5e8;
}

.connector-line-dark {
    background: #b8a9d4;
}

.connector-circle {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #d4728c;
    border: 2px solid #d4728c;
    flex-shrink: 0;
    transform: scale(0);
    transition: transform 400ms ease-out;
}

.connector-circle.active {
    transform: scale(1);
}

.connector-circle-dark {
    background: #e8b4a0;
    border-color: #d4728c;
}

/* ===== NODE TIMESTAMP ===== */
.node-timestamp {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 12px;
}

.timestamp-time {
    font-family: 'Space Mono', monospace;
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #9b8ab8;
}

.timestamp-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.08em;
    color: #b8a9d4;
    background: rgba(184, 169, 212, 0.1);
    padding: 2px 8px;
    display: inline-block;
    width: fit-content;
}

.node-timestamp-dark .timestamp-time {
    color: #c9bdd9;
}

.node-timestamp-dark .timestamp-tag {
    color: #b8a9d4;
    background: rgba(184, 169, 212, 0.15);
}

/* ===== NODE CONTENT ===== */
.node-content .photo-placeholder svg {
    width: 300px;
    height: 400px;
}

.node-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    color: #2d2040;
    letter-spacing: 0.08em;
    margin-top: 16px;
    line-height: 1.3;
    text-shadow: 1px 0 rgba(212, 114, 140, 0.4), -1px 0 rgba(126, 184, 201, 0.4);
}

.node-title-dark {
    color: #e8dff5;
}

.node-caption {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    color: #4a3d5c;
    line-height: 1.72;
    margin-top: 10px;
}

.node-caption-dark {
    color: #c9bdd9;
}

/* ===== INTERLUDE ===== */
.interlude {
    position: relative;
    z-index: 2;
    padding: 80px 0;
}

.interlude-photo {
    position: relative;
    width: 100%;
}

.interlude-wrapper {
    width: 100%;
    border-radius: 0;
}

.interlude-wrapper .photo-placeholder svg {
    width: 100%;
    height: auto;
}

.interlude-spine-dashed {
    position: absolute;
    top: 0;
    left: 33%;
    width: 2px;
    height: 100%;
    background-image: repeating-linear-gradient(
        to bottom,
        #b8a9d4 0,
        #b8a9d4 8px,
        transparent 8px,
        transparent 16px
    );
    z-index: 5;
}

.interlude-quote {
    max-width: 700px;
    margin: 40px auto;
    text-align: center;
    padding: 0 40px;
}

.interlude-quote p {
    font-family: 'Libre Baskerville', serif;
    font-weight: 400;
    font-style: italic;
    font-size: clamp(1.4rem, 3vw, 2.4rem);
    color: #d4728c;
    line-height: 1.4;
    text-shadow: 1px 0 rgba(212, 114, 140, 0.6), -1px 0 rgba(126, 184, 201, 0.6);
}

.interlude-timestamp {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 24px;
}

/* ===== DUSK SECTION ===== */
.section-dusk {
    background: linear-gradient(180deg, #e8dff5 0%, #2d2040 15%, #1a1428 40%);
    padding-top: 80px;
    padding-bottom: 120px;
}

.section-dusk .timeline-spine-segment {
    background: linear-gradient(to bottom, #b8a9d4, #d4728c);
}

/* ===== WAVE CONTAINER ===== */
.wave-container {
    position: relative;
    z-index: 2;
    background: #1a1428;
    padding: 20px 0;
}

.wave-svg {
    width: 100%;
    height: 60px;
    display: block;
}

#wavePath {
    stroke-dasharray: 2000;
    stroke-dashoffset: 2000;
    transition: stroke-dashoffset 2s ease-out;
}

#wavePath.drawn {
    stroke-dashoffset: 0;
}

/* ===== CLOSING ===== */
.closing {
    position: relative;
    z-index: 2;
    background: #1a1428;
    padding: 60px 40px 100px;
    text-align: center;
}

.closing-domain {
    font-family: 'Libre Baskerville', serif;
    font-weight: 400;
    font-style: italic;
    font-size: 1.2rem;
    color: #e8dff5;
    letter-spacing: 0.08em;
    text-shadow: 1px 0 rgba(212, 114, 140, 0.4), -1px 0 rgba(126, 184, 201, 0.4);
}

.closing-message {
    font-family: 'Karla', sans-serif;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.1vw, 1.15rem);
    color: #c9bdd9;
    margin-top: 12px;
    font-style: italic;
}

/* ===== DUSK MARKER ===== */
.timeline-marker-dusk {
    position: relative;
    background: #1a1428;
    padding-bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    bottom: auto;
}

.timeline-marker-dusk .marker-diamond {
    background: #d4728c;
    border-color: #e8b4a0;
}

.timeline-marker-dusk .marker-label {
    color: #c9bdd9;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .timeline-spine {
        left: 16px;
    }

    .timeline-marker {
        left: 16px;
    }

    .hero {
        grid-template-columns: 1fr;
        padding-top: 80px;
    }

    .hero-content {
        padding: 20px 20px 20px 40px;
        align-items: flex-start;
    }

    .hero-title {
        text-align: left;
    }

    .hero-subtitle {
        text-align: left;
    }

    .hero-image {
        padding: 20px;
    }

    .hero-photo svg {
        max-width: 100%;
    }

    .node-right {
        margin-left: 40px;
        margin-right: 16px;
    }

    .node-left {
        margin-left: 40px;
        margin-right: 16px;
    }

    .node-content .photo-placeholder svg {
        width: 100%;
        height: auto;
    }

    .interlude-spine-dashed {
        left: 16px;
    }

    .nav-cluster {
        top: 12px;
        right: 12px;
    }

    .nav-domain {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.2rem;
    }

    .node-right,
    .node-left {
        margin-left: 32px;
        margin-right: 8px;
    }
}
