:root {
    --color-bg: #f8fafc;
    --color-surface: #ffffff;
    --color-surface-elevated: #ffffff;
    --color-border: #e2e8f0;
    --color-text-primary: #0f172a;
    --color-text-secondary: #475569;
    --color-text-muted: #64748b;
    --color-primary: #0f172a;
    --color-primary-light: #1e293b;
    --color-accent: #0ea5e9;
    --color-accent-dark: #0284c7;
    --color-success: #10b981;
    --color-success-bg: #ecfdf5;
    --color-warning: #f59e0b;
    --color-error: #ef4444;
    --color-error-bg: #fef2f2;
    --shadow-sm: 0 1px 2px 0 rgb(15 23 42 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(15 23 42 / 0.08), 0 2px 4px -2px rgb(15 23 42 / 0.06);
    --shadow-lg: 0 10px 15px -3px rgb(15 23 42 / 0.08), 0 4px 6px -4px rgb(15 23 42 / 0.05);
    --shadow-xl: 0 20px 25px -5px rgb(15 23 42 / 0.08), 0 8px 10px -6px rgb(15 23 42 / 0.05);
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.25rem;
    --radius-full: 9999px;
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --header-height: 4.5rem;
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
}

#app {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.app-main {
    flex: 1 0 auto;
    padding-top: var(--header-height);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
    transition: box-shadow var(--transition-base);
}

.site-header.scrolled {
    box-shadow: var(--shadow-md);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--color-text-primary);
    font-weight: 800;
    font-size: 1.375rem;
    letter-spacing: -0.02em;
}

.brand-mark {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
    display: grid;
    place-items: center;
    color: white;
    box-shadow: var(--shadow-sm);
}

.brand-mark svg {
    width: 1.25rem;
    height: 1.25rem;
}

.brand-text span {
    color: var(--color-accent);
}

.main-nav {
    display: none;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--color-text-secondary);
    font-weight: 600;
    font-size: 0.9375rem;
    transition: color var(--transition-fast);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-accent);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--color-accent);
    border-radius: var(--radius-full);
}

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

.mobile-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border: none;
    background: transparent;
    color: var(--color-text-primary);
    cursor: pointer;
    border-radius: var(--radius-md);
    transition: background var(--transition-fast);
}

.mobile-menu-toggle:hover {
    background: var(--color-bg);
}

@media (min-width: 768px) {
    .main-nav {
        display: flex;
    }
    .mobile-menu-toggle {
        display: none;
    }
}

/* Mobile menu */
.mobile-menu {
    display: none;
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(12px);
    z-index: 999;
    padding: 1.5rem;
    flex-direction: column;
    gap: 0.5rem;
    animation: slideIn 200ms ease;
}

.mobile-menu.open {
    display: flex;
}

.mobile-menu .nav-link {
    font-size: 1.125rem;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
}

.mobile-menu .nav-link:hover {
    background: var(--color-bg);
}

.mobile-menu .nav-link.active::after {
    display: none;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(-0.5rem); }
    to { opacity: 1; transform: translateY(0); }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-family: inherit;
    font-weight: 600;
    font-size: 0.9375rem;
    line-height: 1.5;
    text-decoration: none;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
}

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

.btn-primary:hover {
    background: var(--color-primary-light);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.btn-accent {
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px rgba(14, 165, 233, 0.35);
}

.btn-accent:hover {
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.45);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: var(--color-text-secondary);
    border-color: var(--color-border);
}

.btn-outline:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    background: rgba(14, 165, 233, 0.04);
}

.btn-ghost {
    background: transparent;
    color: var(--color-text-secondary);
    border-color: transparent;
}

.btn-ghost:hover {
    background: var(--color-bg);
    color: var(--color-text-primary);
}

.btn-lg {
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* User menu */
.user-menu {
    position: relative;
}

.user-menu-button {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--radius-full);
    border: 1px solid var(--color-border);
    background: var(--color-surface);
    color: var(--color-text-secondary);
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: all var(--transition-fast);
}

.user-menu-button:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
    background: rgba(14, 165, 233, 0.04);
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    min-width: 12rem;
    background: var(--color-surface-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: 0.5rem;
    animation: fadeIn 150ms ease;
    z-index: 1001;
}

.user-dropdown a,
.user-dropdown button {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.625rem 0.875rem;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--color-text-secondary);
    font-weight: 500;
    font-size: 0.9375rem;
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: all var(--transition-fast);
}

.user-dropdown a:hover,
.user-dropdown button:hover {
    background: var(--color-bg);
    color: var(--color-text-primary);
}

.user-dropdown svg {
    width: 1.125rem;
    height: 1.125rem;
    flex-shrink: 0;
}

