:root {
  --ink: #202124;
  --muted: #6f706d;
  --cream: #f7f3ea;
  --paper: #fffdf8;
  --line: #ddd6c8;
  --red: #d94f3d;
  --red-dark: #b43b2d;
  --teal: #227b72;
  --teal-soft: #dceee9;
  --shadow: 0 24px 70px rgba(62, 50, 35, .13);
  --background-illustration: url('/findatime/background-illustration.jpeg');
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background-color: var(--cream);
  background-image:
    linear-gradient(135deg, rgba(247, 243, 234, .92), rgba(225, 239, 234, .84)),
    var(--background-illustration);
  background-position: center;
  background-size: cover;
  background-attachment: fixed;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.site-header {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5vw;
  border-bottom: 1px solid rgba(66, 56, 43, .12);
  background: rgba(247, 243, 234, .9);
}

.brand {
  color: var(--ink);
  text-decoration: none;
  font-family: Georgia, "Noto Serif SC", serif;
  font-size: 1.25rem;
  font-weight: 700;
}

.brand span { color: var(--red); }
.brand-group { display: flex; align-items: center; gap: 12px; min-width: 0; }
.language-switcher-slot { display: inline-flex; align-items: center; }
.language-switcher-slot .language-switcher {
  padding: 3px;
  box-shadow: 0 4px 14px rgba(62, 50, 35, .11);
}
.language-switcher-slot .language-switcher button {
  min-height: 29px;
  padding: .3rem .65rem;
  font-size: .74rem;
}
.header-actions { display: flex; align-items: center; gap: 14px; }
.home-link { color: var(--muted); text-decoration: none; font-size: .92rem; }
.home-link:hover { color: var(--red); }
.admin-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid rgba(217, 79, 61, .35);
  border-radius: 999px;
  color: var(--red);
  background: rgba(217, 79, 61, .07);
  text-decoration: none;
  font-size: .67rem;
  font-weight: 850;
  letter-spacing: .1em;
}
.admin-link:hover { color: #fff; border-color: var(--red); background: var(--red); }

.page-shell {
  width: min(880px, 92vw);
  margin: 52px auto 72px;
}

.card {
  min-height: 660px;
  padding: clamp(28px, 5vw, 62px);
  border: 1px solid rgba(66, 56, 43, .12);
  border-radius: 32px;
  background: rgba(255, 253, 248, .94);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
}

.eyebrow {
  color: var(--red);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
}

h1 {
  margin: 12px 0 10px;
  font: 700 clamp(2.1rem, 5vw, 4.2rem)/1.02 Georgia, "Noto Serif SC", serif;
  letter-spacing: -.035em;
}

.lead { max-width: 620px; margin: 0 0 34px; color: var(--muted); line-height: 1.75; }

.progress {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 34px;
  color: #90897e;
  font-size: .83rem;
}

.progress span { display: inline-flex; align-items: center; gap: 7px; }
.progress b {
  width: 25px; height: 25px;
  display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 50%;
  font-size: .75rem;
}
.progress .active { color: var(--ink); font-weight: 700; }
.progress .active b { color: #fff; border-color: var(--red); background: var(--red); }
.progress i { width: 34px; height: 1px; background: var(--line); }

.field { margin: 0 0 24px; }
.field > label, .field-label { display: block; margin-bottom: 10px; font-weight: 750; }
.hint { display: block; margin-top: 7px; color: var(--muted); font-size: .82rem; }

input[type="text"], input[type="date"], select {
  width: 100%;
  min-height: 52px;
  padding: 0 15px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  outline: none;
}

textarea {
  width: 100%;
  min-height: 112px;
  padding: 13px 15px;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  outline: none;
  line-height: 1.6;
  resize: vertical;
}

input:focus, select:focus, textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(34, 123, 114, .12); }

.duration-control {
  padding: 18px 20px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.duration-display { display: flex; align-items: baseline; justify-content: space-between; }
.duration-value {
  color: var(--teal);
  font: 700 1.6rem/1.2 Georgia, "Noto Serif SC", serif;
}
.duration-range {
  --duration-progress: 6.6667%;
  width: 100%;
  height: 8px;
  margin: 24px 0 14px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(
    to right,
    var(--teal) 0,
    var(--teal) var(--duration-progress),
    #d9d4ca var(--duration-progress),
    #d9d4ca 100%
  );
  appearance: none;
  cursor: grab;
  transition: box-shadow .18s ease;
}
.duration-range:active { cursor: grabbing; }
.duration-range::-webkit-slider-thumb {
  width: 26px;
  height: 26px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 2px 8px rgba(32, 33, 36, .22);
  appearance: none;
  transition: box-shadow .16s ease, transform .16s cubic-bezier(.2, .8, .2, 1);
  will-change: transform;
}
.duration-range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 2px 8px rgba(32, 33, 36, .22);
  transition: box-shadow .16s ease, transform .16s cubic-bezier(.2, .8, .2, 1);
  will-change: transform;
}
.duration-range:active::-webkit-slider-thumb {
  box-shadow: 0 3px 12px rgba(34, 123, 114, .34);
  transform: scale(1.12);
}
.duration-range:active::-moz-range-thumb {
  box-shadow: 0 3px 12px rgba(34, 123, 114, .34);
  transform: scale(1.12);
}
.duration-range:focus { box-shadow: none; }
.duration-range:focus-visible { outline: 3px solid rgba(34, 123, 114, .2); outline-offset: 8px; }
.duration-scale {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: .78rem;
}

@media (prefers-reduced-motion: reduce) {
  .duration-range,
  .duration-range::-webkit-slider-thumb,
  .duration-range::-moz-range-thumb { transition: none; }
}

.actions { display: flex; justify-content: flex-end; align-items: center; gap: 12px; margin-top: 34px; }
.button {
  min-height: 50px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--red);
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(217, 79, 61, .2);
}
.button:hover { background: var(--red-dark); }
.button:disabled { cursor: not-allowed; opacity: .55; }
.button.secondary { color: var(--ink); border: 1px solid var(--line); background: transparent; box-shadow: none; }
.button.secondary:hover { background: #f4efe6; }
.button.small { min-height: 40px; padding: 0 17px; font-size: .86rem; }

.slot-adder { display: grid; grid-template-columns: 1.3fr .8fr auto; gap: 10px; align-items: end; }
.slot-adder .field { margin: 0; }
.slot-count { margin: 22px 0 10px; color: var(--muted); font-size: .85rem; }
.slot-list { display: grid; gap: 9px; }
.slot-row, .vote-slot {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 12px 15px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
.slot-date {
  min-width: 140px;
  color: var(--red);
  font: 700 1rem Georgia, "Noto Serif SC", serif;
  white-space: nowrap;
}
.slot-time { flex: 1; font-weight: 700; }
.slot-remove { width: 34px; height: 34px; border: 0; border-radius: 50%; background: #f5eee8; color: var(--red); }
.empty-state { padding: 24px; border: 1px dashed var(--line); border-radius: 14px; color: var(--muted); text-align: center; }

.summary {
  margin: 28px 0;
  padding: 22px 24px;
  border-left: 4px solid var(--teal);
  border-radius: 0 16px 16px 0;
  background: var(--teal-soft);
  font: 700 1rem/1.6 Georgia, "Noto Serif SC", serif;
}

.summary > div { display: grid; grid-template-columns: max-content 1fr; gap: 6px; }
.summary > div + div { margin-top: 8px; }
.summary dt, .summary dd { margin: 0; }
.summary dt { color: #365f59; }
.summary dd { color: var(--ink); }

.meeting-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.pill { padding: 7px 11px; border-radius: 999px; background: #f1ece3; color: #625d55; font-size: .8rem; }
.vote-list { display: grid; gap: 10px; margin: 14px 0 28px; }
.vote-slot { position: relative; cursor: pointer; align-items: flex-start; }
.vote-slot input { width: 21px; height: 21px; accent-color: var(--teal); }
.vote-slot:has(input:checked) { border-color: var(--teal); background: #f2faf7; }
.vote-slot-main { flex: 1; display: grid; grid-template-columns: minmax(140px, auto) 1fr; gap: 8px; align-items: center; }
.vote-details { min-width: 160px; display: grid; gap: 4px; text-align: right; }
.vote-count { color: var(--teal); font-weight: 800; }
.attendee-names { color: var(--muted); font-size: .78rem; line-height: 1.4; }
.vote-slot-unavailable { border-style: dashed; }
.vote-slot-unavailable:has(input:checked) { border-color: var(--red); background: #fff5f2; }
.vote-slot-unavailable input { accent-color: var(--red); }
.vote-slot-unavailable .vote-count { color: var(--red); }
.unavailable-option-main .slot-date { color: var(--red); }
.unavailable-option-main .slot-time { color: var(--muted); font-size: .82rem; }
.error { min-height: 24px; margin-top: 12px; color: #b03125; font-size: .9rem; }
.loading { padding: 100px 0; text-align: center; color: var(--muted); }

.conversation {
  margin-top: 48px;
  padding-top: 38px;
  border-top: 1px solid var(--line);
}
.conversation-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.conversation-heading h2 {
  margin: 7px 0 0;
  font: 700 clamp(1.65rem, 4vw, 2.35rem)/1.1 Georgia, "Noto Serif SC", serif;
  letter-spacing: -.025em;
}
.conversation-intro { margin: 12px 0 22px; color: var(--muted); line-height: 1.65; }
.comment-gate {
  padding: 15px 17px;
  border: 1px dashed #b8afa1;
  border-radius: 14px;
  color: var(--muted);
  background: rgba(247, 243, 234, .7);
  font-size: .9rem;
}
.comment-composer {
  margin-bottom: 28px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #f8f5ee;
}
.comment-composer > label, .reply-form > label { display: block; margin-bottom: 9px; font-weight: 750; }
.comment-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 12px; }
.comment-author { color: var(--muted); font-size: .82rem; }
.comments-status { padding: 24px 0; color: var(--muted); text-align: center; }
.comments-list { display: grid; gap: 14px; }
.comment {
  padding: 18px 19px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.comment-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.comment-name { color: var(--teal); font-weight: 800; }
.comment-time { color: var(--muted); font-size: .75rem; white-space: nowrap; }
.comment-text { margin: 9px 0 12px; line-height: 1.65; overflow-wrap: anywhere; white-space: pre-wrap; }
.comment-text.withdrawn { color: var(--muted); font-style: italic; }
.comment-controls { display: flex; align-items: center; gap: 14px; }
.reply-toggle {
  padding: 3px 0;
  border: 0;
  color: var(--red);
  background: transparent;
  font-size: .82rem;
  font-weight: 800;
}
.reply-toggle:hover { color: var(--red-dark); }
.withdraw-comment {
  padding: 3px 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: .82rem;
  font-weight: 750;
}
.withdraw-comment:hover:not(:disabled) { color: var(--red-dark); }
.withdraw-comment:disabled { cursor: wait; opacity: .65; }
.reply-form { margin-top: 14px; padding-top: 14px; border-top: 1px solid #eee8dd; }
.reply-form textarea { min-height: 88px; }
.reply-form .comment-actions { justify-content: flex-end; }
.replies { display: grid; gap: 10px; margin: 14px 0 0 18px; padding-left: 14px; border-left: 3px solid var(--teal-soft); }
.reply {
  padding: 14px 15px;
  border-radius: 12px;
  background: #f5faf8;
}
.reply .comment-text { margin-bottom: 0; }
.comments-empty { padding: 24px; border: 1px dashed var(--line); border-radius: 14px; color: var(--muted); text-align: center; }

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(31, 29, 25, .55);
}
.modal {
  width: min(520px, 100%);
  padding: 34px;
  border-radius: 24px;
  background: var(--paper);
  box-shadow: var(--shadow);
}
.modal h2 { margin: 0 0 8px; font: 700 1.8rem Georgia, "Noto Serif SC", serif; }
.modal p { color: var(--muted); line-height: 1.6; }
.copy-row { display: flex; gap: 8px; margin: 22px 0; }
.copy-row input { flex: 1; min-width: 0; }
.hidden { display: none !important; }

@media (max-width: 860px) {
  .page-shell { margin-top: 28px; }
  .card { min-height: auto; }
}

@media (max-width: 560px) {
  .site-header { height: 66px; }
  .brand-group { gap: 8px; }
  .language-switcher-slot .language-switcher button { padding-inline: .52rem; }
  .header-actions { gap: 9px; }
  .home-link { font-size: .76rem; }
  .page-shell { width: min(94vw, 680px); }
  .card { padding: 25px 19px; border-radius: 22px; }
  .duration-control { padding-inline: 15px; }
  .slot-adder { grid-template-columns: 1fr 1fr; }
  .slot-adder .button { grid-column: 1 / -1; }
  .actions { flex-wrap: wrap; }
  .actions .button { flex: 1; }
  .copy-row { flex-direction: column; }
  .summary > div { grid-template-columns: 1fr; gap: 0; }
  .slot-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 4px 12px;
  }
  .slot-row .slot-date { min-width: 0; }
  .slot-row .slot-time { grid-column: 1; }
  .slot-row .slot-remove { grid-column: 2; grid-row: 1 / 3; align-self: center; }
  .vote-slot { flex-wrap: wrap; }
  .vote-slot-main { min-width: calc(100% - 40px); grid-template-columns: 1fr; gap: 4px; }
  .vote-slot-main .slot-date { min-width: 0; }
  .vote-details { width: 100%; padding-left: 35px; text-align: left; }
  .conversation { margin-top: 38px; padding-top: 30px; }
  .comment-actions { align-items: flex-start; flex-direction: column; }
  .comment-actions .button { width: 100%; }
  .comment-header { align-items: flex-start; flex-direction: column; gap: 3px; }
  .comment-time { white-space: normal; }
  .replies { margin-left: 5px; padding-left: 10px; }
}

@media (max-width: 390px) {
  .home-link { display: none; }
}

/* Keep the meeting creation flow inside a single portrait viewport. */
@media (orientation: portrait) {
  body.creator-layout {
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
  }

  body.creator-layout .site-header {
    height: clamp(48px, 7dvh, 60px);
    padding-inline: 4vw;
  }

  body.creator-layout .page-shell {
    width: min(94vw, 680px);
    height: calc(100dvh - clamp(48px, 7dvh, 60px));
    margin: 0 auto;
    padding-block: clamp(6px, 1.4dvh, 14px);
  }

  body.creator-layout #creator-view {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    overflow: hidden;
    padding: clamp(11px, 2.2dvh, 22px) clamp(14px, 4vw, 28px);
    border-radius: clamp(18px, 3vw, 24px);
  }

  body.creator-layout #creator-view > .eyebrow {
    overflow: hidden;
    flex: none;
    font-size: clamp(.63rem, 1.45vh, .75rem);
    letter-spacing: .1em;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  body.creator-layout #creator-view > h1 {
    flex: none;
    margin: clamp(4px, .8dvh, 8px) 0 4px;
    font-size: clamp(1.5rem, min(7vw, 4.8vh), 2.6rem);
    line-height: 1.02;
  }

  body.creator-layout #creator-view > .lead {
    display: -webkit-box;
    overflow: hidden;
    flex: none;
    max-width: none;
    margin: 0 0 clamp(7px, 1.3dvh, 12px);
    font-size: clamp(.73rem, 1.55vh, .86rem);
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  body.creator-layout #creator-view > .progress {
    flex: none;
    gap: 8px;
    margin-bottom: clamp(7px, 1.3dvh, 12px);
    font-size: clamp(.7rem, 1.45vh, .8rem);
  }

  body.creator-layout #creator-view > .progress span { gap: 5px; }
  body.creator-layout #creator-view > .progress b { width: 22px; height: 22px; }
  body.creator-layout #creator-view > .progress i { width: 24px; }

  body.creator-layout #step-one:not(.hidden) {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
  }

  body.creator-layout #step-two:not(.hidden) {
    display: grid;
    min-height: 0;
    flex: 1;
    grid-template-rows: auto auto minmax(0, 1fr) auto auto;
  }

  body.creator-layout #creator-view .field {
    margin-bottom: clamp(6px, 1.2dvh, 12px);
  }

  body.creator-layout #creator-view .field > label,
  body.creator-layout #creator-view .field-label {
    margin-bottom: clamp(4px, .7dvh, 7px);
    font-size: clamp(.76rem, 1.55vh, .9rem);
  }

  body.creator-layout #creator-view input[type="text"],
  body.creator-layout #creator-view input[type="date"],
  body.creator-layout #creator-view select {
    min-height: clamp(38px, 5.8dvh, 46px);
    padding-inline: 12px;
  }

  body.creator-layout #creator-view .duration-control {
    padding: clamp(8px, 1.3dvh, 13px) 14px clamp(7px, 1.1dvh, 11px);
  }

  body.creator-layout #creator-view .duration-value {
    font-size: clamp(1.15rem, 2.7vh, 1.45rem);
  }

  body.creator-layout #creator-view .duration-range {
    height: 7px;
    margin: clamp(9px, 1.7dvh, 15px) 0 clamp(6px, 1dvh, 9px);
  }

  body.creator-layout #creator-view .duration-range::-webkit-slider-thumb {
    width: 22px;
    height: 22px;
  }

  body.creator-layout #creator-view .duration-scale,
  body.creator-layout #creator-view .hint {
    font-size: clamp(.68rem, 1.35vh, .78rem);
    line-height: 1.3;
  }

  body.creator-layout #creator-view .hint { margin-top: 4px; }
  body.creator-layout #creator-view .error {
    min-height: clamp(16px, 2.5dvh, 22px);
    margin-top: 3px;
    font-size: clamp(.72rem, 1.45vh, .86rem);
    line-height: 1.2;
  }

  body.creator-layout #creator-view .actions {
    flex: none;
    margin-top: auto;
    padding-top: clamp(4px, .8dvh, 8px);
  }

  body.creator-layout #creator-view .button {
    min-height: clamp(38px, 5.8dvh, 46px);
    padding-inline: 18px;
    font-size: clamp(.76rem, 1.55vh, .9rem);
  }

  body.creator-layout #creator-view .slot-adder {
    grid-template-columns: minmax(0, 1.2fr) minmax(82px, .75fr) auto;
    gap: 7px;
  }

  body.creator-layout #creator-view .slot-adder .field { margin: 0; }
  body.creator-layout #creator-view .slot-adder .button { grid-column: auto; }
  body.creator-layout #creator-view .slot-count {
    margin: clamp(7px, 1.2dvh, 12px) 0 6px;
    font-size: .76rem;
  }

  body.creator-layout #creator-view .slot-list {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  body.creator-layout #creator-view .slot-row {
    min-height: 48px;
    padding: 7px 10px;
  }

  body.creator-layout #creator-view .empty-state { padding: clamp(10px, 2dvh, 18px); }
  body.creator-layout #step-two .actions { margin-top: 0; }
}

