/* OmaLaskuri Global Styles, Version 1.2.1 */

/* Root Variables */
:root {
  /* Color Palette - Light Mode (Default) */
  --primary-purple: #7B3FEF;
  --primary-purple-hover: #6a2ad9;
  --dark-bg: #1A1822;
  --dark-card-bg: #2C2A3A;
  --light-bg: #F8F7FF;
  --text-color: #1a1822;
  --subtle-text: #5f5c6d;
  --border-color: #e1e1e1;
  --header-height: 80px;
  --category-nav-height: 40px;

  /* Page backgrounds */
  --page-bg: #ffffff;
  --page-text: #1a1822;
  --card-bg: #ffffff;
  --header-bg: rgba(255, 255, 255, 0.8);
  --footer-bg: #1A1822;
  --footer-text: #a9a6c3;
  --footer-heading: #ffffff;
  
  /* Typography */
  --font-serif: 'Lora', serif;
  --font-sans: 'Inter', sans-serif;
}

/* Dark Mode */
[data-theme="dark"] {
  --page-bg: #0f0e13;
  --page-text: #e4e4e7;
  --text-color: #e4e4e7;
  --subtle-text: #a1a1aa;
  --light-bg: #1f1e26;
  --card-bg: #1a1822;
  --border-color: #333240;
  --header-bg: rgba(26, 24, 34, 0.8);
  --footer-bg: #0a090d;
  --footer-text: #a1a1aa;
  --footer-heading: #e4e4e7;
}

/* Auto theme based on system preference */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page-bg: #0f0e13;
    --page-text: #e4e4e7;
    --text-color: #e4e4e7;
    --subtle-text: #a1a1aa;
    --light-bg: #1f1e26;
    --card-bg: #1a1822;
    --border-color: #333240;
    --header-bg: rgba(26, 24, 34, 0.8);
    --footer-bg: #0a090d;
    --footer-text: #a1a1aa;
    --footer-heading: #e4e4e7;
  }
}

/* Global Overrides */
body {
  font-family: var(--font-sans);
  background-color: var(--page-bg);
  color: var(--page-text);
  --pico-font-size: 16px;
  transition: background-color 0.3s ease, color 0.3s ease;
}
body.menu-open { overflow: hidden; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 600;
}

.container { max-width: 1100px; margin: auto; padding: 0 1rem; }
section { padding: 6rem 0; text-align: center; }

/* Buttons */
.btn {
  --pico-border-radius: 8px;
  --pico-font-weight: 500;
  padding: 0.75rem 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 6px 15px rgba(0,0,0,0.1); }

.btn-primary { background-color: var(--primary-purple); color: white; border: 1px solid var(--primary-purple); }
.btn-primary:hover { background-color: var(--primary-purple-hover); border-color: var(--primary-purple-hover); box-shadow: 0 6px 20px rgba(123, 63, 239, 0.4); }

.btn-secondary { background-color: transparent; color: var(--subtle-text); border: 1px solid var(--border-color); }
.btn-secondary:hover { background-color: var(--light-bg); border-color: var(--border-color); color: var(--text-color); }

/* Header */
.main-header { 
  position: sticky; 
  top: 0; 
  z-index: 1000; 
  background-color: var(--header-bg); 
  backdrop-filter: blur(10px); 
  -webkit-backdrop-filter: blur(10px); 
  transition: transform 0.3s ease-in-out, background-color 0.3s ease; 
  width: 100%;
  padding-block: 0 !important;
  padding: 0 !important;
}
.main-header.header-hidden { transform: translateY(-100%); }
.main-header > .container { 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  height: var(--header-height); 
  max-width: 100%; 
  padding: 0 2rem; 
}
.main-header .header-left { display: flex; align-items: center; gap: 0.5rem; }
.main-header .logo { display: flex; align-items: center; padding-right: 15px; font-size: 1.5rem; color: var(--text-color); text-decoration: none; }
.main-header .logo svg { margin-right: 0.25rem; }
.main-header .desktop-nav { display: none; }

/* Desktop Navigation Redesign */
.desktop-nav {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex: 1;
  max-width: 1000px;
}

/* Hide new nav elements by default */
.desktop-nav-left,
.desktop-nav-right,
.desktop-search {
  display: none;
}

