:root {
  color-scheme: light;
  --bg: #fff7f4;
  --surface: #ffffff;
  --surface-strong: #fff0eb;
  --ink: #211b1b;
  --muted: #716565;
  --line: #ead6cf;
  --primary: #d71920;
  --primary-deep: #a90f17;
  --primary-soft: #ffe2df;
  --green: #18794e;
  --green-soft: #e2f6ea;
  --yellow: #f4b400;
  --shadow: 0 16px 45px rgba(85, 24, 16, 0.12);
  --radius: 8px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100%;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(215, 25, 32, 0.1), transparent 42%),
    var(--bg);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.login-screen {
  display: grid;
  min-height: 100vh;
  min-height: 100svh;
  place-items: center;
  padding: 20px;
  background:
    radial-gradient(circle at 18% 16%, rgba(215, 25, 32, 0.18), transparent 28%),
    radial-gradient(circle at 85% 82%, rgba(244, 180, 0, 0.2), transparent 24%),
    var(--bg);
}

.login-card {
  display: grid;
  width: min(500px, 100%);
  gap: 18px;
  padding: 24px;
}

.login-logo-frame,
.header-logo-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(215, 25, 32, 0.22);
  background: #fff;
  box-shadow: 0 12px 30px rgba(126, 25, 18, 0.13);
}

.login-logo-frame::after,
.header-logo-frame::after {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: inherit;
  content: "";
  pointer-events: none;
}

.login-logo-frame {
  width: 100%;
  aspect-ratio: 1.85 / 1;
  border-radius: 16px;
}

.header-logo-frame {
  width: clamp(270px, 29vw, 350px);
  aspect-ratio: 2.1 / 1;
  flex: 0 1 auto;
  border-radius: 14px;
}

.login-logo-frame img,
.header-logo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 50%;
}

.login-card h1 {
  font-size: 2.4rem;
}

.login-intro,
.login-note {
  color: var(--muted);
}

.login-intro {
  margin: 10px 0 0;
  font-size: 1rem;
}

.login-note {
  margin: 0;
  font-size: 0.82rem;
  text-align: center;
}

.login-form {
  display: grid;
  gap: 14px;
}

.login-error {
  min-height: 1.3rem;
  margin: -4px 0 0;
  color: var(--primary-deep);
  font-size: 0.88rem;
  font-weight: 800;
}

.app-shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 20px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.topbar-actions {
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  gap: 10px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 3rem;
  line-height: 1;
}

h2 {
  margin-bottom: 4px;
  font-size: 1.25rem;
}

.panel-heading p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.shift-card,
.account-card,
.owner-toolbar,
.owner-analytics,
.login-card,
.quick-stats article,
.order-panel,
.cart-panel,
.history-section,
.stock-overview-section,
.payment-card,
.dialog-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow);
}

.shift-card {
  min-width: 220px;
  padding: 14px 16px;
  text-align: right;
}

.account-card {
  display: flex;
  min-width: 210px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
}

.account-card > div {
  display: grid;
  gap: 2px;
}

.account-card span,
.toolbar-label {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.account-card strong {
  font-size: 1rem;
}

.owner-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-color: rgba(215, 25, 32, 0.32);
  background: linear-gradient(100deg, rgba(255, 226, 223, 0.92), rgba(255, 255, 255, 0.92));
  box-shadow: 0 10px 30px rgba(85, 24, 16, 0.08);
}

.owner-toolbar > div:first-child {
  display: grid;
  min-width: 210px;
  gap: 3px;
}

.owner-toolbar strong {
  font-size: 0.96rem;
}

.toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.owner-analytics {
  margin-bottom: 14px;
  padding: 16px;
  border-color: rgba(215, 25, 32, 0.22);
  box-shadow: 0 10px 30px rgba(85, 24, 16, 0.08);
}

.analytics-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.analytics-heading .eyebrow {
  margin-bottom: 3px;
}

.analytics-heading h2,
.analytics-heading p {
  margin-bottom: 0;
}

.analytics-heading > p {
  max-width: 520px;
  color: var(--muted);
  font-size: 0.84rem;
  text-align: right;
}

.analytics-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.analytics-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 15px;
  background: var(--surface);
}

.analytics-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--primary);
  content: "";
}

.analytics-week::before {
  background: var(--yellow);
}

.analytics-month::before {
  background: var(--green);
}

.analytics-card-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.analytics-card-heading span {
  font-size: 0.86rem;
  font-weight: 900;
  text-transform: uppercase;
}

