        :root {
            --header-bg: #1a1f2e;
            --header-text: #ffffff;
            --bg-primary: #ffffff;
            --bg-secondary: #f8f9fa;
            --bg-card: #ffffff;
            --text-primary: #1a202c;
            --text-secondary: #4a5568;
            --text-muted: #6b7280;
            --accent-teal: #2b6cb0;
            --accent-coral: #996060;
            --accent-warm: #c05621;
            --accent-green: #2f855a;
            --border: #e2e8f0;
            --shadow: 0 1px 3px rgba(0,0,0,0.08);
            --chart-line-1: #2b6cb0;
            --chart-line-2: #c05621;
            --chart-line-3: #2f855a;
        }

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

        body {
            font-family: 'DM Sans', 'Noto Sans JP', sans-serif;
            background: var(--bg-secondary);
            color: var(--text-primary);
            line-height: 1.6;
            min-height: 100vh;
        }

        body.ja {
            font-family: 'Noto Sans JP', 'DM Sans', sans-serif;
        }

        /* Header */
        header {
            background: var(--header-bg);
            color: var(--header-text);
            padding: 0.75rem 2rem;
            position: sticky;
            top: 0;
            z-index: 1001;
        }

        .header-content {
            max-width: 1200px;
            margin: 0 auto;
            display: flex;
            justify-content: flex-start;
            align-items: center;
        }

        .logo {
            margin-right: 2rem;
            font-weight: 600;
            font-size: 0.95rem;
            letter-spacing: -0.01em;
            display: flex;
            align-items: center;
            gap: 0.75rem;
            text-decoration: none;
            color: inherit;
        }

        .logo-icon {
            overflow: hidden;
            width: 28px;
            height: 28px;
            background: linear-gradient(135deg, #5b9a94 0%, #2b6cb0 100%);
            border-radius: 6px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.75rem;
        }

        .nav-links {
            display: flex;
            gap: 1.5rem;
            list-style: none;
        }

        .nav-links a {
            color: rgba(255,255,255,0.8);
            text-decoration: none;
            font-size: 0.9rem;
            font-weight: 500;
            transition: color 0.2s;
        }

        .nav-links a:hover, .nav-links a.active {
            color: #ffffff;
        }

        .header-controls {
            margin-left: auto;
            display: flex;
            align-items: center;
            gap: 1rem;
        }

        .lang-switch {
            font-size: 0.8rem;
            display: flex;
            gap: 0.25rem;
        }

        .lang-switch button {
            background: none;
            border: none;
            color: rgba(255,255,255,0.6);
            cursor: pointer;
            font-size: 0.8rem;
            padding: 0.25rem 0.5rem;
            border-radius: 4px;
            transition: all 0.2s;
        }

        .lang-switch button:hover {
            color: rgba(255,255,255,0.9);
        }

        .lang-switch button.active {
            color: #ffffff;
            background: rgba(255,255,255,0.15);
        }

        /* Main content */
        main {
            max-width: 1200px;
            margin: 0 auto;
            padding: 2.5rem 2rem;
        }

        /* Page sections */
        .page-section {
            display: none;
        }

        .page-section.active {
            display: block;
        }

        /* Hero */
        .hero {
            margin-bottom: 2.5rem;
        }

        .hero h1 {
            font-size: 1.75rem;
            font-weight: 600;
            letter-spacing: -0.02em;
            line-height: 1.3;
            margin-bottom: 1rem;
            color: var(--text-primary);
        }

        body.ja .hero h1 {
            font-size: 1.5rem;
            letter-spacing: 0;
        }

        .hero-subtitle {
            font-size: 0.75rem;
            color: var(--text-secondary);
            max-width: 720px;
            line-height: 1.7;
        }

        body.ja .hero-subtitle {
            line-height: 1.9;
        }

        /* Hero Visual Section */
.hero-visual {
    position: relative;
    min-height: 75vh;
    display: flex;
    align-items: center;
    margin: -2.5rem -2rem 3rem -2rem;
    padding: 4rem 2rem;
    background: linear-gradient(
        135deg, 
        rgba(26, 32, 46, 0.88) 0%, 
        rgba(26, 32, 46, 0.75) 50%,
        rgba(26, 32, 46, 0.65) 100%
    ), url('../images/hero.webp');
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.hero-visual-content {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    color: #ffffff;
}

.hero-visual h1 {
    font-size: 2.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin-bottom: 2rem;
    text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}

body.ja .hero-visual h1 {
    font-size: 2.2rem;
    letter-spacing: 0.05em;
}

.hero-visual-text {
    font-size: 1.05rem;
    line-height: 2;
    max-width: 640px;
    color: rgba(255, 255, 255, 0.92);
    margin-bottom: 2rem;
}

body.ja .hero-visual-text {
    line-height: 2.2;
}

.hero-visual-text p {
    margin-bottom: 1.2rem;
}

.hero-visual-text p:last-child {
    margin-bottom: 0;
}

.hero-visual-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #5b9a94;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.2s;
    margin-top: 1.5rem;
}

.hero-visual-link:hover {
    color: #7ab8b0;
    gap: 0.75rem;
}

.hero-visual-signature {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.55);
    font-style: italic;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    max-width: 640px;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.75rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-8px); }
    60% { transform: translateX(-50%) translateY(-4px); }
}

@media (max-width: 768px) {
    .hero-btn {
        font-size: 0.7rem;
        padding: 0.4rem 1rem;
        min-width: 120px;
    }
    .hero-btn-secondary {
        font-size: 0.65rem;
    }
    .hero-visual {
        min-height: 85vh;
        padding: 3rem 1.5rem;
        margin: -2.5rem -1rem 2rem -1rem;
    }
    
    .hero-visual h1 {
        font-size: 1.75rem;
    }
    
    body.ja .hero-visual h1 {
        font-size: 1.6rem;
    }
    
    .hero-visual-text {
        font-size: 0.95rem;
    }
    
    .scroll-indicator {
        bottom: 1.5rem;
    }
}