/* Direct children links (for tablet view) */
.desktop-nav > a {
  display: none;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.75rem;
  color: var(--subtle-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  border-radius: 6px;
  white-space: nowrap;
}

/* Desktop nav right container */
.desktop-nav-right {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}

.desktop-nav-right a,
.desktop-nav > a {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.75rem;
  color: var(--subtle-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  border-radius: 6px;
  white-space: nowrap;
}

.desktop-nav a:hover {
  color: var(--text-color);
  background: rgba(123, 63, 239, 0.08);
}

.desktop-nav a i[data-lucide] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Desktop Search Box - Expanded and Smaller */
.desktop-search {
  display: none;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: var(--light-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  min-width: 280px;
  max-width: 450px;
  flex: 1;
  transition: all 0.2s ease;
  height: 36px;
  color: #dddddd;
}

.desktop-search:focus-within {
  border-color: var(--primary-purple);
  background: var(--card-bg);
  box-shadow: 0 0 0 3px rgba(123, 63, 239, 0.1);
}

.desktop-search i[data-lucide] {
  width: 16px;
  height: 16px;
  color: var(--subtle-text);
  flex-shrink: 0;
}

.desktop-search input {
  flex: 1;
  border: none !important;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
  font-size: 0.875rem !important;
  color: var(--text-color) !important;
  outline: none !important;
  box-shadow: none !important;
  height: auto !important;
  line-height: 1.4 !important;
  min-width: 0 !important;
}

.desktop-search input::placeholder {
  color: var(--subtle-text);
  opacity: 0.7;
}

.desktop-search input:focus {
  outline: none !important;
  box-shadow: none !important;
  border: none !important;
}

/* Desktop Search Results Dropdown */
.desktop-search {
  position: relative;
}

.desktop-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  max-height: 400px;
  overflow-y: auto;
  z-index: 1001;
  display: none;
}

.desktop-search-results:not(:empty) {
  display: block;
}

.desktop-search-results .search-result {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  text-decoration: none;
  color: var(--text-color);
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s ease;
}

.desktop-search-results .search-result:last-child {
  border-bottom: none;
}

.desktop-search-results .search-result:hover,
.desktop-search-results .search-result.selected {
  background: var(--light-bg);
}

.desktop-search-results .search-result i[data-lucide] {
  width: 20px;
  height: 20px;
  color: var(--primary-purple);
  flex-shrink: 0;
}

.desktop-search-results .result-meta {
  flex: 1;
  min-width: 0;
}

.desktop-search-results .result-title {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
  color: var(--text-color);
}

.desktop-search-results .result-snippet {
  font-size: 0.8rem;
  color: var(--subtle-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.desktop-search-results .result-snippet mark {
  background: rgba(123, 63, 239, 0.2);
  color: var(--primary-purple);
  padding: 0 2px;
  border-radius: 2px;
}

.desktop-search-results .search-empty {
  padding: 1rem;
  text-align: center;
  color: var(--subtle-text);
  font-size: 0.9rem;
}

.header-actions { display: flex; align-items: center; gap: 0.5rem; }

/* Theme Dropdown in Header - Complete Pico Override */
.theme-dropdown { 
  position: relative; 
}

/* Reset ALL Pico button styles */
button.theme-toggle-btn,
button.theme-toggle-btn:hover,
button.theme-toggle-btn:focus,
button.theme-toggle-btn:active,
button.theme-toggle-btn[aria-expanded="true"] {
  /* Reset Pico defaults */
  all: unset;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  
  /* Apply our custom styles */
  display: flex !important;
  align-items: center !important;
  gap: 0.3rem !important;
  padding: 0 0.75rem !important;
  height: 40px !important;
  background: transparent !important;
  border: none !important;
  border-radius: 6px !important;
  color: var(--subtle-text) !important;
  font-size: 0.9rem !important;
  font-weight: 500 !important;
  font-family: var(--font-sans) !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  outline: none !important;
  box-shadow: none !important;
  margin: 0 !important;
  line-height: 1 !important;
  width: auto !important;
  text-align: left !important;
  text-decoration: none !important;
  vertical-align: baseline !important;
}

button.theme-toggle-btn:hover {
  color: var(--text-color) !important;
  background: rgba(123, 63, 239, 0.08) !important;
  transform: none !important;
}

button.theme-toggle-btn[aria-expanded="true"] {
  color: var(--text-color) !important;
  background: rgba(123, 63, 239, 0.08) !important;
}

button.theme-toggle-btn:focus-visible {
  outline: 2px solid var(--primary-purple) !important;
  outline-offset: 2px !important;
}

/* Prevent child elements from intercepting clicks */
.theme-toggle-btn * {
  pointer-events: none !important;
}

.theme-toggle-btn i[data-lucide] {
  width: 18px !important;
  height: 18px !important;
  flex-shrink: 0 !important;
}

.theme-toggle-btn .chevron {
  width: 28px !important;
  height: 28px !important;
  transition: transform 0.2s ease !important;
  opacity: 0.6 !important;
  margin-left: 0 !important;
}

button.theme-toggle-btn[aria-expanded="true"] .chevron {
  transform: rotate(180deg) !important;
}

/* Icon visibility based on theme - default shows monitor for auto */
.theme-toggle-btn i[data-lucide="sun"],
.theme-toggle-btn i[data-lucide="moon"],
.theme-toggle-btn svg[data-lucide="sun"],
.theme-toggle-btn svg[data-lucide="moon"] {
  display: none !important;
}

/* Show monitor icon by default (auto mode) */
.theme-toggle-btn i[data-lucide="monitor"],
.theme-toggle-btn svg[data-lucide="monitor"] {
  display: block !important;
}

/* When light theme is explicitly set, show sun icon */
[data-theme="light"] .theme-toggle-btn i[data-lucide="monitor"],
[data-theme="light"] .theme-toggle-btn svg[data-lucide="monitor"] {
  display: none !important;
}

[data-theme="light"] .theme-toggle-btn i[data-lucide="sun"],
[data-theme="light"] .theme-toggle-btn svg[data-lucide="sun"] {
  display: block !important;
}

/* When dark theme is active, show moon icon */
[data-theme="dark"] .theme-toggle-btn i[data-lucide="monitor"],
[data-theme="dark"] .theme-toggle-btn svg[data-lucide="monitor"] {
  display: none !important;
}

[data-theme="dark"] .theme-toggle-btn i[data-lucide="moon"],
[data-theme="dark"] .theme-toggle-btn svg[data-lucide="moon"] {
  display: block !important;
}

.theme-dropdown-menu {
  position: absolute !important;
  top: calc(100% + 0.5rem) !important;
  right: 0 !important;
  left: auto !important;
  min-width: 180px !important;
  width: auto !important;
  background: var(--card-bg) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1) !important;
  opacity: 0 !important;
  visibility: hidden !important;
  transform: translateY(-8px) !important;
  transition: all 0.2s ease !important;
  z-index: 1000 !important;
  overflow: hidden !important;
  padding: 0 !important;
  margin: 0 !important;
  display: block !important;
}

.theme-dropdown-menu.show {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

/* Reset ALL Pico button styles for dropdown items */
.theme-dropdown-menu button.theme-option,
.theme-dropdown-menu button.theme-option:hover,
.theme-dropdown-menu button.theme-option:focus,
.theme-dropdown-menu button.theme-option:active,
.theme-dropdown-menu button.theme-option.active {
  /* Reset Pico defaults */
  all: unset;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  
  /* Apply our custom styles */
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
  width: 100% !important;
  padding: 0.65rem 1rem !important;
  background: transparent !important;
  border: none !important;
  border-bottom: 1px solid var(--border-color) !important;
  border-radius: 0 !important;
  color: var(--text-color) !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  font-family: var(--font-sans) !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
  text-align: left !important;
  margin: 0 !important;
  box-shadow: none !important;
  line-height: 1.4 !important;
  box-sizing: border-box !important;
  outline: none !important;
  text-decoration: none !important;
  vertical-align: baseline !important;
}

.theme-dropdown-menu button.theme-option:last-child {
  border-bottom: none !important;
}

.theme-dropdown-menu button.theme-option:hover {
  background: var(--light-bg) !important;
  color: var(--primary-purple) !important;
  transform: none !important;
}

.theme-dropdown-menu button.theme-option:focus-visible {
  background: var(--light-bg) !important;
  color: var(--primary-purple) !important;
  outline: 2px solid var(--primary-purple) !important;
  outline-offset: -2px !important;
}

.theme-dropdown-menu button.theme-option.active {
  background: linear-gradient(90deg, rgba(168,85,247,0.08), rgba(124,58,237,0.05)) !important;
  color: var(--primary-purple) !important;
  font-weight: 600 !important;
}

.theme-dropdown-menu button.theme-option.active::after {
  content: '✓' !important;
  margin-left: auto !important;
  font-weight: bold !important;
  font-size: 0.9rem !important;
}

.theme-dropdown-menu .theme-option i[data-lucide] {
  width: 16px !important;
  height: 16px !important;
  flex-shrink: 0 !important;
}

.hamburger-btn { display: flex; flex-direction: column; justify-content: space-between; align-items: center; width: 48px; height: 48px; padding: 12px; background: transparent; border: 1px solid transparent; border-radius: 8px; cursor: pointer; transition: all 0.2s ease-in-out; position: relative; flex-shrink: 0; color: var(--primary-purple); }
.hamburger-btn:hover { background: rgba(123, 63, 239, 0.1); transform: scale(1.05); }
.hamburger-btn span { width: 100%; height: 2px; background-color: var(--primary-purple); border-radius: 2px; transition: transform 0.25s ease-in-out, opacity 0.25s ease-in-out; transform-origin: center; }
.hamburger-btn.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-btn.active span:nth-child(2) { opacity: 0; transform: translateX(-10px); }
.hamburger-btn.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
.hamburger-btn i[data-lucide] { width: 20px; height: 20px; color: var(--primary-purple) !important; flex-shrink: 0; }

/* Hide header hamburger on desktop and tablet */
@media (min-width: 769px) {
  .main-header .header-left .hamburger-btn {
    display: none;
  }
}

/* Search Bar */
.search-bar { 
  visibility: hidden; 
  opacity: 0; 
  position: fixed; 
  top: var(--header-height); 
  left: 0; 
  right: 0; 
  background-color: var(--card-bg); 
  padding: 1rem; 
  box-shadow: 0 4px 10px rgba(0,0,0,0.08); 
  transform: translateY(-10px); 
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, background-color 0.3s ease; 
  z-index: 1000; 
  border-bottom: 1px solid var(--border-color); 
}
.search-bar.is-visible { visibility: visible; opacity: 1; transform: translateY(0); }
.search-bar form { display: flex; margin-bottom: 0; }
.search-bar input[type="search"] { border-top-right-radius: 0; border-bottom-right-radius: 0; border-right: 0; }
.search-bar button { border-top-left-radius: 0; border-bottom-left-radius: 0; margin-bottom: 0; width: auto; }

/* Search Results */
.search-results { margin-top: 0.75rem; text-align: left; max-height: 60vh; overflow: auto; border: 1px solid var(--border-color); border-radius: 10px; background: var(--card-bg); }
.search-result { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.75rem 1rem; border-bottom: 1px solid var(--border-color); text-decoration: none; color: var(--text-color); transition: background-color 0.2s ease; }
.search-result:hover { background: var(--light-bg); }
.search-result:last-child { border-bottom: 0; }
.search-result.selected { background: linear-gradient(90deg, rgba(168,85,247,0.08), rgba(124,58,237,0.05)); }
.search-result i[data-lucide] { width: 20px; height: 20px; color: var(--primary-purple); margin-top: 3px; flex-shrink: 0; }
.search-result.large i[data-lucide] { width: 28px; height: 28px; }
.search-result .result-meta { display: grid; gap: 0.15rem; }
.search-result .result-title { font-weight: 600; }
.search-result .result-cat { display: inline-block; margin-top: 0.25rem; margin-bottom: 0.25rem; font-size: 0.8rem; color: var(--subtle-text); }
.search-result .result-snippet { font-size: 0.9rem; color: var(--subtle-text); }
.search-empty { padding: 0.75rem 1rem; color: var(--subtle-text); }

.search-result mark {
  background: linear-gradient(90deg, rgba(168,85,247,0.15), rgba(124,58,237,0.15));
  color: inherit;
  padding: 0 2px;
  border-radius: 3px;
}

/* Category Navigation */
.category-nav {
  background-color: var(--card-bg);
  transition: background-color 0.3s ease;
  display: block;
  width: 100%;
  padding: 0 !important;
  padding-block: 0 !important;
  margin: 0;
  border-bottom: 1px solid var(--border-color);
}

.category-nav .container {
  max-width: 100%;
  padding: 0;
  margin: 0;
  position: relative;
  display: block;
}

.category-nav-list {
  display: flex;
  align-items: stretch;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
  scroll-behavior: smooth;
  position: relative;
  width: 100%;
  margin: 0;
  padding: 0;
  height: auto;
}

.category-nav-list::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

.category-nav-list ul {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  gap: 0;
  flex-wrap: nowrap;
  min-width: 100%;
  align-items: stretch;
}

.category-nav-list li {
  flex-shrink: 0;
  margin: 0;
  padding: 0;
  display: flex;
}

.category-nav-list a {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  color: var(--text-color);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.75rem;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: all 0.2s ease;
  position: relative;
  margin: 0;
  line-height: 1;
  margin-bottom: -1px;
}

.category-nav-list a:hover {
  color: var(--primary-purple);
  background-color: rgba(123, 63, 239, 0.05);
}

.category-nav-list a.active {
  color: var(--primary-purple);
  font-weight: 600;
  border-bottom-color: var(--primary-purple);
}

/* Category Menu Button (Hamburger in navigation) */
.category-menu-item {
  display: none;
  margin: 0;
  padding: 0;
}

.category-menu-btn {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.75rem 1rem;
  background: transparent;
  border: none;
  border-right: 1px solid var(--border-color);
  color: var(--text-color);
  font-weight: 600;
  font-size: 0.75rem;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  margin: 0;
  line-height: 1;
  height: 100%;
}

.category-menu-btn:hover {
  color: var(--primary-purple);
  background-color: rgba(123, 63, 239, 0.05);
}

/* Prevent child elements from intercepting clicks */
.category-menu-btn * {
  pointer-events: none !important;
}

.category-menu-btn i[data-lucide] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Show menu button on tablet and desktop */
@media (min-width: 769px) {
  .category-menu-item {
    display: block;
  }
}
/* Navigation Arrows for Desktop */
.category-nav-arrow {
  display: none;
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50px;
  max-height: 44px;
  border: none;
  cursor: pointer;
  z-index: 10;
  align-items: center;
  justify-content: center;
  color: var(--text-color);
  transition: all 0.2s ease;
  opacity: 0;
  pointer-events: none;
}

.category-nav-arrow:hover {
  color: var(--primary-purple);
}

.category-nav-arrow.left {
  left: 0;
  background: linear-gradient(to right, var(--card-bg) 70%, transparent);
}

.category-nav-arrow.right {
  right: 0;
  background: linear-gradient(to left, var(--card-bg) 70%, transparent);
}

.category-nav-arrow.visible {
  opacity: 1;
  pointer-events: auto;
  display: flex;
}

.category-nav-arrow i[data-lucide],
.category-nav-arrow svg[data-lucide] {
  width: 28px;
  height: 28px;
  stroke-width: 3;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
  color: var(--text-color);
  pointer-events: none;
}

/* Show arrows on desktop when content overflows */
@media (min-width: 769px) {
  .category-nav .container.has-overflow .category-nav-arrow {
    display: flex;
  }
  
  .category-nav .container.has-overflow .category-nav-arrow.visible {
    display: flex;
    opacity: 1;
  }
}

/* Mobile adjustments for category nav */
@media (max-width: 768px) {
  .category-nav {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    padding: 0 !important;
    padding-block: 0 !important;
  }
  
  .category-nav .container {
    display: block !important;
  }
  
  .category-nav-list {
    display: flex !important;
    visibility: visible !important;
  }
  
  /* Hide Valikko button on mobile */
  .category-menu-item {
    display: none !important;
  }
  
  .category-nav-list a {
    padding: 0.6rem 0.8rem;
    font-size: 0.7rem;
  }
  
  .category-menu-btn {
    padding: 0.6rem 0.8rem;
    font-size: 0.7rem;
  }
}

/* Sidebar Menu */
.sidebar-menu-backdrop { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; z-index: 1100; }
.sidebar-menu-backdrop.active { opacity: 1; visibility: visible; }
.sidebar-menu { position: fixed; top: 0; left: 0; width: 100%; max-width: 320px; height: 100%; background-color: var(--card-bg); z-index: 1101; transform: translateX(-100%); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.3s ease; display: flex; flex-direction: column; box-shadow: 2px 0 10px rgba(0,0,0,0.1); }
.sidebar-menu.active { transform: translateX(0); }
.sidebar-menu-header {display: flex;justify-content: space-between;align-items: center;padding: 0.25rem 0.8rem;border-bottom: 1px solid var(--border-color);background-color: var(--card-bg);min-height: 70px;}
.sidebar-back-btn { display: flex; align-items: center; gap: 0.5rem; background: transparent; border: none; cursor: pointer; padding: 0.5rem; margin-left: -0.5rem; border-radius: 8px; transition: background-color 0.2s ease; color: var(--primary-purple); font-weight: 600; font-size: 1rem; }
.sidebar-back-btn:hover { background: rgba(123, 63, 239, 0.1); }
.sidebar-back-btn svg { width: 24px; height: 24px; flex-shrink: 0; }
.sidebar-menu-title {font-size: 1rem;font-weight: 700;color: var(--text-color);flex-grow: 1;text-align: left;padding-left: 20px;}
.sidebar-close-btn { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; background: transparent; border: none; border-radius: 8px; cursor: pointer; transition: all 0.2s ease-in-out; padding: 0; }
.sidebar-close-btn:hover { background: rgba(123, 63, 239, 0.1); }
.sidebar-close-btn svg { width: 27px; height: 27px; color: var(--primary-purple); stroke: currentColor; }
.menu-panels-container { position: relative; flex: 1; overflow: hidden; min-height: 0; }
.menu-panel { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-color: var(--card-bg); transform: translateX(100%); transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.3s ease; overflow-y: auto; padding: 1.5rem; }
.menu-panel.active { transform: translateX(0); z-index: 2; }
.menu-panel.parent { transform: translateX(-30%); z-index: 1; }
.menu-panel ul { list-style: none; padding: 0; margin: 0; }
.menu-panel li { margin-bottom: 0; }
.menu-panel a {display: flex;align-items: center;padding: 0.25rem 0.25rem;color: var(--text-color);text-decoration: none;border-radius: 6px;font-weight: 500;font-size: 0.95rem;transition: background-color 0.2s ease, color 0.2s ease;gap: 0.75rem;}
.menu-panel a:hover { background-color: var(--light-bg); }
.menu-panel a i[data-lucide] { width: 18px; height: 18px; flex-shrink: 0; }
.menu-panel a.has-submenu-link { justify-content: space-between; }
.menu-panel a.has-submenu-link .arrow-icon { margin-left: auto; opacity: 0.5; }

/* Sidebar Theme Switcher */
.sidebar-theme-switcher {
  display: block;
  padding: 0.4rem 0.75rem;
  border-top: 1px solid var(--border-color);
  background-color: var(--card-bg);
  margin-top: 1rem;
  flex-shrink: 0;
}

.sidebar-theme-switcher .theme-label {
  font-size: 0.55rem;
  font-weight: 600;
  color: var(--subtle-text);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 0.3rem;
  display: block;
}

.sidebar-theme-options {
  display: flex;
  gap: 0.25rem;
}

.sidebar-theme-switcher .theme-option {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  padding: 0.25rem 0.3rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 3px;
  color: var(--text-color);
  font-size: 0.6rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
}

.sidebar-theme-switcher .theme-option i[data-lucide] {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  color: var(--text-color);
}

.sidebar-theme-switcher .theme-option:hover {
  background: var(--light-bg);
  border-color: var(--primary-purple);
  color: var(--primary-purple);
}

.sidebar-theme-switcher .theme-option:hover i[data-lucide] {
  color: var(--primary-purple);
}

.sidebar-theme-switcher .theme-option.active {
  background: var(--primary-purple);
  border-color: var(--primary-purple);
  color: white;
}

.sidebar-theme-switcher .theme-option.active i[data-lucide] {
  color: white;
}

.sidebar-theme-switcher .theme-option.active:hover {
  background: var(--primary-purple-hover);
  border-color: var(--primary-purple-hover);
}

/* Prevent child elements from intercepting clicks */
.sidebar-theme-switcher .theme-option * {
  pointer-events: none !important;
}

/* Hero */
.hero { padding-top: 5rem; padding-bottom: 0; background: linear-gradient(180deg, var(--light-bg) 0%, var(--page-bg) 80%); position: relative; overflow: hidden; }
.hero h1 { font-size: clamp(2.8rem, 6vw, 4.2rem); max-width: 800px; margin-left: auto; margin-right: auto; line-height: 1.15; font-weight: 500; }
.hero p { max-width: 650px; margin: 1.5rem auto 2.5rem; font-size: 1.1rem; line-height: 1.6; color: var(--subtle-text); }
.hero-illustration { width: 100%; object-fit: cover; margin-top: 3rem; mask-image: linear-gradient(to top, transparent 0%, black 20%); }

/* Feature Sections */
.feature-section { padding: 4rem 0; text-align: left; }
.feature-section .grid { align-items: center; gap: 5rem; }
.feature-section h2 { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: 1rem; }
.feature-section p { color: var(--subtle-text); line-height: 1.7; }
.feature-section img { width: 100%; border-radius: 12px; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; margin-top: 3rem; text-align: left; }
.feature-item { display: flex; gap: 1rem; align-items: flex-start; }
.feature-item .icon { flex-shrink: 0; width: 44px; height: 44px; border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.feature-item h4 { margin-bottom: 0.5rem; font-family: var(--font-sans); font-weight: 600; font-size: 1rem; }
.feature-item p { font-size: 0.9rem; color: var(--subtle-text); line-height: 1.6; }
.icon-green { background-color: #E6F6F0; color: #00875A; }
.icon-yellow { background-color: #FFF7E6; color: #FF9900; }
.icon-blue { background-color: #E9F5FF; color: #007BFF; }
.icon-orange { background-color: #FFF0E6; color: #FF5722; }

/* Dark CTA */
.cta-dark-section { background: var(--dark-bg); color: #fff; border-radius: 20px; padding: 4rem; margin: 4rem auto; max-width: 1100px; box-shadow: 0 25px 50px -12px rgba(123, 63, 239, 0.25); }
.cta-dark-section .grid { align-items: center; gap: 3rem; }
.cta-dark-section .badge { display: inline-block; background: var(--border-color); color: var(--subtle-text); padding: 0.25rem 0.75rem; border-radius: 99px; font-size: 0.8rem; font-weight: 500; margin-bottom: 1rem; }
.cta-dark-section h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); color: #fff; line-height: 1.2; margin: 0; }
.cta-dark-section p { color: #C1BFE4; margin: 1rem 0 2rem; }

/* Enterprise Section */
.enterprise-section .grid { align-items: center; gap: 5rem; }
.checklist { list-style: none; padding: 0; text-align: left; }
.checklist li { display: flex; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--border-color); }
.checklist li:first-child { border-top: 1px solid var(--border-color); }
.checklist i { color: var(--primary-purple); margin-right: 1rem; flex-shrink: 0; }

/* Footer Breadcrumb */
.footer-breadcrumb {
  background: var(--light-bg);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  padding: 0.5rem 0;
  transition: background-color 0.3s ease;
}

.footer-breadcrumb .container {
  max-width: 1100px;
  margin: auto;
  padding: 0 1rem;
  overflow: visible;
}

.footer-breadcrumb nav {
  overflow-x: visible;
  overflow-y: visible;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  margin-left: 0;
  padding-left: 0;
}

.footer-breadcrumb nav::-webkit-scrollbar {
  display: none;
}

.footer-breadcrumb ol {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  padding-left: 0 !important;
}

.footer-breadcrumb ol li {
  display: flex;
  align-items: center;
  white-space: nowrap;
  margin: 0;
  padding: 0;
  list-style: none !important;
}

.footer-breadcrumb ol li::before,
.footer-breadcrumb ol li::marker {
  display: none !important;
  content: none !important;
}

.footer-breadcrumb a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.5rem;
  color: var(--text-color);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.footer-breadcrumb a:hover {
  background: var(--card-bg);
  color: var(--primary-purple);
}

.footer-breadcrumb a i[data-lucide] {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.footer-breadcrumb .separator {
  display: flex;
  align-items: center;
  color: var(--subtle-text);
  opacity: 0.5;
}

.footer-breadcrumb .separator i[data-lucide] {
  width: 12px;
  height: 12px;
}

@media (max-width: 767px) {
  .footer-breadcrumb {
    padding: 0.4rem 0;
  }
  
  .footer-breadcrumb a {
    font-size: 0.7rem;
    padding: 0.2rem 0.4rem;
  }
  
  .footer-breadcrumb a i[data-lucide] {
    width: 16px;
    height: 16px;
  }
  
  .footer-breadcrumb .separator i[data-lucide] {
    width: 11px;
    height: 11px;
  }
}

/* Footer */
.main-footer { 
  background: var(--footer-bg); 
  color: var(--footer-text); 
  padding: 2rem 0 2rem; 
  font-size: 0.9rem; 
  transition: background-color 0.3s ease, color 0.3s ease; 
}

/* Footer Grid - 5 Columns */
.main-footer .footer-grid { 
  display: grid; 
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr; 
  gap: 3rem; 
  margin-bottom: 3rem;
}

/* Brand Column */
.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding-right: 0.25rem;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  text-decoration: none;
  color: var(--footer-heading);
  font-size: 1.5rem;
  font-weight: 700;
  transition: all 0.3s ease;
}

.footer-logo i[data-lucide] {
  width: 32px;
  height: 32px;
  color: var(--primary-purple);
}

.footer-logo:hover {
  color: var(--primary-purple);
  transform: translateX(3px);
}

.footer-tagline {
  font-size: 0.8rem;
  line-height: 1.4;
  text-align: inherit;
  color: var(--footer-text);
  margin: 0;
}

.footer-trust-badges {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--footer-text);
  line-height: 1.4;
}

.trust-badge i[data-lucide] {
  width: 16px;
  height: 16px;
  color: #10b981;
  flex-shrink: 0;
}

/* Footer Columns */
.footer-col {
  display: flex;
  flex-direction: column;
}

.main-footer h3 { 
  font-family: var(--font-sans); 
  color: var(--footer-heading); 
  font-weight: 700; 
  font-size: 0.95rem; 
  margin-bottom: 1.25rem; 
  text-transform: uppercase; 
  letter-spacing: 0.8px; 
}

.main-footer ul { 
  list-style: none !important; 
  padding: 0 !important; 
  margin: 0 !important; 
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.main-footer ul li {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
  list-style-type: none !important;
}

.main-footer ul li::before {
  display: none !important;
  content: none !important;
}

.main-footer ul li::marker {
  display: none !important;
  content: none !important;
}

.main-footer ul li a { 
  color: var(--footer-text);
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.15rem 0;
  font-size: 0.8rem;
  line-height: 1.4;
}

.main-footer ul li a:hover { 
  color: var(--footer-heading); 
  transform: translateX(3px);
}

.main-footer ul li a i[data-lucide] { 
  width: 16px; 
  height: 16px; 
  flex-shrink: 0;
  opacity: 0.7;
}

.main-footer ul li a:hover i[data-lucide] {
  opacity: 1;
  color: var(--primary-purple);
}

/* Footer Bottom */
.footer-bottom { 
  padding-top: 2rem; 
  border-top: 1px solid rgba(255, 255, 255, 0.1); 
}

.footer-bottom-content { 
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  flex-wrap: wrap; 
  gap: 2rem; 
}

.footer-bottom .copyright { 
  font-size: 0.85rem; 
  color: var(--footer-text);
}

.footer-legal-links {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

.footer-legal-links a {
  color: var(--footer-text);
  text-decoration: none;
  transition: color 0.2s ease;
}

.footer-legal-links a:hover {
  color: var(--footer-heading);
  text-decoration: underline;
}

.footer-legal-links .separator {
  color: var(--footer-text);
  opacity: 0.5;
}

/* Footer Theme Switcher */
.footer-theme-switcher { 
  display: flex; 
  align-items: center; 
  gap: 1rem; 
  flex-wrap: wrap; 
}

.footer-theme-switcher .theme-label { 
  font-size: 0.85rem; 
  font-weight: 600; 
  color: var(--footer-heading); 
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-theme-switcher .theme-options { 
  display: flex; 
  gap: 0.5rem; 
}

.footer-theme-switcher .theme-option { 
  display: flex; 
  align-items: center; 
  gap: 0.5rem; 
  padding: 0.5rem 1rem; 
  background: transparent; 
  border: 1px solid rgba(255, 255, 255, 0.2); 
  border-radius: 6px; 
  color: var(--footer-text); 
  font-size: 0.85rem; 
  font-weight: 500;
  cursor: pointer; 
  transition: all 0.2s ease; 
}

.footer-theme-switcher .theme-option i[data-lucide] { 
  width: 16px; 
  height: 16px; 
  flex-shrink: 0;
}

.footer-theme-switcher .theme-option:hover { 
  background: rgba(255, 255, 255, 0.1); 
  border-color: var(--primary-purple); 
  color: var(--footer-heading); 
  transform: translateY(-2px);
}

.footer-theme-switcher .theme-option.active { 
  background: var(--primary-purple); 
  border-color: var(--primary-purple); 
  color: white; 
}

.footer-theme-switcher .theme-option.active:hover { 
  background: var(--primary-purple-hover); 
  border-color: var(--primary-purple-hover); 
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 56px;
  height: 56px;
  background: var(--primary-purple);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(123, 63, 239, 0.4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s ease;
  z-index: 999;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--primary-purple-hover);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(123, 63, 239, 0.5);
}

.back-to-top svg {
  width: 30px;
  height: 30px;
  stroke-width: 3;
}

@media (max-width: 767px) {
  .back-to-top {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 50px;
    height: 50px;
  }
  
  .back-to-top svg {
    width: 26px;
    height: 26px;
    stroke-width: 3;
  }
}

/* Single Post */
.post-cover-image {
  width: 100%;
  min-height: 380px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 0 50px 50px;
}

.post-cover-overlay {
  width: 100%;
  position: relative;
  z-index: 1;
}

.post-cover-image::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.5) 100%);
  z-index: 0;
}

.post-cover-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  color: white;
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
  margin: 0;
  line-height: 1.2;
}

.single-post-article { padding: 3rem 0; max-width: 800px; margin: 0 auto; }

/* Breadcrumb - Single Post Breadcrumb Above Featured Image */
.single .breadcrumb { 
  padding: 0; 
  border-bottom: none; 
  margin: 0;
  line-height: 1;
}

.single .breadcrumb ol { 
  list-style: none; 
  padding: 0; 
  margin: 0; 
  display: flex; 
  flex-wrap: wrap; 
  align-items: center; 
  gap: 0.25rem; 
  font-size: 0.65rem;
  line-height: 1;
}

.single .breadcrumb ol li { 
  display: flex; 
  align-items: center; 
  gap: 0.25rem;
  line-height: 1;
}

.single .breadcrumb ol li::after { 
  content: '';
  display: none;
}

.single .breadcrumb ol li.current { 
  color: #654321; 
  font-weight: 400; 
}

.single .breadcrumb a { 
  color: #654321; 
  text-decoration: none; 
  transition: all 0.2s ease; 
  display: inline-flex; 
  align-items: center; 
  gap: 0;
  line-height: 1;
  padding: 0;
}

.single .breadcrumb a:hover { 
  text-decoration: underline; 
}

.single .breadcrumb .separator {
  display: inline-flex;
  align-items: center;
  opacity: 0.5;
  color: #654321;
}

.single .breadcrumb .separator i[data-lucide] { 
  width: 10px; 
  height: 10px; 
  display: inline-block;
}

/* Breadcrumb - Other Pages */
.breadcrumb { padding: 0; border-bottom: none; margin: 0; line-height: 1; }
.breadcrumb ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem; font-size: 0.7rem; line-height: 1; }
.breadcrumb ol li { display: flex; align-items: center; gap: 0.25rem; line-height: 1; }
.breadcrumb ol li::after { content: ''; display: none; }
.breadcrumb ol li.current { color: var(--subtle-text); font-weight: 400; }
.breadcrumb a { color: var(--text-color); text-decoration: none; transition: color 0.2s ease; display: inline-flex; align-items: center; gap: 0; line-height: 1; padding: 0; }
.breadcrumb a:hover { color: var(--primary-purple); text-decoration: underline; }
.breadcrumb .separator { display: inline-flex; align-items: center; opacity: 0.5; color: var(--subtle-text); }
.breadcrumb .separator i[data-lucide] { width: 12px; height: 12px; display: inline-block; }

/* Category Archive */
.category-header { 
  text-align: left; 
  padding: 1.5rem 0 1rem; 
  max-width: 100%; 
  margin: 0;
}
.category-title { 
  font-size: clamp(1.5rem, 4vw, 2rem); 
  margin-bottom: 0.5rem; 
  line-height: 1.2; 
  color: var(--text-color);
}
.category-description { 
  font-size: 0.95rem; 
  line-height: 1.5; 
  color: var(--subtle-text); 
  margin-bottom: 0;
}
.category-description p { 
  margin-bottom: 0.35rem; 
}
.category-description p:last-child { 
  margin-bottom: 0; 
}

/* Posts Grid - Card Layout */
.posts-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); 
  gap: 2rem; 
  margin: 3rem 0;
}

.post-card { 
  background: var(--card-bg); 
  border-radius: 12px; 
  overflow: hidden; 
  border: 1px solid var(--border-color); 
  transition: transform 0.3s ease, box-shadow 0.3s ease; 
  display: flex; 
  flex-direction: column;
  height: 100%;
}
.post-card:hover { 
  transform: translateY(-5px); 
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); 
}

.post-card-image { 
  display: block; 
  overflow: hidden; 
  aspect-ratio: 16 / 9; 
  background: var(--light-bg);
}
.post-card-image img { 
  width: 100%; 
  height: 100%; 
  object-fit: cover; 
  transition: transform 0.3s ease; 
}
.post-card:hover .post-card-image img { 
  transform: scale(1.05); 
}

.post-card-content { 
  padding: 1.5rem; 
  display: flex; 
  flex-direction: column; 
  flex-grow: 1;
}

.post-card-meta { 
  display: flex; 
  align-items: center; 
  gap: 1rem; 
  margin-bottom: 1rem; 
  flex-wrap: wrap;
}

.post-card-category { 
  display: inline-block; 
  background: var(--primary-purple); 
  color: white; 
  padding: 0.25rem 0.75rem; 
  border-radius: 20px; 
  font-size: 0.75rem; 
  font-weight: 600; 
  text-decoration: none; 
  text-transform: uppercase; 
  letter-spacing: 0.5px; 
  transition: background 0.2s ease;
}
.post-card-category:hover { 
  background: var(--primary-purple-hover); 
}

.post-card-date { 
  display: inline-flex; 
  align-items: center; 
  gap: 0.35rem; 
  font-size: 0.85rem; 
  color: var(--subtle-text);
}
.post-card-date i[data-lucide] { 
  width: 14px; 
  height: 14px; 
}

.post-card-title { 
  font-size: 1.4rem; 
  margin-bottom: 0.75rem; 
  line-height: 1.3; 
  font-family: var(--font-serif); 
  font-weight: 600;
}
.post-card-title a { 
  color: var(--text-color); 
  text-decoration: none; 
  transition: color 0.2s ease;
}
.post-card-title a:hover { 
  color: var(--primary-purple); 
}

.post-card-excerpt { 
  font-size: 0.95rem; 
  line-height: 1.6; 
  color: var(--subtle-text); 
  margin-bottom: 1.5rem; 
  flex-grow: 1;
}

.post-card-footer { 
  margin-top: auto;
}

.post-card-link { 
  display: inline-flex; 
  align-items: center; 
  gap: 0.5rem; 
  color: var(--primary-purple); 
  font-weight: 600; 
  font-size: 0.9rem; 
  text-decoration: none; 
  transition: gap 0.2s ease;
}
.post-card-link:hover { 
  gap: 0.75rem; 
}
.post-card-link i[data-lucide] { 
  width: 16px; 
  height: 16px; 
}

/* No Posts Message */
.no-posts { 
  text-align: center; 
  padding: 4rem 2rem; 
  background: var(--light-bg); 
  border-radius: 12px; 
  margin: 3rem 0;
}
.no-posts p { 
  font-size: 1.1rem; 
  color: var(--subtle-text); 
  margin: 0;
}

/* Pagination */
.pagination { 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  gap: 0.5rem; 
  margin: 3rem 0; 
  flex-wrap: wrap;
}
.pagination .nav-links { 
  display: flex; 
  align-items: center; 
  gap: 0.5rem; 
  flex-wrap: wrap;
}
.pagination a, 
.pagination .current { 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  min-width: 45px; 
  height: 45px; 
  padding: 0.5rem 1rem; 
  background: var(--card-bg); 
  border: 1px solid var(--border-color); 
  border-radius: 8px; 
  color: var(--text-color); 
  text-decoration: none; 
  font-weight: 500; 
  transition: all 0.2s ease;
}
.pagination a:hover { 
  background: var(--primary-purple); 
  border-color: var(--primary-purple); 
  color: white; 
}
.pagination .current { 
  background: var(--primary-purple); 
  border-color: var(--primary-purple); 
  color: white; 
  font-weight: 600;
}
.pagination .prev, 
.pagination .next { 
  gap: 0.5rem;
}
.pagination i[data-lucide] { 
  width: 16px; 
  height: 16px; 
}
.pagination .dots { 
  padding: 0.5rem; 
  color: var(--subtle-text); 
  border: none; 
  background: transparent;
}

/* Entry Header */
.entry-header { margin-bottom: 2.5rem; }
.entry-title { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: 1rem; line-height: 1.2; }
.entry-meta { display: flex; flex-wrap: wrap; gap: 1.5rem; font-size: 0.9rem; color: var(--subtle-text); padding-bottom: 1.5rem; border-bottom: 1px solid var(--border-color); }
.entry-meta span { display: inline-flex; align-items: center; gap: 0.35rem; }
.entry-meta i[data-lucide] { width: 16px; height: 16px; }
.entry-meta a { color: var(--primary-purple); text-decoration: none; transition: color 0.2s ease; }
.entry-meta a:hover { color: var(--primary-purple-hover); }

/* Entry Content */
.entry-content { font-size: 1.05rem; line-height: 1.8; color: var(--text-color); margin-bottom: 3rem; }
.entry-content p { margin-bottom: 1.5rem; }
.entry-content h2, .entry-content h3, .entry-content h4 { margin-top: 2.5rem; margin-bottom: 1rem; }
.entry-content h2 { font-size: 1.8rem; }
.entry-content h3 { font-size: 1.5rem; }
.entry-content h4 { font-size: 1.25rem; }
.entry-content ul, .entry-content ol { margin-bottom: 1.5rem; padding-left: 2rem; }
.entry-content li { margin-bottom: 0.5rem; }
.entry-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 2rem 0; }
.entry-content blockquote { border-left: 4px solid var(--primary-purple); padding-left: 1.5rem; margin: 2rem 0; font-style: italic; color: var(--subtle-text); }
.entry-content a { color: var(--primary-purple); text-decoration: underline; transition: color 0.2s ease; }
.entry-content a:hover { color: var(--primary-purple-hover); }
.entry-content code { background-color: var(--light-bg); padding: 0.2rem 0.5rem; border-radius: 4px; font-size: 0.9em; font-family: 'Courier New', monospace; }
.entry-content pre { background-color: var(--dark-bg); color: #fff; padding: 1.5rem; border-radius: 8px; overflow-x: auto; margin: 2rem 0; }
.entry-content pre code { background-color: transparent; padding: 0; color: inherit; }

.page-links { margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--border-color); }

/* Entry Footer */
.entry-footer { padding-top: 2rem; border-top: 1px solid var(--border-color); margin-bottom: 3rem; }
.post-tags { display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.post-tags i[data-lucide] { width: 18px; height: 18px; color: var(--subtle-text); }
.post-tags a { display: inline-block; background-color: var(--light-bg); color: var(--text-color); padding: 0.35rem 0.75rem; border-radius: 20px; font-size: 0.85rem; text-decoration: none; transition: all 0.2s ease; }
.post-tags a:hover { background-color: var(--primary-purple); color: white; }

/* Post Navigation */
.post-navigation { margin-bottom: 3rem; padding: 2rem 0; border-top: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color); }
.post-navigation .nav-links { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.post-navigation .nav-previous, .post-navigation .nav-next { display: block; }
.post-navigation a { display: block; padding: 1rem; border-radius: 8px; background-color: var(--light-bg); text-decoration: none; transition: all 0.2s ease; }
.post-navigation a:hover { background-color: var(--primary-purple); color: white; }
.post-navigation .nav-subtitle { display: block; font-size: 0.85rem; color: var(--subtle-text); margin-bottom: 0.5rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
.post-navigation a:hover .nav-subtitle { color: rgba(255, 255, 255, 0.8); }
.post-navigation .nav-title { display: block; font-family: var(--font-serif); font-weight: 600; font-size: 1.1rem; color: var(--text-color); }
.post-navigation a:hover .nav-title { color: white; }

/* Accessibility */
:focus-visible { outline: 2px solid var(--primary-purple); outline-offset: 2px; }
@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; }
}

/* Responsive */
@media (min-width: 768px) {
  /* Hide search icon on tablet and larger - not needed since desktop has search in nav */
  /* Keep it visible for now on tablet until desktop breakpoint */
}

/* Hide theme dropdown in header on mobile and tablet, show only on desktop */
@media (max-width: 1023px) {
  .header-actions .theme-dropdown {
    display: none !important;
  }
  
  /* Show search icon on mobile and tablet */
  .header-actions .mobile-only {
    display: flex !important;
  }
}

/* Hide theme dropdown completely - now in footer */
.header-actions .theme-dropdown {
  display: none !important;
}

/* Hide search icon on desktop (1024px+) since desktop has search in nav bar */
@media (min-width: 1024px) {
  .header-actions .mobile-only {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  /* Desktop only: Show desktop nav */
  .main-header .desktop-nav { 
    display: flex !important; 
    flex: 1;
    max-width: 1100px;
    margin: 0 1rem;
  }
  
  /* Hide simple nav links on desktop */
  .desktop-nav > a:not(.desktop-nav-right a) {
    display: none !important;
  }
  
  /* Show desktop search and right nav */
  .desktop-nav-right,
  .desktop-search {
    display: flex !important;
  }
  
  .main-header .container {
    max-width: 100%;
    padding: 0 2rem;
  }
  
  /* Ensure proper logo sizing on desktop */
  .main-header .logo {
    font-size: 1.5rem;
  }
}

/* Large desktop optimization */
@media (min-width: 1280px) {
  .main-header .desktop-nav {
    max-width: 1200px;
  }
  
  .desktop-search {
    min-width: 320px;
    max-width: 500px;
  }
}

/* Tablet landscape - between mobile and desktop */
@media (min-width: 768px) and (max-width: 1023px) {
  .main-header {
    padding: 0 !important;
    padding-block: 0 !important;
  }
  
  .main-header .container { 
    padding: 0 1.5rem; 
  }
  
  .category-nav {
    padding: 0 !important;
    padding-block: 0 !important;
  }
  
  .main-header .logo {
    font-size: 1.3rem;
  }
  
  .main-header .logo svg {
    width: 22px;
    height: 22px;
  }
  
  /* Ensure search icon is properly sized on tablet */
  .hamburger-btn.mobile-only {
    width: 52px;
    height: 52px;
  }
}

@media (max-width: 992px) {
  .main-footer .footer-grid { 
    grid-template-columns: 1fr 1fr 1fr; 
    gap: 2.5rem;
  }
  .footer-brand-col { 
    grid-column: 1 / -1; 
    max-width: 100%;
    margin-bottom: 1rem;
  }
  .footer-tagline {
    max-width: 100%;
    text-align:left;
    max-width: 100%;
    padding: 0.8rem 0 0.8rem 0;
    line-height: 1.4rem;
  }
  .footer-trust-badges {
    flex-direction: row;
    gap: 1.5rem;
  }
}

@media (max-width: 767px) {
  :root {
    --header-height: 50px;
  }
  
  .header-buttons, .desktop-nav { display: none; }
  
  .main-header {
    padding: 0 !important;
    padding-block: 0 !important;
  }
  
  .main-header .container { 
    padding: 0 1rem; 
    display: grid; 
    grid-template-columns: 48px 1fr 48px; 
    align-items: center; 
    gap: 0.5rem; 
  }
  
  .category-nav {
    padding: 0 !important;
    padding-block: 0 !important;
  }
  
  .main-header .header-left { position: static; display: contents; }
  .main-header .header-left .hamburger-btn { grid-column: 1; justify-self: start; }
  .main-header .header-left .logo { 
    grid-column: 2; 
    justify-self: center; 
    margin: 0;
    font-size: 1.25rem;
  }
  .main-header .logo svg {
    width: 20px;
    height: 20px;
  }
  .main-header .header-actions { grid-column: 3; justify-self: end; margin-left: 0; }
  
  /* Ensure search icon button is properly sized */
  .hamburger-btn {
    width: 48px;
    height: 48px;
    padding: 12px;
  }
  
  section { padding: 3rem 0; }
  .feature-section .grid, .enterprise-section .grid, .cta-dark-section .grid { grid-template-columns: 1fr; }
  .feature-section img { order: -1; margin-bottom: 2rem; }
  .cta-dark-section { padding: 2rem; text-align: center; }
  .cta-dark-section div { text-align: center; }
  .enterprise-section { text-align: center; }
  
  /* Footer Mobile Styles */
  .main-footer {
    padding: 3rem 0 2rem;
  }
  
  .main-footer .footer-grid { 
    grid-template-columns: 1fr 1fr; 
    gap: 2rem;
  }
  
  .footer-brand-col {
    grid-column: 1 / -1;
    text-align: center;
    align-items: center;
    margin-bottom: 1rem;
  }
  
  .footer-logo {
    justify-content: center;
    font-size: 1.35rem;
  }
  
  .footer-logo i[data-lucide] {
    width: 28px;
    height: 28px;
  }
  
  .footer-tagline {
    text-align: center;
    max-width: 100%;
  }
  
  .footer-trust-badges {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
  
  .footer-col h3 {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    font-weight: 700;
  }
  
  .main-footer ul li a {
    font-size: 0.85rem;
    padding: 0.25rem 0;
  }
  
  .main-footer ul li a i[data-lucide] {
    width: 14px;
    height: 14px;
  }
  
  /* Footer Bottom Mobile */
  .footer-bottom-content { 
    flex-direction: column; 
    align-items: center; 
    text-align: center; 
    gap: 1rem; 
  }
  
  .footer-legal-links {
    justify-content: center;
    font-size: 0.8rem;
  }
  
  /* Category Archive Mobile */
  .category-header { padding: 1rem 0 0.75rem; }
  .category-title { font-size: clamp(1.25rem, 4vw, 1.5rem); margin-bottom: 0.35rem; }
  .category-description { font-size: 0.85rem; }
  .posts-grid { grid-template-columns: 1fr; gap: 1.5rem; margin: 2rem 0; }
  .post-card-title { font-size: 1.25rem; }
  .pagination a, .pagination .current { min-width: 40px; height: 40px; padding: 0.5rem 0.75rem; font-size: 0.9rem; }
  
  /* Single Post Mobile */
  .post-cover-image { 
    min-height: 300px; 
    padding: 0 20px 30px;
  }
  .post-cover-title {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
  }
  .single-post-article { padding: 2rem 0; }
  .entry-header { margin-bottom: 2rem; }
  .entry-meta { gap: 1rem; font-size: 0.85rem; }
  .entry-content { font-size: 1rem; }
  .post-navigation .nav-links { grid-template-columns: 1fr; gap: 1rem; }
  .single .breadcrumb { padding: 0; margin: 0; }
  .single .breadcrumb ol { font-size: 0.6rem; gap: 0.2rem; }
  .single .breadcrumb ol li { gap: 0.2rem; }
  .single .breadcrumb .separator i[data-lucide] { width: 9px; height: 9px; }
  .breadcrumb { padding: 0; margin: 0; }
  .breadcrumb ol { font-size: 0.65rem; gap: 0.2rem; }
  .breadcrumb ol li { gap: 0.2rem; }
  .breadcrumb .separator i[data-lucide] { width: 10px; height: 10px; }
  
  /* Theme Switcher Mobile */
  .footer-bottom-content { flex-direction: column; align-items: center; text-align: center; gap: 1.5rem; }
  .theme-switcher { justify-content: center; }
  .theme-switcher .theme-option span { display: none; }
  .theme-switcher .theme-option { padding: 0.65rem; }
}



/* Calculator Tools Section */
.tool-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.5rem 1rem;
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  text-decoration: none;
  color: var(--text-color);
  text-align: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  min-height: 120px;
  position: relative;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.tool-tile::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 12px;
  opacity: 0;
  transition: opacity 0.3s ease;
  background: linear-gradient(135deg, 
    rgba(123, 63, 239, 0.1) 0%, 
    rgba(168, 85, 247, 0.15) 50%, 
    rgba(124, 58, 237, 0.1) 100%);
  z-index: -1;
  filter: blur(8px);
}

.tool-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px -12px rgba(123, 63, 239, 0.3),
              0 10px 25px -5px rgba(168, 85, 247, 0.25),
              0 8px 16px -8px rgba(124, 58, 237, 0.2);
  border-color: var(--primary-purple);
  background: linear-gradient(135deg, var(--card-bg) 0%, var(--light-bg) 100%);
}

.tool-tile:hover::before {
  opacity: 1;
}

.tool-tile i[data-lucide] {
  width: 32px;
  height: 32px;
  color: var(--primary-purple);
  flex-shrink: 0;
}

.tool-tile:hover i[data-lucide] {
  transform: scale(1.1);
  transition: transform 0.3s ease;
}

.tool-tile span {
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--text-color);
}

.tool-tile:hover span {
  color: var(--primary-purple);
}

@media (max-width: 768px) {
  .tool-tile {
    min-height: 100px;
    padding: 1rem 0.75rem;
    gap: 0.5rem;
  }
  
  .tool-tile i[data-lucide] {
    width: 28px;
    height: 28px;
  }
  
  .tool-tile span {
    font-size: 0.85rem;
  }
}

/* Logo icon sizing for tablet and mobile */
@media (max-width: 1023px) {
  .main-header .logo svg[data-lucide],
  .main-footer .logo svg[data-lucide] {
    width: 28px !important;
    height: 28px !important;
  }
}

/* ===========================
   CALCULATOR COMMON STYLES
   =========================== */

/* Calculator Hero Section - Natural Background */
.calculator-hero-section {
  background: transparent;
  position: relative;
  overflow: visible;
  padding: 3rem 0 4rem;
}

.calculator-hero-section::before,
.calculator-hero-section::after {
  display: none;
}

/* Calculator Container - Centered, No Background */
.calculator-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 1.5rem;
  background: transparent;
  border-radius: 16px;
  box-shadow: none;
  border: none;
  position: relative;
  z-index: 1;
}

