/*
Theme Name: Trading Paal
Theme URI: https://tradingpaal.com
Author: Taimoor Ahmed
Author URI: https://tradingpaal.com
Description: Premium financial tools and calculator hub. 75+ free calculators for stocks, taxes, loans, budgeting, and investing.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: tradingpaal
Tags: dark-mode, financial, calculators, custom-colors
*/

/* ── Webfonts ──────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

/* ── Design Tokens ─────────────────────────────────────── */
:root {
  /* Base palette */
  --navy-950: #0A0E1A;
  --navy-900: #0D1220;
  --navy-850: #111827;
  --navy-800: #161E2E;
  --navy-700: #1F2937;
  --blue-500: #3B82F6;
  --blue-400: #60A5FA;
  --blue-600: #2563EB;
  --purple-500: #8B5CF6;
  --purple-400: #A78BFA;
  --green-500: #10B981;
  --red-500: #EF4444;
  --yellow-500: #F59E0B;
  --white: #F9FAFB;

  /* Semantic - Dark (default) */
  --bg-app: var(--navy-950);
  --bg-elevated: var(--navy-900);
  --surface-card: var(--navy-850);
  --surface-card-2: var(--navy-800);
  --surface-input: rgba(255,255,255,0.03);
  --surface-hover: rgba(255,255,255,0.04);
  --border-subtle: rgba(255,255,255,0.05);
  --border-strong: rgba(255,255,255,0.10);
  --border-focus: var(--blue-500);
  --text-primary: #F9FAFB;
  --text-secondary: rgba(255,255,255,0.50);
  --text-muted: rgba(255,255,255,0.25);
  --text-on-accent: #FFFFFF;
  --accent: var(--blue-500);
  --accent-hover: var(--blue-400);
  --accent-2: var(--purple-500);
  --gradient-accent: linear-gradient(135deg, #3B82F6, #8B5CF6);
  --gradient-text: linear-gradient(135deg, #60A5FA, #A78BFA);
  --gain: var(--green-500);
  --loss: var(--red-500);
  --warning: var(--yellow-500);
  --gain-soft: rgba(16,185,129,0.12);
  --loss-soft: rgba(239,68,68,0.12);
  --warning-soft: rgba(245,158,11,0.12);
  --accent-soft: rgba(59,130,246,0.12);
  --accent-2-soft: rgba(139,92,246,0.12);

  /* Shadows & glows */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.40);
  --shadow-md: 0 8px 24px rgba(0,0,0,0.35);
  --shadow-lg: 0 20px 50px rgba(0,0,0,0.45);
  --glow-blue: 0 0 40px rgba(59,130,246,0.35);
  --glow-purple: 0 0 40px rgba(139,92,246,0.35);
  --glow-card-hover: 0 12px 40px rgba(59,130,246,0.18);
  --focus-ring: 0 0 0 3px rgba(59,130,246,0.25);

  /* Glass */
  --glass-bg: rgba(17,24,39,0.55);
  --glass-blur: blur(10px);
  --glass-border: rgba(255,255,255,0.08);

  /* Orbs */
  --orb-blue: radial-gradient(circle, rgba(59,130,246,0.15), transparent 70%);
  --orb-purple: radial-gradient(circle, rgba(139,92,246,0.15), transparent 70%);

  /* Transitions */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast: 120ms;
  --dur: 200ms;
  --dur-slow: 360ms;

  /* Spacing */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;

  /* Radii */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-pill: 999px;

  /* Layout */
  --container: 1200px;
  --container-narrow: 760px;

  /* Typography */
  --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --text-display: 64px;
  --text-h1: 48px;
  --text-h2: 36px;
  --text-h3: 22px;
  --text-lg: 18px;
  --text-base: 16px;
  --text-sm: 14px;
  --text-xs: 12px;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;
  --fw-extrabold: 800;
  --lh-tight: 1.05;
  --lh-heading: 1.15;
  --lh-body: 1.6;
  --ls-tight: -0.02em;
  --ls-tighter: -0.03em;
  --ls-normal: 0;
  --ls-wide: 0.04em;
}

/* ── Light Mode ────────────────────────────────────────── */
[data-theme="light"] {
  --bg-app: #F8FAFC;
  --bg-elevated: #F1F5F9;
  --surface-card: #FFFFFF;
  --surface-card-2: #F8FAFC;
  --surface-input: rgba(15,23,42,0.03);
  --surface-hover: rgba(15,23,42,0.03);
  --border-subtle: rgba(15,23,42,0.08);
  --border-strong: rgba(15,23,42,0.14);
  --text-primary: #0F172A;
  --text-secondary: rgba(15,23,42,0.60);
  --text-muted: rgba(15,23,42,0.35);
  --glass-bg: rgba(248,250,252,0.88);
  --glass-border: rgba(15,23,42,0.10);
  --accent-soft: rgba(59,130,246,0.10);
  --gain-soft: rgba(16,185,129,0.12);
  --loss-soft: rgba(239,68,68,0.12);
  --warning-soft: rgba(245,158,11,0.14);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.10);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.14);
  --glow-card-hover: 0 8px 28px rgba(59,130,246,0.14);
}

/* ── Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { background: var(--bg-app); color: var(--text-primary); font-family: var(--font-sans); font-size: var(--text-base); line-height: var(--lh-body); overflow-x: hidden; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ── Header ────────────────────────────────────────────── */
.site-header { position: sticky; top: 0; z-index: 100; display: flex; align-items: center; justify-content: space-between; padding: 0 40px; height: 66px; background: var(--glass-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); border-bottom: 1px solid var(--border-subtle); }
.logo { font-size: 20px; font-weight: var(--fw-extrabold); letter-spacing: var(--ls-tight); background: var(--gradient-accent); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav-links { display: flex; gap: 2px; }
.nav-links a { padding: 8px 14px; border-radius: var(--radius-md); font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-secondary); transition: all var(--dur) var(--ease-out); }
.nav-links a:hover, .nav-links a.active { color: var(--text-primary); background: var(--surface-hover); }
.header-right { display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 38px; height: 38px; border-radius: var(--radius-md); border: 1px solid var(--border-subtle); background: transparent; display: inline-flex; align-items: center; justify-content: center; color: var(--text-secondary); transition: all var(--dur) var(--ease-out); }
.icon-btn:hover { border-color: var(--border-strong); color: var(--text-primary); background: var(--surface-hover); }
.btn-primary { display: inline-flex; align-items: center; gap: 6px; padding: 9px 20px; border-radius: var(--radius-md); background: var(--gradient-accent); color: var(--text-on-accent); font-size: var(--text-sm); font-weight: var(--fw-bold); border: none; transition: opacity var(--dur); }
.btn-primary:hover { opacity: 0.88; }
.btn-secondary { display: inline-flex; align-items: center; gap: 6px; padding: 9px 20px; border-radius: var(--radius-md); background: transparent; color: var(--text-primary); font-size: var(--text-sm); font-weight: var(--fw-bold); border: 1px solid var(--border-strong); transition: all var(--dur) var(--ease-out); }
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
.hamburger { display: none; }
@media (max-width: 960px) {
  .nav-links { position: fixed; top: 66px; left: 0; right: 0; bottom: 0; flex-direction: column; background: var(--bg-app); padding: 24px; gap: 4px; display: none; z-index: 99; border-top: 1px solid var(--border-subtle); }
  .nav-links.mobile-open { display: flex; }
  .nav-links a { padding: 14px 16px; font-size: var(--text-base); }
}

/* ── Glow Orbs ─────────────────────────────────────────── */
.orb { position: fixed; border-radius: 50%; pointer-events: none; z-index: 0; }
.orb-blue { width: 700px; height: 700px; top: -300px; right: -150px; background: radial-gradient(circle, rgba(59,130,246,0.14), transparent 70%); filter: blur(60px); }
.orb-purple { width: 640px; height: 640px; bottom: 100px; left: -220px; background: radial-gradient(circle, rgba(139,92,246,0.12), transparent 70%); filter: blur(60px); }
[data-theme="light"] .orb-blue,
[data-theme="light"] .orb-purple { opacity: 0.15; }

/* ── Section Helpers ───────────────────────────────────── */
.section { position: relative; z-index: 1; padding: var(--space-20) var(--space-10); }
.section-inner { max-width: var(--container); margin: 0 auto; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 36px; }
.section-title { font-size: 30px; font-weight: var(--fw-bold); letter-spacing: var(--ls-tight); }
.see-all { font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--accent); display: inline-flex; align-items: center; gap: 5px; transition: opacity var(--dur); }
.see-all:hover { opacity: 0.75; }

/* ── Cards ─────────────────────────────────────────────── */
.card { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: var(--space-6); transition: transform var(--dur) var(--ease-out), border-color var(--dur), box-shadow var(--dur); }
.card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--glow-card-hover); }
.card-glass { background: var(--glass-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); }

/* ── Category Cards ────────────────────────────────────── */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat-card { background: var(--surface-card); border-radius: var(--radius-lg); border: 1px solid var(--border-subtle); padding: 22px 24px; cursor: pointer; transition: transform var(--dur) var(--ease-out), border-color var(--dur), box-shadow var(--dur); }
.cat-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--glow-card-hover); }
.cat-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 12px; }
.cat-emoji { font-size: 32px; line-height: 1; }
.cat-arr { color: var(--text-muted); font-size: 18px; transition: transform var(--dur), color var(--dur); margin-top: 2px; }
.cat-card:hover .cat-arr { color: var(--accent); transform: translateX(4px); }
.cat-name { font-size: 16px; font-weight: var(--fw-bold); margin-bottom: 4px; }
.cat-count { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--accent); font-weight: var(--fw-semibold); margin-bottom: 8px; }
.cat-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }

/* ── Tool Cards ────────────────────────────────────────── */
.tool-card { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: 22px; cursor: pointer; transition: transform var(--dur) var(--ease-out), border-color var(--dur), box-shadow var(--dur); }
.tool-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--glow-card-hover); }
.tool-icon { width: 40px; height: 40px; border-radius: var(--radius-sm); background: var(--accent-soft); display: inline-flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.tool-name { font-size: 15px; font-weight: var(--fw-bold); margin-bottom: 6px; }
.tool-desc { font-size: 13px; color: var(--text-secondary); line-height: 1.5; margin-bottom: 18px; }
.use-now { font-size: 13px; font-weight: var(--fw-bold); color: var(--accent); display: inline-flex; align-items: center; gap: 4px; }

/* ── Hero ──────────────────────────────────────────────── */
.hero-section { position: relative; z-index: 1; max-width: var(--container); margin: 0 auto; padding: 92px 40px 84px; display: grid; grid-template-columns: 1.5fr 1fr; gap: 64px; align-items: center; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px 6px 8px; border-radius: var(--radius-pill); background: var(--accent-soft); border: 1px solid rgba(59,130,246,0.22); color: var(--accent); font-size: 13px; font-weight: var(--fw-bold); margin-bottom: 24px; }
.badge-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.hero-h1 { font-size: clamp(44px, 5.5vw, 68px); font-weight: var(--fw-extrabold); letter-spacing: -0.035em; line-height: var(--lh-tight); background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; color: transparent; margin-bottom: 20px; }
.hero-sub { font-size: var(--text-lg); color: var(--text-secondary); line-height: 1.65; margin-bottom: 34px; max-width: 480px; }

/* ── Search ────────────────────────────────────────────── */
.search-wrap { display: flex; align-items: center; background: var(--surface-card); border: 1px solid var(--border-strong); border-radius: 14px; padding: 0 8px 0 20px; height: 60px; gap: 12px; margin-bottom: 18px; box-shadow: var(--shadow-md); transition: border-color var(--dur), box-shadow var(--dur); }
.search-wrap:focus-within { border-color: var(--accent); box-shadow: var(--focus-ring), var(--shadow-md); }
.search-wrap input { flex: 1; background: none; border: none; outline: none; font-family: var(--font-sans); font-size: var(--text-base); color: var(--text-primary); }
.search-wrap input::placeholder { color: var(--text-muted); }
.search-btn { width: 42px; height: 42px; border-radius: 10px; background: var(--gradient-accent); border: none; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--text-on-accent); }
.quick-links { display: flex; gap: 8px; flex-wrap: wrap; }
.quick-chip { padding: 8px 16px; border-radius: var(--radius-pill); background: var(--surface-card-2); border: 1px solid var(--border-subtle); font-size: 13px; font-weight: var(--fw-semibold); color: var(--text-secondary); transition: all var(--dur) var(--ease-out); }
.quick-chip:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
[data-theme="light"] .search-wrap { background: #fff; }
[data-theme="light"] .search-wrap input { color: #0F172A; }
[data-theme="light"] .quick-chip { background: #fff; }

/* ── Hero Visual (random on refresh) ──────────────────── */
.hero-visual { display: none; }
.hero-visual.active { display: block; }

/* Option 1: Mini Calculator */
.mini-calc { border-radius: var(--radius-xl); background: var(--surface-card); border: 1px solid var(--border-subtle); padding: 28px; position: relative; overflow: hidden; box-shadow: 0 0 80px rgba(59,130,246,0.08), 0 0 160px rgba(139,92,246,0.04); }
.mini-calc::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at 65% 35%, rgba(59,130,246,0.08), transparent 55%), radial-gradient(ellipse at 30% 70%, rgba(139,92,246,0.06), transparent 55%); pointer-events: none; }
.mini-calc-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; position: relative; }
.mini-calc-title { font-size: 14px; font-weight: 700; }
.mini-calc-badge { font-size: 10px; font-weight: 700; padding: 4px 10px; border-radius: var(--radius-pill); background: var(--accent-soft); color: var(--accent); text-transform: uppercase; letter-spacing: 0.5px; }
.mini-results { background: var(--surface-card-2); border: 1px solid var(--border-subtle); border-radius: 14px; padding: 20px; margin-top: 20px; }
.result-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; }
.result-row:not(:last-child) { border-bottom: 1px solid var(--border-subtle); }
.result-label { font-size: 12px; color: var(--text-secondary); }
.result-value { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.result-value.highlight { color: var(--accent); font-size: 18px; }
.mini-chart { margin-top: 16px; display: flex; align-items: flex-end; gap: 4px; height: 60px; }
.mini-bar { flex: 1; border-radius: 3px 3px 0 0; animation: barGrow 1s ease-out forwards; transform-origin: bottom; }
@keyframes barGrow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.mini-cta { display: block; text-align: center; margin-top: 16px; padding: 12px; border-radius: 10px; background: var(--gradient-accent); color: var(--text-on-accent); font-size: 13px; font-weight: 700; transition: opacity 0.2s; }
.mini-cta:hover { opacity: 0.9; }
.live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gain); display: inline-block; margin-right: 6px; animation: livePulse 2s infinite; }
@keyframes livePulse { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }

/* Option 2: Floating Cards */
.float-scene { position: relative; width: 100%; aspect-ratio: 1; perspective: 800px; }
.float-card { position: absolute; border-radius: var(--radius); padding: 20px; backdrop-filter: blur(20px); border: 1px solid rgba(255,255,255,0.1); cursor: default; transition: transform 0.3s; }
.float-card:hover { transform: scale(1.05) !important; }
.fc-1 { background: linear-gradient(135deg, rgba(59,130,246,0.15), rgba(59,130,246,0.05)); top: 5%; left: 10%; width: 200px; animation: hFloat1 6s ease-in-out infinite; }
.fc-2 { background: linear-gradient(135deg, rgba(16,185,129,0.15), rgba(16,185,129,0.05)); top: 35%; right: 5%; width: 180px; animation: hFloat2 7s ease-in-out infinite; animation-delay: -1s; }
.fc-3 { background: linear-gradient(135deg, rgba(139,92,246,0.15), rgba(139,92,246,0.05)); bottom: 20%; left: 5%; width: 190px; animation: hFloat3 8s ease-in-out infinite; animation-delay: -2s; }
.fc-4 { background: linear-gradient(135deg, rgba(244,63,94,0.12), rgba(244,63,94,0.04)); top: 12%; right: 15%; width: 160px; animation: hFloat4 5.5s ease-in-out infinite; animation-delay: -0.5s; }
.fc-5 { background: linear-gradient(135deg, rgba(59,130,246,0.12), rgba(139,92,246,0.08)); bottom: 8%; right: 12%; width: 170px; animation: hFloat5 6.5s ease-in-out infinite; animation-delay: -3s; }
@keyframes hFloat1 { 0%,100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-20px) rotate(1deg); } }
@keyframes hFloat2 { 0%,100% { transform: translateY(0) rotate(1deg); } 50% { transform: translateY(-15px) rotate(-2deg); } }
@keyframes hFloat3 { 0%,100% { transform: translateY(0) rotate(2deg); } 50% { transform: translateY(-18px) rotate(-1deg); } }
@keyframes hFloat4 { 0%,100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-12px) rotate(2deg); } }
@keyframes hFloat5 { 0%,100% { transform: translateY(0) rotate(1deg); } 50% { transform: translateY(-16px) rotate(-1.5deg); } }
.fc-icon { width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; margin-bottom: 12px; }
.fc-1 .fc-icon { background: rgba(59,130,246,0.2); } .fc-2 .fc-icon { background: rgba(16,185,129,0.2); } .fc-3 .fc-icon { background: rgba(139,92,246,0.2); } .fc-4 .fc-icon { background: rgba(244,63,94,0.2); } .fc-5 .fc-icon { background: rgba(59,130,246,0.2); }
.fc-label { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-secondary); margin-bottom: 6px; }
.fc-value { font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -0.5px; margin-bottom: 4px; }
.fc-1 .fc-value { color: var(--accent); } .fc-2 .fc-value { color: var(--gain); } .fc-3 .fc-value { color: #8B5CF6; } .fc-4 .fc-value { color: var(--loss); } .fc-5 .fc-value { color: var(--accent); }
.fc-sub { font-size: 11px; color: var(--text-secondary); font-weight: 500; }
.fc-change { font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; gap: 3px; padding: 2px 8px; border-radius: var(--radius-pill); margin-top: 6px; }
.fc-change.up { color: var(--gain); background: rgba(16,185,129,0.1); } .fc-change.dn { color: var(--loss); background: rgba(244,63,94,0.1); }
.float-scene::before { content: ''; position: absolute; top: 20%; left: 30%; width: 40%; height: 40%; border: 1px dashed rgba(59,130,246,0.08); border-radius: 50%; animation: spinSlow 20s linear infinite; }
@keyframes spinSlow { from { transform: rotate(0); } to { transform: rotate(360deg); } }
.particle { position: absolute; width: 4px; height: 4px; border-radius: 50%; background: var(--accent); opacity: 0.3; animation: particleFloat 4s ease-in-out infinite; }
.particle:nth-child(2) { width: 3px; height: 3px; background: #8B5CF6; top: 20%; left: 50%; animation-delay: -1s; animation-duration: 5s; }
.particle:nth-child(3) { width: 5px; height: 5px; background: var(--gain); top: 60%; left: 40%; animation-delay: -2s; opacity: 0.2; }
.particle:nth-child(4) { width: 3px; height: 3px; background: var(--accent); top: 80%; left: 70%; animation-delay: -3s; animation-duration: 6s; opacity: 0.25; }
@keyframes particleFloat { 0%,100% { transform: translateY(0) scale(1); opacity: 0.3; } 50% { transform: translateY(-30px) scale(1.5); opacity: 0.1; } }

/* Option 3: Counter Stats */
.stats-visual { display: flex; flex-direction: column; gap: 16px; }
.stat-card { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius); padding: 24px 28px; position: relative; overflow: hidden; transition: all 0.3s; }
.stat-card:hover { border-color: rgba(59,130,246,0.2); transform: translateX(-4px); }
.stat-card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; border-radius: 0 2px 2px 0; }
.stat-card:nth-child(1)::before { background: linear-gradient(180deg, var(--accent), #8B5CF6); }
.stat-card:nth-child(2)::before { background: linear-gradient(180deg, var(--gain), #06b6d4); }
.stat-card:nth-child(3)::before { background: linear-gradient(180deg, #8B5CF6, var(--loss)); }
.stat-card:nth-child(4)::before { background: linear-gradient(180deg, #f59e0b, var(--loss)); }
.stat-card-inner { display: flex; align-items: center; gap: 20px; }
.stat-icon { width: 48px; height: 48px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.stat-card:nth-child(1) .stat-icon { background: rgba(59,130,246,0.1); } .stat-card:nth-child(2) .stat-icon { background: rgba(16,185,129,0.1); } .stat-card:nth-child(3) .stat-icon { background: rgba(139,92,246,0.1); } .stat-card:nth-child(4) .stat-icon { background: rgba(245,158,11,0.1); }
.stat-number { font-size: 32px; font-weight: 800; letter-spacing: -1px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat-card:nth-child(1) .stat-number { color: var(--accent); } .stat-card:nth-child(2) .stat-number { color: var(--gain); } .stat-card:nth-child(3) .stat-number { color: #8B5CF6; } .stat-card:nth-child(4) .stat-number { color: #f59e0b; }
.stat-desc { font-size: 12px; color: var(--text-secondary); font-weight: 500; margin-top: 2px; }
.stat-bar { height: 4px; border-radius: 2px; background: rgba(255,255,255,0.04); margin-top: 16px; overflow: hidden; }
.stat-bar-fill { height: 100%; border-radius: 2px; animation: fillBar 2s ease-out forwards; transform-origin: left; }
@keyframes fillBar { from { width: 0; } to { width: var(--w); } }
.stat-card:nth-child(1) .stat-bar-fill { background: linear-gradient(90deg, var(--accent), #8B5CF6); } .stat-card:nth-child(2) .stat-bar-fill { background: linear-gradient(90deg, var(--gain), #06b6d4); } .stat-card:nth-child(3) .stat-bar-fill { background: linear-gradient(90deg, #8B5CF6, var(--loss)); } .stat-card:nth-child(4) .stat-bar-fill { background: linear-gradient(90deg, #f59e0b, var(--loss)); }
.sparkline { position: absolute; right: 28px; top: 50%; transform: translateY(-50%); opacity: 0.15; }

/* Option 4: Pakistan Map */
.map-scene { position: relative; width: 100%; aspect-ratio: 1; display: flex; align-items: center; justify-content: center; }
.map-container { position: relative; width: 100%; height: 100%; }
.map-container svg { width: 100%; height: 100%; }
.map-glow { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 70%; height: 70%; border-radius: 50%; background: radial-gradient(circle, rgba(59,130,246,0.08) 0%, transparent 70%); animation: mapPulse 4s ease-in-out infinite; }
@keyframes mapPulse { 0%,100% { opacity: 0.5; transform: translate(-50%,-50%) scale(1); } 50% { opacity: 1; transform: translate(-50%,-50%) scale(1.05); } }
.map-dot { position: absolute; cursor: pointer; z-index: 2; }
.map-dot::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); display: block; animation: dotPulse 2s ease-in-out infinite; box-shadow: 0 0 12px rgba(59,130,246,0.5); }
.map-dot::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid rgba(59,130,246,0.3); animation: dotRing 2s ease-in-out infinite; }
@keyframes dotPulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.3); opacity: 0.7; } }
@keyframes dotRing { 0%,100% { transform: translate(-50%,-50%) scale(1); opacity: 0.5; } 50% { transform: translate(-50%,-50%) scale(1.8); opacity: 0; } }
.map-dot:nth-child(3)::before { background: var(--gain); box-shadow: 0 0 12px rgba(16,185,129,0.5); animation-delay: -0.5s; } .map-dot:nth-child(3)::after { border-color: rgba(16,185,129,0.3); animation-delay: -0.5s; }
.map-dot:nth-child(4)::before { background: #8B5CF6; box-shadow: 0 0 12px rgba(139,92,246,0.5); animation-delay: -1s; } .map-dot:nth-child(4)::after { border-color: rgba(139,92,246,0.3); animation-delay: -1s; }
.map-dot:nth-child(5)::before { background: #f59e0b; box-shadow: 0 0 12px rgba(245,158,11,0.5); animation-delay: -1.5s; } .map-dot:nth-child(5)::after { border-color: rgba(245,158,11,0.3); animation-delay: -1.5s; }
.map-label { position: absolute; top: -52px; left: 50%; transform: translateX(-50%); white-space: nowrap; pointer-events: none; }
.map-label-inner { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: 10px; padding: 10px 14px; font-size: 11px; backdrop-filter: blur(10px); opacity: 0; transform: translateY(4px); animation: labelFade 0.5s ease-out forwards; }
.map-dot:nth-child(2) .map-label-inner { animation-delay: 0.5s; } .map-dot:nth-child(3) .map-label-inner { animation-delay: 1s; } .map-dot:nth-child(4) .map-label-inner { animation-delay: 1.5s; } .map-dot:nth-child(5) .map-label-inner { animation-delay: 2s; }
@keyframes labelFade { to { opacity: 1; transform: translateY(0); } }
.ml-city { font-weight: 700; margin-bottom: 2px; } .ml-tool { color: var(--accent); font-weight: 600; }
.map-badge { position: absolute; bottom: 8%; left: 50%; transform: translateX(-50%); background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-pill); padding: 8px 20px; font-size: 12px; font-weight: 600; color: var(--text-secondary); display: flex; align-items: center; gap: 8px; z-index: 3; }

/* ── Ticker ─────────────────────────────────────────────── */
.ticker-bar { border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); background: var(--bg-elevated); padding: 13px 0; overflow: hidden; position: relative; z-index: 1; }
.ticker-track { display: flex; white-space: nowrap; animation: scroll-l 30s linear infinite; }
.ticker-item { display: inline-flex; align-items: center; gap: 8px; padding: 0 28px; font-family: var(--font-mono); font-size: 13px; font-weight: var(--fw-semibold); }
.t-label { color: var(--text-secondary); }
.t-up { color: var(--gain); }
.t-dn { color: var(--loss); }
.t-sep { color: var(--border-strong); padding: 0 4px; }
@keyframes scroll-l { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
[data-theme="light"] .ticker-bar { background: #F1F5F9; }

/* ── How It Works ──────────────────────────────────────── */
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.how-card { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: 36px 28px; text-align: center; }
.how-step { width: 56px; height: 56px; border-radius: 50%; background: var(--gradient-accent); margin: 0 auto 20px; display: flex; align-items: center; justify-content: center; font-size: 26px; box-shadow: 0 0 24px rgba(59,130,246,0.3); }
.how-title { font-size: var(--text-lg); font-weight: var(--fw-bold); margin-bottom: 10px; }
.how-desc { font-size: var(--text-sm); color: var(--text-secondary); line-height: var(--lh-body); }
[data-theme="light"] .how-card { box-shadow: 0 1px 4px rgba(0,0,0,0.06); }

/* ── Stats ─────────────────────────────────────────────── */
.stats-section { background: var(--bg-elevated); border-top: 1px solid var(--border-subtle); border-bottom: 1px solid var(--border-subtle); position: relative; z-index: 1; }
.stats-grid { max-width: var(--container); margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); }
.stat-item { text-align: center; padding: 56px 24px; border-right: 1px solid var(--border-subtle); }
.stat-item:last-child { border-right: none; }
.stat-num { font-family: var(--font-mono); font-size: 56px; font-weight: var(--fw-extrabold); letter-spacing: var(--ls-tighter); line-height: 1; background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; color: transparent; margin-bottom: 10px; }
.stat-label { font-size: 15px; color: var(--text-secondary); font-weight: var(--fw-semibold); }
[data-theme="light"] .stats-section { background: #F1F5F9; }

/* ── Blog Cards ────────────────────────────────────────── */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.blog-card { background: var(--surface-card); border-radius: var(--radius-lg); border: 1px solid var(--border-subtle); overflow: hidden; cursor: pointer; transition: transform var(--dur) var(--ease-out), box-shadow var(--dur), border-color var(--dur); }
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.blog-img { height: 172px; display: flex; align-items: center; justify-content: center; font-size: 36px; }
.blog-body { padding: 20px 22px; }
.blog-tag { display: inline-block; padding: 4px 10px; border-radius: var(--radius-pill); font-size: 11px; font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: 0.05em; background: var(--accent-soft); color: var(--accent); margin-bottom: 11px; }
.blog-title { font-size: 15px; font-weight: var(--fw-bold); line-height: 1.45; margin-bottom: 12px; }
.blog-meta { font-size: var(--text-xs); color: var(--text-muted); font-family: var(--font-mono); }
[data-theme="light"] .blog-card { box-shadow: 0 1px 4px rgba(0,0,0,0.07); }

/* ── Footer ────────────────────────────────────────────── */
.site-footer { background: var(--bg-elevated); border-top: 1px solid var(--border-subtle); padding: 64px 40px 32px; position: relative; z-index: 1; }
.footer-inner { max-width: var(--container); margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 0.8fr 1.3fr 1fr; gap: 36px; margin-bottom: 48px; }
.footer-col h4 { font-size: var(--text-xs); font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: 0.07em; color: var(--text-primary); margin-bottom: 18px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: var(--text-sm); color: var(--text-secondary); transition: color var(--dur); }
.footer-col a:hover { color: var(--accent); }
.footer-about { font-size: var(--text-sm); color: var(--text-secondary); line-height: 1.7; }
.footer-bar { padding-top: 24px; border-top: 1px solid var(--border-subtle); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--text-muted); }
.footer-bar-links { display: flex; gap: 20px; }
.footer-bar a { color: var(--text-muted); transition: color var(--dur); }
.footer-bar a:hover { color: var(--text-secondary); }
[data-theme="light"] .site-footer { background: #F1F5F9; }

/* ── Badges ────────────────────────────────────────────── */
.badge { display: inline-block; padding: 4px 10px; border-radius: var(--radius-pill); font-size: 11px; font-weight: var(--fw-bold); text-transform: uppercase; letter-spacing: 0.05em; }
.badge-accent { background: var(--accent-soft); color: var(--accent); }
.badge-gain { background: var(--gain-soft); color: var(--gain); }
.badge-loss { background: var(--loss-soft); color: var(--loss); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }

/* ── Tables ────────────────────────────────────────────── */
.data-table { width: 100%; border-collapse: collapse; font-family: var(--font-mono); font-size: var(--text-sm); }
.data-table th { text-align: left; padding: 12px 16px; font-size: var(--text-xs); font-weight: var(--fw-semibold); text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-muted); border-bottom: 1px solid var(--border-strong); }
.data-table td { padding: 14px 16px; border-bottom: 1px solid var(--border-subtle); }
.data-table tr:hover td { background: var(--surface-hover); }
.text-gain { color: var(--gain); }
.text-loss { color: var(--loss); }

/* ── Form Inputs ───────────────────────────────────────── */
.form-group { margin-bottom: var(--space-5); }
.form-label { display: block; font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-secondary); margin-bottom: var(--space-2); }
.form-input { width: 100%; padding: 12px 16px; background: var(--surface-input); border: 1px solid var(--border-strong); border-radius: var(--radius-md); color: var(--text-primary); font-size: var(--text-base); transition: border-color var(--dur), box-shadow var(--dur); }
.form-input:focus { outline: none; border-color: var(--accent); box-shadow: var(--focus-ring); }
.form-input::placeholder { color: var(--text-muted); }

/* ── Breadcrumbs ───────────────────────────────────────── */
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: var(--text-sm); color: var(--text-muted); padding: 20px 0; }
.breadcrumb a { color: var(--text-muted); transition: color var(--dur); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .current { color: var(--text-secondary); }

/* ── Accordion / FAQ ───────────────────────────────────── */
.accordion-item { border-bottom: 1px solid var(--border-subtle); }
.accordion-btn { width: 100%; padding: 20px 0; display: flex; align-items: center; justify-content: space-between; background: none; border: none; color: var(--text-primary); font-size: var(--text-base); font-weight: var(--fw-semibold); text-align: left; cursor: pointer; }
.accordion-btn svg { transition: transform var(--dur) var(--ease-out); color: var(--text-muted); flex-shrink: 0; }
.accordion-item.open .accordion-btn svg { transform: rotate(180deg); }
.accordion-body { overflow: hidden; max-height: 0; transition: max-height var(--dur-slow) var(--ease-out); }
.accordion-item.open .accordion-body { max-height: 500px; }
.accordion-content { padding: 0 0 20px; font-size: var(--text-sm); color: var(--text-secondary); line-height: var(--lh-body); }

/* ── Responsive ────────────────────────────────────────── */
@media (max-width: 960px) {
  .site-header { padding: 0 24px; }
  .nav-links { display: none; }
  .hamburger { display: inline-flex !important; }
  .hero-section { grid-template-columns: 1fr; padding: 60px 24px 56px; gap: 40px; }
  .float-scene, .map-scene { max-width: 400px; margin: 0 auto; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .how-grid { grid-template-columns: 1fr; gap: 14px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-item:nth-child(2) { border-right: none; }
  .stat-item:nth-child(3) { border-right: 1px solid var(--border-subtle); border-top: 1px solid var(--border-subtle); }
  .stat-item:nth-child(4) { border-top: 1px solid var(--border-subtle); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .section { padding: 60px 24px; }
}
@media (max-width: 540px) {
  .cat-grid { grid-template-columns: 1fr; }
  .blog-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-num { font-size: 44px; }
  .calc-grid { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .cat-tools-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr; }
  .how-grid { grid-template-columns: 1fr; }
  .tool-header-row { flex-direction: column; }
  .tool-header-actions { width: 100%; justify-content: flex-start; }
  .hero-section { padding: 40px 20px 40px; }
}

/* ── Page Container ────────────────────────────────────── */
.pg { position: relative; z-index: 1; }

/* ── Calculator Page ───────────────────────────────────── */
.tool-header { padding: 32px 0 24px; }
.tool-header h1 { font-size: var(--text-h1); font-weight: var(--fw-extrabold); letter-spacing: var(--ls-tighter); margin-bottom: 8px; }
.tool-subtitle { font-size: var(--text-lg); color: var(--text-secondary); line-height: 1.6; }
.tool-header-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.tool-header-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

.calc-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 24px; margin-bottom: 48px; }
.panel { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: var(--space-8); }
.results-panel { display: flex; flex-direction: column; gap: 16px; }
[data-theme="light"] .panel { box-shadow: 0 1px 4px rgba(0,0,0,0.08); }

.inp-grp { margin-bottom: var(--space-6); }
.inp-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.inp-lbl { font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-secondary); }
.inp-val { font-family: var(--font-mono); font-size: var(--text-sm); font-weight: var(--fw-bold); color: var(--accent); }

input[type="range"] { width: 100%; height: 6px; -webkit-appearance: none; appearance: none; background: var(--border-strong); border-radius: 3px; outline: none; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: var(--gradient-accent); cursor: pointer; box-shadow: 0 0 10px rgba(59,130,246,0.35); }
[data-theme="light"] input[type="range"] { background: rgba(15,23,42,0.12); }

.slider-ticks { display: flex; justify-content: space-between; font-size: 11px; color: var(--text-muted); margin-top: 6px; }

.calc-cta { width: 100%; padding: 16px; border-radius: var(--radius-md); background: var(--gradient-accent); color: var(--text-on-accent); font-size: var(--text-base); font-weight: var(--fw-bold); border: none; margin-top: var(--space-4); transition: opacity var(--dur); }
.calc-cta:hover { opacity: 0.88; }
.reset-lnk { display: block; width: 100%; text-align: center; background: none; border: none; color: var(--text-muted); font-size: var(--text-sm); margin-top: 12px; }
.reset-lnk:hover { color: var(--text-secondary); }

.emi-card { position: relative; background: var(--glass-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); border: 1px solid var(--glass-border); border-radius: var(--radius-lg); padding: var(--space-8); text-align: center; overflow: hidden; }
.emi-lbl { font-size: var(--text-sm); color: var(--text-secondary); margin-bottom: 8px; }
.emi-val { font-family: var(--font-mono); font-size: 36px; font-weight: var(--fw-extrabold); background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.emi-sub { font-size: var(--text-xs); color: var(--text-muted); margin-top: 8px; }

.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.stat-c { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-md); padding: 16px; text-align: center; }
.stat-lbl { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 6px; }
.stat-n { font-family: var(--font-mono); font-size: var(--text-sm); font-weight: var(--fw-bold); }

.tool-content { padding: 32px 0; }
.tool-content h2 { font-size: var(--text-h3); font-weight: var(--fw-bold); margin-bottom: 16px; }
.tool-content p { color: var(--text-secondary); line-height: 1.75; margin-bottom: 16px; }

.formula-box { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-md); padding: 24px; text-align: center; margin: 20px 0; font-family: var(--font-mono); font-size: var(--text-lg); font-weight: var(--fw-bold); color: var(--accent); }

.tip-box { display: flex; gap: 12px; padding: 16px 20px; background: var(--accent-soft); border: 1px solid rgba(59,130,246,0.15); border-radius: var(--radius-md); margin: 20px 0; }

.related-section { padding: 48px 0; }
.related-section h2 { font-size: var(--text-h3); font-weight: var(--fw-bold); margin-bottom: 20px; }
.related-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 960px) { .related-grid { grid-template-columns: repeat(2, 1fr); } }

/* ── Category Page ─────────────────────────────────────── */
.category-hero { padding: 48px 0 32px; }
.filter-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; padding: 12px 0; border-bottom: 1px solid var(--border-subtle); }
.filter-count { font-size: var(--text-sm); color: var(--text-secondary); }
.sort-wrap { display: flex; align-items: center; gap: 8px; }
.sort-label { font-size: var(--text-xs); color: var(--text-muted); }
.cat-tools-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 960px) { .cat-tools-grid { grid-template-columns: repeat(2, 1fr); } }

/* ── Directory Page ────────────────────────────────────── */
.directory-hero { padding: 48px 0 32px; }
.tabs-bar { border-bottom: 1px solid var(--border-subtle); padding: 0 40px; position: relative; z-index: 1; }
.tabs-scroll { display: flex; gap: 4px; overflow-x: auto; -ms-overflow-style: none; scrollbar-width: none; max-width: var(--container); margin: 0 auto; }
.tabs-scroll::-webkit-scrollbar { display: none; }
.tab-btn { padding: 12px 16px; border: none; background: none; font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-muted); cursor: pointer; white-space: nowrap; border-bottom: 2px solid transparent; transition: all var(--dur); }
.tab-btn:hover { color: var(--text-secondary); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); }
.tab-count { font-family: var(--font-mono); font-size: 11px; opacity: 0.6; margin-left: 4px; }
.tools-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 32px 0; }
@media (max-width: 960px) { .tools-grid { grid-template-columns: repeat(2, 1fr); } .tabs-bar { padding: 0 24px; } }
@media (max-width: 540px) { .tools-grid { grid-template-columns: 1fr; } }

/* ── Article Body ──────────────────────────────────────── */
.article-body h2 { font-size: var(--text-h3); font-weight: var(--fw-bold); color: var(--text-primary); margin: 32px 0 12px; }
.article-body h3 { font-size: var(--text-lg); font-weight: var(--fw-bold); color: var(--text-primary); margin: 24px 0 8px; }
.article-body p { margin-bottom: 16px; }
.article-body ul, .article-body ol { margin: 0 0 16px 24px; color: var(--text-secondary); }
.article-body li { margin-bottom: 8px; line-height: 1.7; }
.article-body table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: var(--text-sm); }
.article-body th { text-align: left; padding: 12px 16px; background: var(--surface-card); border: 1px solid var(--border-subtle); font-weight: var(--fw-semibold); color: var(--text-primary); }
.article-body td { padding: 12px 16px; border: 1px solid var(--border-subtle); }
.article-body blockquote { border-left: 3px solid var(--accent); padding: 16px 20px; margin: 20px 0; background: var(--accent-soft); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; font-style: italic; color: var(--text-secondary); }

