/* ═══ Untapped Agents — studies.html ═══ */
/* PREMIUM DATA-DRIVEN STORYTELLING EXPERIENCE */

/* ANIMATIONS */
@keyframes pulse-badge {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.95;
  }
}

@keyframes shimmer-accent {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes border-grow {
  0% {
    background-size: 0% 100%;
    background-position: center;
  }
  100% {
    background-size: 100% 100%;
    background-position: center;
  }
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes noise-grain {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 10px 10px;
  }
}

@keyframes radial-glow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(158, 82, 97, 0.3), inset 0 0 20px rgba(158, 82, 97, 0.1);
  }
  50% {
    box-shadow: 0 0 30px rgba(158, 82, 97, 0.5), inset 0 0 30px rgba(158, 82, 97, 0.15);
  }
}

@keyframes link-bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

/* HERO */
.shero {
  padding: 10rem 2rem 5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: var(--bg0);
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.shero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image:
    radial-gradient(circle at 2px 2px, rgba(0, 0, 0, 0.04) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  z-index: 0;
}

.shero::after {
  display: none;
}

.shero > * {
  position: relative;
  z-index: 1;
}

.shero h1 {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 700;
  color: var(--tbr);
  line-height: 1.2;
  margin-bottom: 1.25rem;
  letter-spacing: -0.03em;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
  opacity: 0;
}

.shero h1 em {
  font-style: normal;
  color: var(--cy);
  font-weight: 700;
  font-weight: 700;
}

.shero p {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 1.05rem;
  color: var(--tmd);
  max-width: 600px;
  margin: 0 auto;
  font-weight: 400;
  line-height: 1.85;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s forwards;
  opacity: 0;
}

.shero .count {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.85rem;
  color: var(--tmd);
  margin-top: 2rem;
  font-weight: 500;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
  opacity: 0;
}

.shero .count strong {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--tl);
  font-weight: 700;
  background: var(--bg1);
  padding: 0.5rem 1rem;
  border-radius: 980px;
  border: 1px solid var(--bdr);
}

/* NAV TABS */
.tabs {
  /* Symmetric 4rem so the centered tabs sit on the true page center
     (right 4rem clears the .hh-burger, left 4rem balances it). */
  padding: 0.5rem 4rem;
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.tabs-inner {
  max-width: 1020px;
  margin: 0 auto;
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.tabs-inner::-webkit-scrollbar {
  display: none;
}

/* Center the tabs (they were left-aligned). Auto-margins center the group
   when it fits and collapse to 0 when the row overflows on narrow screens,
   so it stays start-aligned and fully scrollable on mobile. */
.tabs-inner > .tab:first-child { margin-left: auto; }
.tabs-inner > .tab:last-child  { margin-right: auto; }

.tab {
  padding: 0.55rem 1.15rem;
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--tmd);
  text-transform: none;
  letter-spacing: 0.02em;
  white-space: nowrap;
  cursor: pointer;
  border-radius: 980px;
  margin: 0.15rem 0.2rem;
  transition: all 0.25s var(--ease-spring);
  text-decoration: none;
  border: 1px solid transparent;
  position: relative;
  background: transparent;
}

.tab::after {
  display: none;
}

.tab:hover {
  color: var(--tl);
  background: var(--bg1);
  border-color: var(--bdrh);
}

.tab:hover::after {
  display: none;
}

.tab.act {
  color: var(--bg0);
  background: var(--tl);
  font-weight: 600;
  border-color: var(--tl);
}

.tab.act::after {
  display: none;
}

/* STUDY SECTIONS */
.sec {
  padding: 4rem 2rem 2rem;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.sec-head {
  margin-bottom: 2.5rem;
  position: relative;
}

.sec-head::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 40px;
  height: 1px;
  background: var(--bdrh);
  margin-bottom: 1rem;
}

.sec-head h2 {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: clamp(1rem, 1.5vw, 1.4rem);
  font-weight: 700;
  color: var(--tbr);
  line-height: 1.8;
  margin-bottom: 0.5rem;
  margin-top: 1rem;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.sec-head h2::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--tbr);
  border-radius: 50%;
  flex-shrink: 0;
  opacity: 0.3;
}

.sec-head p {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--tmd);
  max-width: 560px;
  line-height: 1.75;
  font-weight: 400;
}

