:root {
    --bg: #0f1720;
    --fg: #e6eef6;
    --muted: #9aa7b2;
    --accent: #1fb6ff;
    --accent-hover: #0ea5e9;
    --secondary: #6366f1;
    --success: #10b981;
    --gradient: linear-gradient(135deg, var(--accent), var(--secondary));
    --shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] {
    --bg: #ffffff;
    --fg: #0f1720;
    --muted: #546b75;
    --accent: #0066cc;
    --accent-hover: #0052a3;
    --secondary: #4f46e5;
    --success: #059669;
    --gradient: linear-gradient(135deg, var(--accent), var(--secondary));
    --shadow: 0 10px 25px rgba(15, 23, 32, 0.08);
    --shadow-lg: 0 20px 40px rgba(15, 23, 32, 0.12);
}

* {
    box-sizing: border-box;
}

body {
    background: var(--bg);
    color: var(--fg);
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    margin: 0;
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

/* Header Styles */
.site-header {
    background: rgba(15, 23, 32, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .site-header {
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
}

.logo img {
    display: block;
    transition: transform 0.3s ease;
    border-radius: 8px;
}

.logo:hover img {
    transform: scale(1.05);
}

.main-nav {
    display: flex;
    gap: 2rem;
}

.main-nav a {
    color: var(--fg);
    text-decoration: none;
    position: relative;
    transition: all 0.3s ease;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.main-nav a:hover {
    color: var(--accent);
    background: rgba(31, 182, 255, 0.1);
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.main-nav a:hover::after {
    width: 80%;
}

.controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Language Selector and Controls */
.lang-dropdown {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--fg);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    min-width: 120px;
}

[data-theme="light"] .lang-dropdown {
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.lang-dropdown:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--accent);
    transform: translateY(-1px);
}

[data-theme="light"] .lang-dropdown:hover {
    background: rgba(0, 0, 0, 0.1);
}

.lang-dropdown:focus {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.lang-dropdown option {
    background: var(--bg);
    color: var(--fg);
    padding: 0.5rem;
}

.theme-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--fg);
    padding: 0.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.2rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

[data-theme="light"] .theme-btn {
    background: rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.theme-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
    transform: rotate(180deg) translateY(-1px);
}

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

/* Hero Section */
.hero {
    padding: 6rem 0;
    background: var(--gradient);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><defs><radialGradient id="a" cx="50%" cy="0%" r="100%"><stop offset="0%" stop-color="rgba(255,255,255,0.1)"/><stop offset="100%" stop-color="transparent"/></radialGradient></defs><rect width="100" height="20" fill="url(%23a)"/></svg>');
    animation: shimmer 3s ease-in-out infinite;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    width: 200px;
    height: 400px;
    background: #000;
    border-radius: 30px;
    padding: 20px;
    box-shadow: var(--shadow-lg);
    position: relative;
}

.phone-screen {
    width: 100%;
    height: 100%;
    background: var(--gradient);
    border-radius: 20px;
    opacity: 0.8;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn.primary {
    background: white;
    color: var(--accent);
    box-shadow: var(--shadow);
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn.secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* Features Section */
.features {
    padding: 6rem 0;
    background: var(--bg);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--fg);
}

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

.feature-card {
    background: rgba(255, 255, 255, 0.02);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.feature-card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.feature-card p {
    color: var(--muted);
}

/* Download Section */
.download-section {
    padding: 6rem 0;
    background: rgba(31, 182, 255, 0.05);
    text-align: center;
}

.download-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--fg);
}

.download-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: var(--muted);
}

.download-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.store-button {
    transition: transform 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.store-button:not([style*="cursor: not-allowed"]):hover {
    transform: scale(1.05);
}

.store-button img {
    height: 60px;
    width: auto;
    transition: opacity 0.3s ease;
}

/* Web App store button (clickable) */
.store-button.web {
    cursor: pointer;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.12);
    padding: 0.75rem 1rem;
}

.store-button.web a {
    color: var(--fg);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.store-button.web svg {
    height: 60px;
    width: 60px;
    color: var(--accent);
    transition: transform 0.25s ease, color 0.2s ease;
}

.store-button.web .store-label {
    font-size: 0.95rem;
    color: var(--fg);
    font-weight: 600;
}

.store-button.web:hover svg {
    transform: scale(1.06);
    color: var(--accent-hover);
}

.store-button.web:focus-within {
    outline: 3px solid rgba(31, 182, 255, 0.25);
    outline-offset: 4px;
}

.store-button[style*="cursor: not-allowed"] {
    position: relative;
}

.store-button[style*="cursor: not-allowed"]::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    pointer-events: none;
}

.store-button span {
    font-size: 0.875rem;
    color: var(--muted);
    font-weight: 500;
}

/* Footer */
.site-footer {
    padding: 3rem 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    background: rgba(15, 23, 32, 0.5);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

@keyframes shimmer {
    0% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.5;
    }
}

.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-slide-up {
    animation: slideUp 0.8s ease-out both;
}

.animate-bounce {
    animation: bounce 2s infinite;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-actions {
        justify-content: center;
    }

    .phone-mockup {
        width: 150px;
        height: 300px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .download-buttons {
        flex-direction: column;
        align-items: center;
    }

    .main-nav {
        display: none;
    }
}

/* Download Page Styles */
.download-hero {
    padding: 6rem 0;
    background: var(--gradient);
    position: relative;
    overflow: hidden;
}

.download-hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.download-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.download-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.phone-mockup-large {
    width: 250px;
    height: 500px;
    background: #000;
    border-radius: 40px;
    padding: 20px;
    box-shadow: var(--shadow-lg);
    position: relative;
    margin: 0 auto;
}

.phone-screen-content {
    width: 100%;
    height: 100%;
    background: var(--bg);
    border-radius: 30px;
    overflow: hidden;
    position: relative;
}

.app-interface {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.status-bar {
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    margin-bottom: 10px;
}

.app-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: var(--accent);
    color: white;
}

.app-icon-small {
    width: 24px;
    height: 24px;
}

.app-content {
    flex: 1;
    padding: 20px;
    background: var(--bg);
}

.map-placeholder {
    height: 200px;
    background: rgba(31, 182, 255, 0.2);
    border-radius: 10px;
    margin-bottom: 20px;
    position: relative;
}

.route-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.route-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.route-line {
    width: 20px;
    height: 3px;
    background: var(--accent);
    border-radius: 2px;
}

.download-options {
    padding: 6rem 0;
    background: var(--bg);
}

.platform-detection {
    text-align: center;
    margin-bottom: 3rem;
}

.platform-detection h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--fg);
}

.platform-detection p {
    font-size: 1.25rem;
    color: var(--muted);
}

.store-buttons {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 4rem;
    flex-wrap: wrap;
}

.store-button-large {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 2rem;
    background: var(--fg);
    color: var(--bg);
    text-decoration: none;
    border-radius: 16px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
    min-width: 200px;
}

.store-button-large:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.store-button-large.ios {
    background: #000;
    color: white;
}

.store-button-large.android {
    background: #01875f;
    color: white;
}

.store-icon {
    flex-shrink: 0;
}

.store-text {
    display: flex;
    flex-direction: column;
}

.store-label {
    font-size: 0.875rem;
    opacity: 0.8;
}

.store-name {
    font-size: 1.25rem;
    font-weight: 600;
}

.qr-section {
    text-align: center;
    margin-bottom: 4rem;
}

.qr-section h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--fg);
}

