/* ============================================================
   doublestandard.xyz - v2 Styles
   Palette: #D06030 #FFF5E8 #3A1A0A #FF8040 #508050 #2A1008
   Fonts: Fredoka (display), Quicksand (body), Space Mono (accent)
   Aesthetic: playful + diagonal-sections + blur-focus + vector-art
   ============================================================ */

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Quicksand', sans-serif;
    font-weight: 400;
    font-size: clamp(15px, 1.1vw, 18px);
    line-height: 1.75;
    color: #3A1A0A;
    background: #FFF5E8;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3 {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.05;
}

p {
    max-width: 64ch;
}

.accent-word {
    color: #508050;
    position: relative;
    display: inline-block;
}

.accent-word::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.06em;
    height: 0.16em;
    background: #508050;
    opacity: 0.18;
    border-radius: 6px;
    transform: skewX(-10deg);
}

/* ============================================================
   HERO - Bold Declaration (100vh)
   ============================================================ */

.hero-section {
    position: relative;
    width: 100%;
    height: 100vh;
    background: #D06030;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 10;
    color: #FFF5E8;
}

/* Decorative diagonal stripe pattern (subtle) */
.hero-section::before {
    content: '';
    position: absolute;
    inset: -20% -10% -10% -10%;
    background-image: repeating-linear-gradient(
        118deg,
        transparent 0,
        transparent 56px,
        rgba(255, 245, 232, 0.05) 56px,
        rgba(255, 245, 232, 0.05) 57px
    );
    pointer-events: none;
    z-index: 0;
}

/* Diagonal bottom edge */
.hero-section::after {
    content: '';
    position: absolute;
    left: -2vw;
    right: -2vw;
    bottom: -7vh;
    height: 14vh;
    background: #D06030;
    transform: skewY(-6deg);
    transform-origin: 0 100%;
    z-index: 2;
    box-shadow: 0 8px 0 0 rgba(58, 26, 10, 0.05);
}

.hero-content {
    position: relative;
    z-index: 5;
    text-align: center;
    padding: 0 6vw;
}

.hero-title {
    font-size: clamp(48px, 11vw, 168px);
    color: #FFF5E8;
    letter-spacing: -0.045em;
    line-height: 0.92;
    text-transform: uppercase;
    margin: 0;
    display: inline-block;
    min-height: 1em;
}

.hero-title .letter {
    display: inline-block;
    opacity: 0;
    transform: translateY(0.4em) scale(1.1);
    transition: transform 360ms cubic-bezier(0.34, 1.56, 0.64, 1),
        opacity 360ms ease-out;
    text-shadow: 0 4px 0 rgba(58, 26, 10, 0.12);
}

.hero-title .letter.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* alternating letter coloring for raw-authentic typography */
.hero-title .letter:nth-child(7n+3) {
    color: #FFE2C9;
}
.hero-title .letter:nth-child(11n+5) {
    color: #FF8040;
}

.hero-domain {
    display: inline-block;
    margin-top: clamp(8px, 1.4vw, 18px);
    font-family: 'Fredoka', sans-serif;
    font-weight: 500;
    font-size: clamp(28px, 4.4vw, 64px);
    color: #3A1A0A;
    letter-spacing: -0.02em;
    filter: blur(8px);
    opacity: 0;
    transition: filter 700ms ease-out, opacity 700ms ease-out;
    background: #FFF5E8;
    padding: 0.04em 0.32em 0.08em;
    border-radius: 0.18em;
    transform: rotate(-1.6deg);
}

.hero-domain.visible {
    filter: blur(0);
    opacity: 1;
}

.hero-tagline {
    margin-top: clamp(28px, 4vh, 48px);
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #FFE2C9;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 600ms ease-out 1500ms,
        transform 600ms ease-out 1500ms;
}

.hero-tagline.visible {
    opacity: 0.85;
    transform: translateY(0);
}

.tag-line {
    position: relative;
    padding: 0 0.8em;
}

.tag-line::before,
.tag-line::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 28px;
    height: 1px;
    background: #FFE2C9;
    opacity: 0.6;
}

.tag-line::before {
    right: 100%;
}

.tag-line::after {
    left: 100%;
}

.hero-coords {
    position: absolute;
    top: clamp(20px, 3vh, 36px);
    right: clamp(20px, 3vw, 36px);
    z-index: 6;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    color: #FFF5E8;
    letter-spacing: 0.1em;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    opacity: 0;
    transition: opacity 600ms ease-out 1700ms;
}

.hero-coords.visible {
    opacity: 0.7;
}

.coord-label {
    font-size: 10px;
    opacity: 0.6;
}

/* ============================================================
   COMPARISON SECTIONS - Tilted Standards (4 x ~100vh)
   ============================================================ */

