@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700&family=Manrope:wght@400;500;600;700&display=swap");

:root {
  /* Brand — warm hospitality */
  --ink: #1a1410;
  --ink-soft: #2e261f;
  --muted: #7a7168;
  --bg: #f0ebe5;
  --bg-deep: #e3dbd2;
  --panel: #faf7f3;
  --panel-strong: #ffffff;
  --surface-1: #faf7f3;
  --surface-2: rgba(255, 255, 255, 0.72);
  --line: #ddd4c8;
  --line-soft: rgba(26, 20, 16, 0.08);

  --accent: #e86a0c;
  --accent-mid: #ff8f1f;
  --accent-deep: #c04a00;
  --accent-soft: rgba(232, 106, 12, 0.12);
  --accent-ink: #fffbf0;
  --brass: #e86a0c;
  --brass-soft: #ffb25c;

  --danger: #b33a2e;
  --warn: #c47a12;
  --ok: #2f8a5b;
  --info: #3d6b8a;

  --status-ready: #2f8a5b;
  --status-dirty: #b33a2e;
  --status-cleaning: #e86a0c;
  --status-inspected: #3d6b8a;
  --status-ooo: #6a6460;
  --status-vacant: #2f8a5b;
  --status-occupied: #e86a0c;

  --sidebar: #140e0a;
  --sidebar-elev: #1f1610;
  --sidebar-ink: #fff6ec;
  --sidebar-muted: #b89a7e;

  --radius-sm: 8px;
  --radius: 12px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --font-display: "Fraunces", "Times New Roman", serif;
  --font-ui: "Manrope", "Helvetica Neue", sans-serif;
  --font-mono: "SF Mono", "Menlo", "Consolas", monospace;

  --shadow-soft: 0 32px 64px rgba(26, 20, 16, 0.12);
  --shadow-card:
    0 0 0 1px rgba(26, 20, 16, 0.04),
    0 1px 2px rgba(26, 20, 16, 0.04),
    0 8px 24px rgba(26, 20, 16, 0.06),
    0 24px 48px rgba(26, 20, 16, 0.04);
  --shadow-glow: 0 0 0 1px rgba(232, 106, 12, 0.12), 0 8px 32px rgba(232, 106, 12, 0.15);
  --glass: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(255, 255, 255, 0.85);
  --sidebar-glow: rgba(232, 106, 12, 0.35);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --noise: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.94rem;
  line-height: 1.55;
  color: var(--ink);
  background-color: var(--bg);
  background-image:
    var(--noise),
    radial-gradient(ellipse 90% 55% at -5% -5%, rgba(232, 106, 12, 0.14), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 0%, rgba(255, 143, 31, 0.1), transparent 50%),
    linear-gradient(165deg, #f7f2ec 0%, var(--bg) 42%, var(--bg-deep) 100%);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}
a:hover { color: var(--accent-deep); }

h1, h2, .brand, .auth-brand, .display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.12;
  color: var(--ink);
}
h1 { margin: 0 0 0.35rem; font-size: clamp(2rem, 2.8vw, 2.55rem); }
h2 { margin: 0 0 0.85rem; font-size: 1.28rem; font-weight: 600; }
.muted { color: var(--muted); }
.eyebrow {
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 0.45rem;
}

/* —— App shell —— */
.app-shell {
  display: grid;
  grid-template-columns: 272px 1fr;
  min-height: 100vh;
  animation: shellIn 0.55s var(--ease-out) both;
}
@keyframes shellIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  background:
    linear-gradient(180deg, rgba(232, 106, 12, 0.22), transparent 34%),
    linear-gradient(160deg, var(--sidebar-elev), var(--sidebar) 70%);
  color: var(--sidebar-ink);
  padding: 1.65rem 1.1rem 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  border-right: 1px solid rgba(255, 255, 255, 0.04);
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.15) transparent;
}

.brand {
  position: relative;
  padding: 0.2rem 0.4rem 1rem;
  border-bottom: 1px solid rgba(255, 246, 236, 0.1);
  color: #fff;
  font-size: 1.35rem;
}
.nav-close {
  display: none;
  position: absolute;
  top: 0.15rem;
  right: 0.15rem;
  width: 2.25rem;
  height: 2.25rem;
  border: 0;
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: none;
  padding: 0;
}
.nav-close:hover {
  background: rgba(255,255,255,0.14);
  transform: none;
  box-shadow: none;
}
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0.45rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  box-shadow: none;
  flex-shrink: 0;
}
.nav-toggle:hover {
  transform: none;
  box-shadow: none;
  border-color: var(--accent);
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--ink);
  border-radius: 2px;
}
.nav-backdrop {
  display: none;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}
.brand-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  flex-shrink: 0;
  box-shadow: 0 8px 18px rgba(232, 106, 12, 0.4);
  object-fit: cover;
}
.brand-text {
  min-width: 0;
  line-height: 1.2;
}
.brand-mark {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brass-soft);
  margin-bottom: 0.2rem;
}
.brand-sub {
  display: block;
  margin-top: 0.15rem;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--sidebar-muted);
  letter-spacing: 0.02em;
}

.nav-group {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  margin-bottom: 0.85rem;
}
.nav-label {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sidebar-muted);
  padding: 0.35rem 0.65rem 0.45rem;
  opacity: 0.85;
}

.sidebar nav a {
  position: relative;
  color: var(--sidebar-ink);
  opacity: 0.72;
  padding: 0.52rem 0.7rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  transition: opacity 0.2s ease, background 0.2s ease, transform 0.2s var(--ease-out);
}
.sidebar nav a:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  transform: translateX(2px);
}
.sidebar nav a.is-active {
  opacity: 1;
  background: linear-gradient(90deg, rgba(232, 106, 12, 0.55), rgba(232, 106, 12, 0.2));
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 178, 92, 0.2);
}
.sidebar nav a.is-active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 22%;
  bottom: 22%;
  width: 2px;
  background: linear-gradient(180deg, #ffb25c, #e86a0c);
  border-radius: 2px;
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 246, 236, 0.1);
}

.tenant-switch form { margin: 0.2rem 0; }
.tenant-switch button {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: inherit;
  padding: 0.42rem 0.55rem;
  cursor: pointer;
  font: inherit;
  font-size: 0.8rem;
  border-radius: var(--radius);
  transition: background 0.2s ease, border-color 0.2s ease;
}
.tenant-switch button:hover,
.tenant-switch button.active {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 143, 31, 0.5);
}

.main {
  padding: 1.6rem 2.35rem 2.75rem;
  animation: mainRise 0.55s var(--ease-out) both;
  position: relative;
  min-width: 0; /* grid child: allow full flex width */
  width: 100%;
}
@keyframes mainRise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.65rem;
  padding: 0.85rem 1.05rem;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-card);
  position: relative;
  z-index: 200;
}
.topbar-meta {
  font-size: 0.74rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}
.topbar-meta .plan-pill {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
  background: rgba(232, 106, 12, 0.12);
  color: var(--accent-deep);
  letter-spacing: 0.04em;
}

