/* ==========================================================================
   PIHU TOOLS - MODERN HOME PAGE DESIGN SYSTEM
   Inspired by Top-Tier SaaS Suites (iLovePDF, Canva, TinyWow)
   ========================================================================== */

/* Base & Typography */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #f6f8fa;
  color: #1e293b;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

[hidden] {
  display: none !important;
}

/* ==========================================================================
   Header Styles
   ========================================================================== */
.home-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid #e2e8f0;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

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

.brand-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
  flex-shrink: 0;
}

.brand-icon svg {
  width: 22px;
  height: 22px;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #0f172a;
  line-height: 1.2;
  font-family: 'Outfit', 'Inter', sans-serif;
}

.brand-sub {
  font-size: 11.5px;
  font-weight: 500;
  color: #64748b;
  letter-spacing: 0.2px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.privacy-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 9999px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  font-size: 12px;
  font-weight: 600;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #22c55e;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
  animation: pulse-dot 2s infinite ease-in-out;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.15); }
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: #475569;
  transition: all 0.15s ease;
}

.nav-link:hover, .nav-link.active {
  color: #1d4ed8;
  background-color: #eff6ff;
}

.theme-toggle-btn {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 16px;
  transition: all 0.2s ease;
}

.theme-toggle-btn:hover {
  background: #e2e8f0;
  transform: translateY(-1px);
}

/* ==========================================================================
   Main Layout Container
   ========================================================================== */
.home-layout {
  max-width: 1400px;
  margin: 0 auto;
  padding: 28px 24px 60px;
}

/* ==========================================================================
   Daily Quotes Banner
   ========================================================================== */
.quote-banner {
  margin-bottom: 32px;
}

.quote-card {
  background: linear-gradient(135deg, #ffffff 0%, #f8faff 100%);
  border: 1px solid #e0e7ff;
  border-radius: 18px;
  padding: 22px 26px;
  box-shadow: 0 4px 20px -4px rgba(99, 102, 241, 0.08), 0 2px 6px -1px rgba(0, 0, 0, 0.02);
  position: relative;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.quote-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(to bottom, #4f46e5, #06b6d4);
  border-radius: 4px 0 0 4px;
}

.quote-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px dashed #e2e8f0;
}

.quote-tag {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.quote-sparkle {
  font-size: 16px;
}

.quote-heading {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: #4338ca;
  text-transform: uppercase;
}

.quote-date {
  font-size: 12px;
  color: #64748b;
  background: #f1f5f9;
  padding: 3px 8px;
  border-radius: 6px;
  font-weight: 500;
}

.quote-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.quote-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.quote-btn svg {
  width: 14px;
  height: 14px;
  transition: transform 0.4s ease;
}

.quote-btn:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a;
  transform: translateY(-1px);
}

.quote-btn:hover .icon-spin-target {
  transform: rotate(180deg);
}

.quote-btn-share {
  background: #25d366;
  border-color: #22c55e;
  color: #ffffff !important;
}

.quote-btn-share:hover {
  background: #1eb857;
  border-color: #16a34a;
  color: #ffffff;
}

.quote-content {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.quote-icon {
  font-size: 42px;
  line-height: 1;
  color: #c7d2fe;
  font-family: Georgia, serif;
  font-weight: bold;
  user-select: none;
}

.quote-body {
  flex: 1;
}

.quote-hindi {
  font-size: 17px;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.55;
  margin-bottom: 4px;
  font-family: 'Mukta', 'Inter', sans-serif;
}

.quote-english {
  font-size: 13.5px;
  color: #475569;
  font-style: italic;
  line-height: 1.45;
  margin-bottom: 8px;
}

.quote-author {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  color: #4f46e5;
  background: #eef2ff;
  padding: 3px 10px;
  border-radius: 6px;
}

/* ==========================================================================
   Hero Header & Search Bar
   ========================================================================== */
.home-hero {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 36px;
}

.hero-title {
  font-size: clamp(28px, 3.4vw, 42px);
  font-weight: 900;
  letter-spacing: -0.8px;
  color: #0f172a;
  line-height: 1.25;
  margin-bottom: 12px;
  font-family: 'Outfit', 'Inter', sans-serif;
}

.gradient-text {
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: clamp(15px, 1.4vw, 17px);
  color: #475569;
  line-height: 1.6;
  max-width: 780px;
  margin: 0 auto 28px;
}

/* Supercharged Search Input Box */
.search-wrapper {
  max-width: 680px;
  margin: 0 auto;
}

.search-input-box {
  position: relative;
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 14px;
  padding: 4px 8px 4px 16px;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.06), 0 4px 10px -2px rgba(15, 23, 42, 0.03);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-input-box:focus-within {
  border-color: #2563eb;
  box-shadow: 0 12px 28px -4px rgba(37, 99, 235, 0.15), 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.search-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  margin-right: 12px;
  flex-shrink: 0;
}

.search-icon svg {
  width: 20px;
  height: 20px;
}

.search-input-box input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: inherit;
  font-size: 15.5px;
  color: #0f172a;
  padding: 10px 0;
  width: 100%;
}

.search-input-box input::placeholder {
  color: #94a3b8;
  font-size: 14.5px;
}

.search-clear-btn {
  background: #f1f5f9;
  border: none;
  border-radius: 50%;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #64748b;
  cursor: pointer;
  margin-right: 8px;
  transition: all 0.15s ease;
}

.search-clear-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.search-kbd-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 11px;
  color: #64748b;
  user-select: none;
}

