/*
Theme Name: Nexora Pro
Theme URI: https://santaprasad.com/nexora-pro
Author: Santa Prasad Tharu
Author URI: https://santaprasad.com
Description: Nexora Pro is a modern, ultra-fast WordPress magazine and high-RPM blog theme engineered for Technology, Business, and digital publishers. Built for Core Web Vitals 90+ (LCP < 2.5s, CLS < 0.1) with zero-CLS responsive ad management, high-CTR horizontal card feeds, instant live search, auto table of contents, reading time, and seamless dark mode. Developed with pride by Santa Prasad Tharu.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: santaprasad-pro
Tags: blog, news, magazine, technology, e-commerce, dark-mode, grid-layout, one-column, two-columns, left-sidebar, right-sidebar, custom-colors, custom-menu, custom-logo, featured-images, footer-widgets, full-width-template, theme-options, translation-ready, block-patterns, accessibility-ready

-----------------------------------------------------------------------------------
TABLE OF CONTENTS:
1. CSS Custom Properties / Design Tokens (:root)
2. Reset & Base HTML5 Styles
3. Typography Scale & Fluid Font Sizing
4. Global Layout & Grid System
5. Header & Navigation (Variants & Sticky Behavior)
6. Hero Magazine Section & Featured Posts Grid
7. Post Cards (Grid, List, Magazine layouts)
8. Single Post Article View & Distraction-free Reading Column
9. Auto Table of Contents (TOC) & Reading Progress Bar
10. Floating Social Share Bar & Font Size Adjuster
11. Author Bio Box & Related Posts Section
12. Comments Section (Collapsible for Performance)
13. Sidebar & Widget Styling
14. Ads Management Wrappers (Zero CLS Min-Heights & Aspect Ratios)
15. Footer & Newsletter Signup Section
16. Live Search Modal & Drawer Navigation
17. Accessibility, Focus States, & Print Styles
-----------------------------------------------------------------------------------
*/

/* ==========================================================================
   1. CSS CUSTOM PROPERTIES / DESIGN TOKENS
   ========================================================================== */
:root {
  /* Brand Color Palette (Light Mode Default) */
  --sp-primary: #2563eb;          /* Tech Blue */
  --sp-primary-hover: #1d4ed8;
  --sp-primary-rgb: 37, 99, 235;
  --sp-secondary: #0f172a;        /* Deep Slate */
  --sp-secondary-hover: #1e293b;
  --sp-accent: #f59e0b;           /* Amber Accent */
  --sp-accent-hover: #d97706;

  /* Surfaces & Backgrounds */
  --sp-bg: #f8fafc;
  --sp-surface: #ffffff;
  --sp-surface-alt: #f1f5f9;
  --sp-surface-elevated: #ffffff;

  /* Text & Foreground */
  --sp-text: #0f172a;
  --sp-text-muted: #64748b;
  --sp-text-light: #94a3b8;
  --sp-border: #e2e8f0;
  --sp-border-light: #f1f5f9;

  /* Status Colors */
  --sp-success: #10b981;
  --sp-warning: #f59e0b;
  --sp-danger: #ef4444;
  --sp-info: #0ea5e9;

  /* Category Badges */
  --sp-cat-tech: #2563eb;
  --sp-cat-business: #059669;
  --sp-cat-finance: #d97706;
  --sp-cat-reviews: #7c3aed;
  --sp-cat-general: #475569;

  /* Fluid Typography Scale */
  --sp-font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans Devanagari", "Hind", Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  --sp-font-heading: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans Devanagari", "Hind", sans-serif;
  --sp-font-code: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace;

  /* Fluid Font Sizes using clamp() */
  --sp-text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.8125rem);      /* 12-13px */
  --sp-text-sm: clamp(0.8438rem, 0.8rem + 0.25vw, 0.9063rem);    /* 13.5-14.5px */
  --sp-text-base: clamp(1rem, 0.95rem + 0.25vw, 1.0625rem);      /* 16-17px */
  --sp-text-lg: clamp(1.125rem, 1.05rem + 0.35vw, 1.25rem);      /* 18-20px */
  --sp-text-xl: clamp(1.25rem, 1.15rem + 0.5vw, 1.45rem);        /* 20-23px */
  --sp-text-2xl: clamp(1.5rem, 1.35rem + 0.75vw, 1.875rem);      /* 24-30px */
  --sp-text-3xl: clamp(1.875rem, 1.65rem + 1vw, 2.375rem);       /* 30-38px */
  --sp-text-4xl: clamp(2.25rem, 1.95rem + 1.5vw, 3rem);          /* 36-48px */

  /* Line Heights */
  --sp-lh-tight: 1.2;
  --sp-lh-snug: 1.35;
  --sp-lh-base: 1.65;
  --sp-lh-relaxed: 1.8;

  /* Spacing Scale (8px system) */
  --sp-space-1: 0.25rem;  /* 4px */
  --sp-space-2: 0.5rem;   /* 8px */
  --sp-space-3: 0.75rem;  /* 12px */
  --sp-space-4: 1rem;     /* 16px */
  --sp-space-5: 1.25rem;  /* 20px */
  --sp-space-6: 1.5rem;   /* 24px */
  --sp-space-8: 2rem;     /* 32px */
  --sp-space-10: 2.5rem;  /* 40px */
  --sp-space-12: 3rem;    /* 48px */
  --sp-space-16: 4rem;    /* 64px */

  /* Layout Containers */
  --sp-container-width: 1240px;
  --sp-reading-width: 740px;
  --sp-sidebar-width: 340px;

  /* Radii & Shadows */
  --sp-radius-sm: 6px;
  --sp-radius-md: 10px;
  --sp-radius-lg: 16px;
  --sp-radius-full: 9999px;

  --sp-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
  --sp-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.04);
  --sp-shadow-lg: 0 10px 25px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
  --sp-shadow-hover: 0 14px 28px rgba(0, 0, 0, 0.12), 0 6px 10px rgba(0, 0, 0, 0.06);

  /* Transitions */
  --sp-transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --sp-transition-normal: 250ms cubic-bezier(0.4, 0, 0.2, 1);
  --sp-transition-smooth: 350ms cubic-bezier(0.16, 1, 0.3, 1);

  /* Z-Index Hierarchy */
  --sp-z-dropdown: 100;
  --sp-z-sticky: 500;
  --sp-z-drawer: 1000;
  --sp-z-modal: 1100;
  --sp-z-progress: 1200;
}

/* ==========================================================================
   2. RESET & BASE HTML5 STYLES
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

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

body {
  font-family: var(--sp-font-body);
  font-size: var(--sp-text-base);
  line-height: var(--sp-lh-base);
  color: var(--sp-text);
  background-color: var(--sp-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color var(--sp-transition-normal), color var(--sp-transition-normal);
}

img, picture, video {
  max-width: 100%;
  height: auto;
  display: block;
  vertical-align: middle;
}

svg {
  max-width: 100%;
}

a {
  color: var(--sp-primary);
  text-decoration: none;
  transition: color var(--sp-transition-fast);
}

a:hover, a:focus {
  color: var(--sp-primary-hover);
  text-decoration: underline;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

ul, ol {
  list-style: none;
}

/* Skip link for Accessibility */
.sp-skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--sp-primary);
  color: #ffffff !important;
  padding: 0.75rem 1.25rem;
  z-index: 99999;
  font-weight: 600;
  border-radius: var(--sp-radius-sm);
  box-shadow: var(--sp-shadow-lg);
  transition: top var(--sp-transition-fast);
  text-decoration: none !important;
}

