/* ═══════════════════════════════════════════════════════════
   TARA Institut — Hero premium
   ═══════════════════════════════════════════════════════════ */

.hero {
  position: relative;
  overflow: hidden;
  background: var(--bg-base);
  padding-top: clamp(1.5rem, 3vw, 2.75rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}

/* ── Fond : dégradés + grille de points ── */
.hero__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.hero__bg::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 60%;
  height: 80%;
  background: radial-gradient(circle, rgba(26, 37, 121, 0.10) 0%, transparent 65%);
}

.hero__bg::after {
  content: '';
  position: absolute;
  bottom: -25%;
  left: -12%;
  width: 55%;
  height: 75%;
  background: radial-gradient(circle, rgba(212, 35, 35, 0.08) 0%, transparent 65%);
}

[data-theme="dark"] .hero__bg::before { background: radial-gradient(circle, rgba(35, 51, 160, 0.30) 0%, transparent 65%); }
[data-theme="dark"] .hero__bg::after  { background: radial-gradient(circle, rgba(212, 35, 35, 0.14) 0%, transparent 65%); }

.hero__grid-pattern {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, var(--border-mid) 1px, transparent 1px);
  background-size: 38px 38px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 35%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 35%, #000 0%, transparent 75%);
  opacity: 0.5;
}

/* Aurora animée — souffle de couleur subtil */
.hero__aurora {
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 80%;
  background:
    radial-gradient(ellipse 38% 60% at 25% 40%, rgba(212,35,35,0.14), transparent 70%),
    radial-gradient(ellipse 42% 65% at 75% 35%, rgba(35,51,160,0.20), transparent 72%);
  filter: blur(20px);
  animation: hero-aurora 14s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes hero-aurora {
  0%   { transform: translate3d(0, 0, 0) scale(1); opacity: 0.9; }
  50%  { transform: translate3d(3%, 2%, 0) scale(1.08); opacity: 1; }
  100% { transform: translate3d(-3%, -1%, 0) scale(1.03); opacity: 0.85; }
}

/* ── Layout ── */
.hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  max-width: var(--container-wide);
  margin-inline: auto;
  padding-inline: var(--container-padding);
}

/* ─────────────────────────────────────────────
   COLONNE GAUCHE — contenu
───────────────────────────────────────────── */
.hero__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-6);
  min-width: 0;
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 7px 8px 7px 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  box-shadow: var(--shadow-sm);
}

.hero__badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  background: var(--color-red);
  color: #fff;
  border-radius: var(--radius-full);
  font-size: 0.68rem;
  font-weight: var(--weight-bold);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero__badge-tag svg { width: 12px; height: 12px; }

.hero__badge-text { padding-right: var(--space-2); }

/* ── Titre ── */
.hero__title {
  font-family: var(--font-heading);
  font-size: clamp(2.6rem, 5.6vw, 4.6rem);
  font-weight: var(--weight-black);
  line-height: 1.05;
  letter-spacing: -0.035em;
  color: var(--text-primary);
}

.hero__title-line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
}

.hero__title-text {
  display: inline-block;
}

.hero__title-text--accent {
  position: relative;
  color: var(--color-red);
  background: linear-gradient(100deg, var(--color-red-dark) 0%, var(--color-red) 38%, #FF7A7A 62%, var(--color-red) 100%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: hero-accent-shine 7s ease-in-out infinite;
}

@keyframes hero-accent-shine {
  0%, 100% { background-position: 0% center; }
  50%       { background-position: 100% center; }
}

/* Trait décoratif sous le mot accent */
.hero__title-text--accent::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0.04em;
  width: 100%;
  height: 0.10em;
  background: var(--color-red);
  opacity: 0.22;
  border-radius: var(--radius-full);
}

