:root {
  --bg: #e9ece3;
  --bg-soft: #f4f5ee;
  --panel: #fffefa;
  --panel-strong: #fffefa;
  --ink: #11140f;
  --muted: #6d746b;
  --line: rgba(21, 24, 18, 0.12);
  --line-strong: rgba(21, 24, 18, 0.2);
  --black: #0d0e0c;
  --accent-lime: #d8ff3d;
  --lime: var(--accent-lime);
  --lime-soft: #ecff9b;
  --mint: #bdf6d4;
  --mint-soft: #e8faef;
  /* Optional bento card backgrounds. Do not apply unless explicitly requested. */
  --bento-mint: #a6ffe8;
  --bento-ivory: #feffe3;
  --blue: #8dd6f1;
  --blue-soft: #e6f7ff;
  --lemon: #fff0a8;
  --danger: #c74652;
  --warning: #8b6815;
  --shadow: 0 24px 70px rgba(35, 38, 30, 0.11);
  --shadow-soft: 0 12px 28px rgba(35, 38, 30, 0.055);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius: 16px;
  --grid: rgba(38, 42, 32, 0.045);
  --bento-gap: 18px;
  --bento-x: 112px;
  --bento-1x: var(--bento-x);
  --bento-2x: calc(var(--bento-x) + var(--bento-x) + var(--bento-gap));
  --bento-4x: calc(var(--bento-x) + var(--bento-x) + var(--bento-x) + var(--bento-x) + var(--bento-gap) + var(--bento-gap) + var(--bento-gap));
  --font-extra-title: clamp(31px, 5vw, 68px);
  --font-title: clamp(20px, 2vw, 24px);
  --font-subtitle: 18px;
  --font-text: 14px;
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
}

body {
  min-height: 100%;
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: var(--font-text);
  color: var(--ink);
  background:
    linear-gradient(115deg, rgba(141, 214, 241, 0.42), transparent 34%),
    linear-gradient(245deg, rgba(216, 255, 61, 0.42), transparent 38%),
    var(--bg);
}

a { color: inherit; text-decoration: none; }
p { color: var(--muted); line-height: 1.55; }
h1, h2, h3, p { margin-top: 0; }
h1 {
  max-width: 760px;
  margin-bottom: 14px;
  font-size: var(--font-extra-title);
  line-height: 0.98;
  letter-spacing: 0;
}
h2 {
  margin-bottom: 12px;
  font-size: var(--font-title);
  line-height: 1.05;
  letter-spacing: 0;
}
h3 {
  margin-bottom: 10px;
  font-size: var(--font-subtitle);
  line-height: 1.2;
  letter-spacing: 0;
}

.user-main {
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 26px 0 52px;
}

.public-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: var(--font-subtitle);
}

.brand strong {
  letter-spacing: 0;
}

.brand small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 700;
}

.brand.inverse { color: #fff; }
.brand.inverse small { color: rgba(255,255,255,0.62); }

.brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: var(--black);
  color: var(--lime);
  font-size: var(--font-text);
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18);
}

.public-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 999px;
  background: rgba(255,255,255,0.54);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 800;
}

.public-nav a:not(.button) {
  padding: 9px 12px;
  border-radius: 999px;
}

.public-nav a:not(.button):hover {
  background: rgba(255,255,255,0.68);
  color: var(--ink);
}

.public-hero,
.account-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 22px;
  align-items: stretch;
  overflow: hidden;
  margin-bottom: 18px;
  padding: 30px;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 34px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.84), rgba(245,250,238,0.68)),
    linear-gradient(115deg, rgba(216,255,61,0.2), rgba(141,214,241,0.18));
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.public-hero {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: minmax(126px, auto);
  overflow: visible;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: space-between;
  gap: 26px;
}

.public-hero .hero-copy {
  grid-column: 1 / span 3;
  grid-row: 1 / span 2;
  min-height: 342px;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 34px;
  background: var(--panel-strong);
  padding: 30px;
  box-shadow: var(--shadow);
  backdrop-filter: none;
}

.public-hero p,
.account-hero p {
  max-width: 800px;
  margin-bottom: 0;
  font-size: var(--font-text);
}

.hero-metrics,
.admin-metrics {
  display: grid;
  gap: 12px;
}

.hero-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.public-hero .hero-metrics {
  display: contents;
}

.hero-metrics span,
.metric-card {
  min-height: 112px;
  display: grid;
  align-content: start;
  gap: 5px;
  border: 1px solid rgba(255,255,255,0.74);
  border-radius: 22px;
  background: var(--panel-strong);
  padding: 16px;
  box-shadow: var(--shadow-soft);
}

.hero-metrics span {
  grid-template-rows: auto 52px auto;
}

.public-hero .hero-metrics span {
  grid-row: 3;
}

.metric-card strong { font-size: var(--font-title); line-height: 1; }

.hero-metrics strong {
  min-height: 52px;
  display: flex;
  align-items: center;
  font-size: var(--font-subtitle);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.hero-metrics small,
.metric-card small {
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 800;
}

.hero-metrics small:first-child {
  color: rgba(17,20,15,0.48);
  text-transform: uppercase;
  font-weight: 900;
}

.hero-metrics em {
  color: var(--muted);
  font-size: var(--font-text);
  font-style: normal;
  font-weight: 400;
  line-height: 1.45;
}

.metric-status strong {
  gap: 9px;
}

.metric-status i {
  width: 13px;
  height: 13px;
  flex: 0 0 13px;
  border-radius: 999px;
  background: rgba(17,20,15,0.28);
  box-shadow: 0 0 0 5px rgba(17,20,15,0.06);
}

.metric-status.is-online i {
  background: var(--accent-lime);
  box-shadow: 0 0 0 5px rgba(216,255,61,0.28), 0 0 22px rgba(216,255,61,0.58);
}

.hero-note {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: space-between;
  overflow: hidden;
  isolation: isolate;
  min-height: 246px;
  border: 1px solid rgba(17,20,15,0.1);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(216,255,61,0.96), rgba(236,255,155,0.94));
  padding: 22px;
  color: var(--ink);
}

.public-hero .hero-note {
  grid-column: 4;
  grid-row: 1 / span 2;
  min-height: 342px;
}

