
@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap');

.checkbox-input,
.radio-input {
  appearance: none;
  position: relative;
  width: 30px;
  height: 30px;
  box-shadow: inset 0 0 5px rgb(0 0 0 / 0.2);
  border-radius: 10px;
  border: 1px solid #FFFFFF;
  transition: 500ms;
}

.radio-input {
  border-radius: 50%;
}

body {
    font-family: Roboto;
    background: url('../background.png');
    background-size: cover;
    margin: 0;
    padding: 0;
    align-items: center;
    justify-content: center;
}

.container {
      width: 100%;
      max-width: 1300px;
      min-height: 80vh;
      margin: 0 auto;
      padding: 0 20px;
    }

.main-head{
    background-color: #48403c;
    margin: 0;
    padding: 0 40px;
    height: 60px;
    display: flex;
    justify-content:space-between;
    align-items: center;
    border-radius: 0 0 40px 40px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    width: 40px;
}

.logo p {
    font-weight: bold;
    color: azure;
}

a {
    color: azure;
    text-decoration: none;
    font-weight: bold;
    font-size: 18px;
    margin: 0px 20px 0px 20px;
}

.links {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.button {
    width: calc(136px + 30px);
    font-size: 18px;
    font-weight: regular;
    padding: 5px 15px;
    border-radius: 15px;
    background-color: #DCF402;
}

section {
        /* width: 100%;
        max-width: 1200px;
        margin: 0 auto; */
    background-color: white;
    padding: 10px 40px;
}

.section-title{
    font-size: 28px;
    margin: 0px 0 20px;
    width: 100%;
    height: fit-content;
}

.grid {
    display:flexbox;
    border-top-left-radius: 30px;
    border-top-right-radius: 30px;
    min-height: 80vh;
}

img {
    width: 100%;
    border-radius: 20px;
}

.card{
    width: fit-content;
    flex: 0 0 calc(20% - 16px);
    cursor: pointer;
    transition: 0.2s;
}

.card:hover {
    transform: scale(1.03);
}


.catalog {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    width: fit-content;
}

h4, p, .price {
    width: 100%;
    margin: 5px;
}

.more {
    display: block;
    padding: 10px 20px;
    border-radius: 10px;
    background-color: #aeaeae;
    border: none;
    cursor: pointer;
    width: 50%;
    height: fit-content;
}

footer {
    width: 100%;
    padding: 60px 0;
    background-color: #D9D9D9;
    display: flex;
    align-items: center;
    justify-content: center;
}

footer div {
    width: 100%;
    max-width: 1300px;
}

.about-us {
    display: grid;
    padding-top: 100px;
    align-items: center;
    justify-content: center;
}

.big-text {
    font-size: 36px;
    margin: 20px;
}

.quotation-mark {
    font-size: 100px;
    margin: 0;
    height: fit-content;
}

.quotation-mark.down {
    margin-top: 100px;
}

.text-about {
    display: flex;
    align-items: start;
    width: 100%;
}

.text-ps {
    display: grid;
    width: 50%;
    
}

.text-ps-accent {
    color: #667104;
}

.delivery {
    padding-top: 100px;
    padding-bottom: 100px;
}

.cards-punct {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.cards-punct .card-dev {
    flex: 1 1 calc(33.333% - 30px);
}

.cards-punct div h3, 
.cards-punct div p {
    display: grid;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
}

.cards-punct div h3 {
    font-size: 36px;
    width: 80px;
    height: 80px;
    margin: 20px auto;
    border-radius: 50%;
    color: white;
    background-color: #202020;

    display: flex;
    align-items: center;
    justify-content: center;
}

.cards-punct div p {
    font-size: 16px;
    width: 100%;
    height: fit-content;
    margin: 0;
}

footer {
    background-color: #48403c;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    padding: 30px 80px;
    box-sizing: border-box;
}

footer div {
    align-items: center;
    justify-content: center;
    flex: 0 0 calc(50% - 40px);
    gap: 20px;
    box-sizing: border-box;
}  

footer a {
    display: block;
    margin: 5px 5px;
    width: fit-content;
    border: none;
}
footer a img {
    width: 30px;
    border-radius: 0;
}
.azure {
    color: #f0ffff;
}
.bold {
    font-weight: bold;
}
button {
    font-size: 18px;
    font-weight: regular;
    padding: 10px 20px;
    border-radius: 15px;
    background-color: #DCF402;
    border: none;
    cursor: pointer;
}
.right {
    display: flex;
    align-items: start;
    justify-content: end;
    width: 100%;
    margin-bottom: auto;
}

footer .logo {
    font-size: 24px;
    font-weight: bold;
    color: #DCF402;
}

.pred-footer {
    width: 100%;
    height: 30px;
    background-color: #48403c;
    border-radius: 50px 50px 0px 0px;
}
.social-networks {
    display: flex;
    gap: 0px;
    align-items: start;
    justify-content: start;
}

.button-spase {
    display: flex;
    padding-left: 0px;
    align-items: center;
    justify-content: center;
    width: 100%;
}

/* PRODUCT PAGE */


.product-layout {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 40px 0;
}

.product-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.product-title {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
}

.price {
  font-size: 24px;
  font-weight: 700;
  color: #2a7a2a;
}

.product-desc {
  font-size: 16px;
  color: #555;
  line-height: 1.5;
}

/* RECOMENDATION */

.tea-info {
  display: flex;
  gap: 40px;
  padding: 36px;
  background: #c9cea7; /* оливковый фон */
  border-radius: 0px;
}

.tea-info__text {
  flex: 1;
  color: #2b2b2b;
}

.tea-info__text h2 {
  margin-top: 0;
  font-size: 28px;
  letter-spacing: 1px;
}

.tea-info__text p {
  font-size: 16px;
  line-height: 1.6;
  color: #3a3a3a;
}

.tea-info__btn {
  margin-top: 16px;
  padding: 10px 22px;
  border: none;
  border-radius: 15px;
  background: #b7bc7a;
  color: #1f1f1f;
  font-weight: 400;
  cursor: pointer;
  transition: 0.2s;
}

.tea-info__btn:hover {
  background: #aab06b;
}

.tea-info__gallery {
  flex: 0 0 420px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.tea-info__gallery img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 4px;
}

.gallery {
    position: relative;
    width: 400px;
    height: 400px;
}

.gallery img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 10px;
}

.nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: white;
    border: none;
    font-size: 28px;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 6px;
}