.sp-skip-link:focus {
  top: 1rem;
  outline: 3px solid #ffffff;
}

/* ==========================================================================
   3. TYPOGRAPHY
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--sp-font-heading);
  color: var(--sp-secondary);
  font-weight: 700;
  line-height: var(--sp-lh-tight);
  margin-top: 0;
  letter-spacing: -0.02em;
}

h1 { font-size: var(--sp-text-4xl); }
h2 { font-size: var(--sp-text-3xl); }
h3 { font-size: var(--sp-text-2xl); }
h4 { font-size: var(--sp-text-xl); }
h5 { font-size: var(--sp-text-lg); }
h6 { font-size: var(--sp-text-base); }

p {
  margin-bottom: var(--sp-space-5);
}

p:last-child {
  margin-bottom: 0;
}

/* Reading font scaling modifier (A- / A+ feature) */
body.sp-font-small .sp-entry-content { font-size: 0.9375rem; }
body.sp-font-large .sp-entry-content { font-size: 1.1875rem; }
body.sp-font-xlarge .sp-entry-content { font-size: 1.3125rem; }

/* ==========================================================================
   4. GLOBAL LAYOUT & CONTAINERS
   ========================================================================== */
.sp-site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.sp-site-main {
  flex: 1 0 auto;
  padding-top: var(--sp-space-8);
  padding-bottom: var(--sp-space-12);
}

.sp-container {
  width: 100%;
  max-width: var(--sp-container-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--sp-space-4);
  padding-right: var(--sp-space-4);
}

.sp-container-boxed {
  background-color: var(--sp-surface);
  box-shadow: var(--sp-shadow-md);
  border-radius: var(--sp-radius-md);
  padding-top: var(--sp-space-6);
  padding-bottom: var(--sp-space-6);
}

.sp-main-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-space-8);
}

@media (min-width: 1024px) {
  .sp-main-layout.sp-has-sidebar-right {
    grid-template-columns: minmax(0, 1fr) var(--sp-sidebar-width);
  }
  .sp-main-layout.sp-has-sidebar-left {
    grid-template-columns: var(--sp-sidebar-width) minmax(0, 1fr);
  }
  .sp-main-layout.sp-has-sidebar-left .sp-primary-content {
    grid-column: 2;
  }
  .sp-main-layout.sp-has-sidebar-left .sp-sidebar-wrapper {
    grid-column: 1;
    grid-row: 1;
  }
  .sp-main-layout.sp-no-sidebar {
    grid-template-columns: 1fr;
  }
  .sp-main-layout.sp-no-sidebar .sp-primary-content {
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
  }
}

/* ==========================================================================
   5. HEADER & NAVIGATION
   ========================================================================== */
.sp-header {
  background-color: var(--sp-surface);
  border-bottom: 1px solid var(--sp-border);
  position: relative;
  width: 100%;
  z-index: var(--sp-z-sticky);
  transition: transform var(--sp-transition-normal), box-shadow var(--sp-transition-normal);
}

.sp-header.sp-sticky {
  position: sticky;
  top: 0;
}

.sp-header.sp-header-hidden {
  transform: translateY(-100%);
}

.sp-header.sp-header-scrolled {
  box-shadow: var(--sp-shadow-md);
}

/* Top bar for date/trending/social */
.sp-topbar {
  background: var(--sp-surface-alt);
  border-bottom: 1px solid var(--sp-border-light);
  font-size: var(--sp-text-xs);
  color: var(--sp-text-muted);
  padding: 0.35rem 0;
}

.sp-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sp-topbar-trending {
  display: flex;
  align-items: center;
  gap: var(--sp-space-2);
}

.sp-topbar-badge {
  background: var(--sp-danger);
  color: #ffffff;
  padding: 2px 6px;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.6875rem;
  border-radius: var(--sp-radius-sm);
}

.sp-topbar-social {
  display: flex;
  align-items: center;
  gap: var(--sp-space-2);
}

.sp-topbar-social .sp-social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: var(--sp-text-muted);
  background: transparent;
  transition: all var(--sp-transition-fast);
}

.sp-topbar-social .sp-social-btn .sp-svg-icon {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

/* Main Navbar */
.sp-navbar {
  padding: var(--sp-space-4) 0;
}

.sp-navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-space-6);
}

/* Logo styling */
.sp-branding {
  display: flex;
  align-items: center;
}

.sp-site-title {
  font-size: clamp(1.4rem, 1.2rem + 0.5vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--sp-secondary);
}

.sp-site-title a {
  color: inherit;
  text-decoration: none;
}

.sp-site-title a span.sp-highlight {
  color: var(--sp-primary);
}

.sp-site-description {
  font-size: var(--sp-text-xs);
  color: var(--sp-text-muted);
  margin-top: 2px;
}

.custom-logo {
  max-height: 52px;
  width: auto;
}

/* Header Banner Slot (Header Layout 2) */
.sp-header-banner-slot {
  display: none;
}

@media (min-width: 900px) {
  .sp-header-banner-slot {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    flex-grow: 1;
  }
}

/* Desktop Navigation Menu */
.sp-desktop-nav {
  display: none;
}

@media (min-width: 1024px) {
  .sp-desktop-nav {
    display: block;
    margin-left: auto;
  }
  .sp-main-menu {
    display: flex;
    align-items: center;
    gap: var(--sp-space-6);
  }
  .sp-main-menu > li {
    position: relative;
  }
  .sp-main-menu a {
    color: var(--sp-secondary);
    font-weight: 600;
    font-size: 0.9375rem;
    padding: var(--sp-space-2) 0;
    display: inline-block;
    transition: color var(--sp-transition-fast);
  }
  .sp-main-menu a:hover,
  .sp-main-menu .current-menu-item > a {
    color: var(--sp-primary);
    text-decoration: none;
  }
  /* Submenus / Dropdowns */
  .sp-main-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 210px;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--sp-radius-md);
    box-shadow: var(--sp-shadow-lg);
    padding: var(--sp-space-2) 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity var(--sp-transition-fast), transform var(--sp-transition-fast), visibility var(--sp-transition-fast);
    z-index: var(--sp-z-dropdown);
  }
  .sp-main-menu li:hover > .sub-menu,
  .sp-main-menu li:focus-within > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }
  .sp-main-menu .sub-menu a {
    display: block;
    padding: var(--sp-space-2) var(--sp-space-4);
    font-size: 0.875rem;
    color: var(--sp-text);
  }
  .sp-main-menu .sub-menu a:hover {
    background-color: var(--sp-surface-alt);
    color: var(--sp-primary);
  }
  .sp-main-menu > li:last-child .sub-menu,
  .sp-main-menu > li:nth-last-child(2) .sub-menu {
    left: auto;
    right: 0;
  }
}

/* Header Actions: Search, Dark Mode, Mobile Hamburger */
.sp-header-actions {
  display: flex;
  align-items: center;
  gap: var(--sp-space-2);
}

.sp-icon-btn {
  background: transparent;
  border: 1px solid var(--sp-border);
  color: var(--sp-text);
  width: 40px;
  height: 40px;
  border-radius: var(--sp-radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--sp-transition-fast);
}

.sp-icon-btn:hover {
  background-color: var(--sp-surface-alt);
  color: var(--sp-primary);
  border-color: var(--sp-primary);
}

.sp-hamburger {
  display: inline-flex;
}