/* Hero */
.hero {
    position: relative;
    padding: 5rem 0 6rem;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0c4a6e 100%);
    color: white;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(14, 165, 233, 0.2) 0%, transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(16, 185, 129, 0.12) 0%, transparent 40%);
    pointer-events: none;
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 3rem 3rem;
    mask-image: linear-gradient(to bottom, black 30%, transparent 100%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.875rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
    backdrop-filter: blur(4px);
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin: 0 0 1.25rem;
    letter-spacing: -0.03em;
}

.hero-title .accent {
    color: var(--color-accent);
}

.hero-subtitle {
    font-size: clamp(1.0625rem, 2.2vw, 1.25rem);
    color: rgba(255, 255, 255, 0.75);
    margin: 0 auto 2rem;
    max-width: 640px;
    line-height: 1.7;
}

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

/* Section styling */
.section {
    padding: 4rem 0;
}

.section-alt {
    background: var(--color-surface);
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 3rem;
}

.section-label {
    display: inline-block;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-accent);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    margin: 0 0 1rem;
    letter-spacing: -0.02em;
}

.section-description {
    font-size: 1.0625rem;
    color: var(--color-text-secondary);
    margin: 0;
}

/* Cards */
.card {
    background: var(--color-surface-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.card-body {
    padding: 2rem;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

/* Status card */
.status-card {
    max-width: 880px;
    margin: 0 auto;
    margin-top: -3.5rem;
    position: relative;
    z-index: 2;
}

.status-card .card-body {
    padding: 2.5rem;
}

/* Form controls */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 0.5rem;
}

.form-input,
.form-select {
    width: 100%;
    padding: 0.75rem 1rem;
    font-family: inherit;
    font-size: 0.9375rem;
    color: var(--color-text-primary);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
}

.form-input::placeholder {
    color: var(--color-text-muted);
}

.form-hint {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    margin-top: 0.375rem;
}

.form-error {
    font-size: 0.875rem;
    color: var(--color-error);
    margin-top: 0.375rem;
}

.input-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 0.75rem;
    align-items: center;
}

.input-row span {
    color: var(--color-text-muted);
    font-weight: 500;
    font-size: 0.9375rem;
}

/* Time result cards */
.result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
}

.result-card {
    padding: 1.5rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    background: linear-gradient(145deg, #ffffff, #f8fafc);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.result-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.result-card.best {
    border-color: rgba(14, 165, 233, 0.3);
    background: linear-gradient(145deg, #ffffff, #f0f9ff);
}

.result-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--radius-md);
    display: grid;
    place-items: center;
    margin-bottom: 1rem;
}

.result-icon.blue {
    background: rgba(14, 165, 233, 0.1);
    color: var(--color-accent);
}

.result-icon.orange {
    background: rgba(249, 115, 22, 0.1);
    color: #f97316;
}

.result-label {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent);
    margin-bottom: 0.25rem;
}

.result-time {
    font-size: 2rem;
    font-weight: 800;
    color: var(--color-text-primary);
    line-height: 1.2;
    margin-bottom: 0.25rem;
}

.result-duration {
    font-size: 0.9375rem;
    color: var(--color-text-secondary);
}

.result-empty {
    color: var(--color-text-muted);
    font-size: 0.9375rem;
}

/* Processing card */
.processing-visual {
    text-align: center;
    padding: 1rem 0;
}

.processing-number {
    font-size: clamp(4rem, 10vw, 6rem);
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.processing-label {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    margin-top: 0.5rem;
}

.progress-bar {
    width: 100%;
    height: 0.625rem;
    background: var(--color-bg);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin: 1.5rem 0 1rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
    border-radius: var(--radius-full);
    transition: width 600ms ease;
}

/* Feature cards */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.feature-card {
    padding: 2rem;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    background: var(--color-surface);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(14, 165, 233, 0.2);
}

.feature-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.1) 0%, rgba(14, 165, 233, 0.05) 100%);
    color: var(--color-accent);
    display: grid;
    place-items: center;
    margin-bottom: 1.5rem;
}

.feature-icon svg {
    width: 1.75rem;
    height: 1.75rem;
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.feature-text {
    color: var(--color-text-secondary);
    margin: 0;
    font-size: 0.9375rem;
}

/* Footer */
.site-footer {
    background: var(--color-primary);
    color: rgba(255, 255, 255, 0.7);
    padding: 3rem 0;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    text-align: center;
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: 800;
    font-size: 1.25rem;
    text-decoration: none;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.footer-links a:hover {
    color: white;
}

.footer-copy {
    font-size: 0.875rem;
    margin: 0;
}

/* Page layouts */
.page-header {
    padding: 2.5rem 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e0f2fe 100%);
    border-bottom: 1px solid var(--color-border);
}

.page-header-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 640px) {
    .page-header-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
}

