/* ===== CSS Variables ===== */
:root {
  --navy: #1a2332;
  --navy-light: #243044;
  --teal: #00b4d8;
  --teal-dark: #0096b7;
  --gold: #f4a261;
  --white: #ffffff;
  --off-white: #f8f9fa;
  --gray-100: #f0f2f5;
  --gray-200: #e2e6ea;
  --gray-300: #ccd1d9;
  --gray-500: #8892a0;
  --gray-700: #4a5568;
  --gray-900: #1a202c;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
  --shadow-xl: 0 20px 60px rgba(0,0,0,0.15);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --transition: all 0.3s ease;
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); color: var(--gray-900); line-height: 1.6; background: var(--white); -webkit-font-smoothing: antialiased; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ===== Container ===== */
.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

/* ===== Navbar ===== */
.navbar { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; padding: 16px 0; transition: var(--transition); background: transparent; }
.navbar.scrolled { background: rgba(26,35,50,0.95); backdrop-filter: blur(12px); padding: 12px 0; box-shadow: var(--shadow-md); }
.nav-content { display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; gap: 8px; }
.logo-text { font-size: 20px; font-weight: 700; color: var(--white); letter-spacing: -0.5px; }
.logo-accent { color: var(--teal); }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { color: rgba(255,255,255,0.8); font-size: 14px; font-weight: 500; transition: var(--transition); }
.nav-links a:hover { color: var(--white); }
.mobile-menu-btn { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.mobile-menu-btn span { display: block; width: 24px; height: 2px; background: var(--white); margin: 5px 0; transition: var(--transition); }

/* ===== Buttons ===== */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 28px; border-radius: 50px; font-size: 14px; font-weight: 600; cursor: pointer; transition: var(--transition); border: none; font-family: var(--font); }
.btn-primary { background: var(--teal); color: var(--white); }
.btn-primary:hover { background: var(--teal-dark); transform: translateY(-2px); box-shadow: 0 8px 25px rgba(0,180,216,0.35); }
.btn-nav { background: rgba(255,255,255,0.15); color: var(--white); border: 1px solid rgba(255,255,255,0.25); padding: 10px 24px; }
.btn-nav:hover { background: rgba(255,255,255,0.25); }
.btn-lg { padding: 16px 36px; font-size: 16px; }
.btn-outline { background: transparent; border: 2px solid var(--teal); color: var(--teal); }
.btn-outline:hover { background: var(--teal); color: var(--white); }
.btn-secondary { background: var(--gray-200); color: var(--gray-700); }
.btn-secondary:hover { background: var(--gray-300); }
.btn-gold { background: var(--gold); color: var(--navy); }
.btn-gold:hover { background: #e8963a; transform: translateY(-2px); }

/* ===== Hero ===== */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; justify-content: center; text-align: center; background: linear-gradient(135deg, #1a2332 0%, #0d1b2a 50%, #1b3a4b 100%); overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: 0; background: url('https://images.unsplash.com/photo-1488646953014-85cb44e25828?w=1920&q=80') center/cover; opacity: 0.2; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(26,35,50,0.4) 0%, rgba(26,35,50,0.8) 100%); }
.hero-content { position: relative; z-index: 2; padding: 0 24px; max-width: 700px; }
.hero-title { font-size: clamp(36px, 6vw, 64px); font-weight: 800; color: var(--white); line-height: 1.1; letter-spacing: -1.5px; margin-bottom: 20px; }
.hero-subtitle { font-size: clamp(16px, 2.5vw, 20px); color: rgba(255,255,255,0.7); line-height: 1.6; margin-bottom: 36px; font-weight: 300; }
.hero-note { margin-top: 16px; font-size: 13px; color: rgba(255,255,255,0.5); }

/* ===== Sections ===== */
.section { padding: 100px 0; }
.section-light { background: var(--white); }
.section-dark { background: var(--navy); }
.section-title { font-size: 36px; font-weight: 700; text-align: center; margin-bottom: 12px; letter-spacing: -0.5px; }
.section-title.light { color: var(--white); }
.section-subtitle { text-align: center; color: var(--gray-500); font-size: 18px; margin-bottom: 60px; }

/* ===== Steps ===== */
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.step-card { text-align: center; padding: 40px 30px; border-radius: var(--radius-lg); background: var(--off-white); transition: var(--transition); position: relative; }
.step-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.step-number { position: absolute; top: -16px; left: 50%; transform: translateX(-50%); width: 36px; height: 36px; background: var(--teal); color: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; }
.step-icon { margin: 16px auto 20px; }
.step-card h3 { font-size: 20px; font-weight: 600; margin-bottom: 12px; }
.step-card p { color: var(--gray-500); font-size: 15px; line-height: 1.7; }

/* ===== Features ===== */
.features-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px; }
.feature { padding: 32px; border-radius: var(--radius); background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.08); transition: var(--transition); }
.feature:hover { background: rgba(255,255,255,0.08); border-color: rgba(0,180,216,0.3); }
.feature h4 { color: var(--teal); font-size: 18px; margin-bottom: 10px; }
.feature p { color: rgba(255,255,255,0.6); font-size: 15px; line-height: 1.7; }