.hero-note strong,
.hero-note span { display: block; }
.hero-note strong,
.hero-note > span,
.hero-steps {
  position: relative;
  z-index: 1;
}
.hero-note strong { font-size: var(--font-title); line-height: 1.1; }
.hero-note span { color: rgba(17,20,15,0.68); margin-top: 10px; line-height: 1.5; }

.hero-steps {
  display: grid;
  gap: 8px;
}

.hero-steps span {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border-radius: 999px;
  background: rgba(17,20,15,0.1);
  padding: 8px 12px 8px 8px;
  color: rgba(17,20,15,0.74);
  font-size: var(--font-text);
  font-weight: 900;
}

.hero-steps b {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--black);
  color: var(--lime);
  font-size: var(--font-text);
}

.panel {
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: var(--radius-xl);
  background: var(--panel);
  padding: 24px;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

.auth-wizard {
  border-color: rgba(255,255,255,0.18);
  background:
    linear-gradient(145deg, #3a3e36 0%, #252923 52%, #171a14 100%);
  color: #fff;
  margin-bottom: 18px;
  padding: 26px;
  box-shadow:
    0 16px 34px rgba(17,20,15,0.14),
    inset 0 1px 0 rgba(255,255,255,0.08);
}

.auth-wizard h2 {
  color: #fff;
}

.auth-wizard p {
  color: rgba(255,255,255,0.68);
}

.auth-wizard .eyebrow,
.auth-wizard label {
  color: rgba(255,255,255,0.62);
}

.wizard-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: start;
  margin-bottom: 20px;
}

.wizard-head p {
  max-width: 780px;
  margin-bottom: 0;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0;
}

.step-track {
  display: flex;
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 999px;
  background: rgba(255,255,255,0.5);
}

.step-track span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 900;
}

.step-track span.active {
  background: var(--black);
  color: var(--lime);
}

.auth-wizard .step-track {
  border-color: rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.08);
}

.auth-wizard .step-track span {
  color: rgba(255,255,255,0.62);
}

.auth-wizard .step-track span.active {
  background: var(--accent-lime);
  color: var(--black);
}

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

.auth-option {
  min-height: 164px;
  display: grid;
  align-content: space-between;
  gap: 12px;
  border: 0;
  border-radius: 26px;
  background: var(--panel-strong);
  color: var(--ink);
  padding: 22px;
  cursor: pointer;
  outline: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, border-color .18s ease;
}

.auth-option:hover,
.auth-option:focus-visible,
.auth-option:focus-within {
  border-color: rgba(17,20,15,0.16);
  background: var(--accent-lime);
  transform: translateY(-4px);
  box-shadow: 0 22px 48px rgba(35,38,30,0.18);
}

.auth-option:hover span,
.auth-option:hover .option-label,
.auth-option:focus-visible span,
.auth-option:focus-visible .option-label,
.auth-option:focus-within span,
.auth-option:focus-within .option-label {
  color: rgba(17,20,15,0.72);
}

.auth-option:hover em,
.auth-option:focus-visible em,
.auth-option:focus-within em {
  background: var(--black);
  color: #fff;
}

.auth-option:hover em::after,
.auth-option:focus-visible em::after,
.auth-option:focus-within em::after {
  background: #fff;
  color: var(--black);
}

.auth-option strong {
  font-size: var(--font-title);
  line-height: 1.1;
}

.auth-option span {
  color: var(--muted);
  line-height: 1.45;
}

.auth-option .option-label {
  color: rgba(17,20,15,0.62);
  font-size: var(--font-text);
  font-weight: 900;
  text-transform: uppercase;
}

.auth-option em {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  padding: 9px 12px;
  border-radius: 999px;
  background: var(--black);
  color: #fff;
  font-style: normal;
  font-weight: 900;
}

.auth-option em::after {
  content: "→";
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent-lime);
  color: var(--black);
  font-size: var(--font-text);
  line-height: 1;
}

.auth-form {
  max-width: 680px;
}

form { display: grid; gap: 12px; }
label { font-size: var(--font-text); font-weight: 850; color: var(--muted); }

input, select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px 15px;
  font: inherit;
  font-weight: 700;
  color: var(--ink);
  background: rgba(255,255,255,0.72);
}

input::placeholder { color: rgba(17,20,15,0.36); }

input:focus, select:focus {
  outline: 3px solid rgba(216,255,61,0.55);
  border-color: rgba(17,20,15,0.28);
}

.auth-wizard input,
.auth-wizard select {
  border-color: rgba(255,255,255,0.88);
  background: var(--panel-strong);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(17,20,15,0.04), 0 10px 24px rgba(0,0,0,0.12);
}

.auth-wizard input::placeholder {
  color: rgba(17,20,15,0.42);
  opacity: 1;
}

.auth-wizard input:focus,
.auth-wizard select:focus {
  border-color: var(--accent-lime);
  box-shadow: inset 0 0 0 1px rgba(17,20,15,0.04), 0 0 0 3px rgba(216,255,61,0.26), 0 10px 24px rgba(0,0,0,0.12);
}

.form-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.button, button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  background: var(--black);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
  font-size: var(--font-text);
  box-shadow: 0 8px 18px rgba(13,14,12,0.14);
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease, border-color .18s ease, filter .18s ease;
}

.button:not(.danger):hover,
.button:not(.danger):focus-visible,
button:not(.danger):hover,
button:not(.danger):focus-visible {
  border-color: rgba(17,20,15,0.16);
  background: var(--accent-lime);
  color: var(--black);
  filter: none;
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(35,38,30,0.18);
}

.button.secondary { background: var(--accent-lime); color: var(--black); }
.button.ghost { background: rgba(255,255,255,0.68); color: var(--ink); border: 1px solid rgba(255,255,255,0.9); box-shadow: none; }
.auth-wizard .auth-form > button:not(.danger),
.auth-wizard .form-actions button:not(.danger) {
  gap: 10px;
  padding-right: 12px;
  background: var(--panel-strong);
  color: var(--black);
  box-shadow: 0 10px 24px rgba(0,0,0,0.14);
}

.auth-wizard .auth-form > button:not(.danger)::after,
.auth-wizard .form-actions button:not(.danger)::after {
  content: "→";
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent-lime);
  color: var(--black);
  font-size: var(--font-text);
  line-height: 1;
  transition: background .18s ease, color .18s ease, transform .18s ease;
}

