/* ============================================
   etudiant.fr — Stylesheet principal
   Palette : Bleu #2563EB, Orange #F97316, Fond #F8FAFC
   Typo : Inter (Google Fonts)
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --blue: #2563EB;
  --blue-dark: #1D4ED8;
  --blue-light: #DBEAFE;
  --orange: #F97316;
  --orange-dark: #EA580C;
  --bg: #F8FAFC;
  --white: #FFFFFF;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-500: #6B7280;
  --gray-600: #4B5563;
  --gray-700: #374151;
  --gray-800: #1F2937;
  --gray-900: #111827;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,.07), 0 2px 4px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 15px rgba(0,0,0,.1), 0 4px 6px rgba(0,0,0,.05);
  --max-w: 1140px;
  --transition: .2s ease;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--gray-800);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--blue-dark); }

img { max-width: 100%; height: auto; display: block; }

.container { width: 100%; max-width: var(--max-w); margin: 0 auto; padding: 0 1.25rem; }

/* --- Header --- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  box-shadow: var(--shadow);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.logo { font-size: 1.35rem; font-weight: 800; color: var(--gray-900); display: flex; align-items: center; gap: .5rem; }
.logo span { color: var(--blue); }
.logo .dot { color: var(--orange); }

.nav-links { display: flex; gap: 1.75rem; list-style: none; align-items: center; }
.nav-links a {
  font-size: .9rem; font-weight: 500; color: var(--gray-600);
  padding: .25rem 0; position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; left: 0; bottom: -2px;
  width: 0; height: 2px; background: var(--blue);
  transition: width var(--transition);
}
.nav-links a:hover { color: var(--blue); }
.nav-links a:hover::after { width: 100%; }

.menu-toggle {
  display: none; background: none; border: none; cursor: pointer;
  width: 28px; height: 28px; position: relative;
}
.menu-toggle span {
  display: block; width: 100%; height: 2px; background: var(--gray-700);
  position: absolute; left: 0; transition: var(--transition);
}
.menu-toggle span:nth-child(1) { top: 6px; }
.menu-toggle span:nth-child(2) { top: 13px; }
.menu-toggle span:nth-child(3) { top: 20px; }

/* --- Hero --- */
.hero {
  background: linear-gradient(135deg, var(--blue) 0%, #3B82F6 50%, #60A5FA 100%);
  color: var(--white);
  padding: 5rem 0 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; top: -50%; right: -20%;
  width: 600px; height: 600px;
  background: rgba(255,255,255,.06);
  border-radius: 50%;
}
.hero h1 { font-size: 2.75rem; font-weight: 800; line-height: 1.15; margin-bottom: 1.25rem; }
.hero p { font-size: 1.2rem; opacity: .92; max-width: 620px; margin: 0 auto 2rem; line-height: 1.6; }
.hero .btn { font-size: 1.05rem; padding: .9rem 2.2rem; }

/* --- Buttons --- */
.btn {
  display: inline-block;
  font-family: inherit; font-weight: 600; font-size: .95rem;
  border: none; border-radius: 8px; cursor: pointer;
  padding: .7rem 1.6rem;
  transition: all var(--transition);
  text-align: center;
}
.btn-primary { background: var(--orange); color: var(--white); }
.btn-primary:hover { background: var(--orange-dark); color: var(--white); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-secondary { background: var(--white); color: var(--blue); }
.btn-secondary:hover { background: var(--gray-100); color: var(--blue-dark); }
.btn-outline {
  background: transparent; color: var(--blue); border: 2px solid var(--blue);
}
.btn-outline:hover { background: var(--blue); color: var(--white); }
.btn-sm { font-size: .85rem; padding: .5rem 1.1rem; }

/* --- Sections --- */
.section { padding: 4rem 0; }
.section-title {
  font-size: 2rem; font-weight: 800; color: var(--gray-900);
  text-align: center; margin-bottom: .75rem;
}
.section-subtitle {
  text-align: center; color: var(--gray-500); font-size: 1.05rem;
  max-width: 600px; margin: 0 auto 2.5rem;
}

/* --- Cards Grid --- */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-img {
  height: 180px; background: var(--blue-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
}
.card-body { padding: 1.5rem; }
.card-body h3 { font-size: 1.15rem; font-weight: 700; color: var(--gray-900); margin-bottom: .5rem; }
.card-body p { color: var(--gray-600); font-size: .92rem; margin-bottom: 1rem; }
.card-tag {
  display: inline-block; font-size: .75rem; font-weight: 600; text-transform: uppercase;
  background: var(--blue-light); color: var(--blue); padding: .2rem .6rem;
  border-radius: 4px; margin-bottom: .75rem;
}

/* --- Comparison Table --- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 2rem 0; }
.compare-table {
  width: 100%; border-collapse: collapse; min-width: 700px;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
}
.compare-table thead { background: var(--blue); color: var(--white); }
.compare-table th {
  padding: .9rem 1rem; font-size: .85rem; font-weight: 700;
  text-align: left; text-transform: uppercase; letter-spacing: .03em;
}
.compare-table td {
  padding: .85rem 1rem; font-size: .9rem; border-bottom: 1px solid var(--gray-100);
  vertical-align: middle;
}
.compare-table tbody tr:hover { background: var(--gray-50); }
.compare-table .bank-name { font-weight: 700; color: var(--gray-900); white-space: nowrap; }
.compare-table .badge {
  display: inline-block; padding: .15rem .55rem; border-radius: 4px;
  font-size: .78rem; font-weight: 600;
}
.badge-green { background: #DCFCE7; color: #166534; }
.badge-orange { background: #FEF3C7; color: #92400E; }
.badge-red { background: #FEE2E2; color: #991B1B; }
.badge-blue { background: var(--blue-light); color: var(--blue); }

.note-stars { color: var(--orange); font-weight: 700; letter-spacing: 1px; }

.cta-cell .btn { white-space: nowrap; }

/* --- Article / Guide --- */
.article-content {
  max-width: 780px; margin: 0 auto;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 2.5rem 2rem;
}
.article-content h2 { font-size: 1.5rem; color: var(--gray-900); margin: 2rem 0 .75rem; }
.article-content h3 { font-size: 1.2rem; color: var(--gray-800); margin: 1.5rem 0 .5rem; }
.article-content p { margin-bottom: 1rem; color: var(--gray-700); }
.article-content ul, .article-content ol {
  margin: .75rem 0 1.25rem 1.5rem; color: var(--gray-700);
}
.article-content li { margin-bottom: .4rem; }
.article-content blockquote {
  border-left: 4px solid var(--blue);
  padding: 1rem 1.25rem; margin: 1.5rem 0;
  background: var(--blue-light); border-radius: 0 8px 8px 0;
  color: var(--gray-700); font-style: italic;
}
.article-meta {
  display: flex; gap: 1.5rem; align-items: center;
  font-size: .85rem; color: var(--gray-500); margin-bottom: 2rem;
  padding-bottom: 1.5rem; border-bottom: 1px solid var(--gray-200);
}

/* --- Bons Plans List --- */
.deal-card {
  display: flex; gap: 1.25rem; align-items: flex-start;
  background: var(--white); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 1.5rem; margin-bottom: 1rem;
  transition: transform var(--transition), box-shadow var(--transition);
}
.deal-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.deal-icon {
  flex-shrink: 0; width: 56px; height: 56px;
  background: var(--blue-light); border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
}
.deal-content h3 { font-size: 1.05rem; font-weight: 700; color: var(--gray-900); margin-bottom: .3rem; }
.deal-content p { font-size: .9rem; color: var(--gray-600); margin-bottom: .5rem; }

/* --- Page Header (inner pages) --- */
.page-header {
  background: linear-gradient(135deg, var(--blue) 0%, #3B82F6 100%);
  color: var(--white); padding: 3rem 0 2.5rem; text-align: center;
}
.page-header h1 { font-size: 2.2rem; font-weight: 800; margin-bottom: .5rem; }
.page-header p { opacity: .9; font-size: 1.05rem; max-width: 550px; margin: 0 auto; }

/* --- Footer --- */
.site-footer {
  background: var(--gray-900); color: var(--gray-300);
  padding: 3.5rem 0 1.5rem; margin-top: 4rem;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem; margin-bottom: 2.5rem;
}
.footer-brand p { font-size: .88rem; margin-top: .75rem; line-height: 1.6; color: var(--gray-500); }
.site-footer h4 {
  font-size: .85rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .05em; color: var(--gray-100); margin-bottom: .75rem;
}
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: .4rem; }
.site-footer li a { color: var(--gray-400); font-size: .88rem; }
.site-footer li a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid var(--gray-700); padding-top: 1.25rem;
  display: flex; justify-content: space-between; align-items: center;
  font-size: .82rem; color: var(--gray-500);
}

/* --- Cookie Banner --- */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  background: var(--gray-900); color: var(--gray-100);
  padding: 1rem 1.5rem;
  display: flex; align-items: center; justify-content: center; gap: 1.5rem;
  font-size: .88rem;
  transform: translateY(100%);
  transition: transform .4s ease;
}
.cookie-banner.visible { transform: translateY(0); }
.cookie-banner p { max-width: 650px; }
.cookie-banner .btn { flex-shrink: 0; }

/* --- Breadcrumb --- */
.breadcrumb {
  font-size: .85rem; color: var(--gray-500); padding: 1rem 0;
}
.breadcrumb a { color: var(--gray-500); }
.breadcrumb a:hover { color: var(--blue); }
.breadcrumb span { margin: 0 .4rem; }

/* --- Responsive --- */
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .nav-links {
    display: none; flex-direction: column; gap: 0;
    position: absolute; top: 64px; left: 0; right: 0;
    background: var(--white); border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-md);
  }
  .nav-links.open { display: flex; }
  .nav-links li { border-bottom: 1px solid var(--gray-100); }
  .nav-links a { display: block; padding: .85rem 1.25rem; font-size: .95rem; }
  .nav-links a::after { display: none; }

  .hero { padding: 3rem 0 2.5rem; }
  .hero h1 { font-size: 1.9rem; }
  .hero p { font-size: 1rem; }

  .section { padding: 2.5rem 0; }
  .section-title { font-size: 1.6rem; }

  .cards-grid { grid-template-columns: 1fr; }

  .article-content { padding: 1.5rem 1.25rem; }

  .deal-card { flex-direction: column; gap: .75rem; }

  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: .5rem; text-align: center; }
}
@media (max-width: 480px) {
  .hero h1 { font-size: 1.55rem; }
  .page-header h1 { font-size: 1.6rem; }
  .compare-table th, .compare-table td { padding: .6rem .7rem; font-size: .82rem; }
}

