:root {
  --bg: #f4f1ea;
  --ink: #191919;
  --muted: #635f57;
  --panel: #fff;
  --line: #ded8cc;
  --yellow: #f7d117;
  --dark: #071726;
  --green: #2c8b57;
  --red: #b7352d;
  --blue: #255f8f;
  --shadow: 0 14px 38px rgba(34, 27, 14, .10);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
}

.hero {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-end;
  padding: 34px 42px;
  color: #fff;
  background:
    linear-gradient(120deg, #071726, #12344d 64%, #2e3f32);
}

.stage-hero {
  background:
    linear-gradient(120deg, #071726, #12344d 64%, #2e3f32);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--yellow);
  text-transform: uppercase;
  font-weight: 800;
  font-size: 13px;
}

h1 {
  margin: 0 0 10px;
  font-size: 38px;
}

h2 {
  margin-top: 0;
}

.lead {
  max-width: 860px;
  margin: 0;
  color: #e6edf3;
  font-size: 18px;
}

nav {
  display: flex;
  gap: 10px;
}

nav a,
.controls button {
  border: 1px solid rgba(255,255,255,.38);
  border-radius: 6px;
  padding: 10px 13px;
  color: inherit;
  text-decoration: none;
  font-weight: 700;
  background: rgba(255,255,255,.09);
}

main {
  padding: 24px 42px 42px;
}

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

.summary article,
.table-section,
.notes {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.summary article {
  padding: 16px;
  display: grid;
  gap: 6px;
}

.summary strong {
  color: #8b6a00;
  font-size: 18px;
}

.controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
}

.controls button {
  cursor: pointer;
  color: var(--ink);
  border-color: var(--line);
  background: #fff;
}

.controls button.active {
  background: var(--dark);
  color: #fff;
}

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

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.photo {
  height: clamp(300px, 21vw, 380px);
  background: #071726;
  position: relative;
  overflow: hidden;
}

.photo::before {
  content: "";
  position: absolute;
  inset: -18px;
  background-image:
    linear-gradient(rgba(7,23,38,.32), rgba(7,23,38,.32)),
    var(--photo-url);
  background-position: center;
  background-size: cover;
  filter: blur(16px) saturate(.95);
  transform: scale(1.08);
}

.photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7,23,38,.18), rgba(7,23,38,.48));
}

.photo img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 12px 24px rgba(0,0,0,.26));
}

.badge {
  position: absolute;
  z-index: 2;
  left: 12px;
  bottom: 12px;
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--yellow);
  color: #111;
  font-size: 12px;
  font-weight: 800;
}

.card-body {
  padding: 14px;
}

.card h3 {
  margin: 0 0 4px;
  font-size: 20px;
}

.team {
  margin: 0 0 10px;
  color: var(--muted);
  font-weight: 700;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.tag {
  padding: 4px 7px;
  border-radius: 999px;
  background: #eef1f3;
  font-size: 12px;
  font-weight: 700;
}

.tag.gc { background: #fff1b8; color: #6d5100; }
.tag.sprint { background: #dff2e8; color: var(--green); }
.tag.stage { background: #e1edf8; color: var(--blue); }
.tag.risk { background: #f8dfdc; color: var(--red); }

.card p {
  margin: 0 0 10px;
}

.small {
  color: var(--muted);
  font-size: 13px;
}

.social {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.social strong {
  margin-right: 2px;
}

.social a {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--dark);
  background: #fff;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.social a:hover {
  border-color: var(--yellow);
  background: #fff7c9;
}

.table-section,
.notes {
  margin-top: 22px;
  padding: 18px;
}

.guide ul {
  margin: 0;
  padding-left: 22px;
}

.guide li {
  margin: 0 0 10px;
}

.guide-summary {
  margin-top: 18px;
}

.table-wrap {
  overflow-x: auto;
}

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

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

th {
  background: #f8f5ef;
  font-size: 13px;
}

code {
  background: #eee7da;
  padding: 2px 5px;
  border-radius: 4px;
}

@media (max-width: 1200px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .photo { height: 330px; }
}

@media (max-width: 820px) {
  .hero,
  main {
    padding-left: 18px;
    padding-right: 18px;
  }

  .hero,
  .summary {
    display: block;
  }

  nav,
  .summary article {
    margin-top: 12px;
  }

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

  .photo {
    height: 340px;
  }
}
