:root {
  --up-ink: #28231f;
  --up-muted: #655e56;
  --up-paper: #faf6ed;
  --up-card: rgba(255, 255, 255, .78);
  --up-line: rgba(65, 48, 39, .15);
  --up-rust: #7b4334;
  --up-green: #355f50;
  --up-gold: #ad8447;
}

body.universal-home {
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 10% 9%, rgba(173, 132, 71, .17), transparent 26rem),
    radial-gradient(circle at 88% 14%, rgba(53, 95, 80, .13), transparent 30rem),
    linear-gradient(180deg, #fcf9f2 0%, #f2eadc 54%, #fbf8f1 100%);
  color: var(--up-ink);
}

body.universal-home::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(40, 35, 31, .028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(40, 35, 31, .022) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,.86), transparent 78%);
  content: "";
  pointer-events: none;
}

.universal-home .site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  width: min(1220px, calc(100% - 32px));
  min-height: 78px;
  margin-inline: auto;
  border-bottom: 1px solid var(--up-line);
  background: rgba(250, 246, 237, .91);
  backdrop-filter: blur(15px);
}

.universal-home .brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--up-ink);
  font-weight: 900;
  text-decoration: none;
}

.universal-home .brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(123, 67, 52, .35);
  border-radius: 50%;
  background: rgba(255,255,255,.65);
  color: var(--up-rust);
  font-family: Georgia, "Times New Roman", serif;
}

.universal-home .site-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 14px;
}

.universal-home .site-nav a,
.universal-home .language-nav a {
  color: #514b44;
  font-size: .84rem;
  font-weight: 800;
  text-decoration: none;
}

.universal-home .site-nav a:hover,
.universal-home .language-nav a:hover { color: var(--up-rust); }

.language-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.language-nav .current {
  color: var(--up-rust);
  font-weight: 950;
}

.universal-shell {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}

.universal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, .72fr);
  gap: clamp(30px, 6vw, 78px);
  align-items: center;
  padding: clamp(54px, 8vw, 104px) 0 clamp(46px, 7vw, 84px);
}

.universal-eyebrow {
  display: inline-flex;
  width: fit-content;
  margin: 0 0 14px;
  border: 1px solid rgba(53, 95, 80, .22);
  border-radius: 999px;
  background: rgba(255,255,255,.66);
  color: var(--up-green);
  padding: 7px 12px;
  font-size: .76rem;
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.universal-hero h1,
.universal-section h2,
.universal-closing h2 {
  margin: 0;
  color: #25211e;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -.035em;
}

.universal-hero h1 {
  max-width: 900px;
  font-size: clamp(3.2rem, 7.5vw, 7rem);
  line-height: .93;
}

.universal-lead {
  max-width: 760px;
  margin: 24px 0 0;
  color: #4f514c;
  font-size: clamp(1.08rem, 1.8vw, 1.3rem);
  line-height: 1.7;
}

.universal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
  margin-top: 28px;
}

.universal-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 47px;
  border: 1px solid rgba(40, 35, 31, .82);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--up-ink);
  font-weight: 900;
  text-decoration: none;
  transition: transform .16s ease, background .16s ease;
}

.universal-button:hover { transform: translateY(-2px); }
.universal-button.primary { background: var(--up-ink); color: var(--up-paper); }
.universal-button.secondary { background: rgba(255,255,255,.7); }

.universal-map-card {
  position: relative;
  min-height: 410px;
  overflow: hidden;
  border: 1px solid rgba(58, 41, 34, .16);
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 45%, rgba(255,255,255,.12), transparent 25%),
    linear-gradient(145deg, #87503e, #3c2823);
  box-shadow: 0 28px 90px rgba(40, 31, 26, .18);
}

.universal-map-ring,
.universal-map-axis {
  position: absolute;
  left: 50%;
  top: 47%;
}

.universal-map-ring {
  border: 1px solid rgba(255, 239, 218, .34);
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.universal-map-ring.one { width: 74%; aspect-ratio: 1; }
.universal-map-ring.two { width: 54%; aspect-ratio: 1; }
.universal-map-ring.three { width: 34%; aspect-ratio: 1; }

.universal-map-axis {
  width: 69%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,239,218,.42), transparent);
  transform-origin: center;
}

.universal-map-axis.a { transform: translate(-50%, -50%) rotate(0deg); }
.universal-map-axis.b { transform: translate(-50%, -50%) rotate(60deg); }
.universal-map-axis.c { transform: translate(-50%, -50%) rotate(120deg); }

.universal-map-core {
  position: absolute;
  left: 50%;
  top: 47%;
  display: grid;
  place-items: center;
  width: 120px;
  height: 120px;
  border: 1px solid rgba(255,239,218,.7);
  border-radius: 50%;
  background: rgba(51, 30, 25, .84);
  color: #fff3e5;
  transform: translate(-50%, -50%);
}

.universal-map-core strong {
  font: 500 3rem/.9 Georgia, "Times New Roman", serif;
}

.universal-map-core span {
  color: rgba(255,243,229,.72);
  font-size: .72rem;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.universal-map-caption {
  position: absolute;
  inset: auto 22px 20px;
  color: rgba(255,244,230,.78);
  text-align: center;
  font-size: .86rem;
  font-weight: 800;
}

.universal-section {
  padding: clamp(48px, 7vw, 88px) 0;
  border-top: 1px solid var(--up-line);
}

.universal-section h2,
.universal-closing h2 {
  max-width: 900px;
  font-size: clamp(2.1rem, 5vw, 4.5rem);
  line-height: 1.03;
}

.section-intro {
  max-width: 810px;
  margin: 18px 0 0;
  color: var(--up-muted);
  font-size: 1.08rem;
  line-height: 1.72;
}

.problem-finder-panel {
  margin-top: 28px;
  border: 1px solid var(--up-line);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.9), rgba(243,230,207,.72)),
    #fffaf0;
  box-shadow: 0 24px 72px rgba(40, 35, 31, .11);
  padding: clamp(22px, 4vw, 38px);
}

