/* rstnc site components */

/* ── Smooth scroll ── */
html { scroll-behavior: smooth; }

/* ── Selection ── */
::selection { background: #00ff8855; color: #fff; }

/* ── Nav ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 2rem;
  background: rgba(0,0,0,.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,.06);
  font-family: "Fira Mono", monospace;
  font-size: .8rem;
}
.nav-logo {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: "Oxanium", sans-serif;
  font-weight: 800; font-size: 1.4rem;
  line-height: 1;
  letter-spacing: -.03em;
  color: #fff; text-decoration: none;
}
.nav-logo-icon {
  width: 26px; height: 26px;
  flex-shrink: 0;
  vertical-align: middle;
  position: relative; top: -1px;
  transition: opacity .3s ease, transform .3s ease;
}
.nav-logo-icon.hidden { opacity: 0; transform: scale(.7); pointer-events: none; }
.nav-logo-icon.visible { opacity: 1; transform: scale(1); }
.nav-links { display: flex; gap: 1.5rem; list-style: none; }
.nav-links a {
  color: rgba(255,255,255,.6); text-decoration: none;
  transition: color .2s;
}
.nav-links a:hover, .nav-links a.active { color: #00ff88; }

/* hamburger */
.nav-toggle { display: none; background: none; cursor: pointer; }
.nav-toggle span {
  display: block; width: 22px; height: 2px;
  background: #fff; margin: 5px 0; transition: .3s;
}
@media (max-width: 640px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: rgba(0,0,0,.95); padding: 1rem 2rem;
    border-bottom: 1px solid rgba(255,255,255,.06);
  }
  .nav-links.open { display: flex; }
}

/* ── Body offset for fixed nav ── */
body { padding-top: 3.5rem; }

/* ── Section layout ── */
.section {
  max-width: 800px; margin: 0 auto;
  padding: 4rem 1.5rem;
}
.section-sm { max-width: 600px; }

/* ── Typography ── */
.heading {
  font-family: "Oxanium", sans-serif;
  font-weight: 800; letter-spacing: -.03em;
  line-height: 1.1;
}
.h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); }
.h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
.h3 { font-size: clamp(1.2rem, 3vw, 1.6rem); }
.body-text {
  font-family: "Fira Mono", monospace;
  font-size: clamp(.85rem, 1.5vw, 1rem);
  line-height: 1.7;
  color: rgba(255,255,255,.7);
}
.accent { color: #00ff88; }
.muted { color: rgba(255,255,255,.4); }

/* ── Buttons ── */
.btn {
  display: inline-block;
  font-family: "Oxanium", sans-serif; font-weight: 800;
  font-size: .95rem; letter-spacing: .02em;
  padding: .85rem 2rem; border-radius: 0;
  text-decoration: none; cursor: pointer;
  transition: all .2s; border: 2px solid transparent;
}
.btn-primary {
  background: #00ff88; color: #000;
  border-color: #00ff88;
}
.btn-primary:hover { background: #00cc6a; border-color: #00cc6a; }
.btn-outline {
  background: transparent; color: #00ff88;
  border-color: #00ff88;
}
.btn-outline:hover { background: #00ff8815; }
.btn-ghost {
  background: transparent; color: rgba(255,255,255,.6);
  border-color: rgba(255,255,255,.15);
}
.btn-ghost:hover { border-color: rgba(255,255,255,.4); color: #fff; }

/* ── Progress bar ── */
.progress-track {
  width: 100%; height: 6px;
  background: rgba(255,255,255,.08); border-radius: 0;
  overflow: hidden;
}
.progress-fill {
  height: 100%; background: #00ff88;
  transition: width 1.5s ease;
}

/* ── Cards ── */
.card {
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  padding: 2rem;
}
.card:hover { border-color: rgba(0,255,136,.2); }

/* ── Grid ── */
.grid-2 {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem;
}
.grid-3 {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem;
}
@media (max-width: 640px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* ── Form ── */
.input {
  width: 100%; padding: .85rem 1rem;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  color: #fff; font-family: "Fira Mono", monospace;
  font-size: .9rem; outline: none;
  transition: border-color .2s;
}
.input:focus { border-color: #00ff88; }
.input::placeholder { color: rgba(255,255,255,.3); }

/* ── Divider ── */
.divider {
  border: none; border-top: 1px solid rgba(255,255,255,.06);
  margin: 3rem 0;
}

/* ── Stat block ── */
.stat-value {
  font-family: "Oxanium", sans-serif; font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.5rem);
  color: #00ff88; line-height: 1;
}
.stat-label {
  font-family: "Fira Mono", monospace;
  font-size: .75rem; color: rgba(255,255,255,.4);
  text-transform: uppercase; letter-spacing: .1em;
  margin-top: .5rem;
}

/* ── ASCII box (reuse from original) ── */
.ascii-box {
  font-family: "Fira Mono", monospace;
  letter-spacing: .1em;
  text-align: center;
  color: rgba(255,255,255,.6);
  line-height: 1.6;
}

/* ── Footer ── */
.footer {
  text-align: center; padding: 3rem 1.5rem;
  font-family: "Fira Mono", monospace;
  font-size: .75rem; color: rgba(255,255,255,.3);
  border-top: 1px solid rgba(255,255,255,.06);
}
.footer a { color: #00ff88; text-decoration: none; }
.footer a:hover { text-decoration: underline; }

/* ── Flex helpers ── */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }
.gap-4 { gap: 2rem; }
.text-center { text-align: center; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.w-full { width: 100%; }

/* ── Animate fade-in ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp .8s ease both; }
.fade-up-d1 { animation-delay: .1s; }
.fade-up-d2 { animation-delay: .2s; }
.fade-up-d3 { animation-delay: .3s; }
.fade-up-d4 { animation-delay: .4s; }

/* ── Spinner ── */
@keyframes spin {
  to { transform: rotate(360deg); }
}
.spinner-overlay {
  display: none;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 1.5rem;
  padding: 3rem 1rem;
}
.spinner-overlay.active { display: flex; }
.spinner {
  width: 48px; height: 48px;
  border: 3px solid rgba(255,255,255,.1);
  border-top-color: #00ff88;
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
.spinner-text {
  font-family: "Fira Mono", monospace;
  font-size: .8rem;
  color: rgba(255,255,255,.5);
}

/* ── Success fade-in ── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.success-reveal {
  display: none;
}
.success-reveal.active {
  display: block;
  animation: fadeIn .6s ease both;
}