@media (orientation: portrait) and (max-height: 680px) {
  body.creator-layout #creator-view > .lead { display: none; }
  body.creator-layout #creator-view > h1 { font-size: clamp(1.35rem, 6.4vw, 1.8rem); }
  body.creator-layout #creator-view .hint {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

@media (orientation: portrait) and (max-width: 350px) {
  body.creator-layout #creator-view .slot-adder { grid-template-columns: 1fr 1fr; }
  body.creator-layout #creator-view .slot-adder .button { grid-column: 1 / -1; }
}

/* If the regular landscape layout overflows, JS adds this class and the form
   expands sideways into two columns while the meeting result view stays intact. */
body.creator-layout-wide {
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}

body.creator-layout-wide .site-header {
  height: clamp(50px, 8dvh, 64px);
  padding-inline: 3vw;
}

body.creator-layout-wide .page-shell {
  width: min(1280px, 96vw);
  height: calc(100dvh - clamp(50px, 8dvh, 64px));
  margin: 0 auto;
  padding-block: clamp(8px, 1.7dvh, 18px);
}

body.creator-layout-wide #creator-view {
  display: grid;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  grid-template-columns: minmax(150px, .7fr) minmax(0, 1.3fr);
  grid-template-rows: auto auto auto 1fr;
  column-gap: clamp(16px, 4vw, 62px);
  padding: clamp(14px, 3.5dvh, 34px) clamp(18px, 4vw, 48px);
  border-radius: clamp(20px, 3vw, 30px);
}

