/* Auto Car Pro by Cardus & Co. — static portfolio demo
   Vintage American garage / service-station look (ported from the Shopify hd-landing theme). */
:root {
  --red: #b8322a;
  --red-dark: #93281f;
  --navy: #16233f;
  --navy-deep: #0f1a30;
  --paper: #f3ecdd;
  --paper-2: #e9dfc8;
  --cream: #fffdf7;
  --brass: #b08d57;
  --green: #2f6b3f;
  --ink: #1c2438;
  --muted: rgba(28, 36, 56, 0.72);
  --line: rgba(28, 36, 56, 0.16);
  --coral: #f47c72;
  --display: 'Oswald', 'Arial Narrow', 'Helvetica Neue', sans-serif;
  --body: 'Libre Franklin', system-ui, -apple-system, sans-serif;
  --script: 'Yellowtail', 'Brush Script MT', cursive;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --max: 1240px;
  --radius: 6px;
  --header-h: 68px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.65 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 3px;
}

.container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 20px;
}

@media (min-width: 750px) {
  .container {
    padding-inline: 40px;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ---------- Paper grain ---------- */
.grain {
  position: relative;
  isolation: isolate;
}

.grain::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.07;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Type ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  font: 500 14px/1.2 var(--display);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red);
}

.eyebrow::before,
.head .eyebrow::after {
  content: '\2605';
  font-size: 11px;
  letter-spacing: 0;
}

.display,
.title,
.h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  text-wrap: balance;
}

.display {
  font-size: clamp(44px, 6.2vw, 92px);
  line-height: 0.96;
  letter-spacing: 0.005em;
}

.title {
  font-size: clamp(36px, 4.6vw, 64px);
  line-height: 1;
  letter-spacing: 0.01em;
}

.h3 {
  font-size: clamp(22px, 2vw, 27px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.02em;
}

:is(.display, .title, .h3) em {
  display: inline-block;
  font-family: var(--script);
  font-size: 1.08em;
  font-style: normal;
  font-weight: 400;
  line-height: 0.8;
  letter-spacing: 0;
  text-transform: none;
  color: var(--red);
  transform: rotate(-4deg) translateY(0.04em);
}

.display em {
  font-size: 0.86em;
  line-height: 1;
  transform: rotate(-4deg) translateY(-0.04em);
}

.lead {
  max-width: 620px;
  margin: 22px 0 0;
  font-size: clamp(17px, 1.35vw, 19px);
  line-height: 1.6;
  color: var(--muted);
}

.head {
  max-width: 820px;
  margin: 0 auto clamp(40px, 5vw, 64px);
  text-align: center;
}

.head .lead {
  margin-inline: auto;
}

.section {
  position: relative;
  padding-block: clamp(68px, 8vw, 112px);
}

.section--cream {
  background: var(--cream);
}

.section--navy {
  background: var(--navy);
  color: var(--paper);
  --muted: rgba(243, 236, 221, 0.78);
  --line: rgba(243, 236, 221, 0.18);
}

.section--navy .eyebrow,
.section--navy :is(.display, .title, .h3) em {
  color: var(--coral);
}

.section--navy.grain::before {
  mix-blend-mode: normal;
  opacity: 0.05;
}

.stripes::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  z-index: 2;
  height: 10px;
  background: repeating-linear-gradient(90deg, var(--red) 0 28px, var(--cream) 28px 56px);
}

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 56px;
  margin: 0;
  padding: 0 28px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: transparent;
  font: 600 16px/1.1 var(--display);
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s, color 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
  transition: transform 0.3s var(--ease);
}

.btn:hover svg {
  transform: translateX(4px);
}

.btn--red {
  background: var(--red);
  color: var(--cream);
  box-shadow: 4px 4px 0 var(--navy);
}

.btn--red:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--navy);
}

.btn--red:active {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 var(--navy);
}

.on-dark .btn--red {
  border-color: var(--cream);
  box-shadow: 4px 4px 0 var(--cream);
}

.on-dark .btn--red:hover {
  box-shadow: 6px 6px 0 var(--cream);
}

.btn--line {
  color: inherit;
  border-color: currentColor;
}

.btn--line:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.on-dark .btn--line:hover {
  background: var(--paper);
  border-color: var(--paper);
  color: var(--navy);
}

.btn--block {
  width: 100%;
}

