/*
Theme Name: Omics Portal Pro
Theme URI: https://omics.co.in/
Author: Omics India
Author URI: https://omics.co.in/
Description: Modern, high-performance bioinformatics and omics research portal. Features responsive design, dark/light theme support, interactive sequence tools, NGS comparison matrices, and structured educational tracks.
Version: 2.5.0
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 7.4
Text Domain: omics-portal
*/

:root {
  --bg-primary: #0b0f19;
  --bg-secondary: #111827;
  --bg-surface: #172136;
  --bg-card: rgba(23, 33, 54, 0.7);
  --bg-card-hover: rgba(30, 42, 69, 0.9);
  --bg-glass: rgba(11, 15, 25, 0.85);
  --bg-code: #0a0e17;

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-accent: #38bdf8;

  --border-subtle: #1e293b;
  --border-card: rgba(56, 189, 248, 0.15);
  --border-hover: rgba(56, 189, 248, 0.4);

  --accent-cyan: #06b6d4;
  --accent-teal: #14b8a6;
  --accent-emerald: #10b981;
  --accent-indigo: #6366f1;
  --accent-violet: #8b5cf6;
  --accent-blue: #38bdf8;
  --accent-amber: #f59e0b;

  --gradient-brand: linear-gradient(135deg, #06b6d4 0%, #3b82f6 50%, #8b5cf6 100%);
  --gradient-glow: radial-gradient(circle at 50% 0%, rgba(6, 182, 212, 0.18) 0%, transparent 70%);

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;

  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Menlo, Monaco, Consolas, monospace;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(6, 182, 212, 0.25);

  --header-height: 72px;
  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --bg-surface: #ffffff;
  --bg-card: rgba(255, 255, 255, 0.9);
  --bg-card-hover: #ffffff;
  --bg-glass: rgba(248, 250, 252, 0.88);
  --bg-code: #1e293b;

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --text-accent: #0284c7;

  --border-subtle: #e2e8f0;
  --border-card: #e2e8f0;
  --border-hover: rgba(2, 132, 199, 0.35);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 25px rgba(2, 132, 199, 0.15);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  scroll-behavior: smooth;
  color-scheme: dark;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

[data-theme="light"] {
  color-scheme: light;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-size: 16px;
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  position: relative;
  transition: background-color 0.3s ease, color 0.3s ease;
  -webkit-font-smoothing: antialiased;
}

.site-main {
  width: 100%;
  max-width: 100%;
  overflow-x: clip;
}

section, .section {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: var(--transition);
}

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

img, svg, canvas, video {
  max-width: 100%;
  height: auto;
  display: block;
}

pre, code {
  max-width: 100%;
  word-break: break-word;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
  box-sizing: border-box;
}

.container-narrow {
  max-width: 860px;
}

/* Header & Navbar */
/* Header & Navbar */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: linear-gradient(90deg, rgba(0, 245, 120, 0.08) 0%, rgba(6, 182, 212, 0.04) 48%, rgba(56, 189, 248, 0.09) 100%), var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  height: var(--header-height);
  transition: var(--transition);
  overflow: visible;
}

/* Semi-transparent backdrop overlay between background stream and foreground text */
.site-header::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 15, 29, 0.72);
  pointer-events: none;
  z-index: 1;
}

[data-theme="light"] .site-header::after {
  background: rgba(248, 250, 252, 0.85);
}

.site-header .container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  position: relative;
  z-index: 10;
}

/* Ambient Bioinformatics Sequence Stream: DNA to Binary Processing */
.header-dna-binary-stream {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  user-select: none;
  z-index: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  padding: 3px 0;
  opacity: 0.11;
  font-family: 'JetBrains Mono', 'Fira Code', 'SFMono-Regular', Consolas, monospace;
  font-size: 0.70rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1.2;
}

.stream-row {
  width: 100%;
  overflow: hidden;
  white-space: nowrap;
  display: flex;
}

.stream-track {
  display: inline-flex;
  align-items: center;
  gap: 32px;
  white-space: nowrap;
  animation: streamFlowLeft 50s linear infinite;
  will-change: transform;
}

.stream-track-reverse {
  animation: streamFlowRight 56s linear infinite;
}

