/* «رزرو وقت مشاوره با سینا» — the booking dialog. Markup: tools/book-markup.mjs;
 * behaviour: sinora-book.js. V2: the solid card material, one gold action (send), form
 * fields of §7.6, the founder's photograph at the start side; on a phone, a sheet from the
 * bottom with the photo as a compact header. It is a body child, above every layer. */

.sbk {
  --ink: #f8f6f2; --soft: #dedbd3; --muted: #b9b5ab; --gold: #e6ba5a; --edge: #f5d28a;
  --grad: linear-gradient(115deg, #f7d785, #e6b454 66%, #c38d35);
  position: fixed; inset: 0; z-index: 10070; display: grid; place-items: center; padding: 16px;
  color: var(--ink); text-align: start; -webkit-font-smoothing: antialiased;
}
.sbk[hidden] { display: none; }
.sbk *, .sbk *::before, .sbk *::after { box-sizing: border-box; }
.sbk[lang="fa"] { font-family: IranSans, Tahoma, sans-serif; }
.sbk[lang="tr"] { font-family: Inter, system-ui, sans-serif; }
html.sbk-locked, html.sbk-locked body { overflow: hidden !important; }

.sbk-scrim { position: absolute; inset: 0; background: rgba(5, 5, 4, .66); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.sbk-panel {
  position: relative; width: min(940px, 100%); max-height: calc(100dvh - 32px); display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  border-radius: 28px; background: #111110; border: 1px solid rgba(255, 255, 255, .1); overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 40px 110px rgba(0, 0, 0, .65);
}
.sbk-x {
  position: absolute; top: 14px; inset-inline-end: 14px; z-index: 2; width: 44px; height: 44px; display: grid; place-items: center; padding: 0;
  border-radius: 50%; border: 1px solid rgba(255, 255, 255, .14); background: rgba(17, 17, 16, .72); color: var(--soft); cursor: pointer;
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); transition: color .2s ease, border-color .2s ease, transform .1s ease-out;
}
.sbk-x:hover { color: var(--ink); border-color: rgba(230, 186, 90, .45); }
.sbk-x:active { transform: scale(.94); }
.sbk-x svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* the photograph: warm, close, the name on it */
.sbk-photo { position: relative; margin: 0; min-height: 100%; overflow: hidden; background: #0b0b0a; }
.sbk-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 58% 22%; display: block; }
.sbk-photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(17, 17, 16, 0) 52%, rgba(17, 17, 16, .88) 90%), radial-gradient(90% 60% at 30% 100%, rgba(214, 166, 73, .18), rgba(214, 166, 73, 0));
}
.sbk-photo figcaption { position: absolute; inset-inline: 22px; bottom: 20px; z-index: 1; display: flex; flex-direction: column; gap: 2px; }
.sbk-photo figcaption b { font-size: 17px; font-weight: 700; color: var(--ink); }
.sbk[lang="fa"] .sbk-photo figcaption b { font-family: "w_Ray Extra Black", IranSans, sans-serif; font-weight: 900; word-spacing: .12em; }
.sbk-photo figcaption span { font-size: 12.5px; color: var(--gold); }

/* the form */
.sbk-form { display: flex; flex-direction: column; gap: 14px; padding: 34px 34px 28px; overflow-y: auto; overscroll-behavior: contain; }
.sbk-eyebrow { display: flex; align-items: center; gap: 12px; margin: 0; color: var(--gold); font-size: 13px; font-weight: 700; line-height: 1.6; }
.sbk-eyebrow::after { content: ""; width: 44px; height: 1px; background: var(--gold); opacity: .55; }
.sbk-title { margin: 0; color: var(--ink); font-size: 30px; line-height: 1.35; }
.sbk[lang="fa"] .sbk-title { font-family: "w_Ray Extra Black", IranSans, sans-serif !important; font-weight: 900; word-spacing: .12em; }
.sbk[lang="tr"] .sbk-title { font-family: Inter, system-ui, sans-serif !important; font-weight: 750; letter-spacing: -.03em; line-height: 1.15; font-size: 28px; }
.sbk-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; margin-top: 6px; }
.sbk-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.sbk-field > span { color: var(--muted); font-size: 12.5px; line-height: 1.5; }
.sbk-field :is(input, textarea) {
  width: 100%; margin: 0; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .14); background: #0b0b0a; color: var(--ink);
  font: inherit; font-size: 15px; line-height: 1.6; outline: 0; box-shadow: none; -webkit-appearance: none; appearance: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.sbk-field input { height: 52px; padding: 0 16px; }
