:root {
  color-scheme: light;
  --bg: #f4f7f8;
  --bg-strong: #edf3f5;
  --panel: #ffffff;
  --panel-soft: #f8fbfc;
  --ink: #19313d;
  --ink-soft: #55707e;
  --line: #d8e5ea;
  --shadow: 0 18px 46px rgba(20, 52, 70, 0.08);
  --shadow-soft: 0 10px 24px rgba(19, 49, 61, 0.06);
  --blue: #2d73b9;
  --teal: #0f8f91;
  --green: #32a46b;
  --green-soft: #e8f7ef;
  --blue-soft: #e9f3fc;
  --teal-soft: #e6f7f6;
  --amber: #bf8a1b;
  --amber-soft: #fff4da;
  --rose: #b55e6d;
  --rose-soft: #fbeff1;
  --danger: #b84f5c;
  --sidebar: #eef5f7;
  --sidebar-edge: #d7e5ea;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background:
    radial-gradient(circle at top right, rgba(45, 115, 185, 0.08), transparent 28%),
    radial-gradient(circle at top left, rgba(15, 143, 145, 0.08), transparent 26%),
    var(--bg);
  color: var(--ink);
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

.hidden {
  display: none !important;
}

.dashboard-page {
  min-height: 100vh;
  padding: 24px;
}

.status {
  min-height: 24px;
  margin-bottom: 12px;
  color: var(--teal);
  font-size: 0.94rem;
  font-weight: 700;
}

.status.error {
  color: var(--danger);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 8px;
  font-size: clamp(1.9rem, 3.7vw, 2.85rem);
  line-height: 1.02;
}

h2 {
  margin-bottom: 8px;
  font-size: 1.28rem;
  line-height: 1.2;
}

h3 {
  margin-bottom: 6px;
  font-size: 1rem;
  line-height: 1.3;
}

.login-shell {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 80px);
}

.login-card {
  width: min(460px, 100%);
  padding: 32px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

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

.brand-mark {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: linear-gradient(145deg, var(--blue), var(--teal));
  color: white;
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  box-shadow: 0 14px 28px rgba(15, 143, 145, 0.22);
}

.login-copy,
.header-subtitle,
.overview-summary,
.section-copy,
.sidebar-copy,
.meta-copy,
.team-empty,
.survey-description,
.survey-source,
.project-source {
  color: var(--ink-soft);
}

.dashboard-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.dashboard-sidebar {
  position: sticky;
  top: 24px;
  display: grid;
  gap: 22px;
  padding: 24px 20px;
  border: 1px solid var(--sidebar-edge);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.9)),
    var(--sidebar);
  box-shadow: var(--shadow-soft);
}

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

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

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  color: var(--ink-soft);
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}

.sidebar-link.active {
  border-color: rgba(15, 143, 145, 0.12);
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(45, 115, 185, 0.05);
}

.sidebar-link-text {
  justify-content: center;
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.8);
  text-decoration: none;
}

.nav-icon,
.icon-badge,
.project-icon,
.kpi-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 14px;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.nav-icon {
  width: 34px;
  height: 34px;
  background: rgba(45, 115, 185, 0.1);
  color: var(--blue);
}

.sidebar-note {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.76);
}

.sidebar-projects-explorer {
  display: grid;
  gap: 6px;
  margin: -2px 0 4px 54px;
  padding-left: 10px;
  border-left: 2px solid rgba(45, 115, 185, 0.12);
}

.sidebar-project-list {
  display: grid;
  gap: 6px;
}

.sidebar-project-item {
  display: grid;
  gap: 4px;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: rgba(244, 247, 248, 0.72);
  color: var(--ink);
  text-align: left;
}

.sidebar-project-item.active {
  border-color: rgba(45, 115, 185, 0.18);
  background: rgba(233, 243, 252, 0.95);
}

.sidebar-project-item strong {
  font-size: 0.92rem;
}

