:root {
  --canvas: #F9FAF9;
  --text: #1A2D25;
  --muted: #65716C;
  --line: rgba(51, 88, 75, 0.68);
  --line-soft: rgba(51, 88, 75, 0.12);
  --panel: rgba(255, 255, 255, 0.78);
  --card: rgba(255, 255, 255, 0.88);
  --soft: #EEF2EF;
  --soft-strong: #E7ECE8;
  --block: #33584B;
  --block-deep: #102D24;
  --accent: #A7664B;
  --shadow: 0 24px 60px rgba(26, 45, 37, 0.1);
  --radius: 22px;
  --radius-sm: 12px;
  --speed: 180ms ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html.is-locked,
html.is-locked body {
  overflow: hidden;
}

body {
  margin: 0;
  min-width: 320px;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  font-weight: 500;
  color: var(--text);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

button,
fieldset {
  border: 0;
}

input,
textarea,
select {
  outline: none;
}

input::placeholder,
textarea::placeholder {
  color: rgba(26, 45, 37, 0.38);
}

a {
  color: inherit;
  text-decoration: none;
}

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

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

.shell {
  width: min(1280px, calc(100% - 84px));
  margin: 0 auto;
}

.page {
  min-height: 100vh;
}

.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;
}


button:disabled {
  cursor: not-allowed;
  opacity: 0.56;
  box-shadow: none;
}

.button,
.card-button,
.contact-submit,
.summary-submit,
.drawer-checkout,
.success-button,
.ghost-button {
  appearance: none;
  min-height: 52px;
  padding: 0 24px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  transition: transform var(--speed), background-color var(--speed), border-color var(--speed), color var(--speed), box-shadow var(--speed), opacity var(--speed);
}

.button,
.contact-submit,
.summary-submit,
.drawer-checkout,
.success-button {
  background: var(--block);
  color: var(--canvas);
  box-shadow: 0 14px 30px rgba(26, 45, 37, 0.14);
}

.button:hover,
.button:focus-visible,
.contact-submit:hover,
.contact-submit:focus-visible,
.summary-submit:hover,
.summary-submit:focus-visible,
.drawer-checkout:hover,
.drawer-checkout:focus-visible,
.success-button:hover,
.success-button:focus-visible {
  background: #2A473D;
}

.button:active,
.card-button:active,
.contact-submit:active,
.summary-submit:active,
.drawer-checkout:active,
.success-button:active,
.ghost-button:active,
.icon-button:active,
.floating-cart:active,
.drawer-close:active,
.modal-close:active,
.contact-close:active,
.qty-step:active,
.drawer-line__remove:active,
.nav-toggle:active,
.success-close:active {
  transform: translateY(1px);
}

.card-button,
.ghost-button {
  min-height: 40px;
  padding: 0 18px;
  background: transparent;
  color: var(--text);
  border: 1.3px solid rgba(51, 88, 75, 0.44);
  box-shadow: none;
}

.card-button:hover,
.card-button:focus-visible,
.ghost-button:hover,
.ghost-button:focus-visible {
  background: rgba(51, 88, 75, 0.05);
  border-color: rgba(51, 88, 75, 0.7);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(249, 250, 249, 0.94);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(26, 45, 37, 0.06);
}

.header-bar {
  min-height: 90px;
  display: grid;
  grid-template-columns: auto auto 1fr auto auto auto;
  align-items: center;
  gap: 26px;
}

.logo {
  display: inline-flex;
  align-items: center;
  font-size: clamp(2.55rem, 3.9vw, 3.85rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.09em;
  color: var(--text);
}

.logo__accent {
  display: inline-block;
  font-style: italic;
  transform: skewX(-10deg);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
}

.main-nav a {
  position: relative;
  font-size: 1rem;
  line-height: 1;
  color: rgba(26, 45, 37, 0.92);
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform var(--speed);
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  transform: scaleX(1);
}

.header-spacer {
  min-width: 1px;
}

.header-socials {
  display: flex;
  align-items: center;
  gap: 18px;
}

.icon-button,
.nav-toggle,
.drawer-close,
.modal-close,
.contact-close,
.qty-step,
.drawer-line__remove,
.success-close,
.floating-cart {
  appearance: none;
  padding: 0;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: transparent;
  color: var(--text);
  transition: transform var(--speed), opacity var(--speed);
}

.icon-button:hover,
.icon-button:focus-visible {
  opacity: 0.72;
}

.icon-button svg,
.header-cart svg,
.floating-cart svg {
  width: 100%;
  height: 100%;
}

.header-phone {
  white-space: nowrap;
  font-size: 1rem;
  letter-spacing: 0.05em;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cart-button,
.floating-cart {
  position: relative;
}

.header-cart {
  width: 24px;
  height: 24px;
}

.page-home .header-cart {
  display: none;
}

.cart-badge {
  position: absolute;
  top: -6px;
  right: -8px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--accent);
  color: #FFFFFF;
  font-size: 0.67rem;
  font-weight: 700;
  line-height: 1;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(51, 88, 75, 0.06);
  color: var(--text);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

.hero {
  padding: 0 0 52px;
}

.hero-stage {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  background: #FFFFFF;

}

.hero-visual {
  position: absolute;
  inset: 0;
  --hero-custom-image: url("../images/IMG_4962.jpg");

  border-bottom: none;

  background-image: var(--hero-custom-image);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;

  opacity: 0.25; /* 50% прозрачности */
}

.hero-content {
  position: relative;
  z-index: 1;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-copy {
  width: min(860px, 100%);
  max-width: 860px;
  margin: 0 auto;
  padding: 84px 0 96px;
  text-align: left;
}

.hero-copy h1 {
  font-size: clamp(3.8rem, 5.1vw, 5.75rem);
  line-height: 0.95;
  font-weight: 800;
  letter-spacing: -0.07em;
  white-space: nowrap;
}

.hero-copy p {
  max-width: 760px;
  margin-top: 18px;
  font-size: 1.18rem;
  line-height: 1.48;
  color: var(--muted);
}

.hero-button {
  margin-top: 28px;
  min-width: 150px;
}

.catalog {
  position: relative;
  padding: 18px 0 96px;
}

.catalog::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/topography.svg") center top / 1600px auto repeat-y;
  opacity: 0.33;
  pointer-events: none;
}

.catalog .shell,
.about .shell,
.contacts .shell,
.checkout-main .shell {
  position: relative;
  z-index: 1;
}

.catalog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.product-card {
  position: relative;
  padding: 14px 14px 16px;
  background: rgba(255, 255, 255, 0.74);
  border-radius: 16px;
  border: 1px solid rgba(51, 88, 75, 0.08);
  box-shadow: 0 12px 26px rgba(26, 45, 37, 0.04);
}

.product-card__media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 0.98;
  overflow: hidden;
  background: var(--block);
  border: 1px solid rgba(51, 88, 75, 0.14);
  border-radius: 8px;
  transition: border-color var(--speed), box-shadow var(--speed), transform var(--speed);
}

.product-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-card.is-in-cart .product-card__media {
  border-color: rgba(51, 88, 75, 0.3);
  box-shadow: inset 0 0 0 2px rgba(51, 88, 75, 0.14);
}

.product-card__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 0 0;
}

.product-card__title,
.drawer-line__title,
.checkout-item__title {
  font-size: 1.42rem;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.045em;
}

.product-card__subtitle,
.drawer-line__subtitle,
.checkout-item__subtitle,
.section-text,
.contacts__text,
.drawer-subtitle,
.modal-subtitle,
.contact-subtitle,
.contact-dialog__note,
.success-text,
.checkout-empty p,
.modal-copy__text {
  color: var(--muted);
}

.product-card__subtitle,
.drawer-line__subtitle,
.checkout-item__subtitle {
  font-size: 0.96rem;
  line-height: 1.35;
}

.product-card__price,
.checkout-item__price,
.summary-total strong,
.drawer-total strong,
.drawer-line__price,
.modal-price,
.success-row strong {
  color: var(--accent);
}

.product-card__price {
  margin-top: 4px;
  font-size: 1.4rem;
  font-weight: 600;
}

.product-card__actions {
  margin-top: 8px;
}

.card-button {
  width: 100%;
  min-height: 38px;
  border-radius: 8px;
  font-size: 0.94rem;
}

.about {
  padding: 92px 0 96px;
  background: var(--soft);
}

.section-title {
  font-size: clamp(3.1rem, 4.9vw, 5.2rem);
  font-weight: 800;
  line-height: 0.96;
  letter-spacing: -0.075em;
}

.section-title--center,
.section-text,
.about-tags,
.contacts {
  text-align: center;
}

.section-text {
  max-width: 900px;
  margin: 18px auto 0;
  font-size: 1.16rem;
  line-height: 1.62;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 38px;
}

.about-block,
.checkout-thumb,
.drawer-thumb {
  position: relative;
  overflow: hidden;
  background: var(--block);
}

.checkout-thumb,
.drawer-thumb,
.product-preview {
  border: 1px solid rgba(51, 88, 75, 0.12);
}

.about-block {
  aspect-ratio: 1 / 0.76;
  border-radius: 6px;
}

.about-block::before,
.checkout-thumb::before,
.drawer-thumb::before,
.product-card__media::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.05), rgba(0, 0, 0, 0.08)),
    radial-gradient(circle at 18% 16%, rgba(255, 255, 255, 0.1), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.04));
}