@media (min-width: 1024px) {
  .sp-hamburger {
    display: none;
  }
}

/* Reading Progress Bar on top */
.sp-reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--sp-primary), var(--sp-accent));
  z-index: var(--sp-z-progress);
  transition: width 75ms ease-out;
}

/* ==========================================================================
   6. HERO MAGAZINE SECTION & FEATURED POSTS
   ========================================================================== */
.sp-hero-section {
  margin-bottom: var(--sp-space-10);
}

.sp-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-space-4);
}

@media (min-width: 768px) {
  .sp-hero-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .sp-hero-grid {
    grid-template-columns: 1.6fr 1fr;
    grid-template-rows: 240px 240px;
  }
  .sp-hero-grid .sp-hero-main {
    grid-column: 1;
    grid-row: 1 / span 2;
  }
  .sp-hero-grid .sp-hero-sub:nth-child(2) {
    grid-column: 2;
    grid-row: 1;
  }
  .sp-hero-grid .sp-hero-sub:nth-child(3) {
    grid-column: 2;
    grid-row: 2;
  }
}

.sp-hero-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--sp-radius-md);
  background: var(--sp-secondary);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--sp-space-6);
  min-height: 280px;
  box-shadow: var(--sp-shadow-md);
}

.sp-hero-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.1) 0%, rgba(0, 0, 0, 0.85) 100%);
  z-index: 1;
  pointer-events: none;
}

.sp-hero-card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--sp-transition-smooth);
}

.sp-hero-card:hover .sp-hero-card-img {
  transform: scale(1.04);
}

.sp-hero-content {
  position: relative;
  z-index: 2;
}

.sp-hero-card .sp-hero-title {
  color: #ffffff;
  font-size: var(--sp-text-xl);
  font-weight: 700;
  line-height: var(--sp-lh-snug);
  margin-top: var(--sp-space-2);
  margin-bottom: var(--sp-space-2);
}

.sp-hero-main .sp-hero-title {
  font-size: var(--sp-text-2xl);
}

.sp-hero-card .sp-hero-title a {
  color: #ffffff;
  text-decoration: none;
}

.sp-hero-card .sp-hero-title a:hover {
  text-decoration: underline;
}

.sp-hero-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-space-3);
  font-size: var(--sp-text-xs);
  color: rgba(255, 255, 255, 0.85);
}

/* Trending strip */
.sp-trending-strip {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  padding: var(--sp-space-3) var(--sp-space-4);
  margin-bottom: var(--sp-space-8);
  display: flex;
  align-items: center;
  gap: var(--sp-space-4);
  overflow-x: auto;
}

.sp-trending-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--sp-text-xs);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--sp-primary);
  white-space: nowrap;
}

.sp-trending-list {
  display: flex;
  align-items: center;
  gap: var(--sp-space-6);
  white-space: nowrap;
}

.sp-trending-item a {
  font-size: var(--sp-text-sm);
  font-weight: 500;
  color: var(--sp-text);
}

.sp-trending-item a:hover {
  color: var(--sp-primary);
}

/* ==========================================================================
   7. RECENT POSTS SECTION HEADER, CARDS & RESPONSIVE GRID
   ========================================================================== */
.sp-section-header {
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-3);
  border-bottom: 2px solid var(--sp-border);
  padding-bottom: var(--sp-space-4);
  margin-bottom: var(--sp-space-8);
}

@media (min-width: 640px) {
  .sp-section-header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.sp-section-header-content {
  display: flex;
  flex-direction: column;
}

.sp-section-title {
  font-size: var(--sp-text-2xl);
  font-weight: 800;
  position: relative;
  display: inline-block;
  color: var(--sp-secondary);
  line-height: 1.2;
}

.sp-section-title::after {
  content: "";
  position: absolute;
  bottom: -18px;
  left: 0;
  width: 52px;
  height: 3px;
  background: var(--sp-primary);
  border-radius: var(--sp-radius-full);
}

.sp-section-subtitle {
  font-size: var(--sp-text-sm);
  color: var(--sp-text-muted);
  margin-top: 6px;
  margin-bottom: 0;
  line-height: 1.45;
}

.sp-section-view-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--sp-primary);
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--sp-transition-fast);
  padding-bottom: 2px;
}

.sp-section-view-all:hover {
  color: var(--sp-primary-hover);
  transform: translateX(3px);
  text-decoration: none;
}

/* Responsive Grid (CSS Grid Container) */
.sp-posts-grid {
  display: grid;
  grid-template-columns: 1fr; /* Mobile: 1 card per row */
  gap: var(--sp-space-6);
  margin-bottom: var(--sp-space-10);
  align-items: stretch;
}

@media (min-width: 640px) {
  .sp-posts-grid {
    grid-template-columns: repeat(2, 1fr); /* Tablet: 2 cards per row */
  }
}

@media (min-width: 1024px) {
  .sp-posts-grid.sp-cols-3 {
    grid-template-columns: repeat(3, 1fr); /* Desktop: 3 cards per row */
  }
  .sp-posts-grid.sp-cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .sp-posts-grid.sp-cols-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Premium Card Appearance (Flexbox Internal Structure) */
.sp-card {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04), 0 1px 2px -1px rgba(0, 0, 0, 0.02);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.25s ease;
}

/* Card Radius Modifiers */
.sp-card-radius-soft { border-radius: 14px; }
.sp-card-radius-rounded { border-radius: 20px; }
.sp-card-radius-sharp { border-radius: 4px; }

.sp-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 32px -8px rgba(0, 0, 0, 0.1), 0 4px 12px -2px rgba(0, 0, 0, 0.04);
  border-color: rgba(var(--sp-primary-rgb), 0.45);
}

/* 1. Featured Image at Top (Compact & Proportioned) */
.sp-card-thumb-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: var(--sp-surface-alt);
  aspect-ratio: 16 / 9;
  max-height: 190px;
}

.sp-aspect-16-9 { aspect-ratio: 16 / 9; max-height: 190px; }
.sp-aspect-4-3  { aspect-ratio: 4 / 3; max-height: 190px; }
.sp-aspect-3-2  { aspect-ratio: 3 / 2; max-height: 190px; }
.sp-aspect-1-1  { aspect-ratio: 1 / 1; max-height: 190px; }

.sp-card-thumb-link {
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.sp-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sp-card:hover .sp-card-thumb {
  transform: scale(1.05);
}

/* Floating Category Badge overlaid on image (Compact) */
.sp-card-thumb-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  pointer-events: auto;
}

.sp-card-thumb-badge .sp-badge {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 0.625rem;
  letter-spacing: 0.05em;
  font-weight: 700;
  text-transform: uppercase;
}

/* 2. Card Body Content (Compact Padding & Proportions) */
.sp-card-body {
  padding: 1rem 1.15rem 0.85rem;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

/* Post Title Directly Below Image (Balanced Size) */
.sp-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  margin-top: 0;
  margin-bottom: 0.4rem;
  letter-spacing: -0.01em;
  color: var(--sp-text);
}

.sp-card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.sp-card-title a:hover,
.sp-card:hover .sp-card-title a {
  color: var(--sp-primary);
  text-decoration: none;
}

/* Short Post Excerpt (Crisp 2-line clamp) */
.sp-card-excerpt {
  font-size: 0.8125rem;
  color: var(--sp-text-muted);
  line-height: 1.5;
  margin-bottom: 0.75rem;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  flex-grow: 1; /* Pushes card footer to the bottom */
}