body.creator-layout-wide #creator-view > .eyebrow { grid-column: 1; grid-row: 1; }
body.creator-layout-wide #creator-view > h1 {
  grid-column: 1;
  grid-row: 2;
  margin: clamp(7px, 1.4dvh, 12px) 0 8px;
  font-size: clamp(1.7rem, min(4vw, 7vh), 3.6rem);
}
body.creator-layout-wide #creator-view > .lead {
  grid-column: 1;
  grid-row: 3;
  margin: 0 0 clamp(12px, 2vh, 24px);
  font-size: clamp(.76rem, 1.7vh, .95rem);
  line-height: 1.5;
}
body.creator-layout-wide #creator-view > .progress {
  grid-column: 1;
  grid-row: 4;
  align-self: start;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
}

body.creator-layout-wide #step-one:not(.hidden) {
  display: grid;
  min-height: 0;
  grid-column: 2;
  grid-row: 1 / -1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: auto auto 1fr auto;
  column-gap: 12px;
}

body.creator-layout-wide #step-one > .field:nth-child(3),
body.creator-layout-wide #step-one > .error,
body.creator-layout-wide #step-one > .actions { grid-column: 1 / -1; }

body.creator-layout-wide #step-two:not(.hidden) {
  display: grid;
  min-height: 0;
  grid-column: 2;
  grid-row: 1 / -1;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
}

