body {
    margin: 0;
    font-family: 'Times New Roman' , Times, Serif;
    background-color: #cdcdcd;
    background-image: url('../bgwhitepc.jpg'); /* Укажите путь к фото */
    background-size: cover; /* Фото растягивается на весь экран */
    background-position: center; /* Фото центрируется */
    background-repeat: repeat; /* Фото не повторяется */
    background-attachment: fixed; /* Фото фиксируется при прокрутке */
}

.navbar {
    height: 10vh; /* Высота 10% экрана */
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 15px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin-top: 5px;
    position: fixed;
    top: 0;
    z-index: 5;
    box-sizing: border-box;
    width: 100%;
}

.logo-container {
    display: flex;
    align-items: center;
    padding-left:  10px;
}

.logo {
    width: 150px;
    height: auto;
    object-fit: contain;
    margin-right: 20px;
    padding-bottom: 7px;
}

.studio-name {
    font-size: 30px;
    color: #333;
    font-style: italic;
    font-weight: bold;
    letter-spacing: 1px;
}

.nav-buttons {
    display: flex;
    gap: 15px;
    padding-right: 10px;    
}

.nav-btn {
    background: white;
    border: 1px solid #000;
    border-radius: 10px;
    padding: 10px 20px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s;
    color: black;
    text-decoration: none;
}

.nav-btn:hover {
    background: #f0f0f0;
}

/* Стили корзины для десктопа */
.popup-overlay {
    position: fixed;
    width: 100%;
    height: 100%;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-in-out;
    display: flex;
    background: rgba(0,0,0,0.3);
    margin-top: -6.4%;
    padding-bottom: 500px;
    
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.close-popup {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 32px; /* Увеличили размер */
    cursor: pointer;
    padding: 8px; /* Добавили отступы для лучшей кликабельности */
    line-height: 1;
    transition: color 0.3s ease;
    z-index: 1;
    background: none;
    border: none;
    color: #333; /* Цвет по умолчанию */
}

.close-popup:hover {
    color: #000; /* Цвет при наведении */
    transform: scale(1.1); /* Легкое увеличение при наведении */
}

.cart-popup-content {
    display: flex;
    height: 88%;
    padding: 20px;
    flex-direction: row-reverse; /* Меняем порядок блоков */
    transform: translateY(20px);
    transition: transform 0.3s ease-in-out;
    width: 80%;
    margin-left: 10%;
    background: white;
    pointer-events: all;
    border: 1px solid #000;
    border-radius: 14px;
    margin-top: 3vh;
}

.popup-overlay.active .cart-popup-content {
    transform: translateY(0);
}

.cart-items-wrapper {
    width: 50%; /* Товары справа */
    padding-left: 30px;
    border-left: 2px solid black;
    margin-bottom: 14px;
    margin-left: 10px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    height: 100%; /* Добавляем высоту для правильной работы flex */
    min-height: 0; /* Важно для вложенных flex-элементов */
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    margin-bottom: 20px;
    padding-top: 5px;
}

/* Улучшенные стили формы */
.order-form {
    width: 50%;
    padding-right: 30px;
}

.order-form h4 {
    margin: 20px 0 15px;
    font-size: 18px;
    color: #333;
    border-bottom: 2px solid #000;
    padding-bottom: 5px;
}

.form-title-icon {
    display: none;
}
.input-group {
    margin-bottom: 15px;
}

/* Стили для выбранных кнопок */
.social-btn.selected,
.delivery-btn.selected {
    background: black;
    color: white;
}

.social-btn,
.delivery-btn {
    background: white;
    color: black;
    border: 1px solid black;
    border-radius: 20px;
    padding: 8px 16px;
    margin: 5px;
    cursor: pointer;
    transition: all 0.3s;
}

.social-btn:hover,
.delivery-btn:hover {
    background: #f0f0f0;
}

.social-btn:active,
.delivery-btn:active {
    background: black;
    color: white;
}

.social-btn {
    margin-bottom: 14px;
}

.input-label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    color: #666;
}

.input-label a {
    color: inherit; /* Наследует цвет родителя */
    text-decoration: none; /* Убирает подчеркивание */
    border-bottom: 1px dashed #666; /* Необязательный вариант */
    transition: color 0.3s ease;
}

.input-label a:hover {
    color: #000; /* Цвет при наведении */
    text-decoration: none; /* Убирает стандартное подчеркивание */
    border-bottom-style: solid; /* Для dashed варианта */
}

.order-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 14px;
    font-size: 14px;
}

.promo-code-container {
    display: flex;
    gap: 10px;
}

.apply-promo-btn {
    white-space: nowrap;
    background: #000;
    color: white;
}