@keyframes streamFlowLeft {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes streamFlowRight {
  0% { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

.stream-chunk {
  display: inline-flex;
  align-items: center;
  gap: 20px;
}

.stream-dna {
  color: #a7f3d0;
  text-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}

.stream-dna .base-a { color: #00f578; font-weight: 700; text-shadow: 0 0 6px rgba(0, 245, 120, 0.6); }
.stream-dna .base-t { color: #ff2d5a; font-weight: 700; text-shadow: 0 0 6px rgba(255, 45, 90, 0.6); }
.stream-dna .base-g { color: #ffb900; font-weight: 700; text-shadow: 0 0 6px rgba(255, 185, 0, 0.6); }
.stream-dna .base-c { color: #00e1ff; font-weight: 700; text-shadow: 0 0 6px rgba(0, 225, 255, 0.6); }

.stream-transition {
  color: #94a3b8;
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  opacity: 0.9;
  background: linear-gradient(90deg, #10b981, #06b6d4, #8b5cf6, #38bdf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stream-binary {
  color: #38bdf8;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-shadow: 0 0 10px rgba(56, 189, 248, 0.5);
}

.stream-row .tag-label {
  font-size: 0.60rem;
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  vertical-align: middle;
  letter-spacing: 0.05em;
  margin-right: 4px;
}

[data-theme="light"] .header-dna-binary-stream {
  opacity: 0.10;
}

[data-theme="light"] .stream-dna {
  color: #065f46;
  text-shadow: none;
}
[data-theme="light"] .stream-dna .base-a { color: #047857; text-shadow: none; }
[data-theme="light"] .stream-dna .base-t { color: #be123c; text-shadow: none; }
[data-theme="light"] .stream-dna .base-g { color: #b45309; text-shadow: none; }
[data-theme="light"] .stream-dna .base-c { color: #0369a1; text-shadow: none; }
[data-theme="light"] .stream-binary {
  color: #1d4ed8;
  text-shadow: none;
}
[data-theme="light"] .stream-transition {
  background: linear-gradient(90deg, #059669, #0284c7, #7c3aed, #2563eb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
[data-theme="light"] .stream-row .tag-label {
  background: rgba(15, 23, 42, 0.08);
  color: #475569;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-logo-container {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  line-height: 0;
}

.brand-logo-img {
  height: 38px !important;
  width: 38px !important;
  object-fit: contain;
  border-radius: var(--radius-full);
  filter: drop-shadow(0 0 6px rgba(0, 245, 120, 0.45)) drop-shadow(0 0 12px rgba(0, 225, 255, 0.4));
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), filter 0.35s ease;
  flex-shrink: 0;
  display: inline-block !important;
  opacity: 1 !important;
  visibility: visible !important;
}

.brand-wrapper:hover .brand-logo-img {
  transform: rotate(18deg) scale(1.08);
  filter: drop-shadow(0 0 10px rgba(0, 245, 120, 0.75)) drop-shadow(0 0 18px rgba(0, 225, 255, 0.65));
}

/* Green Beating Dot in Center of "O" Logo */
.brand-logo-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: radial-gradient(circle, #00f578 35%, #059669 100%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 2;
  box-shadow: 0 0 6px #00f578, 0 0 12px rgba(0, 245, 120, 0.75);
  animation: logoDotHeartbeat 1.6s cubic-bezier(0.25, 0.1, 0.25, 1) infinite;
}

.brand-logo-dot::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(0, 245, 120, 0.55);
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: logoDotRipple 1.6s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

.brand-wrapper:hover .brand-logo-dot {
  box-shadow: 0 0 10px #00f578, 0 0 20px rgba(0, 245, 120, 0.95);
}

@keyframes logoDotHeartbeat {
  0% {
    transform: translate(-50%, -50%) scale(0.9);
    box-shadow: 0 0 5px #00f578, 0 0 10px rgba(0, 245, 120, 0.5);
  }
  14% {
    transform: translate(-50%, -50%) scale(1.35);
    box-shadow: 0 0 10px #00f578, 0 0 18px rgba(0, 245, 120, 0.9);
  }
  28% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 0 6px #00f578, 0 0 10px rgba(0, 245, 120, 0.6);
  }
  42% {
    transform: translate(-50%, -50%) scale(1.22);
    box-shadow: 0 0 8px #00f578, 0 0 14px rgba(0, 245, 120, 0.8);
  }
  56% {
    transform: translate(-50%, -50%) scale(0.9);
    box-shadow: 0 0 5px #00f578, 0 0 10px rgba(0, 245, 120, 0.5);
  }
  100% {
    transform: translate(-50%, -50%) scale(0.9);
    box-shadow: 0 0 5px #00f578, 0 0 10px rgba(0, 245, 120, 0.5);
  }
}

@keyframes logoDotRipple {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.8;
  }
  14% {
    transform: translate(-50%, -50%) scale(1.7);
    opacity: 0.45;
  }
  28% {
    transform: translate(-50%, -50%) scale(2.2);
    opacity: 0;
  }
  42% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 0.4;
  }
  56% {
    transform: translate(-50%, -50%) scale(1.9);
    opacity: 0;
  }
  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0;
  }
}

@media (max-width: 640px) {
  .brand-logo-dot {
    width: 6px;
    height: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .brand-logo-dot,
  .brand-logo-dot::after {
    animation: none !important;
    opacity: 0.95;
  }
}

.footer-brand .brand-logo-img {
  height: 44px;
  width: 44px;
}

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.brand-tag {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(6, 182, 212, 0.15);
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 100%;
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.86rem;
  padding: 6px 9px;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.nav-link svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

.nav-item-has-dropdown {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.nav-item-has-dropdown:hover .nav-link svg,
.nav-item-has-dropdown:focus-within .nav-link svg,
.nav-item-has-dropdown.is-open .nav-link svg {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 280px;
  background: rgba(15, 23, 42, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.08);
  padding: 12px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.2s;
  z-index: 1050;
}

/* Invisible hover bridge to prevent flicker when moving cursor from tab to menu */
.dropdown-menu::before {
  content: '';
  position: absolute;
  top: -14px;
  left: 0;
  right: 0;
  height: 14px;
}

.nav-item-has-dropdown:hover .dropdown-menu,
.nav-item-has-dropdown:focus-within .dropdown-menu,
.nav-item-has-dropdown.is-open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

/* Light Mode Dropdown styling */
[data-theme="light"] .dropdown-menu {
  background: rgba(255, 255, 255, 0.98);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.12), 0 0 0 1px rgba(0, 0, 0, 0.05);
}

/* Right-align dropdown for tabs located on the right side of nav */
.dropdown-menu.nav-dropdown-right {
  left: auto !important;
  right: 0 !important;
}

/* Responsive grid for wide dropdowns */
.dropdown-menu.dropdown-menu-wide {
  max-width: calc(100vw - 32px);
}

.dropdown-item {
  display: block;
  padding: 8px 12px;
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
  text-decoration: none;
}

.dropdown-item:hover,
.dropdown-item:focus {
  color: var(--text-primary);
  background: rgba(56, 189, 248, 0.12) !important;
  transform: translateX(4px);
}

[data-theme="light"] .dropdown-item {
  color: #334155;
}

[data-theme="light"] .dropdown-item:hover,
[data-theme="light"] .dropdown-item:focus {
  color: #0f172a;
  background: rgba(6, 182, 212, 0.1) !important;
}

.dropdown-item-desc {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: block;
  font-weight: 400;
  margin-top: 2px;
  line-height: 1.35;
}

[data-theme="light"] .dropdown-item-desc {
  color: #64748b;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-search-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-family: inherit;
  padding: 7px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
}

.btn-search-trigger:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.kbd-shortcut {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--border-subtle);
}

.theme-toggle-btn {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.theme-toggle-btn:hover {
  color: var(--text-primary);
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.1);
}

.menu-toggle-mobile {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 6px;
}

/* Hero Section */
.hero-section {
  position: relative;
  padding: 90px 0 60px;
  overflow: hidden;
  background: var(--gradient-glow);
}

.hero-section .container {
  position: relative;
  z-index: 10;
}

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

.hero-card-col {
  position: relative;
  z-index: 10;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 48px;
  position: relative;
  z-index: 10;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(6, 182, 212, 0.12);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: var(--accent-cyan);
  margin-bottom: 24px;
}

.hero-badge .pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulseAnimation 2s infinite;
}

@keyframes pulseAnimation {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

.hero-title {
  font-size: clamp(2.2rem, 3.8vw, 3.1rem);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -0.025em;
  margin-bottom: 20px;
}

.hero-title .gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-lead {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
  max-width: 600px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 12px 26px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--gradient-brand);
  color: #ffffff;
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(6, 182, 212, 0.4);
  color: #ffffff;
}

.btn-secondary {
  background: var(--bg-surface);
  border-color: var(--border-subtle);
  color: var(--text-primary);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
}

.stat-item h3 {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 6px;
}

.stat-item p {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Hero Interactive Card / DNA Visualizer */
.hero-card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(12px);
  position: relative;
}

.hero-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.hero-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
}

.live-badge {
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
  font-weight: 600;
}

.hero-quick-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 10px !important;
}

.hero-quick-grid .result-stat-box {
  padding: 10px 8px;
  text-align: center;
}

.hero-quick-grid .result-stat-val {
  font-size: 1.1rem;
}

.hero-quick-grid .result-stat-lbl {
  font-size: 0.72rem;
}

/* Section Common */
.section {
  padding: 80px 0;
  position: relative;
}

.section-alt {
  background-color: var(--bg-secondary);
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 56px;
}

.section-header-full {
  max-width: 100% !important;
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.section-header-full .section-title,
.section-header-full .section-desc,
.section-header-full .section-subtitle {
  max-width: 100% !important;
  width: 100% !important;
}

.section-subtitle {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-cyan);
  display: block;
  margin-bottom: 12px;
}

.section-title {
  font-size: 2.35rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
}

/* Feature Grid Cards */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 24px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 28px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-md);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 20px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.2);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.card-desc {
  color: var(--text-secondary);
  font-size: 0.94rem;
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

.card-link:hover {
  gap: 10px;
}

/* Sequencing Tech Comparison Matrix */
.table-responsive {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  box-shadow: var(--shadow-md);
}

.omics-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.92rem;
}

.omics-table th {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  font-weight: 700;
  padding: 16px 20px;
  border-bottom: 2px solid var(--border-subtle);
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.omics-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.omics-table tbody tr:hover {
  background: rgba(56, 189, 248, 0.04);
}

.tech-cell {
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

/* In-Browser Interactive Bio-Tools Suite */
.tool-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 100%;
}

.tool-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 12px;
  overflow-x: auto;
  max-width: 100%;
  width: 100%;
  -webkit-overflow-scrolling: touch;
}

.tool-tab-btn {
  background: transparent;
  border: none;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}

.tool-tab-btn.active, .tool-tab-btn:hover {
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.1);
}

.tool-panel {
  display: none;
}

.tool-panel.active {
  display: block;
}

.input-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  display: block;
  margin-bottom: 8px;
}

.code-textarea {
  width: 100%;
  min-height: 120px;
  background: var(--bg-code);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--accent-cyan);
  resize: vertical;
  margin-bottom: 16px;
}

.code-textarea:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 2px rgba(6, 182, 212, 0.2);
}

.tool-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.tool-results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.result-stat-box {
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 18px;
}

.result-stat-val {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--accent-cyan);
  font-family: var(--font-mono);
}

