:root {
  --site-bg: #f6f1e8;
  --ink: #2a2926;
  --muted-ink: #5f6f63;
  --line-ink: rgba(95,111,99,0.38);
  --line-active: rgba(95,111,99,0.82);
}

html, body {
  background-color: var(--site-bg);
  color: var(--ink);
}

.muted {
  color: var(--muted-ink);
}


:root {
  --site-bg: #f6f1e8;
}

html, body {
  margin: 0;
  padding: 0;
  background-color: var(--site-bg);
  color: #2a2926;
  font-family: Georgia, serif;
}

.muted {
  color: #5f6f63;
}

.top-bar {
  display: flex;
  justify-content: space-between;
  padding: 12px 24px;
  border-bottom: 1px solid rgba(0,0,0,0.1);
}

.title-block {
  text-align: center;
  padding: 40px 20px;
}

.layout {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  gap: 20px;
  padding: 20px;
}

.panel {
  background: rgba(0,0,0,0.025);
  border: 1px solid rgba(0,0,0,0.06);
  padding: 15px;
}

.system-panel {
  text-align: center;
}


/* Local Trophic — Chestnut Creek working system */
.system-panel {
  text-align: center;
  min-height: 580px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: visible;
}

.trophic-map {
  position: relative;
  width: min(720px, 100%);
  height: 560px;
  margin: 0 auto;
}

.trophic-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

.trophic-line {
  fill: none;
  stroke: var(--line-ink);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 7 8;
  opacity: 0.26;
  transition: opacity 260ms ease, stroke 260ms ease, stroke-width 260ms ease;
}

.trophic-line.visible {
  opacity: 0.75;
}

.trophic-line.active {
  stroke: var(--line-active);
  stroke-width: 1.9;
  opacity: 1;
}

.trophic-node {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 250px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  opacity: 0.58;
  transition: opacity 220ms ease, transform 220ms ease;
}

.trophic-node:hover,
.trophic-node:focus-visible,
.trophic-node.revealed {
  opacity: 1;
}

.trophic-node.active {
  transform: translateY(-2px);
}

.trophic-node:focus-visible {
  outline: 1px solid rgba(95,111,99,0.6);
  outline-offset: 6px;
  border-radius: 999px;
}

