/* Ink, rubrication and warm parchment shared by the home and room screens. */
#start-screen {
  --home-ink: #30271e;
  --home-rubric: #8c382d;
  --home-line: #a38a60;
  color: var(--home-ink);
  background: radial-gradient(ellipse at 50% 15%, #fff8e7a6, transparent 70%), #eddbb4 url('parchment20.svg') center / 760px;
}
#start-screen .home-wrap { max-width: 660px; padding: 24px 28px; }
#start-screen .home-head { margin: 0 0 18px; gap: 16px; }
#start-screen .home-wordmark { width: 196px; height: 62px; }
#start-screen .home-head button:last-child { font-size: 13px; border: 1px solid var(--home-line); box-shadow: 0 2px 0 #a38a603d; background: #fff6df66; padding: 8px 12px; min-height: 44px; }
#start-screen .home-kicker { color: #705c40; font-size: 10px; letter-spacing: 2px; margin: 0 0 12px; }
#start-screen h1 { color: var(--home-ink); font-size: clamp(32px, 6vw, 48px); letter-spacing: -1px; margin: 10px 0 18px; }
#start-screen .home-lead { color: #62513c; font-size: 16px; line-height: 1.45; margin-bottom: 20px; }
#start-screen .home-wrap button { -webkit-tap-highlight-color: transparent; }
#start-screen .home-wrap button:focus-visible { outline: 3px solid #264a60; outline-offset: 3px; }
#start-screen .home14-start { gap: 12px; margin: 16px 0; }
#start-screen .home14-start button,
#start-screen .home-resume,
#start-screen .home14-multi,
#start-screen .home14-continue,
#start-screen .home14-extras button,
#start-screen .home14-settings-links button {
  border: 1px solid #8c7450 !important;
  border-radius: 5px 11px 5px 11px;
  background: linear-gradient(100deg, #f9edcf, #efdcad) !important;
  box-shadow: 0 3px 0 #9c8055, inset 0 0 0 3px #fff8e65c;
  color: var(--home-ink);
  min-height: 48px;
  padding: 12px 16px;
  font-size: 15px;
  cursor: pointer;
}
#start-screen .home14-start button:after,
#start-screen .home14-extras button:after { content: none; }
#start-screen .home14-start b { font: 700 23px/1.1 Georgia, serif; }
#start-screen .home14-start small { font: 12px/1.35 system-ui, sans-serif; margin-top: 4px; color: #715d43; }
#start-screen .home14-icon { font-size: 24px; min-width: 30px; color: var(--home-rubric); text-shadow: none; }
#start-screen .home14-start i { font-size: 24px; color: var(--home-rubric); }
#start-screen .home14-start .home14-continue,
#start-screen .home-resume { background: linear-gradient(110deg, #903d31, #743025) !important; color: #fff4d7; border-color: #5c2c23 !important; box-shadow: 0 3px 0 #54271e, inset 0 0 0 3px #ffc77a24; }
#start-screen .home14-continue > span { font: 12px/1.3 system-ui, sans-serif; color: #ffe7b5; background: transparent; border: 0; box-shadow: none; padding: 0; }
#start-screen .home-foot { border-top: 1px solid #9c80558c; color: #6b573e; font-size: 12px; margin-top: 24px; padding-top: 12px; }
#start-screen .home-foot nav { display: flex; justify-content: space-between; gap: 8px; }
#start-screen .home-foot button { color: #655039; font-size: 12px; border: 0; margin: 0; min-height: 44px; padding: 8px 0; }
#start-screen input:not([type=checkbox]), #start-screen select { width: 100%; box-sizing: border-box; min-height: 46px; border: 1px solid #ad9368; border-radius: 5px; background: #fff8e8; color: var(--home-ink); padding: 10px 12px; }
#start-screen input:focus-visible, #start-screen select:focus-visible { outline: 2px solid #8c382d; outline-offset: 2px; }
#start-screen .home-note { color: #705c44; }
#start-screen .home14-back { color: var(--home-rubric); }
#start-screen .online-directory { border-block: 1px solid #a38a6080; padding: 12px 0; }
#start-screen .online-directory h2 { margin: 0 0 12px; font-size: 24px; }
#start-screen .online-directory li { color: #705c44; background: #fff8e744; border-radius: 5px; }
#start-screen .online-room-link { border-radius: 5px 11px 5px 11px; background: #fff3d6; box-shadow: 0 2px #9c8055; }
#start-screen .online-room-link .online-room-join { background: #83372b; color: #fff3d6; border-radius: 4px; }
#start-screen .online-private input { width: 20px; height: 20px; accent-color: #83372b; }