.auth-wizard .auth-form > button:not(.danger):hover,
.auth-wizard .auth-form > button:not(.danger):focus-visible,
.auth-wizard .form-actions button:not(.danger):hover,
.auth-wizard .form-actions button:not(.danger):focus-visible,
.auth-wizard .auth-form.is-complete > button:not(.danger),
.auth-wizard .auth-form.is-complete .form-actions button:not(.danger) {
  background: var(--accent-lime);
  color: var(--black);
}

.auth-wizard .auth-form > button:not(.danger):hover::after,
.auth-wizard .auth-form > button:not(.danger):focus-visible::after,
.auth-wizard .form-actions button:not(.danger):hover::after,
.auth-wizard .form-actions button:not(.danger):focus-visible::after,
.auth-wizard .auth-form.is-complete > button:not(.danger)::after,
.auth-wizard .auth-form.is-complete .form-actions button:not(.danger)::after {
  background: var(--black);
  color: #fff;
  transform: translateX(1px);
}

.auth-wizard .button.ghost {
  border: 1px solid rgba(255,255,255,0.18);
  background: transparent;
  color: #fff;
  box-shadow: none;
}
.auth-wizard .button.ghost:hover,
.auth-wizard .button.ghost:focus-visible {
  border-color: transparent;
  background: var(--accent-lime);
  color: var(--black);
  box-shadow: 0 18px 36px rgba(35,38,30,0.18);
}
.button.danger { background: var(--danger); color: #fff; }
.button.small { min-height: 36px; padding: 8px 13px; font-size: var(--font-text); }

.check-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 750;
}

.check-line input { width: auto; }

.email-confirm {
  width: min(680px, 100%);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--mint-soft);
  padding: 14px 16px;
  margin-bottom: 14px;
}

.auth-wizard .email-confirm {
  border-color: rgba(255,255,255,0.88);
  background: var(--panel-strong);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(17,20,15,0.04), 0 10px 24px rgba(0,0,0,0.12);
}

.email-confirm span {
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 850;
}

.email-confirm strong { overflow-wrap: anywhere; }
.email-confirm a { color: var(--ink); font-weight: 900; }
.auth-wizard .email-confirm strong,
.auth-wizard .email-confirm a { color: var(--ink); }
.resend-form { max-width: 680px; margin-top: 10px; }

.auth-wizard .resend-form .resend-button {
  width: 100%;
}

.public-info {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
  margin-bottom: 18px;
}

.info-copy {
  position: relative;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(17,20,15,0.1);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(180deg, rgba(216,255,61,0.96), rgba(236,255,155,0.94));
  padding: 22px;
  color: var(--ink);
}

.info-copy::after {
  content: "?";
  position: absolute;
  right: 14px;
  bottom: 2px;
  z-index: 0;
  color: rgba(17,20,15,0.08);
  font-size: 154px;
  font-weight: 950;
  line-height: 0.92;
  text-shadow: none;
  pointer-events: none;
}

.info-copy h2 {
  position: relative;
  z-index: 1;
  margin-bottom: 0;
  color: var(--ink);
  font-size: var(--font-title);
  line-height: 1.1;
}

.muted-eyebrow {
  position: relative;
  z-index: 1;
  color: rgba(17,20,15,0.68);
}

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

.info-list div {
  min-height: 172px;
  display: grid;
  grid-template-rows: 18px minmax(44px, auto) auto;
  align-content: start;
  gap: 10px;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 24px;
  background: var(--panel-strong);
  padding: 22px;
  box-shadow: var(--shadow-soft);
}

.info-list span {
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 900;
  line-height: 18px;
}

.info-list strong {
  display: flex;
  align-items: flex-start;
  font-size: var(--font-subtitle);
  line-height: 1.2;
}

.info-list p {
  align-self: start;
  font-size: var(--font-text);
  margin: 0;
}

.flash-list { display: grid; gap: 8px; margin-bottom: 18px; }

.flash {
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.78);
  box-shadow: var(--shadow-soft);
  font-weight: 800;
}

