/* Общие настройки */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Arial', sans-serif;
  position: relative;
  /* Убрали overflow: hidden и height: 100vh */
}

/* Фон как отдельный слой */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('images/background.jpg');
  background-size: cover;
  background-position: top;
  background-attachment: fixed;
  z-index: -1;
}

/* Логотип */
#logo {
  position: absolute;
  width: 35%;
  top: 3px;
  left: 35%;
  cursor: grab;
  z-index: 100;
}

#logo:active {
  cursor: grabbing;
}
body.modal-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
  height: 100%;
}

/* Серая полоска (заголовок) */
#bar {
  position: absolute;
  width: 90%;
  height: 30px;
  background-color: #777777;
  top: calc(14% + 170px);
  left: 5%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  z-index: 99;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

#bar h1 {
  color: white;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

#bar:active {
  cursor: grabbing;
}

/* Белый контактный бар — теперь точно так же, как полоска, но 90% ширины */
#contact-bar {
  position: absolute;
  width: 90%;
  height: 30px;
  background-color: white;
  top: calc(14% + 210px); /* Начальное положение — ниже серой полоски */
  left: 5%;              /* ← ВСЁ! Центрирование без transform! */
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  z-index: 98;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  text-align: center;
  line-height: 1.4;
  font-family: 'Courier New', monospace;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  word-break: break-all;
  padding: 0 10px;
}

#contact-bar:active {
  cursor: grabbing;
}

.draggable {
  transition: 
    left 0.5s ease,
    top 0.5s ease,
    filter 0.2s ease;
}

.draggable:hover {
  filter: brightness(1.1);
}

.draggable.active {
  transition: none !important;
  filter: brightness(1.3) drop-shadow(0 0 15px rgba(255, 255, 255, 0.8));
}

/* Кнопка сброса позиций */
.reset-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 50px;
  height: 50px;
  background: #ff3366;
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  z-index: 1000;
  box-shadow: 0 4px 15px rgba(255, 51, 102, 0.4);
  transition: all 0.3s ease;
}

.reset-button:hover {
  background: #e62e5c;
  transform: rotate(90deg);
}


/* Мобильная версия - скрываем основные элементы и показываем упрощенный текст */
@media (max-width: 768px) {
  /* Скрываем логотип, бар и контактную строку */
  #logo,
  #bar,
  #contact-bar {
    display: none;
  }
  
  /* Показываем мобильный заголовок */
  .mobile-header {
    display: block;
    position: absolute;
    top: 10px;
    left: 5%;
    width: 90%;
    background: rgba(30, 30, 30, 0.9);
    padding: 15px;
    border-radius: 12px;
    color: white;
    text-align: center;
    z-index: 100;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  }
  
  .mobile-header h1 {
    font-size: 18px;
    margin-bottom: 8px;
    color: #fff;
  }
  
  .mobile-header p {
    font-size: 14px;
    color: #ccc;
    line-height: 1.4;
  }
  
  /* Корректируем позиции остальных блоков */
  .gallery-container {
    top: calc(10% + 100px) !important;
  }
  
  .content-section {
    top: calc(10% + 240px) !important;
  }
  
  .visualizer {
    top: calc(10% + 280px) !important;
  }
}

@media (max-width: 480px) {
  .mobile-header {
    top: 5px;
    padding: 12px;
  }
  
  .mobile-header h1 {
    font-size: 16px;
  }
  
  .mobile-header p {
    font-size: 12px;
  }
  
  .gallery-container {
    top: calc(10% + 90px) !important;
  }
  
  .content-section {
    top: calc(10% + 220px) !important;
  }
}

/* === Галерея шаблонов === */
.gallery-container {
  position: absolute;
  width: 93%;
  height: 120px;
  background-color: #111;
  top: calc(22% + 250px);
  left: 5%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow-x: auto;
  gap: 3px; /* небольшой зазор между элементами */
  padding: 10px 15px;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.5);
  scrollbar-width: thin;
  scrollbar-color: #555 #222;
}

