/* Сброс */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Общие */
body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, Helvetica, Arial, sans-serif;
  background: #fff;
  color: #111;
}


.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
}

/* HEADER */
.header {
  background: #000;
  width: 100%;
  height: 110px;          /* шапка больше на ПК */
  display: flex;
  align-items: center;    /* вертикально по центру */
}

.header__container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;

  display: flex;
  justify-content: center; /* логотип по центру */
  align-items: center;
}

.header__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.header__logo img {
  height: 200px;    /* размер логотипа на ПК */
  width: auto;
}

/* Адаптив под мобилки */
@media (max-width: 600px) {
  .header {
    height: 90px;         /* чуть меньше, чтобы не съедало экран */
  }

  .header__logo img {
    height: 130px;         /* логотип меньше на телефоне */
  }
}

.footer {
  background: #000;
  color: #fff;
  margin-top: 32px;
  padding: 18px 0;
}

.footer__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
  text-align: center;
  opacity: 0.85;
  font-size: 14px;
}

html, body {
  height: 100%;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.home {
  text-align: center;
}

.home__title {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.02em;
}



.page__content {
  flex: 1;              /* растягивает контент и толкает футер вниз */
}

.region-note {
  margin-top: 12px;

  display: inline-flex;
  align-items: center;   /* 🔥 ключевая строка */
  gap: 8px;

  font-size: 14px;
  line-height: 1.4;      /* чтобы текст не «рвал» строку */
  color: #333;

  background: #f5f5f5;
  padding: 8px 12px;
  border-radius: 6px;
}

.region-note img {
  display: block;        /* 🔥 убирает baseline-баг */
  height: 16px;
  width: auto;
  flex-shrink: 0;        /* чтобы не сжимался */
}


@media (max-width: 600px) {
  .region-note {
    font-size: 13px;
    padding: 6px 10px;
  }

  .region-note img {
    height: 14px;
  }
}

.flag-emoji {
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  font-size: 16px;
  line-height: 1;
}

.home__subtitle{
  margin-top: 24px;
  font-size: 18px;
  font-weight: 600;
}

.category-grid{
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.category-card{
  display: block;
  text-decoration: none;
  color: inherit;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.category-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(0,0,0,0.12);
}

.category-card img{
  width: 100%;
  height: 270px;
  object-fit: cover;
  display: block;
}

.category-card__title{
  padding: 12px 14px;
  font-weight: 600;
  text-align: center;
}

@media (max-width: 600px){
  .category-grid{
    grid-template-columns: 1fr;  /* на телефоне в столбик */
  }
  .category-card img{
    height: 260px;
  }
}

.order-note {
  margin-top: 28px;
  text-align: center;
  font-size: 14px;
  color: #333;
}

.order-note a {
  color: #0088cc;          /* фирменный Telegram-синий */
  text-decoration: none;
  font-weight: 600;
}

.order-note a:hover {
  text-decoration: underline;
}

/* ===== Product page ===== */

.product-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 30px 16px;
}

.product-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.product-title {
  margin: 0;
  font-size: 34px;
  font-weight: 700;
  text-align: center;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2px;
  white-space: nowrap;
}

.badge-main {
  background: #111;
  color: #ffd54a;
  border: 1px solid rgba(0,0,0,.12);
}

.product-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: start;
}

/* ===== Slider ===== */

.slider {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #f4f4f4;
}

/* важно: отдельный слой под картинку */
.slider-viewport {
  position: relative;
  z-index: 1;
  width: 100%;
  overflow: hidden;
}

.slider-track {
  display: flex;
  transition: transform .25s ease;
  will-change: transform;
}

.slide {
  min-width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.slide img {
  width: 100%;
  max-height: 520px;
  object-fit: contain;
  background: #f4f4f4;
}

/* стрелки: поверх картинки, всегда видны */
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-size: 30px;
  line-height: 1;

  display: grid;
  place-items: center;

  background: rgba(0,0,0,.55);
  color: #fff;

  z-index: 10; /* ВАЖНО: поверх всего */
  opacity: 0.95;

  box-shadow: 0 8px 22px rgba(0,0,0,.25);
  backdrop-filter: blur(6px);
}

.slider-btn:hover {
  opacity: 1;
}

.slider-btn--left { left: 12px; }
.slider-btn--right { right: 12px; }

/* если в JS ставишь disabled — пусть будет видно */
.slider-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

/* точки: поверх картинки снизу */
.slider-dots {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(0,0,0,.25);
  backdrop-filter: blur(8px);
  z-index: 9;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 0;
  background: rgba(255,255,255,.55);
  cursor: pointer;
  padding: 0;
}

.dot.is-active {
  width: 18px;
  background: rgba(255,255,255,.95);
}

/* ===== Info ===== */

.product-info {
  padding-top: 6px;
}

.product-price {
  font-size: 28px;
  margin-bottom: 14px;
}

.price-old {
  text-decoration: line-through;
  color: #999;
  margin-right: 10px;
}

.price-sale {
  color: #d32f2f;
  font-weight: 800;
}

.tags {
  margin-bottom: 18px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 10px;
  background: #efefef;
  margin-right: 6px;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 600;
}

.block { margin-top: 16px; }
.block h3 { margin: 0 0 8px; }

.text { margin: 0; line-height: 1.55; }

.attrs {
  list-style: none;
  padding: 0;
  margin: 0;
}

.attrs li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}

