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

:root {
  /* KERNAX BRAND PALETTE: Obsidian & Electric Cyan */
  --k-bg: #090A0F;              /* Pitch Black / Obsidian */
  --k-surface: #11131C;         /* Deep Slate / Cards */
  --k-surface-hover: #161A25;   /* Lighter Slate */
  
  --k-border: #1F2533;          /* Subtle Blue-ish Gray */
  --k-border-hover: #323C52;    
  
  --k-primary: #00F0FF;         /* Electric Cyan / Neon Blue */
  --k-primary-dark: #00B3C7;    /* Darker Cyan for hovers */
  --k-primary-dim: rgba(0, 240, 255, 0.1); 
  --k-primary-glow: rgba(0, 240, 255, 0.3);

  --k-text-main: #F8FAFC;       /* White-ish */
  --k-text-muted: #94A3B8;      /* Slate Gray */
  
  --k-success: #22D3EE;         /* Cyan success (keeping it in palette) */
  --k-alert: #F43F5E;           /* Red for dots/errors */
  --k-warn: #FBBF24;            /* Yellow for dots */
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--k-bg);
  color: var(--k-text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Cursor/Grid Background mapped to Kernax Palette */
.grid-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 150vh;
  background-image: 
    linear-gradient(to right, var(--k-border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--k-border) 1px, transparent 1px);
  background-size: 4rem 4rem;
  mask-image: radial-gradient(circle at 50% 30%, black, transparent 70%);
  -webkit-mask-image: radial-gradient(circle at 50% 30%, black, transparent 70%);
  z-index: -2;
  pointer-events: none;
  opacity: 0.5;
}

/* The Core Glow (Electric Cyan Core) */
.core-glow {
  position: absolute;
  top: 10%;
  left: 50%;
  transform: translateX(-50%);
  width: 50vw;
  height: 50vh;
  background: radial-gradient(circle, var(--k-primary-dim), transparent 70%);
  filter: blur(120px);
  z-index: -1;
  pointer-events: none;
}

/* Navbar */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 24px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: rgba(9, 10, 15, 0.6);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--k-border);
}

.logo {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--k-text-main);
  display: flex;
  align-items: center;
  gap: 12px;
  letter-spacing: -0.02em;
}
.logo svg { width: 22px; height: 22px; stroke: var(--k-primary); }