/* —— Buttons —— */
button,
.btn,
a.btn,
button[type="submit"] {
  font-family: var(--font-ui);
  font-size: 0.86rem;
  font-weight: 600;
  border-radius: var(--radius);
  transition: transform 0.18s var(--ease-out), background 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.logout-form button,
.auth-card button,
button[type="submit"],
.btn,
a.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  background: linear-gradient(180deg, var(--accent-mid), var(--accent));
  color: var(--accent-ink);
  border: 0;
  padding: 0.62rem 1.05rem;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(232, 106, 12, 0.28);
}
.logout-form button {
  width: 100%;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--sidebar-ink);
  box-shadow: none;
}
.logout-form button:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}
button[type="submit"]:hover,
.btn:hover,
a.btn:hover {
  background: linear-gradient(180deg, var(--accent), var(--accent-deep));
  color: var(--accent-ink);
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(232, 106, 12, 0.32);
}
.btn-ghost,
a.btn-ghost {
  background: transparent;
  color: var(--accent-deep);
  border: 1px solid var(--line);
  padding: 0.58rem 0.95rem;
  box-shadow: none;
}
.btn-ghost:hover,
a.btn-ghost:hover {
  background: var(--panel-strong);
  color: var(--accent-deep);
  border-color: var(--accent);
  box-shadow: none;
}

/* —— Auth cinematic —— */
body.auth {
  background: #140e0a;
}

.auth-main {
  min-height: 100vh;
  display: grid;
  place-items: stretch;
  padding: 0;
}

.auth-stage {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.25fr 0.85fr;
  gap: 0;
  overflow: hidden;
  animation: authIn 0.7s var(--ease-out) both;
}
@keyframes authIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.auth-hero {
  position: relative;
  min-height: 100vh;
  padding: 3rem 3.25rem 3.5rem;
  color: #eef7f3;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background:
    linear-gradient(105deg, rgba(20, 14, 10, 0.78) 0%, rgba(20, 14, 10, 0.32) 55%, rgba(192, 74, 0, 0.45) 100%),
    url("../img/login-lobby.jpg") center / cover no-repeat;
  isolation: isolate;
}
.auth-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 70% 20%, rgba(255, 143, 31, 0.22), transparent 42%),
    linear-gradient(to top, rgba(20, 14, 10, 0.78), transparent 45%);
  z-index: 0;
  pointer-events: none;
}
.auth-hero > * { position: relative; z-index: 1; }
.auth-brand-lockup {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1.25rem;
  animation: brandRise 0.85s var(--ease-out) both;
}
.auth-logo {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35);
}
.auth-brand-lockup .brand-mark {
  margin: 0;
  color: var(--brass-soft);
}
.auth-card-logo {
  margin-bottom: 1.15rem;
}
.auth-card-logo img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 10px 22px rgba(232, 106, 12, 0.3);
}
.auth-brand {
  font-size: clamp(3.2rem, 6vw, 4.6rem);
  color: #fff;
  margin: 0 0 0.65rem;
  text-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  animation: brandRise 0.85s var(--ease-out) 0.1s both;
}
@keyframes brandRise {
  from { opacity: 0; transform: translateY(18px); filter: blur(4px); }
  to { opacity: 1; transform: none; filter: none; }
}
.auth-hero p {
  margin: 0;
  max-width: 22em;
  color: rgba(238, 247, 243, 0.82);
  font-size: 1.05rem;
  line-height: 1.6;
  animation: brandRise 0.85s var(--ease-out) 0.22s both;
}
.auth-hero .brand-mark {
  color: var(--brass-soft);
  animation: brandRise 0.85s var(--ease-out) both;
}

.auth-card {
  padding: clamp(2rem, 4vw, 3.5rem) clamp(1.75rem, 3vw, 3rem);
  background:
    linear-gradient(180deg, #fffbf7, #f7f1ea);
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 1px solid rgba(255, 255, 255, 0.4);
}
.auth-card h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin-bottom: 0.2rem;
}
.auth-card label {
  display: block;
  margin: 1.05rem 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.auth-card input {
  display: block;
  width: 100%;
  margin-top: 0.45rem;
  padding: 0.8rem 0.85rem;
  border: 1px solid var(--line);
  background: #fff;
  font: inherit;
  color: var(--ink);
  border-radius: var(--radius);
  text-transform: none;
  letter-spacing: normal;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.auth-card input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(232, 106, 12, 0.16);
}
.auth-card button {
  width: 100%;
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  font-size: 0.92rem;
}

/* —— Content —— */
.messages {
  list-style: none;
  padding: 0;
  margin: 0 0 1.25rem;
}
.messages li {
  padding: 0.75rem 1rem;
  margin-bottom: 0.45rem;
  border-left: 3px solid var(--line);
  background: var(--panel-strong);
  border-radius: 0 var(--radius) var(--radius) 0;
  animation: msgIn 0.35s var(--ease-out) both;
  box-shadow: var(--shadow-card);
}
@keyframes msgIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: none; }
}
.messages .error { color: var(--danger); border-left-color: var(--danger); background: #fff6f6; }
.messages .success { color: var(--accent-deep); border-left-color: var(--accent); background: #fff5eb; }
.messages .warning { color: var(--warn); border-left-color: var(--warn); background: #fff8eb; }
.error { color: var(--danger); }

.panel,
.stat,
.board-table,
.section-card,
.room-tile {
  background: var(--panel-strong);
  border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-card);
}

.panel {
  padding: 1.2rem 1.3rem;
  margin-bottom: 1.25rem;
  border-radius: var(--radius-lg);
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.45rem;
}
.page-head h1 { margin-bottom: 0.15rem; }
.page-head .muted { margin: 0; }
.page-subtitle { margin-top: 0.25rem !important; font-size: 0.92rem; }
.page-actions { margin: 0; flex-shrink: 0; }
.page-content {
  max-width: none;
  width: 100%;
  animation: sectionIn 0.45s var(--ease-out) both;
}

/* —— Global forms (barcha sahifalar) —— */
.app-form,
.main .stack-form {
  background:
    linear-gradient(165deg, rgba(255, 253, 249, 0.98), rgba(255, 246, 236, 0.65));
  border: 1px solid rgba(232, 160, 90, 0.2);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.4rem 1.2rem;
  box-shadow: var(--shadow-card);
  max-width: 760px;
}
.app-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem 1rem;
}
.app-form-grid .form-field,
.app-form-grid p {
  margin: 0;
}
.app-form-grid .field-span-2 {
  grid-column: 1 / -1;
}
.app-form label,
.app-form-grid label,
.main .stack-form label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(60, 42, 28, 0.72);
  margin-bottom: 0.35rem;
}
.app-form input,
.app-form select,
.app-form textarea,
.main .stack-form input,
.main .stack-form select,
.main .stack-form textarea {
  display: block;
  width: 100%;
  max-width: none;
  margin-top: 0;
  padding: 0.68rem 0.8rem;
  font: inherit;
  border: 1px solid rgba(40, 28, 18, 0.12);
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
.app-form input:focus,
.app-form select:focus,
.app-form textarea:focus,
.main .stack-form input:focus,
.main .stack-form select:focus,
.main .stack-form textarea:focus {
  outline: none;
  border-color: rgba(232, 106, 12, 0.55);
  box-shadow: 0 0 0 3px rgba(255, 143, 31, 0.18);
}
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin-top: 1.1rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(40, 28, 18, 0.06);
}
.field-help {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.78rem;
  color: var(--muted);
}
.field-error {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.8rem;
  color: var(--danger);
  font-style: normal;
}
.payment-modal {
  width: min(440px, 100%);
}
.payment-modal-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin: 0 0 0.9rem;
  font-size: 0.88rem;
  color: var(--muted);
}
.payment-modal-form {
  max-width: none;
}
.payment-modal-foot {
  margin: 0.85rem 0 0;
  font-size: 0.82rem;
  color: var(--muted);
}
@media (max-width: 720px) {
  .app-form-grid {
    grid-template-columns: 1fr;
  }
}
.form-actions .btn { min-width: 7rem; }
.form-errors,
.app-form .errorlist,
.stack-form .errorlist {
  display: block;
  margin: 0.25rem 0 0;
  padding: 0;
  list-style: none;
  font-size: 0.8rem;
  color: var(--danger);
}
.form-errors {
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.85rem;
  background: rgba(179, 58, 46, 0.08);
  border-radius: var(--radius);
  border: 1px solid rgba(179, 58, 46, 0.2);
}

