/* ============================================================
   DUYGU BÄCKEREI — ADMIN PANEL
   Design tokens from adminPanelSpecs.md § 1
   ============================================================ */

:root {
  /* brand */
  --bg-primary: #0d2a22;
  --bg-secondary: #1a3a2e;
  --accent-gold: #c47f2a;
  --gold-light: #e8a020;
  --cream: #f5ead8;
  --text-primary: #f5f0e8;
  --text-muted: #8fa89a;
  --border: rgba(255, 255, 255, 0.08);

  /* status pills */
  --status-neu: #e8a020;
  --status-in-arbeit: #4a90d9;
  --status-fertig: #27ae60;
  --status-storniert: #e74c3c;

  /* layout */
  --topbar-h: 64px;
  --sidebar-w: 72px;
  --sidebar-w-collapsed: 72px;
  --tabbar-h: 72px;
  --radius: 14px;
  --radius-sm: 9px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  /* fonts */
  --font-heading: "Cormorant Garamond", serif;
  --font-body: "DM Sans", sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 600;
}

/* ============================================================
   TOPBAR
   ============================================================ */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--topbar-h);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1rem;
  padding: 0 1.25rem;
  background: var(--bg-primary);
  border-bottom: 2px solid var(--accent-gold);
  z-index: 100;
}

.hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  margin-left: 0.75rem;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-primary);
}

.hamburger:hover {
  background: rgba(255, 255, 255, 0.06);
}

.hamburger svg,
.icon-btn svg,
.admin-caret svg,
.topbar-search-icon svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.7;
}

.nav-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 1.7;
}

.topbar-brand {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.25rem;
  height: 100%;
  padding: 0 1.25rem;
  line-height: 1.1;
}

.topbar-logo-img {
  height: 34px;
  width: auto;
  object-fit: contain;
}

.topbar-logo-sub {
  display: flex;
  justify-content: center;
  font-size: 0.56rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--cream);
}

.topbar-search {
  position: relative;
  justify-self: center;
  width: 100%;
  max-width: 480px;
  margin: 0 1.25rem;
}

.topbar-search-icon {
  position: absolute;
  left: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.topbar-search input {
  width: 100%;
  padding: 0.55rem 1rem 0.55rem 2.4rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.82rem;
  outline: none;
  transition:
    border-color 0.2s var(--ease),
    background 0.2s var(--ease);
}

.topbar-search input::placeholder {
  color: var(--text-muted);
}

.topbar-search input:focus {
  border-color: var(--accent-gold);
  background: rgba(255, 255, 255, 0.08);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  justify-self: end;
  padding-right: 1.5rem;
}

.icon-btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  transition: background 0.2s var(--ease);
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.icon-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--gold-light);
  color: var(--bg-primary);
  font-size: 0.62rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid var(--bg-secondary);
}

.admin-account {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  border: none;
  background: transparent;
  padding: 0.3rem 0.5rem 0.3rem 0.3rem;
  border-radius: 999px;
  color: var(--text-primary);
  transition: background 0.2s var(--ease);
}

.admin-account:hover {
  background: rgba(255, 255, 255, 0.06);
}

.admin-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent-gold), var(--gold-light));
  color: var(--bg-primary);
  flex-shrink: 0;
}

.admin-avatar svg {
  width: 18px;
  height: 18px;
}

.admin-name-block {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  text-align: left;
}