/* ── Page Content ──────────────────────────────────────── */
.page-content h2 { font-size: var(--text-h2); font-weight: var(--fw-bold); margin: 32px 0 12px; }
.page-content p { font-size: var(--text-lg); color: var(--text-secondary); line-height: 1.75; margin-bottom: 16px; }

/* ── Scroll Fade ───────────────────────────────────────── */
.fade-target { opacity: 0; transform: translateY(20px); transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out); }
.fade-target.visible { opacity: 1; transform: translateY(0); }

/* ── Featured Scroll ───────────────────────────────────── */
.featured-scroll { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
.featured-scroll::-webkit-scrollbar { height: 3px; }
.featured-scroll::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 2px; }
.featured-scroll .tool-card { flex: 0 0 228px; }

/* ── Search Dropdown ───────────────────────────────────── */
.search-dropdown { position: absolute; top: 100%; left: 0; right: 0; background: var(--surface-card); border: 1px solid var(--border-strong); border-radius: 0 0 14px 14px; max-height: 320px; overflow-y: auto; display: none; z-index: 50; box-shadow: var(--shadow-lg); }
.search-dropdown-item { display: block; padding: 12px 20px; border-bottom: 1px solid var(--border-subtle); transition: background var(--dur); text-decoration: none; }
.search-dropdown-item:hover { background: var(--surface-hover); }
.search-dropdown-title { display: block; font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-primary); margin-bottom: 2px; }
.search-dropdown-cat { display: block; font-size: var(--text-xs); color: var(--text-muted); }
.search-dropdown-empty { padding: 16px; color: var(--text-muted); font-size: var(--text-sm); }

