:root {
  --primary: #00d2ff;
  --secondary: #3a7bd5;
  --accent: #ff4081;
  --background: #0a0e14;
  --surface: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
  --text-primary: #ffffff;
  --text-secondary: #b0b0b0;
  --gradient: linear-gradient(135deg, var(--primary), var(--secondary));
  --transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
  --mockup-bg: #1a1e26;
  --card-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
}

[data-theme="light"] {
  --primary: #0088aa;
  --secondary: #2c5a9e;
  --background: #f0f4f8;
  --surface: rgba(255, 255, 255, 0.7);
  --glass-border: rgba(0, 0, 0, 0.08);
  --text-primary: #1a1e26;
  --text-secondary: #555555;
  --mockup-bg: #ffffff;
  --card-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Cairo", "Outfit", sans-serif;
  background-color: var(--background);
  background-image: radial-gradient(circle at 20% 30%,
      rgba(0, 210, 255, 0.05) 0%,
      transparent 40%),
    radial-gradient(circle at 80% 70%,
      rgba(58, 123, 213, 0.05) 0%,
      transparent 40%);
  color: var(--text-primary);
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

/* Container & Wrapper */
.presentation-container {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
}

.slides-wrapper {
  flex: 1;
  position: relative;
  perspective: 1000px;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3% 5%;
  /* Decreased padding to give more room for content */
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.98);
  transition: var(--transition);
  overflow-y: auto;
  /* Enable vertical scrolling */
  scrollbar-width: thin;
  scrollbar-color: var(--primary) transparent;
}

.slide.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  z-index: 10;
}

/* Slide Content Layout */
.slide-grid {
  display: grid;
  grid-template-columns: 0.8fr 1.6fr;
  /* More space for image */
  grid-template-areas: "text image";
  gap: 3rem;
  align-items: start;
  /* Align to top to handle long text better */
  width: 100%;
  max-width: 1400px;
  margin: auto;
  /* Center vertically if content is short */
  padding: 2rem 0;
}

.text-side {
  grid-area: text;
  position: relative;
}

.image-side {
  grid-area: image;
}

.slide-grid.inverse {
  grid-template-columns: 1.6fr 0.8fr;
  /* More space for image */
  grid-template-areas: "image text";
}

/* Typography */
.content {
  text-align: center;
  max-width: 800px;
}

h1 {
  font-size: 5rem;
  font-weight: 800;
  margin: 1rem 0;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
}

h2 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: var(--primary);
}

.subtitle {
  font-size: 1.5rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

p {
  line-height: 1.6;
  font-size: 1.2rem;
  color: var(--text-secondary);
}

.badge {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  background: var(--glass-border);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  font-size: 0.9rem;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 1rem;
}

.hero-logo {
  max-width: 450px;
  width: 100%;
  height: auto;
}

.responsive-title {
  font-size: 3.5rem;
  margin-bottom: 1rem;
}

.responsive-subtitle {
  max-width: 900px;
  margin: 0 auto 2rem;
}

.slide-number {
  font-family: "Outfit";
  font-size: 4rem;
  font-weight: 800;
  opacity: 0.1;
  position: absolute;
  top: -2rem;
  right: -1rem;
}

.text-side {
  position: relative;
}

/* Features List */
.features-list {
  list-style: none;
  margin-top: 2rem;
  text-align: right;
}

.features-list li {
  margin-bottom: 1rem;
  padding-right: 2rem;
  position: relative;
  font-weight: 600;
  color: var(--text-primary);
}

.features-list li::before {
  content: "✓";
  position: absolute;
  right: 0;
  color: var(--primary);
  font-weight: bold;
}

/* Mockups */
.mockup-container {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--card-shadow), 0 0 20px rgba(0, 210, 255, 0.1);
  border: 1px solid var(--glass-border);
  background: var(--mockup-bg);
  /* Dark background for better contrast */
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 85vh;
  /* Increased max-height to allow taller images */
}

.system-screenshot {
  width: 100%;
  height: 100%;
  object-fit: contain;
  /* Ensure full image is visible without cropping */
  display: block;
  transition: transform 0.5s ease;
  image-rendering: -webkit-optimize-contrast;
  /* Improve sharpness on some browsers */
  image-rendering: crisp-edges;
}

.mockup-container:hover .system-screenshot {
  transform: scale(1.01);
  /* Very subtle zoom to keep it sharp */
}