/* ============================================================
   UPGRADE CSS — etudiant.fr
   Ameliorations CTA orange, tables comparaison, cartes
   Date: 2026-04-29
   ============================================================ */

/* --- Transitions globales --- */
.btn-primary,
.btn-secondary,
.btn-outline,
.btn-sm,
.cards-grid > *,
table tr {
  transition: all 0.25s ease;
}

/* --- Bouton principal orange : glow chaud + scale --- */
.btn-primary:hover {
  box-shadow: 0 4px 20px rgba(249, 115, 22, 0.4), 0 2px 8px rgba(249, 115, 22, 0.2);
  transform: translateY(-2px) scale(1.02);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
}

/* --- Tables de comparaison : highlight bleu clair au hover --- */
table tbody tr:hover {
  background-color: rgba(37, 99, 235, 0.04);
  box-shadow: inset 3px 0 0 #2563EB;
}

table tbody tr {
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

/* --- Boutons CTA dans les tables : plus prominents --- */
.cta-cell .btn-primary,
.cta-cell .btn-sm,
td .btn-primary,
td .btn-sm {
  padding: 10px 24px;
  font-weight: 600;
}

.cta-cell .btn-primary:hover,
td .btn-primary:hover {
  box-shadow: 0 4px 18px rgba(249, 115, 22, 0.45);
  transform: translateY(-2px) scale(1.03);
}

/* --- Cartes : lift + ombre amelioree au hover --- */
.cards-grid > *:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.10), 0 4px 10px rgba(0, 0, 0, 0.06);
}

/* --- Bouton outline : effet remplissage --- */
.btn-outline:hover {
  background-color: #2563EB;
  color: #fff;
  border-color: #2563EB;
  box-shadow: 0 3px 12px rgba(37, 99, 235, 0.25);
}

/* --- Bouton secondaire --- */
.btn-secondary:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}
