/* MP Driving School — main stylesheet */

:root {
  --navy: #1b2a6b;
  --navy-dark: #111c4d;
  --red: #d7262e;
  --red-dark: #b51d24;
  --yellow: #ffd200;
  --ink: #1d2433;
  --muted: #5b6475;
  --line: #e3e7ef;
  --bg: #ffffff;
  --bg-soft: #f4f6fb;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(17, 28, 77, .08);
  --font-head: "Outfit", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--navy); text-underline-offset: 3px; }
a:hover { color: var(--red); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.15;
  color: var(--navy-dark);
  margin: 0 0 .6em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.25rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }
p { margin: 0 0 1em; }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding-inline: 20px; }

.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-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 8px;
}
.skip-link:focus { top: 12px; }

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

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

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font-family: var(--font-head); font-weight: 700; font-size: 1rem;
  padding: .8em 1.4em; border-radius: 999px; border: 2px solid transparent;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, color .15s, border-color .15s, transform .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); color: #fff; }
.btn-accent { background: var(--yellow); color: var(--navy-dark); }
.btn-accent:hover { background: #fff; color: var(--navy-dark); }
.btn-outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn-ghost { border-color: rgba(255,255,255,.5); color: #fff; }
.btn-ghost:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,.1); }
.btn-lg { font-size: 1.125rem; padding: .9em 1.7em; }
.btn-block { width: 100%; }

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

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96);
  backdrop-filter: saturate(1.5) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 20px; min-height: 68px; }

.brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-weight: 800; font-size: 1.15rem;
  color: var(--navy-dark); text-decoration: none; margin-right: auto;
}
.brand img { width: 50px; height: auto; }
.brand:hover { color: var(--navy-dark); }
.brand span, .site-nav a { white-space: nowrap; }

/* Desktop: logo hangs below the header on a white tab, shrinks back when scrolling */
@media (min-width: 901px) {
  .site-header .brand { align-self: flex-start; height: 68px; }
  .site-header .brand img {
    align-self: flex-start; box-sizing: content-box; width: 92px;
    padding: 10px 12px 12px; background: #fff; border-radius: 0 0 16px 16px;
    box-shadow: 0 10px 24px rgba(17, 28, 77, .18);
    transition: width .2s, padding .2s, box-shadow .2s, margin .2s;
  }
  .site-header.is-scrolled .brand img {
    width: 50px; padding: 0; margin-top: 14px; box-shadow: none; border-radius: 0;
  }
}

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.site-nav a {
  display: block; padding: 8px 12px; border-radius: 8px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: .98rem;
}
.site-nav a:hover { background: var(--bg-soft); color: var(--navy); }
.site-nav a[aria-current="page"] { color: var(--red); }

.header-call { padding: .6em 1.1em; font-size: .95rem; }

.nav-toggle {
  display: none; width: 44px; height: 44px; border: 0; background: transparent;
  border-radius: 8px; cursor: pointer; position: relative;
}
.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  position: absolute; left: 11px; width: 22px; height: 2.5px; border-radius: 2px;
  background: var(--navy-dark); content: ""; transition: transform .2s, opacity .2s;
}
.nav-toggle-bars { top: 21px; }
.nav-toggle-bars::before { left: 0; top: -7px; }
.nav-toggle-bars::after { left: 0; top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1060px) {
  .header-call { display: none; }
}

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; padding: 8px 12px 16px; }
  .site-nav a { padding: 12px; font-size: 1.05rem; }
}

/* ---------- Hero ---------- */

