/* 
 * Endgame - Minimal Theme Styles
 */

/*****************************************************************************
 * FONT DECLARATIONS
 ****************************************************************************/
@font-face {
  font-family: 'SequelSansWide';
  src:
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Regular.woff2')
      format('woff2'),
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Regular.woff')
      format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SequelSansWide';
  src:
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Medium.woff2')
      format('woff2'),
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Medium.woff')
      format('woff');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SequelSansWide';
  src:
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-SemiBold.woff2')
      format('woff2'),
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-SemiBold.woff')
      format('woff');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SequelSansWide';
  src:
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Bold.woff2')
      format('woff2'),
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-Bold.woff')
      format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'SequelSansWide';
  src:
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-ExtraBold.woff2')
      format('woff2'),
    url('https://assets.serverless-extras.com/endgame/SequelSansWide-ExtraBold.woff')
      format('woff');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/*****************************************************************************
 * GLOBAL VARIABLES
 ****************************************************************************/
:root {
  /* Typography */
  --font-sequel:
    'SequelSansWide', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI',
    Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', sans-serif;
  --font-body:
    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
    Ubuntu, Cantarell, 'Open Sans', sans-serif;
  --font-mono:
    ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Monaco, Consolas,
    'Liberation Mono', 'Courier New', monospace;

  /* Layout */
  --max-width: 1180px;

  /* Selection Color */
  --color-selection: #3df179;
  --color-accent: #3df179;
  --color-accent-glow: rgba(0, 208, 132, 0.15);
  --color-accent-glow-strong: rgba(0, 208, 132, 0.25);

  /* Animation durations */
  --animation-speed-medium: 0.8s;
  --animation-speed-fast: 0.4s;

  /* Button size classes - can be applied to any button style */
  --btn-font-size-default: 1.2rem;
  --btn-font-size-medium: 0.95rem;
  --btn-font-size-small: 0.8rem;
  --btn-font-size-large: 1.4rem;
  --btn-padding-default: 1.02rem 2.1rem;
  --btn-padding-medium: 0.8rem 1.6rem;
  --btn-padding-small: 0.6rem 1.2rem;
  --btn-padding-large: 1.2rem 2.4rem;

  /* Dark theme variables */
  --dark-color-bg: #000000;
  --dark-color-text: #eeeeee;
  --dark-color-btn-primary: #3df179;
  --dark-color-btn-primary-text: rgb(0, 0, 0);
  --dark-color-btn-primary-hover: #ffffff;
  --dark-color-btn-secondary: #ffffff;
  --dark-color-btn-secondary-text: #000000;
  --dark-color-btn-secondary-hover: #ffffff;
  --dark-color-btn-secondary-hover-text: #000000;
  --dark-color-text-muted: rgba(255, 255, 255, 0.7);
  --dark-color-text-muted-2: rgba(255, 255, 255, 0.5);
  --dark-color-divider: rgba(255, 255, 255, 0.5);
  --dark-color-divider-faint: rgba(255, 255, 255, 0.2);
  --dark-color-hover-bg: rgba(255, 255, 255, 0.05);
  --dark-color-code-bg: rgba(255, 255, 255, 0.1);
  --dark-color-bg-alt: rgba(255, 255, 255, 0.05);
  --dark-shadow-sm: 0 1px 0px rgba(0, 0, 0, 0.3);
  --dark-shadow-md: 0 6px 26px rgba(0, 0, 0, 0.3);
  --dark-shadow-lg: 0 10px 35px rgba(0, 0, 0, 0.6);
  --dark-pattern-dot-color: rgba(255, 255, 255, 0.12);
  --dark-pattern-grid-size: 30px;

  /* Light theme variables */
  --light-color-bg: #ffffff;
  --light-color-text: #111111;
  --light-color-btn-primary: #3df179;
  --light-color-btn-primary-text: rgb(0, 0, 0);
  --light-color-btn-primary-hover: #ffffff;
  --light-color-btn-secondary: #000000;
  --light-color-btn-secondary-text: #ffffff;
  --light-color-btn-secondary-hover: #ffffff;
  --light-color-btn-secondary-hover-text: #000000;
  --light-color-text-muted: rgba(17, 17, 17, 0.7);
  --light-color-text-muted-2: rgba(17, 17, 17, 0.5);
  --light-color-divider: rgba(0, 0, 0, 0.4);
  --light-color-divider-faint: rgba(0, 0, 0, 0.2);
  --light-color-hover-bg: rgba(0, 0, 0, 0.05);
  --light-color-code-bg: rgba(0, 0, 0, 0.1);
  --light-color-bg-alt: rgba(0, 0, 0, 0.05);
  --light-shadow-sm: 0 2px 2px rgba(43, 43, 43, 0.2);
  --light-shadow-md: 0 6px 8px rgba(0, 0, 0, 0.11);
  --light-shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
  --light-pattern-dot-color: rgba(0, 0, 0, 0.25);
  --light-pattern-grid-size: 30px;

  /* Default to dark theme */
  --color-bg: var(--dark-color-bg);
  --color-text: var(--dark-color-text);
  --color-text-muted: var(--dark-color-text-muted);
  --color-text-muted-2: var(--dark-color-text-muted-2);
  --color-btn-primary: var(--dark-color-btn-primary);
  --color-btn-primary-text: var(--dark-color-btn-primary-text);
  --color-btn-primary-hover: var(--dark-color-btn-primary-hover);
  --color-btn-secondary: var(--dark-color-btn-secondary);
  --color-btn-secondary-text: var(--dark-color-btn-secondary-text);
  --color-btn-secondary-hover: var(--dark-color-btn-secondary-hover);
  --color-btn-secondary-hover-text: var(--dark-color-btn-secondary-hover-text);
  --color-divider: var(--dark-color-divider);
  --color-divider-faint: var(--dark-color-divider-faint);
  --color-hover-bg: var(--dark-color-hover-bg);
  --color-code-bg: var(--dark-color-code-bg);
  --color-bg-alt: var(--dark-color-bg-alt);
  --shadow-sm: var(--dark-shadow-sm);
  --shadow-md: var(--dark-shadow-md);
  --shadow-lg: var(--dark-shadow-lg);
  --pattern-dot-color: var(--dark-pattern-dot-color);
  --pattern-grid-size: var(--dark-pattern-grid-size);
}

/*****************************************************************************
* THEME VARIATIONS
****************************************************************************/
/* Light theme colors - manual selection */
.light-theme {
  --color-bg: var(--light-color-bg);
  --color-text: var(--light-color-text);
  --color-text-muted: var(--light-color-text-muted);
  --color-text-muted-2: var(--light-color-text-muted-2);
  --color-btn-primary: var(--light-color-btn-primary);
  --color-btn-primary-text: var(--light-color-btn-primary-text);
  --color-btn-primary-hover: var(--light-color-btn-primary-hover);
  --color-btn-secondary: var(--light-color-btn-secondary);
  --color-btn-secondary-text: var(--light-color-btn-secondary-text);
  --color-btn-secondary-hover: var(--light-color-btn-secondary-hover);
  --color-btn-secondary-hover-text: var(--light-color-btn-secondary-hover-text);
  --color-divider: var(--light-color-divider);
  --color-divider-faint: var(--light-color-divider-faint);
  --color-hover-bg: var(--light-color-hover-bg);
  --color-code-bg: var(--light-color-code-bg);
  --color-bg-alt: var(--light-color-bg-alt);
  --shadow-sm: var(--light-shadow-sm);
  --shadow-md: var(--light-shadow-md);
  --shadow-lg: var(--light-shadow-lg);
  --pattern-dot-color: var(--light-pattern-dot-color);
  --pattern-grid-size: var(--light-pattern-grid-size);

  /* Accent colors for light theme */
  --color-selection: #1be45e;
  --color-accent: #1be45e;
  --color-accent-glow: rgba(27, 228, 94, 0.15);
  --color-accent-glow-strong: rgba(27, 228, 94, 0.25);
}

/* Dark theme colors - manual selection */
.dark-theme {
  --color-bg: var(--dark-color-bg);
  --color-text: var(--dark-color-text);
  --color-text-muted: var(--dark-color-text-muted);
  --color-text-muted-2: var(--dark-color-text-muted-2);
  --color-btn-primary: var(--dark-color-btn-primary);
  --color-btn-primary-text: var(--dark-color-btn-primary-text);
  --color-btn-primary-hover: var(--dark-color-btn-primary-hover);
  --color-btn-secondary: var(--dark-color-btn-secondary);
  --color-btn-secondary-text: var(--dark-color-btn-secondary-text);
  --color-btn-secondary-hover: var(--dark-color-btn-secondary-hover);
  --color-btn-secondary-hover-text: var(--dark-color-btn-secondary-hover-text);
  --color-divider: var(--dark-color-divider);
  --color-divider-faint: var(--dark-color-divider-faint);
  --color-hover-bg: var(--dark-color-hover-bg);
  --color-code-bg: var(--dark-color-code-bg);
  --color-bg-alt: var(--dark-color-bg-alt);
  --shadow-sm: var(--dark-shadow-sm);
  --shadow-md: var(--dark-shadow-md);
  --shadow-lg: var(--dark-shadow-lg);
  --pattern-dot-color: var(--dark-pattern-dot-color);
  --pattern-grid-size: var(--dark-pattern-grid-size);
}

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

/* Global selection styling */
::selection {
  background-color: var(--color-selection);
  color: var(--dark-color-bg);
}

/* For Firefox */
::-moz-selection {
  background-color: var(--color-selection);
  color: var(--dark-color-bg);
}

/* Sequel Sans Wide utility classes */
.sequel {
  font-family: var(--font-sequel);
}

/* Remove default focus outlines and add custom focus styles */
:focus {
  outline: none;
}

html {
  background: var(--color-bg);
  min-height: 100%;
  height: 100%;
  position: relative;
  scroll-behavior: smooth;
  overscroll-behavior: none; /* Disable rubber band scrolling */
  -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  text-align: center;
  transition:
    background-color 0.3s ease,
    color 0.3s ease,
    padding-top 0.3s ease;
  position: relative;
  background: transparent;
  padding-top: 0;
  overscroll-behavior: none; /* Disable rubber band scrolling */
}

/* Prevents scrolling - added to body during intro sequence */
.prevent-scroll {
  overflow: hidden;
}

/* Prevent tap highlight on mobile */
a,
button,
input,
select,
textarea,
[role='button'],
[tabindex] {
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

/* Custom focus styles for interactive elements */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  box-shadow: 0 0 0 2px var(--color-accent-glow-strong);
  border-radius: 3px;
}

.accent {
  color: var(--color-accent);
}

.bg-dots {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: radial-gradient(
    var(--pattern-dot-color) 0.75px,
    transparent 0.75px
  );
  background-size: var(--pattern-grid-size) var(--pattern-grid-size);
  background-position: calc(var(--pattern-grid-size) / 2)
    calc(var(--pattern-grid-size) / 2);
  opacity: 0;
  transition: opacity 0.8s ease-in;
  z-index: 0;
}

.bg-dots-visible {
  opacity: 1;
}

/* Home page background video - replaces dots on home page only */
.bg-home {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease-in;
  z-index: 0;
  overflow: hidden;
}

.bg-home::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.bg-home video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  object-position: center;
}

