:root {
  color-scheme: light;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f5f7f9;
  color: #10253c;
  --teal-900: #045f70;
  --teal-800: #057589;
  --teal-700: #07899e;
  --teal-100: #e8f7f9;
  --navy-900: #0d2942;
  --navy-700: #294a68;
  --muted: #687b8d;
  --line: #e1e8ee;
  --panel: #ffffff;
  --bg: #f4f7f9;
  --yellow: #f4b41a;
  --orange: #e56f3f;
}

* { box-sizing: border-box; }
html:not(.auth-navigation-ready) [data-admin-only="true"] { display: none !important; }
/* Home is core-only from the first paint; access-ui mirrors the same rule after auth bootstrap. */
.sidebar-nav .sidebar-link:not([href="home.html"]) { display: none !important; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  padding-left: calc(100vw / 6);
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0 auto 0 0;
  width: calc(100vw / 6);
  background: var(--teal-800);
  z-index: 0;
}

.sidebar-logo-wrap {
  position: fixed;
  top: 4px;
  left: 12px;
  width: calc((100vw / 6) - 32px);
  max-width: 150px;
  transform: scale(0.9504);
  transform-origin: left top;
  overflow: visible;
  z-index: 2;
  pointer-events: none;
}

.sidebar-logo { width: 100%; height: auto; object-fit: contain; display: block; }

.sidebar-nav {
  position: fixed;
  top: 112px;
  left: 12px;
  width: calc((100vw / 6) - 24px);
  max-width: 230px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}

.sidebar-user-info {
  position: fixed;
  left: 12px;
  bottom: 14px;
  width: calc((100vw / 6) - 24px);
  max-width: 230px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(212, 242, 247, 0.2);
  border: 1px solid rgba(212, 242, 247, 0.4);
  backdrop-filter: blur(2px);
  z-index: 3;
}

