/* ====== БАЗА ====== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: #f3eee8;
  color: #18171a;
  min-height: 100vh;
  position: relative;
}

/* Фоновая анимация */

.bg-animation {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(circle at 10% 0%, rgba(255,255,255,0.7) 0, rgba(255,255,255,0) 45%),
    radial-gradient(circle at 90% 100%, rgba(197,206,232,0.6) 0, rgba(197,206,232,0) 55%),
    linear-gradient(180deg, #f6f1ea 0%, #e8e2da 60%, #e5dfd6 100%);
  animation: bgMove 20s ease-in-out infinite alternate;
}

@keyframes bgMove {
  0% {
    filter: blur(0px);
    transform: translate3d(0,0,0);
  }
  100% {
    filter: blur(2px);
    transform: translate3d(0, -10px, 0);
  }
}

/* ====== ПРОМО-ПОЛОСА ====== */

.top-banner {
  width: 100%;
  text-align: center;
  background: rgba(24,23,26,0.94);
  color: #f7f4ef;
  font-size: 13px;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 10px 16px;
  position: sticky;
  top: 0;
  z-index: 20;
}

/* ====== HEADER ====== */

.header {
  position: sticky;
  top: 38px;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 56px;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: rgba(246,241,234,0.92);
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

.logo {
  font-family: "Cormorant Garamond", serif;
  font-size: 24px;
  letter-spacing: .18em;
  text-transform: uppercase;
  cursor: pointer;
}

.nav {
  display: flex;
  gap: 28px;
  font-size: 14px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.nav a {
  text-decoration: none;
  color: #3b3940;
  position: relative;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  height: 1px;
  width: 0;
  background: #11111a;
  transition: width .2s;
}

.nav a:hover::after {
  width: 100%;
}

.cart-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #11111a;
  color: #f8f5f0;
  text-decoration: none;
  font-size: 13px;
}

.cart-count {
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #f8f5f0;
  color: #11111a;
  font-size: 11px;
}

/* Бургер */

.burger {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  padding: 0;
  margin-left: 12px;
  cursor: pointer;
}

.burger span {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: #18171a;
}

/* ====== ОСНОВНОЙ КОНТЕНТ ====== */

.main {
  max-width: 1160px;
  margin: 40px auto 80px;
  padding: 0 24px 80px;
}

/* ====== HERO ====== */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  padding: 40px 32px 56px;
  border-radius: 32px;
  background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(238,233,225,0.96));
  box-shadow: 0 32px 70px rgba(10,12,22,0.06);
  margin-bottom: 64px;
}

.hero-content {
  max-width: 520px;
}

.hero-kicker {
  font-size: 13px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #8a8580;
  margin-bottom: 12px;
}

.hero h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: 40px;
  line-height: 1.1;
  margin: 0 0 16px;
  color: #222029;
}

.hero-sub {
  font-size: 15px;
  line-height: 1.7;
  color: #5f5a55;
  margin-bottom: 24px;
}