.sidebar-project-item span {
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.sidebar-project-item-add {
  place-items: center start;
  color: var(--blue);
  font-weight: 800;
}

.sidebar-footer {
  padding-top: 6px;
}

.dashboard-main {
  display: grid;
  gap: 22px;
}

.dashboard-header,
.section-heading,
.overview-card-top,
.project-card-top,
.project-headline,
.project-footer,
.survey-row-top,
.manager-profile,
.metric-tile,
.team-person,
.survey-progress-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.dashboard-header {
  padding: 6px 4px 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--blue);
  font-size: 0.73rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.notification-button {
  flex: 0 0 auto;
  padding: 0;
}

.notification-button svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.manager-profile {
  align-items: center;
  padding: 6px 6px 6px 10px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow-soft);
}

.manager-copy {
  min-width: 0;
}

.manager-copy strong {
  display: block;
  font-size: 0.98rem;
}

.manager-identity {
  margin: 4px 0 0;
  color: var(--ink-soft);
  font-size: 0.84rem;
}

.avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 2px solid white;
  border-radius: 999px;
  background: linear-gradient(145deg, var(--teal), var(--green));
  color: white;
  font-size: 0.76rem;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(15, 143, 145, 0.16);
}

.avatar-large {
  width: 42px;
  height: 42px;
  font-size: 0.82rem;
}

.overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
}

.overview-main-column {
  display: grid;
  gap: 18px;
}

.overview-card,
.kpi-card,
.project-card,
.team-person,
.modal-card {
  border: 1px solid rgba(216, 229, 234, 0.92);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
}

.overview-card,
.kpi-card,
.project-card {
  padding: 22px;
}

.overview-card-primary {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.9)),
    linear-gradient(135deg, rgba(233, 243, 252, 0.7), rgba(230, 247, 246, 0.72)),
    var(--overview-project-image),
    rgba(255, 255, 255, 0.96);
  background-size: cover, cover, cover, cover;
  background-position: center, center, center, center;
  background-repeat: no-repeat;
}

.overview-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: stretch;
}

.overview-content {
  display: grid;
  gap: 8px;
}

.overview-content h2 {
  margin-bottom: 0;
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1.02;
}

.status-pill,
.survey-badge,
.calendar-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.calendar-badge {
  background: var(--blue-soft);
  color: var(--blue);
}

.overview-controls {
  display: grid;
  gap: 14px;
}

.project-location-label {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  width: fit-content;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 800;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.field,
.form-grid,
.form-group {
  display: grid;
  gap: 10px;
}

.compact-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

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

label {
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink);
  outline: none;
}

textarea {
  min-height: 96px;
  padding: 12px 14px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(45, 115, 185, 0.4);
  box-shadow: 0 0 0 4px rgba(45, 115, 185, 0.08);
}

button {
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: 15px;
  cursor: pointer;
}

button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.primary-button {
  background: linear-gradient(135deg, var(--blue), var(--teal));
  color: white;
  font-weight: 800;
  box-shadow: 0 12px 26px rgba(45, 115, 185, 0.2);
}

.secondary-button {
  background: rgba(233, 243, 252, 0.76);
  color: var(--blue);
  font-weight: 800;
}

.danger-button {
  background: rgba(251, 239, 241, 0.9);
  color: var(--danger);
  font-weight: 800;
}

.roster-card {
  display: grid;
  gap: 16px;
}

.project-user-sheet {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.user-sheet-wrap {
  overflow: auto;
  max-height: min(52vh, 560px);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.user-sheet-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 860px;
  table-layout: fixed;
}

.user-sheet-table th,
.user-sheet-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(216, 229, 234, 0.78);
  text-align: left;
  vertical-align: middle;
}

.user-sheet-table th:nth-child(1),
.user-sheet-table td:nth-child(1) {
  width: 22%;
}

