:root {
  color-scheme: light;
  --ink: #18201c;
  --muted: #69736d;
  --faint: #8a948e;
  --canvas: #f4f6f3;
  --surface: #ffffff;
  --surface-soft: #eef2ef;
  --line: #dce3de;
  --line-strong: #c7d0ca;
  --brand: #1f5a43;
  --brand-strong: #174633;
  --brand-soft: #e4efe9;
  --blue: #2c64a7;
  --blue-soft: #dce9f7;
  --green: #287a50;
  --green-soft: #dcefe4;
  --amber: #9c6513;
  --amber-soft: #fbebc8;
  --red: #a43c36;
  --red-soft: #f7ddda;
  --gray: #5f6b65;
  --gray-soft: #e3e7e4;
  --shadow-dialog: 0 24px 70px rgba(26, 43, 34, .2);
  --radius-sm: 7px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --sidebar-width: 224px;
  --room-col: 154px;
  --day-col: 92px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: "Aptos", "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--canvas); }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  background: var(--canvas);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

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

button, a, select, input[type="date"] { touch-action: manipulation; }

button, a { -webkit-tap-highlight-color: transparent; }

button { color: inherit; }

a { color: inherit; text-decoration: none; }

[hidden] { display: none !important; }

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

:focus-visible {
  outline: 3px solid rgba(31, 90, 67, .32);
  outline-offset: 2px;
}

h1, h2, h3, p { margin-top: 0; }

h1, h2, h3 { color: var(--ink); text-wrap: balance; }

h1 { margin-bottom: 0; font-size: clamp(1.7rem, 3vw, 2.2rem); line-height: 1.08; letter-spacing: -.035em; }
h2 { margin-bottom: 0; font-size: 1.28rem; line-height: 1.2; letter-spacing: -.02em; }
h3 { margin-bottom: 0; font-size: 1rem; }

.eyebrow {
  margin-bottom: 6px;
  color: var(--brand);
  font-size: .76rem;
  font-weight: 750;
  letter-spacing: .095em;
  line-height: 1.2;
  text-transform: uppercase;
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-lockup > span:last-child { display: flex; flex-direction: column; min-width: 0; line-height: 1.05; }
.brand-lockup strong { color: var(--muted); font-size: .66rem; font-weight: 650; letter-spacing: .055em; text-transform: uppercase; }
.brand-lockup b { margin-top: 3px; color: var(--ink); font-size: 1.18rem; font-weight: 760; letter-spacing: -.025em; }

.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  place-items: center;
  color: white;
  background: var(--brand);
  border-radius: 13px;
}

.brand-mark--small { width: 40px; height: 40px; border-radius: 10px; }

.button,
.icon-button,
.text-button,
.nav-item,
.date-range-button {
  border: 0;
  cursor: pointer;
}

.button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 14px;
  color: var(--ink);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-weight: 690;
  line-height: 1.2;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}

