/*
 * The Malt — Mobile-first stylesheet
 */

/* ── Reset & Base ──────────────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-primary:        #4F46E5;
  --color-primary-dark:   #3730A3;
  --color-primary-light:  #EEF2FF;
  --color-danger:         #DC2626;
  --color-danger-bg:      #FEF2F2;
  --color-danger-border:  #FECACA;
  --color-success:        #16A34A;
  --color-success-bg:     #F0FDF4;
  --color-success-border: #BBF7D0;
  --color-text:           #111827;
  --color-text-muted:     #6B7280;
  --color-border:         #E5E7EB;
  --color-bg:             #F9FAFB;
  --color-white:          #FFFFFF;
  --radius:               12px;
  --radius-sm:            8px;
  --shadow:               0 1px 3px rgba(0,0,0,0.10), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-lg:            0 10px 15px -3px rgba(0,0,0,0.10), 0 4px 6px -2px rgba(0,0,0,0.05);
}

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── Flash Messages ────────────────────────────────────────────────────────── */
.flash {
  padding: 0.875rem 1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.4;
}

.flash-alert {
  background: var(--color-danger-bg);
  color: var(--color-danger);
  border: 1px solid var(--color-danger-border);
}

.flash-notice {
  background: var(--color-success-bg);
  color: var(--color-success);
  border: 1px solid var(--color-success-border);
}

/* ── Auth Layout ───────────────────────────────────────────────────────────── */
.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 1rem;
}

.auth-card {
  background: var(--color-white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 2rem 1.5rem;
  width: 100%;
  max-width: 420px;
}

.auth-logo {
  text-align: center;
  margin-bottom: 1.75rem;
}

.auth-logo-image {
  width: 120px;
  height: auto;
  margin-bottom: 0.75rem;
}

.auth-logo h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.025em;
}

.auth-logo p {
  color: var(--color-text-muted);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* ── Auth Tabs ─────────────────────────────────────────────────────────────── */
.auth-admin-link {
  text-align: center;
  margin-top: 0.75rem;
  font-size: 0.75rem;
}

.auth-admin-link a {
  color: var(--color-text-muted);
  text-decoration: none;
}

.auth-admin-link a:hover {
  text-decoration: underline;
}

.auth-tabs {
  display: flex;
  border-bottom: 2px solid var(--color-border);
  margin-bottom: 1.5rem;
}

.auth-tab {
  flex: 1;
  padding: 0.75rem 0.25rem;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text-muted);
  cursor: pointer;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  background: none;
  transition: color 0.15s, border-color 0.15s;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
  font-family: inherit;
}

.auth-tab.active {
  color: var(--color-primary);
  border-bottom-color: var(--color-primary);
}

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Form Elements ─────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.125rem; }

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: 0.375rem;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  color: var(--color-text);
  background: var(--color-white);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none;
  appearance: none;
  min-height: 48px;
  font-family: inherit;
}

.form-control:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.form-control::placeholder { color: #9CA3AF; }

.form-hint {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 0.375rem;
}

/* ── Buttons ───────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: background-color 0.15s, opacity 0.15s;
  text-decoration: none;
  min-height: 48px;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
  width: 100%;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
}

.btn-primary:hover  { background: var(--color-primary-dark); }
.btn-primary:active { opacity: 0.88; }

.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-google {
  background: var(--color-white);
  color: var(--color-text);
  border: 1.5px solid var(--color-border);
  font-weight: 500;
}

.btn-google:hover  { background: var(--color-bg); }
.btn-google:active { opacity: 0.88; }

.btn-google svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* ── OTP Input ─────────────────────────────────────────────────────────────── */
.otp-group {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 0.5rem;
}

.otp-box {
  width: 48px;
  height: 58px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-white);
  color: var(--color-text);
  -webkit-appearance: none;
  appearance: none;
  caret-color: transparent;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s, background-color 0.15s;
}

.otp-box:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
  background: var(--color-primary-light);
}

.otp-phone-hint {
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 1.25rem;
}

.otp-phone-hint strong { color: var(--color-text); }

/* ── Resend / Countdown ────────────────────────────────────────────────────── */
.resend-section {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.resend-btn {
  background: none;
  border: none;
  color: var(--color-primary);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.875rem;
  font-family: inherit;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

.resend-btn:disabled {
  color: var(--color-text-muted);
  cursor: default;
}

/* ── Divider ───────────────────────────────────────────────────────────────── */
.divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.25rem 0;
  color: var(--color-text-muted);
  font-size: 0.8rem;
  font-weight: 500;
}

.divider::before, .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

/* ── Auth Footer ───────────────────────────────────────────────────────────── */
.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.auth-footer a {
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: none;
}

/* ── Dashboard Layout ──────────────────────────────────────────────────────── */
.dashboard-page {
  min-height: 100vh;
  background: var(--color-bg);
  display: flex;
  flex-direction: column;
}

.dashboard-header {
  background: var(--color-white);
  padding: 0.875rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  position: sticky;
  top: 0;
  z-index: 20;
}

.dashboard-brand {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary);
  letter-spacing: -0.025em;
}