/* Sticky Results Container for Desktop */
.results-container {
  background: transparent;
  padding: 1.25rem;
  border-radius: 12px;
  margin: 0 auto 0;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

@media (min-width: 1024px) {
  .calculator-wrapper {
    display: grid;
    grid-template-columns: 60fr 40fr;
    gap: 2rem;
    align-items: start;
    max-width: 1200px;
    margin: 0 auto;
  }
  
  .calculator-form-wrapper {
    position: relative;
    background: transparent;
    padding: 1.25rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
  }
  
  .results-container.sticky {
    position: sticky;
    top: calc(var(--header-height) + var(--category-nav-height, 44px) + 1.5rem);
  }
}

/* Preset Buttons */
.preset-buttons {
  margin: 0.75rem 0 0.5rem;
}

.preset-buttons label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text-color);
  font-size: 0.85rem;
}

.preset-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)) !important;
  gap: 0.5rem !important;
}

.preset-btn {
  padding: 0.3rem 0.75rem !important;
  background: var(--light-bg) !important;
  border: 2px solid var(--border-color) !important;
  border-radius: 8px !important;
  color: var(--text-color) !important;
  font-size: 0.85rem !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  text-align: center !important;
  height: auto !important;
  line-height: 1.2 !important;
  display: inline-block !important;
  width: 100% !important;
  box-sizing: border-box !important;
  margin: 0 !important;
}