.btn--sm {
  min-height: 42px;
  padding: 0 16px;
  font-size: 14px;
  box-shadow: 3px 3px 0 var(--navy);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin-top: 34px;
}

/* ---------- Demo bar ---------- */
.demobar {
  position: relative;
  z-index: 60;
  background: var(--navy-deep);
  color: rgba(243, 236, 221, 0.86);
  font: 500 12.5px/1.3 var(--body);
  letter-spacing: 0.02em;
  text-align: center;
}

.demobar .container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  flex-wrap: wrap;
}

.demobar strong {
  font: 600 12.5px/1 var(--display);
  letter-spacing: 0.16em;
  color: var(--cream);
}

.demobar a {
  color: var(--cream);
  text-decoration: underline;
  text-decoration-color: var(--coral);
  text-underline-offset: 3px;
}

.demobar a:hover {
  color: var(--coral);
}

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(243, 236, 221, 0.94);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 2px solid var(--navy);
}

.header .container {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--header-h);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex: none;
}

.logo img {
  width: auto;
  height: 38px;
}

.logo__sub {
  padding-left: 12px;
  border-left: 1.5px solid var(--line);
  font: 600 13px/1.05 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--red);
}

.nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
}

.nav a {
  position: relative;
  padding: 8px 14px;
  font: 500 15px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
}

.nav a::after {
  content: '';
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}

.nav a:hover::after {
  transform: scaleX(1);
}

.cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 44px;
  padding: 0 16px 0 14px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: var(--cream);
  font: 600 14px/1 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.cart-btn:hover {
  background: var(--navy);
  color: var(--cream);
}

.cart-btn svg {
  width: 20px;
  height: 20px;
}

.cart-btn__count {
  display: grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 11px;
  background: var(--red);
  color: var(--cream);
  font: 600 12px/1 var(--display);
  letter-spacing: 0;
}

.cart-btn.is-bump {
  animation: bump 0.5s var(--ease);
}

@keyframes bump {
  30% {
    transform: scale(1.08);
  }
}

@media (max-width: 899px) {
  .nav {
    display: none;
  }

  .cart-btn {
    margin-left: auto;
  }
}

@media (max-width: 520px) {
  :root {
    --header-h: 60px;
  }

  .logo img {
    height: 30px;
  }

  .logo__sub {
    display: none;
  }

  .cart-btn__label {
    display: none;
  }

  .cart-btn {
    padding: 0 12px;
  }
}

/* ---------- Marquee ---------- */
.marquee {
  position: relative;
  overflow: hidden;
  background: var(--red);
  color: var(--cream);
  border-block: 2px solid var(--navy);
}

.marquee__track {
  display: flex;
  width: max-content;
  animation: marquee 38s linear infinite;
}

.marquee__track span {
  display: inline-flex;
  align-items: center;
  gap: 26px;
  padding: 14px 13px;
  font: 600 17px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
}

.marquee__track span::after {
  content: '\2605';
  font-size: 12px;
  color: var(--paper-2);
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

/* ---------- Seal ---------- */
.seal {
  position: relative;
  display: grid;
  place-items: center;
  width: var(--seal, 150px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--red);
  color: var(--cream);
  box-shadow: 0 0 0 5px var(--cream), 0 0 0 7px var(--red), 0 14px 30px -10px rgb(0 0 0 / 0.45);
}

.seal svg {
  position: absolute;
  inset: 6%;
  width: 88%;
  height: 88%;
  animation: spin 28s linear infinite;
}

.seal text {
  fill: currentColor;
  font: 600 13.5px var(--display);
  letter-spacing: 3.2px;
  text-transform: uppercase;
}

.seal__center {
  position: relative;
  text-align: center;
  font-family: var(--display);
  line-height: 0.9;
  text-transform: uppercase;
}

.seal__big {
  display: block;
  font-size: calc(var(--seal, 150px) * 0.3);
  font-weight: 700;
}

.seal__small {
  display: block;
  margin-top: 4px;
  font-size: calc(var(--seal, 150px) * 0.085);
  font-weight: 500;
  letter-spacing: 0.12em;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- Product grid ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px 24px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--cream);
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 6px 8px 0 var(--navy);
}

.card__media {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-bottom: 2px solid var(--navy);
  background: var(--paper-2);
}

