/* ═══════════════════════════════════════════════════════
   CalculCPE.ca — Design System
   Thème : Turquoise chaleureux & Jaune soleil (Enfance, Joie, Famille)
   ═══════════════════════════════════════════════════════ */

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

:root {
  --accent:      #0891b2; /* Cyan-600 */
  --accent-2:    #0e7490; /* Cyan-700 */
  --accent-glow: #cffafe; /* Cyan-100 */
  --accent-mid:  #a5f3fc; /* Cyan-200 */

  --sun:         #eab308; /* Yellow-500 */
  --sun-glow:    #fef9c3; /* Yellow-100 */
  --sun-mid:     #fde047; /* Yellow-300 */

  --pink:        #ec4899;
  --green:       #16a34a;
  --danger:      #ef4444;

  --bg:      #f0fdff; /* Cyan-50 */
  --surface: #ffffff;
  --surface2:#f0fdff;
  --border:  #a5f3fc; /* Cyan-200 */
  --text:    #164e63; /* Cyan-900 */
  --text-2:  #0891b2; /* Cyan-600 */
  --muted:   #64748b; /* Slate-500 */

  --radius:    20px;
  --radius-sm: 12px;
  --shadow:    0 4px 15px rgba(8, 145, 178, 0.08);
  --shadow-lg: 0 12px 40px rgba(8, 145, 178, 0.14);
}

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