.attrs-k { font-weight: 700; }
.attrs-v { color: #333; }

/* ===== Mobile ===== */

@media (max-width: 900px) {
  .product-layout {
    grid-template-columns: 1fr;
  }

  .product-head {
    flex-direction: column;
    gap: 10px;
  }

  .product-title {
    font-size: 28px;
  }

  .slide img {
    max-height: 420px;
  }

  .slider-btn {
    width: 44px;
    height: 44px;
    font-size: 28px;
  }
}

/* ===== Lightbox ===== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.82);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 18px;
}

.lightbox.is-open {
  display: flex;
}

.lightbox-body {
  max-width: 1100px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-body img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 12px;
  background: rgba(255,255,255,.04);
}

.lightbox-close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-size: 30px;
  line-height: 1;
  background: rgba(255,255,255,.12);
  color: #fff;
  display: grid;
  place-items: center;
  backdrop-filter: blur(6px);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-size: 34px;
  line-height: 1;
  background: rgba(255,255,255,.12);
  color: #fff;
  display: grid;
  place-items: center;
  backdrop-filter: blur(6px);
}

.lightbox-nav--left { left: 16px; }
.lightbox-nav--right { right: 16px; }

.lightbox-nav:disabled {
  opacity: .35;
  cursor: default;
}

.stock { margin: 10px 0 14px; }

.stock-badge {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.stock-badge--ok {
  background: rgba(46, 204, 113, .15);
  color: #1b7f46;
  border: 1px solid rgba(46, 204, 113, .35);
}

.stock-badge--no {
  background: rgba(231, 76, 60, .12);
  color: #b13b31;
  border: 1px solid rgba(231, 76, 60, .35);
}

.notice{
  display: flex;
  align-items: center;
  gap: 10px;

  padding: 12px 14px;
  border-radius: 14px;

  font-size: 14px;
  font-weight: 600;

  border: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
}

.notice__icon{
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;

  font-weight: 900;
  font-size: 14px;
  flex: 0 0 auto;
}

.notice__text{
  line-height: 1.25;
}

/* success */
.notice--success{
  background: rgba(46, 204, 113, .10);
  border-color: rgba(46, 204, 113, .25);
  color: #145a32;
}

.notice--success .notice__icon{
  background: rgba(46, 204, 113, .18);
  color: #1b7f46;
}

/* на мобилке чуть компактнее */
@media (max-width: 900px){
  .notice{
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
  }
}


.buy{
  margin-top: 14px;
  display: grid;
  gap: 12px;
}

.qty label{
  font-size: 13px;
  font-weight: 700;
  display: block;
  margin-bottom: 6px;
}

.qty-row{
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  gap: 10px;
  align-items: center;
}

.qty-btn{
  height: 44px;
  border-radius: 12px;
  border: 1px solid #ddd;
  background: #fff;
  cursor: pointer;
  font-size: 22px;
}

.qty input{
  height: 44px;
  border-radius: 12px;
  border: 1px solid #ddd;
  padding: 0 12px;
  font-size: 16px;
  text-align: center;
}

.buy-btn{
  height: 46px;
  border-radius: 14px;
  border: 0;
  cursor: pointer;
  font-size: 16px;
  font-weight: 800;
  background: #111;
  color: #ffd54a;
}

.buy-btn:disabled{
  opacity: .45;
  cursor: default;
}

.category-page{
  max-width: 1100px;
  margin: 0 auto;
  padding: 30px 16px;
}

.category-title{
  margin: 0 0 18px;
  text-align: center;
  font-size: 32px;
  font-weight: 800;
}

.products-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.product-card{
  display: block;
  border-radius: 16px;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(0,0,0,.08);
  box-shadow: 0 10px 25px rgba(0,0,0,.06);
  text-decoration: none;
  color: inherit;
  transition: transform .15s ease;
}

.product-card:hover{
  transform: translateY(-2px);
}

.product-card__img{
  background: #f4f4f4;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-card__img img{
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.no-img{
  color: #777;
  font-weight: 600;
}

.product-card__body{
  padding: 12px 12px 14px;
}

.product-card__name{
  font-weight: 800;
  margin-bottom: 8px;
  line-height: 1.25;
}

.product-card__price .old{
  color: #999;
  text-decoration: line-through;
  margin-right: 8px;
}

.product-card__price .sale{
  color: #d32f2f;
  font-weight: 900;
}

.product-card__price .price{
  font-weight: 900;
}

.stock-chip{
  margin-top: 10px;
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  background: rgba(231, 76, 60, .12);
  border: 1px solid rgba(231, 76, 60, .25);
  color: #b13b31;
}

@media (max-width: 900px){
  .products-grid{ grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px){
  .products-grid{ grid-template-columns: 1fr; }
}

.product-card__img{
  position: relative;           /* важно для абсолютного чипа */
  background: #f4f4f4;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;             /* чтобы чип не вылезал */
}

.img-chip{
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;

  padding: 8px 10px;
  border-radius: 12px;

  font-size: 13px;
  font-weight: 700;
  text-align: center;

  background: rgba(20, 20, 20, 0.35); /* полупрозрачное */
  color: #fff;

  backdrop-filter: blur(10px);
  box-shadow: 0 10px 24px rgba(0,0,0,.18);
}

.buy-btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 14px 22px;
  border-radius: 14px;
  border: none;

  font-size: 16px;
  font-weight: 800;
  text-decoration: none;

  background: #111;
  color: #fff;
  cursor: pointer;

  transition: transform .15s ease, box-shadow .15s ease, opacity .15s;
}

.buy-btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(0,0,0,.2);
}

.buy-btn:disabled{
  opacity: .45;
  cursor: not-allowed;
}

/* Telegram-акцент */
.buy-btn--tg{
  background: linear-gradient(135deg, #2AABEE, #229ED9);
}