/* STAT CARD */
.stat {
  border: 1px solid var(--bdr);
  background: var(--bg1);
  margin-bottom: 1.5rem;
  border-radius: 18px;
  transition: all 0.35s var(--ease-spring);
  overflow: hidden;
  box-shadow: var(--shadow-s);
  position: relative;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.stat::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--sc, var(--cy)), transparent, var(--sc, var(--cy)));
  background-size: 200% 100%;
  animation: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.stat:hover {
  border-color: var(--bdrh);
  background: var(--bg0);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .08);
  transform: translateY(-4px);
}

.stat:hover::before {
  opacity: 1;
}

.stat-top {
  display: flex;
  align-items: stretch;
}

.stat-num {
  min-width: 140px;
  padding: 2rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg0);
  border-right: 1px solid var(--bdr);
  text-align: center;
  flex-shrink: 0;
  position: relative;
}

.stat-num span {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: clamp(1rem, 2vw, 1.8rem);
  font-weight: 800;
  color: var(--sc, var(--cy));
  line-height: 1.4;
  display: inline-block;
}

.stat-body {
  padding: 1.75rem 2rem;
  flex: 1;
}

.stat-claim {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 1rem;
  color: var(--tbr);
  font-weight: 700;
  line-height: 1.7;
  margin-bottom: 0.75rem;
}

.stat-context {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.85rem;
  color: var(--tmd);
  line-height: 1.7;
  margin-bottom: 1rem;
  font-weight: 400;
}