.user-sheet-table th:nth-child(2),
.user-sheet-table td:nth-child(2) {
  width: 28%;
}

.user-sheet-table th:nth-child(3),
.user-sheet-table td:nth-child(3) {
  width: 11%;
}

.user-sheet-table th:nth-child(4),
.user-sheet-table td:nth-child(4) {
  width: 27%;
}

.user-sheet-table th {
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.8);
}

.user-sheet-table tbody tr:last-child td {
  border-bottom: 0;
}

.inline-action-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.inline-action-row input {
  flex: 1 1 auto;
}

.user-cell-identity {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-cell-name {
  display: block;
  font-weight: 800;
}

.user-link-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.user-link-button:hover {
  color: var(--teal);
  text-decoration: underline;
}

.user-link-button:focus-visible {
  outline: 2px solid rgba(15, 143, 145, 0.38);
  outline-offset: 3px;
  border-radius: 8px;
}

.user-cell-role {
  display: block;
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.roster-person {
  min-height: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  overflow: hidden;
}

.roster-person-button,
.roster-person-static {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 76px;
  padding: 12px 14px;
}

.roster-person-button {
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.roster-person-button:hover {
  background: rgba(15, 143, 145, 0.06);
}

.roster-person-button:focus-visible {
  outline: 2px solid rgba(15, 143, 145, 0.38);
  outline-offset: -2px;
}

.roster-person-badge {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(45, 115, 185, 0.14), rgba(15, 143, 145, 0.14));
  color: var(--teal);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.roster-person-copy {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.roster-person-name {
  display: block;
  font-weight: 800;
}

.roster-person-meta {
  display: block;
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.user-sheet-link {
  font-weight: 700;
}

.editing-row {
  background: rgba(15, 143, 145, 0.06);
}

.table-input {
  width: 100%;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
  color: var(--ink);
}

.user-sheet-table td:nth-child(4) .table-input,
.user-sheet-table td:nth-child(4) .user-link-button {
  min-width: 220px;
}

.table-input-small {
  max-width: 88px;
}

.table-actions-cell {
  width: 1%;
  white-space: nowrap;
}

.table-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.compact-button {
  min-height: 38px;
  padding: 0 12px;
  white-space: nowrap;
}

.team-person {
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  background: var(--panel-soft);
  box-shadow: none;
}

.team-person-copy {
  min-width: 0;
}

.team-person-name {
  display: block;
  font-weight: 800;
}

.team-person-role {
  display: block;
  margin-top: 4px;
  color: var(--ink-soft);
  font-size: 0.86rem;
}

.team-empty {
  padding: 16px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.kpi-card {
  display: grid;
  gap: 16px;
}

.kpi-icon {
  width: 46px;
  height: 46px;
}

.kpi-icon[data-tone="blue"] {
  background: var(--blue-soft);
  color: var(--blue);
}

.kpi-icon[data-tone="teal"] {
  background: var(--teal-soft);
  color: var(--teal);
}

.kpi-icon[data-tone="green"] {
  background: var(--green-soft);
  color: var(--green);
}

.kpi-icon[data-tone="amber"] {
  background: var(--amber-soft);
  color: var(--amber);
}

.kpi-value {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1;
}

.kpi-label {
  display: block;
  margin-top: 6px;
  font-size: 0.94rem;
  font-weight: 800;
}

.kpi-trend {
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 700;
}

.projects-section {
  display: grid;
  gap: 16px;
}

.project-card-list {
  display: grid;
  gap: 18px;
}

.project-card {
  display: grid;
  gap: 18px;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.survey-service-card {
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.2fr);
  gap: 18px;
  align-items: stretch;
}

.survey-service-media {
  overflow: hidden;
  border-radius: 22px;
  min-height: 240px;
  background: linear-gradient(145deg, rgba(45, 115, 185, 0.18), rgba(15, 143, 145, 0.22));
}

.survey-service-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.survey-service-copy {
  display: grid;
  gap: 14px;
}

.project-card.is-active {
  border-color: rgba(45, 115, 185, 0.28);
  box-shadow: 0 18px 42px rgba(45, 115, 185, 0.12);
  transform: translateY(-1px);
}

.project-card-top {
  align-items: flex-start;
}

.project-headline {
  justify-content: flex-start;
  align-items: flex-start;
  flex: 1;
  min-width: 0;
}

.project-icon {
  width: 60px;
  height: 60px;
  border-radius: 20px;
  font-size: 0.84rem;
}

.project-icon[data-tone="teal"] {
  background: var(--teal-soft);
  color: var(--teal);
}

.project-icon[data-tone="blue"] {
  background: var(--blue-soft);
  color: var(--blue);
}

.project-title-block {
  min-width: 0;
}

.project-description {
  margin: 0;
  max-width: 780px;
  color: var(--ink-soft);
}

.project-source {
  margin: 8px 0 0;
  font-size: 0.85rem;
}

.card-menu {
  width: 42px;
  min-width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel-soft);
  color: var(--ink-soft);
  font-weight: 900;
}

.avatar-stack {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
}

.avatar-stack .avatar {
  margin-right: -10px;
}

.avatar-stack .avatar-more {
  background: #e7eef2;
  color: var(--ink-soft);
}

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

.tag-chip,
.metric-value,
.token-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  font-weight: 800;
}

.tag-chip {
  min-height: 30px;
  padding: 0 12px;
  background: var(--panel-soft);
  color: var(--ink-soft);
  font-size: 0.8rem;
}

.project-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric-tile {
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 6px;
  min-height: 118px;
  padding: 16px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 20px;
  background: var(--panel-soft);
}

.metric-label {
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.metric-value {
  min-height: 34px;
  padding: 0;
  color: var(--ink);
  font-size: 1.45rem;
}

.metric-detail {
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.survey-list-compact {
  display: grid;
  gap: 12px;
}

.survey-highlight {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.survey-response-legend {
  display: flex;
  flex-wrap: wrap;
  flex-basis: 100%;
  gap: 8px;
  align-items: center;
}

.survey-response-legend-label {
  color: var(--ink);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.survey-response-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 4px 10px 4px 6px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink);
  font-size: 0.74rem;
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(19, 49, 61, 0.05);
}

.survey-moment-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.survey-moment-legend-label {
  color: var(--ink);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.survey-moment-legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 16px;
  background: rgba(247, 251, 252, 0.96);
}

.survey-moment-legend-copy {
  display: grid;
  gap: 2px;
}

.survey-moment-legend-copy strong {
  font-size: 0.82rem;
  line-height: 1.1;
}

.survey-moment-legend-copy span {
  color: var(--ink-soft);
  font-size: 0.74rem;
  font-weight: 700;
}

.survey-row {
  display: grid;
  gap: 12px;
  padding: 16px 18px;
  border: 1px solid rgba(216, 229, 234, 0.88);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(248, 251, 252, 0.92), rgba(255, 255, 255, 0.94));
}

.survey-row-top {
  align-items: center;
}

.survey-card-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.survey-row-copy {
  min-width: 0;
}

.survey-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.status-pill {
  background: var(--green-soft);
  color: var(--green);
}

.survey-badge {
  background: var(--blue-soft);
  color: var(--blue);
}

.survey-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.survey-stat {
  padding: 12px 14px;
  border-radius: 16px;
  background: white;
}

.survey-stat-label {
  display: block;
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.survey-stat-value {
  display: block;
  margin-top: 6px;
  font-size: 1rem;
  font-weight: 800;
}

.progress-track {
  width: 100%;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dce9ee;
}

.progress-bar {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--blue), var(--green));
}

.project-footer {
  align-items: center;
  padding-top: 2px;
  border-top: 1px solid rgba(216, 229, 234, 0.72);
}

.footer-note {
  color: var(--ink-soft);
  font-size: 0.85rem;
}

.ghost-button {
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: transparent;
  color: var(--blue);
  font-weight: 800;
}

.modal-panel {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(19, 49, 61, 0.24);
  backdrop-filter: blur(8px);
}

.modal-card {
  width: min(640px, 100%);
  max-height: calc(100vh - 48px);
  padding: 24px;
  overflow: auto;
}

.modal-card-wide {
  width: min(912px, 100%);
}

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

.token-field {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
}

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

.token-list.token-list-sheet {
  display: block;
}

.token-chip {
  min-height: 32px;
  padding: 0 12px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 0.8rem;
}

.token-chip button {
  min-width: 0;
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-weight: 900;
}

.token-input {
  flex: 1 1 160px;
  min-width: 140px;
  min-height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
  outline: none;
}

.empty-state {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
  color: var(--ink-soft);
}

@media (max-width: 1200px) {
  .dashboard-shell {
    grid-template-columns: 1fr;
  }

  .dashboard-sidebar {
    position: static;
  }

  .sidebar-projects-explorer {
    margin-left: 0;
  }

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

@media (max-width: 980px) {
  .overview-grid,
  .overview-split,
  .survey-service-card,
  .project-metrics,
  .survey-stats {
    grid-template-columns: 1fr;
  }

  .dashboard-header,
  .header-actions,
  .project-card-top,
  .project-headline,
  .project-footer,
  .section-heading {
    flex-direction: column;
    align-items: stretch;
  }

}

@media (max-width: 720px) {
  .dashboard-page {
    padding: 16px;
  }

  .compact-fields,
  .compact-fields-3,
  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .button-row {
    flex-direction: column;
  }

  .button-row button,
  .ghost-button,
  .primary-button,
  .secondary-button,
  .danger-button {
    width: 100%;
  }

  .team-person {
    flex-direction: column;
    align-items: flex-start;
  }

  .metric-tile:nth-child(n + 3) {
    display: none;
  }

  .project-user-sheet {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  }

  .project-footer {
    gap: 10px;
  }
}

.survey-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-soft);
}

.survey-card > * {
  position: relative;
  z-index: 1;
}

.survey-card-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.survey-card-background::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.82)),
    linear-gradient(145deg, rgba(45, 115, 185, 0.08), rgba(15, 143, 145, 0.09));
}

