:root {
  --bg: #111111;
  --bg-soft: #171717;
  --panel: #1d1d1d;
  --line: #2e2a20;
  --text: #f7f2e8;
  --muted: #a88f59;
  --muted-soft: #7a6740;
  --gold: #c9a84c;
  --gold-strong: #e3c26c;
  --danger: #ff8972;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.3);
  --radius-xl: 28px;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(201, 168, 76, 0.18), transparent 32%),
    radial-gradient(circle at top right, rgba(84, 113, 255, 0.12), transparent 28%),
    linear-gradient(180deg, #111111 0%, #151515 50%, #101010 100%);
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }

input[type="date"],
input[type="time"] {
  color-scheme: dark;
}

input[type="date"]::-webkit-calendar-picker-indicator,
input[type="time"]::-webkit-calendar-picker-indicator {
  filter: invert(79%) sepia(40%) saturate(521%) hue-rotate(7deg) brightness(96%) contrast(91%);
  opacity: 1;
  cursor: pointer;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 24px 18px;
  border-right: 1px solid rgba(201, 168, 76, 0.12);
  background: rgba(14, 14, 14, 0.92);
  backdrop-filter: blur(20px);
}

.brand {
  display: grid;
  gap: 6px;
  padding: 10px 12px 24px;
}

.brand-sidebar {
  gap: 14px;
}

.brand-logo {
  width: 58px;
  height: 58px;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 16px 30px rgba(201, 168, 76, 0.22));
}

.brand-logo-sidebar {
  width: 100%;
  max-width: 280px;
  height: auto;
}

.brand h1 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-size: 2.15rem;
  font-weight: 600;
}

.brand p,
.subtle {
  margin: 0;
  color: var(--muted-soft);
  font-size: 0.92rem;
}

.nav { display: grid; gap: 8px; margin-top: 10px; }

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 15px;
  border: 1px solid transparent;
  border-radius: 16px;
  color: #d7c5a0;
  transition: 180ms ease;
}

.nav-link:hover,
.nav-link.active {
  color: #17120b;
  background: linear-gradient(135deg, var(--gold-strong), #ad8737);
  border-color: rgba(255, 239, 188, 0.18);
  box-shadow: 0 10px 24px rgba(201, 168, 76, 0.18);
}

.nav-icon { width: 18px; text-align: center; }

.sidebar-foot {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 20px;
  display: grid;
  gap: 14px;
}

.role-switch {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 12px;
  background: rgba(27, 27, 27, 0.75);
}

.role-switch label {
  display: block;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted-soft);
  margin-bottom: 8px;
}

.role-switch select,
.input,
.textarea {
  width: 100%;
  border: 1px solid rgba(201, 168, 76, 0.16);
  border-radius: 14px;
  background: rgba(11, 11, 11, 0.75);
  color: var(--text);
  padding: 12px 14px;
}

.content { min-width: 0; padding: 28px; }
.page { display: grid; gap: 18px; }

.hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 22px;
}

.hero-title {
  margin: 0;
  font-size: clamp(2rem, 3vw, 3rem);
  line-height: 1;
  letter-spacing: -0.04em;
}

.hero p { margin-top: 10px; max-width: 58ch; }

.hero-actions,
.stack,
.inline-actions,
.filters,
.mobile-tabs,
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn,
.ghost-btn,
.chip {
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 11px 16px;
  transition: 160ms ease;
}

.btn {
  color: #17120b;
  background: linear-gradient(135deg, var(--gold-strong), #b88f35);
  box-shadow: 0 14px 30px rgba(201, 168, 76, 0.22);
}

.ghost-btn,
.chip {
  color: #dcc696;
  background: rgba(31, 31, 31, 0.75);
  border-color: rgba(201, 168, 76, 0.16);
}

.active-login {
  color: #18120b;
  background: linear-gradient(135deg, #f0d284, #c4993c);
}

.chip.active {
  color: #18120b;
  background: linear-gradient(135deg, #f0d284, #c4993c);
}

.panel {
  background: linear-gradient(180deg, rgba(28, 28, 28, 0.9), rgba(22, 22, 22, 0.96));
  border: 1px solid rgba(201, 168, 76, 0.1);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  margin-bottom: 18px;
}

.calendar-shell { overflow: hidden; }
.calendar-grid { display: grid; grid-template-columns: 96px repeat(7, minmax(140px, 1fr)); min-width: 980px; }
.calendar-scroll { overflow-x: auto; }

.calendar-grid > div {
  border-right: 1px solid rgba(201, 168, 76, 0.08);
  border-bottom: 1px solid rgba(201, 168, 76, 0.08);
}

.calendar-grid > div:nth-child(8n) { border-right: 0; }

.month-grid-wrap {
  overflow-x: auto;
}

.month-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(140px, 1fr));
  min-width: 980px;
}

.month-head {
  padding: 14px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted-soft);
  background: rgba(16, 16, 16, 0.9);
  border-right: 1px solid rgba(201, 168, 76, 0.08);
  border-bottom: 1px solid rgba(201, 168, 76, 0.08);
}

