:root {
  color-scheme: light;
  --bg: #f4f7f6;
  --panel: #fff;
  --ink: #17211e;
  --muted: #64726d;
  --line: #d9e2dd;
  --accent: #0d6b5f;
  font-family: "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  scroll-behavior: smooth;
}

.install {
  max-width: 560px;
  margin: 40px auto;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

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

aside {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
  padding: 24px;
  border-right: 1px solid var(--line);
  background: var(--panel);
}

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

form,
nav {
  display: grid;
  gap: 12px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 11px 12px;
  font: inherit;
  background: #fff;
}

textarea {
  resize: vertical;
  line-height: 1.6;
}

button {
  min-height: 44px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.account-box {
  display: grid;
  gap: 6px;
  margin: 0 0 16px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
}

.account-box span,
.account-box a {
  color: var(--muted);
  font-size: 13px;
}

.account-box a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
}

.project-nav a {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  text-decoration: none;
}

.project-nav a.active,
.project-nav a:hover {
  border-color: var(--accent);
  background: #e8f0ec;
}

.project-nav span,
.project-nav small,
.empty,
.report header p {
  color: var(--muted);
  font-size: 13px;
}

.project-nav small {
  display: block;
  line-height: 1.35;
}

.report {
  display: grid;
  gap: 18px;
  padding: 32px;
}

.report-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 20px;
  align-items: end;
  margin: -32px -32px 0;
  padding: 24px 32px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(244, 247, 246, 0.96);
  backdrop-filter: blur(10px);
}

.date-picker {
  display: block;
}

.report-card {
  scroll-margin-top: 120px;
}

.report-card h3 {
  margin-bottom: 10px;
  font-size: 18px;
}

.report-meta,
.dev-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.report-meta span,
.dev-summary span,
.dev-summary strong {
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fbfa;
  color: var(--muted);
  font-size: 12px;
}

.dev-summary strong {
  color: var(--ink);
}

.meeting-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.meeting-list section {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fbfdfc;
}

.meeting-list pre {
  margin-top: 8px;
  padding: 10px;
  font-size: 13px;
}

pre,
.placeholder {
  margin: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  white-space: pre-wrap;
  line-height: 1.7;
}

#overall pre {
  min-height: 220px;
}

.notice {
  margin-bottom: 18px;
  padding: 12px;
  border-radius: 6px;
}

.success {
  background: #e8f0ec;
}

.error {
  background: #fff1f1;
  color: #9b1c1c;
}

.admin-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.admin-topbar p {
  margin-bottom: 5px;
  color: var(--muted);
}

.top-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.top-links a {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: var(--panel);
  text-decoration: none;
  font-weight: 700;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: var(--panel);
  text-decoration: none;
  font-weight: 800;
}

.button-link.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.button-link:hover {
  border-color: var(--accent);
  background: #e8f0ec;
}

.button-link.primary:hover {
  background: #0a5a50;
  color: #fff;
}

.admin-tabs {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
}

.admin-tabs a {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 14px;
}

.admin-tabs a.active,
.admin-tabs a:hover {
  border-color: var(--accent);
  background: #e8f0ec;
}

.sub-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 4px;
}

.sub-tabs a {
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: var(--panel);
  text-decoration: none;
  font-weight: 800;
}

.sub-tabs a.active,
.sub-tabs a:hover {
  border-color: var(--accent);
  background: #e8f0ec;
}

.project-picker {
  display: grid;
  grid-template-columns: minmax(220px, 0.7fr) minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.project-workspace {
  gap: 16px;
}

.project-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.project-hero h2 {
  margin-bottom: 8px;
  font-size: 28px;
}

.project-hero p {
  max-width: 720px;
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.55;
}

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

.project-status-tabs {
  display: inline-flex;
  width: fit-content;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #edf3f0;
}

.project-status-tabs a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 112px;
  justify-content: center;
  border-color: transparent;
  background: transparent;
}

.project-status-tabs a.active {
  background: var(--panel);
  box-shadow: 0 1px 4px rgba(23, 33, 30, 0.08);
}

