/* ============================================================
   Solution Auto Garage Mecanique — Rufisque
   Composition: warm earth editorial · broadsheet columns
   ============================================================ */

:root {
  --bg: #f5efe4;
  --bg-soft: #efe6d6;
  --bg-deep: #e7dcc7;
  --ink: #2b1e14;
  --ink-soft: #5a4636;
  --ink-faint: #8a7663;
  --accent: #c25a37;
  --accent-deep: #9d4326;
  --secondary: #6a7a4a;
  --rule: rgba(43, 30, 20, 0.16);
  --rule-soft: rgba(43, 30, 20, 0.09);
  --warm-light: rgba(255, 214, 160, 0.55);
  --glow-y: 12%;
  --card: #fbf7ef;
  --shadow: 0 1px 2px rgba(43, 30, 20, 0.05), 0 12px 32px -18px rgba(43, 30, 20, 0.35);
  --serif: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
  --sans: 'DM Sans', 'Inter', system-ui, -apple-system, sans-serif;
  --wrap: 1180px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1a1410;
    --bg-soft: #221a14;
    --bg-deep: #2b211a;
    --ink: #f2e8da;
    --ink-soft: #c9b8a4;
    --ink-faint: #9b8874;
    --accent: #e07a52;
    --accent-deep: #f0956f;
    --secondary: #9aab74;
    --rule: rgba(242, 232, 218, 0.18);
    --rule-soft: rgba(242, 232, 218, 0.1);
    --warm-light: rgba(224, 122, 82, 0.22);
    --card: #241c16;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 14px 34px -18px rgba(0, 0, 0, 0.8);
  }
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Soft light source that drifts with scroll */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(
    circle 60vmax at 50% var(--glow-y),
    var(--warm-light) 0,
    transparent 62%
  );
  transition: background 0.4s linear;
}

body > * { position: relative; z-index: 1; }

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-deep); }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-wrap: balance;
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2.1rem, 6.2vw, 4.1rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.5rem); }
h3 { font-size: 1.22rem; }

p { margin: 0 0 1.1em; max-width: 68ch; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: clamp(1.15rem, 4vw, 2.5rem);
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--bg);
  padding: 0.7rem 1rem; z-index: 99;
}
.skip:focus { left: 0.5rem; top: 0.5rem; }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--secondary);
  margin: 0 0 0.9rem;
}

/* ---------- header ---------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule-soft);
}

.head-inner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding-block: 0.7rem;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--ink);
  margin-right: auto;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px; height: 42px;
  flex: 0 0 42px;
  background: var(--accent);
  color: #fff8ef;
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 700;
  border-radius: 3px;
}

.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-family: var(--serif); font-size: 1.06rem; font-weight: 700; }
.brand-text em {
  font-style: normal;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.site-nav {
  display: flex;
  gap: 1.15rem;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding-block: 0.35rem;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--accent); border-bottom-color: var(--accent); }

.call-btn {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.15;
  text-decoration: none;
  background: var(--ink);
  color: var(--bg);
  padding: 0.5rem 0.95rem;
  border-radius: 3px;
  min-height: 44px;
  justify-content: center;
}
.call-btn:hover { background: var(--accent); color: #fff8ef; }
.call-label {
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.75;
}
.call-num { font-family: var(--serif); font-size: 1rem; font-weight: 700; }

/* ---------- hero ---------- */

.hero {
  padding-block: clamp(2.5rem, 7vw, 5rem) clamp(2rem, 5vw, 3.5rem);
  border-bottom: 1px solid var(--rule);
}

.hero .wrap { max-width: 900px; }

.hero-title { position: relative; margin-bottom: 1.1rem; }

.hero-title .default,
.hero-title .alt {
  display: block;
  transition: opacity 0.45s ease;
}
.hero-title .alt {
  position: absolute;
  inset: 0;
  opacity: 0;
  color: var(--accent);
  pointer-events: none;
}
.hero-title:hover .default,
.hero-title:focus-within .default { opacity: 0; }
.hero-title:hover .alt,
.hero-title:focus-within .alt { opacity: 1; }