/* —— Filter / qidiruv panel —— */
.filter-panel {
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
}
.filter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}
.filter-form input,
.filter-form select {
  flex: 1 1 160px;
  min-width: 0;
  padding: 0.58rem 0.75rem;
  font: inherit;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
}
.filter-form input:focus,
.filter-form select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232, 106, 12, 0.12);
}
.btn-sm {
  padding: 0.52rem 0.9rem !important;
  font-size: 0.82rem !important;
}

/* —— Ro‘yxatlar (entity list) —— */
.main .list,
.entity-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.main .list li,
.entity-list .entity-row,
.entity-list > li {
  padding: 0.85rem 1rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  background: var(--panel-strong);
  box-shadow: var(--shadow-card);
  transition: border-color 0.15s ease, transform 0.15s var(--ease-out);
}
.entity-list .entity-row.guest-chip,
.main .list li.guest-chip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}
.main .list li:hover,
.entity-list .entity-row:hover {
  border-color: rgba(232, 106, 12, 0.25);
  transform: translateX(2px);
}
.main .list li:last-child,
.entity-list .entity-row:last-child { border-bottom: 1px solid var(--line-soft); }
.main .list li.muted,
.entity-list .empty-row {
  text-align: center;
  color: var(--muted);
  padding: 1.75rem 1rem;
  transform: none !important;
  background: rgba(255, 255, 255, 0.5);
}
.entity-row-main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
  margin-bottom: 0.2rem;
}
.entity-title {
  font-weight: 650;
  font-size: 0.98rem;
  color: var(--ink-soft);
}
.entity-meta {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.45;
}
.guest-chip span {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.65rem;
}

/* —— Status pills —— */
.status-pill {
  display: inline-flex;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
  background: rgba(122, 113, 104, 0.12);
  color: var(--muted);
}
.status-pill.status-confirmed,
.status-pill.status-checked_in { background: rgba(47, 138, 91, 0.14); color: var(--ok); }
.status-pill.status-inquiry { background: rgba(232, 106, 12, 0.14); color: var(--accent-deep); }
.status-pill.status-cancelled,
.status-pill.status-no_show { background: rgba(179, 58, 46, 0.12); color: var(--danger); }
.status-pill.status-checked_out { background: rgba(122, 113, 104, 0.15); color: var(--muted); }

/* —— Section panellar —— */
.main > section,
.section-panel {
  background: var(--panel-strong);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.25rem 1.2rem;
  margin-bottom: 1.15rem;
  box-shadow: var(--shadow-card);
}
.main > section .page-head {
  margin-bottom: 0.85rem;
}
.main > section .page-head h2 {
  margin: 0;
  font-size: 1.08rem;
}
.main > section .page-head a:not(.btn):not(.btn-ghost) {
  font-size: 0.86rem;
  font-weight: 600;
}

/* —— Jadval —— */
table.data,
.panel table,
.folio table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.88rem;
  background: var(--panel-strong);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
table.data th,
.panel table th,
.folio table th {
  text-align: left;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.65rem 0.85rem;
  background: rgba(240, 235, 229, 0.65);
  border-bottom: 1px solid var(--line-soft);
}
table.data td,
.panel table td,
.folio table td {
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid var(--line-soft);
  vertical-align: top;
}
table.data tr:last-child td,
.panel table tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: rgba(232, 106, 12, 0.04); }

/* —— Detail sahifalar —— */
.detail-hero {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.15rem;
}
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}
.kv-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.kv-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 0.88rem;
}
.kv-list li:last-child { border-bottom: 0; }
.kv-list span:first-child { color: var(--muted); }

/* —— Link tugmalar (page-head ichida) —— */
.page-head a.btn-ghost,
.page-head .actions a.btn-ghost {
  text-decoration: none;
}
.page-head .actions > a:not(.btn):not(.btn-ghost) {
  font-size: 0.86rem;
  font-weight: 600;
  align-self: center;
}

/* Walk-in layout to‘liq kenglik */
.page-content .walkin-layout {
  max-width: none;
}

.list { list-style: none; padding: 0; margin: 0; }
.list li {
  padding: 0.8rem 0.35rem;
  border-bottom: 1px solid var(--line-soft);
  transition: background 0.15s ease, padding-left 0.15s ease;
}
.list li:hover {
  background: rgba(232, 106, 12, 0.05);
  padding-left: 0.55rem;
}
.list li:last-child { border-bottom: 0; }

.stack-form p { margin: 0.8rem 0; }
.stack-form label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}
.stack-form input,
.stack-form select,
.stack-form textarea {
  display: block;
  width: min(460px, 100%);
  margin-top: 0.35rem;
  padding: 0.6rem 0.7rem;
  font: inherit;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.stack-form input:focus,
.stack-form select:focus,
.stack-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(232, 106, 12, 0.14);
}

.field-with-add {
  margin: 0.8rem 0;
  max-width: min(560px, 100%);
}
.field-with-add > label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}
.field-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.35rem;
}
.field-row select {
  flex: 1 1 auto;
  width: auto;
  max-width: min(460px, calc(100% - 5.5rem));
  min-width: 0;
  margin-top: 0;
}
.field-row .btn-ghost {
  flex: 0 0 auto;
  white-space: nowrap;
  padding-inline: 0.7rem;
}
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(20, 14, 10, 0.45);
  backdrop-filter: blur(2px);
}
.modal-dialog {
  width: min(420px, 100%);
  max-height: min(90vh, 640px);
  overflow: auto;
  padding: 1.15rem 1.2rem 1.25rem;
  background: var(--panel-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}
body.modal-open {
  overflow: hidden;
}
.quick-add-panel {
  margin: 1rem 0 1.5rem;
  padding: 1rem 1.1rem;
  max-width: 460px;
  background: var(--panel-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}
.quick-add-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}
.quick-add-form p { margin: 0.55rem 0; }
.quick-add-form input,
.quick-add-form select,
.quick-add-form textarea {
  width: 100%;
  max-width: none;
}

.expense-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  justify-content: flex-end;
}
.expense-actions form { margin: 0; }
.expense-actions .inline-htmx { display: inline; }
.reject-inline {
  display: inline-flex;
  gap: 0.3rem;
  align-items: center;
}
.reject-inline input {
  width: 9rem;
  font-size: 0.78rem;
  padding: 0.25rem 0.4rem;
}
.hk-task-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}
.hk-assign {
  display: inline-flex;
  gap: 0.3rem;
  align-items: center;
  margin: 0;
}
.hk-assign select {
  font-size: 0.78rem;
  max-width: 10rem;
}
.badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  margin-left: 0.35rem;
  vertical-align: middle;
}
.badge-vip {
  background: #2f5d50;
  color: #fff;
}
.badge-blacklist {
  background: #8b1e1e;
  color: #fff;
}
.alert-banner {
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  margin: 0.75rem 0 1rem;
  border: 1px solid transparent;
}
.alert-banner.blacklist {
  background: rgba(139, 30, 30, 0.08);
  border-color: rgba(139, 30, 30, 0.35);
  color: #6b1515;
}
.room-tile .badge { margin-left: 0.25rem; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem 1rem;
}
.form-grid.overrides { margin: 0.5rem 0 1rem; }
.form-grid input,
.form-grid select,
.form-grid textarea { width: 100%; }
.walkin-form .form-grid p { margin: 0.45rem 0; }