.survey-card-background img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0.34;
  transform: scale(1.03);
  filter: saturate(1) contrast(0.96);
}

.survey-card-active {
  border-color: rgba(15, 143, 145, 0.22);
  border-radius: 24px 24px 12px 12px;
  box-shadow: 0 12px 24px rgba(15, 143, 145, 0.1);
}

.survey-detail-panel {
  display: grid;
  gap: 18px;
  padding: 18px 22px 22px;
  border: 1px solid rgba(15, 143, 145, 0.18);
  border-top: 0;
  border-radius: 0 0 24px 24px;
  background: linear-gradient(180deg, rgba(247, 251, 252, 0.96), rgba(255, 255, 255, 0.98));
  box-shadow: 0 18px 34px rgba(15, 143, 145, 0.1);
}

.survey-detail-panel-inline {
  margin-top: -12px;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 180ms ease, transform 220ms ease;
}

.survey-detail-panel-inline.survey-detail-panel-enter {
  opacity: 1;
  transform: translateY(0);
}

.survey-links-panel {
  display: grid;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid rgba(216, 229, 234, 0.92);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
}

.survey-links-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.survey-links-heading h3 {
  margin-bottom: 0;
  font-size: 1rem;
}

.survey-links-list {
  display: grid;
  gap: 10px;
}