.hero {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(255,210,0,.18), transparent 60%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-dark) 100%);
  color: #fff;
  overflow: hidden;
}
.hero-inner {
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center;
  padding-block: 64px 72px;
}
.hero h1 { color: #fff; }
.hero h1 .hl { color: var(--yellow); }
.hero-lead { font-size: 1.2rem; color: rgba(255,255,255,.88); max-width: 34em; }
.hero-price {
  display: inline-flex; align-items: baseline; gap: .4em;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2);
  padding: .45em 1em; border-radius: 999px; margin-bottom: 1.4em; font-weight: 600;
}
.hero-price strong { font-family: var(--font-head); font-size: 1.5rem; color: var(--yellow); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.hero-points { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px 22px; color: rgba(255,255,255,.9); font-size: .98rem; }
.hero-points li::before { content: "✓"; color: var(--yellow); font-weight: 800; margin-right: .45em; }

.hero-photo { position: relative; margin: 0; }
.hero-photo img {
  border-radius: 20px; box-shadow: 0 20px 50px rgba(0,0,0,.35);
  aspect-ratio: 4 / 3.4; object-fit: cover; width: 100%;
}
.hero-photo figcaption {
  position: absolute; left: -18px; bottom: 22px;
  background: var(--yellow); color: var(--navy-dark);
  font-family: var(--font-head); font-weight: 800; font-size: 1.05rem;
  padding: .55em 1em; border-radius: 12px; box-shadow: var(--shadow);
}

.hero-car img {
  border-radius: 0; box-shadow: none; aspect-ratio: auto; object-fit: contain;
  filter: drop-shadow(0 24px 30px rgba(0,0,0,.35));
}
.hero-car { margin-right: -40px; }
.hero-car figcaption { position: static; display: inline-block; margin-top: 8px; }
.hero-inner:has(.hero-car) { grid-template-columns: 1fr 1.05fr; }
@media (max-width: 700px) { .hero-car { display: none; } }
@media (max-width: 860px) { .hero-car { margin: 0 auto; max-width: 480px; } .hero-inner:has(.hero-car) { grid-template-columns: 1fr; } }

.car-showcase {
  background: radial-gradient(ellipse at 50% 40%, #2a3d8f 0%, var(--navy) 55%, var(--navy-dark) 100%);
  border-radius: 18px; padding: 28px 24px 20px; margin-bottom: 1.5em;
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; padding-block: 40px 48px; gap: 32px; }
  .hero-photo figcaption { left: 12px; }
}

/* ---------- Sections ---------- */

.section { padding-block: 72px; }
.section-soft { background: var(--bg-soft); }
.section-head { max-width: 720px; margin-bottom: 36px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.eyebrow {
  display: inline-block; font-family: var(--font-head); font-weight: 700;
  font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; color: var(--red);
  margin-bottom: .6em;
}

@media (max-width: 700px) { .section { padding-block: 52px; } }

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid-3 { grid-template-columns: 1fr; } }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; box-shadow: var(--shadow);
}
.card h3 { margin-bottom: .4em; }
.card p { color: var(--muted); margin-bottom: 0; }
a.card { display: block; text-decoration: none; color: inherit; transition: transform .15s, border-color .15s; }
a.card:hover { transform: translateY(-3px); border-color: var(--navy); }
a.card .more { display: inline-block; margin-top: 14px; font-weight: 700; color: var(--red); }

.icon {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: var(--bg-soft); color: var(--navy); margin-bottom: 16px; font-size: 1.4rem;
}

/* ---------- Prices ---------- */

.price-card { text-align: center; position: relative; display: flex; flex-direction: column; }
.price-card .hours { font-family: var(--font-head); font-weight: 700; color: var(--muted); font-size: 1.05rem; }
.price-card .amount { font-family: var(--font-head); font-weight: 800; font-size: 2.6rem; color: var(--navy-dark); line-height: 1.1; margin: .15em 0; }
.price-card .per { color: var(--muted); }
.price-card.featured { border: 2px solid var(--red); }
.price-card .tag {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--red); color: #fff; font-size: .8rem; font-weight: 700;
  padding: 3px 12px; border-radius: 999px; white-space: nowrap;
}