.admin-name {
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.admin-role {
  font-size: 0.66rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.admin-caret {
  color: var(--text-muted);
}

.admin-account-wrap {
  position: relative;
}

.admin-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  padding: 0.35rem;
  z-index: 200;
}

.admin-dropdown-menu.is-open {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.7rem;
  border-radius: 6px;
  font-size: 0.82rem;
  color: var(--text-primary);
  transition: background 0.15s var(--ease);
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.dropdown-item svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

/* ============================================================
   SHELL LAYOUT
   ============================================================ */
.admin-shell {
  display: flex;
  padding-top: var(--topbar-h);
  min-height: 100vh;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  top: var(--topbar-h);
  background: rgba(0, 0, 0, 0.45);
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease);
}

/* ============================================================
   SIDEBAR — narrow filled-icon rail (ADM-10/22)
   ============================================================ */
.sidebar {
  position: fixed;
  top: var(--topbar-h);
  left: 0;
  bottom: 0;
  width: var(--sidebar-w);
  background: var(--bg-primary);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 95;
  overflow-x: hidden;
}

.sidebar-wave,
.sidebar-card {
  display: none;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 0.85rem 0.5rem;
  flex: 1;
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: 14px;
  color: var(--text-muted);
  font-size: 0.86rem;
  font-weight: 500;
  white-space: nowrap;
  transition:
    background 0.18s var(--ease),
    color 0.18s var(--ease);
}

.nav-item.is-active {
  background: var(--accent-gold);
  color: #fff;
  font-weight: 600;
}

.nav-item.is-active .nav-icon {
  color: #fff;
}

.nav-item.is-active .nav-badge {
  background: #fff;
  color: var(--accent-gold);
}

.nav-icon {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
}

.nav-icon svg {
  width: 28px;
  height: 28px;
}

/* Desktop-Sidebar only — tabbar stays 22px via .tabbar-circle .nav-icon */
.sidebar .nav-icon {
  width: 34px;
  height: 34px;
}

.sidebar .nav-icon svg {
  width: 34px;
  height: 34px;
  stroke-width: 2.4;
}

.nav-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.nav-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--gold-light);
  color: var(--bg-primary);
  font-size: 0.6rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  line-height: 1;
}

.sidebar-card {
  display: none;
}

.sidebar-card-icon {
  width: 100%;
  height: 84px;
  margin: 0 auto 0.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.sidebar-card-icon img {
  height: 84px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}

.sidebar-card-tagline {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: 0.86rem;
  color: var(--gold-light);
  line-height: 1.4;
  margin-bottom: 0.8rem;
}

.sidebar-card-brand {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--border);
}

.sidebar-card-name {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--text-primary);
}

.sidebar-card-since {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  font-size: 0.68rem;
  color: var(--text-muted);
}

.sidebar-card-since svg {
  width: 11px;
  height: 11px;
  color: var(--status-storniert);
  fill: var(--status-storniert);
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */
.main-content {
  flex: 1;
  /* Lets the inner scroll boxes (tables, charts) scroll instead of widening the page. */
  min-width: 0;
  margin-left: var(--sidebar-w);
  padding: 2rem;
  min-height: calc(100vh - var(--topbar-h));
  transition: margin-left 0.25s var(--ease);
}

.content-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  min-height: 60vh;
  color: var(--text-muted);
  text-align: center;
}

.content-placeholder svg {
  width: 46px;
  height: 46px;
  opacity: 0.4;
}

.content-placeholder p {
  font-size: 0.9rem;
}

/* ============================================================
   SHARED PAGE / CARD PATTERNS
   ============================================================ */
.page-header {
  margin-bottom: 1.5rem;
}

.page-header-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.page-header-title svg {
  width: 22px;
  height: 22px;
  color: var(--accent-gold);
}