.project-status-tabs strong {
  min-width: 26px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #dbe7e2;
  color: var(--accent);
  font-size: 12px;
  text-align: center;
}

.project-status-tabs a.active strong {
  background: var(--accent);
  color: #fff;
}

.project-picker-card,
.project-edit-card {
  display: grid;
  gap: 18px;
}

.card-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.card-title-row h3 {
  margin-bottom: 5px;
  font-size: 18px;
}

.card-title-row p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.count-badge,
.status-badge {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  background: #edf3f0;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.status-badge.ended {
  background: #f1f3f2;
  color: var(--muted);
}

.project-badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.role-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fbfa;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.role-badge.lead {
  border-color: rgba(13, 107, 95, 0.25);
  background: #e8f0ec;
  color: var(--accent);
}

.role-badge.sub {
  background: #f4f7f6;
}

.project-edit-form {
  display: grid;
  gap: 14px;
}

.form-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 4px;
}

.form-footer button {
  min-width: 180px;
}

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

.admin-section {
  display: grid;
  gap: 14px;
  margin-bottom: 24px;
  scroll-margin-top: 90px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.section-head h2,
.section-head p {
  margin-bottom: 0;
}

.section-head p {
  max-width: 720px;
  color: var(--muted);
  font-size: 14px;
}

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

.admin-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.admin-card.wide {
  grid-column: span 1;
}

.git-progress {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #d8e4df;
  border-radius: 8px;
  background: #f8fbfa;
}

.git-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  color: #123d34;
  font-size: 14px;
}

.git-progress-head span {
  font-weight: 800;
  color: #0f7668;
}

.git-progress-track {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e6efec;
}

.git-progress-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0f7668, #22c55e);
  transition: width 0.45s ease;
}

.git-progress-bar.is-error {
  background: linear-gradient(90deg, #b91c1c, #ef4444);
}

.manual-projects {
  display: grid;
  gap: 12px;
}

.project-editor-grid,
.report-project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.project-card,
.report-project-card,
.review-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdfc;
}

.review-card {
  margin-top: 14px;
}

.review-filter {
  display: grid;
  grid-template-columns: minmax(180px, 240px) minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.review-card-head {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 12px;
  align-items: end;
}

.review-card-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.review-card-toolbar span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.publish-switch-form {
  margin: 0;
}

.switch-label {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.switch-label input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.switch-label i {
  position: relative;
  width: 54px;
  height: 30px;
  border-radius: 999px;
  background: #ccd7d2;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: background 0.18s ease;
}

.switch-label i::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.22);
  transition: transform 0.18s ease;
}

.switch-label input:checked + i {
  background: var(--accent);
}

.switch-label input:checked + i::after {
  transform: translateX(24px);
}

.review-card-head span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.check-row input {
  width: auto;
}