.gallery-container::-webkit-scrollbar {
  height: 8px;
}

.gallery-container::-webkit-scrollbar-track {
  background: #222;
  border-radius: 10px;
}

.gallery-container::-webkit-scrollbar-thumb {
  background: #555;
  border-radius: 10px;
}

.gallery-item {
  flex: 0 0 calc((100% / 9) * 0.95); /* ← Уменьшаем ширину на 5% */
  height: 84px;
  background-color: #222;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease, opacity 0.3s ease;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  position: relative;
  min-width: 80px;
  width: calc((100% / 9) * 0.95); /* Явно задаём */
  margin: 0 2px; /* Добавляем тонкий отступ между элементами */
}



.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s ease;
}
.gallery-item:hover {
  width: calc((100% / 9) * 0.95 * 1.258); /* База * 1.258 */
  box-shadow: 0 8px 20px rgba(255, 255, 255, 0.3);
  z-index: 10;
  opacity: 1;
  filter: brightness(1.1) saturate(1.05);
}
.gallery-container:hover .gallery-item:not(:hover) {
  width: calc((100% / 9) * 0.95 * 0.9677); /* База * 0.9677 */
  opacity: 0.85;
}

/* === Модальное окно === */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  overflow-y: auto;
  padding-top: 50px;
  font-family: 'Arial', sans-serif;
}

.modal-content {
  background-color: #111;
  margin: 0 auto;
  width: 1000px;
  max-width: 95vw;
  border-radius: 12px;
  overflow: hidden;
  color: white;
  position: relative;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8);
}

.close {
  color: #aaa;
  float: right;
  font-size: 36px;
  font-weight: bold;
  position: absolute;
  top: 10px;
  right: 20px;
  cursor: pointer;
  transition: color 0.3s;
}

.close:hover {
  color: white;
}

.modal-title {
  margin: 0;
  padding: 20px 40px;
  font-size: 24px;
  font-weight: 600;
  background-color: #222;
  text-align: center;
  color: #fff;
}

.modal-image {
  display: block;
  width: 100%;
  height: 600px;
  object-fit: cover;
  border-bottom: 1px solid #333;
}

.modal-description {
  margin: 0;
  padding: 20px 40px;
  font-size: 16px;
  line-height: 1.6;
  color: #ddd;
  text-align: left;
}

.btn-want {
  display: block;
  margin: 20px auto;
  padding: 14px 40px;
  font-size: 18px;
  font-weight: 600;
  background-color: #ff3366;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s;
  box-shadow: 0 4px 12px rgba(255, 51, 102, 0.4);
}

.btn-want:hover {
  background-color: #e62e5c;
}
/* === Визуализатор === */
.visualizer {
  position: absolute;
  top: calc(20% + 360px);
  left: 5%;
  width: 90%;
  background: rgba(20, 20, 20, 0.95);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  z-index: 500;
  color: white;
  font-family: Arial, sans-serif;
  display: block;
}

.visualizer.hidden {
  display: none;
}

.visualizer-controls {
  display: flex;
  flex-direction: column;
  height: 800px;
}

.control-row.top-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid #444;
}

.main-content {
  display: flex;
  gap: 20px;
  flex: 1;
  overflow: hidden;
}

.control-column {
  width: 300px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  padding-right: 10px;
}

.visualizer-canvas {
  flex: 1;
  background: #0a0a0a;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.preview-area {
  width: 100%;
  height: 100%;
}

.preview-placeholder {
  color: #666;
  font-size: 18px;
  text-align: center;
  padding: 20px;
}

.total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  margin-top: 20px;
  border-top: 1px solid #444;
  font-size: 20px;
  font-weight: bold;
}

/* Адаптив для планшетов и телефонов */
@media (max-width: 900px) {
  .main-content {
    flex-direction: column;
  }
  .control-column {
    width: 100%;
    max-height: 300px;
  }
  .visualizer {
    top: calc(10% + 280px);
    height: auto;
  }
  .visualizer-controls {
    height: auto;
  }
}
/* === Модальное окно выбора цвета === */
.color-modal {
  display: none;
  position: fixed;
  z-index: 100000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  overflow: auto;
}

