/* ============================================
   MAIN.CSS — LEGACY IMPORT HUB
   Энэ файлыг устгаагүй (дүрмийн дагуу).
   Шинэ бүтэц: base.css, header.css, hero.css,
   sections.css, login.css, footer.css
   Dashboard: admin.css
   ============================================ */

/* dashboard.html энэ файлыг ашигладаг тул
   shared variables-г энд хадгалж байна */
:root {
    --gold: #f9d71c;
    --gold-hover: #e6c200;
    --gold-subtle: rgba(249,215,28,0.10);
    --gold-ring: rgba(249,215,28,0.25);
    --white: #ffffff;
    --bg: #f7f8fa;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --green: #10b981;
    --green-bg: #ecfdf5;
    --red: #ef4444;
    --red-bg: #fef2f2;
    --amber: #f59e0b;
    --amber-bg: #fffbeb;
    --blue: #3b82f6;
    --blue-bg: #eff6ff;
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.06);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.08);
    --transition: 0.2s ease;
    --sidebar-w: 72px;
    --header-h: 64px;
}

/* -- Reset -- */
* { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body { font-family:'Inter',system-ui,-apple-system,sans-serif; color:var(--gray-800); background:var(--white); line-height:1.6; overflow-x:hidden; }
a { text-decoration:none; color:inherit; }
button { font-family:inherit; cursor:pointer; border:none; background:none; }
input,select,textarea { font-family:inherit; }

/* -- Shared Form Components -- */
.tab-row { display:flex; margin-bottom:24px; background:var(--gray-100); border-radius:var(--radius-sm); overflow:hidden; }
.tab-btn { flex:1; padding:10px 16px; font-size:0.8125rem; font-weight:600; color:var(--gray-500); background:transparent; transition:var(--transition); }
.tab-btn.active { background:var(--gold); color:var(--gray-900); }
.form-group { margin-bottom:16px; }
.form-label { display:block; font-size:0.8125rem; font-weight:600; color:var(--gray-700); margin-bottom:6px; }
.form-input { width:100%; padding:10px 14px; border:1px solid var(--gray-200); border-radius:10px; font-size:0.875rem; color:var(--gray-800); transition:var(--transition); background:var(--white); outline:none; }
.form-input:focus { border-color:var(--gold); box-shadow:0 0 0 3px var(--gold-ring); }
.form-input::placeholder { color:var(--gray-400); }
.btn-gold { width:100%; padding:12px; background:var(--gold); color:var(--gray-900); font-weight:700; font-size:0.875rem; border-radius:var(--radius); transition:var(--transition); margin-top:8px; }
.btn-gold:hover { background:var(--gold-hover); }
.btn-dark { width:100%; padding:12px; background:var(--gray-800); color:var(--white); font-weight:600; font-size:0.875rem; border-radius:var(--radius); transition:var(--transition); margin-top:8px; }
.btn-dark:hover { background:var(--gray-700); }
.error-msg { color:var(--red); font-size:0.75rem; margin-top:4px; display:none; }
.success-msg { color:var(--green); font-size:0.75rem; margin-top:4px; display:none; }

/* -- Landing Header -- */
.l-header { position:fixed; top:0; left:0; right:0; z-index:100; background:rgba(255,255,255,0.92); backdrop-filter:blur(12px); border-bottom:1px solid var(--gray-200); height:var(--header-h); display:flex; align-items:center; padding:0 32px; transition:var(--transition); }
.l-header-inner { max-width:1280px; margin:0 auto; width:100%; display:flex; align-items:center; justify-content:space-between; }
.l-logo { font-weight:800; font-size:1.125rem; color:var(--gray-900); display:flex; align-items:center; gap:8px; }
.l-logo-mark { width:32px; height:32px; background:var(--gold); border-radius:var(--radius-sm); display:flex; align-items:center; justify-content:center; }
.l-logo-mark svg { width:18px; height:18px; }
.l-nav { display:flex; gap:32px; }
.l-nav a { font-size:0.8125rem; font-weight:600; color:var(--gray-500); letter-spacing:1px; text-transform:uppercase; transition:var(--transition); position:relative; padding:4px 0; }
.l-nav a:hover { color:var(--gray-900); }
.l-nav a::after { content:''; position:absolute; bottom:-2px; left:0; width:0; height:2px; background:var(--gold); transition:var(--transition); }
.l-nav a:hover::after { width:100%; }
.l-header-actions { display:flex; align-items:center; gap:12px; }
.btn-login { padding:10px 24px; background:var(--gold); color:var(--gray-900); font-weight:700; font-size:0.8125rem; border-radius:var(--radius); transition:var(--transition); letter-spacing:0.5px; }
.btn-login:hover { background:var(--gold-hover); transform:translateY(-1px); box-shadow:0 4px 12px var(--gold-ring); }
.btn-login:active { transform:translateY(0) scale(0.98); }
.mobile-toggle { display:none; flex-direction:column; gap:5px; padding:8px; cursor:pointer; }
.mobile-toggle span { width:20px; height:2px; background:var(--gray-700); border-radius:2px; transition:var(--transition); }

/* -- Hero -- */
.hero { min-height:100vh; display:flex; align-items:center; justify-content:center; text-align:center; padding:calc(var(--header-h) + 40px) 24px 80px; position:relative; overflow:hidden; background:var(--white); }
.hero-bg { position:absolute; inset:0; pointer-events:none; overflow:hidden; }
.hero-bg-circle { position:absolute; border-radius:50%; border:1px solid var(--gray-200); }
.hero-bg-circle:nth-child(1) { width:600px; height:600px; top:-200px; right:-100px; }
.hero-bg-circle:nth-child(2) { width:400px; height:400px; bottom:-100px; left:-100px; }
.hero-bg-circle:nth-child(3) { width:200px; height:200px; top:30%; left:10%; border-color:var(--gold-ring); }
.hero-dot { position:absolute; width:6px; height:6px; background:var(--gold); border-radius:50%; }
.hero-dot:nth-child(4) { top:20%; right:20%; }
.hero-dot:nth-child(5) { bottom:30%; left:15%; }
.hero-dot:nth-child(6) { top:40%; right:35%; width:4px; height:4px; background:var(--gray-300); }
.hero-content { position:relative; z-index:2; max-width:700px; }
.hero-badge { display:inline-flex; align-items:center; gap:6px; background:var(--gold-subtle); color:var(--gray-700); padding:6px 16px; border-radius:20px; font-size:0.8125rem; font-weight:600; margin-bottom:24px; border:1px solid var(--gold-ring); }
.hero-badge-dot { width:6px; height:6px; background:var(--gold); border-radius:50%; }
.hero h1 { font-size:clamp(2.5rem,6vw,4.5rem); font-weight:800; color:var(--gray-900); line-height:1.1; letter-spacing:-2px; margin-bottom:20px; }
.hero h1 span { color:var(--gold-hover); }
.hero p { font-size:1.125rem; color:var(--gray-500); max-width:500px; margin:0 auto 36px; line-height:1.7; }
.hero-cta { display:inline-flex; align-items:center; gap:8px; padding:14px 32px; background:var(--gold); color:var(--gray-900); font-weight:700; font-size:0.9375rem; border-radius:var(--radius); transition:var(--transition); letter-spacing:0.5px; }
.hero-cta:hover { background:var(--gold-hover); transform:translateY(-2px); box-shadow:0 8px 24px var(--gold-ring); }
.hero-cta:active { transform:translateY(0) scale(0.98); }
.hero-cta svg { width:16px; height:16px; transition:var(--transition); }
.hero-cta:hover svg { transform:translateX(3px); }

/* -- Hero actions -- */
.hero-actions { display:flex; gap:16px; align-items:center; justify-content:center; flex-wrap:wrap; }
.hero-cta-secondary { font-size:0.875rem; font-weight:600; color:var(--gray-500); border-bottom:2px solid var(--gray-300); padding-bottom:2px; transition:var(--transition); }
.hero-cta-secondary:hover { color:var(--gray-900); border-color:var(--gold); }

/* -- Stats Bar -- */
.stats-bar { background:var(--gray-900); padding:48px 24px; }
.stats-grid { max-width:1280px; margin:0 auto; display:grid; grid-template-columns:repeat(4,1fr); gap:32px; text-align:center; }
.stat-number { font-size:clamp(1.75rem,3vw,2.5rem); font-weight:800; color:var(--gold); letter-spacing:-1px; margin-bottom:4px; }
.stat-label { font-size:0.8125rem; font-weight:500; color:var(--gray-400); }

/* -- Features -- */
.features-section { background:var(--bg); }
.features-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:20px; margin-top:48px; }
.feature-card { background:var(--white); border-radius:var(--radius-lg); padding:32px 24px; border:1px solid var(--gray-200); transition:var(--transition); }
.feature-card:hover { border-color:var(--gold); box-shadow:var(--shadow-md); transform:translateY(-3px); }
.feature-icon { width:48px; height:48px; background:var(--gold-subtle); border-radius:var(--radius); display:flex; align-items:center; justify-content:center; margin-bottom:16px; }
.feature-icon svg { width:22px; height:22px; color:var(--gold-hover); }
.feature-card h3 { font-size:1rem; font-weight:700; color:var(--gray-900); margin-bottom:8px; }
.feature-card p { font-size:0.8125rem; color:var(--gray-500); line-height:1.7; }