.month-head:last-child {
  border-right: 0;
}

.month-cell {
  min-height: 150px;
  padding: 12px;
  background: rgba(20, 20, 20, 0.82);
  border-right: 1px solid rgba(201, 168, 76, 0.08);
  border-bottom: 1px solid rgba(201, 168, 76, 0.08);
  cursor: pointer;
}

.month-cell-today {
  background:
    linear-gradient(180deg, rgba(240, 210, 132, 0.12), transparent 48%),
    rgba(28, 24, 14, 0.96);
  box-shadow: inset 0 0 0 1px rgba(240, 210, 132, 0.45);
}

.month-cell-muted {
  opacity: 0.45;
}

.month-cell-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.month-cell-top strong {
  font-size: 1rem;
}

.month-cell-top span {
  font-size: 0.72rem;
  color: var(--muted-soft);
}

.month-bookings {
  display: grid;
  gap: 8px;
}

.month-booking-pill {
  width: 100%;
  text-align: left;
  padding: 9px 10px;
  border-radius: 12px;
  border-top: 1px solid rgba(201, 168, 76, 0.1);
  border-right: 1px solid rgba(201, 168, 76, 0.1);
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
  background: rgba(11, 11, 11, 0.72);
  color: var(--text);
}

.month-booking-pill span,
.month-booking-pill small {
  display: block;
}

.month-booking-pill small {
  margin-top: 4px;
  color: var(--muted);
}

.month-more {
  font-size: 0.78rem;
}

.slot-header,
.time-cell,
.slot-cell { min-height: 86px; position: relative; }

.slot-header { padding: 18px 14px; background: rgba(16, 16, 16, 0.9); }
.slot-header strong { display: block; font-size: 0.95rem; }
.slot-header span { color: var(--muted-soft); font-size: 0.82rem; }
.slot-header-today {
  background:
    linear-gradient(180deg, rgba(240, 210, 132, 0.18), rgba(16, 16, 16, 0.92));
  box-shadow: inset 0 -2px 0 rgba(240, 210, 132, 0.7);
}
.slot-header-today span,
.month-cell-today .month-cell-top span {
  color: #f0d284;
}
.time-cell { padding: 12px 14px; color: var(--muted-soft); font-size: 0.82rem; background: rgba(17, 17, 17, 0.86); }

.slot-cell {
  padding: 10px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.01), transparent),
    rgba(20, 20, 20, 0.82);
}

.slot-cell:hover { background: rgba(29, 29, 29, 0.92); }

.slot-cell-clickable {
  cursor: pointer;
}

.booking-card {
  border-radius: 18px;
  padding: 12px 13px;
  min-height: 66px;
  color: #fff;
  box-shadow: 0 16px 24px rgba(0, 0, 0, 0.18);
}

.booking-card-clickable {
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.booking-card-clickable:hover {
  transform: translateY(-1px);
  box-shadow: 0 20px 28px rgba(0, 0, 0, 0.24);
}

.booking-card h4,
.summary-card h3,
.table-title,
.metric-card h3,
.list-item h4,
.list-item p {
  margin: 0;
}

.booking-card h4 { font-size: 0.9rem; margin-bottom: 8px; }
.booking-card p, .booking-card small { margin: 0; opacity: 0.9; }

.grid-2,
.metrics-grid {
  display: grid;
  gap: 18px;
}

.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.metrics-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.summary-card,
.metric-card,
.table-panel,
.list-panel,
.empty-state,
.form-panel { padding: 20px; }

.metric-card { position: relative; overflow: hidden; }
.metric-card::after {
  content: "";
  position: absolute;
  inset: auto -40px -40px auto;
  width: 120px;
  height: 120px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(201, 168, 76, 0.18), transparent 70%);
}

.eyebrow {
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted-soft);
}

.metric-value {
  margin-top: 10px;
  font-size: clamp(2rem, 4vw, 2.7rem);
  font-weight: 800;
  letter-spacing: -0.05em;
}

.room-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(15, 15, 15, 0.72);
  border: 1px solid rgba(201, 168, 76, 0.1);
}

.dot { width: 10px; height: 10px; border-radius: 999px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }

th,
td {
  padding: 14px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(201, 168, 76, 0.08);
}

th {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted-soft);
}

td { color: #e7dcc1; font-size: 0.94rem; }
.soft { color: var(--muted); }
.bars { display: grid; gap: 12px; }

.bar-row {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  align-items: center;
  gap: 14px;
}

.bar-track {
  height: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 999px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #f2d688, #c19337);
}

.list { display: grid; gap: 12px; }

.list-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(15, 15, 15, 0.62);
  border: 1px solid rgba(201, 168, 76, 0.08);
}

.list-item p { margin-top: 6px; color: var(--muted); }