.checkbox-group {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.checkbox-group legend {
  padding: 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

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

.ranking-filter {
  display: grid;
  grid-template-columns: 220px auto;
  align-items: end;
  gap: 10px;
  max-width: 420px;
  margin-bottom: 14px;
}

.manual-row {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th,
td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

td span {
  color: var(--muted);
  font-size: 12px;
}

td a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

code {
  display: inline-block;
  max-width: 100%;
  overflow-wrap: anywhere;
  color: #243b53;
  font-family: Consolas, "Courier New", monospace;
  font-size: 12px;
}

.inline-form {
  display: inline;
}

.danger {
  min-height: 34px;
  padding: 0 10px;
  background: #9b1c1c;
}

.customer-brief {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px;
}

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

.customer-topbar p {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 14px;
}

.customer-topbar h1 {
  margin-bottom: 0;
  font-size: 28px;
}

.customer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.customer-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
}

.customer-links a.active,
.customer-links a:hover {
  border-color: var(--accent);
  background: #e8f0ec;
  color: var(--accent);
}

.brief-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 20px;
  align-items: end;
  padding: 28px;
  border-radius: 8px;
  background: #102923;
  color: #fff;
}

.brief-hero-main p {
  margin-bottom: 8px;
  color: #bfd2cc;
}

.business-day-label {
  color: #8fb0a7 !important;
  font-size: 13px !important;
  font-weight: 800;
}

.brief-hero h2 {
  max-width: 820px;
  margin-bottom: 16px;
  font-size: 30px;
  line-height: 1.25;
}

.brief-chip-row,
.brief-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.brief-chip-row span,
.brief-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.today-projects {
  display: grid;
  gap: 10px;
  max-width: 760px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.today-projects strong {
  color: #bfd2cc;
  font-size: 12px;
  letter-spacing: 0;
}

.today-projects div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.today-projects a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.today-projects a:hover {
  background: #fff;
  color: #102923;
}

.today-projects p {
  margin: 0;
  color: #bfd2cc;
  font-size: 13px;
}

.brief-date-picker {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.brief-date-picker label {
  color: #d9e7e2;
}

.brief-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 18px 0;
}

.brief-summary-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.brief-summary-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.brief-summary-card strong {
  font-size: 30px;
}

.brief-overall,
.brief-project-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.brief-overall {
  margin-bottom: 18px;
}

.brief-section-head,
.brief-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.brief-section-head p,
.brief-card-head p {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.brief-section-head h2,
.brief-card-head h3 {
  margin-bottom: 0;
}

.brief-overall pre,
.brief-project-card pre {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #23302c;
  font-size: 14px;
  line-height: 1.75;
  white-space: pre-wrap;
}

.brief-projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.brief-project-card {
  display: grid;
  gap: 12px;
  align-content: start;
}

.idle-projects {
  margin-bottom: 18px;
}

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

.idle-project-list span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid #d7e2de;
  border-radius: 999px;
  background: #f7faf9;
  color: #40524c;
  font-size: 13px;
  font-weight: 800;
}

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

.project-title-row h3 {
  margin-bottom: 0;
}

.project-date-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 5px;
}

.project-date-row p {
  margin-bottom: 0;
}

.project-date-row span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border: 1px solid #d6e3de;
  border-radius: 999px;
  background: #f3f8f6;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.brief-score {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 58px;
  height: 58px;
  border: 6px solid #dbe7e2;
  border-radius: 50%;
  color: var(--accent);
  font-size: 18px;
  font-weight: 900;
}

.brief-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fbfa;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.brief-overall .brief-pill {
  border-color: var(--line);
  background: #e8f0ec;
  color: var(--accent);
}

