@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&display=swap");

:root {
  color-scheme: light;
  font-family: "Manrope", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --blue-950: #001d47;
  --blue-900: #003d76;
  --blue-800: #084c94;
  --blue-700: #005fb8;
  --blue-500: #1590e2;
  --blue-100: #e9f4ff;
  --blue-050: #f4f9ff;
  --orange: #ff9500;
  --orange-soft: #fff4e2;
  --ink: #16243a;
  --muted: #68788e;
  --line: #dfe9f4;
  --paper: #ffffff;
  --canvas: #f5f9fd;
  --green: #36b37e;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 5%, rgba(70, 173, 255, 0.12), transparent 22rem),
    var(--canvas);
}

a {
  color: inherit;
  text-decoration: none;
}

.topbar {
  min-height: 88px;
  padding: 12px max(5vw, calc((100vw - 1440px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid rgba(0, 61, 118, 0.1);
  box-shadow: 0 6px 28px rgba(0, 61, 118, 0.06);
  position: sticky;
  top: 0;
  z-index: 30;
}

.brand {
  display: flex;
  align-items: center;
  gap: 15px;
}

.brand img {
  width: 46px;
  height: 51px;
  object-fit: contain;
}

.brand-divider {
  width: 1px;
  height: 34px;
  background: #d6e1ec;
}

.brand-copy {
  display: grid;
  gap: 3px;
}

.brand-copy strong {
  color: var(--blue-900);
  font-size: 0.92rem;
  letter-spacing: -0.02em;
}

.brand-copy small {
  color: #7b8b9e;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.live-status {
  display: flex;
  align-items: center;
}

.live-status {
  gap: 8px;
  color: #52657a;
  font-size: 0.76rem;
  font-weight: 700;
}

.live-status > span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(54, 179, 126, 0.13);
}

.account-actions,
.current-user {
  display: flex;
  align-items: center;
}

.account-actions {
  gap: 14px;
}

.current-user {
  gap: 9px;
}

.user-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(145deg, var(--blue-500), var(--blue-900));
  border-radius: 50%;
  font-size: 0.72rem;
  font-weight: 800;
}

.current-user > span:last-child {
  display: grid;
  gap: 1px;
}

.current-user strong {
  max-width: 180px;
  overflow: hidden;
  color: var(--blue-950);
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.current-user small {
  color: #8796a8;
  font-size: 0.58rem;
}

.logout-button {
  min-height: 36px;
  padding: 0 13px;
  color: var(--blue-800);
  background: var(--blue-050);
  border-color: #d4e5f4;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.68rem;
  font-weight: 800;
}

.logout-button:hover:not(:disabled) {
  color: #fff;
  background: var(--blue-800);
  border-color: var(--blue-800);
}

.data-chip {
  padding: 9px 13px;
  color: var(--blue-800);
  background: var(--blue-100);
  border: 1px solid #cee4f8;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 800;
}

.app-shell {
  max-width: 1920px;
  min-height: calc(100vh - 88px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
}

.sidebar {
  height: calc(100vh - 88px);
  padding: 28px 17px 20px;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.96);
  border-right: 1px solid var(--line);
  position: sticky;
  top: 88px;
  overflow-y: auto;
}

.nav-group > p {
  margin: 0 12px 10px;
  color: #91a0b2;
  font-size: 0.61rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav-group nav {
  display: grid;
  gap: 5px;
}

.nav-item {
  min-height: 58px;
  padding: 9px 10px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  color: #53677d;
  border: 1px solid transparent;
  border-radius: 12px;
  transition:
    color 140ms ease,
    background 140ms ease,
    transform 140ms ease;
}

a.nav-item:hover {
  color: var(--blue-800);
  background: var(--blue-050);
}

.nav-item.active {
  color: var(--blue-900);
  background: #eaf5ff;
  border-color: #d3e9fb;
  box-shadow: inset 3px 0 0 var(--blue-500);
}

.nav-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  color: var(--blue-700);
  background: #fff;
  border: 1px solid #dbe9f5;
  border-radius: 9px;
  font-size: 1rem;
  font-weight: 800;
}

.nav-item > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.nav-item strong {
  font-size: 0.75rem;
}

.nav-item small {
  color: #8a9aab;
  font-size: 0.6rem;
  white-space: nowrap;
}

.nav-count {
  min-width: 28px;
  padding: 4px 6px;
  color: var(--blue-800);
  background: #fff;
  border: 1px solid #d5e7f7;
  border-radius: 999px;
  font-size: 0.59rem;
  text-align: center;
}

.nav-planning {
  margin-top: 28px;
}

.nav-administration {
  margin-top: 28px;
}

.nav-item.disabled {
  color: #99a6b5;
  cursor: default;
}

.nav-item.disabled .nav-icon {
  color: #98a8b9;
  background: #f7f9fb;
}

.sidebar-source {
  margin-top: auto;
  padding: 14px;
  display: grid;
  gap: 6px;
  background: var(--blue-050);
  border: 1px solid #e0edf8;
  border-radius: 12px;
}

.sidebar-source > span {
  color: #8797a9;
  font-size: 0.59rem;
}

.sidebar-source strong {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--blue-900);
  font-size: 0.65rem;
}

.sidebar-source i {
  width: 7px;
  height: 7px;
  background: var(--green);
  border-radius: 50%;
}

.page-shell {
  min-width: 0;
}

main,
footer {
  width: min(1320px, calc(100% - 48px));
  margin-inline: auto;
}

.hero {
  min-height: 480px;
  padding: 62px 5.5%;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  align-items: center;
  gap: clamp(40px, 7vw, 110px);
  color: #fff;
  background:
    radial-gradient(circle at 89% 20%, rgba(70, 173, 255, 0.36), transparent 15rem),
    radial-gradient(circle at 5% 100%, rgba(21, 144, 226, 0.28), transparent 22rem),
    linear-gradient(125deg, #003264 0%, #004c91 52%, #0074c8 100%);
  border-radius: 0 0 34px 34px;
  overflow: hidden;
  position: relative;
}

.hero::after {
  content: "";
  position: absolute;
  right: -110px;
  top: -170px;
  width: 420px;
  height: 420px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  box-shadow:
    0 0 0 45px rgba(255, 255, 255, 0.025),
    0 0 0 100px rgba(255, 255, 255, 0.018);
}

.hero-copy,
.portfolio-card {
  position: relative;
  z-index: 1;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--blue-500);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.16em;
}

.hero .eyebrow {
  color: #8ed2ff;
}

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

h1 {
  margin-bottom: 20px;
  font-size: clamp(2.9rem, 5vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
}

h1 span {
  color: #83ceff;
}

.hero-copy > p:not(.eyebrow) {
  max-width: 650px;
  margin-bottom: 28px;
  color: #d6e9fa;
  font-size: clamp(0.92rem, 1.2vw, 1.06rem);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

.primary-action {
  padding: 13px 21px;
  color: #fff;
  background: var(--orange);
  border-radius: 999px;
  box-shadow: 0 9px 24px rgba(255, 149, 0, 0.24);
  font-size: 0.82rem;
  font-weight: 800;
}

.primary-action:hover {
  background: #ee8900;
  transform: translateY(-1px);
}

.source-note {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #bcd9ee;
  font-size: 0.72rem;
}

.source-note i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #83ceff;
}

.source-note strong {
  color: #fff;
}

.portfolio-card {
  padding: 25px;
  background: rgba(255, 255, 255, 0.97);
  color: var(--ink);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 24px;
  box-shadow: 0 28px 65px rgba(0, 23, 65, 0.24);
}

.portfolio-heading,
.portfolio-heading > div,
.portfolio-progress > div:first-child,
.portfolio-footer {
  display: flex;
  justify-content: space-between;
}

.portfolio-heading {
  align-items: flex-start;
}

.portfolio-heading > div {
  flex-direction: column;
  gap: 5px;
}

.portfolio-heading span,
.portfolio-progress span {
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.portfolio-heading strong {
  color: var(--blue-900);
  font-size: 1rem;
}

.portfolio-heading .pulse {
  padding: 6px 9px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #17815d;
  background: #e9f8f2;
  border-radius: 999px;
  font-size: 0.64rem;
  letter-spacing: 0;
}

.pulse i {
  width: 6px;
  height: 6px;
  background: var(--green);
  border-radius: 50%;
}

.portfolio-total {
  padding: 30px 0 25px;
  display: grid;
  border-bottom: 1px solid var(--line);
}

.portfolio-total strong {
  color: var(--blue-900);
  font-size: clamp(3rem, 5vw, 4.25rem);
  line-height: 1;
  letter-spacing: -0.065em;
}

.portfolio-total span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.78rem;
}

.portfolio-progress {
  padding: 22px 0 20px;
}

.portfolio-progress strong {
  color: var(--blue-800);
  font-size: 0.76rem;
}

.progress-track {
  height: 8px;
  margin-top: 12px;
  background: #e5edf6;
  border-radius: 999px;
  overflow: hidden;
}

.progress-track span {
  width: 0;
  height: 100%;
  display: block;
  background: linear-gradient(90deg, var(--blue-500), var(--blue-700));
  border-radius: inherit;
  transition: width 500ms ease;
}

.portfolio-footer {
  gap: 15px;
}

.portfolio-footer span {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.7rem;
}

.portfolio-footer b {
  color: var(--ink);
}

.portfolio-footer i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

.dot-blue {
  background: var(--blue-500);
}

.dot-orange {
  background: var(--orange);
}

.metrics {
  margin-top: -31px;
  padding: 0 3.5%;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
  position: relative;
  z-index: 2;
}

.metric-card {
  min-height: 128px;
  padding: 21px;
  display: flex;
  align-items: center;
  gap: 17px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 16px 45px rgba(0, 61, 118, 0.09);
}

.metric-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  color: var(--blue-700);
  background: var(--blue-100);
  border-radius: 13px;
  font-size: 0.68rem;
  font-weight: 800;
}

.metric-attention .metric-icon {
  color: #b66800;
  background: var(--orange-soft);
}

.metric-card > div:last-child {
  display: grid;
  gap: 4px;
}

.metric-card span,
.metric-card small {
  color: var(--muted);
  font-size: 0.7rem;
}

.metric-card > div > strong {
  color: var(--blue-900);
  font-size: 1.9rem;
  line-height: 1;
  letter-spacing: -0.05em;
}

.overview-grid {
  margin: 26px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.75fr);
  gap: 20px;
}

