/* 26.10.2026 (Farid): «Оставить заявку» — the request form (lead-form.js). Was artifacts/drafts-20261026/zayavka-demo.css. */
/* Вторичная кнопка: тот же размер и форма, что у «Выбрать стол», но без заливки */
.spaces-page #main-content .zd-open,
.zd-open {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 26px;
  border: 1px solid rgba(212, 173, 103, .55); border-radius: 999px;
  background: rgb(16 16 14 / 72%); color: #f2eee5;
  font: inherit; font-size: .875rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase;
  cursor: pointer; transition: background .2s, border-color .2s;
  -webkit-tap-highlight-color: transparent;
}
.zd-open:hover { background: rgba(212, 173, 103, .12); border-color: #d4ad67; }
.zd-open:focus-visible { outline: 2px solid #f1d79c; outline-offset: 6px; }
.zd-open svg { width: 18px; height: 18px; flex: none; }
@media (max-width: 760px) { .spaces-page #main-content .zd-open { width: 100%; } }

/* Окно заявки: по центру на компьютере, нижний лист на телефоне */
.zd-dialog {
  width: min(560px, calc(100% - 32px)); max-height: min(860px, calc(100dvh - 48px));
  padding: 0; margin: auto;
  border: 1px solid rgba(212, 173, 103, .35); border-radius: 20px;
  background: #121110; color: #f2eee5; color-scheme: dark;
  font-family: "ALS Granate", "Helvetica Neue", Arial, sans-serif;
  box-shadow: 0 30px 90px rgb(0 0 0 / 60%);
  overflow: hidden;
}
.zd-dialog[open] { display: flex; flex-direction: column; animation: zd-in .22s ease-out; }
.zd-dialog::backdrop { background: rgb(5 5 4 / 82%); backdrop-filter: blur(3px); }
@keyframes zd-in { from { opacity: 0; transform: translateY(14px); } }
@media (max-width: 700px) {
  .zd-dialog { width: 100%; max-width: 100%; max-height: 94dvh; margin: auto 0 0; border-radius: 22px 22px 0 0; border-width: 1px 0 0; }
  @keyframes zd-in { from { transform: translateY(40px); opacity: .4; } }
}
@media (prefers-reduced-motion: reduce) { .zd-dialog[open] { animation: none; } }
body.zd-lock { overflow: hidden; }

.zd-head {
  position: relative; flex: none; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  padding: 22px 18px 14px 24px; border-bottom: 1px solid rgba(212, 173, 103, .18);
}
.zd-grip { display: none; }
@media (max-width: 700px) {
  .zd-head { padding: 22px 12px 12px 20px; }
  .zd-grip { display: block; position: absolute; top: 8px; left: 50%; width: 42px; height: 4px; margin-left: -21px; border-radius: 4px; background: rgba(242, 238, 229, .25); }
}
.zd-eyebrow { margin: 0 0 6px; color: #d4ad67; font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.zd-title { margin: 0; font-size: 1.45rem; font-weight: 500; line-height: 1.2; }
.zd-close {
  flex: none; width: 48px; height: 48px; border: 1px solid rgba(212, 173, 103, .45); border-radius: 50%;
  background: transparent; color: #f2eee5; font-size: 1.6rem; line-height: 1; cursor: pointer;
}
.zd-close:focus-visible, .zd-dialog :is(input, select, textarea, button, a):focus-visible { outline: 2px solid #f1d79c; outline-offset: 3px; }

.zd-body { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 18px 24px 8px; }
@media (max-width: 700px) { .zd-body { padding: 16px 20px 8px; } }
.zd-form { display: contents; }
.zd-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 380px) { .zd-row { grid-template-columns: 1fr; } }
.zd-field { margin: 0 0 16px; min-width: 0; border: 0; padding: 0; }
.zd-label, .zd-field legend { display: block; margin: 0 0 7px; padding: 0; color: #c9c1b4; font-size: .82rem; font-weight: 600; letter-spacing: .02em; }
.zd-label small, .zd-field legend small { color: #8f877a; font-weight: 400; }
.zd-input {
  display: block; width: 100%; min-height: 52px; padding: 12px 14px;
  border: 1px solid rgba(242, 238, 229, .22); border-radius: 12px;
  background: #1b1916; color: #f2eee5;
  font: inherit; font-size: 1rem; /* 16px: iPhone не увеличивает страницу при вводе */
  -webkit-appearance: none; appearance: none;
}
.zd-input::placeholder { color: #7d766b; }
select.zd-input { padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, #d4ad67 50%), linear-gradient(135deg, #d4ad67 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; }
input[type="date"].zd-input { min-height: 52px; }
input[type="date"].zd-input::-webkit-calendar-picker-indicator { filter: invert(78%) sepia(30%) saturate(600%) hue-rotate(358deg); cursor: pointer; }
textarea.zd-input { min-height: 84px; resize: vertical; }
.zd-input:hover { border-color: rgba(212, 173, 103, .5); }
.zd-input:focus { border-color: #d4ad67; outline: none; box-shadow: 0 0 0 3px rgba(212, 173, 103, .18); }
.zd-hint { margin: 6px 0 0; color: #8f877a; font-size: .78rem; line-height: 1.4; }
.zd-error { display: none; margin: 6px 0 0; color: #ff9a8a; font-size: .82rem; line-height: 1.4; }
.zd-field.is-invalid .zd-error { display: block; }
.zd-field.is-invalid :is(.zd-input, .zd-stepper) { border-color: #ff8a78; box-shadow: 0 0 0 3px rgb(255 138 120 / 14%); }
.zd-field.is-invalid .zd-choices label span { border-color: rgb(255 138 120 / 70%); }

/* Гостей: − число + */
.zd-stepper { display: grid; grid-template-columns: 52px 1fr 52px; min-height: 52px; border: 1px solid rgba(242, 238, 229, .22); border-radius: 12px; background: #1b1916; overflow: hidden; }
.zd-stepper button { border: 0; background: transparent; color: #d4ad67; font-size: 1.4rem; cursor: pointer; }
.zd-stepper button:disabled { color: #4b463f; cursor: default; }
.zd-stepper input { width: 100%; min-width: 0; border: 0; border-inline: 1px solid rgba(242, 238, 229, .12); background: transparent; color: #f2eee5; font: inherit; font-size: 1.05rem; text-align: center; -moz-appearance: textfield; }
.zd-stepper input::-webkit-inner-spin-button, .zd-stepper input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.zd-stepper input:focus { outline: none; background: rgba(212, 173, 103, .08); }

/* Где сидеть: крупные плашки */
.zd-choices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.zd-choices label { position: relative; display: block; cursor: pointer; }
.zd-choices input { position: absolute; opacity: 0; inset: 0; margin: 0; }
.zd-choices span { display: flex; flex-direction: column; justify-content: center; min-height: 56px; padding: 8px 12px; border: 1px solid rgba(242, 238, 229, .22); border-radius: 12px; background: #1b1916; font-size: .92rem; line-height: 1.25; }
.zd-choices span small { color: #8f877a; font-size: .74rem; }
.zd-choices input:checked + span { border-color: #d4ad67; background: rgba(212, 173, 103, .14); color: #fff; box-shadow: inset 0 0 0 1px #d4ad67; }
.zd-choices input:focus-visible + span { outline: 2px solid #f1d79c; outline-offset: 2px; }

/* Согласие */
.zd-consent { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; min-height: 48px; padding: 10px 0; color: #c9c1b4; font-size: .84rem; line-height: 1.45; cursor: pointer; }
.zd-consent input { width: 24px; height: 24px; margin: 1px 0 0; accent-color: #d4ad67; cursor: pointer; }
.zd-consent a { color: #d4ad67; text-underline-offset: 3px; }

.zd-foot { flex: none; padding: 14px 24px 18px; border-top: 1px solid rgba(212, 173, 103, .18); background: #121110; }
@media (max-width: 700px) { .zd-foot { padding: 12px 20px max(16px, env(safe-area-inset-bottom)); } }
.zd-submit {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 54px;
  border: 1px solid #d4ad67; border-radius: 999px; background: #d4ad67; color: #080807;
  font: inherit; font-size: .95rem; font-weight: 700; letter-spacing: .03em; cursor: pointer;
}
.zd-submit[aria-busy="true"] { opacity: .75; cursor: progress; }
.zd-note { margin: 9px 0 0; color: #a69d8f; font-size: .8rem; text-align: center; }
.zd-summary-error { display: none; margin: 0 0 10px; color: #ff9a8a; font-size: .84rem; text-align: center; }
.zd-summary-error.is-on { display: block; }

/* Экран «Заявка принята» */
.zd-done { padding: 34px 24px 26px; text-align: center; }
.zd-done[hidden] { display: none; }
.zd-done__mark { display: grid; place-items: center; width: 68px; height: 68px; margin: 0 auto 18px; border: 1px solid #d4ad67; border-radius: 50%; color: #d4ad67; font-size: 2rem; }
.zd-done h3 { margin: 0 0 10px; font-size: 1.5rem; font-weight: 500; line-height: 1.25; }
.zd-done p { margin: 0 auto; max-width: 40ch; color: #c9c1b4; line-height: 1.6; }
.zd-done dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; max-width: 360px; margin: 20px auto; padding: 14px 16px; border: 1px solid rgba(212, 173, 103, .22); border-radius: 12px; text-align: left; font-size: .9rem; }
.zd-done dt { color: #8f877a; }
.zd-done dd { margin: 0; color: #f2eee5; }
.zd-done .zd-submit { max-width: 360px; margin: 6px auto 0; }
.zd-summary-error a { color: inherit; text-underline-offset: 3px; }
