/* ==========================================================================
   Ephany — Open Source layer
   Sits on top of ud-styles.css. Brand tokens unchanged (#3056d3 / Poppins);
   this file adds the developer-facing surfaces: terminals, repo cards,
   contribution lanes, and the dark "for AI agents" band.
   ========================================================================== */

:root {
  --eph-accent: #3056d3;
  --eph-accent-soft: #eaeefc;
  --eph-accent-light: #7d9bff;
  --eph-ink: #0b1020;
  --eph-ink-2: #131a2e;
  --eph-ink-3: #1c2540;
  --eph-ink-line: rgba(255, 255, 255, 0.1);
  --eph-ink-text: #b6c0d9;
  --eph-surface: #f7f8fb;
  --eph-line: #e4e8f0;
  --eph-heading: #101828;
  --eph-body: #566072;
  --eph-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
    "Liberation Mono", monospace;
}

/* ── Shared bits ─────────────────────────────────────────────────────────── */

.eph-mono {
  font-family: var(--eph-mono);
}

.eph-section {
  padding: 100px 0;
}

.eph-section--tight {
  padding: 80px 0;
}

.eph-section--surface {
  background: var(--eph-surface);
}

.eph-section-head {
  max-width: 680px;
  margin: 0 auto 60px;
  text-align: center;
}

.eph-section-head--left {
  margin-left: 0;
  text-align: left;
}

.eph-eyebrow {
  display: inline-block;
  font-family: var(--eph-mono);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--eph-accent);
  margin-bottom: 16px;
}

.eph-section-head h2 {
  font-size: 40px;
  line-height: 1.2;
  font-weight: 700;
  color: var(--eph-heading);
  margin-bottom: 18px;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.eph-section-head p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--eph-body);
  margin: 0;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */

.eph-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.eph-btn i {
  font-size: 17px;
}

.eph-btn--primary {
  background: var(--eph-accent);
  color: #fff;
}

.eph-btn--primary:hover {
  background: #2545b4;
  color: #fff;
}

.eph-btn--light {
  background: #fff;
  color: var(--eph-accent);
}

.eph-btn--light:hover {
  background: rgba(255, 255, 255, 0.9);
  color: var(--eph-accent);
}

.eph-btn--ghost-light {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.35);
  color: #fff;
}

.eph-btn--ghost-light:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.eph-btn--outline {
  background: transparent;
  border-color: var(--eph-line);
  color: var(--eph-heading);
}

.eph-btn--outline:hover {
  border-color: var(--eph-accent);
  color: var(--eph-accent);
}

/* ── Header tweak: GitHub button ─────────────────────────────────────────── */

.eph-gh-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #fff;
  transition: all 0.2s ease;
}

.eph-gh-btn:hover {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}

.sticky .eph-gh-btn {
  background: var(--eph-accent);
  border-color: var(--eph-accent);
  color: #fff;
}

.sticky .eph-gh-btn:hover {
  background: #2545b4;
}

.eph-gh-btn svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */

.eph-hero {
  background: var(--eph-accent);
  background-image: radial-gradient(
      circle at 15% 0%,
      rgba(125, 155, 255, 0.45) 0%,
      transparent 45%
    ),
    radial-gradient(circle at 85% 100%, rgba(11, 16, 32, 0.5) 0%, transparent 50%);
  padding: 170px 0 90px;
  position: relative;
  overflow: hidden;
}

.eph-hero-inner {
  max-width: 940px;
  margin: 0 auto;
  text-align: center;
}

.eph-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 16px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  font-family: var(--eph-mono);
  font-size: 12.5px;
  letter-spacing: 0.03em;
  color: #fff;
  margin-bottom: 28px;
}

.eph-hero-pill .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #5ce6a1;
  box-shadow: 0 0 0 3px rgba(92, 230, 161, 0.25);
}

.eph-hero h1 {
  font-size: 48px;
  line-height: 1.16;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.025em;
  margin-bottom: 22px;
  text-wrap: balance;
}

.eph-hero h1 .accent {
  color: #cddaff;
}

.eph-hero-desc {
  font-size: 19px;
  line-height: 1.68;
  color: rgba(255, 255, 255, 0.85);
  max-width: 660px;
  margin: 0 auto 36px;
}

.eph-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  margin-bottom: 44px;
}

.eph-hero-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 28px;
  font-family: var(--eph-mono);
  font-size: 13px;
  color: rgba(255, 255, 255, 0.72);
}

.eph-hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.eph-hero-meta .swatch {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #ffd43b;
}

/* ── Terminal / code blocks ──────────────────────────────────────────────── */

.eph-terminal {
  background: var(--eph-ink);
  border: 1px solid var(--eph-ink-line);
  border-radius: 10px;
  overflow: hidden;
  text-align: left;
  box-shadow: 0 24px 60px -20px rgba(6, 10, 25, 0.55);
}

.eph-terminal--flat {
  box-shadow: none;
}

.eph-terminal-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  background: var(--eph-ink-2);
  border-bottom: 1px solid var(--eph-ink-line);
}

.eph-terminal-dots {
  display: flex;
  gap: 6px;
}

