/* ==========================================================================
   Eight Forty Square — site styles
   Mobile-first. No build step, no frameworks.
   The palette is taken from the signage: black, white and orange.
   Change the custom properties in :root below to re-skin the whole site.
   ========================================================================== */

/* --- Design tokens ------------------------------------------------------ */

:root {
  /* Brand */
  --accent: #e8481c;          /* the orange from the sign */
  --accent-strong: #c93a12;
  --brand-black: #101010;     /* the sign's black — used for the header */
  --whatsapp: #25d366;

  /* Surfaces + text (light theme) */
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-alt: #f4f2ef;
  --ink: #16150f;
  --ink-muted: #5c5a53;
  --line: #e2dfd8;

  /* Type — a bold geometric sans, echoing the wordmark on the sign */
  --font-display: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  /* Rhythm */
  --wrap: 1120px;
  --gap: 1.25rem;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(22 21 15 / 6%), 0 8px 24px rgb(22 21 15 / 8%);

  --header-h: 64px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent: #ff6134;
    --accent-strong: #ff7d57;
    --bg: #121211;
    --surface: #1b1b19;
    --surface-alt: #232320;
    --ink: #f4f2ed;
    --ink-muted: #a8a59c;
    --line: #33322e;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 24px rgb(0 0 0 / 35%);
  }
}

/* --- Base --------------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

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

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

a {
  color: var(--accent-strong);
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 800;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2rem, 6vw, 3.25rem);
}
h2 {
  font-size: clamp(1.5rem, 4vw, 2.25rem);
}
h3 {
  font-size: 1.15rem;
}

p {
  margin: 0 0 1rem;
}

.wrap {
  width: min(100% - 2rem, var(--wrap));
  margin-inline: auto;
}

.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 for keyboard users */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 100;
  background: var(--accent);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: 0 0 8px 8px;
  transition: top 0.15s;
}
.skip-link:focus {
  top: 0;
}

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

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.4rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.12s ease, background-color 0.15s ease;
}
.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-strong);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover {
  background: var(--surface-alt);
}

.btn-whatsapp {
  background: var(--whatsapp);
  color: #06301a;
}
.btn-whatsapp:hover {
  filter: brightness(0.94);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

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

/* The header is black in both themes — it mirrors the signage, and gives the
   orange and white a consistent backdrop to sit on. */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--brand-black);
  border-bottom: 1px solid #2a2a28;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
/* The concentric-square mark, redrawn as SVG so it stays crisp at any size and
   sits cleanly on the black bar. Rings inherit currentColor; centre is orange,
   as on the sign. */
.brand-mark {
  width: 32px;
  height: 32px;
  flex: none;
}
.brand-mark .ring {
  fill: none;
  stroke: currentColor;
}
.brand-mark .core {
  fill: var(--accent);
}
.brand-sub {
  font-weight: 600;
  letter-spacing: 0.18em;
  font-size: 0.62rem;
  color: var(--accent);
  display: block;
  margin-top: 1px;
}