.page-header-title h1 {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.page-header-subtitle {
  margin: 0.3rem 0 0;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.card {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.card-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 1rem;
}

.status-pill {
  display: inline-block;
  padding: 0.18rem 0.65rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  white-space: nowrap;
}

.btn-outline-sm {
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.76rem;
  cursor: pointer;
  transition: background 0.18s var(--ease);
}

.btn-outline-sm:hover {
  background: rgba(255, 255, 255, 0.08);
}

/* ============================================================
   TABLES
   ============================================================ */
.table-scroll {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.data-table thead th {
  background: rgba(0, 0, 0, 0.2);
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: left;
  padding: 0.65rem 1rem;
  white-space: nowrap;
}

.data-table tbody td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  white-space: nowrap;
}

.data-table tbody tr {
  cursor: pointer;
  transition: background 0.15s var(--ease);
}

.data-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

/* ============================================================
   BESTELLUNGEN GRID (glanceable multi-order overview)
   3 columns — each card's labeled rows (Geschmack/Dekor/Toppings/...) each
   get their own full-width line (single column, see .order-grid-info),
   but the icons WITHIN a row lay out horizontally (.order-grid-icons is a
   wrapping flex row) instead of stacking, and with the icon-name hidden
   (see .order-grid-item-name's :has() rule) + the full card width now
   available to one category at a time, 2-3 icons almost never need to
   wrap onto a second line — that's what keeps cards short enough for 3x2
   = 6 to fit the viewport with no scrolling, per client request. Collapses
   at the same breakpoints .kpi-grid already uses, for the same reason
   (sidebar collapses to icons-only at 1024px, goes off-canvas at 768px).
   ============================================================ */
.order-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
}

.order-grid-card {
  display: flex;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
  cursor: pointer;
  transition:
    background 0.15s var(--ease),
    border-color 0.15s var(--ease);
  overflow: hidden;
}

.order-grid-card:active {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
}

.order-grid-media {
  flex: 0 0 32%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.order-grid-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 158 / 235;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

.order-grid-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.order-grid-thumb i {
  width: 24px;
  height: 24px;
}

.order-grid-foto-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(13, 42, 34, 0.85);
  color: var(--cream);
  display: grid;
  place-items: center;
  pointer-events: none;
}

.order-grid-foto-badge svg {
  width: 14px;
  height: 14px;
}

.dia-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--text-primary, #1b201d);
  display: inline-grid;
  place-items: center;
  vertical-align: middle;
  background: #fff;
  line-height: 1;
  margin: 0 2px;
}

.dia-badge-n {
  font-size: 0.68rem;
  font-weight: 700;
  color: #1b201d;
}

.order-grid-under-thumb {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.68rem;
}

.order-grid-under-thumb .order-grid-row {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-grid-under-thumb strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* Right ~70%: dense description — back to a single stacked column (client
   feedback: pairing two categories side by side per line looked cramped).
   Height is instead kept down at the ROW level: each category's icons sit
   in a single horizontal row (.order-grid-icons is flex, not a column) —
   with the FULL card width available to one category at a time (instead
   of sharing it with a second category), 2-3 icons almost never need to
   wrap onto a second line, which is what actually saves the height here. */
.order-grid-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  font-size: 0.66rem;
}

.order-grid-row {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-grid-row i {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
}

.order-grid-row strong {
  color: var(--text-primary);
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-grid-top {
  justify-content: space-between;
  gap: 0.4rem;
}

.order-grid-number {
  font-weight: 700;
  color: var(--text-primary);
  font-size: 0.76rem;
}

.order-grid-top .status-pill {
  padding: 0.1rem 0.5rem;
  font-size: 0.6rem;
  flex-shrink: 0;
}

.order-grid-done {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  min-height: 34px;
  padding: 0.25rem 0.75rem;
  border: 1.5px solid var(--accent, #c47f2a);
  border-radius: 999px;
  background: #fff;
  color: var(--accent, #c47f2a);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
}

.order-grid-done svg {
  width: 14px;
  height: 14px;
}

.order-grid-done.is-done {
  background: #2e7d32;
  border-color: #2e7d32;
  color: #fff;
}

.status-pill-cycle {
  border: none;
  font-family: inherit;
  line-height: 1.2;
}

.status-pill-cycle.is-clickable {
  cursor: pointer;
  min-height: 28px;
  min-width: 44px;
}

.status-pill-cycle:disabled {
  cursor: default;
  opacity: 0.95;
}

.order-grid-labeled {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  column-gap: 10px;
  align-items: center;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  margin-top: 2px;
}

.order-grid-field-label {
  font-weight: 700;
  color: var(--text-primary);
  align-self: center;
}

.order-grid-icons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  align-content: center;
  gap: 5px 8px;
}

/* flex:1 1 0 (not a fixed width) — a fallback name-only item (no mapped
   image, see the :has() rule below) shrinks and ellipsis-truncates to
   whatever room is actually left instead of reserving a fixed width that
   could overflow the card. */
.order-grid-item {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1 1 0;
  min-width: 0;
}

/* Icon present -> the name label is redundant (see .order-grid-item-name's
   :has() rule below) and hidden, so the item only needs to be as wide as
   the icon itself instead of stretching to fill the row. */
.order-grid-item:has(img) {
  flex: 0 0 auto;
}

.order-grid-icons img {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
}

.order-grid-item-name {
  font-size: 0.66rem;
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

/* Client request: the name next to an icon is redundant once the picture
   is already shown — hide it. Falls back to showing the name when there's
   no mapped image for that item (gridIconName only renders an <img> when
   it has a src), so nothing ever renders as a bare, unlabeled blank. */
.order-grid-item:has(img) .order-grid-item-name {
  display: none;
}

.order-grid-price {
  /* .order-grid-info is flex-column again, so margin-top:auto pushes this
     to the bottom of whatever space is left, same as before the 2-column
     grid experiment. */
  margin-top: auto;
  padding-top: 0.2rem;
  border-top: 1px solid var(--border);
  font-weight: 700;
  color: var(--accent-gold);
  font-size: 0.76rem;
  text-align: right;
}

/* ============================================================
   DASHBOARD
   ============================================================ */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.kpi-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem;
}

.kpi-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(196, 127, 42, 0.15);
  color: var(--accent-gold);
  flex-shrink: 0;
}

.kpi-icon svg {
  width: 20px;
  height: 20px;
}

.kpi-body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.kpi-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
}

.kpi-label {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.bar-chart {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem;
  height: 160px;
}

.bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  height: 100%;
}

.bar-count {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-primary);
}