.comparison-section {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-top: -5vh;
    padding: clamp(60px, 9vh, 120px) 0;
}

/* Diagonal clipping uses CSS clip-path polygon for crisp edges */
.comp-1 {
    background: #FFF5E8;
    color: #3A1A0A;
    clip-path: polygon(0 6vh, 100% 0, 100% calc(100% - 6vh), 0 100%);
    z-index: 9;
}

.comp-2 {
    background: #FF8040;
    color: #3A1A0A;
    clip-path: polygon(0 0, 100% 6vh, 100% 100%, 0 calc(100% - 6vh));
    z-index: 8;
}

.comp-3 {
    background: #3A1A0A;
    color: #FFF5E8;
    clip-path: polygon(0 6vh, 100% 0, 100% calc(100% - 6vh), 0 100%);
    z-index: 7;
}

.comp-4 {
    background: #508050;
    color: #FFF5E8;
    clip-path: polygon(0 0, 100% 6vh, 100% 100%, 0 calc(100% - 6vh));
    z-index: 6;
}

.comparison-inner {
    position: relative;
    width: min(1100px, 90vw);
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: clamp(32px, 5vw, 64px);
    padding: clamp(32px, 5vw, 64px);
    will-change: transform;
}

/* Sliding entry along the section's diagonal slope */
.comp-1 .comparison-inner,
.comp-3 .comparison-inner {
    transform: translateY(50px) translateX(-30px);
    opacity: 0;
    transition: transform 900ms cubic-bezier(0.16, 1, 0.3, 1) 100ms,
        opacity 700ms ease-out 100ms;
}

.comp-2 .comparison-inner,
.comp-4 .comparison-inner {
    transform: translateY(50px) translateX(30px);
    opacity: 0;
    transition: transform 900ms cubic-bezier(0.16, 1, 0.3, 1) 100ms,
        opacity 700ms ease-out 100ms;
}

.comparison-section.in-view .comparison-inner {
    transform: translateY(0) translateX(0);
    opacity: 1;
}

