/* ==========================================================================
   DESIGN SYSTEM & VARIABLES (Japanese 3D Paper & Wind Zen Theme)
   ========================================================================== */
:root {
    --paper-white: #F6F1E6;
    --ink-black: #1A1A1A;
    --soft-red: #B0463C;
    --bamboo-green: #6C7A5C;
    --stone-beige: #CBBBA0;
    --stone-light: #EBE5D8;
    
    /* System Elements */
    --text-primary: #1A1A1A;
    --text-secondary: #5C5549;
    --text-muted: #8E8474;
    --border-color: rgba(26, 26, 26, 0.12);
    --border-thick: 1px solid var(--stone-beige);
    
    /* Shadow Matrix (Origami paper layering depth) */
    --shadow-flat: 0 1px 2px rgba(26, 26, 26, 0.05);
    --shadow-soft: 0 4px 10px rgba(26, 26, 26, 0.06);
    --shadow-origami-1: -4px 6px 15px rgba(26, 26, 26, 0.08);
    --shadow-origami-2: 8px 12px 25px rgba(26, 26, 26, 0.12);
    --shadow-origami-3: -12px 18px 40px rgba(26, 26, 26, 0.15);
    
    /* Core Typography */
    --font-serif: 'Noto Serif JP', Georgia, serif;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    
    /* Layout Transitions */
    --transition-zen: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    --transition-quick: all 0.2s ease;
}

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

html {
    scroll-behavior: smooth;
    background-color: var(--paper-white);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

body {
    overflow-x: hidden;
    position: relative;
    background-color: var(--paper-white);
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

button {
    font-family: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

/* ==========================================================================
   LAYOUT SYSTEM (Zen Breathing Spaces)
   ========================================================================== */
.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 120px 24px;
    position: relative;
}

.bg-muted {
    background-color: var(--stone-light);
    border-top: 1px solid rgba(26, 26, 26, 0.05);
    border-bottom: 1px solid rgba(26, 26, 26, 0.05);
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.bg-muted > * {
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

/* Section Header Typography */
.section-header {
    max-width: 700px;
    margin-bottom: 80px;
}

.section-title-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.section-number {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--soft-red);
}

.section-title {
    font-family: var(--font-serif);
    font-size: 2.5rem;
    font-weight: 500;
    color: var(--ink-black);
    letter-spacing: -0.5px;
}

.section-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ==========================================================================
   NAVIGATION HEADER
   ========================================================================== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(246, 241, 230, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(26, 26, 26, 0.05);
    z-index: 1000;
    transition: var(--transition-zen);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink-black);
}

.logo-dot {
    width: 12px;
    height: 12px;
    background-color: var(--soft-red);
    border-radius: 50%;
    display: inline-block;
}

.nav-list {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 0.938rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition-quick);
    position: relative;
    padding: 4px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1.5px;
    background-color: var(--soft-red);
    transition: var(--transition-zen);
}

.nav-link:hover {
    color: var(--ink-black);
}

.nav-link:hover::after {
    width: 100%;
}

/* Hamburger mobile button */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    z-index: 1001;
}

.hamburger-bar {
    width: 24px;
    height: 2px;
    background-color: var(--ink-black);
    transition: var(--transition-quick);
}

/* ==========================================================================
   SECTION 1: HERO / TOURNAMENT FEATURE
   ========================================================================== */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
    padding: 0 24px;
    z-index: 1;
}

.hero-bg-canvas-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background-color: #F0EAE1;
}

.wind-particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* 3D Paper Layer Visual Emulation (Origami style) */
.origami-layer {
    position: absolute;
    background: var(--paper-white);
    border: 1px solid rgba(26, 26, 26, 0.05);
    transition: transform 1.2s cubic-bezier(0.1, 0.8, 0.3, 1);
}

.layer-1 {
    width: 45%;
    height: 60%;
    right: -10%;
    top: 15%;
    transform: rotate3d(1, -1, 0, 15deg) translateZ(40px);
    box-shadow: var(--shadow-origami-3);
    border-radius: 4px;
    z-index: 1;
}