.search-kbd-badge kbd {
  font-family: inherit;
  font-weight: 700;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  padding: 1px 5px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.1);
}

/* Status bar & tags */
.search-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
  padding: 0 4px;
}

.search-stats {
  font-size: 12.5px;
  font-weight: 600;
  color: #2563eb;
  background: #eff6ff;
  padding: 3px 10px;
  border-radius: 20px;
}

.popular-tags {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.tags-label {
  font-size: 12px;
  color: #64748b;
  font-weight: 600;
}

.quick-tag {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
}

.quick-tag:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #1d4ed8;
}

/* ==========================================================================
   Category Filter Tabs
   ========================================================================== */
.home-tabs-container {
  margin: 0 auto 36px;
  display: flex;
  justify-content: center;
}

.home-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 6px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.home-tabs button {
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  color: #475569;
  padding: 8px 18px;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.home-tabs button:hover {
  color: #0f172a;
  background-color: #f1f5f9;
}

.home-tabs button[aria-pressed="true"] {
  background: #0f172a;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.2);
}

/* ==========================================================================
   Tool Section & Cards Grid (Matching User's Screenshot)
   ========================================================================== */
.tool-section {
  margin-bottom: 40px;
}

/* Modern Section Header & Accent Bar (Matching Reference Screenshot) */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding: 0 2px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  font-family: 'Outfit', 'Inter', sans-serif;
  letter-spacing: -0.3px;
  margin: 0;
}

