/* ==========================================================================
   STEEL & OAK — стили демо-сайту барбершопу
   ==========================================================================
   ЦВЕТОВАЯ ПАЛИТРА задаётся через CSS-переменные ниже (:root).
   Чтобы поменять фирменные цвета для другого проекта — меняй только их,
   вся вёрстка построена на переменных, hardcoded-цветов в коде нет.
   ========================================================================== */

:root {
  /* --- Основная палитра: графит/чёрный + тёплая медь/золото --- */
  --color-bg: #0e0d0c;              /* основной фон — почти чёрный графит */
  --color-bg-alt: #161412;          /* фон альтернативных секций */
  --color-surface: #1c1a17;         /* карточки, поля форм */
  --color-surface-hover: #242019;   /* карточки при наведении */
  --color-border: #2e2a24;          /* тонкие разделители */

  --color-copper: #c17d43;          /* медный акцент (основной) */
  --color-copper-light: #e0a868;    /* медный светлее — hover/градиенты */
  --color-gold: #d4af37;            /* золото — вторичный акцент */

  --color-text: #f2ede6;            /* основной текст (тёплый белый) */
  --color-text-muted: #a89f93;      /* приглушённый текст */
  --color-text-faint: #6b6459;      /* совсем светлый/декоративный текст */

  --color-success: #6fae7a;
  --color-error: #d4645a;

  /* --- Типографика --- */
  --font-display: 'Bebas Neue', sans-serif;
  --font-body: 'Manrope', sans-serif;

  /* --- Тени / радиусы --- */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 40px rgba(193, 125, 67, 0.15);

  --transition: 0.3s ease;
}

/* ==================== RESET / BASE ==================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input,
select {
  font-family: inherit;
  font-size: 1rem;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.accent {
  color: var(--color-copper);
}

/* ==================== КНОПКИ ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: linear-gradient(135deg, var(--color-copper) 0%, var(--color-gold) 100%);
  color: #171310;
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(193, 125, 67, 0.4);
}

.btn--primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn--large {
  padding: 17px 44px;
  font-size: 1rem;
}

.btn--small {
  padding: 10px 22px;
  font-size: 0.82rem;
}

.btn--full {
  width: 100%;
}

/* ==================== ШАПКА ==================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(14, 13, 12, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), background var(--transition);
}

.header.is-scrolled {
  border-bottom-color: var(--color-border);
  background: rgba(14, 13, 12, 0.96);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.04em;
}

.logo__icon {
  color: var(--color-copper);
  font-size: 1.3rem;
}

.nav {
  display: flex;
  gap: 36px;
}

.nav a {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text-muted);
  position: relative;
  transition: color var(--transition);
}

.nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background: var(--color-copper);
  transition: width var(--transition);
}

.nav a:hover {
  color: var(--color-text);
}

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

.header__right {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* --- Переключатель языка --- */
.lang-switch {
  display: flex;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.lang-switch__btn {
  padding: 7px 13px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-text-muted);
  transition: background var(--transition), color var(--transition);
}

.lang-switch__btn.is-active {
  background: var(--color-copper);
  color: #171310;
}

/* --- Бургер-меню (мобильный) --- */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
}

.burger span {
  width: 24px;
  height: 2px;
  background: var(--color-text);
  transition: transform var(--transition), opacity var(--transition);
}

.burger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.burger.is-open span:nth-child(2) {
  opacity: 0;
}
.burger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ==================== HERO ==================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(193, 125, 67, 0.14) 0%, transparent 45%),
    radial-gradient(circle at 80% 75%, rgba(212, 175, 55, 0.1) 0%, transparent 50%),
    linear-gradient(180deg, var(--color-bg) 0%, #131110 100%);
  z-index: 0;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 48px 48px;
}

.hero__inner {
  position: relative;
  z-index: 1;
  padding-top: 76px;
}

.hero__subtitle {
  color: var(--color-copper-light);
  text-transform: uppercase;
  letter-spacing: 0.35em;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 18px;
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 10vw, 7.5rem);
  line-height: 0.95;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, #f2ede6 30%, var(--color-copper-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 22px;
}

.hero__tagline {
  max-width: 560px;
  margin: 0 auto 40px;
  color: var(--color-text-muted);
  font-size: 1.1rem;
}

.hero__scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: var(--color-text-faint);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  z-index: 1;
}

.hero__scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(180deg, var(--color-copper) 0%, transparent 100%);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ==================== СЕКЦИИ (общее) ==================== */
.section {
  padding: 110px 0;
}

.section--alt {
  background: var(--color-bg-alt);
}

.section__head {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 64px;
}

.section__title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  letter-spacing: 0.02em;
  margin-bottom: 14px;
}

.section__subtitle {
  color: var(--color-text-muted);
  font-size: 1.05rem;
}

/* ==================== УСЛУГИ ==================== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  transition: transform var(--transition), border-color var(--transition), background var(--transition);
}

.service-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-copper);
  background: var(--color-surface-hover);
  box-shadow: var(--shadow-card);
}

.service-card--featured {
  border-color: var(--color-copper);
  background: linear-gradient(160deg, rgba(193, 125, 67, 0.1), var(--color-surface));
}

.service-card__icon {
  font-size: 2rem;
  margin-bottom: 18px;
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.service-card__desc {
  color: var(--color-text-muted);
  font-size: 0.92rem;
  margin-bottom: 22px;
  min-height: 44px;
}

.service-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  border-top: 1px solid var(--color-border);
}

.service-card__price {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--color-copper-light);
  letter-spacing: 0.02em;
}

/* ==================== МАСТЕРА ==================== */
.barbers-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.barber-card {
  text-align: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 36px 22px;
  transition: transform var(--transition), border-color var(--transition);
}