/* ── Header ─────────────────────────────────────────── */
.site-header { position: fixed; top: 0; left: 0; right: 0; z-index: 800; background: rgba(255,255,255,0.95); backdrop-filter: blur(12px); border-bottom: 3px solid var(--accent-mid); box-shadow: var(--shadow); }
.header-inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; height: 68px; display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.4rem; color: var(--accent); text-decoration: none; }
.logo-icon { width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--sun)); display: flex; align-items: center; justify-content: center; font-size: 1.4rem; box-shadow: 0 4px 14px rgba(8,145,178,0.3); }
.logo-text span { color: var(--sun); }
.nav-links { list-style: none; display: flex; gap: 8px; }
.nav-links a { padding: 8px 18px; border-radius: 50px; font-size: 0.95rem; font-weight: 700; color: var(--muted); transition: all 0.2s; }
.nav-links a:hover { background: var(--accent-glow); color: var(--accent); }
.nav-links a.active { background: var(--accent); color: #fff; }

/* ── Hero ───────────────────────────────────────────── */
.hero { padding: 130px 24px 70px; text-align: center; background: linear-gradient(170deg, #f0fdff 0%, #cffafe 50%, #fef9c3 100%); border-bottom: 1px solid var(--border); position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; top: -50px; right: -80px; width: 300px; height: 300px; background: radial-gradient(circle, rgba(234,179,8,0.15), transparent 70%); border-radius: 50%; }
.hero::after  { content: ''; position: absolute; bottom: -60px; left: -60px; width: 250px; height: 250px; background: radial-gradient(circle, rgba(8,145,178,0.1), transparent 70%); border-radius: 50%; }
.hero > * { position: relative; z-index: 1; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 2px solid var(--accent-mid); color: var(--accent); font-size: 0.82rem; font-weight: 800; padding: 6px 18px; border-radius: 30px; margin-bottom: 24px; box-shadow: var(--shadow); text-transform: uppercase; letter-spacing: 0.08em; }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 900; color: var(--text); line-height: 1.15; margin-bottom: 20px; letter-spacing: -0.02em; }
.hero h1 span { color: var(--sun); }
.hero p { color: var(--muted); font-size: 1.15rem; font-weight: 600; max-width: 640px; margin: 0 auto 36px; }
.hero-tabs { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-tab { padding: 13px 26px; border-radius: 50px; font-size: 0.95rem; font-weight: 800; cursor: pointer; border: 2px solid var(--border); background: #fff; color: var(--accent); transition: all 0.2s; text-decoration: none; box-shadow: var(--shadow); }
.hero-tab:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.hero-tab.active { background: var(--accent); color: #fff; border-color: var(--accent); box-shadow: 0 8px 24px rgba(8,145,178,0.35); }

/* ── Layout ─────────────────────────────────────────── */
.main-layout { max-width: 1100px; margin: 0 auto; padding: 50px 24px 80px; display: grid; grid-template-columns: 1fr 340px; gap: 32px; }
@media (max-width: 900px) { .main-layout { grid-template-columns: 1fr; } }

/* ── Cards ───────────────────────────────────────────── */
.card { background: var(--surface); border-radius: var(--radius); border: 2px solid var(--border); box-shadow: var(--shadow-lg); padding: 32px; margin-bottom: 28px; }
.card-title { font-size: 1.4rem; font-weight: 900; color: var(--accent); margin-bottom: 24px; display: flex; align-items: center; gap: 12px; padding-bottom: 16px; border-bottom: 2px dashed var(--accent-mid); }
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 0.9rem; font-weight: 800; color: var(--text-2); margin-bottom: 8px; }
.input-wrap { display: flex; }
.input-prefix { background: var(--surface2); border: 2px solid var(--border); border-right: none; border-radius: var(--radius-sm) 0 0 var(--radius-sm); padding: 0 14px; display: flex; align-items: center; color: var(--sun); font-weight: 900; font-size: 1.1rem; }
.input-suffix { background: var(--surface2); border: 2px solid var(--border); border-left: none; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 0 12px; display: flex; align-items: center; color: var(--accent); font-weight: 700; }
.form-input { flex: 1; padding: 13px 16px; border: 2px solid var(--border); font-size: 1.05rem; font-weight: 700; color: var(--text); background: var(--surface); outline: none; transition: all 0.2s; font-family: 'Nunito', sans-serif; width: 100%; }
.form-input.no-prefix { border-radius: var(--radius-sm); }
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(8,145,178,0.15); }
select.form-input, select.form-input.no-prefix { cursor: pointer; }
.btn-calc { width: 100%; padding: 16px; background: linear-gradient(135deg, var(--sun), #d97706); color: #fff; font-size: 1.1rem; font-weight: 900; border: none; border-radius: var(--radius-sm); cursor: pointer; transition: all 0.2s; margin-top: 8px; font-family: 'Nunito', sans-serif; box-shadow: 0 4px 15px rgba(234,179,8,0.35); }
.btn-calc:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(234,179,8,0.4); }

/* ── Résultats ──────────────────────────────────────── */
.results-panel { display: none; border-radius: var(--radius); overflow: hidden; border: 2px solid var(--border); box-shadow: var(--shadow-lg); margin-top: 24px; animation: popIn 0.35s cubic-bezier(0.16,1,0.3,1); }
@keyframes popIn { from { opacity:0; transform:scale(0.97) translateY(8px); } to { opacity:1; transform:scale(1) translateY(0); } }

.comparison-grid { display: grid; grid-template-columns: 1fr 1fr; }
.col-cpe  { background: linear-gradient(160deg, var(--accent), var(--accent-2)); color: #fff; padding: 24px; }
.col-prive { background: linear-gradient(160deg, #f8fafc, #fff); color: var(--text); padding: 24px; }
.col-label { font-size: 0.8rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 4px; opacity: 0.8; }
.col-value { font-size: 1.9rem; font-weight: 900; letter-spacing: -0.02em; }
.col-sub   { font-size: 0.85rem; margin-top: 12px; opacity: 0.85; }
.col-sub div { display: flex; justify-content: space-between; padding: 4px 0; border-bottom: 1px solid rgba(255,255,255,0.15); }

.savings-bar { background: var(--sun-glow); border-top: 2px solid var(--sun-mid); padding: 20px 24px; text-align: center; }
.savings-label { font-size: 0.85rem; font-weight: 800; color: var(--sun); text-transform: uppercase; letter-spacing: 0.08em; }
.savings-value { font-size: 2.5rem; font-weight: 900; color: var(--text); }
.savings-sub   { font-size: 0.95rem; color: var(--muted); font-weight: 600; }

/* ── Sidebar ────────────────────────────────────────── */
.sidebar { display: flex; flex-direction: column; gap: 24px; }
.sidebar-card { background: var(--surface); border: 2px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.sidebar-card h3 { font-size: 0.95rem; font-weight: 900; color: var(--accent); margin-bottom: 16px; text-transform: uppercase; letter-spacing: 0.08em; }
.sidebar-tool { display: flex; align-items: center; gap: 12px; padding: 13px 14px; background: var(--bg); border: 2px solid var(--border); border-radius: var(--radius-sm); color: var(--text); font-size: 0.95rem; font-weight: 700; margin-bottom: 10px; transition: all 0.2s; }
.sidebar-tool:hover { background: var(--accent-glow); border-color: var(--accent); color: var(--accent); transform: translateX(4px); }
.sicon { font-size: 1.3rem; }

/* ── Callouts ───────────────────────────────────────── */
.callout { padding: 16px 20px; border-radius: var(--radius-sm); margin: 20px 0; font-size: 0.95rem; line-height: 1.6; font-weight: 600; }
.callout-info { background: var(--accent-glow); border-left: 4px solid var(--accent); color: var(--text); }
.callout-sun  { background: var(--sun-glow); border-left: 4px solid var(--sun); color: #78350f; }

/* ── SEO ─────────────────────────────────────────────── */
.seo-section { max-width: 1100px; margin: 0 auto; padding: 60px 24px; }
.seo-section h2 { font-size: 1.9rem; font-weight: 900; color: var(--accent); margin-bottom: 20px; }
.seo-section p { color: var(--muted); line-height: 1.9; margin-bottom: 18px; font-size: 1.05rem; }

/* ── Footer ─────────────────────────────────────────── */
.site-footer { background: var(--accent); color: var(--accent-glow); text-align: center; padding: 40px 24px; font-size: 0.9rem; font-weight: 700; border-top: 4px solid var(--sun); }
.site-footer a { color: var(--sun-mid); font-weight: 900; }

@media (max-width: 640px) {
  .comparison-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 2rem; }
}
