/* ==========================================================
   AI IDEA EVALUATOR SAAS - HIGH-AESTHETICS DESIGN SYSTEM
   Theme: Midnight Glassmorphism / Cyber Obsidian
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    /* Color Palette */
    --bg-main: #090c15;
    --bg-secondary: #0e1322;
    --bg-tertiary: #161c31;
    --card-bg: rgba(18, 24, 43, 0.7);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-border-glow: rgba(99, 102, 241, 0.35);

    /* Gradients */
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
    --accent-glow: radial-gradient(circle, rgba(99, 102, 241, 0.22) 0%, rgba(139, 92, 246, 0.08) 45%, transparent 70%);
    --surface-gradient: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);

    /* Core Colors */
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #8b5cf6;
    --accent: #ec4899;

    /* Semantic Status Colors */
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.12);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.12);
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.12);
    --info: #06b6d4;
    --info-bg: rgba(6, 182, 212, 0.12);

    /* Text Colors */
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-subtle: #64748b;

    /* Shadows & Radii */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 22px;
    --radius-full: 9999px;
    --shadow-subtle: 0 4px 20px -2px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.25);
    --shadow-card: 0 10px 30px -5px rgba(0, 0, 0, 0.6);

    /* Fonts */
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

/* Ambient Background Lights */
body::before {
    content: '';
    position: fixed;
    top: -150px;
    left: 20%;
    width: 600px;
    height: 600px;
    background: var(--accent-glow);
    border-radius: 50%;
    filter: blur(80px);
    z-index: -1;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -150px;
    right: 15%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(90px);
    z-index: -1;
    pointer-events: none;
}

/* Container */
.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Navigation Header */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    background: rgba(9, 12, 21, 0.85);
    border-bottom: 1px solid var(--card-border);
    transition: all 0.3s ease;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

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

.brand-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-sm);
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.5);
}

.brand-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    background: rgba(99, 102, 241, 0.18);
    color: var(--primary-light);
    border: 1px solid rgba(99, 102, 241, 0.3);
    font-weight: 600;
    text-transform: uppercase;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    list-style: none;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.925rem;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: var(--text-main);
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.65rem 1.4rem;
    font-size: 0.925rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    border: none;
    font-family: inherit;
    position: relative;
    white-space: nowrap;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(99, 102, 241, 0.55);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(8px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--card-border);
}

.btn-outline:hover {
    color: var(--text-main);
    border-color: var(--primary);
}

.btn-lg {
    padding: 0.85rem 2rem;
    font-size: 1.05rem;
    border-radius: var(--radius-md);
}

.btn-sm {
    padding: 0.4rem 0.9rem;
    font-size: 0.825rem;
    border-radius: var(--radius-sm);
}

.btn-block {
    width: 100%;
}

/* Glassmorphic Cards */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow-card);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
}

.card:hover {
    border-color: rgba(99, 102, 241, 0.3);
}

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

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

/* Credit Badge */
.credit-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 1rem;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--primary-light);
}

.credit-badge .sparkle {
    color: #f59e0b;
}

/* Hero Section */
.hero {
    padding: 6rem 0 4rem;
    text-align: center;
    position: relative;
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 1rem;
    border-radius: var(--radius-full);
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.25);
    font-size: 0.85rem;
    color: var(--primary-light);
    margin-bottom: 1.75rem;
    font-weight: 600;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.25rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--text-muted);
    max-width: 680px;
    margin: 0 auto 2.5rem;
    font-weight: 400;
}

.hero-cta-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-bottom: 3.5rem;
}

/* Feature Grid */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.75rem;
    margin: 3rem 0;
}

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

.feature-card {
    padding: 2.25rem;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    border-color: var(--card-border-glow);
    box-shadow: var(--shadow-glow);
}

.feature-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-md);
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.25rem;
    color: var(--primary-light);
}

.feature-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
}

.feature-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.55;
}

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

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

.form-label .optional {
    color: var(--text-subtle);
    font-weight: 400;
    font-size: 0.8rem;
    margin-left: 0.25rem;
}

