/* ===========================
   DRELVORO — Курсы декора мебели
   Основные стили
   =========================== */

/* === Переменные === */
:root {
  --color-bg: #FDF9F5;
  --color-bg-alt: #F5EDE3;
  --color-bg-dark: #2D1B0E;
  --color-primary: #C1624A;
  --color-primary-dark: #A04E3A;
  --color-primary-light: #E8886E;
  --color-accent: #7A8C5E;
  --color-accent-light: #A2B07E;
  --color-text: #2D1B0E;
  --color-text-muted: #7A6558;
  --color-text-light: #BCA898;
  --color-white: #FFFFFF;
  --color-border: #E8D9CC;

  --font-heading: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;

  --shadow-sm: 0 2px 8px rgba(45, 27, 14, 0.08);
  --shadow-md: 0 4px 20px rgba(45, 27, 14, 0.12);
  --shadow-lg: 0 8px 40px rgba(45, 27, 14, 0.16);

  --max-w: 1140px;
  --section-padding: 80px 0;
}

/* === Сброс === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

ul, ol {
  list-style: none;
}

/* === Типографика === */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.2;
  font-weight: 700;
  color: var(--color-text);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.2rem, 3vw, 1.6rem); }
h4 { font-size: 1.15rem; }

p {
  color: var(--color-text-muted);
  line-height: 1.75;
}

/* === Утилиты === */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: var(--section-padding);
}

.section-label {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.section-title {
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.1rem;
  max-width: 580px;
  color: var(--color-text-muted);
}

.text-center {
  text-align: center;
}

.text-center .section-subtitle {
  margin: 0 auto;
}

/* === Кнопки === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 4px 12px rgba(193, 98, 74, 0.35);
}

.btn-primary:hover {
  background: var(--color-primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(193, 98, 74, 0.45);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

.btn-lg {
  padding: 18px 36px;
  font-size: 1rem;
  border-radius: var(--radius-md);
}

/* === Шапка / Навигация === */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--color-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-text);
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text-muted);
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--color-primary);
}

.nav-cta {
  padding: 10px 22px;
  font-size: 0.9rem;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.open span:nth-child(2) {
  opacity: 0;
}
.hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-nav {
  display: none;
  position: absolute;
  top: 68px;
  left: 0;
  right: 0;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  padding: 20px;
  flex-direction: column;
  gap: 16px;
  box-shadow: var(--shadow-md);
}

.mobile-nav.open {
  display: flex;
}

.mobile-nav .nav-link {
  font-size: 1rem;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-border);
}

.mobile-nav .btn {
  margin-top: 8px;
  text-align: center;
}

/* === Герой === */
.hero {
  padding: 60px 0 80px;
  overflow: hidden;
  background: linear-gradient(150deg, var(--color-bg) 55%, var(--color-bg-alt) 100%);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(193, 98, 74, 0.1);
  border: 1px solid rgba(193, 98, 74, 0.2);
  color: var(--color-primary);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.hero-title {
  margin-bottom: 20px;
  color: var(--color-text);
}

.hero-title em {
  font-style: italic;
  color: var(--color-primary);
}

.hero-desc {
  font-size: 1.05rem;
  margin-bottom: 32px;
  max-width: 480px;
}

.hero-form-box {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

.hero-form-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 6px;
}

.hero-form-sub {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-bottom: 24px;
}

.hero-image {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-image-badge {
  position: absolute;
  bottom: 20px;
  left: 20px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  gap: 10px;
}

.badge-icon {
  font-size: 1.4rem;
}

.badge-text {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.3;
}

.badge-text strong {
  display: block;
  font-weight: 700;
  color: var(--color-text);
  font-size: 0.9rem;
}

/* === Форма === */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: 6px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-bg);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  -webkit-appearance: none;
}

.form-group input:focus,
.form-group select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(193, 98, 74, 0.12);
}

.form-group input.error,
.form-group input:invalid:not(:placeholder-shown) {
  border-color: #e05252;
}

