/* ==========================================================================
   DigiAi Dhairya - AI Tools Directory V2 Stylesheet
   Theme: Premium AI SaaS Deep Midnight Navy & Clean Light Mode
   Benchmarks: Linear, Vercel, Framer, Perplexity, Notion
   ========================================================================== */

@import url('design-system.css');

:root {
  --primary-glow: #3b82f6;
  --secondary-glow: #06b6d4;
  --accent-violet: #8b5cf6;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #ef4444;

  /* Dark Theme (Default) */
  --bg-base: #070a12;
  --bg-surface: #0c1220;
  --bg-surface-hover: #111a2e;
  --bg-card: #0c1220;
  --bg-input: rgba(15, 23, 42, 0.8);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glass: rgba(255, 255, 255, 0.14);
  --border-focus: #3b82f6;
  --border-glow: rgba(59, 130, 246, 0.35);
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --badge-bg: rgba(255, 255, 255, 0.05);
  --shadow-card: 0 4px 20px -2px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 0 20px rgba(59, 130, 246, 0.25);
  --shadow-hover: 0 12px 32px -4px rgba(0, 0, 0, 0.6), 0 0 20px rgba(59, 130, 246, 0.15);
  --font-body: 'Plus Jakarta Sans', 'Inter', -apple-system, sans-serif;
  --font-heading: 'Outfit', 'Plus Jakarta Sans', sans-serif;
}

[data-theme="light"] {
  --bg-base: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-hover: #f1f5f9;
  --bg-card: #ffffff;
  --bg-input: #ffffff;
  --border-subtle: #e2e8f0;
  --border-glass: #cbd5e1;
  --border-focus: #3b82f6;
  --border-glow: rgba(59, 130, 246, 0.25);
  --text-primary: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --badge-bg: #f1f5f9;
  --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.06);
  --shadow-glow: 0 4px 15px rgba(59, 130, 246, 0.15);
  --shadow-hover: 0 12px 28px -4px rgba(15, 23, 42, 0.12), 0 0 15px rgba(59, 130, 246, 0.1);
}

/* Reset & Scaffolding */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body.directory-body {
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  transition: background-color 0.25s ease, color 0.25s ease;
  -webkit-font-smoothing: antialiased;
}

/* Container */
.dir-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
}

@media (max-width: 640px) {
  .dir-container {
    padding: 0 1rem;
  }
}

/* Navbar */
.dir-navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-surface);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.75rem 0;
  transition: all 0.25s ease;
}

.dir-nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.dir-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-primary);
}

.dir-brand-logo {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.dir-nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.dir-nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dir-nav-link:hover, .dir-nav-link.active {
  color: var(--primary-glow);
}

.dir-nav-badge {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
  line-height: 1;
}

.dir-nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.dir-btn-icon {
  background: var(--badge-bg);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.95rem;
  transition: all 0.2s ease;
}

.dir-btn-icon:hover {
  border-color: var(--primary-glow);
  color: var(--primary-glow);
}

.dir-lang-select {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 0.45rem 0.75rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
}

.dir-lang-select:focus {
  border-color: var(--primary-glow);
}

/* Hero Section */
.dir-hero {
  padding: 3.5rem 0 2.5rem;
  text-align: center;
  position: relative;
}

.dir-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.25);
  color: #60a5fa;
  padding: 0.35rem 1rem;
  border-radius: 9999px;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.dir-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4.5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 30%, #60a5fa 70%, #06b6d4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

[data-theme="light"] .gradient-text {
  background: linear-gradient(135deg, #0f172a 30%, #2563eb 70%, #0891b2 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.dir-hero p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  max-width: 680px;
  margin: 0 auto 2rem;
}

/* Search Bar Wrapper */
.dir-search-box {
  max-width: 780px;
  margin: 0 auto;
  position: relative;
}

.dir-search-input-wrap {
  display: flex;
  align-items: center;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 0.5rem 0.75rem 0.5rem 1.25rem;
  box-shadow: var(--shadow-card);
  transition: all 0.25s ease;
}

.dir-search-input-wrap:focus-within {
  border-color: var(--primary-glow);
  box-shadow: var(--shadow-glow), 0 0 0 3px rgba(59, 130, 246, 0.25);
}

.dir-search-icon {
  color: var(--text-muted);
  font-size: 1.15rem;
  margin-right: 0.85rem;
}

.dir-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-size: 1.05rem;
  color: var(--text-primary);
  font-family: inherit;
}