.form-control {
    width: 100%;
    padding: 0.8rem 1rem;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text-main);
    background: rgba(14, 19, 34, 0.85);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-md);
    transition: all 0.2s ease;
    outline: none;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
    background: rgba(18, 24, 43, 0.95);
}

.form-control::placeholder {
    color: var(--text-subtle);
}

textarea.form-control {
    resize: vertical;
    min-height: 130px;
}

/* Auth Cards */
.auth-wrapper {
    min-height: calc(100vh - 160px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1rem;
}

.auth-card {
    width: 100%;
    max-width: 460px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-card);
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-title {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    color: var(--text-muted);
    font-size: 0.925rem;
}

.auth-footer {
    text-align: center;
    margin-top: 1.75rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Alerts */
.alert {
    padding: 0.9rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-size: 0.925rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.alert-danger {
    background: var(--danger-bg);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.alert-success {
    background: var(--success-bg);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #6ee7b7;
}

.alert-warning {
    background: var(--warning-bg);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #fcd34d;
}

/* Status Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-high {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.badge-medium {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-low {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
}

/* Viability Score Dial */
.score-card {
    text-align: center;
    padding: 2.5rem;
    background: linear-gradient(180deg, rgba(30, 41, 69, 0.6) 0%, rgba(18, 24, 43, 0.8) 100%);
}

.score-dial-wrap {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto 1.5rem;
}

.score-dial-svg {
    transform: rotate(-90deg);
    width: 100%;
    height: 100%;
}

.score-dial-meter {
    transition: stroke-dashoffset 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.score-dial-inner {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.score-value {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    font-family: var(--font-sans);
}

.score-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 4px;
}

/* Tables */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--card-border);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.925rem;
    text-align: left;
}

.data-table th {
    background: rgba(14, 19, 34, 0.9);
    color: var(--text-muted);
    font-weight: 600;
    padding: 0.9rem 1.25rem;
    border-bottom: 1px solid var(--card-border);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
}

.data-table td {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--card-border);
    color: var(--text-main);
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* Evaluation Loader Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(4, 7, 15, 0.88);
    backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

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

.eval-loader-card {
    background: var(--card-bg);
    border: 1px solid rgba(99, 102, 241, 0.4);
    box-shadow: 0 0 50px rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-lg);
    padding: 3rem;
    max-width: 500px;
    width: 90%;
    text-align: center;
}

.spinner {
    width: 64px;
    height: 64px;
    border: 4px solid rgba(99, 102, 241, 0.2);
    border-top-color: var(--primary-light);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.75rem;
}

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

.step-indicator {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1.75rem;
    text-align: left;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--text-subtle);
    transition: color 0.3s ease;
}

.step-item.active {
    color: var(--primary-light);
    font-weight: 600;
}

.step-item.completed {
    color: var(--success);
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--text-subtle);
}

.step-item.active .step-dot {
    background: var(--primary-light);
    box-shadow: 0 0 8px var(--primary-light);
}

.step-item.completed .step-dot {
    background: var(--success);
}

/* Footer */
.footer {
    margin-top: auto;
    border-top: 1px solid var(--card-border);
    padding: 2.5rem 0;
    font-size: 0.875rem;
    color: var(--text-subtle);
    background: var(--bg-main);
}

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

/* Print Styles for Executive Report Export */
@media print {
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }
    body::before, body::after, .navbar, .footer, .btn, .no-print {
        display: none !important;
    }
    .card {
        background: #ffffff !important;
        color: #000000 !important;
        border: 1px solid #cccccc !important;
        box-shadow: none !important;
        page-break-inside: avoid;
    }
    .text-muted, .text-subtle {
        color: #444444 !important;
    }
    .data-table th {
        background: #f0f0f0 !important;
        color: #000000 !important;
    }
    .data-table td {
        border-color: #dddddd !important;
        color: #000000 !important;
    }
}

/* Responsive Utilities */
@media (max-width: 768px) {
    .nav-container {
        height: 64px;
    }
    .nav-links {
        display: none;
    }
    .hero {
        padding: 4rem 0 2rem;
    }
    .card {
        padding: 1.5rem;
    }
    .auth-card {
        padding: 1.75rem;
    }
}