.flash.error { border-color: rgba(199,70,82,0.35); color: #8b2028; background: #fff0f1; }
.flash.success { border-color: rgba(15,159,148,0.28); color: #08766f; background: var(--mint-soft); }
.flash.otp { border-color: rgba(141,214,241,0.65); color: #174c66; background: var(--blue-soft); font-size: 18px; }

.admin-surface .flash-list {
  width: fit-content;
  max-width: 100%;
  margin: 0 0 16px;
}

.admin-surface .flash {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  align-items: center;
  gap: 10px;
  border-color: var(--admin-graphite-line);
  border-radius: 999px;
  background: linear-gradient(145deg, var(--admin-graphite-soft), var(--admin-graphite) 58%, #090b08);
  color: #fff;
  box-shadow: var(--shadow-soft);
  font-size: var(--font-text);
  line-height: 1.25;
}

.admin-surface .flash::before {
  content: "";
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 999px;
  background: var(--admin-lime);
  box-shadow: 0 0 0 5px rgba(208,255,0,0.12);
}

.admin-surface .flash.error,
.admin-surface .flash.success,
.admin-surface .flash.otp {
  border-color: var(--admin-graphite-line);
  background: linear-gradient(145deg, var(--admin-graphite-soft), var(--admin-graphite) 58%, #090b08);
  color: #fff;
}

.admin-surface .admin-login-card .flash-list {
  position: relative;
  z-index: 1;
  width: 100%;
  margin: 26px 0 0;
}

.admin-surface .admin-login-card .flash {
  width: 100%;
  border-radius: 24px;
  padding: 16px 18px;
}

.auth-wizard .flash-list {
  width: min(680px, 100%);
  margin: 0 0 16px;
}

.auth-wizard .flash {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  border-color: rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.82);
  box-shadow: none;
}

.auth-wizard .flash::before {
  content: "";
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.34);
}

.auth-wizard .flash.success,
.auth-wizard .flash.otp {
  border-color: rgba(216,255,61,0.3);
  background: rgba(216,255,61,0.12);
  color: #fff;
}

.auth-wizard .flash.success::before,
.auth-wizard .flash.otp::before {
  background: var(--accent-lime);
  box-shadow: 0 0 0 5px rgba(216,255,61,0.12);
}

.auth-wizard .flash.error {
  border-color: rgba(199,70,82,0.42);
  background: rgba(199,70,82,0.16);
  color: #fff;
}

.auth-wizard .flash.error::before {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(199,70,82,0.12);
}

.employee-main > .flash-list {
  width: fit-content;
  max-width: min(100%, 760px);
  margin: 0;
}

.employee-main > .flash-list .flash {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  align-items: center;
  gap: 10px;
  border-color: rgba(255,255,255,0.14);
  border-radius: 999px;
  background: linear-gradient(145deg, #252b24, var(--black) 62%);
  color: #fff;
  box-shadow: var(--shadow-soft);
  font-size: var(--font-text);
  line-height: 1.25;
}

.employee-main > .flash-list .flash::before {
  content: "";
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 999px;
  background: var(--accent-lime);
  box-shadow: 0 0 0 5px rgba(216,255,61,0.12);
}

.employee-main > .flash-list .flash.error::before {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(199,70,82,0.12);
}

.account-hero {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: var(--bento-1x);
  gap: var(--bento-gap);
  align-items: stretch;
  overflow: visible;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.account-hero-copy {
  grid-column: 1 / span 3;
  grid-row: 1 / span 2;
  min-height: 0;
  display: grid;
  align-content: space-between;
  gap: 24px;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 34px;
  background: var(--panel-strong);
  padding: 30px;
  box-shadow: var(--shadow);
}

.account-hero-copy h1 {
  max-width: 820px;
}

.account-summary-card {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 6px;
  border: 1px solid rgba(255,255,255,0.74);
  border-radius: 28px;
  background: var(--panel-strong);
  padding: 18px;
  box-shadow: var(--shadow-soft);
}

.account-summary-card small {
  color: rgba(17,20,15,0.48);
  font-size: var(--font-text);
  font-weight: 900;
  text-transform: uppercase;
}

.account-summary-card strong {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--ink);
  font-size: var(--font-title);
  line-height: 1.05;
}

.account-summary-card em {
  color: var(--muted);
  font-style: normal;
  font-size: var(--font-text);
  font-weight: 750;
}

.account-summary-card--status strong i {
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 999px;
  background: rgba(17,20,15,0.22);
}

.account-summary-card--status.is-online strong i {
  background: var(--accent-lime);
  box-shadow: 0 0 0 5px rgba(216,255,61,0.16);
}

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

.account-bento-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: var(--bento-1x);
  gap: var(--bento-gap);
  margin: 0;
  align-items: stretch;
}

.account-info-card {
  min-width: 0;
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 12px;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 28px;
  background: var(--panel-strong);
  padding: 24px;
  box-shadow: var(--shadow-soft);
}

.account-instructions .account-info-card {
  grid-row: span 4;
  min-height: 0;
}

.account-instructions .instruction-card {
  grid-template-rows: 82px minmax(0, 1fr);
  align-content: stretch;
  gap: 18px;
  padding: 28px 24px 24px;
}

.card-number {
  color: rgba(17,20,15,0.48);
  font-size: var(--font-text);
  font-weight: 900;
  line-height: 1;
}

.instruction-toggle {
  width: 100%;
  min-height: 82px;
  display: grid;
  grid-template-rows: 16px minmax(42px, auto);
  align-content: start;
  align-items: start;
  justify-content: stretch;
  justify-items: start;
  gap: 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  box-shadow: none;
  text-align: left;
  cursor: default;
}

.instruction-toggle::after {
  display: none;
}

button.instruction-toggle:not(.danger):hover,
button.instruction-toggle:not(.danger):focus-visible,
button.instruction-toggle:not(.danger):active {
  border-color: transparent;
  background: transparent;
  color: inherit;
  box-shadow: none;
  filter: none;
  transform: none;
}

.instruction-title {
  color: var(--ink);
  font-size: var(--font-subtitle);
  font-weight: 900;
  line-height: 1.2;
}

.instruction-body {
  min-width: 0;
  height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 16px;
  align-content: stretch;
}

.account-info-card ol {
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.5;
  font-size: var(--font-text);
}

.account-info-card .link-row {
  margin-top: 0;
  align-self: end;
}

.account-info-card .button.small,
.account-devices .button.small {
  background: var(--black);
  color: #fff;
}

.account-info-card .button.small:hover,
.account-info-card .button.small:focus-visible,
.account-devices .button.small:hover,
.account-devices .button.small:focus-visible {
  background: var(--accent-lime);
  color: var(--black);
}

.link-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 14px;
}

.mirror-note {
  margin: 16px 0 0;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  font-size: 14px;
}

.account-devices {
  display: grid;
  gap: var(--bento-gap);
  margin: 0;
}

.account-devices-head {
  min-height: var(--bento-2x);
  display: grid;
  align-content: start;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 28px;
  background: linear-gradient(145deg, #252b24, var(--black) 62%);
  color: #fff;
  padding: 24px;
  box-shadow: var(--shadow-soft);
}

.account-devices-head h2,
.account-devices-head p {
  color: #fff;
}

.account-devices-head .eyebrow {
  color: rgba(255,255,255,0.58);
}

.account-devices-head .flash-list {
  width: min(100%, 620px);
  margin: 20px 0 0;
}

.account-devices-head .flash {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  border-color: rgba(255,255,255,0.12);
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  color: #fff;
  box-shadow: none;
  font-size: var(--font-text);
  line-height: 1.25;
}

.account-devices-head .flash::before {
  content: "";
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 999px;
  background: var(--accent-lime);
  box-shadow: 0 0 0 5px rgba(216,255,61,0.12);
}

.account-devices-head .flash.error::before {
  background: var(--danger);
  box-shadow: 0 0 0 5px rgba(199,70,82,0.12);
}

.device-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr));
  grid-auto-rows: var(--bento-1x);
  gap: var(--bento-gap);
  align-items: stretch;
}

.device-card {
  min-width: 0;
  grid-row: span 4;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 26px;
  padding: 24px;
  background: var(--panel-strong);
  box-shadow: var(--shadow-soft);
  min-height: 0;
}

.device-card p { margin-bottom: 10px; font-size: 14px; }

.qr-wrap {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(220px, 304px) minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  margin-top: 12px;
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
}

.qr-link {
  min-width: 0;
  width: 100%;
  display: block;
}

.qr {
  width: min(100%, 304px);
  height: auto;
  aspect-ratio: 1;
  display: block;
  image-rendering: crisp-edges;
  border: 12px solid #fff;
  border-radius: 18px;
  box-shadow: 0 10px 22px rgba(17,20,15,0.08);
}