/* -- How it works -- */
.how-section { background:var(--white); text-align:center; }
.steps-grid { display:flex; align-items:flex-start; justify-content:center; gap:0; margin-top:48px; }
.step-card { flex:1; max-width:280px; padding:0 24px; }
.step-number { font-size:2.5rem; font-weight:800; color:var(--gold); margin-bottom:12px; }
.step-card h3 { font-size:1.125rem; font-weight:700; color:var(--gray-900); margin-bottom:8px; }
.step-card p { font-size:0.8125rem; color:var(--gray-500); line-height:1.7; }
.step-line { width:60px; height:2px; background:var(--gray-200); margin-top:32px; flex-shrink:0; }

/* -- Pricing -- */
.pricing-section { background:var(--bg); }
.pricing-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:24px; margin-top:48px; }
.pricing-card { background:var(--white); border-radius:var(--radius-lg); padding:36px 28px; border:1px solid var(--gray-200); transition:var(--transition); position:relative; text-align:center; }
.pricing-card:hover { border-color:var(--gold); box-shadow:var(--shadow-md); }
.pricing-card.popular { border:2px solid var(--gold); box-shadow:var(--shadow-md); }
.pricing-badge { position:absolute; top:-12px; left:50%; transform:translateX(-50%); background:var(--gold); color:var(--gray-900); font-size:0.6875rem; font-weight:700; padding:4px 16px; border-radius:20px; white-space:nowrap; }
.pricing-name { font-size:1.25rem; font-weight:700; color:var(--gray-900); margin-bottom:4px; }
.pricing-desc { font-size:0.8125rem; color:var(--gray-500); margin-bottom:20px; }
.pricing-price { font-size:2rem; font-weight:800; color:var(--gray-900); margin-bottom:24px; letter-spacing:-1px; }
.pricing-price span { font-size:0.875rem; font-weight:500; color:var(--gray-500); }
.pricing-features { list-style:none; text-align:left; margin-bottom:28px; }
.pricing-features li { padding:8px 0; font-size:0.8125rem; color:var(--gray-600); border-bottom:1px solid var(--gray-100); }
.pricing-features li::before { content:'✓'; color:var(--green); font-weight:700; margin-right:8px; }
.pricing-card .btn-gold { margin-top:0; }
.btn-gold-outline { width:100%; padding:12px; background:transparent; border:2px solid var(--gold); color:var(--gray-900); font-weight:700; font-size:0.875rem; border-radius:var(--radius); transition:var(--transition); }
.btn-gold-outline:hover { background:var(--gold-subtle); }

