/* =========================================
   HOUSE SHEGER — ADMIN CSS
   Extends the tokens defined in ../styles.css
   ========================================= */

body.admin-body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
}

/* ---------- LOGIN SCREEN ---------- */

.login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

.login-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, var(--gold-dim), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(212, 175, 55, .08), transparent 45%);
  pointer-events: none;
}

.login-card {
  position: relative;
  width: 100%;
  max-width: 400px;
  padding: 48px 40px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5);
  opacity: 0;
  transform: translateY(24px);
  animation: loginIn .8s var(--ease-luxury) forwards;
}

@keyframes loginIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-logo {
  text-align: center;
  font-family: var(--serif);
  font-weight: 300;
  font-size: 28px;
  letter-spacing: -.01em;
  margin-bottom: 6px;
}

.login-logo em {
  color: var(--gold);
  font-style: normal;
}

.login-sub {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: .05em;
  margin-bottom: 36px;
}

.login-field {
  margin-bottom: 18px;
}

.login-field label {
  display: block;
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.login-field input {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, .03);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  font-size: 15px;
  font-family: var(--sans);
  transition: border-color .3s var(--ease-luxury), background .3s;
}

.login-field input:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(212, 175, 55, .05);
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 46px;
}

.pw-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  border-radius: 8px;
  transition: color .25s;
}

.pw-toggle:hover {
  color: var(--ink);
}

.pw-toggle.active {
  color: var(--gold);
}

.login-btn {
  width: 100%;
  margin-top: 8px;
  padding: 15px;
  background: var(--gold);
  color: #000;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  border-radius: 10px;
  cursor: pointer;
  transition: all .3s var(--ease-luxury);
  position: relative;
  overflow: hidden;
}

.login-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 30px var(--gold-glow);
}

.login-btn:active {
  transform: translateY(0);
}

.login-btn:disabled {
  opacity: .6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.login-error {
  margin-top: 16px;
  padding: 12px 14px;
  background: rgba(220, 60, 60, .1);
  border: 1px solid rgba(220, 60, 60, .3);
  border-radius: 10px;
  color: #ff8a8a;
  font-size: 13px;
  text-align: center;
  display: none;
}

.login-error.show {
  display: block;
  animation: shake .4s var(--ease-luxury);
}

@keyframes shake {

  0%,
  100% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-6px);
  }

  75% {
    transform: translateX(6px);
  }
}

.login-back {
  display: block;
  text-align: center;
  margin-top: 28px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .05em;
  transition: color .3s;
}

.login-back:hover {
  color: var(--gold);
}

/* ---------- DASHBOARD SHELL ---------- */

.dash {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

.dash-sidebar {
  background: var(--bg-2);
  border-right: 1px solid var(--line);
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}

.dash-logo {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 300;
  padding: 0 12px 28px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}

.dash-logo em {
  color: var(--gold);
  font-style: normal;
}

.dash-logo small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-family: var(--sans);
  margin-top: 4px;
}

.dash-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.dash-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  color: var(--muted);
  font-size: 13.5px;
  letter-spacing: .02em;
  cursor: pointer;
  transition: all .25s var(--ease-luxury);
  border: 1px solid transparent;
}

.dash-nav-item svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
}

.dash-nav-item:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, .03);
}

.dash-nav-item.active {
  color: var(--gold);
  background: var(--gold-dim);
  border-color: rgba(212, 175, 55, .25);
}

.dash-nav-item .badge {
  margin-left: auto;
  background: var(--gold);
  color: #000;
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 100px;
  display: none;
}

.dash-nav-item .badge.show {
  display: inline-block;
}

.dash-logout {
  margin-top: auto;
  padding: 12px 14px;
  color: var(--muted);
  font-size: 13px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  cursor: pointer;
  transition: color .3s;
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-logout:hover {
  color: #ff8a8a;
}

.dash-logout svg {
  width: 16px;
  height: 16px;
}

.dash-main {
  padding: 36px 44px;
  overflow-y: auto;
}

.dash-topbar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 12px;
}

.dash-title {
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 300;
}

.dash-date {
  color: var(--muted);
  font-size: 13px;
}

.dash-section {
  display: none;
  animation: sectionIn .5s var(--ease-luxury);
}

.dash-section.active {
  display: block;
}

@keyframes sectionIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ---------- STAT CARDS ---------- */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-bottom: 36px;
}

.stat-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: transform .3s var(--ease-luxury), border-color .3s;
}

.stat-card:hover {
  transform: translateY(-3px);
  border-color: rgba(212, 175, 55, .3);
}

