/* metodbaza.ru — собственная стилистика. Шрифт TildaSans для консистентности
   с подстраницами на основе Tilda-сохранёнок. */

:root {
  --bg: #ece5d5;
  --bg-soft: #f3eede;
  --surface: #ffffff;
  --text: #1a1a1a;
  --text-muted: #5e5a52;
  --text-on-dark: #f3eede;

  --accent: #c75d52;          /* терракот — основная CTA */
  --accent-dark: #a8493f;
  --highlight: #f4c93e;       /* жёлтый — для tel-кнопки */
  --border: rgba(28, 27, 24, 0.08);

  --radius-md: 16px;
  --radius-lg: 22px;
  --shadow-sm: 0 4px 14px rgba(28, 27, 24, 0.06);
  --shadow-md: 0 12px 32px rgba(199, 93, 82, 0.22);
  --shadow-lg: 0 22px 48px rgba(199, 93, 82, 0.32);
  --shadow-card: 0 6px 22px rgba(28, 27, 24, 0.06);
  --shadow-card-hover: 0 18px 42px rgba(28, 27, 24, 0.12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: 'TildaSans', -apple-system, 'Segoe UI', Arial, sans-serif;
  font-weight: 400;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'cv11', 'ss03';
}

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

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

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

/* ---------- header ---------- */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px max(24px, calc((100vw - 1120px) / 2));
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-logo { height: 28px; width: auto; }
.brand-name {
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
}

.site-nav {
  display: flex;
  gap: 28px;
  font-size: 16px;
  font-weight: 500;
}
.site-nav a {
  position: relative;
  transition: color 0.15s ease;
}
.site-nav a:hover { color: var(--accent); }

/* ---------- hero ---------- */

.hero {
  padding: 64px 0 96px;
}
.hero-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
}
.hero h1 {
  font-size: clamp(40px, 6vw, 76px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin-bottom: 28px;
}
.lead {
  font-size: clamp(18px, 1.6vw, 22px);
  color: var(--text-muted);
  max-width: 720px;
  margin: 0 auto 40px;
}

/* ---------- buttons ---------- */

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 17px;
  padding: 18px 36px;
  border-radius: 999px;
  box-shadow: var(--shadow-md);
  transition:
    transform 0.2s cubic-bezier(.2, .7, .4, 1.1),
    box-shadow 0.2s ease,
    background 0.18s ease;
  will-change: transform, box-shadow;
}
.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.btn-primary:active {
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.btn-tel {
  display: inline-block;
  background: var(--highlight);
  color: var(--text);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.02em;
  padding: 18px 36px;
  border-radius: 999px;
  box-shadow: 0 10px 28px rgba(244, 201, 62, 0.32);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-tel:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 38px rgba(244, 201, 62, 0.42);
}

/* ---------- subjects ---------- */

.subjects { padding: 64px 0; }
.subjects h2,
.about h2,
.cta h2 {
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 36px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.subject-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
  padding: 28px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.subject-card--available:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}
.subject-card__title {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.subject-card__meta {
  color: var(--text-muted);
  margin-top: 8px;
  font-size: 15px;
}
.subject-card__action {
  margin-top: 24px;
  font-weight: 600;
  font-size: 16px;
  color: var(--accent);
}
.subject-card--soon {
  background: var(--bg-soft);
  color: var(--text-muted);
  cursor: default;
  box-shadow: none;
}
.subject-card--soon .subject-card__action { opacity: 0.5; color: var(--text-muted); }

/* ---------- about (карточки «Что внутри программы») ---------- */

.about {
  padding: 96px 0;
}
.about h2 { text-align: center; margin-bottom: 12px; }
.about__lead {
  text-align: center;
  color: var(--text-muted);
  font-size: 18px;
  max-width: 620px;
  margin: 0 auto 48px;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
}
.feature {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.feature:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}
.feature__icon {
  display: inline-flex;
  width: 56px;
  height: 56px;
  align-items: center;
  justify-content: center;
  background: var(--bg-soft);
  border-radius: 16px;
  font-size: 28px;
  margin-bottom: 20px;
}
.feature h3 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}
.feature p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ---------- cta ---------- */

.cta {
  padding: 96px 0;
  text-align: center;
}
.cta p {
  font-size: 18px;
  color: var(--text-muted);
  margin-bottom: 32px;
}

/* ---------- footer (используется на главной и docs) ---------- */

.site-footer {
  padding: 56px 0 40px;
  background: #1c1b18;
  color: var(--text-on-dark);
  font-size: 14px;
}
.site-footer .container {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: start;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-brand .brand-logo {
  height: 32px;
  filter: brightness(0) invert(1);
}
.footer-brand .brand-name {
  color: var(--text-on-dark);
  font-size: 18px;
  font-weight: 700;
}
.footer-contacts {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}
.footer-tel {
  font-weight: 700;
  font-size: 22px;
  color: var(--highlight);
  letter-spacing: 0.02em;
  transition: opacity 0.15s ease;
}
.footer-tel:hover { opacity: 0.8; }
.footer-contacts a:not(.footer-tel) {
  color: rgba(243, 238, 222, 0.7);
  font-size: 15px;
}
.footer-contacts a:not(.footer-tel):hover { color: var(--text-on-dark); }
.footer-legal {
  text-align: right;
  color: rgba(243, 238, 222, 0.55);
  font-size: 13px;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.footer-legal a {
  color: rgba(243, 238, 222, 0.85);
  border-bottom: 1px solid rgba(243, 238, 222, 0.25);
  transition: color 0.15s ease, border-color 0.15s ease;
}
.footer-legal a:hover {
  color: var(--text-on-dark);
  border-color: var(--text-on-dark);
}

/* ---------- legal-doc (оферта, согласие) ---------- */

.legal-doc {
  max-width: 760px;
  margin: 0 auto;
  padding: 56px 24px 96px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
}
.legal-doc h1 {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}
.legal-meta {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}
.legal-doc h2 {
  font-size: 22px;
  font-weight: 700;
  margin: 40px 0 16px;
  letter-spacing: -0.01em;
}
.legal-doc p {
  margin-bottom: 14px;
  color: var(--text);
}
.legal-doc a {
  color: var(--accent);
  text-decoration: underline;
}
.legal-doc a:hover { color: var(--accent-dark); }

/* ---------- mobile ---------- */

@media (max-width: 720px) {
  .site-header { flex-direction: column; gap: 20px; padding: 20px 24px; }
  .site-nav { gap: 20px; font-size: 15px; }
  .hero { padding: 32px 0 64px; }
  .subjects, .cta { padding: 48px 0; }
  .about { padding: 64px 0; }
  .site-footer .container {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .footer-legal { text-align: left; }
  .legal-doc { padding: 32px 20px 64px; }
}