.nav-links {
  display: flex;
  gap: 40px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-links a {
  color: var(--k-text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--k-primary); }

.auth-links a {
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  margin-left: 24px;
}
.btn-text { color: var(--k-text-muted); transition: color 0.2s; }
.btn-text:hover { color: var(--k-text-main); }

.btn-pill {
  background: var(--k-primary);
  color: var(--k-bg);
  padding: 8px 20px;
  border-radius: 99px;
  font-weight: 600;
  transition: all 0.2s;
  box-shadow: 0 0 15px var(--k-primary-glow);
}
.btn-pill:hover { transform: scale(1.05); background: var(--k-text-main); box-shadow: 0 0 25px rgba(255,255,255,0.4); }

/* Hero */
.hero {
  padding: 180px 20px 80px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.hero-pill {
  border: 1px solid var(--k-primary);
  background: var(--k-primary-dim);
  padding: 6px 16px;
  border-radius: 99px;
  font-size: 0.85rem;
  color: var(--k-primary);
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: fadeUp 1s ease-out;
}
.hero-pill span { color: var(--k-text-main); font-weight: 600; }

h1 {
  font-size: clamp(3.5rem, 7vw, 6.5rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1;
  max-width: 1000px;
  margin-bottom: 24px;
  animation: fadeUp 1s ease-out 0.1s both;
}
.h1-glow {
  background: linear-gradient(180deg, var(--k-text-main) 0%, var(--k-text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: clamp(1.2rem, 2vw, 1.4rem);
  color: var(--k-text-muted);
  max-width: 650px;
  font-weight: 400;
  margin-bottom: 48px;
  letter-spacing: -0.01em;
  animation: fadeUp 1s ease-out 0.2s both;
}

.hero-cta {
  display: flex;
  gap: 16px;
  animation: fadeUp 1s ease-out 0.3s both;
}

.btn-hero {
  background: var(--k-primary);
  color: var(--k-bg);
  padding: 16px 36px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  box-shadow: 0 4px 20px var(--k-primary-glow);
  transition: all 0.2s;
}
.btn-hero:hover { background: var(--k-text-main); transform: translateY(-1px); box-shadow: 0 6px 30px rgba(255,255,255,0.3);}

.btn-hero-outline {
  background: transparent;
  color: var(--k-text-main);
  padding: 16px 36px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 1.05rem;
  text-decoration: none;
  border: 1px solid var(--k-border);
  transition: all 0.2s;
}
.btn-hero-outline:hover { background: var(--k-surface); border-color: var(--k-border-hover); }

/* Mockup */
.mockup-wrapper {
  margin-top: 100px;
  width: 100%;
  max-width: 1200px;
  animation: fadeUp 1s ease-out 0.4s both;
  padding: 0 20px;
}

.mac-window {
  background: var(--k-surface);
  border: 1px solid var(--k-border);
  border-radius: 12px;
  box-shadow: 0 40px 100px rgba(0,0,0,0.9), 0 0 0 1px rgba(0, 240, 255, 0.05) inset;
  overflow: hidden;
}

.mac-header {
  height: 48px;
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 8px;
  border-bottom: 1px solid var(--k-border);
  background: rgba(0,0,0,0.3);
}

.mac-dot { width: 12px; height: 12px; border-radius: 50%; }
.m-red { background: var(--k-alert); }
.m-yellow { background: var(--k-warn); }
.m-green { background: #27C93F; } /* Apple Green exact */

.mac-title {
  margin: 0 auto;
  font-size: 0.8rem;
  color: var(--k-text-muted);
}

.mac-body { display: flex; height: 600px; }

.sidebar {
  width: 240px;
  border-right: 1px solid var(--k-border);
  padding: 20px;
  background: rgba(0,0,0,0.2);
}

.editor-area {
  flex: 1;
  padding: 32px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  color: #D4D4D4; /* VS Code standard */
  line-height: 1.7;
}

.chat-panel {
  width: 380px;
  border-left: 1px solid var(--k-border);
  display: flex;
  flex-direction: column;
  background: rgba(0,0,0,0.2);
}

.chat-bubble {
  margin: 16px;
  padding: 16px;
  border-radius: 8px;
  font-size: 0.9rem;
}
.chat-user {
  background: var(--k-border);
  color: var(--k-text-main);
}
.chat-agent {
  border: 1px solid var(--k-primary-dim);
  background: rgba(0, 240, 255, 0.03);
}

.terminal-line { color: var(--k-text-muted); display: block; margin-top: 8px;}
.terminal-line.success { color: var(--k-primary); } /* Glowing success */

/* Agentic Layout (Qoder Style) */
.agentic-section {
    padding: 120px 5%;
    max-width: 1400px;
    margin: 0 auto;
}
.agentic-container {
    display: flex;
    gap: 60px;
    align-items: center;
}
.agentic-left {
    flex: 0 0 40%;
}
.agentic-left h2 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.04em;
}
.agentic-sub {
    color: var(--k-text-muted);
    font-size: 1.15rem;
    margin-bottom: 40px;
    line-height: 1.6;
}
.agentic-tabs {
    display: flex;
    flex-direction: column;
}
.a-tab {
    padding: 24px 0 24px 32px;
    border-left: 2px solid var(--k-border);
    cursor: pointer;
    transition: all 0.3s;
    opacity: 0.4;
}
.a-tab:hover {
    opacity: 0.8;
}
.a-tab h4 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--k-text-main);
    letter-spacing: -0.02em;
}
.a-tab p {
    color: var(--k-text-muted);
    font-size: 1rem;
    line-height: 1.5;
}
.a-tab.active {
    border-left-color: var(--k-success);
    opacity: 1;
}
.a-tab.active h4 {
    color: var(--k-success);
}
.badge {
    background: rgba(34, 211, 238, 0.1);
    color: var(--k-success);
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 600;
}

.agentic-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}
.agentic-video-wrapper {
    width: 100%;
    background: #000;
    padding: 16px;
    border-radius: 20px;
    border: 1px solid var(--k-border);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.9);
    position: relative;
}
.agentic-video-wrapper::before {
    content: '';
    position: absolute;
    top: -2px; left: -2px; right: -2px; bottom: -2px;
    background: linear-gradient(135deg, var(--k-success) 0%, transparent 60%);
    z-index: -1;
    border-radius: 22px;
    opacity: 0.5;
}
.agentic-video-wrapper video {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    display: block;
}

/* Testimonials */
.testimonials-section {
  padding: 100px 5%;
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid var(--k-border);
}

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

.t-card {
  background: var(--k-surface);
  border: 1px solid var(--k-border);
  border-radius: 16px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.t-quote {
  font-size: 1.05rem;
  color: var(--k-text-main);
  line-height: 1.6;
  margin-bottom: 32px;
  font-style: italic;
}

.t-author {
  display: flex;
  align-items: center;
  gap: 16px;
}

.t-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  color: #fff;
}

.t-author strong {
  display: block;
  font-size: 1rem;
  color: var(--k-text-main);
}

.t-author span {
  font-size: 0.85rem;
  color: var(--k-text-muted);
}

/* Pricing Grid */
.pricing {
  padding: 100px 5%;
  max-width: 1000px;
  margin: 0 auto;
  border-top: 1px solid var(--k-border);
}

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 60px;
}