.stat-card .stat-icon {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--gold-dim);
  border-radius: 10px;
  color: var(--gold);
  margin-bottom: 16px;
}

.stat-card .stat-icon svg {
  width: 18px;
  height: 18px;
}

.stat-label {
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.stat-value {
  font-family: var(--serif);
  font-size: 32px;
  font-weight: 400;
}

.stat-value .unit {
  font-size: 15px;
  color: var(--muted);
  font-family: var(--sans);
  margin-left: 4px;
}

.stat-sub {
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
}

/* ---------- CARD / PANEL ---------- */

.panel {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 24px;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  flex-wrap: wrap;
  gap: 10px;
}

.panel-title {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 400;
}

/* ---------- FILTER PILLS ---------- */

.pill-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pill {
  padding: 7px 16px;
  border-radius: 100px;
  border: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  transition: all .25s var(--ease-luxury);
  background: transparent;
}

.pill:hover {
  color: var(--ink);
  border-color: rgba(255, 255, 255, .2);
}

.pill.active {
  color: #000;
  background: var(--gold);
  border-color: var(--gold);
}

.approval-bulk-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}
.approval-bulk-actions .btn-gold-sm {
  padding: 10px 14px;
  font-size: 12px;
}

/* ---------- RESERVATION LIST / TABLE ---------- */

.res-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.row-checkbox {
  display: flex;
  align-items: center;
  justify-content: center;
}

.row-checkbox input {
  width: 16px;
  height: 16px;
}

.res-row {
  display: grid;
  grid-template-columns: auto 1fr auto auto auto auto auto;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  background: rgba(255, 255, 255, .02);
  border: 1px solid var(--line);
  border-radius: 12px;
  transition: border-color .25s;
}

.res-row:hover {
  border-color: rgba(212, 175, 55, .25);
}

.res-main {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.res-name {
  font-size: 14.5px;
  font-weight: 500;
}

.res-meta {
  font-size: 12px;
  color: var(--muted);
}

.res-code {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: .05em;
}

.res-price {
  font-family: var(--serif);
  font-size: 17px;
  color: var(--gold);
  white-space: nowrap;
}

.status-tag {
  font-size: 10.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 100px;
  white-space: nowrap;
}

.status-tag.pending_review {
  background: rgba(212, 175, 55, .12);
  color: var(--gold);
}

.status-tag.approved {
  background: rgba(70, 180, 110, .14);
  color: #6fd99a;
}

.status-tag.rejected {
  background: rgba(220, 60, 60, .12);
  color: #ff8a8a;
}

.status-tag.finished {
  background: rgba(150, 150, 150, .12);
  color: #b0b0b0;
}

.proof-link {
  font-size: 12px;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 7px 12px;
  border-radius: 8px;
  transition: all .25s;
  white-space: nowrap;
}

.proof-link:hover {
  color: var(--gold);
  border-color: rgba(212, 175, 55, .3);
}

.res-actions {
  display: flex;
  gap: 8px;
}

.btn-approve,
.btn-reject,
.btn-finish {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 11.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .06em;
  background: transparent;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: all .25s var(--ease-luxury);
  color: var(--muted);
}

.btn-approve:hover {
  color: #6fd99a;
  border-color: rgba(70, 180, 110, .4);
  background: rgba(70, 180, 110, .08);
}

.btn-reject:hover {
  color: #ff8a8a;
  border-color: rgba(220, 60, 60, .4);
  background: rgba(220, 60, 60, .08);
}

.btn-finish:hover {
  color: #7ab4ff;
  border-color: rgba(122, 180, 255, .4);
  background: rgba(122, 180, 255, .08);
}

.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--muted);
}

.empty-state svg {
  width: 40px;
  height: 40px;
  margin: 0 auto 14px;
  opacity: .4;
}

/* ---------- CALENDAR ---------- */

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.cal-day-label {
  text-align: center;
  font-size: 10.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  padding-bottom: 8px;
}

.cal-cell {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: default;
  transition: border-color .25s, background .25s;
  min-height: 80px;
}

.cal-cell.has-bookings {
  border-color: rgba(212, 175, 55, .3);
  cursor: pointer;
}

.cal-cell.has-bookings:hover {
  background: rgba(212, 175, 55, .05);
}

.cal-cell.empty-cell {
  border: none;
  pointer-events: none;
}

.cal-cell.today {
  box-shadow: inset 0 0 0 1.5px var(--gold);
}

.cal-daynum {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}