.about-tags {
  margin-top: 24px;
  font-size: 1.14rem;
  letter-spacing: 0.02em;
}

.contacts {
  padding: 92px 0 110px;
}

.contacts__text {
  max-width: 670px;
  margin: 18px auto 0;
  font-size: 1.18rem;
  line-height: 1.6;
}

.contacts__actions {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

.site-footer {
  background: linear-gradient(90deg, #102D24 0%, #0B261F 100%);
  color: rgba(249, 250, 249, 0.96);
}

.site-footer__inner {
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.site-footer__copy {
  font-size: 0.92rem;
  letter-spacing: 0.02em;
}

.floating-cart {
  position: fixed;
  right: 28px;
  bottom: 28px;
  z-index: 55;
  width: 68px;
  height: 68px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--block);
  color: var(--canvas);
  box-shadow: 0 18px 42px rgba(26, 45, 37, 0.22);
  transition: transform var(--speed), background-color var(--speed), box-shadow var(--speed);
}

.floating-cart:hover,
.floating-cart:focus-visible {
  background: #2A473D;
}

.floating-cart svg {
  width: 28px;
  height: 28px;
}

.floating-cart .cart-badge {
  top: 9px;
  right: 10px;
}

dialog {
  margin: 0;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
}

dialog::backdrop {
  background: rgba(14, 25, 20, 0.26);
  backdrop-filter: blur(4px);
}

.drawer-dialog,
.modal-dialog {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
}

.drawer-dialog[open] {
  display: flex;
  justify-content: flex-end;
  align-items: stretch;
}

.modal-dialog[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-card {
  width: min(460px, 100vw);
  height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: rgba(249, 250, 249, 0.98);
  border-left: 1px solid rgba(51, 88, 75, 0.14);
  box-shadow: -26px 0 56px rgba(26, 45, 37, 0.14);
}

.drawer-head,
.modal-head,
.contact-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.drawer-head {
  padding: 28px 28px 22px;
  border-bottom: 1px solid rgba(51, 88, 75, 0.08);
}

.drawer-title,
.modal-title,
.contact-title,
.success-title {
  font-size: 2.15rem;
  line-height: 0.98;
  font-weight: 800;
  letter-spacing: -0.06em;
}

.drawer-subtitle,
.modal-subtitle,
.contact-subtitle {
  margin-top: 8px;
  font-size: 0.98rem;
}

.drawer-close,
.modal-close,
.contact-close {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(51, 88, 75, 0.08);
  color: var(--text);
  transition: background-color var(--speed), transform var(--speed);
}

.drawer-close:hover,
.drawer-close:focus-visible,
.modal-close:hover,
.modal-close:focus-visible,
.contact-close:hover,
.contact-close:focus-visible,
.qty-step:hover,
.qty-step:focus-visible,
.drawer-line__remove:hover,
.drawer-line__remove:focus-visible,
.success-close:hover,
.success-close:focus-visible,
.nav-toggle:hover,
.nav-toggle:focus-visible {
  background: rgba(51, 88, 75, 0.14);
}

.drawer-close svg,
.modal-close svg,
.contact-close svg,
.drawer-line__remove svg,
.success-close svg {
  width: 20px;
  height: 20px;
}

.drawer-body {
  padding: 22px 28px 24px;
  overflow: auto;
}

.drawer-empty {
  display: grid;
  gap: 12px;
  padding: 14px 2px;
}

.drawer-empty h3,
.checkout-empty h3 {
  font-size: 1.8rem;
  line-height: 1.02;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.drawer-line {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 16px;
  padding: 14px;
  border-radius: 16px;
  background: #FFFFFF;
  border: 1px solid rgba(51, 88, 75, 0.08);
  box-shadow: 0 10px 28px rgba(26, 45, 37, 0.05);
}

.drawer-line + .drawer-line {
  margin-top: 14px;
}

.drawer-thumb {
  width: 88px;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
}

.drawer-line__meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 18px;
  align-items: start;
}

.drawer-line__size,
.checkout-item__size {
  margin-top: 6px;
  font-size: 0.92rem;
  color: rgba(26, 45, 37, 0.7);
}

.drawer-line__price,
.modal-price,
.success-row strong {
  font-size: 1.36rem;
  font-weight: 600;
}

.drawer-line__side {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.drawer-line__remove,
.qty-step,
.success-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.drawer-line__remove {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: rgba(167, 102, 75, 0.12);
  color: var(--accent);
}

.qty-inline,
.qty-box {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  width: fit-content;
  gap: 2px;
  padding: 3px;
  border-radius: 999px;
  background: rgba(51, 88, 75, 0.08);
}

.qty-step {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font-size: 1rem;
  transition: background-color var(--speed), transform var(--speed);
}

.qty-value {
  min-width: 20px;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 700;
}

.drawer-footer {
  padding: 20px 28px 28px;
  border-top: 1px solid rgba(51, 88, 75, 0.08);
}

.drawer-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  font-size: 1.08rem;
}

.drawer-total strong,
.summary-total strong {
  font-size: 1.42rem;
  font-weight: 700;
}

.drawer-checkout {
  width: 100%;
}

.modal-card,
.contact-card,
.success-card {
  width: min(960px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 28px 30px 30px;
  border-radius: 24px;
  background: rgba(249, 250, 249, 0.98);
  border: 1px solid rgba(51, 88, 75, 0.12);
  box-shadow: 0 30px 80px rgba(26, 45, 37, 0.18);
}

.contact-card {
  width: min(760px, calc(100vw - 32px));
}

.success-card {
  width: min(620px, calc(100vw - 32px));
  text-align: center;
}

.product-modal__body {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(320px, 1fr);
  align-items: start;
  gap: 28px;
  margin-top: 22px;
}

.product-preview {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(180deg, #E9ECE9 0%, #DEE4E0 100%);
}

.product-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-copy {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.modal-copy__text {
  font-size: 1rem;
  line-height: 1.65;
}

.modal-price {
  font-size: 2rem;
}

.modal-group {
  display: grid;
  gap: 12px;
}

.modal-group__label {
  font-size: 0.96rem;
}

.size-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.size-chip {
  appearance: none;
  min-width: 54px;
  height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1.2px solid rgba(51, 88, 75, 0.3);
  background: #FFFFFF;
  transition: background-color var(--speed), border-color var(--speed), color var(--speed), transform var(--speed);
}

.size-chip:hover,
.size-chip:focus-visible {
  border-color: rgba(51, 88, 75, 0.65);
}

.size-chip.is-active {
  background: var(--block);
  border-color: var(--block);
  color: var(--canvas);
}

.modal-actions,
.contact-actions,
.success-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.contact-form {
  margin-top: 22px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 22px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.field--wide {
  grid-column: 1 / -1;
}

.field span {
  font-size: 1rem;
}

.field-control,
.field textarea,
.field select {
  width: 100%;
  border-radius: 12px;
  border: 1.6px solid var(--line);
  background: rgba(249, 250, 249, 0.25);
  color: var(--text);
  transition: border-color var(--speed), box-shadow var(--speed), background-color var(--speed);
}

.field-control,
.field select {
  height: 58px;
  padding: 0 18px;
}

.field textarea {
  min-height: 118px;
  padding: 14px 16px;
  resize: vertical;
}

.select-wrap {
  position: relative;
  display: block;
}

.select-wrap::before {
  content: "▼";
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.96rem;
  line-height: 1;
  pointer-events: none;
  color: var(--text);
}

.select-wrap select {
  appearance: none;
  padding-left: 38px;
  padding-right: 16px;
}

.field-control:focus,
.field textarea:focus,
.select-wrap select:focus {
  background: rgba(255, 255, 255, 0.85);
  border-color: var(--block);
  box-shadow: 0 0 0 3px rgba(173, 225, 216, 0.34);
}

.field-control:invalid:user-invalid,
.field textarea:invalid:user-invalid,
.select-wrap select:invalid:user-invalid {
  border-color: rgba(167, 102, 75, 0.72);
}

.contact-dialog__note {
  margin-top: 16px;
  font-size: 0.96rem;
}

.success-mark {
  width: 74px;
  height: 74px;
  margin: 0 auto 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(51, 88, 75, 0.1);
  color: var(--block);
}

.success-mark svg {
  width: 38px;
  height: 38px;
}

.success-title {
  font-size: 2.4rem;
}

.success-text {
  margin-top: 12px;
  font-size: 1.02rem;
  line-height: 1.6;
}

.success-content {
  margin-top: 24px;
  display: grid;
  gap: 22px;
}

.success-rows {
  display: grid;
  gap: 12px;
  text-align: left;
}

.success-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(51, 88, 75, 0.08);
}

.success-row span {
  color: var(--muted);
}

.toast-area {
  position: fixed;
  top: 94px;
  right: 18px;
  z-index: 80;
  display: grid;
  justify-items: end;
  gap: 10px;
  pointer-events: none;
}

.toast {
  min-width: 260px;
  max-width: min(420px, calc(100vw - 32px));
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(26, 45, 37, 0.92);
  color: #FFFFFF;
  box-shadow: 0 18px 40px rgba(26, 45, 37, 0.18);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--speed), transform var(--speed);
}

.toast--error {
  background: rgba(167, 102, 75, 0.96);
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.checkout-main {
  position: relative;
  min-height: calc(100vh - 90px);
  margin-top: -1px;
  padding: 0 0 86px;
  overflow: hidden;
}

.checkout-main::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../images/gait-watermark.webp") center top / 1520px auto no-repeat;
  opacity: 0.24;
  pointer-events: none;
}

.checkout-heading {
  padding: 42px 0 38px;
  text-align: center;
}

.checkout-heading h1 {
  font-size: clamp(3.9rem, 7vw, 6.8rem);
  line-height: 0.94;
  font-weight: 800;
  letter-spacing: -0.08em;
}

.checkout-layout {
  display: grid;
  grid-template-columns: minmax(340px, 0.94fr) minmax(420px, 1.06fr);
  gap: 72px;
  align-items: start;
}

.summary-panel__heading,
.form-block h2 {
  margin-bottom: 20px;
}

.summary-panel__heading h2,
.form-block h2 {
  font-size: 2rem;
  line-height: 1.03;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.summary-items {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.checkout-item {
  display: grid;
  grid-template-columns: 102px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(51, 88, 75, 0.08);
  box-shadow: 0 10px 24px rgba(26, 45, 37, 0.04);
}

.checkout-thumb {
  width: 102px;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
}

.checkout-item__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.checkout-item__qty {
  width: 38px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: var(--block);
  color: var(--canvas);
  font-size: 1.08rem;
  font-weight: 700;
}

.checkout-item__price {
  font-size: 1.34rem;
  font-weight: 600;
  white-space: nowrap;
}

.summary-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin: 18px 0 28px;
  font-size: 1.18rem;
  line-height: 1.4;
}

.summary-submit {
  min-width: 240px;
}

.form-block + .form-block {
  margin-top: 34px;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 22px;
}

.checkout-empty {
  display: grid;
  gap: 12px;
  padding: 16px 0 0;
}

.page-checkout .site-header {
  box-shadow: none;
}

@media (max-width: 1180px) {
  .shell {
    width: min(1280px, calc(100% - 56px));
  }

  .header-bar {
    gap: 20px;
  }

  .main-nav {
    gap: 26px;
  }

  .hero-stage {
    min-height: 560px;
  }

  .hero-content {
    min-height: 560px;
  }

  .hero-copy {
    width: min(820px, 100%);
    max-width: 820px;
    padding: 72px 0 84px;
  }

  .catalog-grid,
  .about-grid {
    gap: 22px;
  }

  .checkout-layout {
    gap: 46px;
  }
}

@media (max-width: 980px) {
  .shell {
    width: min(1280px, calc(100% - 40px));
  }

  .header-bar {
    position: relative;
    grid-template-columns: auto 1fr auto auto;
    gap: 16px;
  }

  .header-spacer,
  .header-socials,
  .header-phone {
    display: none;
  }

  .main-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 10px);
    display: none;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    padding: 20px;
    background: rgba(249, 250, 249, 0.98);
    border: 1px solid rgba(51, 88, 75, 0.12);
    border-radius: 18px;
    box-shadow: 0 18px 36px rgba(26, 45, 37, 0.1);
  }

  .main-nav.is-open {
    display: flex;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .hero-stage {
    min-height: 500px;
  }

  .hero-content {
    min-height: 500px;
  }

  .hero-copy {
    width: min(720px, 100%);
    max-width: 720px;
    padding: 56px 0 72px;
  }

  .hero-copy h1 {
    white-space: normal;
  }

  .catalog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .about-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .checkout-layout,
  .product-modal__body {
    grid-template-columns: 1fr;
  }

  .form-panel {
    order: 2;
  }

  .summary-panel {
    order: 1;
  }

  .checkout-heading {
    padding-top: 28px;
  }
}

@media (max-width: 720px) {
  .site-header {
    box-shadow: 0 1px 0 rgba(26, 45, 37, 0.04);
  }

  .logo {
    font-size: 2.3rem;
  }

  .hero-stage {
    min-height: 420px;
  }

  .hero-content {
    min-height: 420px;
  }

  .hero-copy {
    width: min(100%, 560px);
    max-width: 560px;
    padding: 46px 0 56px;
  }

  .hero-copy h1,
  .checkout-heading h1,
  .section-title {
    font-size: clamp(2.65rem, 10vw, 4rem);
  }

  .hero-copy p,
  .section-text,
  .contacts__text {
    font-size: 1rem;
  }

  .catalog-grid,
  .about-grid,
  .contact-grid,
  .field-grid {
    grid-template-columns: 1fr;
  }

  .product-card__title,
  .drawer-line__title,
  .checkout-item__title {
    font-size: 1.2rem;
  }

  .checkout-item {
    grid-template-columns: 78px minmax(0, 1fr) auto;
    gap: 14px;
  }

  .checkout-thumb {
    width: 78px;
  }

  .checkout-item__price {
    grid-column: 2 / 3;
    justify-self: start;
  }

  .checkout-item__qty {
    width: 34px;
    height: 40px;
  }

  .summary-total {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .summary-submit,
  .contact-submit,
  .success-button,
  .ghost-button,
  .button,
  .drawer-checkout {
    width: 100%;
  }

  .drawer-card {
    width: 100vw;
  }

  .drawer-head,
  .drawer-body,
  .drawer-footer,
  .modal-card,
  .contact-card,
  .success-card {
    padding-left: 18px;
    padding-right: 18px;
  }

  .modal-actions,
  .contact-actions,
  .success-actions {
    flex-direction: column;
  }

  .floating-cart {
    right: 16px;
    bottom: 16px;
    width: 60px;
    height: 60px;
  }

  .toast-area {
    top: 86px;
    left: 14px;
    right: 14px;
    justify-items: stretch;
  }

  .toast {
    max-width: none;
  }
}

@media (max-width: 560px) {
  .shell {
    width: min(1280px, calc(100% - 28px));
  }

  .header-bar {
    min-height: 78px;
  }

  .product-card,
  .checkout-item,
  .drawer-line {
    padding: 12px;
  }

  .product-preview {
    aspect-ratio: 1 / 0.94;
  }

  .modal-card,
  .contact-card,
  .success-card {
    width: calc(100vw - 20px);
    padding-top: 20px;
    padding-bottom: 20px;
    border-radius: 20px;
  }

  .product-modal__body {
    gap: 18px;
  }

  .success-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
}


/* === GAIT refinement update === */
:root {
  --speed: 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

body {
  background: linear-gradient(180deg, #FBFCFB 0%, #F7FAF8 18%, var(--canvas) 100%);
}

.header-socials {
  gap: 12px;
}

.social-link {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: rgba(51, 88, 75, 0.06);
}

.social-link svg {
  width: 18px;
  height: 18px;
}

.social-link:hover,
.social-link:focus-visible {
  opacity: 1;
  background: rgba(51, 88, 75, 0.12);
  transform: translateY(-1px);
}

.hero {
  padding: 0 0 28px;
}

.hero-stage {
  background: linear-gradient(180deg, #FBFCFB 0%, #F7FAF8 36%, #F1F6F3 72%, var(--canvas) 100%);
}

.hero-stage::before {
  content: "";
  position: absolute;
  inset: -8% -10% 18% -10%;
  background: radial-gradient(circle at 14% 16%, rgba(178, 225, 216, 0.34), transparent 28%), radial-gradient(circle at 88% 14%, rgba(201, 235, 229, 0.32), transparent 24%), radial-gradient(circle at 56% 100%, rgba(206, 233, 227, 0.68), transparent 38%);
  pointer-events: none;
}

.hero-stage::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 180px;
  background: linear-gradient(180deg, rgba(241, 246, 243, 0) 0%, rgba(241, 246, 243, 0.8) 48%, var(--canvas) 100%);
  pointer-events: none;
}

.hero-visual {
  opacity: 0.36;
  background-position: center 44%;
  filter: saturate(0.96);
}

.catalog {
  padding-top: 8px;
}

.product-card {
  overflow: hidden;
  transition: transform var(--speed), box-shadow var(--speed), border-color var(--speed), background-color var(--speed);
}

.product-card:hover,
.product-card:focus-within {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(51, 88, 75, 0.14);
  box-shadow: 0 22px 40px rgba(26, 45, 37, 0.08);
}

.product-card__media,
.card-button,
.qty-inline,
.qty-box,
.drawer-line,
.checkout-item,
.drawer-card,
.modal-card,
.contact-card,
.success-card,
.choice-card__body {
  transition: transform var(--speed), box-shadow var(--speed), border-color var(--speed), background-color var(--speed), opacity var(--speed);
}

.card-button,
.drawer-checkout,
.summary-submit,
.button,
.contact-submit,
.success-button {
  position: relative;
  overflow: hidden;
}

.card-button::after,
.drawer-checkout::after,
.summary-submit::after,
.button::after,
.contact-submit::after,
.success-button::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.18) 46%, transparent 72%);
  opacity: 0;
  transform: translateX(-120%);
  transition: transform 520ms ease, opacity 320ms ease;
}

.card-button:hover::after,
.card-button:focus-visible::after,
.drawer-checkout:hover::after,
.drawer-checkout:focus-visible::after,
.summary-submit:hover::after,
.summary-submit:focus-visible::after,
.button:hover::after,
.button:focus-visible::after,
.contact-submit:hover::after,
.contact-submit:focus-visible::after,
.success-button:hover::after,
.success-button:focus-visible::after {
  opacity: 1;
  transform: translateX(120%);
}

.floating-cart,
.header-cart {
  overflow: visible;
  isolation: isolate;
}

.floating-cart {
  width: 74px;
  height: 74px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(155deg, #355C4E 0%, #17342B 100%);
  box-shadow: 0 22px 54px rgba(26, 45, 37, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.floating-cart::before,
.header-cart::before {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: inherit;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
  opacity: 0.72;
  z-index: -1;
}

.floating-cart::after,
.header-cart::after {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: inherit;
  background: radial-gradient(circle, rgba(51, 88, 75, 0.22), rgba(51, 88, 75, 0) 70%);
  opacity: 0;
  transform: scale(0.82);
  transition: opacity var(--speed), transform var(--speed);
  z-index: -2;
}

.floating-cart:hover::after,
.floating-cart:focus-visible::after,
.floating-cart.is-filled::after,
.header-cart:hover::after,
.header-cart:focus-visible::after,
.header-cart.is-filled::after {
  opacity: 1;
  transform: scale(1);
}

.floating-cart.is-filled,
.header-cart.is-filled {
  box-shadow: 0 24px 58px rgba(26, 45, 37, 0.24), 0 0 0 9px rgba(51, 88, 75, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.floating-cart svg,
.floating-cart .cart-badge,
.header-cart svg,
.header-cart .cart-badge {
  position: relative;
  z-index: 1;
}

.floating-cart.is-bump,
.header-cart.is-bump {
  animation: cartButtonBump 620ms cubic-bezier(0.22, 1, 0.36, 1);
}

.floating-cart .cart-badge,
.header-cart .cart-badge {
  transition: transform var(--speed), opacity var(--speed), background-color var(--speed);
}

.floating-cart.is-bump .cart-badge,
.header-cart.is-bump .cart-badge {
  animation: badgePop 620ms cubic-bezier(0.22, 1, 0.36, 1);
}

.drawer-card {
  background: linear-gradient(180deg, rgba(249, 250, 249, 0.99) 0%, rgba(244, 248, 246, 0.98) 100%);
}

.drawer-line,
.checkout-item {
  position: relative;
  overflow: hidden;
}

.drawer-line {
  opacity: 0;
  transform: translateY(16px);
  animation: fadeUpSoft 520ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--line-index, 0) * 60ms);
}

.checkout-item {
  opacity: 0;
  transform: translateY(16px);
  animation: fadeUpSoft 560ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--item-index, 0) * 70ms);
}

.drawer-line::before,
.checkout-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.46), transparent 30%, transparent 72%, rgba(255, 255, 255, 0.16));
  pointer-events: none;
}

.drawer-dialog[open] .drawer-card {
  animation: drawerSlideIn 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

#productDialog[open] .modal-card,
#contactDialog[open] .contact-card,
#successDialog[open] .success-card {
  animation: modalScaleIn 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

#productDialog[open] .modal-head > *,
#productDialog[open] .product-preview,
#productDialog[open] .modal-copy > * {
  opacity: 0;
  animation: fadeUpSoft 520ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#productDialog[open] .modal-head > *:first-child {
  animation-delay: 40ms;
}

#productDialog[open] .modal-head > *:last-child {
  animation-delay: 70ms;
}

#productDialog[open] .product-preview {
  animation-delay: 90ms;
}

#productDialog[open] .modal-copy > *:nth-child(1) { animation-delay: 110ms; }
#productDialog[open] .modal-copy > *:nth-child(2) { animation-delay: 150ms; }
#productDialog[open] .modal-copy > *:nth-child(3) { animation-delay: 190ms; }
#productDialog[open] .modal-copy > *:nth-child(4) { animation-delay: 230ms; }
#productDialog[open] .modal-copy > *:nth-child(5) { animation-delay: 270ms; }

.qty-inline,
.qty-box {
  padding: 4px;
  border: 1px solid rgba(51, 88, 75, 0.08);
  background: linear-gradient(180deg, rgba(51, 88, 75, 0.09), rgba(51, 88, 75, 0.05));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42);
}