/* -- Testimonials -- */
.testimonial-section { background:var(--white); }
.testimonial-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:24px; margin-top:48px; }
.testimonial-card { background:var(--bg); border-radius:var(--radius-lg); padding:28px; border:1px solid var(--gray-200); }
.testimonial-text { font-size:0.875rem; color:var(--gray-600); line-height:1.8; margin-bottom:20px; font-style:italic; }
.testimonial-author { display:flex; align-items:center; gap:12px; }
.testimonial-avatar { width:40px; height:40px; border-radius:50%; background:var(--gold); display:flex; align-items:center; justify-content:center; font-weight:700; font-size:0.875rem; color:var(--gray-900); }
.testimonial-name { font-size:0.8125rem; font-weight:700; color:var(--gray-900); }
.testimonial-role { font-size:0.6875rem; color:var(--gray-500); }

/* -- CTA Section -- */
.cta-section { background:var(--bg); padding:40px 24px 80px; }
.cta-card { max-width:800px; margin:0 auto; background:var(--gray-900); border-radius:var(--radius-xl); padding:56px 48px; text-align:center; }
.cta-card h2 { font-size:clamp(1.5rem,3vw,2rem); font-weight:800; color:var(--white); margin-bottom:12px; letter-spacing:-0.5px; }
.cta-card p { font-size:0.9375rem; color:var(--gray-400); margin-bottom:28px; }
.btn-lg { padding:16px 40px; font-size:1rem; }

