/* Semario — brand v2 "The Link" · light, Nordic, engineered
   Tokens from docs/branding profile/Semario/brand.tokens.json */

:root {
  --navy: #17233F;
  --midnight: #0E1629;
  --slate: #5B6572;
  --cloud: #E4E7EB;
  --snow: #F5F6F8;
  --white: #FFFFFF;
  --accent: #14B8A6;
  --accent-dark: #0F9D8E;
  --line: #E4E7EB;
  --line-soft: #ECEFF2;
  --shell: 1240px;
  --shadow-card: 0 2px 8px rgba(23, 35, 63, .06);
  --shadow-lift: 0 10px 30px rgba(23, 35, 63, .10);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: var(--snow);
  color: var(--navy);
  font-family: "Inter", sans-serif;
  overflow-x: hidden;
}

body::selection {
  background: var(--accent);
  color: var(--white);
}

a {
  color: inherit;
  text-decoration: none;
}

.shell {
  width: min(calc(100% - 40px), var(--shell));
  margin-inline: auto;
}

.page-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(23, 35, 63, .028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 35, 63, .028) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .5), transparent 65%);
  z-index: -3;
}

/* ---------- header ---------- */

.site-header {
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 10;
}

.brand {
  display: inline-flex;
  align-items: center;
}

.brand img {
  display: block;
}

.nav {
  display: flex;
  gap: 28px;
  align-items: center;
  color: var(--slate);
  font-size: 14px;
  font-weight: 500;
}

.nav a {
  transition: color .2s ease;
}

.nav a:hover {
  color: var(--accent-dark);
}

/* ---------- hero ---------- */

.hero {
  min-height: calc(100vh - 84px);
  padding: 90px 0 110px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  gap: 70px;
  align-items: center;
}

.eyebrow-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--slate);
  font-weight: 600;
  margin-bottom: 28px;
}

.signal-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(20, 184, 166, .12);
}

h1, h2, h3 {
  font-family: "Archivo", sans-serif;
  letter-spacing: -.02em;
}

h1 {
  font-size: clamp(56px, 7.6vw, 104px);
  line-height: .98;
  max-width: 980px;
  font-weight: 700;
  color: var(--navy);
}

.accent-text {
  color: var(--accent);
}

.lede {
  margin-top: 34px;
  max-width: 640px;
  color: var(--slate);
  font-size: clamp(17px, 2vw, 19px);
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 36px;
}

.btn {
  min-height: 52px;
  padding: 0 22px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 15px;
  font-weight: 600;
  transition: transform .2s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: var(--white);
  background: var(--accent);
  box-shadow: 0 4px 14px rgba(20, 184, 166, .28);
}

.btn-primary:hover {
  background: var(--accent-dark);
}

.btn-ghost {
  border: 1px solid var(--cloud);
  background: var(--white);
  color: var(--navy);
}

.btn-ghost:hover {
  border-color: var(--navy);
}

/* hero panel — the dark counterpart */

.hero-panel {
  min-height: 480px;
  border-radius: 20px;
  background:
    radial-gradient(circle at 75% 15%, rgba(20, 184, 166, .14), transparent 45%),
    linear-gradient(180deg, var(--navy), var(--midnight));
  padding: 22px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lift);
  display: flex;
  flex-direction: column;
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black, transparent 72%);
}

.panel-topline {
  display: flex;
  justify-content: space-between;
  color: #7C89A3;
  font-size: 10px;
  letter-spacing: .15em;
  position: relative;
  z-index: 2;
}

.panel-topline span:last-child {
  color: var(--accent);
}

.panel-mark {
  flex: 1;
  position: relative;
  display: grid;
  place-items: center;
}

.panel-mark img {
  width: 62%;
  max-width: 260px;
  position: relative;
  z-index: 3;
  filter: drop-shadow(0 8px 30px rgba(0, 0, 0, .35));
}

.mark-ring {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, .10);
  border-radius: 50%;
}

.ring-a {
  width: 300px;
  height: 300px;
  animation: rotate 26s linear infinite;
}

.ring-a::after,
.ring-b::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 14px rgba(20, 184, 166, .8);
}

.ring-a::after {
  top: 20px;
  left: 44px;
}

.ring-b {
  width: 380px;
  height: 380px;
  opacity: .6;
  animation: rotate-reverse 34s linear infinite;
}

.ring-b::after {
  right: 40px;
  bottom: 62px;
  background: #7C89A3;
  box-shadow: none;
}

