:root {
  color-scheme: light;
  --bg: #f4f7f4;
  --bg-ink: #07110f;
  --surface: rgba(255, 255, 255, 0.88);
  --surface-solid: #ffffff;
  --surface-tint: #eef7f2;
  --surface-strong: #dceae4;
  --text: #101817;
  --text-muted: #5f6f6a;
  --accent: #00a66a;
  --accent-strong: #087a59;
  --mint: #10f2b0;
  --cyan: #2ab7ff;
  --amber: #ffb84d;
  --coral: #ff6b5f;
  --success: #00875a;
  --warning: #b46a00;
  --danger: #c6283d;
  --border: rgba(16, 24, 23, 0.12);
  --border-strong: rgba(16, 24, 23, 0.2);
  --radius: 8px;
  --shadow: 0 20px 54px rgba(7, 17, 15, 0.11);
  --shadow-soft: 0 10px 28px rgba(7, 17, 15, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(90deg, rgba(7, 17, 15, 0.035) 1px, transparent 1px),
    linear-gradient(0deg, rgba(7, 17, 15, 0.035) 1px, transparent 1px),
    radial-gradient(circle at 12% 8%, rgba(42, 183, 255, 0.18), transparent 34%),
    linear-gradient(135deg, #f8fbf8 0%, #eef7f2 38%, #fff7e8 100%);
  background-size: 28px 28px, 28px 28px, auto, auto;
  color: var(--text);
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
}

.hidden {
  display: none !important;
}

.eyebrow {
  color: var(--accent-strong);
  display: block;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  line-height: 1.2;
  text-transform: uppercase;
}

.login-screen {
  align-items: center;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-height: 100vh;
  overflow: hidden;
  padding: 22px;
  position: relative;
}

.login-stage {
  background:
    linear-gradient(120deg, rgba(7, 17, 15, 0.95), rgba(10, 47, 39, 0.92)),
    linear-gradient(90deg, rgba(16, 242, 176, 0.2), rgba(42, 183, 255, 0.16));
  inset: 0;
  overflow: hidden;
  position: absolute;
}

.login-stage::before {
  animation: gridDrift 20s linear infinite;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 48px 48px;
  content: "";
  inset: -80px;
  opacity: 0.56;
  position: absolute;
  transform: perspective(700px) rotateX(58deg) translateY(80px);
}

.login-stage::after {
  background:
    linear-gradient(120deg, transparent 0%, rgba(16, 242, 176, 0.28) 44%, transparent 58%),
    linear-gradient(90deg, transparent, rgba(255, 184, 77, 0.18), transparent);
  content: "";
  inset: 0;
  opacity: 0.8;
  position: absolute;
}

.scanline {
  animation: scanMove 4s ease-in-out infinite;
  background: linear-gradient(90deg, transparent, rgba(16, 242, 176, 0.55), transparent);
  height: 2px;
  left: 0;
  position: absolute;
  right: 0;
  top: 24%;
  z-index: 1;
}

.login-ticker {
  bottom: 30px;
  color: rgba(255, 255, 255, 0.7);
  display: flex;
  font-size: 0.78rem;
  font-weight: 500;
  gap: 28px;
  left: 28px;
  letter-spacing: 0.18em;
  position: absolute;
  right: 28px;
  z-index: 2;
}

.login-metrics {
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #ffffff;
  display: grid;
  gap: 2px;
  padding: 16px;
  position: absolute;
  right: clamp(24px, 8vw, 110px);
  top: clamp(24px, 9vw, 110px);
  width: 180px;
  z-index: 2;
}

.login-metrics strong {
  font-size: 2rem;
  line-height: 1;
}

.login-metrics span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.82rem;
}

.login-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: var(--radius);
  box-shadow: 0 34px 84px rgba(0, 0, 0, 0.25);
  display: grid;
  gap: 16px;
  justify-self: center;
  max-width: 100%;
  padding: clamp(20px, 4vw, 34px);
  position: relative;
  width: min(100%, 460px);
  z-index: 3;
}

