/* ToucheRide · classic car hire & chauffeur, London */

@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/cormorant-garamond.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/cormorant-garamond-italic.woff2") format("woff2");
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("../fonts/jost.woff2") format("woff2");
  font-weight: 300 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #0b101d;
  --ink-rgb: 11 16 29;
  --ivory: #f4efe6;
  --ivory-soft: rgb(244 239 230 / 0.86);
  --ivory-mute: rgb(244 239 230 / 0.68);
  --brass: #c9a96e;
  --brass-soft: rgb(201 169 110 / 0.45);
  --hair: rgb(244 239 230 / 0.18);

  --serif: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --sans: "Jost", "Futura", "Century Gothic", "Helvetica Neue", Arial, sans-serif;

  --gutter: clamp(1rem, 5.5vw, 6rem);
  --header-h: 4.75rem;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  color-scheme: dark;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--ivory);
  font-family: var(--sans);
  font-weight: 350;
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, ul { margin: 0; }

:focus-visible {
  outline: 1px solid var(--brass);
  outline-offset: 4px;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -4rem;
  z-index: 100;
  padding: 0.75rem 1rem;
  background: var(--ivory);
  color: var(--ink);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
}
.skip-link:focus { top: 1rem; }

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: env(safe-area-inset-top) var(--gutter) 0;
  border-bottom: 1px solid transparent;
  transition: background-color 0.5s var(--ease), border-color 0.5s var(--ease), backdrop-filter 0.5s var(--ease);
}
.site-header.is-scrolled {
  background: rgb(var(--ink-rgb) / 0.8);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom-color: var(--hair);
}

/* Wordmark: Touche in ivory, Ride in brass italic, LONDON centred beneath between fine rules */
.brand {
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
  text-decoration: none;
  color: var(--ivory);
}
.brand__name {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 2.3rem;
  line-height: 0.92;
  letter-spacing: 0.005em;
  white-space: nowrap;
  text-shadow: 0 2px 16px rgb(var(--ink-rgb) / 0.5);
}
.brand__name em {
  font-style: italic;
  font-weight: 500;
  color: var(--brass);
}
.brand__place {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.45rem;
  font-size: 0.6rem;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--brass);
  text-shadow: 0 1px 10px rgb(var(--ink-rgb) / 0.8);
}
.brand__place::before,
.brand__place::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--brass-soft);
}
/* tracking trails the last letter, so pad the left side to keep LONDON centred */
.brand__place::before { margin-right: 0.5em; }

.nav {
  display: flex;
  align-items: center;
  gap: clamp(1.25rem, 2.6vw, 2.5rem);
}
.nav__link {
  position: relative;
  padding: 0.4rem 0;
  font-size: 0.72rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ivory-soft);
  transition: color 0.3s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  background: var(--brass);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease);
}
.nav__link:hover,
.nav__link[aria-current="true"] { color: var(--ivory); }
.nav__link:hover::after,
.nav__link[aria-current="true"]::after { transform: scaleX(1); }

.nav__book {
  padding: 0.75rem 1.35rem;
  border: 1px solid var(--brass-soft);
  font-size: 0.72rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ivory);
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.nav__book:hover { background: var(--brass); border-color: var(--brass); color: var(--ink); }

.nav__call {
  display: none;
  width: 2.6rem;
  height: 2.6rem;
  place-items: center;
  border: 1px solid var(--hair);
  border-radius: 50%;
  color: var(--ivory);
}
.nav__call svg,
.btn svg {
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linejoin: round;
}

/* ---------- Panels: one photograph per section ---------- */

.panel {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: hidden;
}

/* The subject sits on the right of every photograph; --fx keeps it in frame when the crop narrows. */
.panel__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--fx, 65%) 50%;
}
.panel--hero       { --fx: 52%; --fx-m: 45%; --s1: 0.86; --s2: 0.66; }
.panel--occasions  { --fx: 88%; --fx-m: 90%; --s1: 0.9;  --s2: 0.8; --s3: 0.46; }
.panel--chauffeur  { --fx: 68%; --fx-m: 55%; --s1: 0.92; --s2: 0.8; }
.panel--collection { --fx: 74%; --fx-m: 50%; --s1: 0.9;  --s2: 0.74; }
.panel--book       { --fx: 72%; --fx-m: 50%; --s1: 0.92; --s2: 0.8; }