.analytics-card-heading small {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analytics-revenue {
  display: block;
  overflow-wrap: anywhere;
  margin: 10px 0 13px;
  color: var(--primary-deep);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  line-height: 1;
}

.analytics-week .analytics-revenue {
  color: #8a5a00;
}

.analytics-month .analytics-revenue {
  color: var(--green);
}

.analytics-details {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.analytics-details div {
  min-width: 0;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}

.analytics-details dt {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
}

.analytics-details dd {
  overflow-wrap: anywhere;
  margin: 3px 0 0;
  font-size: 0.88rem;
  font-weight: 900;
}

.shift-card span,
.quick-stats span,
.totals span,
.change-row span {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.shift-card strong {
  display: block;
  margin-top: 3px;
  color: var(--primary-deep);
  font-size: 1.45rem;
}

.quick-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.cashier-quick-stats {
  grid-template-columns: repeat(2, minmax(180px, 1fr));
}

.quick-stats article {
  padding: 14px;
}

.quick-stats strong {
  display: block;
  margin-top: 6px;
  font-size: 1.35rem;
}

.queue-value {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
}

.queue-reset-button {
  min-height: 34px;
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  background: var(--primary-soft);
  color: var(--primary-deep);
  padding: 0 11px;
  font-size: 0.78rem;
  font-weight: 900;
}

.queue-reset-button:hover,
.queue-reset-button:focus-visible {
  background: var(--primary);
  color: #fff;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(360px, 0.9fr);
  gap: 14px;
  align-items: start;
}

.order-panel,
.cart-panel,
.history-section,
.stock-overview-section {
  padding: 16px;
}

.stock-overview-section {
  margin-bottom: 14px;
}

.stock-overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}

.stock-overview-card {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid #b9dfc9;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #f5fff8, var(--surface));
  padding: 12px;
}

.stock-overview-card.low {
  border-color: #efd078;
  background: linear-gradient(135deg, #fff8df, var(--surface));
}

.stock-overview-card.empty {
  border-color: rgba(215, 25, 32, 0.36);
  background: linear-gradient(135deg, var(--primary-soft), var(--surface));
}

.stock-overview-card > div:first-child {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.stock-overview-card > div:first-child strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stock-status {
  width: fit-content;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  padding: 3px 8px;
  font-size: 0.7rem;
  font-weight: 900;
}

.stock-overview-card.low .stock-status {
  background: #ffedb9;
  color: #765000;
}

.stock-overview-card.empty .stock-status {
  background: #ffd4d1;
  color: var(--primary-deep);
}

.stock-count {
  display: grid;
  flex: 0 0 auto;
  gap: 1px;
  text-align: right;
}

.stock-count span {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
}

.stock-count strong {
  color: var(--primary-deep);
  font-size: 1.45rem;
  line-height: 1;
}

.cart-panel {
  position: sticky;
  top: 12px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.ghost-button,
.icon-button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-weight: 800;
}

.ghost-button {
  padding: 0 14px;
  white-space: nowrap;
}

.ghost-button:hover,
.icon-button:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.ghost-button.danger {
  color: var(--primary-deep);
}

.icon-button {
  width: 42px;
}

.order-meta,
.editor-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.editor-form {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  align-items: end;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

input,
select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  padding: 0 12px;
  outline: none;
}

input:focus,
select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(215, 25, 32, 0.15);
}

.menu-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.45fr);
  gap: 10px;
  margin-bottom: 14px;
}

.category-tabs,
.payment-methods {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.category-tabs button,
.method {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  padding: 0 14px;
  font-weight: 800;
}

.category-tabs button.active,
.method.active {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

.search-box {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 0 12px;
}

.search-box input {
  min-height: 44px;
  border: 0;
  padding: 0;
  box-shadow: none;
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}

.menu-card {
  display: grid;
  position: relative;
  min-height: 134px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 14px;
  text-align: left;
  transition:
    transform 0.16s ease,
    border-color 0.16s ease,
    box-shadow 0.16s ease;
}

.menu-card:hover:not(:disabled),
.menu-card:focus-visible:not(:disabled) {
  border-color: var(--primary);
  box-shadow: 0 10px 24px rgba(215, 25, 32, 0.13);
  transform: translateY(-2px);
}

.menu-card .category {
  width: fit-content;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary-deep);
  padding: 4px 9px;
  font-size: 0.74rem;
  font-weight: 900;
}

.menu-card strong {
  align-self: end;
  font-size: 1rem;
}

.menu-card .menu-price {
  align-self: end;
  color: var(--primary-deep);
  font-size: 1.12rem;
  font-weight: 900;
}

.stock-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  padding: 4px 8px;
  font-size: 0.72rem;
  font-weight: 900;
}

.stock-badge.low {
  background: #fff0c8;
  color: #815a00;
}

.stock-badge.empty {
  background: var(--primary-soft);
  color: var(--primary-deep);
}

.menu-card.out-of-stock {
  cursor: not-allowed;
  filter: grayscale(0.35);
  opacity: 0.58;
}

.cart-list {
  display: grid;
  gap: 10px;
  min-height: 96px;
}

.empty-state {
  display: grid;
  place-items: center;
  min-height: 96px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  text-align: center;
}

.cart-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 12px;
}

.cart-main,
.history-item,
.editor-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.cart-title {
  display: grid;
  gap: 3px;
}

.cart-title strong,
.history-item strong {
  font-size: 0.98rem;
}