.p-card {
  border: 1px solid var(--k-border);
  border-radius: 16px;
  padding: 48px;
  background: var(--k-surface);
}

.p-card.pro {
  background: linear-gradient(145deg, var(--k-surface-hover), var(--k-surface));
  border: 1px solid var(--k-primary);
  box-shadow: 0 0 60px var(--k-primary-dim);
}

.p-card h3 { font-size: 1.5rem; font-weight: 600; margin-bottom: 8px;}
.p-price { font-size: 3.5rem; font-weight: 700; letter-spacing: -0.04em; margin-bottom: 32px; color: var(--k-primary);}
.p-card:not(.pro) .p-price { color: var(--k-text-main); }
.p-price span { font-size: 1rem; color: var(--k-text-muted); font-weight: 400;}

.p-list { list-style: none; margin-bottom: 40px; }
.p-list li {
  margin-bottom: 16px; color: var(--k-text-muted);
  display: flex; align-items: center; gap: 12px;
}
.p-list li::before { content: '→'; color: var(--k-primary); }

/* Footer */
footer {
  border-top: 1px solid var(--k-border);
  padding: 80px 40px 40px;
  background: var(--k-bg);
}

.footer-content {
  max-width: 1200px; margin: 0 auto;
  display: flex; justify-content: space-between;
}

.f-brand { color: var(--k-text-main); font-weight: 600;}
.f-links { display: flex; gap: 80px; }
.f-col { display: flex; flex-direction: column; gap: 16px; }
.f-col a { color: var(--k-text-muted); text-decoration: none; font-size: 0.9rem; transition: color 0.2s;}
.f-col a:hover { color: var(--k-primary); }

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

@media (max-width: 800px) {
  .nav-links { display: none; }
  .mac-body { flex-direction: column; height: auto; }
  .sidebar, .chat-panel { width: 100%; border: none; border-bottom: 1px solid var(--k-border); }
  .bento { grid-template-columns: 1fr; }
  .b-card.wide, .b-card.tall { grid-column: span 1; grid-row: span 1; }
  .pricing-grid { grid-template-columns: 1fr; }
  .footer-content { flex-direction: column; gap: 40px; }
}