#promoCodeInput:disabled {
    background: #f0f0f0;
    cursor: not-allowed;
    color: gray;
}

.cart-summary {
    position: static;
    background: white;
    padding-bottom: 14px;
    padding-right: 28px;
    border-top: 2px solid #000;
    top: 100%;
    text-align: end;
    margin-top: auto; /*прижимает к низу родительского контейнера */
}

#cartsummarytext {
    font-weight: bold;
    font-size: large;
}

#totalPrice {
    transition: opacity 0.5s ease, transform 0.3s ease;
    display: inline-block;
}

.price-update {
    animation: priceUpdate 0.5s ease;
}

@keyframes priceUpdate {
    0% { transform: translateY(-5px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

.order-btn {
    width: 100%;
    background: #000;
    color: white;
    padding: 15px;
    margin-top: 20px;
    font-size: 16px;
}

/* Крестик удаления */
.remove-item {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    z-index: 2;
    transition: color 0.2s ease
}

.remove-item:hover {
    color: #ff0000;
}

/* Адаптация карточек товаров */
.cart-item {
    position: relative;
    display: flex;
    margin-bottom: 20px;
    border: 1px solid #000;
    border-radius: 14px;
    padding: 15px;
    align-items: center;
    transition: transform 0.3s ease;
}

.cart-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Общие стили для обеих версий */
.cart-item-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 10px;
    margin-right: 15px;
}

.cart-item-info {
    flex-grow: 1;
}

.cart-item-info p {
    margin: 5px 0;
    line-height: 1.4;
}

.cart-item-price {
    position: absolute;
    bottom: 15px;
    right: 15px;
    font-weight: bold;
}

button {
    border: 1px solid #000;
    border-radius: 14px;
    background: white;
    padding: 10px 20px;
    transition: all 0.3s;
}

button:hover {
    background: #f0f0f0;
}

button:active {
    background: #000;
    color: white;
}

    /* Блок со скидками */
.sale-container {
    display: block;
    justify-content: center;
    padding: 5px;
    margin-top: 12vh;
    width: 70%; 
    margin-left: 15%;
}

.saletitle {
    margin: 0;
    padding: 0;
}

.saledesc {
    font-size: medium;
}

.sale-block {
  width: 100%;
  background: white;
  border-radius: 10px;
  padding: 5px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  background: rgba(255,255,255,0.9);
}

.sale-items {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
    justify-content: space-between;
}

/* Карточка товара */
.sale-item {
  display: flex;
  flex-wrap: nowrap;
    align-items: stretch;
  border: 1px solid black;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  background-color: white;
  height: 20vh;
    min-height: 20vh;
    width: calc(50%-10px);
    flex: 1 1 calc(50% - 10px); /* Гибкая ширина */
    margin-bottom: 10px;
    cursor: pointer;
}

.sale-item:hover {
  transform: translateY(-5px); /* Поднимаем карточку */
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2); /* Тень */
}

/* Кнопка "Добавить в корзину" */
.add-to-cart {
  display: block; /* Скрыта по умолчанию */
  width: 100%;
  padding: 10px;
  background: black;
  color: white;
  border: 1px solid black;
  border-radius: 14px;
  cursor: pointer;
  margin-top: 10px;
  white-space: nowrap;
}

.add-to-cart:hover {
    color: black;
    background-color: white;
}

.sale-item img {
  height: 150px;
  object-fit: contain;
  border-right: 1px solid black;
  flex: 0 0 150px;
    max-width: 151px;
}

.sale-item-info {
  padding: 5px;
  flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.sale-item-name {
  font-size: 1.2em;
  font-weight: bold;
  margin-bottom: 5px;
}

.sale-item-size, .sale-item-price, .sale-item-details {
  font-size: 1em;
  color: #555;
}

.sale-item-details {
  position: relative;
  display: -webkit-box;
  -webkit-line-clamp: 1; /* Ограничение одной строкой */
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 100%;
  white-space: nowrap;  
  text-overflow: ellipsis; /* Добавляет троеточие в конце */
  margin: 5px 0; /* Отступы для лучшей визуальной отделки */
}

.sale-item-details::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 50px; /* Ширина градиента */
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 1) 100%
  );
}

/* Стили для попапа товаров со скидкой */
.sipopup-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.sipopup-overlay.active {
  opacity: 1;
  visibility: visible;
}

.sipopup-container {
  position: relative;
  width: 60%;
  height: 98%;
  top: 1%;
  margin: 0 auto;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: translateY(-20px);
  transition: transform 0.3s ease;
}

.sipopup-overlay.active .sipopup-container {
  transform: translateY(0);
}

.sipopup-content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.sipopup-gallery {
  position: relative;
  height: 65vh;
}

