/* GeeSystem — shared styles for the booking form and the admin area. */

@font-face {
  font-family: "Schibsted Grotesk";
  src: url("/fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2");
  font-weight: 400 900; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Schibsted Grotesk";
  src: url("/fonts/schibsted-grotesk-latin-ext-wght-normal.woff2") format("woff2");
  font-weight: 400 900; font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --petrol: #233671;
  --petrol-deep: #182654;
  --petrol-soft: #E3E7F2;
  --mist: #EEF0F5;
  --paper: #FFFFFF;
  --ink: #14252A;
  --slate: #586079;
  --line: #D3D8E6;
  --signal: #F5EF21;
  --signal-ink: #2B2A00;
  --danger: #B3261E;
  --danger-soft: #FBEAE8;
  --ok: #1C7C54;
  --wa: #128C4B;
  --radius: 12px;
  --font: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--mist); color: var(--ink);
  font: 400 17px/1.45 var(--font); -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }
.sprite { position: absolute; }
svg { width: 1.25em; height: 1.25em; flex: none; }
a { color: var(--petrol); }
:focus-visible { outline: 3px solid var(--petrol); outline-offset: 2px; }
.band :focus-visible, .top :focus-visible { outline-color: var(--signal); }

.wrap { width: 100%; max-width: 560px; margin: 0 auto; padding-inline: 20px; }