body.creator-layout-wide #creator-view .field { margin-bottom: clamp(8px, 1.7dvh, 16px); }
body.creator-layout-wide #creator-view .field > label,
body.creator-layout-wide #creator-view .field-label { margin-bottom: 6px; }
body.creator-layout-wide #creator-view input[type="text"],
body.creator-layout-wide #creator-view input[type="date"],
body.creator-layout-wide #creator-view select { min-height: clamp(40px, 6.4dvh, 50px); }
body.creator-layout-wide #creator-view .duration-control { padding: clamp(10px, 2vh, 16px) 18px; }
body.creator-layout-wide #creator-view .duration-range { margin: clamp(12px, 2.3dvh, 20px) 0 10px; }
body.creator-layout-wide #creator-view .error { min-height: 20px; margin-top: 4px; }
body.creator-layout-wide #creator-view .actions { margin-top: auto; padding-top: 6px; }
body.creator-layout-wide #creator-view .button { min-height: clamp(40px, 6.4dvh, 48px); }
body.creator-layout-wide #creator-view .slot-adder {
  grid-template-columns: minmax(0, 1.25fr) minmax(90px, .75fr) auto;
}
body.creator-layout-wide #creator-view .slot-adder .button { grid-column: auto; }
body.creator-layout-wide #creator-view .slot-count { margin: clamp(8px, 1.6dvh, 16px) 0 7px; }
body.creator-layout-wide #creator-view .slot-list {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}
body.creator-layout-wide #creator-view .slot-row {
  min-height: clamp(48px, 8dvh, 60px);
  padding-block: 8px;
}
body.creator-layout-wide #creator-view .empty-state { padding: clamp(12px, 3dvh, 24px); }
body.creator-layout-wide #step-two .actions { margin-top: 0; }