.result-stat-lbl {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Learning Tracks & Pathways */
.track-card {
  display: flex;
  gap: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: var(--transition);
}

.track-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  background: var(--bg-card-hover);
}

.track-step-num {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gradient-brand);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* Code & Pre Blocks */
pre, code {
  font-family: var(--font-mono);
}

pre {
  background: var(--bg-code);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
  overflow-x: auto;
  font-size: 0.9rem;
  color: #e2e8f0;
  position: relative;
  margin: 20px 0;
}

code {
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.88em;
  color: var(--accent-cyan);
}

pre code {
  background: transparent;
  padding: 0;
  color: inherit;
}

.code-actions-toolbar {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 5;
}

.btn-copy-code,
.btn-download-code {
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-sans);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-copy-code:hover,
.btn-download-code:hover {
  color: var(--text-primary);
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.15);
}

/* Single Page & Article Layout */
.page-layout-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 48px;
  padding: 40px 0 80px;
}

.page-sidebar {
  position: sticky;
  top: calc(var(--header-height) + 24px);
  height: fit-content;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-box {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.sidebar-title {
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-subtle);
}

.toc-list, .related-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toc-item a, .related-nav-list a {
  font-size: 0.88rem;
  color: var(--text-secondary);
  display: block;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.toc-item a:hover, .toc-item.active a, .related-nav-list a:hover {
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.08);
}

.article-content {
  min-width: 0;
}

.article-header {
  margin-bottom: 32px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-subtle);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

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

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

.article-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.entry-body {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.entry-body h2 {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 48px 0 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-subtle);
}

.entry-body h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 36px 0 16px;
}

.entry-body p {
  margin-bottom: 20px;
}

.entry-body ul, .entry-body ol {
  margin: 20px 0 24px 24px;
}

.entry-body li {
  margin-bottom: 8px;
}

.entry-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}

.entry-body th, .entry-body td {
  padding: 14px 16px;
  border: 1px solid var(--border-subtle);
}

.entry-body th {
  background: rgba(255, 255, 255, 0.04);
  font-weight: 700;
  color: var(--text-primary);
}

/* Callout Box */
.callout {
  background: rgba(6, 182, 212, 0.08);
  border-left: 4px solid var(--accent-cyan);
  padding: 20px 24px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 28px 0;
  color: var(--text-primary);
}

.callout-title {
  font-weight: 700;
  color: var(--accent-cyan);
  margin-bottom: 8px;
}

/* Search Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 100px 20px 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

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

.search-modal-content {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 640px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  transform: translateY(-20px);
  transition: var(--transition);
}

.modal-overlay.active .search-modal-content {
  transform: translateY(0);
}

.search-input-wrapper {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
  gap: 12px;
}

.search-modal-input {
  width: 100%;
  background: transparent;
  border: none;
  font-family: inherit;
  font-size: 1.15rem;
  color: var(--text-primary);
  outline: none;
}

.search-results-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 12px;
}

.search-result-item {
  display: block;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  transition: var(--transition);
}

.search-result-item:hover {
  background: rgba(56, 189, 248, 0.1);
}

.search-result-item h4 {
  font-size: 0.98rem;
  margin-bottom: 4px;
}

.search-result-item p {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Footer */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  padding: 80px 0 32px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 48px;
  margin-bottom: 60px;
}

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin: 16px 0 24px;
  max-width: 320px;
}

.footer-col h4 {
  font-size: 0.92rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--accent-cyan);
  padding-left: 4px;
}

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.88rem;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: 16px;
}

.btn-scroll-top-footer {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 7px 14px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  line-height: 1;
}

.btn-scroll-top-footer svg {
  flex-shrink: 0;
  color: var(--accent-cyan);
  transition: transform 0.2s ease;
}

.btn-scroll-top-footer:hover {
  background: rgba(6, 182, 212, 0.12);
  border-color: rgba(6, 182, 212, 0.4);
  color: var(--accent-cyan);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.18);
}

.btn-scroll-top-footer:hover svg {
  transform: translateY(-2px);
}

[data-theme="light"] .btn-scroll-top-footer {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #334155;
}

[data-theme="light"] .btn-scroll-top-footer:hover {
  background: rgba(6, 182, 212, 0.12);
  border-color: #0891b2;
  color: #0891b2;
}