.color-modal.hidden {
  display: none;
}

.color-modal-content {
  background-color: #222;
  margin: 40px auto;
  padding: 20px;
  width: 90%;
  max-width: 800px;
  border-radius: 12px;
  position: relative;
  color: white;
}

.color-modal-close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.color-modal-close:hover {
  color: white;
}

.color-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.color-option {
  border-radius: 8px;
  height: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
  color: white;
  font-size: 11px;
  text-align: center;
}

.color-option:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(255,255,255,0.3);
}

.color-option .color-swatch {
  width: 100%;
  height: 60px;
  border-radius: 6px;
  margin-bottom: 4px;
}

/* Стили для выбора цвета */
.control-group.color-picker {
  display: flex;
  align-items: center;
  gap: 10px;
}

.color-preview {
  width: 30px;
  height: 30px;
  border: 2px solid #fff;
  border-radius: 4px;
  cursor: pointer;
}

.btn-color {
  padding: 5px 10px;
  background: #444;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.btn-color:hover {
  background: #555;
}

/* Стили для визуализации */
.visualization-text {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 20px;
  transition: all 0.3s ease;
}

.preview-area {
  width: 100%;
  height: 500px; /* Увеличиваем с 300px */
  background: #000;
  border: 1px solid #444;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
}


/* Для адаптивности */
@media (max-width: 900px) {
  .preview-area {
    height: 400px;
  }
}

/* Эффект неона (для будущего использования) */
.neon-effect {
  text-shadow: 
    0 0 5px currentColor,
    0 0 10px currentColor,
    0 0 20px currentColor,
    0 0 40px currentColor;
}

/* Объемные буквы */
.volumetric-text {
  position: relative;
  color: #fff;
  text-shadow: 
    1px 1px 0 #ccc,
    2px 2px 0 #bbb,
    3px 3px 0 #aaa,
    4px 4px 0 #999;
}
/* === Контентная секция === */
.content-section {
  position: absolute;
  width: 90%;
  top: calc(22% + 390px); /* Под галереей шаблонов */
  left: 5%;
  background: rgba(30, 30, 30, 0.9);
  border-radius: 16px;
  padding: 30px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6);
  z-index: 400;
  color: white;
  font-family: Arial, sans-serif;
}

.content-wrapper {
  max-width: 1200px;
  margin: 0 auto;
}