/* 3. Card Footer with Metadata Row and Read More Button (Compact) */
.sp-card-footer {
  margin-top: auto;
  border-top: 1px solid var(--sp-border-light);
  padding-top: 0.65rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

/* Horizontal Post Metadata Flex Row */
.sp-card-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  font-size: 0.75rem;
  color: var(--sp-text-muted);
  line-height: 1;
}

.sp-card-meta-item {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  white-space: nowrap !important;
}

.sp-card-avatar {
  border-radius: 50% !important;
  width: 20px !important;
  height: 20px !important;
  object-fit: cover !important;
  display: inline-block !important;
  vertical-align: middle !important;
  box-shadow: 0 0 0 1px var(--sp-border) !important;
  flex-shrink: 0 !important;
}

.sp-card-meta-author a {
  color: var(--sp-text);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.2s ease;
}

.sp-card-meta-author a:hover {
  color: var(--sp-primary);
}

.sp-card-meta-sep {
  color: var(--sp-text-light);
  opacity: 0.4;
  margin: 0 1px;
}

.sp-meta-svg {
  width: 12px !important;
  height: 12px !important;
  display: inline-block !important;
  vertical-align: -1px !important;
  flex-shrink: 0 !important;
  stroke: var(--sp-text-muted);
}

.sp-read-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--sp-primary);
  text-decoration: none !important;
  transition: gap 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}

.sp-read-more-btn:hover {
  color: var(--sp-primary-hover);
  gap: 7px;
}

/* List Style Layout (Horizontal Cards) */
.sp-posts-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-6);
  margin-bottom: var(--sp-space-10);
}

.sp-card-list,
.sp-card-horizontal {
  flex-direction: column;
}

@media (min-width: 640px) {
  .sp-card-list,
  .sp-card-horizontal {
    flex-direction: row;
    align-items: stretch;
  }
  .sp-card-list .sp-card-thumb-wrapper,
  .sp-card-horizontal .sp-card-thumb-wrapper {
    width: 200px;
    max-width: 32%;
    flex-shrink: 0;
    aspect-ratio: auto;
    min-height: 125px;
    max-height: 145px;
  }
  .sp-card-list .sp-card-thumb,
  .sp-card-horizontal .sp-card-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .sp-card-list .sp-card-body,
  .sp-card-horizontal .sp-card-body {
    padding: 0.75rem 1.15rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  .sp-card-list .sp-card-title,
  .sp-card-horizontal .sp-card-title {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.35;
    margin: 0 0 0.35rem 0;
  }
}

/* ==========================================================================
   7.0 FULL-WIDTH HORIZONTAL STRIP (HEIGHT ~2.5CM / ~105PX - YOUTUBE STYLE)
   ========================================================================== */
.sp-posts-strip-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  margin-bottom: var(--sp-space-8);
}

.sp-card-strip {
  display: flex !important;
  flex-direction: row !important;
  align-items: stretch !important;
  width: 100% !important;
  height: 108px;
  min-height: 105px;
  max-height: 115px;
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md, 10px);
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
  position: relative;
  box-sizing: border-box;
}

.sp-card-strip:hover {
  transform: translateY(-2px);
  border-color: var(--sp-primary);
  box-shadow: 0 6px 18px -2px rgba(37, 99, 235, 0.12), 0 2px 6px -1px rgba(0, 0, 0, 0.06);
}

/* Strip Left Thumbnail (~2.5cm height, 16:9 widescreen) */
.sp-strip-thumb-wrap {
  position: relative;
  width: 185px;
  min-width: 185px;
  max-width: 195px;
  height: 100%;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--sp-border);
}

.sp-strip-thumb-link {
  display: block;
  width: 100%;
  height: 100%;
}

.sp-strip-thumb-wrap img,
.sp-strip-thumb-wrap .sp-card-thumb,
.sp-strip-thumb-wrap .sp-strip-thumb {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
  transition: transform 0.35s ease;
}

.sp-card-strip:hover .sp-strip-thumb-wrap img,
.sp-card-strip:hover .sp-strip-thumb-wrap .sp-card-thumb,
.sp-card-strip:hover .sp-strip-thumb-wrap .sp-strip-thumb {
  transform: scale(1.05);
}

.sp-strip-thumb-badge {
  position: absolute;
  top: 6px;
  left: 6px;
  z-index: 2;
  pointer-events: none;
}

.sp-strip-thumb-badge .sp-badge {
  padding: 2px 7px;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 4px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  line-height: 1.25;
}