/* ==========================================================================
   SOCIAL MEDIA SHARE COMPONENT
   ========================================================================== */
.social-share-container {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 12px 14px !important;
  margin: 24px 0 !important;
  padding: 14px 18px !important;
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.social-share-label {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  font-size: 0.86rem !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  color: var(--accent-amber) !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  margin: 0 !important;
}

.social-share-buttons {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  flex-wrap: wrap !important;
  gap: 8px 10px !important;
  margin: 0 !important;
}

.social-share-btn {
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  padding: 7px 14px !important;
  border-radius: var(--radius-full) !important;
  font-size: 0.84rem !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  border: 1px solid var(--border-subtle) !important;
  background: var(--bg-surface) !important;
  color: var(--text-primary) !important;
  min-height: 38px !important;
  line-height: 1 !important;
  flex: 0 0 auto !important;
  width: auto !important;
  white-space: nowrap !important;
  user-select: none !important;
}

.social-share-btn svg {
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.social-share-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.social-share-btn:hover svg {
  transform: scale(1.1);
}

/* Platform specific branding */
.social-share-btn.btn-share-native {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.15) 0%, rgba(139, 92, 246, 0.15) 100%);
  border-color: rgba(6, 182, 212, 0.4);
  color: var(--accent-cyan);
}
.social-share-btn.btn-share-native:hover {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.25) 0%, rgba(139, 92, 246, 0.25) 100%);
  border-color: var(--accent-cyan);
}

.social-share-btn.btn-share-x:hover {
  background: #000000;
  color: #ffffff;
  border-color: #333333;
}
[data-theme="light"] .social-share-btn.btn-share-x:hover {
  background: #111827;
  color: #ffffff;
}

.social-share-btn.btn-share-linkedin:hover {
  background: #0a66c2;
  color: #ffffff;
  border-color: #0a66c2;
}

.social-share-btn.btn-share-whatsapp:hover {
  background: #25d366;
  color: #ffffff;
  border-color: #25d366;
}

.social-share-btn.btn-share-reddit:hover {
  background: #ff4500;
  color: #ffffff;
  border-color: #ff4500;
}

.social-share-btn.btn-share-facebook:hover {
  background: #1877f2;
  color: #ffffff;
  border-color: #1877f2;
}

.social-share-btn.btn-share-copy:hover {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
  border-color: rgba(16, 185, 129, 0.4);
}

/* Tool Input Row Grid */
.tool-input-row-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

/* Prevent horizontal body overflow across all viewports */
html, body {
  max-width: 100vw;
  overflow-x: hidden;
}

/* ==========================================================================
   TABLET & MOBILE RESPONSIVE SYSTEM
   ========================================================================== */

/* Tablet (iPad Pro, Landscape & Portrait <= 1140px) */
@media (max-width: 1140px) {
  .nav-desktop {
    display: none !important;
  }
  .menu-toggle-mobile {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
  }
  .header-dna-binary-stream,
  .site-header::after {
    display: none !important;
  }
  .site-header {
    background: var(--bg-glass) !important;
  }
  .site-header .container {
    padding: 0 20px;
    position: relative !important;
    z-index: 10 !important;
  }
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .hero-title {
    font-size: clamp(2.35rem, 5vw, 2.9rem);
  }
  .page-layout-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .page-sidebar {
    position: static;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
  }
  .tool-box {
    padding: 24px 20px;
  }
  .tool-input-row-grid {
    grid-template-columns: 1fr 1fr;
  }
  .tool-input-row-grid > div:first-child {
    grid-column: 1 / -1;
  }
}