.qr-codes {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.qr-card {
    text-align: center;
}

.qr-placeholder {
    width: 120px;
    height: 120px;
    background: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: var(--shadow);
}

.qr-pattern {
    width: 80px;
    height: 80px;
    background:
        linear-gradient(90deg, #000 2px, transparent 2px),
        linear-gradient(#000 2px, transparent 2px);
    background-size: 10px 10px;
    opacity: 0.3;
}

.features-preview {
    text-align: center;
    margin-bottom: 3rem;
}

.features-preview h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--fg);
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    max-width: 800px;
    margin: 0 auto;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-2px);
}

.download-note {
    text-align: center;
    color: var(--muted);
    font-style: italic;
    margin-top: 2rem;
}

/* About Page Styles */
.about-hero {
    padding: 6rem 0 4rem;
    background: linear-gradient(135deg, rgba(31, 182, 255, 0.1), rgba(99, 102, 241, 0.1));
    position: relative;
    overflow: hidden;
}

.about-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><defs><radialGradient id="a" cx="50%" cy="0%" r="100%"><stop offset="0%" stop-color="rgba(255,255,255,0.05)"/><stop offset="100%" stop-color="transparent"/></radialGradient></defs><rect width="100" height="20" fill="url(%23a)"/></svg>');
    animation: shimmer 4s ease-in-out infinite;
}

.about-hero-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