/* Strip Right Content (Full Width Fill) */
.sp-strip-content {
  flex: 1;
  min-width: 0;
  padding: 10px 16px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.sp-strip-title {
  font-size: 1.025rem;
  font-weight: 700;
  line-height: 1.35;
  margin: 0 0 5px 0;
  color: var(--sp-secondary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-strip-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease;
}

.sp-strip-title a:hover {
  color: var(--sp-primary);
}

.sp-strip-meta {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 7px;
  font-size: 0.75rem;
  color: var(--sp-text-muted);
  margin-bottom: 5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-strip-meta .sp-strip-author {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 600;
  color: var(--sp-text);
  flex-shrink: 0;
}

.sp-strip-meta .sp-strip-avatar {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  object-fit: cover;
  display: inline-block !important;
  vertical-align: middle !important;
}

.sp-strip-meta .sp-strip-author a {
  color: inherit;
  text-decoration: none;
}

.sp-strip-meta .sp-strip-author a:hover {
  color: var(--sp-primary);
}

.sp-strip-meta .sp-strip-date,
.sp-strip-meta .sp-strip-reading {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.sp-strip-meta .sp-meta-svg {
  width: 12px;
  height: 12px;
  stroke: var(--sp-text-muted);
  display: inline-block !important;
  vertical-align: -1px !important;
  flex-shrink: 0 !important;
}

.sp-strip-meta .sp-card-meta-sep {
  opacity: 0.5;
  font-size: 0.7rem;
}

.sp-badge-updated-tiny {
  display: inline-flex;
  align-items: center;
  padding: 1px 6px;
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: 3px;
  background-color: rgba(37, 99, 235, 0.1);
  color: var(--sp-primary);
  line-height: 1.3;
}

.sp-strip-excerpt {
  font-size: 0.7813rem;
  color: var(--sp-text-muted);
  line-height: 1.4;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Strip Responsive Queries */
@media (max-width: 680px) {
  .sp-card-strip {
    height: 96px;
    min-height: 92px;
    max-height: 102px;
  }
  .sp-strip-thumb-wrap {
    width: 135px;
    min-width: 135px;
    max-width: 140px;
  }
  .sp-strip-content {
    padding: 8px 12px;
  }
  .sp-strip-title {
    font-size: 0.925rem;
    line-height: 1.3;
    margin-bottom: 3px;
  }
  .sp-strip-meta {
    font-size: 0.7rem;
    gap: 5px;
    margin-bottom: 3px;
  }
  .sp-strip-meta .sp-strip-reading {
    display: none;
  }
  .sp-strip-excerpt {
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .sp-card-strip {
    height: 86px;
    min-height: 84px;
    max-height: 90px;
  }
  .sp-strip-thumb-wrap {
    width: 108px;
    min-width: 108px;
    max-width: 112px;
  }
  .sp-strip-content {
    padding: 6px 10px;
  }
  .sp-strip-title {
    font-size: 0.84rem;
    line-height: 1.25;
    margin-bottom: 3px;
  }
  .sp-strip-meta {
    font-size: 0.6875rem;
  }
  .sp-strip-excerpt {
    display: none;
  }
}

/* Category Badges */
.sp-badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--sp-radius-sm);
  color: #ffffff;
  background-color: var(--sp-primary);
  line-height: 1.3;
}

.sp-badge:hover {
  opacity: 0.9;
  text-decoration: none;
  color: #ffffff;
}

.sp-badge-tech { background-color: var(--sp-cat-tech); }
.sp-badge-business { background-color: var(--sp-cat-business); }
.sp-badge-finance { background-color: var(--sp-cat-finance); }
.sp-badge-reviews { background-color: var(--sp-cat-reviews); }

/* ==========================================================================
   7.1 NUMERIC POSTS PAGINATION (PAGE 1, 2, 3... NEXT)
   ========================================================================== */
.sp-pagination,
.navigation.pagination {
  margin: var(--sp-space-8) 0 var(--sp-space-12) 0;
  text-align: center;
}

.sp-pagination .nav-links,
.navigation.pagination .nav-links {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  padding: 8px 12px;
  border-radius: var(--sp-radius-lg, 12px);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.sp-pagination .page-numbers,
.navigation.pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--sp-text);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--sp-radius-md, 8px);
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.sp-pagination .page-numbers:hover,
.navigation.pagination .page-numbers:hover {
  background: var(--sp-surface-alt, #f1f5f9);
  color: var(--sp-primary);
  border-color: var(--sp-border);
  transform: translateY(-1px);
}

.sp-pagination .page-numbers.current,
.navigation.pagination .page-numbers.current {
  background: var(--sp-primary);
  color: #ffffff !important;
  border-color: var(--sp-primary);
  box-shadow: 0 4px 12px rgba(var(--sp-primary-rgb), 0.35);
  pointer-events: none;
}

.sp-pagination .page-numbers.dots,
.navigation.pagination .page-numbers.dots {
  border: none;
  background: transparent;
  color: var(--sp-text-muted);
  min-width: 24px;
  pointer-events: none;
}

.sp-pagination .prev.page-numbers,
.sp-pagination .next.page-numbers,
.navigation.pagination .prev.page-numbers,
.navigation.pagination .next.page-numbers {
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 0 14px;
}

.sp-pagination .prev.page-numbers:hover,
.sp-pagination .next.page-numbers:hover,
.navigation.pagination .prev.page-numbers:hover,
.navigation.pagination .next.page-numbers:hover {
  background: var(--sp-primary);
  color: #ffffff !important;
  border-color: var(--sp-primary);
}

.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

/* ==========================================================================
   8. SINGLE POST ARTICLE VIEW & DISTRACTION-FREE READING
   ========================================================================== */
.sp-single-article {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-lg);
  padding: var(--sp-space-6);
  box-shadow: var(--sp-shadow-sm);
}

@media (min-width: 768px) {
  .sp-single-article {
    padding: var(--sp-space-10);
  }
}

.sp-breadcrumbs {
  font-size: var(--sp-text-xs);
  color: var(--sp-text-muted);
  margin-bottom: var(--sp-space-4);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-space-2);
}

.sp-breadcrumbs a {
  color: var(--sp-text-muted);
}

.sp-breadcrumbs a:hover {
  color: var(--sp-primary);
}

.sp-breadcrumbs .sp-sep {
  opacity: 0.5;
}

.sp-entry-header {
  margin-bottom: var(--sp-space-6);
}

.sp-entry-title {
  font-size: var(--sp-text-3xl);
  font-weight: 800;
  line-height: var(--sp-lh-tight);
  color: var(--sp-secondary);
  margin-top: var(--sp-space-3);
  margin-bottom: var(--sp-space-4);
}

.sp-entry-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-space-4);
  font-size: var(--sp-text-sm);
  color: var(--sp-text-muted);
  padding-bottom: var(--sp-space-4);
  border-bottom: 1px solid var(--sp-border);
}

.sp-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.sp-reader-controls {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 4px;
}

.sp-font-btn {
  background: var(--sp-surface-alt);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-sm);
  padding: 2px 8px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

.sp-font-btn:hover {
  background: var(--sp-primary);
  color: #ffffff;
}

.sp-entry-featured-media {
  margin-bottom: var(--sp-space-8);
  border-radius: var(--sp-radius-md);
  overflow: hidden;
}

.sp-entry-featured-media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.sp-featured-caption {
  font-size: var(--sp-text-xs);
  color: var(--sp-text-muted);
  text-align: center;
  padding: var(--sp-space-2) 0;
}

/* Article Content Typography & Formatting */
.sp-entry-content {
  font-size: var(--sp-text-base);
  line-height: var(--sp-lh-relaxed);
  color: var(--sp-text);
  max-width: var(--sp-reading-width);
  margin-left: auto;
  margin-right: auto;
}

.sp-entry-content h2 {
  font-size: var(--sp-text-2xl);
  margin-top: var(--sp-space-10);
  margin-bottom: var(--sp-space-4);
  padding-bottom: var(--sp-space-2);
  border-bottom: 1px solid var(--sp-border-light);
}

.sp-entry-content h3 {
  font-size: var(--sp-text-xl);
  margin-top: var(--sp-space-8);
  margin-bottom: var(--sp-space-3);
}

.sp-entry-content ul,
.sp-entry-content ol {
  margin-bottom: var(--sp-space-6);
  padding-left: var(--sp-space-6);
}

.sp-entry-content ul {
  list-style-type: disc;
}

.sp-entry-content ol {
  list-style-type: decimal;
}

.sp-entry-content li {
  margin-bottom: var(--sp-space-2);
}

.sp-entry-content blockquote {
  border-left: 4px solid var(--sp-primary);
  background: var(--sp-surface-alt);
  padding: var(--sp-space-4) var(--sp-space-6);
  border-radius: 0 var(--sp-radius-md) var(--sp-radius-md) 0;
  margin: var(--sp-space-6) 0;
  font-style: italic;
  color: var(--sp-text);
}

.sp-entry-content blockquote p {
  margin-bottom: 0;
}

.sp-entry-content pre {
  position: relative;
  background: #1e293b;
  color: #e2e8f0;
  padding: var(--sp-space-5);
  border-radius: var(--sp-radius-md);
  overflow-x: auto;
  font-family: var(--sp-font-code);
  font-size: 0.875rem;
  line-height: 1.5;
  margin: var(--sp-space-6) 0;
}

.sp-entry-content code {
  font-family: var(--sp-font-code);
  font-size: 0.875em;
  background: var(--sp-surface-alt);
  color: var(--sp-primary);
  padding: 2px 6px;
  border-radius: var(--sp-radius-sm);
}

.sp-entry-content pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

/* Copy code block button */
.sp-copy-code-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border: none;
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: var(--sp-radius-sm);
  cursor: pointer;
  transition: background var(--sp-transition-fast);
}

.sp-copy-code-btn:hover {
  background: var(--sp-primary);
}

.sp-entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--sp-space-6) 0;
  font-size: var(--sp-text-sm);
}

.sp-entry-content th,
.sp-entry-content td {
  padding: var(--sp-space-3) var(--sp-space-4);
  border: 1px solid var(--sp-border);
  text-align: left;
}

.sp-entry-content th {
  background: var(--sp-surface-alt);
  font-weight: 700;
}

/* ==========================================================================
   9. AUTO TABLE OF CONTENTS (TOC)
   ========================================================================== */
.sp-toc-container {
  background: var(--sp-surface-alt);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  padding: var(--sp-space-5);
  margin: var(--sp-space-6) 0;
}

