/* =========================================
   1. VARIABLES & THEMING
   ========================================= */
:root {
  --paper:   #F7F1DE;
  --ink:     #1B2540;
  --saffron: #C4801A;
  --muted:   #6A655F;
  --rule:    #DDD5C8;
  --card:    #F0EBE2;
  --card-dk: #E5DDD2;
  --snow:    #FDFAF5;
  --nav-bg:  rgba(247,241,222,0.94);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #17130F; --ink: #F3EADC; --saffron: #D99A3C;
    --muted: #A89C8C; --rule: #352E26; --card: #1F1A14;
    --card-dk: #2A241C; --snow: #0F0C09;
    --nav-bg: rgba(23,19,15,0.94);
  }
}
:root[data-theme="dark"] {
  --paper: #17130F; --ink: #F3EADC; --saffron: #D99A3C;
  --muted: #A89C8C; --rule: #352E26; --card: #1F1A14;
  --card-dk: #2A241C; --snow: #0F0C09;
  --nav-bg: rgba(23,19,15,0.94);
}

/* =========================================
   2. GLOBAL STYLES
   ========================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  transition: background .3s, color .3s;
}

/* Faint ruled-paper lines across the whole page */
body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: repeating-linear-gradient(
    transparent, transparent 27px,
    rgba(160,148,132,0.10) 27px, rgba(160,148,132,0.10) 28px
  );
  pointer-events: none;
  z-index: 0;
}

.z1 { position: relative; z-index: 1; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 48px; }

/* =========================================
   3. NAVIGATION
   ========================================= */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  padding: 18px 48px;
  display: flex; justify-content: space-between; align-items: center;
  background: var(--nav-bg);
  backdrop-filter: blur(10px);
  border-bottom: 0.5px solid var(--rule);
}
.nav-logo { display: flex; align-items: baseline; gap: 10px; text-decoration: none; }
.nav-logo-dev { font-family: 'Noto Sans Devanagari'; font-size: 20px; font-weight: 400; color: var(--ink); }
.nav-logo-sub { font-family: 'Cormorant Garamond'; font-size: 12.5px; font-weight: 400; color: var(--muted); letter-spacing: 0.08em; }