.prev { left: 10px; }
.next { right: 10px; }

.product-desc-short {
    display: -webkit-box;
    -webkit-line-clamp: 1;   /* число строк */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* TAGGS */

.card-img-wrap {
    position: relative;
}

.badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 4px 8px;
    font-size: 12px;
    color: #fff;
    border-radius: 4px;
}

.badge.new { background: #2ecc71; }
.badge.sale { background: #e74c3c; left: auto; right: 8px; }
.badge.out { background: #7f8c8d; top: auto; bottom: 8px; }
.badges { position: relative; top: 10px; padding: 0 10px; margin: 0 50px 0px 50px; z-index: 10;}

.price {
    font-size: 18px;
    margin: 6px 0;
}

.old-price {
    text-decoration: line-through;
    color: #999;
    margin-right: 6px;
}

.sale-price {
    color: #e74c3c;
    font-weight: bold;
}

.tags {
    margin: 6px 0;
}

.tag {
    display: inline-block;
    background: #f1f1f1;
    padding: 2px 6px;
    margin: 2px;
    font-size: 12px;
    border-radius: 3px;
}


/* SORTING */
.sort-select {
    border: none;
    padding: 3px 10px;
    border-radius: 5px;
}

.sort {
    display: flex;
    align-items: start;
    justify-content: start;
    width: fit-content;
}

.sort h4 {
    margin: 0;
}

.catalog-controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.tag-filter {
    margin-right: 10px;
    font-size: 14px;
    display: inline-table;
}

.tag-filter input[type="checkbox"] {
    background-color: none;
    accent-color: #DCF402;
    border: #1f1f1f 2px solid;
}

.tag-filters {
    width: 80%;
}

/* slider */

/* Контейнер слайдера */
.promo-slider {
    position: relative;
    width: 100%;
    /* Высота баннера на ПК */
    height: 200px; 
    overflow: hidden;
    border-radius: 12px; /* Скругление углов */
    margin-top: 20px;
    margin-bottom: 24px; /* Отступ от товаров */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Обертка для слайдов (движущаяся лента) */
.slider-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease-in-out; /* Плавность анимации */
}

/* Сам слайд */
.slide {
    min-width: 100%;
    height: 100%;
    box-sizing: border-box;
}

/* Картинка внутри слайда */
.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Картинка заполняет блок, обрезая лишнее, не искажаясь */
    display: block;
}

/* Точки навигации снизу */
.slider-dots {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
}

.dot.active {
    background-color: #fff;
    transform: scale(1.2);
}

/* Стрелки переключения */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.3);
    color: white;
    border: none;
    font-size: 24px;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 10;
    transition: background 0.3s;
    user-select: none;
}

.slider-btn:hover {
    background: rgba(0,0,0,0.6);
}

.prev { left: 10px; }
.next { right: 10px; }

/* Адаптив для мобильных */
@media (max-width: 600px) {
    .promo-slider {
        height: 200px; /* Уменьшаем высоту на телефоне */
        margin-bottom: 16px;
        border-radius: 8px;
    }
    
    .slider-btn {
        padding: 5px 10px;
        font-size: 18px;
    }
}


/* ===== Mobile & Typography Improvements ===== */
:root {
    --base-font-size: 16px;
    --base-line-height: 1.55;
    --accent-color: #DCF402;
}

html {
    font-size: var(--base-font-size);
}