/* Glass Card */
.glass-card {
  background: var(--surface);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  padding: 2rem;
  border-radius: 24px;
  margin-top: 3rem;
  animation: floating 3s ease-in-out infinite;
}

.icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

/* Progress & Nav */
.progress-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.05);
  z-index: 100;
}

.progress-bar {
  height: 100%;
  background: var(--gradient);
  width: 0%;
  transition: width 0.3s ease;
}

.nav-dots {
  position: absolute;
  left: 3rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  z-index: 100;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}

.dot:hover {
  background: rgba(255, 255, 255, 0.5);
}

.dot.active {
  background: var(--primary);
  transform: scale(1.5);
  box-shadow: 0 0 15px var(--primary);
}

/* Slide Animations */
.slide.active .text-side h2,
.slide.active .text-side p,
.slide.active .content h1,
.slide.active .content .subtitle {
  animation: slideInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.slide.active .features-list li {
  opacity: 0;
  animation: slideInRight 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.slide.active .features-list li:nth-child(1) {
  animation-delay: 0.3s;
}

.slide.active .features-list li:nth-child(2) {
  animation-delay: 0.4s;
}

.slide.active .features-list li:nth-child(3) {
  animation-delay: 0.5s;
}

.slide.active .features-list li:nth-child(4) {
  animation-delay: 0.6s;
}

.slide.active .image-side,
.slide.active .hero-image {
  animation: fadeInRotate 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRotate {
  from {
    opacity: 0;
    transform: scale(0.9) rotateY(-10deg);
  }

  to {
    opacity: 1;
    transform: scale(1) rotateY(0);
  }
}

/* Controls */
.controls {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 2rem;
  background: rgba(255, 255, 255, 0.03);
  padding: 1rem 2rem;
  border-radius: 50px;
  backdrop-filter: blur(5px);
  border: 1px solid var(--glass-border);
  z-index: 100;
}

.nav-btn {
  background: none;
  border: none;
  cursor: pointer;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  color: var(--text-primary);
  /* Set text color for SVG inheritance */
  transition: var(--transition);
}

.nav-btn:hover {
  background: var(--primary);
  color: white;
  /* Ensure icons turn white on hover */
}

.nav-btn svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
  /* Use inherited color */
  stroke: currentColor;
  stroke-width: 0;
  /* Default for filled icons */
}

/* Specific fix for the stroked Sun icon */
.nav-btn svg[fill="none"] {
  fill: none;
  stroke-width: 2;
}

.divider {
  width: 1px;
  height: 30px;
  background: var(--glass-border);
  margin: 0 0.5rem;
}

.export-btn {
  background: var(--gradient);
  border: none;
  color: white;
  padding: 0.6rem 1.2rem;
  border-radius: 12px;
  font-family: "Cairo", sans-serif;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(0, 210, 255, 0.3);
}

.export-btn.ppt-btn {
  background: linear-gradient(135deg, #d24726, #b83b1d);
  box-shadow: 0 4px 15px rgba(210, 71, 38, 0.3);
}

.export-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 210, 255, 0.5);
}

.export-btn.ppt-btn:hover {
  box-shadow: 0 6px 20px rgba(210, 71, 38, 0.5);
}

.export-btn .btn-icon {
  font-size: 1.2rem;
}

.slide-counter {
  font-family: "Outfit";
  font-weight: 600;
  min-width: 60px;
  text-align: center;
}

/* Print / Export Styles */
@media print {
  @page {
    margin: 0;
  }

  body {
    margin: 0;
    padding: 0;
    overflow: visible;
    height: auto;
    background-color: #f0f4f8 !important;
    color: #1a1e26 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .presentation-container {
    background-color: #f0f4f8 !important;
  }

  .slides-wrapper {
    display: block;
    height: auto;
    background-color: #f0f4f8 !important;
  }

  .slide {
    position: relative !important;
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    page-break-after: always;
    break-after: page;
    height: 100vh;
    background-color: #f0f4f8 !important;
    color: #1a1e26 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  h1,
  h2,
  p,
  .subtitle,
  .features-list li {
    color: #1a1e26 !important;
  }

  .slide-number {
    color: #1a1e26 !important;
    opacity: 0.2 !important;
  }

  .slide:last-child {
    page-break-after: avoid;
    break-after: avoid;
  }

  .controls,
  .nav-dots,
  .progress-container {
    display: none !important;
  }
}

.exporting .slide {
  position: relative !important;
  opacity: 1 !important;
  visibility: visible !important;
  display: flex !important;
  transform: none !important;
  page-break-after: always !important;
  break-after: page !important;
  height: 100vh !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 5% !important;
  box-sizing: border-box !important;
  background-color: #f0f4f8 !important;
  color: #1a1e26 !important;
}

.exporting h1,
.exporting h2,
.exporting p,
.exporting .subtitle,
.exporting .features-list li {
  color: #1a1e26 !important;
}

.exporting .slide:last-child {
  page-break-after: avoid !important;
  break-after: avoid !important;
}

.exporting .slides-wrapper,
.exporting .presentation-container {
  perspective: none !important;
  display: block !important;
  background-color: #f0f4f8 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
}

.exporting body {
  background-color: #f0f4f8 !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Animations */
/* Closing Slide */
.closing-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.thanks-title {
  font-size: 6rem;
  margin-bottom: 0.5rem;
}

.contact-grid {
  display: flex;
  gap: 2rem;
  margin: 2rem 0;
  flex-wrap: wrap;
  justify-content: center;
}

.contact-item {
  background: var(--surface);
  padding: 1rem 2rem;
  border-radius: 50px;
  border: 1px solid var(--glass-border);
  color: var(--primary);
  font-weight: 600;
  font-size: 1.1rem;
}

.thanks-card {
  margin-top: 1rem;
  border-color: var(--primary);
  box-shadow: 0 0 30px rgba(0, 210, 255, 0.1);
}

.thanks-card h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

@keyframes floating {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

/* Responsive */
@media (max-width: 1200px) {
  h1 {
    font-size: 4rem;
  }

  h2 {
    font-size: 2.5rem;
  }

  .slide-grid {
    gap: 2rem;
  }
}

@media (max-width: 968px) {

  .slide-grid,
  .slide-grid.inverse {
    grid-template-columns: 1fr;
    grid-template-areas: "text" "image";
    gap: 1.5rem;
    text-align: center;
  }

  .text-side {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .features-list {
    text-align: center;
    margin-top: 1rem;
  }

  .features-list li {
    padding-right: 0;
  }

  .features-list li::before {
    position: static;
    margin-left: 0.5rem;
  }

  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2rem;
  }

  .mockup-container {
    max-height: 45vh;
  }

  .nav-dots {
    left: 1rem;
    gap: 0.5rem;
  }
}

@media (max-width: 600px) {
  .slide {
    padding: 10% 5% 20% 5%;
  }

  h1 {
    font-size: 2.2rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  .subtitle {
    font-size: 1.1rem;
  }

  p {
    font-size: 1rem;
  }

  .controls {
    width: 95%;
    padding: 0.6rem 1rem;
    gap: 0.5rem;
    bottom: 1rem;
  }

  .export-btn {
    padding: 0.5rem 0.8rem;
    font-size: 0.8rem;
  }

  .export-btn .btn-icon {
    display: none;
  }

  .slide-counter {
    min-width: 40px;
    font-size: 0.9rem;
  }

  .nav-btn {
    width: 36px;
    height: 36px;
  }

  .contact-grid {
    gap: 0.8rem;
  }

  .contact-item {
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
  }

  .slide-number {
    font-size: 2.5rem;
    top: -1rem;
    right: 0;
  }

  .badge {
    font-size: 0.75rem;
    padding: 0.4rem 10px;
  }

  .glass-card {
    padding: 1.2rem;
    margin-top: 1.5rem;
  }

  .icon {
    font-size: 2rem;
  }

  .responsive-title {
    font-size: 1.8rem;
    margin-bottom: 0.8rem;
  }

  .responsive-subtitle {
    margin-bottom: 1.5rem;
  }

  .hero-logo {
    max-width: 280px;
  }
}

@media (max-width: 400px) {
  h1 {
    font-size: 1.8rem;
  }

  h2 {
    font-size: 1.4rem;
  }

  .controls {
    gap: 0.3rem;
    padding: 0.5rem 0.7rem;
  }

  .export-btn {
    padding: 0.4rem 0.5rem;
  }
}

/* Custom Scrollbar */
.slide::-webkit-scrollbar {
  width: 6px;
}

.slide::-webkit-scrollbar-track {
  background: transparent;
}

.slide::-webkit-scrollbar-thumb {
  background: var(--surface);
  border-radius: 10px;
  border: 1px solid var(--glass-border);
}

.slide::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* Ensure content doesn't get hidden behind footer/controls */
.slide-grid {
  padding-bottom: 120px;
}

.text-side {
  z-index: 5;
}