/* ==========================================================================
   SECTIONS — PROHRES-SERVIS IF TOV
   warm-craft: тёплая бумага, охра, терракота, скруглённые карточки, крупное фото
   ========================================================================== */

:root {
  --bg: #f3eee4;
  --bg-alt: #e7dccb;
  --bg-deep: #2c261f;
  --ink: #2a231c;
  --ink-soft: #6b5c4e;
  --ink-invert: #f6f1e6;
  --accent: #b5522a;
  --accent-soft: #f3e0d4;
  --line: #dccdbb;
  --brass: #b08948;
  --clay: #8d4330;
  --paper: #f7f3eb;
  --font-display: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --radius: 18px;
  --radius-lg: 28px;
  --tracking-display: -0.03em;
  --shadow: 0 1px 2px color-mix(in srgb, var(--ink) 5%, transparent),
    0 18px 40px color-mix(in srgb, var(--ink) 8%, transparent);
}

/* --- Шапка --- */
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  min-width: 0;
}
.brand img {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex: none;
}
.brand__name {
  display: grid;
  line-height: 1.05;
  min-width: 0;
}
.brand__name strong {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 680;
  letter-spacing: -0.03em;
}
.brand__name span {
  margin-top: 0.15rem;
  font-family: var(--font-body);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.header-phone {
  display: none;
  font-size: var(--step--1);
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
}
@media (min-width: 980px) {
  .header-phone { display: inline; }
}
@media (max-width: 420px) {
  .brand__name span { display: none; }
  .brand__name strong { font-size: 0.86rem; }
}

/* --- Общие блоки --- */
.section-lead {
  max-width: 40rem;
  margin-bottom: clamp(1.8rem, 3vw, 2.8rem);
}
.section-lead h2 { margin-top: 0.35rem; }
.section-lead .lede { margin-top: 0.8rem; }
.section--deep .eyebrow { color: var(--brass); }

/* --- Hero --- */
.hero { padding-top: clamp(2rem, 4vw, 3.5rem); }
.hero__grid {
  display: grid;
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: end;
}
.hero h1 { max-width: 14ch; }
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.hero__facts {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding-top: 0.4rem;
  border-top: 1px solid var(--line);
}
.hero__facts div { min-width: 0; }
.hero__facts dt {
  font-size: var(--step--1);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 650;
}
.hero__facts dd {
  margin: 0.2rem 0 0;
  font-family: var(--font-display);
  font-size: var(--step-0);
}
.hero__figure { margin: 0; }
.hero__figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.hero__figure figcaption {
  margin-top: 0.7rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}
@media (min-width: 768px) {
  .hero__facts { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 980px) {
  .hero__grid { grid-template-columns: 0.86fr 1.14fr; }
  .hero { padding-bottom: clamp(3rem, 5vw, 5rem); }
}

/* --- Узлы --- */
.node-list {
  display: grid;
  gap: var(--gap);
}
.node {
  background: var(--paper);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.3rem 1.5rem;
  box-shadow: var(--shadow);
}
.node__mark {
  font-family: var(--font-display);
  font-size: var(--step-2);
  color: var(--accent);
  line-height: 1;
  margin-bottom: 0.7rem;
}
.node h3 { margin-bottom: 0.55rem; }
.node p:last-child { color: var(--ink-soft); }
@media (min-width: 700px) {
  .node-list { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1100px) {
  .node-list { grid-template-columns: repeat(4, 1fr); }
}

/* --- Услуги --- */
.lane {
  display: grid;
  gap: 0.45rem 1.5rem;
  padding-block: 1.7rem;
  border-top: 1px solid var(--line);
}
.lane:last-child { border-bottom: 1px solid var(--line); }
.lane__num {
  font-family: var(--font-display);
  font-size: var(--step-3);
  line-height: 0.9;
  color: var(--brass);
}
.lane h3 { align-self: center; }
.lane p + p { margin-top: 0.75rem; }
@media (min-width: 860px) {
  .lane {
    grid-template-columns: 4.5rem minmax(12rem, 0.7fr) 1.4fr;
    align-items: start;
  }
  .lane h3 { padding-top: 0.35rem; }
}

/* --- Протокол --- */
.steps {
  list-style: none;
  padding: 0;
  display: grid;
  gap: var(--gap);
}
.step {
  background: var(--paper);
  border-radius: var(--radius-lg);
  padding: 1.3rem 1.25rem 1.45rem;
}
.step h3 { margin-bottom: 0.45rem; }
.step p { color: var(--ink-soft); }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, 1fr); }
}