.about-hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.about-hero p {
    font-size: 1.25rem;
    color: var(--muted);
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.about-features {
    padding: 6rem 0;
    background: var(--bg);
}

.features-intro {
    text-align: center;
    margin-bottom: 4rem;
}

.features-intro h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--fg);
}

.features-intro p {
    font-size: 1.125rem;
    color: var(--muted);
    max-width: 800px;
    margin: 0 auto;
}

.dual-system {
    margin-bottom: 6rem;
}

.dual-system h3 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--fg);
}

.system-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
}

.system-card {
    background: rgba(255, 255, 255, 0.02);
    padding: 2.5rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.system-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transition: left 0.5s ease;
}

.system-card:hover::before {
    left: 100%;
}

.system-card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow-lg);
}

.system-card.independent {
    border-left: 4px solid var(--accent);
}

.system-card.organization {
    border-left: 4px solid var(--secondary);
}

.system-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.system-card h4 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--fg);
}

.system-card ul {
    list-style: none;
    padding: 0;
}

.system-card li {
    padding: 0.5rem 0;
    color: var(--muted);
    position: relative;
    padding-left: 1.5rem;
}

.system-card li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

.transportation-categories {
    margin-bottom: 6rem;
}

.transportation-categories h3 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--fg);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.category-card {
    background: rgba(255, 255, 255, 0.02);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.category-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow-lg);
}

.category-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.category-card h4 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.category-card p {
    color: var(--muted);
    line-height: 1.6;
}

.platform-benefits h3 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--fg);
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.benefit-item {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.benefit-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: var(--shadow);
}

.benefit-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.benefit-content h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--accent);
}

.benefit-content p {
    color: var(--muted);
    line-height: 1.6;
}

.about-cta {
    padding: 6rem 0;
    background: rgba(31, 182, 255, 0.05);
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--fg);
}

.cta-content p {
    font-size: 1.25rem;
    color: var(--muted);
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Legal Pages Styles */
.legal-content {
    padding: 4rem 0;
    max-width: 800px;
    margin: 0 auto;
}

.legal-content h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--fg);
    text-align: center;
}

.legal-content h2 {
    font-size: 1.75rem;
    margin-top: 3rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.legal-content h3 {
    font-size: 1.25rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--fg);
}

.legal-content p {
    margin-bottom: 1rem;
    line-height: 1.6;
    color: var(--muted);
}

.legal-content ul,
.legal-content ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
    color: var(--muted);
}

.legal-content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.legal-content a {
    color: var(--accent);
    text-decoration: none;
}

.legal-content a:hover {
    text-decoration: underline;
}

.legal-meta {
    background: rgba(255, 255, 255, 0.02);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.legal-meta p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--muted);
}

.legal-actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    flex-wrap: wrap;
}

/* Responsive Design for About and Legal Pages */
@media (max-width: 768px) {
    .about-hero h1 {
        font-size: 2.5rem;
    }

    .hero-stats {
        gap: 2rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .system-grid {
        grid-template-columns: 1fr;
    }

    .categories-grid {
        grid-template-columns: 1fr;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .benefit-item {
        flex-direction: column;
        text-align: center;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .legal-content {
        padding: 2rem 1rem;
    }

    .legal-content h1 {
        font-size: 2rem;
    }
}

/* Accessibility */
:focus {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {

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

/* Improve Privacy Policy link visibility in dark mode.
   Note: `theme.js` sets `data-theme="light"` for light mode and removes the attribute for dark mode,
   so the default selector (no data-theme) is used for dark styling. */
#footer-privacy {
    color: #1fb6ff;
    background: rgba(31, 182, 255, 0.08);
    padding: 0.2em 0.6em;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: underline;
    transition: background 0.2s, color 0.2s;
}

#footer-privacy:hover {
    color: #0ea5e9;
    background: rgba(31, 182, 255, 0.18);
}

/* Improve Privacy Policy link visibility in light mode */
[data-theme="light"] #footer-privacy {
    color: #004f9e;
    /* darker blue for good contrast on white */
    background: rgba(0, 102, 204, 0.06);
    padding: 0.2em 0.6em;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: none;
    /* avoid double emphasis in light */
    transition: background 0.2s, color 0.2s;
}

[data-theme="light"] #footer-privacy:hover {
    color: #003a76;
    background: rgba(0, 102, 204, 0.12);
}

/* Keyboard focus styling for accessibility (applies to both themes) */
#footer-privacy:focus-visible {
    outline: 3px solid rgba(31, 182, 255, 0.35);
    outline-offset: 3px;
    border-radius: 4px;
}