/* ==========================================================================
   JAGRIX — Engineering Presentation Slides Stylesheet (style.css)
   Clean, open editorial layout with zero box enclosures and fluid typography
   ========================================================================== */

:root {
  --bg-main: #07090e;
  --border-subtle: rgba(255, 255, 255, 0.1);
  --border-accent: rgba(0, 240, 255, 0.4);

  --accent-cyan: #00f0ff;
  --accent-blue: #3b82f6;
  --accent-violet: #8b5cf6;
  --accent-emerald: #10b981;

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-faint: #334155;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --container-max: 1180px;
}

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

html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  color-scheme: dark;
}

body.jagrix-body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-sans);
  line-height: 1.5;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Ambient Subtle Lighting */
.ambient-vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: 
    radial-gradient(circle at 10% 15%, rgba(0, 240, 255, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 90% 85%, rgba(139, 92, 246, 0.04) 0%, transparent 45%),
    radial-gradient(circle at 50% 50%, rgba(15, 23, 42, 0.25) 0%, rgba(7, 9, 14, 0.98) 100%);
}

/* --------------------------------------------------------------------------
   Top Scroll Progress Bar
   -------------------------------------------------------------------------- */
.scroll-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-blue), var(--accent-violet));
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.6);
  z-index: 999;
  transition: width 0.1s ease-out;
}

/* --------------------------------------------------------------------------
   Floating Slide Pagination Dots (Right Side)
   -------------------------------------------------------------------------- */
.slide-dots-nav {
  position: fixed;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 120;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 6px;
  background: rgba(7, 9, 14, 0.6);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 30px;
}

.slide-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  border: none;
  cursor: pointer;
  position: relative;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 0;
}

.slide-dot:hover {
  background: var(--text-secondary);
  transform: scale(1.3);
}

.slide-dot.active {
  background: var(--accent-cyan);
  box-shadow: 0 0 12px var(--accent-cyan);
  transform: scale(1.35);
  height: 18px;
  border-radius: 9px;
}

.slide-dot .dot-tooltip {
  position: absolute;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(13, 17, 23, 0.95);
  border: 1px solid var(--border-accent);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 1px;
  white-space: nowrap;
  padding: 4px 10px;
  border-radius: 4px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, transform 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.slide-dot:hover .dot-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(-4px);
}

@media (max-width: 900px) {
  .slide-dots-nav {
    display: none;
  }
}

/* --------------------------------------------------------------------------
   Full-Screen Presentation Slides
   -------------------------------------------------------------------------- */
.jagrix-experience {
  position: relative;
  z-index: 1;
  padding-top: 0;
}

.chapter-slide {
  position: relative;
  min-height: 100vh;
  scroll-snap-align: start;
  scroll-snap-stop: normal;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 80px 32px 70px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.slide-inner {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  
  opacity: 0.15;
  transform: translateY(28px);
  filter: blur(3px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.8s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.8s ease;
}

.chapter-slide.is-visible .slide-inner {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.slide-center-cta {
  align-items: center;
  text-align: center;
}

/* Header & Typography */
.slide-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-cyan);
  margin-bottom: 16px;
  display: inline-block;
}

.slide-headline {
  font-size: clamp(2.4rem, 4.6vw, 3.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: #ffffff;
  margin-bottom: 16px;
}

.slide-subtext {
  font-size: 1.2rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 900px;
  margin-bottom: 44px;
}

.slide-center-cta .slide-subtext {
  margin-left: auto;
  margin-right: auto;
}

/* --------------------------------------------------------------------------
   OPEN Information Columns (No Boxes, No Containers)
   -------------------------------------------------------------------------- */
.slide-matter-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.slide-matter-grid-4 {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-bottom: 40px;
}

/* Open, borderless matter columns */
.matter-card {
  background: transparent;
  border: none;
  border-top: 1px solid var(--border-subtle);
  border-radius: 0;
  padding: 24px 0 0 0;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: none;
  
  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),
              border-color 0.25s ease;
}

.chapter-slide.is-visible .matter-card:nth-child(1) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.12s;
}

.chapter-slide.is-visible .matter-card:nth-child(2) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.22s;
}

.chapter-slide.is-visible .matter-card:nth-child(3) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.32s;
}

.chapter-slide.is-visible .matter-card:nth-child(4) {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.42s;
}

.matter-card:hover {
  background: transparent;
  border-top-color: var(--accent-cyan);
  transform: translateY(-2px) !important;
  box-shadow: none;
}

.matter-card-num {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--accent-cyan);
  margin-bottom: 12px;
}

.matter-card-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 16px;
  line-height: 1.35;
}

/* Open bullet points with generous spacing */
.matter-card-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-grow: 1;
}

.matter-card-list li {
  position: relative;
  padding-left: 18px;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

.matter-card-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 6px var(--accent-cyan);
}

/* --------------------------------------------------------------------------
   Supporting Open Rows (Stats, Tags, Footers)
   -------------------------------------------------------------------------- */
.slide-stats-bar,
.slide-action-row,
.slide-cta-box,
.slide-brand-signoff {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.chapter-slide.is-visible .slide-stats-bar,
.chapter-slide.is-visible .slide-action-row,
.chapter-slide.is-visible .slide-cta-box,
.chapter-slide.is-visible .slide-brand-signoff {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.4s;
}

/* Open Stats Row */
.slide-stats-bar {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 48px;
  padding: 24px 0 0 0;
  background: transparent;
  border: none;
  border-top: 1px solid var(--border-subtle);
  border-radius: 0;
}

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

.stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.stat-val {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

.stat-divider {
  width: 1px;
  height: 36px;
  background: var(--border-subtle);
}

/* Open Step Tags Row */
.slide-action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 28px;
  width: 100%;
  padding: 20px 0 0 0;
  border-top: 1px solid var(--border-subtle);
}

.step-tag {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 1.5px;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s ease;
}

.step-tag::before {
  content: "—";
  color: var(--accent-cyan);
  font-weight: bold;
}

.step-tag:hover {
  color: #ffffff;
}

/* Open CTA Row */
.slide-cta-box {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 20px 0 0 0;
  border-top: 1px solid var(--border-subtle);
  width: 100%;
}

.bullet-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 10px var(--accent-cyan);
  display: inline-block;
}

.cta-note {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   Single Clean Contact Text at the Bottom
   -------------------------------------------------------------------------- */
.bottom-contact-line {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-secondary);
  letter-spacing: 0.5px;
  margin-top: 20px;
}

.bottom-contact-email {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
  margin-left: 4px;
  transition: all 0.2s ease;
}

.bottom-contact-email:hover {
  color: #ffffff;
  text-decoration: underline;
  text-shadow: 0 0 10px rgba(0, 240, 255, 0.6);
}


/* Sign-off */
.slide-brand-signoff {
  border-top: 1px solid var(--border-subtle);
  padding-top: 28px;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
}

.signoff-brand {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: 3px;
  color: #ffffff;
}

.signoff-tagline {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 2.5px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Slide Bottom Watermark */
.slide-footer-label {
  position: absolute;
  bottom: 24px;
  left: 32px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2.5px;
  color: rgba(255, 255, 255, 0.2);
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   Responsive Adaptations
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .slide-matter-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .slide-matter-grid-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
  }
}

@media (max-width: 640px) {
  .chapter-slide {
    min-height: auto;
    padding: 70px 20px 50px;
  }

  .slide-matter-grid-4 {
    grid-template-columns: 1fr;
  }

  .slide-stats-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .stat-divider {
    display: none;
  }
}