.node-orb {
  width: 88px;
  height: 88px;
  flex: 0 0 88px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.55), rgba(255,255,255,0.05) 34%, rgba(95,111,99,0.16) 72%),
    rgba(0,0,0,0.025);
  border: 1px solid rgba(95,111,99,0.34);
  box-shadow: 0 10px 22px rgba(42,41,38,0.06);
  color: var(--muted-ink);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.node-copy strong {
  display: block;
  margin-bottom: 4px;
  font-size: 0.82rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.node-copy small {
  display: block;
  max-width: 180px;
  color: var(--muted-ink);
  font-size: 0.86rem;
  line-height: 1.35;
}

.node-stone {
  top: 18px;
  left: 300px;
  width: 310px;
}

.node-algae {
  top: 144px;
  left: 300px;
  width: 300px;
}

.node-insects {
  top: 284px;
  left: 300px;
  width: 310px;
}

.node-fish {
  top: 384px;
  left: 52px;
  flex-direction: row-reverse;
  text-align: right;
}

.node-fish .node-copy small {
  margin-left: auto;
}

.node-crayfish {
  top: 384px;
  left: 468px;
}

.node-kingfisher {
  top: 478px;
  left: 300px;
  width: 320px;
}

.system-caption {
  margin-top: 22px;
  color: var(--muted-ink);
  letter-spacing: 0.04em;
}

/* Optional helper states for a quiet reveal */
.trophic-map.has-selection .trophic-node {
  opacity: 0.34;
}

.trophic-map.has-selection .trophic-node.active {
  opacity: 1;
}

.trophic-map.has-selection .trophic-node:hover,
.trophic-map.has-selection .trophic-node:focus-visible {
  opacity: 1;
}

@media (max-width: 980px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .system-panel {
    min-height: auto;
  }

  .trophic-map {
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 8px 0;
  }

  .trophic-lines {
    display: none;
  }

  .trophic-node {
    position: relative;
    inset: auto;
    width: 100%;
    max-width: 520px;
    margin: 0 auto;
    flex-direction: row;
    text-align: left;
    opacity: 1;
  }

  .node-fish {
    flex-direction: row;
    text-align: left;
  }

  .node-fish .node-copy small {
    margin-left: 0;
  }

  .node-orb {
    width: 72px;
    height: 72px;
    flex-basis: 72px;
  }

  .node-copy small {
    max-width: none;
  }
}


/* Page-ready refinements */
.label {
  color: var(--muted-ink);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.76rem;
  margin-bottom: 8px;
}

.title-block h1 {
  margin: 0;
  font-size: clamp(2.2rem, 6vw, 4.8rem);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.subline,
.instruction {
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}

.instruction {
  margin-top: 10px;
  font-size: 0.96rem;
}

.place-tag {
  margin-top: 18px;
  color: var(--muted-ink);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.quiet-list {
  padding-left: 1.1rem;
  color: var(--muted-ink);
}

.quiet-list li {
  margin: 0.45rem 0;
}

.right-panel h4,
.left-panel h3 {
  margin-top: 0;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.82rem;
}

.panel {
  border-radius: 18px;
}

.trophic-map::before {
  content: "";
  position: absolute;
  inset: 44px 86px;
  border: 1px solid rgba(95,111,99,0.14);
  border-radius: 50%;
  pointer-events: none;
}

.trophic-map::after {
  content: "Click stone to begin, then follow the revealed path.";
  position: absolute;
  left: 28%;
  top: 50%;
  width: 180px;
  transform: translate(-50%, -50%);
  color: rgba(95,111,99,0.72);
  font-size: 0.82rem;
  line-height: 1.35;
  text-align: center;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.trophic-map.has-selection::after {
  opacity: 0;
}

.node-orb {
  font-family: Georgia, serif;
}

.trophic-node.active .node-orb {
  box-shadow: 0 12px 26px rgba(42,41,38,0.09);
  border-color: rgba(95,111,99,0.62);
}

.trophic-node.revealed .node-orb {
  background:
    radial-gradient(circle at 35% 30%, rgba(255,255,255,0.72), rgba(255,255,255,0.08) 34%, rgba(95,111,99,0.22) 72%),
    rgba(0,0,0,0.02);
}

@media (max-width: 980px) {
  .trophic-map::before,
  .trophic-map::after {
    display: none;
  }

  .top-bar {
    gap: 10px;
    flex-wrap: wrap;
    font-size: 0.82rem;
  }

  .title-block {
    padding: 30px 18px 20px;
  }
}


/* Navigation and selection-note refinements */
.top-bar a {
  color: inherit;
  text-decoration: none;
}

.brand-link,
.site-section,
.site-nav a {
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: 0.08em;
}

.site-section {
  font-size: 0.95rem;
}

.brand-link,
.site-nav a {
  color: #1b3a2f;
  font-size: 0.95rem;
}

.brand-link {
  font-weight: 700;
}

.site-nav {
  display: flex;
  gap: 28px;
  align-items: center;
}

.site-nav a {
  color: #1b3a2f;
  transition: color 180ms ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: #1b3a2f;
}

.selection-note {
  max-width: 420px;
  margin: 10px auto 0;
  font-size: 0.88rem;
  line-height: 1.45;
}

@media (max-width: 680px) {
  .top-bar {
    align-items: center;
  }

  .site-nav {
    gap: 16px;
  }
}


/* Trophic medallion images */
.node-orb {
  overflow: hidden;
  position: relative;
  background: rgba(0,0,0,0.025);
}

.node-orb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter:
    contrast(1.04)
    brightness(1.01)
    saturate(0.92);
}

.node-orb::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(
    circle at center,
    rgba(0,0,0,0.01) 42%,
    rgba(0,0,0,0.10) 100%
  );
  pointer-events: none;
}

.node-algae .node-orb img {
  filter:
    saturate(0.86)
    contrast(0.96)
    brightness(0.98);
}

.node-crayfish .node-orb img,
.node-kingfisher .node-orb img {
  filter:
    saturate(0.84)
    contrast(0.96)
    brightness(0.98);
}


/* Inline field-guide preview */
.inline-preview {
  margin: 28px 0 0;
  padding: 0;
}

.inline-preview img {
  display: block;
  width: min(260px, 100%);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
  border: 1px solid rgba(95,111,99,0.32);
  box-shadow: 0 12px 28px rgba(42,41,38,0.10);
  filter:
    contrast(1.03)
    brightness(1.01)
    saturate(0.92);
}

.inline-preview figcaption {
  margin-top: 14px;
  max-width: 280px;
  line-height: 1.45;
}

.inline-preview strong {
  display: block;
  margin-bottom: 5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.inline-preview span {
  display: block;
  color: var(--muted-ink);
  font-size: 0.88rem;
}

@media (max-width: 980px) {
  .inline-preview {
    display: none;
  }
}


/* Refined page title hierarchy */
.header-block,
.title-block {
  text-align: center;
  padding: 50px 20px 34px;
  margin-bottom: 12px;
}

.section-label {
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted-ink);
  margin-bottom: 12px;
  opacity: 0.82;
}

.main-title {
  margin: 0 0 18px;
  font-size: clamp(3.8rem, 8vw, 6.8rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  font-weight: 500;
  color: #1b3a2f;
}

.subtitle-primary {
  max-width: 680px;
  margin: 0 auto 10px;
  font-size: 1.06rem;
  line-height: 1.45;
  color: #1b3a2f;
  opacity: 0.86;
}

.subtitle-secondary {
  max-width: 680px;
  margin: 0 auto;
  font-size: 0.96rem;
  line-height: 1.45;
  color: var(--muted-ink);
  opacity: 0.84;
}

@media (max-width: 680px) {
  .header-block,
  .title-block {
    padding: 36px 18px 24px;
  }

  .main-title {
    font-size: clamp(3rem, 15vw, 4.6rem);
    letter-spacing: -0.035em;
  }

  .subtitle-primary {
    font-size: 1rem;
  }

  .subtitle-secondary {
    font-size: 0.92rem;
  }
}


/* Compact observation header */
.site-section {
  text-align: center;
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-ink);
  font-weight: 500;
  opacity: 0.88;
}

.system-subtitle {
  max-width: 720px;
  margin: 18px auto 10px;
  padding: 0 20px;
  text-align: center;
  color: var(--muted-ink);
  font-size: 0.95rem;
  line-height: 1.45;
  opacity: 0.86;
}

.layout {
  margin-top: 12px;
}

@media (max-width: 760px) {
  .site-section {
    order: 3;
    flex-basis: 100%;
    margin-top: 8px;
    font-size: 0.68rem;
  }

  .system-subtitle {
    margin-top: 16px;
    font-size: 0.9rem;
  }
}