.panel__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgb(var(--ink-rgb) / 0.6) 0, rgb(var(--ink-rgb) / 0) 10rem),
    linear-gradient(0deg, rgb(var(--ink-rgb) / 0.55) 0, rgb(var(--ink-rgb) / 0) 32%),
    linear-gradient(90deg,
      rgb(var(--ink-rgb) / var(--s1)) 0%,
      rgb(var(--ink-rgb) / var(--s2)) 32%,
      rgb(var(--ink-rgb) / var(--s3, 0.3)) 56%,
      rgb(var(--ink-rgb) / 0) 74%);
}

.panel__inner {
  width: 100%;
  padding: calc(var(--header-h) + 3.5rem) var(--gutter) 5.5rem;
}
.panel__content { max-width: 35rem; }
.panel__content--wide { max-width: 40rem; }

/* ---------- Type ---------- */

.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 1.5rem;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--brass);
}
.eyebrow::before {
  content: "";
  flex: none;
  width: 2.5rem;
  height: 1px;
  background: currentColor;
}
.eyebrow .numeral {
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.08em;
}

h1 { font-weight: inherit; }
.nowrap { white-space: nowrap; }
h1 .eyebrow { margin-bottom: 1.5rem; }

.display {
  display: block;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(3.1rem, 7.2vw, 6.5rem);
  line-height: 0.98;
  letter-spacing: -0.012em;
  color: var(--ivory);
  text-wrap: balance;
}
.display em,
.title em {
  font-style: italic;
  color: var(--brass);
}

.title {
  margin-bottom: 1.35rem;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.5rem, 4.8vw, 4.4rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.lead {
  max-width: 31rem;
  margin-top: 1.5rem;
  font-size: clamp(1.05rem, 1.25vw, 1.2rem);
  line-height: 1.65;
  color: var(--ivory-soft);
  text-wrap: pretty;
}
.title + .lead { margin-top: 0; }

/* ---------- Buttons ---------- */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2.5rem;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 3.4rem;
  padding: 0 1.75rem;
  border: 1px solid transparent;
  font-size: 0.76rem;
  font-weight: 450;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.btn--primary { background: var(--brass); color: var(--ink); }
.btn--primary:hover { background: var(--ivory); }
.btn--ghost { border-color: rgb(244 239 230 / 0.42); color: var(--ivory); letter-spacing: 0.14em; }
.btn--ghost:hover { border-color: var(--brass); color: var(--brass); }

/* ---------- I. Hero ---------- */

.panel--hero .panel__bg { animation: settle 16s var(--ease) both; }
@keyframes settle {
  from { transform: scale(1.07); }
  to { transform: scale(1); }
}

.hero-in > * { animation: rise 1.2s var(--ease) both; }
.hero-in > :nth-child(1) { animation-name: lift; }
.hero-in > :nth-child(2) { animation-delay: 0.35s; }
.hero-in > :nth-child(3) { animation-delay: 0.5s; }
@keyframes rise {
  from { opacity: 0; transform: translateY(1.25rem); }
  to { opacity: 1; transform: none; }
}
@keyframes lift {
  from { transform: translateY(0.75rem); }
  to { transform: none; }
}

.hero__foot {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ivory-mute);
  animation: rise 1.2s var(--ease) 0.9s both;
}
.scroll-cue {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.scroll-cue::after {
  content: "";
  width: 1px;
  height: 2.75rem;
  background: linear-gradient(var(--brass), transparent);
  transform-origin: top;
  animation: cue 2.4s var(--ease) infinite;
}
@keyframes cue {
  0% { transform: scaleY(0); opacity: 1; }
  60% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; }
}

/* ---------- II. Occasions ---------- */

.occasions {
  list-style: none;
  padding: 0;
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.6rem 2.75rem;
}
.occasions li {
  padding-top: 1rem;
  border-top: 1px solid var(--hair);
}
.occasions h3 {
  margin-bottom: 0.3rem;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.5rem;
  line-height: 1.15;
}
.occasions p {
  font-size: 0.93rem;
  line-height: 1.55;
  color: var(--ivory-mute);
}