/* ── Toast Notification ────────────────────────────────── */
.tp-toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px); background: var(--surface-card); border: 1px solid var(--border-strong); border-radius: var(--radius-md); padding: 12px 24px; font-size: var(--text-sm); font-weight: var(--fw-semibold); color: var(--text-primary); box-shadow: var(--shadow-lg); z-index: 9999; opacity: 0; transition: opacity var(--dur), transform var(--dur); pointer-events: none; }
.tp-toast-show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── List View Toggle ──────────────────────────────────── */
.view-btns { display: flex; gap: 4px; }
.view-btn { width: 36px; height: 36px; border-radius: var(--radius-sm); border: 1px solid var(--border-subtle); background: transparent; display: inline-flex; align-items: center; justify-content: center; color: var(--text-muted); cursor: pointer; transition: all var(--dur); }
.view-btn:hover { border-color: var(--border-strong); color: var(--text-secondary); }
.view-btn.active { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

.tools-grid.list-view { grid-template-columns: 1fr; }
.tools-grid.list-view .tool-card { display: flex; align-items: center; gap: 16px; padding: 16px 20px; }
.tools-grid.list-view .tool-icon { margin-bottom: 0; }
.tools-grid.list-view .tool-name { margin-bottom: 0; }
.tools-grid.list-view .tool-desc { margin-bottom: 0; }
.tools-grid.list-view .use-now { margin-left: auto; margin-top: 0; }

/* ── Controls Row ──────────────────────────────────────── */
.ctrl-row { display: flex; align-items: center; justify-content: space-between; padding: 16px 0; }
.ctrl-count { font-size: var(--text-sm); color: var(--text-secondary); }

/* ── Spline Embed Container ────────────────────────────── */
.spline-embed { border-radius: var(--radius-xl); overflow: hidden; aspect-ratio: 1; }
.spline-embed iframe { width: 100%; height: 100%; border: none; }