.eph-terminal-dots i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.eph-terminal-label {
  font-family: var(--eph-mono);
  font-size: 12.5px;
  color: #7d8aa8;
}

.eph-terminal-copy {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: 1px solid var(--eph-ink-line);
  border-radius: 5px;
  padding: 5px 11px;
  font-family: var(--eph-mono);
  font-size: 11.5px;
  color: #9aa6c2;
  cursor: pointer;
  transition: all 0.2s ease;
}

.eph-terminal-copy:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.3);
}

.eph-terminal-copy.copied {
  color: #5ce6a1;
  border-color: rgba(92, 230, 161, 0.45);
}

.eph-terminal-body {
  padding: 20px 22px;
  font-family: var(--eph-mono);
  font-size: 14px;
  line-height: 1.9;
  color: #dbe3f5;
  overflow-x: auto;
  white-space: pre;
  margin: 0;
}

.eph-terminal-body .c-prompt {
  color: #5ce6a1;
  user-select: none;
}

.eph-terminal-body .c-cmd {
  color: #fff;
}

.eph-terminal-body .c-flag {
  color: #7d9bff;
}

.eph-terminal-body .c-str {
  color: #ffd88a;
}

.eph-terminal-body .c-com {
  color: #6a7691;
}

.eph-terminal-body .c-key {
  color: #ff9ec3;
}

.eph-hero .eph-terminal {
  max-width: 620px;
  margin: 0 auto 36px;
}

/* ── Quickstart steps ────────────────────────────────────────────────────── */

.eph-steps {
  display: grid;
  gap: 20px;
}

.eph-step {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.eph-step-num {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--eph-accent-soft);
  color: var(--eph-accent);
  font-family: var(--eph-mono);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.eph-step-body h4 {
  font-size: 17px;
  font-weight: 600;
  color: var(--eph-heading);
  margin-bottom: 6px;
}

.eph-step-body p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--eph-body);
  margin: 0;
}

.eph-step-body p code,
.eph-inline-code {
  font-family: var(--eph-mono);
  font-size: 0.9em;
  background: var(--eph-accent-soft);
  color: var(--eph-accent);
  padding: 2px 7px;
  border-radius: 4px;
}

.eph-quickstart-note {
  margin-top: 28px;
  padding: 18px 20px;
  border-left: 3px solid var(--eph-accent);
  background: var(--eph-accent-soft);
  border-radius: 0 6px 6px 0;
  font-size: 14.5px;
  line-height: 1.65;
  color: #3a4560;
}

.eph-quickstart-note strong {
  color: var(--eph-heading);
}

/* ── Dark band (AI agents) ───────────────────────────────────────────────── */

.eph-dark {
  background: var(--eph-ink);
  color: var(--eph-ink-text);
  position: relative;
  overflow: hidden;
}

.eph-dark::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(
    circle at 80% 10%,
    rgba(48, 86, 211, 0.28) 0%,
    transparent 55%
  );
  pointer-events: none;
}

.eph-dark > .container {
  position: relative;
  z-index: 1;
}

.eph-dark .eph-eyebrow {
  color: var(--eph-accent-light);
}

.eph-dark .eph-section-head h2 {
  color: #fff;
}

.eph-dark .eph-section-head p {
  color: var(--eph-ink-text);
}

.eph-agent-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 44px;
}

.eph-agent-card {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid var(--eph-ink-line);
  border-radius: 10px;
  padding: 26px;
}

.eph-agent-card i.lni {
  font-size: 24px;
  color: var(--eph-accent-light);
  margin-bottom: 16px;
  display: block;
}

.eph-agent-card h4 {
  font-size: 16.5px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 9px;
}

.eph-agent-card p {
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--eph-ink-text);
  margin: 0;
}

.eph-agent-card code {
  font-family: var(--eph-mono);
  font-size: 0.9em;
  color: #ffd88a;
}

/* Prompt sample */
.eph-prompt {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--eph-ink-line);
  border-radius: 10px;
  padding: 24px 26px;
  margin-top: 22px;
}

.eph-prompt-label {
  font-family: var(--eph-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6a7691;
  margin-bottom: 14px;
}

.eph-prompt-line {
  display: flex;
  gap: 12px;
  font-family: var(--eph-mono);
  font-size: 14.5px;
  line-height: 1.75;
  color: #fff;
}

.eph-prompt-line + .eph-prompt-line {
  margin-top: 12px;
}

.eph-prompt-line span:first-child {
  color: var(--eph-accent-light);
  flex: 0 0 auto;
}

/* ── Feature grid ────────────────────────────────────────────────────────── */

.eph-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.eph-feature {
  background: #fff;
  border: 1px solid var(--eph-line);
  border-radius: 10px;
  padding: 28px;
  transition: all 0.25s ease;
}

.eph-feature:hover {
  border-color: #c3cee8;
  box-shadow: 0 12px 32px -14px rgba(16, 24, 40, 0.16);
}

.eph-feature i.lni {
  font-size: 22px;
  color: var(--eph-accent);
  margin-bottom: 16px;
  display: block;
}

.eph-feature h4 {
  font-size: 17px;
  font-weight: 600;
  color: var(--eph-heading);
  margin-bottom: 9px;
}

.eph-feature p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--eph-body);
  margin: 0;
}