.brand-lockup,
.header-brand {
  align-items: center;
  display: flex;
  gap: 12px;
  min-width: 0;
}

.login-logo,
img.logo {
  display: block;
  height: 54px;
  object-fit: contain;
  width: 54px;
}

.login-card h1,
.app-header h1,
.dashboard-hero h2,
.login-card p {
  margin: 0;
}

.login-card h1 {
  font-size: clamp(2rem, 8vw, 3.1rem);
  letter-spacing: 0;
  line-height: 0.95;
}

.login-subtitle,
.login-help,
.notification,
.footer,
.field label,
.session-grid span,
.demo-role-panel label {
  color: var(--text-muted);
}

.login-subtitle {
  line-height: 1.55;
}

.login-help {
  border-top: 1px solid var(--border);
  font-size: 0.86rem;
  line-height: 1.5;
  padding-top: 14px;
}

.app-shell {
  margin: 0 auto;
  max-width: 1420px;
  overflow-x: hidden;
  padding: 18px 18px 84px;
}

.app-header {
  align-items: center;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin-bottom: 14px;
  padding: 12px 14px;
  position: sticky;
  top: 10px;
  z-index: 20;
}

.app-header h1 {
  font-size: clamp(1.25rem, 2.4vw, 1.9rem);
  line-height: 1.05;
}

.header-status {
  align-items: center;
  background: #07110f;
  border-radius: var(--radius);
  color: #ffffff;
  display: inline-flex;
  flex: 0 0 auto;
  gap: 8px;
  padding: 10px 12px;
}

.header-status span {
  animation: livePulse 1.8s ease-in-out infinite;
  background: var(--mint);
  border-radius: 999px;
  box-shadow: 0 0 0 6px rgba(16, 242, 176, 0.14);
  height: 8px;
  width: 8px;
}

.header-status strong {
  font-size: 0.82rem;
}

.session-panel {
  align-items: center;
  background: #07110f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  color: #ffffff;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  margin-bottom: 14px;
  padding: 14px;
}