/* Light theme background image opacity */
.light-theme .bg-home-visible {
  /* filter: contrast(1) brightness(1); */
  opacity: 0.7;
}

/* Light theme gradient overlay */
.light-theme .bg-home::after {
  background: radial-gradient(
    ellipse at top left,
    rgba(255, 255, 255, 1) 0%,
    rgba(255, 255, 255, 0.9) 40%,
    transparent 100%
  );
}

/* Dark theme background image opacity */
.dark-theme .bg-home-visible {
  filter: contrast(1.2) brightness(1.2);
  opacity: 0.3; /* Higher opacity for dark theme */
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 60px 0 0 0;
  position: relative;
  z-index: 10;
}

@media (max-width: 768px) {
  .main-content {
    min-height: auto;
    padding: 3rem 0 3.75rem;
  }
}

@media (min-height: 1200px) {
  /* For screens taller than largest MacBook Pro */
  .main-content {
    min-height: 85vh;
  }
}

.section-divider-container {
  display: flex;
  width: 100%;
  height: auto;
  margin: 0 0 5rem 0;
}

.section-divider {
  width: 100%;
  height: 1px;
  background-color: var(--color-divider);
  border: none;
  margin: 0;
  padding: 0;
}

.page-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 80;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

/* Specific to mobile menu overlay to ensure it doesn't interfere with buttons */
.mobile-menu-overlay {
  z-index: 85; /* Higher than regular content but lower than modal */
}

.page-overlay.active {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

a {
  color: var(--color-text-muted);
  text-decoration: none;
  position: relative;
  transition: all 0.25s ease;
}

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

a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--color-accent);
  transition: width 0.3s ease;
}

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

.link-unstyled::after {
  content: none;
}

.underline {
  position: relative;
}

.underline::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--color-text-muted);
  opacity: 0.4;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--btn-font-size-default);
  padding: var(--btn-padding-default);
  border-radius: 5px;
  border: 1px solid var(--color-btn-primary);
  transition: all 0.25s ease;
  box-shadow: var(--shadow-md);
  background-color: var(--color-btn-primary);
  color: var(--color-btn-primary-text);
  position: relative;
  z-index: 1;
  user-select: none; /* Prevent text selection on click */
  text-decoration: none;
}

.btn-primary.btn-small {
  font-size: var(--btn-font-size-small);
  padding: var(--btn-padding-small);
  text-decoration: none;
}

.btn-primary.btn-medium {
  font-size: var(--btn-font-size-medium);
  padding: var(--btn-padding-medium);
  text-decoration: none;
}

.btn-primary.btn-large {
  font-size: var(--btn-font-size-large);
  padding: var(--btn-padding-large);
  text-decoration: none;
}

.btn-primary:hover {
  background-color: var(--color-btn-primary-hover);
  border: 1px solid var(--color-btn-primary-hover);
  cursor: pointer;
  text-decoration: none;
  box-shadow:
    var(--shadow-sm),
    0 0 20px var(--color-accent-glow),
    0 0 40px rgba(51, 255, 160, 0.45);
}

.btn-primary:active {
  transform: scale(0.98);
  cursor: pointer;
  text-decoration: none;
  box-shadow:
    var(--shadow-sm),
    0 0 5px rgba(255, 255, 255, 0.1),
    0 0 10px rgba(255, 255, 255, 0.04);
  background-color: var(--color-btn-primary);
  border: 1px solid var(--color-btn-primary);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: var(--btn-font-size-default);
  padding: var(--btn-padding-default);
  border-radius: 5px;
  border: 1px solid var(--color-btn-secondary);
  transition: all 0.3s ease;
  box-shadow: var(--shadow-md);
  background: var(--color-btn-secondary);
  color: var(--color-btn-secondary-text);
  position: relative;
  z-index: 1;
  user-select: none; /* Prevent text selection on click */
  text-decoration: none;
}

.btn-secondary.btn-small {
  font-size: var(--btn-font-size-small);
  padding: var(--btn-padding-small);
}

/* Medium-sized secondary CTA button */
.btn-secondary.btn-medium {
  font-size: var(--btn-font-size-medium);
  padding: var(--btn-padding-medium);
}

.btn-secondary.btn-large {
  font-size: var(--btn-font-size-large);
  padding: var(--btn-padding-large);
}

.btn-secondary:hover {
  color: var(--color-btn-secondary-hover-text);
  border-color: var(--dark-color-btn-secondary-hover);
  cursor: pointer;
  background: var(--color-btn-secondary-hover);
  box-shadow:
    var(--shadow-sm),
    0 0 15px var(--color-accent-glow),
    0 0 30px rgba(51, 255, 160, 0.35);
}