.cart-title span,
.history-item span,
.editor-row span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.qty-controls {
  display: grid;
  grid-template-columns: 38px 40px 38px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.qty-controls button {
  min-height: 38px;
  border: 0;
  background: var(--surface-strong);
  color: var(--primary-deep);
  font-weight: 900;
}

.qty-controls output {
  text-align: center;
  font-weight: 900;
}

.cart-options {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.cart-options.with-flavor {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cart-option-field {
  display: grid;
  gap: 5px;
}

.cart-option-field > span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.cart-note-field {
  grid-column: 1 / -1;
}

.cart-option-field select,
.cart-option-field input {
  min-height: 40px;
}

.payment-card {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  box-shadow: none;
}

.totals {
  display: grid;
  gap: 10px;
}

.totals > div,
.change-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.totals label {
  grid-template-columns: 1fr minmax(150px, 0.45fr);
  align-items: center;
}

.totals label input {
  text-align: right;
}

.grand-total {
  border-top: 1px solid var(--line);
  padding-top: 10px;
}

.grand-total strong {
  color: var(--primary-deep);
  font-size: 1.7rem;
}

.cash-row {
  grid-template-columns: 1fr minmax(160px, 0.55fr);
  align-items: center;
}

.cash-row input {
  text-align: right;
}

.change-row {
  border-radius: var(--radius);
  background: var(--green-soft);
  color: var(--green);
  padding: 12px;
}

.change-row strong {
  font-size: 1.2rem;
}

.checkout-button {
  min-height: 52px;
  border: 0;
  border-radius: var(--radius);
  background: var(--primary);
  color: #fff;
  padding: 0 16px;
  font-weight: 900;
}

.checkout-button:hover:not(:disabled) {
  background: var(--primary-deep);
}

.checkout-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.checkout-button.small {
  min-height: 46px;
}

.history-section {
  margin-top: 14px;
}

.history-filter {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr)) auto;
  align-items: end;
  gap: 10px;
  margin-bottom: 10px;
}

.history-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.history-presets button {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
  color: var(--primary-deep);
  padding: 0 12px;
  font-size: 0.82rem;
  font-weight: 900;
}

.history-presets button:hover,
.history-presets button:focus-visible {
  border-color: var(--primary);
  background: var(--primary-soft);
}

.history-filter-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  margin-bottom: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.history-filter-summary > div {
  display: grid;
  min-width: 0;
  gap: 4px;
  background: var(--surface-strong);
  padding: 11px 12px;
}

.history-filter-summary span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.history-filter-summary strong {
  overflow-wrap: anywhere;
  color: var(--primary-deep);
  font-size: 1rem;
}

.history-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px;
}

.history-item {
  display: grid;
  align-items: stretch;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 12px;
}

.history-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.history-main > div {
  display: grid;
  gap: 4px;
}

.history-total {
  flex: 0 0 auto;
  color: var(--primary-deep);
  font-size: 1rem;
}

.history-actions {
  display: flex;
  gap: 7px;
}

.history-actions button {
  flex: 1;
}

.history-actions button,
.editor-row button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
  color: var(--primary-deep);
  padding: 0 10px;
  font-weight: 850;
}

.history-actions .history-delete {
  border-color: rgba(215, 25, 32, 0.3);
  background: var(--primary-soft);
  color: var(--primary-deep);
}

.menu-dialog {
  width: min(880px, calc(100% - 28px));
  border: 0;
  padding: 0;
  background: transparent;
}

.menu-dialog::backdrop {
  background: rgba(33, 27, 27, 0.45);
}

.dialog-card {
  max-height: min(86vh, 760px);
  overflow: auto;
  padding: 16px;
}

.menu-editor {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.stock-editor,
.account-editor {
  display: grid;
  gap: 10px;
}

.stock-row {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) 64px minmax(120px, 0.55fr) auto;
  align-items: end;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 12px;
}

.stock-row.low {
  border-color: rgba(244, 180, 0, 0.62);
  background: #fffaf0;
}

.stock-name,
.account-editor article > div {
  display: grid;
  align-self: center;
  gap: 3px;
}

.stock-name span,
.account-editor article span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.stock-row output {
  align-self: center;
  color: var(--primary-deep);
  font-size: 1.7rem;
  font-weight: 950;
  text-align: center;
}

.stock-row input {
  min-height: 42px;
}

.stock-actions {
  display: flex;
  gap: 7px;
}

.stock-actions .ghost-button {
  min-height: 42px;
}

.account-editor article {
  display: grid;
  grid-template-columns: minmax(120px, 0.55fr) minmax(220px, 1fr) auto;
  align-items: end;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 12px;
}

.editor-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 10px;
}

.editor-row label {
  grid-template-columns: auto 130px;
  align-items: center;
}

.editor-row input {
  min-height: 38px;
  text-align: right;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 5;
  max-width: min(360px, calc(100vw - 36px));
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  padding: 12px 14px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
  pointer-events: none;
}

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

.print-receipt {
  display: none;
}

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

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

  .history-presets {
    grid-column: 1 / -1;
  }

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

  .cart-panel {
    position: static;
  }
}