.session-grid {
  display: grid;
  flex: 1 1 620px;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.session-grid div {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  display: grid;
  gap: 5px;
  min-height: 62px;
  padding: 10px 12px;
}

.session-grid span,
.demo-role-panel label {
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.session-grid strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.demo-role-panel {
  display: grid;
  gap: 4px;
}

.tab-bar {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: var(--radius);
  display: grid;
  gap: 6px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-bottom: 14px;
  padding: 6px;
  position: sticky;
  top: 94px;
  z-index: 15;
}

.tab-button {
  background: transparent;
  border: 1px solid transparent;
  border-radius: 7px;
  color: #354540;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  min-height: 42px;
  padding: 10px 12px;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.tab-button:hover {
  background: rgba(0, 166, 106, 0.08);
}

.tab-button.active {
  background: #07110f;
  color: #ffffff;
  transform: translateY(-1px);
}

.tab-content {
  display: none;
}

.tab-content.active {
  animation: contentIn 260ms ease both;
  display: block;
}

.card {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  margin-bottom: 14px;
  padding: clamp(14px, 2.4vw, 22px);
}

.card h2,
.card h3 {
  letter-spacing: 0;
  margin: 0 0 14px;
}

.card h2 {
  font-size: 1.08rem;
}

.card h3 {
  font-size: 0.98rem;
}

.field-grid {
  display: grid;
  gap: 14px;
}

.field-grid.cols-2,
.field-grid.cols-3 {
  grid-template-columns: 1fr;
}

.field {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.field label {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.field input,
.field select,
.field textarea,
.demo-role-panel select,
.expense-table input,
.expense-table select {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  min-height: 44px;
  outline: none;
  padding: 11px 12px;
  width: 100%;
}

.field textarea {
  min-height: 96px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.demo-role-panel select:focus,
.expense-table input:focus,
.expense-table select:focus {
  border-color: rgba(0, 166, 106, 0.7);
  box-shadow: 0 0 0 4px rgba(16, 242, 176, 0.16);
}

.field input[type="color"] {
  padding: 5px;
}

.field input[type=number] {
  -moz-appearance: textfield;
}

.field input[type=number]::-webkit-outer-spin-button,
.field input[type=number]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

button,
button.secondary {
  align-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  display: inline-flex;
  font-weight: 500;
  justify-content: center;
  min-height: 42px;
  padding: 11px 15px;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

button:hover {
  transform: translateY(-1px);
}

button.primary {
  background: linear-gradient(135deg, var(--accent), var(--cyan));
  box-shadow: 0 12px 26px rgba(0, 166, 106, 0.24);
  color: #ffffff;
}

button.secondary {
  background: rgba(255, 255, 255, 0.86);
  border-color: var(--border);
  color: var(--text);
}

button.secondary.danger {
  border-color: rgba(198, 40, 61, 0.24);
  color: var(--danger);
}

button:disabled,
button[disabled] {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
}

.action-row,
.report-actions,
.status-line {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.action-row {
  margin-top: 14px;
}

.status-line {
  justify-content: space-between;
}

.badge {
  align-items: center;
  border-radius: 999px;
  display: inline-flex;
  font-size: 0.75rem;
  font-weight: 500;
  gap: 6px;
  letter-spacing: 0.08em;
  padding: 7px 10px;
  text-transform: uppercase;
  width: fit-content;
}

.badge.draft { background: #eef2f0; color: #354540; }
.badge.submitted { background: #fff1cc; color: var(--warning); }
.badge.approved { background: #d9f8eb; color: var(--success); }
.badge.locked { background: #ffe4e8; color: var(--danger); }

.summary-row {
  align-items: center;
  border-bottom: 1px solid rgba(16, 24, 23, 0.08);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  min-height: 42px;
  padding: 10px 0;
}

.summary-row:last-child {
  border-bottom: 0;
}

.summary-row strong {
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.sticky-summary {
  position: sticky;
  top: 154px;
}

.notification {
  background: rgba(238, 247, 242, 0.74);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius);
  line-height: 1.45;
  margin: 10px 0 0;
  padding: 12px 14px;
}

.expense-table,
.report-table {
  border-collapse: separate;
  border-spacing: 0;
  min-width: 780px;
  width: 100%;
}

.card:has(.expense-table),
.card:has(.report-table) {
  overflow-x: auto;
}

.expense-table th,
.expense-table td,
.report-table th,
.report-table td {
  border-bottom: 1px solid rgba(16, 24, 23, 0.08);
  font-size: 0.88rem;
  padding: 12px 10px;
  text-align: left;
  vertical-align: middle;
}

.expense-table th,
.report-table th {
  background: #07110f;
  color: #ffffff;
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  position: sticky;
  text-transform: uppercase;
  top: 0;
}

.expense-table tr:nth-child(even) td,
.report-table tr:nth-child(even) td {
  background: rgba(255, 255, 255, 0.45);
}

.dashboard-hero {
  background:
    linear-gradient(135deg, rgba(7, 17, 15, 0.98), rgba(9, 54, 44, 0.96) 56%, rgba(56, 43, 20, 0.94)),
    linear-gradient(90deg, rgba(42, 183, 255, 0.2), rgba(16, 242, 176, 0.22));
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  color: #ffffff;
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(0, 1fr);
  margin-bottom: 14px;
  min-height: 260px;
  overflow: hidden;
  padding: clamp(18px, 4vw, 34px);
  position: relative;
}

.dashboard-hero::before {
  animation: gridDrift 24s linear infinite;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 36px 36px;
  content: "";
  inset: -40px;
  opacity: 0.44;
  position: absolute;
}

.dashboard-copy,
.dashboard-visual {
  position: relative;
  z-index: 1;
}

.dashboard-copy .eyebrow {
  color: var(--mint);
}

.dashboard-copy h2 {
  font-size: clamp(2.2rem, 8vw, 5.6rem);
  line-height: 0.9;
  max-width: 680px;
}

.dashboard-pulse-row {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(4, minmax(32px, 80px));
  margin-top: 22px;
}

.dashboard-pulse-row span {
  animation: meterPulse 1.8s ease-in-out infinite;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  height: 5px;
}

.dashboard-pulse-row span:nth-child(2) { animation-delay: 160ms; }
.dashboard-pulse-row span:nth-child(3) { animation-delay: 320ms; }
.dashboard-pulse-row span:nth-child(4) { animation-delay: 480ms; }

.dashboard-visual {
  align-items: end;
  display: grid;
  min-height: 150px;
  overflow: hidden;
}

.radar-ring {
  animation: rotateRadar 12s linear infinite;
  aspect-ratio: 1;
  background:
    conic-gradient(from 0deg, rgba(16, 242, 176, 0.48), transparent 34%, rgba(255, 184, 77, 0.4), transparent 62%, rgba(42, 183, 255, 0.42), transparent);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  height: 170px;
  opacity: 0.8;
  position: absolute;
  right: clamp(14px, 5vw, 76px);
  top: 24px;
}

.radar-ring::after {
  background: #07110f;
  border-radius: 999px;
  content: "";
  inset: 16px;
  position: absolute;
}

.flow-bars {
  align-items: end;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(6, minmax(18px, 1fr));
  height: 126px;
  max-width: 420px;
  min-width: 0;
  width: 100%;
}

.flow-bars span {
  animation: barRise 1.3s ease-out both, barGlow 2.4s ease-in-out infinite;
  background: linear-gradient(180deg, var(--mint), var(--cyan));
  border-radius: 7px 7px 0 0;
  box-shadow: 0 0 24px rgba(16, 242, 176, 0.28);
  height: var(--height);
  min-height: 24px;
}

.flow-bars span:nth-child(2n) {
  background: linear-gradient(180deg, var(--amber), var(--coral));
}

.flow-bars span:nth-child(2) { animation-delay: 80ms; }
.flow-bars span:nth-child(3) { animation-delay: 160ms; }
.flow-bars span:nth-child(4) { animation-delay: 240ms; }
.flow-bars span:nth-child(5) { animation-delay: 320ms; }
.flow-bars span:nth-child(6) { animation-delay: 400ms; }

.flow-line {
  animation: scanMove 3s ease-in-out infinite;
  background: linear-gradient(90deg, transparent, rgba(16, 242, 176, 0.9), transparent);
  height: 2px;
  left: 0;
  position: absolute;
  right: 0;
  top: 54%;
}

.summary-cards {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.summary-card {
  animation: cardEnter 420ms ease both;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 251, 248, 0.92));
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
  min-height: 116px;
  overflow: hidden;
  padding: 16px;
  position: relative;
}

.summary-card::after {
  background: linear-gradient(90deg, var(--mint), var(--cyan), var(--amber));
  bottom: 0;
  content: "";
  height: 3px;
  left: 0;
  position: absolute;
  right: 0;
}

.summary-card h3 {
  color: var(--text-muted);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  margin: 0 0 12px;
  text-transform: uppercase;
}

.summary-card strong {
  display: block;
  font-size: clamp(1.35rem, 4vw, 2rem);
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}

.summary-card:nth-child(2) { animation-delay: 40ms; }
.summary-card:nth-child(3) { animation-delay: 80ms; }
.summary-card:nth-child(4) { animation-delay: 120ms; }
.summary-card:nth-child(5) { animation-delay: 160ms; }
.summary-card:nth-child(6) { animation-delay: 200ms; }
.summary-card:nth-child(7) { animation-delay: 240ms; }
.summary-card:nth-child(8) { animation-delay: 280ms; }
.summary-card:nth-child(9) { animation-delay: 320ms; }
.summary-card:nth-child(10) { animation-delay: 360ms; }
.summary-card:nth-child(11) { animation-delay: 400ms; }
.summary-card:nth-child(12) { animation-delay: 440ms; }

.checkbox-field {
  align-content: center;
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: auto 1fr;
}

.checklist-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.checklist-grid label,
#payment-method-list li,
.settings-area-grid span,
#outlet-list li,
#user-list li,
#category-list li {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  list-style: none;
  padding: 10px 12px;
}

#outlet-list,
#user-list,
#category-list,
#payment-method-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
}

.admin-only.is-disabled {
  opacity: 0.65;
}

.report-filters,
.settings-grid {
  display: grid;
  gap: 14px;
}

.dashboard-controls {
  align-items: end;
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(220px, 0.42fr) minmax(0, 1fr);
}

.dashboard-controls h2 {
  margin-bottom: 6px;
}

.compact-note {
  color: var(--text-muted);
  line-height: 1.45;
  margin: 0;
}

.dashboard-controls button {
  align-self: end;
  min-height: 44px;
}

.settings-area-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.server-status-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.server-status-grid div {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: grid;
  gap: 8px;
  min-height: 82px;
  padding: 12px;
}

.server-status-grid span {
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.server-status-grid strong:not(.badge) {
  overflow-wrap: anywhere;
}

.settings-area-grid span {
  font-size: 0.86rem;
  font-weight: 500;
}

.footer {
  font-size: 0.9rem;
  padding: 24px 12px 12px;
  text-align: center;
}

.footer a {
  color: var(--accent-strong);
  font-weight: 500;
  text-decoration: none;
}

/* Corporate operations polish */
html {
  background:
    linear-gradient(90deg, rgba(15, 23, 42, 0.025) 1px, transparent 1px),
    linear-gradient(0deg, rgba(15, 23, 42, 0.025) 1px, transparent 1px),
    linear-gradient(135deg, #f7faf9 0%, #eef5f2 48%, #f8f7f1 100%);
  background-size: 32px 32px, 32px 32px, auto;
}

body {
  font-size: 14px;
}

.eyebrow {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.11em;
}

.login-card h1 {
  font-size: clamp(1.7rem, 5vw, 2.25rem);
  line-height: 1.06;
}

.app-header h1 {
  font-size: clamp(1.15rem, 1.8vw, 1.55rem);
}

.card,
.summary-card,
.session-panel,
.app-header {
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

.card {
  background: rgba(255, 255, 255, 0.93);
  padding: clamp(14px, 2vw, 18px);
}

.card h2 {
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.25;
}

.card h3 {
  font-size: 0.92rem;
  font-weight: 500;
}

.tab-button {
  font-size: 0.86rem;
  font-weight: 500;
}

.field label,
.summary-card h3 {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.07em;
}

.field input,
.field select,
.field textarea,
.demo-role-panel select,
.expense-table input,
.expense-table select {
  min-height: 40px;
  padding: 9px 11px;
}

button,
button.secondary {
  min-height: 40px;
  padding: 9px 13px;
}

.dashboard-hero {
  min-height: 118px;
  padding: 14px 18px;
}

.dashboard-copy h2 {
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  line-height: 1.2;
  max-width: 560px;
}

.dashboard-pulse-row {
  margin-top: 16px;
}

.radar-ring {
  height: 86px;
}

.flow-bars {
  height: 72px;
}

.expense-table th,
.report-table th {
  background: #f7faf9;
  border-bottom: 1px solid rgba(15, 23, 42, 0.12);
  color: #4f625d;
}

.expense-table td,
.report-table td {
  background: rgba(255, 255, 255, 0.72);
}

.expense-table tr:nth-child(even) td,
.report-table tr:nth-child(even) td {
  background: rgba(248, 250, 252, 0.72);
}

#outlet-form,
#category-form {
  align-items: center;
  margin-top: 10px;
}

#outlet-form input,
#category-form input {
  min-height: 40px;
}

.summary-card {
  min-height: 96px;
  padding: 14px;
}

.summary-card strong {
  font-size: clamp(1.15rem, 2.5vw, 1.55rem);
  font-weight: 500;
}

.section-toolbar {
  align-items: end;
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 340px);
  margin-bottom: 14px;
}

.section-toolbar h2,
.section-toolbar p {
  margin: 0;
}

.section-toolbar p {
  color: var(--text-muted);
  line-height: 1.45;
  margin-top: 6px;
}

.search-field {
  min-width: 0;
}

.entry-overview {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.entry-overview div {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  display: grid;
  gap: 5px;
  min-height: 74px;
  padding: 12px;
}

.entry-overview span {
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.entry-overview strong {
  font-size: 1.08rem;
  font-weight: 500;
}

#daily-entry-tab.active {
  align-items: start;
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
}

#daily-entry-tab > .entry-overview,
#closing-checklist-card,
#daily-entry-tab > .card:last-child {
  grid-column: 1 / -1;
}

#daily-entry-tab > .card:not(.sticky-summary):not(:last-child):not(#closing-checklist-card) {
  grid-column: 1;
}

#daily-entry-tab > .sticky-summary {
  grid-column: 2;
  grid-row: 2 / span 5;
}

.sticky-summary {
  top: 146px;
}

.summary-row {
  min-height: 36px;
  padding: 8px 0;
}

.settings-overview {
  align-items: start;
}

.settings-overview .field {
  align-content: start;
}

#settings-tab ul {
  align-self: start;
  max-height: 260px;
  overflow: auto;
}

#outlet-list li,
#user-list li,
#category-list li,
#payment-method-list li {
  min-height: 0;
  padding: 9px 11px;
}

.settings-area-grid span {
  font-size: 0.8rem;
  font-weight: 500;
}

.owner-analytics {
  display: grid;
  gap: 14px;
  margin-top: 14px;
}

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

.analytics-panel {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: var(--radius);
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
  min-height: 260px;
  padding: 14px;
}

.chart-wide {
  grid-column: 1 / -1;
}

.panel-heading {
  align-items: baseline;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  display: flex;
  gap: 10px;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 10px;
}

.panel-heading span {
  font-size: 0.95rem;
  font-weight: 500;
}

.panel-heading small,
.analytics-note {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.chart-surface {
  min-height: 190px;
}

.empty-chart {
  align-items: center;
  background: rgba(248, 250, 252, 0.9);
  border: 1px dashed rgba(100, 116, 139, 0.24);
  border-radius: var(--radius);
  color: var(--text-muted);
  display: grid;
  min-height: 180px;
  place-items: center;
}

.donut-chart {
  align-items: center;
  border-radius: 999px;
  display: grid;
  height: 150px;
  margin: 8px auto 12px;
  place-items: center;
  position: relative;
  width: 150px;
}

.donut-chart::after {
  background: #ffffff;
  border-radius: 999px;
  content: "";
  inset: 28px;
  position: absolute;
}

.donut-chart span {
  color: var(--text-muted);
  font-size: 0.9rem;
  position: relative;
  z-index: 1;
}

.chart-legend {
  display: grid;
  gap: 8px;
}

.chart-legend-row {
  align-items: center;
  display: grid;
  gap: 8px;
  grid-template-columns: 10px minmax(0, 1fr) auto;
}

.chart-legend-row span,
.line-legend i {
  border-radius: 999px;
  height: 10px;
  width: 10px;
}

.chart-legend-row em {
  font-style: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chart-legend-row strong {
  font-size: 0.85rem;
  text-align: right;
}

.comparison-bar-row {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: minmax(110px, 0.55fr) minmax(160px, 1fr) auto;
  margin-bottom: 12px;
}

.comparison-bars {
  background: #eef3f1;
  border-radius: 999px;
  display: grid;
  gap: 4px;
  padding: 4px;
}

.comparison-bars i,
.comparison-bars b {
  border-radius: 999px;
  display: block;
  height: 8px;
}

.comparison-bars i {
  background: #087a59;
}

.comparison-bars b {
  background: #e6a23c;
}

.chart-surface svg {
  height: 210px;
  width: 100%;
}

.chart-surface svg line {
  stroke: rgba(100, 116, 139, 0.28);
}

.chart-surface svg text {
  fill: var(--text-muted);
  font-size: 0.7rem;
}

.line-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.line-legend span {
  align-items: center;
  color: var(--text-muted);
  display: inline-flex;
  font-size: 0.8rem;
  gap: 5px;
}

.comparison-table-wrap {
  overflow-x: auto;
}

.comparison-table {
  border-collapse: separate;
  border-spacing: 0;
  min-width: 860px;
  width: 100%;
}

.comparison-table th,
.comparison-table td {
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  padding: 10px;
  text-align: left;
}

.comparison-table th {
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Light, corporate typography override */
body,
button,
input,
select,
textarea {
  font-weight: 400;
}

h1,
h2,
h3,
strong,
button,
.tab-button,
.badge,
.field label,
.session-grid strong,
.summary-card strong,
.entry-overview strong,
.report-table th,
.expense-table th {
  font-weight: 500 !important;
}

.eyebrow,
.summary-card h3,
.entry-overview span,
.session-grid span,
.server-status-grid span {
  font-weight: 500 !important;
}

@keyframes gridDrift {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(48px, 48px, 0); }
}

@keyframes scanMove {
  0%, 100% { transform: translateY(-55px); opacity: 0; }
  18%, 80% { opacity: 1; }
  50% { transform: translateY(78px); }
}

@keyframes livePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.32); }
}

@keyframes contentIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes meterPulse {
  0%, 100% { opacity: 0.34; transform: scaleX(0.7); }
  50% { opacity: 1; transform: scaleX(1); }
}

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

@keyframes barRise {
  from { transform: scaleY(0); transform-origin: bottom; }
  to { transform: scaleY(1); transform-origin: bottom; }
}

@keyframes barGlow {
  0%, 100% { filter: saturate(1); }
  50% { filter: saturate(1.45) brightness(1.1); }
}

@keyframes cardEnter {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (min-width: 760px) {
  .field-grid.cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .dashboard-hero {
    grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.75fr);
  }
}

@media (max-width: 860px) {
  .app-header,
  .session-panel {
    align-items: stretch;
  }

  .app-header {
    flex-direction: column;
  }

  .header-status {
    justify-content: center;
  }

  .tab-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    position: static;
  }

  .dashboard-controls {
    grid-template-columns: 1fr;
  }

  .section-toolbar {
    grid-template-columns: 1fr;
  }

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

  .comparison-bar-row {
    grid-template-columns: 1fr;
  }

  #daily-entry-tab.active {
    grid-template-columns: 1fr;
  }

  #daily-entry-tab > .sticky-summary,
  #daily-entry-tab > .card:not(.sticky-summary):not(:last-child):not(#closing-checklist-card) {
    grid-column: 1;
    grid-row: auto;
  }

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

  .sticky-summary {
    position: static;
  }
}

@media (max-width: 640px) {
  .app-shell {
    padding: 10px 10px 70px;
  }

  .login-screen {
    padding: 14px;
  }

  .login-metrics,
  .login-ticker {
    display: none;
  }

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

  .dashboard-copy h2 {
    font-size: 1.25rem;
  }

  .dashboard-hero {
    min-height: 180px;
    padding: 20px;
  }

  .dashboard-visual {
    margin-inline: -2px;
  }

  .radar-ring {
    height: 140px;
    opacity: 0.58;
    right: -26px;
    top: 116px;
  }

  .flow-bars {
    gap: 8px;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    max-width: none;
  }

  .summary-cards {
    grid-template-columns: 1fr;
  }

  .entry-overview {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  html,
  body {
    background: #ffffff;
  }

  .app-header,
  .tab-bar,
  .action-row,
  .footer,
  .settings-grid,
  .report-actions,
  .field .actions,
  .dashboard-hero {
    display: none !important;
  }

  .app-shell {
    padding: 0;
  }

  .card,
  .summary-card {
    border: 1px solid #d8d8d8;
    box-shadow: none;
  }
}