.preset-btn:hover {
  border-color: var(--primary-purple) !important;
  background: var(--primary-purple) !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 2px 8px rgba(123, 63, 239, 0.3) !important;
}

.preset-btn:active,
.preset-btn.active {
  background: var(--primary-purple) !important;
  border-color: var(--primary-purple) !important;
  color: white !important;
  transform: translateY(0) !important;
}

.preset-btn:focus,
.preset-btn:focus-visible {
  outline: 2px solid var(--primary-purple) !important;
  outline-offset: 2px !important;
}

/* Loan Breakdown Bar */
.loan-breakdown {
  margin: 0.75rem 0;
}

.loan-breakdown-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
  font-size: 0.8rem;
  color: var(--subtle-text);
}

.loan-breakdown-bar {
  height: 28px;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  background: var(--light-bg);
  border: 1px solid var(--border-color);
  margin-bottom: 0.5rem;
}

.breakdown-principal {
  background: linear-gradient(135deg, #4CAF50, #66BB6A);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  transition: width 0.4s ease;
  min-width: 0;
  overflow: hidden;
}

.breakdown-interest {
  background: linear-gradient(135deg, #FF9800, #FFB74D);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  transition: width 0.4s ease;
  min-width: 0;
  overflow: hidden;
}

.breakdown-fees {
  background: linear-gradient(135deg, #3B82F6, #60A5FA);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  transition: width 0.4s ease;
  min-width: 0;
  overflow: hidden;
}

/* Savings Tip */
.savings-tip {
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.1), rgba(102, 187, 106, 0.05));
  border: 2px solid rgba(76, 175, 80, 0.3);
  border-radius: 12px;
  display: none;
}

.savings-tip.show {
  display: block;
  animation: slideIn 0.3s ease;
}

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

.savings-tip-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  color: #2E7D32;
}