.btn-secondary:active {
  transform: scale(0.98);
  cursor: pointer;
  /* background-color: var(--color-bg); */
  border: 1px solid var(--color-btn-primary);
  box-shadow:
    var(--shadow-sm),
    0 0 5px rgba(255, 255, 255, 0.1),
    0 0 10px rgba(255, 255, 255, 0.04);
}

/* Medium button styles override */
.btn-medium {
  font-size: var(--btn-font-size-medium);
  padding: var(--btn-padding-medium);
  text-decoration: none;
}

/* Light theme btn-secondary border styling */
.light-theme .btn-secondary {
  border-width: 3px;
}

.light-theme .btn-secondary.btn-medium {
  border-width: 2px;
}

.light-theme .btn-secondary:active {
  border-width: 3px;
}

/*****************************************************************************
 * GLOBAL ANIMATIONS
 ****************************************************************************/
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes float {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-8px);
  }
  100% {
    transform: translateY(0px);
  }
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.1);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(255, 255, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes modalFadeOut {
  from {
    opacity: 1;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(0.95);
  }
}

@keyframes perspectiveRotateIn {
  from {
    opacity: 0;
    transform: perspective(1000px) rotateY(40deg) translateX(50px);
  }
  to {
    opacity: 1;
    transform: perspective(1000px) rotateY(0deg) translateX(0);
  }
}

@keyframes blink {
  0%,
  100% {
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

@keyframes rainDown {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  85% {
    opacity: 1;
  }
  100% {
    transform: translateY(300px);
    opacity: 0;
  }
}

@keyframes rainDownSlow {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  10% {
    opacity: 0.15; /* Lower opacity for background effect */
  }
  85% {
    opacity: 0.15; /* Lower opacity for background effect */
  }
  100% {
    transform: translateY(300px);
    opacity: 0;
  }
}

/* Animation for raining logos */
@keyframes rainDown {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  85% {
    opacity: 1;
  }
  100% {
    transform: translateY(300px);
    opacity: 0;
  }
}

/* Animation for background logos - slower */
@keyframes rainDownSlow {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  10% {
    opacity: 0.15; /* Lower opacity for background effect */
  }
  85% {
    opacity: 0.15; /* Lower opacity for background effect */
  }
  100% {
    transform: translateY(300px);
    opacity: 0;
  }
}

@keyframes slideDownFadeIn {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

/*****************************************************************************
 * HEADER AND NAVIGATION
 ****************************************************************************/
.site-header {
  padding: 0;
  position: absolute;
  width: 100%;
  top: 0;
  left: 0;
  right: 0;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease,
    background-color 0.3s ease;
  z-index: 100;
  /* Set initial height to avoid content jumping */
  height: 60px;
  display: flex;
  align-items: center;
}

/* Fixed header styles when scrolled */
.site-header.fixed {
  position: fixed;
  /* Dark theme with 0.7 opacity */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow:
    0 1px 0 var(--color-divider-faint),
    0 2px 8px rgba(0, 0, 0, 0.08);
  animation: slideDown 0.3s ease-in-out;
}

/* Light theme fixed header with 0.7 opacity */
.light-theme .site-header.fixed {
  background-color: rgba(255, 255, 255, 0);
}

.site-header.fixed .main-nav {
  padding: 0; /* Keep centered padding for fixed state */
}

.main-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 0; /* Remove asymmetric padding */
  height: 100%;
  transition: padding 0.3s ease;
  overflow: visible; /* Ensure glow effects aren't clipped */

  & .logo-link {
    text-decoration: none;
    color: inherit;
    display: inline-block;
  }

  & .logo-container {
    color: var(--color-text);
    padding: 0.3rem 0.7rem 0.3rem 0;
    display: inline-flex;
    align-items: center;
    transition: all 0.2s ease;
    transform-origin: center bottom;

    & .logo-text {
      transition: all 0.2s ease;

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

    & .dark-logo {
      display: block;
    }

    & .light-logo {
      display: none;
    }

    & .logo-icon {
      height: 24px;
      width: auto;
      margin-right: 10px;
    }
  }

  & .logo-text {
    font-family: var(--font-sequel);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 0em;
    color: var(--color-text);
  }

  & .logo-text-dot {
    position: relative;
    font-size: 1.4rem;
    color: var(--color-accent);
    line-height: 1;
    font-family: var(--font-sequel);
    font-weight: 800;
  }

  & .nav-links {
    display: flex;
    align-items: center;
  }

  & .nav-link {
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--color-text-muted-2);
    text-decoration: none;
    transition: color 0.25s ease;
    position: relative;
    padding: 0.3rem 0.3rem 0.25rem 0.3rem;
    margin: 0 1rem 0 0;

    &:hover {
      color: var(--color-text);
    }

    &::after {
      content: '';
      position: absolute;
      bottom: -4px;
      left: 0;
      width: 0;
      height: 1px;
      background: var(--color-accent);
      transition: width 0.3s ease;
    }

    &:hover::after {
      width: 100%;
    }
  }
}

/* Home page navigation animations */
.page-home .main-nav .logo-container {
  opacity: 0;
  animation: fadeInUp var(--animation-speed-fast) ease-out forwards;
  animation-duration: 0.5s;
}

.page-home .main-nav .nav-link {
  opacity: 0;
  animation: fadeIn var(--animation-speed-fast) ease-out forwards;
  animation-fill-mode: forwards;

  &:nth-child(1) {
    animation-delay: 0.4s;
  }
  &:nth-child(2) {
    animation-delay: 0.5s;
  }
  &:nth-child(3) {
    animation-delay: 0.6s;
  }
  &:nth-child(4) {
    animation-delay: 0.7s;
  }
}

.light-theme .main-nav .logo-container {
  & .dark-logo {
    display: none;
  }

  & .light-logo {
    display: block;
  }
}

/* Theme Switcher */
.theme-switcher {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  position: relative;
  margin-left: 1.25rem;
  min-width: 28px; /* Ensure consistent width for single icon */
}

/* Home page theme switcher animation */
.page-home .theme-switcher {
  opacity: 0;
  animation: fadeIn var(--animation-speed-fast) ease-out forwards;
  animation-delay: 0.65s;
  animation-fill-mode: forwards;
}

.theme-switcher::before {
  content: '';
  position: absolute;
  left: -0.75rem;
  top: 50%;
  height: 16px;
  width: 1px;
  background-color: var(--color-divider);
  transform: translateY(-50%);
}

.theme-option {
  cursor: pointer;
  width: 28px;
  height: 28px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  color: var(--color-text-muted-2);
  background-color: transparent;
  user-select: none; /* Prevent text selection */
  -webkit-tap-highlight-color: transparent; /* Remove mobile tap highlight */
}

.theme-option:hover {
  color: var(--color-text);
  opacity: 0.85;
  background: var(--color-hover-bg);
  box-shadow:
    var(--shadow-sm),
    0 0 8px var(--color-accent-glow);
}

.theme-option.active {
  color: var(--color-accent);
  opacity: 1;
}

.theme-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Mobile Navigation Toggle */
.mobile-nav-toggle {
  display: none;
  cursor: pointer;
  background: transparent;
  border: none;
  width: 30px;
  height: 30px;
  position: relative;
  z-index: 100;
}

.mobile-nav-toggle .bar {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-text);
  margin: 5px 0;
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
}

/* Navigation buttons container */
.nav-buttons-container {
  display: flex;
  align-items: center;
  max-width: 280px; /* Increase to accommodate glow margins */
  padding: 1rem 0; /* Increase vertical padding for larger glow */
  margin: 0 0.75rem 0 0;
  overflow: visible; /* Ensure glow isn't clipped */
}

/* Home page nav buttons animation */
.page-home .nav-buttons-container {
  opacity: 0;
  animation: fadeIn var(--animation-speed-fast) ease-out forwards;
  animation-delay: 0.8s; /* Delay to appear after other nav elements */
}

/* Nav button specific animation */
.page-home .nav-button {
  opacity: 0;
  animation: fadeIn var(--animation-speed-fast) ease-out forwards;
  animation-delay: 0.5s; /* Match container delay */
}

/* Nav divider styling */
.nav-buttons-container .nav-divider {
  height: 16px;
  width: 1px;
  background-color: var(--color-divider);
  margin: 0 1.25rem 0 0.5rem;
}

/* Navigation buttons in header */
.nav-buttons-container .btn-primary,
.nav-buttons-container .btn-secondary {
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
  margin: 0 0.5rem; /* Increase horizontal margin for glow */
}

/* Header Responsive Styles */
@media (max-width: 768px) {
  .site-header {
    height: 60px;
  }

  .site-header.fixed .main-nav {
    padding: 0.75rem 0;
  }

  .main-nav {
    padding: 1rem 0;
  }

  .main-nav .logo-container .logo-icon {
    height: 20px;
    margin-right: 8px;
  }

  .main-nav .nav-links {
    position: fixed;
    top: 0;
    right: -280px;
    width: 250px;
    height: 100vh;
    background: var(--color-bg);
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 2rem;
    padding: 5rem 2rem 2rem;
    transition: right 0.3s ease-in-out;
    box-shadow: none;
    z-index: 90;
    visibility: hidden;
  }

  .main-nav .nav-links.open {
    right: 0;
    box-shadow: var(--shadow-lg);
    visibility: visible;
  }

  .main-nav .nav-link {
    font-size: 1.1rem;
  }

  /* Mobile nav links animations only on home page */
  .page-home .main-nav .nav-link {
    opacity: 1;
    animation: none;
  }

  .main-nav .nav-link::after {
    bottom: -6px;
    height: 1px;
  }

  .main-nav .nav-links .theme-switcher {
    margin-top: 2rem;
    width: 100%;
    justify-content: flex-start !important;
  }

  .page-home .main-nav .nav-links .theme-switcher {
    opacity: 1;
    animation: none;
  }

  .main-nav .logo {
    font-size: 1.06rem;
  }

  .page-home .main-nav .logo {
    animation: none;
  }

  .mobile-nav-toggle {
    display: block;
  }

  .mobile-nav-toggle.open .bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .mobile-nav-toggle.open .bar:nth-child(2) {
    opacity: 0;
  }

  .mobile-nav-toggle.open .bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  /* Mobile nav buttons */
  .nav-buttons-container {
    margin: 0;
    width: 100%;
    justify-content: center;
    /* Keep buttons horizontal in mobile menu */
    flex-direction: row;
    gap: 0.5rem;
  }

  .nav-buttons-container .btn-primary,
  .nav-buttons-container .btn-secondary {
    /* Not full width to allow horizontal layout */
    width: auto;
    min-width: 100px;
  }

  .nav-divider {
    display: none; /* Hide dividers on mobile */
  }

  /* Mobile top positioning class for mobile menu */
  .mobile-top-buttons {
    order: -1; /* Position at the top */
    margin-bottom: 0; /* Reduced from 2rem by 40% */
    padding: 1rem 0;
    border-bottom: 1px solid var(--color-divider);
  }
}

/*****************************************************************************
 * MODAL COMPONENTS
 ****************************************************************************/
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-bg);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
  pointer-events: none;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.modal-container {
  width: 100%;
  max-width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: transparent;
  position: relative;
  opacity: 0;
  transform: scale(0.95);
}

.modal-overlay.active .modal-container {
  animation: modalFadeIn 0.3s forwards;
}

.modal-overlay.closing .modal-container {
  animation: modalFadeOut 0.3s forwards;
}

.modal-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 60px;
  padding-bottom: 20px;
  position: relative;
}