.cal-cell.empty-cell .cal-daynum {
  color: transparent;
}

.cal-count {
  margin-top: auto;
  font-size: 11px;
  color: var(--gold);
  font-weight: 600;
  background: rgba(212,175,55,.08);
  border-radius: 20px;
  padding: 2px 6px;
  text-align: center;
  align-self: flex-start;
}

/* ---------- TIME SLOT MANAGEMENT ---------- */

.slot-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: flex-end;
  margin-bottom: 24px;
}

.slot-form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.slot-form-field label {
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}

.slot-form-field select,
.slot-form-field input {
  padding: 14px 16px;
  background: rgba(255, 255, 255, .02);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  font-size: 14.5px;
  font-family: var(--sans);
  transition: all 0.3s var(--ease-luxury);
}
.slot-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 500;
}
.slot-checkbox input {
  width: 18px;
  height: 18px;
}
.slot-time-field { flex: 1 1 220px; }
.slot-full-day-field { flex: 1 1 220px; }

.report-trend {
  display: grid;
  gap: 16px;
  padding: 16px 0;
}
.report-trend-title {
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 10px;
}
.trend-row {
  display: grid;
  grid-template-columns: 1fr 48px;
  gap: 12px;
  align-items: center;
}
.trend-label {
  font-size: 13px;
  color: var(--ink);
}
.trend-chart {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(32px, 1fr));
  gap: 6px;
  align-items: end;
  min-height: 132px;
  padding: 10px;
  background: rgba(255,255,255,.03);
  border: 1px solid var(--line);
  border-radius: 14px;
}
.trend-bar-wrap {
  display: grid;
  gap: 6px;
  align-items: end;
}
.trend-bar {
  display: block;
  width: 100%;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--gold), rgba(212,175,55,.45));
  transition: height .7s ease;
}
.trend-day {
  font-size: 10px;
  text-align: center;
  color: var(--muted);
}
.trend-value {
  font-size: 24px;
  color: var(--ink);
  font-weight: 700;
  margin-top: 6px;
}
.trend-sub {
  font-size: 12px;
  color: var(--muted);
  text-align: right;
}

.slot-form-field select:hover,
.slot-form-field input:hover {
  background: rgba(255, 255, 255, .04);
  border-color: rgba(212, 175, 55, .3);
}

.slot-form-field select:focus,
.slot-form-field input:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(212, 175, 55, .05);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, .1);
}

.btn-gold-sm {
  padding: 14px 24px;
  font-size: 13px;
  background: var(--gold);
  color: #000;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  border-radius: 8px;
  cursor: pointer;
  transition: all .25s var(--ease-luxury);
}

.btn-gold-sm:hover {
  box-shadow: 0 8px 20px var(--gold-glow);
  transform: translateY(-1px);
}

.blocked-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.blocked-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(255, 255, 255, .02);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 13px;
}

.blocked-row .bl-info {
  color: var(--ink);
}

.blocked-row .bl-info span {
  color: var(--muted);
  margin-left: 6px;
}

.bl-remove {
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
  transition: color .25s;
}

.bl-remove:hover {
  color: #ff8a8a;
}

/* ---------- REPORTS ---------- */

.report-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.bar-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.bar-label {
  width: 130px;
  font-size: 12.5px;
  color: var(--muted);
  flex-shrink: 0;
}

.bar-track {
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, .05);
  border-radius: 100px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold));
  border-radius: 100px;
  width: 0;
  transition: width 1s var(--ease-luxury);
}

.bar-value {
  width: 60px;
  text-align: right;
  font-size: 12.5px;
  color: var(--ink);
  flex-shrink: 0;
}

.bar-label {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.bar-count {
  font-size: 10px;
  color: rgba(212, 175, 55, .6);
  font-weight: 500;
}

/* ---------- TOP PERFORMER ---------- */

.top-winner {
  text-align: center;
  padding: 24px 16px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(212,175,55,.08), rgba(212,175,55,.02));
  border: 1px solid rgba(212,175,55,.2);
  margin-bottom: 20px;
}

.top-winner-name {
  font-family: var(--serif);
  font-size: 26px;
  color: var(--gold);
  margin-bottom: 6px;
}

.top-winner-stats {
  font-size: 13px;
  color: var(--muted);
}

.top-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.top-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(255,255,255,.02);
  border: 1px solid var(--line);
}

.top-medal {
  font-size: 20px;
  line-height: 1;
}

.top-name {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}