.savings-tip-header i[data-lucide] {
  width: 20px;
  height: 20px;
}

.savings-tip-header strong {
  font-size: 0.95rem;
}

.savings-tip p {
  margin: 0;
  color: var(--text-color);
  font-size: 0.9rem;
  line-height: 1.5;
}

/* Highlight Results */
.highlight-result {
  background: linear-gradient(135deg, rgba(123, 63, 239, 0.1), rgba(123, 63, 239, 0.05));
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  transition: opacity 0.3s ease;
}

.interest-value {
  color: #FF9800;
  font-weight: 700;
}

/* Value Update Animation */
.result-value,
.breakdown-principal,
.breakdown-interest,
.breakdown-fees {
  transition: opacity 0.3s ease;
}

/* Info Tooltip */
.info-tooltip {
  position: relative;
  display: inline-flex;
  cursor: help;
}

.info-tooltip:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%);
  background: #1a1a1a;
  color: #ffffff;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  line-height: 1.4;
  white-space: normal;
  width: 280px;
  max-width: 90vw;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  font-weight: 400;
}

[data-theme="light"] .info-tooltip:hover::after {
  background: #1a1a1a;
  color: #ffffff;
}

[data-theme="dark"] .info-tooltip:hover::after {
  background: #f8f9fa;
  color: #1a1a1a;
}