/* ---------- III. Chauffeur ---------- */

.principles {
  list-style: none;
  padding: 0;
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.75rem;
}
.principles li {
  padding-top: 1rem;
  border-top: 1px solid var(--hair);
}
.principles h3 {
  margin-bottom: 0.35rem;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.4rem;
  line-height: 1.15;
  color: var(--brass);
}
.principles p {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--ivory-mute);
}

.aside {
  max-width: 31rem;
  margin-top: 2.25rem;
  padding-left: 1.25rem;
  border-left: 1px solid var(--brass);
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--ivory-soft);
}
.aside strong {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.2rem;
  color: var(--ivory);
}

/* ---------- IV. Collection ---------- */

.list-label {
  margin-top: 2.5rem;
  margin-bottom: 1.1rem;
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--brass);
}
.included {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.85rem;
}
.included li {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1.05rem;
  color: var(--ivory-soft);
}
.included li::before {
  content: "";
  flex: none;
  width: 0.42rem;
  height: 0.42rem;
  border: 1px solid var(--brass);
  transform: rotate(45deg);
}

/* ---------- V. Reservations ---------- */

.panel--book { grid-template-rows: 1fr auto; }
.panel--book .panel__inner { align-self: center; padding-bottom: 3rem; }

.contact {
  max-width: 33rem;
  margin-top: 2.5rem;
  font-style: normal;
  border-top: 1px solid var(--hair);
}
.contact__row {
  display: grid;
  grid-template-columns: 7.5rem 1fr auto;
  align-items: center;
  gap: 1rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--hair);
  text-decoration: none;
  color: var(--ivory);
}
.contact__label {
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--brass);
}
.contact__value {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(1.45rem, 2.3vw, 2rem);
  line-height: 1.15;
  font-variant-numeric: lining-nums;
  overflow-wrap: anywhere;
  transition: color 0.3s var(--ease);
}
.contact__arrow {
  width: 1.4rem;
  height: 1.4rem;
  fill: none;
  stroke: var(--brass);
  stroke-width: 1.25;
  transition: transform 0.4s var(--ease);
}
.contact__row:hover .contact__value { color: var(--brass); }
.contact__row:hover .contact__arrow { transform: translateX(0.4rem); }

.contact-hint {
  max-width: 33rem;
  margin-top: 1.25rem;
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--ivory-mute);
}
.copy-btn {
  display: inline;
  margin-left: 0.35rem;
  padding: 0;
  border: 0;
  border-bottom: 1px solid var(--brass-soft);
  background: none;
  font: inherit;
  color: var(--ivory);
  cursor: pointer;
}
.copy-btn:hover { border-bottom-color: var(--brass); }

.site-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding: 1.5rem var(--gutter) calc(1.5rem + env(safe-area-inset-bottom));
  border-top: 1px solid var(--hair);
  background: rgb(var(--ink-rgb) / 0.55);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ivory-mute);
}
.site-footer a { text-decoration: none; color: var(--ivory-soft); }
.site-footer a:hover { color: var(--brass); }

/* ---------- Scroll reveal (enabled by main.js) ---------- */

.js .reveal > * {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
}
.js .reveal.is-in > * { opacity: 1; transform: none; }
.js .reveal > :nth-child(2) { transition-delay: 0.1s; }
.js .reveal > :nth-child(3) { transition-delay: 0.2s; }
.js .reveal > :nth-child(4) { transition-delay: 0.3s; }
.js .reveal > :nth-child(5) { transition-delay: 0.4s; }
.js .reveal > :nth-child(n + 6) { transition-delay: 0.5s; }

/* ---------- Medium screens ---------- */