.page-title {
    font-size: clamp(1.75rem, 4vw, 2.25rem);
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.02em;
}

.page-body {
    padding: 2rem 0 4rem;
}

/* Login page */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - var(--header-height));
    padding: 2rem 0;
}

.login-card {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    text-align: center;
}

.login-card .card-body {
    padding: 2.5rem;
}

.login-title {
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0 0 0.5rem;
}

.login-subtitle {
    color: var(--color-text-secondary);
    margin-bottom: 2rem;
}

.google-btn-wrapper {
    display: flex;
    justify-content: center;
    min-height: 48px;
}

/* Settings */
.settings-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
}

@media (min-width: 1024px) {
    .settings-grid {
        grid-template-columns: 360px 1fr;
        align-items: start;
    }
}

.settings-summary {
    background: linear-gradient(145deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid rgba(14, 165, 233, 0.15);
}

.settings-summary h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 1.25rem;
}

.summary-item {
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(14, 165, 233, 0.1);
}

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

.summary-item svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--color-accent);
    margin-top: 0.125rem;
    flex-shrink: 0;
}

.summary-item h4 {
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--color-text-muted);
    margin: 0 0 0.25rem;
}

.summary-item p {
    margin: 0;
    color: var(--color-text-primary);
    font-weight: 500;
}

.autocomplete-wrapper {
    position: relative;
}

.autocomplete-wrapper input {
    display: none;
}

/* Traffic details */
.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.chart-card {
    padding: 1.5rem;
}

.chart-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 1rem;
}

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

/* States */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 3rem 1rem;
    color: var(--color-text-secondary);
}

.spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid var(--color-border);
    border-top-color: var(--color-accent);
    border-radius: var(--radius-full);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.error-state {
    text-align: center;
    padding: 2.5rem;
    color: var(--color-error);
    background: var(--color-error-bg);
    border: 1px solid rgba(239, 68, 68, 0.15);
    border-radius: var(--radius-lg);
}

.error-state h3 {
    margin: 0 0 0.5rem;
    font-size: 1.125rem;
}

.error-state p {
    margin: 0;
    color: var(--color-text-secondary);
}

.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
    color: var(--color-text-secondary);
}

.empty-state svg {
    width: 4rem;
    height: 4rem;
    color: var(--color-text-muted);
    margin-bottom: 1rem;
}

.empty-state h3 {
    margin: 0 0 0.5rem;
    color: var(--color-text-primary);
}

.empty-state p {
    margin: 0;
}

/* Toasts */
.toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    min-width: 280px;
    max-width: 420px;
    padding: 1rem 1.25rem;
    border-radius: var(--radius-lg);
    background: var(--color-surface-elevated);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-xl);
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    animation: toastIn 300ms ease;
}

.toast.success {
    border-color: rgba(16, 185, 129, 0.25);
    background: var(--color-success-bg);
}

.toast.error {
    border-color: rgba(239, 68, 68, 0.15);
    background: var(--color-error-bg);
}

.toast-message {
    flex: 1;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-text-primary);
}

.toast-close {
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    padding: 0.25rem;
    display: grid;
    place-items: center;
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast);
}

.toast-close:hover {
    color: var(--color-text-primary);
}

@keyframes toastIn {
    from { opacity: 0; transform: translateY(1rem); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(0.5rem); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 400ms ease forwards;
}

/* Utilities */
.text-center { text-align: center; }
.text-muted { color: var(--color-text-muted); }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.w-full { width: 100%; }
.hidden { display: none !important; }

/* Animations for page content */
.page-content {
    animation: fadeIn 400ms ease;
}

/* Legal pages */
.legal-page {
    padding: 3rem 0 5rem;
}

.legal-container {
    max-width: 800px;
    margin: 0 auto;
}

.legal-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.legal-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0 0 0.5rem;
}

.legal-header p {
    color: var(--color-text-muted);
    margin: 0;
}

.legal-content {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
}

.legal-content h2 {
    font-size: 1.375rem;
    font-weight: 700;
    margin: 2rem 0 0.75rem;
    color: var(--color-text-primary);
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 1.5rem 0 0.5rem;
    color: var(--color-text-secondary);
}

.legal-content p,
.legal-content li {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
}

.legal-content ul,
.legal-content ol {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

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

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

/* Responsive tweaks */
@media (max-width: 640px) {
    .section {
        padding: 3rem 0;
    }

    .hero {
        padding: 4rem 0 5rem;
    }

    .card-body {
        padding: 1.5rem;
    }

    .status-card .card-body {
        padding: 1.5rem;
    }

    .input-row {
        grid-template-columns: 1fr;
    }

    .input-row span {
        text-align: center;
    }

    .footer-inner {
        gap: 1rem;
    }
}