.nav-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  background: none;
  border: 1px solid rgb(255 255 255 / 25%);
  border-radius: 10px;
  color: #fff;
  cursor: pointer;
}
.nav-toggle-icon,
.nav-toggle-icon::before,
.nav-toggle-icon::after {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle-icon::before,
.nav-toggle-icon::after {
  content: "";
  position: relative;
}
.nav-toggle-icon::before {
  top: -6px;
}
.nav-toggle-icon::after {
  top: 4px;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-icon {
  background: transparent;
}
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before {
  transform: translateY(6px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after {
  transform: translateY(-4px) rotate(-45deg);
}

.site-nav {
  display: none;
  position: absolute;
  inset: var(--header-h) 0 auto;
  background: var(--brand-black);
  border-bottom: 1px solid #2a2a28;
  padding: 0.75rem 1rem 1.25rem;
  box-shadow: 0 12px 24px rgb(0 0 0 / 35%);
}
.site-nav.is-open {
  display: block;
}
.site-nav ul {
  list-style: none;
  margin: 0 0 0.75rem;
  padding: 0;
}
.site-nav a {
  display: block;
  padding: 0.7rem 0.25rem;
  color: rgb(255 255 255 / 88%);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 1px solid #2a2a28;
}
.site-nav a[aria-current="page"] {
  color: var(--accent);
  font-weight: 700;
}
/* `.site-nav a` outranks `.btn-whatsapp`, which would leave the green pill with
   white text. Restore the dark-on-green contrast. */
.site-nav a.btn-whatsapp {
  color: #06301a;
  border-bottom: 0;
}

@media (min-width: 860px) {
  .nav-toggle {
    display: none;
  }
  .site-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    position: static;
    background: none;
    border: 0;
    padding: 0;
    box-shadow: none;
  }
  .site-nav ul {
    display: flex;
    gap: 1.35rem;
    margin: 0;
  }
  .site-nav a {
    padding: 0.25rem 0;
    border-bottom: 2px solid transparent;
  }
  .site-nav a:hover {
    border-bottom-color: rgb(255 255 255 / 35%);
  }
  .site-nav a[aria-current="page"] {
    border-bottom-color: var(--accent);
  }
}

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

/* The banner is a photo of the signage, which already carries the name. Rather
   than crop it behind a headline, it is shown whole on a black field and the
   words sit beneath it — so nothing important is ever cut off, at any width. */
.hero {
  background: var(--brand-black);
  color: #fff;
  text-align: center;
  padding-bottom: 3.25rem;
}
/* A restrained band rather than a full-bleed hero — tall enough to read the
   scene, short enough that the headline below stays on screen. The crop is
   biased upward to keep the seating and umbrella in frame. */
.hero-banner {
  display: block;
  width: 100%;
  height: clamp(165px, 24vw, 300px);
  object-fit: cover;
  object-position: center 30%;
}
.hero-content {
  max-width: 44rem;
  margin-inline: auto;
  padding-top: 2.5rem;
}
.hero h1 {
  color: #fff;
  font-size: clamp(1.75rem, 5vw, 2.75rem);
}
.hero p {
  color: rgb(255 255 255 / 78%);
  font-size: 1.05rem;
}
.hero-tagline {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.9rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 1.5rem;
}
/* Scoped to .hero on purpose: .hero-actions is reused on the inner pages over a
   light background, where a white ghost button would be invisible. */
.hero .btn-ghost {
  color: #fff;
  border-color: rgb(255 255 255 / 45%);
}
.hero .btn-ghost:hover {
  background: rgb(255 255 255 / 12%);
}

/* Compact hero for inner pages */
.page-head {
  padding: 3rem 0 2rem;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--line);
}
.page-head p {
  color: var(--ink-muted);
  max-width: 48ch;
  margin-bottom: 0;
}
.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--accent-strong);
  margin-bottom: 0.4rem;
}

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

.section {
  padding: 3.5rem 0;
}
.section-alt {
  background: var(--surface-alt);
}
.section-head {
  max-width: 52ch;
  margin-bottom: 2rem;
}
.section-head p {
  color: var(--ink-muted);
  margin-bottom: 0;
}

/* --- Tiles -------------------------------------------------------------- */

.tiles {
  display: grid;
  gap: var(--gap);
  grid-template-columns: 1fr;
}
@media (min-width: 620px) {
  .tiles-2,
  .tiles-3,
  .tiles-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 900px) {
  .tiles-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .tiles-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.tile {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}
.tile-link:hover,
.tile-link:focus-within {
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgb(29 26 22 / 8%), 0 14px 32px rgb(29 26 22 / 14%);
}

.tile-media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--surface-alt);
}
.tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Shown by main.js when an image file is missing, so the layout never breaks
   and you can see exactly which photo slots still need filling. */
