/* ============================================================
   Orvyn — Landing Page Styles
   Pure CSS, no external fetches. System font stack used.
   Dark theme permanent.
   ============================================================ */

/* ---------- CSS Variables (Design Tokens) ---------- */
:root {
  /* Colors - Dark only */
  --bg: #121212;
  --text: #ffffff;
  --text-muted: rgba(202, 202, 202, 0.7);
  --text-subtle: #767676;
  --text-faint: #8f8f8f;
  --text-footer-name: #e9e9e9;
  --card-bg: #181818;
  --card-border: rgba(0, 0, 0, 0.06);
  --card-pad-x: 20px;
  --stage-bg: #131313;
  --stage-border: rgba(255, 255, 255, 0.02);
  --chip-bg: rgba(255, 255, 255, 0.07);
  --icon-color: #ededed;
  --icon-color-muted: rgba(237, 237, 237, 0.6);
  --tab-bar-bg: #202020;
  --tab-pill-bg: #454545;
  --tab-text-muted: rgba(193, 193, 193, 0.8);
  --tab-text-active: #ffffff;

  /* Fonts - System stack (no fetch) */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Animation */
  --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
  --duration-fast: 250ms;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  min-height: 100dvh;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scrollbar-gutter: stable;
  color-scheme: dark;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  overflow-x: hidden;
}

/* ---------- Noise Overlay ---------- */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  opacity: 0.012;
  pointer-events: none;
  z-index: 9999;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* ---------- Skip Link ---------- */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 200;
  padding: 12px 20px;
  border-radius: 8px;
  background: var(--text);
  color: var(--bg);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.skip-link:focus {
  top: 16px;
}

/* ---------- Layout ---------- */
.app {
  position: relative;
  max-width: 1008px;
  margin: 0 auto;
  width: 100%;
  padding: 0 24px 64px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- Top Bar ---------- */
.top-bar {
  position: absolute;
  top: 16px;
  right: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 10;
}

/* ---------- Capsule Pill Buttons ---------- */
.pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border-radius: 50px;
  background: var(--chip-bg);
  color: var(--icon-color-muted);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid var(--stage-border);
  transition: color var(--duration-fast) var(--ease-smooth);
  outline: none;
  box-shadow: none;
}

.pill-btn:hover,
.pill-btn:focus,
.pill-btn:focus-visible,
.pill-btn:active {
  background: var(--chip-bg);
  border-color: var(--stage-border);
  color: var(--text);
  transform: none;
  outline: none;
  box-shadow: none;
}

.pill-btn::-moz-focus-inner {
  border: 0;
}

.pill-btn svg {
  display: block;
  fill: currentColor;
  color: inherit;
  flex-shrink: 0;
}

.pill-text {
  line-height: 1;
}

.github-btn .pill-text {
  text-align: left;
}

#github-star-count {
  transition: opacity 0.2s ease;
}

/* ---------- Header ---------- */
.header {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 120px;
  padding-bottom: 40px;
  text-align: center;
}

.header-icon-wrap {
  position: relative;
  width: 60px;
  height: 60px;
  margin-top: -8px;
  margin-bottom: 10px;
  overflow: visible;
}

.header-icon-img {
  position: absolute;
  left: 0;
  top: 0;
  width: 60px;
  height: 60px;
  user-select: none;
  transform-origin: center;
  transition: filter 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (hover: hover) {
  .header-icon-wrap:hover .header-icon-img {
    filter: hue-rotate(60deg) saturate(1.6);
  }
}

.title {
  font-size: 22px;
  font-weight: 500;
  line-height: 34px;
  color: var(--text);
  letter-spacing: -0.01em;
  margin-top: 6px;
}

.subtitle {
  margin-top: 4px;
  max-width: 560px;
  font-size: 15px;
  font-weight: 400;
  line-height: 22px;
  color: var(--text-muted);
}

/* ---------- View Tabs ---------- */
.view-tabs {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin: 40px auto 0;
  padding: 3px;
  border-radius: 48px;
  background: var(--tab-bar-bg);
}

.view-tab {
  position: relative;
  appearance: none;
  box-sizing: border-box;
  border: 0;
  background: transparent;
  height: 30px;
  padding: 4px 12px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--tab-text-muted);
  cursor: pointer;
  border-radius: 48px;
  z-index: 1;
  transition: color var(--duration-fast) var(--ease-smooth);
  white-space: nowrap;
}

.view-tab:not([aria-selected="true"]):hover {
  color: var(--tab-text-active);
}

.view-tab[aria-selected="true"] {
  color: var(--tab-text-active);
}

.view-tab:focus,
.view-tab:focus-visible,
.view-tab:active {
  outline: none;
  border: none;
  box-shadow: none;
}

.view-tab::-moz-focus-inner {
  border: 0;
}