.content-section h2 {
  font-size: 32px;
  text-align: center;
  margin-bottom: 20px;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.content-text {
  font-size: 18px;
  line-height: 1.6;
  text-align: center;
  margin-bottom: 40px;
  color: #ddd;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  margin-bottom: 40px;
}

.feature-item {
  text-align: center;
  padding: 25px;
  background: rgba(50, 50, 50, 0.6);
  border-radius: 12px;
  transition: transform 0.3s ease, background 0.3s ease;
}

.feature-item:hover {
  transform: translateY(-5px);
  background: rgba(70, 70, 70, 0.8);
}

.feature-icon {
  font-size: 48px;
  margin-bottom: 15px;
}

.feature-item h3 {
  font-size: 20px;
  margin-bottom: 10px;
  color: #fff;
}

.feature-item p {
  font-size: 14px;
  color: #ccc;
  line-height: 1.5;
}

.content-highlight {
  text-align: center;
  padding: 30px;
  background: linear-gradient(135deg, #ff3366, #ff6b35);
  border-radius: 12px;
  margin-top: 20px;
}

.content-highlight h3 {
  font-size: 28px;
  margin-bottom: 15px;
  color: #fff;
}

.content-highlight p {
  font-size: 16px;
  margin-bottom: 20px;
  color: #fff;
  line-height: 1.5;
}
.content-highlight a {
  font-size: 16px;
  margin-bottom: 20px;
  color: #fff;
  line-height: 1.5;
}

.cta-button {
  padding: 15px 30px;
  font-size: 18px;
  font-weight: 600;
  background: #fff;
  color: #ff3366;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.cta-button:hover {
  background: #f0f0f0;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* Адаптивность для контентной секции */
@media (max-width: 768px) {
  .content-section {
    top: calc(22% + 420px);
    padding: 20px;
  }
  
  .content-section h2 {
    font-size: 26px;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .content-text {
    font-size: 16px;
  }
}
/* Текстовый блок */
.text-block {
  margin: 40px 0;
  padding: 30px;
  background: rgba(40, 40, 40, 0.7);
  border-radius: 12px;
  border-left: 4px solid #ff3366;
}

.text-block h2 {
  font-size: 24px;
  color: #fff;
  margin-bottom: 20px;
  text-align: left;
}

.text-block p {
  font-size: 16px;
  line-height: 1.6;
  color: #ddd;
  margin-bottom: 15px;
  text-align: left;
}
.text-block a {
  font-size: 16px;
  line-height: 1.6;
  color: #ffffff;
  margin-bottom: 15px;
  text-align: left;
}
.text-block a:hover {
  font-size: 16px;
  line-height: 1.6;
  color: #ff00CC;
  margin-bottom: 15px;
  text-align: left;
}

.text-block p:last-child {
  margin-bottom: 0;
}

/* Адаптивность для текстового блока */
@media (max-width: 768px) {
  .text-block {
    padding: 20px;
    margin: 30px 0;
  }
  
  .text-block h2 {
    font-size: 20px;
  }
  
  .text-block p {
    font-size: 14px;
  }
}

/* === Секция портфолио внутри контента === */
.portfolio-section {
  margin: 40px 0;
}

.portfolio-section h3 {
  font-size: 24px;
  text-align: center;
  margin-bottom: 20px;
  color: #fff;
}

.portfolio-gallery {
  display: grid;
  grid-template-columns: repeat(6, 1fr); /* 6 колонок */
  grid-template-rows: repeat(3, 1fr); /* 3 ряда */
  gap: 8px;
  height: 300px; /* Высота всей галереи */
  margin-bottom: 20px;
}

.portfolio-item {
  background-color: #222;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.portfolio-item:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2);
  z-index: 10;
}

.portfolio-item:hover img {
  transform: scale(1.1);
}

/* Адаптивность для галереи портфолио */
@media (max-width: 1200px) {
  .portfolio-gallery {
    grid-template-columns: repeat(4, 1fr); /* 4 колонки на планшетах */
    grid-template-rows: repeat(4, 1fr); /* 4 ряда */
    height: 400px;
  }
}

@media (max-width: 768px) {
  .portfolio-gallery {
    grid-template-columns: repeat(3, 1fr); /* 3 колонки на телефонах */
    grid-template-rows: repeat(6, 1fr); /* 6 рядов */
    height: 500px;
  }
  
  .portfolio-section h3 {
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .portfolio-gallery {
    grid-template-columns: repeat(2, 1fr); /* 2 колонки на маленьких телефонах */
    grid-template-rows: repeat(9, 1fr); /* 9 рядов */
    height: 600px;
  }
}
/* Лайтбокс */
.lightbox {
  display: none;
  position: fixed;
  z-index: 100000; /* Увеличиваем z-index */
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95); /* Делаем фон темнее */
  overflow: auto;
}

.lightbox-content {
  position: relative;
  margin: 50px auto;
  width: 1000px;
  max-width: 95vw;
  text-align: center;
  z-index: 100001; /* Еще выше для контента */
}

.lightbox-image {
  width: 1000px;
  height: 600px;
  object-fit: contain;
  border-radius: 8px;
  background: #000; /* Добавляем черный фон для изображения */
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: #fff;
  font-size: 36px;
  font-weight: bold;
  cursor: pointer;
  background: rgba(0, 0, 0, 0.7);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100002; /* Самая высокая для кнопки закрытия */
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  width: 100%;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  z-index: 100002; /* Высокий z-index для навигации */
}

.lightbox-prev,
.lightbox-next {
  color: #fff;
  font-size: 36px;
  font-weight: bold;
  cursor: pointer;
  background: rgba(0, 0, 0, 0.7);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 20px;
  transition: background 0.3s ease;
  z-index: 100003;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lightbox-counter {
  position: absolute;
  bottom: -40px;
  left: 0;
  width: 100%;
  text-align: center;
  color: #fff;
  font-size: 16px;
  z-index: 100002;
}
/* Форма заказа */
.order-form {
  max-width: 500px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  color: #fff;
  font-weight: bold;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #444;
  border-radius: 4px;
  background: #222;
  color: #fff;
  font-size: 14px;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #ff3366;
}

.file-hint {
  font-size: 12px;
  color: #888;
  margin-top: 5px;
}

.submit-btn {
  width: 100%;
  padding: 15px;
  background: #ff3366;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.3s;
}

.submit-btn:hover {
  background: #e62e5c;
}

.submit-btn:disabled {
  background: #666;
  cursor: not-allowed;
}

/* Валидация */
input:invalid {
  border-color: #ff4444;
}

input:valid {
  border-color: #44ff44;
}
.preview-area {
  width: 100%;
  height: 300px;
  background: #000;
  border: 1px solid #444;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
}

.preview-placeholder {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #666;
  font-style: italic;
}

/* Кнопка "Добавить в заказ" */
.add-to-order-btn {
  background: #4CAF50;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  margin-top: 10px;
  transition: background 0.3s;
}

.add-to-order-btn:hover {
  background: #45a049;
}

/* Мини-окно заказа */
.order-mini-window {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 200px;
  height: 30px;
  background: #ffeb3b;
  border: 2px solid #ffc107;
  border-radius: 5px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  z-index: 100000;
}

.order-mini-window:hover {
  background: #ffd54f;
}

.mini-window-title {
  font-size: 14px;
}

/* Уведомление */
.order-notification {
  position: fixed;
  top: 60px;
  right: 20px;
  background: #4CAF50;
  color: white;
  padding: 10px 15px;
  border-radius: 5px;
  z-index: 100001;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

/* Модальное окно заказа */
.order-modal-details {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.order-modal-content {
  background: white;
  border-radius: 12px;
  padding: 30px;
  max-width: 800px;
  max-height: 80vh;
  width: 90%;
  position: relative;
  display: flex;
  flex-direction: column;
}

.order-modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 28px;
  cursor: pointer;
  color: #666;
}

.order-modal-close:hover {
  color: #000;
}

.order-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  border-bottom: 1px solid #f0f0f0;
  transition: background-color 0.2s;
}
.order-item:hover {
  background-color: #f9f9f9;
}

.order-item:last-child {
  border-bottom: none;
}

.order-item-content {
  flex: 1;
}

.order-item-title {
  font-weight: bold;
  color: #333;
  margin-bottom: 5px;
}

.order-item-dimensions {
  color: #666;
  font-size: 14px;
  margin-bottom: 3px;
}

.order-item-cost {
  font-weight: bold;
  color: #ee5a24;
  font-size: 16px;
}

.order-item-remove {
  background: none;
  border: none;
  color: #ff6b6b;
  cursor: pointer;
  padding: 8px;
  border-radius: 4px;
  transition: background-color 0.2s;
}

.order-item-remove:hover {
  background-color: #ffeaea;
}

.order-total-section {
  border-top: 2px solid #eee;
  padding-top: 20px;
  margin-top: 10px;
}

.order-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 18px;
  margin-bottom: 20px;
}

.order-total-price {
  color: #ee5a24;
  font-weight: bold;
  font-size: 20px;
}

.order-submit-btn {
  background: linear-gradient(45deg, #4CAF50, #45a049);
  color: white;
  border: none;
  padding: 15px 30px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  width: 100%;
  transition: all 0.3s ease;
}

.order-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

/* Обновленное мини-окно */
.order-mini-window {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  padding: 15px;
  cursor: pointer;
  z-index: 10000;
  border: 2px solid #ee5a24;
  min-width: 250px;
  transition: all 0.3s ease;
}

.mini-window-title {
  font-weight: bold;
  color: #ee5a24;
  margin-bottom: 8px;
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mini-items-count {
  background: #ee5a24;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.mini-item-preview {
  font-size: 13px;
  color: #333;
  margin-bottom: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mini-total-price {
  font-weight: bold;
  color: #ee5a24;
  font-size: 14px;
  text-align: right;
}
.order-items-list {
  flex: 1;
  overflow-y: auto;
  margin: 20px 0;
  max-height: 400px;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 10px;
}

.order-details {
  margin-top: 20px;
}

.order-row {
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}

.order-row:last-child {
  border-bottom: none;
}

.total-cost {
  font-size: 18px;
  color: #e91e63;
  font-weight: bold;
  margin-top: 15px;
}

/* Стили для формы ввода размеров */
.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  color: #333;
  font-weight: bold;
}

.form-group input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}

.form-group input:focus {
  outline: none;
  border-color: #4CAF50;
}
/* Стили для кнопки "Добавить в заказ" */
.add-to-order-btn {
  background: linear-gradient(45deg, #ff6b6b, #ee5a24);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  margin-top: 15px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(238, 90, 36, 0.3);
}

.add-to-order-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(238, 90, 36, 0.4);
}

.add-to-order-btn:active {
  transform: translateY(0);
}

/* Мини-окно заказа */
.order-mini-window {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: white;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  padding: 15px;
  cursor: pointer;
  z-index: 10000;
  border: 2px solid #ee5a24;
  min-width: 200px;
  transition: all 0.3s ease;
}

.order-mini-window:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.mini-window-title {
  font-weight: bold;
  color: #ee5a24;
  margin-bottom: 8px;
  font-size: 14px;
}

.mini-window-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.mini-item {
  font-size: 13px;
  color: #333;
  flex: 1;
}

.mini-price {
  font-weight: bold;
  color: #ee5a24;
  font-size: 14px;
}

/* Уведомление */
.order-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  background: #4CAF50;
  color: white;
  padding: 15px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
  z-index: 100001;
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}
/* Стили для кнопки создания эскиза */
.screenshot-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    width: 100%;
    justify-content: center;
}

.screenshot-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.screenshot-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Стили для модального окна */
.screenshot-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.screenshot-modal-content {
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 90vw;
    max-height: 90vh;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.screenshot-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
}

.screenshot-modal-close:hover {
    color: #000;
}

.screenshot-image-container {
    max-width: 800px;
    max-height: 600px;
    overflow: auto;
    margin: 16px 0;
    border: 1px solid #eee;
    border-radius: 8px;
}

.screenshot-image {
    display: block;
    max-width: 100%;
    height: auto;
}

.screenshot-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 20px;
}

.screenshot-download-btn,
.screenshot-close-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.screenshot-download-btn {
    background: #4CAF50;
    color: white;
}

.screenshot-download-btn:hover {
    background: #45a049;
}

.screenshot-close-btn {
    background: #f44336;
    color: white;
}

.screenshot-close-btn:hover {
    background: #da190b;
}
.order-item-details {
  margin-top: 8px;
  padding: 8px;
  background: #f8f9fa;
  border-radius: 4px;
  border-left: 3px solid #007bff;
}
.order-item-details small {
  opacity: 0.9;
  line-height: 1.4;
  display: block;
}

.order-item-details strong {
  color: #495057;
}

.order-item-details span[style*="color:"] {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-right: 4px;
  border: 1px solid #ddd;
}

.order-form-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10010 !important;
}

.order-form-content {
  background: white;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.order-form-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 24px;
  cursor: pointer;
  color: #666;
}

.client-contact-form {
  margin-top: 20px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  color: #333;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #007bff;
  outline: none;
}

.validation-error {
  color: #e74c3c;
  font-size: 12px;
  margin-top: 5px;
  display: block;
}

.order-summary-preview {
  background: #f8f9fa;
  padding: 15px;
  border-radius: 5px;
  margin-bottom: 20px;
  border-left: 4px solid #007bff;
}

.preview-item {
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}

.preview-item:last-child {
  border-bottom: none;
}

.preview-total {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 2px solid #ddd;
  text-align: right;
}

.form-protection-info {
  text-align: center;
  margin: 20px 0;
  padding: 10px;
  background: #fff3cd;
  border: 1px solid #ffeaa7;
  border-radius: 5px;
}

.submit-order-btn {
  width: 100%;
  padding: 15px;
  background: #27ae60;
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 18px;
  cursor: pointer;
  transition: background 0.3s;
}

.submit-order-btn:disabled {
  background: #95a5a6;
  cursor: not-allowed;
}

.submit-order-btn:not(:disabled):hover {
  background: #219a52;
}

.success-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10020 !important;
}