/* The home is a single viewport. Longer forms retain normal scrolling. */
#start-screen[data-screen=home] .home-wrap { min-height: 100svh; max-height: 100svh; display: grid; grid-template-rows: auto auto minmax(110px, 1fr) auto auto auto; gap: 10px; box-sizing: border-box; padding-top: max(16px, env(safe-area-inset-top)); padding-bottom: max(10px, env(safe-area-inset-bottom)); }
#start-screen[data-screen=home] .home-head, #start-screen[data-screen=home] .home-kicker { margin: 0; }
.home21-hero { display: grid; grid-template-columns: minmax(0, 1fr) 34%; grid-template-rows: auto auto; column-gap: 12px; align-items: center; align-content: center; }
#start-screen .home21-hero h1 { grid-column: 1; margin: 0 0 10px; font-size: clamp(32px, 6vw, 46px); }
#start-screen .home21-hero .home-lead { grid-column: 1; max-width: 100%; margin: 0; min-height: 0; font-size: 14px; align-self: start; }
#start-screen .home21-hero .home-art { grid-column: 2; grid-row: 1 / 3; float: none; margin: 0; width: 100%; height: auto; min-height: 0; max-height: none; aspect-ratio: 701 / 748; transform: none; filter: drop-shadow(0 3px 1px #78552b22); }
#start-screen .home21-count { display: block; width: 100%; height: 100%; min-height: 0; aspect-ratio: 701 / 748; border: 0; background: url('comte-poses21.png') no-repeat left center; background-size: 300% 100%; padding: 0; cursor: pointer; border-radius: 8px; }
#start-screen[data-screen=home] .home14-start { margin: 0; gap: 10px; }
#start-screen[data-screen=home] .home14-start button { min-height: 62px; padding: 12px 16px; }
#start-screen[data-screen=home] .home14-start .home14-continue { min-height: 50px; font: 700 18px/1.2 Georgia, serif; }
#start-screen .home21-tools { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; border: 0; padding: 0; margin: 0; }

#start-screen .home21-tools button { margin: 0; padding: 9px 5px; font: 12px/1.25 system-ui, sans-serif; min-height: 44px; text-align: center; }
#start-screen[data-screen=home] .home-foot { margin: 0; padding: 0; }
#start-screen .home14-start:not(:has(.home14-continue)) .home14-solo { background: linear-gradient(110deg, #903d31, #743025) !important; color: #fff4d7 !important; border-color: #5c2c23 !important; }
#start-screen .home14-start:not(:has(.home14-continue)) .home14-solo small,
#start-screen .home14-start:not(:has(.home14-continue)) .home14-solo i,
#start-screen .home14-start:not(:has(.home14-continue)) .home14-solo .home14-icon { color: #ffe7b5; }
@media (max-width: 480px) {
  #start-screen .home-wrap { padding: 16px 18px; }
  #start-screen .home-wordmark { width: 157px; height: 48px; }
  #start-screen .home14-start b { font-size: 21px; }
  #start-screen .home21-hero { grid-template-columns: minmax(0, 1fr) 32%; gap: 8px; }
  #start-screen .home21-hero h1 { font-size: 34px; }
  #start-screen .home21-hero .home-lead { font-size: 13px; }
  #start-screen .home14-extras { gap: 8px; }
}
@media (max-height: 650px) and (max-width: 600px) {
  #start-screen[data-screen=home] .home-wrap { padding: max(8px, env(safe-area-inset-top)) 14px max(6px, env(safe-area-inset-bottom)); gap: 6px; grid-template-rows: auto auto minmax(96px, 1fr) auto auto auto; }
  #start-screen .home-wordmark { height: 44px; width: 145px; }
  #start-screen .home-kicker { font-size: 9px; letter-spacing: 1.6px; }
  #start-screen .home21-hero h1 { font-size: 29px; margin-bottom: 6px; }
  #start-screen .home21-hero .home-lead { font-size: 12px; line-height: 1.3; }
  #start-screen[data-screen=home] .home14-start { gap: 8px; }
  #start-screen[data-screen=home] .home14-start button { min-height: 52px; padding: 8px 12px; }
  #start-screen .home14-start b { font-size: 19px; }
  #start-screen .home14-start small { font-size: 11px; margin-top: 3px; }
  #start-screen[data-screen=home] .home14-start .home14-continue { min-height: 48px; font-size: 16px; }
}
@media (max-height: 470px), (min-resolution: 2dppx) and (max-width: 260px) {
  #start-screen[data-screen=home] .home-wrap { max-height: none; }
}
@media (prefers-reduced-motion: reduce) { #start-screen button:active { transform: none; } }

/* On taller phones the hero keeps its natural size instead of taking all free space. */
@media (min-height: 700px) {
  #start-screen[data-screen=home] { display: grid; align-items: start; }
  #start-screen[data-screen=home] .home-wrap {
    width: 100%;
    margin: 0 auto;
    min-height: 0;
    max-height: none;
    grid-template-rows: auto auto auto auto auto auto;
    gap: 12px;
    padding-top: max(18px, env(safe-area-inset-top));
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }
  #start-screen .home21-hero { min-height: 170px; }
  #start-screen .home21-hero .home-art { min-height: 0; }
}

