/* ═══════════════════════════════════════════════════════
   CalculHypotheque.ca — Design System
   Thème : Deep Navy (Confiance, Banque) & Gold (Immobilier)
   ═══════════════════════════════════════════════════════ */

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

:root {
  --accent:      #1e3a8a; /* Blue-900 */
  --accent-2:    #1e40af; /* Blue-800 */
  --accent-glow: #dbeafe; /* Blue-100 */
  
  --gold:        #d97706; /* Amber-600 */
  --gold-glow:   #fef3c7; /* Amber-100 */

  --success:     #10b981;
  --danger:      #ef4444;

  --bg:      #f4f4f5; /* Zinc-100 */
  --surface: #ffffff;
  --surface2:#f8fafc; /* Slate-50 */
  --border:  #e2e8f0; /* Slate-200 */
  --text:    #0f172a; /* Slate-900 */
  --text-2:  #475569; /* Slate-600 */
  --muted:   #94a3b8; /* Slate-400 */
  
  --radius:  12px;
  --radius-sm: 8px;
  --shadow:  0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Plus Jakarta Sans', sans-serif; background: var(--bg); color: var(--text); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; font-weight: 600; }
a:hover { text-decoration: underline; color: var(--gold); }

/* ── Header ─────────────────────────────────────────── */
.site-header { position: fixed; top: 0; left: 0; right: 0; z-index: 800; background: var(--surface); border-bottom: 2px solid var(--accent); box-shadow: var(--shadow); }
.header-inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; height: 70px; display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 1.4rem; color: var(--accent); text-decoration: none; letter-spacing: -0.01em; }
.logo-icon { width: 40px; height: 40px; border-radius: 8px; background: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 1.3rem; box-shadow: 0 4px 10px rgba(30, 58, 138, 0.3); }
.logo-text span { color: var(--gold); }
.nav-links { list-style: none; display: flex; gap: 16px; align-items: center; }
.nav-links a { padding: 8px 16px; border-radius: 6px; font-size: 0.95rem; font-weight: 600; color: var(--text-2); text-decoration: none; transition: all 0.2s; }
.nav-links a:hover { background: var(--surface2); color: var(--accent); }
.nav-links a.active { background: var(--accent); color: #fff; }

/* ── Hero ───────────────────────────────────────────── */
.hero { background: var(--accent); background-image: radial-gradient(circle at 100% 100%, #1e40af 0%, #172554 100%); padding: 140px 24px 70px; text-align: center; color: #fff; position: relative; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2); color: var(--gold-glow); font-size: 0.85rem; font-weight: 700; padding: 6px 16px; border-radius: 30px; margin-bottom: 24px; letter-spacing: 0.05em; text-transform: uppercase; }
.hero h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 800; line-height: 1.15; margin-bottom: 20px; letter-spacing: -0.02em; }
.hero h1 span { color: var(--gold); }
.hero p { font-size: 1.2rem; color: rgba(255,255,255,0.8); font-weight: 500; max-width: 650px; margin: 0 auto 40px; }

.hero-tabs { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-tab { padding: 14px 28px; border-radius: 8px; font-size: 1rem; font-weight: 700; cursor: pointer; border: none; background: rgba(255,255,255,0.1); color: #fff; transition: all 0.2s; text-decoration: none; }
.hero-tab:hover { background: rgba(255,255,255,0.2); }
.hero-tab.active { background: var(--gold); color: #fff; box-shadow: 0 4px 15px rgba(217, 119, 6, 0.4); }

/* ── Layout ─────────────────────────────────────────── */
.main-layout { max-width: 1100px; margin: -40px auto 0; position: relative; z-index: 10; padding: 0 24px 60px; display: grid; grid-template-columns: 1fr 340px; gap: 32px; align-items: start; }
@media (max-width: 900px) { .main-layout { grid-template-columns: 1fr; margin-top: 20px; } }

/* ── Card & Forms ───────────────────────────────────── */
.card { background: var(--surface); border-radius: var(--radius); border: 1px solid var(--border); box-shadow: var(--shadow-lg); padding: 32px; margin-bottom: 24px; }
.card-title { font-size: 1.4rem; font-weight: 800; color: var(--accent); margin-bottom: 24px; display: flex; align-items: center; gap: 10px; letter-spacing: -0.01em; border-bottom: 2px solid var(--accent-glow); padding-bottom: 12px; }

.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 0.95rem; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.input-wrap { position: relative; display: flex; box-shadow: 0 1px 2px rgba(0,0,0,0.05); }
.input-prefix { background: var(--surface2); border: 1px solid var(--border); border-right: none; border-radius: var(--radius-sm) 0 0 var(--radius-sm); padding: 0 16px; display: flex; align-items: center; color: var(--text-2); font-weight: 700; font-size: 1.1rem; }
.input-suffix { background: var(--surface2); border: 1px solid var(--border); border-left: none; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 0 16px; display: flex; align-items: center; color: var(--text-2); font-weight: 700; font-size: 1.1rem; }
.form-input { flex: 1; padding: 14px 16px; border: 1px solid var(--border); font-size: 1.1rem; font-weight: 600; color: var(--text); background: var(--surface); outline: none; transition: all 0.2s; font-family: inherit; width: 100%; }
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); z-index: 2; }
.form-input.no-prefix { border-radius: var(--radius-sm); }
.form-input.mid-input { border-radius: 0; }

.btn-calc { width: 100%; padding: 18px; background: var(--gold); color: #fff; font-size: 1.1rem; font-weight: 800; border: none; border-radius: var(--radius-sm); cursor: pointer; transition: transform 0.2s, box-shadow 0.2s, background 0.2s; margin-top: 20px; font-family: inherit; letter-spacing: 0.02em; }
.btn-calc:hover { background: #b45309; box-shadow: 0 8px 25px rgba(217, 119, 6, 0.35); transform: translateY(-2px); }

/* ── Résultats ──────────────────────────────────────── */
.results-panel { display: none; background: var(--surface2); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; margin-top: 24px; animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes slideUp { from { opacity:0; transform:translateY(15px); } to { opacity:1; transform:translateY(0); } }

.result-highlight { text-align: center; padding: 32px 24px; background: var(--accent); color: #fff; border-radius: var(--radius-sm); margin-bottom: 24px; box-shadow: inset 0 2px 10px rgba(0,0,0,0.2); }
.result-highlight-label { font-size: 0.9rem; font-weight: 700; color: var(--accent-glow); text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 8px; }
.result-highlight-value { font-size: 3.2rem; font-weight: 800; letter-spacing: -0.03em; color: var(--gold); }

.detail-row { display: flex; justify-content: space-between; padding: 16px 0; border-bottom: 1px dashed var(--border); font-size: 1.05rem; }
.detail-row:last-child { border-bottom: none; }
.detail-label { color: var(--text-2); font-weight: 500; }
.detail-value { font-weight: 800; color: var(--text); }

/* ── Sidebar ────────────────────────────────────────── */
.sidebar { display: flex; flex-direction: column; gap: 24px; }
.sidebar-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.sidebar-card h3 { font-size: 1rem; font-weight: 800; color: var(--accent); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 16px; border-bottom: 2px solid var(--gold); padding-bottom: 8px; display: inline-block; }
.sidebar-tool { display: flex; align-items: center; gap: 12px; padding: 14px; background: var(--surface2); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.95rem; font-weight: 600; margin-bottom: 12px; transition: all 0.2s; }
.sidebar-tool:hover { background: #fff; border-color: var(--gold); color: var(--accent); transform: translateX(4px); box-shadow: var(--shadow); }
.sicon { font-size: 1.4rem; }

/* ── Callouts & SEO ─────────────────────────────────── */
.callout { padding: 16px 20px; border-radius: var(--radius-sm); margin: 24px 0; font-size: 0.95rem; line-height: 1.6; font-weight: 500; }
.callout-info { background: var(--accent-glow); border-left: 4px solid var(--accent); color: var(--accent); }
.callout-warn { background: var(--gold-glow); border-left: 4px solid var(--gold); color: #92400e; }

.seo-section { max-width: 1100px; margin: 0 auto; padding: 60px 24px; }
.seo-section h2 { font-size: 2rem; font-weight: 800; color: var(--accent); margin-bottom: 24px; letter-spacing: -0.02em; }
.seo-section p { color: var(--text-2); margin-bottom: 20px; line-height: 1.8; font-size: 1.1rem; }

/* ── Footer ─────────────────────────────────────────── */
.site-footer { background: var(--accent); color: var(--accent-glow); text-align: center; padding: 40px 24px; font-size: 0.95rem; font-weight: 500; border-top: 4px solid var(--gold); }
.site-footer a { color: #fff; font-weight: 600; }
.site-footer a:hover { color: var(--gold); }

@media (max-width: 640px) {
  .hero { padding: 110px 16px 50px; }
  .hero h1 { font-size: 2.2rem; }
  .card { padding: 24px 16px; }
  .result-highlight-value { font-size: 2.6rem; }
  .nav-links { display: none; } /* Mobile menu needed */
}