/* ===== About ===== */
.about-content { max-width: 760px; margin: 0 auto; text-align: center; }
.about-content p { font-size: 17px; color: var(--gray-700); line-height: 1.8; margin-bottom: 20px; }

/* ===== CTA Banner ===== */
.cta-banner { background: linear-gradient(135deg, var(--teal) 0%, #0096b7 100%); padding: 80px 0; text-align: center; }
.cta-banner h2 { font-size: 32px; color: var(--white); margin-bottom: 12px; }
.cta-banner p { color: rgba(255,255,255,0.8); font-size: 18px; margin-bottom: 32px; }
.cta-banner .btn-primary { background: var(--white); color: var(--teal-dark); }
.cta-banner .btn-primary:hover { background: var(--off-white); box-shadow: 0 8px 25px rgba(0,0,0,0.2); }

/* ===== Footer ===== */
.footer { background: var(--navy); padding: 60px 0 0; color: rgba(255,255,255,0.6); }
.footer-content { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; padding-bottom: 40px; }
.footer-logo { margin-bottom: 12px; }
.footer-desc { font-size: 14px; }
.footer-col h4 { color: var(--white); font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px; }
.footer-col p, .footer-col a { display: block; font-size: 14px; margin-bottom: 8px; transition: var(--transition); }
.footer-col a:hover { color: var(--teal); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding: 20px 0; }
.footer-bottom p { font-size: 13px; text-align: center; color: rgba(255,255,255,0.4); }

/* ===== APP PAGE STYLES ===== */

/* App Layout */
.app-page { background: var(--off-white); min-height: 100vh; }
.app-navbar { background: var(--navy); padding: 16px 0; }
.app-main { padding: 40px 0 80px; }
.app-container { max-width: 720px; margin: 0 auto; padding: 0 24px; }

/* Progress Bar */
.progress-wrapper { margin-bottom: 40px; }
.progress-header { display: flex; justify-content: space-between; margin-bottom: 8px; }
.progress-label { font-size: 13px; color: var(--gray-500); font-weight: 500; }
.progress-bar { height: 4px; background: var(--gray-200); border-radius: 4px; overflow: hidden; }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--teal), #00d4ff); border-radius: 4px; transition: width 0.5s ease; }

/* Card */
.card { background: var(--white); border-radius: var(--radius-lg); padding: 48px; box-shadow: var(--shadow-sm); border: 1px solid var(--gray-100); }

/* Step 1: Text Input */
.step-intro { margin-bottom: 28px; }
.step-intro h2 { font-size: 28px; font-weight: 700; margin-bottom: 8px; color: var(--navy); }
.step-intro p { color: var(--gray-500); font-size: 16px; }
.text-input-large { width: 100%; min-height: 120px; padding: 18px; border: 2px solid var(--gray-200); border-radius: var(--radius-sm); font-size: 16px; font-family: var(--font); resize: vertical; transition: var(--transition); line-height: 1.6; }
.text-input-large:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 4px rgba(0,180,216,0.1); }
.text-input-large::placeholder { color: var(--gray-300); }
.step-actions { margin-top: 24px; display: flex; justify-content: flex-end; gap: 12px; }

/* Question Groups */
.question-group { margin-bottom: 28px; }
.question-group:last-child { margin-bottom: 0; }
.question-label { font-size: 15px; font-weight: 600; color: var(--navy); margin-bottom: 12px; display: block; }
.question-sublabel { font-size: 13px; color: var(--gray-500); margin-top: -8px; margin-bottom: 12px; }

/* Option Chips */
.option-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.option-chip { padding: 10px 20px; border: 2px solid var(--gray-200); border-radius: 50px; font-size: 14px; font-weight: 500; cursor: pointer; transition: var(--transition); background: var(--white); color: var(--gray-700); user-select: none; }
.option-chip:hover { border-color: var(--teal); color: var(--teal); }
.option-chip.selected { background: var(--teal); border-color: var(--teal); color: var(--white); }
.option-chip.multi-select.selected { background: rgba(0,180,216,0.1); border-color: var(--teal); color: var(--teal); }

/* Slider */
.slider-container { padding: 0 4px; }
.range-slider { width: 100%; height: 6px; -webkit-appearance: none; appearance: none; background: var(--gray-200); border-radius: 3px; outline: none; }
.range-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--teal); cursor: pointer; box-shadow: 0 2px 6px rgba(0,180,216,0.4); }
.slider-labels { display: flex; justify-content: space-between; margin-top: 8px; font-size: 13px; color: var(--gray-500); }
.slider-value { text-align: center; margin-top: 8px; font-size: 18px; font-weight: 600; color: var(--teal); }

