/* Лендинг «Тихо». Палитра и раскладка — из прототипа Claude Design (design/prototype/Tiho Landing.dc.html). */

:root {
  --bg: #f4efe7;
  --ink: #1d1a16;
  --ink-hover: #3a3129;
  --text: #4a433c;
  --muted: #6b6259;
  --brown: #7a5a2e;
  --gold: #b58a4e;
  --line: #d9cfc1;
  --field: #fffdf9;
  --soft: #e8e0d3;
  --danger: #a33a2a;
  --font: "Roboto", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }
img { max-width: 100%; display: block; }
h1, p, dl, dd { margin: 0; }

a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--brown); }
:focus-visible { outline: 2px solid var(--brown); outline-offset: 2px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.wordmark {
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}
.wordmark:hover { color: var(--ink); }
.wordmark span { color: var(--gold); }

/* ---------- первый экран ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 11fr) minmax(0, 9fr);
  min-height: 100vh;
  min-height: 100dvh;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  max-width: 680px;
  padding: 24px 56px 48px;
}

.hero-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: auto;
  padding-bottom: 32px;
}

.where { font-size: 14px; color: var(--muted); }

.eyebrow {
  margin-bottom: 20px;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brown);
}

h1 {
  margin-bottom: 20px;
  font-size: clamp(40px, 5vw, 72px);
  line-height: 1.02;
  font-weight: 500;
  letter-spacing: -0.025em;
  text-wrap: balance;
}

.lead {
  max-width: 480px;
  margin-bottom: 32px;
  font-size: clamp(17px, 1.4vw, 20px);
  line-height: 1.5;
  color: var(--text);
  text-wrap: pretty;
}

/* ---------- заявка ---------- */

.signup {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 460px;
  margin-bottom: 24px; /* линия фактов не должна прилипать к примечанию */
}

.signup-form { display: flex; flex-wrap: wrap; gap: 8px; }

.input {
  flex: 1;
  min-width: 200px;
  height: 52px;
  padding: 0 16px;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
  transition: border-color 160ms;
}
.input::placeholder { color: var(--muted); }
.input:focus { border-color: var(--brown); }
.input[aria-invalid="true"] { border-color: var(--danger); }

.button {
  height: 52px;
  padding: 0 24px;
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--bg);
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 8px;
  white-space: nowrap;
  cursor: pointer;
  transition: background 160ms, border-color 160ms;
}
.button:hover { background: var(--ink-hover); border-color: var(--ink-hover); }
.button:disabled { opacity: 0.6; cursor: progress; }

.trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.error { font-size: 14px; color: var(--danger); }

.sent {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--soft);
  font-size: 16px;
  outline: none;
}

.note { font-size: 14px; line-height: 1.5; color: var(--muted); text-wrap: pretty; }
.note a { color: var(--muted); }
.note a:hover { color: var(--brown); }

.facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: auto;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.facts div { display: flex; flex-direction: column; gap: 4px; padding-top: 24px; }
.facts dt { font-size: 20px; font-weight: 500; letter-spacing: -0.01em; }
.facts dd { font-size: 14px; color: var(--muted); }

.hero-photo {
  position: relative;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--soft);
}
.hero-photo img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 40% center;
}

/* ---------- политика и 404 ---------- */

.doc-page { max-width: 720px; margin: 0 auto; padding: 24px 24px 80px; }
.doc-page .hero-header { margin-bottom: 48px; padding-bottom: 0; }
.doc-page h1 { font-size: clamp(32px, 4vw, 44px); margin-bottom: 24px; }
.doc-page h2 { font-size: 22px; font-weight: 500; margin: 32px 0 12px; }
.doc-page p, .doc-page li { line-height: 1.65; color: var(--text); }
.doc-page p + p { margin-top: 12px; }
.doc-page ul { padding-left: 20px; }
.doc-page mark { background: var(--soft); color: var(--ink); padding: 0 4px; border-radius: 3px; }

/* ---------- адаптив ---------- */

/* Телефон: фото — первый экран, шапка и заголовок лежат прямо на нём.
   .hero-copy растворяется (display: contents), чтобы его дети встали в общую сетку с фото. */
@media (max-width: 900px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(120px, 1fr) auto auto;
    min-height: 0;
  }
  .hero-copy { display: contents; }
  .hero-copy > * { margin-inline: 24px; }

  .hero-photo { grid-row: 1 / 5; grid-column: 1; min-height: 72svh; }
  .hero-photo::after {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(20, 16, 12, 0.55) 0%, rgba(20, 16, 12, 0) 22%,
      rgba(20, 16, 12, 0) 45%, rgba(20, 16, 12, 0.82) 100%);
  }
  .hero-photo img { object-position: 30% center; }

  .hero-header, .eyebrow, h1 { grid-column: 1; z-index: 1; }
  .hero-header { grid-row: 1; margin-bottom: 0; padding: 20px 0 0; }
  .eyebrow { grid-row: 3; margin-bottom: 12px; color: #e9d3b0; }
  h1 { grid-row: 4; margin-bottom: 28px; color: #fffaf2; font-size: clamp(36px, 10vw, 56px); }
  .hero-header .wordmark, .hero-header .wordmark:hover { color: #fffaf2; }
  .hero-header .where { color: rgba(255, 250, 242, 0.8); }

  .lead { margin-top: 28px; }
  .facts { margin-top: 8px; margin-bottom: 40px; }
}

@media (max-width: 480px) {
  .button { width: 100%; }
  .facts { gap: 12px; }
  .facts div { padding-top: 16px; }
  .facts dt { font-size: 17px; }
  .facts dd { font-size: 13px; }
}