.nav-right { display: flex; align-items: center; gap: 28px; }
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; }
.nav-links a { font-size: 11px; font-weight: 400; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.nav-links a:hover { color: var(--ink); }

.nav-contact { font-size: 11px; letter-spacing: 0.06em; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.nav-contact:hover { color: var(--saffron); }

.nav-links .nav-cta { padding: 7px 16px; border: 1px solid var(--saffron); color: var(--saffron); border-radius: 2px; transition: background 0.2s, color 0.2s; }
.nav-links .nav-cta:hover { background: var(--saffron); color: var(--paper); }

/* Theme Toggle */
.theme-toggle {
  width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--rule); border-radius: 50%;
  color: var(--muted); cursor: pointer; transition: color .2s, border-color .2s;
}
.theme-toggle:hover { color: var(--saffron); border-color: var(--saffron); }
.theme-toggle:focus-visible { outline: 2px solid var(--saffron); outline-offset: 2px; }
.theme-toggle svg { width: 16px; height: 16px; display: block; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 130px 48px 80px;
  max-width: 1100px; margin: 0 auto;
  position: relative; z-index: 1;
}
.hero-glyph {
  font-family: 'Noto Sans Devanagari'; font-weight: 300; font-size: clamp(220px, 34vw, 440px);
  color: var(--ink); opacity: 0.045; position: absolute; top: 46%; left: 50%;
  transform: translate(-50%, -50%); line-height: 1; pointer-events: none; user-select: none; z-index: 0;
}
:root[data-theme="dark"] .hero-glyph { color: rgba(243,234,220,0.14); }

.hero-scripts { margin-bottom: 28px; position: relative; z-index: 1; }
.hero-dev { font-family: 'Noto Sans Devanagari'; font-weight: 300; font-size: clamp(64px, 11vw, 128px); color: var(--ink); line-height: 0.95; letter-spacing: -0.02em; display: block; }
.hero-tam { font-family: 'Noto Sans Tamil'; font-weight: 300; font-size: clamp(44px, 7vw, 84px); color: var(--muted); line-height: 1; display: block; margin-top: 4px; }
.hero-latin { font-family: 'Cormorant Garamond'; font-size: 12.5px; font-weight: 400; letter-spacing: 0.3em; text-transform: uppercase; color: var(--saffron); display: block; margin-top: 18px; }
.hero-rule { width: 40px; height: 1.5px; background: var(--saffron); margin: 26px 0; position: relative; z-index: 1; }
.hero-tagline { font-family: 'Cormorant Garamond'; font-size: clamp(20px, 2.6vw, 29px); font-weight: 300; font-style: italic; color: var(--ink); max-width: 460px; line-height: 1.4; margin-bottom: 18px; position: relative; z-index: 1; }
.hero-body { font-size: 14px; color: var(--muted); max-width: 460px; line-height: 1.85; margin-bottom: 34px; position: relative; z-index: 1; }

.ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.btn-d { display: inline-block; padding: 11px 26px; background: var(--ink); color: var(--snow); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; border: 1px solid var(--ink); border-radius: 2px; transition: background 0.2s, color 0.2s; }
.btn-d:hover { background: transparent; color: var(--ink); }
.btn-o { display: inline-block; padding: 11px 26px; background: transparent; color: var(--saffron); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; border: 1px solid var(--saffron); border-radius: 2px; transition: background 0.2s, color 0.2s; }
.btn-o:hover { background: var(--saffron); color: var(--paper); }
.hero-scroll { position: absolute; bottom: 36px; left: 48px; display: flex; align-items: center; gap: 10px; font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.hero-scroll::before { content: ''; display: block; width: 28px; height: 1px; background: var(--muted); }

/* =========================================
   5. EMAIL CAPTURE (Coming Soon Page)
   ========================================= */
.notify { position: relative; z-index: 1; }
.notify-form { display: flex; gap: 10px; flex-wrap: wrap; max-width: 440px; }
.notify-input {
  flex: 1; min-width: 200px; padding: 12px 16px; background: var(--snow);
  border: 1px solid var(--rule); border-radius: 2px; color: var(--ink);
  font-family: 'Inter', sans-serif; font-size: 13px; font-weight: 400;
}
.notify-input:focus { outline: 2px solid var(--saffron); outline-offset: 1px; border-color: var(--saffron); }
.notify-btn {
  padding: 12px 24px; background: var(--ink); color: var(--snow); border: 1px solid var(--ink);
  font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; border-radius: 2px;
  cursor: pointer; transition: background .2s, color .2s;
}
.notify-btn:hover { background: transparent; color: var(--ink); }
.notify-btn:focus-visible { outline: 2px solid var(--saffron); outline-offset: 2px; }
.notify-note { font-size: 11.5px; color: var(--muted); margin-top: 12px; }
.notify-note a { color: var(--saffron); text-decoration: none; }
.notify-note a:hover { text-decoration: underline; }
.notify-done { display: none; align-items: center; gap: 10px; font-size: 13.5px; color: var(--ink); }
.notify-done.on { display: flex; }
.notify-form.off { display: none; }
.notify-check { width: 17px; height: 17px; border-radius: 50%; background: var(--saffron); display: flex; align-items: center; justify-content: center; color: var(--snow); font-size: 10px; flex-shrink: 0; }

/* =========================================
   6. STATS BAR
   ========================================= */
.stats-bar {
  background: var(--card);
  border-bottom: 0.5px solid var(--rule);
  border-top: 0.5px solid var(--rule);
  padding: 14px 0;
  position: relative; z-index: 1;
}
.stats-inner {
  display: flex; align-items: center; gap: 0;
  flex-wrap: wrap;
}
.stat-item {
  display: flex; align-items: baseline; gap: 8px;
  padding: 0 28px; border-right: 0.5px solid var(--rule);
}
.stat-item:first-child { padding-left: 0; }
.stat-item:last-child { border-right: none; }
.stat-num { font-family: 'Cormorant Garamond'; font-size: 22px; font-weight: 400; color: var(--ink); }
.stat-label { font-size: 10px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); }
.stat-live { display: flex; align-items: center; gap: 6px; margin-left: auto; font-size: 10px; color: var(--muted); letter-spacing: 0.06em; }
.stat-dot { width: 6px; height: 6px; border-radius: 50%; background: #5B9B6A; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.4} }

/* =========================================
   7. GENERAL SECTIONS
   ========================================= */
section { padding: 88px 0; position: relative; z-index: 1; }
.s-rule { width: 100%; height: 0.5px; background: var(--rule); margin-bottom: 60px; }
.s-label { font-size: 10px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--saffron); display: block; margin-bottom: 14px; }
.s-title { font-family: 'Cormorant Garamond'; font-size: clamp(30px, 3.5vw, 46px); font-weight: 300; line-height: 1.15; margin-bottom: 20px; }
.s-body { font-size: 14.5px; color: var(--muted); max-width: 620px; line-height: 1.85; }

.about-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 80px; align-items: start; }
.about-left { position: sticky; top: 100px; }
.about-deco { font-family: 'Noto Sans Devanagari'; font-size: 100px; font-weight: 300; color: rgba(27,37,64,0.055); line-height: 1; margin-bottom: -10px; user-select: none; }
:root[data-theme="dark"] .about-deco { color: rgba(243,234,220,0.055); }
.about-right p + p { margin-top: 16px; }