/* Select */
.select-input { width: 100%; padding: 12px 16px; border: 2px solid var(--gray-200); border-radius: var(--radius-sm); font-size: 15px; font-family: var(--font); background: var(--white); cursor: pointer; transition: var(--transition); appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238892a0' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; }
.select-input:focus { outline: none; border-color: var(--teal); }

/* Text input */
.text-input { width: 100%; padding: 12px 16px; border: 2px solid var(--gray-200); border-radius: var(--radius-sm); font-size: 15px; font-family: var(--font); transition: var(--transition); }
.text-input:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 4px rgba(0,180,216,0.1); }

/* Loading Animation */
.loading-screen { text-align: center; padding: 80px 0; }
.loading-spinner { width: 48px; height: 48px; border: 3px solid var(--gray-200); border-top-color: var(--teal); border-radius: 50%; animation: spin 0.8s linear infinite; margin: 0 auto 24px; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { color: var(--gray-500); font-size: 16px; }
.loading-text span { display: block; margin-top: 4px; font-size: 14px; color: var(--gray-300); }

/* Results */
.results-header { text-align: center; margin-bottom: 40px; }
.results-header h2 { font-size: 32px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.results-header p { color: var(--gray-500); font-size: 16px; }
.results-container { max-width: 900px; margin: 0 auto; padding: 0 24px; }

.destination-card { background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); border: 1px solid var(--gray-100); margin-bottom: 24px; transition: var(--transition); }
.destination-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.dest-image { height: 220px; background-size: cover; background-position: center; position: relative; }
.dest-match { position: absolute; top: 16px; right: 16px; background: rgba(0,180,216,0.9); color: var(--white); padding: 6px 14px; border-radius: 50px; font-size: 13px; font-weight: 700; backdrop-filter: blur(4px); }
.dest-body { padding: 28px; }
.dest-name { font-size: 24px; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.dest-country { color: var(--gray-500); font-size: 14px; margin-bottom: 12px; }
.dest-desc { color: var(--gray-700); font-size: 15px; line-height: 1.7; margin-bottom: 16px; }
.dest-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.dest-tag { padding: 4px 12px; background: rgba(0,180,216,0.08); color: var(--teal-dark); border-radius: 50px; font-size: 12px; font-weight: 600; }
.dest-meta { display: flex; gap: 24px; padding-top: 16px; border-top: 1px solid var(--gray-100); margin-bottom: 20px; }
.dest-meta-item { font-size: 13px; color: var(--gray-500); }
.dest-meta-item strong { color: var(--navy); font-weight: 600; }
.dest-actions { display: flex; gap: 12px; }

/* Modal */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 9999; display: none; align-items: center; justify-content: center; backdrop-filter: blur(4px); }
.modal-overlay.active { display: flex; }
.modal { background: var(--white); border-radius: var(--radius-lg); padding: 48px; max-width: 480px; width: 90%; text-align: center; animation: modalIn 0.3s ease; }
@keyframes modalIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
.modal-icon { width: 56px; height: 56px; background: rgba(0,180,216,0.1); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.modal h3 { font-size: 22px; color: var(--navy); margin-bottom: 8px; }
.modal p { color: var(--gray-500); font-size: 15px; margin-bottom: 24px; line-height: 1.6; }
.modal-input-group { display: flex; gap: 8px; margin-bottom: 16px; }
.modal-input-group input { flex: 1; padding: 12px 16px; border: 2px solid var(--gray-200); border-radius: 50px; font-size: 15px; font-family: var(--font); }
.modal-input-group input:focus { outline: none; border-color: var(--teal); }
.modal-input-group .btn { white-space: nowrap; }
.modal-close { background: none; border: none; color: var(--gray-500); cursor: pointer; font-size: 14px; margin-top: 8px; font-family: var(--font); }
.modal-close:hover { color: var(--gray-700); }
.modal-success { color: var(--teal); font-weight: 600; font-size: 15px; }

/* Restart */
.restart-section { text-align: center; margin-top: 40px; padding-top: 40px; border-top: 1px solid var(--gray-200); }
.restart-section p { color: var(--gray-500); font-size: 15px; margin-bottom: 16px; }

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open { display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: var(--navy); padding: 24px; gap: 16px; }
  .mobile-menu-btn { display: block; }
  .steps-grid { grid-template-columns: 1fr; gap: 48px; }
  .features-grid { grid-template-columns: 1fr; }
  .footer-content { grid-template-columns: 1fr; gap: 32px; }
  .card { padding: 28px; }
  .hero-title { font-size: 36px; }
  .dest-meta { flex-wrap: wrap; gap: 12px; }
  .dest-actions { flex-direction: column; }
  .modal-input-group { flex-direction: column; }
}
