/* Modern Mobile-First Design System */
:root {
    /* Colors */
    --primary-green: #00C853;
    --primary-green-light: #E8F5E9;
    --primary-green-dim: rgba(0, 200, 83, 0.1);

    --bg: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.95);
    --card-bg: #f8f9fa;
    --card-glass: rgba(248, 249, 250, 0.8);

    --text-primary: #1a1a1a;
    --text-secondary: #6b7280;
    --border: #e5e7eb;

    /* Signals */
    --red: #EF4444;
    --red-glow: rgba(239, 68, 68, 0.3);
    --yellow: #F59E0B;
    --yellow-glow: rgba(245, 158, 11, 0.3);
    --green-glow: rgba(0, 200, 83, 0.3);

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-neon: 0 0 20px var(--primary-green-dim);

    /* Spacing */
    --container-padding: 24px;
    --header-height: 80px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-height) + 40px);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    /* Prevent horizontal scroll */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

/* Typography */
h1,
h2,
h3,
h4 {
    color: var(--text-primary);
    line-height: 1.2;
    font-weight: 700;
}

/* Header & Nav */
header {
    padding: 20px 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--bg-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    height: var(--header-height);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    text-decoration: none;
    z-index: 1001;
    position: relative;
}

.logo-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Desktop Nav */
nav {
    display: none;
    /* Mobile first hidden */
}

@media (min-width: 769px) {
    nav {
        display: flex;
        align-items: center;
        gap: 32px;
    }

    nav a {
        color: var(--text-secondary);
        text-decoration: none;
        font-weight: 500;
        transition: color 0.2s;
    }

    nav a:hover {
        color: var(--primary-green);
    }
}

/* Hamburger Menu Button */
.mobile-menu-btn {
    display: block;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 2001;
    /* Higher than menu layer (2000) */
    position: relative;
    color: var(--text-primary);
}

@media (min-width: 769px) {
    .mobile-menu-btn {
        display: none;
    }
}

/* Mobile Menu Overlay */
/* Mobile Menu Overlay (Dialog) */
dialog.mobile-menu {
    /* Reset dialog defaults */
    border: none;
    margin: 0;
    max-width: 100vw;
    max-height: 100vh;
    width: 100%;
    height: 100%;

    position: fixed;
    top: 0;
    left: 0;
    background: #ffffff;
    z-index: 2000;
    padding: 120px 24px 40px;

    /* Layout */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;

    /* Animation State (Hidden by default) */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* User Agent default for dialog:not([open]) is display:none, which we want. */
dialog.mobile-menu:not([open]) {
    display: none;
}

dialog.mobile-menu[open] {
    display: flex;
    /* Override active display */
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

dialog.mobile-menu a {
    font-size: 1.75rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 700;
    opacity: 0;
    transform: translateY(20px);
    transition: 0.3s ease-out;
}

/* Staggered Items Animation */
dialog.mobile-menu[open] a {
    opacity: 1;
    transform: translateY(0);
}

dialog.mobile-menu[open] a:nth-child(1) {
    transition-delay: 0.1s;
}

dialog.mobile-menu[open] a:nth-child(2) {
    transition-delay: 0.15s;
}

dialog.mobile-menu[open] a:nth-child(3) {
    transition-delay: 0.2s;
}

dialog.mobile-menu[open] a:nth-child(4) {
    transition-delay: 0.25s;
}

dialog.mobile-menu[open] a:nth-child(5) {
    transition-delay: 0.3s;
}



body.menu-open {
    overflow: hidden;
}

/* Major Sections */
section {
    padding: 60px 0;
}

/* Hero */
.hero {
    padding: 160px 0 60px;
    text-align: center;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.hero h1 span {
    color: var(--primary-green);
    display: block;
    /* Break line on mobile logically */
}

@media(min-width: 600px) {
    .hero h1 span {
        display: inline;
    }
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: var(--primary-green);
    color: #000;
    padding: 18px 36px;
    border-radius: 100px;
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 10px 20px rgba(0, 200, 83, 0.2);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px rgba(0, 200, 83, 0.3);
}

/* Screenshots Grid */
.screenshots {
    display: flex;
    justify-content: center;
    gap: 32px;
    padding: 40px 0 80px;
    flex-wrap: wrap;
    perspective: 1000px;
}

.screenshot {
    width: 260px;
    max-width: 80vw;
    border-radius: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    transition: transform 0.4s ease;
    border: 8px solid #fff;
}

/* Desktop stagger effect */
@media (min-width: 1024px) {
    .screenshot:nth-child(2) {
        transform: translateY(40px) scale(1.05);
        z-index: 2;
    }

    .screenshot:hover {
        transform: translateY(-10px) scale(1.02);
        z-index: 5;
    }

    .screenshot:nth-child(2):hover {
        transform: translateY(30px) scale(1.08);
    }
}

/* Features Grid */
.features {
    background: linear-gradient(to bottom, transparent, var(--card-bg) 20%);
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
}

.feature-card {
    background: #fff;
    padding: 40px 32px;
    border-radius: 20px;
    border: 1px solid var(--border);
    transition: 0.3s;
    box-shadow: var(--shadow-sm);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-green);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-green-light);
    color: var(--primary-green);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    font-size: 1.5rem;
    font-weight: 700;
}

/* How It Works (Steps) */
.how-it-works h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 48px;
    margin-top: 60px;
}

.step {
    text-align: center;
    position: relative;
}

.step-number {
    width: 50px;
    height: 50px;
    background: var(--primary-green);
    color: white;
    font-weight: 700;
    font-size: 1.25rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    box-shadow: 0 8px 16px rgba(0, 200, 83, 0.25);
}