/* =========================================
   8. STREAMS
   ========================================= */
.streams { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 48px; }
.stream-card { background: var(--card); padding: 36px; border-radius: 3px; border-top: 2px solid; }
.stream-a { border-color: var(--saffron); }
.stream-b { border-color: var(--ink); }
.stream-alpha { font-family: 'Cormorant Garamond'; font-size: 56px; font-weight: 300; color: rgba(27,37,64,0.10); line-height: 1; margin-bottom: 14px; }
:root[data-theme="dark"] .stream-alpha { color: rgba(243,234,220,0.10); }

/* Coming Soon specific headers */
.stream-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.stream-status { font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }

.stream-title { font-family: 'Cormorant Garamond'; font-size: 19px; font-weight: 600; margin-bottom: 8px; }
.stream-desc { font-size: 12.5px; color: var(--muted); line-height: 1.75; margin-bottom: 22px; }
.tags { display: flex; flex-wrap: wrap; gap: 7px; }
.tag { font-size: 9.5px; letter-spacing: 0.07em; text-transform: uppercase; font-weight: 500; padding: 3px 9px; background: var(--card-dk); border-radius: 2px; color: var(--ink); }

/* =========================================
   9. HARDCODED DARK SECTIONS
   ========================================= */
/* Numbers band */
.nums-band { background: #1B2540; padding: 64px 0; position: relative; z-index: 1; }
.nums-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.num-item { text-align: center; padding: 20px 16px; border-left: 0.5px solid rgba(255,255,255,0.08); }
.num-item:first-child { border-left: none; }
.num-val { font-family: 'Cormorant Garamond'; font-size: 56px; font-weight: 300; color: #FDFAF5; line-height: 1; display: block; }
.num-label { font-size: 10px; letter-spacing: 0.09em; text-transform: uppercase; color: rgba(255,255,255,0.38); margin-top: 8px; display: block; }

/* Dark Access Card */
.access-dark { background: #1B2540; border-color: #1B2540; }
.a-badge-dark { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.6); }
.access-dark .a-title { color: #FDFAF5; }
.access-dark .a-sub { color: rgba(255,255,255,0.4); }
.access-dark .a-list li { border-color: rgba(255,255,255,0.07); color: rgba(255,255,255,0.7); }

/* =========================================
   10. TEXTS LIBRARY
   ========================================= */
.texts-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 52px; margin-top: 48px; }
.col-head { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 0.5px solid var(--rule); }
.col-script { font-size: 36px; line-height: 1; }
.col-title { font-family: 'Cormorant Garamond'; font-size: 20px; font-weight: 600; }
.col-sub { font-size: 10px; color: var(--muted); letter-spacing: 0.07em; text-transform: uppercase; margin-top: 2px; }
.text-row { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 16px; padding: 11px 0; border-bottom: 0.5px solid var(--rule); }
.text-row:last-child { border-bottom: none; }
.t-name { font-size: 13.5px; font-weight: 400; }
.t-name em { font-style: italic; font-family: 'Cormorant Garamond'; font-size: 15px; }
.t-kind { font-size: 10px; color: var(--muted); letter-spacing: 0.05em; text-transform: uppercase; margin-top: 1px; }
.t-period { font-size: 11px; color: var(--muted); white-space: nowrap; }

/* =========================================
   11. ACCESS & FORMS
   ========================================= */
.access-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 48px; }
.access-card { padding: 38px; border-radius: 3px; border: 0.5px solid var(--rule); }
.a-badge { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 500; padding: 4px 10px; border-radius: 2px; display: inline-block; margin-bottom: 18px; }
.a-badge-light { background: var(--card-dk); color: var(--ink); }
.a-title { font-family: 'Cormorant Garamond'; font-size: 26px; font-weight: 400; margin-bottom: 6px; }
.a-sub { font-size: 12px; color: var(--muted); margin-bottom: 26px; }
.a-list { list-style: none; margin-bottom: 28px; }
.a-list li { font-size: 13px; padding: 8px 0; border-bottom: 0.5px solid var(--rule); display: flex; align-items: center; gap: 10px; }
.a-list li::before { content: '·'; color: var(--saffron); font-size: 11px; flex-shrink: 0; }

.request-band { background: var(--card); padding: 88px 0; position: relative; z-index: 1; }
.request-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.req-step { display: flex; gap: 20px; margin-bottom: 28px; }
.req-num { font-family: 'Cormorant Garamond'; font-size: 32px; font-weight: 300; color: var(--saffron); line-height: 1; min-width: 26px; padding-top: 2px; }
.req-t { font-size: 14px; font-weight: 500; margin-bottom: 4px; }
.req-d { font-size: 13px; color: var(--muted); line-height: 1.7; }
.terms-box { margin-top: 32px; padding: 22px 24px; border: 0.5px solid var(--rule); border-radius: 3px; background: var(--paper); }
.terms-box h4 { font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--saffron); margin-bottom: 14px; }
.terms-box ul { list-style: none; }
.terms-box li { font-size: 12px; color: var(--muted); padding: 5px 0 5px 14px; position: relative; line-height: 1.6; }
.terms-box li::before { content: '·'; position: absolute; left: 0; color: var(--saffron); }