/* A small drawn icon family and a dedicated reservation entry. */
.home21-icon { width: 28px; height: 28px; display: block; flex: none; }
#start-screen .home-head button:last-child { display: inline-flex; align-items: center; gap: 7px; }
#start-screen .home-head .home21-icon { width: 21px; height: 21px; }
#start-screen .home14-icon { min-width: 34px; }
#start-screen .home14-icon .home21-icon { width: 34px; height: 34px; }
#start-screen .home14-start i .home21-icon { width: 23px; height: 23px; }
#start-screen .home21-tools { grid-template-columns: 1fr 1fr; gap: 10px; }
#start-screen .home21-tools:not(:has(.home-tutorial)) > [onclick="homeSettings14()"] { grid-column: 1 / -1; }
#start-screen .home21-tools button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 9px 12px;
  font-size: 14px;
  text-align: left;
  min-height: 48px;
}
#start-screen .home21-tools .home21-icon { width: 25px; height: 25px; color: #8c382d; }
.home21-tool-text { display: grid; gap: 2px; min-width: 0; }
#start-screen .home21-tool-text b { font: inherit; font-weight: 600; }
#start-screen .home21-tool-text small { font: 11px/1.3 system-ui, sans-serif; color: #786347; }
#start-screen .home21-tools .home21-reserve {
  grid-column: 1 / -1;
  justify-content: flex-start;
  min-height: 58px;
  padding: 10px 16px;
  gap: 13px;
  background: #e8d1a1 !important;
}
#start-screen .home21-reserve .home21-icon { width: 31px; height: 31px; }
#start-screen .home21-reserve b { font: 700 19px/1.15 Georgia, serif; }
#start-screen .home-foot button { display: inline-flex; align-items: center; gap: 5px; }
#start-screen .home-foot .home21-icon { width: 17px; height: 17px; }
@media (max-height: 650px) and (max-width: 600px) {
  #start-screen[data-screen=home] .home-wrap { gap: 5px; padding-top: 6px; padding-bottom: 4px; }
  #start-screen .home21-hero { grid-template-columns: minmax(0, 1fr) 28%; }
  #start-screen .home21-hero h1 { font-size: 26px; margin-bottom: 4px; }
  #start-screen .home21-hero .home-lead { font-size: 11px; line-height: 1.25; }
  #start-screen[data-screen=home] .home14-start { gap: 6px; }
  #start-screen[data-screen=home] .home14-start button { min-height: 44px; padding: 6px 10px; }
  #start-screen .home14-start b { font-size: 17px; }
  #start-screen .home14-start small { font-size: 10px; margin-top: 2px; }
  #start-screen .home14-icon .home21-icon { width: 28px; height: 28px; }
  #start-screen .home21-tools { gap: 6px; }
  #start-screen .home21-tools button { min-height: 44px; padding: 7px 9px; gap: 6px; font-size: 12px; }
  #start-screen .home21-tools .home21-reserve { min-height: 44px; padding: 6px 12px; }
  #start-screen .home21-reserve b { font-size: 16px; }
  #start-screen .home21-reserve small { display: none; }
  #start-screen .home-foot button { font-size: 11px; gap: 3px; }
  #start-screen .home-foot .home21-icon { width: 14px; height: 14px; }
}