.layer-2 {
    width: 35%;
    height: 50%;
    right: 15%;
    top: 30%;
    transform: rotate3d(1.5, 0.5, -0.5, 25deg) translateZ(80px);
    box-shadow: var(--shadow-origami-2);
    border-radius: 4px;
    background-color: var(--stone-light);
    z-index: 2;
}

.layer-3 {
    width: 20%;
    height: 30%;
    right: 8%;
    top: 45%;
    transform: rotate3d(-0.5, 1.5, 0.5, -15deg) translateZ(120px);
    box-shadow: var(--shadow-origami-1);
    border-radius: 2px;
    background-color: var(--stone-beige);
    opacity: 0.95;
    z-index: 3;
}

/* Hero Content */
.hero-container {
    max-width: 750px;
    margin-left: calc((100vw - 1200px) / 2 + 24px);
    position: relative;
    z-index: 10;
}

@media(max-width: 1250px) {
    .hero-container {
        margin-left: 40px;
    }
}

.hero-badge {
    display: inline-flex;
    padding: 6px 16px;
    background: rgba(176, 70, 60, 0.08);
    border: 1px solid var(--soft-red);
    border-radius: 100px;
    margin-bottom: 24px;
}

.badge-text {
    font-size: 0.813rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--soft-red);
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 4.5rem;
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -1.5px;
    color: var(--ink-black);
    margin-bottom: 24px;
}

.hero-title .text-serif {
    font-style: italic;
    font-weight: 300;
}

.hero-subtitle {
    font-size: 1.188rem;
    color: var(--text-secondary);
    max-width: 580px;
    margin-bottom: 40px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 16px;
    align-items: center;
}

/* serener custom button styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    font-size: 0.938rem;
    font-weight: 600;
    border-radius: 4px;
    transition: var(--transition-zen);
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--ink-black);
    color: var(--paper-white);
    box-shadow: var(--shadow-flat);
}

.btn-primary:hover {
    background-color: var(--soft-red);
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

.btn-secondary {
    border-color: var(--stone-beige);
    color: var(--ink-black);
}

.btn-secondary:hover {
    background-color: rgba(26, 26, 26, 0.05);
    border-color: var(--ink-black);
    transform: translateY(-2px);
}

/* ==========================================================================
   SECTION 2: EDITORIAL MATCH INDEX (Zen Grid Pattern)
   ========================================================================== */
.match-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.match-card {
    background-color: var(--paper-white);
    border: var(--border-thick);
    padding: 32px;
    border-radius: 4px;
    box-shadow: var(--shadow-flat);
    transition: var(--transition-zen);
    position: relative;
    cursor: pointer;
    overflow: hidden;
}

.match-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background-color: var(--soft-red);
    transform: scaleY(0);
    transition: var(--transition-zen);
    transform-origin: bottom;
}

.match-card:hover {
    transform: translateY(-5px) scale(1.01);
    box-shadow: var(--shadow-origami-2);
}

.match-card:hover::before {
    transform: scaleY(1);
}

.match-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    border-bottom: 1px dashed rgba(26, 26, 26, 0.1);
    padding-bottom: 12px;
}

.group-tag {
    font-size: 0.813rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--bamboo-green);
}

.match-id {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
}

.match-card-teams {
    margin-bottom: 28px;
}

.match-team-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0;
}

.team-name {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--ink-black);
}

.team-rank {
    font-size: 0.813rem;
    color: var(--text-muted);
    background-color: var(--stone-light);
    padding: 2px 8px;
    border-radius: 2px;
}

.vs-divider {
    font-family: var(--font-serif);
    font-style: italic;
    color: var(--text-muted);
    font-size: 0.938rem;
    text-align: center;
    margin: 4px 0;
    position: relative;
}

.vs-divider::before, .vs-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background-color: rgba(26, 26, 26, 0.08);
}

.vs-divider::before { left: 0; }
.vs-divider::after { right: 0; }

.match-card-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    background-color: var(--stone-light);
    padding: 16px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.stat-mini {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.stat-value {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--ink-black);
}

.match-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.read-more-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--soft-red);
}

.arrow-icon {
    width: 18px;
    height: 18px;
    color: var(--soft-red);
    transition: var(--transition-zen);
}

.match-card:hover .arrow-icon {
    transform: translateX(4px);
}