.form-error-msg {
  font-size: 0.8rem;
  color: #e05252;
  margin-top: 4px;
  display: none;
}

.form-consent {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  text-align: center;
  line-height: 1.5;
  margin-top: 12px;
}

.form-consent a {
  color: var(--color-primary);
  text-decoration: underline;
}

.btn-submit {
  width: 100%;
  padding: 15px;
  font-size: 1rem;
}

/* === Секция боли === */
.pain-section {
  background: var(--color-bg-dark);
  color: var(--color-white);
  padding: var(--section-padding);
}

.pain-section h2,
.pain-section h3,
.pain-section .section-label {
  color: var(--color-white);
}

.pain-section p {
  color: rgba(255,255,255,0.7);
}

.pain-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 48px;
}

.pain-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-md);
  padding: 28px;
}

.pain-card-icon {
  font-size: 2rem;
  margin-bottom: 14px;
}

.pain-card h4 {
  color: var(--color-white);
  margin-bottom: 8px;
}

.pain-card p {
  font-size: 0.9rem;
  line-height: 1.6;
}

/* === Что вы получите === */
.outcomes-section {
  background: var(--color-bg-alt);
}

.outcomes-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 48px;
}

.outcome-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 24px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.outcome-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: rgba(193, 98, 74, 0.1);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

.outcome-text h4 {
  margin-bottom: 4px;
  font-size: 1rem;
}

.outcome-text p {
  font-size: 0.875rem;
  line-height: 1.55;
}

/* === Как устроен курс === */
.format-section {
  padding: var(--section-padding);
}

.format-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.format-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
  box-shadow: var(--shadow-lg);
}

.format-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.steps-list {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 32px;
}

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

.step-num {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  background: var(--color-primary);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
}

.step-body h4 {
  margin-bottom: 4px;
}

.step-body p {
  font-size: 0.875rem;
}

/* === Витрина работ === */
.showcase-section {
  background: var(--color-bg-alt);
}

.showcase-image {
  margin-top: 48px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  max-height: 480px;
}

.showcase-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.showcase-caption {
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-top: 16px;
  font-style: italic;
}

/* === Для кого === */
.audience-section {
  padding: var(--section-padding);
}

.audience-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 48px;
}

.audience-card {
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--color-border);
  background: var(--color-white);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.audience-card:hover {
  border-color: var(--color-primary-light);
  box-shadow: var(--shadow-md);
}

.audience-card-emoji {
  font-size: 2rem;
  margin-bottom: 14px;
}

.audience-card h4 {
  margin-bottom: 8px;
}

.audience-card p {
  font-size: 0.875rem;
  line-height: 1.6;
}

/* === Главная форма захвата === */
.lead-section {
  background: var(--color-primary);
  padding: var(--section-padding);
}

.lead-section h2 {
  color: var(--color-white);
}

.lead-section p {
  color: var(--color-text-muted);
}

.lead-section .section-label {
  color: rgba(255,255,255,0.7);
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  padding: 4px 12px;
  border-radius: 100px;
}

.lead-form-wrap {
  max-width: 560px;
  margin: 40px auto 0;
}

.lead-form-box {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-lg);
}

.lead-form-box .form-group input {
  background: var(--color-bg);
}

/* === FAQ === */
.faq-section {
  background: var(--color-bg-alt);
}

.faq-list {
  max-width: 720px;
  margin: 48px auto 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-text);
  text-align: left;
  transition: background 0.2s;
}

.faq-question:hover {
  background: var(--color-bg-alt);
}

.faq-chevron {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(193, 98, 74, 0.1);
  color: var(--color-primary);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.2s ease;
  padding: 0 24px;
}

.faq-item.open .faq-answer {
  max-height: 300px;
  padding: 0 24px 20px;
}

.faq-answer p {
  font-size: 0.9rem;
  line-height: 1.7;
}

