/* Стилове на сайта на Автосервиз Феникс, Бургас (от шаблона за автосервизи, наново за този клиент).
   Посока: „подредено табло“. Цялата страница е табло от плочки с процепи от 8px, без празни клетки.
   Цветовете са от сервиза: белите стени (фон), тъмносинята табела над вратите (тъмните плочки),
   червеното от логото и вратите (само за действията: обаждане, изпращане). Шрифт: Jost. */

/* ---------- tokens ---------- */
:root {
  --bg: #eef0f3;
  --tile: #ffffff;
  --tile-2: #e1e5eb;
  --ink: #141b2d;
  --muted: #4a5163;
  --navy: #1d2a4f;
  --navy-2: #2b3b66;
  --navy-ink: #ffffff;
  --navy-muted: #b9c3d9;
  --accent: #c8161d;
  --accent-hover: #a91118;
  --accent-ink: #ffffff;

  --font: 'Jost', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* пет размера на страница */
  --step-small: 0.875rem;                                        /* 14 */
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);       /* 17-19 */
  --step-lead: clamp(1.25rem, 1.1rem + 0.6vw, 1.625rem);         /* 20-26 */
  --step-head: clamp(1.875rem, 1.2rem + 2.2vw, 3.25rem);         /* 30-52 */
  --step-display: clamp(2.5rem, 1.2rem + 3.8vw, 4.75rem);        /* 40-76, заглавия на страници */
  --step-name: clamp(3.75rem, 1rem + 7.6vw, 8.25rem);            /* 60-132, името на началната страница */

  --gap: 8px;
  --margin: clamp(16px, 1.6vw, 24px);
  --pad: clamp(18px, 1.7vw, 26px);
  --section-gap: clamp(40px, 3.2vw, 48px);
  --header: 4rem;
  --radius: 6px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --t-press: 140ms;
  --t-hover: 200ms;
  --t-ui: 240ms;
}