.btn-primary,
.btn-secondary {
  cursor: pointer;
  border-radius: 999px;
  border: none;
  font-size: 14px;
  padding: 11px 24px;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.btn-primary {
  background: #11111a;
  color: #f7f4ee;
}

.btn-primary:hover {
  background: #262630;
}

.btn-secondary {
  background: #f4f1ec;
  color: #11111a;
  border: 1px solid rgba(0,0,0,0.08);
}

.btn-secondary:hover {
  background: #e9e3da;
}

.hero-image {
  border-radius: 24px;
  background: radial-gradient(circle at 0 0, #ffffff, #e4ded3 55%, #d6d0c6 100%);
  min-height: 220px;
  position: relative;
  overflow: hidden;
}

.hero-image::after {
  content: "";
  position: absolute;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 0%, rgba(255,255,255,0.7), rgba(199,204,230,0.4));
  filter: blur(4px);
  top: 40%;
  left: 60%;
  transform: translate(-50%, -50%);
}

.hero-image-label {
  position: absolute;
  left: 24px;
  bottom: 24px;
  font-size: 13px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #716c65;
}

/* ====== КАТАЛОГ ====== */

.section-header h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: 26px;
  letter-spacing: .18em;
  text-transform: uppercase;
  margin: 0 0 24px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.product-card {
  background: rgba(255,255,255,0.96);
  border-radius: 24px;
  padding: 18px 18px 20px;
  box-shadow: 0 18px 40px rgba(10,8,20,0.05);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.product-link {
  text-decoration: none;
  color: inherit;
}

.product-image {
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  background: #d3d0cb;
  position: relative;
}

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

.product-image--grey {
  background: radial-gradient(circle at 0 0, #63656a, #2b2d30);
  height: 220px;
}

.product-image--navy {
  background: radial-gradient(circle at 0 0, #1f2742, #111524);
  height: 220px;
}

.product-image-label {
  position: absolute;
  left: 14px;
  bottom: 12px;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgba(245,243,237,0.9);
}

.product-tag {
  margin: 6px 0 0;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #9b948d;
}

.product-card h3 {
  margin: 4px 0;
  font-size: 16px;
  font-weight: 500;
}

.price {
  margin: 0 0 4px;
  font-weight: 600;
  font-size: 15px;
}

.size-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.size-row label {
  font-size: 13px;
  color: #7b756e;
}

.size-select {
  flex: 1;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.12);
  padding: 6px 10px;
  font-size: 13px;
  background: #fbf7f1;
}

.product-card .btn-secondary {
  margin-top: 10px;
  width: 100%;
}

.product-more {
  margin-top: 6px;
  text-align: center;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  text-decoration: none;
  color: #918a82;
}

/* ====== О БРЕНДЕ И КОНТАКТЫ ====== */

.about,
.contacts {
  margin-top: 64px;
}

.about h2,
.contacts h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: 24px;
  letter-spacing: .18em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.about p,
.contacts p {
  max-width: 640px;
  font-size: 15px;
  line-height: 1.8;
  color: #5d564f;
}

/* ====== FOOTER ====== */

.footer {
  padding: 24px 32px 36px;
  border-top: 1px solid rgba(0,0,0,0.06);
  font-size: 13px;
  color: #7b756f;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.footer-links {
  display: flex;
  gap: 20px;
}

.footer-links a {
  color: inherit;
  text-decoration: none;
}

/* ====== REVEAL АНИМАЦИЯ ====== */

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .6s ease-out, transform .6s ease-out;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ====== СТРАНИЦА ТОВАРА ====== */

.product-page {
  max-width: 1100px;
  margin: 140px auto 80px;
  padding: 0 24px 80px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 40px;
}

.product-gallery {
  width: 100%;
}

.gallery-main {
  width: 100%;
  border-radius: 24px;
  overflow: hidden;
  background: #d6d1c7;
}

.gallery-main img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  display: block;
}

.gallery-thumbs {
  display: flex;
  gap: 12px;
  margin-top: 12px;
}

.gallery-thumbs img {
  width: 80px;
  height: 80px;
  border-radius: 12px;
  object-fit: cover;
  cursor: pointer;
  opacity: .6;
  transition: transform .2s, opacity .2s;
}

.gallery-thumbs img:hover {
  opacity: 1;
  transform: scale(1.05);
}

.product-info {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.product-info h1 {
  font-size: 26px;
  margin: 0;
}

.product-sub {
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #958f87;
}

.price-big {
  font-size: 22px;
  font-weight: 600;
  margin-top: 4px;
}

.product-info label {
  font-size: 13px;
  color: #7b756f;
}

.product-info .size-select {
  max-width: 180px;
}

.product-info .btn-primary {
  margin-top: 8px;
  max-width: 240px;
}

.product-desc {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.8;
  color: #5d564f;
}

/* ====== КОРЗИНА, АККАУНТ, ИСТОРИЯ ====== */

.page-shell {
  max-width: 900px;
  margin: 140px auto 80px;
  padding: 0 24px 80px;
}

.page-shell h1 {
  font-family: "Cormorant Garamond", serif;
  font-size: 30px;
  margin-bottom: 24px;
}

.cart-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  margin-bottom: 24px;
}

.cart-table th,
.cart-table td {
  padding: 10px 6px;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.cart-table th {
  text-align: left;
  font-weight: 500;
  color: #847e78;
}

.cart-summary {
  display: flex;
  justify-content: flex-end;
  gap: 14px;
  align-items: center;
  font-size: 16px;
  font-weight: 500;
}

.cart-empty {
  font-size: 14px;
  color: #7a746d;
}

/* Формы (аккаунт) */

.form-card {
  background: rgba(255,255,255,0.96);
  border-radius: 24px;
  padding: 24px 22px 26px;
  box-shadow: 0 16px 40px rgba(10,8,20,0.05);
  max-width: 420px;
}

.form-card h2 {
  margin-top: 0;
  font-size: 20px;
  margin-bottom: 14px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}

.form-row label {
  font-size: 13px;
  color: #7c756f;
}

.form-row input {
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.14);
  padding: 8px 12px;
  font-size: 14px;
  background: #fbf7f1;
}

.form-note {
  font-size: 12px;
  color: #9a938b;
  margin-top: 6px;
}

/* История заказов */

.orders-list {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.orders-list th,
.orders-list td {
  border-bottom: 1px solid rgba(0,0,0,0.06);
  padding: 10px 6px;
}

.orders-list th {
  text-align: left;
  color: #857f77;
}

/* ====== АДАПТИВ ====== */

@media (max-width: 1040px) {
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .header {
    padding-inline: 24px;
  }

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

@media (max-width: 780px) {
  .header {
    top: 38px;
  }

  .nav {
    position: fixed;
    inset: 80px 16px auto 16px;
    padding: 16px 18px;
    background: rgba(246,241,234,0.98);
    border-radius: 18px;
    flex-direction: column;
    gap: 14px;
    transform: translateY(-20px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s, transform .2s;
  }

  .nav.nav--open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .burger {
    display: flex;
  }

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

  .product-page {
    grid-template-columns: 1fr;
    margin-top: 120px;
  }

  .gallery-main img {
    height: 360px;
  }

  .page-shell {
    margin-top: 120px;
  }
}