.stat-src {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.src {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  background: var(--bg2);
  border: 1px solid var(--bdr);
  border-radius: 12px;
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.7rem;
  color: var(--tmd);
  text-decoration: none;
  transition: all 0.2s var(--ease-spring);
  letter-spacing: 0.02em;
  font-weight: 500;
  position: relative;
}

.src::before {
  content: '●';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4px;
  height: 4px;
  background: #2ecc71;
  border-radius: 50%;
  flex-shrink: 0;
  font-size: 0;
}

.src::after {
  content: '↗';
  font-size: 0.6rem;
  opacity: 0;
  transform: translate(0, 0);
  transition: all 0.2s var(--ease-spring);
  margin-left: 0.2rem;
}

.src:hover {
  border-color: var(--bdrh);
  color: var(--tl);
  background: var(--bg1);
}

.src:hover::after {
  opacity: 1;
  transform: translate(2px, -2px);
}

/* COLOR VARIANTS */
.sc-cy {
  --sc: var(--cy);
}

.sc-gn {
  --sc: var(--gn);
}

.sc-or {
  --sc: var(--or);
}

.sc-bl {
  --sc: var(--bl);
}

.sc-pr {
  --sc: var(--pr);
}

.sc-pk {
  --sc: var(--pk);
}

.sc-yl {
  --sc: var(--yl);
}

.sc-rd {
  --sc: var(--rd);
}

/* STAT CARD COLOR VARIANTS */
.sc-cy .stat-num span { color: var(--cy); }
.sc-gn .stat-num span { color: #1a8a5a; }
.sc-or .stat-num span { color: #b86020; }
.sc-bl .stat-num span { color: #2070c0; }
.sc-pr .stat-num span { color: #6840b8; }
.sc-pk .stat-num span { color: #b82078; }
.sc-yl .stat-num span { color: #9a7a18; }
.sc-rd .stat-num span { color: #c03838; }

/* METHODOLOGY NOTE */
.meth {
  padding: 2rem 2rem 4rem;
}

.meth-box {
  border: 1px solid var(--bdr);
  background: var(--bg1);
  padding: 2.5rem;
  border-radius: 18px;
  position: relative;
  max-width: 1020px;
  margin: 0 auto;
  box-shadow: var(--shadow-s), inset 0 1px 2px rgba(255, 255, 255, 0.5);
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  background-image:
    linear-gradient(90deg, rgba(0, 0, 0, 0.02) 1px, transparent 1px),
    linear-gradient(rgba(0, 0, 0, 0.02) 1px, transparent 1px);
  background-size: 40px 40px, 40px 40px;
  background-position: 0 0, 0 0;
}

.meth-box::before {
  content: 'METHODOLOGY';
  position: absolute;
  top: -0.75rem;
  left: 1.5rem;
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--bg0);
  background: var(--tl);
  padding: 0.4rem 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 8px;
}

.meth-box p {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 0.9rem;
  color: var(--tmd);
  line-height: 1.8;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  font-weight: 400;
}

.meth-box p + p {
  margin-top: 1rem;
}

/* DIVIDER */
.divider {
  border: none;
  border-top: none;
  margin: 0 2rem;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--bdr), transparent);
}

/* CTA */
.scta {
  text-align: center;
  padding: 8rem 2rem;
  position: relative;
  overflow: hidden;
  background: #1d1d1f;
  color: #f5f5f7;
}

.scta::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(158, 82, 97, 0.15) 0%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
}

.scta > * {
  position: relative;
  z-index: 1;
}

.scta h2 {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  letter-spacing: -0.03em;
}

.scta h2 em {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-style: italic;
  font-weight: 400;
  color: var(--cy);
  -webkit-text-fill-color: var(--cy);
  padding-right: .12em;
  margin-right: -.02em;
}

.scta p {
  font-family: 'Inter', 'DM Sans', sans-serif;
  font-size: 1rem;
  color: #a1a1a6;
  max-width: 460px;
  margin: 0 auto 2.5rem;
  font-weight: 300;
  line-height: 1.8;
}

.scta-acts {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  animation: fade-in-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
  opacity: 0;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
  .shero {
    padding: 8.5rem 2rem 4rem;
  }
}

@media (max-width: 768px) {
  .shero {
    padding: 7rem 1.5rem 3rem;
  }

  .shero h1 {
    font-size: clamp(1.4rem, 2.5vw, 2rem);
  }

  .stat-top {
    flex-direction: column;
  }

  .stat-num {
    min-width: auto;
    border-right: none;
    border-bottom: 1px solid var(--bdr);
    padding: 1.5rem;
  }

  .stat-body {
    padding: 1.5rem;
  }

  .tab {
    padding: 0.85rem 1rem;
    font-size: 0.75rem;
  }

  .sec,
  .meth {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }

  .sec-head h2 {
    font-size: 1rem;
  }

  .scta {
    padding: 3.5rem 1.5rem 4.5rem;
  }

  .scta h2 {
    font-size: 1rem;
  }

  .scta p {
    font-size: 0.9rem;
  }

  .meth-box {
    padding: 2rem;
  }

  .meth-box::before {
    top: -0.6rem;
    left: 1rem;
    font-size: 0.6rem;
    padding: 0.35rem 0.6rem;
  }
}

@media (max-width: 480px) {
  .shero {
    padding: 5rem 1rem 2rem;
  }

  .shero h1 {
    font-size: clamp(1.2rem, 2vw, 1.6rem);
    margin-bottom: 1rem;
  }

  .shero p {
    font-size: 0.95rem;
  }

  .shero .count {
    margin-top: 1.5rem;
    font-size: 0.8rem;
  }

  .tabs {
    padding: 0 1rem;
  }

  .tab {
    padding: 0.75rem 0.85rem;
    font-size: 0.7rem;
    margin: 0.4rem 0.15rem;
  }

  .sec {
    padding: 3rem 1rem 1.5rem;
  }

  .sec-head {
    margin-bottom: 2rem;
  }

  .sec-head h2 {
    font-size: 0.95rem;
    gap: 0.5rem;
  }

  .stat {
    margin-bottom: 1.25rem;
  }

  .stat-num span {
    font-size: 1.4rem;
  }

  .stat-claim {
    font-size: 0.9rem;
  }

  .stat-context {
    font-size: 0.8rem;
  }

  .src {
    font-size: 0.65rem;
    padding: 0.35rem 0.75rem;
  }

  .meth {
    padding: 1.5rem 1rem 3rem;
  }

  .meth-box {
    padding: 1.5rem;
    border-radius: 16px;
  }

  .divider {
    margin: 0 1rem;
  }

  .scta {
    padding: 2.5rem 1rem 3.5rem;
  }

  .scta h2 {
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1rem;
  }

  .scta p {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }

  .scta-acts {
    gap: 0.75rem;
  }
}

/* STAGGERED ENTRANCE ANIMATIONS */
.stat:nth-child(1) {
  animation-delay: 0s;
}

.stat:nth-child(2) {
  animation-delay: 0.1s;
}

.stat:nth-child(3) {
  animation-delay: 0.2s;
}

.stat:nth-child(4) {
  animation-delay: 0.3s;
}

.stat:nth-child(5) {
  animation-delay: 0.4s;
}

.stat:nth-child(n+6) {
  animation-delay: 0.5s;
}