.section-title::before {
  content: "";
  width: 5px;
  height: 24px;
  background: linear-gradient(180deg, #f97316, #ea580c);
  border-radius: 3px;
  display: inline-block;
  flex-shrink: 0;
}

.section-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-red { background: #fee2e2; color: #b91c1c; }
.badge-purple { background: #f3e8ff; color: #7e22ce; }
.badge-amber { background: #fef3c7; color: #b45309; }
.badge-teal { background: #ccfbf1; color: #0f766e; }
.badge-violet { background: #ede9fe; color: #6d28d9; }

.section-count {
  font-size: 12px;
  font-weight: 700;
  color: #ea580c;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  padding: 2px 10px;
  border-radius: 12px;
}

/* Modern Multi-Column Grid (Matching Screenshot) */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

/* Tool Card (Exact match to modern visual reference in screenshot) */
.tool-card {
  position: relative;
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 20px;
  padding: 24px 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 12px;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.05);
  transition: transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.22s ease, border-color 0.22s ease;
  text-decoration: none;
  min-height: 165px;
  cursor: pointer;
  user-select: none;
}

.tool-card:hover {
  transform: translateY(-4px);
  border-color: #f97316;
  box-shadow: 0 12px 26px -4px rgba(249, 115, 22, 0.22);
}

/* Modern Centered Icon Badge */
.tool-icon-wrap {
  width: 64px;
  height: 58px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.22s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.tool-icon-wrap svg {
  width: 44px;
  height: 40px;
  display: block;
}

.tool-card:hover .tool-icon-wrap {
  transform: scale(1.12);
  box-shadow: 0 6px 16px rgba(249, 115, 22, 0.16);
}

/* Distinct Icon Color Palettes */
.icon-graphic { background: #f8fafc; border: 1px solid #e2e8f0; }
.icon-red { background: #fee2e2; color: #dc2626; }
.icon-orange { background: #ffedd5; color: #ea580c; }
.icon-blue { background: #dbeafe; color: #2563eb; }
.icon-indigo { background: #e0e7ff; color: #4f46e5; }
.icon-purple { background: #f3e8ff; color: #9333ea; }
.icon-violet { background: #ede9fe; color: #7c3aed; }
.icon-green { background: #dcfce7; color: #16a34a; }
.icon-emerald { background: #d1fae5; color: #059669; }
.icon-teal { background: #ccfbf1; color: #0d9488; }
.icon-cyan { background: #cffafe; color: #0891b2; }
.icon-amber { background: #fef3c7; color: #d97706; }
.icon-rose { background: #ffe4e6; color: #e11d48; }
.icon-sky { background: #e0f2fe; color: #0284c7; }
.icon-fuchsia { background: #fae8ff; color: #c026d3; }
.icon-slate { background: #f1f5f9; color: #475569; }

/* Tool Text Info */
.tool-info {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  width: 100%;
}

.tool-title {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.35;
  letter-spacing: -0.2px;
  font-family: 'Inter', sans-serif;
  margin: 0;
}

.tool-desc {
  font-size: 12px;
  color: #64748b;
  line-height: 1.45;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tool-arrow {
  display: none;
}

/* ==========================================================================
   Empty State (No Search Results)
   ========================================================================== */
.no-tools-box {
  text-align: center;
  padding: 48px 24px;
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 16px;
  max-width: 540px;
  margin: 40px auto;
}

.no-tools-icon {
  font-size: 44px;
  margin-bottom: 12px;
}

.no-tools-box h3 {
  font-size: 19px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}

.no-tools-box p {
  font-size: 14px;
  color: #64748b;
  margin-bottom: 18px;
}

.btn-reset-search {
  background: #2563eb;
  color: #ffffff;
  border: none;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.btn-reset-search:hover {
  background: #1d4ed8;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.home-footer {
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  margin-top: 40px;
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 36px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
}

.footer-brand-col {
  max-width: 480px;
}

.footer-logo {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 6px;
  font-family: 'Outfit', sans-serif;
}

.footer-desc {
  font-size: 13px;
  color: #64748b;
  margin-bottom: 8px;
  line-height: 1.5;
}

.footer-copy {
  font-size: 12px;
  color: #94a3b8;
}

.footer-nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13.5px;
  font-weight: 500;
  color: #475569;
}

.footer-nav a:hover {
  color: #2563eb;
}

/* ==========================================================================
   Dark Theme Overrides
   ========================================================================== */
[data-theme="dark"] body {
  background-color: #0b0f19;
  color: #f1f5f9;
}

[data-theme="dark"] .home-header {
  background: rgba(11, 15, 25, 0.94);
  border-bottom-color: #1e293b;
}

[data-theme="dark"] .brand-title {
  color: #f8fafc;
}

[data-theme="dark"] .brand-sub {
  color: #94a3b8;
}

[data-theme="dark"] .privacy-badge {
  background: #064e3b;
  border-color: #059669;
  color: #a7f3d0;
}

[data-theme="dark"] .nav-link {
  color: #cbd5e1;
}

[data-theme="dark"] .nav-link:hover,
[data-theme="dark"] .nav-link.active {
  background-color: #1e293b;
  color: #60a5fa;
}

[data-theme="dark"] .theme-toggle-btn {
  background: #1e293b;
  border-color: #334155;
  color: #f8fafc;
}

[data-theme="dark"] .quote-card {
  background: linear-gradient(135deg, #111827 0%, #1e293b 100%);
  border-color: #374151;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .quote-top {
  border-bottom-color: #374151;
}

[data-theme="dark"] .quote-heading {
  color: #818cf8;
}

[data-theme="dark"] .quote-date {
  background: #1f2937;
  color: #9ca3af;
}

[data-theme="dark"] .quote-btn {
  background: #1f2937;
  border-color: #374151;
  color: #e2e8f0;
}

[data-theme="dark"] .quote-btn:hover {
  background: #374151;
}

[data-theme="dark"] .quote-hindi {
  color: #f8fafc;
}

[data-theme="dark"] .quote-english {
  color: #94a3b8;
}

[data-theme="dark"] .hero-title {
  color: #f8fafc;
}

[data-theme="dark"] .hero-desc {
  color: #94a3b8;
}

[data-theme="dark"] .search-input-box {
  background: #111827;
  border-color: #374151;
}

[data-theme="dark"] .search-input-box input {
  color: #f8fafc;
}

[data-theme="dark"] .search-kbd-badge {
  background: #1f2937;
  border-color: #374151;
  color: #9ca3af;
}

[data-theme="dark"] .search-kbd-badge kbd {
  background: #111827;
  border-color: #4b5563;
  color: #f3f4f6;
}

[data-theme="dark"] .quick-tag {
  background: #1e293b;
  border-color: #374151;
  color: #cbd5e1;
}

[data-theme="dark"] .home-tabs {
  background: #111827;
  border-color: #1f2937;
}

[data-theme="dark"] .home-tabs button {
  color: #94a3b8;
}

[data-theme="dark"] .home-tabs button:hover {
  background-color: #1f2937;
  color: #f8fafc;
}

[data-theme="dark"] .home-tabs button[aria-pressed="true"] {
  background: #3b82f6;
  color: #ffffff;
}

[data-theme="dark"] .section-title {
  color: #f8fafc;
}

[data-theme="dark"] .tool-card {
  background: #111827;
  border-color: #7c2d12;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .tool-card:hover {
  border-color: #f97316;
  box-shadow: 0 10px 28px -4px rgba(249, 115, 22, 0.3);
}

[data-theme="dark"] .icon-graphic {
  background: #1e293b;
  border-color: #334155;
}

[data-theme="dark"] .tool-title {
  color: #f8fafc;
}

[data-theme="dark"] .tool-desc {
  color: #94a3b8;
}

[data-theme="dark"] .section-count {
  background: #1e293b;
  border-color: #7c2d12;
  color: #fb923c;
}

[data-theme="dark"] .home-footer {
  background: #111827;
  border-top-color: #1f2937;
}

[data-theme="dark"] .footer-logo {
  color: #f8fafc;
}

[data-theme="dark"] .no-tools-box {
  background: #111827;
  border-color: #374151;
}

[data-theme="dark"] .no-tools-box h3 {
  color: #f8fafc;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 1200px) {
  .tool-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
  }
}

@media (max-width: 860px) {
  .tool-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .header-inner {
    padding: 12px 16px;
  }
  .home-layout {
    padding: 20px 16px 48px;
  }
  .quote-top {
    flex-direction: column;
    align-items: flex-start;
  }
  .quote-actions {
    width: 100%;
    justify-content: flex-start;
  }
  .search-kbd-badge {
    display: none;
  }
  .search-status-bar {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 560px) {
  .tool-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .tool-card {
    min-height: 140px;
    padding: 16px 8px 14px;
    border-radius: 16px;
    gap: 8px;
  }
  .tool-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    margin-bottom: 2px;
  }
  .tool-icon-wrap svg {
    width: 24px;
    height: 24px;
  }
  .tool-title {
    font-size: 13px;
  }
  .tool-desc {
    font-size: 11px;
    line-height: 1.35;
  }
  .header-nav {
    display: none;
  }
  .privacy-badge {
    display: none;
  }
  .home-tabs {
    border-radius: 16px;
    justify-content: flex-start;
    overflow-x: auto;
    padding: 6px;
    width: 100%;
    -webkit-overflow-scrolling: touch;
  }
  .home-tabs button {
    padding: 6px 14px;
    font-size: 12.5px;
  }
  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ==========================================================================
   Smart PDF & Image Tools Quick Navigation Carousel / Grid
   ========================================================================== */
.smart-pdf-quick-section {
  margin: 12px 0 32px 0;
  padding: 0;
}

.smart-pdf-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.smart-pdf-bar {
  width: 5px;
  height: 24px;
  background: linear-gradient(180deg, #f97316, #ea580c);
  border-radius: 3px;
  display: inline-block;
  flex-shrink: 0;
}

.smart-pdf-group-title {
  margin: 20px 0 12px;
  font-size: 1rem;
  font-weight: 700;
  color: inherit;
}

.smart-pdf-title {
  font-family: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.3px;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.smart-pdf-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.smart-pdf-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 20px;
  padding: 22px 10px 18px;
  text-decoration: none;
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.2s ease, border-color 0.2s ease;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.05);
  cursor: pointer;
  user-select: none;
  min-height: 140px;
}

.smart-pdf-card:hover {
  transform: translateY(-4px);
  border-color: #f97316;
  box-shadow: 0 10px 24px -4px rgba(249, 115, 22, 0.22);
}

.smart-pdf-card:focus-visible {
  outline: 3px solid #fdba74;
  outline-offset: 2px;
}

.smart-pdf-icons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
  height: 48px;
}

.smart-pdf-icons svg {
  width: 40px;
  height: 44px;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.smart-pdf-card:hover .smart-pdf-icons svg {
  transform: scale(1.08);
}

.smart-pdf-label {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.2px;
  line-height: 1.3;
  margin: 0;
}

/* Dark Theme Overrides */
[data-theme="dark"] .smart-pdf-title {
  color: #f8fafc;
}

[data-theme="dark"] .smart-pdf-card {
  background: #111827;
  border-color: #7c2d12;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .smart-pdf-card:hover {
  border-color: #f97316;
  box-shadow: 0 10px 28px -4px rgba(249, 115, 22, 0.3);
}

[data-theme="dark"] .smart-pdf-label {
  color: #f1f5f9;
}

/* Responsive */
@media (max-width: 1100px) {
  .smart-pdf-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
  }
}

@media (max-width: 640px) {
  .smart-pdf-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .smart-pdf-card {
    padding: 16px 8px 14px;
    border-radius: 16px;
    min-height: 120px;
  }
  .smart-pdf-icons {
    gap: 8px;
    height: 38px;
    margin-bottom: 8px;
  }
  .smart-pdf-icons svg {
    width: 32px;
    height: 36px;
  }
  .smart-pdf-label {
    font-size: 12.5px;
  }
}