/* make media (images, svg) responsive */
img, picture, video, svg {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Comfortable tappable controls */
button, .button, .tea-info__btn, .more {
    font-family: inherit;
    font-size: 1rem;
    padding: 12px 16px;
    border-radius: 12px;
    box-sizing: border-box;
}

/* Container: keep side padding on desktop, remove on small screens */
.container {
    box-sizing: border-box;
    padding: 0 20px;
}

/* Slightly smaller headings for better fit on narrow screens */
.section-title { font-size: 26px; }
.big-text { font-size: 28px; }
.product-title { font-size: 28px; }

.short-catalog .card:nth-child(n+6) {
    display: none;
}

select.sort-select {
    font-size: 12px;
    padding: 2px 4px;
    border-radius: 8px;
    border: 1px solid #ccc;

}

/* Responsive adjustments */
@media (max-width: 900px) {
    .promo-slider { height: 100px;}
    .slide { height: 100px;}
    .slide img { height: 100px;}
    .slider-btn { width: auto;}
    .card { flex: 0 0 calc(50% - 12px); }
    .cards-punct .card-dev { flex: 1 1 calc(50% - 30px); }
    .tea-info { flex-direction: column; gap: 16px; padding: 20px; }
    .product-layout { flex-direction: column; }
    .gallery { width: 100%; height: auto; }
    .text-ps { width: 100%; }
}

@media (max-width: 600px) {
    html { font-size: 15px; }
    body { font-size: 0.9375rem; background: white;}
    /* remove side paddings on mobile as requested */
    .container { padding: 0; }
    .grid { padding: 10px;}

    .main-head { padding: 10px 12px; height: auto; flex-wrap: wrap; gap: 8px; }
    .links { justify-content: flex-end; }
    a { font-size: 16px; margin: 0 8px; }
    .section-title { font-size: 20px; margin: 8px 0; }
    .big-text { font-size: 18px; }
    h4 { width: 90%;}

    /* make cards full width on small screens */
    .catalog {
        display: flex;
        flex-wrap: wrap;
        gap: 12px;
        width: 100%;
    }

    .card {
        /* flex-grow: 0, flex-shrink: 0, flex-basis: calc(...) */
        flex: 0 0 calc(50% - 6px); 
        max-width: calc(50% - 6px); /* Для страховки */
        /* width: 100%;  <-- УДАЛИ ЭТУ СТРОКУ, она ломает ряд */
        box-sizing: border-box;     /* Важно, чтобы паддинги не увеличивали ширину */
    }
       
    .cards-punct .card-dev { flex: 1 1 100%; }
    .card-img-wrap img { width: auto; }

    footer { padding: 24px 12px; }
    footer div { flex: 0 0 100%; max-width: 100%; }
    .main-head { border-radius: 0;}
    .product-layout { padding: 12px 0; gap: 12px; }
    .product-info { gap: 8px; }
    .tea-info__gallery { display: none; }
    .catalog-controls { flex-direction: column; align-items: start; gap: 12px; }

    .nav { font-size: 22px; padding: 6px 10px; }
    .links { width: fit-content;}
    
    header .button { display: none;}
    .more, .button, button, .tea-info__btn { width: 100%; box-sizing: border-box; padding: 12px; font-size: 16px; }

    .price { font-size: 20px; }
    .product-title { font-size: 22px; }
    .quotation-mark { font-size: 32px;}
    .product-desc-short { width: 90%;}
    
    .pred-footer { display: none;}
    footer { display: flex; flex-wrap: wrap; margin: 0; padding: 20px 0px ;}
    footer div .logo { font-size: 16px;}
    footer a img { width: 24px; }
    footer div { width: 50%; flex: 0 0 calc(50% - 15px)}
    footer .right { width: 50%;}
    footer .right button { width: fit-content;}

    button.nav { width: fit-content;}
    .badges { margin: 0;}
    span.badge { font-size: 18px; padding: 2px 6px;}
}

/* end mobile improvements */

/* Контейнер для выравнивания */
.sort {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0; /* Отступы сверху/снизу */
}

.sort label {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}

/* Сам селект */
#sortSelect,
#weightSelect {
    /* 1. Убираем стандартные системные стили */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;

    /* 2. Задаем размеры и шрифты */
    padding: 5px 30px 5px 10px; /* Справа отступ больше для стрелки */
    font-size: 14px;
    font-family: inherit;
    line-height: 1.5;
    color: #333;
    background-color: #fff;
    
    /* 3. Границы и скругления */
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    
    /* 4. Рисуем кастомную стрелку через SVG в фоне */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23333333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 16px;
    
    cursor: pointer;
    transition: all 0.2s ease;
}

/* Эффект при наведении */
#sortSelect:hover {
    border-color: #b0b0b0;
}


/* Адаптив для мобильных (добавь это внутрь твоего @media) */
@media (max-width: 600px) {
    .sort {
        flex-direction: column; /* Лейбл сверху, селект снизу */
        align-items: flex-start;
        gap: 8px;
    }
    
    #sortSelect {
        width: 100%; /* На мобильном растягиваем на всю ширину */
    }
}