.info-tooltip:hover::before {
  content: '';
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #1a1a1a;
  z-index: 1001;
}

[data-theme="light"] .info-tooltip:hover::before {
  border-top-color: #1a1a1a;
}

[data-theme="dark"] .info-tooltip:hover::before {
  border-top-color: #f8f9fa;
}

@media (max-width: 767px) {
  .info-tooltip:hover::after {
    width: 240px;
    left: auto;
    right: 0;
    transform: none;
  }
  
  .info-tooltip:hover::before {
    left: auto;
    right: 12px;
    transform: none;
  }
}

/* Share Button */
.btn-share {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: var(--primary-purple);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 1rem;
  width: 100%;
}

.btn-share:hover {
  background: var(--primary-purple-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(123, 63, 239, 0.3);
}

.btn-share i[data-lucide] {
  width: 18px;
  height: 18px;
}

/* Share Modal */
.share-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.share-modal-overlay.active {
  display: flex;
  opacity: 1;
}

.share-modal {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 2rem;
  max-width: 500px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  transform: scale(0.9);
  transition: transform 0.3s ease;
  position: relative;
}

.share-modal-overlay.active .share-modal {
  transform: scale(1);
}

.share-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.share-modal-header h3 {
  margin: 0;
  font-size: 1.5rem;
  color: var(--text-color);
}

.share-modal-close {
  background: transparent !important;
  border: none !important;
  cursor: pointer;
  color: var(--subtle-text) !important;
  padding: 0.5rem !important;
  border-radius: 6px !important;
  transition: all 0.2s ease;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  box-shadow: none !important;
  outline: none !important;
}

.share-modal-close:hover {
  background: var(--light-bg) !important;
  color: var(--text-color) !important;
  box-shadow: none !important;
}

.share-modal-close:focus,
.share-modal-close:focus-visible {
  box-shadow: none !important;
  outline: none !important;
}

.share-modal-close i[data-lucide] {
  width: 24px;
  height: 24px;
}

.share-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.share-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  padding: 1.25rem;
  background: var(--light-bg);
  border: 2px solid var(--border-color);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text-color);
}