.dashboard-content {
  flex: 1;
  padding: 1.5rem 1.25rem;
  max-width: 600px;
  width: 100%;
  margin: 0 auto;
}

.welcome-card {
  background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 100%);
  color: white;
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.25rem;
}

.welcome-card-greeting {
  font-size: 0.75rem;
  font-weight: 600;
  opacity: 0.8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.375rem;
}

.welcome-card h2 {
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.375rem;
}

.welcome-card p {
  opacity: 0.8;
  font-size: 0.875rem;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.info-card {
  background: var(--color-white);
  border-radius: var(--radius);
  padding: 1rem;
  box-shadow: var(--shadow);
}

.info-card-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  margin-bottom: 0.375rem;
}

.info-card-value {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--color-text);
  word-break: break-word;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: var(--color-primary-light);
  color: var(--color-primary);
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
}

/* ── Logout Button ─────────────────────────────────────────────────────────── */
.btn-logout {
  font-size: 0.875rem;
  padding: 0.5rem 0.875rem;
  background: var(--color-danger-bg);
  color: var(--color-danger);
  border: 1px solid var(--color-danger-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 500;
  font-family: inherit;
  min-height: 36px;
  -webkit-tap-highlight-color: transparent;
}

.btn-logout:active { opacity: 0.8; }

/* ── Filter Tabs (shared) ──────────────────────────────────────────────────── */
.filter-tabs {
  display: flex;
  gap: 0.375rem;
  overflow-x: auto;
  padding: 0 1.25rem 0.75rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.filter-tabs::-webkit-scrollbar { display: none; }

.filter-tab {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.875rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  border: 1.5px solid var(--color-border);
  background: var(--color-white);
  color: var(--color-text-muted);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  -webkit-tap-highlight-color: transparent;
  min-height: 32px;
}

.filter-tab:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.filter-tab.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-white);
}

/* ── Dashboard Item Section ────────────────────────────────────────────────── */
.dash-flash-wrap {
  padding: 0.875rem 1.25rem 0;
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

.dash-items-section {
  margin-top: 1.25rem;
}

.dash-items-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0 0.625rem;
}

.dash-items-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-text);
}

.dash-view-all-link {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: none;
}

.dash-item-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-top: 0.875rem;
}

@media (min-width: 480px) {
  .dash-item-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 640px) {
  .dash-item-grid { grid-template-columns: repeat(4, 1fr); }
}

.dash-item-card {
  background: var(--color-white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.dash-item-image-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #F1F5F9;
  flex-shrink: 0;
}

.dash-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.dash-item-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-item-info {
  padding: 0.625rem 0.75rem 0.75rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.dash-item-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dash-item-price {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-top: auto;
}

.dash-items-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--color-text-muted);
  font-size: 0.875rem;
}

/* Filter tabs when inside the sticky menu header — no top padding needed */
.menu-header .filter-tabs { padding-top: 0; }

/* ── Dashboard Menu CTA ────────────────────────────────────────────────────── */
.dashboard-menu-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--color-white);
  border-radius: var(--radius);
  padding: 1rem 1.125rem;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--color-text);
  gap: 0.75rem;
  -webkit-tap-highlight-color: transparent;
  transition: box-shadow 0.15s;
}

.dashboard-menu-cta:hover { box-shadow: var(--shadow-lg); }

.dashboard-menu-cta-left {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  color: var(--color-primary);
}

.dashboard-menu-cta-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--color-text);
}

.dashboard-menu-cta-sub {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 0.1rem;
}

/* ── Menu Page ─────────────────────────────────────────────────────────────── */
.menu-page {
  min-height: 100vh;
  background: var(--color-bg);
  display: flex;
  flex-direction: column;
}

/* Header */
.menu-header {
  background: var(--color-white);
  position: sticky;
  top: 0;
  z-index: 30;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.menu-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.875rem 1.25rem 0.75rem;
}

.menu-brand {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.625rem;
}

.menu-brand-logo {
  height: 32px;
  width: auto;
  display: block;
  flex-shrink: 0;
}

.menu-brand-page-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-text);
  letter-spacing: -0.02em;
  line-height: 1;
}

.menu-signout-btn {
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.375rem 0.75rem;
  background: var(--color-bg);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
  width: auto;
  min-height: unset;
}

/* Search bar */
.menu-search-wrap {
  padding: 0 1.25rem 0.75rem;
}

.menu-search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.menu-search-icon {
  position: absolute;
  left: 0.875rem;
  color: var(--color-text-muted);
  pointer-events: none;
  flex-shrink: 0;
}

.menu-search-input {
  width: 100%;
  padding: 0.625rem 1rem 0.625rem 2.625rem;
  font-size: 0.95rem;
  border: 1.5px solid var(--color-border);
  border-radius: 999px;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: inherit;
  min-height: 44px;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.menu-search-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
  background: var(--color-white);
}