/* --- О компании --- */
.about-grid {
  display: grid;
  gap: clamp(1.4rem, 3vw, 3rem);
  align-items: center;
}
.about__figure { margin: 0; }
.about__figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  aspect-ratio: 3 / 4;
  object-fit: cover;
}
.about-grid a { color: var(--clay); }
@media (min-width: 860px) {
  .about-grid { grid-template-columns: 0.78fr 1.22fr; }
}

/* --- Галерея --- */
.shots {
  display: grid;
  gap: var(--gap);
}
.shots figure { margin: 0; }
.shots img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: var(--radius-lg);
}
.shots figcaption {
  margin-top: 0.55rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}
@media (min-width: 800px) {
  .shots {
    grid-template-columns: 1.15fr 0.85fr 0.85fr;
  }
  .shots figure:nth-child(1) { grid-column: 1; grid-row: 1 / span 2; }
  .shots figure:nth-child(1) img { height: 100%; min-height: 520px; }
  .shots figure:nth-child(2) { grid-column: 2; grid-row: 1; }
  .shots figure:nth-child(3) { grid-column: 3; grid-row: 1; }
  .shots figure:nth-child(4) { grid-column: 2; grid-row: 2; }
  .shots figure:nth-child(5) { grid-column: 3; grid-row: 2; }
  .shots figure:nth-child(n + 2) img { height: 230px; }
}