/* Mobile & Small Tablets (<= 768px) */
@media (max-width: 768px) {
  .site-header {
    height: 64px !important;
    min-height: 64px !important;
    padding: 0 !important;
  }
  .site-header .container {
    height: 100% !important;
    padding: 0 16px !important;
    gap: 12px !important;
    position: relative !important;
    z-index: 10 !important;
  }
  .brand-wrapper {
    gap: 10px;
    min-width: 0;
    flex-shrink: 1;
  }
  .brand-logo-img {
    width: 36px !important;
    height: 36px !important;
    flex-shrink: 0;
  }
  .brand-title {
    font-size: 1.25rem !important;
    white-space: nowrap;
  }
  .header-actions {
    gap: 8px !important;
    flex-shrink: 0;
  }
  .btn-search-trigger {
    width: 38px !important;
    height: 38px !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: var(--radius-full) !important;
  }
  .btn-search-trigger span:not(svg),
  .btn-search-trigger .kbd-shortcut {
    display: none !important;
  }
  .theme-toggle-btn {
    width: 38px !important;
    height: 38px !important;
    flex-shrink: 0;
  }
  .menu-toggle-mobile {
    width: 38px !important;
    height: 38px !important;
    padding: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-subtle);
    color: var(--text-primary);
    cursor: pointer;
    flex-shrink: 0;
  }
  .menu-toggle-mobile:hover,
  .menu-toggle-mobile:active {
    background: rgba(6, 182, 212, 0.15);
    border-color: var(--accent-cyan);
    color: var(--accent-cyan);
  }
  .header-dna-binary-stream,
  .site-header::after {
    display: none !important;
  }
  .hero-section {
    padding: 48px 0 36px;
  }
  .hero-title {
    font-size: clamp(1.9rem, 7vw, 2.35rem);
    line-height: 1.15;
  }
  .hero-lead {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 24px;
  }
  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding-top: 20px;
  }
  .stat-item h3 {
    font-size: 1.5rem;
  }
  .stat-item p {
    font-size: 0.75rem;
  }
  .section {
    padding: 56px 0;
  }
  .section-title {
    font-size: 1.75rem;
  }
  .section-desc {
    font-size: 0.92rem;
    margin-bottom: 32px;
  }
  .cards-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .card {
    padding: 22px 18px;
  }
  .nobel-spotlight-box {
    padding: 24px 18px !important;
  }
  .tool-box {
    padding: 18px 14px;
    border-radius: var(--radius-md);
  }
  .tool-tabs {
    gap: 6px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .tool-tabs::-webkit-scrollbar {
    display: none;
  }
  .tool-tab-btn {
    font-size: 0.84rem;
    padding: 7px 12px;
    border-radius: var(--radius-sm);
    flex-shrink: 0;
    white-space: nowrap;
  }
  .tool-input-row-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .tool-results-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .result-stat-box {
    padding: 12px 10px;
  }
  .result-stat-val {
    font-size: 1.15rem;
  }
  .result-stat-lbl {
    font-size: 0.72rem;
  }
  .social-share-container {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    padding: 12px 14px !important;
  }
  .social-share-buttons {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
  }
  .social-share-btn {
    flex: 0 0 auto !important;
    width: auto !important;
    font-size: 0.8rem !important;
    padding: 6px 12px !important;
    min-height: 34px !important;
    white-space: nowrap !important;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
}

/* Small Smart Phones (<= 480px) */
@media (max-width: 480px) {
  .container {
    padding: 0 14px;
  }
  .site-header {
    height: 58px !important;
    min-height: 58px !important;
    padding: 0 !important;
  }
  .site-header .container {
    padding: 0 12px !important;
    gap: 8px !important;
    position: relative !important;
    z-index: 10 !important;
  }
  .brand-wrapper {
    gap: 8px !important;
  }
  .brand-logo-img {
    width: 32px !important;
    height: 32px !important;
  }
  .brand-title {
    font-size: 1.15rem !important;
  }
  .header-actions {
    gap: 8px !important;
  }
  .btn-search-trigger,
  .theme-toggle-btn,
  .menu-toggle-mobile {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    min-height: 38px !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
  }
  .btn-search-trigger *,
  .theme-toggle-btn *,
  .menu-toggle-mobile * {
    pointer-events: none !important;
  }
  .menu-toggle-mobile svg {
    width: 20px;
    height: 20px;
  }
  .theme-toggle-btn svg {
    width: 18px;
    height: 18px;
  }
  .btn-search-trigger svg {
    width: 16px;
    height: 16px;
  }
  .hero-buttons {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 32px;
  }
  .hero-buttons .btn {
    width: 100%;
    min-height: 48px;
  }
  .hero-card {
    padding: 18px 14px;
  }
  .tool-box {
    padding: 16px 12px;
  }
  .social-share-container {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 10px 12px !important;
    padding: 12px !important;
  }
  .social-share-buttons {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    width: auto !important;
  }
  .social-share-btn {
    display: inline-flex !important;
    flex: 0 0 auto !important;
    width: auto !important;
    white-space: nowrap !important;
    font-size: 0.8rem !important;
    padding: 6px 12px !important;
    min-height: 34px !important;
  }
  .breadcrumbs {
    font-size: 0.78rem;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
  }
  .code-textarea {
    font-size: 0.82rem;
    padding: 10px;
  }
  .tool-results-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .hero-quick-grid {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 6px !important;
  }
  .hero-quick-grid .result-stat-box {
    padding: 8px 4px !important;
    text-align: center;
  }
  .hero-quick-grid .result-stat-val {
    font-size: 0.95rem !important;
  }
  .hero-quick-grid .result-stat-lbl {
    font-size: 0.65rem !important;
  }
}

/* Compact Mobile (<= 360px) */
@media (max-width: 360px) {
  .site-header .container {
    padding: 0 8px !important;
    gap: 5px !important;
    position: relative !important;
    z-index: 10 !important;
  }
  .brand-title {
    font-size: 1.02rem !important;
  }
  .header-actions {
    gap: 6px !important;
  }
  .btn-search-trigger,
  .theme-toggle-btn,
  .menu-toggle-mobile {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
  }
  .brand-logo-img {
    width: 28px !important;
    height: 28px !important;
  }
  .hero-quick-grid {
    grid-template-columns: 1fr !important;
    gap: 6px !important;
  }
  .tool-results-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }
}

/* Mobile Drawer Styles */
.mobile-drawer {
  position: fixed;
  top: 0;
  left: 0;
  width: min(340px, 86vw);
  max-width: 340px;
  height: 100vh;
  height: 100dvh;
  background: var(--bg-surface);
  border-right: 1px solid var(--border-subtle);
  z-index: 2000;
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

.mobile-drawer.active {
  transform: translateX(0);
}

.mobile-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-drawer-overlay.active {
  opacity: 1;
  visibility: visible;
}

body.mobile-drawer-open {
  overflow: hidden !important;
  touch-action: none;
}

.mobile-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
  flex-shrink: 0;
}

.mobile-drawer-close {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  transition: var(--transition);
}

.mobile-drawer-close:hover {
  background: rgba(244, 63, 94, 0.15);
  border-color: #f43f5e;
  color: #f43f5e;
}

.mobile-drawer-body {
  padding: 16px 20px 30px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex: 1;
}

.mobile-search-box {
  margin-bottom: 20px;
}

.mobile-search-input {
  width: 100%;
  background: var(--bg-code);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 0.9rem;
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
}

.mobile-search-input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.25);
}

.mobile-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 0;
  margin: 0;
}

.mobile-nav-list a {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
  text-decoration: none;
}

.mobile-nav-list a:hover,
.mobile-nav-list a:active {
  color: var(--text-primary);
  background: rgba(56, 189, 248, 0.12);
  padding-left: 16px;
}

/* Mobile Navigation Accordion Dropdowns */
.mobile-nav-home-item {
  margin-bottom: 4px;
  list-style: none;
}

.mobile-home-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  color: #f8fafc;
  text-decoration: none;
  transition: all 0.2s ease;
}

.mobile-home-link:hover,
.mobile-home-link:active {
  background: rgba(6, 182, 212, 0.12);
  border-color: rgba(6, 182, 212, 0.3);
}

.mobile-home-icon {
  font-size: 1.1rem;
  line-height: 1;
}

.mobile-home-text {
  font-size: 0.95rem;
  font-weight: 700;
  flex: 1;
  color: #f8fafc;
}

.mobile-home-pill {
  font-size: 0.70rem;
  font-weight: 600;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  color: #94a3b8;
}

.mobile-accordion-group {
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.07);
  overflow: hidden;
  list-style: none;
  margin-bottom: 8px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.mobile-accordion-group.is-open {
  background: rgba(15, 23, 42, 0.6);
  border-color: rgba(6, 182, 212, 0.3);
}

.mobile-accordion-toggle {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: transparent;
  border: none;
  outline: none;
  box-shadow: none;
  cursor: pointer;
  border-radius: 9px;
  transition: background 0.2s ease;
  font-family: inherit;
  text-align: left;
  color: #f1f5f9;
}

.mobile-accordion-toggle * {
  pointer-events: none !important;
}

.mobile-accordion-toggle:hover,
.mobile-accordion-toggle:active {
  background: rgba(255, 255, 255, 0.04);
}

.mobile-acc-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.mobile-acc-icon {
  font-size: 1.15rem;
  line-height: 1;
  flex-shrink: 0;
}