.brief-calendar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.brief-calendar-head a {
  color: #d9e7e2;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

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

.brief-calendar a,
.brief-calendar span {
  display: grid;
  place-items: center;
  min-height: 30px;
  border-radius: 6px;
  color: #d9e7e2;
  font-size: 12px;
  text-decoration: none;
}

.brief-calendar .weekday {
  min-height: 22px;
  color: #8fb0a7;
  font-weight: 900;
}

.brief-calendar .has-report {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-weight: 900;
}

.brief-calendar .selected {
  background: #fff;
  color: #102923;
}

.brief-detail-link {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.brief-meetings,
.project-history {
  display: grid;
  gap: 14px;
}

.brief-meetings article,
.project-history article {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbfa;
}

.brief-meetings article > span {
  display: block;
  margin: 6px 0 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

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

.project-side {
  position: sticky;
  top: 20px;
  height: max-content;
  max-height: calc(100vh - 40px);
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.project-side nav {
  margin-top: 12px;
}

.project-side a {
  display: grid;
  gap: 4px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  text-decoration: none;
}

.project-side a.active,
.project-side a:hover {
  border-color: var(--accent);
  background: #e8f0ec;
}

.project-side small {
  color: var(--muted);
}

.project-side .latest-work {
  color: #6e7b76;
  font-size: 12px;
}

.work-type-card,
.project-side .work-type-card {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  box-shadow: 0 1px 0 rgba(7, 17, 14, 0.06);
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
}

.work-type-card.work-type-development,
.project-side .work-type-card.work-type-development,
.brief-chip-row .work-type-card.work-type-development {
  border-color: #7cc8aa;
  background: #dff6eb;
  color: #064934;
}

.work-type-card.work-type-project,
.project-side .work-type-card.work-type-project,
.brief-chip-row .work-type-card.work-type-project {
  border-color: #9eb8ec;
  background: #e3ecff;
  color: #173b78;
}

.project-side .latest-work.has-today-work {
  color: #07110e;
  font-weight: 900;
}

.project-main {
  min-width: 0;
}

.admin-timeline {
  --bg: #f6f9f8;
  --panel: #fff;
  --ink: #1c2925;
  --muted: #6a7872;
  --line: #dce6e2;
  --accent: #1a4d42;
  background: linear-gradient(180deg, #f6f9f8 0%, #fff 68%);
}

.admin-timeline .admin-shell {
  max-width: 1320px;
  padding: 36px;
}

.admin-timeline .admin-topbar {
  align-items: flex-end;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.admin-timeline .admin-topbar p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.admin-timeline .admin-topbar h1 {
  margin-bottom: 0;
  color: var(--ink);
  font-size: 42px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.admin-timeline .top-links a,
.admin-timeline .button-link {
  border-color: var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--accent);
  font-weight: 900;
}

.admin-timeline .button-link.primary,
.admin-timeline button {
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
}

.admin-timeline .admin-tabs {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  gap: 8px;
  margin: 18px 0 26px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 30px -24px rgba(26, 77, 66, 0.35);
}

.admin-timeline .admin-tabs a {
  border-color: transparent;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 900;
}

.admin-timeline .admin-tabs a.active,
.admin-timeline .admin-tabs a:hover {
  border-color: var(--accent);
  background: #eaf3f0;
  color: var(--accent);
}

.admin-timeline .admin-section {
  position: relative;
  gap: 18px;
  padding-left: 38px;
}

.admin-timeline .admin-section::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 12px;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, var(--accent), #6ee7d6, var(--line));
}

.admin-timeline .section-head,
.admin-timeline .project-hero,
.admin-timeline .admin-card {
  position: relative;
  border-color: var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 10px 30px -22px rgba(26, 77, 66, 0.28);
}

.admin-timeline .section-head::before,
.admin-timeline .project-hero::before,
.admin-timeline .admin-card::before {
  content: "";
  position: absolute;
  left: -37px;
  top: 26px;
  width: 16px;
  height: 16px;
  border: 3px solid var(--accent);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(26, 77, 66, 0.08);
}

.admin-timeline .section-head {
  align-items: flex-start;
  padding: 22px 24px;
  border: 1px solid var(--line);
}

.admin-timeline .section-head h2,
.admin-timeline .project-hero h2 {
  color: var(--ink);
  font-weight: 900;
}

.admin-timeline .section-head p,
.admin-timeline .project-hero p,
.admin-timeline .card-title-row p {
  color: var(--muted);
  font-weight: 600;
}

.admin-timeline .admin-card {
  padding: 22px;
}

.admin-timeline .sub-tabs,
.admin-timeline .project-status-tabs {
  width: fit-content;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
}

.admin-timeline .sub-tabs a {
  border-color: transparent;
  border-radius: 999px;
  background: transparent;
}

.admin-timeline .sub-tabs a.active,
.admin-timeline .sub-tabs a:hover {
  background: #eaf3f0;
  color: var(--accent);
}

.admin-timeline input,
.admin-timeline select,
.admin-timeline textarea {
  border-color: var(--line);
  border-radius: 12px;
}

.admin-timeline table {
  border: 1px solid var(--line);
  border-radius: 14px;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}

.admin-timeline th {
  background: #f6f9f8;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.admin-timeline td {
  background: #fff;
}

.admin-timeline .notice {
  border: 1px solid var(--line);
  border-radius: 14px;
  font-weight: 800;
}

@media (max-width: 820px) {
  html {
    overflow-x: hidden;
  }

  body {
    min-width: 0;
  }

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

  aside {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .report-header {
    position: static;
    grid-template-columns: 1fr;
    margin: -32px -32px 0;
    padding: 18px;
  }

  .admin-shell {
    padding: 16px;
  }

  .admin-timeline .admin-shell {
    padding: 14px;
  }

  .admin-timeline .admin-topbar h1 {
    font-size: 30px;
  }

  .admin-timeline .admin-section {
    padding-left: 0;
  }

  .admin-timeline .admin-section::before,
  .admin-timeline .section-head::before,
  .admin-timeline .project-hero::before,
  .admin-timeline .admin-card::before {
    display: none;
  }

  .admin-timeline .admin-tabs {
    position: static;
    overflow-x: auto;
    margin: 14px 0 18px;
    padding: 8px;
    border-radius: 12px;
    scroll-snap-type: x proximity;
  }

  .admin-timeline .admin-tabs a {
    flex: 0 0 auto;
    min-width: max-content;
    scroll-snap-align: start;
  }

  .admin-timeline .section-head,
  .admin-timeline .project-hero,
  .admin-timeline .admin-card {
    border-radius: 10px;
    padding: 16px;
  }

  .admin-topbar {
    display: grid;
    gap: 12px;
  }

  .top-links,
  .customer-links {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .top-links a,
  .customer-links a {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 8px 11px;
  }

  .customer-brief {
    padding: 12px;
  }

  .customer-topbar,
  .brief-hero,
  .brief-section-head,
  .brief-card-head {
    display: grid;
  }

  .customer-topbar {
    align-items: start;
    gap: 12px;
  }

  .customer-topbar h1 {
    font-size: 24px;
    line-height: 1.2;
  }

  .brief-hero {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 18px;
  }

  .brief-hero h2 {
    font-size: 26px;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }

  .brief-date-picker {
    width: 100%;
    min-width: 0;
  }

  .brief-summary-card {
    padding: 16px;
  }

  .brief-summary-card strong {
    font-size: 28px;
    line-height: 1.15;
    overflow-wrap: anywhere;
  }

  .brief-summary-grid {
    grid-template-columns: 1fr;
  }

  .brief-projects {
    grid-template-columns: 1fr;
  }

  .brief-overall,
  .brief-project-card {
    padding: 16px;
  }

  .brief-meta,
  .brief-chip-row,
  .today-projects div {
    gap: 6px;
  }

  .brief-calendar a,
  .brief-calendar span {
    min-height: 34px;
  }

  .project-layout {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .project-side {
    position: static;
    max-height: none;
    padding: 14px;
    overflow: hidden;
  }

  .project-side nav {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    margin-top: 10px;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
  }

  .project-side a {
    flex: 0 0 220px;
    scroll-snap-align: start;
  }

  .section-head {
    display: grid;
  }

  .project-hero,
  .card-title-row,
  .form-footer {
    display: grid;
  }

  .project-status-tabs {
    width: 100%;
    overflow-x: auto;
  }

  .project-status-tabs a {
    flex: 1;
    min-width: max-content;
  }

  .admin-grid,
  .manual-row,
  .project-picker,
  .developer-assignment-grid,
  .ranking-filter,
  .review-filter,
  .review-card-head {
    grid-template-columns: 1fr;
  }

  table {
    display: block;
    width: 100%;
    overflow-x: auto;
    white-space: nowrap;
  }
}

@media (max-width: 520px) {
  .install {
    margin: 12px;
    padding: 18px;
  }

  .customer-brief,
  .admin-shell,
  .admin-timeline .admin-shell {
    padding: 10px;
  }

  .customer-topbar h1,
  .admin-topbar h1,
  .admin-timeline .admin-topbar h1 {
    font-size: 24px;
  }

  .brief-hero {
    padding: 16px;
  }

  .brief-hero h2 {
    font-size: 24px;
  }

  .brief-summary-card strong {
    font-size: 24px;
  }

  .brief-calendar {
    gap: 3px;
  }

  .brief-calendar a,
  .brief-calendar span {
    min-height: 30px;
    font-size: 11px;
  }

  .project-side a {
    flex-basis: 190px;
  }

  .work-type-card,
  .project-side .work-type-card,
  .brief-chip-row span,
  .brief-pill,
  .brief-meta span {
    max-width: 100%;
    white-space: normal;
  }

  input,
  select,
  textarea,
  button {
    font-size: 16px;
  }
}