.hero-sub {
  font-size: clamp(1.05rem, 1.9vw, 1.24rem);
  color: var(--ink-soft);
  max-width: 60ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin: 1.6rem 0 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.75rem 1.4rem;
  border-radius: 3px;
  font-family: var(--sans);
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  border: 1.5px solid transparent;
}
.btn-primary { background: var(--accent); color: #fff8ef; }
.btn-primary:hover { background: var(--accent-deep); color: #fff8ef; }
.btn-ghost { border-color: var(--rule); color: var(--ink); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.hero-note {
  font-size: 0.88rem;
  color: var(--ink-faint);
  margin: 0;
}

.hero-figure {
  margin: clamp(2rem, 5vw, 3rem) auto 0;
  max-width: var(--wrap);
  padding-inline: clamp(1.15rem, 4vw, 2.5rem);
}
.hero-figure img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: var(--shadow);
}
.hero-figure figcaption {
  font-size: 0.82rem;
  color: var(--ink-faint);
  margin-top: 0.6rem;
  font-style: italic;
}

/* ---------- key figures band ---------- */

.band {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--rule-soft);
}
.band-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 1.5rem 2rem;
  padding-block: 1.9rem;
}
.band-item strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.5rem;
  color: var(--accent);
  line-height: 1.2;
}
.band-item span {
  display: block;
  font-size: 0.86rem;
  color: var(--ink-soft);
  margin-top: 0.2rem;
}

/* ---------- generic sections ---------- */

.section { padding-block: clamp(3rem, 7vw, 5.5rem); }
.section-alt { background: var(--bg-soft); border-block: 1px solid var(--rule-soft); }

.section .lede {
  font-size: 1.1rem;
  color: var(--ink-soft);
  max-width: 62ch;
  margin-bottom: 2.4rem;
}

/* ---------- service cards ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.6rem;
}

.card {
  background: var(--card);
  border: 1px solid var(--rule-soft);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
}
.card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}
.card h3 { margin: 1.15rem 1.25rem 0.5rem; }
.card p {
  margin: 0 1.25rem 0.9rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.card .meta {
  margin-top: auto;
  padding: 0.85rem 1.25rem 1.15rem;
  border-top: 1px solid var(--rule-soft);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--secondary);
  letter-spacing: 0.01em;
}

/* ---------- broadsheet article ---------- */

.broadsheet {
  column-count: 3;
  column-gap: 3rem;
  column-rule: 1px solid var(--rule-soft);
  margin-bottom: 3rem;
}
.broadsheet p {
  max-width: none;
  font-size: 1rem;
  color: var(--ink-soft);
  break-inside: avoid-column;
}
.broadsheet .dropcap::first-letter {
  float: left;
  font-family: var(--serif);
  font-size: 3.6rem;
  line-height: 0.82;
  font-weight: 700;
  color: var(--accent);
  padding: 0.1em 0.12em 0 0;
}

.atelier-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}
.atelier-grid figure { margin: 0; }
.atelier-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 4px;
}
.atelier-grid figcaption {
  font-size: 0.84rem;
  color: var(--ink-faint);
  margin-top: 0.55rem;
}

/* ---------- zone ---------- */

.zone-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}
.zone-col h3 {
  font-size: 1.05rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
  margin-bottom: 1rem;
}
.zone-list { list-style: none; margin: 0; padding: 0; }
.zone-list li {
  padding: 0.5rem 0 0.5rem 1.4rem;
  position: relative;
  font-size: 0.95rem;
  color: var(--ink-soft);
  border-bottom: 1px solid var(--rule-soft);
}
.zone-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 1.05em;
  width: 7px; height: 7px;
  background: var(--secondary);
  border-radius: 50%;
}
.zone-note p { font-size: 0.95rem; color: var(--ink-soft); }
.zone-phone {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 700;
  margin-top: 1.2rem;
}
.zone-phone a { text-decoration: none; }

/* ---------- hours ---------- */

.hours-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(280px, 1.15fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}

.hours-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--rule-soft);
  border-radius: 4px;
  overflow: hidden;
}
.hours-table th, .hours-table td {
  text-align: left;
  padding: 0.72rem 1.1rem;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 0.95rem;
}
.hours-table th { font-weight: 500; color: var(--ink-soft); }
.hours-table td { text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; }
.hours-table tr:last-child th, .hours-table tr:last-child td { border-bottom: 0; }
.hours-table .closed td { color: var(--accent); }
.hours-table .closed th { color: var(--ink-faint); }

.hours-side h3 { margin-bottom: 0.7rem; }
.hours-side p { font-size: 0.96rem; color: var(--ink-soft); }
.hours-warn {
  border-left: 3px solid var(--accent);
  padding-left: 1rem;
  font-weight: 500;
  color: var(--ink) !important;
}

