/* 
  OrionPulse - Corporate Design System
  Based on clean, modern aesthetics for high-trust software companies.
*/

:root {
  /* --- Typography --- */
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  
  /* --- Palette: Corporate Light (Default) --- */
  /* Primary: Trustworthy Royal Blue */
  --color-primary: #2563EB; 
  --color-primary-hover: #1D4ED8;
  --color-primary-subtle: #EFF6FF; /* Blue 50 */

  /* Secondary/Accent: Growth Green & Tech Teal */
  --color-accent: #059669; 
  --color-accent-subtle: #ECFDF5;

  /* Neutrals */
  --color-bg: #FFFFFF;
  --color-surface: #FFFFFF;
  --color-surface-hover: #F8FAFC;
  --color-surface-2: #F1F5F9;
  
  --color-border: #E2E8F0; /* Slate 200 */
  --color-border-hover: #CBD5E1;

  --color-text: #1E293B; /* Slate 800 - High contrast text */
  --color-text-secondary: #64748B; /* Slate 500 - Muted text */
  --color-text-on-primary: #FFFFFF;

  /* Navbar */
  --color-nav-bg: rgba(255, 255, 255, 0.9);
  --color-nav-link: #475569;
  --color-nav-link-hover: #0F172A;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

  /* Spacing System */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
}

/* --- Base --- */
html { height: 100%; scroll-behavior: smooth; }
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  /* Modern clean background pattern instead of 'hacker' noise */
  background-image: radial-gradient(circle at 50% 0%, var(--color-primary-subtle) 0%, transparent 40%);
  background-attachment: fixed;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  color: var(--color-text);
  font-weight: 600;
  line-height: 1.25;
  margin-bottom: 1rem;
  letter-spacing: -0.025em; /* Modern tight titling */
}

p { margin-bottom: 1.5rem; }
a { color: var(--color-primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--color-primary-hover); }

/* --- Layout Utils --- */
.site-main { flex: 1 0 auto; }
.section { padding: 5rem 0; /* More breathing room */ }
.container { max-width: 1200px; padding-left: 1.5rem; padding-right: 1.5rem; }

/* --- Components: Navbar --- */
.header-sticky {
  position: sticky; top: 0; z-index: 1030;
  background: var(--color-nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.navbar { padding-top: 1rem; padding-bottom: 1rem; }
.navbar-brand {
  font-weight: 700;
  color: var(--color-text) !important;
  font-size: 1.5rem;
  letter-spacing: -0.03em;
}
.navbar .nav-link {
  color: var(--color-nav-link) !important;
  font-weight: 500;
  font-size: 0.95rem;
  margin: 0 0.5rem;
  transition: color 0.2s ease;
}
.navbar .nav-link:hover, .navbar .nav-link.active {
  color: var(--color-nav-link-hover) !important;
}

/* --- Components: Buttons --- */
.btn {
  font-weight: 600;
  padding: 0.625rem 1.25rem;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  letter-spacing: -0.01em;
}
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.875rem; }
.btn-lg { padding: 0.875rem 2rem; font-size: 1.125rem; }

.btn-primary {
  --bs-btn-bg: var(--color-primary);
  --bs-btn-border-color: var(--color-primary);
  --bs-btn-hover-bg: var(--color-primary-hover);
  --bs-btn-hover-border-color: var(--color-primary-hover);
  --bs-btn-color: var(--color-text-on-primary);
  /* Custom override because BS5 is stubborn slightly */
  background-color: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-text-on-primary);
}
.btn-primary:hover, .btn-primary:focus {
  background-color: var(--color-primary-hover) !important;
  border-color: var(--color-primary-hover) !important;
  color: var(--color-text-on-primary) !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
  transform: translateY(-1px);
}

.btn-outline-light {
  color: var(--color-text);
  border-color: var(--color-border);
  background: transparent;
}
.btn-outline-light:hover {
  background-color: var(--color-surface-2);
  border-color: var(--color-border-hover);
  color: var(--color-text);
}

