/* style.css */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;700&family=Inter:wght@300;400;600&display=swap');

:root {
    --primary: #001bff;
    --primary-glow: rgba(0, 27, 255, 0.4);
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.6);
    --text-main: #0b0c15;
    --text-muted: #64666e;
    --radius-lg: 24px;
    --radius-md: 16px;
    --shadow-soft: 0 20px 40px rgba(0, 27, 255, 0.05);
    --shadow-glow: 0 0 20px rgba(0, 27, 255, 0.15);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
    font-family: 'Inter', sans-serif;
    background: #f2f4f8;
    color: var(--text-main);
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
}

/* --- ANIMATED BACKGROUND --- */
.ambient-bg {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
    background: radial-gradient(circle at 10% 10%, #eef2ff 0%, transparent 40%),
                radial-gradient(circle at 90% 90%, #e0e7ff 0%, transparent 40%);
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.5;
    animation: float 25s infinite ease-in-out alternate;
}
.orb-1 { width: 600px; height: 600px; background: #001bff; top: -100px; left: -100px; opacity: 0.15; }
.orb-2 { width: 500px; height: 500px; background: #6366f1; bottom: -100px; right: -100px; opacity: 0.15; animation-delay: -5s; }

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 30px) scale(1.1); }
}

/* --- APP CONTAINER --- */
.app-window {
    width: 100%;
    max-width: 900px;
    min-height: 85vh;
    margin: 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: height 0.4s ease;
}

/* --- HEADER --- */
.glass-header {
    padding: 30px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(0,0,0,0.03);
}

.brand {
    display: flex; align-items: center; gap: 12px;
}
.brand img { height: 28px; }
.brand-text { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 18px; letter-spacing: -0.5px; }

/* --- PROGRESS --- */
.progress-container {
    height: 4px; width: 100%; background: rgba(0,27,255,0.05);
}
.progress-bar {
    height: 100%; background: var(--primary); width: 0%;
    transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    box-shadow: 0 0 10px var(--primary-glow);
}

/* --- VIEWS & ANIMATIONS --- */
.view {
    padding: 40px 50px;
    flex: 1;
    display: none;
    opacity: 0;
    overflow-y: auto;
}
.view.active {
    display: block;
    animation: fadeIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

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

/* --- TYPOGRAPHY --- */
h1 { font-family: 'Space Grotesk', sans-serif; font-size: 42px; font-weight: 700; margin: 0 0 15px 0; letter-spacing: -1.5px; line-height: 1.1; }
.subtitle { font-size: 16px; color: var(--text-muted); line-height: 1.6; max-width: 550px; font-weight: 400; }
.section-tag {
    font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 1.5px;
    color: var(--primary); background: rgba(0, 27, 255, 0.08);
    padding: 8px 12px; border-radius: 30px; display: inline-block; margin-bottom: 25px;
}

/* --- CARDS (Profile) --- */
.grid-cards {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; margin-top: 50px;
}
.card {
    background: rgba(255,255,255,0.5);
    border: 1px solid rgba(255,255,255,0.8);
    padding: 30px 25px; border-radius: var(--radius-md);
    cursor: pointer; transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative; overflow: hidden;
}
.card:hover {
    background: #fff; transform: translateY(-8px);
    box-shadow: var(--shadow-glow); border-color: var(--primary);
}
.card-icon { font-size: 32px; margin-bottom: 20px; display: block; filter: grayscale(1); transition: filter 0.3s; }
.card:hover .card-icon { filter: grayscale(0); }
.card-title { font-weight: 700; font-size: 16px; margin-bottom: 8px; color: var(--text-main); }
.card-desc { font-size: 13px; color: var(--text-muted); line-height: 1.4; }

/* --- QUIZ UI --- */
.question-text { font-family: 'Space Grotesk', sans-serif; font-size: 32px; font-weight: 600; color: var(--text-main); margin-bottom: 40px; line-height: 1.2; }
.options-list { display: grid; gap: 15px; }
.option-btn {
    padding: 22px 28px; background: rgba(255,255,255,0.6);
    border: 1px solid rgba(255,255,255,0.8); border-radius: var(--radius-md);
    font-size: 16px; font-weight: 500; color: var(--text-main);
    display: flex; justify-content: space-between; align-items: center;
    cursor: pointer; transition: all 0.2s ease;
}
.option-btn:hover { background: #fff; border-color: var(--primary); color: var(--primary); transform: scale(1.01); box-shadow: var(--shadow-soft); }
.option-btn span { opacity: 0; transform: translateX(-10px); transition: all 0.2s; }
.option-btn:hover span { opacity: 1; transform: translateX(0); }

/* --- SCALE --- */
.scale-group { display: flex; gap: 12px; margin-top: 20px; }
.scale-item {
    flex: 1; height: 70px; background: rgba(255,255,255,0.6);
    border: 1px solid rgba(255,255,255,0.8); border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; font-weight: 700; color: var(--text-muted);
    cursor: pointer; transition: all 0.2s;
}
.scale-item:hover, .scale-item.selected { 
    background: var(--primary); color: white; border-color: var(--primary);
    box-shadow: var(--shadow-glow); transform: translateY(-3px);
}

/* --- BUTTONS & INPUTS --- */
.btn-primary {
    width: 100%; padding: 22px;
    background: var(--primary); color: white;
    border: none; border-radius: var(--radius-md);
    font-size: 16px; font-weight: 700; letter-spacing: 0.5px;
    cursor: pointer; transition: all 0.3s;
    box-shadow: 0 10px 30px rgba(0, 27, 255, 0.25);
    margin-top: 30px; position: relative; overflow: hidden;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 15px 40px rgba(0, 27, 255, 0.35); }
.btn-primary::after {
    content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: 0.5s;
}
.btn-primary:hover::after { left: 100%; }

.btn-back {
    background: none; border: none; color: var(--text-muted);
    font-size: 14px; font-weight: 600; padding: 15px 0;
    cursor: pointer; margin-top: 20px; display: inline-flex; align-items: center;
    transition: color 0.2s;
}
.btn-back:hover { color: var(--text-main); }

.glass-input, .glass-select {
    width: 100%; padding: 20px;
    background: rgba(255,255,255,0.6);
    border: 1px solid rgba(0,0,0,0.05); border-radius: var(--radius-md);
    font-size: 16px; font-family: inherit; color: var(--text-main);
    transition: all 0.2s;
}
.glass-input:focus, .glass-select:focus { 
    outline: none; background: #fff; border-color: var(--primary); 
    box-shadow: 0 0 0 4px rgba(0, 27, 255, 0.1); 
}
.form-label { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--text-muted); margin-bottom: 12px; letter-spacing: 0.5px; }
.form-group { margin-bottom: 30px; }

/* --- DASHBOARD (PDF Friendly) --- */
#result-view { padding: 0 !important; background: white !important; }
.dash-header { background: #0b0c15; color: white; padding: 50px; display: flex; justify-content: space-between; align-items: flex-start; }
.dash-layout { display: grid; grid-template-columns: 300px 1fr; min-height: 900px; }
.dash-sidebar { background: #f8f9fa; padding: 50px 30px; border-right: 1px solid #eef2ff; }
.dash-content { padding: 50px; }

/* Metrics */
.score-circle {
    width: 140px; height: 140px; border-radius: 50%;
    border: 10px solid var(--primary);
    display: flex; align-items: center; justify-content: center;
    font-size: 56px; font-weight: 800; color: var(--primary);
    margin: 0 auto 20px; background: white;
}
.metric-row { margin-bottom: 30px; }
.metric-title { font-size: 11px; font-weight: 700; text-transform: uppercase; color: #888; display: flex; justify-content: space-between; margin-bottom: 8px; }
.metric-track { height: 8px; background: #e0e0e0; border-radius: 4px; overflow: hidden; }
.metric-fill { height: 100%; border-radius: 4px; }

/* Tables & Boxes */
.report-table { width: 100%; border-collapse: collapse; margin: 40px 0; }
.report-table th { text-align: left; font-size: 11px; text-transform: uppercase; color: #888; border-bottom: 2px solid #eee; padding-bottom: 12px; }
.report-table td { padding: 18px 0; border-bottom: 1px solid #f5f5f5; font-size: 14px; font-weight: 500; }

.financial-card {
    background: #f4f7ff; border: 1px solid #e0e6ff;
    padding: 30px; border-radius: var(--radius-md);
    display: flex; justify-content: space-between;
}

.cta-section { margin-top: 60px; text-align: center; padding-top: 40px; border-top: 2px dashed #eee; }
.btn-book {
    display: inline-block; background: var(--primary); color: white !important;
    padding: 16px 32px; border-radius: 50px; text-decoration: none;
    font-weight: 700; font-size: 14px; margin-top: 20px;
    box-shadow: 0 10px 20px rgba(0,27,255,0.2); transition: all 0.2s;
}
.btn-book:hover { transform: translateY(-2px); box-shadow: 0 15px 30px rgba(0,27,255,0.3); }

/* --- MOBILE & PRINT --- */
@media (max-width: 768px) {
    .app-window { border-radius: 0; margin: 0; min-height: 100vh; }
    .view { padding: 30px 20px; }
    .glass-header { padding: 20px; }
    h1 { font-size: 32px; }
    .question-text { font-size: 24px; }
    .dash-layout { grid-template-columns: 1fr; }
    .financial-card { flex-direction: column; gap: 20px; }
}

@media print {
    body { background: white; -webkit-print-color-adjust: exact; }
    .app-window { box-shadow: none; border: none; margin: 0; max-width: 100%; width: 100%; }
    .ambient-bg, .glass-header, .progress-container, #country-view, #profile-view, #quiz-view, #lead-view { display: none !important; }
    #result-view { display: block !important; }
    .dash-header { background: #0b0c15 !important; color: white !important; }
    .score-circle { border-color: #001bff !important; color: #001bff !important; }
    .dash-sidebar { background: #f8f9fa !important; }
    .financial-card { background: #f4f7ff !important; }
    .metric-fill { -webkit-print-color-adjust: exact; }
    .btn-primary, button { display: none !important; }
    .btn-book { display: block !important; }
    .dash-layout { display: grid; grid-template-columns: 280px 1fr; }
    @page { margin: 0; size: A4; }
}