.mobile-acc-text {
  font-size: 0.92rem;
  font-weight: 700;
  color: #f8fafc;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mobile-acc-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
  border: 1px solid rgba(6, 182, 212, 0.3);
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.mobile-acc-chevron {
  color: #64748b;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), color 0.2s;
  flex-shrink: 0;
  margin-left: 8px;
}

.mobile-accordion-group.is-open .mobile-acc-chevron {
  transform: rotate(180deg);
  color: #22d3ee;
}

.mobile-accordion-group.is-open .mobile-acc-text {
  color: #22d3ee;
}

.mobile-accordion-panel {
  display: none;
  padding: 4px 8px 12px 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.mobile-accordion-group.is-open .mobile-accordion-panel {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-sublink {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: transparent;
  text-decoration: none;
  color: #cbd5e1;
  transition: background 0.18s ease, transform 0.18s ease;
}

.mobile-sublink:hover,
.mobile-sublink:active {
  background: rgba(56, 189, 248, 0.12);
  color: #ffffff;
  transform: translateX(3px);
}

.mobile-sublink-icon {
  font-size: 1rem;
  line-height: 1.3;
  flex-shrink: 0;
}

.mobile-sublink-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 2px;
}

.mobile-sublink-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #e2e8f0;
  line-height: 1.3;
}

.mobile-sublink-sub {
  font-size: 0.72rem;
  color: #94a3b8;
  font-weight: 400;
  line-height: 1.25;
}

.mobile-sublink-highlight {
  margin-top: 4px;
  background: rgba(6, 182, 212, 0.08);
  border: 1px dashed rgba(6, 182, 212, 0.35);
}

/* Light Mode Mobile Drawer Styles */
[data-theme="light"] .mobile-drawer {
  background: #ffffff !important;
  border-right: 1px solid rgba(0, 0, 0, 0.08) !important;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.16) !important;
}

[data-theme="light"] .mobile-drawer-header {
  background: #f8fafc !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .mobile-drawer-close,
[data-theme="light"] .drawer-theme-toggle {
  background: rgba(0, 0, 0, 0.05) !important;
  border: 1px solid rgba(0, 0, 0, 0.1) !important;
  color: #475569 !important;
}

[data-theme="light"] .mobile-drawer-close:hover,
[data-theme="light"] .mobile-drawer-close:active {
  background: rgba(239, 68, 68, 0.15) !important;
  color: #dc2626 !important;
  border-color: rgba(239, 68, 68, 0.3) !important;
}

[data-theme="light"] .mobile-drawer-body {
  background: #ffffff !important;
}

[data-theme="light"] .mobile-search-input {
  background: #f1f5f9 !important;
  border: 1px solid rgba(0, 0, 0, 0.12) !important;
  color: #0f172a !important;
}

[data-theme="light"] .mobile-search-input::placeholder {
  color: #94a3b8 !important;
}

[data-theme="light"] .mobile-home-link {
  background: #f8fafc !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  color: #0f172a !important;
}

[data-theme="light"] .mobile-home-link:hover,
[data-theme="light"] .mobile-home-link:active {
  background: rgba(6, 182, 212, 0.08) !important;
  border-color: rgba(6, 182, 212, 0.35) !important;
}

[data-theme="light"] .mobile-home-text {
  color: #0f172a !important;
}

[data-theme="light"] .mobile-home-pill {
  background: rgba(0, 0, 0, 0.06) !important;
  color: #64748b !important;
}

[data-theme="light"] .mobile-accordion-group {
  background: #f8fafc !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .mobile-accordion-group.is-open {
  background: #f8fafc !important;
  border-color: rgba(6, 182, 212, 0.45) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
}

[data-theme="light"] .mobile-accordion-toggle {
  color: #0f172a !important;
}

[data-theme="light"] .mobile-accordion-toggle:hover,
[data-theme="light"] .mobile-accordion-toggle:active {
  background: rgba(0, 0, 0, 0.03) !important;
}

[data-theme="light"] .mobile-acc-text {
  color: #0f172a !important;
}

[data-theme="light"] .mobile-accordion-group.is-open .mobile-acc-text {
  color: #0891b2 !important;
}

[data-theme="light"] .mobile-acc-badge {
  background: rgba(6, 182, 212, 0.12) !important;
  color: #0891b2 !important;
  border-color: rgba(6, 182, 212, 0.3) !important;
}

[data-theme="light"] .mobile-acc-chevron {
  color: #64748b !important;
}

[data-theme="light"] .mobile-accordion-group.is-open .mobile-acc-chevron {
  color: #0891b2 !important;
}

[data-theme="light"] .mobile-accordion-panel {
  border-top: 1px solid rgba(0, 0, 0, 0.06) !important;
  background: #ffffff !important;
}

[data-theme="light"] .mobile-sublink {
  color: #334155 !important;
  background: transparent !important;
}

[data-theme="light"] .mobile-sublink:hover,
[data-theme="light"] .mobile-sublink:active {
  background: rgba(6, 182, 212, 0.08) !important;
  color: #0f172a !important;
}

[data-theme="light"] .mobile-sublink-title {
  color: #0f172a !important;
}

[data-theme="light"] .mobile-sublink-sub {
  color: #64748b !important;
}

[data-theme="light"] .mobile-sublink-highlight {
  background: rgba(6, 182, 212, 0.08) !important;
  border-color: rgba(6, 182, 212, 0.45) !important;
}

[data-theme="light"] .mobile-drawer-overlay {
  background: rgba(15, 23, 42, 0.5) !important;
}


/* ==========================================================================
   REDESIGNED MODERN HEADER & FOOTER (v3.1)
   ========================================================================== */

/* Header Branding & Badges */
.brand-text-block {
  display: flex;
  align-items: center;
  gap: 8px;
}
.brand-badge {
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.28);
  white-space: nowrap;
}
.nav-badge-pill {
  font-size: 0.65rem;
  font-weight: 800;
  background: rgba(6, 182, 212, 0.18);
  color: var(--accent-cyan);
  padding: 1px 7px;
  border-radius: 9999px;
  border: 1px solid rgba(6, 182, 212, 0.35);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-left: 4px;
  display: inline-block;
  line-height: 1.3;
}

@media (max-width: 1180px) {
  .brand-badge {
    display: none;
  }
}

/* Footer Quick Ribbon (Pre-Footer Feature Strip) */
.footer-quick-ribbon {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--border-subtle);
}
.footer-ribbon-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}
.footer-ribbon-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3.5px;
  height: 100%;
  background: var(--card-accent, var(--accent-cyan));
  transition: width 0.2s ease;
}
.footer-ribbon-card:hover {
  transform: translateY(-3px);
  border-color: var(--card-accent, var(--accent-cyan));
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3), 0 0 15px rgba(6, 182, 212, 0.2);
}
.footer-ribbon-card:hover::before {
  width: 5px;
}
.footer-ribbon-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}
.footer-ribbon-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}
.footer-ribbon-cta {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--card-accent, var(--accent-cyan));
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap 0.2s ease;
}
.footer-ribbon-card:hover .footer-ribbon-cta {
  gap: 8px;
}