.survey-link-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(216, 229, 234, 0.82);
  border-radius: 16px;
  background: rgba(248, 251, 252, 0.92);
}

.survey-link-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.survey-link-copy strong {
  font-size: 0.92rem;
}

.survey-link-copy span {
  color: var(--ink-soft);
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.survey-detail-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 2px;
}

.survey-detail-toolbar .calendar-badge {
  justify-self: center;
  min-width: 160px;
  text-align: center;
}

.survey-detail-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}

.survey-detail-stat {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-soft);
}

.survey-detail-stat strong {
  font-size: 1.4rem;
}

.survey-detail-respondents-heading {
  margin-top: 8px;
}

.manager-calendar-grid {
  --manager-moment-row-min-height: 58px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}

.manager-day-spacer {
  min-height: 120px;
}

.manager-day-cell {
  display: grid;
  gap: 10px;
  min-height: 120px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
}

.manager-day-cell-empty {
  background: #f5f8fa;
  color: var(--ink-soft);
}

.manager-day-cell-live,
.builder-day-cell-active {
  border-color: rgba(196, 214, 223, 0.95);
  background: linear-gradient(180deg, rgba(247, 251, 252, 0.98), rgba(241, 247, 249, 0.98));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.85);
}

.manager-day-cell-live {
  min-height: 0;
  grid-template-rows: auto minmax(0, 1fr);
}