[data-theme="dark"] .hero__title-text--accent { color: #F06464; }

.hero__subtitle {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 46ch;
}

/* ── CTAs ── */
.hero__ctas {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.hero__ctas .btn { height: 54px; padding-inline: 28px; font-size: 0.95rem; }

/* ── Trust strip ── */
.hero__trust {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  padding-top: var(--space-5);
  margin-top: var(--space-1);
  border-top: 1px solid var(--border-light);
  width: 100%;
  flex-wrap: wrap;
}

.hero__trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.hero__trust-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hero__trust-icon--red  { background: var(--color-red-pale);  color: var(--color-red); }
.hero__trust-icon--navy { background: var(--color-navy-pale); color: var(--color-navy); }

[data-theme="dark"] .hero__trust-icon--navy { color: #6B84E8; }

.hero__trust-icon svg { width: 20px; height: 20px; }

.hero__trust-text { display: flex; flex-direction: column; line-height: 1.2; }

.hero__trust-value {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.hero__trust-label {
  font-size: 0.76rem;
  color: var(--text-muted);
}

/* ─────────────────────────────────────────────
   COLONNE DROITE — showcase visuel
───────────────────────────────────────────── */
.hero__visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

/* Panneau principal */
.hero__showcase {
  position: relative;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 1 / 1.08;
  border-radius: var(--radius-2xl);
  background: linear-gradient(155deg, #243089 0%, var(--color-navy) 45%, var(--color-navy-dark) 100%);
  box-shadow: 0 30px 70px rgba(17, 26, 94, 0.4),
              inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  text-align: center;
}

.hero__showcase--photo {
  padding: 0;
  justify-content: flex-end;
  align-items: stretch;
  text-align: left;
  background: var(--color-navy-dark);
}

.hero__showcase--photo::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(7, 12, 37, 0.10) 0%, rgba(7, 12, 37, 0.30) 32%, rgba(9, 13, 40, 0.78) 62%, rgba(7, 11, 30, 0.97) 100%),
    linear-gradient(90deg, rgba(212, 35, 35, 0.22), transparent 55%);
  pointer-events: none;
  z-index: 0;
}

.hero__showcase-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04) contrast(1.02);
}

/* Orbes décoratifs dans le panneau */
.hero__showcase-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero__showcase-orb--1 {
  width: 220px; height: 220px;
  top: -90px; right: -70px;
  background: radial-gradient(circle, rgba(212, 35, 35, 0.45) 0%, transparent 70%);
}

.hero__showcase-orb--2 {
  width: 260px; height: 260px;
  bottom: -110px; left: -90px;
  background: radial-gradient(circle, rgba(91, 110, 232, 0.4) 0%, transparent 70%);
}

.hero__showcase-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(circle at 50% 45%, #000 0%, transparent 75%);
  mask-image: radial-gradient(circle at 50% 45%, #000 0%, transparent 75%);
}

.hero__showcase-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-4);
}

.hero__showcase-content--overlay {
  align-items: flex-start;
  justify-content: flex-end;
  min-height: 100%;
  padding: clamp(1.5rem, 4vw, 2.4rem);
  gap: var(--space-3);
}

.hero__showcase-content--overlay .hero__showcase-title,
.hero__showcase-content--overlay .hero__showcase-sub {
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.6);
}

/* Bandeau accent au-dessus du texte overlay */
.hero__showcase-content--overlay::before {
  content: '';
  display: block;
  width: 44px;
  height: 4px;
  border-radius: var(--radius-full);
  background: var(--color-red);
  margin-bottom: 2px;
}

.hero__showcase-logo {
  width: clamp(104px, 23vw, 138px);
  height: auto;
  padding: 16px;
  background: #fff;
  border-radius: var(--radius-xl);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.34);
}

.hero__showcase-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: var(--weight-semibold);
  color: #fff;
  backdrop-filter: blur(8px);
}

.hero__showcase-pill svg { width: 13px; height: 13px; color: var(--color-red-light); }

.hero__showcase-title {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 3.4vw, 1.95rem);
  font-weight: var(--weight-extrabold);
  color: #fff;
  line-height: 1.2;
}

.hero__showcase-title b { color: var(--color-red-light); }

.hero__showcase-sub {
  font-size: 0.88rem;
  color: rgba(241, 245, 249, 0.86);
  max-width: 34ch;
  line-height: 1.55;
}

.hero__showcase-content { position: relative; z-index: 1; }

.hero__showcase-langs {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-1);
}

.hero__showcase-lang {
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  font-weight: var(--weight-medium);
  color: rgba(241, 245, 249, 0.85);
}

/* ── Cartes flottantes (contenues, pas de débordement viewport) ── */
.hero__float {
  position: absolute;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 13px 18px;
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.hero__float--top {
  top: 6%;
  left: -4%;
  animation: float-hero 5s ease-in-out infinite;
}

.hero__float--bottom {
  bottom: 8%;
  right: -3%;
  animation: float-hero 5s ease-in-out infinite;
  animation-delay: -2.5s;
}

.hero__float-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #fff;
}

.hero__float--top    .hero__float-icon { background: var(--color-red); }
.hero__float--bottom .hero__float-icon { background: var(--color-navy); }

.hero__float-icon svg { width: 18px; height: 18px; }

.hero__float-text { display: flex; flex-direction: column; line-height: 1.25; }

.hero__float-value {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: var(--weight-extrabold);
  color: var(--text-primary);
}

