/* Terra Design — homepage */
.td-home-hero {
  position: relative;
  min-height: min(78vh, 720px);
  color: #fff;
  overflow: hidden;
  background: #1c1a17;
}

.td-home-hero__slides {
  position: absolute;
  inset: 0;
}

.td-home-hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.7s ease;
}

.td-home-hero__slide.is-active {
  opacity: 1;
  z-index: 1;
}

.td-home-hero__media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.02);
}

.td-home-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(20, 18, 16, 0.72) 0%, rgba(20, 18, 16, 0.38) 48%, rgba(20, 18, 16, 0.18) 100%);
}

.td-home-hero__inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  min-height: min(78vh, 720px);
  padding-top: 72px;
  padding-bottom: 88px;
}

.td-home-hero__content {
  width: 100%;
  max-width: 640px;
  margin: 0;
  margin-right: auto;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.td-home-hero__kicker {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}

.td-home-hero__title {
  margin: 0 0 16px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(40px, 6vw, 64px);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.td-home-hero__text {
  margin: 0 0 28px;
  max-width: 34rem;
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.84);
}

.td-home-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.td-btn--light {
  background: #fff;
  color: #1c1a17;
  border-color: #fff;
}

.td-btn--light:hover {
  background: #f3f1ee;
}

.td-btn--ghost-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.65);
}

.td-btn--ghost-light:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.td-home-hero__pager {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 28px;
  z-index: 5;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  pointer-events: none;
}

.td-home-hero__dot {
  appearance: none;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.45);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  cursor: pointer;
  padding: 0;
  pointer-events: auto;
  border-bottom: 1px solid transparent;
}

.td-home-hero__dot.is-active {
  color: #fff;
  border-bottom-color: #fff;
}

.td-home-hero__dot:hover {
  color: #fff;
}

.td-home-hero__nav {
  display: none;
}

.td-home-hero__cursor {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 4;
  width: 64px;
  height: 64px;
  margin: -32px 0 0 -32px;
  border-radius: 999px;
  border: 1px solid rgba(184, 149, 94, 0.55);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.06) 100%);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.22) inset,
    0 12px 36px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-9999px, -9999px, 0) scale(0.86);
  transition: opacity 0.2s ease, transform 0.12s ease-out, background 0.2s ease, border-color 0.2s ease;
  will-change: transform, opacity;
}

.td-home-hero__cursor svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.75;
}

.td-home-hero__cursor-icon {
  position: absolute;
  display: inline-flex;
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.td-home-hero__cursor.is-prev .td-home-hero__cursor-icon--prev,
.td-home-hero__cursor.is-next .td-home-hero__cursor-icon--next {
  opacity: 1;
  transform: scale(1);
}

.td-home-hero.has-cursor-nav {
  cursor: none;
}

.td-home-hero.has-cursor-nav .td-home-hero__actions a,
.td-home-hero.has-cursor-nav .td-home-hero__dot {
  cursor: pointer;
}

.td-home-hero.has-cursor-nav .td-home-hero__cursor {
  display: inline-flex;
}

.td-home-hero.has-cursor-nav .td-home-hero__cursor.is-visible {
  opacity: 1;
  transform: translate3d(var(--td-hero-cx, 0px), var(--td-hero-cy, 0px), 0) scale(1);
}

.td-home-hero.has-cursor-nav .td-home-hero__cursor.is-over-ui {
  opacity: 0;
  transform: translate3d(var(--td-hero-cx, 0px), var(--td-hero-cy, 0px), 0) scale(0.86);
}

@media (hover: hover) and (pointer: fine) {
  .td-home-hero.has-cursor-nav .td-home-hero__nav {
    display: none;
  }
}

@media (hover: none), (pointer: coarse) {
  .td-home-hero__cursor {
    display: none !important;
  }

  .td-home-hero.has-cursor-nav {
    cursor: auto;
  }

  /* Mobile: без стрелки в hero — остават pager точките + autoplay */
  .td-home-hero__nav {
    display: none !important;
  }
}

.td-home-section__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}

.td-home-section__title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(28px, 3vw, 38px);
  font-weight: 500;
  line-height: 1.15;
  color: #1c1a17;
}

.td-home-section__link {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1c1a17;
  text-decoration: none;
  white-space: nowrap;
}

.td-home-section__link:hover {
  opacity: 0.7;
}