@keyframes rotate { to { transform: rotate(360deg); } }
@keyframes rotate-reverse { to { transform: rotate(-360deg); } }

.panel-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid rgba(255, 255, 255, .10);
  position: relative;
  z-index: 2;
}

.panel-metrics > div {
  padding: 18px 8px 4px;
}

.panel-metrics > div + div {
  border-left: 1px solid rgba(255, 255, 255, .10);
  padding-left: 20px;
}

.metric-label {
  display: block;
  color: #7C89A3;
  font-size: 9px;
  letter-spacing: .16em;
  margin-bottom: 7px;
}

.panel-metrics strong {
  font-size: 13px;
  font-weight: 600;
  color: #E8ECF3;
}

/* ---------- ticker ---------- */

.ticker {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  white-space: nowrap;
  background: var(--white);
}

.ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 34px;
  padding: 20px 34px;
  animation: ticker 28s linear infinite;
}

.ticker-track span {
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--slate);
  font-weight: 700;
}

.ticker-track i {
  color: var(--accent);
  font-style: normal;
}

@keyframes ticker {
  to { transform: translateX(-50%); }
}

/* ---------- sections ---------- */

.section {
  padding: 130px 0;
}

.section-head {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 90px;
  align-items: end;
  padding-bottom: 52px;
}

.section-head.compact {
  grid-template-columns: 1fr;
}

.section-kicker {
  display: block;
  color: var(--accent-dark);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: .16em;
  font-weight: 700;
  margin-bottom: 16px;
}

.section-head h2,
.contact-card h2 {
  font-size: clamp(40px, 5vw, 68px);
  line-height: 1.0;
  color: var(--navy);
}

.section-head > p {
  color: var(--slate);
  line-height: 1.75;
  font-size: 16px;
  max-width: 500px;
}

/* capability cards */

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

.capability-card {
  min-height: 360px;
  padding: 28px;
  border-radius: 16px;
  border: 1px solid var(--cloud);
  position: relative;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-card);
  transition: box-shadow .25s ease, transform .25s ease, border-color .25s ease;
}

.capability-card:hover {
  box-shadow: var(--shadow-lift);
  transform: translateY(-3px);
  border-color: #D5DAE0;
}

.card-index {
  color: #A6AEB9;
  font-size: 10px;
  letter-spacing: .18em;
  font-weight: 600;
}

.card-content {
  max-width: 520px;
  margin-top: 110px;
  position: relative;
  z-index: 2;
}

.card-tag {
  display: block;
  color: var(--accent-dark);
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: .14em;
  margin-bottom: 12px;
  font-weight: 700;
}

.card-content h3 {
  font-size: clamp(24px, 2.6vw, 34px);
  line-height: 1.08;
  color: var(--navy);
  max-width: 560px;
}

.card-content p {
  color: var(--slate);
  line-height: 1.7;
  font-size: 14.5px;
  margin-top: 14px;
  max-width: 500px;
}

.graph {
  position: absolute;
  top: 36px;
  right: 34px;
  display: flex;
  gap: 8px;
  align-items: flex-end;
  height: 80px;
}

.graph span {
  width: 10px;
  border-radius: 3px 3px 0 0;
  background: linear-gradient(to top, rgba(20, 184, 166, .25), var(--accent));
}

.graph span:nth-child(1) { height: 25%; }
.graph span:nth-child(2) { height: 42%; }
.graph span:nth-child(3) { height: 63%; }
.graph span:nth-child(4) { height: 49%; }
.graph span:nth-child(5) { height: 88%; }

.mini-ui {
  position: absolute;
  right: 28px;
  top: 32px;
  width: 125px;
  height: 80px;
  border: 1px solid var(--cloud);
  border-radius: 12px;
  padding: 12px;
  background: var(--snow);
}

.mini-ui-bar {
  height: 6px;
  width: 56px;
  border-radius: 999px;
  background: var(--accent);
}

.mini-ui-row {
  display: flex;
  gap: 6px;
  margin-top: 18px;
}

.mini-ui-row span {
  height: 28px;
  flex: 1;
  border-radius: 6px;
  background: var(--cloud);
}

.nodes {
  position: absolute;
  top: 55px;
  right: 55px;
  width: 105px;
  height: 70px;
}

.nodes::before,
.nodes::after {
  content: "";
  position: absolute;
  border-top: 1px solid #D5DAE0;
  width: 80px;
  top: 34px;
  left: 12px;
  transform: rotate(20deg);
}