@media (orientation: landscape) and (max-height: 500px) {
  body.creator-layout-wide #creator-view > .lead { display: none; }
  body.creator-layout-wide #creator-view > h1 { font-size: clamp(1.45rem, 4vw, 2.25rem); }
  body.creator-layout-wide #creator-view > .progress span { font-size: .72rem; }
  body.creator-layout-wide #creator-view .field { margin-bottom: 5px; }
  body.creator-layout-wide #creator-view .field > label,
  body.creator-layout-wide #creator-view .field-label { margin-bottom: 3px; font-size: .75rem; }
  body.creator-layout-wide #creator-view input[type="text"],
  body.creator-layout-wide #creator-view input[type="date"],
  body.creator-layout-wide #creator-view select { min-height: 34px; padding-inline: 10px; }
  body.creator-layout-wide #creator-view .duration-control { padding: 6px 12px 5px; }
  body.creator-layout-wide #creator-view .duration-value { font-size: 1.1rem; }
  body.creator-layout-wide #creator-view .duration-range { margin: 8px 0 5px; }
  body.creator-layout-wide #creator-view .duration-scale { font-size: .68rem; }
  body.creator-layout-wide #creator-view .hint { display: none; }
  body.creator-layout-wide #creator-view .error { min-height: 14px; margin-top: 2px; font-size: .72rem; }
  body.creator-layout-wide #creator-view .actions { padding-top: 4px; }
  body.creator-layout-wide #creator-view .button { min-height: 36px; padding-inline: 14px; font-size: .78rem; }
  body.creator-layout-wide #creator-view .slot-count { margin: 5px 0 4px; }
}