.bar-track {
  flex: 1;
  width: 100%;
  max-width: 32px;
  display: flex;
  align-items: flex-end;
}

.bar-fill {
  width: 100%;
  min-height: 4px;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, var(--gold-light), var(--accent-gold));
}

.bar-day {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: capitalize;
  min-height: 1em;
}

.bar-chart-30 {
  gap: 0.15rem;
  overflow-x: auto;
}

.bar-chart-30 .bar-col {
  min-width: 18px;
  flex: 1 0 18px;
}

.bar-chart-30 .bar-track {
  max-width: 14px;
}

.bar-chart-30 .bar-count {
  font-size: 0.58rem;
}

.bar-chart-30 .bar-day {
  font-size: 0.55rem;
  letter-spacing: -0.02em;
}

.chart-empty {
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 1rem 0;
}

/* ============================================================
   MOBILE CIRCLE TAB BAR (ADM-22)
   ============================================================ */
.admin-tabbar {
  display: none;
}

/* ============================================================
   ORDER DETAIL MODAL (Prompt 6)
   ============================================================ */
.order-modal-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.order-modal-header h2 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  color: var(--text-primary);
  margin: 0;
}

.detail-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
}

.detail-meta-row strong {
  color: var(--text-primary);
  font-weight: 600;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

.detail-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
}

.detail-card h3 {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin: 0 0 0.6rem;
}

.detail-card h3 svg {
  width: 14px;
  height: 14px;
  color: var(--accent-gold);
}

.detail-card dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 0.75rem;
  margin: 0;
}

.detail-dl-2col {
  grid-template-columns: repeat(2, auto 1fr);
}

