/* ═══════════════════════════════════════════════════
   TackLabs — AI-Native Software Infrastructure
   Main Stylesheet
   ═══════════════════════════════════════════════════ */

/* ─── RESET & BASE ─────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --cyan: #00e5c8;
  --cyan-dim: rgba(0, 229, 200, 0.12);
  --cyan-glow: rgba(0, 229, 200, 0.3);
  --amber: #f5a623;
  --red: #ff4b6e;
  --bg: #060910;
  --surface: #0c1118;
  --elevated: #111a24;
  --card: #0e1620;
  --border: rgba(0, 229, 200, 0.1);
  --border-md: rgba(0, 229, 200, 0.2);
  --white: #edf2f8;
  --subtle: #7a8fa0;
  --muted: #3d5060;
  --font-head: "Funnel Display", sans-serif;
  --font-mono: "JetBrains Mono", monospace;
  --font-body: "Inter", sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font-body);
  overflow-x: hidden;
  cursor: default;
}

/* ─── CUSTOM CURSOR (desktop only) ──────────────── */
@media (hover: hover) and (pointer: fine) {
  *,
  a {
    cursor: none !important;
  }

  #cursor {
    position: fixed;
    width: 8px;
    height: 8px;
    background: var(--cyan);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition:
      width 0.15s,
      height 0.15s,
      opacity 0.15s;
    mix-blend-mode: screen;
  }

  #cursor-ring {
    position: fixed;
    width: 32px;
    height: 32px;
    border: 1px solid rgba(0, 229, 200, 0.4);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition:
      transform 0.08s linear,
      width 0.2s,
      height 0.2s,
      border-color 0.2s;
  }

  body:hover #cursor {
    opacity: 1;
  }
}

/* Hide cursor elements on touch devices */
@media (hover: none) {
  #cursor,
  #cursor-ring {
    display: none !important;
  }
}

/* ─── NAV ────────────────────────────────────────── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 60px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition:
    background 0.3s,
    backdrop-filter 0.3s,
    border-color 0.3s;
  border-bottom: 1px solid transparent;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.nav-mark {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.nav-name {
  font-family: var(--font-head);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--white);
}

.nav-name span {
  color: var(--cyan);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--subtle);
  text-decoration: none;
  transition: color 0.15s;
}

.nav-links a:hover {
  color: var(--white);
}

.nav-cta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bg) !important;
  background: var(--cyan);
  padding: 8px 18px;
  clip-path: polygon(0 0,
      calc(100% - 6px) 0,
      100% 6px,
      100% 100%,
      6px 100%,
      0 calc(100% - 6px));
  transition: box-shadow 0.2s !important;
}

.nav-cta:hover {
  box-shadow: 0 0 20px var(--cyan-glow) !important;
  color: var(--bg) !important;
}

/* ─── HERO — full-bleed ─────────────────────────── */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 700px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url("../images/hero-bg.png");
  background-size: cover;
  background-position: center center;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse at 50% 40%,
      rgba(6, 9, 16, 0.3) 0%,
      rgba(6, 9, 16, 0.7) 70%),
    linear-gradient(to bottom,
      rgba(6, 9, 16, 0.4) 0%,
      rgba(6, 9, 16, 0.15) 30%,
      rgba(6, 9, 16, 0.15) 60%,
      rgba(6, 9, 16, 0.95) 100%);
}

/* ─── Hero centered content ──────────────────────── */
.hero-center {
  position: relative;
  z-index: 5;
  text-align: center;
  max-width: 720px;
  padding: 0 24px;
}

.hero-eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeUp 0.7s 0.2s ease both;
  border: 1px solid var(--border-md);
  padding: 6px 16px;
  border-radius: 999px;
}

.hero-eyebrow::before {
  display: none;
}

.hero-h1 {
  font-family: var(--font-head);
  font-size: clamp(36px, 5vw, 62px);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeUp 0.7s 0.35s ease both;
  max-width: none;
}

.hero-body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 300;
  margin: 0 auto 40px auto;
  max-width: 520px;
  opacity: 0;
  animation: fadeUp 0.7s 0.5s ease both;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.7s 0.65s ease both;
}