.top-clients {
  font-size: 12px;
  color: var(--muted);
  background: rgba(255,255,255,.04);
  padding: 3px 10px;
  border-radius: 20px;
}

.top-revenue {
  font-size: 13px;
  color: var(--gold);
  font-weight: 600;
  min-width: 80px;
  text-align: right;
}

/* ---------- TOAST ---------- */

.toast {
  position: fixed;
  bottom: 28px;
  right: 28px;
  padding: 14px 22px;
  background: var(--bg-2);
  border: 1px solid rgba(212, 175, 55, .3);
  border-radius: 12px;
  font-size: 13px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .5);
  transform: translateY(20px);
  opacity: 0;
  transition: all .4s var(--ease-spring);
  pointer-events: none;
  z-index: 999;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast.error {
  border-color: rgba(220, 60, 60, .4);
  color: #ff8a8a;
}

/* ---------- LOADER SKELETON ---------- */

.skeleton {
  background: linear-gradient(90deg, rgba(255, 255, 255, .03) 25%, rgba(255, 255, 255, .06) 37%, rgba(255, 255, 255, .03) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: 8px;
}

@keyframes shimmer {
  0% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0 50%;
  }
}

/* ---------- MOBILE SIDEBAR ---------- */

.dash-mobile-toggle {
  display: none;
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 200;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-2);
  border: 1px solid var(--line);
  align-items: center;
  justify-content: center;
  color: var(--ink);
}

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

  .dash-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: 260px;
    transform: translateX(-100%);
    transition: transform .35s var(--ease-luxury);
    z-index: 150;
  }

  .dash-sidebar.open {
    transform: translateX(0);
  }

  .dash-main {
    padding: 90px 20px 40px;
  }

  .dash-mobile-toggle {
    display: flex;
  }

  .stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .res-row {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .report-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .stat-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .stat-card {
    padding: 14px;
    border-radius: 12px;
  }

  .stat-card .stat-icon {
    width: 30px;
    height: 30px;
    margin-bottom: 10px;
    border-radius: 8px;
  }

  .stat-card .stat-icon svg {
    width: 14px;
    height: 14px;
  }

  .stat-label {
    font-size: 10px;
    margin-bottom: 5px;
  }

  .stat-value {
    font-size: 22px;
  }

  .stat-sub {
    font-size: 10.5px;
  }

  .panel {
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 16px;
  }

  .panel-title {
    font-size: 16px;
  }

  .dash-title {
    font-size: 22px;
  }

  .dash-main {
    padding: 84px 14px 32px;
  }

  .res-row {
    padding: 12px 14px;
    gap: 10px;
    border-radius: 10px;
  }

  .res-name {
    font-size: 13px;
  }

  .res-meta,
  .res-code {
    font-size: 11px;
  }

  .res-price {
    font-size: 15px;
  }

  .status-tag {
    font-size: 9.5px;
    padding: 4px 9px;
  }

  .proof-link {
    font-size: 11px;
    padding: 6px 10px;
  }

  .btn-approve,
  .btn-reject,
  .btn-finish {
    padding: 7px 11px;
    font-size: 10.5px;
  }

  .cal-grid {
    gap: 3px;
  }

  .cal-cell {
    min-height: 52px;
    padding: 6px 4px;
    border-radius: 7px;
  }

  .cal-daynum {
    font-size: 11px;
  }

  .cal-count {
    font-size: 9px;
    padding: 1px 4px;
  }

  .cal-day-label {
    font-size: 9px;
    letter-spacing: .04em;
  }

  .pill {
    font-size: 11px;
    padding: 6px 12px;
  }

  .login-card {
    padding: 36px 26px;
  }
}

/* ---------- PROOF IMAGE MODAL ---------- */

.proof-modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.proof-modal[hidden] {
  display: none !important;
}

.proof-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .75);
  backdrop-filter: blur(6px);
}

.proof-modal-card {
  position: relative;
  max-width: 480px;
  width: 100%;
  max-height: 86vh;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 20px;
  overflow-y: auto;
  animation: proofIn .3s var(--ease-luxury);
}

@keyframes proofIn {
  from {
    opacity: 0;
    transform: scale(.96);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

.proof-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .06);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: background .25s;
  z-index: 2;
}

.proof-modal-close:hover {
  background: rgba(255, 255, 255, .14);
}

.proof-modal-head {
  font-family: var(--serif);
  font-size: 17px;
  margin-bottom: 14px;
  padding-right: 40px;
}

.proof-modal-body img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  display: block;
}

.proof-modal-body iframe {
  width: 100%;
  height: 60vh;
  border: 1px solid var(--line);
  border-radius: 12px;
}