.success-content {
  background: white;
  padding: 40px;
  border-radius: 10px;
  text-align: center;
  max-width: 400px;
}

.success-icon {
  font-size: 48px;
  color: #27ae60;
  margin-bottom: 20px;
}

.success-close-btn {
  padding: 10px 30px;
  background: #007bff;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  margin-top: 20px;
}
/* Мобильные стили для модального окна заказа */
@media (max-width: 768px) {
  .order-modal-details {
    z-index: 100002 !important;
    padding: 10px;
  }
  
  .order-modal-content {
    width: 95% !important;
    max-width: 95% !important;
    max-height: 90vh !important;
    margin: 0 auto;
    padding: 20px 15px;
  }
  
  .order-items-list {
    max-height: 50vh !important;
  }
  
  .order-item {
    flex-direction: column;
    align-items: flex-start;
    padding: 10px;
  }
  
  .order-item-content {
    width: 100%;
  }
  
  .order-item-cost {
    margin-left: 0;
    margin-top: 10px;
    align-self: flex-end;
  }
  
  .order-item-remove {
    position: absolute;
    top: 10px;
    right: 10px;
  }
  
  .order-modal-close {
    top: 10px;
    right: 15px;
    font-size: 24px;
    z-index: 100003;
  }
  
  /* Улучшаем читаемость текста */
  .order-item-details small {
    font-size: 12px;
  }
  
  .order-item-title {
    font-size: 14px;
    padding-right: 30px;
  }
}