/* ── Repo / ecosystem cards ──────────────────────────────────────────────── */

.eph-repo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.eph-repo {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--eph-line);
  border-radius: 10px;
  padding: 26px;
  transition: all 0.25s ease;
}

.eph-repo:hover {
  border-color: var(--eph-accent);
  transform: translateY(-3px);
  box-shadow: 0 16px 36px -16px rgba(48, 86, 211, 0.3);
}

.eph-repo-name {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--eph-mono);
  font-size: 15px;
  font-weight: 600;
  color: var(--eph-heading);
  margin-bottom: 12px;
}

.eph-repo-name svg {
  width: 16px;
  height: 16px;
  fill: #8b95ab;
  flex: 0 0 auto;
}

.eph-repo p {
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--eph-body);
  margin: 0 0 22px;
  flex: 1;
}

.eph-repo-foot {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 13px;
  color: #7d8798;
  font-family: var(--eph-mono);
}

.eph-repo-foot span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.eph-lang-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.eph-lang-dot--py {
  background: #3572a5;
}

.eph-lang-dot--ts {
  background: #3178c6;
}

.eph-lang-dot--cs {
  background: #178600;
}

/* ── Contribute ──────────────────────────────────────────────────────────── */

.eph-contribute {
  background: var(--eph-surface);
}

.eph-lanes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.eph-lane {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--eph-line);
  border-radius: 8px;
  padding: 18px 20px;
}

.eph-lane i.lni {
  font-size: 18px;
  color: var(--eph-accent);
  margin-top: 3px;
  flex: 0 0 auto;
}

.eph-lane h5 {
  font-size: 15px;
  font-weight: 600;
  color: var(--eph-heading);
  margin-bottom: 4px;
}

.eph-lane p {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--eph-body);
  margin: 0;
}

.eph-honest {
  background: #fff;
  border: 1px solid var(--eph-line);
  border-radius: 10px;
  padding: 30px;
  margin-top: 34px;
}

.eph-honest h4 {
  font-size: 17px;
  font-weight: 600;
  color: var(--eph-heading);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.eph-honest ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.eph-honest li {
  position: relative;
  padding-left: 26px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--eph-body);
}

.eph-honest li + li {
  margin-top: 10px;
}

.eph-honest li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 10px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--eph-accent);
}

/* ── Final CTA ───────────────────────────────────────────────────────────── */

.eph-cta {
  background: var(--eph-accent);
  background-image: radial-gradient(
    circle at 50% 120%,
    rgba(11, 16, 32, 0.45) 0%,
    transparent 60%
  );
  padding: 90px 0;
  text-align: center;
}

.eph-cta h2 {
  text-wrap: balance;
  font-size: 38px;
  line-height: 1.22;
  font-weight: 700;
  color: #fff;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.eph-cta p {
  font-size: 18px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.85);
  max-width: 560px;
  margin: 0 auto 34px;
}

.eph-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
}

/* ── Footer link columns ─────────────────────────────────────────────────── */

.eph-footer-title {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 20px;
}

.eph-footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.eph-footer-links li + li {
  margin-top: 11px;
}

.eph-footer-links a {
  font-size: 14.5px;
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.2s ease;
}

.eph-footer-links a:hover {
  color: #fff;
}

.eph-license-note {
  font-family: var(--eph-mono);
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 22px;
  line-height: 1.7;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 991px) {
  .eph-agent-grid,
  .eph-feature-grid,
  .eph-repo-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .eph-hero h1 {
    font-size: 40px;
  }

  .eph-section-head h2 {
    font-size: 32px;
  }
}

@media (max-width: 767px) {
  .eph-section,
  .eph-section--tight {
    padding: 64px 0;
  }

  .eph-hero {
    padding: 130px 0 70px;
  }

  .eph-hero h1 {
    font-size: 31px;
    line-height: 1.2;
  }

  .eph-hero-desc {
    font-size: 16.5px;
  }

  .eph-hero-actions .eph-btn,
  .eph-cta-actions .eph-btn {
    width: 100%;
  }

  .eph-section-head h2 {
    font-size: 27px;
  }

  .eph-cta h2 {
    font-size: 27px;
  }

  .eph-agent-grid,
  .eph-feature-grid,
  .eph-repo-grid,
  .eph-lanes {
    grid-template-columns: 1fr;
  }

  .eph-terminal-body {
    font-size: 12.5px;
    padding: 16px;
  }

  .eph-terminal-label {
    display: none;
  }

  .eph-hero-pill {
    font-size: 11px;
    padding: 7px 14px;
    line-height: 1.5;
    text-align: left;
  }

  .eph-hero-meta {
    gap: 8px 18px;
    font-size: 12px;
  }
}

/* ── Fixes over the base template ────────────────────────────────────────── */

/* main.js only toggles this on scroll, so it flashes in at page load. */
.back-to-top {
  display: none;
}
