/*
  Flex Tracker Website — v1
  Same layout + interaction system as your Poro Hunt site,
  but with a new brand palette (electric blue / violet).
*/

* { box-sizing: border-box; }
html, body { height: 100%; }
body { min-height: 100vh; margin: 0; }

:root{
  /* Brand palette */
  --bg: #0b0f17;
  --bg2: #0f1624;
  --text: #e8eefc;
  --muted: rgba(232, 238, 252, 0.72);

  /* Flex Tracker accents */
  --accent: #4fb0ff;   /* electric blue */
  --accent2:#7c5cff;   /* violet */
  --accent3:#37e6d7;   /* teal pop */

  --border: rgba(255,255,255,0.10);
  --border2: rgba(255,255,255,0.14);
  --panel: rgba(255,255,255,0.04);

  --shadow: 0 18px 55px rgba(0,0,0,0.35);
}

body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
}

main { min-height: calc(100vh - 80px); padding-bottom: 36px; }

.container {
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding-left: clamp(16px, 3vw, 48px);
  padding-right: clamp(16px, 3vw, 48px);
}

.section { padding: 72px 0; }
.section-alt {
  background: rgba(255, 255, 255, 0.03);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.muted { color: var(--muted); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace; }

.h1 { font-size: clamp(2.2rem, 4vw, 3.2rem); line-height: 1.05; margin: 0 0 1rem; }
.h2 { font-size: 2rem; margin: 0 0 0.5rem; }
.lede { margin: 0 0 2rem; max-width: 75ch; color: rgba(232, 238, 252, 0.78); }

.pill {
  display: inline-block;
  font-weight: 800;
  font-size: 0.9rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.10);
  margin: 0 0 1rem;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  font-weight: 800;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border2);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  cursor: pointer;
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease, box-shadow 140ms ease, filter 140ms ease;
}
.btn:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
.btn:active { transform: translateY(0px) scale(0.98); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent2), var(--accent3));
  border: none;
  color: #06101b;
}
.btn-primary:hover {
  filter: brightness(1.06);
  box-shadow: 0 12px 38px rgba(79, 176, 255, 0.12), 0 12px 38px rgba(124, 92, 255, 0.10);
}
.btn-ghost { background: rgba(255, 255, 255, 0.06); }
/* Support button (unique style) */
.btn-support{
  border: 1px solid rgba(88, 101, 242, 0.35);      /* Discord blurple vibe */
  background: rgba(88, 101, 242, 0.10);
  color: rgba(232,238,252,0.92);
}

.btn-support:hover{
  transform: translateY(-2px);
  border-color: rgba(88, 101, 242, 0.70);
  background: rgba(88, 101, 242, 0.16);
  box-shadow: 0 10px 30px rgba(88, 101, 242, 0.18);
  filter: brightness(1.02);
}

.btn-support:active{
  transform: translateY(0px) scale(0.98);
}

.btn-small { padding: 0.55rem 0.85rem; font-size: 0.95rem; }

/* Crisp highlight + tiny lift (use on key homepage ghost buttons) */
.btn-focus:hover {
  border-color: rgba(79, 176, 255, 0.55);
  box-shadow: 0 10px 28px rgba(0,0,0,0.28);
  transform: translateY(-2px);
}
.btn-focus:active { transform: translateY(-1px) scale(0.99); }

/* NAV */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(10px);
  background: rgba(11, 15, 23, 0.72);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}
.site-header.is-scrolled {
  background: rgba(11, 15, 23, 0.90);
  border-color: rgba(255, 255, 255, 0.10);
  box-shadow: var(--shadow);
}
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; gap: 1rem; }

.brand {
  display: inline-flex;
  gap: 0.65rem;
  align-items: center;
  text-decoration: none;
  color: var(--text);
}
.brand-logo{
  width: 36px;
  height: 36px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 10px 26px rgba(0,0,0,0.35);
}
.brand-text { font-weight: 900; letter-spacing: 0.2px; }

/* NAV (split left/right) */
.nav{
  flex: 1;                         /* lets nav take remaining space */
  display: flex;
  align-items: center;
  justify-content: space-between;  /* left group left, right group right */
  gap: 1rem;
}

.nav-left,
.nav-right{
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.nav-link {
  position: relative;
  text-decoration: none;
  color: rgba(232, 238, 252, 0.86);
  font-weight: 800;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  transition: transform 140ms ease, background 140ms ease, color 140ms ease;
}
.nav-link:hover {
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
  color: rgba(232, 238, 252, 0.95);
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 6px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent2), var(--accent3));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
  opacity: 0.95;
}
.nav-link:hover::after { transform: scaleX(1); }
.nav-link[aria-current="page"] {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(232, 238, 252, 0.98);
}
.nav-link[aria-current="page"]::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  border-radius: 10px;
  padding: 0.6rem 0.75rem;
  font-weight: 900;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border2);
  cursor: pointer;
}
.nav-toggle:hover {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #07101a;
  border-color: rgba(79, 176, 255, 0.65);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}