/* Supported Platforms */
.platforms {
    padding: 80px 0;
    background: var(--card-bg);
}

.platforms h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 48px;
}

.platform-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    max-width: 700px;
    margin: 0 auto;
}

.platform-card {
    background: #fff;
    padding: 32px;
    border-radius: 16px;
    text-align: center;
    border: 2px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.platform-card h3 {
    margin: 16px 0 8px;
    font-size: 1.5rem;
}

.platform-card p {
    color: var(--text-secondary);
    margin: 0;
}

.platform-status {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
}

.platform-card.supported {
    border-color: var(--primary-green);
}

.platform-card.supported .platform-status {
    background: var(--primary-green-light);
    color: var(--primary-green);
}

.platform-card.coming-soon .platform-status {
    background: rgba(245, 158, 11, 0.1);
    color: var(--yellow);
}

.platform-request {
    text-align: center;
    margin-top: 32px;
    color: var(--text-secondary);
}

.platform-request a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 500;
}

.platform-request a:hover {
    text-decoration: underline;
}

/* Signals Grid - Critical Fix */
.signals {
    padding: 80px 0;
}

.signals h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.signals>p {
    text-align: center;
}

.signal-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.signal-card {
    background: #fff;
    padding: 32px;
    border-radius: 16px;
    text-align: center;
    border: 2px solid transparent;
    transition: 0.3s;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.signal-dot {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-bottom: 16px;
}

/* Variations */
.signal-card.green {
    border-color: var(--primary-green);
}

.signal-card.green .signal-dot {
    background: var(--primary-green);
    box-shadow: var(--green-glow);
}

.signal-card.yellow {
    border-color: var(--yellow);
}

.signal-card.yellow .signal-dot {
    background: var(--yellow);
    box-shadow: var(--yellow-glow);
}

.signal-card.red {
    border-color: var(--red);
}

.signal-card.red .signal-dot {
    background: var(--red);
    box-shadow: var(--red-glow);
}

/* Roadmap / What's Next Section */
.roadmap {
    padding: 80px 0;
    background: var(--card-bg);
}

.roadmap h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.roadmap-description {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 48px;
}

.roadmap-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.roadmap-card {
    background: #fff;
    padding: 32px;
    border-radius: 16px;
    text-align: center;
    border: 2px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.roadmap-card h3 {
    margin: 16px 0 8px;
    font-size: 1.25rem;
}

.roadmap-card p {
    color: var(--text-secondary);
    margin: 0;
    font-size: 0.95rem;
}

.roadmap-status {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.roadmap-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.roadmap-card.planned {
    border-color: var(--primary-green);
}

.roadmap-card.planned .roadmap-status {
    background: var(--primary-green-light);
    color: var(--primary-green);
}

.roadmap-card.planned .roadmap-icon {
    color: var(--primary-green);
}

.roadmap-card.exploring {
    border-color: var(--border);
}

.roadmap-card.exploring .roadmap-status {
    background: var(--card-bg);
    color: var(--text-secondary);
}

.roadmap-card.exploring .roadmap-icon {
    color: var(--text-secondary);
}

.roadmap-feedback {
    text-align: center;
    margin-top: 32px;
    color: var(--text-secondary);
}

.roadmap-feedback a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 500;
}

.roadmap-feedback a:hover {
    text-decoration: underline;
}

/* Privacy Section */
section.privacy h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 16px;
}

/* You're In Control Section */
section.control {
    background: var(--card-bg);
    padding: 80px 0;
}

section.control h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.control-description {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 40px;
    color: var(--text-secondary);
}

.control-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.control-point {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    color: var(--primary-green);
    font-weight: 500;
    text-align: left;
    padding: 0 16px;
}

.privacy-description {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 40px;
    color: var(--text-secondary);
}

.privacy-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.privacy-point {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    color: var(--primary-green);
    font-weight: 500;
    text-align: left;
    padding: 0 16px;
    /* Add some padding to prevent edge hugging */
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 80px 0 40px;
    margin-top: 60px;
}

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

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}

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

.footer-links a:hover {
    color: var(--primary-green);
}

.disclaimer {
    margin-top: 40px;
    border-top: 1px solid var(--border);
    padding-top: 24px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
    opacity: 0.8;
}

@media(max-width: 768px) {
    .header-content {
        padding: 0 16px;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-links {
        justify-content: center;
    }
}

/* Legal Pages Typography & Components */
body.legal-content main {
    padding-top: calc(var(--header-height) + 80px);
    padding-bottom: 80px;
}

.legal-content main .container {
    max-width: 800px;
}

.legal-content h1 {
    font-size: 2.5rem;
    margin-bottom: 8px;
}

.legal-content h2 {
    font-size: 1.5rem;
    margin: 48px 0 16px;
    color: var(--text-primary);
}

.legal-content h3 {
    font-size: 1.15rem;
    margin: 32px 0 12px;
}

.legal-content p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.legal-content ul,
.legal-content ol {
    margin: 16px 0;
    padding-left: 24px;
    color: var(--text-secondary);
}

.legal-content li {
    margin-bottom: 8px;
}

.legal-content main a {
    color: var(--text-primary);
    text-decoration: underline;
}

.legal-content hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 48px 0;
}

.last-updated {
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.warning-box {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-left: 4px solid var(--red);
    padding: 24px;
    border-radius: 8px;
    margin: 24px 0;
}

.warning-box p {
    color: var(--text-primary);
    margin-bottom: 0;
}

.disclaimer-box,
.summary-box {
    background: var(--card-bg);
    border: 1px solid var(--border);
    padding: 24px;
    border-radius: 8px;
    margin: 24px 0;
}

.summary-box h2 {
    margin-top: 0;
    margin-bottom: 16px;
}
