:root {
  --ink: #251e1a;
  --ink-2: #382c26;
  --muted: #70665d;
  --line: #e6dccd;
  --paper: #f7f2e8;
  --card: #fffdf9;
  --cream: #f2e9d8;
  --brand-primary: #c6472d;
  --brand-primary-dark: #993320;
  --edition-accent: #88a957;
  --edition-accent-dark: #557531;
  --edition-surface: #eaf0dc;
  --accent-leaf: var(--edition-accent);
  --accent-leaf-dark: var(--edition-accent-dark);
  --accent-amber: #e7b451;
  --status-success: #147d70;
  --status-success-dark: #0f655c;
  --status-success-on-dark: #78c9bf;
  --status-success-surface: #d9f1ed;
  --status-warning: #c58a1a;
  --status-danger: #c63d55;
  --status-info: #6967b3;
  --danger: var(--status-danger);
  --success: var(--status-success);
  --on-dark: #fffdf9;
  --on-dark-secondary: #b8b5b3;
  --on-dark-tertiary: #8d8986;
  --on-brand: #fff7f2;
  --line-control: #94877b;
  --focus-ring: #0f6f64;
  --shadow: 0 18px 55px rgba(37, 30, 26, .10);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 13px;
  --sidebar: 244px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "DM Sans", "Avenir Next", Avenir, Inter, system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.edition-heladerias {
  --edition-accent: #88a957;
  --edition-accent-dark: #557531;
  --edition-surface: #eaf0dc;
}
button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, [role="button"] { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 3px;
}
[hidden] { display: none !important; }

.eyebrow {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .14em;
}
.eyebrow.light { color: var(--on-dark-secondary); }

.brand {
  align-items: center;
  color: inherit;
  display: inline-flex;
  gap: 11px;
  text-decoration: none;
}
.brand > span:last-child { display: flex; flex-direction: column; line-height: .88; }
.brand b { font-size: 19px; font-weight: 950; letter-spacing: -.04em; }
.brand small { font-size: 8px; font-weight: 800; letter-spacing: .27em; margin-top: 7px; }
.brand-mark {
  align-items: center;
  background: var(--brand-primary);
  border-radius: 11px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.14);
  display: inline-flex;
  height: 38px;
  justify-content: center;
  position: relative;
  width: 38px;
}
.brand-mark::before {
  border-bottom: 4px solid white;
  border-left: 4px solid white;
  border-radius: 0 0 0 2px;
  content: "";
  height: 17px;
  left: 11px;
  position: absolute;
  top: 8px;
  width: 14px;
}
.brand-mark i {
  background: var(--accent-leaf);
  border: 2px solid var(--ink);
  border-radius: 50%;
  height: 11px;
  position: absolute;
  right: -3px;
  top: -3px;
  width: 11px;
}