.view-tabs-indicator {
  position: absolute;
  top: 3px;
  left: 0;
  height: 30px;
  background: var(--tab-pill-bg);
  border-radius: 48px;
  transition: transform var(--duration-fast) var(--ease-smooth),
              width var(--duration-fast) var(--ease-smooth);
  will-change: transform, width;
  z-index: 0;
  pointer-events: none;
}

/* ---------- Panels ---------- */
.panel-content {
  width: 100%;
}

.panel-content.sf-hidden {
  display: none !important;
}

/* ---------- Hero Section ---------- */
.hero-section {
  text-align: center;
  padding: 1px 20px 40px;
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  grid-column: 1 / -1;
}

.hero-title {
  font-size: 48px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 16px;
  letter-spacing: -1px;
  line-height: 1.1;
}

.hero-subtitle {
  font-size: 18px;
  color: var(--text-muted);
  max-width: 600px;
  line-height: 1.5;
}

.hero-buttons {
  display: flex;
  gap: 16px;
}

.btn {
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  font-size: 15px;
  display: inline-block;
  transition: opacity 0.15s ease;
}

.btn:hover {
  opacity: 0.85;
}

.btn:focus,
.btn:focus-visible {
  outline: none;
  box-shadow: none;
}

.btn::-moz-focus-inner {
  border: 0;
}

.btn-primary {
  background: var(--text);
  color: var(--bg);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--stage-border);
}

/* ---------- Feature Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 320px);
  justify-content: center;
  gap: 24px;
  align-items: start;
}

.card {
  position: relative;
  width: 320px;
  height: 344px;
  border-radius: 24px;
  border: 1px solid var(--card-border);
  border-top: 2px solid var(--stage-border);
  outline: none;
  background-color: #181818;
}

.card:hover {
  background-color: #181818;
}

.card:focus,
.card:focus-visible {
  outline: none;
  box-shadow: none;
}

.card::-moz-focus-inner {
  border: 0;
}

.card-stage {
  position: absolute;
  left: 12px;
  top: 12px;
  width: 296px;
  max-width: calc(100% - 24px);
  height: 260px;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #131313;
}

.card-stage::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 10;
}

.stage-inner {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-meta {
  position: absolute;
  left: var(--card-pad-x);
  bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.card-title {
  font-size: 13px;
  font-weight: 500;
  line-height: 18px;
  color: #ededed;
}

.card-subtitle {
  font-size: 13px;
  font-weight: 400;
  line-height: 13px;
  color: #767676;
}

/* ---------- Discord Embed Mock ---------- */
.discord-mock {
  background-color: var(--stage-bg);
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  color: var(--text);
  width: 280px;
  border-radius: 8px;
  padding: 12px;
  font-family: var(--font-sans);
  text-align: left;
  font-size: 11px;
}

.discord-header {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 6px;
}

.discord-avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

.discord-username {
  color: var(--text);
  font-weight: 600;
}

.discord-badge {
  background-color: var(--text);
  color: var(--bg);
  font-size: 8px;
  font-weight: 600;
  padding: 1px 3px;
  border-radius: 3px;
  text-transform: uppercase;
}

.discord-timestamp {
  color: var(--text-muted);
  font-size: 9px;
  margin-left: 2px;
}

.discord-embed {
  background-color: var(--card-bg);
  border-left: 3px solid var(--text);
  border-radius: 4px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.discord-embed-source {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.discord-embed-title {
  color: var(--text);
  font-weight: 600;
  text-decoration: none;
  font-size: 12px;
}

.discord-embed-desc {
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.4;
  margin-top: 2px;
}

/* ---------- Commands Mock ---------- */
.commands-mock {
  background-color: var(--stage-bg);
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  width: 280px;
  border-radius: 8px;
  padding: 12px;
  font-family: var(--font-sans);
  text-align: left;
  font-size: 11px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.commands-header {
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  font-size: 9px;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--stage-border);
  padding-bottom: 4px;
}

.commands-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.command-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--card-bg);
  padding: 6px 8px;
  border-radius: 4px;
}

.command-row--highlight {
  border: 1px solid var(--stage-border);
}

.command-name {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
}

.command-desc {
  color: var(--text-muted);
  font-size: 9px;
}

/* ---------- Sources Cloud ---------- */
.sources-cloud {
  width: 280px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  align-content: center;
  height: 100%;
}

.source-pill {
  background: var(--chip-bg);
  color: var(--text);
  border: 1px solid var(--stage-border);
  padding: 4px 12px;
  border-radius: 27px;
  font-size: 13px;
  font-weight: 500;
}

/* ---------- Stats Section ---------- */
.stats-section {
  display: flex;
  justify-content: center;
  gap: 32px;
  width: 100%;
  max-width: 960px;
  margin: 0 auto 56px;
  flex-wrap: wrap;
}

.stat-card {
  flex: 1 1 200px;
  max-width: 280px;
  background: var(--card-bg);
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  border-radius: 16px;
  padding: 20px;
  text-align: center;
}

.stat-value {
  font-size: 32px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.5px;
}

