/* ------------------------------------------------------------------
   SHEMS — page Tarifs (#tarifs)
   Utilise uniquement les variables de theme.css : clair et sombre suivent.
   ------------------------------------------------------------------ */
.tf-hero { background: radial-gradient(ellipse at 15% 0%, #8A2D48 0%, var(--band) 45%, #3E1120 100%); color: var(--on-ink); }
.tf-hero .wrap { padding-top: clamp(40px, 6vw, 72px); padding-bottom: clamp(48px, 7vw, 80px); }
.tf-hero .eyebrow { color: rgba(255, 255, 255, .76); }
.tf-hero h1 { font-family: var(--f-display); font-stretch: 125%; font-weight: 800; text-transform: uppercase; line-height: .92; letter-spacing: -.01em; font-size: clamp(3rem, 11vw, 7rem); margin-top: 18px; }
.tf-hero .tf-tag { font-family: var(--f-display); font-weight: 600; font-size: clamp(1.2rem, 2.6vw, 1.6rem); margin-top: 14px; }
.tf-launch { margin-top: 36px; display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; padding: 26px 28px; border: 1px solid rgba(255, 255, 255, .26); border-radius: 20px; background: rgba(255, 255, 255, .08); max-width: 860px; }
.tf-launch > div { min-width: 0; }
.tf-big { font-family: var(--f-display); font-stretch: 125%; font-weight: 900; font-size: clamp(3rem, 9vw, 5rem); line-height: .85; font-variant-numeric: tabular-nums; }
.tf-big small { display: block; font-family: var(--f-mono); font-weight: 500; font-stretch: normal; font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .76); margin-top: 10px; }
.tf-launch h2 { font-family: var(--f-display); font-weight: 700; font-size: clamp(1.25rem, 2.6vw, 1.6rem); line-height: 1.15; }
.tf-launch p { margin-top: 6px; color: rgba(255, 255, 255, .76); }

.tf-body { display: grid; gap: clamp(56px, 8vw, 88px); padding-top: clamp(48px, 7vw, 80px); padding-bottom: clamp(56px, 8vw, 96px); }
.tf-head { display: grid; gap: 10px; margin-bottom: 28px; }
.tf-head .lede { max-width: 60ch; }

.tf-offers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.tf-offer { border: 1px solid var(--line); border-radius: 16px; padding: 28px 24px; display: flex; flex-direction: column; gap: 18px; background: var(--paper); min-width: 0; transition: transform .25s var(--ease), border-color .25s; position: relative; }
.tf-offer:hover { transform: translateY(-3px); border-color: var(--brass); }
.tf-offer.best { border: 2px solid var(--brass); background: var(--brass-soft); }
.tf-badge { position: absolute; top: -13px; left: 22px; background: var(--accent); color: var(--accent-ink); font-family: var(--f-mono); font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; padding: 5px 12px; border-radius: 999px; }
.tf-offer h3 { font-family: var(--f-display); font-stretch: 105%; font-weight: 700; font-size: 1.35rem; }
.tf-for { color: var(--ink-2); font-size: .95rem; margin-top: 4px; }
.tf-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.tf-price b { font-family: var(--f-display); font-stretch: 112%; font-weight: 800; font-size: 3rem; line-height: 1; color: var(--brass); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.tf-price span { color: var(--ink-2); font-size: .95rem; }
.tf-price .then { flex-basis: 100%; font-family: var(--f-mono); font-size: .8rem; }
.tf-incl { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: .95rem; }
.tf-incl li { display: grid; grid-template-columns: 18px 1fr; gap: 10px; color: var(--ink-2); }
.tf-incl li::before { content: ""; width: 8px; height: 8px; margin: 7px 0 0 3px; border-radius: 2px; background: var(--brass); }
.tf-save { margin-top: auto; font-family: var(--f-mono); font-size: .78rem; color: var(--brass); }
.tf-legal { margin-top: 16px; font-size: .85rem; color: var(--mineral); }

.tf-sim { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.tf-sim-in { padding: 28px; display: grid; gap: 22px; align-content: start; min-width: 0; }
.tf-sim-out { padding: 28px; background: var(--surface); display: grid; gap: 8px; align-content: start; border-left: 1px solid var(--line); min-width: 0; }
.tf-field { display: grid; gap: 8px; }
.tf-field > span { font-weight: 600; font-size: .95rem; display: flex; justify-content: space-between; gap: 10px; }
.tf-field output { font-family: var(--f-mono); color: var(--brass); }
.tf-seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; background: var(--surface); padding: 5px; border-radius: 12px; border: 1px solid var(--line); }
.tf-seg input { position: absolute; opacity: 0; pointer-events: none; }
.tf-seg label { text-align: center; padding: 10px 6px; border-radius: 8px; cursor: pointer; font-size: .9rem; font-weight: 600; color: var(--ink-2); }
.tf-seg input:checked + label { background: var(--accent); color: var(--accent-ink); }
.tf-seg input:focus-visible + label { outline: 2px solid var(--brass); outline-offset: 2px; }
.tf-sim input[type=range] { width: 100%; accent-color: var(--accent); }
.tf-chk { display: flex; gap: 10px; align-items: center; font-size: .95rem; cursor: pointer; }
.tf-chk input { width: 18px; height: 18px; accent-color: var(--accent); }
.tf-total { font-family: var(--f-display); font-stretch: 112%; font-weight: 800; font-size: 3.2rem; line-height: 1; color: var(--brass); font-variant-numeric: tabular-nums; }
.tf-lines { list-style: none; padding: 0; margin: 12px 0 0; }
.tf-lines li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
.tf-lines li span:last-child { font-family: var(--f-mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.tf-lines li.free span:last-child { color: var(--brass); }

.tf-cta { background: radial-gradient(ellipse at 85% 100%, #8A2D48 0%, var(--band) 45%, #3E1120 100%); color: var(--on-ink); border-radius: 24px; padding: clamp(28px, 5vw, 56px); display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; }
.tf-cta h2 { font-family: var(--f-display); font-stretch: 125%; font-weight: 800; text-transform: uppercase; font-size: clamp(2rem, 6vw, 3.6rem); line-height: .95; }
.tf-cta p { color: rgba(255, 255, 255, .76); margin-top: 12px; }
.tf-cta .btn { --b-bg: var(--on-ink); --b-fg: var(--band); border-color: var(--on-ink); }
.tf-cta .btn:hover { filter: brightness(.94); }

@media (max-width: 860px) {
  .tf-offers { grid-template-columns: 1fr; gap: 24px; }
  .tf-sim { grid-template-columns: 1fr; }
  .tf-sim-out { border-left: 0; border-top: 1px solid var(--line); }
}
@media (max-width: 480px) { .tf-launch { grid-template-columns: 1fr; gap: 14px; } }
@media (prefers-reduced-motion: reduce) { .tf-offer { transition: none; } .tf-offer:hover { transform: none; } }

/* ------------------------------------------------------------------
   Animations et interactions (rejouées à chaque ouverture de la page)
   ------------------------------------------------------------------ */
/* Bandeau : halo qui dérive lentement */
.tf-hero { position: relative; overflow: hidden; isolation: isolate; }
.tf-hero::before, .tf-hero::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; filter: blur(10px); }
.tf-hero::before { width: 520px; height: 520px; right: -120px; top: -160px; background: radial-gradient(circle, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0) 65%); animation: tf-drift 14s ease-in-out infinite alternate; }
.tf-hero::after { width: 380px; height: 380px; left: 30%; bottom: -220px; background: radial-gradient(circle, rgba(204, 142, 160, .35), rgba(204, 142, 160, 0) 65%); animation: tf-drift 18s ease-in-out -6s infinite alternate-reverse; }
@keyframes tf-drift { from { transform: translate3d(0, 0, 0) scale(1); } to { transform: translate3d(-60px, 40px, 0) scale(1.15); } }

/* Titre : lettres qui montent une à une */
.tf-hero h1 > span { display: inline-flex; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
.tf-hero h1 .ch { display: inline-block; }
.tf-play .tf-hero h1 .ch { animation: tf-rise .9s var(--ease) backwards; animation-delay: calc(var(--i) * 55ms + 80ms); }
@keyframes tf-rise { from { transform: translateY(105%) rotate(8deg); } to { transform: none; } }
.tf-play .tf-hero .eyebrow { animation: tf-up .7s var(--ease) backwards; }
.tf-play .tf-tag { animation: tf-up .8s var(--ease) .38s backwards; }
.tf-play .tf-launch { animation: tf-up .9s var(--ease) .52s backwards; }
@keyframes tf-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* Offre de lancement : reflet qui balaie la carte */
.tf-launch { position: relative; overflow: hidden; }
.tf-launch::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .16) 50%, transparent 65%); transform: translateX(-120%); animation: tf-sheen 5.5s var(--ease) 1.4s infinite; }
@keyframes tf-sheen { 0% { transform: translateX(-120%); } 30%, 100% { transform: translateX(120%); } }

/* Cartes d'offre : entrée en cascade, relief qui suit la souris, halo lumineux */
.tf-offer { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--lift, 0px)); transition: transform .6s var(--ease), border-color .25s, box-shadow .5s var(--ease); will-change: transform; }
.tf-offer:hover { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--lift, 0px)); --lift: -6px; border-color: var(--brass); box-shadow: 0 30px 60px -34px rgba(101, 29, 50, .45); }
.tf-offer.tf-move { transition: transform .12s linear, border-color .25s, box-shadow .5s var(--ease); }
.tf-offer::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s; background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 30%), color-mix(in srgb, var(--brass) 16%, transparent), transparent 70%); }
.tf-offer:hover::before { opacity: 1; }
.tf-offer > *:not(.tf-badge) { position: relative; }
.tf-play .tf-offer { animation: tf-card .9s var(--ease) backwards; animation-delay: calc(var(--i) * 120ms + 250ms); }
@keyframes tf-card { from { opacity: 0; transform: perspective(900px) translateY(40px) rotateX(12deg); } to { opacity: 1; transform: perspective(900px); } }
.tf-badge { animation: tf-bob 3.2s ease-in-out infinite; }
@keyframes tf-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
.tf-price b { display: inline-block; transition: transform .4s var(--ease); }
.tf-offer:hover .tf-price b { transform: scale(1.06); transform-origin: left bottom; }
.tf-incl li { transition: transform .3s var(--ease); }
.tf-offer:hover .tf-incl li { transform: translateX(3px); }
.tf-offer:hover .tf-incl li:nth-child(2) { transition-delay: .04s; }
.tf-offer:hover .tf-incl li:nth-child(3) { transition-delay: .08s; }

