/* Cattle Coin AI — dark mode redesign */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&display=swap');

:root {
  --bg:            #080705;
  --bg-mid:        #0f0d0b;
  --bg-surface:    #161310;
  --surface:       rgba(255, 255, 255, 0.035);
  --surface-hover: rgba(255, 255, 255, 0.06);
  --surface-border: rgba(255, 255, 255, 0.07);
  --text:          #ede8df;
  --text-dim:      #7a7268;
  --text-muted:    #4e4a44;
  --gold:          #c8922a;
  --gold-bright:   #e8b84b;
  --gold-dim:      #7a5a1e;
  --gold-glow:     rgba(200, 146, 42, 0.18);
  --red-accent:    #8b3a2a;
  --shadow-sm:     0 1px 3px rgba(0,0,0,0.5);
  --shadow-md:     0 8px 32px rgba(0,0,0,0.6), 0 2px 8px rgba(0,0,0,0.4);
  --shadow-frame:  0 32px 80px rgba(0,0,0,0.8), 0 0 0 1px rgba(255,255,255,0.06) inset;
  --radius-sm:     8px;
  --radius-md:     12px;
  --radius-lg:     18px;
  --font-body:     "Space Grotesk", "Source Sans 3", system-ui, sans-serif;
  --font-title:    "Newsreader", "Georgia", serif;
  --measure:       min(44rem, 100%);
  --media-max:     min(480px, 84vw);
  --space:         8px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
  overflow-x: hidden;
}

/* ─── Ambient background ─── */
.page-bg {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% -5%,  rgba(200,146,42,0.10) 0%, transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 80%, rgba(139,58,42,0.07) 0%, transparent 50%),
    radial-gradient(ellipse 40% 35% at 0% 50%,   rgba(200,146,42,0.04) 0%, transparent 45%),
    var(--bg);
}

.page-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.45;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
  mix-blend-mode: screen;
}

body > *:not(.page-bg) { position: relative; z-index: 1; }

a { color: inherit; text-decoration: none; }

/* ─── Header ─── */
.header {
  padding: calc(var(--space) * 3) clamp(1.25rem, 4vw, 2.5rem);
  border-bottom: 1px solid rgba(255,255,255,0.04);
  backdrop-filter: blur(0);
}

.header__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem 1.75rem;
}

.header__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  transition: opacity 0.2s ease;
}

.header__brand:hover { opacity: 0.75; }

.header__mark {
  position: relative;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: conic-gradient(from 200deg, var(--gold-dim), var(--gold-bright), var(--gold), var(--gold-dim));
  box-shadow: 0 0 12px var(--gold-glow), 0 0 0 1px rgba(232,184,75,0.2);
  flex-shrink: 0;
}

.header__mark::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.25), transparent 60%),
              var(--bg-surface);
}

.header__wordmark {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text);
}

.header__ai {
  color: var(--gold-bright);
  font-weight: 700;
}

/* ─── Nav pill (right side) ─── */
.header__nav {
  display: flex;
  gap: 0.5rem;
}

.header__nav-link {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-dim);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.header__nav-link:hover {
  color: var(--gold-bright);
  border-color: var(--surface-border);
  background: var(--surface);
}

.header__nav-link.is-active {
  color: var(--gold-bright);
  border-color: rgba(200, 146, 42, 0.35);
  background: rgba(200, 146, 42, 0.08);
}

/* ─── Main (centered landing column) ─── */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: calc(var(--space) * 8);
}

/* ─── Slideshow ─── */
.show {
  width: 100%;
  max-width: calc(var(--media-max) + 2rem);
  padding: calc(var(--space) * 4) clamp(1.25rem, 4vw, 2rem) calc(var(--space) * 4);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.show__frame {
  position: relative;
  width: 100%;
  max-width: var(--media-max);
  margin: 0 auto;
  aspect-ratio: 1024 / 686;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #050403;
  box-shadow: var(--shadow-frame);
  outline: 1px solid rgba(255,255,255,0.07);
  outline-offset: -1px;
}

/* Subtle gold glow ring under the frame */
.show__frame::before {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(200,146,42,0.3), transparent 50%, rgba(139,58,42,0.15) 100%);
  z-index: -1;
  filter: blur(16px);
  opacity: 0.6;
}

.show__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.show__img.is-active { opacity: 1; z-index: 1; }

@media (prefers-reduced-motion: reduce) { .show__img { transition: none; } }

.show__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1rem;
}

.show__dots {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  padding: 0.3rem 0.5rem;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 999px;
  backdrop-filter: blur(12px);
}

.show__dot {
  width: 6px;
  height: 6px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(255,255,255,0.15);
  cursor: pointer;
  transition: width 0.25s ease, background 0.2s ease;
}

.show__dot.is-active {
  width: 20px;
  background: linear-gradient(90deg, var(--gold), var(--gold-bright));
}