.td-home-cats {
  padding: 28px 0 8px;
}

.td-home-cats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.td-home-cat {
  position: relative;
  display: block;
  min-height: 280px;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
}

.td-home-cat__media {
  position: absolute;
  inset: 0;
  background: #cfc8be center / cover no-repeat;
  transition: transform 0.55s ease;
}

.td-home-cat:hover .td-home-cat__media {
  transform: scale(1.04);
}

.td-home-cat__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.08) 20%, rgba(0, 0, 0, 0.62) 100%);
}

.td-home-cat__body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 22px 20px;
  display: grid;
  gap: 8px;
}

.td-home-cat__title {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(24px, 2.2vw, 30px);
  font-weight: 500;
  line-height: 1.15;
}

.td-home-cat__cta {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.9;
}

.td-home-brands {
  padding: 56px 0 24px;
  overflow: hidden;
}

.td-home-rail {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
}

.td-home-rail--brands {
  margin-top: 8px;
  padding: 0 12px;
}

.td-home-rail__viewport {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
  touch-action: pan-y;
  cursor: grab;
}

.td-home-rail__viewport:active {
  cursor: grabbing;
}

.td-home-rail__track {
  display: flex;
  width: max-content;
  will-change: transform;
  transform: translate3d(0, 0, 0);
}

.td-home-rail__group {
  display: flex;
  align-items: center;
  gap: 48px;
  padding: 8px 24px;
  flex-shrink: 0;
}

.td-home-rail__group--products {
  gap: 16px;
  padding: 4px 8px 8px;
  align-items: stretch;
}

.td-home-rail__group--products .td-shop-card {
  flex: 0 0 240px;
  width: 240px;
  min-width: 240px;
}

.td-home-rail__btn {
  appearance: none;
  width: 52px;
  height: 52px;
  border-radius: 999px;
  border: 1px solid rgba(184, 149, 94, 0.35);
  background: linear-gradient(180deg, #fff 0%, #faf8f5 100%);
  color: #1c1a17;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 10px 28px rgba(28, 26, 23, 0.1);
  transition: background 0.22s ease, border-color 0.22s ease, color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
  z-index: 2;
  flex-shrink: 0;
}

.td-home-rail__btn svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.75;
}

.td-home-rail__btn:hover {
  border-color: #b8955e;
  color: #b8955e;
  background: #fff;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.95) inset,
    0 14px 32px rgba(28, 26, 23, 0.14);
  transform: translateY(-1px);
}

.td-home-rail__btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 14px rgba(28, 26, 23, 0.1);
}

.td-home-rail__btn:focus-visible {
  outline: 2px solid #b8955e;
  outline-offset: 3px;
}

.td-home-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 56px;
  flex: 0 0 auto;
  opacity: 0.72;
  filter: grayscale(1);
  transition: opacity 0.2s ease, filter 0.2s ease;
}

.td-home-brand:hover {
  opacity: 1;
  filter: none;
}

.td-home-brand img {
  max-width: 140px;
  max-height: 42px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.td-home-products {
  padding: 40px 0 56px;
  overflow: hidden;
}

.td-home-rail--products {
  margin-top: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .td-home-rail.is-static .td-home-rail__group[aria-hidden="true"] {
    display: none;
  }

  .td-home-rail.is-static .td-home-rail__viewport {
    overflow-x: auto;
    mask-image: none;
    -webkit-mask-image: none;
  }
}

@media (max-width: 700px) {
  .td-home-rail {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .td-home-rail__btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
  }

  .td-home-rail__btn--prev {
    left: 4px;
  }

  .td-home-rail__btn--next {
    right: 4px;
  }

  .td-home-rail__btn:hover {
    transform: translateY(-50%);
  }

  .td-home-rail__group--products .td-shop-card {
    flex-basis: 200px;
    width: 200px;
    min-width: 200px;
  }
}

.td-home-insp {
  padding: 24px 0 56px;
}

.td-home-insp__grid {
  display: grid;
  grid-template-columns: 1.55fr 0.9fr;
  gap: 16px;
  min-height: 420px;
}

.td-home-insp__main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #fff;
  border: 1px solid #e7e2db;
  overflow: hidden;
}

.td-home-insp__copy,
.td-home-insp__aside-copy {
  padding: clamp(28px, 4vw, 44px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
}

.td-home-insp__eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6b6560;
}