.modal-title {
  color: var(--color-text);
  font-size: 1.75rem;
  font-weight: 600;
  margin: 0;
}

.modal-close {
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.modal-close svg {
  width: 24px;
  height: 24px;
  color: var(--color-text);
}

.modal-close:hover {
  background-color: var(--color-hover-bg);
}

.modal-content {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 20px 40px;
}

/* Modal Responsive Styles */
@media (max-width: 768px) {
  .modal-container {
    width: 95%;
  }

  .modal-header {
    padding: 1rem;
  }

  .modal-content {
    padding: 1rem;
  }
}

/*****************************************************************************
 * FOOTER COMPONENTS
 ****************************************************************************/
.site-footer {
  padding: 8rem 0 3rem 0;
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.footer-logo {
  display: flex;
  align-items: center;
}

.footer-logo a {
  display: inline-flex;
  align-items: center;
}

.footer-logo .logo-icon {
  height: 20px;
  width: auto;
  margin-right: 10px;
}

.footer-logo .dark-logo {
  display: block;
}

.footer-logo .light-logo {
  display: none;
}

.light-theme .footer-logo .dark-logo {
  display: none;
}

.light-theme .footer-logo .light-logo {
  display: block;
}

.footer-logo .logo-container {
  color: var(--color-text);
  display: inline-flex;
  align-items: center;
  transition: all 0.2s ease;
  transform-origin: center bottom;
}

.footer-logo .logo-container:hover .logo-text {
  color: var(--color-accent);
  text-shadow: 0 0 8px var(--color-accent-glow);
}

.footer-logo .logo-text {
  font-family: var(--font-sequel);
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--color-text);
  animation: fadeInUp var(--animation-speed-fast) ease-out forwards;
  transform-origin: center bottom;
  transition: all 0.2s ease;
}

.footer-logo .logo-text-dot {
  position: relative;
  font-size: 1.4rem;
  color: var(--color-accent);
  line-height: 1;
  font-family: var(--font-sequel);
  font-weight: 800;
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
}

.footer-link {
  color: var(--color-text-muted-2);
  text-decoration: none;
  font-size: 0.75rem;
  transition: color 0.25s ease;
}

.footer-link:hover {
  color: var(--color-accent);
}

.footer-divider {
  width: 100%;
  height: 1px;
  background-color: var(--color-divider);
  margin-bottom: 1.5rem;
}

.footer-bottom {
  text-align: center;
}

.footer-bottom p {
  font-size: 0.75rem;
  color: var(--color-text-muted-2);
}

/* Footer Responsive Styles */
@media (max-width: 768px) {
  .site-footer {
    padding: 2rem 0 1.5rem;
  }

  .footer-content {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
  }

  .footer-nav {
    gap: 1.25rem;
  }

  .footer-logo .logo-icon {
    height: 18px;
    margin-right: 8px;
  }
}

@media (max-width: 768px) {
  .installer-options {
    flex-direction: column;
    gap: 0.5rem;
  }

  .installer-container {
    width: 100%;
    min-width: 100%;
  }

  .installer-tabs {
    flex-wrap: wrap;
  }
}

/**
 * HOME PAGE
 */

.hero-section {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: 100%;
  height: 100%;
  padding: 0 0 5rem 0;
}

.hero-content-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  width: 50%;
  gap: 1.575rem;
}

.hero-content-right {
  width: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-image-container {
  width: 100%;
  display: flex;
  justify-content: center;
}

.cta-container {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 0.4s;
  animation-fill-mode: forwards;
}

.tagline {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  font-size: 3.8rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  max-width: 100%;
  font-style: normal;
  line-height: 1.25;
  opacity: 0;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 0.2s;
  animation-fill-mode: forwards;
  text-align: left;
}

.subtagline {
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--color-text-muted);
  margin-bottom: 1rem;
  max-width: 100%;
  line-height: 1.6;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 0.2s;
  opacity: 0;
  animation-fill-mode: forwards;
  animation-delay: 0.3s;
  text-align: left;
  letter-spacing: -0.005em;

  & span {
    color: var(--color-text);
    font-weight: 500;
  }
}