.hero__float-label {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ── Carte note / crédibilité flottante ── */
.hero__rating {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: -26px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 12px 18px;
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  animation: float-hero 6s ease-in-out infinite;
  animation-delay: -1.2s;
}

.hero__rating-stars {
  display: flex;
  gap: 2px;
  color: #F5A623;
}

.hero__rating-stars svg { width: 13px; height: 13px; fill: currentColor; }

.hero__rating-text {
  display: flex;
  align-items: baseline;
  gap: 6px;
  white-space: nowrap;
}

.hero__rating-text strong {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: var(--weight-extrabold);
  color: var(--color-red);
}

.hero__rating-text span {
  font-size: 0.76rem;
  color: var(--text-secondary);
}

/* ─────────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────────── */
@media (max-width: 980px) {
  .hero__inner {
    grid-template-columns: 1fr;
    gap: clamp(2.5rem, 6vw, 4rem);
  }
  .hero__content { align-items: center; text-align: center; }
  .hero__subtitle { max-width: 52ch; }
  .hero__trust { justify-content: center; }
  .hero__visual { order: -1; margin-bottom: var(--space-5); }
  .hero__showcase { max-width: 400px; }
}

@media (max-width: 540px) {
  .hero__ctas { width: 100%; }
  .hero__ctas .btn { flex: 1; justify-content: center; min-width: 0; }
  .hero__trust { gap: var(--space-4); }
  .hero__float { padding: 10px 14px; }
  .hero__float-icon { width: 32px; height: 32px; }
  .hero__float--top { left: 2%; }
  .hero__float--bottom { right: 2%; }
  .hero__badge { flex-wrap: wrap; }
}

@media (max-width: 540px) {
  .hero__rating-text span { display: none; }
}

@media (max-width: 380px) {
  .hero__float { display: none; }
}

/* ═══════════════════════════════════════════════════════════
   HERO — Améliorations visuelles supplémentaires
   ═══════════════════════════════════════════════════════════ */

/* Animation d'entrée du showcase */
@keyframes showcase-glow {
  0%, 100% { box-shadow: 0 30px 70px rgba(17,26,94,0.4), inset 0 1px 0 rgba(255,255,255,0.08); }
  50%       { box-shadow: 0 40px 90px rgba(17,26,94,0.55), 0 0 60px rgba(212,35,35,0.14), inset 0 1px 0 rgba(255,255,255,0.08); }
}

.hero__showcase {
  animation: showcase-glow 5s ease-in-out infinite;
}

/* Anneau décoratif autour du showcase */
.hero__visual::before {
  content: '';
  position: absolute;
  inset: -24px;
  border-radius: calc(var(--radius-2xl) + 24px);
  border: 1px solid rgba(255,255,255,0.04);
  pointer-events: none;
}

.hero__visual::after {
  content: '';
  position: absolute;
  inset: -48px;
  border-radius: calc(var(--radius-2xl) + 48px);
  border: 1px solid rgba(255,255,255,0.025);
  pointer-events: none;
}

/* Badge certifié — animation pulse renforcée */
.hero__badge {
  animation: badge-pulse 3s ease-in-out infinite;
}

@keyframes badge-pulse {
  0%, 100% { box-shadow: var(--shadow-sm); }
  50%       { box-shadow: 0 4px 20px rgba(212,35,35,0.18); }
}

/* Trust items : appear plus premium */
.hero__trust-icon {
  position: relative;
}

.hero__trust-icon::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: calc(var(--radius-md) + 2px);
  border: 1px solid transparent;
  transition: border-color var(--duration-base);
}

.hero__trust-item:hover .hero__trust-icon--red::after  { border-color: rgba(212,35,35,0.3); }
.hero__trust-item:hover .hero__trust-icon--navy::after { border-color: rgba(26,37,121,0.3); }

