/* Modern Design System - CSAT Analyzer */
:root {
    --font-body: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-display: "Space Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
    --transition-fast: 160ms ease;

    /* Color Palette - Slate & Blue */
    --bg-body: #0f172a;
    --bg-surface: #1e293b;
    --bg-surface-hover: #334155;

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --brand-primary: #3b82f6;
    --brand-primary-hover: #2563eb;
    --brand-secondary: #64748b;

    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #0ea5e9;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-12: 3rem;
    --space-16: 4rem;

    /* Borders */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-full: 9999px;

    --border-color: rgba(148, 163, 184, 0.1);
    --border-focus: rgba(59, 130, 246, 0.5);

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-glow: 0 0 15px rgba(59, 130, 246, 0.3);
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background:
        radial-gradient(1200px 650px at 10% 0%, rgba(59, 130, 246, 0.22), transparent 60%),
        radial-gradient(900px 520px at 92% 6%, rgba(14, 165, 233, 0.16), transparent 62%),
        radial-gradient(800px 520px at 50% 110%, rgba(16, 185, 129, 0.10), transparent 55%),
        var(--bg-body);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--text-primary);
    font-weight: 700;
    font-family: var(--font-display);
    line-height: 1.2;
    margin-bottom: var(--space-4);
}

h1 {
    font-size: 2.5rem;
    letter-spacing: -0.025em;
}

h2 {
    font-size: 2rem;
    letter-spacing: -0.025em;
}

h3 {
    font-size: 1.5rem;
}

/* Layout */
.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--space-8) var(--space-4);
}

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

.section {
    padding: var(--space-12) 0;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: var(--space-4);
    margin-bottom: var(--space-6);
    flex-wrap: wrap;
}

/* Home */
.hero {
    position: relative;
    padding: var(--space-16) 0 var(--space-12);
}

.hero-title {
    font-size: 3rem;
    letter-spacing: -0.03em;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    flex-wrap: wrap;
}

/* Components */
/* Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.8);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: var(--space-4) 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-4);
    position: relative;
}

.nav-brand {
    font-weight: 800;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.nav-brand span {
    color: var(--brand-primary);
}

.nav-links {
    display: flex;
    gap: var(--space-6);
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
}

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

.nav-cta {
    background: rgba(59, 130, 246, 0.14);
    border: 1px solid rgba(59, 130, 246, 0.3);
    padding: 0.45rem 0.75rem;
    border-radius: var(--radius-full);
    color: var(--text-primary);
}

.nav-cta:hover {
    background: rgba(59, 130, 246, 0.22);
    color: var(--text-primary);
}

.nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-primary);
    cursor: pointer;
}

.nav-toggle:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(148, 163, 184, 0.25);
}

.nav-toggle:focus-visible,
.nav-link:focus-visible {
    outline: 2px solid var(--brand-primary);
    outline-offset: 2px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s;
    gap: var(--space-2);
}

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

.btn-primary:hover {
    background: var(--brand-primary-hover);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--bg-surface);
    color: var(--text-primary);
    border-color: var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-surface-hover);
    border-color: var(--text-secondary);
}

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

.btn-ghost:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.btn-full {
    width: 100%;
}

.btn-lg {
    padding: 0.75rem 1.35rem;
    font-size: 1.05rem;
    border-radius: var(--radius-lg);
}

.btn-sm {
    padding: 0.45rem 0.85rem;
    font-size: 0.9rem;
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border: 1px solid transparent;
    white-space: nowrap;
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: #6ee7b7;
    border-color: rgba(16, 185, 129, 0.25);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.14);
    color: #fcd34d;
    border-color: rgba(245, 158, 11, 0.25);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.14);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.25);
}

.badge-neutral {
    background: rgba(148, 163, 184, 0.14);
    color: #cbd5e1;
    border-color: rgba(148, 163, 184, 0.25);
}

/* Cards */
.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    box-shadow: var(--shadow-sm);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--space-4);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

/* Forms */
.form-group {
    margin-bottom: var(--space-4);
}