.qr-wrap p { font-size: 14px; margin: 6px 0 0; }

.qr-wrap > div {
  min-width: 0;
  overflow-wrap: anywhere;
}

.add-card {
  display: grid;
  gap: 12px;
  align-content: start;
  background: var(--panel-strong);
}

.empty-device {
  align-content: start;
  background: var(--panel-strong);
}

.empty-device-notes {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(17,20,15,0.1);
}

.empty-device-notes p {
  margin: 0;
  color: var(--muted);
  line-height: 1.48;
}

.empty-device-notes strong {
  color: var(--ink);
}

.fixed-profile-note {
  display: grid;
  gap: 6px;
  border-top: 1px solid rgba(17,20,15,0.1);
  border-bottom: 1px solid rgba(17,20,15,0.1);
  border-radius: 0;
  background: transparent;
  padding: 12px 0;
}

.fixed-profile-note strong { color: var(--ink); }
.fixed-profile-note span { color: var(--muted); line-height: 1.45; font-size: 14px; }

.admin-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.employee-shell {
  width: min(1540px, calc(100% - 40px));
  min-height: 100vh;
  display: grid;
  align-content: start;
  gap: var(--bento-gap);
  margin: 0 auto;
  padding: 20px 0 52px;
}

.admin-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 26px 22px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.admin-surface {
  --admin-lime: #d0ff00;
  --admin-cyan: #00bcc8;
  --admin-gray: #edf0ea;
  --admin-gray-strong: #dce0d8;
  --admin-graphite: #141813;
  --admin-graphite-soft: #252b24;
  --admin-graphite-line: rgba(255,255,255,0.13);
  --admin-white: #fffefa;
  --admin-muted: #70786d;
  --admin-shadow: 0 24px 64px rgba(15,18,13,0.13);
}

.admin-sidebar {
  background:
    radial-gradient(circle at 12% 8%, rgba(0,188,200,0.16), transparent 28%),
    radial-gradient(circle at 86% 18%, rgba(208,255,0,0.14), transparent 24%),
    linear-gradient(155deg, var(--admin-graphite-soft), var(--admin-graphite) 54%, #090b08);
  color: #fff;
  box-shadow: inset -1px 0 0 rgba(255,255,255,0.08);
}

.nav { display: grid; gap: 8px; }

.nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 13px;
  border-radius: 999px;
  color: rgba(255,255,255,0.78);
  font-weight: 850;
}

.nav a:first-child { background: var(--lime); color: var(--black); }
.nav a:hover { background: rgba(255,255,255,0.1); color: #fff; }

.admin-surface .brand.inverse small,
.admin-surface .sidebar-note {
  color: rgba(255,255,255,0.66);
}

.admin-surface .brand-mark {
  background: #050704;
  color: var(--admin-lime);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.14),
    0 12px 28px rgba(0,0,0,0.18);
}

.admin-surface .nav a:first-child {
  background: var(--admin-lime);
  color: #070906;
}

.admin-surface .nav a:hover {
  background: rgba(0,188,200,0.18);
  color: #fff;
}

.employee-topbar {
  display: grid;
  grid-template-columns: minmax(0, auto) auto;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 30px;
  background: linear-gradient(145deg, #343a31 0%, #242a23 58%, #151914 100%);
  color: #fff;
  padding: 16px 18px;
  box-shadow: var(--shadow-soft);
}

.employee-topbar .brand,
.employee-topbar .employee-session strong,
.employee-topbar .employee-session small {
  color: #fff;
}

.employee-topbar .brand small,
.employee-topbar .employee-session small {
  color: rgba(255,255,255,0.62);
}

.employee-topbar .brand-mark {
  background: #050704;
  color: var(--accent-lime);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.14),
    0 12px 28px rgba(0,0,0,0.18);
}

.employee-main {
  display: grid;
  gap: var(--bento-gap);
  padding: 0;
}

.employee-session {
  min-width: 0;
  justify-self: end;
  text-align: right;
}

.employee-session strong {
  display: block;
  color: var(--ink);
  font-size: var(--font-text);
  font-weight: 900;
}

.employee-session small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: var(--font-text);
  font-weight: 760;
  overflow-wrap: anywhere;
}

.employee-logout {
  min-width: 92px;
  background: #fffefa;
  color: var(--black);
}

.employee-logout:hover,
.employee-logout:focus-visible {
  background: var(--accent-lime);
  color: var(--black);
}

.sidebar-note {
  margin-top: auto;
  color: rgba(255,255,255,0.64);
  font-size: 13px;
  line-height: 1.55;
}

.main {
  padding: 28px;
  display: grid;
  gap: 18px;
  align-content: start;
}

.admin-main {
  gap: 20px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  border: 1px solid rgba(255,255,255,0.78);
  border-radius: 34px;
  background: var(--panel-strong);
  padding: 28px;
  box-shadow: var(--shadow);
}

.admin-surface .topbar {
  position: relative;
  overflow: hidden;
  border-color: rgba(255,255,255,0.82);
  background:
    linear-gradient(135deg, rgba(255,254,250,0.98), rgba(255,254,250,0.88)),
    radial-gradient(circle at 90% 12%, rgba(0,188,200,0.18), transparent 30%);
  box-shadow: var(--admin-shadow);
}

.admin-surface .topbar::after {
  content: "";
  position: absolute;
  right: 26px;
  bottom: 0;
  width: 160px;
  height: 6px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(90deg, var(--admin-lime), var(--admin-cyan));
  opacity: 0.9;
}

.topbar h1 {
  margin-bottom: 10px;
  font-size: var(--font-extra-title);
  line-height: 0.98;
}

.topbar p {
  max-width: 780px;
  margin-bottom: 0;
  font-size: var(--font-text);
}

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

