/* ==========================================================================
   svozar.com — Refined Light Editorial + Autonomous Trajectory Design System
   ========================================================================== */

:root {
  --bg: #f8fafc;
  --bg-elevated: rgba(255, 255, 255, 0.88);
  --bg-card: rgba(255, 255, 255, 0.94);
  --bg-card-solid: #ffffff;
  --bg-pill: rgba(15, 23, 42, 0.05);

  --border: rgba(15, 23, 42, 0.09);
  --border-hover: rgba(29, 78, 216, 0.35);

  --text: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;

  --accent: #0284c7;
  --accent-strong: #1d4ed8;
  --accent-glow: rgba(29, 78, 216, 0.08);
  --emerald: #059669;

  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
  --shadow-card: 0 4px 16px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.03);
  --shadow-card-hover: 0 14px 32px rgba(15, 23, 42, 0.1), 0 3px 8px rgba(15, 23, 42, 0.04);

  --font-display: "Space Grotesk", "Inter", -apple-system, sans-serif;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --max-width: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background-color: var(--bg);
  line-height: 1.65;
  overflow-x: hidden;
}

a {
  color: var(--accent-strong);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--accent);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Scroll Progress Bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  z-index: 999;
  background: linear-gradient(90deg, var(--accent-strong), var(--accent), var(--emerald));
  transition: width 0.05s linear;
}

/* ==========================================================================
   Floating Glassmorphic Navbar
   ========================================================================== */

.nav-wrap {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 0.85rem 1.25rem;
}

.nav-bar {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.65rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--bg-elevated);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.07);
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

.nav-brand:hover {
  color: var(--text);
}

.status-pulse {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 0 0 rgba(5, 150, 105, 0.55);
  animation: pulse 2.4s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(5, 150, 105, 0.55); }
  70% { box-shadow: 0 0 0 8px rgba(5, 150, 105, 0); }
  100% { box-shadow: 0 0 0 0 rgba(5, 150, 105, 0); }
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  padding: 0.42rem 0.9rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.nav-links a:hover,
.nav-links a.active,
.nav-links a[aria-current="page"] {
  color: var(--accent-strong);
  background: rgba(29, 78, 216, 0.08);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.4rem;
  padding: 0.38rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-card-solid);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
}

.nav-toggle svg {
  width: 16px;
  height: 16px;
}

/* ==========================================================================
   Light Hero Section with Subtle Autonomous Trajectory Canvas
   ========================================================================== */

.hero {
  position: relative;
  min-height: 76vh;
  display: flex;
  align-items: center;
  padding: 3rem 1.5rem 4.25rem;
  overflow: hidden;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-bottom: 1px solid var(--border);
}

#trajectory-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.hero-glow {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 50% at 78% 22%, rgba(29, 78, 216, 0.08), transparent 70%),
    radial-gradient(ellipse 50% 45% at 12% 80%, rgba(5, 150, 105, 0.06), transparent 65%);
}

.hero-container {
  position: relative;
  z-index: 2;
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.28fr 0.72fr;
  gap: 3rem;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(29, 78, 216, 0.07);
  border: 1px solid rgba(29, 78, 216, 0.18);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-strong);
  margin-bottom: 1.25rem;
}

.hero-title {
  margin: 0 0 1.05rem;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 4.4vw, 3.45rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.035em;
  color: var(--text);
}

.gradient-text {
  background: linear-gradient(120deg, #0f172a 0%, #1d4ed8 55%, #059669 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  margin: 0 0 1.75rem;
  max-width: 54ch;
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

.hero-lead strong {
  color: var(--text);
  font-weight: 600;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.72rem 1.3rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.btn svg {
  width: 16px;
  height: 16px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-strong), #0284c7);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(29, 78, 216, 0.25);
}

.btn-primary:hover {
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(29, 78, 216, 0.35);
}

.btn-ghost {
  background: var(--bg-card-solid);
  border-color: var(--border);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}

.btn-ghost:hover {
  color: var(--accent-strong);
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

/* Clean Portrait Frame */
.portrait-frame {
  position: relative;
  justify-self: center;
  width: 284px;
}

.portrait-card {
  position: relative;
  border-radius: 50%;
  padding: 8px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border);
  box-shadow: 0 18px 44px rgba(15, 23, 42, 0.12), 0 4px 12px rgba(15, 23, 42, 0.05);
}

.portrait-card img {
  width: 268px;
  height: 268px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center 20%;
  border-radius: 50%;
}

/* ==========================================================================
   Sections & Bento Grid
   ========================================================================== */

.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 1.5rem;
}

.section-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2rem;
}

.section-kicker {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-strong);
  margin-bottom: 0.4rem;
}

.section-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

/* Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.15rem;
}

.bento-card {
  position: relative;
  overflow: hidden;
  padding: 1.6rem 1.75rem;
  border-radius: var(--radius-md);
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  --mx: 50%;
  --my: 50%;
}

.bento-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(360px circle at var(--mx) var(--my), var(--accent-glow), transparent 65%);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.bento-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card-hover);
}

.bento-card:hover::before {
  opacity: 1;
}

.bento-card > * {
  position: relative;
  z-index: 1;
}

.span-7 { grid-column: span 7; }
.span-5 { grid-column: span 5; }
.span-4 { grid-column: span 4; }
.span-6 { grid-column: span 6; }
.span-8 { grid-column: span 8; }
.span-12 { grid-column: span 12; }

.bento-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
  margin-bottom: 0.75rem;
}

.bento-card h3 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.bento-card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 2.9rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  margin-bottom: 0.45rem;
  background: linear-gradient(120deg, var(--text), var(--accent-strong));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ==========================================================================
   Career Timeline
   ========================================================================== */

.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding-left: 2rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(180deg, var(--emerald), var(--accent-strong), var(--border));
}

.timeline-item {
  position: relative;
  padding: 1.45rem 1.7rem;
  border-radius: var(--radius-md);
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.timeline-item:hover {
  border-color: var(--border-hover);
  transform: translateX(4px);
  box-shadow: var(--shadow-card);
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -2rem;
  top: 1.7rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--bg-card-solid);
  border: 3px solid var(--accent-strong);
}

.timeline-item--current::before {
  border-color: var(--emerald);
  background: var(--emerald);
  box-shadow: 0 0 0 4px rgba(5, 150, 105, 0.18);
}

.timeline-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--accent-strong);
}

.timeline-item h3 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-size: 1.18rem;
  font-weight: 700;
}

.timeline-item p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* ==========================================================================
   Interactive Patents Explorer
   ========================================================================== */

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-pill {
  padding: 0.42rem 0.95rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-card-solid);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.filter-pill:hover {
  color: var(--text);
  border-color: var(--border-hover);
}

.filter-pill.is-active {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: #ffffff;
}

.patent-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.15rem;
}

.patent-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.5rem;
  border-radius: var(--radius-md);
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.patent-card.is-hidden {
  display: none;
}

.patent-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card-hover);
}

.patent-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
}

.badge-granted {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  background: rgba(5, 150, 105, 0.1);
  color: #047857;
  border: 1px solid rgba(5, 150, 105, 0.25);
}

.badge-app {
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  background: var(--bg-pill);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.patent-org {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.patent-card h3 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
}

.patent-card p {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.patent-nums {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: auto;
}

.patent-num {
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 600;
  background: rgba(29, 78, 216, 0.07);
  border: 1px solid rgba(29, 78, 216, 0.2);
  color: var(--accent-strong);
}

.patent-num:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
  color: #ffffff;
}

/* ==========================================================================
   Media Showcase
   ========================================================================== */

.media-showcase {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.25rem;
  align-items: start;
}

.stage-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--bg-card-solid);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
}

.stage-card-img {
  width: 100%;
  height: auto;
  display: block;
}

.stage-card-body {
  padding: 1.25rem 1.5rem 1.35rem;
}

.stage-card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text);
}

.stage-card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.media-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-height: 395px;
  overflow-y: auto;
  padding-right: 0.35rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(15, 23, 42, 0.2) transparent;
}

.media-link-card {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 1.1rem 1.25rem;
  border-radius: var(--radius-md);
  background: var(--bg-card-solid);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.media-link-card:hover {
  color: var(--accent-strong);
  transform: translateX(4px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card);
}

.media-link-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent-strong);
  text-transform: uppercase;
}

.media-link-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.98rem;
}

/* ==========================================================================
   Scroll Reveal & Footer
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.wild-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-card-solid);
  padding: 2.25rem 1.5rem;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.wild-footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-links a {
  color: var(--text-secondary);
}

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

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
  .hero-container,
  .media-showcase {
    grid-template-columns: 1fr;
  }

  .media-list {
    max-height: none;
    overflow-y: visible;
    padding-right: 0;
  }

  .portrait-frame {
    order: -1;
    width: 196px;
  }

  .portrait-card img {
    width: 180px;
    height: 180px;
  }

  .span-7, .span-5, .span-4, .span-6, .span-8 {
    grid-column: span 12;
  }

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

@media (max-width: 640px) {
  .nav-bar {
    flex-wrap: wrap;
    border-radius: 20px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    padding-top: 0.5rem;
    margin-top: 0.45rem;
    border-top: 1px solid var(--border);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a {
    border-radius: 10px;
  }

  .hero {
    min-height: auto;
    padding: 1.75rem 1.15rem 3rem;
  }

  .section {
    padding: 2.75rem 1.15rem;
  }
}