.comp-index {
    grid-column: 1 / -1;
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    opacity: 0.55;
    margin-bottom: clamp(8px, 1.2vh, 14px);
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.comp-index::before {
    content: '';
    width: 28px;
    height: 1px;
    background: currentColor;
    opacity: 0.6;
}

.comparison-heading {
    font-size: clamp(36px, 6vw, 80px);
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin-bottom: clamp(16px, 2.4vh, 28px);
    grid-column: 1;
}

.comparison-body {
    grid-column: 1;
    font-size: clamp(15px, 1.2vw, 19px);
    line-height: 1.75;
    max-width: 38ch;
    opacity: 0.92;
}

.comparison-illustration {
    grid-column: 2;
    grid-row: 2 / 4;
    align-self: center;
    position: relative;
    padding: clamp(20px, 3vh, 32px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(12px, 1.6vh, 20px);
}

.illustration-pair {
    display: flex;
    align-items: center;
    gap: clamp(20px, 4vw, 56px);
    width: 100%;
    justify-content: center;
}

.illust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    cursor: default;
    transition: transform 320ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.illust-item:hover {
    transform: translateY(-4px) rotate(-1.5deg);
}

.illust-item.illust-b:hover {
    transform: translateY(-4px) rotate(1.5deg);
}

.comparison-svg {
    width: clamp(110px, 16vw, 170px);
    height: clamp(110px, 16vw, 170px);
    display: block;
    transition: filter 320ms ease-out;
}

.comparison-svg circle,
.comparison-svg rect,
.comparison-svg path,
.comparison-svg polygon,
.comparison-svg line,
.comparison-svg text {
    transition: fill 480ms cubic-bezier(0.4, 0, 0.2, 1),
        stroke 480ms cubic-bezier(0.4, 0, 0.2, 1);
}

.illust-item:hover .comparison-svg {
    filter: drop-shadow(0 6px 0 rgba(58, 26, 10, 0.18));
}

.illust-label {
    font-family: 'Fredoka', sans-serif;
    font-weight: 500;
    font-size: clamp(15px, 1.2vw, 18px);
    letter-spacing: 0.02em;
}

.illust-vs {
    font-family: 'Fredoka', sans-serif;
    font-weight: 600;
    font-size: clamp(20px, 2.2vw, 32px);
    opacity: 0.35;
    transform: rotate(-6deg);
    user-select: none;
}

.swap-hint {
    margin-top: 4px;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    opacity: 0.45;
}

/* Color-swap state (toggled by JS on hover) */
.comparison-illustration.swapped .swap-fill-a {
    fill: #2A1008;
}

.comparison-illustration.swapped .swap-fill-b {
    fill: #FFF5E8;
}

.comparison-illustration.swapped .swap-fill-c {
    fill: #FFF5E8;
}

.comparison-illustration.swapped .swap-fill-d {
    fill: #D06030;
}

.comparison-illustration.swapped .swap-stroke-d {
    stroke: #FFF5E8;
}

/* Per-comparison swap accents */
.comp-1 .comparison-illustration.swapped .swap-fill-a { fill: #3A1A0A; }
.comp-1 .comparison-illustration.swapped .swap-fill-c { fill: #FFF5E8; }
.comp-1 .comparison-illustration.swapped .swap-fill-d { fill: #D06030; }

.comp-2 .comparison-illustration.swapped .swap-fill-a { fill: #D06030; }
.comp-2 .comparison-illustration.swapped .swap-fill-c { fill: #508050; }

.comp-3 .comparison-illustration.swapped .swap-fill-a { fill: #2A1008; }
.comp-3 .comparison-illustration.swapped .swap-fill-c { fill: #FF8040; }

.comp-4 .comparison-illustration.swapped .swap-fill-a { fill: #D06030; }
.comp-4 .comparison-illustration.swapped .swap-fill-b { fill: #FFF5E8; }
.comp-4 .comparison-illustration.swapped .swap-fill-c { fill: #FFF5E8; }
.comp-4 .comparison-illustration.swapped .swap-fill-d { fill: #508050; }

/* Diagonal ripple effect */
.comparison-section.ripple::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        118deg,
        transparent 0%,
        rgba(255, 245, 232, 0.04) 50%,
        transparent 100%
    );
    animation: ripple 320ms ease-out;
    mix-blend-mode: overlay;
}

@keyframes ripple {
    0%   { opacity: 0; transform: translateX(-30px); }
    50%  { opacity: 1; }
    100% { opacity: 0; transform: translateX(30px); }
}

/* ============================================================
   FLOATING ELEMENTS INTERLUDE (100vh)
   ============================================================ */

.interlude-section {
    position: relative;
    width: 100%;
    height: 100vh;
    background: #FFF5E8;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 5;
    margin-top: -5vh;
    color: #3A1A0A;
}

.floating-container {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.floating-icon {
    position: absolute;
    pointer-events: auto;
    cursor: default;
    transition: transform 360ms cubic-bezier(0.34, 1.56, 0.64, 1),
        filter 360ms ease-out;
    will-change: transform;
}

.floating-icon svg {
    display: block;
    width: 100%;
    height: 100%;
}

.floating-icon:hover {
    transform: scale(1.35) !important;
    filter: drop-shadow(0 4px 0 rgba(58, 26, 10, 0.15));
    animation-play-state: paused;
}

.floating-icon.pulse {
    animation: pulse-icon 1.2s ease-in-out infinite;
}

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

.interlude-text {
    position: relative;
    z-index: 5;
    text-align: center;
    padding: 0 6vw;
    pointer-events: none;
}

.interlude-eyebrow {
    display: inline-block;
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #D06030;
    opacity: 0.7;
    margin-bottom: clamp(14px, 2vh, 22px);
}

.interlude-heading {
    font-size: clamp(44px, 8vw, 110px);
    margin-bottom: clamp(12px, 1.6vh, 20px);
}

.interlude-body {
    font-size: clamp(16px, 1.4vw, 22px);
    opacity: 0.7;
    max-width: 36ch;
    margin: 0 auto;
}

/* ============================================================
   BLUR-FOCUS DEEP DIVE (80vh)
   ============================================================ */

.blur-focus-section {
    position: relative;
    width: 100%;
    min-height: 80vh;
    background: #2A1008;
    color: #FFF5E8;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(60px, 10vh, 120px) 6vw;
    overflow: hidden;
}

.blur-focus-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(
        ellipse at center,
        rgba(255, 245, 232, 0.04) 0%,
        rgba(255, 245, 232, 0) 60%
    );
    pointer-events: none;
}

.blur-focus-container {
    position: relative;
    width: min(1200px, 92vw);
    display: grid;
    grid-template-columns: 1fr 1.4fr 1fr;
    gap: clamp(20px, 3vw, 36px);
    align-items: center;
}

.blur-panel {
    font-family: 'Quicksand', sans-serif;
    font-size: clamp(14px, 1vw, 17px);
    line-height: 1.7;
    color: #FFE2C9;
    filter: blur(6px);
    opacity: 0.55;
    transition: filter 600ms ease-out, opacity 600ms ease-out;
    padding: clamp(20px, 3vh, 32px);
    border-left: 1px solid rgba(255, 245, 232, 0.1);
}

.blur-panel.blur-right {
    border-left: none;
    border-right: 1px solid rgba(255, 245, 232, 0.1);
    text-align: right;
}

.blur-panel.shifted {
    filter: blur(2px);
    opacity: 0.85;
}

.focus-center {
    position: relative;
    text-align: center;
    padding: clamp(28px, 4vh, 48px) clamp(16px, 2vw, 32px);
    background: rgba(58, 26, 10, 0.5);
    border-radius: 18px;
    box-shadow: 0 24px 48px -24px rgba(0, 0, 0, 0.6);
    transform: scale(0.96);
    transition: transform 800ms cubic-bezier(0.16, 1, 0.3, 1);
}

.blur-focus-section.in-view .focus-center {
    transform: scale(1);
}

.focus-eyebrow {
    display: inline-block;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: #FF8040;
    margin-bottom: clamp(12px, 1.6vh, 18px);
    padding: 4px 10px;
    border: 1px solid rgba(255, 128, 64, 0.3);
    border-radius: 999px;
}

.focus-heading {
    font-size: clamp(32px, 4.4vw, 56px);
    line-height: 1.1;
    margin-bottom: clamp(14px, 1.8vh, 22px);
    color: #FFF5E8;
}

.focus-body {
    font-size: clamp(15px, 1.15vw, 19px);
    line-height: 1.75;
    color: #FFE2C9;
    opacity: 0.92;
    margin: 0 auto;
}

.blur-progress {
    position: absolute;
    left: 50%;
    bottom: clamp(20px, 3vh, 32px);
    transform: translateX(-50%);
    width: clamp(120px, 18vw, 220px);
    height: 2px;
    background: rgba(255, 245, 232, 0.12);
    overflow: hidden;
    border-radius: 2px;
}

.blur-progress-fill {
    width: 0%;
    height: 100%;
    background: #FF8040;
    transition: width 200ms linear;
}

/* ============================================================
   LEVEL GROUND FOOTER (50vh)
   ============================================================ */

.footer-section {
    position: relative;
    width: 100%;
    min-height: 50vh;
    background: #FFF5E8;
    color: #3A1A0A;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: clamp(48px, 8vh, 96px) 6vw;
    text-align: center;
}

.footer-line {
    width: 0%;
    height: 2px;
    background: #3A1A0A;
    margin-bottom: clamp(28px, 4.5vh, 56px);
    transition: width 1100ms cubic-bezier(0.16, 1, 0.3, 1);
    max-width: min(600px, 80vw);
}

.footer-section.in-view .footer-line {
    width: min(600px, 80vw);
}

.footer-content {
    max-width: 720px;
}

.footer-eyebrow {
    display: inline-block;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: #508050;
    margin-bottom: clamp(14px, 2vh, 22px);
}

.footer-heading {
    font-size: clamp(40px, 7vw, 96px);
    margin-bottom: clamp(14px, 2vh, 22px);
}

.footer-body {
    font-size: clamp(15px, 1.2vw, 19px);
    line-height: 1.75;
    opacity: 0.7;
    margin: 0 auto clamp(28px, 4.5vh, 56px);
    max-width: 48ch;
}

.footer-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(12px, 2vw, 24px);
    font-family: 'Space Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.14em;
    color: #3A1A0A;
    opacity: 0.55;
    text-transform: uppercase;
}

.footer-rule {
    display: inline-block;
    width: 28px;
    height: 1px;
    background: currentColor;
    opacity: 0.5;
}

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

@media (max-width: 880px) {
    .comparison-inner {
        grid-template-columns: 1fr;
        gap: clamp(20px, 3vh, 32px);
    }

    .comparison-heading,
    .comparison-body,
    .comparison-illustration {
        grid-column: 1;
    }

    .comparison-illustration {
        grid-row: auto;
    }

    .comp-1,
    .comp-2,
    .comp-3,
    .comp-4 {
        clip-path: polygon(0 0, 100% 3vh, 100% 100%, 0 calc(100% - 3vh));
    }

    .comp-1,
    .comp-3 {
        clip-path: polygon(0 3vh, 100% 0, 100% calc(100% - 3vh), 0 100%);
    }

    .hero-section::after {
        height: 8vh;
        transform: skewY(4deg);
    }

    .blur-focus-container {
        grid-template-columns: 1fr;
    }

    .blur-panel {
        border-left: none;
        border-right: none;
        border-top: 1px solid rgba(255, 245, 232, 0.1);
        border-bottom: 1px solid rgba(255, 245, 232, 0.1);
    }

    .blur-panel.blur-right {
        text-align: left;
    }

    .comp-1 .comparison-inner,
    .comp-3 .comparison-inner {
        transform: translateY(40px) translateX(0);
    }

    .comp-2 .comparison-inner,
    .comp-4 .comparison-inner {
        transform: translateY(40px) translateX(0);
    }
}

@media (max-width: 540px) {
    .hero-coords {
        font-size: 10px;
    }

    .illustration-pair {
        gap: 20px;
    }

    .comparison-svg {
        width: 100px;
        height: 100px;
    }
}

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

    .floating-icon {
        animation: none !important;
    }
}