.card__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.5s ease, transform 0.8s var(--ease);
}

.card__media img + img {
  opacity: 0;
}

.card:hover .card__media img + img {
  opacity: 1;
}

.card:hover .card__media img {
  transform: scale(1.03);
}

.card__tag {
  position: absolute;
  left: 12px;
  top: 12px;
  z-index: 2;
  padding: 7px 11px;
  border-radius: 3px;
  background: var(--navy);
  color: var(--cream);
  font: 600 11.5px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.card__tag--red {
  background: var(--red);
}

.card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px 20px 20px;
}

.card__kind {
  font: 500 12px/1.2 var(--display);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--red);
}

.card__name {
  margin: 6px 0 6px;
  font: 600 23px/1.08 var(--display);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.card__name a {
  text-decoration: none;
}

.card__name a::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
}

.card__text {
  margin: 0 0 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--muted);
}

.card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
}

.card__foot .btn {
  position: relative;
  z-index: 2;
}

@media (max-width: 1000px) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .grid {
    gap: 14px;
  }

  .card__body {
    padding: 12px 12px 14px;
  }

  .card__name {
    font-size: 17px;
  }

  .card__kind {
    font-size: 10.5px;
    letter-spacing: 0.14em;
  }

  .card__text {
    display: none;
  }

  .card__foot {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .card__foot .price {
    font-size: 18px;
  }

  .card__tag {
    left: 8px;
    top: 8px;
    padding: 6px 8px;
    font-size: 10px;
  }
}

/* ---------- Final CTA ---------- */
.final {
  position: relative;
  overflow: hidden;
  color: var(--cream);
  text-align: center;
}

.final__bg {
  position: absolute;
  inset: 0;
}

.final__bg img, .final__bg video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 60%;
}

.final__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 26, 48, 0.62), rgba(15, 26, 48, 0.78));
}

.final .container {
  padding-block: clamp(90px, 12vw, 160px);
}

.final .title {
  max-width: 900px;
  margin-inline: auto;
}

.final .title em {
  color: var(--coral);
}

.final .lead {
  margin-inline: auto;
  color: rgba(255, 253, 247, 0.85);
}

.final .actions {
  justify-content: center;
}

/* ---------- Footer ---------- */
.footer {
  background: var(--navy-deep);
  color: rgba(243, 236, 221, 0.78);
  font-size: 15px;
}

.footer .container {
  padding-block: 64px 30px;
}

.footer__top {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 40px;
}

.footer__brand img {
  width: 210px;
  height: auto;
}

.footer__brand p {
  max-width: 320px;
  margin: 18px 0 0;
}

.footer__tag {
  display: block;
  margin-top: 12px;
  font: 400 26px/1 var(--script);
  color: var(--coral);
}

.footer h4 {
  margin: 0 0 14px;
  font: 600 14px/1 var(--display);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cream);
}

.footer ul {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer a {
  text-decoration: none;
}

.footer a:hover {
  color: var(--cream);
  text-decoration: underline;
  text-decoration-color: var(--coral);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 30px;
  margin-top: 52px;
  padding-top: 22px;
  border-top: 1px solid rgba(243, 236, 221, 0.14);
  font-size: 13px;
  color: rgba(243, 236, 221, 0.6);
}

.footer__bottom a {
  text-decoration: underline;
}

@media (max-width: 899px) {
  .footer__top {
    grid-template-columns: 1fr 1fr;
  }

  .footer__brand {
    grid-column: 1 / -1;
  }
}

/* ---------- Product page ---------- */
.pdp {
  padding-block: 30px clamp(68px, 8vw, 100px);
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 26px;
  padding: 0;
  list-style: none;
  font: 500 13px/1.3 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.crumbs li + li::before {
  content: '/';
  margin-right: 8px;
  opacity: 0.5;
}

.crumbs a {
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--red);
}

.pdp__grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.gallery {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 16px;
}

.gallery__thumbs {
  display: grid;
  gap: 12px;
  align-content: start;
}

.gallery__thumb {
  padding: 0;
  border: 2px solid transparent;
  border-radius: 4px;
  overflow: hidden;
  background: var(--paper-2);
  cursor: pointer;
  aspect-ratio: 4 / 5;
  transition: border-color 0.2s, opacity 0.2s;
  opacity: 0.7;
}

.gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery__thumb[aria-current='true'] {
  border-color: var(--red);
  opacity: 1;
}

.gallery__thumb:hover {
  opacity: 1;
}

.gallery__main {
  position: relative;
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: var(--paper-2);
  aspect-ratio: 4 / 5;
}

.gallery__main::-webkit-scrollbar {
  display: none;
}

.gallery__main img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  scroll-snap-align: start;
}

