/* AI Feature Tracker - Styles */
/* WCAG 2.1 AA Compliant (4.5:1 contrast ratio minimum) */

/* ========================================
   ACCESSIBILITY & MOTION
   ======================================== */

/* Smooth scroll with reduced motion support */
html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Skip link for keyboard/screen reader users */
.skip-link {
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: #000;
    padding: 12px 24px;
    border-radius: 0 0 8px 8px;
    font-weight: 600;
    text-decoration: none;
    z-index: 1000;
    transition: top 0.2s;
}

.skip-link:focus {
    top: 0;
}

/* ========================================
   CSS VARIABLES (DARK MODE DEFAULT)
   ======================================== */

:root {
    --bg-gradient-start: #1a1a2e;
    --bg-gradient-end: #16213e;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0a0;
    --text-heading: #fff;
    --text: #e0e0e0;
    --card-bg: #1e1e30;
    --card-border: #3a3a4a;
    --border: #3a3a4a;
    --input-bg: #252538;
    --accent: #4fc3f7;
    --accent-bg: #0f3460;
    --badge-bg: #2d2d44;

    /* Status colors - dark mode */
    --status-yes: #4caf50;
    --status-yes-text: #000;
    --status-no: #555;
    --status-no-bg: #333;
    --status-soon: #888;
    --status-soon-text: #000;
    --status-partial: #e67700;
    --status-partial-text: #000;
    --status-partial-bg: #5a3000;
}

/* ========================================
   LIGHT MODE OVERRIDES
   ======================================== */

:is(html, body).light-mode {
    --bg-gradient-start: #f5f5f7;
    --bg-gradient-end: #e8e8ed;
    --text-primary: #2d2d2d;
    --text-secondary: #595959;
    --text-heading: #111;
    --text: #2d2d2d;
    --card-bg: #fff;
    --card-border: #ccc;
    --border: #ccc;
    --input-bg: #f0f0f5;
    --accent: #0055aa;
    --accent-bg: #e6f2ff;
    --badge-bg: #e0e0e5;

    /* Status colors - light mode (WCAG compliant) */
    --status-yes: #1b7d1b;
    --status-yes-text: #fff;
    --status-no: #444;
    --status-no-bg: #e0e0e0;
    --status-soon: #777;
    --status-soon-text: #fff;
    --status-partial: #c45500;
    --status-partial-text: #fff;
    --status-partial-bg: #fff3cd;
}