.works-with-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 1rem 0 0 0;
  gap: 0.5rem;
  opacity: 0;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 0.6s;
  animation-fill-mode: forwards;
}

.works-with-text {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--color-text-muted-2);
  margin-bottom: 0.3rem;
  max-width: 100%;
}

.works-with-logos {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.5rem;
  margin: -0.5rem;
}

.works-with-logos .logo-item img {
  height: 18px;
  width: auto;
  opacity: 0.75;
  transition:
    opacity 0.2s ease,
    filter 0.25s ease;
}

.works-with-logos .logo-item img:hover {
  opacity: 1;
}

.works-with-logos .logo-link {
  text-decoration: none;
  display: inline-block;
  transition: all 0.3s ease;
}

.works-with-logos .logo-link::after {
  display: none;
}

.works-with-logos .logo-link:hover img {
  filter: drop-shadow(0 0 5px rgba(51, 255, 160, 0.2))
    drop-shadow(0 0 10px var(--color-accent-glow))
    drop-shadow(0 0 20px rgba(51, 255, 160, 0.45));
}

.demo-1 {
  width: 90% !important;
  min-width: 300px !important;
  max-width: 400px !important;
  height: 500px;
  border: 1px solid var(--color-divider);
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--dark-color-bg);
  box-shadow: var(--shadow-md);
  position: relative;
  margin: 1rem auto 0 auto;
  opacity: 0;
  animation: perspectiveRotateIn var(--animation-speed-medium) ease-out forwards;
  transition: all 0.2s ease;
  animation-delay: 0.7s;
}

.demo-1:hover {
  box-shadow:
    var(--shadow-lg),
    0 0 30px var(--color-accent-glow),
    0 0 60px rgba(51, 255, 160, 0.1);
}

.light-theme .demo-1 {
  background: var(--light-color-bg);
}

.light-theme .demo-1-header {
  background: rgba(0, 0, 0, 0.02);
}

.light-theme .demo-1-action-box {
  background: rgba(0, 0, 0, 0.01);
}

.demo-1-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-divider);
  background: rgba(255, 255, 255, 0.03);
}

.demo-1-title {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--color-text);
}

.demo-1-controls {
  display: flex;
  gap: 6px;
}

.demo-1-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-divider);
}

.demo-1-content {
  flex: 1;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.02);
}

.demo-1-message {
  display: flex;
  opacity: 0;
  align-self: flex-start;
  max-width: 100%;
  transition: opacity 0.5s ease-out;
}

.demo-1-message.user {
  align-self: flex-start;
}

.demo-1-text {
  padding: 0;
  font-size: 0.85rem;
  text-align: left;
  line-height: 1.5;
  color: var(--color-text);
}

.demo-1-message.user .demo-1-text {
  color: var(--color-text);
  text-align: left;
  background: rgba(255, 255, 255, 0.05);
  padding: 10px 14px;
  border-radius: 6px;
}

.light-theme .demo-1-message.user .demo-1-text {
  background: rgba(0, 0, 0, 0.05);
}

.demo-1-action-box {
  margin: 4px 0;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--color-divider);
  display: flex;
  flex-direction: column;
  opacity: 0;
  align-self: stretch;
  transition: opacity 0.5s ease-out;
}

.demo-1-action-content {
  display: flex;
  flex-direction: column;
}

.demo-1-action-line {
  font-size: 0.9rem;
  text-align: left;
  color: var(--color-text-muted);
  line-height: 1.4;
  display: flex;
  align-items: center;
  gap: 12px;
}

.demo-1-chevron {
  font-size: 1.4rem;
  color: var(--color-text);
  line-height: 1;
}

.demo-1-tool-text {
  color: var(--color-text);
  font-weight: 400;
}

.demo-1-command-box {
  background: rgba(255, 255, 255, 0.1);
  padding: 4px 12px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--color-text);
}

.demo-1-check {
  color: var(--color-accent);
  font-size: 1.2rem;
  line-height: 1;
}

.light-theme .demo-1-command-box {
  background: rgba(0, 0, 0, 0.1);
}

.demo-1-typing::after {
  content: '';
  width: 6px;
  height: 12px;
  background: var(--color-text);
  display: inline-block;
  margin-left: 4px;
  animation: blink 1s infinite;
  vertical-align: middle;
}

.demo-1-logo {
  display: flex;
  align-items: center;
}

.cursor-logo {
  height: 16px;
  width: auto;
}

.demo-1-url {
  font-weight: 600;
  color: var(--color-text);
}

.scene-2 {
  opacity: 0;
  display: none;
}

.scene-2.visible {
  display: flex;
  animation: fadeIn 0.5s ease-out forwards;
}

.demo-1-action-box.scene-2.visible {
  display: flex;
  animation: fadeIn 0.5s ease-out forwards;
  animation-delay: 0.3s;
}

.demo-controls {
  display: flex;
  justify-content: center;
  gap: 0;
  margin-top: 1rem;
  width: 100%;
  align-items: center;
  position: relative;
  opacity: 0;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 1s;
}

.demo-control-link {
  position: relative;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--color-text-muted-2);
  text-decoration: none;
  padding: 0.2rem 1.5rem;
  transition: all 0.2s ease;
  letter-spacing: -0.02em;
}

.demo-control-link:hover {
  color: var(--color-text-muted);
}

.demo-control-link.active {
  color: var(--color-text);
  font-weight: 500;
}

.demo-control-link:first-child {
  border-right: 1px solid var(--color-divider);
}

/*****************************************************************************
 * FEATURES SECTION COMPONENTS
 ****************************************************************************/
.features-section {
  padding: 0 06rem 0;
  width: 100%;
  opacity: 0;
  animation: fadeIn var(--animation-speed-medium) ease-out forwards;
  animation-delay: 0.3s;
}

.section-title {
  font-family: var(--font-sequel);
  font-size: 2.75rem;
  font-weight: 600;
  max-width: 1000px;
  margin: 0 auto 3rem auto;
  text-align: center;
  padding: 2em 0;
}

.features-grid {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  width: 100%;
}

.left-column,
.right-column {
  display: flex;
  flex-direction: column;
  width: calc(50% - 10px);
}

.right-column {
  padding-top: 6rem;
}

.feature-tile {
  font-family: var(--font-sequel);
  background: var(--color-bg);
  border: 1px solid var(--color-divider);
  border-radius: 8px;
  padding: 2rem 2rem 4rem 2rem;
  box-shadow: var(--shadow-sm);
  transition: all 0.5s ease;
  margin-bottom: 30px;
  letter-spacing: 0.05em;
}

.feature-tile:last-child {
  margin-bottom: 0;
}

.feature-tile:hover {
  box-shadow:
    var(--shadow-md),
    0 0 20px var(--color-accent-glow),
    0 0 40px rgba(51, 255, 160, 0.2);
  z-index: 1;
  cursor: pointer;
  border-color: var(--color-text);
}

.feature-title {
  font-size: 1.3rem;
  font-weight: 500;
  color: var(--color-text);
  margin: 2rem 0;
  text-align: center;
}

.feature-description {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.6;
  color: var(--color-text-muted);
  text-align: left;
  margin-bottom: 0.75rem;
}

.feature-description:last-child {
  margin-bottom: 0;
}

.framework-graphic {
  /* Hidden until graphics are added */
  display: none;
}