.share-option:hover {
  border-color: var(--primary-purple);
  background: rgba(123, 63, 239, 0.05);
  transform: translateY(-2px);
}

.share-option i[data-lucide] {
  width: 32px;
  height: 32px;
  color: var(--primary-purple);
}

.share-option span {
  font-size: 0.9rem;
  font-weight: 600;
}

.share-link-section {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.share-link-section label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-color);
}

.share-link-input-group {
  display: flex;
  gap: 0.5rem;
}

.share-link-input-group input {
  flex: 1;
  padding: 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--light-bg);
  color: var(--text-color);
  font-size: 0.9rem;
}

.share-link-input-group button {
  padding: 0.10rem 1.25rem !important;
  background: var(--primary-purple) !important;
  color: white !important;
  border: none !important;
  border-radius: 5px !important;
  font-weight: 600 !important;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  width: auto !important;
  height: 3.1rem;
  margin: 0 !important;
  box-shadow: none !important;
}

.share-link-input-group button:hover {
  background: var(--primary-purple-hover) !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

.share-link-input-group button:focus,
.share-link-input-group button:focus-visible {
  box-shadow: 0 0 0 3px rgba(123, 63, 239, 0.2) !important;
  outline: none !important;
}

.copy-success {
  display: none;
  margin-top: 0.5rem;
  padding: 0.5rem;
  background: #10b981;
  color: white;
  border-radius: 6px;
  font-size: 0.85rem;
  text-align: center;
  animation: fadeInOut 2s ease;
}

.copy-success.show {
  display: block;
}

@keyframes fadeInOut {
  0%, 100% { opacity: 0; }
  10%, 90% { opacity: 1; }
}

/* Calculator Content Section - Natural Background, Centered */
.calculator-content-section {
  background: transparent;
  padding: 4rem 0;
}

.calculator-content-section .content-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2rem;
  text-align: left;
}