/* ---------- contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1.6rem;
}
.contact-card {
  background: var(--card);
  border: 1px solid var(--rule-soft);
  border-radius: 4px;
  padding: 1.6rem 1.5rem;
  box-shadow: var(--shadow);
}
.contact-card h3 { margin-bottom: 0.8rem; }
.contact-card p { font-size: 0.94rem; color: var(--ink-soft); margin-bottom: 0.7rem; }
.contact-card p:last-child { margin-bottom: 0; }
.contact-primary { border-top: 4px solid var(--accent); }

.big-phone {
  display: block;
  font-family: var(--serif);
  font-size: clamp(1.7rem, 4vw, 2.2rem);
  font-weight: 700;
  text-decoration: none;
  line-height: 1.2;
  margin-bottom: 0.6rem;
}

address { font-style: normal; font-size: 0.98rem; line-height: 1.65; margin-bottom: 0.8rem; }

.map-link { font-size: 0.9rem; font-weight: 700; text-decoration: none; }

.checklist { list-style: none; margin: 0 0 0.9rem; padding: 0; }
.checklist li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.45rem;
  font-size: 0.93rem;
  color: var(--ink-soft);
}
.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--secondary);
  font-weight: 700;
}
.small { font-size: 0.85rem !important; color: var(--ink-faint) !important; }

/* ---------- closing ---------- */

.closing {
  background: var(--bg-deep);
  border-top: 1px solid var(--rule);
  padding-block: clamp(2.8rem, 6vw, 4.5rem);
  text-align: center;
}
.closing .wrap { max-width: 760px; }
.closing-line {
  font-family: var(--serif);
  font-size: clamp(1.35rem, 3.4vw, 2.1rem);
  font-style: italic;
  line-height: 1.35;
  margin: 0 auto 0.8rem;
  max-width: 30ch;
}
.closing-sub {
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 1.8rem;
}

/* ---------- footer ---------- */

.site-foot {
  background: var(--ink);
  color: var(--bg);
  padding-block: 2.6rem 1.4rem;
}
.site-foot a { color: var(--bg); }
.site-foot a:hover { color: var(--accent); }

.foot-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 3rem;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 1.6rem;
  border-bottom: 1px solid rgba(245, 239, 228, 0.18);
}
.foot-brand strong { font-family: var(--serif); font-size: 1.1rem; display: block; margin-bottom: 0.4rem; }
.foot-brand p { font-size: 0.88rem; margin: 0 0 0.25rem; opacity: 0.82; max-width: 40ch; }

.foot-nav { display: flex; flex-wrap: wrap; gap: 0.6rem 1.3rem; }
.foot-nav a { font-size: 0.88rem; text-decoration: none; opacity: 0.85; }
.foot-nav a:hover { opacity: 1; }

.foot-claim { padding-top: 1.2rem; }

.claim-banner {
  display: inline-block;
  font-size: 0.78rem;
  padding: 0.4rem 0.75rem;
  border-radius: 3px;
  background: rgba(245, 239, 228, 0.1);
  color: rgba(245, 239, 228, 0.85) !important;
  text-decoration: none;
  border: 1px solid rgba(245, 239, 228, 0.16);
}
.claim-banner:hover {
  background: rgba(245, 239, 228, 0.18);
  color: var(--bg) !important;
}

.foot-attr { padding-top: 0.9rem; }
.attribution {
  position: static;
  margin: 0;
  font-size: 0.72rem;
  opacity: 0.55;
  font-family: var(--sans);
}
.attribution a { color: inherit; }

/* ---------- page-load orchestration ---------- */

@keyframes riseIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-14px); }
  to { opacity: 1; transform: none; }
}
@keyframes typeIn {
  from { opacity: 0; clip-path: inset(0 100% 0 0); }
  to { opacity: 1; clip-path: inset(0 0 0 0); }
}

.site-head { animation: slideDown 0.6s cubic-bezier(0.2, 0.7, 0.3, 1) both; }

.reveal { animation: riseIn 0.7s cubic-bezier(0.2, 0.7, 0.3, 1) both; }
.hero-title.reveal { animation: typeIn 1.1s steps(38, end) 0.15s both; }
.d1 { animation-delay: 0.06s; }
.d2 { animation-delay: 0.18s; }
.d3 { animation-delay: 0.30s; }
.d4 { animation-delay: 0.42s; }
.d5 { animation-delay: 0.54s; }

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .broadsheet { column-count: 2; column-gap: 2rem; }
  .hours-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .site-nav { display: none; }
  .head-inner { gap: 0.75rem; }
  .brand-text em { display: none; }
}

@media (max-width: 620px) {
  .broadsheet { column-count: 1; column-rule: none; }
  .hero-title .alt { position: static; opacity: 0; display: none; }
  .hero-title:hover .default { opacity: 1; }
  .call-btn { padding: 0.45rem 0.7rem; }
  .call-num { font-size: 0.9rem; }
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal, .site-head, .hero-title.reveal { opacity: 1; transform: none; clip-path: none; }
  body::before { transition: none; }
}