@media (max-width: 720px) {
  .app-shell {
    padding: 12px;
  }

  .topbar,
  .owner-toolbar,
  .analytics-heading,
  .panel-heading,
  .cart-main,
  .history-item,
  .editor-row {
    align-items: stretch;
    flex-direction: column;
  }

  .shift-card {
    text-align: left;
  }

  .topbar-actions {
    width: 100%;
    flex-direction: column;
  }

  .header-logo-frame {
    width: min(360px, 100%);
  }

  .shift-card,
  .account-card {
    width: 100%;
  }

  .owner-toolbar {
    align-items: stretch;
  }

  .analytics-heading > p {
    max-width: none;
    text-align: left;
  }

  .toolbar-actions {
    justify-content: stretch;
  }

  .toolbar-actions .ghost-button {
    flex: 1 1 140px;
  }

  .quick-stats,
  .order-meta,
  .editor-form,
  .menu-tools,
  .cart-options,
  .history-filter,
  .history-filter-summary {
    grid-template-columns: 1fr;
  }

  .history-presets {
    grid-column: auto;
  }

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

  .menu-card {
    min-height: 126px;
  }

  h1 {
    font-size: 2.15rem;
  }

  .stock-row,
  .account-editor article {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .stock-row output {
    text-align: left;
  }

  .stock-actions .ghost-button {
    flex: 1;
  }
}

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

  .totals label,
  .cash-row {
    grid-template-columns: 1fr;
  }
}

@page {
  margin: 0;
}

@media print {
  html,
  body {
    width: 58mm;
    min-height: 0;
  }

  body {
    padding: 2mm 5mm;
    background: #fff;
  }

  .app-shell,
  .login-screen,
  .menu-dialog,
  .toast {
    display: none !important;
  }

  .print-receipt {
    display: block;
    width: 48mm;
    margin: 0 auto;
    color: #000;
    font-family: "Courier New", Courier, monospace;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.25;
    letter-spacing: 0;
    overflow-wrap: anywhere;
  }

  .print-receipt h1 {
    margin: 0 0 6px;
    text-align: center;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.15;
  }

  .receipt-line,
  .receipt-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 4px;
    margin-bottom: 1px;
  }

  .receipt-line > :first-child,
  .receipt-row > :first-child {
    min-width: 0;
  }

  .receipt-line > :last-child,
  .receipt-row > :last-child {
    text-align: right;
  }

  .receipt-line > :last-child {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .receipt-row > :last-child,
  .receipt-line > strong:last-child {
    flex-shrink: 0;
    white-space: nowrap;
  }

  .receipt-line strong {
    font-size: 13px;
  }

  .receipt-divider {
    border-top: 1px dashed #000;
    margin: 5px 0;
  }

  .print-receipt p {
    margin: 7px 0 0;
  }
}