/* --- FAQ --- */
.faq {
  display: grid;
  gap: 0.8rem;
}
.faq details {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.15rem 1.05rem;
}
.faq summary { cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { font-size: var(--step-1); }
.faq details p {
  margin-top: 0.7rem;
  color: var(--ink-soft);
}
@media (min-width: 800px) {
  .faq { grid-template-columns: 1fr 1fr; align-items: start; }
}

/* --- Пульт --- */
.terminal-layout {
  display: grid;
  gap: var(--gap);
  align-items: center;
}
.stage {
  height: 420px;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.stage__world {
  width: 280px;
  height: 280px;
  position: relative;
  transform-style: preserve-3d;
  transform: rotateX(56deg) rotateZ(-36deg) scale(1.28);
}
.stage__floor,
.stage__wall,
.piece {
  position: absolute;
}
.stage__floor {
  inset: 0;
  background:
    linear-gradient(var(--line), var(--line)) 0 0 / 100% 1px,
    linear-gradient(90deg, var(--line), var(--line)) 0 0 / 1px 100%,
    var(--paper);
  background-repeat: no-repeat;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px var(--line);
}
.stage__floor::after {
  content: "";
  position: absolute;
  left: 16px;
  bottom: 18px;
  width: 150px;
  height: 78px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--accent) 22%, var(--paper));
}
.stage__wall--back {
  left: 0;
  right: 0;
  top: 0;
  height: 120px;
  background: color-mix(in srgb, var(--paper) 78%, var(--brass));
  transform-origin: top center;
  transform: rotateX(-90deg);
}
.stage__wall--back::after {
  content: "";
  position: absolute;
  left: 36px;
  top: 28px;
  width: 70px;
  height: 48px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--brass) 55%, var(--paper));
  opacity: 0.85;
}
.stage__wall--left {
  left: 0;
  top: 0;
  bottom: 0;
  width: 120px;
  background: color-mix(in srgb, var(--bg-alt) 70%, var(--clay));
  transform-origin: left center;
  transform: rotateY(90deg);
}
.piece {
  border-radius: 6px;
  opacity: 0.42;
  transition: opacity 0.3s var(--ease), background-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.piece--sofa {
  width: 132px;
  height: 52px;
  left: 24px;
  bottom: 28px;
  background: var(--clay);
  transform: translateZ(18px);
}
.piece--desk {
  width: 92px;
  height: 58px;
  left: 22px;
  top: 28px;
  background: var(--brass);
  transform: translateZ(16px);
}
.piece--desk::after {
  content: "";
  position: absolute;
  left: 22px;
  width: 36px;
  height: 28px;
  bottom: 100%;
  background: var(--ink);
  border-radius: 3px;
  transform-origin: bottom center;
  transform: rotateX(-90deg);
}
.piece--cabinet {
  width: 54px;
  height: 54px;
  right: 28px;
  top: 108px;
  background: var(--ink-soft);
  transform: translateZ(36px);
}
.piece--tv {
  width: 86px;
  height: 12px;
  left: 140px;
  top: 22px;
  background: var(--ink);
  transform: translateZ(8px);
}
.piece--tv::after {
  content: "";
  position: absolute;
  left: 6px;
  right: 6px;
  bottom: 100%;
  height: 48px;
  background: var(--ink);
  border-radius: 3px;
  transform-origin: bottom center;
  transform: rotateX(-90deg);
}
.stage__world,
.piece { transform-style: preserve-3d; }
.stage__world[data-decor="on"] .piece--sofa,
.stage__world[data-pc="on"] .piece--desk,
.stage__world[data-appliance="on"] .piece--cabinet,
.stage__world[data-tv="on"] .piece--tv {
  opacity: 1;
  background: var(--accent);
}
.stage__world[data-decor="on"] .piece--sofa { transform: translateZ(28px); }
.stage__world[data-pc="on"] .piece--desk { transform: translateZ(26px); }
.stage__world[data-appliance="on"] .piece--cabinet { transform: translateZ(48px); }
.stage__world[data-tv="on"] .piece--tv { transform: translateZ(18px); }

.tumbler-card,
.tally,
.terminal-card {
  background: var(--paper);
  color: var(--ink);
  border-radius: var(--radius-lg);
  padding: clamp(1rem, 2vw, 1.5rem);
}
.tumbler-card .eyebrow { margin-bottom: 0.4rem; }
.tumblers { display: grid; }
.tumbler {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  text-align: left;
  padding: 0.75rem 0.1rem;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
}
.tumbler:last-child { border-bottom: 0; }
.tumbler__slot {
  width: 36px;
  height: 46px;
  flex: none;
  display: grid;
  place-items: end center;
  background: var(--bg-alt);
  border-radius: 8px;
  border: 1px solid var(--line);
}
.tumbler__lever {
  display: block;
  width: 14px;
  height: 26px;
  margin-bottom: 6px;
  border-radius: 4px 4px 7px 7px;
  background: var(--ink-soft);
  transform: rotate(-26deg);
  transform-origin: bottom center;
  transition: transform 0.22s var(--ease), background-color 0.22s var(--ease);
}
.tumbler[aria-pressed="true"] .tumbler__lever {
  transform: rotate(26deg);
  background: var(--brass);
}
.tumbler[aria-pressed="true"] .tumbler__slot {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.tumbler__text { display: grid; gap: 0.1rem; }
.tumbler__text strong {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 620;
  line-height: 1.2;
}
.tumbler__text small { color: var(--ink-soft); font-size: var(--step--1); }
.tumbler-reset {
  margin-top: 0.4rem;
  font-size: var(--step--1);
  font-weight: 650;
  color: var(--clay);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.tally__label {
  font-size: var(--step--1);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 650;
  color: var(--accent);
}
.tally__sum {
  font-family: var(--font-display);
  font-size: var(--step-4);
  line-height: 1;
  margin: 0.25rem 0 0.8rem;
}
.tally ul {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.4rem;
}
.tally li { color: var(--ink-soft); }
.tally__note {
  margin-top: 0.9rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}

.form-grid {
  display: grid;
  gap: 0.9rem;
}
.terminal-card .field input,
.terminal-card .field textarea {
  background: var(--bg);
}
.form-status { margin-block: 0.8rem; }
@media (min-width: 720px) {
  .form-grid { grid-template-columns: 1fr 1fr; }
  .form-grid__wide { grid-column: 1 / -1; }
}
@media (min-width: 900px) {
  .terminal-layout { grid-template-columns: 1.25fr 0.75fr; }
  .stage { height: 460px; }
}
@media (max-width: 800px) {
  .stage__world { transform: rotateX(56deg) rotateZ(-36deg) scale(1); }
}
@media (max-width: 520px) {
  .stage { height: 300px; }
  .stage__world { transform: rotateX(56deg) rotateZ(-36deg) scale(0.7); }
}

/* --- Подвал --- */
.footer-grid {
  display: grid;
  gap: 1.6rem;
}
.footer-brand {
  display: grid;
  gap: 0.55rem;
  justify-items: start;
}
.footer-brand img { border-radius: 14px; }
.footer-brand__name {
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: 680;
}
.footer-grid address { font-style: normal; }
.footer-grid a { text-decoration: none; }
.footer-grid a:hover { text-decoration: underline; }
.footer-grid nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
}
@media (min-width: 800px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr auto; align-items: start; }
}