/* -- Footer license -- */
.footer-license { font-size:0.75rem; font-weight:600; margin-top:12px; opacity:0.7; }

/* -- Section shared -- */
.section { padding:80px 24px; }
.section-container { max-width:1280px; margin:0 auto; }
.section-eyebrow { font-size:0.75rem; font-weight:700; color:var(--gold-hover); letter-spacing:2px; text-transform:uppercase; margin-bottom:8px; }
.section-title { font-size:clamp(1.75rem,4vw,2.5rem); font-weight:800; color:var(--gray-900); letter-spacing:-1px; margin-bottom:12px; }
.section-desc { font-size:1rem; color:var(--gray-500); max-width:500px; line-height:1.7; }

/* -- Services -- */
.services { background:var(--bg); }
.services-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:24px; margin-top:48px; }
.service-card { background:var(--white); border-radius:var(--radius-lg); padding:36px 28px; border:1px solid var(--gray-200); transition:var(--transition); position:relative; overflow:hidden; }
.service-card:hover { border-color:var(--gold); box-shadow:var(--shadow-md); transform:translateY(-4px); }
.service-num { font-size:3rem; font-weight:800; color:var(--gray-100); line-height:1; margin-bottom:16px; }
.service-card:hover .service-num { color:var(--gold-subtle); }
.service-icon { width:48px; height:48px; background:var(--gold-subtle); border-radius:var(--radius); display:flex; align-items:center; justify-content:center; margin-bottom:20px; }
.service-icon svg { width:24px; height:24px; color:var(--gold-hover); }
.service-card h3 { font-size:1.125rem; font-weight:700; color:var(--gray-900); margin-bottom:8px; }
.service-card p { font-size:0.875rem; color:var(--gray-500); line-height:1.6; }