/* =========================================
   12. TEAM & ANANTA
   ========================================= */
.team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.team-card { padding: 28px; background: var(--card); border-radius: 3px; border: 0.5px solid var(--rule); }
.team-role { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--saffron); margin-bottom: 10px; }
.team-name { font-family: 'Cormorant Garamond'; font-size: 20px; font-weight: 400; margin-bottom: 6px; }
.team-desc { font-size: 12px; color: var(--muted); line-height: 1.7; }
.team-join { padding: 28px; background: transparent; border: 0.5px dashed var(--rule); border-radius: 3px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.team-join-label { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.team-join-title { font-family: 'Cormorant Garamond'; font-size: 18px; font-weight: 300; color: var(--ink); margin-bottom: 10px; line-height: 1.3; }

.ananta-grid { display: grid; grid-template-columns: 160px 1fr; gap: 64px; align-items: center; }
.ananta-glyph { font-family: 'Noto Sans Devanagari'; font-size: 120px; font-weight: 300; color: rgba(27,37,64,0.065); line-height: 1; text-align: center; user-select: none; }
:root[data-theme="dark"] .ananta-glyph { color: rgba(243,234,220,0.065); }
.ananta-quote { font-family: 'Cormorant Garamond'; font-size: clamp(18px, 2vw, 23px); font-style: italic; font-weight: 300; line-height: 1.55; color: var(--ink); border-left: 2px solid var(--saffron); padding-left: 24px; margin-bottom: 22px; }

/* =========================================
   13. FOOTER
   ========================================= */
footer { padding: 36px 0; border-top: 0.5px solid var(--rule); position: relative; z-index: 1; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; }
.footer-mark { display: flex; align-items: baseline; gap: 10px; }
.footer-dev { font-family: 'Noto Sans Devanagari'; font-size: 18px; color: var(--ink); }
.footer-tam { font-family: 'Noto Sans Tamil'; font-size: 16px; color: var(--muted); }
.footer-dom { font-family: 'Cormorant Garamond'; font-size: 13px; color: var(--muted); letter-spacing: 0.07em; margin-left: 6px; }
.footer-nav { display: flex; gap: 22px; list-style: none; }
.footer-nav a { font-size: 11px; color: var(--muted); text-decoration: none; letter-spacing: 0.04em; transition: color 0.2s; }
.footer-nav a:hover { color: var(--saffron); }
.footer-copy { font-size: 10px; color: rgba(106,101,95,0.55); letter-spacing: 0.03em; }
.footer-controls { display: flex; align-items: center; gap: 16px; }

/* =========================================
   14. UTILITIES & ANIMATIONS
   ========================================= */
.fi { opacity: 0; transform: translateY(18px); transition: opacity 0.65s ease, transform 0.65s ease; }
.fi.vis { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) { .fi { opacity: 1; transform: none; transition: none; } }

/* =========================================
   15. MOBILE
   ========================================= */
@media (max-width: 840px) {
  nav { padding: 16px 20px; }
  .nav-links li:not(:last-child):not(:nth-last-child(2)) { display: none; }
  .container { padding: 0 20px; }
  .hero { padding: 110px 20px 60px; }
  .hero-scroll { display: none; }
  .about-grid, .streams, .texts-cols, .access-grid,
  .request-grid, .ananta-grid { grid-template-columns: 1fr; gap: 28px; }
  .about-left { position: static; }
  .ananta-glyph { display: none; }
  .nums-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-controls { width: 100%; justify-content: space-between; margin-top: 12px; }
  .stats-inner { gap: 16px; }
  .stat-item { padding: 0 16px; }
}.req-fields { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.req-fields .notify-input { width: 100%; min-width: 0; resize: vertical; }
.req-choice { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.req-choice[hidden] { display: none; }
.access-dialog { margin: auto; inset: 0; position: fixed; max-width: 560px; width: calc(100% - 32px); max-height: 90vh; overflow-y: auto; padding: 32px 28px; background: var(--paper); color: var(--ink); border: 1px solid var(--rule); border-radius: 2px; }
.access-dialog::backdrop { background: rgba(0,0,0,0.45); }
.access-close { position: absolute; top: 10px; right: 14px; background: none; border: 0; font-size: 24px; color: var(--muted); cursor: pointer; }

/* =========================================
   16. ABOUT PAGE
   ========================================= */
.about-page { padding: 150px 0 100px; }
.people-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 44px; }
.person-card { background: var(--card); border: 0.5px solid var(--rule); border-radius: 2px; padding: 22px 24px; transition: border-color 0.2s, transform 0.2s; }
.person-card:hover { border-color: var(--saffron); transform: translateY(-2px); }
.person-name { font-family: 'Cormorant Garamond'; font-size: 21px; font-weight: 600; color: var(--ink); line-height: 1.3; }
.person-role { font-size: 10.5px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--saffron); margin-top: 7px; }
.team-actions { margin-top: 28px; }
.team-divider { margin-top: 70px; }
#our-team, #open-positions { scroll-margin-top: 100px; }
.open-positions { margin-top: 70px; }
.positions-category { font-family: 'Cormorant Garamond'; font-size: 25px; font-weight: 600; margin: 36px 0 12px; }
.position-row { display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 20px; align-items: center; padding: 22px 0; border-bottom: 0.5px solid var(--rule); }
.position-row h4 { font-size: 15px; font-weight: 500; line-height: 1.5; }
.position-row p { font-size: 13px; color: var(--muted); margin-top: 5px; }
.position-apply { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 1px solid var(--rule); border-radius: 2px; text-decoration: none; color: var(--saffron); font-size: 23px; }
.position-apply:hover { border-color: var(--saffron); }
.person-socials { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.person-socials a { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; color: var(--muted); text-decoration: none; }
.person-socials a:hover { color: var(--saffron); }
.person-socials svg { width: 18px; height: 18px; }
.person-socials a:focus-visible, .position-apply:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; }
.contrib-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px 22px; margin-top: 40px; }
.contrib-name { font-size: 13.5px; color: var(--muted); padding: 9px 0; border-bottom: 0.5px solid var(--rule); }
@media (max-width: 840px) {
  .about-page { padding: 120px 0 70px; }
  .people-grid { grid-template-columns: 1fr; }
  .contrib-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Home-page team & open roles row: the role cards sit beside the team card and slide */
#team .team-grid { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: calc((100% - 40px) / 3); overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 4px; }
#team .team-grid::-webkit-scrollbar { display: none; }
#team .team-grid > * { scroll-snap-align: start; min-width: 0; }
.roles-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 20px; }
.roles-all { color: var(--saffron); font-size: 11px; text-decoration: none; margin-right: 10px; }
.roles-all:hover { text-decoration: underline; }
.roles-arrow { background: transparent; cursor: pointer; flex-shrink: 0; }
.roles-arrow:disabled { opacity: 0.3; cursor: default; }
.role-card { min-height: 270px; justify-content: flex-start; }
.role-card .team-join-title { font-size: 22px; font-weight: 400; line-height: 1.25; overflow-wrap: anywhere; }
.role-card .team-desc { margin-bottom: 20px; }
.role-card .position-apply { margin-top: auto; }
.roles-track:focus-visible, .roles-controls:focus-within, .roles-all:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; }
#team .team-grid:focus-visible { outline: 2px solid var(--saffron); outline-offset: 3px; }
@media (max-width: 840px) { #team .team-grid { grid-auto-columns: calc((100% - 20px) / 2); } }
@media (max-width: 540px) { #team .team-grid { grid-auto-columns: 86%; } .roles-controls { width: 100%; } .roles-all { margin-right: auto; } }

/* =========================================
   17. MODERN POLISH (subtle, keeps the paper look)
   ========================================= */
::selection { background: color-mix(in oklab, var(--saffron) 30%, transparent); }

nav { backdrop-filter: blur(14px) saturate(1.15); -webkit-backdrop-filter: blur(14px) saturate(1.15); }

/* Buttons: softer corners, gentle lift, quiet shadow */
.btn-d, .btn-o, .notify-btn, .nav-links .nav-cta {
  border-radius: 6px;
  transition: background .25s ease, color .25s ease, border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}
.btn-d, .notify-btn { box-shadow: 0 1px 2px color-mix(in oklab, var(--ink) 16%, transparent); }
.btn-d:hover, .notify-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 18px -8px color-mix(in oklab, var(--ink) 38%, transparent); }
.btn-o:hover, .nav-links .nav-cta:hover { transform: translateY(-1px); box-shadow: 0 8px 18px -10px color-mix(in oklab, var(--saffron) 60%, transparent); }

/* Cards: rounder corners and a soft lift on hover */
.stream-card, .access-card, .team-card, .team-join, .terms-box, .person-card, .notify-input, .access-dialog { border-radius: 8px; }
.stream-card, .access-card, .team-card, .person-card { transition: border-color .25s ease, transform .25s ease, box-shadow .25s ease; }
.stream-card:hover, .access-card:hover, .team-card:hover { transform: translateY(-3px); box-shadow: 0 16px 32px -16px color-mix(in oklab, var(--ink) 24%, transparent); }
.person-card:hover { box-shadow: 0 14px 28px -16px color-mix(in oklab, var(--ink) 24%, transparent); }

/* Inputs: modern focus ring instead of a hard outline */
.notify-input { transition: border-color .2s ease, box-shadow .2s ease; }
.notify-input:focus { outline: none; border-color: var(--saffron); box-shadow: 0 0 0 3px color-mix(in oklab, var(--saffron) 22%, transparent); }

/* Pills and round icon buttons */
.tag, .a-badge { border-radius: 999px; }
.tag { padding: 4px 11px; }
.position-apply { border-radius: 50%; transition: border-color .2s ease, background .2s ease, transform .2s ease; }
.position-apply:hover { background: color-mix(in oklab, var(--saffron) 10%, transparent); transform: translateX(2px); }
.roles-arrow { border-radius: 50%; }
.person-socials a { border-radius: 50%; transition: color .2s ease, background .2s ease; }
.person-socials a:hover { background: color-mix(in oklab, var(--saffron) 10%, transparent); }

/* Library rows: a faint wash on hover */
.text-row { transition: background .2s ease; }
.text-row:hover { background: color-mix(in oklab, var(--ink) 3%, transparent); }

@media (prefers-reduced-motion: reduce) {
  .btn-d:hover, .btn-o:hover, .notify-btn:hover, .nav-links .nav-cta:hover,
  .stream-card:hover, .access-card:hover, .team-card:hover, .person-card:hover,
  .position-apply:hover { transform: none; }
}

/* About narrative and role applications */
.about-story { margin-top: 20px; }
.about-story p + p { margin-top: 18px; }
.application-form { display: grid; gap: 18px; margin-top: 24px; }
.application-form label { display: grid; gap: 8px; font-size: 13px; color: var(--muted); }
.application-form .notify-input { width: 100%; min-width: 0; resize: vertical; }
.application-error { color: var(--saffron); font-size: 13px; }
.application-dialog h2 { font-size: 28px; padding-right: 20px; }
.application-submit { justify-self: start; }
.openings-page .positions-category { margin-top: 42px; }
.openings-page .position-apply { background: transparent; }

/* Join-us line: pull it away from the narrative and tie it to the buttons below */
.join-us { margin-top: 44px; font-weight: 600; }