.metric-card.lime { background: var(--lime); }
.metric-card.blue { background: var(--blue-soft); }
.metric-card.mint { background: var(--mint-soft); }
.metric-card.dark { background: var(--black); color: #fff; }
.metric-card.dark small,
.metric-card.dark span { color: rgba(255,255,255,0.62); }

.admin-surface .metric-card {
  min-height: 122px;
  border-color: rgba(255,255,255,0.8);
  background: var(--admin-white);
  box-shadow: var(--shadow-soft);
}

.admin-surface .metric-card span {
  color: rgba(17,20,15,0.52);
}

.admin-surface .metric-card small {
  color: var(--admin-muted);
  font-weight: 760;
}

.admin-surface .metric-card.lime {
  border-color: rgba(17,20,15,0.08);
  background: var(--admin-lime);
}

.admin-surface .metric-card.blue {
  border-color: rgba(0,188,200,0.34);
  background: var(--admin-cyan);
  color: #07100d;
}

.admin-surface .metric-card.blue span,
.admin-surface .metric-card.blue small,
.admin-surface .metric-card.lime span,
.admin-surface .metric-card.lime small {
  color: rgba(17,20,15,0.62);
}

.admin-surface .metric-card.mint {
  border-color: rgba(17,20,15,0.06);
  background: var(--admin-gray);
}

.admin-surface .metric-card.dark {
  border-color: var(--admin-graphite-line);
  background: linear-gradient(145deg, var(--admin-graphite-soft), var(--admin-graphite) 58%, #090b08);
  color: #fff;
}

.admin-surface .metric-card.dark small,
.admin-surface .metric-card.dark span {
  color: rgba(255,255,255,0.64);
}

.grid { display: grid; gap: 18px; }
.grid.two { grid-template-columns: minmax(0, 1.1fr) minmax(340px, 0.9fr); }

.admin-settings-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.admin-settings-card {
  align-content: start;
  gap: 11px;
  border-color: rgba(255,255,255,0.78);
  background: var(--panel-strong);
  backdrop-filter: none;
}

.admin-settings-card h2 {
  margin-bottom: 0;
}

.admin-settings-card .muted {
  margin-bottom: 0;
}

.admin-settings-card input,
.admin-settings-card select {
  border-color: rgba(17,20,15,0.1);
  background: var(--admin-white);
}

.admin-settings-card .button {
  justify-self: start;
  margin-top: 4px;
}

.admin-limit-card {
  border-color: rgba(17,20,15,0.08);
  background: var(--admin-lime);
}

.admin-account-card {
  border-color: rgba(0,188,200,0.22);
  background:
    linear-gradient(180deg, var(--admin-white), rgba(255,254,250,0.94)),
    linear-gradient(120deg, rgba(0,188,200,0.1), transparent 52%);
}

.admin-smtp-card {
  border-color: rgba(0,188,200,0.24);
  background:
    linear-gradient(150deg, rgba(0,188,200,0.14), var(--admin-white) 54%),
    var(--admin-white);
}

.admin-surface .admin-settings-card {
  box-shadow: var(--admin-shadow);
}

.admin-surface .admin-settings-card .button,
.admin-surface .topbar .button,
.admin-surface .button,
.admin-surface button {
  background: #070906;
  color: #fff;
}

.admin-surface .admin-settings-card .button:hover,
.admin-surface .admin-settings-card .button:focus-visible,
.admin-surface .topbar .button:hover,
.admin-surface .topbar .button:focus-visible,
.admin-surface .button:hover,
.admin-surface .button:focus-visible,
.admin-surface button:hover,
.admin-surface button:focus-visible {
  background: var(--admin-lime);
  color: #070906;
}

.admin-surface .button.ghost {
  border-color: rgba(17,20,15,0.08);
  background: var(--admin-white);
  color: var(--ink);
}

.limit-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 2px 0;
  padding: 13px 0;
  border-top: 1px solid rgba(17,20,15,0.12);
  border-bottom: 1px solid rgba(17,20,15,0.12);
}

.admin-surface .limit-summary {
  border-color: rgba(17,20,15,0.16);
}

.limit-summary span {
  display: grid;
  gap: 4px;
}

.limit-summary em {
  color: rgba(17,20,15,0.56);
  font-size: var(--font-text);
  font-style: normal;
  font-weight: 850;
}

.limit-summary strong {
  color: var(--ink);
  font-size: var(--font-title);
  line-height: 1;
}

.metric {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
}

.metric span { color: var(--muted); }
.metric strong { font-size: 18px; overflow-wrap: anywhere; }

.muted { color: var(--muted); }

.admin-surface .panel {
  border-color: rgba(255,255,255,0.82);
  background: var(--admin-white);
  box-shadow: var(--shadow-soft);
}

.admin-surface .panel > .metric {
  background: transparent;
}

.admin-surface .metric {
  border-bottom-color: rgba(17,20,15,0.1);
}

.admin-surface .metric span,
.admin-surface .muted,
.admin-surface p {
  color: var(--admin-muted);
}

.admin-surface .eyebrow {
  color: rgba(17,20,15,0.5);
}

.admin-surface .runtime-grid .metric {
  min-height: 68px;
  border-bottom-color: rgba(17,20,15,0.08);
}

.runtime-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 18px;
  margin-bottom: 8px;
}

.table {
  display: grid;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.46);
}

.admin-surface .table {
  border-color: rgba(17,20,15,0.08);
  background: var(--admin-gray);
}

.table-row {
  display: grid;
  grid-template-columns: 1.1fr 1.3fr 120px 260px;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}

.table-row:last-child { border-bottom: 0; }
.table.devices .table-row { grid-template-columns: 1.4fr 1fr 1fr 120px; }
.table-row.head { color: var(--muted); font-weight: 900; font-size: 13px; background: rgba(255,255,255,0.52); }

.admin-surface .table-row {
  border-bottom-color: rgba(17,20,15,0.08);
}

.admin-surface .table-row.head {
  color: rgba(17,20,15,0.52);
  background: rgba(0,188,200,0.1);
}

.status {
  width: fit-content;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(255,255,255,0.72);
  font-size: 12px;
  font-weight: 900;
}