.qty-step {
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 4px 12px rgba(26, 45, 37, 0.06);
}

.qty-step:hover,
.qty-step:focus-visible {
  transform: translateY(-1px);
}

.drawer-thumb,
.checkout-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-thumb img,
.checkout-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.drawer-note,
.summary-note,
.field-note {
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--muted);
}

.drawer-note {
  margin: 0 0 4px;
}

.summary-note {
  margin: -8px 0 28px;
}

.field-note {
  margin: 2px 0 0;
}

.drawer-footer {
  display: grid;
  gap: 14px;
}

.field-grid--checkout {
  align-items: start;
}

.choice-field {
  min-width: 0;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.choice-field legend {
  padding: 0;
  font-size: 1rem;
}

.choice-grid {
  display: grid;
  gap: 12px;
}

.choice-card {
  position: relative;
  display: block;
  cursor: pointer;
}

.choice-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
}

.choice-card__body {
  position: relative;
  min-height: 82px;
  display: grid;
  gap: 6px;
  padding: 16px 54px 16px 18px;
  border-radius: 18px;
  border: 1.6px solid rgba(51, 88, 75, 0.16);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(244, 247, 245, 0.96));
  box-shadow: 0 10px 22px rgba(26, 45, 37, 0.04);
}

.choice-card__body::after {
  content: "";
  position: absolute;
  top: 18px;
  right: 18px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1.5px solid rgba(51, 88, 75, 0.32);
  background: #FFFFFF;
  box-shadow: inset 0 0 0 5px transparent;
  transition: border-color var(--speed), background-color var(--speed), box-shadow var(--speed), transform var(--speed);
}