.calculator-content-section h2 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin-bottom: 1.5rem;
  color: var(--text-color);
  line-height: 1.3;
  text-align: left;
}

.calculator-content-section h3 {
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: var(--text-color);
  text-align: left;
}

.calculator-content-section p {
  color: var(--subtle-text);
  line-height: 1.8;
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
  text-align: left;
}

.calculator-content-section ul,
.calculator-content-section ol {
  color: var(--subtle-text);
  line-height: 1.8;
  margin-bottom: 1.5rem;
  padding-left: 2rem;
  list-style-position: outside;
  text-align: left;
}

.calculator-content-section li {
  margin-bottom: 0.75rem;
  text-align: left;
}

.calculator-content-section strong {
  color: var(--text-color);
  font-weight: 600;
}

/* FAQ Section - Natural Background, Centered */
.calculator-faq-section {
  background: transparent;
  padding: 4rem 0;
  border-top: none;
}

.calculator-faq-section .faq-wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2rem;
}

.calculator-faq-section h2 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin-bottom: 2rem;
  color: var(--text-color);
  text-align: center;
}

/* Override Pico CSS details styling */
.calculator-faq-section details.faq-item {
  background: transparent;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
  padding: 0 !important;
}

.calculator-faq-section details.faq-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Override Pico CSS summary styling */
.calculator-faq-section details.faq-item summary.faq-question {
  width: 100%;
  padding: 1.25rem 1.5rem !important;
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  text-align: left;
  cursor: pointer;
  display: flex !important;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 1.05rem;
  font-weight: 600 !important;
  color: var(--text-color) !important;
  transition: all 0.2s ease;
  list-style: none;
  margin: 0 !important;
  outline: none !important;
  box-shadow: none !important;
}

/* Hide Pico's default arrow */
.calculator-faq-section details.faq-item summary.faq-question::after,
.calculator-faq-section details.faq-item summary.faq-question::before,
.calculator-faq-section details.faq-item summary.faq-question::marker {
  display: none !important;
  content: none !important;
}

.calculator-faq-section details.faq-item summary.faq-question::-webkit-details-marker {
  display: none !important;
}

.calculator-faq-section details.faq-item summary.faq-question:hover {
  color: var(--primary-purple) !important;
  background: transparent !important;
}

.calculator-faq-section details.faq-item summary.faq-question:focus,
.calculator-faq-section details.faq-item summary.faq-question:focus-visible {
  color: var(--primary-purple) !important;
  box-shadow: none !important;
  outline: none !important;
  background: transparent !important;
}

.calculator-faq-section summary.faq-question span {
  flex: 1;
}

.calculator-faq-section summary.faq-question i.faq-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.3s ease;
  color: var(--primary-purple);
  margin: 0 !important;
  float: none !important;
}

.calculator-faq-section details.faq-item[open] summary.faq-question i.faq-icon {
  transform: rotate(180deg);
}

.calculator-faq-section .faq-answer {
  padding: 0 1.5rem 1.25rem 1.5rem;
  color: var(--subtle-text);
  line-height: 1.7;
  animation: fadeIn 0.3s ease;
  text-align: left;
}

.calculator-faq-section .faq-answer p {
  margin: 0;
  padding-top: 0.5rem;
  text-align: left;
}

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

/* Mobile Responsiveness */
@media (max-width: 767px) {
  .calculator-hero-section {
    padding: 2rem 0 3rem;
  }
  
  .calculator-container {
    padding: 1.5rem;
    border-radius: 12px;
  }
  
  .share-options {
    grid-template-columns: 1fr;
  }
  
  .share-modal {
    padding: 1.5rem;
    margin: 1rem;
  }
  
  .calculator-content-section,
  .calculator-faq-section {
    padding: 3rem 0;
  }
  
  .calculator-content-section .content-wrapper,
  .calculator-faq-section .faq-wrapper {
    padding: 0 1rem;
  }
  
  /* Mobile optimizations for new features */
  .preset-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
  
  .preset-btn {
    padding: 0.875rem 0.5rem;
    font-size: 0.85rem;
  }
  
  .loan-breakdown-bar {
    height: 40px;
  }
  
  .breakdown-principal,
  .breakdown-interest {
    font-size: 0.75rem;
  }
  
  .savings-tip {
    padding: 0.875rem;
    font-size: 0.85rem;
  }
  
  /* Larger touch targets for mobile sliders */
  input[type="range"] {
    height: 48px;
    -webkit-appearance: none;
    appearance: none;
  }
  
  input[type="range"]::-webkit-slider-thumb {
    width: 24px;
    height: 24px;
    -webkit-appearance: none;
    appearance: none;
  }
  
  input[type="range"]::-moz-range-thumb {
    width: 24px;
    height: 24px;
  }
}