/* 5-Column Sitemap Grid */
.footer-grid-5 {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1.05fr 1.05fr;
  gap: 36px;
  margin-bottom: 54px;
}

.footer-col h4 {
  font-size: 0.88rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-primary);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.footer-col h4::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
  margin-left: 6px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 0;
  margin: 0;
}
.footer-links li {
  line-height: 1.4;
}
.footer-links a {
  color: var(--text-secondary);
  font-size: 0.88rem;
  transition: all 0.18s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.footer-links a:hover {
  color: var(--accent-cyan);
  transform: translateX(3px);
}

/* Footer Tag Pills */
.footer-tag {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.04);
  padding: 3px 10px;
  border-radius: 9999px;
  border: 1px solid var(--border-subtle);
  white-space: nowrap;
}
[data-theme="light"] .footer-tag {
  background: rgba(0, 0, 0, 0.03);
  color: var(--text-secondary);
}

@media (max-width: 1200px) {
  .footer-quick-ribbon {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid-5 {
    grid-template-columns: 1.3fr repeat(2, 1fr);
    gap: 32px;
  }
}

@media (max-width: 768px) {
  .footer-quick-ribbon {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 32px;
    padding-bottom: 24px;
  }
  .footer-grid-5 {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}


/* ==========================================================================
   PAGE SPACING COMPACTION & 2-LINE TOOL TABS (v3.1.0)
   ========================================================================== */

/* Remove excess top padding on hero and sections */
.hero-section {
  padding: 18px 0 32px !important;
}
.hero-badge {
  margin-bottom: 12px !important;
}
.section {
  padding: 36px 0 !important;
}
.breadcrumbs {
  margin-bottom: 10px !important;
}
.article-header {
  margin-bottom: 18px !important;
  padding-bottom: 14px !important;
}

/* 2-Line Tool Tabs: Wrap without horizontal scroll */
.tool-tabs {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px 10px !important;
  margin-bottom: 24px !important;
  border-bottom: 1px solid var(--border-subtle) !important;
  padding-bottom: 14px !important;
  overflow-x: visible !important;
  max-width: 100% !important;
  width: 100% !important;
}
.tool-tab-btn {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  font-family: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 7px 13px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
}
.tool-tab-btn:hover {
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.1);
  border-color: rgba(6, 182, 212, 0.3);
}
.tool-tab-btn.active {
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--accent-cyan);
  font-weight: 700;
}
[data-theme="light"] .tool-tab-btn {
  background: rgba(0, 0, 0, 0.03);
  color: #334155;
}
[data-theme="light"] .tool-tab-btn:hover {
  background: rgba(6, 182, 212, 0.1);
  color: var(--accent-cyan);
}
[data-theme="light"] .tool-tab-btn.active {
  background: rgba(6, 182, 212, 0.15);
  color: var(--accent-cyan);
  border-color: var(--accent-cyan);
}

/* ==========================================================================
   MOBILE USABILITY & VISUAL HIERARCHY ENHANCEMENTS (v3.2.0)
   Addresses mobile review: touch targets, chip rails, table cues, layout
   ========================================================================== */

/* 1. VISUAL HIERARCHY: LEARN VS DO STYLING */
.hero-btn-tools {
  background: linear-gradient(135deg, var(--accent-cyan), #0284c7) !important;
  color: #04111d !important;
  font-weight: 800 !important;
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.35) !important;
}
.hero-btn-tools:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.45) !important;
}
.hero-btn-tutorials {
  background: rgba(99, 102, 241, 0.12) !important;
  color: #818cf8 !important;
  border: 1px solid rgba(99, 102, 241, 0.35) !important;
  font-weight: 700 !important;
}
.hero-btn-tutorials:hover {
  background: rgba(99, 102, 241, 0.22) !important;
  border-color: #818cf8 !important;
  color: #a5b4fc !important;
}

/* Distinct Cards for "Doing" (Tools) vs "Learning" (Reference/Tutorials) */
.card-type-tool {
  border-color: rgba(6, 182, 212, 0.28) !important;
}
.card-type-tool:hover {
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 12px 30px -10px rgba(6, 182, 212, 0.25) !important;
}

.card-type-ref {
  border-color: rgba(16, 185, 129, 0.28) !important;
}
.card-type-ref:hover {
  border-color: var(--accent-emerald) !important;
  box-shadow: 0 12px 30px -10px rgba(16, 185, 129, 0.22) !important;
}

.card-type-catalog {
  border-color: rgba(139, 92, 246, 0.28) !important;
}
.card-type-catalog:hover {
  border-color: #a78bfa !important;
  box-shadow: 0 12px 30px -10px rgba(139, 92, 246, 0.22) !important;
}

/* 2. ACCESSIBLE TOUCH TARGETS & FOCUS RINGS */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent-cyan) !important;
  outline-offset: 2px !important;
}

/* Code Snippet Scroll Container Clearance */
pre, .code-block {
  position: relative;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch !important;
}
pre::-webkit-scrollbar, .code-block::-webkit-scrollbar {
  height: 6px;
}
pre::-webkit-scrollbar-thumb, .code-block::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}

/* 3. TABLE HORIZONTAL SCROLL HINT */
.mobile-table-scroll-hint {
  display: none;
}
@media (max-width: 768px) {
  .mobile-table-scroll-hint {
    display: inline-flex !important;
    align-items: center;
    gap: 4px;
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--accent-cyan);
    animation: hintPulse 2.5s infinite ease-in-out;
  }
}
@keyframes hintPulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