/* —— Walk-in (darhol joylash) —— */
.walkin-layout {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  gap: 1.25rem;
  align-items: start;
}
.walkin-section {
  margin-bottom: 1rem;
}
.walkin-section-title {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink-soft);
}
.walkin-fields label,
.walkin-stay-fields label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 0.35rem;
}
.walkin-layout input,
.walkin-layout select,
.walkin-layout textarea {
  display: block;
  width: 100%;
  padding: 0.62rem 0.75rem;
  font: inherit;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.walkin-layout input:focus,
.walkin-layout select:focus,
.walkin-layout textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(232, 106, 12, 0.12);
}
.walkin-fields p,
.walkin-stay-fields p {
  margin: 0;
}
.field-span-2 {
  grid-column: 1 / -1;
}
.walkin-stay-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem 1rem;
  margin-bottom: 0.75rem;
}
.walkin-date-strip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.walkin-date-chip {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.45rem 0.7rem;
  background: rgba(232, 106, 12, 0.08);
  border: 1px solid rgba(232, 106, 12, 0.2);
  border-radius: var(--radius);
  min-width: 5.5rem;
}
.walkin-date-chip small {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  font-weight: 600;
}
.walkin-date-chip strong {
  font-size: 0.95rem;
  color: var(--accent-deep);
}
.walkin-date-arrow {
  color: var(--muted);
  font-weight: 700;
}
.walkin-legend {
  margin-bottom: 0.85rem;
}
.walkin-room-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(108px, 1fr));
  gap: 0.55rem;
  margin: 0.85rem 0 0.5rem;
}
.walkin-room-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  padding: 0.65rem 0.7rem;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line-soft);
  background: linear-gradient(180deg, #fffbf7, #f8f2eb);
  text-align: left;
  font: inherit;
  color: inherit;
  min-height: 88px;
  transition: transform 0.15s var(--ease-out), border-color 0.15s ease, box-shadow 0.15s ease;
}
.walkin-room-card.is-selectable {
  cursor: pointer;
}
.walkin-room-card.is-selectable:hover {
  transform: translateY(-2px);
  border-color: rgba(232, 106, 12, 0.45);
  box-shadow: var(--shadow-card);
}
.walkin-room-card.is-selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232, 106, 12, 0.18);
  background: linear-gradient(180deg, #fff8f0, #ffeede);
}
.walkin-room-card.is-dirty {
  background: linear-gradient(180deg, #fff9ef, #f5ebe0);
  border-color: rgba(196, 122, 18, 0.35);
}
.walkin-room-card.is-occupied {
  opacity: 0.72;
  background: #f0eeeb;
  border-style: dashed;
  cursor: not-allowed;
}
.walkin-room-num {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.1;
  color: var(--ink);
}
.walkin-room-meta {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.3;
}
.walkin-room-badge {
  margin-top: auto;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.12rem 0.4rem;
  border-radius: 999px;
  background: rgba(47, 138, 91, 0.12);
  color: var(--ok);
}
.walkin-room-badge.warn {
  background: rgba(196, 122, 18, 0.15);
  color: var(--warn);
}
.walkin-room-card.is-occupied .walkin-room-badge {
  background: rgba(232, 106, 12, 0.15);
  color: var(--accent-deep);
}
.walkin-toggles {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.75rem;
}
.walkin-toggle {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  cursor: pointer;
  margin: 0;
}
.walkin-toggle input {
  margin-top: 0.35rem;
  width: auto;
  accent-color: var(--accent);
}
.walkin-toggle-box {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--panel-strong);
  flex: 1;
}
.walkin-toggle-box strong {
  font-size: 0.86rem;
  color: var(--ink-soft);
}
.walkin-toggle-box small {
  font-size: 0.75rem;
  color: var(--muted);
}
.walkin-submit-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 1rem 1.15rem;
  position: sticky;
  bottom: 0.75rem;
  z-index: 5;
}
.walkin-submit-hint {
  margin: 0;
  font-size: 0.85rem;
}
.walkin-submit-btn {
  min-width: 11rem;
  padding: 0.75rem 1.35rem;
  font-size: 0.92rem;
}
.walkin-submit-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}
.walkin-loading {
  display: none;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
}
.walkin-loading.htmx-request {
  display: flex;
}
.walkin-spinner {
  width: 1rem;
  height: 1rem;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: walkinSpin 0.7s linear infinite;
}
@keyframes walkinSpin {
  to { transform: rotate(360deg); }
}
.walkin-field-error,
.walkin-hint {
  font-size: 0.82rem;
  margin: 0.35rem 0 0;
}
.walkin-field-error {
  color: var(--danger);
}
.walkin-empty {
  text-align: center;
  padding: 2rem 1.5rem;
}
.walkin-empty p {
  margin: 0 0 1rem;
}

@media (max-width: 900px) {
  .walkin-layout {
    grid-template-columns: 1fr;
  }
  .walkin-submit-bar {
    position: static;
  }
  .walkin-submit-btn {
    width: 100%;
  }
}