@media (max-width: 768px) {
  .hero-section {
    flex-direction: column;
    gap: 3rem;
    padding: 4rem 0 2rem 0;
    min-height: auto;
  }

  .hero-content-left,
  .hero-content-right {
    width: 100%;
  }

  .tagline {
    text-align: center;
    max-width: 100%;
    font-size: 2.7rem;
    margin-bottom: 1.05rem;
  }

  .subtagline {
    max-width: 100%;
    text-align: center;
    font-size: 1rem;
    margin-bottom: 0.5rem;
    max-width: 95%;
  }

  .cta-container {
    max-width: 100%;
    width: 100%;
    justify-content: center;
  }

  .works-with-container {
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 1rem 0;
  }

  .works-with-logos {
    justify-content: center;
    gap: 1rem;
  }

  .works-with-logos .logo-item {
    margin-bottom: 0.5rem;
  }

  .rain-logo {
    width: 35px;
    height: 35px;
  }

  .demo-1 {
    min-width: 100% !important;
    max-width: 100% !important;
    height: 450px;
    margin-top: 20px;
  }

  .features-section {
    padding: 4rem 0;
  }

  .section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
  }

  /* Stack columns on mobile */
  .features-grid {
    flex-direction: column;
    gap: 0;
  }

  .left-column,
  .right-column {
    width: 100%;
  }

  .feature-tile {
    padding: 1.5rem;
    margin-bottom: 20px;
  }

  /* Mobile-specific video and transition styles */
  .video-background video {
    max-width: 90%;
    width: 90%;
    height: auto;
  }

  .logo-transition-text {
    font-size: 32px;
    padding: 0 1rem;
    gap: 0.25rem;
  }

  .mobile-play-button {
    width: 100px;
    height: 100px;
  }

  .mobile-play-button svg {
    width: 40px;
    height: 40px;
  }

  .mobile-play-text {
    font-size: 16px;
  }

  .mobile-skip-button {
    padding: 10px 20px;
    font-size: 14px;
  }
}

.dark-logo {
  display: block;
}

.light-logo {
  display: none;
}

/* Light theme state */
.light-theme .dark-logo {
  display: none;
}

.light-theme .light-logo {
  display: block;
}

.works-with-container .works-with-logos .logo-item .dark-logo {
  display: block;
}

.works-with-container .works-with-logos .logo-item .light-logo {
  display: none;
}

.light-theme .works-with-container .works-with-logos .logo-item .dark-logo {
  display: none;
}

.light-theme .works-with-container .works-with-logos .logo-item .light-logo {
  display: block;
}

/* Demo cursor logo in demo-1 header */
.demo-1-logo .dark-logo {
  display: block;
}

.demo-1-logo .light-logo {
  display: none;
}

.light-theme .demo-1-logo .dark-logo {
  display: none;
}

.light-theme .demo-1-logo .light-logo {
  display: block;
}

/* Framework logos container */
.framework-logos-container .dark-logo {
  display: none;
}

.framework-logos-container .light-logo {
  display: block;
}

.light-theme .framework-logos-container .dark-logo {
  display: block;
}

.light-theme .framework-logos-container .light-logo {
  display: none;
}

/*****************************************************************************
 * VIDEO BACKGROUND COMPONENT
 ****************************************************************************/
.video-loading-indicator {
  position: absolute;
  top: 80%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--color-text);
  font-size: 16px;
  padding: 12px 24px;
  border-radius: 4px;
  z-index: 10;
  font-weight: 500;
  opacity: 0.1 !important;
}

.video-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 1000;
  background-color: var(--color-bg);
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  opacity: 1;
  visibility: visible;
}

.video-background:hover {
  cursor: pointer;
}

.video-background::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
}

/* Different overlay for light theme */
.light-theme .video-background::after {
  background-color: rgba(255, 255, 255, 0.15);
}

.video-background video {
  max-width: 800px;
  width: 100%;
  height: auto;
  object-fit: contain;
  position: relative;
  z-index: 2;
  mix-blend-mode: screen;
}

.video-background.hidden {
  opacity: 0;
  visibility: hidden;
}

/* For dark theme, adjust the video contrast and brightness */
.dark-theme .video-background video {
  filter: brightness(0.9) contrast(1.1);
  mix-blend-mode: lighten;
}

/* For light theme, use different blend mode */
.light-theme .video-background video {
  mix-blend-mode: darken;
}

/* Logo animation that appears after video */
.logo-transition {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 900;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  visibility: hidden;
}

.logo-transition::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 3;
}

.logo-transition-text {
  font-family: var(--font-sequel);
  font-size: 45px;
  font-weight: 600;
  color: var(--color-text);
  opacity: 1;
  position: relative;
  z-index: 2;
  display: flex;
  gap: 0.5rem;
  flex-direction: column;
  align-items: center;
  text-align: center;
  line-height: 1.2;
  text-shadow:
    0 0 20px var(--color-accent-glow),
    0 0 40px rgba(255, 255, 255, 0.25),
    0 0 60px rgba(255, 255, 255, 0.12);
}

.logo-transition-text .tagline-line-1 {
  opacity: 0;
  transform: translateY(-30px);
  filter: blur(8px);
  transition:
    opacity 0.4s ease-out,
    transform 0.4s ease-out,
    filter 0.4s ease-out;
  transition-delay: 0s;
}

.logo-transition-text .tagline-line-2 {
  opacity: 0;
  transform: translateY(30px);
  filter: blur(8px);
  transition:
    opacity 0.4s ease-out,
    transform 0.4s ease-out,
    filter 0.4s ease-out;
  transition-delay: 0.2s;
}

.logo-transition-text .tagline-line-3 {
  color: var(--color-accent);
  opacity: 0;
  transform: translateX(50px);
  filter: blur(8px);
  transition:
    opacity 0.4s ease-out,
    transform 0.4s ease-out,
    filter 0.4s ease-out;
  transition-delay: 0.4s;
}

.logo-transition.visible {
  opacity: 1;
  visibility: visible;
  /* animation: logoFlicker 1s forwards; */
}

.logo-transition.visible .tagline-line-1 {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.logo-transition.visible .tagline-line-2 {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

.logo-transition.visible .tagline-line-3 {
  opacity: 1;
  transform: translateX(0);
  filter: blur(0);
}

/* Fade-out animation with zoom-out effect */
.logo-transition.fade-out {
  transition:
    opacity 0.3s ease-out,
    transform 0.3s ease-out;
  opacity: 0;
  transform: scale(0.8);
}

.logo-transition.fade-out .logo-transition-text {
  transition:
    opacity 0.3s ease-out,
    transform 0.3s ease-out;
  opacity: 0;
  transform: scale(0.8);
}

@keyframes logoFlicker {
  0% {
    opacity: 0;
  }
  50% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* Initially hide the main content until video is complete */
.main-content-hidden {
  opacity: 0;
  transition: none; /* Initially no transition */
}

.main-content-visible {
  opacity: 1;
  transition: opacity 0.5s ease-in; /* Add transition when becoming visible */
}

/* Make sure content is still in the DOM for SEO purposes but visually hidden */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Video filter classes applied via JavaScript */
.dark-video {
  filter: brightness(0.9) contrast(1.15) hue-rotate(2deg);
}

.light-video {
  filter: brightness(1.05) contrast(1);
}

/* Mobile video play overlay styles */
.mobile-video-play-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-bg);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 15;
}

.mobile-play-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.mobile-play-button {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--color-accent);
  border: none;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.mobile-play-button:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(0, 0, 0, 0.4);
}

.mobile-play-button svg {
  width: 32px;
  height: 32px;
  margin-left: 4px; /* Optical alignment for play icon */
}

.mobile-play-text {
  color: var(--color-text);
  font-size: 18px;
  font-weight: 500;
  margin: 0;
}