.show__dot:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ─── Content (centered below hero) ─── */
.content {
  width: 100%;
  max-width: min(40rem, 92vw);
  margin: 0 auto;
  padding: calc(var(--space) * 2) clamp(1.25rem, 4vw, 2rem) 0;
  text-align: center;
}

.article {
  margin: 0 auto;
  padding: calc(var(--space) * 2) 0 calc(var(--space) * 1);
}

.article__eyebrow {
  display: block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
  opacity: 0.9;
}

.article__title {
  margin: 0 auto 1.2rem;
  max-width: min(30ch, 100%);
  font-family: var(--font-title);
  font-weight: 500;
  font-size: clamp(1.85rem, 5vw + 0.35rem, 2.85rem);
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: var(--text);
  text-wrap: balance;
}

.article__body {
  margin: 0 auto 2.25rem;
  max-width: 48ch;
  color: var(--text-dim);
  font-size: 1.02rem;
  line-height: 1.8;
  letter-spacing: 0.01em;
  text-wrap: pretty;
}

/* ─── Facts (centered stack) ─── */
.facts {
  margin: 0 auto;
  padding: 0;
  max-width: 38rem;
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.facts li {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.35rem;
  padding: 1.15rem 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
}

.facts li:first-child {
  padding-top: 0.5rem;
}

.facts li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.facts li:hover .facts__title {
  color: var(--gold-bright);
}

.facts__title {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

.facts__text {
  display: block;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--text-dim);
}

/* ─── Team (centered grid) ─── */
.team {
  width: 100%;
  max-width: min(56rem, 94vw);
  margin: 0 auto;
  padding: calc(var(--space) * 6) clamp(1.25rem, 4vw, 2rem) calc(var(--space) * 2);
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.team__heading {
  margin: 0 0 0.35rem;
  font-family: var(--font-title);
  font-weight: 500;
  font-size: clamp(1.35rem, 2.5vw + 0.45rem, 1.75rem);
  letter-spacing: -0.02em;
  color: var(--text);
}

.team__intro {
  margin: 0 auto 1.85rem;
  max-width: 36ch;
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* Top row: 2 · Bottom row: 3 (6-column tracks) */
.team__grid {
  margin: 0 auto;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(1.25rem, 3vw, 2rem) clamp(0.35rem, 1.2vw, 0.75rem);
  justify-items: center;
  align-items: start;
  max-width: min(44rem, 100%);
}

.team__card:nth-child(1) {
  grid-column: 1 / 4;
  justify-self: end;
}

.team__card:nth-child(2) {
  grid-column: 4 / 7;
  justify-self: start;
}

.team__card:nth-child(3) {
  grid-column: 1 / 3;
}

.team__card:nth-child(4) {
  grid-column: 3 / 5;
}

.team__card:nth-child(5) {
  grid-column: 5 / 7;
}

.team__card {
  width: min(180px, 28vw);
  max-width: min(180px, 28vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
}

.team__photo-frame {
  width: min(100%, 168px);
  aspect-ratio: 1;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-surface);
  box-shadow: var(--shadow-md), 0 0 0 1px rgba(200, 146, 42, 0.15);
}

.team__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.team__name {
  margin: 0;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
}

.team__role {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold);
  line-height: 1.4;
}

@media (max-width: 640px) {
  .team__grid {
    grid-template-columns: 1fr;
    max-width: min(18rem, 88vw);
    gap: 1.5rem;
  }

  .team__card:nth-child(n) {
    grid-column: auto;
  }

  .team__card:nth-child(1),
  .team__card:nth-child(2) {
    justify-self: center;
  }

  .team__card {
    width: min(200px, 70vw);
    max-width: min(200px, 70vw);
  }

  .team__photo-frame {
    width: min(100%, 168px);
  }
}

@media (max-width: 380px) {
  .team__card {
    width: min(168px, 72vw);
    max-width: min(168px, 72vw);
  }

  .team__photo-frame {
    width: min(100%, 148px);
  }
}

/* Team standalone page */
.main--team-page {
  flex: 1;
  justify-content: center;
}

.team--page {
  border-top: none;
  padding-top: calc(var(--space) * 5);
  padding-bottom: calc(var(--space) * 6);
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ─── Footer ─── */
.footer {
  margin-top: auto;
  padding: calc(var(--space) * 5) clamp(1.25rem, 4vw, 2rem) calc(var(--space) * 6);
  border-top: 1px solid rgba(255,255,255,0.04);
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.3));
}

.footer__inner {
  max-width: 920px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.5rem;
}

.footer__brand {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.footer__brand span {
  color: var(--gold);
}

.footer__meta {
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* ─── Mobile ─── */
@media (max-width: 540px) {
  .article { padding-top: var(--space); }
  .article__title { max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