/* ── Brand ── */
.brand { display: inline-flex; align-items: center; text-decoration: none; color: #fff; }
.brand img { height: 40px; width: auto; display: block; }
.wordmark { display: inline-flex; align-items: center; gap: 9px; font-weight: 750; font-size: 23px; letter-spacing: -0.02em; }
.wordmark svg { width: 26px; height: 26px; color: var(--signal); }

/* ── Booking page header ── */
.logobar { background: #fff; padding: calc(10px + env(safe-area-inset-top)) 0 10px; }
.logobar img { display: block; height: 58px; width: auto; }
.logobar + .band { padding-top: 22px; }
.logobar + .band h1 { margin-top: 0; }
.band { background: var(--petrol); color: #fff; padding: calc(18px + env(safe-area-inset-top)) 0 54px; }
.band h1 { font-size: 30px; line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; margin-top: 26px; max-width: 13em; }

.progress { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 24px 0 0; padding: 0; }
.progress li { font-size: 13px; color: #A3AED3; padding-top: 9px; border-top: 4px solid #3B4D8A; border-radius: 2px; white-space: nowrap; }
.progress li.done { border-color: #8E9BC7; color: #CBD2EA; }
.progress li.now { border-color: var(--signal); color: #fff; font-weight: 600; }

.sheet { background: var(--paper); border-radius: 20px 20px 0 0; margin-top: -30px; padding-top: 26px; padding-bottom: 28px; min-height: 60vh; }

/* ── Form ── */
.step { display: grid; gap: 18px; }
.step h2 { font-size: 20px; letter-spacing: -0.015em; margin-top: 6px; }
.step h2:first-child { margin-top: 0; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }

.field { display: grid; gap: 7px; min-width: 0; }
.label { font-size: 15px; font-weight: 600; color: var(--ink); }
.label i { font-style: normal; font-weight: 400; color: var(--slate); }
.hint { display: block; font-size: 14px; color: var(--slate); }
.small { font-size: 14px; color: var(--slate); }

input, textarea, select {
  font: inherit; color: var(--ink); background: #fff; width: 100%; min-width: 0;
  border: 1.5px solid var(--line); border-radius: var(--radius); padding: 13px 14px; min-height: 54px;
  -webkit-appearance: none; appearance: none;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.4; }
input::placeholder, textarea::placeholder { color: #8A9B9F; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--petrol); box-shadow: 0 0 0 3px rgba(35, 54, 113, .22); }
input[type="date"], input[type="time"] { display: block; text-align: left; }
input::-webkit-date-and-time-value { text-align: left; }
.invalid input, .invalid textarea, input.invalid { border-color: var(--danger); }
.err { color: var(--danger); font-size: 14px; font-weight: 500; }
.err:empty { display: none; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* Quantities */
.counts { border: 1.5px solid var(--line); border-radius: 16px; }
.count { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 12px 12px 16px; }
.count .label, .count .err { display: block; }
.count .err:empty { display: none; }
.count + .count { border-top: 1px solid var(--line); }
.stepper { display: grid; grid-template-columns: 48px 68px 48px; flex: none; }
.stepper button {
  font: 500 24px/1 var(--font); height: 48px; border: 0; border-radius: 50%; cursor: pointer;
  background: var(--petrol-soft); color: var(--petrol); touch-action: manipulation; padding: 0 0 2px;
}
.stepper button:active { background: var(--petrol); color: #fff; }
.stepper input { border: 0; min-height: 48px; padding: 0; text-align: center; font-size: 21px; font-weight: 700; font-variant-numeric: tabular-nums; border-radius: 8px; }
.count.invalid { background: var(--danger-soft); }
.count.invalid:first-child { border-radius: 14px 14px 0 0; }

/* Checks */
.check { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; padding: 4px 0; }
.check input { width: 26px; height: 26px; min-height: 0; padding: 0; border-radius: 7px; flex: none; margin: 0; cursor: pointer; }
.check input:checked { background: var(--petrol) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='M6 12.500l4 4 8-9'/%3E%3C/svg%3E") center/20px no-repeat; border-color: var(--petrol); }
.check.confirm { background: var(--mist); border-radius: var(--radius); padding: 16px; font-weight: 600; margin-top: 4px; }

/* Disclosure blocks */
details summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 9px; font-weight: 600; color: var(--petrol); font-size: 16px; }
details summary::-webkit-details-marker { display: none; }
.repeat { background: var(--mist); border-radius: var(--radius); padding: 14px 16px; }
.repeat-body { display: grid; gap: 12px; margin-top: 14px; }
.repeat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.repeat-list:empty { display: none; }
.repeat-list button { width: 100%; text-align: left; font: inherit; background: #fff; border: 1.5px solid var(--line); border-radius: 10px; padding: 11px 13px; cursor: pointer; color: var(--ink); }
.repeat-list b { display: block; }
.repeat-list span { font-size: 14px; color: var(--slate); }
.more summary::before { content: "+"; font-size: 22px; line-height: 1; width: 20px; }
.more[open] summary::before { content: "−"; }
.more .field { margin-top: 12px; }
.notice { background: #FBF8C4; color: var(--signal-ink); border-radius: var(--radius); padding: 12px 14px; font-size: 15px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px; text-decoration: none; cursor: pointer;
  font: 600 17px/1.2 var(--font); min-height: 54px; padding: 0 22px; border-radius: 999px; border: 1.5px solid transparent;
  touch-action: manipulation; -webkit-tap-highlight-color: transparent;
}
.btn.primary { background: var(--petrol); color: #fff; }
.btn.primary:active { background: var(--petrol-deep); }
.btn.ghost { background: transparent; color: var(--petrol); padding-inline: 14px; }
.btn.quiet { background: #fff; color: var(--petrol); border-color: var(--line); }
.btn.wa { background: var(--wa); color: #fff; }
.btn.danger { background: #fff; color: var(--danger); border-color: #E8BDB9; }
.btn.sm { min-height: 42px; font-size: 15px; padding-inline: 16px; }
.btn[disabled] { opacity: .55; cursor: default; }

.bar {
  position: sticky; bottom: 0; z-index: 5; display: flex; gap: 8px; margin: 26px -20px 0; padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .94); backdrop-filter: blur(8px); border-top: 1px solid var(--line);
}
.bar .primary { flex: 1; }

/* Summary blocks (review, confirmation) */
.sum { border-top: 1px solid var(--line); padding: 16px 0; }
.sum:first-child { border-top: 0; padding-top: 0; }
.sum-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.sum-head h3 { font-size: 15px; font-weight: 600; color: var(--slate); }
.sum-head button { font: 600 15px var(--font); color: var(--petrol); background: none; border: 0; padding: 4px 0 4px 12px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.sum dl { margin: 0; display: grid; grid-template-columns: minmax(0, 6.500em) minmax(0, 1fr); gap: 5px 12px; }
.sum dt { color: var(--slate); font-size: 15px; }
.sum dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; white-space: pre-line; }
.sum .lead { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.kit { display: flex; flex-wrap: wrap; gap: 8px; }
.kit span { background: var(--mist); border-radius: 10px; padding: 8px 12px; font-size: 15px; }
.kit b { font-size: 19px; font-variant-numeric: tabular-nums; margin-right: 5px; }

/* The equipment-case tag shown once a booking is sent */
.tag {
  position: relative; background: var(--signal); color: var(--signal-ink); margin: 6px 0 22px;
  padding: 22px 22px 20px 62px; display: grid; gap: 2px;
  clip-path: polygon(30px 0, 100% 0, 100% 100%, 30px 100%, 0 calc(100% - 30px), 0 30px);
  border-radius: 0 14px 14px 0;
}
.tag-hole { position: absolute; left: 22px; top: 50%; width: 20px; height: 20px; margin-top: -10px; border-radius: 50%; background: var(--paper); box-shadow: inset 0 1px 2px rgba(0, 0, 0, .25); }
.tag-label { font-size: 14px; font-weight: 600; }
.tag-ref { font-size: 36px; line-height: 1.05; font-weight: 800; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.tag-status { font-size: 15px; font-weight: 600; margin-top: 6px; }
.thanks { font-size: 20px; font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; }
.actions { display: grid; gap: 10px; margin: 22px 0 30px; }
#missing { display: grid; gap: 14px; justify-items: start; }

@media (min-width: 620px) {
  body.booking { padding-bottom: 40px; }
  .band h1 { font-size: 38px; }
  .sheet { border-radius: 20px; padding: 34px 34px 0; box-shadow: 0 18px 40px -24px rgba(35, 54, 113, .45); }
  .bar { margin-inline: -34px; padding-inline: 34px; border-radius: 0 0 20px 20px; }
  .actions { grid-template-columns: 1fr 1fr; }
  .actions .wa { grid-column: 1 / -1; }
  #done, #missing { padding-bottom: 34px; }
}
@media (max-width: 359px) {
  .row { grid-template-columns: 1fr; }
  .stepper { grid-template-columns: 44px 56px 44px; }
  .band h1 { font-size: 26px; }
}
@media (prefers-reduced-motion: no-preference) {
  .tag { animation: tag-in .45s cubic-bezier(.2, .9, .3, 1.2) both; transform-origin: 20px 50%; }
  @keyframes tag-in { from { transform: rotate(-7deg) translateY(10px); opacity: 0; } }
}