label {
    display: block;
    margin-bottom: var(--space-2);
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Utilities */
.text-center {
    text-align: center;
}

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

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

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

.text-gradient {
    background: linear-gradient(135deg, #fff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.mt-2 {
    margin-top: var(--space-2);
}

.mt-4 {
    margin-top: var(--space-4);
}

.mt-0 {
    margin-top: 0;
}

.mb-2 {
    margin-bottom: var(--space-2);
}

.mb-4 {
    margin-bottom: var(--space-4);
}

.mb-0 {
    margin-bottom: 0;
}

.gap-4 {
    gap: var(--space-4);
}

.grid {
    display: grid;
    gap: var(--space-6);
}

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

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: var(--radius-md);
    margin-bottom: var(--space-4);
    border: 1px solid transparent;
}

.alert-error,
.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.2);
    color: #6ee7b7;
}

.alert-info {
    background: rgba(14, 165, 233, 0.1);
    border-color: rgba(14, 165, 233, 0.2);
    color: #7dd3fc;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.25);
    color: #fcd34d;
}

.alert-debug {
    background: rgba(148, 163, 184, 0.12);
    border-color: rgba(148, 163, 184, 0.25);
    color: #cbd5e1;
}

/* Upload Zone Override */
.upload-zone {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: rgba(15, 23, 42, 0.3);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

/* New Utilities for About Page */
.container-sm {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.text-relaxed {
    line-height: 1.8;
}

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

.mt-8 {
    margin-top: var(--space-8);
}

/* Home Page Specifics */
.text-5xl {
    font-size: 5rem;
}

.text-2xl {
    font-size: 2rem;
}

.text-lg {
    font-size: 1.25rem;
}

.hero-subtitle {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto var(--space-8);
}

/* Auth & Legal Pages Utilities */
.container-xs {
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.my-16 {
    margin-top: 4rem;
    margin-bottom: 4rem;
}

.my-8 {
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.text-legal {
    line-height: 1.6;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.section-heading {
    color: var(--text-primary);
    margin-top: 1.5rem;
}

/* Card highlight override */
.highlight-card {
    background: linear-gradient(145deg, rgba(59, 130, 246, 0.1), rgba(15, 23, 42, 0.4));
    border: 1px solid rgba(59, 130, 246, 0.2);
    display: flex;
    align-items: center;
    gap: var(--space-4);
    text-align: left;
    flex-wrap: wrap;
}


.flex-center-gap {
    display: flex;
    gap: var(--space-4);
    justify-content: center;
    margin-bottom: var(--space-12);
    flex-wrap: wrap;
}

.list-none-grid {
    list-style: none;
    display: grid;
    gap: var(--space-4);
}

/* Form Styles */
.form-group input:not([type="submit"]):not([type="hidden"]),
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--brand-primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.helptext {
    color: var(--text-secondary);
    font-size: 0.85rem;
    display: block;
    margin-top: 0.25rem;
}


.img-fluid {
    width: 100%;
    display: block;
}

.rounded-lg {
    border-radius: var(--radius-lg);
}

.shadow-lg {
    box-shadow: var(--shadow-lg);
}

.shadow-glow {
    box-shadow: var(--shadow-glow);
}

.container-md {
    max-width: 900px;
    margin: 0 auto;
}

/* Footer */
.footer {
    border-top: 1px solid var(--border-color);
    padding: var(--space-8) 0;
    margin-top: var(--space-12);
    background: rgba(15, 23, 42, 0.35);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: var(--space-6);
    align-items: start;
}

.footer-title {
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: -0.01em;
}

.footer-links {
    display: flex;
    gap: var(--space-6);
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

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

/* Responsive */
@media (max-width: 720px) {
    .app-container {
        padding: var(--space-6) var(--space-4);
    }

    .hero {
        padding: var(--space-12) 0 var(--space-8);
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .nav-toggle {
        display: inline-flex;
    }

    .nav-links {
        position: absolute;
        top: calc(100% + 10px);
        right: 0;
        left: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: var(--space-2);
        padding: var(--space-3);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-lg);
        background: rgba(15, 23, 42, 0.96);
        -webkit-backdrop-filter: blur(14px);
        backdrop-filter: blur(14px);
        box-shadow: var(--shadow-lg);
    }

    .nav-links .nav-link {
        display: block;
        width: 100%;
        padding: 0.65rem 0.75rem;
        border-radius: var(--radius-md);
    }

    .nav-links .nav-link:hover,
    .nav-links .nav-link:focus-visible {
        background: rgba(148, 163, 184, 0.14);
    }

    .nav-links .nav-cta {
        text-align: center;
    }

    .nav-links.is-open {
        display: flex;
    }

    body.nav-open {
        overflow: hidden;
    }

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

    .footer-links {
        justify-content: flex-start;
    }
}