:is(html, body).light-mode header,
:is(html, body).light-mode .site-header {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

:is(html, body).light-mode .platform-status-link {
    background: #d4edda;
    color: #155724;
}

:is(html, body).light-mode .platform-status-link:hover { background: #c3e6cb; }

:is(html, body).light-mode .feature-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

:is(html, body).light-mode .feature-card.keyboard-focus {
    box-shadow: 0 0 0 2px rgba(0, 85, 170, 0.3);
}

:is(html, body).light-mode .badge.avail-ga { background: #2e7d32; color: #fff; }
:is(html, body).light-mode .badge.avail-beta { background: #e65100; color: #fff; }

:is(html, body).light-mode .badge.gate-free { background: #1565c0; color: #fff; }
:is(html, body).light-mode .badge.gate-paid { background: #e3f2fd; color: #0d47a1; border: 1px solid #0d47a1; }
:is(html, body).light-mode .badge.gate-invite { background: #fce4ec; color: #880e4f; border: 1px solid #880e4f; }
:is(html, body).light-mode .badge.gate-org { background: #f1f8e9; color: #33691e; border: 1px solid #33691e; }

:is(html, body).light-mode .plat-icon.yes { background: #2e7d32; color: #fff; }
:is(html, body).light-mode .plat-icon.no { background: #ccc; color: #555; }
:is(html, body).light-mode .plat-icon.soon { background: #bbb; color: #444; }
:is(html, body).light-mode .plat-icon.partial { background: #fff3cd; color: #c45500; }

:is(html, body).light-mode .talking-point.copied { background: #2e7d32 !important; color: #fff !important; }

/* ========================================
   BASE STYLES
   ======================================== */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, var(--bg-gradient-start) 0%, var(--bg-gradient-end) 100%);
    min-height: 100vh;
    color: var(--text-primary);
    padding: 20px;
    line-height: 1.5;
}

.container { max-width: 1600px; margin: 0 auto; padding-top: 70px; }

/* ========================================
   HEADER
   ======================================== */

/* Sticky header - shared across all pages */
header, .site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 12px 20px;
    background: var(--bg-gradient-start);
    border-bottom: 1px solid var(--card-border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

h1, .site-header h1 { font-size: 1.4rem; color: var(--text-heading); margin: 0; }

.header-logo {
    vertical-align: middle;
    margin-right: 6px;
    margin-top: -2px;
}

.header-meta { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }

/* Hamburger menu button - hidden on desktop */
.hamburger-btn {
    display: none;
    background: var(--input-bg);
    border: 1px solid var(--card-border);
    border-radius: 6px;
    padding: 10px;
    cursor: pointer;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
}

.hamburger-icon {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    position: relative;
}

.hamburger-icon::before,
.hamburger-icon::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    left: 0;
    transition: transform 0.2s ease;
}

.hamburger-icon::before { top: -6px; }
.hamburger-icon::after { top: 6px; }

/* Hamburger X state when menu is open */
.hamburger-btn.active .hamburger-icon { background: transparent; }
.hamburger-btn.active .hamburger-icon::before { transform: rotate(45deg); top: 0; }
.hamburger-btn.active .hamburger-icon::after { transform: rotate(-45deg); top: 0; }

.last-updated {
    background: var(--badge-bg);
    padding: 6px 14px;
    border-radius: 16px;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.github-link,
.about-link {
    background: var(--card-border);
    color: var(--text-heading);
    padding: 6px 14px;
    border-radius: 16px;
    font-size: 0.8rem;
    text-decoration: none;
}

.github-link:hover,
.about-link:hover { background: var(--input-bg); }

.github-link:focus,
.github-link:focus-visible,
.about-link:focus,
.about-link:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Back button for subpages - always visible */
.back-btn {
    background: var(--accent);
    color: #fff;
    padding: 8px 16px;
    border-radius: 16px;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
}

.back-btn:hover {
    filter: brightness(1.1);
}

.back-btn:focus,
.back-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.theme-toggle {
    background: var(--badge-bg);
    border: 1px solid var(--card-border);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s;
}

.theme-toggle:hover { border-color: var(--accent); }

/* Focus outlines for accessibility */
.theme-toggle:focus,
.theme-toggle:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ========================================
   FILTERS & CONTROLS
   ======================================== */

/* Filters */
.filters {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    align-items: center;
}

/* Filter dropdowns wrapper - wraps as a single block */
.filter-dropdowns {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-group { display: flex; align-items: center; gap: 8px; }
.filter-group label { font-size: 0.85rem; color: var(--text-secondary); }

.filter-group select {
    background: var(--input-bg);
    border: 1px solid var(--card-border);
    color: var(--text-heading);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    transition: all 0.2s;
}

.filter-group select.active {
    background: var(--accent-bg);
    border-color: var(--accent);
    color: var(--accent);
}

.filter-group select:focus,
.filter-group select:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.feature-count {
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 6px 12px;
    background: var(--badge-bg);
    border-radius: 6px;
}

.feature-count strong { color: var(--accent); }

.definitions-link {
    margin-left: auto;
    color: var(--text-secondary);
    text-decoration: underline;
    text-decoration-color: var(--card-border);
    text-underline-offset: 2px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.2s;
}

.definitions-link:hover {
    color: var(--accent);
    background: var(--input-bg);
    text-decoration-color: var(--accent);
}

.definitions-link:focus,
.definitions-link:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Provider toggles */
.provider-toggles {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

.provider-toggles label { font-size: 0.85rem; color: var(--text-secondary); margin-right: 4px; }

.provider-toggle {
    background: var(--input-bg);
    border: 1px solid var(--card-border);
    color: var(--text-secondary);
    padding: 5px 10px;
    border-radius: 14px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.provider-toggle:hover { border-color: var(--accent); }

.provider-toggle.active {
    background: var(--accent-bg);
    border-color: var(--accent);
    color: var(--accent);
}

.provider-toggle:focus,
.provider-toggle:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ========================================
   PLATFORM SECTIONS
   ======================================== */

/* Platform status link (inline with header) */
.platform-status-link {
    background: #1a3a1a;
    color: #6fbf6f;
    padding: 3px 8px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.7rem;
    font-weight: 500;
    margin-left: 8px;
}

.platform-status-link:hover { background: #2a4a2a; }

.platform-status-link:focus,
.platform-status-link:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Platform sections */
.platform-section {
    margin-bottom: 40px;
}

.platform-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 12px;
}

.platform-header h2 {
    font-size: 1.3rem;
    color: var(--text-heading);
    display: flex;
    align-items: center;
    gap: 10px;
}

.platform-logo {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.platform-meta {
    display: flex;
    gap: 8px;
    font-size: 0.8rem;
}

.platform-meta a {
    color: var(--accent);
    text-decoration: underline;
    text-decoration-color: var(--accent);
    text-underline-offset: 2px;
}

.platform-meta a:hover { text-decoration-thickness: 2px; }

/* Pricing bar */
.pricing-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.price-tag {
    background: var(--input-bg);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.price-tag strong { color: var(--accent); }

/* ========================================
   FEATURE CARDS
   ======================================== */

/* Feature cards grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 16px;
}

.feature-card {
    background: var(--card-bg);
    border-radius: 10px;
    padding: 18px;
    border: 1px solid var(--card-border);
    transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}

.feature-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.feature-card.keyboard-focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(79, 195, 247, 0.3);
}

.feature-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.feature-header h3 {
    font-size: 1rem;
    color: var(--text-heading);
}

.feature-link {
    color: var(--text-heading);
    text-decoration: underline;
    text-decoration-color: var(--card-border);
    text-underline-offset: 2px;
}

.feature-link:hover {
    color: var(--accent);
    text-decoration-color: var(--accent);
    text-decoration-thickness: 2px;
}

.feature-link:focus,
.feature-link:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ========================================
   BADGES
   ======================================== */

.badge {
    font-size: 0.65rem;
    padding: 3px 8px;
    border-radius: 10px;
    font-weight: 600;
    text-transform: uppercase;
    margin-left: 4px;
}

/* Availability badges (release status) - WCAG compliant */
.badge.avail-ga { background: #4caf50; color: #000; }
.badge.avail-beta { background: #ff9800; color: #000; }
.badge.avail-preview { background: #9c27b0; color: #fff; }
.badge.avail-deprecated { background: #757575; color: #fff; }

/* Gating badges (access type) - WCAG compliant */
.badge.gate-free { background: #1976d2; color: #fff; }
.badge.gate-paid { background: #1a3a5c; color: #7dd3fc; border: 1px solid #7dd3fc; }
.badge.gate-invite { background: #5c1a3a; color: #f9a8d4; border: 1px solid #f9a8d4; }
.badge.gate-org { background: #3a5c1a; color: #bef264; border: 1px solid #bef264; }

/* ========================================
   AVAILABILITY GRID
   ======================================== */

.avail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 6px;
    margin-bottom: 12px;
}

.avail-item {
    background: var(--input-bg);
    padding: 6px 8px;
    border-radius: 4px;
    text-align: center;
    font-size: 0.75rem;
}

.avail-item .plan { color: var(--text-secondary); display: block; }
.avail-item .plan.has-tooltip {
    position: relative;
    cursor: help;
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 2px;
}

.plan-tooltip {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    max-width: 200px;
    padding: 6px 10px;
    margin-bottom: 4px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    font-size: 0.68rem;
    line-height: 1.4;
    color: var(--text);
    z-index: 100;
    white-space: normal;
    text-align: center;
    text-decoration: none;
    transition: opacity 0.15s, visibility 0.15s;
}

.plan.has-tooltip:hover .plan-tooltip,
.plan.has-tooltip:focus .plan-tooltip {
    visibility: visible;
    opacity: 1;
}

/* Plan tooltip arrow */
.plan-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--border);
}

.avail-item .status { font-weight: 600; }

/* Status indicators - WCAG compliant */
.avail.yes { color: var(--status-yes); }
.avail.no { color: var(--status-no); }
.avail.soon { color: var(--status-soon); }
.avail.partial { color: var(--status-partial); }

/* ========================================
   PLATFORM ICONS
   ======================================== */

.platforms-row {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.plat-icon {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 600;
}

.plat-icon.yes { background: #4caf50; color: #000; }
.plat-icon.no { background: #333; color: #666; }
.plat-icon.soon { background: #555; color: #aaa; }
.plat-icon.partial { background: #5a3000; color: #ffb347; }

/* ========================================
   TALKING POINTS
   ======================================== */

.talking-point {
    background: var(--input-bg);
    border-left: 3px solid var(--accent);
    padding: 10px 12px;
    border-radius: 0 6px 6px 0;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--text-primary);
    cursor: pointer;
}

.talking-point:hover { background: var(--badge-bg); }

.talking-point:focus,
.talking-point:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
.talking-point strong { color: var(--accent); }
.talking-point.copied { background: #1b5e20 !important; color: #fff !important; }

/* ========================================
   DATES & METADATA
   ======================================== */

.dates-row {
    display: flex;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.date-item {
    font-size: 0.68rem;
    color: var(--text-secondary);
}

.date-item .date-label {
    color: var(--text-secondary);
    margin-right: 4px;
}

.date-item .date-value {
    font-family: monospace;
    color: var(--text-secondary);
}

.date-item.clickable {
    cursor: pointer;
}

.date-item.clickable:hover .date-value {
    color: var(--accent);
}

.date-item.launched .date-label::before { content: '🚀 '; }
.date-item.verified .date-label::before { content: '✓ '; }
.date-item.checked .date-label::before { content: '👁 '; }

/* ========================================
   TOOLTIPS
   ======================================== */

/* Notes tooltip */
.notes-tooltip {
    position: relative;
    margin-left: auto;
    cursor: help;
    font-size: 0.75rem;
    opacity: 0.7;
    transition: opacity 0.15s;
}

.notes-tooltip:hover,
.notes-tooltip:focus {
    opacity: 1;
}

.notes-icon {
    display: inline-block;
}

.notes-content {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 100%;
    right: 0;
    width: 280px;
    max-width: 90vw;
    padding: 10px 12px;
    margin-bottom: 6px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    font-size: 0.72rem;
    line-height: 1.5;
    color: var(--text);
    z-index: 100;
    white-space: normal;
    transition: opacity 0.15s, visibility 0.15s;
}

.notes-tooltip:hover .notes-content,
.notes-tooltip:focus .notes-content {
    visibility: visible;
    opacity: 1;
}

/* Tooltip arrow */
.notes-content::after {
    content: '';
    position: absolute;
    top: 100%;
    right: 12px;
    border: 6px solid transparent;
    border-top-color: var(--border);
}

/* ========================================
   PERMALINK & INTERACTIONS
   ======================================== */

.permalink-btn {
    background: none;
    border: none;
    padding: 2px 4px;
    margin-right: 4px;
    cursor: pointer;
    font-size: 0.75rem;
    opacity: 0.5;
    transition: opacity 0.15s;
    vertical-align: middle;
}

.feature-card:hover .permalink-btn,
.permalink-btn:focus {
    opacity: 1;
}

.permalink-btn:focus,
.permalink-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.permalink-btn.copied {
    opacity: 1;
    color: var(--status-yes);
}

/* Permalink highlight animation */
.feature-card.permalink-highlight {
    animation: highlightPulse 2s ease-out;
}

@keyframes highlightPulse {
    0% {
        box-shadow: 0 0 0 4px var(--accent);
        border-color: var(--accent);
    }
    100% {
        box-shadow: 0 0 0 0 transparent;
        border-color: var(--card-border);
    }
}

@media (prefers-reduced-motion: reduce) {
    .feature-card.permalink-highlight {
        animation: none;
        box-shadow: 0 0 0 3px var(--accent);
    }
}

/* ========================================
   MODAL
   ======================================== */

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-overlay.active { display: flex; }

.modal {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 24px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    border: 1px solid var(--card-border);
}

.modal h3 {
    color: var(--text-heading);
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.modal-close {
    float: right;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
}

.modal-close:hover { color: var(--text-heading); }

.modal-close:focus,
.modal-close:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.changelog-table {
    width: 100%;
    border-collapse: collapse;
}

.changelog-table th, .changelog-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--card-border);
    font-size: 0.85rem;
}

.changelog-table th {
    color: var(--text-secondary);
    font-weight: 600;
}

.changelog-table td:first-child {
    white-space: nowrap;
    color: var(--accent);
    font-family: monospace;
}

/* ========================================
   FOOTER
   ======================================== */

footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid var(--card-border);
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-align: center;
}

footer a {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 2px;
}

footer a:hover {
    text-decoration-thickness: 2px;
}

.footer-social {
    display: inline-block;
    background: var(--badge-bg);
    color: var(--text-primary);
    padding: 6px 14px;
    border-radius: 16px;
    font-size: 0.8rem;
    text-decoration: none;
    margin: 0 4px;
    transition: background 0.2s;
}

.footer-social:hover {
    background: var(--input-bg);
    color: var(--accent);
}

.footer-social:focus,
.footer-social:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ========================================
   RESPONSIVE: TABLET (max-width: 900px)
   ======================================== */

@media (max-width: 900px) {
    /* Increase container padding when header wraps */
    .container { padding-top: 120px; }

    /* Stack header elements vertically */
    header, .site-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 10px 16px;
    }

    .header-meta {
        width: 100%;
        justify-content: flex-start;
    }
}

/* ========================================
   RESPONSIVE: MOBILE (max-width: 600px)
   ======================================== */

@media (max-width: 600px) {
    /* Reduce body padding on mobile */
    body {
        padding: 12px;
    }

    .features-grid { grid-template-columns: 1fr; }
    .avail-grid { grid-template-columns: repeat(3, 1fr); }

    /* Reduced padding for mobile header */
    .container { padding-top: 80px; }

    /* Compact header on mobile - single row layout */
    header, .site-header {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        padding: 10px 12px;
        gap: 8px;
    }

    h1, .site-header h1 {
        font-size: 1.1rem;
        flex-shrink: 1;
        min-width: 0;
    }

    .feature-count {
        flex-shrink: 0;
    }

    /* Show hamburger button on mobile - positioned at right */
    .hamburger-btn {
        display: flex;
        flex-shrink: 0;
        order: 3;
    }

    /* Mobile menu - dropdown from upper right */
    .header-meta {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        width: auto;
        min-width: 220px;
        background: var(--bg-gradient-start);
        border: 1px solid var(--card-border);
        border-top: none;
        border-radius: 0 0 8px 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
        padding: 12px;
        flex-direction: column;
        gap: 8px;
    }

    .header-meta.open {
        display: flex;
    }

    .header-meta .last-updated,
    .header-meta .about-link,
    .header-meta .github-link,
    .header-meta .theme-toggle {
        width: 100%;
        text-align: center;
        justify-content: center;
        min-height: 44px;
        padding: 12px 16px;
    }

    .header-meta .about-link,
    .header-meta .github-link {
        display: flex;
        align-items: center;
    }

    .header-meta .theme-toggle {
        background: var(--input-bg);
        border: 1px solid var(--card-border);
        border-radius: 6px;
    }

    /* Make filters stack better */
    .filters {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        margin-bottom: 16px;
    }

    /* Provider toggles - wrap on mobile, hide label */
    .provider-toggles {
        width: 100%;
        flex-wrap: wrap;
        gap: 6px;
        justify-content: flex-start;
    }

    .provider-toggles label {
        display: none; /* Hide "Providers:" label on mobile */
    }

    .provider-toggle {
        flex-shrink: 0;
        white-space: nowrap;
        font-size: 0.8rem;
        padding: 8px 12px;
        min-height: 36px;
    }

    /* Filter dropdowns - full width on mobile */
    .filter-dropdowns {
        width: 100%;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
    }

    .filter-group {
        flex: 1 1 auto;
        min-width: 0;
    }

    .filter-group label {
        display: none; /* Hide labels, use placeholder/selected value */
    }

    .filter-group select {
        width: 100%;
        min-height: 44px;
        padding: 10px 12px;
        font-size: 0.9rem;
    }

    .definitions-link {
        margin-left: 0;
        justify-content: center;
        width: 100%;
        min-height: 44px;
        padding: 10px 14px;
        background: var(--input-bg);
        border-radius: 6px;
    }

    /* Feature cards - more compact on mobile */
    .feature-card {
        padding: 14px;
    }

    .feature-header {
        margin-bottom: 10px;
    }

    .feature-header h3 {
        font-size: 0.95rem;
    }

    /* Platform icons - horizontal scroll */
    .platforms-row {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
        gap: 4px;
    }

    .plat-icon {
        flex-shrink: 0;
        font-size: 0.6rem;
        padding: 3px 6px;
    }

    /* Talking point */
    .talking-point {
        padding: 12px 14px;
        font-size: 0.82rem;
    }

    /* Dates row - compact */
    .dates-row {
        gap: 8px;
        margin-top: 8px;
    }

    .date-item {
        font-size: 0.62rem;
    }

    /* Platform section headers */
    .platform-header h2 {
        font-size: 1.1rem;
    }

    .pricing-bar {
        gap: 8px;
    }

    .price-tag {
        font-size: 0.75rem;
        padding: 4px 10px;
    }

    /* Footer - more compact */
    footer {
        margin-top: 24px;
        padding-top: 16px;
        font-size: 0.75rem;
    }

    .footer-social {
        padding: 8px 12px;
        font-size: 0.75rem;
        margin: 4px 2px;
    }

    /* Feature count badge */
    .feature-count {
        font-size: 0.8rem;
        padding: 4px 10px;
    }

    /* Modal improvements for mobile */
    .modal {
        width: 95%;
        padding: 16px;
        max-height: 85vh;
    }

    .modal h3 {
        font-size: 1rem;
    }

    .changelog-table th, .changelog-table td {
        padding: 8px 10px;
        font-size: 0.8rem;
    }
}