/* Visual refresh — presentation only. Application structure and behavior stay unchanged. */
@media screen {
  :root {
    --bg: #fff4e6;
    --surface: #ffffff;
    --surface-strong: #fff9f2;
    --ink: #292323;
    --muted: #756763;
    --line: #efd9c8;
    --primary: #d71920;
    --primary-deep: #a90f16;
    --primary-soft: #ffe5e1;
    --orange: #f47a20;
    --orange-soft: #fff0df;
    --yellow: #ffb629;
    --yellow-soft: #fff7dc;
    --green: #24a866;
    --green-soft: #e7f8ef;
    --shadow: 0 10px 28px rgba(104, 39, 18, 0.08);
    --shadow-hover: 0 15px 34px rgba(128, 38, 15, 0.13);
    --radius: 14px;
    font-family:
      Inter, Poppins, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
      "Segoe UI", sans-serif;
  }

  html {
    background: var(--bg);
  }

  body {
    font-size: 1rem;
    line-height: 1.5;
    background:
      radial-gradient(circle at 8% 4%, rgba(255, 182, 41, 0.18), transparent 24rem),
      radial-gradient(circle at 95% 24%, rgba(244, 122, 32, 0.1), transparent 28rem),
      radial-gradient(circle at 20% 92%, rgba(215, 25, 32, 0.06), transparent 25rem),
      radial-gradient(circle, rgba(169, 15, 22, 0.045) 1px, transparent 1.5px),
      var(--bg);
    background-attachment: fixed;
    background-position: center, center, center, 0 0, center;
    background-size: auto, auto, auto, 34px 34px, auto;
  }

  button,
  input,
  select {
    transition:
      border-color 0.18s ease,
      background-color 0.18s ease,
      color 0.18s ease,
      box-shadow 0.18s ease,
      transform 0.18s ease;
  }

  button:focus-visible,
  input:focus-visible,
  select:focus-visible {
    outline: 3px solid rgba(255, 182, 41, 0.5);
    outline-offset: 2px;
  }

  .login-screen {
    padding: 24px;
    background:
      radial-gradient(circle at 14% 18%, rgba(215, 25, 32, 0.14), transparent 25rem),
      radial-gradient(circle at 90% 85%, rgba(255, 182, 41, 0.24), transparent 24rem),
      radial-gradient(circle, rgba(244, 122, 32, 0.05) 1px, transparent 1.5px),
      var(--bg);
    background-size: auto, auto, 32px 32px, auto;
  }

  .login-card {
    width: min(470px, 100%);
    gap: 18px;
    padding: 26px 28px;
    border: 1px solid rgba(244, 122, 32, 0.22);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 24px 60px rgba(112, 37, 14, 0.14);
    backdrop-filter: blur(10px);
  }

  .login-logo-frame,
  .header-logo-frame {
    overflow: visible;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .login-logo-frame::after,
  .header-logo-frame::after {
    display: none;
  }

  .login-logo-frame {
    display: grid;
    width: 100%;
    height: 96px;
    aspect-ratio: auto;
    overflow: hidden;
    place-items: center;
  }

  .login-logo-frame img,
  .header-logo-frame img {
    object-fit: contain;
    object-position: center;
    filter: drop-shadow(0 10px 12px rgba(85, 19, 8, 0.2));
  }

  .login-logo-frame img {
    width: auto;
    max-width: 100%;
    height: 90px;
    max-height: 90px;
  }

  .login-card h1 {
    margin-bottom: 0;
    color: var(--ink);
    font-size: clamp(1.85rem, 7vw, 2.25rem);
    letter-spacing: -0.035em;
  }

  .login-card .eyebrow {
    color: var(--orange);
  }

  .login-intro {
    margin-top: 6px;
    font-size: 0.94rem;
  }

  .login-note {
    font-size: 0.78rem;
  }

  .login-error {
    font-size: 0.875rem;
  }

  .app-shell {
    width: min(1440px, 100%);
    padding: 22px;
  }

  .topbar {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    gap: 18px;
    margin-bottom: 16px;
    padding: 14px 18px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 20px;
    background: linear-gradient(118deg, var(--primary-deep) 0%, var(--primary) 50%, var(--orange) 100%);
    box-shadow: 0 16px 36px rgba(169, 15, 22, 0.24);
  }

  .topbar::before {
    position: absolute;
    z-index: -1;
    inset: 0;
    background:
      radial-gradient(circle at 78% 18%, rgba(255, 255, 255, 0.16) 0 2px, transparent 2.5px),
      radial-gradient(circle at 88% 72%, rgba(255, 182, 41, 0.22) 0 3px, transparent 3.5px),
      radial-gradient(circle at 52% 115%, transparent 0 75px, rgba(255, 255, 255, 0.1) 76px 77px, transparent 78px);
    background-size: 28px 28px, 52px 52px, auto;
    content: "";
    opacity: 0.75;
  }

  .header-logo-frame {
    display: grid;
    width: 220px;
    height: 112px;
    aspect-ratio: auto;
    flex: 0 0 220px;
    place-items: center;
  }

  .topbar-actions {
    position: relative;
    z-index: 1;
    gap: 10px;
  }

  .shift-card,
  .account-card {
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 8px 22px rgba(92, 23, 8, 0.14);
    backdrop-filter: blur(8px);
  }

  .shift-card {
    min-width: 210px;
    padding: 13px 15px;
  }

  .shift-card span,
  .account-card span {
    color: #7a615b;
    font-size: 0.75rem;
    letter-spacing: 0.04em;
  }

  .shift-card strong {
    margin-top: 2px;
    color: var(--primary-deep);
    font-size: 1.55rem;
    letter-spacing: -0.03em;
  }

  .account-card {
    min-width: 220px;
    padding: 10px 12px 10px 15px;
  }

  .account-card strong {
    color: var(--ink);
    font-size: 1.02rem;
  }

  #logoutButton {
    border-color: rgba(215, 25, 32, 0.18);
    background: var(--primary-soft);
    color: var(--primary-deep);
    box-shadow: none;
  }

  #logoutButton:hover {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
  }

  .owner-toolbar,
  .owner-analytics,
  .quick-stats article,
  .order-panel,
  .cart-panel,
  .history-section,
  .stock-overview-section,
  .payment-card,
  .dialog-card {
    border: 1px solid rgba(224, 188, 162, 0.58);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
  }

  .owner-toolbar {
    margin-bottom: 16px;
    padding: 14px 16px;
    border-color: rgba(244, 122, 32, 0.24);
    background: linear-gradient(100deg, #fffaf4, #ffffff);
  }

  .toolbar-label {
    color: var(--orange);
    font-size: 0.75rem;
    letter-spacing: 0.06em;
  }

  .owner-toolbar strong {
    color: var(--ink);
    font-size: 0.98rem;
  }

  .toolbar-actions {
    gap: 8px;
  }

  .ghost-button,
  .icon-button {
    min-height: 42px;
    border-color: #ead4c4;
    border-radius: 11px;
    background: #fffaf5;
    color: #4b3732;
    font-size: 0.875rem;
    box-shadow: 0 3px 10px rgba(102, 38, 17, 0.05);
  }

  .ghost-button:hover,
  .icon-button:hover {
    border-color: rgba(215, 25, 32, 0.42);
    background: var(--primary-soft);
    color: var(--primary-deep);
    box-shadow: 0 7px 16px rgba(126, 34, 14, 0.1);
    transform: translateY(-1px);
  }

  .toolbar-actions .ghost-button {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0 13px;
  }

  .toolbar-actions .ghost-button::before {
    display: inline-grid;
    width: 22px;
    height: 22px;
    border-radius: 7px;
    place-items: center;
    background: var(--primary-soft);
    color: var(--primary-deep);
    font-size: 0.82rem;
    font-weight: 950;
    line-height: 1;
  }

  #openStockManager::before {
    content: "+";
  }

  #openMenuManager::before {
    content: "✎";
  }

  #exportSales::before {
    content: "⇩";
  }

  #resetQueue::before {
    content: "↻";
  }

  #openAccountManager::before {
    content: "●";
    font-size: 0.58rem;
  }

  .owner-analytics {
    margin-bottom: 16px;
    padding: 19px;
  }

  .analytics-heading {
    margin-bottom: 16px;
  }

  .analytics-heading h2,
  .panel-heading h2 {
    color: var(--ink);
    font-size: 1.3rem;
    letter-spacing: -0.02em;
  }

  .analytics-heading > p,
  .panel-heading p {
    color: var(--muted);
    font-size: 0.875rem;
  }

  .eyebrow {
    color: var(--primary);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
  }

  .analytics-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
  }

  .analytics-card {
    min-height: 190px;
    border-radius: 14px;
    padding: 17px 17px 15px 19px;
    box-shadow: 0 6px 18px rgba(83, 35, 21, 0.06);
  }

  .analytics-card::before {
    width: 5px;
    border-radius: 0 10px 10px 0;
  }

  .analytics-day {
    border-color: rgba(215, 25, 32, 0.2);
    background: linear-gradient(145deg, #fff0ee, #ffffff 70%);
  }

  .analytics-week {
    border-color: rgba(244, 122, 32, 0.24);
    background: linear-gradient(145deg, #fff3e4, #ffffff 70%);
  }

  .analytics-month {
    border-color: rgba(36, 168, 102, 0.22);
    background: linear-gradient(145deg, #eaf9f1, #ffffff 70%);
  }

  .analytics-week::before {
    background: var(--orange);
  }

  .analytics-month::before {
    background: var(--green);
  }

  .analytics-card-heading span {
    font-size: 0.84rem;
    letter-spacing: 0.045em;
  }

  .analytics-card-heading small {
    font-size: 0.75rem;
  }

  .analytics-revenue {
    margin: 13px 0 16px;
    font-size: clamp(1.7rem, 3vw, 2.25rem);
    letter-spacing: -0.045em;
  }

  .analytics-week .analytics-revenue {
    color: #bd570e;
  }

  .analytics-details {
    gap: 10px;
  }

  .analytics-details div {
    border-top-color: rgba(108, 72, 58, 0.13);
  }

  .analytics-details dt {
    font-size: 0.75rem;
  }

  .analytics-details dd {
    font-size: 0.94rem;
  }

  .quick-stats {
    gap: 12px;
    margin-bottom: 16px;
  }

  .quick-stats article {
    position: relative;
    overflow: hidden;
    min-height: 106px;
    padding: 17px 58px 15px 16px;
    border-top: 3px solid var(--primary);
  }

  .quick-stats article::before {
    position: absolute;
    top: 16px;
    right: 15px;
    display: grid;
    width: 36px;
    height: 36px;
    border-radius: 11px;
    place-items: center;
    background: var(--primary-soft);
    color: var(--primary-deep);
    content: "✓";
    font-size: 0.9rem;
    font-weight: 950;
  }

  .quick-stats article:nth-child(2) {
    border-top-color: var(--orange);
  }

  .quick-stats article:nth-child(2)::before {
    background: var(--orange-soft);
    color: #b64f0b;
    content: "Rp";
    font-size: 0.72rem;
  }

  .quick-stats article:nth-child(3) {
    border-top-color: var(--yellow);
  }

  .quick-stats article:nth-child(3)::before {
    background: var(--yellow-soft);
    color: #976600;
    content: "▦";
  }

  .quick-stats article:nth-child(4) {
    border-top-color: var(--primary-deep);
  }

  .quick-stats article:nth-child(4)::before {
    background: var(--primary-soft);
    color: var(--primary-deep);
    content: "!";
  }

  .cashier-quick-stats article:nth-child(2)::before {
    content: "#";
    font-size: 0.9rem;
  }

  .quick-stats span,
  .shift-card span,
  .totals span,
  .change-row span {
    font-size: 0.82rem;
  }

  .quick-stats strong {
    margin-top: 8px;
    color: var(--ink);
    font-size: 1.55rem;
    letter-spacing: -0.035em;
  }

  .order-panel,
  .cart-panel,
  .history-section,
  .stock-overview-section {
    padding: 18px;
  }

  .stock-overview-section {
    margin-bottom: 16px;
  }

  .panel-heading {
    margin-bottom: 16px;
  }

  label {
    color: #675752;
    font-size: 0.875rem;
  }

  input,
  select {
    min-height: 46px;
    border-color: #e8d1c0;
    border-radius: 11px;
    background: #fffcf9;
    color: var(--ink);
    font-size: 0.94rem;
    box-shadow: inset 0 1px 2px rgba(86, 39, 23, 0.025);
  }

  input:hover,
  select:hover {
    border-color: rgba(244, 122, 32, 0.52);
  }

  input:focus,
  select:focus {
    border-color: var(--primary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(215, 25, 32, 0.1);
  }

  .category-tabs,
  .payment-methods {
    gap: 7px;
  }

  .category-tabs button,
  .method {
    min-height: 43px;
    border-color: #e9d3c3;
    border-radius: 11px;
    background: #fffaf5;
    color: #5e4841;
    font-size: 0.84rem;
  }

  .category-tabs button:hover,
  .method:hover {
    border-color: rgba(215, 25, 32, 0.4);
    background: var(--primary-soft);
    color: var(--primary-deep);
    transform: translateY(-1px);
  }

  .category-tabs button.active,
  .method.active {
    border-color: transparent;
    background: linear-gradient(120deg, var(--primary), var(--orange));
    color: #fff;
    box-shadow: 0 7px 15px rgba(215, 25, 32, 0.19);
  }

  .search-box {
    border-color: #e8d1c0;
    border-radius: 11px;
    background: #fffcf9;
  }

  .search-box span {
    color: var(--primary);
    font-size: 0.82rem;
  }

  .menu-grid {
    gap: 11px;
  }

  .menu-card {
    min-height: 136px;
    border-color: #eddbcd;
    border-radius: 14px;
    background: linear-gradient(145deg, #ffffff, #fffaf5);
    box-shadow: 0 5px 14px rgba(94, 42, 25, 0.055);
  }

  .menu-card:hover:not(:disabled),
  .menu-card:focus-visible:not(:disabled) {
    border-color: rgba(215, 25, 32, 0.48);
    box-shadow: var(--shadow-hover);
    transform: translateY(-3px);
  }

  .menu-card .category {
    background: var(--orange-soft);
    color: #aa4b0e;
    font-size: 0.74rem;
  }

  .menu-card strong {
    color: var(--ink);
    font-size: 1rem;
  }

  .menu-card .menu-price {
    color: var(--primary-deep);
    font-size: 1.14rem;
  }

  .stock-badge {
    background: var(--green-soft);
    color: #147c46;
  }

  .stock-badge.low {
    background: #fff0cf;
    color: #a86000;
  }

  .stock-badge.empty {
    background: var(--primary-soft);
    color: var(--primary-deep);
  }

  .empty-state {
    border-color: #e6cdbb;
    border-radius: 12px;
    background: rgba(255, 249, 242, 0.68);
    color: var(--muted);
    font-size: 0.9rem;
  }

  .cart-item,
  .history-item,
  .editor-row,
  .stock-row,
  .account-editor article {
    border-color: #ead6c7;
    border-radius: 12px;
    background: #fffdfb;
    box-shadow: 0 4px 12px rgba(92, 41, 24, 0.045);
  }

  .cart-title span,
  .history-item span,
  .editor-row span,
  .stock-name span,
  .account-editor article span {
    font-size: 0.78rem;
  }

  .qty-controls {
    border-color: #ead3c2;
    border-radius: 10px;
  }

  .qty-controls button {
    background: var(--orange-soft);
    color: var(--primary-deep);
  }

  .qty-controls button:hover {
    background: var(--primary);
    color: #fff;
  }

  .cart-option-field > span {
    font-size: 0.78rem;
  }

  .payment-card {
    border-color: rgba(244, 122, 32, 0.2);
    background: linear-gradient(145deg, #fffaf4, #ffffff);
    box-shadow: none;
  }

  .grand-total {
    border-top-color: #ead4c3;
  }

  .grand-total strong {
    color: var(--primary-deep);
    font-size: 1.8rem;
    letter-spacing: -0.04em;
  }

  .change-row {
    border: 1px solid rgba(36, 168, 102, 0.17);
    border-radius: 11px;
    background: var(--green-soft);
    color: #137844;
  }

  .checkout-button {
    border-radius: 12px;
    background: linear-gradient(120deg, var(--primary), var(--orange));
    font-size: 0.94rem;
    box-shadow: 0 10px 20px rgba(215, 25, 32, 0.2);
  }

  .checkout-button:hover:not(:disabled) {
    background: linear-gradient(120deg, var(--primary-deep), #dc5d15);
    box-shadow: 0 13px 24px rgba(169, 15, 22, 0.25);
    transform: translateY(-2px);
  }

  .stock-overview-grid {
    gap: 11px;
  }

  .stock-overview-card {
    min-height: 82px;
    border-color: rgba(36, 168, 102, 0.24);
    border-radius: 12px;
    background: linear-gradient(145deg, #f3fcf7, #ffffff);
    box-shadow: 0 5px 14px rgba(43, 106, 67, 0.06);
    padding: 13px;
  }

  .stock-overview-card:hover {
    box-shadow: 0 9px 20px rgba(69, 64, 45, 0.1);
    transform: translateY(-2px);
  }

  .stock-overview-card.low {
    border-color: rgba(244, 122, 32, 0.36);
    background: linear-gradient(145deg, #fff3df, #ffffff);
  }

  .stock-overview-card.empty {
    border-color: rgba(215, 25, 32, 0.34);
    background: linear-gradient(145deg, #ffe8e4, #ffffff);
  }

  .stock-overview-card > div:first-child strong {
    font-size: 0.94rem;
  }

  .stock-status {
    background: var(--green-soft);
    color: #147a46;
    font-size: 0.72rem;
  }

  .stock-overview-card.low .stock-status {
    background: #ffe7bd;
    color: #a65608;
  }

  .stock-overview-card.empty .stock-status {
    background: #ffd9d4;
  }

  .stock-count strong {
    color: var(--ink);
    font-size: 1.65rem;
  }

  .history-section {
    margin-top: 16px;
  }

  .history-filter {
    gap: 11px;
    margin-bottom: 12px;
  }

  .history-presets {
    gap: 7px;
  }

  .history-presets button {
    min-height: 46px;
    border-color: #e6cebc;
    border-radius: 11px;
    background: #fff8f1;
    color: #5e4740;
    font-size: 0.82rem;
    box-shadow: 0 3px 9px rgba(95, 40, 20, 0.04);
  }

  .history-presets button:hover {
    border-color: rgba(215, 25, 32, 0.36);
    background: var(--primary-soft);
    color: var(--primary-deep);
  }

  .history-presets button:focus {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
    box-shadow: 0 7px 15px rgba(215, 25, 32, 0.2);
  }

  .history-filter-summary {
    gap: 1px;
    margin-bottom: 14px;
    border-color: #ead4c3;
    border-radius: 12px;
    background: #ead4c3;
  }

  .history-filter-summary > div {
    background: linear-gradient(145deg, #fff8f0, #ffffff);
    padding: 12px 14px;
  }

  .history-filter-summary span {
    color: #7b6760;
    font-size: 0.74rem;
  }

  .history-filter-summary strong {
    color: var(--primary-deep);
    font-size: 1.05rem;
  }

  .history-list {
    gap: 11px;
  }

  .history-item {
    padding: 14px;
  }

  .history-total {
    color: var(--primary-deep);
    font-size: 1.08rem;
  }

  .history-actions button,
  .editor-row button {
    border-color: #e7cfbd;
    border-radius: 10px;
    background: #fff8f1;
    font-size: 0.82rem;
  }

  .history-actions button:hover,
  .editor-row button:hover {
    border-color: var(--primary);
    background: var(--primary-soft);
  }

  .history-actions .history-delete {
    border-color: rgba(215, 25, 32, 0.24);
    background: #fff0ee;
  }

  .stock-row.low {
    border-color: rgba(244, 122, 32, 0.38);
    background: #fff7e9;
  }

  .stock-row output {
    color: var(--primary-deep);
  }

  .menu-dialog::backdrop {
    background: rgba(52, 24, 18, 0.55);
    backdrop-filter: blur(3px);
  }

  .dialog-card {
    padding: 18px;
    box-shadow: 0 26px 70px rgba(55, 24, 16, 0.24);
  }

  .toast {
    border: 1px solid rgba(255, 182, 41, 0.34);
    border-radius: 12px;
    background: #332724;
    font-size: 0.88rem;
    box-shadow: 0 14px 32px rgba(43, 24, 19, 0.22);
  }
}

@media screen and (max-width: 980px) {
  .analytics-grid,
  .workspace {
    grid-template-columns: 1fr;
  }

  .cart-panel {
    position: static;
  }

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

  .history-presets {
    grid-column: 1 / -1;
  }
}

@media screen and (max-width: 720px) {
  .app-shell {
    padding: 12px;
  }

  .topbar {
    gap: 12px;
    padding: 14px;
    border-radius: 17px;
  }

  .header-logo-frame {
    width: min(220px, 100%);
    height: 106px;
    flex-basis: auto;
    align-self: center;
  }

  .shift-card {
    text-align: left;
  }

  .owner-toolbar,
  .owner-analytics,
  .order-panel,
  .cart-panel,
  .history-section,
  .stock-overview-section {
    padding: 15px;
    border-radius: 14px;
  }

  .analytics-card {
    min-height: 0;
  }

  .quick-stats,
  .history-filter,
  .history-filter-summary {
    grid-template-columns: 1fr;
  }

  .history-presets {
    grid-column: auto;
  }

  .history-presets button {
    flex: 1 1 100px;
  }

  .toolbar-actions .ghost-button {
    flex: 1 1 145px;
  }

  .menu-card {
    min-height: 128px;
  }
}

@media screen and (max-width: 480px) {
  .login-screen {
    padding: 14px;
  }

  .login-card {
    padding: 20px;
    border-radius: 17px;
  }

  .login-logo-frame {
    height: 82px;
  }

  .login-logo-frame img {
    height: 76px;
    max-height: 76px;
  }

  .topbar-actions,
  .shift-card,
  .account-card {
    min-width: 0;
  }

  .account-card {
    gap: 8px;
  }

  .history-main {
    flex-direction: column;
  }

  .history-total {
    align-self: flex-start;
  }
}