@media (max-width: 560px) {
  .walkin-room-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.rate-matrix {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.4rem;
  margin: 1rem 0 1.5rem;
}
.rate-cell {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.45rem 0.5rem;
  background: #fffaf5;
  min-height: 64px;
}
.rate-cell.is-weekend { background: #f6f1ea; }
.rate-cell.is-season {
  background: rgba(232, 106, 12, 0.1);
  border-color: rgba(232, 106, 12, 0.35);
}
.rate-cell .d { font-size: 0.72rem; color: var(--muted); }
.rate-cell .p { font-weight: 650; font-size: 0.9rem; margin-top: 0.15rem; }
.rate-cell .s { font-size: 0.65rem; color: #8a4b12; margin-top: 0.15rem; }
@media (max-width: 720px) {
  .rate-matrix { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.search-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  background: var(--panel-strong);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}
.search-form input,
.search-form select {
  flex: 1 1 160px;
  min-width: 0;
  max-width: none;
  padding: 0.58rem 0.75rem;
  font: inherit;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
}
.search-form input:focus,
.search-form select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232, 106, 12, 0.12);
}

section {
  margin: 1.75rem 0;
  animation: sectionIn 0.5s var(--ease-out) both;
}
section:nth-of-type(1) { animation-delay: 0.05s; }
section:nth-of-type(2) { animation-delay: 0.1s; }
section:nth-of-type(3) { animation-delay: 0.15s; }
@keyframes sectionIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.section-card {
  padding: 1.25rem 1.35rem;
  border-radius: var(--radius-lg);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 1.15rem 0;
}

/* —— Dashboard command strip —— */
.dash-hero {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr;
  gap: 1rem;
  margin-bottom: 1.35rem;
}
.dash-hero-main {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.7rem;
  background:
    linear-gradient(135deg, rgba(20, 14, 10, 0.94), rgba(192, 74, 0, 0.82)),
    radial-gradient(circle at 90% 10%, rgba(255, 143, 31, 0.4), transparent 42%);
  color: #eef7f3;
  box-shadow: var(--shadow-soft);
  min-height: 168px;
}
.dash-hero-main h1 {
  color: #fff;
  margin: 0 0 0.4rem;
  font-size: clamp(1.9rem, 2.5vw, 2.4rem);
}
.dash-hero-main p {
  margin: 0;
  max-width: 28em;
  color: rgba(238, 247, 243, 0.78);
}
.dash-hero-main .actions { margin: 1.1rem 0 0; }
.dash-hero-main .btn {
  background: #fff;
  color: var(--accent-deep);
  box-shadow: none;
}
.dash-hero-main .btn:hover {
  background: #fffbf0;
  color: var(--accent-deep);
}
.dash-hero-main .btn-ghost {
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}
.dash-hero-main .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #fff;
  color: #fff;
}

.occ-ring-card {
  border-radius: var(--radius-lg);
  background: var(--panel-strong);
  border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-card);
  padding: 1.2rem;
  display: grid;
  place-items: center;
  gap: 0.35rem;
}
.occ-ring {
  --p: 0;
  width: 118px;
  height: 118px;
  border-radius: 50%;
  background:
    radial-gradient(closest-side, #fff 72%, transparent 73% 100%),
    conic-gradient(var(--accent) calc(var(--p) * 1%), #eadfd4 0);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--ink);
  animation: ringIn 0.9s var(--ease-out) both;
}
@keyframes ringIn {
  from { opacity: 0; transform: scale(0.86); }
  to { opacity: 1; transform: none; }
}
.occ-ring-label {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
  margin: 0 0 1.5rem;
}
.stat {
  padding: 1.05rem 1.1rem;
  border-radius: var(--radius-lg);
  position: relative;
  overflow: hidden;
  animation: statIn 0.55s var(--ease-out) both;
}
.stat::after {
  content: "";
  position: absolute;
  inset: auto -20% -40% auto;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(232, 106, 12, 0.1), transparent 70%);
  pointer-events: none;
}
.stat:nth-child(1) { animation-delay: 0.05s; }
.stat:nth-child(2) { animation-delay: 0.1s; }
.stat:nth-child(3) { animation-delay: 0.15s; }
.stat:nth-child(4) { animation-delay: 0.2s; }
@keyframes statIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
.stat span {
  display: block;
  color: var(--muted);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.stat strong {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.num,
.money {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.dash-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.pnl-line {
  font-size: 1.08rem;
  padding: 0.9rem 0 0;
  border-top: 1px solid var(--line-soft);
  margin-top: 0.55rem;
}
.guest-chip {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
}
.guest-chip .code {
  font-weight: 600;
  color: var(--accent-deep);
}
.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 0.35rem;
  background: var(--accent);
  vertical-align: middle;
}
.status-dot.warn { background: var(--warn); }
.status-dot.danger { background: var(--danger); }

.stat-delta {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  margin-top: 0.25rem;
}
.stat-delta.up { color: var(--ok, #1a7f4b); }
.stat-delta.down { color: var(--danger); }
.stat small.stat-delta { margin-top: 0.35rem; }

.ops-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
}
.ops-chip {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--line-soft);
  background: var(--surface-2, rgba(255,255,255,0.5));
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, transform 0.15s;
}
.ops-chip:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}
.ops-chip strong { font-family: var(--font-display); font-size: 1.25rem; }
.ops-chip span { font-size: 0.72rem; color: var(--muted); font-weight: 600; }
.ops-chip.warn { border-color: rgba(232, 106, 12, 0.35); }
.ops-chip.danger { border-color: color-mix(in srgb, var(--danger) 35%, transparent); }
.ops-chip.ok { border-color: color-mix(in srgb, var(--ok) 35%, transparent); }

.room-status-bar {
  display: flex;
  height: 2rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  gap: 2px;
  margin-bottom: 0.75rem;
}
.room-status-seg {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
}
.room-status-seg.status-ready { background: var(--status-ready); }
.room-status-seg.status-dirty { background: var(--status-dirty); }
.room-status-seg.status-cleaning { background: var(--status-cleaning); }
.room-status-seg.status-inspected { background: var(--status-inspected); }
.room-status-seg.status-out_of_order { background: var(--status-ooo); }
.room-status-legend {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem 1rem;
  font-size: 0.82rem;
}
.room-status-legend .dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 0.35rem;
}
.room-status-legend .dot.status-ready { background: var(--status-ready); }
.room-status-legend .dot.status-dirty { background: var(--status-dirty); }
.room-status-legend .dot.status-cleaning { background: var(--status-cleaning); }
.room-status-legend .dot.status-inspected { background: var(--status-inspected); }
.room-status-legend .dot.status-out_of_order { background: var(--status-ooo); }

.trend-chart {
  display: flex;
  align-items: flex-end;
  gap: 0.45rem;
  min-height: 9rem;
  padding-top: 0.5rem;
}
.trend-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  min-width: 0;
}
.trend-bar-wrap {
  width: 100%;
  height: 5rem;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
.trend-bar {
  width: 72%;
  max-width: 2.5rem;
  border-radius: 6px 6px 2px 2px;
  background: linear-gradient(180deg, var(--accent), var(--accent-deep));
  min-height: 4px;
}
.trend-col.is-today .trend-bar {
  box-shadow: 0 0 0 2px var(--accent-soft, rgba(232,106,12,0.3));
}
.trend-amt { font-size: 0.62rem; color: var(--muted); }
.trend-lbl { font-size: 0.68rem; color: var(--muted); font-weight: 600; }

.cod-checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1rem 0;
}
.cod-item {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--line-soft);
  background: var(--surface-2, rgba(255,255,255,0.4));
}
.cod-item.has-issues {
  border-color: rgba(232, 106, 12, 0.45);
  background: rgba(232, 106, 12, 0.04);
}
.cod-item-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}
.cod-item-head .badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background: var(--line-soft);
}
.cod-item.has-issues .badge {
  background: rgba(232, 106, 12, 0.15);
  color: var(--accent-deep);
}
.ok-line { margin: 0; font-size: 0.85rem; color: var(--ok, #1a7f4b); }

/* —— Room board tiles —— */
.board-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.board-legend span::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  margin-right: 0.35rem;
  vertical-align: -1px;
}
.leg-vacant::before { background: #e8f0ec; border: 1px solid var(--line); }
.leg-occupied::before { background: rgba(232, 106, 12, 0.85); }
.leg-dirty::before { background: var(--warn); }
.leg-ooo::before { background: #8a9090; }

.room-board {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 0.75rem;
}
.room-tile {
  border-radius: var(--radius-lg);
  padding: 0.95rem 1rem;
  min-height: 112px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s ease;
  animation: tileIn 0.45s var(--ease-out) both;
}
.room-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(26, 20, 16, 0.1);
}
.room-tile:nth-child(odd) { animation-delay: 0.03s; }
.room-tile:nth-child(3n) { animation-delay: 0.06s; }
@keyframes tileIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
.room-tile .num {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  color: var(--ink);
}
.room-tile .meta {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.15rem;
}
.room-tile .guest {
  margin-top: 0.65rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-soft);
}
.room-tile.vacant { background: linear-gradient(180deg, #fffbf7, #f3ebe3); }
.room-tile.occupied {
  background: linear-gradient(160deg, #e86a0c, #c04a00);
  color: #eef7f3;
  border-color: transparent;
}
.room-tile.occupied .num,
.room-tile.occupied .guest { color: #fff; }
.room-tile.occupied .meta { color: rgba(255, 251, 240, 0.75); }
.room-tile.occupied a { color: #fff; text-decoration: underline; text-underline-offset: 2px; }
.room-tile .tile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.45rem;
}
.tile-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.28rem 0.55rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(26, 20, 16, 0.18);
  background: rgba(255, 255, 255, 0.88);
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  line-height: 1.2;
}
/* Board actions use shared .btn scale */
.room-tile .btn,
.room-tile .btn-sm,
.room-tile a.btn {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.32rem 0.6rem;
  border-radius: var(--radius-sm);
  min-height: 0;
  line-height: 1.2;
  box-shadow: none;
}
.room-tile .btn::after { display: none; }
.room-tile .btn-ghost-tile,
.room-tile a.btn-ghost-tile {
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(26, 20, 16, 0.18);
  color: var(--ink);
}
.room-tile.occupied .btn-ghost-tile,
.room-tile.occupied a.btn-ghost-tile,
.room-tile.occupied .btn:not(.btn-warn) {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}
.room-tile.occupied .btn:not(.btn-ghost-tile):not(.btn-warn) {
  background: linear-gradient(165deg, var(--accent-mid), var(--accent-deep));
  border-color: transparent;
  color: #fff;
}
.btn-warn,
.room-tile .btn-warn,
button.btn-warn {
  background: #fff3e0;
  border: 1px solid #e08a2c;
  color: #8a3d00;
}
.room-tile.vacant .btn {
  background: linear-gradient(165deg, var(--accent-mid), var(--accent-deep));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 12px rgba(232, 106, 12, 0.3);
}
.room-tile.occupied .tile-btn {
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}
.tile-btn.warn {
  background: #fff3e0;
  border-color: #e08a2c;
  color: #8a3d00;
}
.tile-btn.primary,
button.tile-btn.primary {
  background: var(--accent);
  border-color: var(--accent-deep);
  color: #fff;
}
.room-tile.occupied .tile-btn.primary {
  background: #fff;
  color: var(--accent-deep);
  border-color: #fff;
}
.tile-balance {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  margin: 0.2rem 0 0.35rem;
}
.tile-balance.warn { color: #ffd4a8; }
.room-tile form { margin: 0; display: inline; }
button.tile-btn {
  font: inherit;
  appearance: none;
}
.guest-chip.is-void {
  opacity: 0.55;
  text-decoration: line-through;
}
.void-inline {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  margin-top: 0.35rem;
  width: 100%;
}
.void-inline input {
  flex: 1;
  min-width: 0;
  font-size: 0.8rem;
  padding: 0.25rem 0.45rem;
}
.void-inline button {
  font-size: 0.75rem;
  padding: 0.25rem 0.55rem;
}
.room-tile.dirty {
  background: linear-gradient(180deg, #fff9ef, #f7e8c9);
  box-shadow: inset 0 0 0 1px rgba(154, 106, 26, 0.25), var(--shadow-card);
}
.room-tile.ooo {
  background: #eceeed;
  opacity: 0.72;
  filter: grayscale(0.35);
}

.board-table {
  width: 100%;
  border-collapse: collapse;
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.board-table th,
.board-table td {
  border-bottom: 1px solid var(--line-soft);
  padding: 0.75rem 0.65rem;
  text-align: left;
}
.board-table th {
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  background: var(--panel);
}
.board-table tr.occupied { background: rgba(232, 106, 12, 0.08); }
.board-table tr.status-dirty td:first-child {
  box-shadow: inset 3px 0 0 var(--warn);
}
.board-table tr.status-out_of_order { opacity: 0.6; }

.calendar-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line-soft);
  background: var(--panel-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}
.calendar-table th,
.calendar-table td {
  min-width: 54px;
  font-size: 0.8rem;
  text-align: center;
}
.calendar-table td:first-child,
.calendar-table th:first-child {
  text-align: left;
  min-width: 72px;
  position: sticky;
  left: 0;
  z-index: 2;
  background: var(--panel-strong);
  box-shadow: 4px 0 8px rgba(26, 20, 16, 0.04);
}

.availability {
  margin: 0.75rem 0;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-lg);
  font-size: 0.92rem;
}
.availability.ok {
  background: #fff5eb;
  color: var(--accent-deep);
  border: 1px solid rgba(232, 106, 12, 0.22);
}
.availability.bad {
  background: #fff5f5;
  color: var(--danger);
  border: 1px solid rgba(180, 50, 50, 0.18);
}
.lang-switch select {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.25rem 0.45rem;
  font: inherit;
  color: inherit;
}
.htmx-indicator { opacity: 0; transition: opacity 200ms; }
.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator { opacity: 1; }

/* —— SPA navigatsiya (React uslubi) —— */
.spa-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 9999;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    transparent 0%,
    var(--accent) 35%,
    var(--accent-deep) 65%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: spaProgress 0.9s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(232, 106, 12, 0.45);
}
@keyframes spaProgress {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}
#spa-root {
  min-height: 2rem;
  transition: opacity 0.18s ease, transform 0.18s var(--ease-out);
}
#spa-root.spa-loading {
  opacity: 0.72;
  transform: translateY(4px);
}
#spa-root.htmx-settling {
  opacity: 1;
  transform: none;
}
@supports (view-transition-name: root) {
  #spa-root { view-transition-name: spa-content; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}


/* —— Folio summary / notifications / HK —— */
.folio-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.folio-summary .stat.warn {
  border-color: rgba(196, 122, 18, 0.35);
  background: linear-gradient(180deg, #fffaf0, #fff);
}
.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}
.notify-panel { position: relative; z-index: 1; }
.notify-panel[open] { z-index: 2; }
.notify-panel > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.35rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  box-shadow: none;
}
.notify-panel > summary::-webkit-details-marker { display: none; }
.notify-count {
  display: inline-grid;
  place-items: center;
  min-width: 1.15rem;
  height: 1.15rem;
  margin-left: 0.25rem;
  padding: 0 0.25rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.68rem;
}
.notify-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 0.45rem);
  width: min(320px, 80vw);
  background: #fff;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  z-index: 210;
  max-height: 360px;
  overflow: auto;
  padding: 0.35rem 0;
}
.notify-item {
  display: block;
  padding: 0.65rem 0.85rem;
  color: var(--ink);
  border-left: 3px solid transparent;
}
.notify-item:hover { background: rgba(232, 106, 12, 0.06); }
.notify-item strong { display: block; font-size: 0.86rem; }
.notify-item span { display: block; font-size: 0.78rem; color: var(--muted); }
.notify-item.kind-arrival { border-left-color: var(--ok); }
.notify-item.kind-web_booking { border-left-color: #2563eb; }
.notify-item.kind-departure { border-left-color: var(--warn); }
.notify-item.kind-overdue { border-left-color: var(--danger); }

.hk-board .hk-form {
  display: flex;
  gap: 0.35rem;
  margin-top: 0.65rem;
  align-items: center;
}
.hk-board .hk-form select {
  flex: 1;
  font: inherit;
  font-size: 0.78rem;
  padding: 0.35rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}
.hk-board .hk-form .btn-ghost {
  padding: 0.35rem 0.55rem;
  font-size: 0.75rem;
  box-shadow: none;
}

.hk-board-touch .hk-tile {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  min-height: 11rem;
}
.hk-quick-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.4rem;
  margin-top: auto;
}
.hk-touch-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.5rem 0.35rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--line-soft);
  background: var(--surface-2, #fff);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
}
.hk-touch-btn.ok {
  background: rgba(26, 127, 75, 0.12);
  border-color: rgba(26, 127, 75, 0.45);
  color: #1a7f4b;
}
.hk-touch-btn.warn {
  background: rgba(232, 106, 12, 0.1);
  border-color: rgba(232, 106, 12, 0.45);
  color: var(--accent-deep);
}
.hk-touch-btn.danger {
  background: rgba(198, 40, 40, 0.08);
  border-color: rgba(198, 40, 40, 0.4);
  color: #c62828;
}
.hk-maint-panel summary {
  list-style: none;
  cursor: pointer;
}
.hk-maint-panel summary::-webkit-details-marker { display: none; }
.hk-maint-form {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.45rem;
}
.hk-maint-form input[type="text"] {
  width: 100%;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font: inherit;
}
.hk-check {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
}
.hk-task-list .hk-touch-btn {
  min-width: 5.5rem;
}
.minibar-quick-card {
  max-width: 28rem;
}
.minibar-quick-form input,
.minibar-quick-form select {
  font-size: 1.05rem;
  padding: 0.75rem 0.85rem;
}
.minibar-quick-form .btn-lg,
button.btn-lg {
  min-height: 3rem;
  font-size: 1rem;
  font-weight: 700;
  width: 100%;
}
.checkout-balance {
  font-size: 1.05rem;
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  background: var(--surface-2, rgba(255,255,255,0.5));
}
.checkout-balance.warn { border: 1px solid rgba(232, 106, 12, 0.45); }
.checkout-balance.ok { border: 1px solid rgba(26, 127, 75, 0.45); }
.checkout-modal .btn { width: 100%; margin-top: 0.5rem; }