.builder-day-cell[data-tone="morning"] {
  background: linear-gradient(180deg, #fff4da, #fffaf0);
}

.builder-day-cell[data-tone="afternoon"] {
  background: linear-gradient(180deg, #ffe5ba, #fff7e8);
}

.builder-day-cell[data-tone="night"] {
  background: linear-gradient(180deg, #e5efff, #f5f8ff);
}

.builder-day-cell[data-tone="morning-afternoon"] {
  background: linear-gradient(180deg, #ffe2ad, #fff5da);
}

.builder-day-cell[data-tone="morning-night"] {
  background: linear-gradient(180deg, #eef0d4, #f7f8ef);
}

.builder-day-cell[data-tone="afternoon-night"] {
  background: linear-gradient(180deg, #e7ddff, #f4f0ff);
}

.builder-day-cell[data-tone="all"] {
  background: linear-gradient(180deg, #e5e4bf, #f5f4d9);
}

.builder-day-cell {
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 176px;
}

.manager-day-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.78rem;
}

.manager-day-head strong {
  color: var(--ink);
  font-size: 1rem;
}

.manager-response-stack {
  display: grid;
  grid-auto-rows: minmax(var(--manager-moment-row-min-height), max-content);
  gap: 8px;
  align-content: start;
}

.manager-moment-stack {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.manager-response-row {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: var(--manager-moment-row-min-height);
  padding: 8px 10px;
  border: 1px solid rgba(216, 229, 234, 0.9);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
}

.manager-response-row-morning {
  border-color: rgba(229, 189, 93, 0.38);
  background: linear-gradient(180deg, rgba(255, 245, 208, 0.98), rgba(255, 250, 234, 0.98));
}

.manager-response-row-afternoon {
  border-color: rgba(219, 141, 42, 0.34);
  background: linear-gradient(180deg, rgba(255, 232, 198, 0.98), rgba(255, 243, 223, 0.98));
}

.manager-response-row-night {
  border-color: rgba(110, 144, 212, 0.34);
  background: linear-gradient(180deg, rgba(228, 238, 255, 0.98), rgba(241, 246, 255, 0.98));
}

.manager-response-row span {
  color: var(--ink-soft);
  font-size: 0.72rem;
}

.manager-response-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-soft);
  font-size: 0.76rem;
  font-weight: 700;
}

.manager-response-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.manager-response-mode-stack {
  display: grid;
  gap: 6px;
}

.manager-initial-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  min-width: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--blue);
  font-size: 0.72rem;
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(25, 49, 61, 0.05);
}

.manager-initial-pill-available {
  background: var(--green-soft);
  color: #1c7f4d;
}

.manager-initial-pill-avoid {
  background: var(--amber-soft);
  color: #9b6b00;
}

.manager-initial-pill-not-available {
  background: var(--rose-soft);
  color: #9d4154;
}

.manager-initial-pill-neutral,
.manager-initial-pill-overflow {
  background: rgba(45, 115, 185, 0.1);
  color: var(--blue);
}

.manager-status-swatch {
  display: inline-flex;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(25, 49, 61, 0.12);
}

.schedule-preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.builder-calendar-grid .weekday {
  padding-bottom: 4px;
  color: var(--ink-soft);
  text-align: center;
  font-size: 0.78rem;
  font-weight: 700;
}

.builder-cycle-button {
  display: grid;
  align-content: center;
  justify-items: center;
  width: 100%;
  min-height: 112px;
  padding: 16px 12px;
  border: 0;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.4);
  color: var(--ink-soft);
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(117, 132, 143, 0.16);
  transition: background-color 140ms ease, color 140ms ease, transform 140ms ease, box-shadow 140ms ease;
  cursor: pointer;
}

.builder-cycle-button .moment-icon-shell {
  justify-self: center;
  align-self: center;
}

.builder-cycle-button.active {
  background: rgba(255, 255, 255, 0.56);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(117, 132, 143, 0.22);
}

.builder-cycle-button:hover,
.builder-cycle-button:focus-visible {
  background: rgba(255, 255, 255, 0.68);
  color: var(--ink);
  outline: none;
  transform: translateY(-1px);
  box-shadow: inset 0 0 0 1px rgba(84, 98, 110, 0.26);
}

.builder-cycle-button:disabled {
  cursor: default;
  opacity: 0.82;
  transform: none;
}

.builder-cycle-label {
  color: var(--ink);
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1.2;
}

.builder-cycle-placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 800;
}

.moment-icon-svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.moment-icon-shell {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: transparent;
  transition: background-color 140ms ease, box-shadow 140ms ease;
}

.moment-icon-shell-builder {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.4);
  box-shadow: inset 0 0 0 1px rgba(117, 132, 143, 0.14);
}