/* --- Components: Cards --- */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
  color: var(--color-text);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}
.card-body { padding: 2rem; }
.card .h5, .card h3 { color: var(--color-text); margin-bottom: 0.75rem; }
.card p { color: var(--color-text-secondary); font-size: 0.95rem; margin-bottom: 0; }

/* --- Components: Hero --- */
.hero {
  position: relative;
  padding: 8rem 0 6rem 0;
  overflow: hidden;
  background: transparent; /* Rely on body bg */
}
.hero h1, .hero .display-5 {
  font-weight: 800;
  line-height: 1.1;
  color: var(--color-text) !important; /* Force text color */
}
.hero .lead {
  font-size: 1.25rem;
  color: var(--color-text-secondary);
  font-weight: 400;
  max-width: 600px;
}

/* --- Motion & Animations --- */
@media (prefers-reduced-motion: no-preference) {
  [data-animate] {
    opacity: 0;
    will-change: transform, opacity;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  }
  
  [data-animate="fade-up"] { transform: translateY(30px); }
  [data-animate="fade-in"] { transform: scale(0.95); }
  [data-animate="slide-right"] { transform: translateX(-30px); }
  [data-animate="slide-left"] { transform: translateX(30px); }

  [data-animate].in-view {
    opacity: 1;
    transform: none;
  }
}

/* --- Refined Components for "Clean Design" --- */

/* Hero Section - Cleaner Typography */
.hero {
  padding: 5rem 0 3rem 0; /* Tuned for modern density */
}
.hero h1 {
  letter-spacing: -0.04em; /* Tighter for modern feel */
  font-weight: 800;
  margin-bottom: 1.5rem;
}
.hero .lead {
  font-weight: 400;
  color: var(--color-text-secondary);
  line-height: 1.8;
}

/* Cards - Minimalist */
.card {
  border: 1px solid transparent; /* Remove visible border by default */
  box-shadow: 0 4px 20px rgba(0,0,0,0.04); /* Very subtle shadow */
  background: var(--color-surface);
}
.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.08);
  border-color: var(--color-border-hover);
}
.card-body { padding: 2.5rem; } /* More internal breathing room */

/* Buttons - Pill Shape & Modern Hover */
.btn {
  border-radius: 50rem; /* Pill shape */
  padding: 0.75rem 2rem;
  font-weight: 600;
  letter-spacing: 0.02em; 
}
.btn-primary {
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3); /* Coloured shadow */
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

/* Navbar - Glassmorphism */
.header-sticky {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Section Titles - Centered & Clean */
.section-title {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem auto;
}
.section-title h2 {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--color-text);
}
.section-title p {
  color: var(--color-text-secondary);
  font-size: 1.1rem;
}
.footer {
  background-color: var(--color-surface-2);
  border-top: 1px solid var(--color-border);
  padding: 4rem 0;
  color: var(--color-text-secondary);
}
.footer h5, .footer h6 { color: var(--color-text) !important; font-weight: 700; margin-bottom: 1.25rem; }
.footer a { color: var(--color-text-secondary); }
.footer a:hover { color: var(--color-primary); }

/* --- Utilities --- */
.text-primary { color: var(--color-primary) !important; }
.text-secondary { color: var(--color-text-secondary) !important; }
.bg-surface { background-color: var(--color-surface); }
.bg-surface-2 { background-color: var(--color-surface-2); }

/* Dropdown */
.dropdown-menu {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
}
.dropdown-item { color: var(--color-text); padding: 0.5rem 1rem; }
.dropdown-item:hover, .dropdown-item:focus {
  background-color: var(--color-surface-2);
  color: var(--color-primary);
}

/* Cookie Banner */
.cookie-banner {
  position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
  background: var(--color-surface);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-lg);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-lg);
  z-index: 2000;
  max-width: 600px; width: 90%;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem;
}
.cookie-banner p { margin: 0; font-size: 0.9rem; color: var(--color-text-secondary); }
.cookie-banner a { color: var(--color-primary); text-decoration: underline; }