@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 280ms; animation-timing-function: var(--ease-out); }

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--bg); scroll-padding-top: calc(var(--header) + 1rem); }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: var(--step-body); line-height: 1.5; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }
h1, h2, h3, h4, p, figure, blockquote, ul, ol, dl, dd, fieldset { margin: 0; }
fieldset { border: 0; padding: 0; min-width: 0; }
legend { padding: 0; }
ul[role="list"], ol[role="list"], ul[class], ol[class] { padding: 0; list-style: none; }
img, video, svg, iframe { display: block; max-width: 100%; }
img, video { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; text-align: inherit; -webkit-tap-highlight-color: transparent; }
a { color: inherit; -webkit-tap-highlight-color: transparent; }
::selection { background: var(--navy); color: #fff; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: var(--margin); top: -4rem; z-index: 200; background: var(--navy); color: #fff; padding: 0.7rem 1rem; text-decoration: none; border-radius: var(--radius); }
.skip:focus { top: 0.5rem; }
[hidden] { display: none !important; }

/* ---------- type ---------- */
h1, h2, h3 { font-weight: inherit; text-wrap: balance; hyphens: none; }
.display { font-weight: 700; font-size: var(--step-display); line-height: 0.95; letter-spacing: -0.03em; text-transform: uppercase; }
.head { font-weight: 700; font-size: var(--step-head); line-height: 0.98; letter-spacing: -0.025em; text-transform: uppercase; }
.lead { font-size: var(--step-lead); line-height: 1.32; text-wrap: pretty; }
.nums { font-variant-numeric: tabular-nums; }
p { max-width: 64ch; text-wrap: pretty; }
.t-title { display: block; font-size: var(--step-lead); font-weight: 500; line-height: 1.2; }

/* ---------- controls ---------- */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 0.5em; min-height: 3rem; padding: 0 1.25rem; background: var(--accent); color: var(--accent-ink); border-radius: var(--radius); font-weight: 500; line-height: 1.2; text-decoration: none; white-space: nowrap; transition: background-color var(--t-hover) ease, scale var(--t-press) var(--ease-out); }
.button:active { scale: 0.97; }
.button--navy { background: var(--navy); color: #fff; }
.button--light { background: var(--tile); color: var(--ink); }
.button--small { min-height: 2.75rem; padding: 0 1rem; }
.link { text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 40%, transparent); text-underline-offset: 0.22em; text-decoration-thickness: 0.07em; transition: text-decoration-color var(--t-hover) ease; }
button.link { font-size: inherit; text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 40%, transparent); text-underline-offset: 0.22em; }
.t-more { display: inline-flex; align-items: center; gap: 0.45em; margin-top: auto; padding-top: 0.75rem; font-weight: 500; }
.t-more::after { content: '→'; transition: translate var(--t-hover) var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .button:hover { background: var(--accent-hover); }
  .button--navy:hover { background: var(--navy-2); }
  .button--light:hover { background: var(--tile-2); }
  .link:hover { text-decoration-color: currentColor; }
}
.field { display: block; width: 100%; min-height: 3.25rem; padding: 0.75rem 1rem; background: var(--tile); color: var(--ink); border: 0; border-radius: var(--radius); font-size: max(1rem, 16px); }
.field::placeholder { color: var(--muted); }
select.field { appearance: none; padding-right: 2.5rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23ffffff' stroke-width='2'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; }

/* ---------- the board and its tiles ---------- */
main { padding-top: var(--gap); }
.board { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); padding: 0 var(--margin); }
main > .board + .board, main > .board + section, main > section + .board { margin-top: var(--section-gap); }
main > .board.is-joined { margin-top: var(--gap); }
.t { position: relative; display: flex; flex-direction: column; gap: 0.65rem; min-width: 0; padding: var(--pad); border-radius: var(--radius); background: var(--tile); color: var(--ink); text-decoration: none; overflow: hidden; }
.t--sunk { background: var(--tile-2); }
.t--navy { background: var(--navy); color: var(--navy-ink); }
.t--navy p { color: var(--navy-ink); }
.t--red { background: var(--accent); color: var(--accent-ink); }
a.t, button.t { transition: background-color var(--t-hover) ease, scale var(--t-press) var(--ease-out); }
a.t:active, button.t:active { scale: 0.985; }
@media (hover: hover) and (pointer: fine) {
  a.t:not(.t--navy):not(.t--red):not(.t-call):not(.t-viber):not(.t-rating):hover { background: #f8f9fb; }
  a.t.t--sunk:hover { background: #d8dde5; }
  a.t--navy:hover, a.t-viber:hover, a.t-rating:hover { background: var(--navy-2); }
  a.t-call:hover, a.t--red:hover { background: var(--accent-hover); }
  a.t:hover .t-more::after, a.t:hover .t-call-phone::after { translate: 4px 0; }
}
.t h3 { font-size: var(--step-lead); font-weight: 500; line-height: 1.2; }

/* photo tiles */
.t-photo { padding: 0; background: var(--tile-2); cursor: zoom-in; display: block; text-align: left; }
.t-photo-img { position: absolute; inset: 0; overflow: hidden; display: block; }
.t-photo-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 700ms var(--ease-out); }
.t-cap { position: absolute; left: 0; bottom: 0; max-width: calc(100% - 16px); padding: 0.45rem 0.8rem; background: var(--navy); color: #fff; font-size: var(--step-small); line-height: 1.3; border-top-right-radius: var(--radius); }
@media (hover: hover) and (pointer: fine) { .t-photo:hover .t-photo-img img { transform: scale(1.04); } }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 60; background: var(--bg); transition: transform 360ms var(--ease-out); }
.site-header.is-hidden { transform: translateY(-100%); }
.bar { height: var(--header); display: flex; align-items: center; gap: clamp(1rem, 2.2vw, 2rem); padding: 0 var(--margin); }
.brand { display: inline-flex; align-items: center; gap: 0.7rem; text-decoration: none; white-space: nowrap; }
.brand-badge { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: var(--radius); background: var(--navy); }
.brand-badge img { width: 2.1rem; height: auto; }
.brand-name { display: grid; font-weight: 700; font-size: 1.3rem; line-height: 1; letter-spacing: -0.01em; text-transform: uppercase; }
.brand-sub { font-weight: 400; font-size: var(--step-small); letter-spacing: 0; text-transform: none; color: var(--muted); margin-top: 0.2rem; }
.nav { margin-left: auto; display: flex; gap: 0.25rem; }
.nav-link { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 0.85rem; border-radius: var(--radius); font-weight: 500; text-decoration: none; color: var(--ink); transition: background-color var(--t-hover) ease; }
.nav-link[aria-current="page"], .nav-link.is-current, .nav-services[aria-expanded="true"] { background: var(--tile); }
.bar .button--bar { min-height: 2.75rem; padding: 0 1rem; }
.menu-btn { display: none; margin-left: auto; min-height: 2.75rem; padding: 0 1rem; background: var(--navy); color: #fff; border-radius: var(--radius); font-weight: 500; }
.menu-btn-close { display: none; }
.menu-btn[aria-expanded="true"] .menu-btn-open { display: none; }
.menu-btn[aria-expanded="true"] .menu-btn-close { display: inline; }
@media (hover: hover) and (pointer: fine) { .nav-link:hover { background: var(--tile); } }

.menu { position: absolute; left: 0; right: 0; top: 100%; padding: var(--gap) var(--margin) var(--margin); background: var(--bg); box-shadow: 0 18px 40px -20px rgba(20, 27, 45, 0.35); opacity: 0; transform: translateY(-0.5rem); transition: opacity var(--t-ui) var(--ease-out), transform var(--t-ui) var(--ease-out); } /* taste-skill-ignore: the open menu really floats over the page */
.menu.is-open { opacity: 1; transform: none; }
.menu-services { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--gap); }
.menu-services a { display: grid; gap: 0.2rem; padding: 0 0 1rem; border-radius: var(--radius); background: var(--tile); text-decoration: none; overflow: hidden; transition: background-color var(--t-hover) ease; }
.menu-thumb { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; margin-bottom: 0.7rem; }
.menu-name { padding: 0 1rem; font-weight: 500; font-size: var(--step-lead); line-height: 1.15; }
.menu-sub { padding: 0 1rem; color: var(--muted); font-size: var(--step-small); }
.menu-services a[aria-current="page"] { background: var(--navy); color: #fff; }
.menu-services a[aria-current="page"] .menu-sub { color: var(--navy-muted); }
.menu-extra, .menu-contact { display: none; }
@media (hover: hover) and (pointer: fine) { .menu-services a:hover { background: #f8f9fb; } }

/* ---------- home: the first board ---------- */
.hero { grid-template-rows: repeat(6, minmax(0, 1fr)); height: clamp(620px, calc(100svh - var(--header) - var(--gap) * 2), 900px); }
.h-name { grid-column: 1 / 6; grid-row: 1 / 5; justify-content: space-between; gap: 1.25rem; container-type: inline-size; }
.h-emblem { width: clamp(4.5rem, 6.4vw, 6.75rem); height: auto; }
.h-name h1 { font-weight: 700; line-height: 1; }
.h-copy { display: grid; gap: clamp(1rem, 1.8vw, 1.6rem); }
.h1-name { display: block; font-size: min(var(--step-name), 24cqi); line-height: 0.88; letter-spacing: -0.035em; text-transform: uppercase; }
.h1-sub { display: block; margin-top: 0.55rem; font-size: var(--step-lead); font-weight: 500; letter-spacing: 0; color: var(--navy-muted); }
.h-lead { font-size: var(--step-lead); line-height: 1.32; max-width: 30ch; }
.h-photo { grid-column: 6 / 13; grid-row: 1 / 5; }
.h-photo img { object-position: 50% 60%; }
.h-call { grid-column: 1 / 5; grid-row: 5 / 7; }
.h-open { grid-column: 5 / 8; grid-row: 5 / 7; }
.h-facts { grid-column: 8 / 11; grid-row: 5 / 7; }
.h-rating { grid-column: 11 / 13; grid-row: 5 / 7; }
.h-facts p + p { margin-top: auto; }

/* call tile (red) */
.t-call { background: var(--accent); color: #fff; justify-content: space-between; }
.t-call-line { font-size: var(--step-lead); font-weight: 500; line-height: 1.2; max-width: 22ch; }
.t-call-phone { display: inline-flex; align-items: baseline; gap: 0.35em; font-weight: 700; font-size: var(--step-head); line-height: 1; letter-spacing: -0.02em; white-space: nowrap; }
.t-call-phone::after { content: '→'; font-weight: 400; font-size: 0.6em; transition: translate var(--t-hover) var(--ease-out); }

/* open now */
.t-open { gap: 0.3rem; }
.open-state { display: flex; align-items: center; gap: 0.55rem; font-size: var(--step-lead); font-weight: 500; line-height: 1.2; }
.open-dot { width: 0.7rem; height: 0.7rem; border-radius: 50%; background: var(--muted); flex: none; }
.t-open.is-open .open-dot { background: #1f8a4c; outline: 4px solid rgba(31, 138, 76, 0.2); }
.t-open.is-closed .open-dot { background: var(--accent); }
.open-note { color: var(--muted); }
.open-hours { margin-top: auto; padding-top: 0.6rem; display: grid; gap: 0.1rem; font-size: var(--step-small); }
.open-hours li { display: flex; justify-content: space-between; gap: 0.75rem; }

/* rating */
.t-rating { background: var(--navy); color: #fff; gap: 0.35rem; }
.rating-num { font-weight: 700; font-size: var(--step-head); line-height: 0.95; letter-spacing: -0.02em; }
.rating-of { display: grid; gap: 0.2rem; font-size: var(--step-small); color: var(--navy-muted); }
.stars { display: block; width: 6.5rem; height: auto; fill: var(--accent); }
.t--navy .stars, .t-rating .stars { fill: #ffffff; }

/* ---------- home: what we do (mosaic) ---------- */
.svc { grid-template-rows: auto minmax(15rem, auto) minmax(13rem, auto); }
.svc-head { grid-column: 1 / 5; grid-row: 1; }
.svc-head p { margin-top: 0.4rem; }
.svc-volvo { grid-column: 5 / 13; grid-row: 1; padding: 0; display: grid; grid-template-columns: 1fr 1fr; }
.svc-volvo-copy { display: flex; flex-direction: column; gap: 0.6rem; padding: var(--pad); }
.svc-volvo-copy p { color: var(--navy-ink); }
.svc-volvo-img { position: relative; overflow: hidden; min-height: 16rem; }
.svc-volvo-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 75%; transition: transform 700ms var(--ease-out); }
.svc-meh { grid-column: 1 / 7; grid-row: 2 / 4; padding: 0; min-height: 30rem; }
.svc-meh .t-photo-img img { height: 112%; object-position: 50% 30%; }
.svc-meh-box { position: absolute; left: var(--gap); bottom: var(--gap); width: min(26rem, calc(100% - 16px)); display: flex; flex-direction: column; gap: 0.5rem; padding: var(--pad); border-radius: var(--radius); background: var(--tile); color: var(--ink); }
.svc-diag { grid-column: 7 / 10; grid-row: 2; }
.svc-el { grid-column: 10 / 13; grid-row: 2; }
.svc-oil { grid-column: 7 / 13; grid-row: 3; padding: 0; display: grid; grid-template-columns: 3fr 2fr; }
.svc-oil-copy { display: flex; flex-direction: column; gap: 0.6rem; padding: var(--pad); }
.svc-oil-img { position: relative; overflow: hidden; }
.svc-oil-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 40% 55%; transition: transform 700ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { a.t:hover .svc-volvo-img img, a.t:hover .svc-oil-img img, a.t:hover .t-photo-img img { transform: scale(1.04); } }

/* ---------- home: Volvo, one photograph cut across the tiles ---------- */
.vs { grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: calc((100vw - var(--margin) * 2 - var(--gap) * 5) / 6); max-height: none; }
.vs-piece { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--tile-2); }
.vs-piece img { position: absolute; max-width: none; width: calc(600% + var(--gap) * 5); height: calc(300% + var(--gap) * 2); left: calc(var(--c) * (100% + var(--gap)) * -1); top: calc(var(--r) * (100% + var(--gap)) * -1); object-fit: cover; object-position: 50% 62%; transition: transform 700ms var(--ease-out); transform-origin: calc(var(--c) * 20%) calc(var(--r) * 50%); }
@media (hover: hover) and (pointer: fine) { .vs-piece:hover img { transform: scale(1.04); } }
.vs-head { grid-column: 1 / 3; grid-row: 1; background: var(--navy); color: #fff; justify-content: space-between; }
.vs-head p { color: var(--navy-muted); }
.vs-fact { font-size: var(--step-body); line-height: 1.4; }
.vs-fact strong { display: block; font-weight: 500; font-size: var(--step-lead); line-height: 1.15; margin-bottom: 0.3rem; }
.vs-f1 { grid-column: 6; grid-row: 1; }
.vs-f2 { grid-column: 2; grid-row: 3; background: var(--tile-2); }
.vs-f3 { grid-column: 4; grid-row: 3; }
.vs-act { grid-column: 6; grid-row: 3; background: var(--accent); color: #fff; justify-content: space-between; }
.vs-act .t-title { font-weight: 500; }
.vs-act .t-title::after { content: ' →'; }
.vs-whole { display: none; }

/* ---------- steps: tiles that grow ---------- */
.steps-title { grid-column: 1 / 8; grid-row: 1; align-self: start; padding-top: 0.25rem; }
.steps-row { grid-column: 1 / 13; grid-row: 1; display: grid; grid-template-columns: 2fr 3fr 3fr 4fr; grid-template-rows: auto auto auto; column-gap: var(--gap); }
.step { display: grid; grid-row: span 3; grid-template-rows: subgrid; }
.step-tile { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--tile-2); align-self: end; }
.step:nth-child(1) .step-tile { height: clamp(10rem, 22svh, 13rem); }
.step:nth-child(2) .step-tile { height: clamp(14rem, 30svh, 18rem); }
.step:nth-child(3) .step-tile { height: clamp(18rem, 38svh, 23rem); }
.step:nth-child(4) .step-tile { height: clamp(22rem, 46svh, 28rem); }
.step-tile img { width: 100%; height: 100%; object-fit: cover; }
.step-tile--plain { display: flex; align-items: flex-end; padding: var(--pad); background: var(--navy); color: #fff; }
.step-big { font-weight: 700; font-size: var(--step-lead); line-height: 1.1; }
.step-name { margin-top: 0.75rem; font-size: var(--step-lead); font-weight: 500; line-height: 1.2; }
.step p { margin-top: 0.3rem; color: var(--muted); max-width: 34ch; }

/* ---------- reviews ---------- */
.rev-rate { grid-column: 1 / 4; grid-row: 1 / 3; }
.rev-rate .head { margin-bottom: auto; }
.rev-rate .rating-num { font-size: var(--step-name); line-height: 0.85; letter-spacing: -0.04em; }
.rev-q1 { grid-column: 4 / 9; grid-row: 1; }
.rev-q2 { grid-column: 9 / 13; grid-row: 1 / 3; }
.rev-q3 { grid-column: 4 / 9; grid-row: 2; }
.t-quote { gap: 0.9rem; }
.t-quote blockquote p { font-size: var(--step-body); line-height: 1.5; }
.rev .t-quote blockquote p { font-size: var(--step-lead); line-height: 1.38; }
.t-quote figcaption { margin-top: auto; font-weight: 500; }
.t-quote.t--navy figcaption { color: var(--navy-muted); }

/* ---------- photos: a board of six cells ---------- */
.pboard { grid-template-rows: repeat(2, minmax(15rem, 18rem)); }
.p-head { grid-column: 1 / 4; grid-row: 1; }
.p-a { grid-column: 4 / 7; grid-row: 1 / 3; }
.p-b { grid-column: 7 / 10; grid-row: 1; }
.p-c { grid-column: 10 / 13; grid-row: 1 / 3; }
.p-d { grid-column: 1 / 4; grid-row: 2; }
.p-e { grid-column: 7 / 10; grid-row: 2; }

/* ---------- booking (form as filled cells) ---------- */
.t-book { grid-column: 1 / 9; background: var(--navy); color: #fff; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1.25rem var(--gap); align-content: start; }
.book-head { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0.5rem var(--gap); align-items: end; }
.book-head .head { grid-column: 1 / 4; }
.book-head p { grid-column: 4 / 7; color: var(--navy-muted); }
.book-cars { grid-column: 1 / -1; }
.book-cars legend { margin-bottom: 0.5rem; color: var(--navy-muted); font-size: var(--step-small); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { min-height: 2.75rem; padding: 0 1rem; border-radius: var(--radius); background: var(--navy-2); color: #fff; font-weight: 500; transition: background-color var(--t-hover) ease, color var(--t-hover) ease, scale var(--t-press) var(--ease-out); }
.chip:active { scale: 0.96; }
.chip[aria-pressed="true"] { background: #fff; color: var(--navy); }
@media (hover: hover) and (pointer: fine) { .chip:hover:not([aria-pressed="true"]) { background: #36487a; } }
.book-cells { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.cell { display: block; }
.cell .field { min-height: 3.75rem; background: var(--navy-2); color: #fff; }
.cell .field::placeholder { color: var(--navy-muted); }
.cell .field:focus { background: #3a4d82; outline: none; }
.cell .field:focus-visible { outline: 3px solid #fff; outline-offset: 0; }
.cell select.field option { color: var(--ink); background: #fff; }
.cell--wide { grid-column: 1 / 3; }
.cell--send { min-height: 3.75rem; border-radius: var(--radius); background: var(--accent); color: #fff; font-weight: 500; text-align: center; transition: background-color var(--t-hover) ease, scale var(--t-press) var(--ease-out); }
.cell--send:active { scale: 0.98; }
@media (hover: hover) and (pointer: fine) { .cell--send:hover { background: var(--accent-hover); } }
.book-out { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0.4rem var(--gap); align-items: start; }
.book-label { grid-column: 1 / 2; color: var(--navy-muted); font-size: var(--step-small); padding-top: 0.9rem; }
.book-preview { grid-column: 2 / 7; max-width: none; padding: 0.85rem 1rem; border-radius: var(--radius); background: rgba(255, 255, 255, 0.08); color: #fff; }
.book-alt { grid-column: 2 / 7; color: var(--navy-muted); font-size: var(--step-small); }
.book-alt .link { color: #fff; }
.book-place { grid-column: 9 / 13; min-height: 18rem; }
.book-addr { grid-column: 9 / 13; }
.book:has(.book-place) .t-book { grid-row: 1 / 3; }
.book:not(:has(.book-place)) .t-book { grid-column: 1 / -1; }
.t-addr .t-title { font-weight: 500; }
.t-addr .addr-buttons { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 0.75rem; }
.t-addr .button--light { background: var(--tile-2); }
@media (hover: hover) and (pointer: fine) { .t-addr .button--light:hover { background: #d3d9e2; } }

/* ---------- footer ---------- */
.site-footer { margin-top: var(--section-gap); padding-bottom: var(--gap); }
.footer-board { align-items: stretch; }
.tile-f { padding: var(--pad); border-radius: var(--radius); background: var(--tile); }
.f-logo { grid-column: 1 / 4; display: grid; place-items: center; background: var(--navy); text-decoration: none; }
.footer-logo { width: min(100%, 15rem); height: auto; }
.f-services { grid-column: 4 / 7; }
.f-more { grid-column: 7 / 10; background: var(--tile-2); }
.f-contact { grid-column: 10 / 13; }
.fhead { font-weight: 500; font-size: var(--step-small); color: var(--muted); margin-bottom: 0.7rem; }
.tile-f ul { display: grid; gap: 0.4rem; padding: 0; list-style: none; }
.f-extras { margin-top: 1rem; color: var(--muted); font-size: var(--step-small); }
.tile-f p + p { margin-top: 0.35rem; }
.footer-phone { font-weight: 700; font-size: var(--step-lead); text-decoration: none; letter-spacing: -0.01em; }
.footer-hours { margin-top: 0.8rem; font-size: var(--step-small); color: var(--muted); }
.footer-hours li { display: flex; justify-content: space-between; gap: 0.75rem; }
.f-last { grid-column: 1 / -1; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.75rem 0 0.5rem; font-size: var(--step-small); color: var(--muted); }

.quickbar { display: none; }
.toast { position: fixed; left: 50%; bottom: calc(1.25rem + env(safe-area-inset-bottom)); z-index: 120; max-width: min(28rem, calc(100vw - 2rem)); padding: 0.9rem 1.1rem; border-radius: var(--radius); background: var(--navy); color: #fff; font-size: var(--step-small); opacity: 0; transform: translate(-50%, 1rem); pointer-events: none; transition: opacity var(--t-ui) ease, transform var(--t-ui) var(--ease-out); }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- service pages ---------- */
.s-hero { grid-template-rows: auto minmax(11rem, auto); }
.s-title { grid-column: 1 / 6; grid-row: 1; background: var(--tile-2); container-type: inline-size; gap: 1rem; }
.s-title h1 { font-size: min(var(--step-display), 11cqi); }
.s-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1.25rem; margin-top: 0.4rem; }
.s-photo { grid-column: 6 / 13; grid-row: 1 / 3; min-height: clamp(22rem, 58svh, 36rem); }
.s-open { grid-column: 1 / 4; grid-row: 2; }
.s-fact { grid-column: 4 / 6; grid-row: 2; background: var(--navy); color: #fff; }
.s-fact p { color: var(--navy-muted); }

.inc > .t { min-height: 11rem; }
.inc > :nth-child(1) { grid-column: span 4; }
.inc > :nth-child(2) { grid-column: span 4; }
.inc > :nth-child(3) { grid-column: span 4; background: var(--navy); color: #fff; }
.inc > :nth-child(3) p { color: var(--navy-muted); }
.inc > :nth-child(4) { grid-column: span 3; }
.inc > :nth-child(5) { grid-column: span 5; background: var(--tile-2); }
.inc > :nth-child(6) { grid-column: span 4; }
.inc > :nth-child(7) { grid-column: span 7; }
.inc > :nth-child(8) { grid-column: span 5; }
.inc p { color: var(--muted); }
.inc .t-head p { color: var(--ink); }
.t-head { background: var(--tile-2); }

.sp > .t-quote { grid-column: 1 / 6; min-height: 22rem; }
.sp > .t-photo { min-height: 22rem; }
.sp > .t-photo:nth-of-type(1) { grid-column: 6 / 10; }
.sp > .t-photo:nth-of-type(2) { grid-column: 10 / 13; }
.sp--noquote > .t-photo:nth-of-type(1) { grid-column: 1 / 8; }
.sp--noquote > .t-photo:nth-of-type(2) { grid-column: 8 / 13; }

.faq-head { grid-column: 1 / 4; }
.faq-list { grid-column: 4 / 13; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gap); align-items: start; }
.qa { padding: 0; }
.qa summary { display: flex; justify-content: space-between; gap: 1.25rem; padding: 1.1rem var(--pad); cursor: pointer; list-style: none; font-weight: 500; line-height: 1.35; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: '+'; flex: none; color: var(--accent); font-size: 1.5rem; line-height: 1; transition: rotate var(--t-ui) var(--ease-out); }
.qa[open] summary::after { rotate: 45deg; }
.qa p { padding: 0 var(--pad) 1.2rem; color: var(--muted); }
@media (hover: hover) and (pointer: fine) { .qa summary:hover { color: var(--accent); } }

.cta-row .t { min-height: 12rem; }
.cta-row .t-call { grid-column: 1 / 5; }
.cta-row .t-viber { grid-column: 5 / 8; background: var(--navy); color: #fff; }
.cta-row .t-open { grid-column: 8 / 11; }
.cta-row .t-where { grid-column: 11 / 13; background: var(--tile-2); }

/* ---------- gallery page ---------- */
.g-hero .g-title { grid-column: 1 / 8; background: var(--tile-2); }
.g-hero .g-side { grid-column: 8 / 13; background: var(--navy); color: #fff; justify-content: space-between; }
.g-hero .g-side p { color: var(--navy-muted); }
.g-board { grid-auto-rows: minmax(16rem, auto); }
.g-board > section > *, .g-board > .g-fb { grid-column: span 3; }
.g-board .t-photo { aspect-ratio: 4 / 5; min-height: 0; }
.g-group-head { background: var(--tile); }
.g-group-head .g-meta { color: var(--muted); font-size: var(--step-small); }
.g-group-head .g-links { margin-top: auto; display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; font-weight: 500; }
.g-board > section { display: contents; }

/* ---------- contact page ---------- */
.c-hero .c-title { grid-column: 1 / 6; background: var(--tile-2); }
.c-hero .t-call { grid-column: 6 / 10; }
.c-hero .t-viber { grid-column: 10 / 13; background: var(--navy); color: #fff; }
.c-hero .t-addr { grid-column: 1 / 5; }
.c-hero .t-open { grid-column: 5 / 8; }
.c-hero .c-lang { grid-column: 8 / 13; background: var(--tile-2); }
.c-map { grid-column: 1 / 9; min-height: clamp(22rem, 56svh, 34rem); padding: 0; }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.c-place { grid-column: 9 / 13; display: flex; flex-direction: column; }
.c-place .t-photo { flex: 1; min-height: 16rem; }
.c-onsite { grid-auto-rows: minmax(15rem, auto); }
.c-onsite > * { grid-column: span 3; }
.t-viber .t-more { margin-top: auto; }
.g-fb { justify-content: space-between; }

/* Volvo board below 1180px: the whole photograph on top, the facts as tiles under it */
@media (max-width: 1180px) and (min-width: 821px) {
  .vs { grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: auto; grid-auto-flow: dense; }
  .vs-piece { display: none; }
  .vs-whole { display: block; grid-column: 1 / -1; aspect-ratio: 16 / 7; }
  .vs-head { grid-column: 1 / 5; grid-row: auto; }
  .vs-f1 { grid-column: 5 / 9; grid-row: auto; }
  .vs-f2 { grid-column: 9 / 13; grid-row: auto; }
  .vs-f3 { grid-column: 1 / 7; grid-row: auto; }
  .vs-act { grid-column: 7 / 13; grid-row: auto; }
}

/* ---------- lightbox ---------- */
.lb { position: fixed; inset: 0; z-index: 150; display: grid; grid-template-rows: minmax(0, 1fr) auto; background: rgba(14, 19, 33, 0.96); color: #fff; opacity: 0; transition: opacity 260ms ease; }
.lb.is-open { opacity: 1; }
.lb-stage { position: relative; overflow: hidden; touch-action: pan-y; }
.lb-media { position: absolute; display: block; object-fit: contain; background: var(--navy); transform-origin: 0 0; border-radius: var(--radius); }
.lb-ui { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 1rem 1.5rem; padding: 0.9rem var(--margin) calc(0.9rem + env(safe-area-inset-bottom)); }
.lb-caption { font-size: var(--step-small); }
.lb-caption b { font-weight: 500; }
.lb-count { color: var(--navy-muted); font-size: var(--step-small); }
.lb-controls { display: flex; gap: 6px; }
.lb-btn { min-height: 2.9rem; padding: 0 1rem; border-radius: var(--radius); background: var(--navy-2); font-weight: 500; transition: background-color var(--t-hover) ease, scale var(--t-press) var(--ease-out); }
.lb-btn:active { scale: 0.96; }
.lb-close { background: #fff; color: var(--navy); }
@media (hover: hover) and (pointer: fine) { .lb-btn:hover { background: #36487a; } .lb-close:hover { background: var(--tile-2); } }
body.lb-lock { overflow: hidden; }

/* ---------- motion (content stays visible without JavaScript) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(20px); transition: opacity 600ms var(--ease-out) calc(var(--i, 0) * 70ms), transform 800ms var(--ease-expo) calc(var(--i, 0) * 70ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
  /* the signature move: the first photograph opens like a garage door */
  .js .shutter .t-photo-img { animation: shutter 1100ms var(--ease-in-out) 150ms both; }
  .js .shutter .t-photo-img img { animation: settle 1500ms var(--ease-out) 150ms both; }
  .js .hero .h-name > * { animation: rise 800ms var(--ease-out) both; }
  .js .hero .h-name > :nth-child(2) { animation-delay: 90ms; }
  .js .hero .h-name > :nth-child(3) { animation-delay: 180ms; }
  .js .vs .vs-piece { opacity: 0; transition: opacity 700ms ease calc(var(--k, 0) * 45ms); }
  .js .vs.is-in .vs-piece { opacity: 1; }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes shutter { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes settle { from { transform: scale(1.12); } to { transform: none; } }

/* ---------- tablet ---------- */
@media (max-width: 1100px) {
  .menu-services { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .nav-link { padding: 0 0.6rem; }
  .h-name { grid-column: 1 / 7; }
  .h-photo { grid-column: 7 / 13; }
  .h-call { grid-column: 1 / 5; }
  .h-open { grid-column: 5 / 9; }
  .h-facts { display: none; }
  .h-rating { grid-column: 9 / 13; }
  .svc-head { grid-column: 1 / -1; }
  .svc-volvo { grid-column: 1 / -1; grid-row: 2; }
  .svc-meh { grid-column: 1 / -1; grid-row: 3; min-height: 26rem; }
  .svc-diag { grid-column: 1 / 7; grid-row: 4; }
  .svc-el { grid-column: 7 / 13; grid-row: 4; }
  .svc-oil { grid-column: 1 / -1; grid-row: 5; }
  .svc { grid-template-rows: none; }
  .rev-rate { grid-column: 1 / 5; }
  .rev-q1 { grid-column: 5 / 13; }
  .rev-q3 { grid-column: 5 / 13; }
  .rev-q2 { grid-column: 1 / -1; grid-row: 3; }
  .t-book { grid-column: 1 / -1; }
  .book-place { grid-column: 1 / 7; }
  .book-addr { grid-column: 7 / 13; }
  .book:has(.book-place) .t-book { grid-row: auto; }
  .f-logo { grid-column: 1 / 5; }
  .f-services { grid-column: 5 / 9; }
  .f-more { grid-column: 9 / 13; }
  .f-contact { grid-column: 1 / -1; }
  .inc > :nth-child(n) { grid-column: span 6; }
  .faq-head { grid-column: 1 / -1; }
  .faq-list { grid-column: 1 / -1; }
  .g-board > section > *, .g-board > .g-fb { grid-column: span 4; }
}

/* ---------- small tablets and phones ---------- */
@media (max-width: 820px) {
  :root { --header: 3.75rem; }
  .nav { display: none; }
  .bar .button--bar { margin-left: auto; }
  .menu-btn { display: inline-flex; align-items: center; margin-left: 0; }
  .menu { position: fixed; top: var(--header); bottom: 0; overflow-y: auto; padding: var(--gap) var(--margin) 6rem; }
  .menu-services { grid-template-columns: 1fr; }
  .menu-services a { grid-template-columns: 6rem 1fr; column-gap: 1rem; align-items: center; padding: 0; }
  .menu-thumb { grid-row: span 2; margin: 0; height: 100%; aspect-ratio: 4 / 3; }
  .menu-name, .menu-sub { padding: 0; }
  .menu-name { align-self: end; }
  .menu-sub { align-self: start; padding-bottom: 0.5rem; }
  .menu-extra { display: grid; gap: var(--gap); grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: var(--gap); }
  .menu-extra a { display: grid; place-items: center; min-height: 3.25rem; border-radius: var(--radius); background: var(--tile); font-weight: 500; text-decoration: none; }
  .menu-contact { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); margin-top: var(--gap); }
  .menu-contact a { display: grid; place-items: center; min-height: 3.25rem; border-radius: var(--radius); background: var(--navy); color: #fff; font-weight: 500; text-decoration: none; }
  .menu-contact a:first-child { background: var(--accent); }

  .board { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; --gap: 6px; }
  .board > * { grid-column: 1 / -1 !important; grid-row: auto !important; }
  .hero { height: auto; grid-template-rows: none; }
  .h-name { min-height: 0; gap: 1rem; }
  .h-photo { aspect-ratio: 4 / 3; }
  .h-call { min-height: 8.5rem; }
  .h-open, .h-rating { grid-column: span 1 !important; min-height: 10rem; }
  .h-open .open-hours { display: none; }
  .h-facts { display: flex; }
  .board > .h-facts { order: 5; }

  .svc-volvo { grid-template-columns: 1fr; }
  .svc-volvo-img { min-height: 13rem; }
  .svc-meh { min-height: 24rem; }
  .board > .svc-diag, .board > .svc-el { grid-column: span 1 !important; }
  .svc-oil { grid-template-columns: 1fr; }
  .svc-oil-img { min-height: 12rem; }

  .vs { grid-auto-rows: auto; }
  .vs-piece { display: none; }
  .vs-whole { display: block; aspect-ratio: 4 / 3; }
  .board > .vs-f1, .board > .vs-f2, .board > .vs-f3, .board > .vs-act { grid-column: span 1 !important; }
  .vs-head { min-height: 0; gap: 0.6rem; }

  .steps { display: block; }
  .steps-title { margin-bottom: 1rem; }
  .steps-row { grid-template-columns: 1fr; grid-template-rows: none; gap: 1.5rem; }
  .step { display: block; grid-row: auto; }
  .step .step-tile { height: auto !important; }
  .step:nth-child(1) .step-tile { aspect-ratio: 16 / 7; }
  .step:nth-child(2) .step-tile { aspect-ratio: 16 / 9; }
  .step:nth-child(3) .step-tile { aspect-ratio: 4 / 3; }
  .step:nth-child(4) .step-tile { aspect-ratio: 1; }

  .pboard { grid-template-rows: none; }
  .board > .p-a, .board > .p-b, .board > .p-c, .board > .p-d { grid-column: span 1 !important; aspect-ratio: 4 / 5; }
  .board > .p-e { aspect-ratio: 16 / 10; }

  .t-book { grid-template-columns: 1fr; }
  .book-head, .book-out { display: block; }
  .book-head p { margin-top: 0.6rem; }
  .book-cells { grid-template-columns: 1fr; }
  .cell--wide { grid-column: auto; }
  .book-preview { margin-top: 0.4rem; }
  .book-alt { margin-top: 0.6rem; }
  .book-label { padding-top: 0; }

  .footer-board .tile-f { grid-column: 1 / -1 !important; }
  .board > .f-services, .board > .f-more { grid-column: span 1 !important; }
  .f-last { flex-wrap: wrap; }

  .s-photo { min-height: 0; aspect-ratio: 4 / 3; }
  .s-hero { grid-template-rows: none; }
  .inc > .t { min-height: 0; }
  .sp > .t-quote { min-height: 0; }
  .sp > .t-photo { min-height: 0; aspect-ratio: 4 / 3; }
  .faq-list { grid-template-columns: 1fr; gap: 6px; }
  .cta-row .t { min-height: 0; }
  .board > .cta-row .t-open, .cta-row > .t-open, .cta-row > .t-where { grid-column: span 1 !important; }
  .board.g-board > section > * { grid-column: span 1; }
  .board.g-board > section > .g-group-head, .board.g-board > .g-fb { grid-column: 1 / -1 !important; }
  .g-board { grid-auto-rows: auto; }
  .c-map { min-height: 0; aspect-ratio: 1; }
  .c-onsite { grid-auto-rows: auto; }
  .board.c-onsite > .t-photo { grid-column: span 1 !important; aspect-ratio: 4 / 5; }
  .board.c-onsite > .t-photo:last-child { grid-column: 1 / -1 !important; aspect-ratio: 16 / 10; }
  .board > .c-hero-pair { grid-column: span 1 !important; }
  .lb-ui { grid-template-columns: 1fr auto; }
  .lb-controls { grid-column: 1 / -1; }
  .lb-controls .lb-btn { flex: 1; }
}

/* ---------- phone: thumb bar with call and Viber ---------- */
@media (max-width: 640px) {
  body { padding-bottom: calc(3.5rem + env(safe-area-inset-bottom)); }
  .bar .button--bar { display: none; }
  .menu-btn { margin-left: auto; }
  .quickbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: var(--bg); transition: transform 320ms var(--ease-out); }
  .quickbar a { display: grid; place-items: center; min-height: 3rem; border-radius: var(--radius); background: var(--navy); color: #fff; font-weight: 500; text-decoration: none; }
  .quickbar a:first-child { background: var(--accent); }
  .quickbar.is-hidden, .quickbar.is-off { transform: translateY(110%); }
  .toast { bottom: calc(4.75rem + env(safe-area-inset-bottom)); }
  .brand-sub { display: none; }
}

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