.barber-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-copper);
}

.barber-card__avatar {
  width: 92px;
  height: 92px;
  margin: 0 auto 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.05em;
  color: #171310;
  background: linear-gradient(135deg, var(--color-copper) 0%, var(--color-gold) 100%);
  box-shadow: var(--shadow-glow);
}

.barber-card h3 {
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.barber-card__role {
  color: var(--color-copper-light);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
}

.barber-card__desc {
  color: var(--color-text-muted);
  font-size: 0.88rem;
}

/* ==================== ФОРМА ЗАПИСИ ==================== */
.booking-form {
  max-width: 760px;
  margin: 0 auto;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 44px;
}

.booking-form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-bottom: 8px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-field label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-field input,
.form-field select {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-field input::placeholder {
  color: var(--color-text-faint);
}

.form-field input:focus,
.form-field select:focus {
  outline: none;
  border-color: var(--color-copper);
  box-shadow: 0 0 0 3px rgba(193, 125, 67, 0.15);
}

.form-field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23a89f93' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

/* --- поле с ошибкой валидации --- */
.form-field.has-error input,
.form-field.has-error select {
  border-color: var(--color-error);
}

.field-error {
  color: var(--color-error);
  font-size: 0.78rem;
  margin-top: -2px;
}

.booking-form .btn {
  margin-top: 26px;
}

/* --- сообщения об успехе / ошибке отправки --- */
.form-message {
  margin-top: 22px;
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 600;
  text-align: center;
  animation: fadeSlideIn 0.4s ease;
}

.form-message--success {
  background: rgba(111, 174, 122, 0.12);
  border: 1px solid var(--color-success);
  color: var(--color-success);
}

.form-message--error {
  background: rgba(212, 100, 90, 0.12);
  border: 1px solid var(--color-error);
  color: var(--color-error);
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==================== КОНТАКТЫ / КАРТА ==================== */
.contacts-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
  align-items: stretch;
}

.contacts-info {
  display: flex;
  flex-direction: column;
  gap: 28px;
  justify-content: center;
}

.contact-item {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.contact-item__icon {
  font-size: 1.5rem;
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.contact-item__label {
  color: var(--color-text-faint);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.contact-item__value {
  font-size: 1.02rem;
  font-weight: 600;
}

.map-placeholder {
  min-height: 320px;
  border-radius: var(--radius-lg);
  border: 1px dashed var(--color-border);
  background:
    repeating-linear-gradient(45deg, rgba(193,125,67,0.04) 0, rgba(193,125,67,0.04) 2px, transparent 2px, transparent 14px),
    var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-faint);
  font-size: 0.95rem;
  text-align: center;
  padding: 20px;
}

/* ==================== ФУТЕР ==================== */
.footer {
  background: #0a0908;
  border-top: 1px solid var(--color-border);
  padding-top: 64px;
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer__tagline {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-top: 14px;
  max-width: 280px;
}

.footer__col h4 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-copper-light);
  margin-bottom: 16px;
}

.footer__col p {
  color: var(--color-text-muted);
  font-size: 0.92rem;
  margin-bottom: 8px;
}

.footer__social {
  display: flex;
  gap: 12px;
}

.footer__social a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--color-text-muted);
  transition: border-color var(--transition), color var(--transition);
}

.footer__social a:hover {
  border-color: var(--color-copper);
  color: var(--color-copper-light);
}

.footer__bottom {
  border-top: 1px solid var(--color-border);
  padding: 22px 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1180px;
  margin: 0 auto;
  color: var(--color-text-faint);
  font-size: 0.82rem;
}

/* ==================== АНИМАЦИЯ ПОЯВЛЕНИЯ ПРИ СКРОЛЛЕ ==================== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==================== АДАПТИВНОСТЬ ==================== */

/* --- Планшет: 768px --- */
@media (max-width: 900px) {
  .nav {
    display: none;
  }

  .burger {
    display: flex;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .barbers-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .booking-form__grid {
    grid-template-columns: 1fr;
  }

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

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

  .footer__col:first-child {
    grid-column: 1 / -1;
  }

  /* мобильное выпадающее меню */
  .nav.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    padding: 20px 24px;
    gap: 18px;
  }
}

/* --- Мобильный: 375px --- */
@media (max-width: 480px) {
  .container {
    padding: 0 18px;
  }

  .header__right .btn--small {
    display: none;
  }

  .hero__title {
    font-size: 3.4rem;
  }

  .hero__tagline {
    font-size: 0.98rem;
  }

  .section {
    padding: 72px 0;
  }

  .section__head {
    margin-bottom: 44px;
  }

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

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

  .booking-form {
    padding: 26px 20px;
  }

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

  .footer__col:first-child {
    grid-column: auto;
  }

  .footer__bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* --- Широкий десктоп: 1440px+ --- */
@media (min-width: 1440px) {
  .container {
    max-width: 1320px;
  }

  .hero__tagline {
    max-width: 640px;
  }
}
