* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #1a3a6b;
  --primary-light: #2a5298;
  --accent: #c9a227;
  --accent-light: #f0c040;
  --bg: #f8f9fc;
  --card: #ffffff;
  --text: #1a1a2e;
  --text-muted: #6b7280;
  --border: #e5e7eb;
  --success: #16a34a;
  --danger: #dc2626;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(26,58,107,0.10);
}

body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; }

/* NAV */
.navbar { display: flex; align-items: center; justify-content: space-between; padding: 16px 40px; background: var(--primary); position: sticky; top: 0; z-index: 100; }
.nav-brand { color: #fff; font-size: 1.2rem; font-weight: 700; letter-spacing: 0.5px; }
.nav-links { display: flex; align-items: center; gap: 24px; }
.nav-links a { color: rgba(255,255,255,0.85); text-decoration: none; font-size: 0.9rem; }
.nav-links a:hover { color: #fff; }

/* BUTTONS */
.btn-primary { background: var(--accent); color: var(--primary); padding: 10px 22px; border-radius: 8px; font-weight: 700; text-decoration: none; border: none; cursor: pointer; font-size: 0.95rem; transition: background 0.2s; display: inline-block; }
.btn-primary:hover { background: var(--accent-light); }
.btn-outline { border: 2px solid var(--accent); color: var(--accent); padding: 8px 20px; border-radius: 8px; font-weight: 600; text-decoration: none; background: transparent; cursor: pointer; font-size: 0.95rem; transition: all 0.2s; display: inline-block; }
.btn-outline:hover { background: var(--accent); color: var(--primary); }
.btn-lg { padding: 14px 32px; font-size: 1.05rem; }
.btn-full { width: 100%; text-align: center; margin-top: 20px; }
.btn-danger { background: var(--danger); color: #fff; padding: 10px 22px; border-radius: 8px; font-weight: 600; border: none; cursor: pointer; font-size: 0.95rem; }

/* HERO */
.hero { display: flex; align-items: center; justify-content: space-between; gap: 40px; padding: 80px 40px; max-width: 1200px; margin: 0 auto; }
.hero-content { flex: 1; }
.badge { display: inline-block; background: rgba(26,58,107,0.1); color: var(--primary); padding: 4px 14px; border-radius: 20px; font-size: 0.8rem; font-weight: 600; margin-bottom: 16px; }
.hero-content h1 { font-size: 2.8rem; font-weight: 800; color: var(--primary); line-height: 1.2; margin-bottom: 20px; }
.hero-content p { font-size: 1.1rem; color: var(--text-muted); max-width: 480px; margin-bottom: 32px; }
.hero-actions { display: flex; align-items: center; gap: 20px; margin-bottom: 32px; }
.hero-note { font-size: 0.85rem; color: var(--text-muted); }
.visa-types { display: flex; flex-wrap: wrap; gap: 10px; }
.visa-types span { background: var(--primary); color: #fff; padding: 6px 14px; border-radius: 20px; font-size: 0.8rem; font-weight: 500; }

/* HERO CARD */
.hero-card { flex: 1; max-width: 420px; }
.consul-card { background: var(--card); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); border: 1px solid var(--border); }
.consul-avatar { font-size: 2.5rem; text-align: center; margin-bottom: 8px; }
.consul-name { text-align: center; font-weight: 700; color: var(--primary); font-size: 0.95rem; margin-bottom: 16px; }
.consul-bubble { background: var(--primary); color: #fff; padding: 12px 16px; border-radius: 12px 12px 12px 0; font-size: 0.88rem; margin-bottom: 10px; }
.applicant-bubble { background: #f0f4ff; color: var(--text); padding: 12px 16px; border-radius: 12px 12px 0 12px; font-size: 0.88rem; margin-bottom: 20px; }
.score-label { font-size: 0.8rem; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; display: block; margin-bottom: 10px; }
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; font-size: 0.8rem; color: var(--text-muted); }
.bar-row span { width: 140px; flex-shrink: 0; }
.bar { flex: 1; height: 6px; background: var(--border); border-radius: 3px; overflow: hidden; }
.fill { height: 100%; background: var(--accent); border-radius: 3px; }

/* HOW IT WORKS */
.how-it-works { background: var(--primary); color: #fff; padding: 80px 40px; text-align: center; }
.how-it-works h2 { font-size: 2rem; margin-bottom: 48px; }
.steps { display: flex; gap: 40px; max-width: 900px; margin: 0 auto; justify-content: center; }
.step { flex: 1; }
.step-num { width: 48px; height: 48px; background: var(--accent); color: var(--primary); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.2rem; margin: 0 auto 16px; }
.step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { font-size: 0.9rem; color: rgba(255,255,255,0.75); }

/* PACKAGES */
.packages { padding: 80px 40px; text-align: center; max-width: 1100px; margin: 0 auto; }
.packages h2 { font-size: 2rem; color: var(--primary); margin-bottom: 8px; }
.section-sub { color: var(--text-muted); margin-bottom: 48px; }
.package-cards { display: flex; gap: 24px; justify-content: center; flex-wrap: wrap; }
.package-card { background: var(--card); border: 2px solid var(--border); border-radius: var(--radius); padding: 32px 28px; width: 300px; position: relative; transition: box-shadow 0.2s; }
.package-card:hover { box-shadow: var(--shadow); }
.package-card.featured { border-color: var(--primary); }
.package-badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--primary); color: #fff; padding: 4px 16px; border-radius: 20px; font-size: 0.78rem; font-weight: 700; white-space: nowrap; }
.package-name { font-size: 1.2rem; font-weight: 700; color: var(--primary); margin-bottom: 8px; }
.package-price { font-size: 2.4rem; font-weight: 800; color: var(--accent); margin-bottom: 4px; }
.package-sessions { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 20px; }
.package-features { list-style: none; text-align: left; margin-bottom: 4px; }
.package-features li { padding: 6px 0; font-size: 0.9rem; color: var(--text-muted); border-bottom: 1px solid var(--border); }
.package-features li::before { content: '✓ '; color: var(--success); font-weight: 700; }

/* FOOTER */
.footer { background: var(--primary); color: rgba(255,255,255,0.7); text-align: center; padding: 32px; }
.footer-brand { color: #fff; font-weight: 700; font-size: 1.1rem; margin-bottom: 8px; }
.footer-note { font-size: 0.85rem; }

/* AUTH PAGE */
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%); }
.auth-card { background: #fff; border-radius: var(--radius); padding: 40px; width: 100%; max-width: 420px; box-shadow: 0 8px 40px rgba(0,0,0,0.2); }
.auth-logo { text-align: center; margin-bottom: 8px; font-size: 1.8rem; }
.auth-title { text-align: center; font-size: 1.4rem; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.auth-sub { text-align: center; color: var(--text-muted); font-size: 0.88rem; margin-bottom: 28px; }
.auth-tabs { display: flex; border-bottom: 2px solid var(--border); margin-bottom: 28px; }
.auth-tab { flex: 1; padding: 10px; text-align: center; cursor: pointer; font-weight: 600; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -2px; }
.auth-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 0.88rem; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.form-group input { width: 100%; padding: 10px 14px; border: 1.5px solid var(--border); border-radius: 8px; font-size: 0.95rem; outline: none; transition: border 0.2s; }
.form-group input:focus { border-color: var(--primary); }
.auth-error { background: #fef2f2; color: var(--danger); padding: 10px 14px; border-radius: 8px; font-size: 0.88rem; margin-bottom: 16px; display: none; }
.auth-btn { width: 100%; padding: 12px; background: var(--primary); color: #fff; border: none; border-radius: 8px; font-size: 1rem; font-weight: 700; cursor: pointer; margin-top: 8px; }
.auth-btn:hover { background: var(--primary-light); }

/* DASHBOARD */
.dashboard { max-width: 900px; margin: 0 auto; padding: 40px 24px; }
.dashboard-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 32px; }
.dashboard-header h1 { font-size: 1.6rem; color: var(--primary); }
.sessions-badge { background: var(--primary); color: #fff; padding: 8px 20px; border-radius: 20px; font-size: 0.9rem; font-weight: 600; }
.sessions-badge span { color: var(--accent); font-weight: 800; }
.section-title { font-size: 1.1rem; font-weight: 700; color: var(--primary); margin-bottom: 16px; }
.visa-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 40px; }
.visa-card { background: var(--card); border: 2px solid var(--border); border-radius: var(--radius); padding: 24px; cursor: pointer; transition: all 0.2s; text-align: center; }
.visa-card:hover { border-color: var(--primary); box-shadow: var(--shadow); }
.visa-card.selected { border-color: var(--primary); background: #f0f4ff; }
.visa-icon { font-size: 2.2rem; margin-bottom: 10px; }
.visa-card h3 { font-size: 1rem; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.visa-card p { font-size: 0.82rem; color: var(--text-muted); }
.start-btn { width: 100%; padding: 16px; background: var(--primary); color: #fff; border: none; border-radius: var(--radius); font-size: 1.05rem; font-weight: 700; cursor: pointer; margin-top: 8px; }
.start-btn:hover { background: var(--primary-light); }
.start-btn:disabled { background: var(--border); color: var(--text-muted); cursor: not-allowed; }
.past-sessions { margin-top: 40px; }
.session-row { display: flex; align-items: center; justify-content: space-between; background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 14px 20px; margin-bottom: 10px; }
.session-info { font-size: 0.9rem; }
.session-visa { font-weight: 600; color: var(--primary); }
.session-date { color: var(--text-muted); font-size: 0.82rem; }
.session-score { font-size: 1.1rem; font-weight: 800; color: var(--accent); }
.result-approved { color: var(--success); font-size: 0.8rem; font-weight: 700; }
.result-denied { color: var(--danger); font-size: 0.8rem; font-weight: 700; }
.no-sessions { text-align: center; color: var(--text-muted); padding: 32px; font-size: 0.9rem; }

/* INTERVIEW PAGE */
.interview-page { max-width: 800px; margin: 0 auto; padding: 32px 24px; }
.interview-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.interview-header h2 { font-size: 1.1rem; color: var(--primary); font-weight: 700; }
.turn-counter { font-size: 0.85rem; color: var(--text-muted); }
.consul-info { display: flex; align-items: center; gap: 12px; background: var(--primary); color: #fff; border-radius: var(--radius); padding: 16px 20px; margin-bottom: 24px; }
.consul-info-avatar { font-size: 1.8rem; }
.consul-info-name { font-weight: 700; font-size: 0.95rem; }
.consul-info-status { font-size: 0.8rem; opacity: 0.75; }
.chat-area { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; min-height: 360px; max-height: 420px; overflow-y: auto; margin-bottom: 20px; display: flex; flex-direction: column; gap: 14px; }
.msg { max-width: 80%; }
.msg-consul { align-self: flex-start; }
.msg-user { align-self: flex-end; }
.msg-bubble { padding: 12px 16px; border-radius: 12px; font-size: 0.92rem; line-height: 1.5; }
.msg-consul .msg-bubble { background: var(--primary); color: #fff; border-radius: 12px 12px 12px 0; }
.msg-user .msg-bubble { background: #e8edff; color: var(--text); border-radius: 12px 12px 0 12px; }
.msg-label { font-size: 0.75rem; color: var(--text-muted); margin-bottom: 4px; font-weight: 600; }
.msg-user .msg-label { text-align: right; }
.voice-panel { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; text-align: center; }
.voice-status { font-size: 0.88rem; color: var(--text-muted); margin-bottom: 16px; min-height: 20px; }
.voice-btn { width: 72px; height: 72px; border-radius: 50%; border: none; font-size: 1.8rem; cursor: pointer; transition: all 0.2s; margin: 0 auto; display: block; }
.voice-btn.idle { background: var(--primary); color: #fff; }
.voice-btn.recording { background: var(--danger); color: #fff; animation: pulse 1s infinite; }
.voice-btn.thinking { background: var(--border); color: var(--text-muted); cursor: not-allowed; }
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.08); } }
.voice-hint { font-size: 0.78rem; color: var(--text-muted); margin-top: 10px; }
.end-btn { margin-top: 16px; padding: 10px 24px; background: transparent; border: 1.5px solid var(--border); border-radius: 8px; color: var(--text-muted); cursor: pointer; font-size: 0.88rem; }
.end-btn:hover { border-color: var(--danger); color: var(--danger); }

/* REPORT PAGE */
.report-page { max-width: 800px; margin: 0 auto; padding: 40px 24px; }
.report-header { text-align: center; margin-bottom: 40px; }
.report-header h1 { font-size: 1.8rem; color: var(--primary); margin-bottom: 8px; }
.report-visa { color: var(--text-muted); font-size: 0.95rem; }
.score-circle { width: 120px; height: 120px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; margin: 0 auto 24px; }
.score-number { font-size: 2.2rem; font-weight: 800; color: var(--accent); line-height: 1; }
.score-text { font-size: 0.75rem; opacity: 0.8; }
.result-banner { text-align: center; padding: 12px 24px; border-radius: 8px; font-weight: 700; font-size: 1rem; margin-bottom: 32px; }
.result-banner.approved { background: #dcfce7; color: var(--success); }
.result-banner.denied { background: #fef2f2; color: var(--danger); }
.result-banner.additional { background: #fef9c3; color: #854d0e; }
.category-scores { display: grid; grid-template-columns: repeat(2,1fr); gap: 16px; margin-bottom: 32px; }
.cat-card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 16px 20px; }
.cat-name { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 6px; }
.cat-score { font-size: 1.4rem; font-weight: 800; color: var(--primary); }
.cat-score span { font-size: 0.8rem; color: var(--text-muted); font-weight: 400; }
.report-section { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 20px; }
.report-section h3 { font-size: 1rem; font-weight: 700; color: var(--primary); margin-bottom: 12px; }
.report-section p, .report-section li { font-size: 0.92rem; color: var(--text); line-height: 1.7; }
.report-actions { display: flex; gap: 12px; margin-top: 32px; }
.report-actions a, .report-actions button { flex: 1; text-align: center; padding: 14px; border-radius: 10px; font-weight: 700; cursor: pointer; font-size: 0.95rem; }

/* LOADING */
.loading { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--text-muted); font-size: 0.9rem; }
.dot { width: 6px; height: 6px; background: var(--primary); border-radius: 50%; animation: bounce 1.2s infinite; }
.dot:nth-child(2) { animation-delay: 0.2s; }
.dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes bounce { 0%,80%,100% { transform: translateY(0); } 40% { transform: translateY(-8px); } }

/* TOAST */
.toast { position: fixed; bottom: 24px; right: 24px; background: var(--text); color: #fff; padding: 12px 20px; border-radius: 8px; font-size: 0.9rem; z-index: 9999; opacity: 0; transform: translateY(10px); transition: all 0.3s; pointer-events: none; }
.toast.show { opacity: 1; transform: translateY(0); }

/* EMPTY STATE */
.empty { text-align: center; padding: 48px 24px; color: var(--text-muted); }
.empty-icon { font-size: 3rem; margin-bottom: 12px; }

@media (max-width: 768px) {
  .hero { flex-direction: column; padding: 40px 20px; }
  .hero-content h1 { font-size: 2rem; }
  .hero-card { max-width: 100%; }
  .steps { flex-direction: column; }
  .package-cards { flex-direction: column; align-items: center; }
  .visa-grid { grid-template-columns: 1fr; }
  .category-scores { grid-template-columns: 1fr; }
  .navbar { padding: 14px 20px; }
  .nav-links a:not(.btn-primary):not(.btn-outline) { display: none; }
}