@media (max-width: 480px) {
  .proof-modal-card {
    padding: 16px;
    border-radius: 14px;
  }
}
/* ---------- QUICK LOOKUP (QR scan + manual search) ---------- */

.qr-viewport {
  position: relative;
  width: 100%;
  max-width: 360px;
  aspect-ratio: 1;
  margin: 0 auto 14px;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
}

.qr-viewport video {
  width: 100%; height: 100%; object-fit: cover;
}

.qr-overlay {
  position: absolute; inset: 14%;
  border: 2px solid var(--gold);
  border-radius: 12px;
  box-shadow: 0 0 0 999px rgba(0,0,0,.35);
  pointer-events: none;
}

.qr-hint {
  position: absolute; bottom: 10px; left: 0; right: 0;
  text-align: center;
  font-size: 11px; letter-spacing: .05em;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,.6);
}

.qr-stop-btn {
  display: block;
  margin: 0 auto;
  padding: 10px 22px;
  background: rgba(220,60,60,.12);
  border: 1px solid rgba(220,60,60,.35);
  color: #ff8a8a;
  font-size: 12px;
  letter-spacing: .05em;
  border-radius: 100px;
  cursor: pointer;
  transition: all .25s var(--ease-luxury);
}
.qr-stop-btn:hover { background: rgba(220,60,60,.2); }

.lookup-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }

.lookup-card {
  background: var(--bg-2);
  border: 1px solid rgba(212,175,55,.3);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 14px;
  animation: sectionIn .4s var(--ease-luxury);
}

.lookup-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.lookup-name { font-family: var(--serif); font-size: 21px; margin-bottom: 4px; }
.lookup-code { font-size: 13px; color: var(--gold); letter-spacing: .08em; }

.lookup-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 16px;
}

.lookup-grid div { font-size: 14px; color: var(--ink); }
.lookup-grid span { display: block; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 3px; }

@media (max-width: 480px) {
  .lookup-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .lookup-card { padding: 16px; }
  .lookup-name { font-size: 18px; }
  .qr-viewport { max-width: 280px; }
}

/* ---------- AI VERIFICATION ---------- */

.ai-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 100px;
  white-space: nowrap;
  cursor: help;
}
.ai-badge-excellent { background: rgba(70,180,110,.14); color: #6fd99a; }
.ai-badge-good { background: rgba(212,175,55,.14); color: var(--gold); }
.ai-badge-review { background: rgba(240,160,60,.14); color: #f0a03c; }
.ai-badge-manual { background: rgba(220,60,60,.14); color: #ff8a8a; }
.ai-badge-none { background: rgba(255,255,255,.05); color: var(--muted); }

.ai-panel {
  margin-top: 16px;
  padding: 16px;
  background: rgba(255,255,255,.02);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.ai-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.ai-panel-title { font-family: var(--serif); font-size: 15px; }

.ai-panel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.ai-panel-row { font-size: 12.5px; }
.ai-panel-row span { display: block; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }

.ai-panel-text {
  margin-top: 10px;
  padding: 10px 12px;
  background: rgba(255,255,255,.02);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 11.5px;
  color: var(--muted);
  max-height: 120px;
  overflow-y: auto;
  white-space: pre-wrap;
}

.ai-panel-reason {
  margin-top: 10px;
  padding: 10px 12px;
  background: rgba(220,60,60,.08);
  border: 1px solid rgba(220,60,60,.25);
  border-radius: 8px;
  font-size: 12px;
  color: #ff8a8a;
}

.ai-panel-none {
  font-size: 12.5px;
  color: var(--muted);
  padding: 8px 0;
}

/* ---------- RECEIPT ZOOM ---------- */

.proof-modal-body img { cursor: zoom-in; transition: transform .3s var(--ease-luxury); }
.proof-modal-body img.zoomed { cursor: zoom-out; transform: scale(1.8); }
.proof-modal-body { overflow: auto; }

@media (max-width: 480px) {
  .ai-panel-grid { grid-template-columns: 1fr 1fr; }
}

.proof-modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}

.proof-modal-download {
  padding: 8px 16px;
  background: var(--gold);
  color: #000;
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .04em;
  border-radius: 100px;
}

.proof-modal-hint {
  font-size: 11px;
  color: var(--muted);
}

.ai-panel-recommendation {
  margin-top: 10px;
  font-size: 12.5px;
  color: var(--ink);
}
.ai-panel-recommendation strong { color: var(--gold); }
