/* ==========================================================================
   ML Imbiss – styles
   ========================================================================== */

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-v18-latin-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-v18-latin-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Colors (from the original site) */
  --bg: #222222;
  --bg-card: #2a2a2a;
  --line: #383838;
  --text: #f7f8f9;
  --text-muted: #b2b2be;
  --white: #ffffff;
  --accent: #1e73be;
  --accent-hover: #4a9be0;
  --overlay: rgb(33 33 33 / 0.5);
  --star: #fbbc04;
  --shadow-text: rgb(0 0 0 / 0.3) 1px 2px 2px;

  /* Fluid type (360px → 1440px) */
  --fs-xs: clamp(0.8125rem, 0.78rem + 0.15vw, 0.875rem);
  --fs-sm: clamp(0.875rem, 0.84rem + 0.17vw, 0.9375rem);
  --fs-body: clamp(1rem, 0.96rem + 0.19vw, 1.125rem);
  --fs-lead: clamp(1.0625rem, 0.99rem + 0.37vw, 1.25rem);
  --fs-hero-sub: clamp(1.125rem, 0.94rem + 0.93vw, 1.75rem);
  --fs-h2: clamp(1.75rem, 1.42rem + 1.67vw, 2.75rem);
  --fs-hero: clamp(2.5rem, 1.83rem + 3.33vw, 4.75rem);

  /* Fluid spacing */
  --space-2xs: clamp(0.25rem, 0.23rem + 0.09vw, 0.3125rem);
  --space-xs: clamp(0.5rem, 0.46rem + 0.19vw, 0.625rem);
  --space-s: clamp(0.75rem, 0.69rem + 0.28vw, 1rem);
  --space-m: clamp(1rem, 0.89rem + 0.56vw, 1.5rem);
  --space-l: clamp(1.5rem, 1.28rem + 1.11vw, 2.5rem);
  --space-xl: clamp(2rem, 1.56rem + 2.22vw, 4rem);
  --space-2xl: clamp(3rem, 2.33rem + 3.33vw, 6rem);

  --gutter: clamp(1rem, 0.56rem + 2.22vw, 3rem);
  --container: 90rem;
  --radius: clamp(0.5rem, 0.43rem + 0.37vw, 0.75rem);
}

/* Reset --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
ul[class] { list-style: none; padding: 0; }
address { font-style: normal; }

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-weight: 400;
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { font-weight: 500; line-height: 1.15; }
p + p { margin-top: var(--space-s); }

a { color: var(--white); }
a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent-hover);
  outline-offset: 3px;
}

.sprite { display: none; }
.icon { width: 1em; height: 1em; flex: none; fill: currentColor; }

.visually-hidden {
  position: absolute !important;
  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: var(--space-s); top: -100%;
  z-index: 100;
  padding: var(--space-xs) var(--space-s);
  background: var(--white); color: var(--bg);
  border-radius: 0.25rem;
}
.skip-link:focus { top: var(--space-s); }

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.icon-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  color: var(--white);
  text-decoration: none;
  transition: color 0.3s ease;
}
.icon-link:hover, .icon-link:focus-visible { color: var(--accent-hover); }

/* Screens ------------------------------------------------------------- */
/* Each main section fills the viewport on desktop. */
@media (min-width: 1025px) {
  .screen {
    min-height: 100vh;
    min-height: 100svh;
  }
}

.screen--stack {
  display: flex;
  flex-direction: column;
}

/* Thin dark strips (top bar, address, footer) ------------------------- */
.strip {
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-sm);
  text-align: center;
  padding: var(--space-xs) var(--gutter);
}
.strip p {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
}
.strip--address { padding-block: var(--space-s); }
.strip--footer {
  border-top: 1px solid var(--line);
  color: var(--text-muted);
  font-size: var(--fs-xs);
  padding-block: var(--space-m);
}

/* Heroes -------------------------------------------------------------- */
.hero {
  position: relative;
  flex: 1;
  display: grid;
  place-items: center;
  min-height: clamp(24rem, 70svh, 48rem);
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}
@media (min-width: 1025px) {
  .hero { min-height: 0; }
}

.hero__img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--overlay);
}

.hero__content { padding: var(--space-l) var(--gutter); }
.hero__title {
  font-size: var(--fs-hero);
  color: var(--text);
  text-shadow: var(--shadow-text);
}
.hero__sub {
  margin-top: var(--space-2xs);
  font-size: var(--fs-hero-sub);
  line-height: 1.35;
  color: var(--text);
  text-shadow: rgb(0 0 0 / 0.3) 1px 1px 2px;
}

/* Reviews ------------------------------------------------------------- */
.reviews {
  padding-block: var(--space-xl);
  background: var(--bg);
}

.reviews__carousel { position: relative; }