.sp-toc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-weight: 700;
  color: var(--sp-secondary);
}

.sp-toc-title {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-space-2);
  font-size: 1.05rem;
}

.sp-toc-toggle {
  font-size: var(--sp-text-xs);
  color: var(--sp-primary);
  background: transparent;
  border: none;
  cursor: pointer;
  font-weight: 600;
}

.sp-toc-list {
  margin-top: var(--sp-space-4);
  padding-left: var(--sp-space-4);
  list-style: decimal;
}

.sp-toc-list li {
  margin-bottom: var(--sp-space-2);
  font-size: var(--sp-text-sm);
}

.sp-toc-list li a {
  color: var(--sp-text);
  text-decoration: none;
}

.sp-toc-list li a:hover,
.sp-toc-list li.sp-toc-active a {
  color: var(--sp-primary);
  font-weight: 600;
  text-decoration: underline;
}

.sp-toc-list .sp-toc-h3 {
  margin-left: var(--sp-space-4);
  list-style-type: circle;
}

/* ==========================================================================
   10. FLOATING SHARE BAR & SOCIAL BUTTONS
   ========================================================================== */
.sp-share-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-space-2);
  margin: var(--sp-space-6) 0;
  padding: var(--sp-space-4) 0;
  border-top: 1px solid var(--sp-border);
  border-bottom: 1px solid var(--sp-border);
}

.sp-share-label {
  font-size: var(--sp-text-xs);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--sp-text-muted);
  margin-right: var(--sp-space-2);
}

.sp-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #ffffff !important;
  border-radius: var(--sp-radius-sm);
  text-decoration: none !important;
  transition: opacity var(--sp-transition-fast);
}

.sp-share-btn:hover {
  opacity: 0.88;
}

.sp-share-btn .sp-svg-icon {
  width: 14px;
  height: 14px;
  fill: currentColor;
  flex-shrink: 0;
}

.sp-share-twitter { background-color: #000000; }
.sp-share-facebook { background-color: #1877f2; }
.sp-share-linkedin { background-color: #0a66c2; }
.sp-share-whatsapp { background-color: #25d366; }
.sp-share-telegram { background-color: #229ed9; }
.sp-share-reddit { background-color: #ff4500; }
.sp-share-copy { background-color: var(--sp-secondary); cursor: pointer; }

/* Desktop Floating Share Bar (Side Rail) */
@media (min-width: 1280px) {
  .sp-floating-share {
    position: fixed;
    top: 200px;
    left: calc((100vw - var(--sp-container-width)) / 2 - 60px);
    display: flex;
    flex-direction: column;
    gap: var(--sp-space-2);
    z-index: 50;
  }
  .sp-floating-share .sp-share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    padding: 0;
    justify-content: center;
  }
  .sp-floating-share .sp-share-btn span {
    display: none;
  }
}

/* ==========================================================================
   11. AUTHOR BIO, RELATED POSTS, PREV/NEXT
   ========================================================================== */
.sp-author-box {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-space-5);
  background: var(--sp-surface-alt);
  border-radius: var(--sp-radius-md);
  padding: var(--sp-space-6);
  margin: var(--sp-space-8) 0;
}

.sp-author-box-avatar {
  border-radius: 50%;
  width: 72px;
  height: 72px;
  flex-shrink: 0;
}

.sp-author-box-name {
  font-size: var(--sp-text-lg);
  font-weight: 700;
  margin-bottom: var(--sp-space-2);
}

.sp-author-box-desc {
  font-size: var(--sp-text-sm);
  color: var(--sp-text-muted);
  line-height: var(--sp-lh-base);
  margin-bottom: var(--sp-space-3);
}

.sp-post-nav {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-space-4);
  margin: var(--sp-space-8) 0;
}

@media (min-width: 640px) {
  .sp-post-nav {
    grid-template-columns: 1fr 1fr;
  }
}

.sp-post-nav-card {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  padding: var(--sp-space-4);
  display: flex;
  flex-direction: column;
}

.sp-post-nav-label {
  font-size: var(--sp-text-xs);
  text-transform: uppercase;
  font-weight: 700;
  color: var(--sp-text-muted);
  margin-bottom: var(--sp-space-1);
}

.sp-post-nav-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--sp-secondary);
}

.sp-related-posts {
  margin-top: var(--sp-space-10);
}

/* ==========================================================================
   12. COMMENTS SECTION (COLLAPSIBLE FOR CWV)
   ========================================================================== */
.sp-comments-area {
  margin-top: var(--sp-space-10);
  padding-top: var(--sp-space-8);
  border-top: 1px solid var(--sp-border);
}

.sp-comments-toggle-wrapper {
  text-align: center;
  margin-bottom: var(--sp-space-6);
}

.sp-comments-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-space-2);
  background: var(--sp-surface-alt);
  border: 1px solid var(--sp-border);
  color: var(--sp-text);
  padding: 10px 24px;
  font-weight: 600;
  border-radius: var(--sp-radius-full);
  cursor: pointer;
  transition: all var(--sp-transition-fast);
}

.sp-comments-toggle-btn:hover {
  background: var(--sp-primary);
  color: #ffffff;
  border-color: var(--sp-primary);
}

.sp-comments-container {
  display: none;
}

.sp-comments-container.sp-comments-open {
  display: block;
}

.comment-list {
  margin: var(--sp-space-6) 0;
}

.comment-list .comment {
  border-bottom: 1px solid var(--sp-border-light);
  padding: var(--sp-space-4) 0;
}

.comment-list .children {
  padding-left: var(--sp-space-6);
  border-left: 2px solid var(--sp-border-light);
}

.comment-author {
  display: flex;
  align-items: center;
  gap: var(--sp-space-3);
  margin-bottom: var(--sp-space-2);
}

.comment-author img {
  border-radius: 50%;
}

.comment-metadata {
  font-size: var(--sp-text-xs);
  color: var(--sp-text-muted);
  margin-bottom: var(--sp-space-2);
}

.comment-content {
  font-size: var(--sp-text-sm);
  line-height: var(--sp-lh-base);
}

.comment-reply-link {
  display: inline-block;
  font-size: var(--sp-text-xs);
  font-weight: 600;
  color: var(--sp-primary);
  margin-top: var(--sp-space-2);
}

/* Comment Form */
#commentform {
  display: grid;
  gap: var(--sp-space-4);
}

#commentform label {
  display: block;
  font-size: var(--sp-text-sm);
  font-weight: 600;
  margin-bottom: var(--sp-space-1);
}

#commentform input[type="text"],
#commentform input[type="email"],
#commentform input[type="url"],
#commentform textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  color: var(--sp-text);
  font-size: var(--sp-text-sm);
}

#commentform input:focus,
#commentform textarea:focus {
  outline: none;
  border-color: var(--sp-primary);
  box-shadow: 0 0 0 3px rgba(var(--sp-primary-rgb), 0.15);
}

#commentform input[type="submit"] {
  background: var(--sp-primary);
  color: #ffffff;
  border: none;
  padding: 10px 24px;
  font-weight: 600;
  border-radius: var(--sp-radius-md);
  cursor: pointer;
  align-self: flex-start;
  transition: background var(--sp-transition-fast);
}

#commentform input[type="submit"]:hover {
  background: var(--sp-primary-hover);
}

/* ==========================================================================
   13. SIDEBAR & WIDGETS
   ========================================================================== */
.sp-sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-8);
}

.sp-widget {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  padding: var(--sp-space-6);
  box-shadow: var(--sp-shadow-sm);
}