/* Responsive */
@media (min-width: 992px) {
  .dropdown-hover:hover > .dropdown-menu { display: block; margin-top: 0; }
  .navbar-expand-lg .navbar-nav .nav-link { padding-right: 0.75rem; padding-left: 0.75rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}


/* --- Compatibility / Safety --- */
/* Prevent legacy Bootstrap class from making headings invisible on light background */
h1.text-light, h2.text-light, h3.text-light, h4.text-light, h5.text-light, h6.text-light,
.display-1.text-light, .display-2.text-light, .display-3.text-light, .display-4.text-light, .display-5.text-light, .display-6.text-light {
  color: var(--color-text) !important;
}


/* --- Components: Footer --- */
.footer {
  background-color: var(--color-surface-2);
  border-top: 1px solid var(--color-border);
  padding: 4rem 0;
  color: var(--color-text-secondary);
}
.footer h5, .footer h6 { color: var(--color-text) !important; font-weight: 700; margin-bottom: 1.25rem; }
.footer a { color: var(--color-text-secondary); }
.footer a:hover { color: var(--color-primary); }
.footer .btn-outline-primary:hover { color: var(--color-text-on-primary) !important; }


/* --- Refactored Inline Styles --- */

/* Carousel Custom Indicators */
.carousel-indicator-dot {
  width: 10px !important;
  height: 10px !important;
  border: none !important;
  margin-right: 6px;
  margin-left: 6px;
  opacity: 0.5;
  transition: opacity 0.3s ease;
}
.carousel-indicator-dot.active {
  opacity: 1;
}

/* Floating Badge in Hero */
.hero-floating-badge {
  max-width: 200px;
}

/* Timeline Dots (Vertical Line) */
.timeline-dot {
  width: 20px;
  height: 20px;
  left: -1.5rem !important; /* Overrides Bootstrap positioning if needed */
}

/* Products Components */
.icon-square-lg {
  width: 64px;
  height: 64px;
}

/* Layout Utilities */
.mw-500 { max-width: 500px; }
.mw-700 { max-width: 700px; }
.mw-800 { max-width: 800px; }


.product-icon-img {
  width: 64px;
  height: 64px;
  object-fit: contain;
}

/* ==========================================================================
   Mobile Optimization (App-like Experience)
   ========================================================================== */

/* Bottom Navigation Bar (Mobile Only) */
.mobile-app-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: calc(60px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.96); /* High opacity for readability */
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.03);
  z-index: 1090;
  padding-bottom: env(safe-area-inset-bottom); /* Safe area for iPhone home bar */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Nav Items */
.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #94A3B8; /* Slate 400 - Inactive Color */
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  width: 100%;
}

.mobile-nav-item .icon-container {
  position: relative;
  transition: transform 0.2s ease;
  margin-bottom: 2px;
}

.mobile-nav-item svg {
  stroke-width: 2px;
  transition: all 0.2s ease;
}

.mobile-nav-item .label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* Active State */
.mobile-nav-item.active {
  color: var(--color-primary);
}

.mobile-nav-item.active .icon-container {
  transform: translateY(-2px);
}

.mobile-nav-item.active svg {
  stroke: var(--color-primary);
  fill: rgba(37, 99, 235, 0.1);
}

/* Click Feedback */
.mobile-nav-item:active {
  transform: scale(0.95);
}

@media (max-width: 991.98px) {
  /* Hide the Header Toggler when mobile nav is active */
  .header-sticky .navbar-toggler {
    display: none !important;
  }
  
  /* Center the brand when toggler is gone */
  .header-sticky .container {
    justify-content: center;
  }
}

/* Add padding to body on mobile to prevent content being covered by bar */
@media (max-width: 767.98px) {
    body {
        padding-bottom: calc(70px + env(safe-area-inset-bottom));
    }
    
    /* Hide the default desktop footer links that might be redundant or messy */
    .footer {
        padding-bottom: calc(70px + env(safe-area-inset-bottom));
    }
}


