:root {
  --ink: #20251f;
  --ink-soft: #667067;
  --forest-950: #111813;
  --forest-900: #19221c;
  --forest-800: #26342b;
  --forest-700: #315f40;
  --forest-600: #3f7650;
  --forest-100: #dfe9df;
  --gold: #d7b268;
  --gold-light: #ecd59f;
  --paper: #f1f2ee;
  --surface: #ffffff;
  --surface-soft: #f7f8f5;
  --line: #dde1d9;
  --danger: #a34f3d;
  --danger-soft: #fff4f1;
  --warning: #9a6816;
  --warning-soft: #f8e9c9;
  --success: #356343;
  --success-soft: #e4f0e5;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 22px 64px rgba(18, 29, 21, .16);
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; }
body { min-height: 100vh; margin: 0; color: var(--ink); background: var(--paper); font-family: var(--font); font-size: 15px; line-height: 1.5; }
button, input, select, textarea { font: inherit; }
button, select { cursor: pointer; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid rgba(215, 178, 104, .55); outline-offset: 2px; }
.icon { width: 19px; height: 19px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }
.eyebrow { margin: 0 0 7px; color: #a97927; font-size: 11px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; }
.muted { color: var(--ink-soft); }

.brand { display: inline-flex; align-items: center; gap: 11px; color: inherit; }
.brand-mark { display: grid; width: 40px; height: 40px; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--gold); color: #232923; font-size: 16px; font-weight: 600; }
.brand-copy { display: grid; line-height: 1.15; }
.brand-copy strong { font-size: 13px; }
.brand-copy small { margin-top: 5px; color: rgba(255,255,255,.48); font-size: 10px; }

.button { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 8px; padding: 9px 15px; border: 1px solid transparent; border-radius: 10px; color: var(--ink); font-weight: 650; line-height: 1.2; transition: border-color .18s, background .18s, color .18s, transform .18s; }
.button:hover:not(:disabled) { transform: translateY(-1px); }
.button:disabled { opacity: .48; cursor: not-allowed; transform: none; }
.button-primary { border-color: var(--gold); background: var(--gold); color: #20261f; }
.button-primary:hover:not(:disabled) { border-color: #e2c17c; background: #e2c17c; }
.button-secondary { border-color: var(--line); background: var(--surface); }
.button-secondary:hover:not(:disabled) { border-color: #bcc5ba; background: #fafbf8; }
.button-ghost { border-color: transparent; background: transparent; color: #4d5950; padding-inline: 3px 11px; }
.button-success { border-color: #b9d1be; background: #eff8f0; color: var(--success); }
.button-danger { border-color: #dfc1ba; background: var(--danger-soft); color: var(--danger); }
.button-danger-ghost { border-color: #dfc1ba; background: transparent; color: var(--danger); }
.button-small { min-height: 33px; padding: 6px 10px; border-radius: 8px; font-size: 11px; }
.button-block { width: 100%; }
.icon-button { display: inline-grid; width: 40px; height: 40px; place-items: center; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); color: #526057; }
.icon-button:hover { border-color: #b8c1b7; color: var(--forest-700); }

.form-field { display: block; min-width: 0; }
.form-field label, .form-field > span { display: block; margin-bottom: 6px; color: #566158; font-size: 12px; font-weight: 600; }
.form-field input, .form-field select, .form-field textarea { width: 100%; min-height: 44px; padding: 9px 11px; border: 1px solid #d5dbd2; border-radius: 9px; color: var(--ink); background: var(--surface); transition: border-color .18s, box-shadow .18s; }
.form-field textarea { resize: vertical; }
.form-field input:hover, .form-field select:hover, .form-field textarea:hover { border-color: #bbc5ba; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus { border-color: var(--forest-600); outline: 0; box-shadow: 0 0 0 3px rgba(63,118,80,.12); }
.form-field input[readonly] { background: var(--surface-soft); color: var(--ink-soft); }
.field-help, .field-error { display: block; margin-top: 6px; color: #7b847b; font-size: 11px; }
.field-error { color: var(--danger); }
.form-grid, .public-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.full-field { grid-column: 1 / -1; }
.form-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 22px; }
.check-field { display: flex; align-items: flex-start; gap: 9px; margin-top: 17px; color: #59635a; font-size: 12px; cursor: pointer; }
.check-field input { width: 16px; height: 16px; margin: 1px 0 0; accent-color: var(--forest-700); }
.inline-message { margin: 14px 0 0; padding: 10px 12px; border-radius: 8px; background: var(--danger-soft); color: var(--danger); font-size: 12px; }
.inline-message.is-success { background: var(--success-soft); color: var(--success); }
.alert { display: flex; align-items: flex-start; gap: 9px; margin-bottom: 18px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-size: 13px; }
.alert p { margin: 0; }
.alert-error, .alert-danger { border-color: #eccdc6; background: var(--danger-soft); color: var(--danger); }
.alert-success { border-color: #c6ddca; background: var(--success-soft); color: var(--success); }
.notice { display: flex; align-items: flex-start; gap: 10px; padding: 13px 14px; border-radius: 10px; background: #f5f2e9; color: #6d624a; font-size: 12px; }
.notice p { margin: 0; }
.notice.compact { margin: 18px 0; }
.toast-stack { position: fixed; z-index: 1000; right: 20px; bottom: 20px; display: grid; width: min(360px, calc(100vw - 40px)); gap: 9px; }
.toast { display: flex; align-items: center; gap: 10px; padding: 13px 15px; border-radius: 10px; background: var(--forest-900); color: #f3f5f1; box-shadow: 0 12px 35px rgba(0,0,0,.24); font-size: 13px; animation: toast-in .2s ease-out; }
.toast.is-error { background: #702f26; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

/* Public booking */
.public-body { background: var(--forest-900); }
.public-page { min-height: 100vh; padding: 24px clamp(20px, 5vw, 72px) 48px; color: #fff; background: linear-gradient(90deg, rgba(20,28,23,.98) 0 40%, rgba(20,28,23,.7) 58%, rgba(20,28,23,.16) 100%), radial-gradient(circle at 88% 25%, rgba(233,204,137,.95) 0 10%, transparent 10.5%), linear-gradient(137deg, #3c4940 0 53%, #c8b27e 53% 100%); overflow: hidden; }
.public-nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; max-width: 1420px; margin: 0 auto clamp(46px, 8vh, 92px); }
.public-phone { padding: 10px 16px; border: 1px solid rgba(255,255,255,.32); border-radius: 999px; font-weight: 600; transition: background .18s; }
.public-phone:hover { background: rgba(255,255,255,.1); }
.public-grid { display: grid; max-width: 1420px; margin: 0 auto; grid-template-columns: minmax(280px, .82fr) minmax(540px, 1.18fr); gap: clamp(40px, 7vw, 108px); align-items: center; }
.public-copy .eyebrow { margin-bottom: 18px; color: var(--gold-light); font-size: 13px; }
.public-copy h1 { max-width: 650px; margin: 0 0 24px; font-size: clamp(48px, 5.7vw, 86px); font-weight: 540; letter-spacing: -.052em; line-height: .96; }
.public-copy > p:not(.eyebrow) { max-width: 520px; margin: 0 0 34px; color: rgba(255,255,255,.76); font-size: clamp(16px, 1.4vw, 19px); line-height: 1.65; }
.public-facts { display: flex; flex-wrap: wrap; gap: 16px 26px; }
.public-fact { display: flex; align-items: center; gap: 10px; min-width: 115px; }
.public-fact > .icon { width: 22px; height: 22px; color: var(--gold-light); }
.public-fact strong { display: block; font-size: 23px; line-height: 1.1; }
.public-fact span { color: rgba(255,255,255,.56); font-size: 11px; }
.booking-panel { min-height: 558px; padding: clamp(20px, 2.5vw, 30px); border-radius: var(--radius-lg); background: var(--surface); color: var(--ink); box-shadow: 0 28px 78px rgba(0,0,0,.29); }
.booking-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.booking-head h2 { margin: 0 0 5px; font-size: 25px; font-weight: 570; letter-spacing: -.025em; }
.booking-head p { max-width: 310px; margin: 0; color: #727b72; font-size: 12px; }
.booking-price { color: var(--success); font-size: 13px; font-weight: 700; white-space: nowrap; }
.booking-progress { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 25px; }
.booking-progress span { padding-top: 8px; border-top: 2px solid #e0e4dd; color: #8b918a; font-size: 11px; }
.booking-progress span b { display: inline-grid; width: 18px; height: 18px; place-items: center; margin-right: 2px; border-radius: 50%; background: #eef0ec; font-size: 9px; }
.booking-progress span.is-active, .booking-progress span.is-done { border-color: var(--forest-600); color: var(--success); }
.booking-progress span.is-active b, .booking-progress span.is-done b { background: var(--forest-700); color: #fff; }
.field-label { display: block; color: #657066; font-size: 12px; }
.calendar-control { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 9px; }
.calendar-control > div { flex: 1; }
.calendar-control .field-label { margin-bottom: 1px; }
.calendar-control small { color: #8a9189; font-size: 10px; }
.date-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 20px; }
.date-choice, .time-choice, .duration-choice { min-height: 45px; padding: 7px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); transition: border-color .15s, background .15s, color .15s, transform .15s; }
.date-choice:hover:not(:disabled), .time-choice:hover:not(:disabled), .duration-choice:hover:not(:disabled) { border-color: #91a594; transform: translateY(-1px); }
.date-choice strong { display: block; font-size: 13px; font-weight: 650; }
.date-choice small { color: #7e867d; font-size: 10px; }
.date-choice.is-selected, .time-choice.is-selected, .duration-choice.is-selected { border-color: var(--forest-700); background: var(--forest-700); color: #fff; }
.date-choice.is-selected small { color: rgba(255,255,255,.72); }
.time-choice:disabled, .duration-choice:disabled { border-color: transparent; background: #edf0eb; color: #aeb4ad; text-decoration: line-through; cursor: not-allowed; }
.slot-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.slot-note { display: inline-flex; align-items: center; gap: 5px; color: #929991; font-size: 10px; }
.slot-note i { width: 7px; height: 7px; border-radius: 50%; background: #ccd2cb; }
.time-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 7px; min-height: 97px; margin-bottom: 18px; }
.duration-grid { display: flex; flex-wrap: wrap; gap: 8px; min-height: 45px; margin-top: 8px; }
.duration-choice { min-width: 76px; }
.booking-summary { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 21px; padding-top: 19px; border-top: 1px solid #e2e5df; }
.booking-summary strong { display: block; font-size: 14px; }
.booking-summary span { display: block; margin-top: 3px; color: #747d74; font-size: 11px; }
.step-title { margin: 0 0 19px; font-size: 19px; font-weight: 600; }
.review-list { margin: 0 0 18px; }
.review-row { display: flex; justify-content: space-between; gap: 20px; padding: 12px 0; border-bottom: 1px solid #e3e6df; font-size: 13px; }
.review-row span { color: #737d74; }
.review-row strong { max-width: 60%; text-align: right; }
.success-state { display: grid; min-height: 380px; place-content: center; justify-items: center; text-align: center; }
.success-icon { display: grid; width: 64px; height: 64px; place-items: center; margin-bottom: 18px; border-radius: 50%; background: var(--success-soft); color: var(--success); }
.success-icon .icon { width: 28px; height: 28px; }
.success-state .eyebrow { margin-bottom: 9px; color: var(--success); }
.success-state h3 { max-width: 400px; margin: 0 0 9px; font-size: 24px; }
.success-state p { max-width: 420px; margin: 0 0 22px; color: #6c756c; }
.skeleton-grid { position: relative; border-radius: 10px; background: repeating-linear-gradient(90deg, #f0f2ef 0 14%, #f8f9f7 14% 17%); animation: skeleton 1.25s ease-in-out infinite alternate; }
@keyframes skeleton { to { opacity: .55; } }

/* Authentication */
.auth-body { background: var(--paper); }
.auth-page { display: grid; min-height: 100vh; grid-template-columns: minmax(360px, 1fr) minmax(420px, 1fr); }
.auth-visual { display: flex; flex-direction: column; justify-content: space-between; padding: clamp(30px, 5vw, 68px); color: #fff; background: linear-gradient(145deg, rgba(20,29,23,.97), rgba(48,67,54,.93) 62%, rgba(184,151,84,.82)), linear-gradient(130deg, #1b261e, #ad9157); }
.auth-visual h1 { max-width: 650px; margin: 14px 0 22px; font-size: clamp(44px, 5vw, 74px); font-weight: 520; letter-spacing: -.05em; line-height: .97; }
.auth-visual > div > p:last-child { max-width: 520px; margin: 0; color: rgba(255,255,255,.68); font-size: 16px; line-height: 1.65; }
.auth-visual small { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,.52); }
.auth-form-wrap { display: grid; place-items: center; padding: 32px; }
.auth-form { width: min(390px, 100%); }
.auth-icon { display: grid; width: 48px; height: 48px; place-items: center; margin-bottom: 20px; border-radius: 12px; background: #e7eee7; color: var(--success); }
.auth-icon .icon { width: 23px; height: 23px; }
.auth-form h2 { margin: 0 0 7px; font-size: 31px; letter-spacing: -.025em; }
.auth-form > p { margin: 0 0 28px; color: #727b72; }
.auth-form .form-field { margin-bottom: 16px; }
.password-field { position: relative; }
.password-field input { padding-right: 48px; }
.password-field .icon-button { position: absolute; top: 2px; right: 2px; width: 40px; height: 40px; border: 0; background: transparent; }
.auth-form .button-block { margin-top: 8px; }
.back-link { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 22px; color: #667168; font-size: 12px; }
.back-link:hover { color: var(--forest-700); }

/* Admin shell */
.admin-body { background: #eef0eb; }
.admin-shell { display: grid; min-height: 100vh; grid-template-columns: 232px minmax(0, 1fr); }
.admin-sidebar { position: sticky; top: 0; display: flex; height: 100vh; flex-direction: column; padding: 22px 15px 16px; background: var(--forest-950); color: #eef1eb; }
.admin-brand { padding: 0 8px 28px; }
.admin-menu { display: grid; gap: 5px; }
.admin-menu a, .admin-sidebar-foot a, .admin-sidebar-foot button { display: flex; width: 100%; min-height: 44px; align-items: center; gap: 11px; padding: 9px 12px; border: 0; border-radius: 9px; background: transparent; color: rgba(255,255,255,.6); text-align: left; }
.admin-menu a:hover, .admin-sidebar-foot a:hover, .admin-sidebar-foot button:hover { background: rgba(255,255,255,.06); color: #fff; }
.admin-menu a.is-active { background: rgba(215,178,104,.16); color: #f0d394; }
.admin-sidebar-foot { display: grid; gap: 3px; margin-top: auto; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.08); }
.admin-sidebar-foot form { margin: 0; }
.admin-sidebar-foot button { cursor: pointer; }
.admin-content { min-width: 0; padding: 32px clamp(24px, 3vw, 48px) 56px; }
.admin-container { width: min(1560px, 100%); margin: 0 auto; }
.admin-topbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.admin-title h1 { margin: 0 0 4px; font-size: 32px; font-weight: 600; letter-spacing: -.035em; }
.admin-title > p:last-child { margin: 0; color: #6c756d; font-size: 14px; }
.admin-user { display: flex; align-items: center; gap: 9px; color: #647066; font-size: 12px; }
.admin-avatar { display: grid; width: 37px; height: 37px; place-items: center; border-radius: 50%; background: var(--gold); color: #242a24; font-weight: 650; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 13px; margin-bottom: 20px; }
.toolbar-primary { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.segment-control { display: flex; gap: 4px; padding: 4px; border-radius: 10px; background: #dfe3dc; }
.segment-control button { min-height: 34px; padding: 6px 12px; border: 0; border-radius: 7px; background: transparent; color: #657066; font-size: 12px; }
.segment-control button.is-active { background: var(--surface); color: var(--ink); box-shadow: 0 3px 10px rgba(32,43,34,.08); }
.content-panel, .week-board, .booking-list, .stat-block { border: 1px solid rgba(67,82,69,.04); background: var(--surface); box-shadow: 0 1px 2px rgba(20,28,22,.03); }
.content-panel { padding: clamp(18px, 2.6vw, 28px); border-radius: var(--radius); }
.occupancy-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat-block { position: relative; min-height: 112px; padding: 17px; border-radius: var(--radius); overflow: hidden; }
.stat-block span { display: flex; align-items: center; gap: 6px; margin-bottom: 9px; color: #747e74; font-size: 12px; }
.stat-block strong { display: block; font-size: 26px; font-weight: 610; letter-spacing: -.02em; }
.stat-block small { display: block; margin-top: 6px; color: #929991; font-size: 9px; }
.stat-accent { color: #fff; background: linear-gradient(135deg, #24372b, #3f674c); }
.stat-accent span, .stat-accent small { color: rgba(255,255,255,.64); }
.legend-dot { display: inline-block; width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; }
.legend-dot.free { background: #d0ded2; }
.legend-dot.pending { background: #e5a73c; }
.legend-dot.awaiting-payment { background: #dd762e; }
.legend-dot.confirmed { background: #397149; }
.legend-dot.blocked { background: #6f7770; }
.week-board { margin-bottom: 21px; padding: 20px; border-radius: var(--radius); }
.week-head, .section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.week-head { margin-bottom: 18px; }
.week-head h2, .list-header h2, .section-heading h2, .content-panel h2 { margin: 0; font-size: 18px; font-weight: 620; letter-spacing: -.015em; }
.week-head .eyebrow, .list-header .eyebrow, .section-heading .eyebrow { margin-bottom: 3px; }
.legend { display: flex; flex-wrap: wrap; gap: 11px; color: #6f786f; font-size: 10px; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.schedule-wrap { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 9px; }
.schedule-wrap.month-mode { grid-template-columns: minmax(0, 1fr); }
.week-grid { display: grid; grid-template-columns: repeat(7, minmax(70px, 1fr)); gap: 9px; }
.week-grid.day-grid { min-width: 0; grid-template-columns: minmax(220px, 340px); }
.time-axis { display: grid; padding-top: 35px; gap: 3px; }
.time-axis span { display: flex; min-height: 25px; align-items: center; color: #6f786f; font-size: 10px; font-variant-numeric: tabular-nums; }
.day-column { min-width: 0; }
.day-label { margin-bottom: 8px; text-align: center; }
.day-label strong { display: block; font-size: 12px; font-weight: 650; }
.day-label span { color: #858d84; font-size: 10px; }
.day-load { display: grid; gap: 3px; }
.load-slot { display: flex; min-height: 25px; align-items: center; justify-content: center; padding: 2px 4px; border: 1px solid #cddbcf; border-radius: 5px; background: #e7efe8; color: #435247; font-size: 9px; font-variant-numeric: tabular-nums; }
button.load-slot { width: 100%; cursor: pointer; }
.load-slot.pending { border-color: #d89425; background: #f2c775; color: #573b0b; }
.load-slot.awaiting-payment { border-color: #c9611c; background: #e99253; color: #422008; }
.load-slot.confirmed { border-color: #285f38; background: #397149; color: #fff; }
.load-slot.blocked { border-color: #626b64; background: #727b73; color: #fff; }
.load-slot:hover { filter: brightness(.94); }
button.load-slot:hover { border-color: #668b6f; box-shadow: 0 0 0 2px rgba(57,113,73,.12); transform: translateY(-1px); }
.week-grid.month-grid { grid-template-columns: repeat(7, minmax(72px, 1fr)); }
.month-heat { position: relative; display: grid; width: 100%; min-height: 64px; place-content: center; overflow: hidden; border: 1px solid #d6ded5; border-radius: 8px; background: linear-gradient(to top, #397149 var(--load), #edf2ed var(--load)); color: var(--ink); }
.month-heat::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(32,72,44,.14) var(--load), transparent var(--load)); pointer-events: none; }
.month-heat strong, .month-heat span { position: relative; z-index: 1; }
.month-heat strong { font-size: 15px; }
.month-heat span { font-size: 10px; }
.skeleton-day { opacity: .55; animation: skeleton 1.2s ease-in-out infinite alternate; }
.skeleton-line { width: 60%; height: 15px; margin: 0 auto 8px; border-radius: 4px; background: #e2e6e0; }
.booking-list { border-radius: var(--radius); overflow: hidden; }
.list-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 17px 19px; border-bottom: 1px solid #e2e6df; }
.list-filters { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; }
.search-field { display: flex; min-width: 240px; min-height: 38px; align-items: center; gap: 7px; padding: 0 10px; border: 1px solid #d5dbd2; border-radius: 8px; background: var(--surface); color: #778077; }
.search-field input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 11px; }
.list-filter, .compact-filter { min-height: 40px; border: 1px solid #d5dbd2; border-radius: 8px; background: var(--surface); color: var(--ink); font-size: 11px; }
.list-filter { padding: 6px 10px; }
.compact-filter { display: flex; align-items: center; gap: 5px; padding: 3px 8px; color: #788179; }
.compact-filter input { width: 112px; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 11px; }
.booking-table-head, .booking-row { display: grid; grid-template-columns: minmax(150px, .95fr) minmax(180px, 1.15fr) minmax(110px, .7fr) minmax(140px, .85fr) minmax(125px, .8fr) minmax(225px, 1.15fr); gap: 16px; align-items: center; }
.booking-table-head { padding: 9px 19px; border-bottom: 1px solid #e7eae4; color: #8e968d; background: #fafbf9; font-size: 9px; letter-spacing: .06em; text-transform: uppercase; }
.booking-row { padding: 16px 19px; border-bottom: 1px solid #e5e8e2; font-size: 13px; }
.booking-row:last-child { border-bottom: 0; }
.booking-row strong { font-weight: 620; }
.booking-row small { display: block; margin-top: 3px; color: #727c73; font-size: 11px; }
.row-phone { display: block; width: fit-content; margin-top: 3px; color: var(--forest-700); font-size: 12px; }
.row-phone:hover { text-decoration: underline; }
.row-statuses { display: grid; justify-items: start; gap: 5px; }
.row-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.status-badge { display: inline-flex; width: fit-content; align-items: center; padding: 5px 9px; border-radius: 999px; font-size: 10px; font-weight: 650; }
.status-pending { background: #f8e2b5; color: #78500d; }
.status-awaiting-payment { background: #f7d2b9; color: #873f10; }
.status-confirmed { background: var(--success-soft); color: var(--success); }
.status-cancelled, .status-rejected { background: #eceeeb; color: #6d756d; }
.status-blocked { background: #e1e4e1; color: #555d56; }
.payment-badge { display: inline-flex; width: fit-content; align-items: center; padding: 4px 8px; border: 1px solid #d9ded8; border-radius: 999px; color: #677168; background: #f6f7f5; font-size: 10px; font-weight: 600; }
.payment-partial { border-color: #e4c484; background: #fff8e8; color: #7f570f; }
.payment-paid { border-color: #bcd5c1; background: #eef7ef; color: #2f633d; }
.payment-refunded { border-color: #dfc2bb; background: #fff4f1; color: #934839; }
.payment-not_recorded, .payment-legacy_untracked { border-color: #d4d8d1; background: #f1f2ef; color: #6f766f; }
.empty-state { display: grid; min-height: 260px; place-content: center; justify-items: center; padding: 30px; text-align: center; }
.empty-state > .icon { width: 35px; height: 35px; margin-bottom: 12px; color: #8b958b; }
.empty-state h3 { margin: 0 0 6px; font-size: 16px; }
.empty-state p { max-width: 420px; margin: 0 0 17px; color: #788178; font-size: 12px; }
.empty-state.compact { min-height: 210px; }

/* Booking details and new booking */
.detail-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(245px, .5fr); gap: 18px; align-items: start; }
.detail-section { padding-bottom: 25px; margin-bottom: 25px; border-bottom: 1px solid #e4e7e1; }
.detail-section:last-child { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
.detail-section h3 { margin: 0 0 12px; font-size: 15px; }
.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 22px; margin-top: 18px; }
.detail-item { padding: 11px 0; border-bottom: 1px solid #e6e9e4; }
.detail-item span { display: block; margin-bottom: 4px; color: #7d867d; font-size: 10px; }
.detail-item strong { font-size: 13px; font-weight: 620; }
.detail-item a { color: var(--success); }
.detail-comment { margin: 0; color: #505950; line-height: 1.65; }
.detail-status-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 7px; }
.payment-section .section-heading { align-items: center; margin-bottom: 16px; }
.payment-section .section-heading h3 { margin: 0; }
.payment-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; margin-bottom: 18px; }
.payment-summary-grid > div { padding: 13px; border-radius: 9px; background: #f5f7f3; }
.payment-summary-grid span, .payment-summary-grid strong { display: block; }
.payment-summary-grid span { margin-bottom: 4px; color: #748075; font-size: 10px; }
.payment-summary-grid strong { font-size: 17px; }
.payment-summary-grid .payment-due { background: #f8e9c9; }
.payment-ledger { display: grid; gap: 6px; }
.payment-row { display: grid; grid-template-columns: 70px 95px 130px 90px minmax(120px, 1fr); gap: 10px; align-items: center; padding: 10px 12px; border: 1px solid #e1e5df; border-radius: 8px; color: #6a746b; font-size: 11px; }
.payment-row strong { color: var(--success); font-size: 13px; }
.payment-row-refund strong { color: var(--danger); }
.payment-operation { font-weight: 650; color: var(--ink); }
.empty-ledger { padding: 18px; border: 1px dashed #d6ddd4; border-radius: 9px; color: #758076; text-align: center; font-size: 12px; }
.legacy-payment-note { margin: 12px 0 0; padding: 10px 12px; border-radius: 8px; background: #fff8e8; color: #7f570f; font-size: 11px; }
.payment-dialog { width: min(560px, calc(100vw - 30px)); }
.payment-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.source-badge { display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 999px; background: #eef2ed; color: #667166; font-size: 10px; }
.source-badge .icon { width: 14px; height: 14px; }
.timeline { display: grid; gap: 15px; }
.timeline-item { display: grid; grid-template-columns: 13px 1fr; gap: 10px; color: #596359; font-size: 11px; }
.timeline-item p { margin: 2px 0 0; color: #899188; }
.timeline-dot { width: 9px; height: 9px; margin-top: 4px; border: 2px solid var(--surface); border-radius: 50%; background: #4c805d; box-shadow: 0 0 0 2px #bad0bf; }
.notification-log { display: grid; gap: 10px; }
.notification-item { display: flex; align-items: flex-start; gap: 10px; padding: 11px; border-radius: 9px; background: var(--surface-soft); color: #667066; font-size: 11px; }
.notification-item p { margin: 2px 0 0; color: #8d948c; }
.side-actions { position: sticky; top: 22px; display: grid; gap: 10px; }
.side-actions hr { width: 100%; height: 1px; margin: 7px 0; border: 0; background: #e1e5df; }
.side-note { display: flex; align-items: flex-start; gap: 8px; margin-top: 8px; color: #7a837a; font-size: 10px; }
.side-note p { margin: 0; }
.new-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 18px; align-items: start; }
.form-section { padding-bottom: 27px; margin-bottom: 27px; border-bottom: 1px solid #e2e6df; }
.form-section:last-of-type { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
.form-section.is-disabled { opacity: .58; }
.form-section > h2 { margin-bottom: 16px; }
.new-summary { position: sticky; top: 22px; }
.new-summary .eyebrow { margin-bottom: 3px; }
.summary-lines { margin-top: 15px; }
.summary-line { display: flex; justify-content: space-between; gap: 14px; padding: 11px 0; border-bottom: 1px solid #e5e8e2; font-size: 12px; }
.summary-line span { color: #778077; }
.summary-line strong { text-align: right; }
.summary-total { padding: 18px 0 3px; }
.summary-total span { display: block; color: #7a837a; font-size: 10px; }
.summary-total strong { display: block; margin-top: 3px; font-size: 25px; }

/* Settings */
.settings-page { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 20px; align-items: start; }
.settings-tabs { position: sticky; top: 22px; display: grid; gap: 4px; }
.settings-tabs button { display: flex; min-height: 43px; align-items: center; gap: 9px; padding: 9px 11px; border: 0; border-radius: 9px; background: transparent; color: #677168; text-align: left; }
.settings-tabs button:hover { background: rgba(255,255,255,.6); }
.settings-tabs button.is-active { background: var(--surface); color: var(--ink); box-shadow: 0 4px 14px rgba(27,39,30,.06); }
.settings-form { padding-bottom: 0; }
.settings-section { min-height: 380px; }
.settings-section .section-heading { padding-bottom: 21px; margin-bottom: 22px; border-bottom: 1px solid #e3e6df; }
.section-heading p:not(.eyebrow) { max-width: 590px; margin: 6px 0 0; color: #778077; font-size: 12px; }
.check-card { display: flex; align-items: flex-start; gap: 10px; padding: 13px; border: 1px solid #dce1d9; border-radius: 9px; cursor: pointer; }
.check-card input { margin-top: 2px; accent-color: var(--forest-700); }
.check-card strong, .check-card small { display: block; }
.check-card strong { font-size: 12px; }
.check-card small { margin-top: 3px; color: #7b847b; font-size: 10px; }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 0; border-bottom: 1px solid #e5e8e2; }
.switch-copy { display: flex; align-items: flex-start; gap: 11px; }
.switch-copy > .icon { margin-top: 2px; color: var(--forest-600); }
.switch-copy strong, .switch-copy span { display: block; }
.switch-copy strong { font-size: 13px; }
.switch-copy span { margin-top: 3px; color: #7c857c; font-size: 11px; }
.switch { position: relative; width: 43px; height: 24px; flex: 0 0 auto; }
.switch input { position: absolute; opacity: 0; }
.switch span { display: block; height: 100%; border-radius: 999px; background: #ccd2cb; transition: background .18s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 2px 5px rgba(0,0,0,.18); transition: transform .18s; }
.switch input:checked + span { background: var(--forest-600); }
.switch input:checked + span::after { transform: translateX(19px); }
.switch input:focus-visible + span { outline: 3px solid rgba(215,178,104,.55); outline-offset: 2px; }
.notification-fields { display: grid; grid-template-columns: 1.3fr .7fr; gap: 15px; padding: 18px 0; border-bottom: 1px solid #e5e8e2; }
.switch-row.is-disabled { opacity: .58; }
.coming-soon { padding: 5px 8px; border-radius: 999px; background: #eceeeb; color: #6e776f; font-size: 10px; }
.extras-list { display: grid; gap: 8px; }
.extra-row { display: grid; grid-template-columns: 1fr 140px 40px; gap: 9px; }
.extra-row input { min-width: 0; min-height: 42px; padding: 8px 10px; border: 1px solid #d5dbd2; border-radius: 8px; }
.settings-actions { position: sticky; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 26px -28px 0; padding: 15px 28px; border-top: 1px solid #dfe3dc; background: rgba(255,255,255,.94); backdrop-filter: blur(9px); }
.settings-actions > span { color: #808980; font-size: 10px; }

/* Dialog */
.confirm-dialog { width: min(430px, calc(100vw - 30px)); padding: 25px; border: 0; border-radius: 15px; color: var(--ink); box-shadow: 0 28px 80px rgba(0,0,0,.3); }
.confirm-dialog::backdrop { background: rgba(15,21,17,.6); backdrop-filter: blur(2px); }
.dialog-close { position: absolute; top: 12px; right: 12px; border: 0; }
.dialog-icon { display: grid; width: 45px; height: 45px; place-items: center; margin-bottom: 16px; border-radius: 11px; background: var(--warning-soft); color: var(--warning); }
.confirm-dialog h2 { margin: 0 0 6px; font-size: 21px; }
.confirm-dialog > p { margin: 0 0 17px; color: #707a71; font-size: 12px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 19px; }

@media (max-width: 1080px) {
  .public-grid { grid-template-columns: minmax(240px, .72fr) minmax(500px, 1.28fr); gap: 38px; }
  .public-copy h1 { font-size: clamp(43px, 5.8vw, 65px); }
  .admin-shell { grid-template-columns: 82px minmax(0, 1fr); }
  .admin-brand { justify-content: center; padding-inline: 0; }
  .admin-brand .brand-copy, .admin-menu a span, .admin-sidebar-foot span { display: none; }
  .admin-menu a, .admin-sidebar-foot a, .admin-sidebar-foot button { justify-content: center; }
  .booking-table-head, .booking-row { grid-template-columns: minmax(130px, .9fr) minmax(150px, 1.1fr) 90px minmax(120px, .8fr) minmax(120px, .8fr) minmax(165px, 1fr); gap: 9px; }
  .row-actions .button-small { padding-inline: 7px; }
}

@media (max-width: 850px) {
  .public-page { min-height: auto; background: linear-gradient(180deg, rgba(19,27,22,.97), rgba(28,39,31,.92)), linear-gradient(137deg, #3c4940, #c8b27e); }
  .public-nav { margin-bottom: 52px; }
  .public-grid { grid-template-columns: 1fr; }
  .public-copy { max-width: 660px; }
  .booking-panel { min-height: 0; }
  .auth-page { grid-template-columns: 1fr; }
  .auth-visual { min-height: 330px; }
  .auth-visual h1 { max-width: 580px; font-size: clamp(40px, 8vw, 62px); }
  .auth-form-wrap { min-height: 570px; }
  .occupancy-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .booking-table-head { display: none; }
  .booking-row { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
  .booking-row > * { min-width: 0; }
  .row-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .detail-layout, .new-layout { grid-template-columns: 1fr; }
  .side-actions, .new-summary { position: static; }
  .settings-page { grid-template-columns: 1fr; }
  .settings-tabs { position: static; display: flex; overflow-x: auto; padding-bottom: 3px; }
  .settings-tabs button { flex: 0 0 auto; }
}

@media (max-width: 600px) {
  body { font-size: 14px; }
  .public-page { padding: 18px 14px 28px; }
  .public-nav { margin-bottom: 38px; }
  .public-nav .brand strong { font-size: 13px; }
  .public-phone { padding: 8px 10px; font-size: 11px; }
  .public-copy h1 { font-size: 42px; }
  .public-copy > p:not(.eyebrow) { font-size: 15px; }
  .public-facts { gap: 15px; }
  .public-fact { min-width: 100px; }
  .booking-panel { padding: 19px; border-radius: 16px; }
  .booking-head { display: block; }
  .booking-price { display: block; margin-top: 7px; }
  .booking-progress span { font-size: 9px; }
  .date-grid { grid-template-columns: repeat(2, 1fr); }
  .time-grid { grid-template-columns: repeat(3, 1fr); }
  .public-form-grid, .form-grid, .detail-grid, .notification-fields { grid-template-columns: 1fr; }
  .full-field { grid-column: auto; }
  .booking-summary { align-items: stretch; flex-direction: column; }
  .booking-summary .button { width: 100%; }
  .review-row { align-items: flex-start; flex-direction: column; gap: 3px; }
  .review-row strong { max-width: none; text-align: left; }
  .form-actions .button { flex: 1; padding-inline: 9px; font-size: 12px; }
  .auth-visual { min-height: 270px; padding: 25px 20px; }
  .auth-visual h1 { font-size: 39px; }
  .auth-visual > div > p:last-child, .auth-visual small { display: none; }
  .auth-form-wrap { min-height: calc(100vh - 270px); padding: 32px 20px; }
  .admin-shell { display: block; }
  .admin-sidebar { position: sticky; z-index: 50; top: 0; display: block; width: 100%; height: auto; padding: 8px 10px; }
  .admin-brand, .admin-sidebar-foot { display: none; }
  .admin-menu { grid-template-columns: repeat(3, 1fr); }
  .admin-menu a { min-height: 48px; flex-direction: column; gap: 2px; padding: 5px 3px; }
  .admin-menu a span { display: block; font-size: 9px; }
  .admin-content { padding: 21px 12px 40px; }
  .admin-topbar { align-items: flex-start; margin-bottom: 21px; }
  .admin-title h1 { font-size: 27px; }
  .admin-user > span:first-child { display: none; }
  .toolbar { align-items: stretch; }
  .toolbar-primary { width: 100%; }
  .toolbar-primary > .button { flex: 1; }
  .metric-tabs { width: 100%; }
  .metric-tabs button { flex: 1; }
  .segment-control { width: 100%; }
  .segment-control button { flex: 1; padding-inline: 6px; }
  .occupancy-stats { gap: 8px; }
  .stat-block { min-height: 101px; padding: 13px; }
  .stat-block strong { font-size: 22px; }
  .week-board { padding: 14px 10px; overflow: hidden; }
  .week-head { align-items: flex-start; flex-direction: column; }
  .schedule-wrap { overflow-x: auto; }
  .week-grid { min-width: 620px; gap: 5px; }
  .week-grid.month-grid { min-width: 620px; }
  .time-axis { position: sticky; z-index: 2; left: 0; background: var(--surface); }
  .list-header { align-items: stretch; flex-direction: column; padding: 14px; }
  .list-filters { align-items: stretch; flex-direction: column; }
  .search-field { min-width: 0; }
  .booking-row { grid-template-columns: 1fr; padding: 14px; }
  .booking-row > :nth-child(4) { grid-column: auto; }
  .row-actions { display: grid; grid-template-columns: repeat(2, 1fr); width: 100%; }
  .row-actions .button { width: 100%; }
  .content-panel { padding: 17px; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .detail-layout { gap: 12px; }
  .detail-grid { gap: 0; }
  .payment-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .payment-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .payment-row > :last-child { grid-column: 1 / -1; }
  .payment-form-grid { grid-template-columns: 1fr; }
  .new-layout { gap: 12px; }
  .settings-tabs button { min-height: 40px; padding-inline: 9px; font-size: 11px; }
  .settings-tabs .icon { display: none; }
  .settings-section { min-height: 0; }
  .settings-actions { align-items: stretch; flex-direction: column; margin-inline: -17px; padding: 13px 17px; }
  .settings-actions .button { width: 100%; }
  .extra-row { grid-template-columns: 1fr 90px 40px; }
  .dialog-actions { align-items: stretch; flex-direction: column-reverse; }
  .dialog-actions form, .dialog-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