.stat-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ---------- Section Layouts ---------- */
.section-container {
  width: 100%;
  max-width: 960px;
  margin: 64px auto 0;
  text-align: center;
}

.section-title {
  font-size: 20px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 32px;
  letter-spacing: -0.3px;
}

/* ---------- Step Guide ---------- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: left;
}

.step-card {
  background: var(--card-bg);
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  border-radius: 16px;
  padding: 28px 24px;
  position: relative;
  transition: none;
  outline: none;
  box-shadow: none;
}

.step-card:hover,
.step-card:focus,
.step-card:focus-visible {
  border-color: var(--stage-border);
  outline: none;
  box-shadow: none;
  transform: none;
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--chip-bg);
  border: 1px solid var(--stage-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
}

.step-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.step-desc {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}

/* ---------- FAQ Accordion ---------- */
.faq-list {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
}

.faq-item {
  background: var(--card-bg);
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color var(--duration-fast) var(--ease-smooth);
}

.faq-item:hover,
.faq-item:focus,
.faq-item:focus-visible {
  border-color: var(--stage-border);
  outline: none;
  box-shadow: none;
}

.faq-trigger {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.faq-trigger,
.faq-trigger:hover,
.faq-trigger:focus,
.faq-trigger:focus-visible,
.faq-trigger:active {
  outline: none;
  box-shadow: none;
  border: none;
}

.faq-trigger::-moz-focus-inner {
  border: 0;
}

.faq-arrow {
  color: var(--text-muted);
  transition: transform 0.25s var(--ease-smooth);
}

.faq-trigger[aria-expanded="true"] .faq-arrow {
  transform: rotate(180deg);
}

.faq-answer-panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.25s var(--ease-smooth);
}

.faq-trigger[aria-expanded="true"] + .faq-answer-panel {
  grid-template-rows: 1fr;
}

.faq-answer-content {
  overflow: hidden;
}

.faq-answer-content p {
  padding: 0 20px 16px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Document Panels (ToS / Privacy) ---------- */
.doc-panel {
  max-width: 960px;
  margin: 0 auto;
}

.doc-container {
  background: var(--card-bg);
  border-radius: 24px;
  padding: 40px;
  border: 1px solid var(--stage-border);
  border-top: 2px solid var(--stage-border);
  text-align: left;
}

.doc-heading {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 24px;
  color: var(--text);
}

.doc-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.doc-text h3 {
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  margin-top: 10px;
}

.doc-text p {
  margin-bottom: 4px;
}

.doc-text ul {
  padding-left: 20px;
  list-style-type: disc;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.doc-text code {
  font-family: var(--font-mono);
  background: var(--chip-bg);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
}


/* ---------- Site Footer (Cosmos-inspired) ---------- */
.site-footer {
  width: 100%;
  margin-top: 120px;
  padding-top: 80px;
  border-top: 1px solid var(--stage-border);
  font-family: var(--font-sans);
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 320px;
}

.footer-logo {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.footer-logo-img {
  width: 32px;
  height: 32px;
  display: block;
  user-select: none;
  pointer-events: none;
}

.footer-desc {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-muted);
  font-weight: 400;
}

.footer-links-grid {
  display: flex;
  gap: 80px;
}

.footer-links-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-col-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-subtle);
}

.footer-links-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links-list a {
  font-size: 14px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--duration-fast) var(--ease-smooth);
}

.footer-links-list a:hover {
  color: var(--text);
}

.footer-bottom {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  overflow: hidden;
  margin-bottom: -64px; /* Pull it down to sit flush with the bottom of .app */
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.footer-huge-text {
  font-size: 16vw;
  font-weight: 900;
  line-height: 0.8;
  margin-bottom: -0.16em; /* Cuts off the bottom of the letters at the bottom edge */
  color: rgba(255, 255, 255, 0.08);
  letter-spacing: -0.04em;
  text-align: center;
  user-select: none;
  width: 100%;
  white-space: nowrap;
  display: block;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .cards {
    grid-template-columns: repeat(2, 320px);
  }
}

@media (max-width: 700px) {
  .cards {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin: 0 auto;
  }

  .steps-grid {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin: 0 auto;
    gap: 16px;
  }

  .hero-title {
    font-size: 32px;
  }

  .hero-subtitle {
    font-size: 16px;
  }

  .hero-buttons {
    flex-direction: column;
    align-items: center;
  }

  .top-bar {
    right: 16px;
    top: 12px;
    gap: 6px;
  }

  .pill-btn {
    padding: 0 10px;
    height: 32px;
    font-size: 12px;
  }

  .footer-top {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 40px;
  }
  
  .footer-brand {
    align-items: center;
    max-width: 100%;
  }
  
  .footer-logo {
    justify-content: center;
  }
  
  .footer-links-grid {
    flex-direction: column;
    gap: 32px;
    width: 100%;
    align-items: center;
  }
  
  .footer-links-col {
    align-items: center;
  }
  
  .footer-links-list {
    align-items: center;
  }

}