/* Auth */
.auth-screen {
  background: var(--card);
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(440px, 1.05fr) minmax(420px, .95fr);
}
.auth-story {
  background:
    radial-gradient(circle at 75% 20%, rgba(198,71,45,.31), transparent 28%),
    radial-gradient(circle at 18% 82%, rgba(136,169,87,.18), transparent 30%),
    var(--ink);
  color: white;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  overflow: hidden;
  padding: clamp(34px, 4vw, 64px);
  position: relative;
}
.auth-story::before,
.auth-story::after {
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 50%;
  content: "";
  height: 460px;
  position: absolute;
  right: -210px;
  top: 80px;
  width: 460px;
}
.auth-story::after { height: 330px; right: -145px; top: 145px; width: 330px; }
.brand-auth { position: relative; z-index: 1; }
.auth-copy { margin: auto 0; max-width: 560px; position: relative; z-index: 1; }
.auth-copy h1 {
  font-family: "Manrope", "Arial Black", sans-serif;
  font-size: clamp(64px, 7vw, 104px);
  letter-spacing: -.075em;
  line-height: .86;
  margin: 24px 0 30px;
}
.auth-copy h1 em { color: var(--accent-leaf); font-style: normal; }
.auth-copy p {
  color: var(--on-dark-secondary);
  font-size: 17px;
  line-height: 1.65;
  max-width: 480px;
}
.auth-live-card {
  backdrop-filter: blur(12px);
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 20px;
  bottom: clamp(52px, 7vw, 100px);
  padding: 22px;
  position: absolute;
  right: clamp(36px, 5vw, 76px);
  transform: rotate(3deg);
  width: 250px;
  z-index: 2;
}
.live-card-top { align-items: center; display: flex; gap: 9px; }
.live-card-top b { font-size: 13px; }
.live-card-top small {
  background: rgba(20,125,112,.22);
  border-radius: 12px;
  color: var(--status-success-on-dark);
  font-size: 8px;
  font-weight: 900;
  margin-left: auto;
  padding: 6px 8px;
}
.status-dot {
  background: var(--status-success-on-dark);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(120,201,191,.12);
  height: 7px;
  width: 7px;
}
.live-card-metrics { border-top: 1px solid rgba(255,255,255,.09); display: grid; gap: 10px; grid-template-columns: repeat(3, 1fr); margin-top: 18px; padding-top: 18px; }
.live-card-metrics span { display: flex; flex-direction: column; }
.live-card-metrics b { font-size: 22px; }
.live-card-metrics small { color: var(--on-dark-secondary); font-size: 7px; font-weight: 800; margin-top: 4px; }
.auth-signature { bottom: 28px; color: var(--on-dark-tertiary); font-size: 11px; left: clamp(34px, 4vw, 64px); position: absolute; }
.auth-signature span { color: var(--accent-leaf); }
.auth-form-wrap { align-items: center; display: flex; justify-content: center; min-height: 100vh; padding: 50px; }
.auth-form { max-width: 430px; width: 100%; }
.auth-form h2 {
  font-family: "Manrope", sans-serif;
  font-size: 42px;
  letter-spacing: -.055em;
  margin: 16px 0 8px;
}
.auth-form > p { color: var(--muted); line-height: 1.55; margin: 0 0 36px; }
label { display: flex; flex-direction: column; gap: 8px; }
label > span { font-size: 11px; font-weight: 800; letter-spacing: .02em; }
input, select, textarea {
  background: #fff;
  border: 1px solid var(--line-control);
  border-radius: 11px;
  color: var(--ink);
  min-height: 48px;
  padding: 0 14px;
  transition: border .18s, box-shadow .18s;
  width: 100%;
}
textarea { min-height: 92px; padding-top: 13px; resize: vertical; }
input:focus, select:focus, textarea:focus {
  border-color: var(--focus-ring);
  box-shadow: 0 0 0 4px rgba(15,111,100,.13);
  outline: none;
}
.auth-form > label { margin-bottom: 18px; }
.password-field { position: relative; }
.password-field input { padding-right: 60px; }
.password-field button {
  background: none;
  border: 0;
  color: var(--brand-primary-dark);
  font-size: 11px;
  font-weight: 800;
  padding: 10px;
  position: absolute;
  right: 6px;
  top: 5px;
}
.btn {
  align-items: center;
  border: 0;
  border-radius: 11px;
  display: inline-flex;
  font-size: 12px;
  font-weight: 800;
  gap: 14px;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  transition: transform .15s, box-shadow .15s, background .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn:disabled { cursor: wait; opacity: .55; transform: none; }
.btn-dark { background: var(--ink); color: white; }
.btn-primary { background: var(--brand-primary); color: var(--on-brand); }
.btn-primary:hover { box-shadow: 0 9px 24px rgba(198,71,45,.24); }
.btn-light { background: white; color: var(--ink); }
.btn-soft { background: #f1e9de; color: var(--ink); }
.btn-danger { background: var(--ink); color: white; }
.btn-login { justify-content: space-between; margin-top: 10px; padding: 0 20px; width: 100%; }
.btn-login b { font-size: 18px; }
.form-error, .modal-error { color: var(--danger); font-size: 12px; line-height: 1.4; min-height: 18px; padding-top: 8px; }
.demo-hint {
  background: var(--cream);
  border: 1px solid var(--line);
  border-radius: 12px;
  display: grid;
  gap: 10px;
  grid-template-columns: auto 1fr;
  margin-top: 26px;
  padding: 16px;
}
.demo-hint span { background: var(--accent-leaf); border-radius: 6px; color: var(--ink); font-size: 8px; font-weight: 900; height: fit-content; letter-spacing: .08em; padding: 6px 7px; }
.demo-hint p { color: var(--muted); font-size: 11px; line-height: 1.5; margin: 0; }

/* Layout */
.app-shell { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: 100vh; }
.sidebar {
  background: var(--ink);
  color: white;
  display: flex;
  flex-direction: column;
  height: 100vh;
  justify-content: space-between;
  left: 0;
  overflow-y: auto;
  padding: 27px 18px 20px;
  position: sticky;
  top: 0;
  z-index: 20;
}
.brand-sidebar { margin: 0 10px 43px; }
.brand-sidebar .brand-mark { height: 34px; width: 34px; }
.brand-sidebar .brand-mark::before { height: 15px; left: 10px; top: 7px; width: 12px; }
.brand-sidebar b { font-size: 17px; }
.nav-label { color: var(--on-dark-tertiary); font-size: 8px; font-weight: 900; letter-spacing: .17em; margin: 0 13px 10px; }
.nav-label.inner { margin-top: 29px; }
.main-nav { display: flex; flex-direction: column; gap: 3px; }
.nav-item {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 9px;
  color: var(--on-dark-secondary);
  display: flex;
  font-size: 12px;
  font-weight: 650;
  gap: 12px;
  min-height: 43px;
  padding: 0 12px;
  text-align: left;
  width: 100%;
}
.nav-item:hover { background: rgba(255,255,255,.05); color: white; }
.nav-item.active { background: rgba(255,255,255,.095); color: white; }
.nav-item.active::before { background: var(--accent-leaf); border-radius: 0 3px 3px 0; content: ""; height: 23px; left: 0; position: absolute; width: 3px; }
.nav-item { position: relative; }
.nav-icon { color: var(--on-dark-secondary); display: inline-flex; font-size: 16px; justify-content: center; width: 18px; }
.nav-item i:not(:empty) {
  background: var(--brand-primary);
  border-radius: 10px;
  font-size: 8px;
  font-style: normal;
  font-weight: 900;
  margin-left: auto;
  min-width: 19px;
  padding: 4px 6px;
  text-align: center;
}
.sidebar-footer { border-top: 1px solid rgba(255,255,255,.08); padding-top: 15px; }
.branch-switcher {
  align-items: center;
  background: rgba(255,255,255,.055);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 11px;
  display: grid;
  gap: 9px;
  grid-template-columns: 34px 1fr auto;
  padding: 10px;
}
.branch-letter { align-items: center; background: var(--accent-leaf); border-radius: 8px; color: var(--ink); display: flex; font-size: 13px; font-weight: 900; height: 34px; justify-content: center; }
.branch-switcher b { display: block; font-size: 10px; }
.branch-switcher small { align-items: center; color: var(--on-dark-tertiary); display: flex; font-size: 8px; gap: 5px; margin-top: 4px; }
.branch-switcher small i { background: var(--status-success); border-radius: 50%; height: 5px; width: 5px; }
.logout-button {
  background: none;
  border: 0;
  color: var(--on-dark-tertiary);
  display: flex;
  font-size: 9px;
  justify-content: space-between;
  margin-top: 10px;
  padding: 10px 11px;
  width: 100%;
}
.logout-button:hover { color: white; }
.workspace { min-width: 0; }
.topbar {
  align-items: center;
  background: rgba(247,242,232,.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(230,220,205,.84);
  display: flex;
  height: 92px;
  justify-content: space-between;
  padding: 0 clamp(24px, 4vw, 54px);
  position: sticky;
  top: 0;
  z-index: 15;
}
.topbar h1 { font-family: "Manrope", sans-serif; font-size: 23px; letter-spacing: -.045em; margin: 5px 0 0; }
.topbar-actions { align-items: center; display: flex; gap: 22px; }
.today-date { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-width: 76px; padding-right: 22px; text-align: right; }
.today-date span { color: var(--muted); font-size: 7px; font-weight: 900; letter-spacing: .12em; }
.today-date b { font-size: 12px; margin-top: 4px; }
.user-chip { align-items: center; background: transparent; border: 0; display: flex; gap: 10px; padding: 0; }
.user-chip > span {
  align-items: center;
  background: var(--ink);
  border-radius: 10px;
  color: white;
  display: flex;
  font-size: 10px;
  font-weight: 850;
  height: 38px;
  justify-content: center;
  width: 38px;
}
.user-chip div { display: flex; flex-direction: column; text-align: left; }
.user-chip b { font-size: 10px; }
.user-chip small { color: var(--muted); font-size: 8px; margin-top: 3px; }
.user-chip > i { color: var(--muted); font-size: 10px; font-style: normal; margin-left: 3px; }
.mobile-menu { background: none; border: 0; display: none; font-size: 22px; }
.page-content { margin: 0 auto; max-width: 1580px; padding: 30px clamp(24px, 4vw, 54px) 64px; }
.mobile-nav { display: none; }

/* Shift */
.shift-banner {
  align-items: center;
  background: var(--ink);
  border-radius: var(--radius-lg);
  color: white;
  display: grid;
  gap: 18px;
  grid-template-columns: 46px minmax(220px, 1fr) auto auto;
  margin-bottom: 22px;
  min-height: 114px;
  overflow: hidden;
  padding: 22px 24px;
  position: relative;
}
.shift-banner::after {
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 50%;
  content: "";
  height: 200px;
  position: absolute;
  right: 20%;
  top: -105px;
  width: 200px;
}
.shift-banner.closed { background: #4a3d36; }
.shift-state-icon { align-items: center; background: rgba(20,125,112,.18); border-radius: 13px; display: flex; height: 44px; justify-content: center; width: 44px; }
.shift-state-icon span { background: var(--status-success-on-dark); border-radius: 50%; box-shadow: 0 0 0 6px rgba(120,201,191,.12); height: 9px; width: 9px; }
.closed .shift-state-icon span { background: #d5c9bc; box-shadow: 0 0 0 6px rgba(255,255,255,.09); }
.shift-copy { position: relative; z-index: 1; }
.shift-copy > span { color: var(--status-success-on-dark); font-size: 8px; font-weight: 900; letter-spacing: .13em; }
.shift-copy h2 { font-family: "Manrope", sans-serif; font-size: 20px; letter-spacing: -.04em; margin: 4px 0 3px; }
.shift-copy p { color: var(--on-dark-secondary); font-size: 10px; margin: 0; }
.shift-temperature { border-left: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; padding: 4px 27px; position: relative; z-index: 1; }
.shift-temperature span { color: var(--on-dark-tertiary); font-size: 7px; font-weight: 850; letter-spacing: .08em; }
.shift-temperature b { font-size: 16px; margin-top: 5px; }
.shift-banner .btn { min-width: 142px; position: relative; z-index: 1; }

.attention-strip {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  margin-bottom: 16px;
}
.alert-chip {
  align-items: center;
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 3px solid var(--status-warning);
  border-radius: 10px;
  display: grid;
  gap: 10px;
  grid-template-columns: 30px 1fr auto;
  min-height: 54px;
  padding: 10px 12px;
}
.alert-chip.danger { border-left-color: var(--danger); }
.alert-chip.info { border-left-color: var(--status-info); }
.alert-chip > span { align-items: center; background: #f2ece3; border-radius: 8px; display: flex; font-size: 12px; height: 30px; justify-content: center; }
.alert-chip b { display: block; font-size: 9px; }
.alert-chip small { color: var(--muted); display: block; font-size: 8px; margin-top: 2px; }
.alert-chip button { background: none; border: 0; color: var(--muted); font-size: 12px; padding: 5px; }

/* Metrics and cards */
.metrics-grid { display: grid; gap: 13px; grid-template-columns: repeat(4, 1fr); margin-bottom: 16px; }
.metric-card, .card {
  background: var(--card);
  border: 1px solid rgba(230,220,205,.92);
  border-radius: var(--radius-lg);
}
.metric-card { min-height: 137px; padding: 19px; }
.metric-sales { border-color: var(--line); box-shadow: inset 4px 0 0 var(--brand-primary); }
.metric-heading { align-items: center; display: flex; justify-content: space-between; }
.metric-heading span { color: var(--muted); font-size: 8px; font-weight: 900; letter-spacing: .09em; }
.metric-heading i { align-items: center; background: #f2ece3; border-radius: 8px; display: flex; font-size: 12px; font-style: normal; height: 28px; justify-content: center; width: 28px; }
.metric-sales .metric-heading span { color: var(--muted); }
.metric-sales .metric-heading i { background: rgba(198,71,45,.12); color: var(--brand-primary-dark); }
.metric-sales > strong { color: var(--brand-primary-dark); }
.metric-card > strong { display: block; font-family: "Manrope", sans-serif; font-size: clamp(28px, 2.8vw, 39px); letter-spacing: -.065em; margin: 13px 0 12px; }
.metric-bottom { align-items: center; display: flex; gap: 9px; }
.metric-bottom small { color: var(--muted); font-size: 8px; }
.metric-sales .metric-bottom small { color: var(--muted); }
.progress { background: #eadfd3; border-radius: 4px; display: block; height: 4px; overflow: hidden; width: 58px; }
.progress i { background: var(--brand-primary); border-radius: inherit; display: block; height: 100%; width: 0; }
.metric-bottom.split { justify-content: space-between; }
.metric-bottom.split small b { color: var(--ink); font-size: 9px; }
.healthy { align-items: center; color: var(--success) !important; display: flex; gap: 5px; }
.healthy i { background: var(--status-success); border-radius: 50%; height: 5px; width: 5px; }

.dashboard-grid { display: grid; gap: 16px; grid-template-columns: 1.28fr .9fr .9fr; }
.card { min-width: 0; padding: 20px; }
.card-header { align-items: center; display: flex; justify-content: space-between; margin-bottom: 17px; }
.card-header h2 { font-family: "Manrope", sans-serif; font-size: 16px; letter-spacing: -.04em; margin: 5px 0 0; }
.link-button { background: none; border: 0; color: var(--brand-primary-dark); font-size: 9px; font-weight: 800; padding: 7px 0; }
.count-pill { background: #f2ece3; border-radius: 12px; color: var(--muted); font-size: 8px; font-weight: 750; padding: 6px 9px; }
.attention-card { grid-column: span 2; }
.vitrina-card { grid-row: span 1; }
.orders-card { grid-column: span 1; }
.team-card { grid-column: span 1; }
.tasks-card { grid-column: span 1; }
.activity-card { grid-column: span 2; }

.attention-list { display: grid; gap: 9px; }
.attention-row {
  align-items: center;
  background: #fffbf6;
  border: 1px solid #eadfd3;
  border-radius: 11px;
  display: grid;
  gap: 11px;
  grid-template-columns: 38px 1fr auto;
  padding: 10px;
}
.attention-row > span { align-items: center; background: #eadfd3; border-radius: 9px; display: flex; font-size: 14px; height: 38px; justify-content: center; }
.attention-row.warning > span { background: #fff2d5; }
.attention-row.danger > span { background: #f9e1e6; color: var(--danger); }
.attention-row.info > span { background: #e0e7f6; color: var(--status-info); }
.attention-row b { display: block; font-size: 10px; }
.attention-row small { color: var(--muted); display: block; font-size: 8px; margin-top: 4px; }
.attention-row button { background: white; border: 1px solid var(--line); border-radius: 8px; font-size: 8px; font-weight: 800; min-height: 31px; padding: 0 10px; }
.empty-inline { color: var(--muted); font-size: 11px; padding: 22px 0; text-align: center; }

.vitrina-summary { align-items: center; display: flex; gap: 21px; justify-content: center; min-height: 113px; }
.vitrina-ring {
  align-items: center;
  background: conic-gradient(var(--accent-leaf) 0deg 280deg, #e8dfd4 280deg);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  height: 96px;
  justify-content: center;
  position: relative;
  width: 96px;
}
.vitrina-ring::before { background: var(--card); border-radius: 50%; content: ""; height: 74px; position: absolute; width: 74px; }
.vitrina-ring b, .vitrina-ring small { position: relative; z-index: 1; }
.vitrina-ring b { font-family: "Manrope", sans-serif; font-size: 26px; letter-spacing: -.05em; }
.vitrina-ring small { color: var(--muted); font-size: 6px; font-weight: 850; }
.vitrina-states { display: flex; flex-direction: column; gap: 10px; }
.vitrina-states span { align-items: center; color: var(--muted); display: flex; font-size: 8px; gap: 7px; }
.vitrina-states b { color: var(--ink); min-width: 12px; }
.dot { background: #d5c9bc; border-radius: 50%; height: 7px; width: 7px; }
.dot.full { background: var(--status-success); }
.dot.low { background: var(--status-warning); }
.dot.out { background: var(--status-danger); }
.btn-full { width: 100%; }

.live-label { align-items: center; color: var(--success); display: flex; font-size: 7px; font-weight: 850; gap: 5px; }
.live-label i { animation: pulse 1.7s infinite; background: var(--success); border-radius: 50%; height: 6px; width: 6px; }
@keyframes pulse { 50% { box-shadow: 0 0 0 5px rgba(20,125,112,.12); } }
.order-list { display: flex; flex-direction: column; gap: 8px; }
.order-row {
  align-items: center;
  border-bottom: 1px solid #eadfd3;
  display: grid;
  gap: 9px;
  grid-template-columns: 40px 1fr auto;
  padding: 2px 0 10px;
}
.order-row:last-child { border-bottom: 0; padding-bottom: 0; }
.order-number { align-items: center; background: #f1e9de; border-radius: 9px; display: flex; font-size: 9px; font-weight: 900; height: 36px; justify-content: center; }
.order-row b { display: block; font-size: 9px; }
.order-row small { color: var(--muted); display: block; font-size: 7px; margin-top: 3px; }
.status-tag { border-radius: 10px; font-size: 7px; font-weight: 850; padding: 5px 7px; white-space: nowrap; }
.status-new { background: #e8e8f7; color: #55539b; }
.status-preparing { background: #fff2d5; color: #8a5c09; }
.status-ready { background: #d9f1ed; color: #146b61; }

.team-preview { display: flex; flex-direction: column; gap: 9px; }
.team-mini {
  align-items: center;
  display: grid;
  gap: 9px;
  grid-template-columns: 32px 1fr auto;
}
.avatar { align-items: center; background: var(--ink); border-radius: 9px; color: white; display: flex; font-size: 8px; font-weight: 850; height: 32px; justify-content: center; width: 32px; }
.avatar.aqua { background: var(--accent-leaf); color: var(--ink); }
.avatar.primary { background: var(--brand-primary); }
.avatar.info { background: var(--status-info); }
.team-mini b { display: block; font-size: 9px; }
.team-mini small { color: var(--muted); display: block; font-size: 7px; margin-top: 2px; }
.team-mini > span:last-child { color: var(--success); font-size: 7px; font-weight: 800; }
.team-mini > span.late { color: #8a5c09; }
.team-mini > span.absent { color: var(--danger); }

.icon-button { align-items: center; background: #f1e9de; border: 0; border-radius: 8px; display: flex; font-size: 17px; height: 30px; justify-content: center; width: 30px; }
.task-list { display: flex; flex-direction: column; gap: 8px; }
.task-row {
  align-items: flex-start;
  display: grid;
  gap: 9px;
  grid-template-columns: auto 1fr auto;
}
.task-toggle {
  align-items: center;
  background: white;
  border: 1px solid #d5c9bc;
  border-radius: 6px;
  display: flex;
  height: 19px;
  justify-content: center;
  margin-top: 1px;
  padding: 0;
  width: 19px;
}
.task-toggle.done { background: var(--status-success); border-color: var(--status-success); color: white; }
.task-toggle.done::after { content: "✓"; font-size: 10px; font-weight: 900; }
.task-row b { display: block; font-size: 9px; line-height: 1.4; }
.task-row.done b { color: #9b8f84; text-decoration: line-through; }
.task-row small { color: var(--muted); display: block; font-size: 7px; margin-top: 2px; }
.task-priority { background: #f2ece3; border-radius: 8px; color: var(--muted); font-size: 6px; font-weight: 850; padding: 4px 6px; text-transform: uppercase; }
.task-priority.high { background: #f9e1e6; color: var(--danger); }

.activity-preview { display: grid; gap: 0; grid-template-columns: repeat(3, 1fr); }
.activity-mini { border-left: 1px solid var(--line); min-height: 66px; padding: 2px 15px; }
.activity-mini:first-child { border-left: 0; padding-left: 0; }
.activity-mini time { color: var(--brand-primary-dark); display: block; font-size: 8px; font-weight: 850; }
.activity-mini b { display: block; font-size: 9px; line-height: 1.35; margin-top: 6px; }
.activity-mini small { color: var(--muted); display: block; font-size: 7px; margin-top: 4px; }

/* Inner pages */
.view-panel { display: none; }
.view-panel.active { display: block; }
.section-toolbar { align-items: flex-end; display: flex; justify-content: space-between; margin: 6px 0 22px; }
.section-toolbar h2 { font-family: "Manrope", sans-serif; font-size: 25px; letter-spacing: -.05em; margin: 0; }
.section-toolbar p { color: var(--muted); font-size: 11px; margin: 7px 0 0; }
.toolbar-actions { align-items: center; display: flex; gap: 10px; }
.search-field { align-items: center; background: white; border: 1px solid var(--line-control); border-radius: 11px; display: flex; flex-direction: row; gap: 8px; height: 46px; padding: 0 12px; }
.search-field span { color: var(--muted); font-size: 17px; }
.search-field input { background: transparent; border: 0; box-shadow: none; font-size: 10px; height: 42px; min-height: 0; padding: 0; width: 190px; }
.search-field.compact { height: 36px; }
.search-field.compact input { height: 32px; width: 135px; }
.flavor-stats, .team-summary { display: grid; gap: 12px; grid-template-columns: repeat(4, 1fr); margin-bottom: 15px; }
.stat-tile { align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 14px; display: grid; gap: 11px; grid-template-columns: 36px 1fr; min-height: 70px; padding: 13px; }
.stat-tile > i { align-items: center; background: #f1e9de; border-radius: 10px; display: flex; font-size: 13px; font-style: normal; height: 36px; justify-content: center; width: 36px; }
.stat-tile b { display: block; font-family: "Manrope", sans-serif; font-size: 20px; letter-spacing: -.05em; }
.stat-tile small { color: var(--muted); display: block; font-size: 7px; margin-top: 2px; text-transform: uppercase; }
.data-card { padding: 0; overflow: hidden; }
.filter-row { align-items: center; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; min-height: 62px; padding: 12px 18px; }
.filter-row > span { color: var(--muted); font-size: 9px; }
.segmented { align-items: center; background: #f1e9de; border-radius: 9px; display: flex; gap: 2px; padding: 3px; }
.segmented button { background: transparent; border: 0; border-radius: 7px; color: var(--muted); font-size: 8px; font-weight: 750; min-height: 29px; padding: 0 11px; }
.segmented button.active { background: white; box-shadow: 0 2px 7px rgba(37,30,26,.08); color: var(--ink); }
.flavor-table { display: flex; flex-direction: column; }
.flavor-row {
  align-items: center;
  border-bottom: 1px solid #eadfd3;
  display: grid;
  gap: 13px;
  grid-template-columns: minmax(190px, 1.5fr) minmax(160px, 1fr) 100px 105px 125px;
  min-height: 72px;
  padding: 11px 18px;
}
.flavor-row:last-child { border-bottom: 0; }
.flavor-identity { align-items: center; display: grid; gap: 11px; grid-template-columns: 39px 1fr; }
.flavor-scoop { border-radius: 50% 50% 45% 45%; height: 35px; position: relative; width: 35px; }
.flavor-scoop::after { background: inherit; border-radius: 2px 2px 6px 6px; bottom: -4px; content: ""; height: 8px; left: 14px; position: absolute; width: 7px; }
.flavor-identity b { display: block; font-size: 10px; }
.flavor-identity small { color: var(--muted); display: block; font-size: 7px; margin-top: 3px; }
.stock-meter { align-items: center; display: flex; gap: 9px; }
.stock-meter > span { background: #eadfd3; border-radius: 4px; height: 6px; overflow: hidden; width: 90px; }
.stock-meter i { border-radius: inherit; display: block; height: 100%; }
.stock-meter small { color: var(--muted); font-size: 8px; min-width: 28px; }
.stock-pill { border-radius: 12px; display: inline-flex; font-size: 7px; font-weight: 850; justify-content: center; padding: 6px 8px; width: fit-content; }
.stock-pill.full { background: #d9f1ed; color: #146b61; }
.stock-pill.low { background: #fff2d5; color: #8a5c09; }
.stock-pill.critical { background: #f9e1e6; color: #a72e46; }
.stock-pill.out { background: #e8dfd4; color: #5f554d; }
.flavor-row > small { color: var(--muted); font-size: 8px; }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; }
.row-actions button { background: white; border: 1px solid var(--line); border-radius: 8px; font-size: 8px; font-weight: 800; min-height: 31px; padding: 0 9px; }
.row-actions button.primary-mini { background: var(--ink); border-color: var(--ink); color: white; }

/* Replenishment */
.replenishment-board { display: grid; gap: 14px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.replenishment-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px; }
.replenishment-top { align-items: flex-start; display: flex; justify-content: space-between; }
.replenishment-flavor { align-items: center; display: flex; gap: 10px; }
.replenishment-flavor .flavor-scoop { height: 30px; width: 30px; }
.replenishment-flavor b { display: block; font-size: 10px; }
.replenishment-flavor small { color: var(--muted); display: block; font-size: 7px; margin-top: 3px; }
.priority-pill { border-radius: 9px; font-size: 7px; font-weight: 900; padding: 5px 7px; text-transform: uppercase; }
.priority-pill.urgent { background: #f9e1e6; color: var(--danger); }
.priority-pill.high { background: #fff2d5; color: #8a5c09; }
.priority-pill.normal { background: #eee6dc; color: var(--muted); }
.replenishment-quantity { align-items: baseline; display: flex; gap: 5px; margin: 22px 0 17px; }
.replenishment-quantity strong { font-family: "Manrope", sans-serif; font-size: 32px; letter-spacing: -.06em; }
.replenishment-quantity span { color: var(--muted); font-size: 9px; }
.tracker { display: grid; grid-template-columns: repeat(4, 1fr); margin: 18px 0 13px; }
.tracker span { color: #9b8f84; font-size: 6px; font-weight: 800; padding-top: 13px; position: relative; text-align: center; }
.tracker span::before { background: #d5c9bc; border: 3px solid var(--card); border-radius: 50%; content: ""; height: 8px; left: calc(50% - 4px); position: absolute; top: 0; width: 8px; z-index: 2; }
.tracker span::after { background: #d5c9bc; content: ""; height: 2px; position: absolute; right: 50%; top: 3px; width: 100%; }
.tracker span:first-child::after { display: none; }
.tracker span.done, .tracker span.current { color: var(--ink); }
.tracker span.done::before, .tracker span.current::before { background: var(--status-success); }
.tracker span.done::after, .tracker span.current::after { background: var(--status-success); }
.replenishment-actions { border-top: 1px solid var(--line); display: flex; gap: 7px; margin-top: 13px; padding-top: 13px; }
.replenishment-actions button { background: #f1e9de; border: 0; border-radius: 8px; flex: 1; font-size: 8px; font-weight: 800; min-height: 34px; }
.replenishment-actions button.primary-mini { background: var(--ink); color: white; }
.empty-promo { align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); display: flex; flex-direction: column; padding: 60px; text-align: center; }
.empty-promo > span { align-items: center; background: #d9f1ed; border-radius: 50%; color: var(--success); display: flex; font-size: 18px; height: 48px; justify-content: center; width: 48px; }
.empty-promo h3 { margin: 15px 0 5px; }
.empty-promo p { color: var(--muted); font-size: 10px; margin: 0; }

/* Cash */
.cash-layout { display: grid; gap: 15px; grid-template-columns: 1.05fr 1fr; }
.cash-hero {
  background:
    radial-gradient(circle at 85% 10%, rgba(20,125,112,.30), transparent 35%),
    var(--ink);
  border-radius: var(--radius-xl);
  color: white;
  min-height: 280px;
  overflow: hidden;
  padding: 30px;
  position: relative;
}
.cash-hero::after { border: 1px solid rgba(255,255,255,.07); border-radius: 50%; content: ""; height: 250px; position: absolute; right: -100px; top: 40px; width: 250px; }
.cash-hero > strong { display: block; font-family: "Manrope", sans-serif; font-size: clamp(48px, 6vw, 78px); letter-spacing: -.08em; margin: 22px 0 10px; position: relative; z-index: 1; }
.cash-hero > p { color: var(--on-dark-secondary); font-size: 10px; }
.cash-status { align-items: center; border-top: 1px solid rgba(255,255,255,.1); bottom: 25px; display: flex; gap: 8px; left: 30px; padding-top: 16px; position: absolute; right: 30px; }
.cash-status i { background: var(--status-success-on-dark); border-radius: 50%; height: 7px; width: 7px; }
.cash-status span { color: var(--on-dark-secondary); font-size: 9px; }
.payment-card { min-height: 280px; }
.payment-list { display: flex; flex-direction: column; gap: 14px; }
.payment-row { display: grid; gap: 11px; grid-template-columns: 35px 1fr auto; align-items: center; }
.payment-row > span { align-items: center; background: #f1e9de; border-radius: 9px; display: flex; height: 35px; justify-content: center; }
.payment-row b { display: block; font-size: 9px; }
.payment-row small { color: var(--muted); display: block; font-size: 7px; margin-top: 2px; }
.payment-row > strong { font-size: 12px; }
.cash-guide { align-items: center; background: var(--cream); display: flex; gap: 17px; grid-column: span 2; }
.cash-guide > span { align-items: center; background: var(--status-success-surface); border-radius: 12px; color: var(--status-success-dark); display: flex; font-size: 18px; height: 45px; justify-content: center; min-width: 45px; }
.cash-guide h3 { font-size: 13px; margin: 0 0 4px; }
.cash-guide p { color: var(--muted); font-size: 9px; line-height: 1.5; margin: 0; }

/* Team */
.team-roster { display: flex; flex-direction: column; }
.roster-row {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(190px, 1.5fr) 130px 120px 150px 110px;
  min-height: 75px;
  padding: 11px 18px;
}
.roster-row:last-child { border-bottom: 0; }
.roster-person { align-items: center; display: grid; gap: 11px; grid-template-columns: 38px 1fr; }
.roster-person .avatar { height: 38px; width: 38px; }
.roster-person b { display: block; font-size: 10px; }
.roster-person small, .roster-row > small { color: var(--muted); display: block; font-size: 8px; margin-top: 3px; }
.attendance-pill { border-radius: 11px; font-size: 7px; font-weight: 850; padding: 6px 8px; width: fit-content; }
.attendance-pill.present { background: #d9f1ed; color: #146b61; }
.attendance-pill.late { background: #fff2d5; color: #8a5c09; }
.attendance-pill.absent { background: #f9e1e6; color: #a72e46; }
.attendance-pill.scheduled, .attendance-pill.off { background: #eee6dc; color: #5f554d; }
.attendance-pill.break { background: #e8e8f7; color: #55539b; }
.roster-row > button { background: white; border: 1px solid var(--line); border-radius: 8px; font-size: 8px; font-weight: 800; min-height: 32px; }
.two-column-section { display: grid; gap: 15px; grid-template-columns: 1fr 1fr; margin-top: 15px; }
.task-list.full { gap: 12px; }
.incident-list { display: flex; flex-direction: column; gap: 10px; }
.incident-row { background: #fffbf6; border: 1px solid #eadfd3; border-radius: 11px; padding: 12px; }
.incident-top { align-items: flex-start; display: flex; justify-content: space-between; }
.incident-row b { display: block; font-size: 9px; line-height: 1.4; }
.incident-row p { color: var(--muted); font-size: 8px; line-height: 1.45; margin: 6px 0 9px; }
.incident-row footer { align-items: center; display: flex; justify-content: space-between; }
.incident-row footer small { color: var(--muted); font-size: 7px; }
.incident-row footer button { background: white; border: 1px solid var(--line); border-radius: 7px; font-size: 7px; font-weight: 800; min-height: 27px; padding: 0 8px; }
.severity { border-radius: 8px; font-size: 6px; font-weight: 900; padding: 4px 6px; text-transform: uppercase; }
.severity.high { background: #f9e1e6; color: var(--danger); }
.severity.medium { background: #fff2d5; color: #8a5c09; }
.severity.low { background: #eee6dc; color: var(--muted); }

/* Activity */
.activity-timeline { padding: 5px 22px 25px; }
.timeline-day { border-bottom: 1px solid var(--line); color: var(--muted); font-size: 8px; font-weight: 900; letter-spacing: .1em; padding: 17px 0 12px; }
.timeline-row { display: grid; gap: 14px; grid-template-columns: 52px 32px minmax(0,1fr) 130px; min-height: 72px; padding: 14px 0; position: relative; }
.timeline-row:not(:last-child)::after { background: var(--line); bottom: -14px; content: ""; left: 67px; position: absolute; top: 44px; width: 1px; }
.timeline-row time { color: var(--muted); font-size: 8px; font-weight: 750; padding-top: 9px; }
.timeline-icon { align-items: center; background: #f1e9de; border-radius: 9px; display: flex; font-size: 12px; height: 32px; justify-content: center; position: relative; z-index: 1; }
.timeline-icon.stock { background: #d9f1ed; }
.timeline-icon.cash { background: #fff2d5; }
.timeline-icon.incident { background: #f9e1e6; }
.timeline-icon.team { background: #e8e8f7; }
.timeline-content b { display: block; font-size: 10px; }
.timeline-content p { color: var(--muted); font-size: 8px; line-height: 1.4; margin: 4px 0 0; }
.timeline-user { align-items: center; display: flex; gap: 7px; justify-content: flex-end; }
.timeline-user .avatar { border-radius: 7px; height: 27px; width: 27px; }
.timeline-user span { font-size: 8px; }

/* Modals */
.modal {
  background: var(--card);
  border: 0;
  border-radius: 22px;
  box-shadow: 0 24px 80px rgba(37,30,26,.28);
  color: var(--ink);
  max-height: calc(100vh - 40px);
  max-width: 620px;
  overflow: auto;
  padding: 0;
  width: calc(100% - 32px);
}
.modal::backdrop { backdrop-filter: blur(4px); background: rgba(30,22,18,.62); }
.modal-small { max-width: 520px; }
.modal form { display: flex; flex-direction: column; gap: 17px; padding: 27px; }
.modal-head { align-items: flex-start; display: flex; justify-content: space-between; }
.modal-head h2 { font-family: "Manrope", sans-serif; font-size: 25px; letter-spacing: -.05em; margin: 7px 0 5px; }
.modal-head p { color: var(--muted); font-size: 10px; line-height: 1.5; margin: 0; max-width: 440px; }
.modal-close { align-items: center; background: #f1e9de; border: 0; border-radius: 50%; display: flex; font-size: 20px; height: 33px; justify-content: center; min-width: 33px; }
.form-grid { display: grid; gap: 13px; grid-template-columns: 1fr 1fr; }
.unit-field { position: relative; }
.unit-field input { padding-right: 44px; }
.unit-field i { color: var(--muted); font-size: 10px; font-style: normal; position: absolute; right: 14px; top: 17px; }
.modal-actions { border-top: 1px solid var(--line); display: flex; gap: 9px; justify-content: flex-end; padding-top: 18px; }
.modal-actions .btn { min-width: 120px; }
.split-actions { justify-content: space-between; }
.checklist-callout { align-items: center; background: var(--cream); border-radius: 13px; display: flex; gap: 12px; padding: 13px; }
.checklist-callout > span { align-items: center; background: var(--status-success-surface); border-radius: 9px; color: var(--status-success-dark); display: flex; font-size: 12px; font-weight: 900; height: 34px; justify-content: center; min-width: 34px; }
.checklist-callout b { display: block; font-size: 10px; }
.checklist-callout p { color: var(--muted); font-size: 8px; margin: 3px 0 0; }
.opening-checks { display: grid; gap: 8px; }
.opening-checks label { align-items: center; background: #fffbf6; border: 1px solid var(--line); border-radius: 10px; display: flex; flex-direction: row; padding: 10px 12px; }
.opening-checks input { accent-color: var(--brand-primary); height: 18px; min-height: 0; width: 18px; }
.opening-checks label span { letter-spacing: 0; }
.opening-checks b { display: block; font-size: 9px; }
.opening-checks small { color: var(--muted); display: block; font-size: 7px; margin-top: 2px; }
.close-summary { background: var(--ink); border-radius: 13px; color: white; display: grid; gap: 8px; grid-template-columns: repeat(3,1fr); padding: 15px; }
.close-summary span { border-left: 1px solid rgba(255,255,255,.1); display: flex; flex-direction: column; padding-left: 14px; }
.close-summary span:first-child { border-left: 0; padding-left: 0; }
.close-summary small { color: var(--on-dark-secondary); font-size: 6px; font-weight: 850; }
.close-summary b { font-size: 15px; margin-top: 5px; }
.stock-options { display: grid; gap: 7px; grid-template-columns: 1fr 1fr; }
.stock-options label { display: block; }
.stock-options input { opacity: 0; pointer-events: none; position: absolute; }
.stock-choice { align-items: center; border: 1px solid var(--line-control); border-radius: 11px; cursor: pointer; display: grid; gap: 1px 9px; grid-template-columns: 12px 1fr; min-height: 58px; padding: 10px; transition: border .15s, background .15s; }
.stock-choice i { background: #9b8f84; border-radius: 50%; grid-row: span 2; height: 10px; width: 10px; }
.stock-choice b { font-size: 9px; }
.stock-choice small { color: var(--muted); font-size: 7px; }
.stock-choice.full i { background: var(--status-success); }
.stock-choice.low i { background: var(--status-warning); }
.stock-choice.critical i { background: var(--status-danger); }
.stock-choice.out i { background: #70665d; }
.stock-options input:checked + .stock-choice { background: #f2ece3; border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.stock-options input:focus-visible + .stock-choice { outline: 3px solid var(--focus-ring); outline-offset: 2px; }

/* Utility */
.toast-region { bottom: 25px; display: flex; flex-direction: column; gap: 8px; pointer-events: none; position: fixed; right: 25px; z-index: 100; }
.toast {
  animation: toast-in .25s ease-out;
  background: var(--ink);
  border-radius: 11px;
  box-shadow: 0 12px 35px rgba(37,30,26,.22);
  color: white;
  display: grid;
  gap: 10px;
  grid-template-columns: 25px 1fr;
  max-width: 350px;
  min-width: 280px;
  padding: 13px;
}
.toast > span { align-items: center; background: var(--status-success); border-radius: 7px; color: white; display: flex; font-size: 11px; font-weight: 900; height: 25px; justify-content: center; }
.toast.error > span { background: var(--status-danger); color: white; }
.toast b { display: block; font-size: 9px; }
.toast small { color: var(--on-dark-secondary); display: block; font-size: 8px; margin-top: 3px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }
.loading-layer { align-items: center; background: rgba(247,242,232,.78); backdrop-filter: blur(3px); display: flex; flex-direction: column; inset: 0; justify-content: center; position: fixed; z-index: 150; }
.loading-layer p { color: var(--muted); font-size: 10px; font-weight: 750; margin-top: 12px; }
.loader { animation: spin .8s linear infinite; border: 3px solid var(--line); border-radius: 50%; border-top-color: var(--brand-primary); height: 30px; width: 30px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Responsive */
@media (max-width: 1240px) {
  .dashboard-grid { grid-template-columns: 1.25fr .85fr; }
  .attention-card, .activity-card { grid-column: span 2; }
  .vitrina-card, .orders-card, .team-card, .tasks-card { grid-column: span 1; }
  .metrics-grid { grid-template-columns: 1fr 1fr; }
  .replenishment-board { grid-template-columns: 1fr 1fr; }
  .flavor-row { grid-template-columns: minmax(180px,1.4fr) minmax(130px,1fr) 90px 110px; }
  .flavor-row > small { display: none; }
  .roster-row { grid-template-columns: minmax(180px,1.5fr) 120px 120px 110px; }
  .roster-row > small:nth-of-type(2) { display: none; }
  .auth-live-card { display: none; }
}

@media (max-width: 960px) {
  :root { --sidebar: 214px; }
  .auth-screen { grid-template-columns: .9fr 1.1fr; }
  .auth-copy h1 { font-size: 62px; }
  .shift-banner { grid-template-columns: 42px 1fr auto; }
  .shift-temperature { display: none; }
  .page-content, .topbar { padding-left: 25px; padding-right: 25px; }
  .flavor-stats, .team-summary { grid-template-columns: 1fr 1fr; }
  .cash-layout { grid-template-columns: 1fr; }
  .cash-guide { grid-column: span 1; }
  .two-column-section { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  body { padding-bottom: 66px; }
  .auth-screen { display: block; }
  .auth-story { display: none; }
  .auth-form-wrap { min-height: 100vh; padding: 28px; }
  .auth-form h2 { font-size: 36px; }
  .app-shell { display: block; }
  .sidebar { box-shadow: 15px 0 40px rgba(0,0,0,.18); display: none; position: fixed; width: 250px; }
  .sidebar.mobile-open { display: flex; }
  .topbar { height: 76px; padding: 0 16px; }
  .mobile-menu { display: block; margin-right: 10px; }
  .topbar > div:first-of-type { flex: 1; }
  .topbar h1 { font-size: 17px; }
  .topbar .eyebrow { font-size: 7px; }
  .today-date, .user-chip div, .user-chip > i { display: none; }
  .user-chip > span { height: 34px; width: 34px; }
  .page-content { padding: 16px 13px 35px; }
  .mobile-nav {
    background: rgba(255,255,255,.96);
    border-top: 1px solid var(--line);
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(5,1fr);
    height: 64px;
    left: 0;
    position: fixed;
    right: 0;
    z-index: 50;
  }
  .mobile-nav button { align-items: center; background: none; border: 0; color: var(--muted); display: flex; flex-direction: column; font-size: 7px; font-weight: 800; gap: 4px; justify-content: center; }
  .mobile-nav button span { font-size: 17px; }
  .mobile-nav button.active { color: var(--brand-primary-dark); }
  .shift-banner { align-items: start; gap: 12px; grid-template-columns: 38px 1fr; padding: 18px; }
  .shift-state-icon { border-radius: 10px; height: 36px; width: 36px; }
  .shift-banner .btn { grid-column: span 2; margin-top: 4px; width: 100%; }
  .shift-copy h2 { font-size: 17px; }
  .metrics-grid { gap: 9px; grid-template-columns: 1fr 1fr; }
  .metric-card { min-height: 124px; padding: 15px; }
  .metric-card > strong { font-size: 27px; }
  .metric-bottom.split { align-items: flex-start; flex-direction: column; gap: 3px; }
  .dashboard-grid { display: flex; flex-direction: column; }
  .attention-card { order: 0; }
  .vitrina-card { order: 1; }
  .orders-card { order: 2; }
  .tasks-card { order: 3; }
  .team-card { order: 4; }
  .activity-card { order: 5; }
  .activity-preview { display: block; }
  .activity-mini { border-left: 0; border-top: 1px solid var(--line); min-height: 0; padding: 11px 0; }
  .activity-mini:first-child { border-top: 0; }
  .section-toolbar { align-items: stretch; flex-direction: column; gap: 15px; }
  .section-toolbar h2 { font-size: 22px; }
  .toolbar-actions { align-items: stretch; flex-direction: column; }
  .search-field input { width: 100%; }
  .flavor-stats, .team-summary { gap: 8px; }
  .stat-tile { grid-template-columns: 30px 1fr; min-height: 61px; padding: 10px; }
  .stat-tile > i { height: 30px; width: 30px; }
  .stat-tile b { font-size: 17px; }
  .filter-row { align-items: stretch; flex-direction: column; gap: 10px; }
  .segmented { overflow-x: auto; width: 100%; }
  .segmented button { flex: none; }
  .flavor-row {
    align-items: center;
    gap: 9px;
    grid-template-columns: minmax(150px,1fr) auto;
    min-height: 78px;
    padding: 12px;
  }
  .flavor-row .stock-meter, .flavor-row > small { display: none; }
  .flavor-row .stock-pill { justify-self: end; }
  .flavor-row .row-actions { grid-column: span 2; justify-content: stretch; }
  .row-actions button { flex: 1; }
  .replenishment-board { grid-template-columns: 1fr; }
  .cash-hero { min-height: 245px; padding: 23px; }
  .cash-hero > strong { font-size: 52px; }
  .cash-status { left: 23px; right: 23px; }
  .cash-guide { align-items: flex-start; }
  .roster-row { gap: 9px; grid-template-columns: minmax(150px,1fr) auto; min-height: 91px; padding: 12px; }
  .roster-row > small { display: none; }
  .roster-row > button { grid-column: span 2; }
  .timeline-row { gap: 9px; grid-template-columns: 40px 30px 1fr; }
  .timeline-user { display: none; }
  .timeline-row:not(:last-child)::after { left: 55px; }
  .modal { border-radius: 18px 18px 0 0; margin: auto 0 0; max-height: calc(100vh - 12px); width: 100%; }
  .modal form { padding: 22px 17px; }
  .modal-head h2 { font-size: 22px; }
  .form-grid { grid-template-columns: 1fr; }
  .stock-options { grid-template-columns: 1fr 1fr; }
  .modal-actions { position: sticky; bottom: -22px; background: var(--card); padding-bottom: 18px; }
  .modal-actions .btn { flex: 1; min-width: 0; }
  .toast-region { bottom: 76px; left: 12px; right: 12px; }
  .toast { max-width: none; min-width: 0; width: 100%; }
}

@media (max-width: 390px) {
  .metrics-grid { grid-template-columns: 1fr; }
  .metric-card { min-height: 112px; }
  .stock-options { grid-template-columns: 1fr; }
}