.nav-toggle:active { transform: scale(0.97); }

/* HERO */
.hero {
  padding: 84px 0 56px;
  background:
    radial-gradient(1000px 500px at 20% 10%, rgba(79, 176, 255, 0.16), transparent 60%),
    radial-gradient(900px 500px at 80% 10%, rgba(124, 92, 255, 0.14), transparent 60%),
    radial-gradient(850px 520px at 55% 0%, rgba(55, 230, 215, 0.10), transparent 62%);
}
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 2rem; align-items: start; }
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 1.5rem; }

.hero-subtitle{
  display:block;
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 800;
  margin-top: 0.6rem;
  opacity: 0.9;
}

.card, .hero-card, .demo-card {
  border-radius: 22px;
  border: 1px solid var(--border);
  background: var(--panel);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.card { padding: 18px; }
.card h2, .card h3 { margin-top: 0; }
.card p { max-width: 75ch; }

.demo-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: var(--shadow);
}

/* Value cards */
.value-card{
  border-radius: 18px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(0,0,0,0.22);
}
.value-card h3 { margin: 0 0 0.35rem; }
.value-card p { margin: 0; color: rgba(232,238,252,0.74); }

/* Page hero */
.page-hero {
  padding: 56px 0 24px;
  background:
    radial-gradient(900px 420px at 20% 10%, rgba(79, 176, 255, 0.12), transparent 60%),
    radial-gradient(850px 420px at 80% 10%, rgba(124, 92, 255, 0.10), transparent 60%),
    radial-gradient(850px 520px at 55% 0%, rgba(55, 230, 215, 0.08), transparent 62%);
}

/* Demo / Discord UI */
.demo-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 1rem;
  align-items: start;
}
.discord-shell { border-radius: 18px; border: 1px solid rgba(255,255,255,0.08); background: rgba(0,0,0,0.25); overflow: hidden; }
.discord-top { display:flex; gap:0.5rem; align-items: baseline; padding:10px 12px; border-bottom: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.03); }
.hash { font-weight: 900; opacity: 0.8; }
.chan { font-weight: 900; }
.topic { margin-left: auto; font-size: 0.9rem; }

.discord-feed { padding: 10px; min-height: 250px; }
.discord-actions { display:flex; align-items:center; gap:0.65rem; flex-wrap:wrap; padding:10px; border-top:1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.02); }

.dmsg { display:grid; grid-template-columns: 38px 1fr; gap:10px; padding:8px 6px; border-radius:14px; transition: background 120ms ease; }
.dmsg:hover { background: rgba(255,255,255,0.03); }
.avatar { width:36px; height:36px; border-radius:999px; display:grid; place-items:center; font-weight:900; background: rgba(255,255,255,0.10); border:1px solid rgba(255,255,255,0.10); }
.avatar.bot { background: rgba(79, 176, 255, 0.10); border-color: rgba(79, 176, 255, 0.30); }
.avatar.user { background: rgba(124, 92, 255, 0.10); border-color: rgba(124, 92, 255, 0.28); }

.dmsg-head { display:flex; gap:0.5rem; align-items: baseline; }
.name { font-weight: 900; }
.name.bot { color: rgba(79, 176, 255, 0.95); }
.tag {
  font-size: 0.75rem;
  font-weight: 900;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(55, 230, 215, 0.10);
  border: 1px solid rgba(55, 230, 215, 0.24);
  color: rgba(232,238,252,0.88);
}
.time { margin-left:auto; font-size:0.85rem; color: rgba(232,238,252,0.55); }
.dmsg-body { margin-top:2px; color: rgba(232,238,252,0.78); }
.meta-line { margin-top:4px; font-size:0.9rem; color: rgba(232,238,252,0.6); }

@keyframes popIn { 0%{opacity:0; transform:translateY(8px) scale(0.98); filter:blur(2px)} 100%{opacity:1; transform:translateY(0) scale(1); filter:blur(0)} }
.dmsg.spawn-in { animation: popIn 220ms ease-out both; }
.dmsg.fading { opacity:0; transform: translateY(6px); transition: opacity 520ms ease, transform 520ms ease; }

