/* ============================================================
   Pixosight — Shared Design System
   Glassmorphism / Frosted aesthetic
   ============================================================ */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

/* --- Design Tokens --- */
:root {
  /* Background — cool blue-white, derived from icon palette */
  --bg-start:       #eef5fa;
  --bg-mid:         #e6f1f8;
  --bg-end:         #eef5f9;

  /* Accent — steel blue from the icon lens gradient */
  --accent:         #3cb6e8;
  --accent-deep:    #2890be;
  --accent-light:   #d6eef9;
  --accent-glow:    rgba(60, 182, 232, 0.18);

  /* Navy — from the icon's dark background / shape color */
  --navy:           #2d3a4e;
  --navy-mid:       #3a4c60;
  --navy-light:     #e4eaef;

  /* Keep these names for compatibility but map to icon palette */
  --violet:         var(--navy);
  --violet-light:   var(--navy-light);

  /* Text */
  --text-primary:   #1c2a38;   /* dark navy, from icon */
  --text-secondary: #435060;
  --text-muted:     #7d8fa0;
  --text-inverse:   #ffffff;

  /* Glass card */
  --glass-bg:       rgba(255, 255, 255, 0.65);
  --glass-border:   rgba(255, 255, 255, 0.88);
  --glass-shadow:   0 8px 32px rgba(44, 80, 110, 0.10), 0 1.5px 6px rgba(44,80,110,0.06);
  --glass-blur:     blur(18px);

  /* Surfaces */
  --surface-raised: rgba(255, 255, 255, 0.85);

  /* Borders */
  --border-subtle:  rgba(150, 190, 215, 0.32);

  /* Spacing scale — complete, no gaps */
  --sp-1:  0.25rem;
  --sp-2:  0.5rem;
  --sp-3:  0.75rem;
  --sp-4:  1rem;
  --sp-5:  1.25rem;
  --sp-6:  1.5rem;
  --sp-8:  2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;
  --sp-14: 3.5rem;
  --sp-16: 4rem;
  --sp-20: 5rem;
  --sp-24: 6rem;

  /* Radius */
  --r-sm:  8px;
  --r-md:  14px;
  --r-lg:  22px;
  --r-xl:  32px;
  --r-full: 9999px;

  /* Type */
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Transitions */
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --dur:  200ms;
}

/* --- Global Body --- */
body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: linear-gradient(135deg, var(--bg-start) 0%, var(--bg-mid) 50%, var(--bg-end) 100%);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Fixed animated gradient orbs (ambient background) */
body::before,
body::after {
  content: '';
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}
body::before {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #a8d8ef, transparent 70%);
  top: -150px; left: -100px;
}
body::after {
  width: 500px; height: 500px;
  background: radial-gradient(circle, #b6cfe0, transparent 70%);
  bottom: 0; right: -100px;
}

/* All page content sits above the orbs */
nav, main, footer, section, header, .container {
  position: relative;
  z-index: 1;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.4rem); }
h4 { font-size: 1.05rem; }

p {
  color: var(--text-secondary);
  line-height: 1.75;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}
a:hover { color: var(--accent-deep); }

/* --- Layout --- */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--sp-6);
}

.section {
  padding: clamp(3rem, 7vw, 5rem) 0;
}

.section--sm {
  padding: clamp(2rem, 5vw, 3.5rem) 0;
}

/* --- Navigation --- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: var(--sp-4) 0;
}

.nav__inner {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-xl);
  padding: var(--sp-3) var(--sp-6);
  box-shadow: 0 4px 20px rgba(44, 80, 110, 0.08);
  margin: 0 var(--sp-6);
}

.nav__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.nav__logo img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.nav__logo-wordmark span {
  color: var(--accent);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  list-style: none;
}

.nav__links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-sm);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.nav__links a:hover,
.nav__links a.active {
  color: var(--accent);
  background: var(--accent-light);
}

.nav__cta {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

.nav__signin {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-sm);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.nav__signin:hover {
  color: var(--accent);
  background: var(--accent-light);
}

.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: var(--r-sm);
  flex-shrink: 0;
  margin-left: var(--sp-1);
}
.nav__hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav__hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__hamburger.open span:nth-child(2) { opacity: 0; }
.nav__hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nav__mobile {
  display: none;
  flex-direction: column;
  padding-top: var(--sp-3);
  margin-top: var(--sp-2);
  border-top: 1px solid var(--border-subtle);
  gap: var(--sp-1);
}
.nav__mobile.open { display: flex; }
.nav__mobile a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: var(--sp-3) var(--sp-2);
  border-radius: var(--r-sm);
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.nav__mobile a:hover,
.nav__mobile a.active {
  color: var(--accent);
  background: var(--accent-light);
}
.nav__mobile-divider {
  border: none;
  border-top: 1px solid var(--border-subtle);
  margin: var(--sp-2) 0;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.9rem;
  padding: var(--sp-3) var(--sp-6);
  border-radius: var(--r-full);
  border: none;
  cursor: pointer;
  transition: all var(--dur) var(--ease);
  text-decoration: none;
  white-space: nowrap;
}

.btn--primary {
  background: linear-gradient(135deg, var(--accent), var(--navy));
  color: #fff;
  box-shadow: 0 4px 16px rgba(60, 182, 232, 0.30);
}
.btn--primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(60, 182, 232, 0.40);
  color: #fff;
}
.btn--primary:active { transform: translateY(0); }

.btn--ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
}
.btn--ghost:hover {
  background: var(--glass-bg);
  color: var(--text-primary);
  border-color: rgba(180, 195, 255, 0.6);
}

.btn--outline {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}
.btn--outline:hover {
  background: var(--accent-light);
  color: var(--accent-deep);
}

.btn--lg {
  font-size: 1rem;
  padding: var(--sp-4) var(--sp-8);
}

/* --- Glass Cards --- */
.card {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-lg);
  box-shadow: var(--glass-shadow);
  padding: var(--sp-8);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 48px rgba(80, 100, 200, 0.14), 0 3px 10px rgba(80,100,200,0.08);
}