.sp-widget-title {
  font-size: var(--sp-text-lg);
  font-weight: 700;
  color: var(--sp-secondary);
  border-bottom: 2px solid var(--sp-border);
  padding-bottom: var(--sp-space-3);
  margin-bottom: var(--sp-space-5);
  position: relative;
}

.sp-widget-title::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 36px;
  height: 2px;
  background: var(--sp-primary);
}

.sp-widget ul li {
  padding: var(--sp-space-2) 0;
  border-bottom: 1px solid var(--sp-border-light);
  font-size: 0.9375rem;
}

.sp-widget ul li:last-child {
  border-bottom: none;
}

/* ==========================================================================
   RECENT POSTS HORIZONTAL CARD VIEW (webinhindi.co Style - Image 2)
   ========================================================================== */
.sp-recent-cards-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-3);
  margin-top: var(--sp-space-3);
}

.sp-recent-card-item {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.sp-recent-card-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  border-color: var(--sp-primary);
}

/* Thumbnail on Left (Compact) */
.sp-recent-card-thumb-wrap {
  width: 95px;
  min-width: 95px;
  max-width: 105px;
  position: relative;
  overflow: hidden;
  background-color: var(--sp-border-light);
  flex-shrink: 0;
}

.sp-recent-card-thumb-link {
  display: block;
  width: 100%;
  height: 100%;
}

.sp-recent-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.sp-recent-card-item:hover .sp-recent-card-thumb {
  transform: scale(1.06);
}

/* Card Body Content on Right (Compact) */
.sp-recent-card-body {
  flex: 1;
  padding: 0.55rem 0.75rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.sp-recent-card-meta-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.25rem;
}

.sp-recent-card-title {
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.32;
  margin: 0 0 0.25rem 0;
  color: var(--sp-text);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.sp-recent-card-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.18s ease;
}

.sp-recent-card-title a:hover {
  color: var(--sp-primary);
}

.sp-recent-card-excerpt {
  font-size: 0.8125rem;
  color: var(--sp-text-muted);
  line-height: 1.5;
  margin-bottom: 0.35rem;
}

.sp-recent-card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  font-size: 0.75rem;
  color: var(--sp-text-muted);
}

.sp-recent-card-date,
.sp-recent-card-reading {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Updated Freshness Badge ("⚡ Updated") */
.sp-badge-updated {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--sp-radius-sm);
  background-color: rgba(16, 185, 129, 0.12);
  color: #059669;
  line-height: 1.3;
}

[data-theme="dark"] .sp-badge-updated {
  background-color: rgba(16, 185, 129, 0.22);
  color: #34d399;
}

.sp-updated-svg {
  flex-shrink: 0;
}

/* Shortcode Grid/List Variations */
.sp-shortcode-recent-cards {
  margin: var(--sp-space-6) 0;
}

/* Modernize Core WordPress Recent Posts block & default widget */
.widget_recent_entries ul {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 0.75rem !important;
}

.widget_recent_entries ul li {
  background: var(--sp-bg) !important;
  border: 1px solid var(--sp-border) !important;
  border-radius: var(--sp-radius-md) !important;
  padding: 0.875rem 1rem !important;
  font-weight: 600 !important;
  transition: all 0.2s ease !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
}

.widget_recent_entries ul li:hover {
  border-color: var(--sp-primary) !important;
  transform: translateX(4px) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
}

.widget_recent_entries ul li a {
  color: var(--sp-text) !important;
  text-decoration: none !important;
  display: block !important;
}

.widget_recent_entries ul li a:hover {
  color: var(--sp-primary) !important;
}

.widget_recent_entries .post-date {
  display: inline-flex !important;
  align-items: center !important;
  font-size: 0.75rem !important;
  color: var(--sp-text-muted) !important;
  font-weight: 400 !important;
}

/* Core Latest Posts Block Modernization */
.wp-block-latest-posts {
  padding-left: 0 !important;
}

.wp-block-latest-posts li {
  margin-bottom: 0.75rem !important;
}

.sp-sticky-sidebar-ad {
  position: sticky;
  top: 90px;
}

/* ==========================================================================
   14. ADS MANAGEMENT (ZERO CLS & RESPONSIVE MIN-HEIGHTS)
   ========================================================================== */
.sp-ad-wrapper {
  margin: var(--sp-space-6) auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--sp-surface-alt);
  border: 1px dashed var(--sp-border);
  border-radius: var(--sp-radius-sm);
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
}

.sp-ad-label {
  display: block;
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sp-text-muted);
  margin-bottom: 4px;
  user-select: none;
}

.sp-ad-content {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Slot 1: Header Banner (728x90 Desktop, 320x100 Mobile) */
.sp-ad-header-banner {
  min-height: 100px;
  width: 100%;
  max-width: 728px;
}
@media (min-width: 768px) {
  .sp-ad-header-banner {
    min-height: 90px;
  }
}

/* Slot 2: Below Post Title */
.sp-ad-below-title {
  min-height: 250px;
  width: 100%;
  max-width: 728px;
}

/* Slot 3: In-Content (Mid-Article) */
.sp-ad-in-content {
  min-height: 250px;
  width: 100%;
  max-width: 650px;
}

/* Slot 4: Sidebar Banner (300x250) */
.sp-ad-sidebar {
  min-height: 250px;
  width: 100%;
  max-width: 300px;
}

/* Slot 5: Sticky Sidebar Banner (300x600) */
.sp-ad-sticky-sidebar {
  min-height: 600px;
  width: 100%;
  max-width: 300px;
}

/* Slot 6: End of Post / Before Comments */
.sp-ad-end-of-post {
  min-height: 250px;
  width: 100%;
  max-width: 728px;
}

/* Slot 7: Footer Banner */
.sp-ad-footer-banner {
  min-height: 90px;
  width: 100%;
  max-width: 728px;
}

/* Slot 8: Mobile Sticky Bottom (320x50 / 320x100) */
.sp-ad-mobile-sticky {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: var(--sp-z-sticky);
  background: var(--sp-surface);
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
  min-height: 50px;
  margin: 0;
  border-top: 1px solid var(--sp-border);
  border-radius: 0;
}

.sp-ad-close-btn {
  position: absolute;
  top: -24px;
  right: 12px;
  background: var(--sp-secondary);
  color: #ffffff;
  border: none;
  font-size: 0.6875rem;
  padding: 2px 8px;
  border-radius: var(--sp-radius-sm) var(--sp-radius-sm) 0 0;
  cursor: pointer;
}

@media (min-width: 768px) {
  .sp-ad-mobile-sticky {
    display: none !important;
  }
}

/* ==========================================================================
   15. FOOTER & NEWSLETTER SIGNUP
   ========================================================================== */
.sp-footer {
  background: var(--sp-secondary);
  color: #cbd5e1;
  padding-top: var(--sp-space-12);
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sp-newsletter-section {
  background: linear-gradient(135deg, var(--sp-primary) 0%, #1e40af 100%);
  color: #ffffff;
  border-radius: var(--sp-radius-lg);
  padding: var(--sp-space-8);
  margin-bottom: var(--sp-space-12);
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-space-6);
  align-items: center;
}

@media (min-width: 768px) {
  .sp-newsletter-section {
    grid-template-columns: 1.2fr 1fr;
    padding: var(--sp-space-10);
  }
}

.sp-newsletter-title {
  color: #ffffff;
  font-size: var(--sp-text-2xl);
  margin-bottom: var(--sp-space-2);
}

.sp-newsletter-desc {
  font-size: var(--sp-text-sm);
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 0;
}

.sp-newsletter-form {
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-2);
}

@media (min-width: 480px) {
  .sp-newsletter-form {
    flex-direction: row;
  }
}

.sp-newsletter-input {
  flex-grow: 1;
  padding: 12px 16px;
  border-radius: var(--sp-radius-md);
  border: none;
  font-size: var(--sp-text-sm);
  color: var(--sp-text);
  background: #ffffff;
}

.sp-newsletter-btn {
  background: var(--sp-secondary);
  color: #ffffff;
  border: none;
  padding: 12px 24px;
  font-weight: 700;
  border-radius: var(--sp-radius-md);
  cursor: pointer;
  transition: background var(--sp-transition-fast);
  white-space: nowrap;
}

.sp-newsletter-btn:hover {
  background: #000000;
}

/* Footer Widget Columns */
.sp-footer-widgets {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-space-8);
  padding-bottom: var(--sp-space-10);
}