.mobile-skip-button {
  background: transparent;
  border: 2px solid var(--color-border);
  color: var(--color-text-secondary);
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.mobile-skip-button:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

/**
 * PRICING PAGE
 */

.page-header {
  text-align: center;
  margin: 5rem 0 3rem 0;
}

.page-header h1 {
  font-family: var(--font-sequel);
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: 0.03em;
}

.page-description {
  font-size: 1.2rem;
  color: var(--color-text-muted);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.pricing-page-container {
  max-width: var(--max-width);
  width: 100%;
  padding: 0 1rem;
}

.pricing-container {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 5rem 0 8rem;
  flex-wrap: nowrap;
  width: 100%;
  overflow-x: visible;
}

.pricing-card {
  background: var(--color-bg);
  border: 1px solid var(--color-divider);
  border-radius: 8px;
  padding: 1.75rem;
  flex: 1;
  min-width: 0;
  max-width: 290px;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  margin: 0;
}

.pricing-card-pro {
  max-width: 330px;
  padding: 2.25rem;
  transform: scale(1.05);
  z-index: 2;
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow:
    var(--shadow-md),
    0 0 20px var(--color-accent-glow),
    0 0 40px var(--color-accent-glow);
}

/* Keep the Pro card properly scaled when hovering */
.pricing-card-pro:hover {
  transform: translateY(-5px) scale(1.05);
}

.pricing-card-highlighted {
  border: 1px solid var(--color-divider);
  box-shadow:
    var(--shadow-md),
    0 0 20px var(--color-accent-glow);
  position: relative;
}

.pricing-badge {
  position: absolute;
  top: -12px;
  right: 25px;
  background: var(--color-accent);
  color: var(--dark-color-bg);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.3rem 1rem;
  border-radius: 20px;
  box-shadow: 0 0 15px var(--color-accent-glow);
}

.pricing-header {
  margin-bottom: 1rem;
  text-align: center;
}

.pricing-header h3 {
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 1.2rem;
}

.pricing-price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  margin-bottom: 1.2rem;
}

.currency {
  font-size: 1.5rem;
  font-weight: 500;
  margin-right: 0.2rem;
}

.amount {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1;
}

.period {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  margin-left: 0.15rem;
}

.custom-price {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0.75rem 0;
}

.pricing-description {
  font-size: 0.95rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.pricing-features {
  margin-bottom: 1rem;
  flex-grow: 1;
}

.pricing-features ul {
  list-style: none;
  padding: 0;
}

.pricing-features li {
  padding: 0.7rem 0;
  font-size: 0.95rem;
  color: var(--color-text);
  border-bottom: 1px solid var(--color-divider);
  display: flex;
  align-items: flex-start;
  text-align: left;
}

.pricing-features li:last-child {
  border-bottom: none;
}

.pricing-features li::before {
  content: '✓';
  color: var(--color-accent);
  margin-right: 0.8rem;
  font-weight: 600;
  min-width: 16px;
  text-align: center;
}

/* CTA Button */
.pricing-cta {
  margin-top: auto;
  text-align: center;
}

.pricing-cta .btn-primary,
.pricing-cta .btn-secondary {
  width: 100%;
  font-size: var(--btn-font-size-medium);
  padding: var(--btn-padding-medium);
}

.faq-section {
  margin: 8rem 0 4rem 0;
  text-align: center;
}

.faq-section h2 {
  font-family: var(--font-sequel);
  font-size: 2.2rem;
  font-weight: 600;
  margin-bottom: 2.5rem;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
  text-align: left;
}

.faq-item {
  margin-bottom: 1rem;
}

.faq-item h4 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.faq-item p {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.6;
}

/* Responsive adjustments */
@media (max-width: 1100px) {
  .pricing-container {
    gap: 1rem;
  }

  .pricing-card {
    padding: 1.5rem;
    max-width: 270px;
  }

  .pricing-card-pro {
    max-width: 300px;
    padding: 1.75rem;
  }
}

@media (max-width: 960px) {
  .pricing-page-container {
    padding: 0 0.5rem;
  }

  .pricing-container {
    gap: 0.75rem;
  }

  .pricing-card {
    padding: 1.25rem;
    max-width: 250px;
  }

  .pricing-card-pro {
    max-width: 280px;
    padding: 1.5rem;
  }

  .pricing-header h3 {
    font-size: 1.6rem;
  }

  .amount {
    font-size: 3rem;
  }

  .pricing-features li {
    font-size: 0.9rem;
    padding: 0.6rem 0;
  }
}

@media (max-width: 860px) {
  .pricing-container {
    flex-direction: column;
    align-items: center;
    gap: 3rem;
  }

  .pricing-card {
    max-width: 100%;
    width: 100%;
    padding: 2rem;
    transform: none !important;
  }

  .pricing-card-pro {
    max-width: 100%;
    width: 100%;
    padding: 2.5rem;
    transform: none !important;
  }

  .pricing-features li {
    font-size: 0.95rem;
    padding: 0.8rem 0;
  }

  .pricing-header h3 {
    font-size: 1.8rem;
  }

  .amount {
    font-size: 3.5rem;
  }
}

@media (max-width: 768px) {
  .page-header {
    margin: 3rem 0 2rem;
  }

  .page-header h1 {
    font-size: 2.5rem;
  }

  .page-description {
    font-size: 1.1rem;
  }

  .faq-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

@media (max-width: 480px) {
  .page-header h1 {
    font-size: 2.2rem;
  }

  .page-description {
    font-size: 1rem;
  }
}

/* Fix for logo visibility in light/dark themes */
.dark-logo {
  display: block;
}

.light-logo {
  display: none;
}

.light-theme .dark-logo {
  display: none;
}

.light-theme .light-logo {
  display: block;
}

/**
 * TERMS & PRIVACY PAGE
 */

.terms-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
  line-height: 1.6;
  position: relative;
  z-index: 10;
}

.terms-content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 2rem 0 1rem 0;
  color: var(--color-text);
}

.terms-content h3 {
  font-size: 1.2rem;
  font-weight: 500;
  margin: 1.5rem 0 0.75rem 0;
  color: var(--color-text);
}

.terms-content p {
  margin-bottom: 1rem;
  color: var(--color-text);
}

.terms-content ul {
  margin: 0.5rem 0 1rem 1.5rem;
  padding: 0;
}

.terms-content li {
  margin-bottom: 0.25rem;
  color: var(--color-text);
}

.terms-content a {
  color: var(--color-accent);
  text-decoration: underline;
}

.terms-content a:hover {
  color: var(--color-text);
}

/* Responsive adjustments for terms page */
@media (max-width: 768px) {
  .terms-content {
    max-width: 100%;
    padding: 0 1rem;
  }

  .terms-content h2 {
    font-size: 1.3rem;
  }

  .terms-content h3 {
    font-size: 1.1rem;
  }
}

/**
 * 
 * DOCUMENTATION PAGE
 * 
 */

.documentation-container {
  max-width: 1560px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.docs-page .site-header {
  position: fixed;
  background-color: var(--color-bg);
  border-bottom: 1px solid var(--color-divider-faint);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
}

.docs-page .main-content {
  justify-content: start;
  padding-top: 60px; /* Account for fixed header */
}

.docs-page .docs-wrapper {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr) 250px;
  grid-gap: 2.5rem;
  margin: 0;
  min-height: 70vh;
  position: relative;
  align-items: start;
}

/* Documentation main content area */
.docs-page .docs-main {
  min-width: 0; /* Prevent overflow */
  position: relative;
}

/* Mobile navigation toggle */
.docs-page .docs-mobile-nav-toggle {
  display: none;
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 20;
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.docs-page .docs-mobile-nav-toggle .bar {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  margin: 2px 0;
  transition: all 0.3s ease;
}

.docs-page .docs-mobile-nav-toggle.open .bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.docs-page .docs-mobile-nav-toggle.open .bar:nth-child(2) {
  opacity: 0;
}

.docs-page .docs-mobile-nav-toggle.open .bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.docs-page .page-header {
  text-align: left;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--color-divider-faint);
  margin: 4rem 0 2rem 0;
}

.docs-page .page-header h1 {
  font-family: var(--font-sans);
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  letter-spacing: -0.03em;
}

.docs-page .docs-wrapper .page-description {
  font-size: 1rem;
  margin: 0;
  width: 100%;
  max-width: 100%;
}

/* Docs content styling */
.docs-page .docs-content {
  text-align: left;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
}

.docs-page .docs-content h1 {
  font-size: 2.2rem;
  margin-top: 0;
  margin-bottom: 1.5rem;
  line-height: 1.3;
  font-weight: 700;
}

.docs-page .docs-content h2 {
  font-size: 1.8rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 600;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--color-divider-faint);
}