.nodes::after {
  transform: rotate(-20deg);
}

.nodes span {
  position: absolute;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 1.5px solid #B6BEC9;
  background: var(--white);
}

.nodes span:nth-child(1) { left: 0; top: 7px; }
.nodes span:nth-child(2) { right: 0; top: 0; }
.nodes span:nth-child(3) { left: 16px; bottom: 0; }
.nodes span:nth-child(4) {
  right: 12px;
  bottom: 3px;
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 14px rgba(20, 184, 166, .35);
}

.code-chip {
  position: absolute;
  top: 42px;
  right: 30px;
  border: 1px solid var(--cloud);
  border-radius: 999px;
  padding: 10px 13px;
  display: flex;
  gap: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  background: var(--snow);
}

.code-chip span { color: var(--slate); }
.code-chip strong { color: var(--accent-dark); font-weight: 600; }

/* principles */

.principles {
  padding-top: 60px;
}

.principle-list {
  border-top: 1px solid var(--line);
}

.principle-item {
  display: grid;
  grid-template-columns: 90px 1fr 1fr;
  gap: 30px;
  align-items: center;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
}

.principle-item > span {
  color: #A6AEB9;
  font-size: 11px;
  letter-spacing: .16em;
  font-weight: 600;
}

.principle-item h3 {
  font-size: 24px;
  color: var(--navy);
}

.principle-item p {
  color: var(--slate);
  line-height: 1.65;
  font-size: 14.5px;
  max-width: 470px;
}

/* manifesto — dark counterpart */

.manifesto {
  background:
    radial-gradient(circle at 85% 0%, rgba(20, 184, 166, .10), transparent 40%),
    linear-gradient(180deg, var(--navy), var(--midnight));
}

.manifesto .section-kicker {
  color: var(--accent);
}

.manifesto-inner {
  padding: 110px 0;
}

.manifesto p {
  max-width: 1000px;
  font-family: "Archivo", sans-serif;
  font-weight: 700;
  font-size: clamp(40px, 5.8vw, 78px);
  line-height: 1.04;
  letter-spacing: -.02em;
  color: var(--white);
}

.manifesto p span {
  color: var(--accent);
}

/* contact */

.contact {
  padding: 130px 0;
}

.contact-card {
  border: 1px solid var(--cloud);
  border-radius: 20px;
  padding: 52px;
  background:
    radial-gradient(circle at top right, rgba(20, 184, 166, .07), transparent 32%),
    var(--white);
  box-shadow: var(--shadow-card);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: end;
}

.contact-card p {
  color: var(--slate);
  margin-top: 18px;
  font-size: 16px;
}

.contact-link {
  min-width: 300px;
  padding: 20px 0 12px;
  border-bottom: 2px solid var(--navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 16px;
  font-weight: 600;
  color: var(--navy);
  transition: border-color .2s ease, color .2s ease;
}

.contact-link:hover {
  border-color: var(--accent);
  color: var(--accent-dark);
}

/* footer — dark counterpart */

.footer {
  background: var(--midnight);
  color: #8E99AF;
}

.footer-inner {
  padding: 34px 0 42px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-meta {
  display: flex;
  gap: 26px;
  font-size: 12px;
}

/* ---------- responsive ---------- */

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

  .hero-panel {
    min-height: 420px;
  }

  .section-head {
    grid-template-columns: 1fr;
    gap: 26px;
  }

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

  .contact-link {
    min-width: 0;
    width: 100%;
  }
}

@media (max-width: 760px) {
  .site-header {
    height: 72px;
  }

  .nav a:not(:last-child) {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 64px 0 80px;
  }

  h1 {
    font-size: clamp(44px, 13vw, 72px);
  }

  .hero-panel {
    min-height: 360px;
  }

  .panel-mark img {
    width: 55%;
  }

  .ring-a { width: 220px; height: 220px; }
  .ring-b { width: 290px; height: 290px; }

  .section {
    padding: 90px 0;
  }

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

  .capability-card {
    min-height: 330px;
  }

  .card-content {
    margin-top: 96px;
  }

  .principle-item {
    grid-template-columns: 55px 1fr;
  }

  .principle-item p {
    grid-column: 2;
  }

  .contact-card {
    padding: 32px 24px;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 20px;
  }

  .footer-meta {
    flex-direction: column;
    gap: 6px;
  }
}