/* ==========================================================================
   SECTION 3: TOP TITLE CONTEXT
   ========================================================================== */
.favorites-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.favorite-card {
    background-color: var(--paper-white);
    border: var(--border-thick);
    padding: 40px 32px;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    transition: var(--transition-zen);
}

.favorite-card:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-origami-1);
    border-color: var(--soft-red);
}

.favorite-card.highlight-card {
    background-color: var(--paper-white);
    border-color: var(--soft-red);
    box-shadow: var(--shadow-flat);
}

.favorite-rank-badge {
    position: absolute;
    top: -10px;
    right: -10px;
    font-family: var(--font-serif);
    font-size: 5rem;
    font-weight: 700;
    color: rgba(176, 70, 60, 0.05);
    line-height: 1;
    pointer-events: none;
    user-select: none;
}

.favorite-card.highlight-card .favorite-rank-badge {
    color: rgba(176, 70, 60, 0.08);
}

.favorite-body h3 {
    font-family: var(--font-serif);
    font-size: 1.875rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 6px;
}

.favorite-meta {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.favorite-meters {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.meter-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.meter-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
}

.meter-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ink-black);
}

.meter-value-sub {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--bamboo-green);
}

.meter-bar-outer {
    width: 100%;
    height: 6px;
    background-color: var(--stone-light);
    border-radius: 10px;
    overflow: hidden;
}

.meter-bar-inner {
    height: 100%;
    background-color: var(--soft-red);
    border-radius: 10px;
}

/* ==========================================================================
   SECTION 4: EXPANDED MATCH PREVIEWS
   ========================================================================== */
.previews-list {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

.preview-item {
    display: flex;
    gap: 48px;
    background-color: var(--paper-white);
    border: var(--border-thick);
    padding: 48px;
    border-radius: 4px;
    box-shadow: var(--shadow-flat);
    position: relative;
    transition: var(--transition-zen);
    scroll-margin-top: 100px;
}

.preview-item:hover {
    box-shadow: var(--shadow-origami-2);
}

.preview-number {
    font-family: var(--font-serif);
    font-size: 3rem;
    font-weight: 500;
    color: var(--stone-beige);
    line-height: 1;
}

.preview-content {
    flex: 1;
}

.group-label {
    font-size: 0.813rem;
    font-weight: 700;
    color: var(--bamboo-green);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 12px;
}

.preview-title {
    font-family: var(--font-serif);
    font-size: 2.25rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 32px;
}

/* Dynamic Matchup Compare System */
.comparison-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 32px;
    align-items: center;
    background-color: var(--stone-light);
    padding: 32px;
    border-radius: 4px;
    margin-bottom: 32px;
}

.compare-team {
    display: flex;
    flex-direction: column;
}

.compare-team.b {
    text-align: right;
}

.compare-team-name {
    font-family: var(--font-serif);
    font-size: 1.75rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 16px;
}

.compare-metrics-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.compare-metrics-list li {
    font-size: 0.938rem;
    color: var(--text-secondary);
}

.compare-metrics-list li strong {
    color: var(--ink-black);
    font-weight: 600;
}

.compare-vs {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.5rem;
    color: var(--soft-red);
    padding: 12px;
    background-color: var(--paper-white);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-flat);
}

.preview-editorial {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-primary);
    max-width: 800px;
}

/* ==========================================================================
   SECTION 5: GROUP RACE CONTEXT
   ========================================================================== */
.groups-summary-wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.group-summary-card {
    background-color: var(--paper-white);
    border: var(--border-thick);
    border-radius: 4px;
    padding: 32px;
    box-shadow: var(--shadow-flat);
}

.group-header {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 24px;
    border-bottom: 2px solid var(--stone-beige);
    padding-bottom: 8px;
}

.group-battle {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.team-bar-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-radius: 4px;
}

.team-bar-item.positive {
    background-color: rgba(108, 122, 92, 0.08);
    border-left: 4px solid var(--bamboo-green);
}

.team-bar-item.negative {
    background-color: rgba(176, 70, 60, 0.04);
    border-left: 4px solid var(--stone-beige);
}

.team-bar-item .name {
    font-weight: 600;
    color: var(--ink-black);
}