.is-placeholder {
  display: grid;
  place-items: center;
  background: repeating-linear-gradient(
    45deg,
    var(--surface-alt),
    var(--surface-alt) 12px,
    color-mix(in srgb, var(--surface-alt) 70%, var(--line)) 12px,
    color-mix(in srgb, var(--surface-alt) 70%, var(--line)) 24px
  );
}
.is-placeholder::after {
  content: attr(data-placeholder);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ink-muted);
  background: var(--surface);
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  text-align: center;
}

.tile-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.tile-body h3 {
  margin-bottom: 0.35rem;
}
.tile-body p {
  color: var(--ink-muted);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}
.tile-body p:last-child {
  margin-bottom: 0;
}
.tile-cta {
  margin-top: auto;
  font-weight: 600;
  text-decoration: none;
  color: var(--accent-strong);
}
.tile-cta::after {
  content: " →";
}
/* Makes the whole tile clickable while keeping one real link for a11y. */
.tile-link {
  position: relative;
}
.tile-link .tile-cta::before {
  content: "";
  position: absolute;
  inset: 0;
}

/* --- Menu tiles (price on the right) ------------------------------------ */

.menu-tile {
  padding: 1.1rem 1.25rem;
}
.menu-tile-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}
.menu-tile-head h3 {
  margin: 0;
  font-size: 1.05rem;
}
.price {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  color: var(--accent-strong);
  white-space: nowrap;
}
.menu-tile p {
  margin: 0.35rem 0 0;
  font-size: 0.9rem;
  color: var(--ink-muted);
}

/* --- Package tiles (car wash) ------------------------------------------- */

.package {
  padding: 1.5rem 1.35rem;
  text-align: center;
}
.package-price {
  font-size: 2rem;
  font-weight: 700;
  font-family: var(--font-display);
  color: var(--ink);
  margin: 0.25rem 0;
}
.package-meta {
  font-size: 0.85rem;
  color: var(--ink-muted);
  margin-bottom: 1rem;
}
.package ul {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
  text-align: left;
  font-size: 0.93rem;
}
.package li {
  padding: 0.4rem 0 0.4rem 1.5rem;
  position: relative;
  border-top: 1px solid var(--line);
}
.package li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}
.package.is-featured {
  border-color: var(--accent);
  border-width: 2px;
}
.badge {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
}

/* --- Info strip (hours / location / pay) -------------------------------- */

.info-strip {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .info-strip {
    grid-template-columns: repeat(3, 1fr);
  }
}
.info-strip h3 {
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 0.5rem;
}
.info-strip p,
.info-strip li {
  margin: 0;
  font-size: 0.98rem;
}
.info-strip ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.info-strip li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.2rem 0;
}
.info-strip li span:last-child {
  color: var(--ink-muted);
}

/* --- Map ---------------------------------------------------------------- */

.map-frame {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--surface-alt);
}
.map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* --- Notice ------------------------------------------------------------- */

.notice {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 1.1rem 1.25rem;
  border-radius: var(--radius);
  border: 1px dashed var(--line);
  background: var(--surface-alt);
  color: var(--ink-muted);
  font-size: 0.95rem;
}
.notice strong {
  color: var(--ink);
}

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

.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: 2.5rem 0 1.5rem;
  margin-top: 1rem;
  font-size: 0.95rem;
}
.footer-grid {
  display: grid;
  gap: 1.75rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}
.site-footer h3 {
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 0.6rem;
}
.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-footer li {
  padding: 0.2rem 0;
}
.site-footer a {
  color: var(--ink);
  text-decoration: none;
}
.site-footer a:hover {
  text-decoration: underline;
}
.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--ink-muted);
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
}

/* --- Floating WhatsApp -------------------------------------------------- */

.wa-float {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.1rem;
  border-radius: 999px;
  background: var(--whatsapp);
  color: #06301a;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  box-shadow: 0 6px 20px rgb(0 0 0 / 25%);
}
.wa-float svg {
  width: 20px;
  height: 20px;
  flex: none;
}
@media (max-width: 480px) {
  .wa-float .wa-label {
    display: none;
  }
  .wa-float {
    padding: 0.85rem;
  }
}

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

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