/* Premium day / night system */
:root {
  --paper: #f7f6f2;
  --paper-strong: #ffffff;
  --paper-soft: #eeece7;
  --text: #111111;
  --text-soft: #66635f;
  --hairline: rgba(17, 17, 17, .16);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0c0c0c;
  --paper-strong: #121212;
  --paper-soft: #191919;
  --text: #f5f3ee;
  --text-soft: #aaa7a2;
  --hairline: rgba(255, 255, 255, .15);
}

html[data-theme="light"] { color-scheme: light; }
.header-actions,
.spotlight__utilities,
.mobile-brand__actions { display: flex; align-items: center; gap: 8px; }
.theme-toggle { display: grid; width: 36px; height: 36px; flex: 0 0 auto; place-items: center; border: 1px solid currentColor; border-radius: 50%; background: transparent; color: inherit; cursor: pointer; }
.theme-toggle i { font-size: 17px; }

html[data-theme="light"] body { background: #eae7e1; color: #111; }
html[data-theme="light"] .rail {
  border-color: rgba(0, 0, 0, .12);
  background: rgba(249, 248, 245, .98);
  color: #111;
  box-shadow: 0 22px 50px rgba(0, 0, 0, .22);
}
html[data-theme="light"] .brand-lockup .brand-wordmark,
html[data-theme="light"] .mobile-brand img,
html[data-theme="light"] .rail-launcher img { filter: none; }
html[data-theme="light"] .brand-lockup .brand-emblem { filter: none; }
html[data-theme="light"] .brand-lockup span,
html[data-theme="light"] .panel-heading p:not(.eyebrow),
html[data-theme="light"] .catalog-intro > span { color: #6e6b66; }
html[data-theme="light"] .icon-button { border-color: rgba(0,0,0,.17); background: transparent; color: #111; }
html[data-theme="light"] .tabs { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .tab { color: #5e5b57; }
html[data-theme="light"] .tab:hover,
html[data-theme="light"] .tab.is-active,
html[data-theme="light"] .panel-heading h1,
html[data-theme="light"] .catalog-intro h2,
html[data-theme="light"] .section-title h2 { color: #111; }
html[data-theme="light"] .catalog-sticky { background: rgba(249,248,245,.97); }
html[data-theme="light"] .catalog-tabs,
html[data-theme="light"] .mobile-catalog-tabs { border-color: rgba(0,0,0,.14); background: #fff; }
html[data-theme="light"] .catalog-tabs button,
html[data-theme="light"] .mobile-catalog-tabs button { border-color: rgba(0,0,0,.1); color: #5f5c58; }
html[data-theme="light"] .catalog-tabs button.is-active,
html[data-theme="light"] .mobile-catalog-tabs button.is-active { background: var(--red); color: #fff; }
html[data-theme="light"] .catalog-search,
html[data-theme="light"] .filter-toggle { border-color: rgba(0,0,0,.14); background: #fff; color: #625f5a; }
html[data-theme="light"] .catalog-search input { color: #111; }
html[data-theme="light"] .filter-drawer label { color: #67645f; }
html[data-theme="light"] .filter-drawer select { border-color: rgba(0,0,0,.14); background: #fff; color: #111; }
html[data-theme="light"] .empty-state { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .empty-state button { color: #111; }
html[data-theme="light"] .editorial-card,
html[data-theme="light"] .configurator,
html[data-theme="light"] .era-feature,
html[data-theme="light"] .legend-strip button,
html[data-theme="light"] .intent-grid button,
html[data-theme="light"] .concierge-card,
html[data-theme="light"] .contact-details > *,
html[data-theme="light"] .craft-list button,
html[data-theme="light"] .era-rail button,
html[data-theme="light"] .mobile-config,
html[data-theme="light"] .mobile-era,
html[data-theme="light"] .mobile-era-list button,
html[data-theme="light"] .mobile-intents button {
  border-color: rgba(0,0,0,.13);
  background: #fff;
  color: #111;
}
html[data-theme="light"] .editorial-card p,
html[data-theme="light"] .era-feature p,
html[data-theme="light"] .intent-grid span,
html[data-theme="light"] .contact-details > *,
html[data-theme="light"] .mobile-config p,
html[data-theme="light"] .mobile-era p { color: #6b6863; }
html[data-theme="light"] .config-steps { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .config-steps button { border-color: rgba(0,0,0,.1); color: #686560; }
html[data-theme="light"] .config-steps button.is-active { color: #111; }
html[data-theme="light"] .config-options > p { color: #5f5c58; }
html[data-theme="light"] .choice-grid button { border-color: rgba(0,0,0,.12); background: #f8f7f3; color: #55524e; }
html[data-theme="light"] .choice-grid button.is-selected { color: #111; }
html[data-theme="light"] .config-summary { border-color: rgba(0,0,0,.12); background: rgba(0,0,0,.08); }
html[data-theme="light"] .config-summary div { background: #f8f7f3; color: #111; }
html[data-theme="light"] .era-rail button.is-active,
html[data-theme="light"] .intent-grid button.is-selected { color: #111; }
html[data-theme="light"] .milestone-chips i { background: #eceae5; color: #55524e; }
html[data-theme="light"] .heritage-numbers { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .heritage-numbers div { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .concierge-card input,
html[data-theme="light"] .concierge-card select,
html[data-theme="light"] .concierge-card textarea { border-color: rgba(0,0,0,.14); background: #f8f7f3; color: #111; }
html[data-theme="light"] .contact-context { border-color: rgba(0,0,0,.1); }
html[data-theme="light"] .contact-details strong { color: #111; }
html[data-theme="light"] .rail__footer { border-color: rgba(0,0,0,.12); background: #f1efea; }
html[data-theme="light"] .rail__footer button { color: #55524e; }
html[data-theme="light"] .rail-launcher,
html[data-theme="light"] .tour-dock,
html[data-theme="light"] .drive-controls,
html[data-theme="light"] .config-cta { border-color: rgba(0,0,0,.15); background: rgba(255,255,255,.93); color: #111; }
html[data-theme="light"] .tour-dock button,
html[data-theme="light"] .drive-controls button { color: #222; }
html[data-theme="light"] .dock-separator,
html[data-theme="light"] .drive-controls button { border-color: rgba(0,0,0,.1); }
html[data-theme="light"] .mobile-sheet {
  border-color: rgba(0,0,0,.15);
  background: rgba(249,248,245,.98);
  color: #111;
  box-shadow: 0 -16px 45px rgba(0,0,0,.2);
}
html[data-theme="light"] .mobile-tabs { border-color: rgba(0,0,0,.12); }
html[data-theme="light"] .mobile-tabs button { border-color: rgba(0,0,0,.12); background: #fff; color: #55524e; }
html[data-theme="light"] .mobile-tabs button.is-active { color: #111; }
html[data-theme="light"] .mobile-brand__actions > .theme-toggle { background: transparent; color: #111; font-size: 12px; }
html[data-theme="light"] .booking__shell,
html[data-theme="light"] .story-shell { border-color: rgba(0,0,0,.14); background: #fff; color: #111; }
html[data-theme="light"] .booking .dialog-close,
html[data-theme="light"] .story-dialog .dialog-close { border-color: rgba(0,0,0,.2); background: #fff; color: #111; }
html[data-theme="light"] .booking-intro,
html[data-theme="light"] .story-copy #story-body p { color: #686560; }
html[data-theme="light"] .booking input,
html[data-theme="light"] .booking select { border-color: rgba(0,0,0,.14); background: #f5f3ee; color: #111; }
html[data-theme="light"] .story-lead { border-color: rgba(0,0,0,.12); color: #111; }
html[data-theme="light"] .story-milestones span { border-color: rgba(0,0,0,.14); color: #55524e; }
html[data-theme="light"] .toast { border-color: rgba(0,0,0,.14); background: rgba(255,255,255,.94); color: #111; }

/* Full-screen vehicle presentation */
.spotlight {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  overflow: hidden;
  background: var(--paper);
  color: var(--text);
}
.spotlight::backdrop { background: rgba(0,0,0,.76); backdrop-filter: blur(10px); }
.spotlight__grab { display: none; }
.spotlight__shell { display: block; width: 100%; height: 100%; min-height: 0; overflow: hidden; border: 0; border-radius: 0; background: var(--paper); color: var(--text); box-shadow: none; }
.spotlight__header {
  position: relative;
  z-index: 5;
  display: grid;
  height: 112px;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 36px;
  padding: 18px 46px;
  border-bottom: 2px solid var(--red);
  background: var(--paper-strong);
}
.spotlight__header > img { width: 46px; height: 64px; object-fit: contain; }
.spotlight__section-label { display: flex; align-items: center; gap: 21px; min-width: 0; border-left: 1px solid var(--hairline); padding-left: 35px; text-transform: uppercase; }
.spotlight__section-label span { color: var(--red); font-size: 17px; font-weight: 600; letter-spacing: .28em; }
.spotlight__section-label i { width: 22px; height: 1px; background: currentColor; }
.spotlight__section-label strong { font-size: 18px; font-weight: 500; letter-spacing: .28em; }
.spotlight__utilities .theme-toggle { width: 48px; height: 48px; }
.spotlight .dialog-close { position: static; width: 54px; height: 54px; border: 1.5px solid currentColor; background: transparent; color: inherit; }
.spotlight .dialog-close i { font-size: 27px; }
.spotlight__scroll { height: calc(100dvh - 112px); overflow-y: auto; overscroll-behavior: contain; background: var(--paper); scrollbar-width: thin; scrollbar-color: var(--red) transparent; }
.spotlight__hero { display: grid; min-height: calc(100dvh - 112px); grid-template-columns: minmax(0, 58%) minmax(360px, 42%); overflow: hidden; background: var(--paper); }
.spotlight__car { align-self: stretch; width: 100%; height: 100%; min-height: 620px; object-fit: contain; object-position: var(--spotlight-hero-position, 50% 55%); background: #eeeae3; mix-blend-mode: multiply; transform: scale(1.05); }
html[data-theme="dark"] .spotlight__car { mix-blend-mode: normal; }
.spotlight .dialog-close:focus-visible,
.spotlight .theme-toggle:focus-visible { outline-color: var(--red); }
.spotlight__badges { top: 34px; left: 38px; gap: 8px; }
.spotlight__badges .pill { padding: 8px 12px; border: 1px solid rgba(0,0,0,.08); background: rgba(255,255,255,.9); font-size: 9px; }
.spotlight__copy { display: flex; justify-content: center; padding: 78px 7vw 72px 4vw; background: var(--paper-strong); }
.spotlight__copy > p:first-child { margin: 0 0 22px; color: var(--red); font-size: 10px; font-weight: 600; letter-spacing: .24em; text-transform: uppercase; }
.spotlight__copy h2 { margin: 0; font: 400 clamp(56px, 5.8vw, 96px)/.91 "Montserrat", sans-serif; letter-spacing: -.065em; text-transform: uppercase; }
.spotlight__copy h3 { margin: 24px 0 0; color: var(--text-soft); font: 400 clamp(18px, 1.6vw, 27px)/1.25 "Montserrat", sans-serif; letter-spacing: .12em; text-transform: uppercase; }
.spotlight__copy > p:last-child { max-width: 520px; margin: 42px 0 0; color: var(--text-soft); font-size: 13px; line-height: 1.8; }
.spotlight__accordions { border-bottom: 1px solid var(--hairline); background: var(--paper-strong); }
.vehicle-accordion { border-top: 1px solid var(--hairline); }
.vehicle-accordion > button { display: grid; width: 100%; min-height: 150px; grid-template-columns: 66px 1fr 48px; align-items: center; gap: 24px; padding: 30px max(48px, calc((100vw - 1440px) / 2 + 48px)); border: 0; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.vehicle-accordion__number { align-self: start; padding-top: 4px; color: var(--red); font-size: 16px; font-weight: 500; }
.vehicle-accordion__number::after { display: block; width: 24px; height: 1px; margin-top: 8px; background: var(--red); content: ""; }
.vehicle-accordion__label { display: grid; gap: 13px; }
.vehicle-accordion__label strong { font-size: clamp(25px, 2.5vw, 39px); font-weight: 500; letter-spacing: .08em; text-transform: uppercase; }
.vehicle-accordion__label small { color: var(--text-soft); font-size: 14px; font-weight: 400; letter-spacing: .1em; text-transform: uppercase; }
.vehicle-accordion > button > i { justify-self: end; font-size: 30px; transition: transform .35s var(--ease); }
.vehicle-accordion.is-open > button > i { transform: rotate(90deg); }
.vehicle-accordion__panel { background: var(--paper-soft); }
.vehicle-accordion__panel[hidden] { display: none; }
.vehicle-accordion__panel > div { max-width: 1440px; margin: 0 auto; padding: 0 48px 52px 138px; }
.vehicle-performance { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.vehicle-performance > div { display: grid; grid-template-columns: auto 1fr; gap: 5px 18px; padding: 31px 36px; border-right: 1px solid var(--hairline); }
.vehicle-performance > div:last-child { border-right: 0; }
.vehicle-performance i { grid-row: span 2; align-self: center; color: var(--red); font-size: 28px; }
.vehicle-performance span { color: var(--text-soft); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.vehicle-performance strong { font-size: 29px; font-weight: 500; }
.vehicle-performance small { color: var(--text-soft); font-size: 12px; font-weight: 500; }
.vehicle-design { display: grid; min-height: 330px; grid-template-columns: 48% 52%; overflow: hidden; background: var(--paper-strong); }
.vehicle-design > div { display: flex; flex-direction: column; justify-content: center; padding: 54px; }
.vehicle-design h4 { margin: 0 0 20px; font-size: 26px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; }
.vehicle-design p,
.vehicle-prose p { margin: 0; color: var(--text-soft); font-size: 15px; line-height: 1.8; }
.vehicle-design img { width: 100%; height: 100%; min-height: 330px; object-fit: cover; object-position: var(--spotlight-hero-position, 50% 55%); clip-path: polygon(18% 0, 100% 0, 100% 100%, 0 100%); }
.vehicle-prose { padding: 44px; border-left: 2px solid var(--red); background: var(--paper-strong); }
.vehicle-prose small { display: block; margin-top: 20px; color: var(--text-soft); font-size: 11px; font-style: italic; }
.vehicle-facts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 25px; }
.vehicle-facts span { display: inline-flex; align-items: center; gap: 7px; padding: 9px 13px; border: 1px solid var(--hairline); border-radius: 999px; color: var(--text-soft); font-size: 9px; font-weight: 600; text-transform: uppercase; }
.vehicle-facts i { color: var(--red); font-size: 15px; }
.spotlight__actions { display: grid; max-width: 1440px; grid-template-columns: 1.3fr .7fr; margin: 0 auto; padding: 54px 48px; background: var(--paper); }
.spotlight__actions button { display: flex; min-height: 90px; align-items: center; justify-content: space-between; padding: 0 32px; border: 1px solid var(--hairline); background: transparent; color: inherit; font-size: 19px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.spotlight__actions button:first-child { border-color: var(--red); background: var(--red); color: white; }
.spotlight__actions button i { display: grid; width: 46px; height: 46px; place-items: center; border: 1px solid currentColor; border-radius: 0; font-size: 22px; }
.spotlight__utilities { display: flex; align-items: center; gap: 12px; }
.spotlight__nav { position: static; z-index: auto; inset: auto; display: flex; align-items: center; gap: 12px; }
.spotlight__nav button { display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--hairline); border-radius: 50%; background: transparent; color: inherit; cursor: pointer; }
.spotlight__nav span { color: var(--text-soft); font-size: 10px; letter-spacing: .18em; white-space: nowrap; }

/* Véhicule vendu : un seul CTA (Voir le stock actuel), pleine largeur */
html.spotlight-sold #spotlight-secondary { display: none; }
html.spotlight-sold .spotlight__actions { grid-template-columns: 1fr; }

/* CTA "Voir le stock actuel" mis en avant (véhicule vendu) : rouge + souffle + reflet */
html.spotlight-sold #spotlight-primary {
  position: relative;
  overflow: hidden;
  min-height: 52px !important;
  border-color: var(--red) !important;
  background: var(--red) !important;
  color: #fff !important;
  box-shadow: 0 12px 30px -14px rgba(224, 0, 22, .7) !important;
  animation: sold-cta-breathe 2.8s ease-in-out infinite;
}
html.spotlight-sold #spotlight-primary i {
  width: 34px !important;
  height: 34px !important;
  border-color: rgba(255, 255, 255, .7) !important;
  color: #fff !important;
  transition: transform .4s ease;
}
html.spotlight-sold #spotlight-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 32%, rgba(255, 255, 255, .38) 50%, transparent 68%);
  transform: translateX(-130%);
  animation: sold-cta-shine 4.6s ease-in-out infinite;
  pointer-events: none;
}
html.spotlight-sold #spotlight-primary:hover {
  background: #c8000f !important;
  color: #fff !important;
  border-color: #c8000f !important;
}
html.spotlight-sold #spotlight-primary:hover i { transform: translateX(5px); }

@keyframes sold-cta-breathe {
  0%, 100% { box-shadow: 0 8px 22px -14px rgba(224, 0, 22, .55); }
  50% { box-shadow: 0 16px 36px -12px rgba(224, 0, 22, .9); }
}
@keyframes sold-cta-shine {
  0% { transform: translateX(-130%); }
  55%, 100% { transform: translateX(130%); }
}
@media (prefers-reduced-motion: reduce) {
  html.spotlight-sold #spotlight-primary { animation: none; }
  html.spotlight-sold #spotlight-primary::after { display: none; }
}

html[data-theme="dark"] .spotlight__badges .pill { border-color: rgba(255,255,255,.12); background: rgba(18,18,18,.9); color: #f5f3ee; }
html[data-theme="dark"] .booking__shell,
html[data-theme="dark"] .story-shell { background: #101010; }

@media (max-width: 860px) {
  .mobile-brand__actions > .theme-toggle { width: 34px; height: 34px; padding: 0; border: 1px solid currentColor; border-radius: 50%; font-size: 12px; justify-content: center; }
  .tour-dock { left: 12px; right: auto; transform: none; }
  .tour-dock::before {
    content: "";
    position: fixed;
    top: 10px;
    left: 10px;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(8, 8, 8, .97);
    z-index: -1;
  }
  html[data-theme="light"] .tour-dock::before { background: rgba(255, 255, 255, .96); }
  .spotlight { width: 100vw; height: 100dvh; }
  .spotlight__shell { min-height: 0; border: 0; border-radius: 0; }
  .spotlight__header { height: 86px; gap: 9px; padding: 12px 14px; border-bottom-width: 1px; }
  .spotlight__nav { gap: 6px; }
  .spotlight__nav button { width: 27px; height: 27px; }
  .spotlight__nav button i { font-size: 12px; }
  .spotlight__nav span { font-size: 8px; letter-spacing: .12em; }
  .spotlight__header > img { width: 34px; height: 48px; }
  .spotlight__section-label { gap: 7px; padding-left: 10px; }
  .spotlight__section-label span { font-size: 12px; letter-spacing: .2em; }
  .spotlight__section-label i { width: 14px; }
  .spotlight__section-label strong { overflow: hidden; font-size: 11px; letter-spacing: .18em; text-overflow: ellipsis; }
  .spotlight__utilities { gap: 10px; }
  .spotlight__utilities .theme-toggle { display: none; }
  .spotlight .dialog-close { width: 43px; height: 43px; }
  .spotlight .dialog-close i { font-size: 23px; }
  .spotlight__scroll { height: calc(100% - 86px); }
  .spotlight__hero { display: block; min-height: 0; }
  .spotlight__car { width: 100%; height: min(32vh, 280px); min-height: 220px; object-fit: contain; }
  .spotlight__badges { top: 18px; left: 18px; gap: 5px; }
  .spotlight__badges .pill { padding: 6px 8px; font-size: 7px; }
  .spotlight__badges .pill i { font-size: 10px; }
  .spotlight__copy { display: block; padding: 35px 24px 48px; }
  .spotlight__copy > p:first-child { margin-bottom: 14px; font-size: 8px; letter-spacing: .18em; }
  .spotlight__copy h2 { font-size: clamp(48px, 15.5vw, 76px); line-height: .92; letter-spacing: -.07em; }
  .spotlight__copy h3 { margin-top: 19px; font-size: 14px; line-height: 1.5; letter-spacing: .14em; }
  .spotlight__copy > p:last-child { margin-top: 27px; font-size: 11px; line-height: 1.7; }
  .vehicle-accordion > button { min-height: 138px; grid-template-columns: 42px 1fr 28px; gap: 12px; padding: 26px 21px; }
  .vehicle-accordion__number { font-size: 13px; }
  .vehicle-accordion__number::after { width: 19px; }
  .vehicle-accordion__label { gap: 10px; }
  .vehicle-accordion__label strong { font-size: clamp(22px, 7vw, 30px); letter-spacing: .055em; }
  .vehicle-accordion__label small { font-size: 10px; line-height: 1.45; letter-spacing: .07em; }
  .vehicle-accordion > button > i { font-size: 23px; }
  .vehicle-accordion__panel > div { padding: 0 20px 30px 63px; }
  .vehicle-performance { grid-template-columns: 1fr; }
  .vehicle-performance > div { padding: 20px; border-right: 0; border-bottom: 1px solid var(--hairline); }
  .vehicle-performance > div:last-child { border-bottom: 0; }
  .vehicle-design { min-height: 260px; grid-template-columns: 47% 53%; }
  .vehicle-design > div { padding: 24px 12px 24px 22px; }
  .vehicle-design h4 { margin-bottom: 12px; font-size: 16px; line-height: 1.25; }
  .vehicle-design p { font-size: 10px; line-height: 1.6; }
  .vehicle-design img { min-height: 260px; }
  .vehicle-prose { padding: 25px 22px; }
  .vehicle-prose p { font-size: 12px; line-height: 1.75; }
  .vehicle-facts { gap: 5px; margin-top: 18px; }
  .vehicle-facts span { padding: 7px 9px; font-size: 7px; }
  .spotlight__footer { position: sticky; bottom: 0; z-index: 2; background: var(--paper); box-shadow: 0 -8px 24px rgba(0,0,0,.15); padding: 9px 14px calc(9px + env(safe-area-inset-bottom, 0px)); }
  /* CTA compacts sur une seule ligne (véhicule vendu = 1 seul CTA plein) */
  .spotlight__actions { grid-template-columns: 1.14fr .86fr; gap: 8px; margin: 0; padding: 0; }
  .spotlight__actions button { min-height: 54px; padding: 0 12px 0 16px; font-size: 12px; font-weight: 600; letter-spacing: .03em; line-height: 1.16; gap: 8px; }
  .spotlight__actions button span { overflow: hidden; }
  .spotlight__actions button i { flex: none; width: 32px; height: 32px; font-size: 15px; }
}

@media (min-width: 861px) and (max-width: 1120px) {
  .spotlight__hero { grid-template-columns: 55% 45%; }
  .spotlight__copy { padding-right: 4vw; }
  .vehicle-accordion > button { padding-right: 36px; padding-left: 36px; }
}

/* Vehicle detail lives inside the showroom rail, never above Matterport */
.spotlight {
  position: fixed;
  z-index: 40;
  top: 18px;
  right: auto;
  bottom: 18px;
  left: 18px;
  width: var(--rail-width);
  height: auto;
  max-width: calc(100vw - 36px);
  max-height: none;
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--hairline);
  border-radius: 16px;
  background: var(--paper);
  box-shadow: 0 24px 56px rgba(0,0,0,.3);
}
.spotlight[open] { display: block; }
.spotlight__shell { width: 100%; height: 100%; border-radius: inherit; }
.spotlight__header { height: 86px; gap: 14px; padding: 12px 18px; border-bottom-width: 1px; }
.spotlight__header > img { width: 34px; height: 48px; }
.spotlight__section-label { gap: 10px; padding-left: 14px; }
.spotlight__section-label span { font-size: 12px; letter-spacing: .2em; }
.spotlight__section-label i { width: 14px; }
.spotlight__section-label strong { overflow: hidden; font-size: 11px; letter-spacing: .18em; text-overflow: ellipsis; }
.spotlight__utilities { gap: 5px; }
.spotlight__utilities .theme-toggle { width: 34px; height: 34px; }
.spotlight .dialog-close { width: 43px; height: 43px; }
.spotlight .dialog-close i { font-size: 23px; }
.spotlight__scroll { height: calc(100% - 86px); }
.spotlight__hero { position: relative; display: block; min-height: 0; overflow: hidden; }
.spotlight__car { width: 100%; height: 260px; min-height: 0; object-fit: contain; transform: scale(1.04); }
.spotlight__badges { top: 14px; left: 14px; gap: 4px; }
.spotlight__badges .pill { padding: 6px 8px; font-size: 7px; }
.spotlight__badges .pill i { font-size: 10px; }
.spotlight__copy { display: block; padding: 24px 22px 30px; }
.spotlight__copy > p:first-child { margin-bottom: 10px; font-size: 7px; letter-spacing: .16em; }
.spotlight__copy h2 { font-size: clamp(39px, 4vw, 56px); line-height: .92; letter-spacing: -.065em; }
.spotlight__copy h3 { margin-top: 14px; font-size: 11px; line-height: 1.45; letter-spacing: .13em; }
.spotlight__copy > p:last-child { display: none; }
.vehicle-accordion > button { min-height: 108px; grid-template-columns: 38px 1fr 24px; gap: 10px; padding: 20px; }
.vehicle-accordion__number { font-size: 11px; }
.vehicle-accordion__number::after { width: 17px; margin-top: 6px; }
.vehicle-accordion__label { gap: 8px; }
.vehicle-accordion__label strong { font-size: clamp(20px, 1.8vw, 27px); letter-spacing: .055em; }
.vehicle-accordion__label small { font-size: 8px; line-height: 1.4; letter-spacing: .065em; }
.vehicle-accordion > button > i { font-size: 20px; }
.vehicle-accordion__panel > div { padding: 0 16px 24px 58px; }
.vehicle-performance { grid-template-columns: 1fr; }
.vehicle-performance > div { padding: 16px; border-right: 0; border-bottom: 1px solid var(--hairline); }
.vehicle-performance > div:last-child { border-bottom: 0; }
.vehicle-performance i { font-size: 21px; }
.vehicle-performance strong { font-size: 22px; }
.vehicle-design { min-height: 215px; grid-template-columns: 46% 54%; }
.vehicle-design > div { padding: 20px 8px 20px 18px; }
.vehicle-design h4 { margin-bottom: 10px; font-size: 14px; line-height: 1.3; }
.vehicle-design p { font-size: 8px; line-height: 1.6; }
.vehicle-design img { min-height: 215px; }
.vehicle-prose { padding: 22px 18px; }
.vehicle-prose p { font-size: 10px; line-height: 1.7; }
.vehicle-prose small { font-size: 8px; }
.vehicle-facts { gap: 5px; margin-top: 16px; }
.vehicle-facts span { padding: 6px 8px; font-size: 6px; }
.spotlight__actions { grid-template-columns: 1fr; padding: 22px 16px; }
.spotlight__actions button { min-height: 62px; padding: 0 18px; font-size: 12px; }
.spotlight__actions button i { width: 36px; height: 36px; font-size: 17px; }
.spotlight__nav { min-height: 68px; }
.spotlight__nav button { width: 35px; height: 35px; }

@media (max-width: 860px) {
  .spotlight {
    top: auto;
    right: 8px;
    bottom: 8px;
    left: 8px;
    width: auto;
    height: min(78dvh, calc((100vw - 16px) * 1.7778));
    max-width: none;
    border-radius: 22px;
  }
  .spotlight__header { height: 76px; padding: 9px 14px; }
  .spotlight__header > img { width: 30px; height: 43px; }
  .spotlight__section-label { padding-left: 10px; }
  .spotlight__section-label strong { font-size: 9px; }
  .spotlight__utilities .theme-toggle { width: 31px; height: 31px; }
  .spotlight .dialog-close { width: 38px; height: 38px; }
  .spotlight__scroll { height: calc(100% - 76px); }
  .spotlight__car { height: 225px; }
  .spotlight__copy { padding: 21px 19px 25px; }
  .spotlight__copy h2 { font-size: clamp(38px, 12vw, 52px); }
  .vehicle-accordion > button { min-height: 102px; padding: 18px; }
  .vehicle-accordion__panel > div { padding-left: 54px; }
}

/* Ferrari editorial system — global harmonisation */
:root {
  --ui-canvas: #e9e6e0;
  --ui-surface: #ffffff;
  --ui-surface-soft: #f3f1ec;
  --ui-surface-muted: #e9e6df;
  --ui-text: #111111;
  --ui-text-secondary: #66625d;
  --ui-text-tertiary: #8a8680;
  --ui-line: rgba(17, 17, 17, .14);
  --ui-line-strong: rgba(17, 17, 17, .24);
  --ui-shadow: 0 22px 54px rgba(18, 16, 13, .2);
}

html[data-theme="dark"] {
  --ui-canvas: #050505;
  --ui-surface: #0d0d0d;
  --ui-surface-soft: #151515;
  --ui-surface-muted: #1d1d1d;
  --ui-text: #f5f3ee;
  --ui-text-secondary: #b8b4ae;
  --ui-text-tertiary: #85817c;
  --ui-line: rgba(255, 255, 255, .14);
  --ui-line-strong: rgba(255, 255, 255, .26);
  --ui-shadow: 0 24px 64px rgba(0, 0, 0, .5);
}

html,
body,
button,
input,
select,
textarea { font-family: "Montserrat", Arial, sans-serif; }

body { background: var(--ui-canvas); color: var(--ui-text); }

:where(button, a, input, select, textarea, [tabindex]):focus { outline: 0; }
:where(button, a, input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible { outline-color: var(--red); }
.tab:focus-visible { outline: 0; box-shadow: inset 0 -2px 0 var(--red); }
.vehicle-accordion > button:focus-visible { outline: 0; box-shadow: inset 2px 0 0 var(--red); }

.rail,
.mobile-sheet {
  border-color: var(--ui-line);
  background: var(--ui-surface);
  background-image: none;
  color: var(--ui-text);
  box-shadow: var(--ui-shadow);
}

.rail { border-radius: 18px; }
.rail__header { min-height: 104px; padding: 22px 24px 14px; }
.brand-lockup::after { display: none; }
.brand-lockup .brand-wordmark,
.mobile-brand > img,
.rail-launcher img { filter: none !important; }
html[data-theme="dark"] .brand-lockup .brand-wordmark,
html[data-theme="dark"] .mobile-brand > img,
html[data-theme="dark"] .rail-launcher img { filter: invert(1) grayscale(1) brightness(2.7) !important; }
.brand-lockup span { color: var(--ui-text-secondary); font-size: 9px; font-weight: 500; letter-spacing: .3em; }
.header-actions { padding-top: 4px; }
.icon-button,
.dialog-close,
.theme-toggle { border-color: var(--ui-line-strong); background: transparent; color: var(--ui-text); }
.icon-button:hover,
.dialog-close:hover,
.theme-toggle:hover { border-color: var(--red); background: rgba(224, 0, 22, .06); }

.tabs { margin: 0 22px; border-color: var(--ui-line); }
.tab { min-height: 82px; gap: 10px; padding: 12px 4px 17px; color: var(--ui-text-secondary); }
.tab i { font-size: 23px; }
.tab span { font-size: 9px; font-weight: 500; letter-spacing: .09em; }
.tab:hover,
.tab.is-active { color: var(--ui-text); }
.tab::after { right: 10px; left: 10px; height: 2px; }

.panel { padding: 24px 22px 30px; }
.panel-heading { margin: 5px 2px 25px; }
.eyebrow { margin-bottom: 10px; font-size: 9px; font-weight: 600; letter-spacing: .24em; }
.panel-heading h1,
.catalog-intro h2,
.section-title h2 { color: var(--ui-text); font-weight: 500; letter-spacing: .01em; }
.panel-heading h1 { font-size: clamp(27px, 2vw, 34px); line-height: 1.02; }
.panel-heading p:not(.eyebrow),
.catalog-intro > span { color: var(--ui-text-secondary); font-size: 11px; line-height: 1.65; }
.live-dot { color: var(--ui-text-tertiary); }

.catalog-sticky { top: -24px; margin-right: -2px; margin-left: -2px; padding: 11px 2px 10px; background: color-mix(in srgb, var(--ui-surface) 94%, transparent); }
.catalog-tabs,
.mobile-catalog-tabs { border-color: var(--ui-line-strong); border-radius: 7px; background: var(--ui-surface); }
.catalog-tabs button,
.mobile-catalog-tabs button { min-height: 48px; border-color: var(--ui-line); color: var(--ui-text-secondary); font-size: 9px; font-weight: 500; letter-spacing: .06em; }
.catalog-tabs button strong,
.mobile-catalog-tabs button strong { color: var(--ui-text-tertiary); font-weight: 600; }
.catalog-tabs button.is-active,
.mobile-catalog-tabs button.is-active { background: var(--red); color: #fff; }
.catalog-tabs button.is-active strong,
.mobile-catalog-tabs button.is-active strong { color: #fff; }
.catalog-tools { gap: 8px; margin-top: 8px; }
.catalog-search,
.filter-toggle { height: 42px; border-color: var(--ui-line-strong); border-radius: 7px; background: var(--ui-surface); color: var(--ui-text-secondary); }
.catalog-search input { color: var(--ui-text); font-size: 9px; }
.catalog-search input::placeholder { color: var(--ui-text-tertiary); }
.filter-drawer label { color: var(--ui-text-secondary); }
.filter-drawer select { border-color: var(--ui-line); background: var(--ui-surface-soft); color: var(--ui-text); }
.filter-drawer > button { color: var(--ui-text-secondary); }
.catalog-intro { padding: 13px 4px 16px; border-bottom: 1px solid var(--ui-line); }
.catalog-intro h2 { font-size: 20px; }

.model-list { gap: 11px; padding-top: 11px; }
.model-card {
  overflow: hidden;
  border-color: var(--ui-line-strong);
  border-radius: 8px;
  background: var(--ui-surface);
  color: var(--ui-text);
  box-shadow: 0 8px 20px rgba(18, 16, 13, .08);
}
.model-card:hover { border-color: var(--red); box-shadow: 0 14px 30px rgba(18, 16, 13, .15); }
.model-card:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.model-card__media { background: #ece8df; }
.model-card__media img { mix-blend-mode: multiply; }
html[data-theme="dark"] .model-card__media img { mix-blend-mode: normal; }
.model-card__copy { padding-right: 16px; }
.model-card__copy h2 { color: var(--ui-text); font-size: 21px; font-weight: 500; }
.model-card__copy h3 { color: var(--ui-text-secondary); font-size: 12px; font-weight: 500; }
.model-card__copy p { color: var(--ui-text-secondary); }
.commercial-note { color: var(--ui-text-tertiary); }
.model-card__open { border-color: var(--ui-line-strong); background: var(--ui-surface); color: var(--ui-text); }
.model-card__stats { border-color: var(--ui-line); background: var(--ui-surface-soft); }
.model-card__stat { border-color: var(--ui-line); }
.model-card__stat span,
.model-card__stat small { color: var(--ui-text-secondary); }
.model-card__stat strong { color: var(--ui-text); font-weight: 500; }
.model-card--exhibition { background: var(--ui-surface); }

.empty-state,
.editorial-card,
.official-config-card,
.craft-list button,
.era-rail button,
.era-feature,
.heritage-numbers,
.legend-strip button,
.intent-grid button,
.concierge-card,
.contact-details > * {
  border-color: var(--ui-line);
  border-radius: 7px;
  background: var(--ui-surface);
  color: var(--ui-text);
}
.editorial-card { box-shadow: none; }
.editorial-card h2,
.official-config-card h2,
.craft-list strong,
.era-feature h2,
.legend-strip strong,
.intent-grid strong { color: var(--ui-text); font-weight: 500; }
.editorial-card p,
.official-config-card p,
.era-feature p,
.intent-grid span,
.contact-details > * { color: var(--ui-text-secondary); }
.official-config-card:hover,
.craft-list button:hover,
.era-rail button:hover,
.legend-strip button:hover { border-color: var(--red); }
.craft-list { gap: 0; margin-top: 12px; border-top: 1px solid var(--ui-line); }
.craft-list button { min-height: 58px; border-width: 0 0 1px; border-radius: 0; }
.craft-list strong { font-size: 12px; letter-spacing: .04em; }
.craft-list i { color: var(--ui-text-secondary); }

.heritage-hero { border-radius: 8px; }
.heritage-hero h2,
.heritage-hero p,
.heritage-hero button { color: #fff; }
.era-rail { gap: 0; margin: 13px 0; }
.era-rail button { flex-basis: 132px; border-radius: 0; }
.era-rail button + button { border-left: 0; }
.era-rail button.is-active { border-color: var(--red); background: var(--ui-surface-soft); color: var(--ui-text); }
.era-feature { border-radius: 8px; }
.era-feature button { color: var(--ui-text); }
.milestone-chips i { background: var(--ui-surface-muted); color: var(--ui-text-secondary); }
.heritage-numbers { border-radius: 0; }
.heritage-numbers div { border-color: var(--ui-line); }
.heritage-numbers span { color: var(--ui-text-secondary); }
.legend-strip button { border-radius: 7px; }

.intent-grid { gap: 0; border-top: 1px solid var(--ui-line); border-left: 1px solid var(--ui-line); }
.intent-grid button { min-height: 78px; border-width: 0 1px 1px 0; border-radius: 0; }
.intent-grid button.is-selected { border-color: var(--red); background: rgba(224,0,22,.06); color: var(--ui-text); }
.concierge-card { gap: 13px; padding: 20px; }
.contact-context { border-color: var(--ui-line); }
.concierge-card label { color: var(--ui-text-secondary); }
.concierge-card input,
.concierge-card select,
.concierge-card textarea,
.booking input,
.booking select { border-color: var(--ui-line-strong); border-radius: 6px; background: var(--ui-surface-soft); color: var(--ui-text); }
.contact-details { gap: 0; }
.contact-details > * { border-radius: 0; }
.contact-details > * + * { border-left: 0; }
.contact-details strong { color: var(--ui-text); font-weight: 500; }

.rail__footer { border-color: var(--ui-line); background: var(--ui-surface-soft); }
.rail__footer button { color: var(--ui-text-secondary); }
.rail-launcher,
.tour-dock,
.drive-controls,
.config-cta { border-color: var(--ui-line-strong); background: color-mix(in srgb, var(--ui-surface) 94%, transparent); color: var(--ui-text); }
.tour-dock button,
.drive-controls button { color: var(--ui-text); }

.booking__shell,
.story-shell { border-color: var(--ui-line); border-radius: 16px; background: var(--ui-surface); color: var(--ui-text); }
.booking__shell h2,
.story-copy h2 { color: var(--ui-text); font-weight: 500; }
.booking-intro,
.story-copy #story-body p { color: var(--ui-text-secondary); }
.booking .dialog-close,
.story-dialog .dialog-close { border-color: var(--ui-line-strong); background: var(--ui-surface); color: var(--ui-text); }
.story-lead { border-color: var(--ui-line); color: var(--ui-text); }
.story-milestones span { border-color: var(--ui-line-strong); color: var(--ui-text-secondary); }
.booking label { color: var(--ui-text-secondary); }
.booking-success { background: var(--ui-surface); }
.booking-success h3 { color: var(--ui-text); font-weight: 500; }
.booking-success p { color: var(--ui-text-secondary); }

.config-embed__shell { border-color: var(--ui-line); background: var(--ui-surface); color: var(--ui-text); }
.config-embed__bar { border-color: var(--ui-line); background: var(--ui-surface); }
.config-embed__bar > div strong { color: var(--ui-text); font-weight: 500; }
.config-embed__bar nav,
.config-embed__bar > a,
.config-embed__fullscreen,
.config-embed__close { border-color: var(--ui-line-strong); color: var(--ui-text); }
.config-embed__bar nav button { color: var(--ui-text-secondary); }
.config-embed__viewport,
.config-embed__viewport iframe,
.config-embed__loading { background: var(--ui-surface-soft); }

.mobile-sheet { border-radius: 22px 22px 0 0; }
.mobile-tabs { border-color: var(--ui-line); }
.mobile-tabs button { border-color: var(--ui-line); background: transparent; color: var(--ui-text-secondary); }
.mobile-tabs button.is-active { color: var(--ui-text); }

/* Atelier Tailor Made — expérience éditoriale */
#atelier-desktop,
#mobile-content { container-type: inline-size; }
#panel-atelier { padding-top: 18px; }
.atelier-manifesto { position: relative; min-height: 430px; overflow: hidden; border: 1px solid var(--ui-line); border-radius: 8px; background: #090909; color: #fff; }
.atelier-manifesto::after { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.88) 0%, rgba(0,0,0,.58) 46%, rgba(0,0,0,.06) 78%), linear-gradient(0deg, rgba(0,0,0,.42), transparent 55%); content: ""; }
.atelier-manifesto > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.atelier-manifesto__copy { position: relative; z-index: 1; display: flex; width: min(68%, 470px); min-height: 430px; flex-direction: column; align-items: flex-start; justify-content: flex-end; padding: 42px; }
.atelier-manifesto__copy .eyebrow { color: #ff2838; }
.atelier-manifesto__copy h1 { margin: 9px 0 15px; color: #fff; font: 500 clamp(34px, 4.2vw, 56px)/.94 "Montserrat", sans-serif; letter-spacing: -.035em; text-transform: uppercase; }
.atelier-manifesto__copy > p:not(.eyebrow) { max-width: 410px; margin: 0 0 22px; color: rgba(255,255,255,.78); font-size: 12px; line-height: 1.7; }
.atelier-manifesto__copy button { display: inline-flex; min-height: 42px; align-items: center; gap: 18px; padding: 0 16px; border: 1px solid rgba(255,255,255,.5); border-radius: 4px; background: rgba(0,0,0,.22); color: #fff; font-size: 8px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; }
.atelier-manifesto__copy button:hover { border-color: var(--red); background: var(--red); }
.atelier-manifesto__edition { position: absolute; z-index: 2; top: 20px; right: 22px; color: rgba(255,255,255,.7); font-size: 7px; font-weight: 600; letter-spacing: .17em; text-transform: uppercase; }

.atelier-models,
.tailor-studio,
.atelier-process { padding: 34px 0 0; scroll-margin-top: 18px; }
.atelier-section-heading { display: grid; grid-template-columns: 42px 1fr; gap: 12px; margin-bottom: 20px; padding: 0 4px; }
.atelier-section-heading > span { padding-top: 2px; color: var(--red); font-size: 11px; font-weight: 500; }
.atelier-section-heading > span::after { display: block; width: 20px; height: 1px; margin-top: 8px; background: var(--red); content: ""; }
.atelier-section-heading h2 { margin: 5px 0 7px; color: var(--ui-text); font: 500 clamp(25px, 2.6vw, 34px)/1 "Montserrat", sans-serif; letter-spacing: -.025em; text-transform: uppercase; }
.atelier-section-heading div > p:not(.eyebrow) { margin: 0; color: var(--ui-text-secondary); font-size: 10px; line-height: 1.6; }

.atelier-model-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.atelier-model { overflow: hidden; border: 1px solid var(--ui-line-strong); border-radius: 7px; background: var(--ui-surface); color: var(--ui-text); text-decoration: none; transition: border-color .25s ease, transform .25s ease, box-shadow .25s ease; }
.atelier-model:hover { border-color: var(--red); transform: translateY(-3px); box-shadow: 0 16px 34px rgba(20,16,12,.13); }
.atelier-model:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.atelier-model__media { position: relative; height: 190px; overflow: hidden; background: #ede9e1; }
.atelier-model__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.atelier-model:hover .atelier-model__media img { transform: scale(1.025); }
.atelier-model__media > span { position: absolute; top: 12px; left: 12px; padding: 7px 9px; border-radius: 999px; background: rgba(255,255,255,.9); color: #151515; font-size: 7px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; }
.atelier-model__copy { display: grid; grid-template-columns: auto 1fr; padding: 18px; }
.atelier-model__copy > p { align-self: end; margin: 0 7px 3px 0; color: var(--red); font-size: 10px; letter-spacing: .12em; }
.atelier-model__copy h3 { margin: 0; color: var(--ui-text); font: 500 31px/1 "Montserrat", sans-serif; letter-spacing: -.03em; }
.atelier-model__copy dl { display: grid; grid-column: 1 / -1; grid-template-columns: repeat(3, 1fr); margin: 17px 0; padding: 13px 0; border-top: 1px solid var(--ui-line); border-bottom: 1px solid var(--ui-line); }
.atelier-model__copy dl > div + div { padding-left: 10px; border-left: 1px solid var(--ui-line); }
.atelier-model__copy dt { margin-bottom: 5px; color: var(--ui-text-tertiary); font-size: 6px; letter-spacing: .08em; text-transform: uppercase; }
.atelier-model__copy dd { margin: 0; color: var(--ui-text); font-size: 10px; font-weight: 500; }
.atelier-model__copy > strong { display: flex; grid-column: 1 / -1; align-items: center; justify-content: space-between; color: var(--ui-text); font-size: 8px; font-weight: 600; letter-spacing: .11em; text-transform: uppercase; }
.atelier-model__copy > strong i { color: var(--red); font-size: 15px; }

.tailor-studio__tabs { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--ui-line-strong); border-bottom: 0; }
.tailor-studio__tabs button { display: flex; min-height: 68px; align-items: center; gap: 10px; padding: 0 16px; border-right: 1px solid var(--ui-line); background: var(--ui-surface); color: var(--ui-text-secondary); }
.tailor-studio__tabs button:last-child { border-right: 0; }
.tailor-studio__tabs button span { color: var(--red); font-size: 8px; }
.tailor-studio__tabs button strong { font-size: 10px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; }
.tailor-studio__tabs button.is-active { background: var(--ui-text); color: var(--ui-surface); }
.tailor-studio__tabs button.is-active span { color: #ff2436; }
.tailor-studio__tabs button:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--red); outline-offset: -2px; }
.tailor-universe { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(280px, .92fr); overflow: hidden; border: 1px solid var(--ui-line-strong); background: var(--ui-surface); }
.tailor-universe__media { position: relative; min-height: 430px; overflow: hidden; background: #111; }
.tailor-universe__media img { width: 100%; height: 100%; object-fit: cover; animation: tailor-image-in .45s var(--ease) both; }
.tailor-universe__media > span { position: absolute; right: 15px; bottom: 15px; padding: 7px 9px; background: rgba(0,0,0,.62); color: #fff; font-size: 7px; letter-spacing: .12em; text-transform: uppercase; }
.tailor-universe__copy { display: flex; flex-direction: column; justify-content: center; padding: 34px 30px; animation: tailor-copy-in .38s var(--ease) both; }
.tailor-universe__copy h3 { margin: 8px 0 15px; color: var(--ui-text); font: 500 clamp(24px, 2.6vw, 34px)/1 "Montserrat", sans-serif; letter-spacing: -.025em; text-transform: uppercase; }
.tailor-universe__copy > p:not(.eyebrow) { margin: 0; color: var(--ui-text-secondary); font-size: 10px; line-height: 1.75; }
.tailor-universe__copy ul { display: grid; gap: 9px; margin: 22px 0; padding: 17px 0; border-top: 1px solid var(--ui-line); border-bottom: 1px solid var(--ui-line); list-style: none; }
.tailor-universe__copy li { display: grid; grid-template-columns: 10px 1fr; gap: 8px; color: var(--ui-text-secondary); font-size: 9px; line-height: 1.45; }
.tailor-universe__copy li::before { color: var(--red); content: "•"; }
.tailor-palette { display: flex; flex-wrap: wrap; gap: 10px; }
.tailor-palette span { display: inline-flex; align-items: center; gap: 7px; color: var(--ui-text-secondary); font-size: 7px; }
.tailor-palette i { width: 17px; height: 17px; border: 1px solid var(--ui-line-strong); border-radius: 50%; background: var(--swatch); }

.atelier-process > ol { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0; padding: 0; border-top: 1px solid var(--ui-line); border-left: 1px solid var(--ui-line); list-style: none; }
.atelier-process > ol li { min-height: 150px; padding: 18px 15px; border-right: 1px solid var(--ui-line); border-bottom: 1px solid var(--ui-line); }
.atelier-process > ol span { color: var(--red); font-size: 8px; }
.atelier-process > ol strong { display: block; margin: 25px 0 8px; color: var(--ui-text); font-size: 10px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.atelier-process > ol p { margin: 0; color: var(--ui-text-secondary); font-size: 8px; line-height: 1.55; }
.atelier-final-cta { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 20px; margin-top: 14px; padding: 22px; border: 1px solid var(--ui-line-strong); background: var(--ui-text); color: var(--ui-surface); }
.atelier-final-cta p { margin: 0; }
.atelier-final-cta p span { display: block; margin-bottom: 6px; color: #ff2a3a; font-size: 7px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.atelier-final-cta p strong { font-size: 12px; font-weight: 500; }
.atelier-final-cta > div { display: flex; gap: 6px; }
.atelier-final-cta a { display: inline-flex; min-height: 38px; align-items: center; gap: 14px; padding: 0 12px; border: 1px solid color-mix(in srgb, var(--ui-surface) 38%, transparent); color: var(--ui-surface); font-size: 7px; font-weight: 600; letter-spacing: .08em; text-decoration: none; text-transform: uppercase; }
.atelier-final-cta a:hover { border-color: var(--red); background: var(--red); color: #fff; }
@keyframes tailor-image-in { from { opacity: .45; transform: scale(1.025); } to { opacity: 1; transform: none; } }
@keyframes tailor-copy-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* Héritage — récit continu dans la même carte */
.story-dialog { width: min(1220px, calc(100vw - 48px)); }
.story-shell { display: grid; width: 100%; max-height: min(820px, calc(100dvh - 48px)); grid-template-columns: 52% 48%; overflow: hidden; }
.story-visual { position: relative; min-height: 700px; overflow: hidden; background: #111; }
.story-visual::after { position: absolute; inset: 62% 0 0; background: linear-gradient(transparent, rgba(0,0,0,.65)); content: ""; pointer-events: none; }
.story-visual img { width: 100%; height: 100%; object-fit: cover; transition: opacity .25s ease; }
.story-visual > span { position: absolute; z-index: 1; right: 24px; bottom: 22px; left: 24px; color: rgba(255,255,255,.8); font-size: 7px; font-weight: 500; letter-spacing: .13em; text-transform: uppercase; }
.story-copy { position: relative; overflow-y: auto; padding: 38px 44px 0; }
.story-progress { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px; margin: 0 46px 38px 0; color: var(--ui-text-tertiary); font-size: 7px; font-weight: 600; letter-spacing: .11em; text-transform: uppercase; }
.story-progress > i { height: 1px; overflow: hidden; background: var(--ui-line-strong); }
.story-progress > i b { display: block; width: 16.666%; height: 100%; background: var(--red); transition: width .35s var(--ease); }
.story-copy h2 { max-width: 470px; margin-bottom: 17px; font-size: clamp(38px, 4.2vw, 59px); line-height: .94; letter-spacing: -.035em; }
.story-copy h2:focus { outline: none; }
.story-lead { margin-bottom: 22px; padding-bottom: 22px; font-size: 13px; line-height: 1.5; }
.story-copy #story-body { display: grid; gap: 13px; }
.story-copy #story-body p { margin: 0; font-size: 10px; line-height: 1.72; }
.story-insight { margin: 22px 0; padding: 18px 20px; border: 1px solid var(--ui-line); border-left: 2px solid var(--red); background: var(--ui-surface-soft); }
.story-insight span { display: block; margin-bottom: 8px; color: var(--red); font-size: 7px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.story-insight p { margin: 0; color: var(--ui-text); font-size: 10px; line-height: 1.6; }
.story-milestones { margin-bottom: 22px; }
.story-navigation { position: sticky; z-index: 2; bottom: 0; display: grid; grid-template-columns: 1fr 1fr; margin: 0 -44px; border-top: 1px solid var(--ui-line); background: color-mix(in srgb, var(--ui-surface) 96%, transparent); backdrop-filter: blur(12px); }
.story-navigation[hidden] { display: none; }
.story-navigation button { display: grid; min-height: 80px; grid-template-columns: auto 1fr; align-content: center; gap: 3px 10px; padding: 14px 20px; color: var(--ui-text); text-align: left; }
.story-navigation button + button { grid-template-columns: 1fr auto; border-left: 1px solid var(--ui-line); text-align: right; }
.story-navigation i { grid-row: 1 / 3; align-self: center; color: var(--red); font-size: 18px; }
.story-navigation button + button i { grid-column: 2; }
.story-navigation span { color: var(--ui-text-tertiary); font-size: 6px; font-weight: 600; letter-spacing: .11em; text-transform: uppercase; }
.story-navigation strong { overflow: hidden; color: var(--ui-text); font-size: 9px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.story-navigation button:hover { background: var(--red); color: #fff; }
.story-navigation button:hover span,
.story-navigation button:hover strong,
.story-navigation button:hover i { color: #fff; }

html[data-theme="dark"] .atelier-model__media { background: #171717; }
html[data-theme="dark"] .atelier-model__media img { mix-blend-mode: normal; }

@container (max-width: 600px) {
  .atelier-model-grid { grid-template-columns: 1fr; }
  .atelier-model__media { height: 215px; }
  .tailor-universe { grid-template-columns: 1fr; }
  .tailor-universe__media { min-height: 285px; }
  .atelier-process > ol { grid-template-columns: 1fr 1fr; }
  .atelier-final-cta { grid-template-columns: 1fr; }
  .atelier-final-cta > div { flex-direction: column; }
}

@media (max-width: 900px) {
  #panel-atelier { padding: 12px; }
  .atelier-manifesto { min-height: 470px; }
  .atelier-manifesto::after { background: linear-gradient(0deg, rgba(0,0,0,.92) 0%, rgba(0,0,0,.52) 55%, rgba(0,0,0,.08) 100%); }
  .atelier-manifesto__copy { width: 100%; min-height: 470px; padding: 28px 23px; }
  .atelier-manifesto__copy h1 { font-size: 35px; }
  .atelier-model-grid { display: grid; grid-auto-flow: column; grid-auto-columns: 84%; grid-template-columns: none; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 2px; }
  .atelier-model-grid::-webkit-scrollbar { display: none; }
  .atelier-model { scroll-snap-align: start; }
  .atelier-model__media { height: 205px; }
  .tailor-studio__tabs { display: flex; grid-template-columns: none; overflow-x: auto; scroll-snap-type: x proximity; border-bottom: 1px solid var(--ui-line-strong); scrollbar-width: none; }
  .tailor-studio__tabs::-webkit-scrollbar { display: none; }
  .tailor-studio__tabs button { flex: 0 0 auto; min-width: 150px; min-height: 50px; border-right: 1px solid var(--ui-line); scroll-snap-align: start; }
  .tailor-studio__tabs button:last-child { border-right: 0; }
  .tailor-universe { grid-template-columns: 1fr; }
  .tailor-universe__media { min-height: 260px; }
  .tailor-universe__copy { padding: 27px 22px; }
  .atelier-process > ol { grid-template-columns: 1fr 1fr; }
  .atelier-final-cta { grid-template-columns: 1fr; }
  .atelier-final-cta > div { flex-direction: column; }

  .story-dialog { width: calc(100vw - 16px); }
  .story-shell { max-height: calc(100dvh - 16px); grid-template-columns: 1fr; grid-template-rows: 34% 66%; }
  .story-visual { min-height: 0; }
  .story-copy { padding: 24px 20px 0; }
  .story-progress { margin: 0 42px 24px 0; }
  .story-copy h2 { font-size: 35px; }
  .story-navigation { margin: 0 -20px; }
  .story-navigation button { min-height: 68px; padding: 10px 12px; }
  .story-navigation strong { max-width: 110px; font-size: 7px; }
}

@media (max-width: 560px) {
  .atelier-process > ol li { min-height: 128px; padding: 16px 12px; }
  .atelier-model__copy dl { gap: 0; }
  .atelier-model__copy dd { font-size: 9px; }
}

/* Full-width vehicle accordion layouts */
.spotlight { border-color: var(--ui-line); background: var(--ui-surface); color: var(--ui-text); }
.spotlight__shell,
.spotlight__header,
.spotlight__scroll,
.spotlight__accordions { background: var(--ui-surface); color: var(--ui-text); }
.spotlight__header { border-color: var(--red); }
.spotlight__car { background: #ebe7de; }
.spotlight__copy { background: var(--ui-surface); }
.spotlight__copy h2 { color: var(--ui-text); font-weight: 400; }
.spotlight__copy h3,
.vehicle-accordion__label small { color: var(--ui-text-secondary); }
.vehicle-accordion { border-color: var(--ui-line); }
.vehicle-accordion > button { color: var(--ui-text); }
.vehicle-accordion > button:focus:not(:focus-visible) { outline: 0; }
.vehicle-accordion__label strong { font-weight: 500; }
.vehicle-accordion__panel { overflow: hidden; background: var(--ui-surface-soft); }
.vehicle-accordion__panel > div { width: 100%; max-width: none; margin: 0; padding: 0; }

.vehicle-detail-section,
.vehicle-design { width: 100%; background: var(--ui-surface-soft); }
.vehicle-section-lead,
.vehicle-section-copy { padding: 24px 22px; }
.vehicle-section-lead > span,
.vehicle-section-copy > span,
.vehicle-history__era > span { display: block; margin-bottom: 10px; color: var(--red); font-size: 8px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; }
.vehicle-section-lead p,
.vehicle-section-copy p { margin: 0; color: var(--ui-text-secondary); font-size: 10px; line-height: 1.72; }
.vehicle-section-copy p + p { margin-top: 11px; }
.vehicle-section-copy h4 { margin: 0 0 13px; color: var(--ui-text); font-size: 20px; font-weight: 500; line-height: 1.15; letter-spacing: .035em; text-transform: uppercase; }

.vehicle-performance { grid-template-columns: repeat(3, minmax(0, 1fr)); border-color: var(--ui-line); background: var(--ui-surface); }
.vehicle-performance > div { display: flex; min-width: 0; flex-direction: column; gap: 4px; padding: 18px 12px; border-color: var(--ui-line); }
.vehicle-performance i { margin-bottom: 5px; font-size: 22px; }
.vehicle-performance span { font-size: 7px; }
.vehicle-performance strong { color: var(--ui-text); font-size: 20px; font-weight: 500; white-space: nowrap; }
.vehicle-performance small { color: var(--ui-text-secondary); font-size: 8px; }

.vehicle-detail-list { display: grid; gap: 10px; margin: 0; padding: 20px 22px 24px; border-top: 1px solid var(--ui-line); list-style: none; }
.vehicle-detail-list li { position: relative; padding-left: 17px; color: var(--ui-text-secondary); font-size: 9px; line-height: 1.55; }
.vehicle-detail-list li::before { position: absolute; top: .55em; left: 0; width: 5px; height: 5px; border-radius: 50%; background: var(--red); content: ""; }

.vehicle-design { display: flex; min-height: 0; flex-direction: column; overflow: hidden; }
.vehicle-design > img { order: 0; width: 100%; height: 230px; min-height: 0; object-fit: contain; clip-path: none; background: #eae6dd; }
.vehicle-design > .vehicle-section-copy { order: 1; background: var(--ui-surface); }
.vehicle-design .vehicle-detail-list { margin: 18px -22px -24px; background: var(--ui-surface-soft); }

.vehicle-engine > .vehicle-section-copy { border-left: 2px solid var(--red); background: var(--ui-surface); }
.vehicle-fact-grid { display: grid; grid-template-columns: 1fr 1fr; margin: 0; border-top: 1px solid var(--ui-line); border-left: 1px solid var(--ui-line); }
.vehicle-fact-grid > div { min-height: 83px; padding: 17px 14px; border-right: 1px solid var(--ui-line); border-bottom: 1px solid var(--ui-line); background: var(--ui-surface-soft); }
.vehicle-fact-grid dt { margin-bottom: 8px; color: var(--red); font-size: 7px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.vehicle-fact-grid dd { margin: 0; color: var(--ui-text); font-size: 11px; font-weight: 500; line-height: 1.35; }

.vehicle-history { display: grid; grid-template-columns: 116px 1fr; }
.vehicle-history__era { padding: 24px 16px; border-right: 1px solid var(--ui-line); background: var(--ui-text); color: var(--ui-surface); }
.vehicle-history__era strong { display: block; color: inherit; font-size: 12px; font-weight: 500; line-height: 1.35; text-transform: uppercase; }
.vehicle-history > .vehicle-section-copy { background: var(--ui-surface); }
.vehicle-milestones { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.vehicle-milestones i { padding: 7px 9px; border: 1px solid var(--ui-line-strong); border-radius: 999px; color: var(--ui-text-secondary); font-size: 7px; font-style: normal; font-weight: 500; text-transform: uppercase; }

.spotlight__actions { background: var(--ui-surface-soft); }
.spotlight__actions button { border-color: var(--ui-line-strong); color: var(--ui-text); }
.spotlight__nav { border-color: var(--ui-line); background: var(--ui-surface); }
.spotlight__nav button { border-color: var(--ui-line-strong); color: var(--ui-text); }

@media (max-width: 860px) {
  .mobile-sheet { color: var(--ui-text); }
  .spotlight { border-radius: 20px; }
  .vehicle-accordion > button { padding: 18px; }
  .vehicle-accordion__panel > div { padding: 0; }
  .vehicle-design > img { height: 205px; }
  .vehicle-history { grid-template-columns: 94px 1fr; }
  .vehicle-history__era { padding: 22px 12px; }
  .vehicle-section-lead,
  .vehicle-section-copy { padding: 22px 19px; }
  .vehicle-design .vehicle-detail-list { margin-right: -19px; margin-bottom: -22px; margin-left: -19px; }
}

/* Motion UX — une grammaire commune pour toute l’application */
:root {
  --motion-fast: 180ms;
  --motion-medium: 360ms;
  --motion-slow: 620ms;
  --motion-ease-out: cubic-bezier(.16, 1, .3, 1);
  --motion-ease-soft: cubic-bezier(.22, .61, .36, 1);
}

html { scroll-behavior: smooth; }

.panel,
.spotlight__scroll,
.mobile-content,
.story-copy { scroll-behavior: smooth; }

.vehicle-accordion {
  scroll-margin-top: 14px;
  transition: background-color var(--motion-medium) ease, border-color var(--motion-medium) ease;
}

.vehicle-accordion > button {
  position: relative;
  transition: background-color var(--motion-medium) ease, color var(--motion-medium) ease;
}

.vehicle-accordion > button::after {
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: var(--red);
  transform: scaleY(0);
  transform-origin: center;
  transition: transform var(--motion-medium) var(--motion-ease-out);
  content: "";
}

.vehicle-accordion > button:hover { background: color-mix(in srgb, var(--red) 3%, transparent); }
.vehicle-accordion.is-open > button::after { transform: scaleY(1); }
.vehicle-accordion > button > i { transition: transform var(--motion-medium) var(--motion-ease-out), color var(--motion-fast) ease; }
.vehicle-accordion.is-open > button > i { color: var(--red); transform: rotate(90deg); }

.vehicle-accordion__panel {
  display: grid;
  grid-template-rows: 0fr;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    grid-template-rows 520ms var(--motion-ease-out),
    opacity 260ms ease,
    visibility 0s linear 520ms;
}

.vehicle-accordion.is-open .vehicle-accordion__panel {
  grid-template-rows: 1fr;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition:
    grid-template-rows 560ms var(--motion-ease-out),
    opacity 340ms ease 90ms,
    visibility 0s linear 0s;
}

.vehicle-accordion__panel > div {
  min-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 260ms ease, transform 420ms var(--motion-ease-out);
}

.vehicle-accordion.is-open .vehicle-accordion__panel > div {
  opacity: 1;
  transform: none;
  transition-delay: 110ms;
}

.vehicle-accordion.is-motion-active > button { background: color-mix(in srgb, var(--red) 4%, var(--ui-surface)); }

.filter-drawer,
.filter-drawer.is-open {
  display: grid;
  overflow: hidden;
  transition:
    max-height var(--motion-medium) var(--motion-ease-out),
    opacity 240ms ease,
    transform var(--motion-medium) var(--motion-ease-out),
    padding var(--motion-medium) var(--motion-ease-out),
    visibility 0s linear var(--motion-medium);
}

.filter-drawer {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  pointer-events: none;
}

.filter-drawer.is-open {
  max-height: 180px;
  padding-top: 9px;
  padding-bottom: 1px;
  opacity: 1;
  visibility: visible;
  transform: none;
  pointer-events: auto;
  transition-delay: 0s;
}

.model-card__media img,
.legend-strip img,
.era-feature > img { transition: transform var(--motion-slow) var(--motion-ease-out), filter var(--motion-medium) ease; }
.model-card:hover .model-card__media img,
.legend-strip button:hover img { transform: scale(1.025); }
.model-card__open { transition: color var(--motion-fast) ease, border-color var(--motion-fast) ease, transform var(--motion-medium) var(--motion-ease-out); }
.model-card:hover .model-card__open { border-color: var(--red); color: var(--red); transform: translateX(3px); }

.tab,
.mobile-tabs button,
.catalog-tabs button,
.mobile-catalog-tabs button,
.intent-grid button,
.era-rail button,
.story-navigation button,
.spotlight__nav button,
.spotlight__actions button,
.atelier-final-cta a {
  transition:
    color var(--motion-fast) ease,
    background-color var(--motion-medium) ease,
    border-color var(--motion-fast) ease,
    transform var(--motion-fast) var(--motion-ease-out),
    box-shadow var(--motion-medium) ease;
}

.tab:active,
.mobile-tabs button:active,
.catalog-tabs button:active,
.intent-grid button:active,
.era-rail button:active,
.story-navigation button:active,
.spotlight__nav button:active,
.spotlight__actions button:active { transform: scale(.975); }

.era-feature > img { animation: motion-media-enter 560ms var(--motion-ease-out) both; }
.era-feature > div { animation: motion-copy-enter 480ms var(--motion-ease-out) 60ms both; }
.panel.is-active .panel-heading { animation: motion-copy-enter 480ms var(--motion-ease-out) both; }
.panel.is-active .model-card { animation: motion-card-enter 520ms var(--motion-ease-out) both; animation-delay: var(--delay, 0ms); }

.spotlight.is-model-entering .spotlight__car { animation: spotlight-media-enter 620ms var(--motion-ease-out) both; }
.spotlight.is-model-entering .spotlight__copy > * { animation: motion-copy-enter 520ms var(--motion-ease-out) both; }
.spotlight.is-model-entering .spotlight__copy > :nth-child(2) { animation-delay: 45ms; }
.spotlight.is-model-entering .spotlight__copy > :nth-child(3) { animation-delay: 90ms; }
.spotlight.is-model-entering .spotlight__copy > :nth-child(4) { animation-delay: 135ms; }
.spotlight.is-model-entering .vehicle-accordion { animation: motion-card-enter 460ms var(--motion-ease-out) both; }
.spotlight.is-model-entering .vehicle-accordion:nth-child(2) { animation-delay: 45ms; }
.spotlight.is-model-entering .vehicle-accordion:nth-child(3) { animation-delay: 90ms; }
.spotlight.is-model-entering .vehicle-accordion:nth-child(4) { animation-delay: 135ms; }

dialog[open]::backdrop { animation: motion-backdrop-in 320ms ease both; }
dialog.is-closing { animation: motion-dialog-out 240ms cubic-bezier(.4, 0, 1, 1) both !important; }
dialog.is-closing::backdrop { animation: motion-backdrop-out 240ms ease both; }

@keyframes motion-card-enter {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

@keyframes motion-media-enter {
  from { opacity: .35; transform: scale(1.025); }
  to { opacity: 1; transform: none; }
}

@keyframes spotlight-media-enter {
  from { opacity: .35; transform: scale(1.075); }
  to { opacity: 1; transform: scale(1.05); }
}

@keyframes motion-copy-enter {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

@keyframes motion-backdrop-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes motion-backdrop-out { from { opacity: 1; } to { opacity: 0; } }
@keyframes motion-dialog-out {
  from { opacity: 1; transform: none; }
  to { opacity: 0; transform: translateY(10px) scale(.988); }
}

@media (prefers-reduced-motion: reduce) {
  html,
  .panel,
  .spotlight__scroll,
  .mobile-content,
  .story-copy { scroll-behavior: auto !important; }

  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-delay: 0ms !important;
    transition-duration: .01ms !important;
    transition-delay: 0ms !important;
  }
}

/* Ferrari official monochrome system — design-only pass */
:root {
  --color-pure-white: #ffffff;
  --color-pure-black: #000000;
  --color-carbon-black: #181818;
  --color-graphite: #303030;
  --color-steel-gray: #8f8f8f;
  --font-ferrari-custom-sans-serif: "Inter", "Helvetica Neue", Arial, sans-serif;
  --font-body-font: "Inter", "Helvetica Neue", Arial, sans-serif;
  --text-caption: 11px;
  --text-body-sm: 12px;
  --text-body: 13px;
  --leading-caption: 1.78;
  --leading-body-sm: 1.78;
  --leading-body: 1.78;
  --ferrari-track-wide: .091em;
  --ferrari-track-label: .083em;
  --ferrari-track-body: .018em;
  --ferrari-line-light: rgba(0, 0, 0, .18);
  --ferrari-line-dark: rgba(255, 255, 255, .18);
  --red: var(--color-pure-black);
  --red-dark: var(--color-carbon-black);
  --yellow: var(--color-pure-black);
  --paper: var(--color-pure-white);
  --paper-strong: var(--color-pure-white);
  --paper-soft: #f4f4f4;
  --text: var(--color-pure-black);
  --text-soft: var(--color-graphite);
  --hairline: var(--ferrari-line-light);
  --ui-canvas: var(--color-pure-white);
  --ui-surface: var(--color-pure-white);
  --ui-surface-soft: #f5f5f5;
  --ui-surface-muted: #eeeeee;
  --ui-text: var(--color-pure-black);
  --ui-text-secondary: var(--color-graphite);
  --ui-text-tertiary: var(--color-steel-gray);
  --ui-line: var(--ferrari-line-light);
  --ui-line-strong: rgba(0, 0, 0, .32);
  --ui-shadow: none;
  --shadow: none;
}

html[data-theme="dark"] {
  --red: var(--color-pure-white);
  --red-dark: var(--color-steel-gray);
  --yellow: var(--color-pure-white);
  --paper: var(--color-pure-black);
  --paper-strong: var(--color-carbon-black);
  --paper-soft: var(--color-carbon-black);
  --text: var(--color-pure-white);
  --text-soft: var(--color-steel-gray);
  --hairline: var(--ferrari-line-dark);
  --ui-canvas: var(--color-pure-black);
  --ui-surface: var(--color-carbon-black);
  --ui-surface-soft: var(--color-pure-black);
  --ui-surface-muted: var(--color-graphite);
  --ui-text: var(--color-pure-white);
  --ui-text-secondary: var(--color-steel-gray);
  --ui-text-tertiary: #6f6f6f;
  --ui-line: var(--ferrari-line-dark);
  --ui-line-strong: rgba(255, 255, 255, .32);
  --ui-shadow: none;
  --shadow: none;
}

html,
body,
button,
input,
select,
textarea {
  font-family: var(--font-ferrari-custom-sans-serif) !important;
  font-weight: 400 !important;
  letter-spacing: var(--ferrari-track-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

html[data-theme="light"] body,
body {
  background: var(--color-pure-black) !important;
  color: var(--ui-text);
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 1px solid currentColor !important;
  outline-offset: 4px;
  box-shadow: none !important;
}

body :is(h1, h2, h3, h4, h5, h6, strong, b, button, a, label, dt, dd, th) {
  font-family: var(--font-ferrari-custom-sans-serif) !important;
  font-weight: 400 !important;
}

body :is(.tab span, .eyebrow, .status-tag, .pill, .live-dot, .filter-toggle, .catalog-tabs button, .mobile-catalog-tabs button, .model-card__stat span, .panel-heading h1, .catalog-intro h2, .section-title h2, .model-card__copy h2, .model-card__copy h3, .vehicle-accordion__label strong, .vehicle-accordion__label small, .vehicle-section-copy span, .vehicle-section-lead span, .vehicle-section-copy h4, .atelier-section-heading h2, .atelier-model__copy h3, .atelier-final-cta a, .story-copy h2, .story-progress, .story-navigation span, .story-navigation strong, .config-embed__bar, .booking__shell h2, .contact-context, .contact-details span, .rail__footer button) {
  text-transform: uppercase;
}

body :is(.tab span, .eyebrow, .status-tag, .pill, .live-dot, .filter-toggle, .catalog-tabs button, .mobile-catalog-tabs button, .model-card__stat span, .vehicle-accordion__number, .vehicle-section-copy span, .vehicle-section-lead span, .atelier-section-heading > span, .story-progress, .story-navigation span, .config-embed__bar > div span, .rail__footer button, .contact-context span, .booking label, .concierge-card label) {
  letter-spacing: var(--ferrari-track-wide) !important;
}

body :is(.panel-heading h1, .catalog-intro h2, .section-title h2, .model-card__copy h2, .spotlight__copy h2, .vehicle-accordion__label strong, .vehicle-section-copy h4, .atelier-manifesto__copy h1, .atelier-section-heading h2, .atelier-model__copy h3, .story-copy h2, .booking__shell h2) {
  letter-spacing: .05em !important;
}

body :is(.panel-heading p:not(.eyebrow), .catalog-intro p, .model-card__copy p, .vehicle-section-copy p, .vehicle-section-lead p, .vehicle-prose p, .atelier-section-heading div > p:not(.eyebrow), .atelier-process > ol p, .story-copy #story-body p, .booking-intro, .concierge-card input, .concierge-card select, .concierge-card textarea, .booking input, .booking select) {
  line-height: 1.78 !important;
}

body :is(.eyebrow, .live-dot, .status-tag, .vehicle-accordion__number, .spotlight__section-label span, .spotlight__copy > p:first-child, .config-embed__bar > div span, .contact-context strong, .f40-loader__copy span, .craft-list span, .era-feature span, .legend-strip span, .atelier-section-heading > span, .atelier-model__copy > p, .atelier-final-cta p span, .story-insight span, .story-progress > span, .story-navigation i, .vehicle-performance i, .vehicle-facts i, .model-card__stat i, .contact-details i, .config-cta > i, .booking-success i, .tab.is-active i) {
  color: var(--ui-text) !important;
}

html[data-theme="dark"] body :is(.eyebrow, .live-dot, .status-tag, .vehicle-accordion__number, .spotlight__section-label span, .spotlight__copy > p:first-child, .config-embed__bar > div span, .contact-context strong, .f40-loader__copy span, .craft-list span, .era-feature span, .legend-strip span, .atelier-section-heading > span, .atelier-model__copy > p, .atelier-final-cta p span, .story-insight span, .story-progress > span, .story-navigation i, .vehicle-performance i, .vehicle-facts i, .model-card__stat i, .contact-details i, .config-cta > i, .booking-success i, .tab.is-active i) {
  color: var(--ui-text) !important;
}

:is(.rail, .spotlight, .mobile-sheet) {
  box-shadow: none !important;
}

.rail,
html[data-theme="light"] .rail {
  border-color: var(--ui-line-strong) !important;
  background: color-mix(in srgb, var(--ui-surface) 98%, transparent) !important;
  background-image: none !important;
  color: var(--ui-text) !important;
}

html[data-theme="dark"] .rail {
  background: color-mix(in srgb, var(--color-carbon-black) 98%, transparent) !important;
}

.tour__shade,
.f40-loader::before,
.story-visual::after,
.atelier-manifesto::after {
  background: none !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.atelier-manifesto::after {
  background: rgba(0, 0, 0, .56) !important;
}

.f40-loader__piece { filter: none !important; }
.f40-loader__scan { background: linear-gradient(90deg, transparent, rgba(255,255,255,.72), transparent) !important; }
.f40-loader__copy span,
.f40-loader__copy strong { color: var(--color-pure-white) !important; }
.f40-loader__copy i { background: var(--color-pure-white) !important; }

:is(.model-card, .editorial-card, .configurator, .era-feature, .legend-strip button, .intent-grid button, .concierge-card, .contact-details > *, .craft-list button, .era-rail button, .mobile-config, .mobile-era, .mobile-era-list button, .mobile-intents button, .catalog-tabs, .mobile-catalog-tabs, .catalog-search, .filter-toggle, .filter-drawer select, .empty-state, .choice-grid button, .config-summary, .config-summary div, .milestone-chips i, .booking__shell, .story-shell, .config-embed__shell, .config-embed__bar nav, .config-embed__bar > a, .mobile-tabs button, .atelier-manifesto, .atelier-model, .atelier-model__media > span, .atelier-final-cta, .story-insight, .story-milestones span, .vehicle-design, .vehicle-prose, .vehicle-fact-grid > div, .vehicle-milestones i, .tailor-made-detail__section, .tailor-made-detail__level, .contact-card) {
  border-radius: 0 !important;
  box-shadow: none !important;
}

:is(.model-card__media img, .editorial-card img, .era-feature > img, .legend-strip img, .atelier-manifesto > img, .atelier-model__media img, .spotlight__car, .vehicle-design img, .story-visual img, .contact-card, .heritage-hero img, .mobile-era img) {
  border-radius: 0 !important;
  box-shadow: none !important;
}

:is(.model-card, .editorial-card, .configurator, .era-feature, .legend-strip button, .intent-grid button, .concierge-card, .contact-details > *, .craft-list button, .era-rail button, .mobile-config, .mobile-era, .mobile-era-list button, .mobile-intents button, .atelier-model, .vehicle-design, .vehicle-prose, .vehicle-fact-grid > div, .vehicle-detail-section, .tailor-made-detail__section, .tailor-made-detail__level) {
  border-color: var(--ui-line) !important;
  background: var(--ui-surface) !important;
  color: var(--ui-text) !important;
}

html[data-theme="light"] :is(.catalog-tabs, .mobile-catalog-tabs, .catalog-search, .filter-toggle, .filter-drawer select, .choice-grid button, .concierge-card input, .concierge-card select, .concierge-card textarea, .booking input, .booking select) {
  background: var(--color-pure-white) !important;
  color: var(--color-pure-black) !important;
}

html[data-theme="dark"] :is(.catalog-tabs, .mobile-catalog-tabs, .catalog-search, .filter-toggle, .filter-drawer select, .choice-grid button, .concierge-card input, .concierge-card select, .concierge-card textarea, .booking input, .booking select) {
  background: var(--color-pure-black) !important;
  color: var(--color-pure-white) !important;
}

:is(.icon-button, .dialog-close, .theme-toggle, .model-card__open, .spotlight__nav button, .spotlight__actions button i, .config-embed__fullscreen, .config-embed__close, .booking-cta i, .button i, .atelier-final-cta a i, .config-cta > i, .story-navigation i) {
  border-radius: 9999px !important;
  border-color: currentColor !important;
  background: transparent !important;
  color: inherit !important;
  box-shadow: none !important;
}

:is(.icon-button, .dialog-close, .theme-toggle, .model-card__open, .spotlight__nav button, .spotlight__actions button i, .config-embed__fullscreen, .config-embed__close) {
  border-width: 1px !important;
}

:is(.icon-button:hover, .dialog-close:hover, .theme-toggle:hover, .model-card:hover .model-card__open, .spotlight__nav button:hover, .config-embed__fullscreen:hover, .config-embed__close:hover) {
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
  border-color: var(--ui-text) !important;
}

.tab::after,
.vehicle-accordion__number::after,
.model-card__copy h3::after,
.red-rule,
.atelier-section-heading > span::after,
.story-progress > i b,
.f40-loader__copy i {
  background: currentColor !important;
}

.tab::after {
  height: 1px !important;
  right: 14px !important;
  left: 14px !important;
}

.tab,
.mobile-tabs button,
.catalog-tabs button,
.mobile-catalog-tabs button,
.intent-grid button,
.era-rail button {
  color: var(--ui-text-secondary) !important;
  background: transparent !important;
}

:is(.tab.is-active, .tab:hover, .mobile-tabs button.is-active, .mobile-tabs button:hover, .catalog-tabs button.is-active, .catalog-tabs button:hover, .mobile-catalog-tabs button.is-active, .mobile-catalog-tabs button:hover, .intent-grid button.is-selected, .intent-grid button:hover, .era-rail button.is-active, .era-rail button:hover) {
  background: transparent !important;
  color: var(--ui-text) !important;
  border-color: var(--ui-text) !important;
}

.catalog-tabs button.is-active,
.mobile-catalog-tabs button.is-active,
.intent-grid button.is-selected,
.era-rail button.is-active {
  box-shadow: inset 0 -1px 0 currentColor !important;
}

.catalog-tabs button.is-active strong,
.mobile-catalog-tabs button.is-active strong {
  color: currentColor !important;
}

.pill,
.status-tag,
.spotlight__badges .pill,
.vehicle-facts span,
.story-milestones span,
.tailor-made-detail__chips i,
.atelier-model__media > span {
  border: 1px solid var(--ui-line-strong) !important;
  background: transparent !important;
  color: var(--ui-text) !important;
  border-radius: 9999px !important;
  backdrop-filter: none !important;
}

.tailor-made-detail__chips i[data-swatch]::before {
  background: transparent !important;
  border-color: currentColor !important;
}

.model-card {
  grid-template-columns: 58% 42%;
  border-color: var(--ui-line-strong) !important;
  background: var(--ui-surface) !important;
  transform: none !important;
}

.model-card:hover {
  transform: none !important;
  border-color: var(--ui-text) !important;
}

.model-card__media img {
  mix-blend-mode: normal !important;
  filter: saturate(.94) contrast(1.02);
}

.model-card__stats,
.model-card__stat {
  border-color: var(--ui-line) !important;
  background: transparent !important;
}

.model-card__copy h2 {
  font-size: 20px !important;
  line-height: 1.04 !important;
}

.model-card__copy h3,
.model-card__copy p,
.panel-heading p:not(.eyebrow),
.catalog-intro p,
.vehicle-accordion__label small,
.vehicle-section-copy p,
.vehicle-section-lead p,
.atelier-section-heading div > p:not(.eyebrow),
.atelier-process > ol p,
.story-copy #story-body p,
.booking-intro,
.contact-details > *,
.mobile-era p {
  color: var(--ui-text-secondary) !important;
}

.spotlight {
  border-color: var(--ui-line-strong) !important;
  background: var(--ui-surface) !important;
}

.spotlight::backdrop,
dialog[open]::backdrop {
  background: rgba(0, 0, 0, .72) !important;
  backdrop-filter: none !important;
}

.spotlight__shell,
.spotlight__header,
.spotlight__copy,
.spotlight__accordions,
.spotlight__nav {
  background: var(--ui-surface) !important;
  color: var(--ui-text) !important;
}

.spotlight__header {
  border-bottom: 1px solid var(--ui-text) !important;
}

.spotlight__scroll {
  background: var(--ui-surface) !important;
  scrollbar-color: var(--ui-text) transparent !important;
}

.spotlight__hero {
  background: var(--ui-surface) !important;
}

.spotlight__car {
  background: var(--ui-surface-soft) !important;
  mix-blend-mode: normal !important;
  transform: scale(1) !important;
}

.spotlight__copy h2 {
  letter-spacing: .065em !important;
}

.vehicle-accordion {
  border-color: var(--ui-line) !important;
}

.vehicle-accordion > button {
  background: transparent !important;
  color: var(--ui-text) !important;
}

.vehicle-accordion > button:hover,
.vehicle-accordion.is-motion-active > button {
  background: var(--ui-surface-soft) !important;
}

.vehicle-accordion > button:focus-visible {
  outline: 1px solid currentColor !important;
  outline-offset: -6px !important;
  box-shadow: none !important;
}

.vehicle-accordion__panel {
  background: var(--ui-surface-soft) !important;
}

.vehicle-performance,
.vehicle-performance > div,
.vehicle-design,
.vehicle-prose,
.vehicle-fact-grid,
.vehicle-fact-grid > div,
.vehicle-history,
.vehicle-milestones i {
  border-color: var(--ui-line) !important;
}

.vehicle-design img {
  clip-path: none !important;
}

.vehicle-section-copy,
.vehicle-section-lead {
  padding-inline: 22px !important;
}

.spotlight__actions {
  background: var(--ui-surface) !important;
}

.spotlight__actions button,
.spotlight__actions button:first-child,
.button,
.button--red,
.booking-cta,
.atelier-final-cta a,
.config-embed__bar > a,
.config-cta,
.filter-drawer button,
.empty-state button,
.section-title button,
.era-feature button,
.heritage-hero button,
.atelier-manifesto__copy button {
  border: 1px solid var(--ui-line-strong) !important;
  background: transparent !important;
  color: var(--ui-text) !important;
  box-shadow: none !important;
  border-radius: 9999px !important;
  letter-spacing: var(--ferrari-track-wide) !important;
  text-transform: uppercase !important;
}

:is(.spotlight__actions button, .button, .button--red, .booking-cta, .atelier-final-cta a, .config-embed__bar > a, .config-cta, .filter-drawer button, .empty-state button, .section-title button, .era-feature button, .heritage-hero button, .atelier-manifesto__copy button):hover {
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
  border-color: var(--ui-text) !important;
  transform: none !important;
}

.spotlight__actions button i,
.button i,
.booking-cta i,
.atelier-final-cta a i,
.config-cta > i {
  display: grid !important;
  width: 38px !important;
  height: 38px !important;
  place-items: center !important;
  border: 1px solid currentColor !important;
  border-radius: 9999px !important;
  background: transparent !important;
}

.config-cta small,
.config-cta small strong {
  color: inherit !important;
  letter-spacing: var(--ferrari-track-wide) !important;
}

.atelier-manifesto {
  background: var(--color-pure-black) !important;
}

.atelier-manifesto__copy h1,
.atelier-manifesto__copy > p:not(.eyebrow),
.atelier-manifesto__edition {
  color: var(--color-pure-white) !important;
}

.atelier-manifesto__copy button {
  color: var(--color-pure-white) !important;
  border-color: var(--color-pure-white) !important;
}

.atelier-model:hover {
  border-color: var(--ui-text) !important;
  transform: none !important;
  box-shadow: none !important;
}

.atelier-model:hover .atelier-model__media img,
.model-card:hover .model-card__media img,
.legend-strip button:hover img,
.era-feature > img {
  transform: none !important;
}

.atelier-final-cta {
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
}

.atelier-final-cta :is(p span, p strong, a) {
  color: inherit !important;
}

.atelier-final-cta a {
  border-color: color-mix(in srgb, currentColor 42%, transparent) !important;
}

.story-shell,
.booking__shell,
.config-embed__shell {
  background: var(--ui-surface) !important;
  color: var(--ui-text) !important;
}

.story-copy {
  background: var(--ui-surface) !important;
}

.story-lead,
.story-insight,
.story-navigation,
.story-navigation button,
.story-progress > i,
.booking input,
.booking select,
.concierge-card input,
.concierge-card select,
.concierge-card textarea {
  border-color: var(--ui-line) !important;
}

.story-insight {
  border-left-width: 1px !important;
  background: var(--ui-surface-soft) !important;
}

.story-navigation {
  background: var(--ui-surface) !important;
  backdrop-filter: none !important;
}

.story-navigation button:hover {
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
}

.story-navigation button:hover :is(span, strong, i) {
  color: var(--ui-surface) !important;
}

.config-embed__bar nav button.is-active {
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
}

.config-embed__loading i {
  color: var(--ui-text) !important;
}

.booking-success {
  background: var(--ui-surface) !important;
}

.inline-success,
.booking-success {
  color: var(--ui-text) !important;
}

.contact-card {
  background-image: none !important;
  background-color: var(--ui-surface) !important;
  color: var(--ui-text) !important;
}

.rail-launcher,
.tour-dock,
.drive-controls,
.config-cta {
  border-color: var(--ui-line-strong) !important;
  background: color-mix(in srgb, var(--ui-surface) 96%, transparent) !important;
  color: var(--ui-text) !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.tour-dock button.is-active {
  color: var(--ui-text) !important;
  font-weight: 400 !important;
  box-shadow: inset 0 -1px 0 currentColor;
}

.dock-brand img {
  filter: none !important;
}

html[data-theme="dark"] .dock-brand img,
html[data-theme="dark"] .brand-lockup .brand-wordmark,
html[data-theme="dark"] .mobile-brand > img,
html[data-theme="dark"] .rail-launcher img {
  filter: invert(1) grayscale(1) brightness(2.7) !important;
}

.brand-lockup span {
  color: var(--ui-text-secondary) !important;
  font-weight: 400 !important;
}

.mobile-sheet {
  border-color: var(--ui-line-strong) !important;
  background: color-mix(in srgb, var(--ui-surface) 98%, transparent) !important;
  color: var(--ui-text) !important;
}

.mobile-brand button:not(.theme-toggle) {
  border: 1px solid var(--ui-line-strong) !important;
  background: transparent !important;
  color: var(--ui-text) !important;
  border-radius: 9999px !important;
}

.mobile-tabs button.is-active {
  box-shadow: inset 0 -1px 0 currentColor !important;
}

:is(.tab, .mobile-tabs button, .catalog-tabs button, .mobile-catalog-tabs button, .era-rail button, .intent-grid button, .tailor-studio__tabs button):focus-visible {
  outline: 0 !important;
  box-shadow: inset 0 -1px 0 currentColor !important;
}

.sheet-handle span,
.tricolore i {
  background: var(--ui-text-secondary) !important;
}

.tricolore i:nth-child(2) {
  background: var(--ui-line-strong) !important;
}

@keyframes spotlight-media-enter {
  from { opacity: .35; transform: scale(1.015); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes motion-card-enter {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

@keyframes motion-copy-enter {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

@media (max-width: 860px) {
  .mobile-sheet {
    border-radius: 22px 22px 0 0 !important;
  }

  .mobile-models .model-card {
    border-radius: 0 !important;
  }

  .spotlight__copy h2 {
    letter-spacing: .045em !important;
  }

  .vehicle-design {
    grid-template-columns: 1fr !important;
  }

  .vehicle-design img {
    min-height: 220px !important;
    order: -1;
  }
}

/* Secondary surfaces and legacy components brought into the same Ferrari grammar */
:is(.official-config-card, .heritage-hero, .heritage-numbers, .feature-grid > *, .material-list, .service-list > *, .timeline-list, .inline-success, .toast, .mobile-config, .mobile-era, .mobile-era-list button, .mobile-intents button, .tailor-studio, .tailor-studio__tabs, .tailor-studio__tabs button, .tailor-universe, .tailor-universe__media, .tailor-palette, .tailor-made-detail__cta a) {
  border-radius: 0 !important;
  box-shadow: none !important;
  background: var(--ui-surface) !important;
  color: var(--ui-text) !important;
  border-color: var(--ui-line) !important;
}

:is(.official-config-card img, .heritage-hero img, .feature-grid img, .material-list img, .service-list img, .timeline-list img, .tailor-universe__media img, .mobile-config img, .mobile-era img) {
  border-radius: 0 !important;
  box-shadow: none !important;
}

:is(.official-config-card span, .official-config-card > i, .heritage-hero span, .milestone-chips i, .heritage-numbers strong, .intent-grid i, .feature-grid i, .material-list span, .service-list > * > i:first-child, .timeline-list strong, .contact-card > span, .catalog-intro p, .category-tag, .empty-state i, .tailor-studio__tabs button span, .tailor-universe__copy li::before, .tailor-palette i, .tailor-made-detail__section span, .tailor-made-detail__list li::before, .mobile-config span, .mobile-era > span, .mobile-era-list button span, .mobile-intents button.is-active) {
  color: var(--ui-text) !important;
}

:is(.official-config-card:hover, .tailor-made-detail__cta a:hover, .mobile-config > button:hover, .mobile-intents button:hover, .mobile-era-list button:hover) {
  border-color: var(--ui-text) !important;
  background: var(--ui-text) !important;
  color: var(--ui-surface) !important;
  transform: none !important;
  box-shadow: none !important;
}

.official-config-card:hover > i,
.tailor-made-detail__cta a:hover i,
.mobile-config > button:hover i,
.mobile-intents button:hover i,
.mobile-era-list button:hover span,
.mobile-era-list button:hover strong {
  color: var(--ui-surface) !important;
}

.mobile-config > button,
.mobile-intents button,
.mobile-era-list button,
.official-config-card,
.tailor-made-detail__cta a {
  border: 1px solid var(--ui-line-strong) !important;
  background: transparent !important;
  color: var(--ui-text) !important;
  text-transform: uppercase !important;
  letter-spacing: var(--ferrari-track-wide) !important;
}

.mobile-config > button {
  border-radius: 9999px !important;
}

.heritage-hero {
  overflow: hidden;
  border: 1px solid var(--ui-line) !important;
}

.heritage-hero button,
.mobile-config > button,
.tailor-made-detail__cta a {
  border-radius: 9999px !important;
}

.heritage-numbers {
  border-radius: 0 !important;
}

.heritage-numbers div,
.model-card__stat,
.contact-details > *,
.tailor-studio__tabs button {
  border-color: var(--ui-line) !important;
}

.live-dot::before {
  background: currentColor !important;
  box-shadow: none !important;
}

.inline-success {
  border: 1px solid var(--ui-line) !important;
  background: var(--ui-surface-soft) !important;
}

.inline-success i {
  color: var(--ui-text) !important;
}

.contact-card {
  box-shadow: none !important;
}

.contact-card,
.contact-card h2,
.contact-card p,
.contact-card a {
  color: var(--ui-text) !important;
}

.contact-card p {
  color: var(--ui-text-secondary) !important;
}

.consent input {
  accent-color: var(--ui-text) !important;
}

.tailor-universe__media > span {
  background: var(--color-pure-black) !important;
  color: var(--color-pure-white) !important;
  border-radius: 0 !important;
}

.tailor-palette i {
  background: transparent !important;
  border-color: currentColor !important;
}

.tailor-studio__tabs button.is-active,
.tailor-studio__tabs button:hover {
  background: transparent !important;
  color: var(--ui-text) !important;
  border-color: var(--ui-text) !important;
  box-shadow: inset 0 -1px 0 currentColor !important;
}

.tailor-studio__tabs button.is-active span {
  color: var(--ui-text) !important;
}

:is(.config-cta:hover, .official-config-card:hover, .atelier-manifesto__copy button:hover) {
  box-shadow: none !important;
}

:is(.story-shell, .booking__shell, .config-embed__shell) {
  border-radius: 0 !important;
}

:is(input, select, textarea, .catalog-search, .filter-toggle, .filter-drawer select, .concierge-card input, .concierge-card select, .concierge-card textarea, .booking input, .booking select) {
  border-radius: 0 !important;
  box-shadow: none !important;
}

html[data-theme="light"] :is(.rail-launcher, .tour-dock, .drive-controls, .config-cta) {
  background: rgba(255, 255, 255, .96) !important;
}

html[data-theme="dark"] :is(.rail-launcher, .tour-dock, .drive-controls, .config-cta) {
  background: rgba(24, 24, 24, .96) !important;
}

@media (max-width: 860px) {
  :is(.mobile-config, .mobile-era, .mobile-era-list button, .mobile-intents button) {
    border-radius: 0 !important;
  }
}

/* July 2026 usability polish: catalogue rhythm, readable cards and accessible stories */
.catalog-intro {
  padding: 50px 12px 42px !important;
  border-bottom: 1px solid var(--ui-line) !important;
}

.catalog-intro > .section-title {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 20px;
}

.catalog-intro .section-title > div {
  min-width: 0;
}

.catalog-intro .eyebrow {
  margin-bottom: 14px;
  font-size: 8px !important;
  line-height: 1.4 !important;
}

.catalog-intro .section-title h2 {
  max-width: 350px;
  margin: 0;
  font-size: clamp(25px, 2.15vw, 31px) !important;
  line-height: 1.12 !important;
  letter-spacing: .075em !important;
}

.catalog-intro .section-title > p {
  max-width: 350px;
  margin: 0;
  justify-self: start;
  color: var(--ui-text-secondary) !important;
  font-size: 10px !important;
  line-height: 1.78 !important;
  letter-spacing: .045em !important;
  text-transform: none !important;
}

.model-list {
  gap: 16px !important;
  padding-top: 18px !important;
  padding-bottom: 32px;
}

.model-card {
  grid-template-columns: minmax(0, 56%) minmax(0, 44%) !important;
}

.model-card__badges {
  top: 14px;
  left: 14px;
  flex-wrap: wrap;
  gap: 5px;
  max-width: calc(100% - 28px);
}

.model-card__badges .pill {
  min-height: 25px;
  gap: 5px;
  padding: 5px 8px !important;
  font-size: 6.5px !important;
  line-height: 1 !important;
  letter-spacing: .075em !important;
}

.model-card__badges .pill i {
  flex: 0 0 auto;
  font-size: 11px;
}

.model-card__copy {
  padding: 18px 17px 56px 14px !important;
}

.model-card__copy .status-tag {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  min-height: 23px;
  align-items: center;
  margin: 0 0 11px;
  padding: 5px 9px !important;
  font-size: 7px !important;
  line-height: 1 !important;
  letter-spacing: .095em !important;
  white-space: nowrap;
}

.model-card__copy h2 {
  margin-bottom: 6px !important;
  font-size: clamp(17px, 1.55vw, 20px) !important;
  line-height: 1.08 !important;
  letter-spacing: .035em !important;
  overflow-wrap: normal;
  word-break: normal;
}

.model-card__copy h3 {
  margin-bottom: 9px !important;
  font-size: 10px !important;
  line-height: 1.35 !important;
  letter-spacing: .07em !important;
}

.model-card__copy p {
  font-size: 8px !important;
  line-height: 1.62 !important;
}

.model-card__open {
  right: 15px;
  bottom: 59px;
}

.panel {
  scroll-padding-block: 18px 44px;
}

/* One continuous scroll surface: wheel and touch work over the image or the copy. */
.story-dialog {
  overflow: visible;
}

.story-shell {
  height: min(820px, calc(100dvh - 48px));
  max-height: calc(100dvh - 48px) !important;
  align-items: start;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--ui-text) transparent;
}

.story-visual {
  position: sticky !important;
  top: 0;
  height: min(820px, calc(100dvh - 48px));
  min-height: 0 !important;
  align-self: start;
}

.story-copy {
  min-height: min(820px, calc(100dvh - 48px));
  overflow: visible !important;
  padding-bottom: 0 !important;
}

.story-dialog .dialog-close {
  position: fixed !important;
  z-index: 10;
  top: max(44px, calc((100dvh - 820px) / 2 + 20px));
  right: max(44px, calc((100vw - 1220px) / 2 + 20px));
}

.story-navigation {
  bottom: 0;
}

/* Closed-showroom controls share one deliberate top grid. */
.rail-launcher,
.tour-dock,
.booking-cta {
  transition:
    top var(--motion-medium) var(--motion-ease-out),
    left var(--motion-medium) var(--motion-ease-out),
    right var(--motion-medium) var(--motion-ease-out),
    transform var(--motion-medium) var(--motion-ease-out),
    opacity var(--motion-fast) ease,
    background-color var(--motion-fast) ease,
    color var(--motion-fast) ease;
}

.app[data-rail="closed"] .rail-launcher {
  top: 28px;
  left: 28px;
  width: 186px;
  min-height: 58px;
  justify-content: space-between;
  padding: 0 18px;
}

.app[data-rail="closed"] .rail-launcher img {
  width: 118px;
}

.app[data-rail="closed"] .tour-dock {
  top: 28px;
  left: 50%;
  min-height: 58px;
  transform: translateX(-50%);
}

.app[data-rail="closed"] .booking-cta {
  top: 28px;
  right: 28px;
  min-width: 272px;
  min-height: 58px;
}

@media (max-width: 1180px) and (min-width: 861px) {
  .app[data-rail="closed"] .rail-launcher {
    width: 154px;
  }

  .app[data-rail="closed"] .rail-launcher img {
    width: 96px;
  }

  .app[data-rail="closed"] .tour-dock button {
    padding-inline: 9px;
  }

  .app[data-rail="closed"] .tour-dock button span {
    display: none;
  }

  .app[data-rail="closed"] .booking-cta {
    min-width: 218px;
  }
}

@media (max-width: 860px) {
  .catalog-intro {
    padding: 30px 2px 28px !important;
  }

  .catalog-intro > .section-title {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .catalog-intro .section-title > p {
    max-width: none;
    justify-self: start;
  }

  .model-card__copy {
    padding: 15px 14px 58px !important;
  }

  .model-card__copy .status-tag {
    margin-bottom: 9px;
  }

  .story-shell {
    display: block !important;
    height: calc(100dvh - 16px);
    max-height: calc(100dvh - 16px) !important;
  }

  .story-visual {
    position: relative !important;
    width: 100%;
    height: 31dvh;
  }

  .story-copy {
    min-height: 0;
    padding-bottom: 0 !important;
  }

  .story-dialog .dialog-close {
    top: 22px;
    right: 22px;
  }
}

/* Sold vehicles remain part of the editorial visit and lead to live dealer stock. */
.sold-stock-panel[hidden] {
  display: none !important;
}

.sold-stock-panel {
  color: var(--ui-text);
  background: var(--ui-surface);
  border: 1px solid var(--ui-line-strong);
}

.sold-stock-panel > span {
  color: var(--ui-text-secondary);
  font-size: 9px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.sold-stock-panel h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: .075em;
  text-transform: uppercase;
}

.sold-stock-panel p {
  margin: 0;
  color: var(--ui-text-secondary);
  font-size: 11px;
  line-height: 1.7;
  letter-spacing: .015em;
}

.sold-stock-panel button {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0;
  border: 0;
  border-top: 1px solid var(--ui-line);
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 9px;
  font-weight: 400;
  letter-spacing: .13em;
  text-align: left;
  text-transform: uppercase;
  cursor: pointer;
}

.sold-stock-panel button i {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 15px;
  transition: background-color var(--motion-fast) ease, color var(--motion-fast) ease;
}

.sold-stock-panel button:hover i,
.sold-stock-panel button:focus-visible i {
  background: var(--ui-text);
  color: var(--ui-surface);
}

.sold-stock-panel--floating {
  position: fixed;
  z-index: 18;
  top: 50%;
  right: 28px;
  display: grid;
  width: min(292px, calc(100vw - 56px));
  gap: 14px;
  padding: 22px 22px 12px;
  transform: translateY(-50%);
  animation: sold-panel-in .45s var(--motion-ease-out) both;
}

.sold-stock-panel--inline {
  display: none;
}

@keyframes sold-panel-in {
  from { opacity: 0; transform: translate3d(20px, -50%, 0); }
  to { opacity: 1; transform: translate3d(0, -50%, 0); }
}

.model-card.is-sold .status-tag,
.model-card.is-sold .model-card__badges .pill:first-child,
.spotlight__badges .pill:first-child {
  border-color: var(--ui-text) !important;
}

/* Live Ferrari Approved stock: separate from the model configurator. */
.stock-embed {
  width: min(1580px, calc(100vw - 32px));
  height: min(940px, calc(100dvh - 32px));
  max-width: none;
  max-height: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ui-text);
}

.stock-embed[open] {
  animation: dialog-in .42s var(--motion-ease-out) both;
}

.stock-embed::backdrop {
  background: rgba(0, 0, 0, .72);
}

.stock-embed__shell {
  border-radius: 0 !important;
}

.stock-embed__bar {
  grid-template-columns: minmax(220px, 1fr) auto 44px !important;
}

.stock-embed__bar > div span {
  color: var(--ui-text-secondary) !important;
}

.stock-embed__viewport iframe {
  background: #fff !important;
}

.stock-embed__loading {
  align-content: center;
  padding: 28px;
  text-align: center;
}

.stock-embed__loading > strong {
  color: var(--ui-text);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.stock-embed__loading > span {
  color: var(--ui-text-secondary);
  font-size: 9px;
  line-height: 1.7;
  letter-spacing: .08em;
}

.stock-embed__loading.is-fallback > i {
  display: none;
}

.stock-embed__fallback {
  display: grid;
  justify-items: center;
  gap: 16px;
  margin-top: 10px;
}

.stock-embed__fallback[hidden] {
  display: none;
}

.stock-embed__fallback p {
  margin: 0;
  color: var(--ui-text-secondary);
  font-size: 11px;
  letter-spacing: .01em;
  text-transform: none;
}

.stock-embed__fallback a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 12px;
  padding: 0 18px;
  border: 1px solid var(--ui-line-strong);
  border-radius: 9999px;
  color: var(--ui-text);
  font-size: 9px;
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: uppercase;
}

@media (max-width: 1180px) and (min-width: 861px) {
  .sold-stock-panel--floating {
    right: 20px;
    width: 244px;
    padding-inline: 18px;
  }

  .sold-stock-panel--floating h2 {
    font-size: 15px;
  }
}

@media (max-width: 860px) {
  .sold-stock-panel--floating {
    display: none !important;
  }

  .sold-stock-panel--inline:not([hidden]) {
    display: grid;
    gap: 14px;
    margin: 0;
    padding: 26px 20px 14px;
    border-width: 1px 0;
  }

  .sold-stock-panel--inline h2 {
    font-size: 20px;
  }

  .stock-embed {
    width: calc(100vw - 12px);
    height: calc(100dvh - 12px);
  }

  .stock-embed__bar {
    grid-template-columns: minmax(0, 1fr) 38px 38px !important;
    gap: 7px;
    min-height: 61px;
    padding: 8px 9px 8px 13px;
  }

  .stock-embed__bar > div strong {
    font-size: 13px !important;
  }

  .stock-embed__bar > a {
    display: grid !important;
    width: 36px;
    min-height: 36px;
    place-items: center;
    padding: 0 !important;
    font-size: 0 !important;
  }

  .stock-embed__bar > a i {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sold-stock-panel--floating {
    animation: none;
  }
}

/* Mobile focus tier: heritage story stays full-bleed */
@media (max-width: 860px) {
  html[data-sheet-state="focus"] .tour-dock,
  html[data-sheet-state="focus"] .booking-cta { display: none; }

  html[data-sheet-state="focus"] .story-dialog {
    inset: env(safe-area-inset-top, 0px) 0 0 0;
    margin: 0;
    width: auto;
    height: auto;
    max-width: none;
    max-height: none;
  }
  html[data-sheet-state="focus"] .story-shell {
    max-height: calc(100dvh - env(safe-area-inset-top, 0px));
    border-radius: 0;
  }
}

/* Mobile vehicle spotlight: opens as a draggable bottom sheet (half / full) */
@media (max-width: 860px) {
  .spotlight {
    inset: auto 0 0 0;
    margin: 0;
    width: auto;
    height: auto;
    max-width: none;
    max-height: none;
    border-radius: 24px 24px 0 0;
    overflow: hidden;
    transition: height .42s var(--ease);
  }
  .spotlight.is-dragging { transition: none; }
  html[data-spotlight="half"] .spotlight { height: 62dvh; }
  html[data-spotlight="full"] .spotlight { height: calc(100dvh - env(safe-area-inset-top, 0px)); border-radius: 0; }
  html[data-spotlight="full"] .tour-dock { display: none; }
  html[data-spotlight] .mobile-sheet { visibility: hidden; }
  html[data-spotlight] .booking-cta { display: none; }

  .spotlight__shell { position: relative; }
  .spotlight__grab {
    position: absolute;
    z-index: 6;
    top: 0;
    left: 50%;
    width: 160px;
    transform: translateX(-50%);
    display: grid;
    height: 26px;
    place-items: center;
    border: 0;
    background: transparent;
    cursor: grab;
    touch-action: none;
  }
  .spotlight__grab::before { content: ""; position: absolute; left: -20px; right: -20px; top: 0; height: 52px; }
  .spotlight__grab span { display: block; width: 52px; height: 5px; border-radius: 4px; background: rgba(0,0,0,.22); }
  html[data-theme="dark"] .spotlight__grab span { background: rgba(255,255,255,.32); }
  .spotlight__header { padding-top: 22px; }
  .spotlight__nav { min-height: 0; }
  .spotlight__footer { padding: 9px 14px calc(9px + env(safe-area-inset-bottom, 0px)); }
  .spotlight__actions { grid-template-columns: 1.14fr .86fr; gap: 8px; margin: 0; padding: 0; }
  .spotlight__actions button { min-height: 54px; padding: 0 12px 0 16px; font-size: 12px; font-weight: 600; letter-spacing: .03em; line-height: 1.16; gap: 8px; }
  .spotlight__actions button span { overflow: hidden; }
  .spotlight__actions button i { flex: none; width: 32px; height: 32px; font-size: 15px; }
}