/* Дополнительные исправления для очень маленьких экранов */
@media (max-width: 480px) {
  .order-modal-content {
    padding: 15px 10px;
  }
  
  .order-item-details {
    padding: 6px;
  }
  
  .order-item-details small {
    font-size: 11px;
  }
  
  .order-total-row {
    font-size: 16px;
  }
  
  .order-submit-btn {
    padding: 12px;
    font-size: 14px;
  }
}
/* Стили для мини-окна заказа */
.order-mini-window {
  position: fixed !important;
  bottom: 20px !important;
  right: 20px !important;
  background: #fff !important;
  border: 2px solid #007bff !important;
  border-radius: 10px !important;
  padding: 15px !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2) !important;
  cursor: pointer !important;
  z-index: 10001 !important;
  min-width: 200px !important;
  font-family: Arial, sans-serif !important;
}

.order-mini-window:hover {
  background: #f8f9fa !important;
}

.mini-window-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mini-window-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.mini-window-title {
  font-weight: bold;
  color: #333;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.mini-items-count {
  background: #ff5722;
  color: white;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
}

.mini-total-price {
  font-weight: bold;
  color: #e91e63;
  font-size: 14px;
  white-space: nowrap;
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
  .order-mini-window {
    bottom: 10px;
    right: 10px;
    left: 10px;
    min-width: auto;
  }
  
  .mini-window-info {
    flex-direction: column;
    gap: 4px;
    text-align: center;
  }
}