.price-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.price-table th, .price-table td { padding: 16px 20px; text-align: left; border-bottom: 1px solid var(--line); }
.price-table th { background: var(--navy); color: #fff; font-family: var(--font-head); font-weight: 700; }
.price-table tr:last-child td { border-bottom: 0; }
.price-table td:last-child, .price-table th:last-child { text-align: right; }
.price-table td strong { font-family: var(--font-head); font-size: 1.15rem; color: var(--navy-dark); }
.table-scroll { overflow-x: auto; border-radius: var(--radius); }

.note { font-size: .95rem; color: var(--muted); }

/* ---------- Gallery ---------- */

.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
@media (max-width: 700px) { .gallery { grid-template-columns: repeat(2, 1fr); gap: 8px; } }
.gallery button {
  padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 12px; overflow: hidden;
  aspect-ratio: 1; display: block;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.gallery button:hover img { transform: scale(1.04); }

.lightbox {
  border: 0; padding: 0; background: transparent; max-width: min(92vw, 900px); max-height: 92vh;
}
.lightbox::backdrop { background: rgba(10, 14, 30, .88); }
.lightbox img { max-height: 86vh; width: auto; margin: 0 auto; border-radius: 12px; }
.lightbox-close {
  position: fixed; top: 16px; right: 16px; width: 48px; height: 48px; border-radius: 50%;
  border: 0; background: #fff; color: var(--navy-dark); font-size: 1.6rem; line-height: 1; cursor: pointer;
}

/* ---------- Chips / lists ---------- */

.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.chips li {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 16px; font-weight: 600; color: var(--navy-dark);
}

.ticks { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 10px; }
.ticks li { padding-left: 32px; position: relative; }
.ticks li::before {
  content: "✓"; position: absolute; left: 0; top: .1em; width: 22px; height: 22px; border-radius: 50%;
  background: var(--yellow); color: var(--navy-dark); font-weight: 800; font-size: .8rem;
  display: grid; place-items: center;
}
.ticks.cols { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.ticks.why-list { grid-template-columns: repeat(2, 1fr); max-width: 820px; margin-inline: auto; margin-bottom: 32px; column-gap: 40px; }

/* ---------- Split / content pages ---------- */

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split img { border-radius: 18px; box-shadow: var(--shadow); }
@media (max-width: 640px) { .ticks.why-list { grid-template-columns: 1fr; } }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 28px; } }

.page-hero { background: linear-gradient(160deg, var(--navy) 0%, var(--navy-dark) 100%); color: #fff; padding-block: 52px 56px; }
.page-hero h1 { color: #fff; margin-bottom: .3em; }
.page-hero p { color: rgba(255,255,255,.88); font-size: 1.15rem; max-width: 40em; margin: 0; }

.page-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; padding-block: 56px 72px; }
.page-body .prose { max-width: 720px; }
.prose h2 { font-size: 1.6rem; margin-top: 1.6em; }
.prose h2:first-child { margin-top: 0; }
@media (max-width: 900px) { .page-body { grid-template-columns: 1fr; gap: 36px; } }

.aside-stack { display: grid; gap: 20px; align-content: start; }
.aside-call { background: var(--navy); color: #fff; border: 0; }
.aside-call h3 { color: #fff; }
.aside-call p { color: rgba(255,255,255,.85); }
.aside-call .phone { font-family: var(--font-head); font-weight: 800; font-size: 1.5rem; color: var(--yellow); text-decoration: none; display: block; margin-bottom: 14px; }
.aside-links ul { list-style: none; padding: 0; margin: 0; }
.aside-links li { border-bottom: 1px solid var(--line); }
.aside-links li:last-child { border-bottom: 0; }
.aside-links a { display: block; padding: 10px 0; text-decoration: none; font-weight: 600; }

/* ---------- CTA band ---------- */

.cta-band { background: var(--red); color: #fff; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-block: 44px; }
.cta-band h2 { color: #fff; margin-bottom: .2em; }
.cta-band p { margin: 0; color: rgba(255,255,255,.92); }

/* ---------- Footer ---------- */

.site-footer { background: var(--navy-dark); color: rgba(255,255,255,.78); font-size: .97rem; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--yellow); }
.site-footer h3 { color: #fff; font-size: 1.05rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer ul a { text-decoration: none; color: rgba(255,255,255,.78); }
.site-footer ul a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.1fr; gap: 36px; padding-block: 56px 36px; }
.brand-footer { color: #fff; margin-bottom: 14px; }
.brand-footer:hover { color: #fff; }
.brand-footer img { background: #fff; border-radius: 8px; padding: 4px 6px; width: 58px; }
.footer-phone a { font-family: var(--font-head); font-weight: 800; font-size: 1.3rem; text-decoration: none; }
.footer-badges { display: flex; gap: 12px; align-items: center; }
.footer-badges img { background: #fff; border-radius: 8px; padding: 4px; }
.footer-badges img.badge-round { background: none; padding: 0; border-radius: 50%; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-block: 20px; font-size: .9rem; }
.footer-bottom p { margin: 0; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Mobile call bar ---------- */

.mobile-call-bar { display: none; }
@media (max-width: 700px) {
  .mobile-call-bar {
    display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(255,255,255,.97); border-top: 1px solid var(--line);
    box-shadow: 0 -6px 20px rgba(17,28,77,.08);
  }
  body { padding-bottom: 76px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
