  :root {
    --sky: #54C5F8;
    --sky-dim: #2a9fd8;
    --navy: #1A237E;
    --bg: #0D1117;
    --bg-elev: #11161E;
    --bg-card: #131A23;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.14);
    --text: #E6EDF3;
    --text-dim: #8B949E;
    --text-faint: #6E7681;
  }

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

  html, body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.5;
  }

  body {
    overflow-x: hidden;
  }

  a { color: inherit; text-decoration: none; }
  button { font-family: inherit; cursor: pointer; }

  .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
  }

  /* ======== NAV ======== */
  nav.topnav {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    background: rgba(13, 17, 23, 0.72);
    border-bottom: 1px solid var(--line);
  }
  .topnav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
  }
  .brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 15px;
    letter-spacing: -0.01em;
  }
  .brand-mark {
    width: 32px;
    height: 24px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
    display: block;
  }
  .brand-name {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 500;
    font-size: 14px;
    color: var(--text);
  }
  .brand-name .accent { color: var(--sky); }

  .nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
    font-size: 14px;
    color: var(--text-dim);
  }
  .nav-links a:hover { color: var(--text); }
  .nav-links .gh-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text);
  }
  .version-badge {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    padding: 3px 8px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    color: var(--text-dim);
  }

  /* ======== HERO ======== */
  .hero {
    position: relative;
    padding: 120px 0 100px;
    overflow: hidden;
  }
  .hero-grid-bg {
    position: absolute;
    inset: 0;
    background-image:
      radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.06) 1px, transparent 0);
    background-size: 32px 32px;
    mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black 30%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black 30%, transparent 80%);
    pointer-events: none;
  }
  .hero-glow {
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 900px;
    height: 600px;
    background: radial-gradient(ellipse at center, rgba(84, 197, 248, 0.18) 0%, rgba(26, 35, 126, 0.08) 35%, transparent 70%);
    filter: blur(40px);
    pointer-events: none;
  }
  .hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
  }

  .eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px 6px 6px;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-dim);
    margin-bottom: 32px;
  }
  .eyebrow .pill {
    background: var(--sky);
    color: var(--bg);
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 10px;
    letter-spacing: 0.04em;
    padding: 3px 8px;
    border-radius: 999px;
    text-transform: uppercase;
  }

  h1.hero-headline {
    font-size: clamp(40px, 6vw, 76px);
    line-height: 0.98;
    letter-spacing: -0.035em;
    font-weight: 700;
    margin-bottom: 24px;
  }
  h1.hero-headline .accent {
    color: var(--sky);
  }
  h1.hero-headline .ext {
    display: block;
    color: var(--text-dim);
    font-weight: 500;
  }

  .hero-sub {
    font-size: 19px;
    line-height: 1.55;
    color: var(--text-dim);
    max-width: 520px;
    margin-bottom: 40px;
  }

  .cta-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 40px;
  }

  .btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 22px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    border: 1px solid transparent;
    transition: transform 0.12s ease, background 0.12s ease, border-color 0.12s ease;
    text-decoration: none;
  }
  .btn:hover { transform: translateY(-1px); }
  .btn:active { transform: translateY(0); }

  .btn-primary {
    background: var(--sky);
    color: #062231;
  }
  .btn-primary:hover { background: #6CCFFA; }
  .btn-primary svg { stroke: #062231; }

  .btn-secondary {
    background: transparent;
    color: var(--text);
    border-color: var(--line-strong);
  }
  .btn-secondary:hover { border-color: rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.03); }

  .hero-meta {
    display: flex;
    gap: 28px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-faint);
  }
  .hero-meta span strong {
    color: var(--text);
    font-weight: 500;
    margin-right: 6px;
  }

  /* Hero right — code window + tv silhouette */
  .hero-visual {
    position: relative;
    aspect-ratio: 5 / 4;
    width: 100%;
  }
  .tv-frame {
    position: absolute;
    inset: 0;
    border: 1px solid var(--line-strong);
    border-radius: 14px;
    background: linear-gradient(180deg, #0F1620 0%, #0A0E14 100%);
    overflow: hidden;
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(84, 197, 248, 0.05);
  }
  .tv-titlebar {
    height: 36px;
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    padding: 0 14px;
    gap: 8px;
    background: rgba(255, 255, 255, 0.015);
  }
  .tv-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
  }
  .tv-titlebar .filename {
    margin-left: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-faint);
  }
  .tv-content {
    padding: 24px 26px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13.5px;
    line-height: 1.85;
  }
  .code-line { display: flex; gap: 18px; }
  .code-num {
    color: var(--text-faint);
    opacity: 0.5;
    width: 16px;
    text-align: right;
    user-select: none;
  }
  .code-content { flex: 1; min-width: 0; }
  .tk-key { color: #FF7B72; }
  .tk-cls { color: var(--sky); }
  .tk-fn  { color: #D2A8FF; }
  .tk-str { color: #A5D6A6; }
  .tk-com { color: var(--text-faint); font-style: italic; }
  .tk-num { color: #79C0FF; }
  .tk-pn  { color: var(--text-dim); }
  .indent { display: inline-block; width: 1em; }

  .cursor {
    display: inline-block;
    width: 7px;
    height: 14px;
    background: var(--sky);
    vertical-align: -2px;
    margin-left: 2px;
    animation: blink 1.1s steps(2) infinite;
  }
  @keyframes blink { 50% { opacity: 0; } }

  /* Floating apple-tv silhouette badge */
  .tv-badge {
    position: absolute;
    bottom: -24px;
    right: -24px;
    width: 160px;
    height: 116px;
    background: var(--bg-card);
    border: 1px solid var(--line-strong);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.5);
  }
  .tv-badge img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }

  /* ======== SECTION HEADER ======== */
  .section {
    padding: 120px 0;
    position: relative;
  }
  .section-divider {
    border-top: 1px solid var(--line);
  }
  .section-tag {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--sky);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 18px;
  }
  .section-tag::before {
    content: '';
    width: 24px;
    height: 1px;
    background: var(--sky);
  }
  .section-title {
    font-size: clamp(32px, 4vw, 44px);
    line-height: 1.05;
    letter-spacing: -0.025em;
    font-weight: 700;
    max-width: 720px;
    margin-bottom: 16px;
  }
  .section-lead {
    font-size: 17px;
    color: var(--text-dim);
    max-width: 600px;
    margin-bottom: 64px;
  }

  /* ======== FEATURES ======== */
  .features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
  }
  .feature-card {
    background: var(--bg);
    padding: 36px 28px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    transition: background 0.18s ease;
  }
  .feature-card:hover { background: var(--bg-elev); }

  .feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: rgba(84, 197, 248, 0.08);
    border: 1px solid rgba(84, 197, 248, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sky);
  }
  .feature-title {
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.01em;
  }
  .feature-desc {
    font-size: 14px;
    line-height: 1.55;
    color: var(--text-dim);
    flex: 1;
  }
  .feature-tag {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--text-faint);
    margin-top: auto;
  }

  /* ======== TEAM ======== */
  .team-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    max-width: 880px;
  }
  .team-card {
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 36px;
    background: var(--bg-elev);
    transition: border-color 0.18s ease;
    display: flex;
    flex-direction: column;
    gap: 24px;
  }
  .team-card:hover { border-color: var(--line-strong); }

  .team-row {
    display: flex;
    align-items: center;
    gap: 20px;
  }
  .avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(84, 197, 248, 0.25), rgba(26, 35, 126, 0.4));
    border: 1px solid var(--line-strong);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 22px;
    color: var(--sky);
    letter-spacing: 0.02em;
    flex-shrink: 0;
    overflow: hidden;
  }
  .avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }
  .team-name {
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 4px;
  }
  .team-role {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.45;
  }
  .team-contrib {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-faint);
    padding-top: 20px;
    border-top: 1px solid var(--line);
    line-height: 1.7;
  }
  .team-contrib .label {
    display: block;
    color: var(--sky);
    margin-bottom: 6px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
  }
  .team-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text-dim);
    margin-top: 4px;
    transition: color 0.15s ease;
  }
  .team-link:hover { color: var(--sky); }

  /* ======== GET STARTED ======== */
  .install-block {
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--bg-elev);
    overflow: hidden;
    margin-bottom: 56px;
  }
  .install-tabs {
    display: flex;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.015);
  }
  .install-tab {
    padding: 14px 22px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-faint);
    border-right: 1px solid var(--line);
    background: transparent;
    border-top: none;
    border-bottom: none;
    border-left: none;
    transition: color 0.15s ease;
  }
  .install-tab.active {
    color: var(--text);
    background: var(--bg);
    border-bottom: 1px solid var(--bg);
    margin-bottom: -1px;
    position: relative;
  }
  .install-tab.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--sky);
  }
  .install-body {
    padding: 28px 32px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
  }
  .install-cmd {
    font-family: 'JetBrains Mono', monospace;
    font-size: 15px;
    color: var(--text);
    overflow-x: auto;
    line-height: 1.9;
    white-space: pre;
    flex: 1;
    min-width: 0;
  }
  .install-cmd .prompt { color: var(--sky); margin-right: 12px; user-select: none; }
  .install-cmd .arg { color: var(--text-dim); }
  .install-cmd .com { color: var(--text-faint); font-style: italic; }
  .copy-btn {
    background: transparent;
    border: 1px solid var(--line-strong);
    color: var(--text-dim);
    border-radius: 6px;
    padding: 8px 14px;
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.15s ease;
    flex-shrink: 0;
  }
  .copy-btn:hover { color: var(--text); border-color: var(--text-dim); }

  .links-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
  }
  .link-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 22px 24px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--bg-elev);
    transition: all 0.18s ease;
  }
  .link-card:hover {
    border-color: var(--sky);
    background: rgba(84, 197, 248, 0.03);
    transform: translateY(-2px);
  }
  .link-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .link-card-icon {
    width: 28px;
    height: 28px;
    color: var(--text-dim);
  }
  .link-card:hover .link-card-icon { color: var(--sky); }
  .link-card-arrow {
    width: 14px;
    height: 14px;
    color: var(--text-faint);
    transition: transform 0.15s ease;
  }
  .link-card:hover .link-card-arrow {
    transform: translate(2px, -2px);
    color: var(--sky);
  }
  .link-card-name {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.01em;
  }
  .link-card-desc {
    font-size: 12px;
    color: var(--text-faint);
    font-family: 'JetBrains Mono', monospace;
  }

  /* ======== FOOTER ======== */
  footer {
    border-top: 1px solid var(--line);
    padding: 56px 0 64px;
    margin-top: 60px;
  }
  .footer-inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
  }
  .footer-disclaimer {
    font-size: 13px;
    color: var(--text-faint);
    max-width: 520px;
    line-height: 1.6;
  }
  .footer-disclaimer .lic {
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    margin-top: 12px;
    color: var(--text-faint);
    opacity: 0.7;
    display: block;
  }
  .footer-meta {
    text-align: right;
    font-size: 12px;
    color: var(--text-faint);
    font-family: 'JetBrains Mono', monospace;
    line-height: 1.8;
  }
  /* ======== RESPONSIVE ======== */
  @media (max-width: 980px) {
    .hero { padding: 80px 0 60px; }
    .hero-inner {
      grid-template-columns: 1fr;
      gap: 60px;
    }
    .hero-visual { max-width: 520px; }
    .features-grid {
      grid-template-columns: repeat(2, 1fr);
    }
    /* With an odd number of cards the last row would otherwise show the grid's
       own background as an empty half-panel beside the last card. */
    .features-grid .feature-card:last-child:nth-child(odd) {
      grid-column: 1 / -1;
    }
    .team-grid {
      grid-template-columns: 1fr;
    }
    .links-grid {
      grid-template-columns: repeat(2, 1fr);
    }
    .section { padding: 80px 0; }
  }

  @media (max-width: 600px) {
    .container { padding: 0 20px; }
    .nav-links { gap: 16px; }
    .nav-links .hide-sm { display: none; }
    .features-grid { grid-template-columns: 1fr; }
    .links-grid { grid-template-columns: 1fr; }
    .install-body {
      flex-direction: column;
      align-items: stretch;
    }
    .install-cmd { font-size: 13px; }
    .tv-badge { width: 96px; height: 96px; bottom: -16px; right: -16px; }
    .tv-badge svg { width: 44px; height: 44px; }
    .hero-meta { flex-wrap: wrap; gap: 14px; }
    .footer-inner { flex-direction: column; }
    .footer-meta { text-align: left; }
  }

  /* Inline code spans. These were repeated inline styles in the hand-written
     page; the sizes are the ones each context shipped with. */
  code.c {
    font-family: 'JetBrains Mono', monospace;
    color: var(--sky);
  }
  code.c-12 { font-size: 12.5px; }
  code.c-14 { font-size: 14px; }
  code.c-15 { font-size: 15px; }

  /* The pub.dev publisher link inside a feature card. */
  .pub-link {
    color: var(--sky);
    text-decoration: none;
    border-bottom: 1px dotted var(--sky);
  }

  /* The Codemagic wordmark in the footer, from their press kit. */
  .codemagic-link {
    display: inline-flex;
    align-items: center;
    vertical-align: middle;
    opacity: 0.75;
    transition: opacity 0.2s ease;
  }
  .codemagic-link:hover { opacity: 1; }
  .codemagic-logo {
    height: 13px;
    width: auto;
    display: block;
  }