.docs-page .docs-content h3 {
  font-size: 1.4rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.docs-page .docs-content h4 {
  font-size: 1.2rem;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.docs-page .docs-content p {
  margin-bottom: 1.25rem;
}

.docs-page .docs-content a {
  border-bottom: 1px solid var(--color-divider);
  transition: all 0.2s ease;
}

.docs-page .docs-content a:hover {
  cursor: pointer !important;
  border-bottom: 1px solid var(--color-text);
}

.docs-page .docs-content ul,
.docs-page .docs-content ol {
  margin-bottom: 1rem;
  padding-left: 1rem;
}

.docs-page .docs-content li {
  padding: 0.35rem 0;
}

.docs-page .docs-content code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--color-code-bg);
  padding: 0.2em 0.4em;
  border-radius: 3px;
}

.docs-page .docs-content pre {
  background: var(--color-code-bg);
  padding: 1rem;
  border-radius: 6px;
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.docs-page .docs-content pre code {
  padding: 0;
  background: transparent;
}

.docs-page .docs-content blockquote {
  border-left: 4px solid var(--color-divider);
  padding-left: 1rem;
  margin-left: 0;
  color: var(--color-text-muted);
  font-style: italic;
}

.docs-page .docs-content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}

.docs-page .docs-content table th,
.docs-page .docs-content table td {
  border: 1px solid var(--color-divider);
  padding: 0.75rem;
  text-align: left;
}

.docs-page .docs-content table th {
  background-color: var(--color-bg-alt);
  font-weight: 600;
}

/* Documentation sidebar styles */
.docs-page .docs-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  padding: 4.5rem 1rem 0 0.5rem;
  border-right: 1px solid var(--color-divider-faint);
}

.docs-page .docs-sidebar-nav {
  text-align: left;
  overflow: auto;
  padding: 0;
}

.docs-page .docs-sidebar-nav h2 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 0 0.5rem;
  color: var(--color-text);
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--color-divider-faint);
}

.docs-page .docs-sidebar ul {
  padding: 0.5rem 0;
}

/* Add indentation for nested sidebar items */
.docs-page .docs-sidebar-nav ul ul li a {
  padding: 0.35rem 0 0.35rem 1rem;
}

.docs-page .docs-sidebar-nav ul ul ul li a {
  padding: 0.35rem 0 0.35rem 1.5rem;
}

/* Root level navigation list */
.docs-page .docs-nav-root {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: left;
}

/* All navigation lists */
.docs-page .docs-sidebar-nav ul {
  list-style: none;
}

/* All list items */
.docs-page .docs-sidebar-nav li {
  margin-bottom: 0;
}

/* Section headers (spans) */
.docs-page .docs-sidebar-nav span {
  display: block;
  color: var(--color-text);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.5rem;
  margin-top: 0.75rem;
  border-bottom: 1px solid var(--color-divider-faint);
}

/* Links styling */
.docs-page .docs-sidebar-nav a {
  display: block;
  padding: 0.5rem;
  color: var(--color-text-muted);
  text-decoration: none;
  border-radius: 4px;
  font-size: 0.85rem;
  transition:
    background-color 0.2s ease,
    color 0.2s ease;
}

.docs-page .docs-sidebar-nav a:hover {
  background-color: var(--color-hover-bg);
  color: var(--color-text);
}

/* Active states */
.docs-page .docs-sidebar-nav li.active > a {
  font-weight: 600;
  background-color: var(--color-hover-bg);
  color: var(--color-text);
  border-left: 3px solid var(--color-accent);
  padding-left: calc(0.75rem - 3px);
}

.docs-page .docs-sidebar-nav li.active-section > a {
  color: var(--color-text);
  font-weight: 600;
}

/* Active states for nested items */
.docs-page .docs-sidebar-nav ul ul li.active > a {
  font-weight: 600;
  background-color: var(--color-hover-bg);
  color: var(--color-text);
  border-left: 3px solid var(--color-accent);
  padding-left: calc(1rem - 3px);
}

.docs-page .docs-sidebar-nav ul ul ul li.active > a {
  padding-left: calc(1.5rem - 3px);
}

/* Right sidebar TOC styles */
.docs-page .docs-toc-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  padding: 4.5rem 1rem;
  border-left: 1px solid var(--color-divider-faint);
}

.docs-page .docs-toc {
  text-align: left;
}

.docs-page .docs-toc-header {
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--color-divider-faint);
}

.docs-page .docs-toc-header h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-text);
}

.docs-page .docs-toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.docs-page .docs-toc-item {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.docs-page .docs-toc-link {
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
  display: block;
  padding: 0.25rem 0;
  line-height: 1.5;
}

.docs-page .docs-toc-link:hover {
}

.docs-page .docs-toc-link.active {
  font-weight: 500;
}

.docs-page .docs-toc-item.indent-1 {
  padding-left: 0;
}

.docs-page .docs-toc-item.indent-2 {
  padding-left: 0.5rem;
}

.docs-page .docs-toc-item.indent-3 {
  padding-left: 1rem;
}

.docs-page .docs-toc-empty {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
  opacity: 0.5;
}

.docs-page .doc-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.docs-page .doc-tag {
  background-color: var(--color-bg-alt);
  color: var(--color-text-muted);
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.docs-page .doc-order {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  margin-bottom: 0.5rem;
}

/* Responsive adjustments for documentation */
@media (max-width: 1400px) {
  .docs-page .documentation-container {
    max-width: 1400px;
  }
}

@media (max-width: 1100px) {
  .docs-page .documentation-container {
    max-width: 100%;
  }

  .docs-page .docs-wrapper {
    grid-template-columns: 220px minmax(0, 1fr) 220px;
    grid-gap: 1.5rem;
  }
}

@media (max-width: 950px) {
  .docs-page .docs-wrapper {
    grid-template-columns: 200px minmax(0, 1fr);
  }

  .docs-page .docs-toc-sidebar {
    display: none; /* Hide the table of contents on smaller screens */
  }
}

@media (max-width: 768px) {
  .docs-page .main-content {
    padding-top: 70px; /* Adjust for smaller header on mobile */
  }

  .docs-page .docs-sidebar,
  .docs-page .docs-toc-sidebar {
    top: 70px; /* Match mobile header height */
    height: calc(100vh - 70px);
  }

  .docs-page .docs-wrapper {
    grid-template-columns: 1fr;
    margin: 1.5rem 0 3rem;
  }

  .docs-page .docs-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 85%;
    max-width: 300px;
    z-index: 30;
    background: var(--color-bg);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    overflow-y: auto;
  }

  .docs-page .docs-sidebar.open {
    transform: translateX(0);
  }

  .docs-page .docs-mobile-nav-toggle {
    display: flex;
  }

  .docs-page .docs-content-wrapper {
    padding: 1.5rem;
  }

  .docs-page .docs-content h1 {
    font-size: 2rem;
  }

  .docs-page .docs-content h2 {
    font-size: 1.6rem;
  }

  .docs-page .docs-content h3 {
    font-size: 1.3rem;
  }

  .docs-page .page-overlay.active {
    z-index: 25; /* Just below sidebar but above content */
  }
}

@media (max-width: 480px) {
  .docs-page .documentation-container {
    padding: 0 0.75rem;
  }

  .docs-page .docs-content-wrapper {
    padding: 1.25rem;
  }

  .docs-page .docs-content h1 {
    font-size: 1.8rem;
  }

  .docs-page .docs-content h2 {
    font-size: 1.5rem;
  }

  .docs-page .docs-content h3 {
    font-size: 1.2rem;
  }
}

/* Fix for logo visibility in light/dark themes */
.dark-logo {
  display: block;
}

.light-logo {
  display: none;
}

.light-theme .dark-logo {
  display: none;
}

.light-theme .light-logo {
  display: block;
}