.diver-cta-card .title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.diver-cta-card .desc {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.diver-cta-card.coming-soon {
    opacity: 0.6;
    pointer-events: none;
}

.diver-cta-card.coming-soon .title::after {
    content: ' (準備中)';
    font-size: 0.7rem;
    color: var(--text-muted);
    font-weight: normal;
}

body:not(.ja) .diver-cta-card.coming-soon .title::after {
    content: ' (Coming Soon)';
}

        /* Section titles */
        .section-title {
            font-size: 1.1rem;
            font-weight: 600;
            margin-bottom: 1rem;
            color: var(--text-primary);
        }


        /* KPI Multi-value layout */
        .kpi-value-multi {
            display: flex;
            flex-direction: column;
            gap: 0.35rem;
            margin: 0.5rem 0;
        }
        .kpi-site {
            display: flex;
            align-items: center;
            gap: 0.4rem;
            font-size: 0.75rem;
            color: var(--text-secondary);
        }
        .kpi-site strong {
            font-family: 'JetBrains Mono', monospace;
            font-size: 1.1rem;
            color: var(--text-primary);
        }
        .kpi-site strong.warning {
            color: var(--accent-warm);
        }
        .kpi-site strong.alert {
            color: var(--accent-coral);
        }
        .site-dot {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            flex-shrink: 0;
        }

        /* KPI Cards */
        .kpi-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
            gap: 1rem;
            margin-bottom: 2.5rem;
        }

        .kpi-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            padding: 1.25rem 1.5rem;
            box-shadow: var(--shadow);
        }

        a.kpi-card-link {
            text-decoration: none;
            color: inherit;
            display: block;
            transition: all 0.2s ease;
        }

        a.kpi-card-link:hover {
            border-color: var(--accent-teal);
            box-shadow: 0 2px 8px rgba(43, 108, 176, 0.15);
            transform: translateY(-2px);
        }

        .kpi-label {
            font-size: 0.8rem;
            font-weight: 500;
            color: var(--text-muted);
            margin-bottom: 0.5rem;
        }

        .kpi-value {
            font-family: 'JetBrains Mono', monospace;
            font-size: 2rem;
            font-weight: 500;
            letter-spacing: -0.02em;
            line-height: 1;
            margin-bottom: 0.35rem;
            color: var(--text-primary);
        }

        .kpi-value.highlight { color: var(--accent-teal); }
        .kpi-value.warning { color: var(--accent-warm); }
        .kpi-value.alert { color: var(--accent-coral); }

        .kpi-context {
            font-size: 0.8rem;
            color: var(--text-muted);
        }

        .kpi-unit {
            font-size: 0.75rem;
            color: var(--text-muted);
            margin-left: 0.15rem;
        }

        /* Chart cards */
        .chart-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
            gap: 1rem;
            margin-bottom: 2.5rem;
        }

        .chart-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            padding: 1.25rem;
            box-shadow: var(--shadow);
        }

        .chart-header {
            margin-bottom: 1rem;
            padding-bottom: 0.75rem;
            border-bottom: 1px solid var(--border);
        }

        .chart-title {
            font-size: 0.75rem;
            font-weight: 600;
            color: var(--text-primary);
            margin-bottom: 0.25rem;
        }

        .chart-subtitle {
            font-size: 0.75rem;
            color: var(--text-muted);
        }

        .chart-container {
            height: 200px;
            position: relative;
        }

        .chart-svg {
            width: 100%;
            height: 100%;
        }

        .chart-line {
            fill: none;
            stroke-width: 1.5;
            stroke-linecap: round;
            stroke-linejoin: round;
        }

        .chart-line-1 { stroke: var(--chart-line-1); }
        .chart-line-2 { stroke: var(--chart-line-2); }
        .chart-line-3 { stroke: var(--chart-line-3); }

        .chart-grid-line {
            stroke: #e2e8f0;
            stroke-width: 1;
        }

        .chart-label {
            fill: var(--text-muted);
            font-size: 10px;
            font-family: 'JetBrains Mono', monospace;
        }

        .chart-legend {
            display: flex;
            gap: 1rem;
            margin-top: 0.75rem;
            flex-wrap: wrap;
        }

        .legend-item {
            display: flex;
            align-items: center;
            gap: 0.35rem;
            font-size: 0.7rem;
            color: var(--text-secondary);
        }

        .legend-line {
            width: 16px;
            height: 2px;
        }

        .legend-line-1 { background: var(--chart-line-1); }
        .legend-line-2 { background: var(--chart-line-2); }
        .legend-line-3 { background: var(--chart-line-3); }

        /* Info grid */
        .info-grid {
            display: grid;
            grid-template-columns: 2fr 1fr;
            gap: 1rem;
        }

        @media (max-width: 768px) {
    .hero-btn {
        font-size: 0.7rem;
        padding: 0.4rem 1rem;
        min-width: 120px;
    }
    .hero-btn-secondary {
        font-size: 0.65rem;
    }
            .info-grid {
                grid-template-columns: 1fr;
            }
        }

        .info-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            padding: 1.5rem;
            box-shadow: var(--shadow);
        }

        .info-card h3 {
            font-size: 0.9rem;
            font-weight: 600;
            margin-bottom: 1rem;
            color: var(--text-primary);
        }

        .info-card p {
            font-size: 0.9rem;
            color: var(--text-secondary);
            line-height: 1.75;
            margin-bottom: 0.75rem;
        }

        body.ja .info-card p {
            line-height: 1.9;
        }

        .info-card a.more-link {
            color: var(--accent-teal);
            text-decoration: none;
            font-weight: 500;
            font-size: 0.75rem;
        }

        .info-card a.more-link:hover {
            text-decoration: underline;
        }

        /* Source list */
        .source-list {
            list-style: none;
        }

        .source-item {
            display: flex;
            justify-content: flex-start;
            align-items: center;
            padding: 0.6rem 0;
            border-bottom: 1px solid var(--border);
            font-size: 0.75rem;
        }

        .source-item:last-child {
            border-bottom: none;
        }

        .source-name {
            color: var(--text-secondary);
        }

        .source-badge {
            font-size: 0.7rem;
            font-weight: 600;
            padding: 0.2rem 0.5rem;
            border-radius: 3px;
            text-transform: uppercase;
            letter-spacing: 0.03em;
        }

        .source-badge.active {
            background: #d4e8e0;
            color: #2a4a3d;
        }

        .source-badge.pending {
            background: #feebc8;
            color: #6b5a3d;
        }

        /* About page */
        .about-content {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            padding: 2.5rem;
            box-shadow: var(--shadow);
            max-width: 800px;
        }

        .about-content h1 {
            font-size: 1.5rem;
            font-weight: 600;
            margin-bottom: 2rem;
            color: var(--text-primary);
        }

        body.ja .about-content h1 {
            font-size: 1.35rem;
        }

        .about-content h2 {
            font-size: 1.1rem;
            font-weight: 600;
            margin-top: 2rem;
            margin-bottom: 0.75rem;
            color: var(--text-primary);
        }

        .about-content p {
            font-size: 0.95rem;
            color: var(--text-secondary);
            line-height: 1.85;
            margin-bottom: 1rem;
        }

        body.ja .about-content p {
            line-height: 2;
        }

        .about-signature {
            margin-top: 2.5rem;
            padding-top: 1.5rem;
            border-top: 1px solid var(--border);
            font-size: 0.75rem;
            color: var(--text-muted);
            font-style: italic;
        }

        /* Glossary page */
        .glossary-grid {
            display: grid;
            gap: 1rem;
        }

        .glossary-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 8px;
            padding: 1.5rem;
            box-shadow: var(--shadow);
        }

        .glossary-term {
            font-size: 0.75rem;
            font-weight: 600;
            color: var(--text-primary);
            margin-bottom: 0.25rem;
        }

        .glossary-term-en {
            font-size: 0.8rem;
            color: var(--text-muted);
            margin-bottom: 0.75rem;
        }

        .glossary-def {
            font-size: 0.9rem;
            color: var(--text-secondary);
            line-height: 1.75;
        }

        body.ja .glossary-def {
            line-height: 1.9;
        }

        .glossary-note {
            font-size: 0.8rem;
            color: var(--text-muted);
            margin-top: 0.5rem;
            padding-left: 0.75rem;
            border-left: 2px solid var(--border);
        }

        /* Footer */
        footer {
            background: var(--bg-card);
            border-top: 1px solid var(--border);
            padding: 1.5rem 2rem;
            margin-top: 2rem;
        }

        .footer-content {
            max-width: 1200px;
            margin: 0 auto;
            display: flex;
            justify-content: flex-start;
            align-items: center;
            flex-wrap: wrap;
            gap: 1rem;
            font-size: 0.8rem;
            color: var(--text-muted);
        }

        .footer-links {
            display: flex;
            gap: 1.5rem;
        }

        .footer-links a {
            color: var(--text-secondary);
            text-decoration: none;
        }

        .footer-links a:hover {
            color: var(--accent-teal);
        }

        /* Responsive */
        @media (max-width: 640px) {
            header { padding: 0.75rem 1rem; }
            main { padding: 1.5rem 1rem; }
            .nav-links { display: none; }
            .chart-grid { grid-template-columns: 1fr; }
            .about-content { padding: 1.5rem; }
        }

        /* Language toggle */
        [data-lang="ja"] { display: none; }
        body.ja [data-lang="en"] { display: none; }
        body.ja [data-lang="ja"] { display: block; }
        .breadcrumb [data-lang] { display: inline !important; }
        body.ja .breadcrumb [data-lang="en"] { display: none !important; }
        body:not(.ja) .breadcrumb [data-lang="ja"] { display: none !important; }
        body.ja .breadcrumb [data-lang="ja"] { display: inline !important; }
        span[data-lang="ja"], span[data-lang="en"] { display: inline; }
        body.ja span[data-lang="en"] { display: none; }
        body:not(.ja) span[data-lang="ja"] { display: none; }
    /* Dark mode support */