.team-bar-item .chance {
    font-size: 0.938rem;
    font-weight: 500;
    color: var(--text-secondary);
}

/* ==========================================================================
   SECTION 6: HOST NATIONS WATCH
   ========================================================================== */
.hosts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.host-card {
    background-color: var(--paper-white);
    border: var(--border-thick);
    border-radius: 4px;
    padding: 40px;
    box-shadow: var(--shadow-flat);
    transition: var(--transition-zen);
}

.host-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-origami-2);
    border-color: var(--soft-red);
}

.host-badge {
    display: inline-block;
    padding: 4px 12px;
    background-color: var(--stone-light);
    color: var(--soft-red);
    font-size: 0.813rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 2px;
    margin-bottom: 20px;
}

.host-main-rank {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 8px;
}

.host-group-info {
    font-size: 0.938rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.host-metrics {
    border-top: 1px solid rgba(26, 26, 26, 0.08);
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.host-metrics .metric-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.938rem;
}

.host-metrics .lbl {
    color: var(--text-secondary);
}

.host-metrics .val {
    font-weight: 700;
    color: var(--ink-black);
}

.host-metrics .val-sub {
    font-weight: 600;
    color: var(--bamboo-green);
}

/* ==========================================================================
   SECTION 7: GUIDE / METHOD NOTE
   ========================================================================== */
.methodology-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.methodology-card {
    background-color: var(--paper-white);
    border-left: 3px solid var(--soft-red);
    padding: 32px;
    border-radius: 4px;
    box-shadow: var(--shadow-flat);
}

.methodology-card h3 {
    font-family: var(--font-serif);
    font-size: 1.375rem;
    font-weight: 500;
    color: var(--ink-black);
    margin-bottom: 16px;
}

.methodology-card p {
    font-size: 0.938rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ==========================================================================
   SECTION 8: FAQ (Serene Accordion)
   ========================================================================== */
.faq-accordion {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    background-color: var(--paper-white);
    border: var(--border-thick);
    border-radius: 4px;
    overflow: hidden;
    transition: var(--transition-zen);
}

.faq-trigger {
    width: 100%;
    padding: 24px 32px;
    text-align: left;
    font-family: var(--font-serif);
    font-size: 1.188rem;
    font-weight: 500;
    color: var(--ink-black);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--paper-white);
}

.faq-icon {
    font-size: 1.5rem;
    color: var(--soft-red);
    transition: var(--transition-zen);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    padding: 0 32px;
    background-color: var(--stone-light);
}

.faq-answer p {
    padding-bottom: 24px;
    padding-top: 12px;
    color: var(--text-secondary);
    line-height: 1.7;
}

.faq-item.active .faq-answer {
    max-height: 200px;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

/* ==========================================================================
   COOKIE CONSENT BANNER
   ========================================================================== */
.cookie-consent-banner {
    position: fixed;
    bottom: 24px;
    left: 24px;
    right: 24px;
    max-width: 600px;
    background-color: var(--paper-white);
    border: 2px solid var(--ink-black);
    box-shadow: var(--shadow-origami-3);
    padding: 24px;
    border-radius: 4px;
    z-index: 10000;
    display: none;
    transform: translateY(100px);
    opacity: 0;
    transition: var(--transition-zen);
}

.cookie-consent-banner.show {
    display: block;
    transform: translateY(0);
    opacity: 1;
}

.cookie-banner-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.cookie-text {
    font-size: 0.875rem;
    color: var(--text-primary);
}

.cookie-link {
    color: var(--soft-red);
    text-decoration: underline;
    font-weight: 600;
}

.cookie-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.btn-cookie-primary {
    background-color: var(--ink-black);
    color: var(--paper-white);
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.813rem;
    transition: var(--transition-quick);
}

.btn-cookie-primary:hover {
    background-color: var(--soft-red);
}

.btn-cookie-secondary {
    border: 1px solid var(--stone-beige);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.813rem;
    transition: var(--transition-quick);
}

.btn-cookie-secondary:hover {
    background-color: var(--stone-light);
    color: var(--ink-black);
}

/* ==========================================================================
   SPA / LEGAL MODAL SYSTEM
   ========================================================================== */
.legal-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(26, 26, 26, 0.4);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-zen);
}