.sipopup-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 0.3s ease-in-out;
  opacity: 1;
}

.sipopup-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.5em;
  transition: 0.3s;
}

.sipopup-arrow:hover {
  background: rgba(255, 255, 255, 1);
}

.sipopup-arrow.left { left: 10px; }
.sipopup-arrow.right { right: 10px; }

.sipopup-details {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  padding: 20px 20px 14px; /* Нижний отступ */
}

.sipopup-title {
  margin: 0 0 15px;
  font-size: 1.5em;
}

.sipopup-price {
  font-size: 1.2em;
  color: #333;
  margin: 10px 0;
}

.sipopup-size {
  color: #666;
  margin: 5px 0;
}

.sipopup-description {
  margin: 15px 0;
  color: #555;
}

.sipopup-close {
  position: absolute;
  right: 15px;
  top: 15px;
  background: none;
  border: none;
  font-size: 1.2em;
  cursor: pointer;
  color: black;
  z-index: 1000;
}

.sipopup-add-btn {
  background: black;
  color: white;
  border: 1px solid black;
  padding: 12px 30px;
    font-size: 16px;
  border-radius: 14px;
  cursor: pointer;
    width: 50%;
    margin-left: 25%;
  margin-top: auto; /* Прижимает к низу */
  margin-bottom: 10px;
}

.sipopup-add-btn:hover {
  background: white;
  color: black;
}

.add-to-cart:active,
.apply-promo-btn:active,
.order-btn:active {
    background: white !important;
    color: black !important;
    border: 1px solid black;
}

.add-to-cart:active {
    transform: scale(0.98);
}
/* Футер */
.site-footer {
    background: #1a1a1a; /* Темный фон */
    color: white;
    padding: 40px 20px;
    font-family: Arial, sans-serif;
}

/* Контент футера */
.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

/* Секции футера */
.footer-section {
    flex: 1;
    min-width: 200px;
    margin-bottom: 20px;
}

/* Логотип и описание */
.footer-logo {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 10px;
}

.footerlogo {
    border-radius: 10px;
}

.footer-description {
    font-size: 14px;
    line-height: 1.6;
    color: #ccc;
}

/* Заголовки секций */
.footer-heading {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
}

/* Ссылки */
.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: white;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #ff00e1; /* Желтый цвет при наведении */
}

/* Социальные сети */
.social-links {
    list-style: none;
    padding: 0;
}

.social-links li {
    margin-bottom: 10px;
}

.social-icon {
    color: white;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.social-icon:hover {
    color: #ff00e1; /* Желтый цвет при наведении */
}

/* Контактная информация */
.contact-info {
    list-style: none;
    padding: 0;
}

.contact-info li {
    margin-bottom: 10px;
    font-size: 14px;
}

.contact-info a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-info a:hover {
    color: #ff00e1; /* Желтый цвет при наведении */
}

/* Копирайт */
/* Стили для футера */
.footer-bottom {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #444;
    font-size: 14px;
    color: #ccc;
}

/* Ссылка на Telegram */
.TGdevlink {
    display: inline-block; /* Чтобы ссылка занимала только нужное место */
    margin-top: 10px; /* Отступ сверху */
    color: white; /* Желтый цвет для выделения */
    text-decoration: none; /* Убираем подчеркивание */
    font-weight: bold; /* Жирный текст */
    transition: color 0.3s ease; /* Плавное изменение цвета */
}

.TGdevlink:hover {
    color: #ff00e1; /* Белый цвет при наведении */
    text-decoration: none; /* Подчеркивание при наведении */
}

/* Логотип */
.footer-logo img {
    width: 150px; /* Ширина логотипа */
    height: auto; /* Сохраняем пропорции */
    margin-bottom: 10px;
}

/* Стили для уведомлений */
#notification-container {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    display: flex;
    flex-direction: column-reverse;
    gap: 10px;
    align-items: center;
    width: 100%;
    pointer-events: none;
}

.notification {
    min-width: 14%; /* Немного увеличили минимальную ширину */
    padding: 10px 28px;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 600; /* Полужирный текст */
    animation: slideIn 0.3s ease-out forwards;
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    display: flex;
    justify-content: center;
    align-items: center;
    line-height: 1.4; /* Межстрочный интервал */
    text-align: center;
}

.notification span {
    display: block;
    width: 100%;
}

.notification.success {
    background: #e8f5e9;
    border: 2px solid #43a047;
    color: #2e7d32;
}

.notification.error {
    background: #ffebee;
    border: 2px solid #e53935;
    color: #c62828;
}

@keyframes slideIn {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(100%);
    }
}

.notification.hide {
    animation: fadeOut 0.3s ease-in forwards;
}