/* ─── Unified Button System ─────────────────────── */
.btn-primary {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--cyan);
  border: none;
  padding: 14px 28px;
  clip-path: polygon(0 0,
      calc(100% - 8px) 0,
      100% 8px,
      100% 100%,
      8px 100%,
      0 calc(100% - 8px));
  transition:
    box-shadow 0.2s,
    transform 0.15s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary:hover {
  box-shadow: 0 0 32px var(--cyan-glow);
  transform: translateY(-1px);
}

/* Hero CTA uses the same system but larger */
.hero-cta-btn {
  padding: 16px 36px;
  font-size: 13px;
}

/* ─── SECTION BASE ───────────────────────────────── */
section.features-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 120px 60px;
}

.features-title {
  font-family: var(--font-head);
  font-size: clamp(28px, 3.5vw, 44px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--white);
  margin-bottom: 16px;
}

.features-sub {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--subtle);
  font-weight: 300;
  max-width: 560px;
  margin-bottom: 72px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-item {
  background: transparent;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.feature-icon {
  width: 56px;
  height: 56px;
  border: 1px solid var(--border-md);
  border-radius: 14px;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  color: var(--cyan);
  transition: box-shadow 0.3s, transform 0.3s, border-color 0.3s;
}

.feature-item:hover .feature-icon {
  border-color: var(--cyan);
  box-shadow: 0 0 20px var(--cyan-glow);
  transform: translateY(-3px);
}

.feature-name {
  font-family: var(--font-head);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--white);
  margin-bottom: 12px;
}

.feature-desc {
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.7;
  color: var(--subtle);
  font-weight: 300;
}

/* ─── CTA SECTION ────────────────────────────────── */
.cta-section {
  max-width: 100%;
  padding: 0;
  border-top: 1px solid var(--border);
}

.cta-inner {
  max-width: 640px;
  margin: 0 auto;
  padding: 100px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 40px;
}

.cta-title {
  font-family: var(--font-head);
  font-size: clamp(28px, 3.5vw, 48px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.05;
  color: var(--white);
  margin-bottom: 14px;
}

.cta-title em {
  font-style: normal;
  color: var(--cyan);
}

.cta-sub {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--subtle);
  font-weight: 300;
  line-height: 1.7;
  max-width: 420px;
}

.cta-right {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  max-width: 400px;
}

.email-input-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.email-input {
  background: var(--surface);
  border: 1px solid var(--border-md);
  padding: 14px 18px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--white);
  outline: none;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  width: 100%;
}

.email-input::placeholder {
  color: var(--muted);
}

.email-input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px var(--cyan-dim);
}

/* ─── LEGAL DOCUMENTS ────────────────────────────── */
.document-section {
  max-width: 800px;
  margin: 0 auto;
  padding: 160px 24px 100px 24px;
}

.document-header {
  margin-bottom: 64px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--border-md);
}

.document-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 24px;
}

.document-title {
  font-family: var(--font-head);
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--white);
}

.document-content {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.8;
  color: var(--subtle);
  font-weight: 300;
}

.document-content h2 {
  font-family: var(--font-head);
  font-size: 24px;
  font-weight: 700;
  color: var(--white);
  margin: 48px 0 20px 0;
  letter-spacing: -0.01em;
}

.document-content p {
  margin-bottom: 24px;
}

.document-content ul {
  margin-bottom: 24px;
  padding-left: 20px;
}

.document-content li {
  margin-bottom: 10px;
}

.document-content a {
  color: var(--cyan);
  text-decoration: none;
  border-bottom: 1px solid var(--cyan-dim);
  transition: border-color 0.2s;
}

.document-content a:hover {
  border-color: var(--cyan);
}

/* ─── FOOTER ─────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 60px;
  max-width: 100%;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-copy {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.06em;
}

.footer-links {
  display: flex;
  gap: 28px;
  list-style: none;
}

.footer-links a {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-links a:hover {
  color: var(--subtle);
}

/* ─── KEYFRAMES ──────────────────────────────────── */
@keyframes pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(0.85);
  }
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}

.reveal.visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* ─── MOBILE ─────────────────────────────────────── */
@media (max-width: 900px) {
  nav {
    padding: 0 24px;
  }

  .nav-links {
    display: none;
  }

  .hero-center {
    padding: 0 16px;
  }

  .hero-h1 {
    font-size: clamp(28px, 7vw, 42px);
  }

  .cta-inner {
    padding: 72px 24px;
  }

  section.features-section {
    padding: 72px 24px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  footer {
    padding: 32px 24px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .document-section {
    padding: 120px 20px 80px 20px;
  }
}