.problem-finder-path {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.problem-finder-path span {
  border: 1px solid rgba(53, 95, 80, .18);
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: #4b554d;
  padding: 6px 10px;
  font-size: .84rem;
  font-weight: 800;
}

.problem-finder-stage { display: grid; gap: 16px; }
.problem-finder-note { margin: 0; color: var(--up-muted); }

.problem-finder-grid,
.finder-results,
.area-grid,
.ecosystem-grid,
.structure-grid {
  display: grid;
  gap: 15px;
}

.problem-finder-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.finder-results { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.area-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 28px; }
.ecosystem-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 28px; }
.structure-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 28px; }

.finder-choice,
.finder-back,
.finder-result { font: inherit; }

.finder-choice {
  width: 100%;
  min-height: 118px;
  border: 1px solid rgba(40, 35, 31, .14);
  border-radius: 13px;
  background: rgba(255,255,255,.78);
  color: var(--up-ink);
  padding: 18px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(40,35,31,.055);
  transition: transform .15s ease, border-color .15s ease, background .15s ease;
}

.finder-choice:hover,
.finder-choice:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(53, 95, 80, .4);
  background: #fffdf8;
}

.finder-choice strong,
.finder-result h3,
.area-card h3,
.ecosystem-card h3,
.structure-card h3 {
  display: block;
  margin: 0 0 8px;
  color: #29241f;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
  font-weight: 500;
  line-height: 1.16;
}

.finder-choice span,
.finder-result p,
.area-card p,
.ecosystem-card p,
.structure-card p { color: var(--up-muted); line-height: 1.55; }

.finder-back {
  width: fit-content;
  border: 1px solid rgba(40, 35, 31, .18);
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--up-green);
  padding: 8px 12px;
  font-weight: 900;
  cursor: pointer;
}

.finder-result,
.area-card,
.ecosystem-card,
.structure-card {
  border: 1px solid var(--up-line);
  border-radius: 14px;
  background: var(--up-card);
  box-shadow: 0 16px 44px rgba(40,35,31,.065);
  padding: 21px;
}

.finder-result.primary {
  border-color: rgba(53, 95, 80, .36);
  background: linear-gradient(135deg, rgba(53,95,80,.1), rgba(255,255,255,.82));
}

.result-id,
.area-count,
.ecosystem-type {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 10px;
  border: 1px solid rgba(53, 95, 80, .18);
  border-radius: 999px;
  background: rgba(255,255,255,.72);
  color: var(--up-green);
  padding: 5px 9px;
  font-size: .74rem;
  font-weight: 950;
  letter-spacing: .06em;
}

.finder-result a,
.area-card a,
.ecosystem-card a {
  display: inline-flex;
  margin-top: 10px;
  color: var(--up-rust);
  font-weight: 900;
  text-decoration: none;
}

.ecosystem-card {
  position: relative;
  overflow: hidden;
}

.ecosystem-card::after {
  position: absolute;
  right: -35px;
  bottom: -35px;
  width: 110px;
  height: 110px;
  border: 1px solid rgba(123,67,52,.12);
  border-radius: 50%;
  content: "";
}

.universal-closing {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  margin: 0 0 72px;
  border-radius: 20px;
  background: #29241f;
  color: var(--up-paper);
  padding: clamp(26px, 5vw, 46px);
}

.universal-closing h2 { color: var(--up-paper); }
.universal-closing p { max-width: 750px; color: rgba(250,246,237,.76); line-height: 1.65; }
.universal-closing .universal-button { border-color: rgba(250,246,237,.75); color: var(--up-paper); }

.universal-home .site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
  border-top: 1px solid var(--up-line);
  padding: 24px 0 38px;
  color: var(--up-muted);
  font-size: .88rem;
}

@media (max-width: 980px) {
  .universal-home .site-header { grid-template-columns: 1fr auto; }
  .universal-home .site-nav { grid-column: 1 / -1; order: 3; padding-bottom: 14px; }
  .universal-hero { grid-template-columns: 1fr; }
  .universal-map-card { min-height: 360px; }
  .area-grid,
  .ecosystem-grid,
  .structure-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .universal-home .site-header { width: min(100% - 22px, 1220px); }
  .universal-home .brand span:last-child { display: none; }
  .universal-home .site-nav { justify-content: flex-start; overflow-x: auto; flex-wrap: nowrap; }
  .universal-home .site-nav a { white-space: nowrap; }
  .universal-shell { width: min(100% - 24px, 1180px); }
  .universal-hero { padding-top: 42px; }
  .universal-hero h1 { font-size: clamp(2.85rem, 14vw, 4.5rem); }
  .universal-actions { display: grid; }
  .universal-button { width: 100%; }
  .problem-finder-grid,
  .finder-results,
  .area-grid,
  .ecosystem-grid,
  .structure-grid { grid-template-columns: 1fr; }
  .finder-choice { min-height: auto; }
  .universal-closing { grid-template-columns: 1fr; }
  .universal-home .site-footer { display: grid; }
}

@media (prefers-reduced-motion: reduce) {
  .universal-button,
  .finder-choice { transition: none; }
}