/* 4. MOBILE LAYOUT & TOUCH TARGET OVERRIDES (< 768px) */
@media (max-width: 768px) {
  /* Ensure Article & Page Sidebar Grid Collapses to 1 Column */
  .article-layout,
  .page-layout-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }
  .article-sidebar,
  .page-sidebar {
    position: static !important;
    width: 100% !important;
    margin-bottom: 20px !important;
  }

  /* Make Long Sidebar Disciplines Horizontally Scrollable on Mobile */
  .article-sidebar .sidebar-box:has(#sidebarDisciplinesNav) {
    position: sticky !important;
    top: 64px !important;
    z-index: 85 !important;
    background: var(--bg-card) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    padding: 10px 12px !important;
    margin-bottom: 12px !important;
    border-radius: var(--radius-sm) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4) !important;
  }
  .article-sidebar .sidebar-title {
    display: none !important;
  }
  #sidebarDisciplinesNav {
    display: flex !important;
    flex-direction: row !important;
    overflow-x: auto !important;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    gap: 8px !important;
    padding-bottom: 2px !important;
  }
  #sidebarDisciplinesNav::-webkit-scrollbar {
    display: none !important;
  }
  .sidebar-disc-btn {
    white-space: nowrap !important;
    flex-shrink: 0 !important;
    min-height: 44px !important;
    padding: 8px 14px !important;
    display: inline-flex !important;
    align-items: center !important;
  }
  .article-sidebar .sidebar-box:not(:has(#sidebarDisciplinesNav)) {
    display: none !important;
  }

  /* Minimum 44px Touch Targets for Interactive Elements */
  .btn,
  .tab-btn,
  .btn-filter-pill,
  .badge.hw-chip,
  .flag-preset-btn,
  .btn-copy-code,
  .btn-download-code,
  .theme-toggle-btn,
  .menu-toggle-mobile,
  .btn-search-trigger {
    min-height: 44px !important;
    min-width: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    touch-action: manipulation !important;
  }

  /* Horizontally Scrollable Chip Rails for Filter Bars */
  .filter-pills,
  #dirCategoryPills,
  #hwFilterChips,
  .tools-tabs-nav,
  .tool-tabs {
    display: flex !important;
    overflow-x: auto !important;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    padding-bottom: 6px !important;
    gap: 8px !important;
    margin-bottom: 16px !important;
    mask-image: linear-gradient(to right, black 90%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, black 90%, transparent 100%);
  }
  .filter-pills::-webkit-scrollbar,
  #dirCategoryPills::-webkit-scrollbar,
  #hwFilterChips::-webkit-scrollbar,
  .tools-tabs-nav::-webkit-scrollbar,
  .tool-tabs::-webkit-scrollbar {
    display: none !important;
  }
  .btn-filter-pill,
  #dirCategoryPills button,
  #hwFilterChips button,
  .tools-tabs-nav button,
  .tool-tabs .tool-tab-btn {
    white-space: nowrap !important;
    flex-shrink: 0 !important;
    min-height: 44px !important;
    padding: 0 16px !important;
    font-size: 0.85rem !important;
  }

  /* Sticky Tools Navigation Bar */
  .tools-sticky-bar {
    top: 58px !important;
    padding: 6px 0 !important;
  }

  /* NGS Coverage Calculator Mobile Single-Column Form */
  .ngs-calc-grid {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  /* Code Textareas & Inputs on Mobile */
  .code-textarea,
  input[type="text"],
  input[type="number"],
  select {
    font-size: 16px !important; /* Prevents iOS auto-zoom on focus */
    min-height: 44px !important;
  }
}

/* ==========================================================================
   v3.3.0 Interactive Pipeline Builder, Search Chips & Guided Tracks
   ========================================================================== */
.search-filter-chip {
  font-size: 0.74rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 9999px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
  user-select: none;
}

.search-filter-chip:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

.search-filter-chip.active {
  background: rgba(6, 182, 212, 0.16);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  font-weight: 700;
}

.search-res-item:hover {
  border-color: var(--accent-cyan) !important;
  background: rgba(6, 182, 212, 0.05) !important;
  transform: translateY(-1px);
}

/* Pipeline Builder Grid */
.pipeline-builder-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 28px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .pipeline-builder-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

.pipeline-config-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
}

.pipeline-preview-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Tech Comparison Tabs & Table */
.tech-comp-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 20px;
  padding-bottom: 4px;
}

.tech-comp-tab-btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.tech-comp-tab-btn.active {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

.tech-comp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.tech-comp-table th,
.tech-comp-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}

.tech-comp-table th {
  background: var(--bg-surface);
  font-weight: 800;
  color: var(--text-primary);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ==========================================================================
   PRINT / PDF EXPORT OPTIMIZATIONS
   Optimized for 1-2 page cheatsheet printing and clean electronic lab notebook records.
   ========================================================================== */
@media print {
  /* Hide non-printable web UI elements */
  .site-header,
  .site-footer,
  .modal-overlay,
  .mobile-drawer,
  .mobile-drawer-overlay,
  .theme-toggle-btn,
  .btn-search-trigger,
  .menu-toggle-mobile,
  .btn-copy-code,
  .btn-copy-cmd,
  .breadcrumbs,
  .tech-comp-tabs,
  .tool-tabs,
  .tool-controls,
  .primer-preset-btn,
  .revcomp-preset-btn,
  .gc-preset-btn,
  .trans-preset-btn,
  .prot-preset-btn,
  .primer-mode-toggle,
  #cheatsheetSearch,
  #btnSearchTrigger,
  button[onclick="window.print()"],
  .cookie-notice,
  .back-to-top {
    display: none !important;
  }

  /* Reset layout, margins, and paper background */
  @page {
    margin: 1.2cm;
    size: auto;
  }

  body,
  html,
  #primary,
  .site-main,
  .container {
    background: #ffffff !important;
    color: #111827 !important;
    font-size: 10pt !important;
    line-height: 1.4 !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  h1, h2, h3, h4 {
    color: #0f172a !important;
    page-break-after: avoid;
    break-after: avoid;
  }

  h1 {
    font-size: 16pt !important;
    margin-bottom: 6pt !important;
  }

  h2 {
    font-size: 13pt !important;
    margin-top: 12pt !important;
    margin-bottom: 4pt !important;
  }

  /* Prevent awkward card splitting across pages */
  .card,
  .cheatsheet-item,
  .tool-panel,
  .tech-comp-content,
  tr {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    box-shadow: none !important;
    margin-bottom: 8pt !important;
    padding: 8pt 10pt !important;
  }

  /* Code blocks in print */
  pre,
  code {
    background: #f8fafc !important;
    color: #0f172a !important;
    border: 1px solid #e2e8f0 !important;
    font-size: 8.5pt !important;
    white-space: pre-wrap !important;
    word-break: break-all !important;
  }

  /* Table styling in print */
  table,
  .omics-table,
  .tech-comp-table {
    border-collapse: collapse !important;
    width: 100% !important;
  }

  th,
  td {
    border: 1px solid #cbd5e1 !important;
    padding: 4pt 6pt !important;
    color: #0f172a !important;
    font-size: 8.5pt !important;
  }

  th {
    background: #f1f5f9 !important;
    font-weight: bold !important;
  }

  /* Links */
  a {
    color: #0f172a !important;
    text-decoration: underline !important;
  }

  /* Badges */
  .badge {
    border: 1px solid #94a3b8 !important;
    background: #f1f5f9 !important;
    color: #334155 !important;
    font-size: 7.5pt !important;
    padding: 1pt 4pt !important;
  }
}