.sidebar-user-text { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.sidebar-user-info .user-name { color: #f3fdff; font-weight: 700; font-size: 12.6px; line-height: 1.2; }
.sidebar-user-info .user-handle,
.sidebar-user-info .user-role { color: #d1ecf2; font-size: 10.8px; line-height: 1.2; }

.profile-more-btn {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #d4f2f7;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}
.profile-more-btn:hover { background: rgba(212, 242, 247, 0.28); color: #f3fdff; }
.profile-more-btn:focus-visible { outline: 2px solid #d4f2f7; outline-offset: 2px; }

.profile-menu-popup {
  position: absolute;
  right: 6px;
  bottom: calc(100% + 8px);
  min-width: 170px;
  background: #0a6b7e;
  border: 1px solid rgba(212, 242, 247, 0.35);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(4, 43, 52, 0.35);
  padding: 6px;
  display: none;
  z-index: 4;
}
.profile-menu-popup.show { display: block; }
.profile-menu-item {
  width: 100%;
  border: 0;
  background: transparent;
  color: #d4f2f7;
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 600;
  border-radius: 8px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: left;
  cursor: pointer;
}
.profile-menu-item .item-icon { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.profile-menu-item:hover { background: rgba(212, 242, 247, 0.28); color: #f3fdff; }

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  color: #d4f2f7;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.1px;
  transition: background-color .18s ease, color .18s ease, transform .18s ease;
}
.sidebar-link:hover,
.sidebar-link.active { background: rgba(212, 242, 247, 0.16); border-color: rgba(212, 242, 247, 0.28); color: #f3fdff; }
.sidebar-link:hover { transform: translateX(1px); }
.sidebar-link .nav-icon { width: 21px; height: 21px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.sidebar-link .home-icon { width: 26px; height: 26px; stroke-width: 2.4; }
.sidebar-link .nav-label { white-space: nowrap; line-height: 1; }

.page { width: 100%; min-height: 100vh; position: relative; z-index: 1; }
.home-shell { width: min(1240px, calc(100% - 44px)); margin: 0 auto; padding: 24px 0 34px; }

.hero-card {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(250px, .55fr);
  gap: 28px;
  align-items: end;
  padding: 26px 28px;
  border-radius: 22px;
  color: #fff;
  background: linear-gradient(125deg, #0b354f 0%, #086d7e 58%, #0894a5 100%);
  box-shadow: 0 18px 42px rgba(15, 53, 73, .14);
}
.hero-card::after {
  content: "";
  position: absolute;
  width: 260px;
  height: 260px;
  right: -80px;
  top: -120px;
  border: 42px solid rgba(255,255,255,.055);
  border-radius: 50%;
}
.hero-copy,
.hero-personal { position: relative; z-index: 1; }
.hero-kicker-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.eyebrow,
.section-kicker { font-size: .68rem; font-weight: 850; letter-spacing: .15em; text-transform: uppercase; }
.eyebrow { color: #9fe9ef; }
.preview-pill {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  color: #d9f7f9;
  font-size: .61rem;
  font-weight: 750;
}
.hero-card h1 { max-width: 760px; margin: 0; font-size: clamp(1.7rem, 2.6vw, 2.75rem); line-height: 1.06; letter-spacing: -.035em; }
.hero-card p { max-width: 780px; margin: 10px 0 0; color: #d8f1f4; font-size: .92rem; line-height: 1.55; }
.hero-personal {
  justify-self: stretch;
  padding: 15px 16px;
  border-radius: 15px;
  background: rgba(4, 37, 55, .28);
  border: 1px solid rgba(220, 249, 251, .18);
  backdrop-filter: blur(5px);
}
.hero-personal span,
.hero-personal strong { display: block; }
.hero-personal .hero-date { margin-bottom: 10px; color: #9fe0e6; font-size: .68rem; font-weight: 700; }
.hero-personal strong { font-size: .98rem; }
.hero-personal span:last-child { margin-top: 4px; color: #cae9ed; font-size: .72rem; }

.section-block {
  margin-top: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background:
    radial-gradient(circle at top right, rgba(8, 148, 165, 0.07), transparent 34%),
    linear-gradient(180deg, #ffffff 0%, #f7fbfc 100%);
  box-shadow: 0 10px 30px rgba(25, 53, 75, .045);
}
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 16px; }
.section-heading.compact { margin-bottom: 14px; }
.section-kicker { display: block; margin-bottom: 5px; color: var(--teal-700); }
.section-heading h2,
.decision-card h2 { margin: 0; color: var(--navy-900); font-size: 1.2rem; letter-spacing: -.018em; }
.section-heading p,
.decision-card > p { max-width: 800px; margin: 6px 0 0; color: var(--muted); font-size: .77rem; line-height: 1.45; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; color: #7a8997; font-size: .66rem; font-weight: 650; white-space: nowrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend-dot { width: 8px; height: 8px; border-radius: 50%; background: #cbd4dc; }
.legend-dot.is-live { background: #18a37d; box-shadow: 0 0 0 3px #e3f6ef; }

.domain-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.domain-card {
  --domain-accent: #087d91;
  --domain-soft: #edf7f8;
  --domain-ink: #0b5f6e;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-width: 0;
  padding: 15px;
  border: 1px solid rgba(227, 233, 238, 0.95);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.92) 0%, rgba(251,252,253,0.98) 100%);
  box-shadow: 0 8px 18px rgba(20, 48, 68, 0.04);
  transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease;
}
.domain-card::before {
  content: attr(data-domain);
  position: absolute;
  right: -6px;
  bottom: -18px;
  z-index: 0;
  color: var(--domain-accent);
  font-size: 4.2rem;
  font-weight: 900;
  letter-spacing: -.08em;
  line-height: 1;
  text-transform: uppercase;
  opacity: .045;
  pointer-events: none;
}
.domain-card::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--domain-accent), color-mix(in srgb, var(--domain-accent) 35%, white));
  opacity: .85;
}
.domain-card > * { position: relative; z-index: 1; }
.domain-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--domain-accent) 38%, #e3e9ee);
  box-shadow: 0 16px 28px rgba(20, 48, 68, 0.1);
}
.domain-card[data-domain="workforce"] { --domain-accent: #3d63c8; --domain-soft: #eaf0ff; --domain-ink: #2b4ea8; }
.domain-card[data-domain="talent"] { --domain-accent: #7a4fc4; --domain-soft: #f3ecff; --domain-ink: #5d35a6; }
.domain-card[data-domain="culture"] { --domain-accent: #0b92a4; --domain-soft: #e6f8fa; --domain-ink: #067687; }
.domain-card[data-domain="organization"] { --domain-accent: #c98412; --domain-soft: #fff6e4; --domain-ink: #8f5d08; }
.domain-card[data-domain="relations"] { --domain-accent: #1d8a68; --domain-soft: #e7f7f0; --domain-ink: #146b50; }
.domain-card[data-domain="analytics"] { --domain-accent: #1a7f98; --domain-soft: #e8f6f9; --domain-ink: #0d6478; }
.domain-card-live {
  background:
    radial-gradient(circle at 92% 8%, rgba(11, 146, 164, 0.18), transparent 36%),
    linear-gradient(165deg, #f2fbfb 0%, #ffffff 58%);
  border-color: #9edbe2;
  box-shadow: 0 10px 24px rgba(11, 146, 164, 0.12), inset 0 3px 0 #0b92a4;
}
.domain-card-live:hover {
  box-shadow: 0 18px 32px rgba(11, 146, 164, 0.16), inset 0 3px 0 #0b92a4;
}
.domain-topline { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.domain-number {
  color: var(--domain-ink);
  font-size: .65rem;
  font-weight: 850;
  letter-spacing: .08em;
  opacity: .72;
}
.domain-status {
  padding: 4px 8px;
  border-radius: 999px;
  background: #eef2f5;
  color: #7c8b99;
  font-size: .56rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
  border: 1px solid transparent;
}
.domain-status.is-live {
  background: #d8f6ea;
  color: #0b7d60;
  border-color: #b6ead6;
  box-shadow: 0 0 0 3px rgba(24, 163, 125, 0.12);
}
.domain-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(160deg, #fff 0%, var(--domain-soft) 100%);
  color: var(--domain-ink);
  border: 1px solid color-mix(in srgb, var(--domain-accent) 18%, white);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
}
.domain-icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.domain-card h3 { margin: 10px 0 5px; color: #17344d; font-size: .9rem; line-height: 1.25; letter-spacing: -.01em; }
.domain-card > p { min-height: 48px; margin: 0; color: #718191; font-size: .67rem; line-height: 1.45; }
.workspace-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 12px; }
.workspace-tabs a,
.workspace-tabs button {
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid #e2e9ee;
  border-radius: 10px;
  background: #fff;
  color: #24455f;
  text-align: left;
  text-decoration: none;
  font: inherit;
}
.workspace-tabs a { cursor: pointer; }
.workspace-tabs a:hover { border-color: #9ed6dc; background: #f0fafb; }
.workspace-tabs button { cursor: not-allowed; opacity: .62; }
.workspace-tabs span,
.workspace-tabs small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.workspace-tabs span { font-size: .66rem; font-weight: 850; }
.workspace-tabs small { margin-top: 2px; color: #8795a2; font-size: .55rem; }
.workspace-tabs a.is-disabled { pointer-events: none; opacity: .55; background: #f5f7f9; }

.strategic-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, .75fr); gap: 14px; margin-top: 14px; }
.ulrich-card,
.decision-card { padding: 20px; border: 1px solid var(--line); border-radius: 20px; background: var(--panel); box-shadow: 0 10px 30px rgba(25, 53, 75, .045); }
.ghost-button { flex-shrink: 0; min-height: 31px; padding: 6px 10px; border: 1px solid #d9e2e8; border-radius: 999px; background: #f7f9fa; color: #83909b; font-size: .62rem; font-weight: 750; cursor: not-allowed; }
.ulrich-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.quadrant { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; align-items: center; min-height: 74px; padding: 10px 11px; border: 1px solid #e5eaee; border-radius: 13px; background: #fafcfd; }
.quadrant > span { width: 31px; height: 31px; display: inline-flex; align-items: center; justify-content: center; border-radius: 9px; font-size: .62rem; font-weight: 900; }
.quadrant div { min-width: 0; }
.quadrant strong,
.quadrant small { display: block; }
.quadrant strong { color: #193850; font-size: .69rem; }
.quadrant small { margin-top: 3px; color: #80909e; font-size: .56rem; line-height: 1.35; }
.quadrant b { color: #a0adb8; font-size: 1.15rem; }
.quadrant-strategic > span { color: #3d63c8; background: #eaf0ff; }
.quadrant-change > span { color: #a87a00; background: #fff6d7; }
.quadrant-employee > span { color: #0d8c8c; background: #e2f7f5; }
.quadrant-admin > span { color: #c35c38; background: #fff0e9; }
.ulrich-note { margin: 10px 2px 0; color: #82909d; font-size: .6rem; line-height: 1.4; }

.decision-card { background: linear-gradient(180deg, #102f49 0%, #0c4658 100%); color: #fff; }
.decision-card .section-kicker { color: #86dce4; }
.decision-card h2 { color: #fff; }
.decision-card > p { color: #c5e0e4; }
.decision-flow { display: flex; flex-direction: column; gap: 7px; margin-top: 14px; }
.decision-flow div { display: grid; grid-template-columns: 25px 72px minmax(0, 1fr); gap: 8px; align-items: center; padding: 8px 9px; border-radius: 10px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.09); }
.decision-flow div span { color: #78d4dd; font-size: .56rem; font-weight: 850; }
.decision-flow div strong { font-size: .68rem; }
.decision-flow div small { color: #bdd6da; font-size: .56rem; }
.decision-flow i { display: none; }

.home-footer-note { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 14px; padding: 14px 17px; border-radius: 15px; background: #eaf4f5; border: 1px solid #d1e6e8; }
.home-footer-note strong,
.home-footer-note span { display: block; }
.home-footer-note strong { color: #174456; font-size: .7rem; }
.home-footer-note span { margin-top: 2px; color: #6d818d; font-size: .6rem; line-height: 1.4; }
.home-footer-note a { flex-shrink: 0; color: #087e91; font-size: .64rem; font-weight: 800; text-decoration: none; }
.home-footer-note a:hover { text-decoration: underline; }

@media (min-width: 1180px) and (min-height: 700px) {
  .home-shell { padding-top: 16px; }
  .hero-card { padding: 20px 22px; }
  .hero-card h1 { font-size: clamp(1.55rem, 2.1vw, 2.25rem); }
  .section-block { padding: 16px; margin-top: 12px; }
  .section-heading { margin-bottom: 11px; }
  .domain-card { padding: 12px; }
  .domain-card > p { min-height: 42px; }
  .strategic-grid { margin-top: 10px; gap: 10px; }
  .ulrich-card,
  .decision-card { padding: 15px; }
  .quadrant { min-height: 62px; padding: 8px 9px; }
  .home-footer-note { margin-top: 10px; padding: 10px 14px; }
}

@media (max-width: 1180px) {
  .home-shell { width: calc(100% - 34px); }
  .domain-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strategic-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  body {
    padding-left: 0;
    padding-bottom: 82px;
  }

  body::before,
  .sidebar-logo-wrap { display: none; }

  .sidebar-nav {
    display: flex;
    position: fixed;
    top: auto;
    right: 12px;
    bottom: 12px;
    left: 12px;
    width: auto;
    max-width: none;
    flex-direction: row;
    gap: 6px;
    padding: 6px;
    border: 1px solid rgba(212, 242, 247, .45);
    border-radius: 18px;
    background: rgba(5, 117, 137, .96);
    box-shadow: 0 14px 32px rgba(10, 57, 70, .24);
    backdrop-filter: blur(10px);
    z-index: 40;
  }

  .sidebar-nav .sidebar-link[hidden] { display: none !important; }
  .sidebar-nav .sidebar-link {
    flex: 1 1 0;
    justify-content: center;
    gap: 8px;
    min-width: 0;
    padding: 9px 10px;
    font-size: .78rem;
  }
  .sidebar-nav .sidebar-link:hover { transform: none; }
  .sidebar-nav .sidebar-link .nav-icon,
  .sidebar-nav .sidebar-link .home-icon { width: 20px; height: 20px; }

  .sidebar-user-info {
    display: flex;
    top: 14px;
    right: 14px;
    bottom: auto;
    left: auto;
    width: 38px;
    height: 38px;
    max-width: none;
    padding: 0;
    border: 1px solid rgba(255,255,255,.28);
    background: rgba(4, 95, 112, .92);
    box-shadow: 0 8px 18px rgba(9, 52, 65, .2);
    backdrop-filter: blur(8px);
    z-index: 42;
  }
  .sidebar-user-text { display: none; }
  .profile-more-btn { width: 38px; height: 38px; }
  .profile-menu-popup {
    top: calc(100% + 8px);
    right: 0;
    bottom: auto;
  }

  .home-shell {
    width: calc(100% - 24px);
    padding-top: 14px;
    padding-bottom: 20px;
  }
  .hero-card { grid-template-columns: 1fr; gap: 14px; padding: 20px 58px 20px 20px; }
  .hero-personal { justify-self: start; width: 100%; }
  .section-heading { flex-direction: column; gap: 10px; }
}

@media (max-width: 640px) {
  .domain-grid,
  .ulrich-grid { grid-template-columns: 1fr; }
  .workspace-tabs { grid-template-columns: 1fr 1fr; }
  .home-footer-note { align-items: flex-start; flex-direction: column; }
  .hero-card h1 { font-size: 1.65rem; }
  .sidebar-nav .sidebar-link { font-size: .72rem; padding-inline: 8px; }
}