.legal-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.legal-modal-container {
    background-color: var(--paper-white);
    border: var(--border-thick);
    width: 90%;
    max-width: 800px;
    max-height: 80vh;
    border-radius: 4px;
    box-shadow: var(--shadow-origami-3);
    position: relative;
    display: flex;
    flex-direction: column;
}

.legal-modal-close {
    position: absolute;
    top: 24px;
    right: 24px;
    font-size: 2rem;
    color: var(--text-secondary);
    transition: var(--transition-quick);
}

.legal-modal-close:hover {
    color: var(--soft-red);
}

.legal-modal-content {
    padding: 48px;
    overflow-y: auto;
    font-family: var(--font-sans);
}

.legal-modal-content h2 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 16px;
    color: var(--ink-black);
}

.legal-modal-content h3 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    margin-top: 24px;
    margin-bottom: 12px;
    color: var(--ink-black);
}

.legal-modal-content p, .legal-modal-content li {
    font-size: 0.938rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
    line-height: 1.6;
}

.legal-modal-content ul {
    list-style-type: disc;
    padding-left: 20px;
    margin-bottom: 16px;
}

/* ==========================================================================
   FOOTER (Serene and Compliant with Address Blocks)
   ========================================================================== */
.site-footer {
    background-color: var(--ink-black);
    color: var(--paper-white);
    padding: 80px 24px 40px;
    margin-top: 80px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand-info {
    max-width: 400px;
}

.footer-logo {
    font-family: var(--font-serif);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--paper-white);
    margin-bottom: 12px;
    display: block;
}

.footer-tagline {
    font-size: 0.938rem;
    color: var(--stone-beige);
}

.footer-links-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-heading {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    color: var(--paper-white);
}

.footer-legal-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-link-item {
    font-size: 0.875rem;
    color: var(--stone-beige);
    transition: var(--transition-quick);
}

.footer-link-item:hover {
    color: var(--soft-red);
}

.footer-divider {
    height: 1px;
    background-color: rgba(246, 241, 230, 0.1);
    margin-bottom: 40px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 32px;
}

.footer-address {
    max-width: 350px;
    font-size: 0.875rem;
    color: var(--stone-beige);
}

.address-text {
    font-weight: 600;
    color: var(--paper-white);
    margin-top: 4px;
}

.footer-copyright {
    text-align: right;
    max-width: 600px;
    font-size: 0.813rem;
    color: var(--stone-beige);
}

.disclaimer-note {
    font-size: 0.75rem;
    color: rgba(246, 241, 230, 0.5);
    margin-top: 8px;
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS (Mobile & Tablet Optimization)
   ========================================================================== */
@media (max-width: 1200px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .match-grid {
        gap: 24px;
    }
}

@media (max-width: 992px) {
    .favorites-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hosts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .methodology-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .section-container {
        padding: 80px 24px;
    }
    
    .site-header {
        padding: 8px 0;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background-color: var(--paper-white);
        border-bottom: 1px solid var(--border-color);
        padding: 24px;
        display: none;
        z-index: 999;
    }
    
    .nav-menu.active {
        display: block;
    }
    
    .nav-list {
        flex-direction: column;
        gap: 20px;
    }
    
    .hero-section {
        height: auto;
        min-height: auto;
        padding-top: 140px;
        padding-bottom: 80px;
    }
    
    .hero-container {
        margin-left: 0;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.75rem;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .origami-layer {
        display: none; /* Simplify background for standard mobile performance */
    }
    
    .match-grid {
        grid-template-columns: 1fr;
    }
    
    .favorites-grid {
        grid-template-columns: 1fr;
    }
    
    .preview-item {
        flex-direction: column;
        gap: 24px;
        padding: 24px;
    }
    
    .comparison-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .compare-team.b {
        text-align: center;
    }
    
    .compare-vs {
        margin: 16px auto;
    }
    
    .groups-summary-wrapper {
        grid-template-columns: 1fr;
    }
    
    .hosts-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: left;
    }
    
    .footer-copyright {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.25rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .preview-title {
        font-size: 1.75rem;
    }
}