.gallery__dots {
  display: none;
}

.pdp__info .eyebrow {
  margin-bottom: 12px;
}

.pdp__title {
  font-size: clamp(36px, 4vw, 54px);
}

.pdp__price {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 18px 0 0;
}

.pdp__price .price {
  font-size: 34px;
}

.pdp__price small {
  font-size: 14px;
  color: var(--muted);
}

.pdp__short {
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.6;
}

.fit {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-top: 26px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  overflow: hidden;
  font-size: 15px;
  line-height: 1.45;
}

.fit div {
  padding: 14px 16px 16px;
  background: var(--cream);
}

.fit div + div {
  border-left: 2px solid var(--navy);
  background: var(--paper-2);
}

.fit b {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  font: 600 13px/1 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.fit div:first-child b {
  color: var(--green);
}

.fit div + div b {
  color: var(--red);
}

.buybox {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  margin-top: 30px;
}

.qty {
  display: inline-flex;
  align-items: center;
  height: 56px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: var(--cream);
}

.qty button {
  width: 46px;
  height: 100%;
  border: 0;
  background: none;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.qty button:hover {
  color: var(--red);
}

.qty output,
.qty span {
  min-width: 34px;
  text-align: center;
  font: 600 18px/1 var(--display);
}

.qty--sm {
  height: 38px;
  border-width: 1.5px;
}

.qty--sm button {
  width: 34px;
  font-size: 18px;
}

.qty--sm span {
  min-width: 24px;
  font-size: 15px;
}

.pdp__assure {
  display: grid;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
}

.pdp__assure li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pdp__assure svg {
  width: 20px;
  height: 20px;
  color: var(--brass);
  flex: none;
}

.acc {
  margin-top: 32px;
  border-top: 2px solid var(--navy);
}

.acc details {
  border-bottom: 2px solid var(--navy);
}

.acc summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 2px;
  font: 600 16px/1.2 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  list-style: none;
}

.acc summary::-webkit-details-marker {
  display: none;
}

.acc summary::after {
  content: '+';
  font: 400 24px/1 var(--display);
  transition: transform 0.3s var(--ease);
}

.acc details[open] summary::after {
  transform: rotate(45deg);
}

.acc__body {
  padding: 0 2px 18px;
  font-size: 15.5px;
  color: var(--muted);
}

.acc__body ol,
.acc__body ul {
  margin: 0;
  padding-left: 20px;
}

.acc__body li + li {
  margin-top: 6px;
}

.related {
  margin-top: clamp(64px, 8vw, 100px);
}

.related .grid .card__text {
  display: none;
}

@media (max-width: 899px) {
  .pdp__grid {
    grid-template-columns: 1fr;
  }

  .gallery {
    position: relative;
    top: 0;
    grid-template-columns: 1fr;
  }

  .gallery__thumbs {
    display: none;
  }

  .gallery__dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
  }

  .gallery__dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--line);
    transition: background 0.2s, width 0.2s;
  }

  .gallery__dots span.is-on {
    width: 22px;
    border-radius: 4px;
    background: var(--red);
  }
}

@media (max-width: 560px) {
  .buybox .btn {
    padding: 0 12px;
    font-size: 15px;
    letter-spacing: 0.06em;
  }

  .fit {
    grid-template-columns: 1fr;
  }

  .fit div + div {
    border-left: 0;
    border-top: 2px solid var(--navy);
  }

  .related .grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .related .grid .card:nth-child(3) {
    display: none;
  }
}

/* ---------- Cart drawer ---------- */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(15, 26, 48, 0.55);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s;
}

.overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
  width: min(440px, 100%);
  background: var(--paper);
  border-left: 2px solid var(--navy);
  box-shadow: -30px 0 60px -30px rgb(0 0 0 / 0.5);
  transform: translateX(105%);
  transition: transform 0.45s var(--ease);
}

.drawer.is-open {
  transform: none;
}

.drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  background: var(--navy);
  color: var(--cream);
}

.drawer__head h2 {
  margin: 0;
  font: 600 22px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.drawer__head h2 em {
  font: 400 1.1em/1 var(--script);
  text-transform: none;
  letter-spacing: 0;
  color: var(--coral);
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 2px solid currentColor;
  border-radius: 50%;
  background: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.icon-btn:hover {
  background: var(--cream);
  color: var(--navy);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

.drawer__ship {
  padding: 14px 22px 16px;
  border-bottom: 2px solid var(--navy);
  background: var(--cream);
  font-size: 14px;
}

.drawer__bar {
  height: 8px;
  margin-top: 8px;
  border-radius: 4px;
  background: var(--paper-2);
  overflow: hidden;
}

.drawer__bar span {
  display: block;
  height: 100%;
  background: repeating-linear-gradient(90deg, var(--red) 0 12px, #cf4a40 12px 24px);
  transition: width 0.5s var(--ease);
}

.drawer__body {
  flex: 1;
  overflow-y: auto;
  padding: 8px 22px;
}

.line {
  display: grid;
  grid-template-columns: 76px 1fr auto;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1.5px solid var(--line);
}

.line img {
  width: 76px;
  height: 95px;
  object-fit: cover;
  border: 1.5px solid var(--navy);
  border-radius: 4px;
  background: var(--paper-2);
}

.line__name {
  display: block;
  font: 600 17px/1.15 var(--display);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-decoration: none;
}

.line__kind {
  display: block;
  margin: 3px 0 10px;
  font-size: 13px;
  color: var(--muted);
}

.line__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
}

.line__price {
  font: 600 17px/1 var(--display);
}

.line__remove {
  padding: 0;
  border: 0;
  background: none;
  font-size: 13px;
  color: var(--muted);
  text-decoration: underline;
  cursor: pointer;
}

.line__remove:hover {
  color: var(--red);
}

.drawer__empty {
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 60px 10px;
  text-align: center;
}

.drawer__empty p {
  margin: 0;
  font: 400 34px/1 var(--script);
  color: var(--red);
}

.drawer__empty span {
  margin-bottom: 18px;
  color: var(--muted);
}

.drawer__foot {
  padding: 18px 22px 22px;
  border-top: 2px solid var(--navy);
  background: var(--cream);
}

.drawer__sub {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 4px;
  font: 600 18px/1 var(--display);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.drawer__sub .price {
  font-size: 26px;
}

.drawer__fine {
  margin: 0 0 16px;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- Demo modal ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 26, 48, 0.6);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.modal.is-open {
  opacity: 1;
  visibility: visible;
}

.modal__box {
  position: relative;
  width: min(460px, 100%);
  padding: 44px 32px 30px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: var(--paper);
  text-align: center;
  box-shadow: 8px 8px 0 var(--red);
  transform: translateY(16px) scale(0.98);
  transition: transform 0.4s var(--ease);
}

.modal.is-open .modal__box {
  transform: none;
}

.modal__box .seal {
  --seal: 96px;
  margin: -92px auto 18px;
}

.modal__box h2 {
  margin: 0;
  font: 700 30px/1.05 var(--display);
  text-transform: uppercase;
}

.modal__box h2 em {
  font: 400 1.1em/1 var(--script);
  text-transform: none;
  color: var(--red);
}

.modal__box p {
  margin: 14px 0 24px;
  color: var(--muted);
}

.modal__box .actions {
  justify-content: center;
  margin-top: 0;
  gap: 12px;
}

.modal__box .actions {
  flex-direction: column;
  align-items: stretch;
}

.modal__box .btn {
  width: 100%;
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  z-index: 110;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border: 2px solid var(--navy);
  border-radius: var(--radius);
  background: var(--cream);
  font: 500 14px/1.2 var(--display);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 4px 4px 0 var(--navy);
  transform: translate(-50%, calc(100% + 40px));
  visibility: hidden;
  transition: transform 0.4s var(--ease), visibility 0.4s;
}

.toast.is-on {
  transform: translate(-50%, 0);
  visibility: visible;
}

.toast svg {
  width: 18px;
  height: 18px;
  color: var(--green);
}

/* ---------- Reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
  transition-delay: var(--d, 0s);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  html {
    scroll-behavior: auto;
  }
}