.region-panel,
.next-step-panel,
.workspace {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 14px 42px rgba(0, 61, 118, 0.055);
}

.region-panel {
  padding: 27px;
}

.panel-heading,
.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

h2 {
  margin-bottom: 0;
  color: var(--blue-950);
  font-size: 1.35rem;
  letter-spacing: -0.035em;
}

.data-chip {
  padding: 7px 11px;
}

.region-breakdown {
  margin-top: 27px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 28px;
}

.region-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px 14px;
}

.region-name,
.region-value {
  font-size: 0.72rem;
  font-weight: 700;
}

.region-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.region-value {
  color: var(--blue-800);
}

.region-track {
  height: 6px;
  grid-column: 1 / -1;
  background: #eaf0f6;
  border-radius: 999px;
  overflow: hidden;
}

.region-track span {
  height: 100%;
  display: block;
  background: linear-gradient(90deg, var(--blue-500), #66a6ff);
  border-radius: inherit;
}

.region-item.review .region-name,
.region-item.review .region-value {
  color: #a86200;
}

.region-item.review .region-track span {
  background: var(--orange);
}

.region-loading {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 0.78rem;
}

.next-step-panel {
  padding: 29px;
  min-height: 260px;
  color: #fff;
  background:
    radial-gradient(circle at 100% 100%, rgba(70, 173, 255, 0.3), transparent 13rem),
    linear-gradient(145deg, var(--blue-950), var(--blue-900));
  border-color: transparent;
  overflow: hidden;
  position: relative;
}

.step-label {
  color: #83ceff;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.next-step-panel h2 {
  margin-top: 10px;
  color: #fff;
}

.next-step-panel p {
  max-width: 430px;
  margin: 16px 0 24px;
  color: #c8dced;
  font-size: 0.78rem;
  line-height: 1.65;
}

.step-status {
  display: grid;
  gap: 4px;
}

.step-status span {
  color: #91b3cf;
  font-size: 0.65rem;
}

.step-status strong {
  color: #fff;
  font-size: 0.76rem;
}

.step-number {
  position: absolute;
  right: 19px;
  bottom: -18px;
  color: rgba(255, 255, 255, 0.07);
  font-size: 7.8rem;
  font-weight: 800;
  line-height: 1;
}

.workspace {
  margin: 0 0 46px;
  padding: 29px;
}

.master-page {
  padding-top: 42px;
}

.page-title {
  margin-bottom: 24px;
  padding: 4px 2px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.page-title h1 {
  margin-bottom: 10px;
  color: var(--blue-950);
  font-size: clamp(2.15rem, 4vw, 3.5rem);
}

.page-title > div > p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.back-link {
  padding: 10px 14px;
  flex: 0 0 auto;
  color: var(--blue-800);
  background: #fff;
  border: 1px solid #d7e5f2;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 800;
}

.back-link:hover {
  background: var(--blue-050);
}

.security-label {
  padding: 9px 13px;
  flex: 0 0 auto;
  color: #8a5a00;
  background: var(--orange-soft);
  border: 1px solid #f6dbad;
  border-radius: 999px;
  font-size: 0.66rem;
  font-weight: 800;
}

.user-management-grid {
  margin-bottom: 46px;
  display: grid;
  grid-template-columns: minmax(300px, 0.68fr) minmax(520px, 1.32fr);
  align-items: start;
  gap: 20px;
}

.user-form-card,
.user-list-card {
  padding: 27px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 14px 42px rgba(0, 61, 118, 0.055);
}

.user-form {
  margin-top: 26px;
  display: grid;
  gap: 17px;
}

.user-form label small {
  color: #91a0b2;
  font-size: 0.59rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.5;
  text-transform: none;
}

.form-alert {
  padding: 11px 13px;
  color: var(--blue-900);
  background: var(--blue-050);
  border: 1px solid #d9eaf8;
  border-radius: 10px;
  font-size: 0.7rem;
  line-height: 1.5;
}

.form-alert.error {
  color: #9f2f27;
  background: #fff1ef;
  border-color: #f3cfca;
}

.form-alert.success {
  color: #167052;
  background: #eaf8f3;
  border-color: #ccecdf;
}

.login-submit {
  min-height: 46px;
  color: #fff;
  background: var(--orange);
  border: 0;
  border-radius: 11px;
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 800;
  box-shadow: 0 9px 22px rgba(255, 149, 0, 0.2);
}

.login-submit:hover:not(:disabled) {
  background: #eb8900;
}

.login-submit:disabled,
.logout-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.user-list {
  margin-top: 20px;
  display: grid;
}

.user-row {
  padding: 16px 0;
  display: grid;
  grid-template-columns: 38px minmax(130px, 1.2fr) auto minmax(130px, 0.8fr) auto;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid #e7eef5;
}

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

.user-row-avatar {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: var(--blue-800);
  background: var(--blue-100);
  border-radius: 11px;
  font-size: 0.72rem;
  font-weight: 800;
}

.user-identity,
.user-login {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.user-identity strong,
.user-login strong {
  overflow: hidden;
  color: var(--blue-950);
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-identity span,
.user-login span {
  color: #8a9aab;
  font-size: 0.6rem;
}

.role-badge,
.status-badge {
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 0.56rem;
  font-weight: 800;
  text-align: center;
}

.role-badge.admin {
  color: #754c00;
  background: var(--orange-soft);
}

.role-badge.viewer {
  color: var(--blue-800);
  background: var(--blue-100);
}

.user-state {
  display: grid;
  justify-items: end;
  gap: 5px;
}

.status-badge.active {
  color: #167052;
  background: #eaf8f3;
}

.status-badge.inactive {
  color: #7a8796;
  background: #edf1f5;
}

.user-status-button {
  min-height: 0;
  padding: 0;
  color: var(--blue-700);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 0.58rem;
  font-weight: 700;
}

.user-status-button:disabled {
  color: #aab4c0;
  cursor: not-allowed;
}

.login-body {
  min-height: 100vh;
  background: #fff;
}

.login-layout {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(420px, 1.05fr) minmax(420px, 0.95fr);
}

.login-brand-panel {
  min-height: 100vh;
  padding: clamp(38px, 6vw, 82px);
  display: flex;
  flex-direction: column;
  color: #fff;
  background:
    radial-gradient(circle at 90% 15%, rgba(70, 173, 255, 0.34), transparent 18rem),
    radial-gradient(circle at 0 100%, rgba(21, 144, 226, 0.3), transparent 25rem),
    linear-gradient(135deg, #002d5c, #005ca9 70%, #087fc8);
  overflow: hidden;
  position: relative;
}

.login-brand-panel::after {
  content: "";
  position: absolute;
  right: -210px;
  bottom: -260px;
  width: 520px;
  height: 520px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  box-shadow:
    0 0 0 60px rgba(255, 255, 255, 0.025),
    0 0 0 125px rgba(255, 255, 255, 0.018);
}

.login-brand,
.login-message,
.login-brand-footer {
  position: relative;
  z-index: 1;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 15px;
}

.login-brand img {
  width: 54px;
  height: 60px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.login-brand > div {
  display: grid;
  gap: 3px;
}

.login-brand strong {
  font-size: 0.95rem;
}

.login-brand span {
  color: #a9d6f4;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.login-message {
  margin: auto 0;
}

.login-message h1 {
  max-width: 760px;
  margin-bottom: 24px;
  font-size: clamp(3rem, 5.7vw, 5.6rem);
}

.login-message > p:last-child {
  max-width: 570px;
  color: #c9e1f2;
  font-size: 0.92rem;
  line-height: 1.75;
}

.login-brand-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #a9cce5;
  font-size: 0.68rem;
}

.login-brand-footer i {
  width: 8px;
  height: 8px;
  background: #53d3a5;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(83, 211, 165, 0.12);
}

.login-form-panel {
  padding: 40px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 100% 0, rgba(70, 173, 255, 0.1), transparent 20rem),
    #fff;
}

.login-card {
  width: min(430px, 100%);
  display: grid;
  gap: 19px;
}

.login-card-heading {
  margin-bottom: 7px;
}

.login-card-heading > span {
  color: var(--blue-500);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.15em;
}

.login-card-heading h2 {
  margin: 9px 0 7px;
  font-size: 2rem;
}

.login-card-heading p,
.login-help {
  margin: 0;
  color: var(--muted);
  font-size: 0.72rem;
}

.login-card input {
  min-height: 50px;
}

.login-help {
  text-align: center;
}

.section-description {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 0.77rem;
}

.result-pill {
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--blue-800);
  background: var(--blue-050);
  border: 1px solid #dcebf8;
  border-radius: 999px;
  font-size: 0.7rem;
}

.result-pill span {
  width: 6px;
  height: 6px;
  background: var(--blue-500);
  border-radius: 50%;
}

.filters {
  margin: 27px 0 18px;
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(190px, 300px);
  gap: 14px;
  background: var(--blue-050);
  border: 1px solid #e0edf8;
  border-radius: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: #53677d;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.control-wrap {
  position: relative;
}

.search-control::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 50%;
  width: 10px;
  height: 10px;
  border: 2px solid #7890a8;
  border-radius: 50%;
  transform: translateY(-60%);
  z-index: 1;
}

.search-control::after {
  content: "";
  position: absolute;
  left: 25px;
  top: 25px;
  width: 6px;
  height: 2px;
  background: #7890a8;
  transform: rotate(45deg);
  transform-origin: left center;
}

input,
select,
button {
  min-height: 44px;
  border: 1px solid #ccdae8;
  border-radius: 10px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

input,
select {
  width: 100%;
  padding: 0 13px;
  outline: none;
}

.search-control input {
  padding-left: 40px;
}

input:focus,
select:focus {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(21, 144, 226, 0.11);
}

.table-shell {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
}

table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
}

th,
td {
  padding: 15px 17px;
  border-bottom: 1px solid #e8eff6;
  text-align: left;
  white-space: nowrap;
}

th {
  color: #6a7c90;
  background: #f7fafe;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

td {
  color: #52647a;
  font-size: 0.77rem;
}

td strong {
  color: var(--blue-950);
}

tbody tr {
  transition: background 120ms ease;
}

tbody tr:hover {
  background: #f7fbff;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  color: #177558;
  background: #eaf8f3;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.badge::before {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--green);
  border-radius: 50%;
}

.region-review {
  color: #a86200;
  font-weight: 800;
}

.empty-state {
  padding: 45px;
  color: var(--muted);
  text-align: center;
}

.empty-state strong,
.empty-state span {
  display: block;
}

.empty-state strong {
  color: var(--blue-900);
  margin-bottom: 5px;
}

.pagination {
  margin-top: 17px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
}

.pagination > div {
  display: flex;
  gap: 6px;
}

.pagination button {
  width: 41px;
  padding: 0;
  color: var(--blue-800);
  cursor: pointer;
  font-weight: 800;
}

.pagination button:hover:not(:disabled) {
  color: #fff;
  border-color: var(--blue-700);
  background: var(--blue-700);
}

.pagination button:disabled {
  cursor: not-allowed;
  opacity: 0.38;
}

.pagination > span {
  color: var(--muted);
  font-size: 0.72rem;
  text-align: center;
}

footer {
  padding: 24px 0 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  font-size: 0.7rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--blue-900);
}

.footer-brand img {
  width: 24px;
  height: 27px;
  object-fit: contain;
}

@media (max-width: 1040px) {
  .hero {
    grid-template-columns: minmax(0, 1.1fr) minmax(310px, 0.9fr);
    padding-inline: 4.5%;
    gap: 35px;
  }

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

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

  .user-management-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .app-shell {
    min-height: 0;
    display: block;
  }

  .sidebar {
    width: 100%;
    height: auto;
    min-height: 0;
    padding: 9px 4vw;
    display: block;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 88px;
    z-index: 20;
    overflow-x: auto;
  }

  .nav-group > p,
  .nav-planning,
  .sidebar-source {
    display: none;
  }

  .nav-administration {
    margin-top: 0;
  }

  .sidebar > .nav-group:not(.nav-planning) {
    display: inline-block;
  }

  .sidebar {
    white-space: nowrap;
  }

  .nav-group nav {
    display: flex;
    gap: 8px;
  }

  .nav-item {
    min-width: 155px;
    min-height: 48px;
    padding: 6px 9px;
    grid-template-columns: 30px minmax(0, 1fr) auto;
  }

  .nav-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }

  .nav-item small {
    display: none;
  }

  .login-layout {
    grid-template-columns: 1fr;
  }

  .login-brand-panel {
    min-height: 300px;
    padding: 35px 6vw;
  }

  .login-message {
    margin: 48px 0 25px;
  }

  .login-message h1 {
    margin-bottom: 15px;
    font-size: clamp(2.6rem, 8vw, 4.5rem);
  }

  .login-brand-footer {
    display: none;
  }

  .login-form-panel {
    padding: 55px 7vw 70px;
  }
}

@media (max-width: 760px) {
  .topbar {
    min-height: 76px;
  }

  .live-status {
    display: none;
  }

  .sidebar {
    top: 76px;
  }

  main,
  footer {
    width: min(100%, 92vw);
  }

  .hero {
    min-height: 0;
    padding: 45px 6% 60px;
    grid-template-columns: 1fr;
    border-radius: 0 0 25px 25px;
  }

  .portfolio-card {
    max-width: 520px;
  }

  .metrics {
    padding-inline: 3%;
  }

  .region-breakdown {
    grid-template-columns: 1fr;
  }

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

  .page-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .current-user > span:last-child {
    display: none;
  }

  .account-actions {
    gap: 8px;
  }

  .logout-button {
    padding-inline: 10px;
  }

  .user-row {
    grid-template-columns: 38px minmax(125px, 1fr) auto;
  }

  .user-login {
    grid-column: 2 / -1;
  }

  .user-state {
    grid-column: 2 / -1;
    grid-row: 3;
    justify-items: start;
  }
}

@media (max-width: 540px) {
  .brand-copy strong {
    font-size: 0.78rem;
  }

  .brand-copy small {
    font-size: 0.58rem;
  }

  .brand img {
    width: 38px;
    height: 42px;
  }

  .brand-divider {
    display: none;
  }

  .hero {
    padding-top: 38px;
  }

  h1 {
    font-size: 2.75rem;
  }

  .metrics {
    grid-template-columns: 1fr;
    margin-top: -25px;
  }

  .metric-card {
    min-height: 105px;
  }

  .region-panel,
  .next-step-panel,
  .workspace {
    padding: 21px 17px;
    border-radius: 16px;
  }

  .section-heading,
  footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .result-pill {
    align-self: flex-start;
  }

  .login-brand-panel {
    min-height: 265px;
  }

  .login-message > p:last-child {
    display: none;
  }

  .login-brand img {
    width: 44px;
    height: 49px;
  }

  .user-form-card,
  .user-list-card {
    padding: 21px 17px;
    border-radius: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition: none !important;
  }
}