/* Final design pass: hero plus premium et plus vivant */
.hero {
  padding-top: clamp(2rem, 4vw, 3.25rem);
  padding-bottom: clamp(3.75rem, 7vw, 6.25rem);
  background:
    radial-gradient(ellipse 56% 64% at 88% 10%, rgba(35, 51, 160, 0.18), transparent 64%),
    radial-gradient(ellipse 46% 54% at 7% 84%, rgba(212, 35, 35, 0.12), transparent 66%),
    linear-gradient(125deg, #fff 0%, #f8fafc 48%, #eef3ff 100%);
}

.hero__inner {
  min-height: min(760px, calc(100vh - 90px));
}

.hero__title {
  max-width: 760px;
  letter-spacing: -0.045em;
}

.hero__title-text--accent::after {
  display: none;
}

.hero__subtitle {
  max-width: 52ch;
}

.hero .hero__title,
.hero .hero__trust-value,
.hero .hero__float-value {
  color: #0F172A;
}

.hero .hero__subtitle,
.hero .hero__trust-label,
.hero .hero__badge,
.hero .hero__badge-text,
.hero .hero__float-label {
  color: #475569;
}

.hero .btn--outline {
  background: rgba(255,255,255,0.76);
  border-color: rgba(26,37,121,0.16);
  color: var(--color-navy);
  box-shadow: 0 12px 34px rgba(17, 26, 94, 0.08);
}

.hero .btn--outline:hover {
  background: var(--color-navy);
  color: #fff;
  border-color: var(--color-navy);
}

.hero__badge {
  background: rgba(255,255,255,0.82);
  border-color: rgba(26,37,121,0.10);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.hero__showcase--photo {
  isolation: isolate;
  transform-style: preserve-3d;
}

.hero__showcase--photo::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 18% 25%, rgba(255,255,255,0.16), transparent 26%),
    radial-gradient(circle at 84% 8%, rgba(212,35,35,0.34), transparent 24%),
    linear-gradient(145deg, rgba(255,255,255,0.06), transparent 48%);
  mix-blend-mode: screen;
  pointer-events: none;
}

.hero__showcase-photo {
  filter: saturate(1.14) contrast(1.08) brightness(0.9);
  transform: scale(1.02);
}

.hero__visual-spark {
  position: absolute;
  z-index: 4;
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: rgba(255,255,255,0.78);
  color: var(--color-navy);
  border: 1px solid rgba(255,255,255,0.72);
  box-shadow: 0 16px 38px rgba(17, 26, 94, 0.16);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: hero-spark-float 5.2s ease-in-out infinite;
}

.hero__visual-spark--languages {
  top: 18%;
  right: 7%;
  color: var(--color-red);
}

.hero__visual-spark--graduate {
  left: 4%;
  bottom: 18%;
  animation-delay: -1.7s;
}

.hero__visual-spark--route {
  right: 2%;
  bottom: 34%;
  color: var(--color-red);
  animation-delay: -3.1s;
}

.hero__trust {
  padding: var(--space-4);
  border: 1px solid rgba(26, 37, 121, 0.08);
  border-radius: var(--radius-xl);
  background: rgba(255,255,255,0.58);
  box-shadow: 0 14px 38px rgba(17, 26, 94, 0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@keyframes hero-spark-float {
  0%, 100% { transform: translate3d(0, 0, 0) rotate(0deg); }
  50%      { transform: translate3d(0, -12px, 0) rotate(-5deg); }
}

@media (max-width: 980px) {
  .hero__inner {
    min-height: 0;
  }
}

@media (max-width: 540px) {
  .hero__visual-spark {
    width: 38px;
    height: 38px;
    border-radius: 14px;
  }

  .hero__visual-spark--route {
    display: none;
  }
}

/* ═══════════════════════════════════════════════════════════
   HERO — Mode sombre
   Le "Final design pass" ci-dessus fige des valeurs claires
   (#fff, #0F172A...) qui ignoraient le theme sombre. On les
   reprend ici pour que la 1re section suive le mode sombre.
   ═══════════════════════════════════════════════════════════ */
[data-theme="dark"] .hero {
  background:
    radial-gradient(ellipse 56% 64% at 88% 10%, rgba(35, 51, 160, 0.30), transparent 64%),
    radial-gradient(ellipse 46% 54% at 7% 84%, rgba(212, 35, 35, 0.16), transparent 66%),
    linear-gradient(125deg, #0A1124 0%, #080E1E 48%, #0C1538 100%);
}

[data-theme="dark"] .hero .hero__title,
[data-theme="dark"] .hero .hero__trust-value,
[data-theme="dark"] .hero .hero__float-value {
  color: var(--text-primary);
}

[data-theme="dark"] .hero .hero__subtitle,
[data-theme="dark"] .hero .hero__trust-label,
[data-theme="dark"] .hero .hero__badge,
[data-theme="dark"] .hero .hero__badge-text,
[data-theme="dark"] .hero .hero__float-label {
  color: var(--text-secondary);
}

[data-theme="dark"] .hero__badge {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.10);
}

[data-theme="dark"] .hero__trust {
  background: rgba(255, 255, 255, 0.035);
  border-color: rgba(255, 255, 255, 0.07);
}

[data-theme="dark"] .hero .btn--outline {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.14);
  color: #C7D2E8;
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] .hero .btn--outline:hover {
  background: var(--color-red);
  border-color: var(--color-red);
  color: #fff;
}

[data-theme="dark"] .hero__grid-pattern { opacity: 0.35; }