/* -- Mobile App -- */
.mobile-section { background:var(--white); text-align:center; }
.phone-wrapper { display:flex; justify-content:center; margin-top:48px; }
.phone-mockup { width:260px; height:520px; background:var(--gray-900); border-radius:36px; padding:12px; box-shadow:var(--shadow-lg); position:relative; }
.phone-screen { width:100%; height:100%; border-radius:28px; overflow:hidden; background:linear-gradient(135deg,#667eea,#764ba2); display:flex; flex-direction:column; align-items:center; justify-content:center; color:white; }
.phone-screen h4 { font-size:1rem; font-weight:700; margin-bottom:16px; }
.phone-screen-item { background:rgba(255,255,255,0.15); padding:12px 24px; border-radius:10px; margin-bottom:8px; font-size:0.8125rem; width:80%; text-align:center; }

/* -- Loan Check -- */
.loan-check { background:var(--bg); }
.loan-check-card { max-width:560px; margin:48px auto 0; background:var(--white); border-radius:var(--radius-lg); padding:32px; border:1px solid var(--gray-200); box-shadow:var(--shadow); }

/* -- Login Overlay -- */
.login-overlay { display:none; position:fixed; inset:0; z-index:200; background:rgba(0,0,0,0.4); backdrop-filter:blur(4px); align-items:center; justify-content:center; padding:24px; }
.login-overlay.show { display:flex; }
.login-select { background:var(--white); border-radius:var(--radius-xl); padding:36px; width:100%; max-width:600px; position:relative; box-shadow:0 20px 60px rgba(0,0,0,0.15); animation:slideUp 0.3s ease; }
.role-grid { display:grid; grid-template-columns:1fr 1fr; gap:20px; margin-top:8px; }
.role-card { background:var(--bg); border:2px solid var(--gray-200); border-radius:var(--radius-lg); padding:32px 24px; text-align:center; transition:var(--transition); cursor:default; }
.role-card:hover { border-color:var(--gold); box-shadow:var(--shadow-md); }
.role-icon { width:56px; height:56px; background:var(--gold-subtle); border-radius:50%; display:flex; align-items:center; justify-content:center; margin:0 auto 16px; }
.role-icon svg { width:28px; height:28px; color:var(--gold-hover); }
.role-icon-org { background:var(--gray-900); }
.role-icon-org svg { color:var(--gold); }
.role-name { font-size:1.125rem; font-weight:700; color:var(--gray-900); margin-bottom:6px; }
.role-desc { font-size:0.8125rem; color:var(--gray-500); line-height:1.6; margin-bottom:20px; min-height:40px; }
.btn-role { width:100%; margin-top:0; }
.login-back { display:flex; align-items:center; gap:6px; font-size:0.8125rem; font-weight:600; color:var(--gray-500); margin-bottom:20px; transition:var(--transition); }
.login-back:hover { color:var(--gray-900); }
.login-back svg { width:16px; height:16px; }
.login-card { background:var(--white); border-radius:var(--radius-xl); padding:36px; width:100%; max-width:420px; position:relative; box-shadow:0 20px 60px rgba(0,0,0,0.15); animation:slideUp 0.3s ease; }
@keyframes slideUp { from{opacity:0;transform:translateY(20px)} to{opacity:1;transform:translateY(0)} }
.login-close { position:absolute; top:16px; right:16px; width:32px; height:32px; border-radius:50%; background:var(--gray-100); display:flex; align-items:center; justify-content:center; transition:var(--transition); }
.login-close:hover { background:var(--gray-200); }
.login-close svg { width:16px; height:16px; color:var(--gray-500); }
.login-title { font-size:1.25rem; font-weight:700; color:var(--gray-900); margin-bottom:4px; }
.login-subtitle { font-size:0.8125rem; color:var(--gray-500); margin-bottom:24px; }
.input-row { display:flex; gap:8px; }
.input-row .form-input { flex:1; }
.btn-verify { padding:10px 16px; background:var(--gold); color:var(--gray-900); font-weight:700; font-size:0.75rem; border-radius:10px; transition:var(--transition); white-space:nowrap; }
.btn-verify:hover { background:var(--gold-hover); }
.verify-group { display:none; }
.register-link { text-align:center; margin-top:16px; font-size:0.8125rem; color:var(--gray-500); }
.register-link a { color:var(--gold-hover); font-weight:600; }
.btn-google { width:100%; padding:12px; background:var(--white); border:1px solid var(--gray-200); color:var(--gray-700); font-weight:600; font-size:0.875rem; border-radius:var(--radius); transition:var(--transition); display:flex; align-items:center; justify-content:center; gap:10px; }
.btn-google:hover { background:var(--gray-50); border-color:var(--gray-300); box-shadow:var(--shadow-sm); }
.google-login-block { text-align:center; padding:20px 0 8px; }
.google-login-icon { margin-bottom:16px; }
.google-login-desc { font-size:0.8125rem; color:var(--gray-500); line-height:1.7; margin-bottom:20px; }
.verify-hint { display:flex; align-items:center; gap:6px; font-size:0.75rem; color:var(--green); margin-top:6px; font-weight:500; }
.code-inputs { display:flex; gap:8px; justify-content:center; }
.code-input { width:44px; height:48px; text-align:center; font-size:1.25rem; font-weight:700; border:1px solid var(--gray-200); border-radius:10px; outline:none; transition:var(--transition); }
.code-input:focus { border-color:var(--gold); box-shadow:0 0 0 3px var(--gold-ring); }
.divider { display:flex; align-items:center; gap:12px; margin:16px 0; }
.divider::before,.divider::after { content:''; flex:1; height:1px; background:var(--gray-200); }
.divider span { font-size:0.75rem; color:var(--gray-400); }

/* -- Footer -- */
.l-footer { background:var(--gold); color:var(--gray-900); padding:60px 24px 32px; }
.footer-inner { max-width:1280px; margin:0 auto; display:flex; justify-content:space-between; align-items:flex-start; gap:48px; flex-wrap:wrap; }
.footer-brand { max-width:320px; }
.footer-brand-name { font-size:1.25rem; font-weight:800; margin-bottom:8px; }
.footer-brand p { font-size:0.875rem; opacity:0.8; line-height:1.6; }
.footer-col h4 { font-size:0.875rem; font-weight:700; margin-bottom:16px; text-transform:uppercase; letter-spacing:1px; }
.footer-col ul { list-style:none; }
.footer-col li { margin-bottom:8px; }
.footer-col a { font-size:0.875rem; opacity:0.7; transition:var(--transition); }
.footer-col a:hover { opacity:1; }
.footer-social { display:flex; gap:10px; margin-top:12px; }
.footer-social a { width:36px; height:36px; background:var(--gray-900); border-radius:50%; display:flex; align-items:center; justify-content:center; transition:var(--transition); }
.footer-social a:hover { transform:translateY(-2px); box-shadow:0 4px 12px rgba(0,0,0,0.2); }
.footer-social svg { width:16px; height:16px; fill:white; }
.footer-bottom { max-width:1280px; margin:40px auto 0; padding-top:20px; border-top:1px solid rgba(0,0,0,0.1); text-align:center; font-size:0.8125rem; opacity:0.6; }

/* -- Landing Responsive -- */
@media(max-width:1024px) {
    .services-grid,.features-grid,.pricing-grid,.testimonial-grid { grid-template-columns:1fr; }
    .stats-grid { grid-template-columns:repeat(2,1fr); }
    .steps-grid { flex-direction:column; align-items:center; gap:24px; }
    .step-line { width:2px; height:40px; }
    .footer-inner { flex-direction:column; }
}
@media(max-width:768px) {
    .l-nav { display:none; position:absolute; top:100%; left:0; right:0; background:var(--white); flex-direction:column; padding:16px 24px; border-bottom:1px solid var(--gray-200); box-shadow:var(--shadow-md); }
    .l-nav.show { display:flex; }
    .mobile-toggle { display:flex; }
    .hero h1 { letter-spacing:-1px; }
    .stats-grid { grid-template-columns:1fr 1fr; gap:20px; }
    .cta-card { padding:40px 24px; }
    .role-grid { grid-template-columns:1fr; }
    .login-select { max-width:420px; }
}