.builder-cycle-button .moment-icon-shell-builder .moment-icon-svg {
  width: 30px;
  height: 30px;
}

.moment-icon-morning {
  color: #b97900;
}

.moment-icon-afternoon {
  color: #c76b00;
}

.moment-icon-night {
  color: #365ea8;
}

.moment-icon-shell-legend {
  box-shadow: inset 0 0 0 1px rgba(117, 132, 143, 0.12);
}

.moment-icon-shell-legend.moment-icon-morning {
  background: rgba(255, 226, 144, 0.42);
}

.moment-icon-shell-legend.moment-icon-afternoon {
  background: rgba(255, 190, 96, 0.34);
}

.moment-icon-shell-legend.moment-icon-night {
  background: rgba(154, 184, 244, 0.34);
}

.moment-icon-shell-response {
  background: transparent;
  box-shadow: none;
}

.builder-cycle-button.active .moment-icon-shell {
  background: rgba(84, 98, 110, 0.14);
  box-shadow: inset 0 0 0 2px rgba(84, 98, 110, 0.4);
}

.builder-cycle-button.active .moment-icon-svg {
  stroke-width: 2.2;
}

.manager-response-slot .moment-icon-svg {
  width: 18px;
  height: 18px;
}

.manager-response-slot .moment-icon-shell {
  width: 28px;
  height: 28px;
}

.survey-moment-legend .moment-icon-shell {
  width: 30px;
  height: 30px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.survey-respondent-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.survey-respondent-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
}

.survey-respondent-top {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.status-pill-muted {
  background: #f4f7f8;
  color: var(--ink-soft);
}

@media (max-width: 920px) {
  .manager-calendar-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .manager-calendar-grid {
    grid-template-columns: 1fr;
  }

  .manager-day-spacer {
    display: none;
  }

  .schedule-preview-toolbar {
    flex-wrap: wrap;
  }
}