.badge {
  display: inline-flex;
  align-items: center;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  color: #18120b;
  background: linear-gradient(135deg, #ebcb75, #be9034);
  white-space: nowrap;
}

.empty-state { text-align: center; color: var(--muted-soft); }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.field { display: grid; gap: 8px; }
.field label { color: var(--muted); font-size: 0.85rem; }
.field.full { grid-column: 1 / -1; }
.textarea { min-height: 96px; resize: vertical; }

.notice {
  padding: 14px 16px;
  border-radius: 16px;
  color: #f5d7cf;
  background: rgba(145, 54, 25, 0.18);
  border: 1px solid rgba(255, 137, 114, 0.18);
}

.mobile-topbar { display: none; }

@media (max-width: 1100px) {
  .grid-2,
  .metrics-grid { grid-template-columns: 1fr; }
}

@media (max-width: 920px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { display: none; }

  .mobile-topbar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: grid;
    gap: 12px;
    margin: -28px -28px 22px;
    padding: 18px 18px 16px;
    background: rgba(14, 14, 14, 0.94);
    border-bottom: 1px solid rgba(201, 168, 76, 0.12);
    backdrop-filter: blur(16px);
  }

  .mobile-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
  }

  .mobile-tabs::-webkit-scrollbar {
    height: 6px;
  }

  .mobile-tabs::-webkit-scrollbar-thumb {
    background: rgba(201, 168, 76, 0.24);
    border-radius: 999px;
  }

  .brand-logo {
    width: 70px;
    height: auto;
  }

  .content { padding: 28px 16px; }
  .hero { flex-direction: column; }
  .toolbar { flex-direction: column; }
  .hero-actions,
  .toolbar .inline-actions,
  .toolbar .filters,
  .toolbar .stack {
    width: 100%;
  }

  .calendar-grid {
    grid-template-columns: 72px repeat(7, minmax(96px, 1fr));
    min-width: 760px;
  }

  .month-grid {
    grid-template-columns: repeat(7, minmax(96px, 1fr));
    min-width: 760px;
  }

  .month-cell {
    min-height: 124px;
    padding: 10px;
  }

  .slot-header,
  .time-cell,
  .slot-cell {
    min-height: 74px;
  }
}

@media (max-width: 640px) {
  .content { padding: 18px 12px; }
  .mobile-topbar {
    margin: -18px -12px 18px;
    padding: 14px 12px 12px;
  }

  .brand h1 {
    font-size: 1.6rem;
  }

  .brand-logo {
    width: 58px;
  }

  .hero-title {
    font-size: 1.7rem;
  }

  .panel,
  .summary-card,
  .metric-card,
  .table-panel,
  .list-panel,
  .empty-state,
  .form-panel {
    border-radius: 22px;
  }

  .form-grid { grid-template-columns: 1fr; }
  .bar-row { grid-template-columns: 1fr; }
  .list-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .calendar-grid {
    grid-template-columns: 58px repeat(7, minmax(84px, 1fr));
    min-width: 650px;
  }

  .month-grid {
    grid-template-columns: repeat(7, minmax(84px, 1fr));
    min-width: 650px;
  }

  .month-head {
    padding: 10px 6px;
    font-size: 0.68rem;
    letter-spacing: 0.08em;
  }

  .month-cell {
    min-height: 108px;
    padding: 8px;
  }

  .month-cell-top {
    margin-bottom: 8px;
  }

  .month-booking-pill {
    padding: 7px 8px;
    font-size: 0.78rem;
  }

  .slot-header,
  .time-cell,
  .slot-cell {
    min-height: 68px;
  }

  .slot-header,
  .time-cell {
    padding: 10px 8px;
  }

  .slot-cell {
    padding: 8px;
  }

  .booking-card {
    min-height: 58px;
    padding: 10px;
  }

  .booking-card h4 {
    font-size: 0.8rem;
    margin-bottom: 6px;
  }

  th,
  td {
    padding: 12px 6px;
    font-size: 0.84rem;
  }

  .dialog-backdrop {
    padding: 10px;
  }

  .dialog-panel {
    padding: 16px;
    width: 100%;
    max-height: 92vh;
  }

  .dialog-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .action-cell {
    white-space: normal;
  }
}
.admin-list {
  display: grid;
  gap: 14px;
}

.admin-card {
  padding: 18px;
  border-radius: 18px;
  background: rgba(15, 15, 15, 0.62);
  border: 1px solid rgba(201, 168, 76, 0.08);
}

.admin-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.admin-card-header h4 {
  margin: 0;
}

.admin-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.room-admin-grid {
  grid-template-columns: 1fr;
}

.auth-panel {
  max-width: 720px;
  padding: 24px;
}

.dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(8px);
}

.dialog-panel {
  width: min(760px, 100%);
  max-height: 90vh;
  overflow: auto;
  padding: 22px;
}

.dialog-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.action-cell {
  white-space: nowrap;
}

.small-btn {
  padding: 8px 12px;
  font-size: 0.8rem;
}

.danger-btn {
  border-color: rgba(255, 137, 114, 0.22);
  color: #f5c1b3;
}

@media (max-width: 920px) {
  .admin-grid {
    grid-template-columns: 1fr;
  }
}