/* === Подвал === */
.footer {
  background: var(--color-bg-dark);
  color: rgba(255,255,255,0.7);
  padding: 48px 0 32px;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-brand .logo-text {
  color: var(--color-white);
  font-size: 1.4rem;
}

.footer-brand p {
  color: rgba(255,255,255,0.55);
  font-size: 0.875rem;
  margin-top: 12px;
  line-height: 1.6;
}

.footer-col h5 {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-white);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}

.footer-col ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col ul a {
  font-size: 0.875rem;
  color: rgba(255,255,255,0.6);
  transition: color 0.2s;
}

.footer-col ul a:hover {
  color: var(--color-primary-light);
}

.footer-bottom {
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-company {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
  line-height: 1.6;
}

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

.footer-legal a {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.4);
  transition: color 0.2s;
}

.footer-legal a:hover {
  color: rgba(255,255,255,0.7);
}

/* === Cookie-баннер === */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  width: calc(100% - 40px);
  max-width: 680px;
  background: var(--color-bg-dark);
  color: var(--color-white);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  animation: slideUp 0.35s ease;
}

.cookie-banner.hidden {
  display: none;
}

@keyframes slideUp {
  from { transform: translateX(-50%) translateY(20px); opacity: 0; }
  to   { transform: translateX(-50%) translateY(0);   opacity: 1; }
}

.cookie-text {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.55;
  flex: 1;
}

.cookie-text a {
  color: var(--color-primary-light);
  text-decoration: underline;
}

.cookie-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.cookie-accept {
  padding: 9px 20px;
  font-size: 0.875rem;
}

.cookie-close {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255,255,255,0.5);
  font-size: 1.2rem;
  padding: 4px;
  line-height: 1;
  transition: color 0.2s;
}

.cookie-close:hover {
  color: var(--color-white);
}

/* === Страница успеха === */
.success-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--color-bg) 60%, var(--color-bg-alt) 100%);
  padding: 40px 20px;
}

.success-box {
  max-width: 520px;
  width: 100%;
  text-align: center;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 52px 40px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--color-border);
}

.success-icon {
  width: 72px;
  height: 72px;
  background: rgba(122, 140, 94, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 24px;
}

.success-box h1 {
  font-size: 1.75rem;
  margin-bottom: 16px;
  color: var(--color-text);
}

.success-box p {
  color: var(--color-text-muted);
  margin-bottom: 32px;
  line-height: 1.7;
}

/* === Юридические страницы === */
.legal-page {
  min-height: 100vh;
  background: var(--color-bg);
}

.legal-hero {
  background: var(--color-bg-dark);
  color: var(--color-white);
  padding: 48px 0;
}

.legal-hero h1 {
  color: var(--color-white);
  font-size: clamp(1.5rem, 4vw, 2rem);
}

.legal-hero p {
  color: rgba(255,255,255,0.6);
  margin-top: 8px;
  font-size: 0.9rem;
}

.legal-content {
  padding: 60px 0;
  max-width: 760px;
  margin: 0 auto;
}

.legal-content h2 {
  font-size: 1.25rem;
  margin-top: 36px;
  margin-bottom: 12px;
  color: var(--color-text);
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content p {
  font-size: 0.9rem;
  margin-bottom: 12px;
  line-height: 1.75;
}

.legal-content ul {
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 12px;
}

.legal-content ul li {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: 6px;
  line-height: 1.6;
}

/* === Адаптив === */
@media (max-width: 900px) {
  :root {
    --section-padding: 60px 0;
  }

  .hero-inner,
  .format-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-inner .hero-content {
    order: 1;
  }
  .hero-inner .hero-image-col {
    order: 2;
  }

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

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

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

  .footer-top {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .nav {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .header {
    position: relative;
  }

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

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

  .footer-top {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
  }

  .cookie-actions {
    width: 100%;
  }

  .cookie-accept {
    flex: 1;
    text-align: center;
  }

  .hero-form-box {
    padding: 24px 20px;
  }

  .lead-form-box {
    padding: 24px 20px;
  }

  .success-box {
    padding: 36px 24px;
  }
}