@media (max-width: 1100px) {
  .panel__scrim {
    background:
      linear-gradient(180deg, rgb(var(--ink-rgb) / 0.6) 0, rgb(var(--ink-rgb) / 0) 10rem),
      linear-gradient(0deg, rgb(var(--ink-rgb) / 0.55) 0, rgb(var(--ink-rgb) / 0) 32%),
      linear-gradient(90deg,
        rgb(var(--ink-rgb) / var(--s1)) 0%,
        rgb(var(--ink-rgb) / var(--s2)) 42%,
        rgb(var(--ink-rgb) / var(--s3, 0.35)) 66%,
        rgb(var(--ink-rgb) / 0) 84%);
  }
  .principles { grid-template-columns: 1fr; gap: 1.1rem; }
}

/* ---------- Phones and portrait tablets: photograph on top, copy beneath ---------- */

@media (max-width: 760px), (max-width: 1100px) and (orientation: portrait) {
  .panel {
    display: block;
    min-height: 0;
  }
  .panel__bg {
    inset: 0 0 auto;
    height: 74vh;
    height: 74svh;
    object-position: var(--fx-m, 50%) 50%;
  }
  .panel__scrim {
    background: linear-gradient(180deg,
      rgb(var(--ink-rgb) / 0.55) 0,
      rgb(var(--ink-rgb) / 0) 6rem,
      rgb(var(--ink-rgb) / 0) 36vh,
      rgb(var(--ink-rgb) / 0.88) 60vh,
      var(--ink) 74vh);
    background: linear-gradient(180deg,
      rgb(var(--ink-rgb) / 0.55) 0,
      rgb(var(--ink-rgb) / 0) 6rem,
      rgb(var(--ink-rgb) / 0) 36svh,
      rgb(var(--ink-rgb) / 0.88) 60svh,
      var(--ink) 74svh);
  }
  .panel__inner {
    padding: 50vh var(--gutter) 4.5rem;
    padding: 50svh var(--gutter) 4.5rem;
  }

  .panel--hero {
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    align-items: flex-end;
  }
  .panel--hero .panel__bg { height: 100%; }
  .panel--hero .panel__scrim {
    background: linear-gradient(180deg,
      rgb(var(--ink-rgb) / 0.88) 0,
      rgb(var(--ink-rgb) / 0.6) 4.5rem,
      rgb(var(--ink-rgb) / 0) 9rem,
      rgb(var(--ink-rgb) / 0) 30%,
      rgb(var(--ink-rgb) / 0.82) 58%,
      rgb(var(--ink-rgb) / 0.96) 100%);
  }
  .panel--hero .panel__inner { padding-top: 0; padding-bottom: 2.75rem; }
  .hero__foot { display: none; }

  .panel--book { display: block; }
}

/* ---------- Phones ---------- */

@media (max-width: 760px) {
  :root { --header-h: 4rem; }

  .brand__name { font-size: 1.85rem; }
  .brand__place { margin-top: 0.35rem; font-size: 0.54rem; gap: 0.5rem; }
  .nav__link { display: none; }
  .nav { gap: 0.6rem; }
  .nav__call { display: grid; }
  .nav__book { padding: 0.7rem 1.1rem; }

  .eyebrow { margin-bottom: 1.1rem; letter-spacing: 0.26em; }
  h1 .eyebrow { font-size: 0.68rem; letter-spacing: 0.2em; }
  h1 .eyebrow::before { display: none; }
  .lead { margin-top: 1.1rem; }
  .actions { margin-top: 1.9rem; }
  .actions .btn { flex: 1 1 100%; justify-content: center; }

  .occasions { grid-template-columns: 1fr; gap: 1.1rem; margin-top: 2rem; }
  .occasions h3 { font-size: 1.35rem; }

  .contact__row {
    grid-template-columns: 1fr auto;
    gap: 0.3rem 1rem;
  }
  .contact__label { grid-column: 1; }
  .contact__value { grid-column: 1; }
  .contact__arrow { grid-column: 2; grid-row: 1 / span 2; }

  .site-footer { flex-direction: column; align-items: flex-start; letter-spacing: 0.12em; line-height: 1.7; }
}

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  .js .reveal > * { opacity: 1; transform: none; }
}

/* ---------- Not found page ---------- */

.panel--notfound { --fx: 74%; --s1: 0.92; --s2: 0.78; }
.panel--notfound .display { font-size: clamp(3rem, 5.8vw, 5.25rem); }