.status.active { color: #08766f; background: var(--mint-soft); }
.status.suspended, .status.revoked { color: var(--warning); background: var(--lemon); }
.status.terminated { color: var(--danger); background: #fff0f1; }

.admin-surface .status {
  background: var(--admin-gray);
}

.admin-surface .status.active {
  color: #07100d;
  background: var(--admin-lime);
}

.admin-surface .status.suspended,
.admin-surface .status.revoked {
  color: #07100d;
  background: rgba(0,188,200,0.22);
}

.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.actions form { display: inline; }
.actions button {
  min-height: 34px;
  padding: 7px 10px;
  font-size: 12px;
  background: rgba(255,255,255,0.76);
  color: var(--ink);
  box-shadow: none;
}

.narrow {
  max-width: 500px;
  margin: 64px auto 0;
}

.admin-login-card {
  background: linear-gradient(150deg, rgba(255,255,255,0.86), var(--blue-soft));
}

.admin-surface .admin-login-card {
  position: relative;
  overflow: hidden;
  width: min(560px, calc(100% - 36px));
  max-width: 560px;
  min-height: 560px;
  display: grid;
  align-content: center;
  border-color: rgba(255,255,255,0.82);
  background: var(--admin-white);
  padding: clamp(36px, 4vw, 54px);
  color: var(--ink);
  box-shadow: var(--admin-shadow);
}

.admin-surface .admin-login-card h1 {
  position: relative;
  z-index: 1;
  max-width: 100%;
  margin-bottom: 0;
  color: var(--ink);
  font-size: clamp(38px, 4.1vw, 56px);
  line-height: 0.98;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}

.admin-surface .admin-login-card form {
  position: relative;
  z-index: 1;
  gap: 18px;
  margin-top: 34px;
}

.admin-surface .admin-login-card input {
  border-color: rgba(17,20,15,0.12);
  background: var(--admin-white);
}

.admin-login-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(190px, auto);
  gap: 12px;
  align-items: stretch;
}

.admin-login-actions .button {
  width: 100%;
}

.admin-surface .admin-reminder-button {
  border-color: rgba(17,20,15,0.1);
  background: var(--admin-gray);
  color: var(--ink);
  box-shadow: none;
}

.admin-surface .admin-reminder-button:hover,
.admin-surface .admin-reminder-button:focus-visible {
  background: var(--admin-lime);
  color: #070906;
}

.admin-login-icon {
  position: absolute;
  top: 36px;
  right: 34px;
  width: 126px;
  height: 126px;
  color: var(--admin-graphite);
  opacity: 0.07;
  pointer-events: none;
}

.admin-login-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.admin-login-card p {
  margin-bottom: 18px;
}

.admin-login-card h1 {
  font-size: clamp(38px, 4.6vw, 48px);
  overflow-wrap: normal;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

@media (max-width: 1120px) {
  .account-bento-grid,
  .admin-metrics,
  .admin-settings-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .device-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .user-main { width: min(100% - 24px, 760px); padding-top: 16px; }
  .public-header, .topbar { align-items: flex-start; flex-direction: column; }
  .public-nav { width: 100%; flex-wrap: wrap; border-radius: 22px; }
  .public-hero, .account-hero, .auth-options, .public-info, .grid.two {
    grid-template-columns: 1fr;
  }
  .admin-settings-grid {
    grid-template-columns: 1fr;
  }
  .public-hero, .account-hero { padding: 22px; }
  .public-hero {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: auto;
    padding: 0;
  }
  .public-hero .hero-copy,
  .public-hero .hero-note,
  .public-hero .hero-metrics span {
    grid-column: auto;
    grid-row: auto;
  }
  .public-hero .hero-copy,
  .public-hero .hero-note {
    grid-column: 1 / -1;
  }
  .public-hero .hero-copy,
  .public-hero .hero-note {
    min-height: auto;
  }
  .hero-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-hero {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }
  .account-hero-copy {
    grid-column: 1 / -1;
    grid-row: auto;
    min-height: auto;
  }
  .account-summary-card {
    grid-column: auto;
    grid-row: auto;
  }
  .wizard-head { grid-template-columns: 1fr; }
  .info-list { grid-template-columns: 1fr; }
  .admin-shell { grid-template-columns: 1fr; }
  .admin-sidebar {
    position: static;
    height: auto;
  }
  .employee-shell {
    width: min(100% - 24px, 920px);
    padding-top: 16px;
  }
  .main { padding: 20px; }
  .table-row, .table.devices .table-row { grid-template-columns: 1fr; }
  .runtime-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  :root {
    --bento-gap: 14px;
    --bento-x: 92px;
  }
  .user-main {
    width: calc(100% - 20px);
    padding-top: 12px;
  }
  .public-hero,
  .auth-wizard,
  .public-info {
    margin-bottom: 14px;
  }
  .public-info {
    gap: 14px;
  }
  .public-header { margin-bottom: 14px; }
  .public-hero, .account-hero, .panel {
    border-radius: 24px;
    padding: 18px;
  }
  .topbar {
    border-radius: 24px;
    padding: 18px;
  }
  .topbar h1 {
    margin-bottom: 8px;
  }
  .limit-summary {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .public-hero {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 0;
    border-radius: 0;
  }
  .public-hero .hero-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    width: 100%;
  }
  .public-hero .hero-copy,
  .public-hero .hero-note,
  .public-hero .hero-metrics span,
  .public-hero .hero-metrics span:nth-child(1),
  .public-hero .hero-metrics span:nth-child(2),
  .public-hero .hero-metrics span:nth-child(3),
  .public-hero .hero-metrics span:nth-child(4) {
    grid-column: 1;
    grid-row: auto;
  }
  .public-hero .hero-copy {
    align-content: start;
    width: 100%;
  }
  .public-hero .hero-note {
    width: 100%;
  }
  .public-hero .hero-copy {
    min-height: auto;
    padding: 18px;
    border-radius: 24px;
  }
  .public-hero, .account-hero {
    gap: var(--bento-gap);
  }
  .public-hero h1,
  .account-hero h1 {
    margin-bottom: 10px;
    font-size: var(--font-extra-title);
    line-height: 1.02;
  }
  .public-hero p,
  .account-hero p {
    font-size: var(--font-text);
    line-height: 1.42;
  }
  .hero-copy {
    gap: 16px;
  }
  .account-hero {
    grid-template-columns: 1fr;
    padding: 0;
    border-radius: 0;
  }
  .account-hero-copy {
    padding: 18px;
    border-radius: 24px;
  }
  .employee-shell {
    width: calc(100% - 20px);
    gap: var(--bento-gap);
    padding-top: 12px;
  }
  .employee-topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    border-radius: 24px;
    padding: 12px;
  }
  .employee-topbar .brand {
    min-width: 0;
    gap: 10px;
  }
  .employee-topbar .brand-mark {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    border-radius: 14px;
    font-size: 17px;
  }
  .employee-topbar .brand strong {
    display: block;
    max-width: 176px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 18px;
    line-height: 1.05;
  }
  .employee-topbar .brand small {
    display: none;
  }
  .employee-session {
    display: none;
  }
  .employee-logout {
    min-width: 0;
    width: auto;
    min-height: 42px;
    padding: 9px 14px;
  }
  .account-bento-grid {
    grid-template-columns: 1fr;
    gap: var(--bento-gap);
    grid-auto-rows: auto;
  }
  .account-info-card {
    grid-column: 1;
    grid-row: auto;
    min-height: auto;
    border-radius: 24px;
    padding: 18px;
  }
  .account-instructions .account-info-card {
    grid-row: auto;
    min-height: auto;
    grid-template-rows: none;
    align-content: start;
  }
  .account-instructions .instruction-card {
    overflow: hidden;
    padding: 0;
  }
  .instruction-toggle {
    min-height: 112px;
    grid-template-columns: minmax(0, 1fr) 34px;
    grid-template-rows: auto auto;
    align-items: center;
    gap: 12px;
    border-radius: 24px;
    padding: 18px;
    cursor: pointer;
  }
  .instruction-toggle::after {
    content: "+";
    grid-column: 2;
    grid-row: 1 / span 2;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: rgba(17,20,15,0.08);
    color: rgba(17,20,15,0.68);
    font-size: var(--font-subtitle);
    font-weight: 900;
    line-height: 1;
    box-shadow: inset 0 0 0 1px rgba(17,20,15,0.08);
  }
  .instruction-card.is-open .instruction-toggle::after {
    content: "−";
    background: rgba(17,20,15,0.08);
    color: rgba(17,20,15,0.68);
  }
  button.instruction-toggle:not(.danger):hover,
  button.instruction-toggle:not(.danger):focus-visible,
  button.instruction-toggle:not(.danger):active {
    border-color: transparent;
    background: transparent;
    color: inherit;
    box-shadow: none;
    filter: none;
    transform: none;
  }
  .instruction-toggle .card-number,
  .instruction-title {
    grid-column: 1;
  }
  .instruction-body {
    height: auto;
    grid-template-rows: none;
    align-content: start;
    max-height: 0;
    overflow: hidden;
    gap: 14px;
    padding: 0 18px;
    opacity: 0;
    transition: max-height .28s ease, opacity .22s ease, padding-bottom .22s ease;
  }
  .instruction-card.is-open .instruction-body {
    max-height: 820px;
    padding-bottom: 18px;
    opacity: 1;
  }
  .account-devices {
    gap: var(--bento-gap);
  }
  .account-devices-head,
  .device-card {
    min-height: auto;
    border-radius: 24px;
    padding: 18px;
  }
  .device-grid {
    grid-auto-rows: auto;
  }
  .device-card {
    grid-row: auto;
    overflow: visible;
  }
  .device-profile-card {
    gap: 14px;
  }
  .device-profile-card .qr-wrap {
    gap: 14px;
    margin-top: 0;
  }
  .device-profile-card .qr-link {
    justify-self: center;
    max-width: min(100%, 300px);
  }
  .device-profile-card .qr {
    width: min(100%, 300px);
    border-width: 10px;
    border-radius: 16px;
  }
  .admin-metrics {
    grid-template-columns: 1fr;
  }
  .admin-surface .admin-login-card h1 {
    max-width: 100%;
    font-size: clamp(32px, 9.4vw, 38px);
    line-height: 0.96;
  }
  .admin-surface .admin-login-card {
    width: calc(100% - 20px);
    padding: 22px;
  }
  .admin-login-actions {
    grid-template-columns: 1fr;
  }
  .admin-login-icon {
    top: 18px;
    right: 18px;
    width: 96px;
    height: 96px;
    opacity: 0.06;
  }
  .hero-metrics {
    grid-template-columns: 1fr;
  }
  .hero-metrics span {
    min-height: 66px;
    grid-template-columns: 112px minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: 12px;
    align-items: center;
    padding: 12px 14px;
    border: 1px solid rgba(255,255,255,0.74);
    border-radius: 22px;
    background: var(--panel-strong);
    box-shadow: var(--shadow-soft);
  }
  .hero-metrics span:first-child {
    border-top: 1px solid rgba(255,255,255,0.74);
  }
  .hero-metrics small:first-child {
    grid-row: 1 / span 2;
  }
  .hero-metrics strong {
    min-height: 0;
    font-size: var(--font-subtitle);
  }
  .hero-metrics small {
    font-size: var(--font-text);
  }
  .hero-metrics em {
    font-size: var(--font-text);
  }
  .info-list {
    grid-auto-rows: 1fr;
    gap: 14px;
  }
  .info-list div {
    min-height: 190px;
    grid-template-rows: 20px auto auto;
    gap: 14px;
    padding: 20px;
  }
  .info-list p {
    font-size: var(--font-text);
  }
  .hero-note {
    min-height: auto;
    align-content: start;
    gap: 10px;
    padding: 18px;
    border: 1px solid rgba(17,20,15,0.1);
    border-radius: 24px;
    background:
      linear-gradient(180deg, rgba(216,255,61,0.96), rgba(236,255,155,0.94));
  }
  .hero-note strong {
    font-size: var(--font-title);
  }
  .info-copy {
    gap: 10px;
    padding: 18px;
    border-radius: 24px;
  }
  .info-copy h2 {
    font-size: var(--font-title);
  }
  .hero-note span {
    margin-top: 6px;
    font-size: var(--font-text);
    line-height: 1.36;
  }
  .hero-note > span {
    display: block;
  }
  .hero-steps {
    gap: 0;
  }
  .hero-steps span {
    min-height: 38px;
    padding: 6px 0;
    border-bottom: 1px solid rgba(17,20,15,0.1);
    border-radius: 0;
    background: transparent;
    font-size: var(--font-text);
  }
  .hero-steps b {
    width: 26px;
    height: 26px;
    flex: 0 0 26px;
  }
  .auth-option { min-height: auto; }
  .email-confirm { grid-template-columns: 1fr; }
  .panel-head { flex-direction: column; }
  .qr-wrap { grid-template-columns: 1fr; }
  .qr {
    width: min(100%, 340px);
  }
  .link-row .button {
    width: 100%;
  }
  .link-row form,
  .link-row form button {
    width: 100%;
  }
  .actions {
    display: grid;
  }
  .actions form,
  .actions button {
    width: 100%;
  }
}