.reviews__track {
  --per-view: 1;
  --gap: var(--space-s);
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - (var(--per-view) - 1) * var(--gap)) / var(--per-view));
  gap: var(--gap);
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  padding-block: 0.25rem;
}
.reviews__track::-webkit-scrollbar { display: none; }
@media (min-width: 560px)  { .reviews__track { --per-view: 2; } }
@media (min-width: 900px)  { .reviews__track { --per-view: 3; } }
@media (min-width: 1200px) { .reviews__track { --per-view: 4; } }
@media (min-width: 1500px) { .reviews__track { --per-view: 6; } }

.review {
  scroll-snap-align: start;
  display: flex;
}
.review article {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: var(--space-m);
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.review__head {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}
.review__avatar {
  flex: none;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--c, var(--accent));
  color: var(--white);
  font-weight: 500;
}
.review__who { flex: 1; min-width: 0; }
.review__name {
  font-size: var(--fs-sm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.review__date {
  display: block;
  font-size: var(--fs-xs);
  color: var(--text-muted);
}
.review__g { flex: none; width: 1.25rem; height: 1.25rem; align-self: flex-start; }

.review__stars {
  display: flex;
  gap: 0.125rem;
  margin-top: var(--space-s);
}
.review__stars svg { width: 1.05rem; height: 1.05rem; fill: var(--star); }

.review__text {
  margin-top: var(--space-xs) !important;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  overflow: hidden;
}
.review.is-open .review__text {
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: none;
}

.review__more {
  align-self: flex-start;
  margin-top: var(--space-xs);
  padding: 0;
  background: none;
  border: 0;
  color: var(--text-muted);
  font-size: var(--fs-xs);
  cursor: pointer;
}
.review__more:hover { color: var(--white); }

.reviews__nav {
  position: absolute;
  top: 50%;
  translate: 0 -50%;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgb(34 34 34 / 0.9);
  cursor: pointer;
  transition: opacity 0.2s ease, background-color 0.2s ease;
}
.reviews__nav:hover { background: var(--line); }
.reviews__nav:disabled { opacity: 0; pointer-events: none; }
.reviews__nav svg { width: 1.5rem; height: 1.5rem; fill: var(--white); }
.reviews__nav--prev { left: calc(var(--space-s) * -1); }
.reviews__nav--prev svg { rotate: 180deg; }
.reviews__nav--next { right: calc(var(--space-s) * -1); }

.reviews__all {
  margin-top: var(--space-m);
  text-align: center;
  font-size: var(--fs-sm);
}
.reviews__all a { color: var(--text-muted); transition: color 0.3s ease; }
.reviews__all a:hover { color: var(--white); }

/* Feature sections (Welcome / Sandwichery) ---------------------------- */
.feature {
  display: grid;
  grid-template-columns: 1fr;
  background: var(--bg);
  border-top: 1px solid var(--line);
}

.feature__media { margin: 0; }
.feature__media img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.feature__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-xl) var(--gutter) var(--space-2xl);
  max-width: 44rem;
}
.feature__title {
  font-size: var(--fs-h2);
  margin-bottom: var(--space-m);
}
.feature__body .icon-link { margin-top: var(--space-2xs); }

@media (min-width: 1025px) {
  .feature { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature__media img { aspect-ratio: auto; }
  .feature__body { padding: var(--space-2xl) var(--space-xl); }
  .feature--reverse .feature__media { order: 2; }
}

/* Contact ------------------------------------------------------------- */
.contact {
  position: relative;
  display: grid;
  place-items: center;
  padding: var(--space-2xl) var(--space-xs);
  overflow: hidden;
  isolation: isolate;
}
.contact::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--overlay);
}
.contact__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contact__card {
  width: min(100%, 60rem);
  padding: var(--space-l) var(--space-m);
  background: rgb(33 33 33 / 0.55);
  border: 1px solid #353535;
  border-radius: var(--radius);
  text-align: center;
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}
.contact__title {
  font-size: var(--fs-hero);
  text-shadow: var(--shadow-text);
}
.contact__intro {
  margin-top: var(--space-xs);
  font-size: var(--fs-lead);
  text-shadow: rgb(0 0 0 / 0.3) 1px 1px 2px;
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: var(--space-m);
  margin-block: var(--space-l);
}
.contact__logo img {
  width: clamp(7rem, 5.5rem + 7.5vw, 10rem);
  height: auto;
}
.contact__links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-xs);
}

@media (min-width: 768px) {
  .contact__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: center;
    column-gap: var(--space-xl);
  }
  .contact__logo { justify-self: end; }
  .contact__links { justify-self: start; }
}

.contact__address { font-size: var(--fs-body); margin-top: var(--space-m); }

.contact__hours {
  width: fit-content;
  margin-inline: auto;
  padding-top: var(--space-m);
  border-top: 1px solid var(--line);
}
.contact__subtitle {
  font-size: var(--fs-lead);
  margin-bottom: var(--space-xs);
}
.contact__hours dl { display: grid; gap: var(--space-2xs); }
.contact__hours dl > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  column-gap: var(--space-xs);
}
.contact__hours dt { font-weight: 500; }
.contact__hours dd { margin: 0; color: var(--text-muted); }

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