/* --- Section Labels --- */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-light);
  padding: var(--sp-1) var(--sp-3);
  border-radius: var(--r-full);
  margin-bottom: var(--sp-4);
}

/* --- Section Header --- */
.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto var(--sp-12);
}

.section-header p {
  margin-top: var(--sp-4);
  font-size: 1.05rem;
}

/* --- Grids --- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-6);
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--sp-6);
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-6);
}

/* --- Icon Chips --- */
.icon-chip {
  width: 48px;
  height: 48px;
  border-radius: var(--r-md);
  background: linear-gradient(135deg, var(--accent-light), var(--navy-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: var(--sp-4);
  flex-shrink: 0;
}

/* --- Badge / Pill --- */
.badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 10px;
  border-radius: var(--r-full);
}

.badge--accent { background: var(--accent-light); color: var(--accent-deep); }
.badge--violet { background: var(--violet-light); color: var(--violet); }
.badge--green  { background: #d1fae5; color: #065f46; }

/* --- Divider --- */
.divider {
  border: none;
  border-top: 1px solid var(--border-subtle);
  margin: var(--sp-12) 0;
}

/* --- Footer --- */
.footer {
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-top: 1px solid var(--border-subtle);
  padding: var(--sp-12) 0 var(--sp-8);
  margin-top: var(--sp-20);
}

.footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--sp-8);
  margin-bottom: var(--sp-8);
}

.footer__brand p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: var(--sp-3);
  max-width: 280px;
}

.footer__col h4 {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--sp-4);
}

.footer__col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.footer__col ul a {
  font-size: 0.88rem;
  color: var(--text-secondary);
  transition: color var(--dur) var(--ease);
}
.footer__col ul a:hover { color: var(--accent); }

.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--sp-6);
  border-top: 1px solid var(--border-subtle);
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* --- Hero screenshot/mockup frame --- */
.app-frame {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-lg);
  box-shadow: 0 24px 80px rgba(80, 100, 200, 0.18), 0 4px 20px rgba(80,100,200,0.10);
  overflow: hidden;
}

.app-frame__bar {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-4);
  background: rgba(255, 255, 255, 0.8);
  border-bottom: 1px solid var(--border-subtle);
}

.app-frame__dot {
  width: 11px; height: 11px;
  border-radius: 50%;
}
.app-frame__dot:nth-child(1) { background: #ff5f57; }
.app-frame__dot:nth-child(2) { background: #ffbd2e; }
.app-frame__dot:nth-child(3) { background: #28ca41; }

.app-frame__content {
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, #e8eeff 0%, #ede9fe 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.app-frame__content img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* --- Gradient text --- */
.gradient-text {
  background: linear-gradient(135deg, var(--accent), var(--navy));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Stat strip --- */
.stat-strip {
  display: flex;
  align-items: center;
  gap: var(--sp-8);
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-item__value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
  letter-spacing: -0.03em;
}

.stat-item__label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}

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

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

  .nav__links { display: none; }
  .nav__signin { display: none; }
  .nav__hamburger { display: flex; }
  .nav__inner { padding: var(--sp-3) var(--sp-4); }

  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__brand { grid-column: 1 / -1; }
  .footer__bottom { flex-direction: column; gap: var(--sp-2); text-align: center; }
}

@media (max-width: 480px) {
  .grid-4 { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .stat-strip { gap: var(--sp-6); }
  .nav__inner { margin: 0 var(--sp-3); }
}

/* --- Utility classes --- */
.text-center { text-align: center; }
.text-muted   { color: var(--text-muted); }
.mt-2  { margin-top: var(--sp-2); }
.mt-4  { margin-top: var(--sp-4); }
.mt-6  { margin-top: var(--sp-6); }
.mt-8  { margin-top: var(--sp-8); }
.mt-12 { margin-top: var(--sp-12); }
.mb-4  { margin-bottom: var(--sp-4); }
.mb-6  { margin-bottom: var(--sp-6); }
.mb-8  { margin-bottom: var(--sp-8); }
.flex  { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-2 { gap: var(--sp-2); }
.gap-3 { gap: var(--sp-3); }
.gap-4 { gap: var(--sp-4); }

/* --- Checkmark list --- */
.check-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.check-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.check-list li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}

.check-list--muted li::before { color: var(--text-muted); }
.check-list--muted li { color: var(--text-muted); text-decoration: line-through; }

/* --- Scroll reveal (JS adds class) --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* --- Lightbox --- */
.lb {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  z-index: 9000;
  align-items: center;
  justify-content: center;
  padding: var(--sp-8);
  cursor: zoom-out;
}
.lb--open { display: flex; }
.lb__img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--r-md);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6);
  pointer-events: none;
}