.button svg, .nav-item svg, .date-range-button svg, .calendar-hint svg, .search-field svg { width: 18px; height: 18px; flex: 0 0 auto; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button:disabled { cursor: wait; opacity: .58; transform: none; }
.button--primary { color: white; background: var(--brand); border-color: var(--brand); }
.button--primary:hover { background: var(--brand-strong); border-color: var(--brand-strong); }
.button--quiet { background: var(--surface); border-color: var(--line-strong); }
.button--quiet:hover { background: var(--surface-soft); }
.button--danger { color: white; background: var(--red); border-color: var(--red); }
.button--danger-quiet { color: var(--red); background: var(--red-soft); }
.button--wide { width: 100%; min-height: 48px; }

.icon-button {
  display: inline-grid;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  place-items: center;
  padding: 0;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  transition: background-color .15s ease, border-color .15s ease;
}

.icon-button:hover { background: var(--surface-soft); border-color: #aebbb3; }
.icon-button svg { width: 20px; height: 20px; }
.icon-button--inside { position: absolute; top: 3px; right: 3px; width: 42px; height: 42px; border: 0; background: transparent; }

.text-button { padding: 6px 0; color: var(--muted); background: transparent; font-weight: 650; }
.text-button:hover { color: var(--ink); }

.login-shell {
  display: grid;
  min-height: 100vh;
  padding: 28px;
  place-items: center;
  background:
    linear-gradient(90deg, transparent 39px, rgba(31, 90, 67, .045) 40px, transparent 41px),
    linear-gradient(rgba(31, 90, 67, .045) 1px, transparent 1px),
    #edf2ee;
  background-size: 80px 100%, 100% 40px, auto;
}

.login-panel {
  width: min(100%, 430px);
  padding: clamp(28px, 6vw, 46px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 22px 60px rgba(31, 62, 46, .11);
}

.brand-lockup--login { margin-bottom: clamp(42px, 9vh, 72px); }
.login-copy { margin-bottom: 26px; }
.login-copy h1 { margin-bottom: 12px; font-size: clamp(2rem, 8vw, 3.15rem); }
.login-copy > p:last-child { max-width: 31ch; margin-bottom: 0; color: var(--muted); font-size: 1rem; text-wrap: pretty; }
.login-form > label { display: block; margin-bottom: 7px; font-size: .86rem; font-weight: 700; }
.password-field { position: relative; margin-bottom: 14px; }
.password-field input { width: 100%; padding-right: 50px; }
.login-footnote { margin: 24px 0 0; color: var(--faint); font-size: .78rem; text-align: center; }

input, select, textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}

textarea { min-height: 88px; resize: vertical; }
input::placeholder, textarea::placeholder { color: #9aa49e; }
input:hover, select:hover, textarea:hover { border-color: #aab7af; }
input:focus, select:focus, textarea:focus { border-color: var(--brand); outline: 0; box-shadow: 0 0 0 3px rgba(31, 90, 67, .14); }

.form-error { margin: 10px 0 0; color: var(--red); font-size: .86rem; font-weight: 650; }

.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed;
  z-index: 30;
  inset: 0 auto 0 0;
  display: flex;
  width: var(--sidebar-width);
  flex-direction: column;
  padding: 22px 16px 18px;
  background: var(--surface);
  border-right: 1px solid var(--line);
}

.sidebar .brand-lockup { padding: 0 6px; }

.main-nav { display: grid; gap: 4px; margin-top: 42px; }

.nav-item {
  display: flex;
  min-height: 46px;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  color: var(--muted);
  background: transparent;
  border-radius: var(--radius-sm);
  font-size: .91rem;
  font-weight: 680;
  text-align: left;
}

.nav-item svg { width: 19px; height: 19px; }
.nav-item:hover { color: var(--ink); background: var(--surface-soft); }
.nav-item.is-active { color: var(--brand-strong); background: var(--brand-soft); }

.sidebar-footer { display: flex; align-items: flex-start; gap: 14px; margin-top: auto; padding: 14px 6px 0; border-top: 1px solid var(--line); flex-direction: column; }
.privacy-note { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: .73rem; font-weight: 650; }
.status-dot { width: 7px; height: 7px; background: var(--green); border-radius: 50%; box-shadow: 0 0 0 3px var(--green-soft); }

.main-content { min-height: 100vh; margin-left: var(--sidebar-width); padding: 34px clamp(24px, 4vw, 58px) 60px; }
.view-section { display: none; animation: view-in .18s ease-out; }
.view-section.is-active { display: block; }
@keyframes view-in { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }

.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.page-heading .button { flex: 0 0 auto; }

.today-summary {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin-bottom: 24px;
  overflow-x: auto;
  background: var(--surface);
  border-block: 1px solid var(--line);
  scrollbar-width: none;
}
.today-summary::-webkit-scrollbar, .legend::-webkit-scrollbar { display: none; }

.summary-stat { min-width: 150px; padding: 15px 22px 14px 0; }
.summary-stat + .summary-stat { padding-left: 22px; border-left: 1px solid var(--line); }
.summary-stat strong { display: block; margin-bottom: 2px; font-size: 1.38rem; line-height: 1.1; letter-spacing: -.03em; }
.summary-stat span { color: var(--muted); font-size: .79rem; white-space: nowrap; }
.summary-stat.is-alert strong { color: var(--amber); }

.calendar-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.date-navigation, .calendar-actions { display: flex; align-items: center; gap: 8px; }
.date-range-button { display: flex; min-height: 42px; align-items: center; gap: 8px; padding: 8px 12px; background: transparent; border-radius: var(--radius-sm); font-weight: 690; }
.date-range-button:hover { background: var(--surface); }

.legend { display: flex; flex-wrap: wrap; gap: 9px 18px; margin: 0 0 12px; color: var(--muted); font-size: .73rem; font-weight: 620; scrollbar-width: none; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend-swatch { width: 10px; height: 10px; border-radius: 3px; }
.legend-swatch--reserved { background: var(--blue); }
.legend-swatch--occupied { background: var(--green); }
.legend-swatch--pending { background: var(--amber); }
.legend-swatch--cleaning { background: #c1872d; }
.legend-swatch--blocked { background: var(--gray); }
.legend-swatch--out { background: var(--red); }

.loading-block, .empty-state {
  display: flex;
  min-height: 260px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.spinner { width: 18px; height: 18px; border: 2px solid var(--line-strong); border-top-color: var(--brand); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.calendar-scroller {
  max-width: 100%;
  max-height: calc(100vh - 330px);
  min-height: 300px;
  overflow: auto;
  overscroll-behavior: contain;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  box-shadow: 0 7px 24px rgba(28, 48, 37, .055);
  scrollbar-color: #aebbb3 transparent;
}

.calendar-grid { width: max-content; min-width: 100%; }
.calendar-header, .calendar-row {
  display: grid;
  grid-template-columns: var(--room-col) repeat(var(--day-count), var(--day-col));
  width: max-content;
  min-width: 100%;
}

.calendar-header { position: sticky; z-index: 8; top: 0; min-height: 62px; background: var(--surface); border-bottom: 1px solid var(--line-strong); }
.calendar-row { position: relative; min-height: 54px; border-bottom: 1px solid var(--line); }
.calendar-row:last-child { border-bottom: 0; }
.calendar-row:hover .calendar-cell { background-color: #fbfcfb; }

.calendar-corner,
.room-label {
  position: sticky;
  z-index: 6;
  left: 0;
  display: flex;
  background: var(--surface);
  border-right: 1px solid var(--line-strong);
}

.calendar-corner { z-index: 10; grid-column: 1; align-items: center; padding: 0 13px; color: var(--muted); font-size: .72rem; font-weight: 740; letter-spacing: .07em; text-transform: uppercase; }
.room-label { grid-column: 1; grid-row: 1; align-items: center; gap: 10px; padding: 7px 12px; }
.room-label strong { display: block; line-height: 1.05; font-size: .98rem; }
.room-label small { display: block; margin-top: 4px; color: var(--muted); font-size: .66rem; line-height: 1; }
.room-floor { display: grid; width: 28px; height: 28px; place-items: center; flex: 0 0 auto; color: var(--brand); background: var(--brand-soft); border-radius: 6px; font-size: .72rem; font-weight: 780; }

.calendar-day {
  display: flex;
  grid-row: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  border-right: 1px solid var(--line);
}

.calendar-day strong { color: var(--ink); font-size: 1.02rem; line-height: 1; }
.calendar-day span { margin-top: 4px; font-size: .66rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.calendar-day.is-today { background: var(--brand-soft); }
.calendar-day.is-today strong, .calendar-day.is-today span { color: var(--brand-strong); }
.calendar-day.is-weekend:not(.is-today) { background: #fafbf9; }

.calendar-cell {
  grid-row: 1;
  min-width: 0;
  padding: 0;
  background: transparent;
  border: 0;
  border-right: 1px solid var(--line);
  border-radius: 0;
}

.calendar-cell.is-today { background: rgba(31, 90, 67, .045); }
.calendar-cell:focus-visible { position: relative; z-index: 4; outline-offset: -3px; }

.reservation-bar, .block-bar {
  position: relative;
  z-index: 5;
  grid-row: 1;
  align-self: center;
  display: flex;
  min-width: 0;
  height: 40px;
  align-items: center;
  gap: 6px;
  margin: 0 3px;
  padding: 0 10px;
  overflow: hidden;
  color: white;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
  font-size: .76rem;
  font-weight: 720;
  text-align: left;
  box-shadow: inset 0 -1px rgba(0, 0, 0, .1);
}

.reservation-bar:hover, .block-bar:hover { filter: brightness(.96); }
.reservation-bar--reserved { background: var(--blue); }
.reservation-bar--occupied { background: var(--green); }
.reservation-bar--checked_out { background: var(--gray); }
.reservation-bar.is-pending { background: var(--amber); }
.reservation-bar.is-partial { background: #9b791b; }
.block-bar--cleaning { color: #3a2b12; background: #efc776; }
.block-bar--blocked { background: var(--gray); }
.block-bar--out_of_service { background: var(--red); }
.reservation-bar span, .block-bar span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.payment-mark { display: grid; width: 17px; height: 17px; flex: 0 0 auto; place-items: center; color: currentColor; border: 1.5px solid currentColor; border-radius: 50%; font-size: .62rem; }

.calendar-hint { display: flex; align-items: center; gap: 7px; margin: 10px 0 0; color: var(--muted); font-size: .76rem; }

.list-toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.search-field { position: relative; display: block; flex: 1; max-width: 520px; }
.search-field svg { position: absolute; top: 14px; left: 13px; color: var(--muted); }
.search-field input { padding-left: 40px; }
.list-toolbar select { width: auto; min-width: 180px; }

.data-list { background: var(--surface); border-block: 1px solid var(--line); }
.data-list-empty { padding: 48px 20px; color: var(--muted); text-align: center; }
.reservation-list-item {
  display: grid;
  grid-template-columns: minmax(180px, 1.5fr) 108px minmax(190px, 1fr) minmax(140px, .8fr) 42px;
  align-items: center;
  gap: 18px;
  min-height: 74px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.reservation-list-item:last-child { border-bottom: 0; }
.reservation-list-item:hover { background: #fafcfb; }
.reservation-primary strong, .reservation-primary span, .reservation-dates strong, .reservation-dates span { display: block; }
.reservation-primary span, .reservation-dates span, .reservation-amount span { margin-top: 3px; color: var(--muted); font-size: .76rem; }
.room-chip { display: inline-flex; width: fit-content; align-items: center; gap: 6px; padding: 5px 9px; color: var(--brand-strong); background: var(--brand-soft); border-radius: 999px; font-size: .78rem; font-weight: 760; }
.reservation-amount strong { display: block; font-size: .9rem; }
.row-arrow { display: grid; width: 38px; height: 38px; place-items: center; color: var(--muted); }
.row-arrow svg { width: 18px; height: 18px; }

.status-badge { display: inline-flex; align-items: center; gap: 6px; width: fit-content; padding: 5px 8px; border-radius: 999px; font-size: .72rem; font-weight: 730; }
.status-badge::before { content: ""; width: 6px; height: 6px; background: currentColor; border-radius: 50%; }
.status-badge--reserved { color: var(--blue); background: var(--blue-soft); }
.status-badge--occupied { color: var(--green); background: var(--green-soft); }
.status-badge--checked_out { color: var(--gray); background: var(--gray-soft); }
.status-badge--pending { color: var(--amber); background: var(--amber-soft); }

.operations-layout { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 34px; }
.operations-group { min-width: 0; }
.operations-group--wide { grid-column: 1 / -1; }
.operations-group-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 11px; border-bottom: 1px solid var(--line-strong); }
.operations-group-header span { color: var(--muted); font-size: .76rem; }
.operation-row { display: flex; min-height: 66px; align-items: center; gap: 13px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.operation-time { width: 48px; flex: 0 0 auto; color: var(--muted); font-size: .73rem; font-weight: 740; }
.operation-room { display: grid; width: 42px; height: 42px; flex: 0 0 auto; place-items: center; color: var(--brand-strong); background: var(--brand-soft); border-radius: 8px; font-weight: 780; }
.operation-main { min-width: 0; flex: 1; }
.operation-main strong, .operation-main span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.operation-main span { margin-top: 2px; color: var(--muted); font-size: .76rem; }
.operation-row .button { min-height: 36px; padding-block: 7px; font-size: .78rem; }
.operations-empty { padding: 24px 0; color: var(--muted); font-size: .86rem; }

.notice { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 26px; padding: 14px 16px; border-radius: var(--radius-sm); font-size: .87rem; }
.notice svg { width: 20px; height: 20px; flex: 0 0 auto; }
.notice--warning { color: #6c4814; background: var(--amber-soft); border: 1px solid #e6c479; }
.notice strong { display: block; margin-bottom: 2px; }

.settings-section { padding: 24px 0 28px; border-top: 1px solid var(--line-strong); }
.settings-section:first-of-type { border-top: 0; }
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 15px; }
.section-heading p { margin: 5px 0 0; color: var(--muted); font-size: .84rem; }
.settings-rows { background: var(--surface); border-block: 1px solid var(--line); }
.settings-row { display: grid; grid-template-columns: minmax(140px, 1fr) minmax(180px, 1fr) auto; align-items: center; gap: 18px; min-height: 64px; padding: 9px 2px; border-bottom: 1px solid var(--line); }
.settings-row:last-child { border-bottom: 0; }
.settings-row strong, .settings-row span { display: block; }
.settings-row span { margin-top: 2px; color: var(--muted); font-size: .76rem; }
.rate-input-wrap { position: relative; max-width: 180px; }
.rate-input-wrap::after { content: "€ / noche"; position: absolute; top: 14px; right: 12px; color: var(--muted); font-size: .75rem; pointer-events: none; }
.rate-input-wrap input { padding-right: 70px; }
.settings-row .icon-button { justify-self: end; }
.export-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.mobile-header, .mobile-nav { display: none; }

.app-dialog {
  width: min(760px, calc(100vw - 30px));
  max-height: min(880px, calc(100vh - 28px));
  padding: 0;
  overflow: hidden;
  color: var(--ink);
  background: var(--surface);
  border: 0;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-dialog);
}

.app-dialog--small { width: min(520px, calc(100vw - 30px)); }
.app-dialog::backdrop, .confirm-dialog::backdrop { background: rgba(17, 29, 23, .52); backdrop-filter: blur(2px); }
.app-dialog[open] { animation: dialog-in .18s ease-out; }
@keyframes dialog-in { from { opacity: 0; transform: translateY(8px) scale(.99); } to { opacity: 1; transform: none; } }
.app-dialog form { display: flex; max-height: inherit; flex-direction: column; }
.dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 22px 24px 18px; border-bottom: 1px solid var(--line); }
.dialog-header .icon-button { margin: -4px -6px 0 0; border: 0; }
.dialog-body { padding: 22px 24px 26px; overflow-y: auto; overscroll-behavior: contain; }
.dialog-body fieldset { min-width: 0; margin: 0 0 24px; padding: 0 0 22px; border: 0; border-bottom: 1px solid var(--line); }
.dialog-body fieldset:last-of-type { margin-bottom: 20px; }
.dialog-body legend { width: 100%; margin-bottom: 13px; padding: 0; color: var(--ink); font-size: .82rem; font-weight: 760; }
.dialog-body label { display: flex; flex-direction: column; gap: 6px; color: var(--ink); font-size: .79rem; font-weight: 700; }
.form-grid { display: grid; gap: 14px; }
.form-grid + .form-grid { margin-top: 14px; }
.form-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field-help { margin: 9px 0 0; color: var(--muted); font-size: .73rem; }
.payment-preview { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; padding: 10px 12px; color: var(--muted); background: var(--surface-soft); border-radius: var(--radius-sm); font-size: .8rem; }
.payment-preview strong { color: var(--ink); }
.dialog-footer { display: flex; align-items: center; gap: 8px; padding: 15px 24px calc(15px + var(--safe-bottom)); background: #fafbf9; border-top: 1px solid var(--line); }
.dialog-spacer { flex: 1; }
.check-row { flex-direction: row !important; align-items: center; }
.check-row input { width: 20px; min-height: 20px; }

.confirm-dialog { width: min(420px, calc(100vw - 30px)); padding: 28px; color: var(--ink); background: var(--surface); border: 0; border-radius: var(--radius-lg); box-shadow: var(--shadow-dialog); text-align: center; }
.confirm-icon { display: grid; width: 48px; height: 48px; margin: 0 auto 16px; place-items: center; color: var(--red); background: var(--red-soft); border-radius: 50%; }
.confirm-icon svg { width: 24px; height: 24px; }
.confirm-dialog p { margin: 10px auto 24px; color: var(--muted); text-wrap: pretty; }
.confirm-actions { display: flex; justify-content: center; gap: 8px; }

.toast-region { position: fixed; z-index: 100; right: 22px; bottom: 22px; display: grid; gap: 8px; width: min(380px, calc(100vw - 32px)); pointer-events: none; }
.toast { display: flex; align-items: flex-start; gap: 10px; padding: 13px 15px; color: white; background: #1d2722; border-radius: var(--radius-sm); box-shadow: 0 12px 30px rgba(18, 31, 24, .22); animation: toast-in .2s ease-out; }
.toast svg { width: 19px; height: 19px; flex: 0 0 auto; }
.toast strong, .toast span { display: block; }
.toast span { margin-top: 2px; color: #d8e0db; font-size: .77rem; }
.toast--error { background: #762d28; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

@media (max-width: 900px) {
  :root { --room-col: 128px; --day-col: 86px; }
  .sidebar { display: none; }
  .mobile-header {
    position: sticky;
    z-index: 25;
    top: 0;
    display: flex;
    min-height: 62px;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(12px);
  }
  .brand-lockup--mobile strong { color: var(--ink); font-size: .96rem; letter-spacing: -.01em; text-transform: none; }
  .brand-lockup--mobile small { margin-top: 2px; color: var(--muted); font-size: .65rem; }
  .main-content { margin-left: 0; padding: 24px 16px calc(92px + var(--safe-bottom)); }
  .mobile-nav {
    position: fixed;
    z-index: 25;
    inset: auto 0 0 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    padding: 6px 6px calc(6px + var(--safe-bottom));
    background: rgba(255, 255, 255, .97);
    border-top: 1px solid var(--line);
    backdrop-filter: blur(12px);
  }
  .mobile-nav .nav-item { min-height: 54px; flex-direction: column; justify-content: center; gap: 3px; padding: 5px 3px; border-radius: 7px; font-size: .65rem; }
  .mobile-nav .nav-item svg { width: 20px; height: 20px; }
  .page-heading { margin-bottom: 22px; }
  .desktop-action { display: none; }
  .today-summary { margin-inline: -16px; padding-left: 16px; }
  .summary-stat { min-width: 132px; padding-right: 16px; }
  .summary-stat + .summary-stat { padding-left: 16px; }
  .calendar-toolbar { align-items: stretch; flex-direction: column; }
  .date-navigation { display: grid; grid-template-columns: 42px auto 42px 1fr; }
  .calendar-actions { justify-content: flex-end; }
  .date-range-button { justify-content: flex-start; }
  .calendar-scroller { max-height: calc(100vh - 390px); margin-inline: -16px; border-inline: 0; border-radius: 0; }
  .calendar-corner, .room-label { box-shadow: 5px 0 8px rgba(25, 43, 34, .045); }
  .calendar-corner { padding-inline: 10px; }
  .room-label { gap: 7px; padding-inline: 8px; }
  .room-floor { width: 25px; height: 25px; }
  .legend { flex-wrap: nowrap; margin-right: -16px; padding-right: 16px; overflow-x: auto; white-space: nowrap; }
  .calendar-hint { align-items: flex-start; }
  .operations-layout { grid-template-columns: 1fr; }
  .operations-group--wide { grid-column: auto; }
  .reservation-list-item { grid-template-columns: 1fr auto; gap: 8px 12px; padding: 13px 2px; }
  .reservation-primary { grid-column: 1; }
  .room-chip { grid-column: 2; grid-row: 1; }
  .reservation-dates { grid-column: 1; }
  .reservation-amount { grid-column: 2; text-align: right; }
  .row-arrow { display: none; }
  .list-toolbar { align-items: stretch; flex-direction: column; }
  .search-field { max-width: none; }
  .list-toolbar select { width: 100%; }
  .settings-row { grid-template-columns: 1fr minmax(130px, .8fr) 42px; gap: 10px; }
}

@media (max-width: 620px) {
  .login-shell { padding: 0; place-items: stretch; background: var(--surface); }
  .login-panel { width: 100%; min-height: 100vh; padding: 28px 22px 34px; border: 0; border-radius: 0; box-shadow: none; }
  .brand-lockup--login { margin-bottom: 14vh; }
  .page-heading h1 { max-width: 12ch; }
  .form-grid--2, .form-grid--3 { grid-template-columns: 1fr; }
  .app-dialog { width: 100vw; max-height: calc(100vh - 10px); margin: auto 0 0; border-radius: 14px 14px 0 0; }
  .app-dialog--small { width: 100vw; }
  .dialog-header { padding: 18px 18px 14px; }
  .dialog-body { padding: 18px 18px 24px; }
  .dialog-footer { padding-inline: 14px; }
  .dialog-footer .button { padding-inline: 11px; }
  .section-heading { align-items: stretch; flex-direction: column; }
  .section-heading .button { align-self: flex-start; }
  .settings-row { grid-template-columns: 1fr 42px; }
  .settings-row--rate { grid-template-columns: 1fr auto; }
  .settings-row--rate .rate-input-wrap { grid-row: 2; grid-column: 1 / -1; max-width: none; }
  .settings-row--rate .button { grid-row: 1; grid-column: 2; min-height: 36px; justify-self: end; padding: 7px 10px; font-size: .78rem; }
  .settings-row > .room-type-copy { grid-column: 1; }
  .settings-row > .room-detail-copy { grid-row: 2; grid-column: 1; }
  .settings-row > .icon-button { grid-row: 1 / span 2; grid-column: 2; }
  .calendar-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
