:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #17221f;
  background: #f4f6f5;
  font-synthesis: none;
}

* { box-sizing: border-box; }

body {
  min-width: 0;
  min-height: 100vh;
  margin: 0;
  background: #f4f6f5;
}

button, input { font: inherit; }

button, .button-link, .app-link {
  min-height: 42px;
  border: 1px solid #b8c1be;
  border-radius: 6px;
  background: #fff;
  color: #17221f;
  cursor: pointer;
  font-weight: 650;
}

button { padding: 0 16px; }

button:hover, .button-link:hover, .app-link:hover { border-color: #47635c; }
button:focus-visible, input:focus-visible, a:focus-visible { outline: 3px solid #e4a65d; outline-offset: 2px; }

.primary {
  border-color: #123d37;
  background: #123d37;
  color: #fff;
}

.primary:hover { border-color: #205d54; background: #205d54; }

.auth-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(360px, 1.1fr);
  min-height: 100vh;
}

.brand-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(36px, 7vw, 96px);
  background: #123d37;
  color: #fff;
}

.brand-panel h1 {
  max-width: 580px;
  margin: 44px 0 16px;
  font-size: clamp(2rem, 4vw, 4rem);
  line-height: 1.06;
  letter-spacing: 0;
}

.brand-panel > p:last-child { max-width: 480px; color: #c9d9d5; font-size: 1.05rem; line-height: 1.6; }

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 800;
}

.product-name { margin: 12px 0 0; font-weight: 750; }

.auth-panel { display: grid; place-items: center; padding: 32px; }
.auth-content { width: min(100%, 420px); }
.auth-content h2, .activation-panel h1 { margin: 6px 0 8px; font-size: 1.8rem; letter-spacing: 0; }
.eyebrow, .step-label { margin: 0; color: #a34f37; font-size: 0.76rem; font-weight: 800; text-transform: uppercase; }
.supporting { margin: 0 0 28px; color: #61706c; line-height: 1.55; }

.form-stack { display: grid; gap: 18px; }
.form-stack label { display: grid; gap: 7px; color: #34423e; font-size: 0.88rem; font-weight: 700; }
.form-stack input {
  width: 100%;
  min-height: 46px;
  border: 1px solid #acb7b3;
  border-radius: 6px;
  background: #fff;
  padding: 9px 11px;
  color: #17221f;
}

.form-status { min-height: 24px; margin: 18px 0 0; color: #47635c; }
.form-status.error { color: #a23c31; }

.activation-shell { width: min(100% - 32px, 760px); margin: 0 auto; padding: 36px 0 72px; }
.activation-header { display: flex; align-items: center; gap: 14px; margin-bottom: 40px; }
.activation-header p { margin: 2px 0; }
.activation-header p:last-child { color: #61706c; font-size: 0.84rem; }
.activation-panel { border-top: 4px solid #123d37; background: #fff; padding: clamp(28px, 6vw, 56px); box-shadow: 0 12px 32px rgb(30 50 44 / 8%); }
.app-link, .button-link { display: inline-flex; align-items: center; justify-content: center; padding: 0 16px; text-decoration: none; }
.app-link { margin-bottom: 18px; }
.secret-box { display: grid; gap: 6px; margin-bottom: 24px; border-left: 3px solid #e4a65d; background: #f5f7f6; padding: 14px 16px; }
.secret-box span { color: #61706c; font-size: 0.76rem; font-weight: 700; text-transform: uppercase; }
.secret-box strong { overflow-wrap: anywhere; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.recovery-codes { overflow: auto; border: 1px solid #d8dfdc; background: #f7f9f8; padding: 20px; line-height: 1.8; }
.action-row { display: flex; flex-wrap: wrap; gap: 10px; }

.management-header {
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #d9dfdd;
  background: #fff;
  padding: 10px clamp(18px, 4vw, 52px);
}

.brand-lockup, .header-actions, .page-heading, .workspace-panel { display: flex; align-items: center; }
.brand-lockup { gap: 12px; font-weight: 750; }
.brand-lockup .brand-mark { color: #123d37; }
.header-actions { gap: 8px; }
.management-shell { width: min(100% - 36px, 1180px); margin: 0 auto; padding: 46px 0; }
.page-heading { justify-content: space-between; gap: 24px; }
.page-heading h1 { margin: 5px 0 0; font-size: 2rem; letter-spacing: 0; }
.identity { color: #61706c; overflow-wrap: anywhere; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 32px; border: 1px solid #d9dfdd; background: #fff; }
.metric-grid article { min-width: 0; padding: 24px; border-right: 1px solid #d9dfdd; }
.metric-grid article:last-child { border-right: 0; }
.metric-grid span { font-size: 1.75rem; font-weight: 760; }
.metric-grid p { margin: 5px 0 0; color: #61706c; }
.workspace-panel { justify-content: space-between; gap: 24px; margin-top: 24px; border-top: 3px solid #e4a65d; background: #fff; padding: 24px; }
.workspace-panel h2, .workspace-panel p { margin: 0; }
.workspace-panel p { margin-top: 6px; color: #61706c; text-transform: capitalize; }
.state-badge { color: #1f6f55; font-size: 0.82rem; font-weight: 750; }
.resource-section { margin-top: 42px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 14px; }
.section-heading h2 { margin: 5px 0 0; font-size: 1.25rem; letter-spacing: 0; }
.data-list { border-top: 1px solid #cdd6d3; }
.data-row { display: flex; min-height: 70px; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid #d9dfdd; padding: 13px 4px; }
.data-row h3, .data-row p { margin: 0; }
.data-row h3 { font-size: 0.98rem; }
.data-row p { margin-top: 5px; color: #61706c; font-size: 0.86rem; }
.data-row .state-badge { text-transform: capitalize; }
.empty-state { margin: 0; border-bottom: 1px solid #d9dfdd; padding: 24px 4px; color: #61706c; }

[hidden] { display: none !important; }

@media (max-width: 760px) {
  .auth-layout { grid-template-columns: 1fr; }
  .brand-panel { min-height: 260px; padding: 30px 24px; }
  .brand-panel h1 { margin: 28px 0 8px; font-size: 2.25rem; }
  .auth-panel { place-items: start stretch; padding: 34px 24px 54px; }
  .auth-content { margin: 0 auto; }
  .management-header { align-items: flex-start; }
  .brand-lockup > span { display: none; }
  .page-heading { align-items: flex-start; flex-direction: column; }
  .identity { margin: 0; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric-grid article:nth-child(2) { border-right: 0; }
  .metric-grid article:nth-child(-n + 2) { border-bottom: 1px solid #d9dfdd; }
}

@media (max-width: 430px) {
  .header-actions button { padding: 0 10px; }
  .metric-grid { grid-template-columns: 1fr; }
  .metric-grid article { border-right: 0; border-bottom: 1px solid #d9dfdd; }
  .metric-grid article:nth-child(3) { border-bottom: 1px solid #d9dfdd; }
  .metric-grid article:last-child { border-bottom: 0; }
  .workspace-panel { align-items: flex-start; flex-direction: column; }
}