.choice-card__title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
}

.choice-card__text {
  font-size: 0.92rem;
  line-height: 1.48;
  color: var(--muted);
}

.choice-card:hover .choice-card__body,
.choice-card:focus-within .choice-card__body {
  transform: translateY(-1px);
  border-color: rgba(51, 88, 75, 0.34);
  box-shadow: 0 16px 32px rgba(26, 45, 37, 0.08);
}

.choice-input:focus-visible + .choice-card__body {
  border-color: var(--block);
  box-shadow: 0 0 0 3px rgba(173, 225, 216, 0.34), 0 16px 32px rgba(26, 45, 37, 0.08);
}

.choice-input:checked + .choice-card__body {
  border-color: rgba(51, 88, 75, 0.58);
  background: linear-gradient(160deg, rgba(51, 88, 75, 0.14), rgba(255, 255, 255, 0.98));
  box-shadow: 0 18px 38px rgba(26, 45, 37, 0.08), inset 0 0 0 1px rgba(51, 88, 75, 0.08);
}

.choice-input:checked + .choice-card__body::after {
  transform: scale(1.02);
  border-color: var(--block);
  background: var(--block);
  box-shadow: inset 0 0 0 4px #FFFFFF;
}

@keyframes drawerSlideIn {
  from {
    opacity: 0;
    transform: translateX(42px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes modalScaleIn {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes fadeUpSoft {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cartButtonBump {
  0% {
    transform: scale(1);
  }
  35% {
    transform: scale(1.08) translateY(-4px);
  }
  65% {
    transform: scale(0.98);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes badgePop {
  0% {
    transform: scale(1);
  }
  35% {
    transform: scale(1.16);
  }
  70% {
    transform: scale(0.96);
  }
  100% {
    transform: scale(1);
  }
}

@media (max-width: 980px) {
  .choice-card__body {
    min-height: 76px;
  }
}

@media (max-width: 720px) {
  .summary-note {
    margin-top: -2px;
  }

  .choice-card__body {
    padding-right: 50px;
  }
}

@media (max-width: 980px) {
  .header-socials {
    display: flex;
    justify-self: end;
    gap: 8px;
  }

  .social-link {
    width: 30px;
    height: 30px;
  }
}

@media (max-width: 720px) {
  .floating-cart {
    width: 62px;
    height: 62px;
  }
}

@media (max-width: 560px) {
  .header-socials {
    gap: 6px;
  }

  .social-link {
    width: 28px;
    height: 28px;
  }
}

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

/* === GAIT cleanup patch === */
.hero {
  padding-bottom: 34px;
}

.hero-stage {
  background: linear-gradient(180deg, #FBFCFB 0%, #F7FAF8 44%, #F3F7F5 78%, var(--canvas) 100%);
}

.hero-stage::before {
  inset: -4% -6% 36% -6%;
  background:
    radial-gradient(circle at 14% 14%, rgba(178, 225, 216, 0.18), transparent 24%),
    radial-gradient(circle at 86% 15%, rgba(201, 235, 229, 0.16), transparent 22%),
    radial-gradient(circle at 52% 100%, rgba(206, 233, 227, 0.26), transparent 28%);
}

.hero-stage::after {
  left: 0;
  right: 0;
  bottom: 0;
  height: 64px;
  background: linear-gradient(
    180deg,
    rgba(243, 247, 245, 0) 0%,
    rgba(243, 247, 245, 0.08) 34%,
    rgba(247, 250, 248, 0.56) 72%,
    var(--canvas) 100%
  );
}

.hero-visual {
  opacity: 0.38;
  background-position: center 40%;
  filter: saturate(0.98);
}

.catalog {
  padding-top: 0;
}

.header-actions {
  position: relative;
  z-index: 3;
}

.floating-cart,
.header-cart {
  isolation: auto;
  overflow: visible;
}

.floating-cart::before,
.floating-cart::after,
.header-cart::before,
.header-cart::after {
  content: none !important;
}

.floating-cart {
  width: 68px;
  height: 68px;
  border: 2px solid rgba(255, 255, 255, 0.88);
  background: var(--block);
  box-shadow: 0 18px 42px rgba(26, 45, 37, 0.22);
}

.floating-cart:hover,
.floating-cart:focus-visible {
  background: #2A473D;
  transform: translateY(-2px);
  box-shadow: 0 20px 44px rgba(26, 45, 37, 0.24);
}

.floating-cart.is-filled {
  border-color: rgba(255, 255, 255, 0.94);
  box-shadow: 0 18px 44px rgba(26, 45, 37, 0.24);
}

.header-cart {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
}

.header-cart svg {
  width: 24px;
  height: 24px;
}

.header-cart:hover,
.header-cart:focus-visible {
  background: rgba(51, 88, 75, 0.06);
  border-color: rgba(51, 88, 75, 0.12);
  transform: translateY(-1px);
}

.header-cart.is-filled {
  background: rgba(51, 88, 75, 0.04);
  border-color: rgba(51, 88, 75, 0.12);
  box-shadow: none;
}

.header-cart .cart-badge {
  top: 3px;
  right: 1px;
}

.drawer-dialog[open] .drawer-card {
  animation-duration: 360ms;
}

.drawer-dialog.is-closing .drawer-card {
  animation: drawerSlideOut 220ms cubic-bezier(0.55, 0, 0.45, 1) forwards;
}

.modal-dialog.is-closing .modal-card,
.modal-dialog.is-closing .contact-card,
.modal-dialog.is-closing .success-card {
  animation: modalScaleOut 180ms cubic-bezier(0.55, 0, 0.45, 1) forwards;
}

.drawer-dialog.is-closing::backdrop,
.modal-dialog.is-closing::backdrop {
  animation: backdropFadeOut 180ms ease forwards;
}

.page-checkout .site-header--checkout .header-bar,
.page-checkout .checkout-heading,
.page-checkout .checkout-layout {
  transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1), filter 260ms ease;
}

body.is-drawer-open.page-checkout .site-header--checkout .header-bar,
body.is-drawer-open.page-checkout .checkout-heading,
body.is-drawer-open.page-checkout .checkout-layout {
  transform: translateX(-24px);
}

.qty-inline.is-changing-up,
.qty-box.is-changing-up {
  animation: qtyPulseUp 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.qty-inline.is-changing-down,
.qty-box.is-changing-down {
  animation: qtyPulseDown 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.qty-inline.is-changing-up .qty-value,
.qty-box.is-changing-up .qty-value {
  animation: qtyNumberUp 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.qty-inline.is-changing-down .qty-value,
.qty-box.is-changing-down .qty-value {
  animation: qtyNumberDown 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.drawer-line.is-removing {
  animation: lineRemove 180ms ease forwards;
  pointer-events: none;
}

.field-note--checkout {
  margin-top: 18px;
}

.field--select {
  min-width: 0;
}

.custom-select {
  position: relative;
  min-width: 0;
}

.custom-select__trigger {
  appearance: none;
  -webkit-appearance: none;
  box-sizing: border-box;
  cursor: pointer;
  font: inherit;
  line-height: 1.2;
  position: relative;
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  text-align: left;
  padding: 0 18px 0 42px;
  border-radius: 12px;
  border: 1.6px solid var(--line);
  background: rgba(249, 250, 249, 0.25);
  color: var(--text);
  transition: border-color var(--speed), box-shadow var(--speed), background-color var(--speed), transform var(--speed);
}

.custom-select__trigger:hover,
.custom-select__trigger:focus-visible,
.custom-select.is-open .custom-select__trigger {
  background: rgba(255, 255, 255, 0.86);
  border-color: var(--block);
  box-shadow: 0 0 0 3px rgba(173, 225, 216, 0.26);
}

.custom-select__arrow {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.95rem;
  line-height: 1;
}

.custom-select__label {
  display: block;
  width: 100%;
  font-size: 1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.custom-select__label.is-placeholder {
  color: transparent;
}

.custom-select__menu[hidden] {
  display: none;
}

.custom-select__menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 8;
  display: grid;
  gap: 4px;
  padding: 8px;
  border-radius: 14px;
  border: 1px solid rgba(51, 88, 75, 0.12);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 18px 38px rgba(26, 45, 37, 0.12);
  opacity: 0;
  transform: translateY(-6px) scale(0.98);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

.custom-select.is-open .custom-select__menu {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.custom-select__option {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  min-height: 46px;
  border: 0;
  cursor: pointer;
  font: inherit;
  padding: 12px 14px;
  border-radius: 10px;
  background: transparent;
  text-align: left;
  font-size: 0.98rem;
  line-height: 1.4;
  color: var(--text);
  transition: background-color var(--speed), color var(--speed), transform var(--speed);
}

.custom-select__option:hover,
.custom-select__option:focus-visible {
  background: rgba(173, 225, 216, 0.18);
}

.custom-select__option.is-selected {
  background: rgba(51, 88, 75, 0.12);
  color: var(--block);
}

.custom-select.is-invalid .custom-select__trigger {
  border-color: rgba(167, 102, 75, 0.72);
  box-shadow: 0 0 0 3px rgba(167, 102, 75, 0.12);
}

@keyframes drawerSlideOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(34px);
  }
}

@keyframes modalScaleOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(10px) scale(0.98);
  }
}

@keyframes backdropFadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

@keyframes qtyPulseUp {
  0% {
    transform: scale(1);
  }
  45% {
    transform: translateY(-1px) scale(1.04);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes qtyPulseDown {
  0% {
    transform: scale(1);
  }
  45% {
    transform: translateY(1px) scale(0.97);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes qtyNumberUp {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  45% {
    opacity: 0.72;
    transform: translateY(-2px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes qtyNumberDown {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  45% {
    opacity: 0.72;
    transform: translateY(2px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes lineRemove {
  from {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateX(18px) scale(0.98);
  }
}

@media (max-width: 980px) {
  body.is-drawer-open.page-checkout .site-header--checkout .header-bar,
  body.is-drawer-open.page-checkout .checkout-heading,
  body.is-drawer-open.page-checkout .checkout-layout {
    transform: translateX(-12px);
  }
}

@media (max-width: 720px) {
  .hero-stage::after {
    height: 46px;
  }

  .floating-cart {
    width: 62px;
    height: 62px;
  }

  .custom-select__menu {
    top: calc(100% + 6px);
  }
}


/* === GAIT polish update 3 === */
.catalog {
  padding-top: 104px;
}

.floating-cart {
  right: 28px;
  bottom: 28px;
  width: 68px;
  height: 68px;
  border: 0;
  background: var(--block);
  color: var(--canvas);
  box-shadow: 0 18px 42px rgba(26, 45, 37, 0.22);
  transform: none;
}

.floating-cart:hover,
.floating-cart:focus-visible,
.floating-cart.is-filled {
  background: #2A473D;
  box-shadow: 0 18px 42px rgba(26, 45, 37, 0.22);
  transform: none;
}

.floating-cart svg {
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
}

.floating-cart .cart-badge {
  top: 9px;
  right: 10px;
}

.drawer-card {
  will-change: transform, opacity;
}

.drawer-dialog[open] .drawer-card {
  animation: drawerPanelIn 320ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.drawer-dialog.is-closing .drawer-card {
  animation: drawerPanelOut 260ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

.qty-inline.is-changing-up,
.qty-inline.is-changing-down,
.qty-inline.is-changing-up .qty-value,
.qty-inline.is-changing-down .qty-value {
  animation: none !important;
}

.byn-symbol {
  position: relative;
  display: inline-block;
  width: 0.78em;
  height: 0.98em;
  margin-left: 0.18em;
  vertical-align: -0.08em;
  color: currentColor;
}

.byn-symbol::before {
  content: "Б";
  position: absolute;
  inset: 0;
  font: inherit;
  font-weight: 700;
  line-height: 1;
}

.byn-symbol::after {
  content: "";
  position: absolute;
  left: 0.14em;
  right: 0.08em;
  top: 0.54em;
  height: 0.08em;
  border-radius: 999px;
  background: currentColor;
}

@keyframes drawerPanelIn {
  from {
    opacity: 0;
    transform: translateX(32px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes drawerPanelOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(24px);
  }
}

@media (max-width: 720px) {
  .catalog {
    padding-top: 88px;
  }

  .floating-cart {
    right: 16px;
    bottom: 16px;
    width: 60px;
    height: 60px;
  }
}

/* === GAIT polish update 4 === */
:root {
  --byn-symbol-url: url("https://www.nbrb.by/coinsbanknotes/byn-ico/byn-ico.png");
}

html {
  scrollbar-gutter: stable both-edges;
}

body {
  --scrollbar-gap: 0px;
}

body.is-locked {
  overflow: hidden;
}

.catalog {
  padding-top: 116px;
}

.catalog .shell::before {
  content: "sneaker store";
  display: block;
  margin: 0 0 28px;
  text-align: center;
  font-size: clamp(2.8rem, 5.6vw, 4.8rem);
  line-height: 1;
  font-weight: 300;
  letter-spacing: -0.07em;
  color: rgba(26, 45, 37, 0.17);
}

.floating-cart,
.header-cart {
  overflow: visible;
  isolation: auto;
}

.floating-cart::before,
.floating-cart::after,
.header-cart::before,
.header-cart::after {
  content: none !important;
}

.floating-cart {
  right: 28px;
  bottom: 28px;
  width: 68px;
  height: 68px;
  padding: 0;
  border: 1.5px solid rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  background: var(--block);
  color: var(--canvas);
  box-shadow: 0 18px 42px rgba(26, 45, 37, 0.22);
  transform: none !important;
}

.floating-cart:hover,
.floating-cart:focus-visible,
.floating-cart.is-filled {
  background: #2A473D;
  box-shadow: 0 20px 44px rgba(26, 45, 37, 0.24);
  transform: none !important;
}

.floating-cart svg,
.header-cart svg {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

.floating-cart svg {
  width: 26px;
  height: 26px;
}

.floating-cart .cart-badge {
  top: 8px;
  right: 8px;
}

.header-cart {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
}

.header-cart svg {
  width: 24px;
  height: 24px;
}

.header-cart:hover,
.header-cart:focus-visible {
  background: rgba(51, 88, 75, 0.06);
  border-color: rgba(51, 88, 75, 0.12);
}

.header-cart .cart-badge {
  top: 1px;
  right: -1px;
}

.byn-symbol {
  display: inline-block;
  width: 0.84em;
  height: 1em;
  margin-left: 0.18em;
  vertical-align: -0.1em;
  background-image: var(--byn-symbol-url);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  filter: grayscale(1) brightness(0) contrast(1.2);
}

@supports ((-webkit-mask-image: url("")) or (mask-image: url(""))) {
  .byn-symbol {
    background-image: none;
    background-color: currentColor;
    -webkit-mask-image: var(--byn-symbol-url);
    mask-image: var(--byn-symbol-url);
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
    filter: none;
  }
}

.modal-card,
.contact-card,
.success-card,
.drawer-card {
  will-change: transform, opacity, filter;
}

.drawer-dialog[open] .drawer-card {
  animation: drawerPanelIn 420ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.drawer-dialog.is-closing .drawer-card {
  animation: drawerPanelOut 300ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

.modal-dialog[open] .modal-card,
.modal-dialog[open] .contact-card,
.modal-dialog[open] .success-card {
  animation: modalScaleIn 380ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.modal-dialog.is-closing .modal-card,
.modal-dialog.is-closing .contact-card,
.modal-dialog.is-closing .success-card {
  animation: modalScaleOut 260ms cubic-bezier(0.4, 0, 0.2, 1) both;
}

.drawer-dialog[open]::backdrop,
.modal-dialog[open]::backdrop {
  animation: backdropFadeIn 220ms ease both;
}

.drawer-dialog.is-closing::backdrop,
.modal-dialog.is-closing::backdrop {
  animation: backdropFadeOut 240ms ease both;
}

@keyframes backdropFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes modalScaleOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
  to {
    opacity: 0;
    transform: translateY(18px) scale(0.955);
    filter: blur(2px);
  }
}

@keyframes drawerPanelIn {
  from {
    opacity: 0;
    transform: translateX(42px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes drawerPanelOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(38px);
  }
}

@media (max-width: 720px) {
  .shell {
    width: min(100%, calc(100% - 44px));
  }

  .header-bar {
    min-height: 72px;
    gap: 12px;
  }

  .logo {
    font-size: 2.2rem;
  }

  .header-cart {
    width: 40px;
    height: 40px;
  }

  .header-cart .cart-badge {
    top: 0;
    right: -2px;
  }

  .hero {
    padding-bottom: 0;
  }

  .hero-stage,
  .hero-content {
    min-height: 930px;
  }

  .hero-content {
    align-items: flex-start;
  }

  .hero-copy {
    width: 100%;
    max-width: none;
    padding: 220px 0 138px;
  }

  .hero-copy h1 {
    font-size: clamp(3.85rem, 17vw, 5.1rem);
    line-height: 0.94;
    letter-spacing: -0.08em;
  }

  .hero-copy p {
    max-width: none;
    margin-top: 18px;
    font-size: 1.04rem;
    line-height: 1.48;
  }

  .hero-button {
    width: auto;
    min-width: 132px;
    min-height: 60px;
    margin-top: 30px;
    padding: 0 34px;
    border-radius: 14px;
  }

  .catalog {
    padding-top: 54px;
    padding-bottom: 70px;
  }

  .catalog .shell::before {
    margin-bottom: 34px;
    font-size: clamp(3rem, 13.5vw, 4.4rem);
    color: rgba(26, 45, 37, 0.16);
  }

  .catalog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px 14px;
  }

  .product-card {
    padding: 8px 8px 10px;
    border-radius: 20px;
  }

  .product-card__media {
    aspect-ratio: 1 / 1.18;
    border-radius: 14px;
  }

  .product-card__body {
    padding-top: 12px;
  }

  .product-card__title {
    font-size: 1.16rem;
  }

  .product-card__subtitle {
    font-size: 0.9rem;
  }

  .product-card__price {
    margin-top: 6px;
    font-size: 1.55rem;
  }

  .card-button {
    min-height: 40px;
    border-radius: 999px;
    font-size: 0.98rem;
  }

  .about {
    padding: 72px 0 78px;
  }

  .section-title,
  .section-title--center,
  .section-text,
  .contacts__text,
  .contacts {
    text-align: left;
  }

  .section-title {
    font-size: clamp(3rem, 13vw, 4.7rem);
  }

  .section-text {
    margin-top: 16px;
    max-width: none;
    font-size: 1.08rem;
    line-height: 1.55;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 0;
    margin-top: 30px;
  }

  .about-grid .about-block:nth-child(n + 2) {
    display: none;
  }

  .about-block {
    min-height: 300px;
    border-radius: 18px;
  }

  .about-tags {
    display: none;
  }

  .contacts {
    padding: 82px 0 88px;
  }

  .contacts__actions {
    justify-content: flex-start;
  }

  .contacts__text {
    max-width: none;
    margin-top: 16px;
    font-size: 1.08rem;
    line-height: 1.55;
  }

  .contacts .button {
    width: auto;
    min-width: 132px;
    min-height: 60px;
    padding: 0 34px;
  }

  .site-footer__inner {
    min-height: 170px;
    justify-content: flex-start;
    text-align: left;
  }

  .site-footer__copy {
    font-size: 1rem;
  }

  .floating-cart {
    right: 18px;
    bottom: 18px;
    width: 60px;
    height: 60px;
  }

  .floating-cart svg {
    width: 24px;
    height: 24px;
  }

  .floating-cart .cart-badge {
    top: 6px;
    right: 6px;
  }
}

@media (max-width: 560px) {
  .hero-stage,
  .hero-content {
    min-height: 900px;
  }

  .hero-copy {
    padding-top: 206px;
  }

  .catalog-grid {
    gap: 18px 12px;
  }

  .about-block {
    min-height: 260px;
  }

  .floating-cart {
    right: 16px;
    bottom: 16px;
  }
}

/* === GAIT polish update 4.1 === */
@media (max-width: 980px) {
  .header-socials {
    display: none;
  }
}

@media (max-width: 720px) {
  .floating-cart {
    display: none;
  }

  .hero-copy h1 {
    max-width: 350px;
    font-size: clamp(3.45rem, 15.2vw, 4.75rem);
  }

  .hero-copy p {
    max-width: 350px;
  }
}

/* === GAIT polish update 4.2 === */
@media (max-width: 980px) {
  .page-home .header-cart {
    display: inline-flex;
  }
}

/* === GAIT polish update 4.3 === */
@media (max-width: 980px) {
  .page-home .header-cart {
    width: 42px;
    height: 42px;
  }

  .page-home .header-cart svg {
    width: 26px;
    height: 26px;
    left: calc(50% - 2px);
  }
}


/* === GAIT final refinement === */
:root {
  --reveal-duration: 760ms;
}

html {
  scrollbar-gutter: stable;
}

html.is-locked,
html.is-locked body {
  overflow: visible;
}

body.is-locked {
  left: 0;
  right: 0;
  width: 100%;
  overscroll-behavior: none;
}

.catalog {
  padding-top: 88px;
}

.catalog .shell::before {
  content: none !important;
}

.reveal-fade {
  opacity: 0;
  transform: translateY(36px);
  filter: blur(6px);
  transition:
    opacity var(--reveal-duration) cubic-bezier(0.22, 1, 0.36, 1),
    transform var(--reveal-duration) cubic-bezier(0.22, 1, 0.36, 1),
    filter 520ms ease;
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform, filter;
}

.reveal-fade.is-visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.catalog .product-card.reveal-fade {
  transform: translateY(42px) scale(0.985);
}

.catalog .product-card.reveal-fade.is-visible {
  transform: translateY(0) scale(1);
}

dialog::backdrop {
  background: rgba(14, 25, 20, 0.28);
  backdrop-filter: blur(6px);
}

.drawer-dialog[open] .drawer-card {
  animation: gaitDrawerIn 460ms cubic-bezier(0.22, 1, 0.36, 1) both !important;
}

.drawer-dialog.is-closing .drawer-card {
  animation: gaitDrawerOut 360ms cubic-bezier(0.4, 0, 0.2, 1) both !important;
}

.modal-dialog[open] .modal-card,
.modal-dialog[open] .contact-card,
.modal-dialog[open] .success-card {
  animation: modalScaleIn 420ms cubic-bezier(0.22, 1, 0.36, 1) both !important;
}

.modal-dialog.is-closing .modal-card,
.modal-dialog.is-closing .contact-card,
.modal-dialog.is-closing .success-card {
  animation: gaitModalOut 320ms cubic-bezier(0.4, 0, 0.2, 1) both !important;
}

.drawer-dialog[open]::backdrop,
.modal-dialog[open]::backdrop {
  animation: backdropFadeIn 240ms ease both;
}

.drawer-dialog.is-closing::backdrop,
.modal-dialog.is-closing::backdrop {
  animation: backdropFadeOut 320ms ease both;
}

@keyframes gaitDrawerIn {
  from {
    opacity: 0;
    transform: translateX(56px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes gaitDrawerOut {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(54px);
  }
}

@keyframes gaitModalOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0) brightness(1);
  }
  to {
    opacity: 0;
    transform: translateY(22px) scale(0.94);
    filter: blur(6px) brightness(0.98);
  }
}

.checkout-submitbar {
  margin-top: 28px;
}

.checkout-submitbar .summary-submit {
  width: 100%;
  min-height: 56px;
}

.page-checkout .floating-cart {
  display: none;
}

@media (max-width: 720px) {
  .header-bar {
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    min-height: 72px;
  }

  .header-socials {
    display: flex !important;
    justify-self: center;
    gap: 8px;
  }

  .header-phone,
  .page-home .header-cart,
  .page-checkout .header-cart {
    display: none !important;
  }

  .header-actions {
    justify-self: end;
    gap: 0;
  }

  .nav-toggle {
    width: 42px;
    height: 42px;
    display: inline-flex;
  }

  .page-home .floating-cart,
  .page-checkout .floating-cart {
    display: inline-flex !important;
  }

  .catalog {
    padding-top: 62px;
  }

  .checkout-submitbar {
    margin-top: 22px;
  }
}

@media (max-width: 560px) {
  .header-socials {
    gap: 6px;
  }

  .social-link {
    width: 30px;
    height: 30px;
  }

  .catalog {
    padding-top: 56px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .reveal-fade {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}


/* === GAIT hotfix: hide scrollbars and remove catalog pseudo-title === */
html,
body,
.drawer-body,
.modal-card,
.contact-card,
.success-card {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar,
.drawer-body::-webkit-scrollbar,
.modal-card::-webkit-scrollbar,
.contact-card::-webkit-scrollbar,
.success-card::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none;
}

html {
  scrollbar-gutter: auto !important;
}

.catalog .shell::before {
  content: none !important;
  display: none !important;
}


/* Fixes: header visibility, drawer stability, checkout header cleanup */
.site-header {
  z-index: 120 !important;
}

body.is-locked .site-header {
  opacity: 1 !important;
  pointer-events: none;
}

dialog {
  position: fixed !important;
  inset: 0 !important;
  width: 100vw !important;
  height: 100dvh !important;
  max-width: none !important;
  max-height: none !important;
  z-index: 100 !important;
}

dialog::backdrop {
  background: transparent !important;
  backdrop-filter: none !important;
}

.drawer-dialog,
.modal-dialog {
  background: rgba(14, 25, 20, 0.24) !important;
  backdrop-filter: blur(4px);
}

.drawer-dialog[open] {
  display: flex;
  justify-content: flex-end;
  align-items: stretch;
}

.modal-dialog[open] {
  display: flex;
  justify-content: center;
  align-items: center;
}

.catalog .shell::before {
  content: none !important;
  display: none !important;
}

.page-checkout .header-cart {
  display: none !important;
}

.drawer-body.is-updating .drawer-line {
  opacity: 1 !important;
  transform: none !important;
  animation: none !important;
}

.drawer-body.is-updating .drawer-line::before {
  opacity: 0.9;
}

.drawer-body.is-updating .drawer-line.is-removing {
  animation: lineRemove 180ms ease forwards !important;
}


/* === GAIT final tweak pack === */
:root {
  --header-offset: 90px;
}

.logo {
  display: inline-flex;
  align-items: center;
  width: min(260px, 22vw);
  max-width: 260px;
}

.logo__image {
  display: block;
  width: 100%;
  height: auto;
}

.hero-content {
  justify-content: flex-start;
}

.hero-copy {
  margin: 0;
}

.site-header {
  z-index: 300 !important;
}

body.is-locked .site-header {
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
}

.drawer-dialog,
.modal-dialog {
  top: var(--header-offset) !important;
  height: calc(100dvh - var(--header-offset)) !important;
}

.drawer-card {
  height: 100%;
}

.modal-dialog[open] {
  align-items: center;
  justify-content: center;
}

.page-checkout .site-header--checkout .header-actions {
  gap: 0;
}

@media (max-width: 980px) {
  .logo {
    width: min(220px, 30vw);
    max-width: 220px;
  }
}

@media (max-width: 720px) {
  :root {
    --header-offset: 72px;
  }

  .logo {
    width: min(148px, 36vw);
    max-width: 148px;
  }

  .hero-content {
    justify-content: flex-start;
  }

  #productDialog[open] {
    display: block;
  }

  #productDialog {
    top: var(--header-offset) !important;
    height: calc(100dvh - var(--header-offset)) !important;
    background: var(--canvas);
  }

  #productDialog .modal-card {
    width: 100vw;
    max-width: none;
    max-height: none;
    height: 100%;
    margin: 0;
    padding: 18px 18px 24px;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: var(--canvas);
  }

  #productDialog .modal-head {
    position: sticky;
    top: 0;
    z-index: 2;
    padding-bottom: 12px;
    background: linear-gradient(180deg, rgba(249, 250, 249, 0.98) 0%, rgba(249, 250, 249, 0.92) 82%, rgba(249, 250, 249, 0) 100%);
    backdrop-filter: blur(0);
  }

  #productDialog .product-modal__body {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 8px;
  }

  #productDialog .product-preview {
    aspect-ratio: 1 / 0.96;
    border-radius: 18px;
  }

  #productDialog .modal-copy {
    gap: 16px;
  }

  #productDialog .modal-actions {
    position: sticky;
    bottom: 0;
    padding-top: 10px;
    background: linear-gradient(180deg, rgba(249, 250, 249, 0) 0%, rgba(249, 250, 249, 0.92) 28%, rgba(249, 250, 249, 1) 100%);
  }

  .drawer-dialog,
  .modal-dialog {
    top: var(--header-offset) !important;
    height: calc(100dvh - var(--header-offset)) !important;
  }
}

/* === fix10: stable header, product page, admin panel === */
dialog[hidden] {
  display: none !important;
}

dialog,
dialog:focus,
dialog:focus-visible {
  outline: none !important;
  border: 0 !important;
}

.site-header {
  z-index: 520 !important;
}

.drawer-dialog,
.modal-dialog {
  z-index: 420 !important;
}

body.is-locked .site-header {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 520 !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
  pointer-events: none;
}

.admin-auth-card {
  width: min(420px, calc(100vw - 24px));
  padding: 24px;
  background: rgba(249, 250, 249, 0.98);
  border: 1px solid rgba(51, 88, 75, 0.12);
  border-radius: 28px;
  box-shadow: 0 22px 50px rgba(22, 39, 32, 0.16);
}

.admin-auth-form {
  display: grid;
  gap: 16px;
}

.admin-dialog .drawer-card {
  width: min(1080px, 100vw);
  border-left: 0;
  box-shadow: -24px 0 60px rgba(22, 39, 32, 0.16);
}

.admin-panel__body {
  display: grid;
  gap: 22px;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-stat {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(241, 244, 242, 0.92);
  border: 1px solid rgba(51, 88, 75, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-stat span {
  color: rgba(26, 45, 37, 0.68);
  font-size: 0.96rem;
}

.admin-stat strong {
  font-size: 1.1rem;
  font-weight: 700;
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.9fr);
  gap: 18px;
  min-height: 0;
}

.admin-column {
  min-width: 0;
  display: grid;
  gap: 14px;
}

.admin-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.admin-section-head h3 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.admin-product-list {
  display: grid;
  gap: 12px;
  align-content: start;
}

.admin-product {
  display: grid;
  grid-template-columns: 86px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border-radius: 22px;
  background: rgba(245, 247, 245, 0.98);
  border: 1px solid rgba(51, 88, 75, 0.08);
}

.admin-product__thumb {
  aspect-ratio: 1;
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(53, 88, 75, 0.12), rgba(53, 88, 75, 0.06));
}

.admin-product__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.admin-upload-preview {
  display: grid;
  gap: 10px;
  padding: 10px;
  border-radius: 16px;
  border: 1px solid rgba(51, 88, 75, 0.1);
  background: rgba(245, 247, 245, 0.96);
}

.admin-upload-preview img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(53, 88, 75, 0.12), rgba(53, 88, 75, 0.06));
}

.admin-product__meta {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.admin-product__meta h3 {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.admin-product__meta p {
  color: rgba(26, 45, 37, 0.68);
}

.admin-product__details {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: rgba(26, 45, 37, 0.76);
  font-size: 0.94rem;
}

.admin-product__actions {
  display: grid;
  gap: 8px;
}

.admin-danger {
  border-color: rgba(145, 67, 55, 0.24);
  color: #7b3428;
}

.admin-form {
  display: grid;
  gap: 14px;
  padding: 16px;
  border-radius: 24px;
  background: rgba(245, 247, 245, 0.96);
  border: 1px solid rgba(51, 88, 75, 0.08);
}

.admin-form__row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.admin-empty {
  padding: 18px;
  border-radius: 18px;
  background: rgba(245, 247, 245, 0.96);
  border: 1px dashed rgba(51, 88, 75, 0.2);
  color: rgba(26, 45, 37, 0.76);
}

.product-page {
  padding: 38px 0 88px;
}

.product-page__topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.product-page__back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid rgba(51, 88, 75, 0.16);
  background: rgba(245, 247, 245, 0.96);
  color: var(--text);
}

.product-page__back svg {
  width: 20px;
  height: 20px;
}

.product-page__crumbs {
  color: rgba(26, 45, 37, 0.56);
  font-size: 0.95rem;
}

.product-page__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.03fr) minmax(0, 0.97fr);
  gap: 34px;
  align-items: start;
}

.product-page__visual,
.product-page__content {
  min-width: 0;
}

.product-page__preview {
  position: relative;
  border-radius: 34px;
  overflow: hidden;
  aspect-ratio: 1 / 0.95;
  background: linear-gradient(180deg, rgba(53, 88, 75, 0.16), rgba(53, 88, 75, 0.05));
}

.product-page__preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-page__content {
  display: grid;
  gap: 18px;
  align-content: start;
}

.product-page__eyebrow {
  color: rgba(26, 45, 37, 0.58);
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.product-page__title {
  font-size: clamp(2.2rem, 4vw, 4rem);
  line-height: 0.95;
  font-weight: 800;
  letter-spacing: -0.07em;
}

.product-page__subtitle {
  font-size: 1.1rem;
  color: rgba(26, 45, 37, 0.68);
}

.product-page__description {
  max-width: 54ch;
  font-size: 1.02rem;
  line-height: 1.65;
  color: rgba(26, 45, 37, 0.82);
}

.product-page__price {
  font-size: 2rem;
  line-height: 1;
  font-weight: 800;
  color: var(--accent-soft);
}

.product-page__controls {
  display: grid;
  gap: 18px;
}

.product-page__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

@media (max-width: 980px) {
  .admin-layout,
  .product-page__grid {
    grid-template-columns: 1fr;
  }

  .product-page__description {
    max-width: none;
  }
}

@media (max-width: 720px) {
  .page-product .header-phone,
  .page-product .header-cart {
    display: none !important;
  }

  .page-product .floating-cart {
    display: inline-flex !important;
  }

  .product-page {
    padding: 12px 0 44px;
  }

  .product-page__topline {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
  }

  .product-page__crumbs {
    font-size: 0.82rem;
  }

  .product-page__back {
    width: fit-content;
    padding-inline: 14px;
  }

  .product-page__grid {
    gap: 18px;
  }

  .product-page__preview {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    border-radius: 0;
    min-height: 48svh;
    aspect-ratio: auto;
  }

  .product-page__content {
    gap: 16px;
  }

  .product-page__title {
    font-size: clamp(2rem, 10vw, 3.2rem);
  }

  .product-page__actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .admin-auth-card {
    width: min(100vw - 20px, 420px);
    padding: 20px;
    border-radius: 24px;
  }

  .admin-dialog .drawer-card {
    width: 100vw;
  }

  .admin-stats {
    grid-template-columns: 1fr;
  }

  .admin-form__row {
    grid-template-columns: 1fr;
  }

  .admin-product {
    grid-template-columns: 76px 1fr;
  }

  .admin-product__actions {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #productDialog .modal-head,
  #productDialog .modal-actions {
    position: static !important;
    top: auto !important;
    bottom: auto !important;
    background: transparent !important;
  }
}

#catalog,
#about,
#contact {
  scroll-margin-top: calc(var(--header-offset) + 18px);
}


/* === GAIT fix12: real image cards, upload fallback, header-safe notifications === */
.product-card__media {
  background: transparent !important;
  border: 0 !important;
  border-radius: 18px !important;
  box-shadow: none !important;
}

.product-card__media::before {
  display: none !important;
}

.product-card__image {
  border-radius: 18px !important;
}

.product-card.is-in-cart .product-card__media {
  border: 0 !important;
  box-shadow: none !important;
}

.toast-area {
  top: calc(var(--header-offset, 90px) + 14px) !important;
  z-index: 640 !important;
}

.admin-dialog {
  z-index: 680 !important;
  top: 0 !important;
  height: 100dvh !important;
}

.admin-dialog .drawer-card {
  margin-top: calc(var(--header-offset, 90px) + 10px);
  height: calc(100dvh - var(--header-offset, 90px) - 10px);
  border-top-left-radius: 24px;
}

@media (max-width: 720px) {
  .toast-area {
    top: calc(var(--header-offset, 72px) + 10px) !important;
  }

  .product-card__media,
  .product-card__image {
    border-radius: 16px !important;
  }

  .admin-dialog .drawer-card {
    margin-top: calc(var(--header-offset, 72px) + 8px);
    height: calc(100dvh - var(--header-offset, 72px) - 8px);
    border-top-left-radius: 22px;
  }
}


/* === GAIT fix: catalog product images instead of green placeholder squares === */
.product-card__media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 0.74 !important;
  overflow: hidden;
  background: transparent !important;
  border: 0 !important;
  border-radius: 20px !important;
  box-shadow: none !important;
}

.product-card__media::before {
  display: none !important;
  content: none !important;
}

.product-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  border-radius: 20px !important;
  background: transparent !important;
}

.product-card.is-in-cart .product-card__media {
  border: 0 !important;
  box-shadow: none !important;
}

@media (max-width: 720px) {
  .product-card__media {
    aspect-ratio: 1 / 0.82 !important;
    border-radius: 16px !important;
  }

  .product-card__image {
    border-radius: 16px !important;
  }
}


/* === fix16: smaller header + configurable comfort images === */
:root {
  --header-offset: 72px;
}

.site-header {
  background: rgba(249, 250, 249, 0.92);
}

.header-bar {
  min-height: 72px;
  gap: 20px;
}

.main-nav {
  gap: 28px;
}

.logo {
  width: min(208px, 18vw);
  max-width: 208px;
}

.logo__image {
  max-height: 42px;
  width: auto;
}

.header-phone {
  font-size: 0.95rem;
}

.header-actions {
  gap: 10px;
}

.icon-button,
.nav-toggle {
  transform: scale(0.92);
  transform-origin: center;
}

.about-block.has-image {
  background: rgba(223, 230, 223, 0.44);
}

.about-block.has-image::before {
  display: none;
}

.about-block__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

@media (max-width: 980px) {
  :root {
    --header-offset: 68px;
  }

  .header-bar {
    min-height: 68px;
    gap: 16px;
  }

  .logo {
    width: min(176px, 24vw);
    max-width: 176px;
  }

  .logo__image {
    max-height: 36px;
  }
}

@media (max-width: 720px) {
  :root {
    --header-offset: 58px;
  }

  .header-bar {
    min-height: 58px;
    gap: 12px;
  }

  .logo {
    width: min(126px, 33vw);
    max-width: 126px;
  }

  .logo__image {
    max-height: 28px;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .about-block {
    min-height: 280px;
    border-radius: 18px;
  }
}


/* === GAIT final mobile/cart polish patch === */
@media (max-width: 720px) {
  .header-bar {
    position: relative;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    min-height: 58px;
  }

  .logo {
    width: min(112px, 29vw);
    max-width: 112px;
    position: relative;
    z-index: 1;
  }

  .header-socials {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: max-content;
    margin: 0;
    z-index: 0;
    pointer-events: auto;
  }

  .header-actions {
    justify-self: end;
    width: 42px;
    min-width: 42px;
    justify-content: flex-end;
  }

  .nav-toggle {
    width: 42px;
    height: 42px;
  }

  .social-link {
    width: 28px;
    height: 28px;
  }

  .site-footer__inner {
    justify-content: center !important;
    text-align: center !important;
  }

  .site-footer__copy {
    width: 100%;
    text-align: center;
  }
}

.drawer-dialog,
.modal-dialog {
  background: rgba(14, 25, 20, 0.18) !important;
  backdrop-filter: none !important;
}

.drawer-card {
  contain: layout paint;
  backface-visibility: hidden;
  transform: translateZ(0);
  box-shadow: -18px 0 34px rgba(26, 45, 37, 0.12);
}

.drawer-dialog[open] .drawer-card {
  animation: drawerPanelInFinal 240ms cubic-bezier(0.22, 1, 0.36, 1) both !important;
}

.drawer-dialog.is-closing .drawer-card {
  animation: drawerPanelOutFinal 180ms cubic-bezier(0.4, 0, 0.2, 1) both !important;
}

.drawer-body {
  contain: content;
}

.drawer-line,
.drawer-thumb,
.drawer-thumb img,
.qty-inline,
.qty-value {
  backface-visibility: hidden;
  transform: translateZ(0);
}

.drawer-thumb img {
  display: block;
  will-change: auto;
}

@keyframes drawerPanelInFinal {
  from {
    opacity: 0;
    transform: translate3d(22px, 0, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes drawerPanelOutFinal {
  from {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
  to {
    opacity: 0;
    transform: translate3d(18px, 0, 0);
  }
}