@media (min-width: 640px) {
  .sp-footer-widgets.sp-footer-cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
  .sp-footer-widgets.sp-footer-cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .sp-footer-widgets.sp-footer-cols-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.sp-footer-widget-title {
  color: #ffffff;
  font-size: var(--sp-text-lg);
  font-weight: 700;
  margin-bottom: var(--sp-space-4);
  position: relative;
  padding-bottom: var(--sp-space-2);
}

.sp-footer-widget-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 32px;
  height: 2px;
  background: var(--sp-primary);
}

.sp-footer a {
  color: #cbd5e1;
}

.sp-footer a:hover {
  color: #ffffff;
}

.sp-footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--sp-space-6) 0;
  font-size: var(--sp-text-xs);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-space-4);
}

@media (min-width: 768px) {
  .sp-footer-bottom {
    flex-direction: row;
  }
}

.sp-footer-copyright {
  color: #94a3b8;
}

.sp-footer-social {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-space-2);
}

.sp-footer-social .sp-social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  transition: all var(--sp-transition-fast);
}

.sp-footer-social .sp-social-btn .sp-svg-icon {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

/* Drawer Social Icons */
.sp-drawer-social {
  margin-top: var(--sp-space-6);
  padding-top: var(--sp-space-5);
  border-top: 1px solid var(--sp-border);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-space-2);
}

.sp-drawer-social .sp-social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--sp-radius-sm);
  background: var(--sp-surface-alt);
  border: 1px solid var(--sp-border);
  color: var(--sp-text);
  transition: all var(--sp-transition-fast);
}

.sp-drawer-social .sp-social-btn .sp-svg-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* Individual Brand Hover States & Transitions */
.sp-social-btn:hover {
  transform: translateY(-2px);
  text-decoration: none !important;
}

.sp-social-twitter:hover { background-color: #000000 !important; color: #ffffff !important; }
.sp-social-facebook:hover { background-color: #1877f2 !important; color: #ffffff !important; }
.sp-social-instagram:hover { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%) !important; color: #ffffff !important; }
.sp-social-youtube:hover { background-color: #ff0000 !important; color: #ffffff !important; }
.sp-social-linkedin:hover { background-color: #0a66c2 !important; color: #ffffff !important; }
.sp-social-github:hover { background-color: #24292e !important; color: #ffffff !important; }
.sp-social-pinterest:hover { background-color: #e60023 !important; color: #ffffff !important; }
.sp-social-tiktok:hover { background-color: #000000 !important; color: #ffffff !important; }
.sp-social-telegram:hover { background-color: #229ed9 !important; color: #ffffff !important; }
.sp-social-whatsapp:hover { background-color: #25d366 !important; color: #ffffff !important; }
.sp-social-reddit:hover { background-color: #ff4500 !important; color: #ffffff !important; }
.sp-social-rss:hover { background-color: #ee802f !important; color: #ffffff !important; }

/* ==========================================================================
   16. LIVE SEARCH MODAL & DRAWER NAVIGATION
   ========================================================================== */
.sp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  z-index: var(--sp-z-modal);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 10vh;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--sp-transition-fast), visibility var(--sp-transition-fast);
}

.sp-modal-overlay.sp-modal-open {
  opacity: 1;
  visibility: visible;
}

.sp-search-modal-box {
  background: var(--sp-surface);
  border: 1px solid var(--sp-border);
  border-radius: var(--sp-radius-lg);
  width: 90%;
  max-width: 640px;
  padding: var(--sp-space-6);
  box-shadow: var(--sp-shadow-lg);
  transform: translateY(-20px);
  transition: transform var(--sp-transition-normal);
}

.sp-modal-overlay.sp-modal-open .sp-search-modal-box {
  transform: translateY(0);
}

.sp-search-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.sp-search-field-live {
  width: 100%;
  font-size: var(--sp-text-lg);
  padding: 12px 48px 12px 16px;
  border: 2px solid var(--sp-border);
  border-radius: var(--sp-radius-md);
  background: var(--sp-surface-alt);
  color: var(--sp-text);
}

.sp-search-field-live:focus {
  outline: none;
  border-color: var(--sp-primary);
  background: var(--sp-surface);
}

.sp-search-close-btn {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  color: var(--sp-text-muted);
  cursor: pointer;
  padding: 6px;
}

.sp-search-results {
  max-height: 50vh;
  overflow-y: auto;
  margin-top: var(--sp-space-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-space-2);
}

.sp-search-result-item {
  display: flex;
  align-items: center;
  gap: var(--sp-space-3);
  padding: var(--sp-space-3);
  border-radius: var(--sp-radius-md);
  text-decoration: none !important;
  transition: background var(--sp-transition-fast);
}

.sp-search-result-item:hover {
  background: var(--sp-surface-alt);
}

.sp-search-result-thumb {
  width: 54px;
  height: 54px;
  border-radius: var(--sp-radius-sm);
  object-fit: cover;
  flex-shrink: 0;
}

.sp-search-result-title {
  font-size: var(--sp-text-sm);
  font-weight: 600;
  color: var(--sp-secondary);
}

/* Mobile Slide-in Drawer */
.sp-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: var(--sp-z-drawer);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--sp-transition-fast), visibility var(--sp-transition-fast);
}

.sp-drawer-overlay.sp-drawer-open {
  opacity: 1;
  visibility: visible;
}

.sp-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 82%;
  max-width: 320px;
  background: var(--sp-surface);
  z-index: calc(var(--sp-z-drawer) + 1);
  padding: var(--sp-space-6);
  overflow-y: auto;
  transform: translateX(-100%);
  transition: transform var(--sp-transition-normal);
  box-shadow: var(--sp-shadow-lg);
}

.sp-drawer-overlay.sp-drawer-open .sp-drawer {
  transform: translateX(0);
}

.sp-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-space-6);
  padding-bottom: var(--sp-space-4);
  border-bottom: 1px solid var(--sp-border);
}

.sp-drawer-menu li {
  margin-bottom: var(--sp-space-3);
}

.sp-drawer-menu a {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--sp-secondary);
  padding: 6px 0;
}

/* ==========================================================================
   17. BACK TO TOP BUTTON
   ========================================================================== */
.sp-back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sp-primary);
  color: #ffffff;
  border: none;
  box-shadow: var(--sp-shadow-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--sp-z-sticky);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--sp-transition-normal);
}

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

.sp-back-to-top:hover {
  background: var(--sp-primary-hover);
  transform: translateY(-2px);
}