.td-home-insp__title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(26px, 3vw, 36px);
  font-weight: 500;
  line-height: 1.15;
  color: #1c1a17;
}

.td-home-insp__text {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: #6b6560;
}

.td-home-insp__copy .td-btn {
  align-self: flex-start;
  margin-top: 6px;
}

.td-home-insp__media,
.td-home-insp__aside-media {
  min-height: 240px;
  background: #ddd6cc center / cover no-repeat;
}

.td-home-insp__aside {
  display: grid;
  grid-template-rows: 1fr 1fr;
  background: #1c1a17;
  color: #fff;
  overflow: hidden;
}

.td-home-insp__aside .td-home-insp__eyebrow {
  color: rgba(255, 255, 255, 0.62);
}

.td-home-insp__aside-title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(24px, 2.4vw, 30px);
  font-weight: 500;
  line-height: 1.15;
}

.td-home-insp__aside .td-home-insp__text {
  color: rgba(255, 255, 255, 0.72);
}

.td-home-insp__aside-link {
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.5);
  align-self: flex-start;
}

.td-home-insp__aside-link:hover {
  border-bottom-color: #fff;
}

.td-home-services {
  background: #f3f1ee;
  padding: 36px 0;
}

.td-home-services__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.td-home-service {
  display: flex;
  align-items: center;
  gap: 12px;
}

.td-home-service__icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #1c1a17;
}

.td-home-service__icon svg {
  width: 24px;
  height: 24px;
}

.td-home-service__title {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.35;
  color: #1c1a17;
}

.td-home-projects {
  padding: 56px 0;
}

.td-home-projects__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.td-home-project {
  position: relative;
  display: block;
  min-height: 180px;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
}

.td-home-project__media {
  position: absolute;
  inset: 0;
  background: #cfc8be center / cover no-repeat;
  transition: transform 0.5s ease;
}

.td-home-project:hover .td-home-project__media {
  transform: scale(1.04);
}

.td-home-project::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0, 0, 0, 0.55));
}

.td-home-project__label {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 14px;
  z-index: 1;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.td-home-showroom {
  position: relative;
  padding: 72px 0;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(18, 16, 14, 0.82) 0%, rgba(18, 16, 14, 0.55) 55%, rgba(18, 16, 14, 0.4) 100%),
    var(--td-home-showroom-image) center / cover no-repeat;
}

.td-home-showroom__inner {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr;
  gap: 36px;
  align-items: center;
}

.td-home-showroom__eyebrow {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}

.td-home-showroom__title {
  margin: 0 0 14px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(32px, 4vw, 46px);
  font-weight: 500;
  line-height: 1.12;
}

.td-home-showroom__text {
  margin: 0 0 24px;
  max-width: 34rem;
  font-size: 15px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.8);
}

.td-home-showroom__facts {
  display: grid;
  gap: 18px;
  padding: 28px;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(4px);
}

.td-home-showroom__row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.td-home-showroom__row svg {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  flex-shrink: 0;
  opacity: 0.85;
}

.td-home-showroom__row strong {
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.td-home-showroom__row span,
.td-home-showroom__row a {
  font-size: 14px;
  line-height: 1.5;
  color: #fff;
  text-decoration: none;
}

.td-home-showroom__row a:hover {
  text-decoration: underline;
}

@media (max-width: 1100px) {
  .td-home-cats__grid {
    grid-template-columns: 1fr 1fr;
  }

  .td-home-brands__group {
    gap: 32px;
  }

  .td-home-rail__group {
    gap: 32px;
  }

  .td-home-services__grid {
    grid-template-columns: 1fr 1fr;
  }

  .td-home-insp__grid {
    grid-template-columns: 1fr;
  }

  .td-home-showroom__inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .td-home-hero {
    min-height: 70vh;
  }

  .td-home-hero__inner {
    min-height: 70vh;
    padding-top: 48px;
    padding-bottom: 72px;
  }

  .td-home-section__head {
    flex-direction: column;
    align-items: flex-start;
  }

  .td-home-cats__grid,
  .td-home-projects__grid,
  .td-home-services__grid {
    grid-template-columns: 1fr;
  }

  .td-home-insp__main {
    grid-template-columns: 1fr;
  }

  .td-home-cat {
    min-height: 220px;
  }
}