/* Simulateur : curseur glissant, total qui rebondit, lignes qui arrivent */
.tf-seg { position: relative; }
.tf-thumb { position: absolute; top: 5px; bottom: 5px; left: 5px; width: calc((100% - 22px) / 3); border-radius: 8px; background: var(--accent); box-shadow: 0 8px 18px -10px rgba(101, 29, 50, .7); transform: translateX(calc(var(--k, 0) * (100% + 6px))); transition: transform .45s var(--ease); }
.tf-seg label { position: relative; z-index: 1; transition: color .3s; }
.tf-seg input:checked + label { background: transparent; color: var(--accent-ink); }
.tf-total { display: inline-block; transform-origin: left center; }
.tf-total.tf-pop { animation: tf-pop .45s var(--ease); }
@keyframes tf-pop { 0% { transform: scale(1); } 40% { transform: scale(1.08); } 100% { transform: scale(1); } }
.tf-lines li { animation: tf-line .45s var(--ease) backwards; animation-delay: calc(var(--i, 0) * 60ms); }
@keyframes tf-line { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: none; } }
.tf-field output { display: inline-block; transition: transform .25s var(--ease); }
.tf-field output.tf-tick { transform: scale(1.18); }

/* Appel à l'action : fond qui respire, flèche qui avance */
.tf-cta { background-size: 160% 160%; animation: tf-breathe 10s ease-in-out infinite alternate; }
@keyframes tf-breathe { from { background-position: 0% 0%; } to { background-position: 100% 100%; } }
.tf-cta .btn:hover .arr { transform: translateX(5px); }
.tf-play .tf-cta { animation: tf-up .9s var(--ease) .6s backwards, tf-breathe 10s ease-in-out infinite alternate; }

@media (prefers-reduced-motion: reduce) {
  .tf-hero::before, .tf-hero::after, .tf-launch::after, .tf-badge, .tf-cta { animation: none !important; }
  .tf-play .tf-hero h1 .ch, .tf-play .tf-hero .eyebrow, .tf-play .tf-tag, .tf-play .tf-launch, .tf-play .tf-offer, .tf-play .tf-cta, .tf-lines li, .tf-total.tf-pop { animation: none !important; }
  .tf-offer, .tf-offer:hover { transform: none; transition: border-color .25s; }
  .tf-thumb { transition: none; }
}
