/* ============================================================
   AIKE — Main Stylesheet
   styles.css
   ============================================================ */

/* ── Design Tokens ─────────────────────────────────────────── */
:root {
  /* Colors */
  --color-bg:          #111111;
  --color-surface:     #1a1a1a;
  --color-surface-alt: #222222;
  --color-border:      rgba(255, 255, 255, 0.08);
  --color-primary:     #a855f7; /* Bright Purple */
  --color-primary-dim: rgba(168, 85, 247, 0.12);
  --color-accent:      #a855f7; /* Removed cyan, sticking to primary */
  --color-text:        #ffffff;
  --color-text-muted:  #9ca3af;
  --color-white:       #ffffff;

  /* Typography */
  --font-sans: 'Inter', system-ui, sans-serif;
  --font-display: 'Inter', system-ui, sans-serif; /* Minimal implies geometric sans, Inter is great */

  /* Spacing scale */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2.5rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;
  --space-4xl: 8rem;

  /* Layout */
  --max-width: 1200px;
  --nav-height: 80px;

  /* Radii */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-glow:  0 0 40px rgba(168, 85, 247, 0.25);
  --shadow-card:  0 4px 32px rgba(0, 0, 0, 0.2);
  --shadow-nav:   0 1px 0 var(--color-border);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, video, svg {
  display: block;
  max-width: 100%;
}

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

ul, ol {
  list-style: none;
}

button, input, textarea, select {
  font: inherit;
  background: none;
  border: none;
  outline: none;
}

button {
  cursor: pointer;
}

/* ── Typography ────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-white);
}

h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.6rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.6rem); }
h4 { font-size: 1.1rem; }

p {
  color: var(--color-text-muted);
  max-width: 65ch;
}

/* ── Layout ────────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--space-lg);
}

.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.page-main {
  flex: 1;
  /* padding-top removed: aike-header JS sets body.paddingTop dynamically */
}

.section {
  padding-block: var(--space-3xl);
}

.section--sm {
  padding-block: var(--space-2xl);
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 4px 16px rgba(168, 85, 247, 0.3);
}

.btn-primary:hover {
  background: #b673f8; /* slightly lighter purple */
  box-shadow: 0 6px 24px rgba(168, 85, 247, 0.5);
  transform: translateY(-2px) scale(1.02);
}

.btn-outline {
  border: 1px solid var(--color-border);
  color: var(--color-white);
  background: transparent;
}

.btn-outline:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-primary-dim);
  transform: translateY(-2px);
}

.btn-ghost {
  color: var(--color-text-muted);
}

.btn-ghost:hover {
  color: var(--color-white);
}

/* ── Cards ─────────────────────────────────────────────────── */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-xl);
  transition: border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.card:hover {
  border-color: rgba(168, 85, 247, 0.4);
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(168, 85, 247, 0.05);
}

/* ── Badge ─────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--color-primary-dim);
  color: var(--color-primary);
  border: 1px solid rgba(108, 99, 255, 0.3);
}

/* ── Grid utilities ────────────────────────────────────────── */
.grid {
  display: grid;
  gap: var(--space-lg);
}

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

.flex {
  display: flex;
}

.flex-col {
  flex-direction: column;
}

.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }

/* ── Text utilities ────────────────────────────────────────── */
.text-center { text-align: center; }
.text-muted   { color: var(--color-text-muted); }
.text-accent  { color: var(--color-accent); }
.text-primary { color: var(--color-primary); }

/* ── Text emphasis ─────────────────────────────────────────── */
.text-purple {
  color: var(--color-primary);
}

.gradient-text {
  color: var(--color-primary); /* For backwards compatibility, fallback to pure purple */
}

/* ── Section header helper ─────────────────────────────────── */
.section-header {
  text-align: center;
  max-width: 700px;
  margin-inline: auto;
  margin-bottom: var(--space-2xl);
}

.section-header .badge {
  margin-bottom: var(--space-md);
}

.section-header p {
  margin-inline: auto;
  margin-top: var(--space-md);
  font-size: 1.05rem;
}

/* ── Divider ───────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--color-border);
  margin-block: var(--space-xl);
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* ── New Component Architecture (Header/Footer) ───────────── */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-lg);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  background: transparent;
}

.header.scrolled {
  top: 15px;
  padding: 0;
}

.header.scrolled .header__inner {
  background: rgba(255, 255, 255, 0.05); /* Light airy grey glass */
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  height: 60px;
  padding: 0 var(--space-xl);
  max-width: 900px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-width);
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.header__brand-group {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.header__logo {
  height: 34px;
  width: auto;
  object-fit: contain;
}

.header__brand {
  font-family: "Suisse Int'l", "Inter", system-ui, sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: -0.02em;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

/* Desktop Navbar Links */
.header__link {
  position: relative;
  color: var(--color-text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--transition-fast);
  text-decoration: none;
  padding: 4px 0;
}

.header__link:hover {
  color: var(--color-white);
}

.header__link::after {
  content: '';
  position: absolute;
  bottom: 0px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-primary); /* Aike Purple */
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.header__link:hover::after {
  transform: scaleX(1);
}

/* Howl nav link — subtle purple accent */
.header__link--howl {
  color: var(--color-primary);
  opacity: 0.88;
}
.header__link--howl:hover {
  color: var(--color-primary);
  opacity: 1;
}

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* ── Mobile Navigation ─────────────────────────────────────── */
.mobile-nav-trigger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 34px;
  border-radius: 17px;
  background: var(--color-surface-alt);
  border: 1px solid var(--color-border);
  cursor: pointer;
  z-index: 1001;
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.mobile-nav-trigger:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
}

.mobile-nav-trigger-lines {
  position: relative;
  width: 18px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: background var(--transition-fast);
}

.mobile-nav-trigger-lines::before,
.mobile-nav-trigger-lines::after {
  content: '';
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: transform var(--transition-base), top var(--transition-base), bottom var(--transition-base);
}

.mobile-nav-trigger-lines::before { top: -6px; }
.mobile-nav-trigger-lines::after { bottom: -6px; }

.mobile-nav-trigger[aria-expanded="true"] .mobile-nav-trigger-lines { background: transparent; }
.mobile-nav-trigger[aria-expanded="true"] .mobile-nav-trigger-lines::before { top: 0; transform: rotate(45deg); }
.mobile-nav-trigger[aria-expanded="true"] .mobile-nav-trigger-lines::after { bottom: 0; transform: rotate(-45deg); }

.mobile-nav-panel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--color-bg);
  z-index: 999;
  display: flex;
  flex-direction: column;
  padding-top: var(--nav-height);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity var(--transition-base), visibility var(--transition-base), transform var(--transition-base);
}