.dir-search-input::placeholder {
  color: var(--text-muted);
}

.dir-search-clear {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.4rem;
  display: none;
}

.dir-search-clear.active {
  display: block;
}

/* Task Finder Section */
.dir-task-finder-section {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 1.75rem 2rem;
  margin: 1.5rem 0 2rem;
  box-shadow: var(--shadow-card);
}

.dir-task-finder-header {
  margin-bottom: 1.25rem;
}

.dir-task-finder-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-primary);
}

.dir-task-finder-sub {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

.dir-tasks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}

.dir-task-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-align: left;
  font-size: 0.88rem;
  font-weight: 600;
  transition: all 0.2s ease;
  user-select: none;
  font-family: var(--font-body);
}

.dir-task-btn:hover {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
  border-color: rgba(59, 130, 246, 0.4);
  transform: translateY(-2px);
}

.dir-task-btn.active {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.2), rgba(59, 130, 246, 0.2));
  border-color: var(--primary-glow);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

[data-theme="light"] .dir-task-btn.active {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #3b82f6;
}

.dir-task-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--badge-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.95rem;
}

/* Active Task Filter Banner */
.dir-active-task-banner {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid var(--border-glow);
  color: var(--text-primary);
  padding: 0.75rem 1.25rem;
  border-radius: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  font-size: 0.92rem;
}

.dir-btn-clear-task {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: #fff;
  padding: 0.35rem 0.75rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.2s;
  font-family: var(--font-body);
}

.dir-btn-clear-task:hover {
  background: var(--accent-rose);
  border-color: var(--accent-rose);
}

/* Category Filter Slider */
.dir-categories-section {
  padding: 1.5rem 0 0.5rem;
}

.dir-cat-pills {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  padding: 0.5rem 0 1rem;
  scrollbar-width: thin;
  scrollbar-color: var(--border-subtle) transparent;
}

.dir-cat-pills::-webkit-scrollbar {
  height: 6px;
}

.dir-cat-pills::-webkit-scrollbar-thumb {
  background: var(--border-subtle);
  border-radius: 10px;
}

.dir-cat-pill {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.dir-cat-pill:hover {
  background: var(--bg-surface-hover);
  color: var(--text-primary);
  border-color: rgba(59, 130, 246, 0.4);
}

.dir-cat-pill.active {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.25), rgba(59, 130, 246, 0.25));
  border-color: var(--primary-glow);
  color: #fff;
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.25);
}

[data-theme="light"] .dir-cat-pill.active {
  color: #1d4ed8;
  background: #eff6ff;
  border-color: #3b82f6;
}

/* Filter Controls Bar */
.dir-controls-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 2rem;
}

.dir-stats-count {
  font-size: 0.95rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.dir-stats-count span {
  color: var(--primary-glow);
  font-weight: 700;
}

.dir-filters-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.dir-select {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 0.5rem 0.85rem;
  border-radius: 10px;
  font-size: 0.86rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s ease;
}

.dir-select:focus {
  border-color: var(--primary-glow);
}

.dir-btn-reset {
  background: transparent;
  border: 1px dashed var(--border-subtle);
  color: var(--text-muted);
  padding: 0.5rem 0.85rem;
  border-radius: 10px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.dir-btn-reset:hover {
  border-color: var(--accent-rose);
  color: var(--accent-rose);
}

/* Tools Grid */
.dir-tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 1.5rem;
}

/* Tool Card */
.dir-tool-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.dir-tool-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-hover);
}

.dir-tool-info {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.dir-tool-name-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.35rem;
}

.dir-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.dir-tool-logo-wrap {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}

[data-theme="light"] .dir-tool-logo-wrap {
  background: #f8fafc;
}