/* Typing indicator */
.typing {
  display:inline-flex; align-items:center; gap:6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  width: fit-content;
}
.dots { display:inline-flex; gap:4px; align-items:center; }
.dotty { width:6px; height:6px; border-radius:999px; background: rgba(232,238,252,0.75); animation: bounce 900ms ease-in-out infinite; }
.dotty:nth-child(2){ animation-delay: 120ms; opacity:0.85; }
.dotty:nth-child(3){ animation-delay: 240ms; opacity:0.7; }
@keyframes bounce { 0%,60%,100%{ transform: translateY(0)} 30%{ transform: translateY(-4px)} }

/* CTA wide */
.cta-wide { width: 100%; text-align: center; }
.cta-inner { max-width: 1100px; margin: 0 auto; padding: clamp(2rem, 5vw, 3.5rem); }
.cta-wide .lede { margin-left: auto; margin-right: auto; max-width: 52ch; }

/* Footer */
.site-footer { padding: 26px 0; border-top: 1px solid rgba(255,255,255,0.06); }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-min { display: inline-flex; gap: 0.9rem; align-items: center; flex-wrap: wrap; }
.footer-min a { color: rgba(232,238,252,0.7); text-decoration: none; font-weight: 900; }
.footer-min a:hover { text-decoration: underline; }

/* Back to top */
.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 50;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.06);
  color: var(--text);
  display: grid;
  place-items: center;
  box-shadow: 0 18px 55px rgba(0,0,0,0.35);
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease, background 140ms ease, border-color 140ms ease;
}
.back-to-top:hover {
  background: rgba(255,255,255,0.10);
  border-color: rgba(255,255,255,0.22);
  transform: translateY(6px);
}
.back-to-top:active { transform: translateY(8px) scale(0.98); }
.back-to-top.is-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }

/* Responsive */
@media (max-width: 980px){
  .hero-grid { grid-template-columns: 1fr; }
  .grid-3, .grid-2, .demo-grid { grid-template-columns: 1fr; }
  .nav-toggle { display: inline-flex; }
  .nav { display:none; width:100%; padding-top:10px; justify-content:flex-start; }
  .nav.is-open { display:flex; }
  .nav-row { flex-wrap: wrap; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  .btn, .site-header, .nav-link, .demo-card, .back-to-top { transition: none; }
  .dmsg.spawn-in { animation: none; }
  .dmsg.fading { transition: none; }
  .dotty { animation: none; }
}

/* ===== Release Announcement Bar ===== */

/* Release bar: collapsible + animated close */
.release-bar{
  width: 100%;
  background: linear-gradient(
    90deg,
    rgba(88,101,242,0.18),
    rgba(79,176,255,0.18)
  );
  border-bottom: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(8px);
  z-index: 15;

  /* Collapsing animation */
  max-height: 0;
  opacity: 0;
  overflow: hidden;

  transition: max-height 260ms ease, opacity 260ms ease;
}

/* When visible, give it enough height to fit content */
.release-bar.is-visible{
  max-height: 120px; /* generous; handles wrapping on mobile */
  opacity: 1;
}

/* Closing state: fade and collapse */
.release-bar.is-closing{
  max-height: 0;
  opacity: 0;
}

/* Keep your inner layout the same */
.release-inner{
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  text-align: center;
}

.release-inner{
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  text-align: center;
}

.release-text{
  font-weight: 800;
  color: rgba(232,238,252,0.95);
}

/* Glow pulse animation */
@keyframes releasePulse {
  0%   { box-shadow: 0 0 0 rgba(88,101,242,0); }
  50%  { box-shadow: 0 0 18px rgba(88,101,242,0.45); }
  100% { box-shadow: 0 0 0 rgba(88,101,242,0); }
}

.release-bar.pulse{
  animation: releasePulse 1.6s ease-in-out infinite;
}

.release-btn{
  text-decoration: none;
  font-weight: 900;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.08);
  color: rgba(232,238,252,0.95);
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease;
}

.release-btn:hover{
  transform: translateY(-1px);
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.28);
}

.release-dismiss{
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.06);
  color: rgba(232,238,252,0.95);
  font-weight: 900;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: transform 140ms ease, background 140ms ease;
}

.release-dismiss:hover{
  transform: translateY(-1px);
  background: rgba(255,255,255,0.12);
}

@media (max-width: 980px){
  .hero-grid { grid-template-columns: 1fr; }
  .grid-3, .grid-2, .demo-grid { grid-template-columns: 1fr; }
  .odds { margin-left: 0; width: 100%; text-align: left; }

  .nav-toggle { display: inline-flex; }

  /* Mobile dropdown menu */
  .nav{
    display: none;
    width: 100%;
    padding-top: 10px;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0.75rem;
  }
  .nav.is-open{ display: flex; }

  .nav-left,
  .nav-right{
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }

  .nav-right .btn{
    width: 100%;                 /* buttons look cleaner in dropdown */
    justify-content: center;
  }

  .nav-row { flex-wrap: wrap; }
}