.mobile-nav-panel.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-nav-panel-inner {
  display: flex;
  flex-direction: column;
  padding: var(--space-xl) var(--space-lg);
  gap: var(--space-sm);
  max-width: 600px;
  margin: 0 auto;
  width: 100%;
}

.mobile-nav-link {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-white);
  padding: 14px 0;
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
  transition: color var(--transition-fast);
}

.mobile-nav-link:hover {
  color: var(--color-primary);
}

.mobile-nav-divider {
  display: none;
}

@media (max-width: 768px) {
  .hide-on-mobile { display: none !important; }
  .mobile-nav-trigger { display: flex; }
}

@media (min-width: 769px) {
  .mobile-nav-panel { display: none !important; }
}

/* ── Footer ────────────────────────────────────────────────── */
.footer {
  background: var(--color-surface);
  padding-top: var(--space-3xl);
  padding-bottom: var(--space-xl);
  position: relative;
  overflow: hidden;
}

.footer__wave {
  width: 200%;
  height: 48px;
  background: url('data:image/svg+xml;utf8,<svg preserveAspectRatio="none" viewBox="0 0 1200 48" xmlns="http://www.w3.org/2000/svg"><path d="M0,24 C300,48 300,0 600,24 C900,48 900,0 1200,24 L1200,48 L0,48 Z" fill="%23151515"/><path d="M0,24 C300,48 300,0 600,24 C900,48 900,0 1200,24" fill="none" stroke="rgba(255,255,255,0.06)" stroke-width="1.5"/></svg>');
  background-size: 50% 100%;
  animation: waveAnimate 12s linear infinite;
  z-index: 10;
  pointer-events: none;
}

@keyframes waveAnimate {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.footer__bg-animate {
  position: absolute;
  top: -50%;
  left: -20%;
  width: 140%;
  height: 200%;
  background: radial-gradient(circle at 50% 50%, rgba(168, 85, 247, 0.03), transparent 70%);
  pointer-events: none;
  animation: footerSweep 15s ease-in-out infinite alternate;
  z-index: 0;
}

@keyframes footerSweep {
  0% { transform: translateX(-5%) translateY(10%) scale(1); }
  100% { transform: translateX(5%) translateY(-5%) scale(1.1); }
}

.footer__inner {
  position: relative;
  z-index: 1;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1fr 700px; /* Expanded 2x massive video scaling */
  gap: var(--space-4xl);
  align-items: center;
}

.footer__main {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.footer__brand-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: var(--space-md);
}

.footer__brand-logo {
  height: 28px;
  width: auto;
}

.footer__brand {
  font-family: 'Suisse Intl', var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary); /* Aike Purple */
  letter-spacing: -0.02em;
}

.footer__description {
  color: var(--color-text-muted);
  max-width: 480px;
  margin-bottom: var(--space-2xl);
  font-size: 1.05rem;
  line-height: 1.5;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-xl);
  margin-bottom: var(--space-2xl);
}

.footer__link {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  display: inline-block;
  text-decoration: none;
  font-weight: 500;
  transition: transform 0.2s ease, color 0.2s ease;
}

.footer__link:hover {
  color: var(--color-white);
  transform: translateY(-2px); /* Vertical hover lift matching reference */
}

.footer__divider {
  width: 100%;
  height: 1px;
  background: var(--color-border);
  margin: var(--space-2xl) 0;
}

.footer__bottom-text {
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.85rem;
}

.footer__media {
  width: 100%;
}

.footer__video-placeholder {
  width: 100%;
  aspect-ratio: 16/9;
  background: rgba(255, 255, 255, 0.02);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.3);
  font-size: 0.9rem;
  gap: 8px;
  transition: background 0.3s ease;
}

.footer__video-placeholder:hover {
  background: rgba(255, 255, 255, 0.04);
}

@media (max-width: 1024px) {
  .footer__grid {
    grid-template-columns: 1fr;
    gap: var(--space-2xl);
  }
  .footer__video-placeholder {
    max-width: 700px;
    margin: 0 auto;
  }
}

@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }

  .btn {
    width: 100%;
    justify-content: center;
  }
  
  .footer__nav {
    flex-direction: column;
    gap: var(--space-md);
  }
}

/* ── Navbar Direct Links ── */
.aike-deskLeft {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.aike-navLink {
  position: relative;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-white);
  text-decoration: none;
  padding: 8px 0;
  display: inline-block;
  transition: color 0.3s ease;
}

.aike-scrolled .aike-navLink {
  color: var(--color-text-main);
}

.aike-navLink::after {
  content: '';
  position: absolute;
  bottom: 0px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--color-primary); /* Aike Purple */
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.aike-navLink:hover::after {
  transform: scaleX(1);
}

.aike-navLinksMobile .aike-navLink {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--color-text-main);
  width: max-content;
}