.dir-tool-logo {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.dir-card-badges {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.35rem;
}

.dir-badge-price {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.badge-free {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-freemium {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-paid {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.badge-trial {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.dir-badge-featured {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.dir-tool-name {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.dir-verified-icon {
  color: var(--accent-emerald);
  font-size: 0.95rem;
}

.dir-tool-tagline {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.dir-tool-meta-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.dir-meta-tag {
  background: var(--badge-bg);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.75rem;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.dir-card-pro-snippet {
  font-size: 0.82rem;
  color: var(--accent-emerald);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dir-card-footer,
.dir-card-actions {
  margin-top: auto;
  display: flex;
  gap: 0.6rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
  width: 100%;
}

.dir-btn-explore {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, #8b5cf6, #3b82f6);
  color: #ffffff !important;
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.25s ease;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.25);
}

.dir-btn-explore:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.45);
  color: #ffffff !important;
}

.dir-btn-explore i {
  transition: transform 0.2s ease;
  font-size: 0.85rem;
}

.dir-btn-explore:hover i {
  transform: translateX(3px);
}

.dir-meta-tag.inr-friendly {
  color: #10b981 !important;
  border-color: rgba(16, 185, 129, 0.3) !important;
  background: rgba(16, 185, 129, 0.08) !important;
}

.dir-btn-details {
  flex: 1;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  text-decoration: none;
  padding: 0.6rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  transition: all 0.2s ease;
}

.dir-btn-details:hover {
  background: var(--bg-surface-hover);
  border-color: var(--border-glass);
  color: var(--primary-glow);
}

.dir-btn-outbound {
  background: linear-gradient(135deg, #8b5cf6, #3b82f6);
  color: #fff;
  border: none;
  text-decoration: none;
  padding: 0.6rem 0.85rem;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

.dir-btn-outbound:hover {
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
  transform: translateY(-1px);
}

/* ==========================================================================
   Tool Detail Page Styling
   ========================================================================== */
.dir-detail-wrap {
  padding: 2.5rem 1.5rem 5rem;
}

.dir-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.dir-breadcrumb a {
  color: var(--text-secondary);
  text-decoration: none;
}

.dir-breadcrumb a:hover {
  color: var(--primary-glow);
}

.dir-lang-notice-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.82rem;
  padding: 0.35rem 0.85rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.dir-detail-header {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  padding: 2.25rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow-card);
}

.dir-detail-main-info {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.dir-detail-logo-wrap {
  width: 76px;
  height: 76px;
  border-radius: 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: var(--shadow-card);
}

.dir-detail-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
}

.dir-detail-title-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.35rem;
}

.dir-detail-h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 800;
  color: var(--text-primary);
}

.dir-detail-tagline {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  max-width: 600px;
}

.dir-tool-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dir-detail-cta-box {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.6rem;
  flex-shrink: 0;
}

.dir-btn-primary-outbound {
  background: linear-gradient(135deg, #8b5cf6, #3b82f6);
  color: #fff;
  text-decoration: none;
  padding: 0.85rem 1.6rem;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.35);
  transition: all 0.25s ease;
}

.dir-btn-primary-outbound:hover {
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
  transform: translateY(-2px);
}

.dir-verified-date {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Detail Grid Layout */
.dir-detail-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 2.5rem;
  align-items: flex-start;
}

.dir-content-block {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 2rem 2.25rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-card);
}

.dir-content-block h2 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.dir-overview-text {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.dir-features-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.dir-features-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  font-size: 0.94rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.dir-feature-icon {
  color: var(--accent-emerald);
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.dir-pros-cons-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.dir-pros-box, .dir-cons-box {
  background: var(--bg-surface);
  border-radius: 14px;
  padding: 1.5rem;
  border: 1px solid var(--border-subtle);
}

.dir-pros-box {
  border-left: 3px solid var(--accent-emerald);
}

.dir-cons-box {
  border-left: 3px solid var(--accent-amber);
}

.dir-box-title {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dir-pros-title { color: var(--accent-emerald); }
.dir-cons-title { color: var(--accent-amber); }

.dir-pros-list, .dir-cons-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.dir-pros-list li, .dir-cons-list li {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  position: relative;
  padding-left: 1.25rem;
}

.dir-pros-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent-emerald);
  font-weight: bold;
}

.dir-cons-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--accent-amber);
  font-weight: bold;
}

.dir-steps-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  counter-reset: step-counter;
}

.dir-step-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  background: var(--bg-surface);
  padding: 1rem 1.25rem;
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
}

.dir-step-num {
  counter-increment: step-counter;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #8b5cf6, #3b82f6);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dir-step-num::before {
  content: counter(step-counter);
}

.dir-step-content {
  font-size: 0.94rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* FAQs */
.dir-faq-item {
  border-bottom: 1px solid var(--border-subtle);
  padding: 1rem 0;
}

.dir-faq-item:last-child {
  border-bottom: none;
}

.dir-faq-question {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  margin-bottom: 0.4rem;
}

.dir-faq-answer {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Sidebar Box */
.dir-sidebar-box {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 18px;
  padding: 1.75rem;
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-card);
}

.dir-sidebar-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.dir-pricing-desc {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.5;
}

.dir-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.6rem 0;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.88rem;
}

.dir-personas-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dir-persona-tag {
  background: var(--badge-bg);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.35rem 0.75rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 500;
}

/* India Highlights Box */
.dir-india-highlights-box {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(16, 185, 129, 0.08));
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 16px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.dir-india-highlights-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.dir-india-highlights-text {
  font-size: 0.94rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Editorial Disclosure Banner */
.dir-disclosure-banner {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 3rem 0;
  text-align: center;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.dir-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 4rem 0 2rem;
  background: #050810;
  margin-top: auto;
}

[data-theme="light"] .dir-footer {
  background: #f1f5f9;
}

.dir-footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.dir-footer-brand h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.dir-footer-col h4 {
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
}

.dir-footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.dir-footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.dir-footer-links a:hover {
  color: var(--primary-glow);
}

.dir-footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 1024px) {
  .dir-detail-grid {
    grid-template-columns: 1fr;
  }

  .dir-footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .dir-nav-links {
    display: none;
  }

  .dir-nav-content {
    gap: 0.5rem;
  }

  .dir-logo {
    gap: 0.5rem;
    min-width: 0;
  }

  .dir-brand-logo {
    height: 32px;
    max-width: 135px;
    width: auto;
  }

  .dir-nav-actions {
    gap: 0.4rem;
    flex-shrink: 0;
  }

  .dir-btn-icon {
    width: 34px;
    height: 34px;
    font-size: 0.85rem;
    border-radius: 8px;
  }

  .dir-lang-select {
    padding: 0.35rem 0.45rem;
    font-size: 0.78rem;
    border-radius: 8px;
    max-width: 105px;
  }

  .dir-detail-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .dir-detail-cta-box {
    align-items: flex-start;
    width: 100%;
  }

  .dir-btn-primary-outbound {
    width: 100%;
    justify-content: center;
  }

  .dir-features-list {
    grid-template-columns: 1fr;
  }

  .dir-pros-cons-grid {
    grid-template-columns: 1fr;
  }

  .dir-footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (max-width: 480px) {
  .dir-container {
    padding: 0 0.75rem;
  }

  .dir-brand-logo {
    height: 28px;
    max-width: 115px;
  }

  .dir-nav-actions {
    gap: 0.3rem;
  }

  .dir-btn-icon {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }

  .dir-lang-select {
    padding: 0.3rem 0.35rem;
    font-size: 0.75rem;
    max-width: 85px;
  }
}


/* ==========================================================================
   DIGIAI DHAIRYA - V1.3 SAVED TOOLS (LOCALSTORAGE) STYLES
   ========================================================================== */

/* Navbar Saved Tools Trigger & Counter Badge */
.dir-btn-saved {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.dir-saved-badge,
.dir-saved-count-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--primary-glow, #9d4edd);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: 9999px;
  padding: 1px 5px;
  min-width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 0 8px rgba(157, 78, 221, 0.5);
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Card Bookmark Button */
.dir-btn-save {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
  color: var(--text-muted, #94a3b8);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  transition: all 0.2s ease;
  margin-left: auto;
}

.dir-btn-save:hover {
  color: var(--primary-glow, #9d4edd);
  border-color: var(--primary-glow, #9d4edd);
  background: rgba(157, 78, 221, 0.12);
  transform: translateY(-1px);
}

.dir-btn-save.is-saved {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.12);
}

.dir-btn-save.is-saved i {
  color: #f59e0b;
}

/* Detail Page Save Button */
.dir-btn-save-detail {
  background: var(--badge-bg, rgba(255, 255, 255, 0.05));
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.15));
  color: var(--text-primary, #f8fafc);
  padding: 0.55rem 1.1rem;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.dir-btn-save-detail:hover {
  background: rgba(157, 78, 221, 0.15);
  border-color: var(--primary-glow, #9d4edd);
  color: #ffffff;
}

.dir-btn-save-detail.is-saved {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.12);
}

/* Saved Tools Modal */
.saved-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: fadeInModal 0.2s ease-out;
}

@keyframes fadeInModal {
  from { opacity: 0; }
  to { opacity: 1; }
}

.saved-modal-card {
  background: var(--bg-surface, #111827);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.15));
  border-radius: 16px;
  width: 100%;
  max-width: 580px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6), 0 0 30px rgba(157, 78, 221, 0.15);
  overflow: hidden;
  animation: slideUpModal 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUpModal {
  from { transform: translateY(16px) scale(0.98); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.saved-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.1));
}

.saved-modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary, #ffffff);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.saved-modal-subtitle {
  font-size: 0.82rem;
  color: var(--text-muted, #94a3b8);
  margin: 0.3rem 0 0 0;
  line-height: 1.4;
}

.saved-modal-close {
  background: transparent;
  border: none;
  font-size: 1.75rem;
  color: var(--text-muted, #94a3b8);
  cursor: pointer;
  line-height: 1;
  padding: 0 0.25rem;
  transition: color 0.2s ease;
}

.saved-modal-close:hover {
  color: var(--text-primary, #ffffff);
}

.saved-tools-list {
  padding: 1.25rem 1.5rem;
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-height: 52vh;
}

.saved-empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--text-muted, #94a3b8);
}

.saved-empty-icon {
  font-size: 2.8rem;
  color: var(--text-muted, #64748b);
  margin-bottom: 1rem;
  opacity: 0.6;
}

.saved-empty-text {
  font-size: 0.92rem;
  line-height: 1.6;
  max-width: 360px;
  margin: 0 auto;
}

.saved-tool-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  border-radius: 12px;
  transition: all 0.2s ease;
}

.saved-tool-item:hover {
  border-color: rgba(157, 78, 221, 0.3);
  background: rgba(157, 78, 221, 0.04);
}

.saved-tool-left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
  flex: 1;
}

.saved-tool-logo {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: contain;
  background: #ffffff;
  padding: 2px;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.saved-tool-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 0.15rem;
}

.saved-tool-name {
  font-weight: 600;
  color: var(--text-primary, #ffffff);
  text-decoration: none;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.2s ease;
}

.saved-tool-name:hover {
  color: var(--primary-glow, #c77dff);
}

.saved-tool-sub {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.saved-tool-category {
  font-size: 0.76rem;
  color: var(--text-muted, #94a3b8);
}

.saved-tool-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.saved-btn-open {
  background: rgba(157, 78, 221, 0.15);
  border: 1px solid rgba(157, 78, 221, 0.35);
  color: #c77dff;
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.2s ease;
}

.saved-btn-open:hover {
  background: var(--primary-glow, #9d4edd);
  color: #ffffff;
  border-color: var(--primary-glow, #9d4edd);
}

.saved-btn-remove {
  background: transparent;
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
  color: var(--text-muted, #94a3b8);
  padding: 0.4rem 0.65rem;
  border-radius: 8px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.saved-btn-remove:hover {
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.1);
}

.saved-modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1.5rem;
  border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.1));
  background: rgba(0, 0, 0, 0.2);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.saved-privacy-notice {
  font-size: 0.74rem;
  color: var(--text-muted, #94a3b8);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.saved-modal-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.saved-btn-clear {
  background: transparent;
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #ef4444;
  padding: 0.45rem 0.9rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.saved-btn-clear:hover {
  background: rgba(239, 68, 68, 0.12);
  border-color: #ef4444;
}

.saved-btn-done {
  background: var(--primary-glow, #9d4edd);
  border: none;
  color: #ffffff;
  padding: 0.45rem 1.1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.saved-btn-done:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 12px rgba(157, 78, 221, 0.4);
}

/* Light Theme Overrides */
[data-theme="light"] .saved-modal-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

[data-theme="light"] .saved-modal-header {
  border-bottom-color: #e2e8f0;
}

[data-theme="light"] .saved-modal-footer {
  border-top-color: #e2e8f0;
  background: #f8fafc;
}

[data-theme="light"] .saved-tool-item {
  background: #f8fafc;
  border-color: #e2e8f0;
}

[data-theme="light"] .saved-tool-item:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

[data-theme="light"] .dir-btn-save {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #64748b;
}

[data-theme="light"] .dir-btn-save.is-saved {
  background: #fef3c7;
  border-color: #f59e0b;
  color: #d97706;
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
  .saved-modal-card {
    max-height: 90vh;
  }
  .saved-modal-header,
  .saved-tools-list,
  .saved-modal-footer {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .saved-tool-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  .saved-tool-right {
    width: 100%;
    justify-content: flex-end;
  }
  .saved-modal-footer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  .saved-privacy-notice {
    justify-content: center;
  }
  .saved-modal-actions {
    justify-content: space-between;
  }
}