.sbk-field textarea { min-height: 128px; padding: 12px 16px; resize: vertical; }
.sbk-field :is(input, textarea)::placeholder { color: #6f6b63; opacity: 1; }
.sbk-field :is(input, textarea):focus { border-color: rgba(230, 186, 90, .6); box-shadow: 0 0 0 4px rgba(230, 186, 90, .1); }
.sbk[lang="fa"] .sbk-field :is(input, textarea) { font-family: IranSans, Tahoma, sans-serif !important; }
.sbk[lang="fa"] .sbk-field input[dir="ltr"] { text-align: right; }
/* the founder's sentence: the reason for the box below it */
.sbk-note {
  margin: 4px 0 0; padding-inline-start: 14px; border-inline-start: 2px solid rgba(230, 186, 90, .7);
  color: var(--soft); font-size: 14px; line-height: 1.85;
}
.sbk[lang="tr"] .sbk-note { line-height: 1.6; }
.sbk-hint { margin: -4px 0 0; color: var(--muted); font-size: 12.5px; line-height: 1.6; }
.sbk-hint[hidden] { display: none; }
.sbk-hint a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.sbk-msg { margin: 0; min-height: 1.4em; color: #9fd8b0; font-size: 13px; line-height: 1.6; }
.sbk-msg:empty { min-height: 0; }
.sbk-send {
  align-self: flex-start; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 26px;
  border-radius: 999px; border: 1px solid var(--edge); background: var(--grad); color: #171309; font: inherit; font-size: 15px; font-weight: 700;
  cursor: pointer; box-shadow: inset 0 1px 1px rgba(255, 233, 175, .4), 0 8px 26px rgba(218, 161, 66, .18); transition: filter .2s ease, transform .1s ease-out;
}
.sbk-send:hover { filter: brightness(1.04); }
.sbk-send:active { transform: scale(.97); }
.sbk-send svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.sbk :is(a, button, input, textarea):focus-visible { outline: 2px solid var(--edge); outline-offset: 3px; }

/* the button that opens it, where a page has no button style of its own for it */
.sbk-open {
  display: inline-flex; align-items: center; gap: 9px; min-height: 48px; padding: 0 22px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .05); color: #f8f6f2; font: inherit; font-size: 14.5px; font-weight: 600;
  cursor: pointer; -webkit-backdrop-filter: blur(16px) saturate(160%); backdrop-filter: blur(16px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16); transition: border-color .2s ease, transform .1s ease-out;
}
.sbk-open:hover { border-color: rgba(230, 186, 90, .5); }
.sbk-open:active { transform: scale(.97); }
.sbk-open svg, [data-sbk-open] > svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* phones: a sheet from the bottom, the photo a compact header */
@media (max-width: 767.98px) {
  .sbk { place-items: end center; padding: 0; }
  .sbk-panel { width: 100%; max-height: 94dvh; grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); border-radius: 24px 24px 0 0; }
  .sbk-photo { min-height: 0; height: 132px; }
  .sbk-photo img { object-position: 55% 18%; }
  .sbk-photo figcaption { bottom: 14px; }
  .sbk-form { padding: 20px 18px calc(22px + env(safe-area-inset-bottom)); gap: 12px; }
  .sbk-title { font-size: 24px; }
  .sbk[lang="tr"] .sbk-title { font-size: 23px; }
  .sbk-grid { grid-template-columns: 1fr; }
  .sbk-send { align-self: stretch; }
}
@media (prefers-reduced-transparency: reduce) {
  .sbk-scrim { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(5, 5, 4, .86); }
}