.detail-card dt {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.detail-card dd {
  font-size: 0.8rem;
  color: var(--text-primary);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.color-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.detail-notes-line {
  margin: 0.75rem 0 0;
  font-size: 0.8rem;
  color: var(--text-primary);
}

.order-3d-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.5rem;
  border: 1px dashed var(--border);
  border-radius: 10px;
  color: var(--text-muted);
  text-align: center;
}

.order-3d-preview svg {
  width: 32px;
  height: 32px;
  opacity: 0.5;
}

.order-3d-preview p {
  margin: 0;
  font-size: 0.75rem;
}

.order-3d-preview-img {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.15);
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.btn-primary {
  background: var(--accent-gold);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.5rem 1.1rem;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s var(--ease);
}

.btn-primary:hover {
  background: var(--gold-light);
}

.btn-danger {
  background: transparent;
  color: var(--status-storniert);
  border: 1px solid var(--status-storniert);
  border-radius: var(--radius-sm);
  padding: 0.5rem 1.1rem;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s var(--ease);
}

.btn-danger:hover {
  background: rgba(231, 76, 60, 0.12);
}

.detail-notes-textarea {
  width: 100%;
  resize: vertical;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.82rem;
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.6rem;
}

.detail-notes-textarea:focus {
  outline: none;
  border-color: var(--accent-gold);
}

.detail-price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.detail-price-row strong {
  color: var(--text-primary);
  font-weight: 700;
}

.detail-price-total {
  color: var(--accent-gold);
  font-size: 0.95rem;
}

.detail-price-total strong {
  color: var(--accent-gold);
  font-size: 0.82rem;
}

/* ============================================================
   KALENDER PAGE
   ============================================================ */
.kalender-grid {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 1.5rem;
  align-items: start;
}

.cal-card {
  margin-bottom: 0;
}

.cal-toolbar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.view-toggle {
  display: flex;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 4px;
}

.view-toggle button {
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.8rem;
  cursor: pointer;
}

.view-toggle button.is-active {
  background: var(--accent-gold);
  color: #fff;
  font-weight: 600;
}

.cal-nav-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.cal-nav-btn svg {
  width: 16px;
  height: 16px;
}

.cal-today-btn {
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--gold-light);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.cal-month-select {
  margin-left: auto;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 500;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.cal-head {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.cal-cell {
  min-height: 90px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 0.4rem 0.5rem;
  cursor: pointer;
  transition: background 0.15s var(--ease);
}

.cal-cell:hover {
  background: rgba(255, 255, 255, 0.03);
}

.cal-cell.is-outside {
  background: rgba(0, 0, 0, 0.1);
  cursor: pointer;
}

.cal-cell.is-outside .cal-day-num {
  color: rgba(255, 255, 255, 0.2);
}

.cal-cell.is-today {
  background: var(--accent-gold);
  border-color: var(--accent-gold);
}

.cal-cell.is-today .cal-day-num {
  color: #fff;
}

.cal-cell.is-selected {
  outline: 2px solid var(--accent-gold);
  outline-offset: -2px;
}

.cal-cell-top {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.cal-day-num {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
}

.cal-shape-counts {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.cal-shape-count {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 0.64rem;
  font-weight: 700;
  color: var(--text-primary);
}

.cal-shape-count svg {
  width: 15px;
  height: 15px;
  color: var(--accent-gold);
}

.cal-fertige-thumb,
.order-block-photo {
  width: 16px;
  height: 16px;
  object-fit: cover;
  border-radius: 3px;
}

.order-block-photo {
  width: 22px;
  height: 22px;
}

.cal-cell.is-today .cal-shape-count {
  color: #fff;
}

.cal-cell.is-today .cal-shape-count svg {
  color: #fff;
}

.cal-view-placeholder {
  min-height: 320px;
}

.cal-legend-bar {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.legend-title {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.legend-dot-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}

/* ---- Right panel ---- */
.right-panel {
  width: 100%;
}

.right-panel-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.right-panel-date svg {
  width: 16px;
  height: 16px;
  color: var(--accent-gold);
}

.stat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.stat-row-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.stat-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(196, 127, 42, 0.15);
  color: var(--accent-gold);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.stat-icon svg {
  width: 16px;
  height: 16px;
}

.stat-label-block {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-primary);
}

.stat-sublabel {
  font-size: 0.6rem;
  color: var(--text-muted);
}

.stat-count {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
}

.info-card {
  margin-top: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.85rem;
}

.info-card-header {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.6rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

.info-card-header svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

.info-card p {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0 0 0.4rem;
}

.info-card p:last-child {
  margin-bottom: 0;
}

.info-card .highlight {
  color: var(--gold-light);
}

.legend-card-header {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
}

.legend-row {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.legend-row .legend-dot {
  margin-top: 3px;
  width: 10px;
  height: 10px;
}

.legend-label {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-primary);
}

.legend-sublabel {
  font-size: 0.66rem;
  color: var(--text-muted);
}

/* ============================================================
   BESTELLUNGEN PAGE (Prompt 7)
   ============================================================ */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 1rem;
}

.filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.filter-field label {
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.filter-field select,
.filter-field input {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.82rem;
  padding: 0.5rem 0.75rem;
}

.filter-field select:focus,
.filter-field input:focus {
  outline: none;
  border-color: var(--accent-gold);
}

.filter-field-search input {
  min-width: 220px;
}

.pagination-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
}

.pagination-bar .btn-outline-sm:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pagination-info {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ============================================================
   BENACHRICHTIGUNGEN PAGE (Prompt 8)
   ============================================================ */
.notif-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 1rem;
}

.notif-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.notif-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.85rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.notif-row.is-unread {
  border-left: 3px solid var(--accent-gold);
  background: rgba(196, 127, 42, 0.06);
}

.notif-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(196, 127, 42, 0.15);
  color: var(--accent-gold);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.notif-icon svg {
  width: 16px;
  height: 16px;
}

.notif-body {
  flex: 1;
  min-width: 0;
}

.notif-top {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
}

.notif-type {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-primary);
}

.notif-time {
  font-size: 0.68rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.notif-message {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.notif-read-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ============================================================
   EINSTELLUNGEN PAGE (Prompt 8)
   ============================================================ */
.settings-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 420px;
}

.settings-time-row {
  display: flex;
  gap: 1rem;
}

.settings-time-row .filter-field {
  flex: 1;
}

.settings-form .btn-primary {
  align-self: flex-start;
}

/* ============================================================
   WEEK / DAY TIME GRID (Prompt 5)
   ============================================================ */
.time-grid-scroll {
  overflow-x: auto;
}

.time-grid {
  display: grid;
  border-top: 1px solid var(--border);
  border-left: 1px solid var(--border);
}

.time-grid-corner {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.time-grid-day-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.time-grid-day-header.is-today {
  color: var(--gold-light);
  background: rgba(196, 127, 42, 0.12);
}

.time-grid-day .time-grid-day-header {
  flex-direction: row;
  font-size: 0.85rem;
  text-transform: capitalize;
}

.day-header-num {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
}

.time-grid-label {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 0 0.5rem;
  font-size: 0.68rem;
  color: var(--text-muted);
  border-right: 1px solid var(--border);
  transform: translateY(-0.5em);
}

.time-grid-slot {
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.12s var(--ease);
}

.time-grid-slot.is-drop-target {
  background: rgba(196, 127, 42, 0.2);
}

.order-block {
  margin: 1px;
  padding: 0.25rem 0.4rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  overflow: hidden;
  cursor: grab;
  font-size: 0.68rem;
  line-height: 1.3;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  transition: opacity 0.15s var(--ease);
}

.order-block.is-dragging {
  opacity: 0.4;
}

.order-block-time {
  font-weight: 700;
  flex-shrink: 0;
}

.order-block-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-block-shape {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 1px;
}

.order-block-shape svg {
  width: 14px;
  height: 14px;
  color: currentColor;
}

/* ============================================================
   TOASTS
   ============================================================ */
.toast-container {
  position: fixed;
  top: calc(var(--topbar-h) + 1rem);
  right: 1.5rem;
  z-index: 300;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.toast {
  min-width: 280px;
  max-width: 360px;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-left: 3px solid var(--text-muted);
  color: var(--text-primary);
  font-size: 0.85rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  animation: toast-in 0.2s var(--ease);
}

.toast-success {
  border-left-color: var(--status-fertig);
}

.toast-error {
  border-left-color: var(--status-storniert);
}

.toast-info {
  border-left-color: var(--status-in-arbeit);
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   MODAL
   ============================================================ */
.admin-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
}

/* The rounded shape + clip now live here, on the OUTER wrapper — the panel
   inside still gets its own real, working overflow-y: auto scrollbar, but
   since the panel itself sits fully inside this wrapper's rounded box, the
   wrapper's overflow:hidden clips just the part of the scrollbar track
   that would otherwise poke past the rounded corners, without hiding or
   disabling the scrollbar itself. */
.admin-modal-panel-wrap {
  width: 100%;
  max-width: 780px;
  max-height: 85vh;
  margin: 0 1rem;
  border-radius: 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  overflow: hidden;
}

.admin-modal-panel {
  position: relative;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 1.5rem;
  color: var(--text-primary);
}

.admin-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--text-muted);
}

.admin-modal-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

.admin-modal-close svg {
  width: 18px;
  height: 18px;
}

body.modal-open {
  overflow: hidden;
}

.detail-thumb {
  display: inline-block;
  transition: opacity 0.15s var(--ease);
}

.detail-thumb:hover {
  opacity: 0.85;
}

.detail-download-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.5rem;
}

.detail-download-link svg {
  width: 14px;
  height: 14px;
}

/* ============================================================
   IMAGE LIGHTBOX (foto / cake preview fullscreen view)
   ============================================================ */
.image-lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
  padding: 2rem;
}

.image-lightbox-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  max-width: min(90vw, 900px);
}

.image-lightbox-panel img {
  max-width: 100%;
  max-height: 78vh;
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.image-lightbox-close {
  position: absolute;
  top: -44px;
  right: 0;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  cursor: pointer;
}

.image-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.image-lightbox-close svg {
  width: 18px;
  height: 18px;
}

.image-lightbox-download {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.image-lightbox-download svg {
  width: 16px;
  height: 16px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 1024px) {
  .admin-name-block {
    display: none;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .kalender-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .order-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile: circle tab bar (shop-style), no hamburger drawer */
@media (max-width: 768px) {
  .hamburger,
  .sidebar,
  .sidebar-overlay {
    display: none !important;
  }

  .topbar {
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    padding: 0 1rem;
  }

  .topbar-search {
    display: none;
  }

  .main-content {
    margin-left: 0;
    padding: 1.25rem 1.25rem calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 1rem);
  }

  /* iOS Safari zooms the page into any focused field below 16px. */
  input:not([type="checkbox"]):not([type="radio"]),
  select,
  .filter-field select,
  select.locale-select,
  textarea {
    font-size: 16px;
  }

  /* Finger-sized tap targets for the small inline buttons. */
  .btn-outline-sm,
  .view-toggle button,
  .cal-today-btn {
    min-height: 40px;
  }

  .cal-nav-btn {
    width: 40px;
    height: 40px;
  }

  /* View switch on its own row, so ‹ Heute › and the month stay together below. */
  .cal-toolbar .view-toggle {
    flex: 1 0 100%;
  }

  .cal-toolbar .view-toggle button {
    flex: 1;
  }

  .cal-toolbar .cal-month-select {
    flex: 1;
    min-width: 0;
  }

  .admin-tabbar {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 120;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: var(--tabbar-h);
    padding: 0.45rem 0.75rem calc(0.45rem + env(safe-area-inset-bottom));
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
  }

  .admin-tabbar::-webkit-scrollbar {
    display: none;
  }

  .tabbar-item {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    color: var(--text-muted);
  }

  .tabbar-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border);
    transition:
      background 0.18s var(--ease),
      color 0.18s var(--ease),
      border-color 0.18s var(--ease);
  }

  .tabbar-item.is-active {
    color: #fff;
  }

  .tabbar-item.is-active .tabbar-circle {
    background: var(--accent-gold);
    border-color: var(--accent-gold);
    color: #fff;
  }

  .tabbar-circle .nav-icon,
  .tabbar-circle .nav-icon svg {
    width: 22px;
    height: 22px;
  }

  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .order-grid {
    grid-template-columns: 1fr;
  }

  .order-grid-media {
    flex-basis: 38%;
  }

  .order-grid-info .order-grid-row {
    white-space: normal;
  }

  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-dl-2col {
    grid-template-columns: auto 1fr;
  }

  .cal-cell {
    min-height: 64px;
    padding: 0.3rem 0.2rem;
    overflow: hidden;
  }

  .cal-cell-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
  }

  .cal-shape-counts {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.1rem;
  }

  .cal-shape-count svg {
    width: 12px;
    height: 12px;
  }
}

@media (max-width: 380px) {
  .admin-name-block {
    display: none;
  }
}

.locale-select {
  margin-right: 0.5rem;
  border: 1px solid var(--border, #d9d3c5);
  background: #fff;
  border-radius: 999px;
  padding: 0.25rem 0.45rem;
  font: inherit;
  font-size: 0.75rem;
}

html[dir="rtl"] .sidebar {
  left: auto;
  right: 0;
}

html[dir="rtl"] .admin-tabbar,
html[dir="rtl"] .topbar-right {
  flex-direction: row-reverse;
}