.menu-search-input::placeholder { color: #9CA3AF; }

/* Category pill nav */
.menu-cat-nav {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0 1.25rem 0.875rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.menu-cat-nav::-webkit-scrollbar { display: none; }

.menu-cat-pill {
  display: inline-block;
  padding: 0.35rem 0.875rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  background: var(--color-primary-light);
  color: var(--color-primary);
  border: 1.5px solid transparent;
  transition: background 0.15s, border-color 0.15s;
  -webkit-tap-highlight-color: transparent;
  min-height: 34px;
  line-height: 1.6;
}

.menu-cat-pill:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

/* Content area */
.menu-content {
  flex: 1;
  padding: 0.5rem 0 2rem;
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

/* Category section */
.menu-section { margin-bottom: 0.5rem; }

.menu-section-heading {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-text);
  padding: 1rem 1.25rem 0.625rem;
  letter-spacing: -0.01em;
  position: sticky;
  top: var(--menu-header-height, 160px);
  background: var(--color-bg);
  z-index: 10;
}

/* Item list */
.menu-items-list {
  display: flex;
  flex-direction: column;
}

/* Item card — horizontal layout like Swiggy/Zomato */
.menu-item-card {
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  padding: 1rem 1.25rem;
  transition: background 0.1s;
  -webkit-tap-highlight-color: transparent;
}

.menu-item-card:first-child {
  border-top: 1px solid var(--color-border);
}

.menu-item-body {
  display: flex;
  gap: 0.875rem;
  align-items: flex-start;
}

.menu-item-info {
  flex: 1;
  min-width: 0;
}

.menu-item-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.25rem;
  line-height: 1.3;
}

.menu-item-desc {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.45;
  margin-bottom: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.menu-item-price {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-text);
}

/* Image */
.menu-item-image-wrap {
  flex-shrink: 0;
  width: 88px;
  height: 88px;
  border-radius: 10px;
  overflow: hidden;
}

.menu-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.menu-item-image-placeholder {
  width: 100%;
  height: 100%;
  background: #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Empty / no results */
.menu-empty {
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

.menu-empty strong { color: var(--color-text); }

.menu-empty-clear {
  margin-top: 0.875rem;
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-primary);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
}

/* Tablet+ — slightly wider cards */
@media (min-width: 480px) {
  .menu-item-image-wrap {
    width: 100px;
    height: 100px;
  }
}

@media (min-width: 640px) {
  .menu-content { padding-top: 1rem; }

  .menu-item-card { padding: 1.125rem 1.5rem; }

  .menu-section-heading { padding: 1.125rem 1.5rem 0.625rem; }
}

/* ── Bottom Navigation Bar ─────────────────────────────────────────────────── */
.bottom-nav {
  width: 100vw;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: var(--color-white);
  border-top: 1px solid var(--color-border);
  display: flex;
  /* Respect the iPhone home-indicator safe area */
  padding-bottom: env(safe-area-inset-bottom, 0px);
  box-shadow: 0 -1px 8px rgba(0,0,0,0.06);
}

.bottom-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  padding: 0.625rem 0;
  min-height: 56px;
  text-decoration: none;
  color: #94A3B8;
  -webkit-tap-highlight-color: transparent;
  transition: color 0.15s;
}

.bottom-nav-item.active {
  color: var(--color-primary);
}

.bottom-nav-item:hover {
  color: var(--color-primary);
}

.bottom-nav-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.bottom-nav-label {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1;
}

/* Push page content above the nav bar */
.dashboard-content,
.menu-content {
  padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px));
}

/* Desktop — centre and constrain the bottom nav */
@media (min-width: 768px) {
  .bottom-nav {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    border-radius: 999px;
    bottom: 1.25rem;
    border: 1px solid var(--color-border);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  }
}

/* ── Pagy Pagination (driver / customer pages) ──────────────────────────────── */
nav.pagy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  margin: 1.25rem 0;
}

nav.pagy a,
nav.pagy span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  color: #475569;
  background: white;
  border: 1px solid #E2E8F0;
}

nav.pagy a:hover { background: #F1F5F9; }

nav.pagy span.current {
  background: #4F46E5;
  color: white;
  border-color: #4F46E5;
}

nav.pagy span.gap,
nav.pagy span.disabled {
  background: transparent;
  border-color: transparent;
  color: #CBD5E1;
}

/* ── Loading Overlay ────────────────────────────────────────────────────────── */
#loading-overlay {
  display: contents; /* wrapper is invisible; the modal inside is what shows */
}

.loading-overlay--visible {
  display: flex !important;
}

.loading-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  align-items: center;
  justify-content: center;
}

.loading-modal-box {
  background: white;
  border-radius: 14px;
  padding: 2rem 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  min-width: 160px;
}

.loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #E2E8F0;
  border-top-color: #4F46E5;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}

.loading-modal-text {
  font-size: 0.875rem;
  font-weight: 600;
  color: #475569;
  letter-spacing: 0.01em;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