.calendar-table td.occupied {
  background: rgba(232, 106, 12, 0.16);
  font-weight: 600;
}

.leg-cal-confirmed::before { background: #c4a574; }
.leg-cal-inhouse::before { background: rgba(232, 106, 12, 0.85); }
.leg-cal-vip::before { background: #2f5d50; }

.calendar-table td.cal-bar {
  padding: 0.2rem 0.35rem;
  vertical-align: middle;
}
.calendar-table td.cal-bar a {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  text-decoration: none;
  color: inherit;
  min-height: 2.4rem;
  justify-content: center;
  padding: 0.25rem 0.4rem;
  border-radius: 8px;
}
.calendar-table td.cal-bar .cal-name {
  font-weight: 650;
  font-size: 0.82rem;
  line-height: 1.15;
}
.calendar-table td.cal-bar .cal-code {
  font-size: 0.68rem;
  opacity: 0.75;
}
.calendar-table td.cal-bar.status-confirmed a {
  background: rgba(196, 165, 116, 0.35);
  color: #5a3d12;
}
.calendar-table td.cal-bar.status-inquiry a {
  background: rgba(140, 150, 160, 0.25);
  color: #3a4450;
}
.calendar-table td.cal-bar.status-checked_in a {
  background: rgba(232, 106, 12, 0.88);
  color: #fff;
}
.calendar-table td.cal-bar.status-checked_out a {
  background: rgba(90, 100, 100, 0.2);
  color: #445;
}
.calendar-table td.cal-bar.is-vip a {
  box-shadow: inset 0 0 0 1.5px #2f5d50;
}
.calendar-table td.cal-empty {
  text-align: center;
  padding: 0.15rem;
}
.calendar-table td.cal-empty .cal-new {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 999px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.15s ease, background 0.15s ease;
}
.calendar-table tr:hover td.cal-empty .cal-new,
.calendar-table td.cal-empty:hover .cal-new {
  opacity: 1;
  background: rgba(232, 106, 12, 0.12);
  color: var(--accent, #e86a0c);
}

.cod-preview .list.compact li {
  padding: 0.2rem 0;
  border: 0;
}

.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0.75rem 0 1.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line-soft);
  background: var(--panel-strong);
}
.table-scroll table {
  margin: 0;
  min-width: 640px;
}

/* —— Responsive / mobile —— */
@media (max-width: 1100px) {
  .folio-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .app-shell { grid-template-columns: 1fr; }

  .nav-toggle { display: inline-flex; }
  .nav-close { display: inline-flex; align-items: center; justify-content: center; }

  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(20, 14, 10, 0.48);
    backdrop-filter: blur(2px);
    border: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
    box-shadow: none;
  }
  .nav-backdrop[hidden] { display: none !important; }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 90;
    width: min(300px, 88vw);
    height: 100dvh;
    max-height: 100dvh;
    transform: translateX(-105%);
    transition: transform 0.28s var(--ease-out);
    box-shadow: 18px 0 40px rgba(0, 0, 0, 0.28);
  }
  .app-shell.nav-open .sidebar { transform: translateX(0); }
  body.nav-lock { overflow: hidden; }

  .sidebar nav {
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow-y: auto;
    flex: 1;
    padding-bottom: 1rem;
  }
  .nav-group { margin-bottom: 0.65rem; }

  .main {
    padding: 0.85rem 0.9rem 2rem;
    width: 100%;
    min-width: 0;
  }

  .topbar {
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-bottom: 1rem;
    padding: 0.65rem 0.75rem;
    position: sticky;
    top: 0.35rem;
    z-index: 200;
  }
  .topbar-left { flex: 1; min-width: 0; }
  .topbar-right {
    width: 100%;
    justify-content: space-between;
    gap: 0.5rem;
  }
  .notify-label { display: none; }
  .notify-bell {
    min-width: 2.5rem;
    justify-content: center;
  }
  .notify-dropdown {
    right: auto;
    left: 0;
    width: min(300px, calc(100vw - 2rem));
  }
  .lang-switch {
    margin-left: auto;
    font-size: 0.7rem;
  }

  h1 { font-size: clamp(1.55rem, 6vw, 2rem); }
  .page-head {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  .page-head .actions,
  .actions {
    width: 100%;
  }
  .page-head .actions > *,
  .actions > .btn,
  .actions > a.btn,
  .actions > a.btn-ghost,
  .actions > form {
    flex: 1 1 auto;
  }
  .page-head .actions button,
  .page-head .actions .btn,
  .page-head .actions a,
  .actions button,
  .actions .btn,
  .actions a.btn,
  .actions a.btn-ghost {
    width: 100%;
  }

  .auth-stage {
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column-reverse; /* forma yuqorida, marketing pastida */
  }
  .auth-hero {
    min-height: auto;
    padding: 1.5rem;
    max-height: none;
  }
  .auth-card {
    flex: 0 0 auto;
  }
  .auth-features,
  .auth-hero-desc {
    display: none;
  }
  .dash-hero { grid-template-columns: 1fr; }
  .dash-hero-main { padding: 1.25rem 1.15rem; min-height: 0; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.65rem; }
  .stat { padding: 0.85rem 0.9rem; }
  .stat strong { font-size: 1.35rem; }
  .dash-columns { grid-template-columns: 1fr; }
  .ops-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cod-checklist { grid-template-columns: 1fr; }
  .room-status-legend { grid-template-columns: 1fr; }
  .folio-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .room-board {
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 0.6rem;
  }
  .room-tile { min-height: 100px; padding: 0.8rem; }
  .room-tile .num { font-size: 1.25rem; }

  .guest-chip {
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
  }
  .guest-chip .expense-actions,
  .guest-chip .hk-task-actions {
    justify-content: flex-start;
  }
  .expense-actions,
  .hk-task-actions {
    width: 100%;
  }
  .reject-inline {
    flex-wrap: wrap;
    width: 100%;
  }
  .reject-inline input { width: 100%; max-width: none; }
  .hk-assign {
    flex-wrap: wrap;
    width: 100%;
  }
  .hk-assign select { max-width: none; flex: 1; }

  .search-form {
    flex-direction: column;
  }
  .search-form input,
  .search-form select {
    max-width: none;
    width: 100%;
  }
  .stack-form input,
  .stack-form select,
  .stack-form textarea {
    width: 100%;
    max-width: none;
  }
  .field-with-add {
    max-width: none;
  }
  .field-row {
    flex-wrap: wrap;
  }
  .field-row select {
    width: 100%;
    max-width: none;
    flex: 1 1 100%;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }

  .section-card { padding: 1rem; }
  .list li { padding: 0.75rem 0.15rem; }

  .calendar-table,
  table.data,
  .folio table,
  .panel table {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .messages { font-size: 0.88rem; }
  .money { white-space: normal; word-break: break-word; }
}

/* —— Kassa smena —— */
.cash-shift-page .cash-shift-live-head {
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
}
.cash-shift-expected {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.15rem;
  min-width: min(100%, 14rem);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(192, 74, 0, 0.08), rgba(26, 20, 16, 0.03));
  border: 1px solid rgba(192, 74, 0, 0.18);
}
.cash-shift-expected-inline {
  align-items: flex-start;
  max-width: 28rem;
}
.cash-shift-expected-lbl {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted, #7a7168);
}
.cash-shift-expected-val {
  font-size: 1.45rem;
  line-height: 1.2;
}
.cash-shift-formula {
  font-size: 0.75rem;
  text-align: right;
  max-width: 16rem;
}
.cash-shift-expected-inline .cash-shift-formula { text-align: left; }
.cash-shift-status-pill {
  display: inline-block;
  margin: 0;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ok) 14%, transparent);
  color: var(--ok);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
}
.cash-shift-stats { margin: 1rem 0 1.25rem; }
.cash-shift-charts { margin-bottom: 1.25rem; }
.cash-shift-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 0.25rem;
}
.cash-shift-card {
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px solid rgba(26, 20, 16, 0.08);
  background: rgba(255, 255, 255, 0.55);
}
.cash-shift-card h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}
.cash-shift-card-hint {
  margin: 0 0 0.85rem;
  font-size: 0.88rem;
}
.cash-shift-mini-list { margin-top: 0.85rem; }
.cash-shift-kind {
  font-weight: 600;
  font-size: 0.85rem;
}
.cash-shift-kind-pay_in { color: var(--ok); }
.cash-shift-kind-pay_out { color: var(--danger); }
.cash-shift-variance-live {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
  padding: 0.55rem 0.75rem;
  border-radius: 10px;
  background: rgba(26, 20, 16, 0.04);
  font-size: 0.92rem;
}
.cash-shift-variance-live.is-plus,
.cash-shift-var.is-plus { color: var(--ok); }
.cash-shift-variance-live.is-minus,
.cash-shift-var.is-minus { color: var(--danger); }
.cash-shift-variance-live.is-zero,
.cash-shift-var.is-zero { color: var(--muted); }
.cash-shift-close-card .btn-danger-soft {
  background: linear-gradient(135deg, #c04a00, #8a3200);
}
.cash-shift-open-layout {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
  align-items: start;
}
.cash-shift-checklist {
  margin: 0.85rem 0 0;
  padding-left: 1.1rem;
  font-size: 0.9rem;
}
.cash-shift-checklist li { margin: 0.25rem 0; }
.cash-shift-open-form {
  padding: 1rem 1.1rem;
  border-radius: 14px;
  border: 1px solid rgba(26, 20, 16, 0.08);
  background: rgba(255, 255, 255, 0.6);
  max-width: none;
  box-shadow: none;
}
.cash-shift-history-chart { margin-bottom: 1rem; }
.cash-shift-history-meta {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  justify-content: flex-end;
}
.cash-shift-detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: -0.35rem 0 1rem;
}
@media (max-width: 900px) {
  .cash-shift-grid,
  .cash-shift-open-layout {
    grid-template-columns: 1fr;
  }
  .cash-shift-expected {
    align-items: flex-start;
    width: 100%;
  }
  .cash-shift-formula { text-align: left; }
}

@media (max-width: 560px) {
  .stats-grid,
  .folio-summary {
    grid-template-columns: 1fr 1fr;
  }
  .room-board {
    grid-template-columns: 1fr 1fr;
  }
  .topbar-meta .role-label { display: none; }
  .dash-hero-main .actions {
    flex-direction: column;
  }
  .dash-hero-main .actions .btn,
  .dash-hero-main .actions .btn-ghost {
    width: 100%;
  }
  .rate-matrix { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .board-legend { font-size: 0.68rem; gap: 0.5rem; }
  .tile-btn { width: 100%; }
  .room-tile .tile-actions { flex-direction: column; }
  .auth-card { padding: 1.35rem 1.15rem; margin: 0 0.75rem 1.5rem; }
  .auth-hero { padding: 1.35rem 1.15rem 1rem; }
  .main {
    padding-bottom: calc(2rem + env(safe-area-inset-bottom, 0px));
  }
  .sidebar {
    padding-bottom: calc(1.35rem + env(safe-area-inset-bottom, 0px));
  }
}