[data-theme="dark"] .six-card {
  background: #1e1e2e;
}
[data-theme="dark"] .six-card-title {
  color: #e0e0e0;
}
[data-theme="dark"] .six-card-desc {
  color: #a0a0a0;
}
@media (max-width: 900px) {
  .six-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  .six-card-grid {
    grid-template-columns: 1fr;
  }
}/* Six Card Section - Marine Identity */
/* Marine Monitor Section */
.marine-monitor {
    margin: 2.5rem 0;
}

.marine-monitor-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 1rem;
}

.marine-monitor-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.marine-monitor-update {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.marine-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.marine-summary-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.marine-summary-card:hover {
    background: #f8fafa;
    border-color: var(--accent-teal);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.marine-summary-card.expanded {
    border-color: var(--accent-teal);
}

.marine-card-header {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 0.5rem;
}

.marine-location {
    font-weight: 600;
    font-size: 0.95rem;
}

.marine-status {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.8rem;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-dot.good { background: #5a9a7a; }
.status-dot.caution { background: #ecc94b; }
.status-dot.warning { background: #f56565; }

.marine-summary-row {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
    flex-wrap: wrap;
}

.marine-summary-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.marine-summary-item .label {
    color: var(--text-muted);
}

.marine-summary-item .value {
    font-weight: 500;
    color: var(--text-primary);
}

.marine-expand-icon {
    display: inline-block;
    font-size: 0.7rem;
    color: var(--text-muted);
    transition: transform 0.2s;
}

.marine-summary-card.expanded .marine-expand-icon {
    display: inline-block;
    transform: rotate(180deg);
}

.marine-detail {
    display: none;
    margin-top: 1rem;
    border-top: 1px solid var(--border);
    padding-top: 1rem;
}

.marine-summary-card.expanded .marine-detail {
    display: block;
}

.marine-day-group {
    margin-bottom: 1rem;
}

.marine-day-header {
    font-weight: 600;
    font-size: 0.75rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    padding: 0.25rem 0.5rem;
    background: var(--bg-secondary);
    border-radius: 4px;
}

.marine-table {
    width: 100%;
    font-size: 0.75rem;
    border-collapse: collapse;
}

.marine-table th {
    text-align: left;
    color: var(--text-muted);
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-bottom: 1px solid var(--border);
}

.marine-table td {
    padding: 0.25rem 0.5rem;
    border-bottom: 1px solid var(--border);
}

.marine-table tr:last-child td {
    border-bottom: none;
}

.wind-dir {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

@media (max-width: 640px) {
    .marine-summary-grid {
        grid-template-columns: 1fr;
    }
    .marine-summary-row {
        gap: 0.5rem;
    }
    .marine-table {
        font-size: 0.7rem;
    }
}


/* ========================================
   DIVER PAGE ENHANCEMENTS
   ======================================== */

/* Gear Guide Section */
.gear-guide {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.gear-guide-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.gear-guide-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.gear-guide-icon {
    font-size: 1.25rem;
}

.gear-guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.gear-location {
    padding: 0.75rem;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.gear-location-name {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.gear-location-temp {
    font-size: 0.9rem;
    color: var(--accent-teal);
    font-weight: 500;
}

.gear-recommendation {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.gear-recommendation strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* Condition Bar */
.condition-bar-section {
    margin-bottom: 1.5rem;
}

.condition-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 0.75rem;
}

.condition-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.condition-location {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.condition-status {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8rem;
    font-weight: 500;
}

.condition-bar-container {
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.condition-bar {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

.condition-bar.good {
    background: linear-gradient(90deg, #48bb78, #68d391);
}

.condition-bar.caution {
    background: linear-gradient(90deg, #ecc94b, #f6e05e);
}

.condition-bar.warning {
    background: linear-gradient(90deg, #f56565, #fc8181);
}

.condition-summary {
    display: flex;
    gap: 1rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
    flex-wrap: wrap;
}

.condition-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.condition-item .label {
    color: var(--text-muted);
}

.condition-item .value {
    font-weight: 500;
    color: var(--text-primary);
}

.condition-advice {
    margin-top: 0.75rem;
    padding: 0.5rem 0.75rem;
    background: rgba(43, 108, 176, 0.08);
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.condition-advice-icon {
    flex-shrink: 0;
}

/* Coral Stress Section */
.coral-stress-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.coral-stress-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.coral-stress-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.coral-stress-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.coral-stress-card {
    padding: 0.75rem;
    background: var(--bg-secondary);
    border-radius: 8px;
}

.coral-stress-location {
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.coral-stress-dhw {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.coral-stress-dhw.safe { color: #5a9a7a; }
.coral-stress-dhw.watch { color: #c4a35a; }
.coral-stress-dhw.warning { color: #e8784b; }
.coral-stress-dhw.alert { color: #c05353; }

.coral-stress-label {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.coral-stress-status {
    margin-top: 0.5rem;
    padding: 0.35rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 500;
    display: inline-block;
}

.coral-stress-status.safe {
    background: rgba(90, 154, 122, 0.15);
    color: #2f855a;
}

.coral-stress-status.watch {
    background: rgba(196, 163, 90, 0.15);
    color: #975a16;
}

.coral-stress-status.warning {
    background: rgba(232, 120, 75, 0.15);
    color: #c05621;
}

.coral-stress-status.alert {
    background: rgba(192, 83, 83, 0.15);
    color: #a65d5d;
}

/* Coral stress card improvements */
.coral-stress-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
}
.coral-stress-metric {
    display: flex;
    flex-direction: column;
    align-items: center;
}
.coral-stress-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}
.coral-stress-value.warm {
    color: #e74c3c;
}
.coral-stress-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.coral-stress-footer {
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.coral-stress-link {
    color: var(--accent-teal);
    text-decoration: none;
    font-weight: 500;
}

.coral-stress-link:hover {
    text-decoration: underline;
}

/* Responsive for new sections */
@media (max-width: 640px) {
    .gear-guide-grid,
    .coral-stress-grid {
        grid-template-columns: 1fr;
    }
    
    .condition-summary {
        gap: 0.5rem;
    }
}

.six-card-section {
  padding: 2rem;
  max-width: 1400px;
  margin: 0 auto;
}
.six-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.six-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 0;
  box-shadow: 0 4px 20px rgba(0, 122, 108, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.3s, box-shadow 0.3s;
}
.six-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 122, 108, 0.15);
}
.six-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #5b9a94, #3d7a73);
  z-index: 10;
}
.six-card.status-warning::before {
  background: linear-gradient(90deg, #c4a35a, #b8956a);
}
.six-card.status-alert::before {
  background: linear-gradient(90deg, #a65d5d, #8b5a5a);
  animation: pulse-alert 2s ease-in-out infinite;
}
@keyframes pulse-alert {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}
.six-card-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 20;
}
.badge-safe {
  background: rgba(78, 205, 196, 0.15);
  color: #3d7a73;
}
.badge-watch {
  background: rgba(249, 168, 37, 0.15);
  color: #f57c00;
}
.badge-alert {
  background: rgba(231, 76, 60, 0.15);
  color: #8b5a5a;
}
.six-card-chart {
  width: 100%;
  height: 180px;
  background: linear-gradient(180deg, rgba(78, 205, 196, 0.05) 0%, rgba(0, 122, 108, 0.1) 100%);
  position: relative;
  padding: 1rem;
  box-sizing: border-box;
}
.six-card-wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 20px;
  overflow: hidden;
}
.six-card-wave svg {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 20px;
}
.six-card-chart canvas {
  width: 100% !important;
  height: calc(100% - 10px) !important;
}
.six-card-body {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #fff 0%, rgba(78, 205, 196, 0.02) 100%);
}
.six-card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1a1a2e;
  margin-bottom: 0.5rem;
  line-height: 1.3;
}
.six-card-location {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: #3d7a73;
  margin-bottom: 0.5rem;
}
.six-card-location svg {
  width: 14px;
  height: 14px;
  fill: #3d7a73;
}
.six-card-latest {
  font-size: 1.1rem;
  color: #1a1a2e;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.six-card-latest .trend-up {
  color: #a65d5d;
  font-size: 0.75rem;
}
.six-card-latest .trend-down {
  color: #4a8a6a;
  font-size: 0.75rem;
}
.six-card-desc {
  font-size: 0.75rem;
  color: #666;
  line-height: 1.6;
  margin-bottom: 1rem;
  flex: 1;
}
.six-card-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.6rem 1.25rem;
  background: linear-gradient(135deg, #3d7a73, #2d5f5a);
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  transition: all 0.2s;
  align-self: flex-start;
}
.six-card-btn:hover {
  background: linear-gradient(135deg, #2d5f5a, #1d4a45);
  gap: 12px;
}
.six-card-btn svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  transition: transform 0.2s;
}
.six-card-btn:hover svg {
  transform: translateX(2px);
}
.six-card.coming-soon {
  opacity: 0.6;
}
.six-card.coming-soon::before {
  background: linear-gradient(90deg, #bdc3c7, #95a5a6);
}
.six-card.coming-soon .six-card-chart {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #f5f5f5 0%, #e0e0e0 100%);
}
.six-card.coming-soon .coming-soon-label {
  font-size: 0.75rem;
  color: #95a5a6;
  font-weight: 600;
  letter-spacing: 1px;
}
.six-card.coming-soon .six-card-body {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 60' opacity='0.03'%3E%3Cpath fill='%23007a6c' d='M20 60 Q25 40 20 30 Q15 20 25 10 M30 60 Q35 45 30 35 Q25 25 35 15 M45 60 Q50 50 45 40 Q40 30 50 20 M55 60 Q60 48 55 38 Q50 28 60 18 M70 60 Q75 42 70 32 Q65 22 75 12 M80 60 Q85 52 80 42 Q75 32 85 22'/%3E%3C/svg%3E") center bottom no-repeat;
  background-size: 80% auto;
}
[data-theme="dark"] .six-card {
  background: #1e1e2e;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
[data-theme="dark"] .six-card-chart {
  background: linear-gradient(180deg, rgba(78, 205, 196, 0.08) 0%, rgba(0, 122, 108, 0.15) 100%);
}
[data-theme="dark"] .six-card-body {
  background: linear-gradient(180deg, #1e1e2e 0%, rgba(78, 205, 196, 0.03) 100%);
}
[data-theme="dark"] .six-card-title {
  color: #e0e0e0;
}
[data-theme="dark"] .six-card-latest {
  color: #fff;
}
[data-theme="dark"] .six-card-desc {
  color: #a0a0a0;
}
[data-theme="dark"] .six-card-location {
  color: #5b9a94;
}
[data-theme="dark"] .six-card-location svg {
  fill: #5b9a94;
}
[data-theme="dark"] .badge-safe {
  background: rgba(78, 205, 196, 0.2);
  color: #5b9a94;
}
[data-theme="dark"] .six-card-wave svg path {
  fill: #1e1e2e;
}
@media (max-width: 1100px) {
  .six-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 700px) {
  .six-card-grid {
    grid-template-columns: 1fr;
  }
}


/* Dark mode */
[data-theme="dark"] .six-card {
  background: #1e1e2e;
}
[data-theme="dark"] .six-card-chart {
  background: linear-gradient(135deg, #2a2a3e 0%, #1e1e2e 100%);
}
[data-theme="dark"] .six-card-title {
  color: #e0e0e0;
}
[data-theme="dark"] .six-card-latest {
  color: #5b9a94;
}
[data-theme="dark"] .six-card-desc {
  color: #a0a0a0;
}
@media (max-width: 1100px) {
  .six-card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 700px) {
  .six-card-grid {
    grid-template-columns: 1fr;
  }
}


/* Hero Impact Version */
.hero-impact {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    background: linear-gradient(
        180deg,
        rgba(26, 32, 46, 0.7) 0%,
        rgba(26, 32, 46, 0.5) 50%,
        rgba(26, 32, 46, 0.7) 100%
    ), url('../images/hero.webp');
    background-size: cover;
    background-position: center;
    padding: 2rem;
}

.hero-spacer {
    height: 45vh;
}

.hero-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 900px;
}

.hero-footer {
    margin-top: auto;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: flex-end;
    padding-bottom: 2vh;
    padding-right: 3vw;
    width: 100%;
}

.hero-tagline {
    font-size: 3.8rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
    color: #ffffff;
    text-shadow: 0 2px 20px rgba(0,0,0,0.5);
    margin-bottom: 2rem;
}

body.ja .hero-tagline {
    font-size: 2.4rem;
    letter-spacing: 0.05em;
    line-height: 1.5;
}

.hero-tagline-sub {
    display: block;
    margin-top: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    font-style: italic;
}

body.ja .hero-tagline-sub {
    font-style: normal;
    font-weight: 400;
    letter-spacing: 0.1em;
}



.hero-btn {
    padding: 0.5rem 1.2rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    min-width: 150px;
    text-align: center;
}

.hero-btn-primary {
    background: #ffffff;
    color: #1a202c;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.hero-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    background: #f0f0f0;
}

.hero-btn-secondary {
    background: transparent;
    color: rgba(255, 255, 255, 0.8);
    border: none;
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 4px;
    min-width: auto;
    padding: 0.75rem 1rem;
}

.hero-btn-secondary:hover {
    color: #ffffff;
}

@media (max-width: 768px) {
    .hero-btn {
        font-size: 0.7rem;
        padding: 0.4rem 1rem;
        min-width: 120px;
    }
    .hero-btn-secondary {
        font-size: 0.65rem;
    }
    .hero-footer {
    margin-top: auto;
        justify-content: center;
        padding-right: 0;
        padding-bottom: 2vh; margin-bottom: -8vh;
    }
    .hero-tagline {
        font-size: 2rem;
    }
    body.ja .hero-tagline {
        font-size: 1.75rem;
    }
    .hero-btn {
        min-width: 180px;
        padding: 0.875rem 2rem;
        font-size: 0.95rem;
    }
    .hero-btn-secondary {
        min-width: auto;
    }
    .hero-cta-buttons {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }
}


/* Data Sources Section - Enhanced */
.data-sources-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.data-sources-section .section-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
}

.source-category {
    margin-bottom: 1.25rem;
}

.source-category:last-child {
    margin-bottom: 0;
}

.source-category-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.source-category-icon {
    font-size: 1rem;
}

.source-item-enhanced {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: var(--bg-secondary);
    border-radius: 6px;
}

.source-item-enhanced:last-child {
    margin-bottom: 0;
}

.source-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.35rem;
}

.source-name-link {
    color: var(--accent-teal);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.85rem;
}

.source-name-link:hover {
    text-decoration: underline;
}

.source-name-text {
    font-weight: 500;
    font-size: 0.85rem;
    color: var(--text-primary);
}

.source-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.source-update {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.35rem;
    font-style: italic;
}

.source-badge.planning {
    background: #e2e8f0;
    color: #4a5568;
}

.source-badge.archive {
    background: #e2e8f0;
    color: #718096;
}


/* Introduction Section */
.intro-section {
    max-width: 880px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem;
}

.intro-content {
    color: #444;
    font-size: 1.05rem;
    line-height: 1.9;
}

.intro-content p {
    margin-bottom: 1rem;
}

.intro-content p:last-child {
    margin-bottom: 0;
}

@media (max-width: 640px) {
    .intro-section {
        padding: 1.5rem 1rem;
    }
    
    .intro-content {
        font-size: 0.9rem;
        line-height: 1.7;
    }
}

/* Introduction Links */
.intro-links {
    display: flex;
    gap: 2rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.intro-link {
    color: var(--accent-teal);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: opacity 0.2s;
}

.intro-link:hover {
    opacity: 0.7;
}

@media (max-width: 640px) {
    .intro-links {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .intro-link {
        font-size: 0.85rem;
    }
}


/* ============================================
   DETAIL PAGE COMMON STYLES
   ============================================ */

/* Site Colors */
:root {
    --kushimoto: #805ad5;
    --ogasawara: #2f855a;
    --amami: #d53f8c;
    --sesoko: #2b6cb0;
    --manza: #c05621;
    --kerama: #0891b2;
    --sekisei: #e53e3e;
}

/* Breadcrumb */
.breadcrumb {
    white-space: nowrap;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}
.breadcrumb a {
    color: var(--accent-teal);
    text-decoration: none;
}

/* Detail Page Main Container */
main.detail-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2.5rem 2rem;
}

/* Hero Section for Detail Pages */
.hero-section {
    color: white;
    padding: 2.5rem 2rem;
    border-radius: 12px;
    margin-bottom: 2.5rem;
    background-size: cover;
    background-position: center;
}
.hero-section.sst {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.7), rgba(66, 153, 225, 0.65)), url("../images/bg-sst.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.dhw {
    background: linear-gradient(135deg, rgba(197, 48, 48, 0.75), rgba(237, 100, 100, 0.65)), url("../images/bg-dhw.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.extreme {
    background: linear-gradient(135deg, rgba(107, 70, 193, 0.75), rgba(159, 122, 234, 0.65)), url("../images/bg-extreme.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.species {
    background: linear-gradient(135deg, rgba(47, 133, 90, 0.75), rgba(72, 187, 120, 0.65)), url("../images/bg-species.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.spawning {
    background: linear-gradient(135deg, rgba(192, 86, 33, 0.75), rgba(237, 137, 54, 0.65)), url("../images/bg-spawning.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.turbidity {
    background: linear-gradient(135deg, rgba(74, 85, 104, 0.75), rgba(113, 128, 150, 0.65)), url("../images/bg-turbidity.webp");
    background-size: cover;
    background-position: center;
}
.hero-section.global-bleaching {
    background: linear-gradient(135deg, rgba(197, 48, 48, 0.75), rgba(237, 100, 100, 0.65)), url("../images/bg-global-bleaching.webp");
    background-size: cover;
    background-position: center;
}

.hero-main { text-align: center; margin-bottom: 2rem; }
.hero-icon { font-size: 3.5rem; margin-bottom: 0.75rem; }
.hero-section .hero-tagline {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}
body.ja .hero-section .hero-tagline { font-size: 1.3rem; }
.hero-subtitle {
    font-size: 1rem;
    opacity: 0.9;
}


/* Region Groups (7-site layout) */
.region-group {
    margin-top: 1.5rem;
}
.region-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0.7;
    margin-bottom: 0.75rem;
    padding-left: 0.25rem;
}
.sst-grid-2 {
    grid-template-columns: repeat(2, 1fr) !important;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}
.sst-grid-5 {
    grid-template-columns: repeat(5, 1fr) !important;
    max-width: 100%;
}
.sst-grid-5 .sst-card {
    min-width: 0;
    padding: 0.75rem 0.5rem;
}
.sst-grid-5 .sst-value {
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
}
@media (max-width: 900px) {
    .sst-grid-5 { 
        grid-template-columns: repeat(3, 1fr) !important; 
    }
}
@media (max-width: 640px) {
    .sst-grid-2 { 
        grid-template-columns: repeat(2, 1fr) !important;
        max-width: 100%;
    }
    .sst-grid-5 { 
        grid-template-columns: repeat(2, 1fr) !important; 
    }
}
@media (max-width: 400px) {
    .sst-grid-2, .sst-grid-5 { 
        grid-template-columns: 1fr !important; 
    }
}

/* SST Grid */
.sst-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}
@media (max-width: 640px) {
    .sst-grid { grid-template-columns: 1fr; }
}
.sst-card {
    background: rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
}
.sst-location {
    font-size: 0.85rem;
    opacity: 0.9;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}
.site-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}
.sst-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 2rem;
    font-weight: 500;
}
.sst-diff {
    font-size: 0.8rem;
    margin-top: 0.25rem;
}
.sst-diff.above { color: #fed7d7; }
.sst-diff.below { color: #c6f6d5; }
.sst-diff.neutral { color: rgba(255,255,255,0.8); }

/* Content Section */
.content-section { margin-bottom: 3rem; }
.content-section h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

/* Card */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

/* Story Box */
.story-box {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.story-box .story-lead {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.7;
}
.story-box p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.9;
}
.story-box p:last-child { margin-bottom: 0; }
.story-box .highlight {
    background: rgba(43, 108, 176, 0.15);
    padding: 0.15rem 0.4rem;
    border-radius: 3px;
    font-weight: 500;
}
.story-box .emphasis {
    font-weight: 600;
    color: var(--text-primary);
}

/* Q&A Blocks */
.qa-block { margin-bottom: 1.5rem; }
.qa-question {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.5rem;
}
.qa-question.heat { color: #c53030; }
.qa-question.cold { color: #0987a0; }
.qa-question.adapt { color: #6b46c1; }
.qa-answer {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.9;
    padding-left: 1rem;
    border-left: 3px solid var(--border);
}
.qa-answer.heat { border-left-color: #feb2b2; }
.qa-answer.cold { border-left-color: #81e6d9; }
.qa-answer.adapt { border-left-color: #d6bcfa; }

/* Colored Sections */
.heat-section {
    background: #fff5f5;
    border: 1px solid #feb2b2;
    border-radius: 8px;
    padding: 1.5rem;
}
.cold-section {
    background: #e6fffa;
    border: 1px solid #81e6d9;
    border-radius: 8px;
    padding: 1.5rem;
}
.adapt-section {
    background: #f5f3ff;
    border: 1px solid #d6bcfa;
    border-radius: 8px;
    padding: 1.5rem;
}
.section-intro {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.9;
}

/* Insight Box */
.insight-box {
    border-left: 3px solid;
    padding: 1rem 1.25rem;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    border-radius: 0 4px 4px 0;
    line-height: 1.8;
}
.insight-box.heat {
    background: rgba(197, 48, 48, 0.1);
    border-left-color: #c53030;
}
.insight-box.cold {
    background: rgba(9, 135, 160, 0.1);
    border-left-color: #0987a0;
}
.insight-box.adapt {
    background: rgba(107, 70, 193, 0.1);
    border-left-color: #6b46c1;
}
.insight-box strong.heat { color: #c53030; }
.insight-box strong.cold { color: #0987a0; }
.insight-box strong.adapt { color: #6b46c1; }

/* Wave Timeline */
.wave-timeline {
    position: relative;
    padding-left: 2rem;
}
.wave-timeline::before {
    content: '';
    position: absolute;
    left: 0.5rem;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, #6b46c1, var(--accent-teal));
    border-radius: 2px;
}
.wave-item {
    position: relative;
    margin-bottom: 1.25rem;
    padding-left: 1rem;
}
.wave-item:last-child { margin-bottom: 0; }
.wave-item::before {
    content: '';
    position: absolute;
    left: -1.5rem;
    top: 0.35rem;
    width: 14px;
    height: 14px;
    background: #6b46c1;
    border-radius: 50%;
    border: 3px solid #f5f3ff;
}
.wave-timing {
    font-size: 0.75rem;
    font-weight: 600;
    color: #6b46c1;
    margin-bottom: 0.25rem;
}
.wave-title {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}
.wave-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Chart */
.chart-container {
    height: 280px;
    position: relative;
}
.chart-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}
.legend-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
}
.legend-line {
    width: 16px;
    height: 3px;
    border-radius: 2px;
}
.legend-kushimoto { background: var(--kushimoto); }
.legend-ogasawara { background: var(--ogasawara); }
.legend-amami { background: var(--amami); }
.legend-sesoko { background: var(--sesoko); }
.legend-manza { background: var(--manza); }
.legend-kerama { background: var(--kerama); }
.legend-sekisei { background: var(--sekisei); }
.legend-mmm { background: #e53e3e; }
.legend-clim {
    background: repeating-linear-gradient(
        90deg,
        var(--text-muted),
        var(--text-muted) 3px,
        transparent 3px,
        transparent 6px
    );
}

/* Threshold Table */
.threshold-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}
.threshold-table th,
.threshold-table td {
    padding: 0.75rem;
    text-align: center;
    border-bottom: 1px solid var(--border);
}
.threshold-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    font-size: 0.8rem;
}
.threshold-table .site-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
}

/* Insights Box */
.insights-box {
    background: linear-gradient(135deg, #ebf8ff 0%, #f0f9ff 100%);
    border: 1px solid #bee3f8;
    border-radius: 8px;
    padding: 1.25rem;
}
.insights-box .box-title {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--accent-teal);
}
.insights-list {
    list-style: none;
}
.insights-list li {
    padding: 0.5rem 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
    border-bottom: 1px solid rgba(43, 108, 176, 0.1);
}
.insights-list li:last-child { border-bottom: none; }
.insights-list .label { font-weight: 600; color: var(--text-primary); }

/* Source Info */
.source-info {
    font-size: 0.8rem;
    color: var(--text-muted);
    padding: 1.25rem;
    background: var(--bg-secondary);
    border-radius: 6px;
    line-height: 1.8;
}
.source-info a { color: var(--accent-teal); text-decoration: none; }
.source-info a:hover { text-decoration: underline; }
.source-info ul { margin-top: 0.75rem; padding-left: 1.25rem; }
.source-info li { margin-bottom: 0.5rem; }

/* Detail Page Footer */
footer.detail-footer {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem;
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border);
}
footer.detail-footer a { color: var(--accent-teal); text-decoration: none; }

/* Line Height Override */
main.detail-page {
    line-height: 1.8;
}


/* ============================================
   DHW PAGE SPECIFIC STYLES
   ============================================ */

/* Page Header */
.page-header {
    margin-bottom: 2rem;
}
.page-header h1 {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}
.page-header .lead {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* DHW Hero Section */
.hero-stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}
@media (max-width: 640px) {
    .hero-stats-row { grid-template-columns: 1fr; }
}
.hero-stat-card {
    background: rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
}
.site-name-hero {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    opacity: 0.95;
}
.dhw-year-values {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.dhw-year-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}
.dhw-year-row .year-label {
    font-size: 0.75rem;
    opacity: 0.8;
}
.dhw-year-row .number {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.4rem;
    font-weight: 500;
}
.dhw-year-row.current .number {
    color: #fef08a;
}
.hero-date-info {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.8rem;
    opacity: 0.85;
}

/* DHW Levels */
.dhw-levels {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    margin-top: 1rem;
}
@media (max-width: 768px) {
    .dhw-levels { grid-template-columns: repeat(2, 1fr); }
}
.dhw-level {
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
}
.dhw-level.watch {
    background: #fef9c3;
    border: 1px solid #fde047;
}
.dhw-level.warning {
    background: #fed7aa;
    border: 1px solid #fb923c;
}
.dhw-level.alert1 {
    background: #fecaca;
    border: 1px solid #f87171;
}
.dhw-level.alert2 {
    background: #fca5a5;
    border: 1px solid #ef4444;
}
.level-name {
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 0.25rem;
}
.level-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    font-weight: 500;
}
.level-desc {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* Diagram */
.diagram-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
    text-align: center;
}
.diagram-caption {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 1rem;
}

/* Insight Grid */
.insight-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}
.insight-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.25rem;
}
.insight-card h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}
.insight-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 0.5rem;
}
.insight-card .citation {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-style: italic;
}
.insight-card.limitation {
    border-left: 3px solid #f59e0b;
}
.insight-card.acclimatization {
    border-left: 3px solid #10b981;
}

/* Observation Box */
.observation-box {
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 8px;
    padding: 1.25rem;
    margin-top: 1.5rem;
}
.obs-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
    color: #166534;
}
.observation-box p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Reference Table */
.ref-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}
.ref-table th,
.ref-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}
.ref-table th {
    background: var(--bg-secondary);
    font-weight: 600;
}

/* References Section */
.references-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}
.references-section h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}
.ref-category {
    margin-bottom: 1.5rem;
}
.ref-category h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}
.ref-list {
    list-style: none;
    padding: 0;
}
.ref-list li {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 0.5rem;
    padding-left: 1rem;
    border-left: 2px solid var(--border);
}
.ref-list a {
    color: var(--accent-teal);
    text-decoration: none;
}
.ref-list a:hover {
    text-decoration: underline;
}

/* Card Title */
.card-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

/* Threshold Note */
.threshold-note {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 0.75rem;
}

/* ========================================
   Navigation - Dropdown & Hamburger Menu
   ======================================== */

/* Desktop Navigation */
.nav-desktop {
    display: flex;
    margin-left: 1rem;
}

.nav-desktop .nav-links {
    display: flex;
    gap: 0.25rem;
    list-style: none;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.85rem;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.2s;
}

.nav-link:hover {
    color: #ffffff;
    background: rgba(255,255,255,0.08);
}

.dropdown-arrow {
    opacity: 0.6;
    transition: transform 0.2s;
}

.nav-item:hover .dropdown-arrow,
.nav-item:focus-within .dropdown-arrow {
    transform: rotate(180deg);
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: var(--header-bg);
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease;
    z-index: 1000;
    list-style: none;
}

.nav-item:hover .dropdown-menu,
.nav-item:focus-within .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(4px);
}

.dropdown-menu li a {
    display: flex;
    align-items: center;
    padding: 0.6rem 1rem;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    font-size: 0.82rem;
    transition: all 0.15s;
}

.dropdown-menu li a:hover {
    color: #ffffff;
    background: rgba(255,255,255,0.08);
}

.nav-badge {
    margin-left: 0.5rem;
    padding: 0.15rem 0.4rem;
    font-size: 0.6rem;
    background: rgba(255,255,255,0.15);
    border-radius: 4px;
    color: rgba(255,255,255,0.7);
}

/* Hamburger Button */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 32px;
    height: 32px;
    padding: 4px;
    background: none;
    border: none;
    cursor: pointer;
    margin-left: auto;
    margin-right: 1rem;
}

.hamburger-line {
    width: 100%;
    height: 2px;
    background: rgba(255,255,255,0.9);
    border-radius: 2px;
    transition: all 0.3s;
}

.hamburger.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.hamburger.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Sidebar */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 998;
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

.sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100%;
    background: var(--header-bg);
    z-index: 999;
    transition: right 0.3s ease;
    overflow-y: auto;
}

.sidebar.active {
    right: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-title {
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 600;
}

.sidebar-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    padding: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-close:hover {
    color: #ffffff;
}

.sidebar-menu {
    list-style: none;
    padding: 1rem 0;
}

.sidebar-section {
    padding: 0.5rem 0;
}

.sidebar-section-title {
    display: block;
    padding: 0.5rem 1.25rem;
    color: rgba(255,255,255,0.5);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.sidebar-submenu {
    list-style: none;
}

.sidebar-submenu li a,
.sidebar-item a {
    display: flex;
    align-items: center;
    padding: 0.7rem 1.25rem;
    padding-left: 1.75rem;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.15s;
}

.sidebar-item a {
    padding-left: 1.25rem;
    font-weight: 500;
}

.sidebar-submenu li a:hover,
.sidebar-item a:hover {
    background: rgba(255,255,255,0.08);
    color: #ffffff;
}

.nav-badge-mobile {
    margin-left: 0.5rem;
    padding: 0.1rem 0.35rem;
    font-size: 0.55rem;
    background: rgba(255,255,255,0.15);
    border-radius: 3px;
    color: rgba(255,255,255,0.6);
}

/* Mobile Responsive */
@media (max-width: 900px) {
    .nav-desktop {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .header-content {
        padding: 0;
    }
}

/* Adjust header controls on mobile */
@media (max-width: 480px) {
    header {
        padding: 0.75rem 1rem;
    }
    
    .lang-switch button {
        font-size: 0.7rem;
        padding: 0.2rem 0.4rem;
    }
}

/* Mobile-optimized background images */
@media (max-width: 768px) {
    .hero-section.sst {
        background: linear-gradient(135deg, rgba(37, 99, 235, 0.7), rgba(66, 153, 225, 0.65)), url("../images/bg-sst-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.dhw {
        background: linear-gradient(135deg, rgba(197, 48, 48, 0.75), rgba(237, 100, 100, 0.65)), url("../images/bg-dhw-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.extreme {
        background: linear-gradient(135deg, rgba(107, 70, 193, 0.75), rgba(159, 122, 234, 0.65)), url("../images/bg-extreme-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.species {
        background: linear-gradient(135deg, rgba(47, 133, 90, 0.75), rgba(72, 187, 120, 0.65)), url("../images/bg-species-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.spawning {
        background: linear-gradient(135deg, rgba(192, 86, 33, 0.75), rgba(237, 137, 54, 0.65)), url("../images/bg-spawning-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.turbidity {
        background: linear-gradient(135deg, rgba(74, 85, 104, 0.75), rgba(113, 128, 150, 0.65)), url("../images/bg-turbidity-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-section.global-bleaching {
        background: linear-gradient(135deg, rgba(197, 48, 48, 0.75), rgba(237, 100, 100, 0.65)), url("../images/bg-global-bleaching-mobile.webp");
        background-size: cover;
        background-position: center;
    }
    .hero-visual {
        background: linear-gradient(
            135deg,
            rgba(26, 32, 46, 0.88) 0%,
            rgba(26, 32, 46, 0.75) 50%,
            rgba(26, 32, 46, 0.65) 100%
        ), url("../images/hero-mobile.webp");
        background-size: cover;
        background-position: center;
    }
}

/* 7-site chart legend */
.chart-legend-7 {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1rem;
}
.chart-legend-7 .legend-item {
    font-size: 0.75rem;
}

/* 7-site threshold table */
.table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.threshold-table-7 {
    min-width: 700px;
}
.threshold-table-7 th,
.threshold-table-7 td {
    padding: 0.5rem 0.4rem;
    font-size: 0.8rem;
    white-space: nowrap;
}
.threshold-table-7 .site-header {
    font-size: 0.75rem;
}

/* Regional characteristics boxes */
.region-box {
    background: #f8fafc;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-left: 4px solid;
}
.region-box.honshu {
    border-left-color: #805ad5;
}
.region-box.ryukyu {
    border-left-color: #e53e3e;
}
.region-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1a202c;
}
.region-content p {
    margin-bottom: 1rem;
    line-height: 1.7;
}
.region-content p:last-child {
    margin-bottom: 0;
}
.highlight-cold {
    background: linear-gradient(transparent 60%, rgba(128, 90, 213, 0.2) 60%);
    padding: 0 2px;
}
.highlight-heat {
    background: linear-gradient(transparent 60%, rgba(229, 62, 62, 0.2) 60%);
    padding: 0 2px;
}

/* ========================================
   UV INDEX & TIDE STYLES (2026-01-10)
   ======================================== */

.marine-summary-row-extra {
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 1px dashed var(--border);
}

.uv-low { color: var(--text-secondary); }
.uv-moderate { color: #f59e0b; }
.uv-high { color: #f97316; }
.uv-veryhigh { color: #ef4444; }
.uv-extreme { color: #dc2626; font-weight: 600; }

.tide-value {
    font-size: 0.7rem;
    letter-spacing: -0.02em;
}

.marine-summary-item small {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-left: 2px;
}

/* Daily forecast status in marine-day-header */
.marine-day-header .status-dot {
    display: inline-block;
    vertical-align: middle;
    margin-left: 0.5rem;
}

.marine-day-header .day-status-text {
    font-size: 0.7rem;
    font-weight: 500;
    margin-left: 0.25rem;
    vertical-align: middle;
}

.marine-day-header .status-dot.good + .day-status-text { color: #5a9a7a; }
.marine-day-header .status-dot.caution + .day-status-text { color: #d69e2e; }
.marine-day-header .status-dot.warning + .day-status-text { color: #e53e3e; }
