/* 
   n8nu.online - Modern CSS Stylesheet
   Updated: Horizontal scroll fixed, mobile responsive, new sections added
*/

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

:root {
  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-tertiary: #f1f5f9;

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;

  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --accent: #ff6b4a;
  --accent-hover: #e04f2f;
  --accent-light: #ff6b4a15;

  --border-color: rgba(15, 23, 42, 0.08);
  --card-shadow: 0 10px 40px -10px rgba(99, 102, 241, 0.05), 0 1px 3px rgba(0, 0, 0, 0.01);
  --header-blur: rgba(248, 250, 252, 0.85);

  --code-bg: #11131c;
  --code-text: #cdd6f4;

  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;

  --transition-speed: 0.3s;
}

[data-theme="dark"] {
  --bg-primary: #090a0f;
  --bg-secondary: #11131c;
  --bg-tertiary: #1b1e2a;

  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;

  --primary: #818cf8;
  --primary-hover: #6366f1;
  --accent: #ff7e62;
  --accent-hover: #ff6b4a;
  --accent-light: #ff7e621f;

  --border-color: rgba(255, 255, 255, 0.08);
  --card-shadow: 0 20px 50px -12px rgba(0, 0, 0, 0.5), 0 1px 2px rgba(255, 255, 255, 0.02);
  --header-blur: rgba(9, 10, 15, 0.85);
}

/* ============================================
   CRITICAL: HORIZONTAL SCROLL FIX
   ============================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden; /* ROOT level fix */
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-secondary);
  line-height: 1.6;
  overflow-x: hidden; /* body level fix */
  max-width: 100vw;   /* prevent body from exceeding viewport */
  transition: background-color var(--transition-speed), color var(--transition-speed);
}

/* All direct block elements must not overflow */
section, header, footer, main, nav, div, article, aside {
  max-width: 100%;
}

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

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.25;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-speed), opacity var(--transition-speed);
}

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

ul {
  list-style: none;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.6rem;
  border-radius: 50px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  gap: 0.5rem;
  white-space: nowrap; /* prevent button text wrapping strangely */
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #4f46e5);
  color: white;
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--primary-hover), #4338ca);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -6px rgba(99, 102, 241, 0.4);
}

.btn-secondary {
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: var(--border-color);
  color: var(--text-primary);
  transform: translateY(-2px);
}

.btn-accent {
  background: linear-gradient(135deg, var(--accent), #f95738);
  color: white;
}

.btn-accent:hover {
  background: linear-gradient(135deg, var(--accent-hover), #e03e1e);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -6px rgba(255, 107, 74, 0.4);
}

/* CTA banner buttons */
.btn-white {
  background: #fff;
  color: #4f46e5;
  border: none;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all var(--transition-speed);
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  color: #4f46e5;
}

.btn-outline-white {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.6);
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all var(--transition-speed);
}

.btn-outline-white:hover {
  background: rgba(255,255,255,0.15);
  color: #fff;
  transform: translateY(-2px);
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: var(--header-blur);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: background-color var(--transition-speed), border var(--transition-speed);
}

.navbar {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--text-primary);
  flex-shrink: 0; /* logo kabhi shrink na ho */
}

.logo span {
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  padding: 0.25rem 0;
  white-space: nowrap;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent);
  transition: width var(--transition-speed);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.theme-toggle {
  background: none;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  font-size: 1.25rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg-tertiary);
  transition: all var(--transition-speed);
  flex-shrink: 0;
}

.theme-toggle:hover {
  transform: scale(1.05);
  background-color: var(--border-color);
}

/* Mobile Menu Button */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1100;
  padding: 4px;
  flex-shrink: 0;
}

.menu-toggle span {
  display: block;
  width: 28px;
  height: 3px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-speed);
}

/* ============================================
   AD SLOTS
   ============================================ */
.ad-wrapper {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.ad-slot {
  width: 100%;
  min-height: 90px;
  background-color: var(--bg-tertiary);
  border: 1px dashed var(--border-color);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  text-align: center;
  overflow: hidden;
}

.ad-slot::before {
  content: 'Sponsored Advertisement';
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.25rem;
}

.ad-slot-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.ad-slot-code {
  font-family: monospace;
  font-size: 0.75rem;
  margin-top: 0.25rem;
  color: var(--text-muted);
}

/* ============================================
   MAIN LAYOUT
   ============================================ */
main {
  margin-top: 80px;
  min-height: calc(100vh - 80px - 300px);
  width: 100%;
  overflow-x: hidden;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  padding: 6rem 2rem 4rem;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  /* Dot grid — contained, won't overflow */
  background-image:
    radial-gradient(var(--border-color) 1px, transparent 1px),
    radial-gradient(var(--border-color) 1px, transparent 1px);
  background-size: 24px 24px;
  background-position: 0 0, 12px 12px;
}

.hero::after {
  content: '';
  position: absolute;
  top: 10%;
  right: 0; /* was -5%, caused overflow */
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.12) 0%, transparent 70%);
  filter: blur(40px);
  z-index: 0;
  pointer-events: none;
}

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

.hero-content h1 {
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1.5rem;
  line-height: 1.15;
}

.hero-content h1 span {
  background: linear-gradient(135deg, var(--accent), #f95738);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content p {
  font-size: 1.15rem;
  line-height: 1.75;
  color: var(--text-secondary);
  margin-bottom: 2.25rem;
  max-width: 560px;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
  min-width: 0; /* critical: prevents grid blowout */
}

.hero-card {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 24px;
  padding: 2rem;
  box-shadow: var(--card-shadow);
  position: relative;
  overflow: hidden;
  min-width: 0;
}

.hero-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, var(--accent-light) 0%, transparent 70%);
  z-index: 0;
  pointer-events: none;
}

.hero-card-inner {
  position: relative;
  z-index: 1;
}

/* ============================================
   BADGE
   ============================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.85rem;
  background-color: var(--accent-light);
  color: var(--accent);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
}

/* ============================================
   SECTIONS — shared layout
   ============================================ */
.section {
  padding: 5rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

/* When section is used as a full-width background wrapper */
section.section,
section[style*="background-color"],
section[style*="border-top"] {
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
}

/* Inner content limiter for full-width sections */
section.section > *:not(.section-header),
section[style*="background-color"] > .section,
section[style*="background-color"] > .grid-3,
section[style*="background-color"] > .grid-2 {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 2rem;
  padding-right: 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
  padding: 0 1rem;
}

.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
}

.section-header p {
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

/* ============================================
   GRIDS
   ============================================ */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: var(--card-shadow);
  transition: all var(--transition-speed) cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  min-width: 0; /* grid blowout prevention */
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 30px 60px -15px rgba(99, 102, 241, 0.15);
  border-color: var(--primary);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background-color: var(--accent-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  flex-shrink: 0;
}

.card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.card-link {
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.95rem;
  margin-top: auto;
}

.card-link span {
  transition: transform var(--transition-speed);
}

.card-link:hover span {
  transform: translateX(4px);
}

/* ============================================
   BLOG CARDS
   ============================================ */
.blog-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0;
}

.blog-img {
  height: 190px;
  background-color: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
  border-radius: 20px 20px 0 0;
  flex-shrink: 0;
}

.blog-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-speed);
}

.blog-card:hover .blog-img img {
  transform: scale(1.05);
}

.blog-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.blog-content h3 {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.blog-content p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

/* ============================================
   STATS STRIP
   ============================================ */
.stats-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem 3rem;
  padding: 2.5rem 2rem;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-primary);
  width: 100%;
}

.stat-item {
  text-align: center;
  min-width: 110px;
}

.stat-number {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
  font-family: var(--font-heading);
}

.stat-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  font-weight: 500;
}

/* ============================================
   HOW IT WORKS — STEPS
   ============================================ */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.step-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  transition: all var(--transition-speed);
  min-width: 0;
}

.step-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--card-shadow);
}

.step-number {
  font-size: 4rem;
  font-weight: 800;
  color: var(--primary);
  opacity: 0.08;
  position: absolute;
  top: -0.5rem;
  right: 0.75rem;
  line-height: 1;
  font-family: var(--font-heading);
  pointer-events: none;
  user-select: none;
}

.step-icon {
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
}

.step-card h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.step-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   INTEGRATIONS BADGES
   ============================================ */
.integrations-section {
  padding: 3rem 2rem;
  text-align: center;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-secondary);
  width: 100%;
}

.integrations-section-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.integrations-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.integrations-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  max-width: 900px;
  margin: 0 auto;
}

.integration-badge {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 0.45rem 0.9rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: all var(--transition-speed);
}

.integration-badge:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
}

/* ============================================
   USE CASES
   ============================================ */
.usecase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.usecase-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  transition: all var(--transition-speed);
  min-width: 0;
}

.usecase-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--card-shadow);
}

.usecase-icon-wrap {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.usecase-card h4 {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}

.usecase-card p {
  font-size: 0.87rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* ============================================
   VIDEO CARDS
   ============================================ */
.video-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.video-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  transition: all var(--transition-speed);
  min-width: 0;
}

.video-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow);
  border-color: var(--primary);
}

.video-thumb {
  position: relative;
  background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%);
  height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.video-play-btn {
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  border: 2px solid rgba(255,255,255,0.4);
  color: #fff;
  transition: all var(--transition-speed);
}

.video-card:hover .video-play-btn {
  background: rgba(255,255,255,0.35);
  transform: scale(1.1);
}

.video-duration {
  position: absolute;
  bottom: 8px;
  right: 10px;
  font-size: 0.75rem;
  background: rgba(0,0,0,0.7);
  color: #fff;
  padding: 2px 7px;
  border-radius: 5px;
}

.video-info {
  padding: 1rem 1.25rem;
}

.video-info h4 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  line-height: 1.45;
}

.video-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ============================================
   COMPARISON TABLE
   ============================================ */
.comparison-wrapper {
  overflow-x: auto;   /* horizontal scroll ONLY inside table, not whole page */
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border-color);
  border-radius: 16px;
  width: 100%;
}

.comparison-table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  background: var(--bg-secondary);
}

.comparison-table th {
  padding: 1rem 1.25rem;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 700;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-tertiary);
  font-family: var(--font-heading);
  color: var(--text-primary);
  white-space: nowrap;
}

.comparison-table th:first-child {
  text-align: left;
}

.comparison-table td {
  padding: 0.85rem 1.25rem;
  text-align: center;
  font-size: 0.88rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
  vertical-align: middle;
}

.comparison-table td:first-child {
  text-align: left;
  font-weight: 500;
  color: var(--text-primary);
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

.comparison-table tbody tr:hover {
  background: var(--bg-tertiary);
}

.check-yes  { color: #10b981; font-size: 1.1rem; font-weight: 700; }
.check-no   { color: #ef4444; font-size: 1.1rem; font-weight: 700; }
.check-partial { color: #f59e0b; font-size: 0.85rem; font-weight: 600; }

.highlighted-col { background: rgba(99, 102, 241, 0.05); }
.n8n-header { color: #6366f1 !important; }

/* ============================================
   TIPS / PRO TIPS
   ============================================ */
.tips-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.tip-card {
  background: var(--bg-primary);
  border-left: 4px solid var(--primary);
  border-top: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  border-radius: 0 14px 14px 0;
  padding: 1.25rem 1.5rem;
  transition: all var(--transition-speed);
  min-width: 0;
}

.tip-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--card-shadow);
  border-left-color: var(--accent);
}

.tip-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 5px;
  background: rgba(99,102,241,0.1);
  color: var(--primary);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.tip-card h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
  line-height: 1.4;
}

.tip-card p {
  font-size: 0.87rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.tip-card p code {
  background: var(--bg-tertiary);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.82em;
  color: var(--accent);
  font-family: monospace;
  word-break: break-all;
}

/* ============================================
   TESTIMONIALS
   ============================================ */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.testimonial-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.75rem;
  transition: all var(--transition-speed);
  min-width: 0;
}

.testimonial-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--card-shadow);
}

.testimonial-stars {
  color: #f59e0b;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  letter-spacing: 2px;
}

.testimonial-text {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: 1.25rem;
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.testimonial-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: #fff;
  flex-shrink: 0;
}

.testimonial-author-info strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.testimonial-author-info span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ============================================
   CTA BANNER
   ============================================ */
.cta-banner {
  background: linear-gradient(135deg, #312e81 0%, #4f46e5 50%, #7c3aed 100%);
  border-radius: 24px;
  padding: 3.5rem 2.5rem;
  text-align: center;
  margin: 0 auto;
  max-width: 900px;
  color: #fff;
  width: 100%;
}

.cta-banner h2 {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 1rem;
  color: #fff;
  line-height: 1.2;
}

.cta-banner p {
  font-size: 1.05rem;
  opacity: 0.85;
  margin-bottom: 2rem;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.cta-banner-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

/* ============================================
   ARTICLE / BLOG POST
   ============================================ */
.article-container {
  max-width: 800px;
  margin: 3rem auto;
  padding: 0 2rem;
  width: 100%;
}

.article-header {
  margin-bottom: 2.5rem;
}

.article-header h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  margin-bottom: 1rem;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1.5rem;
}

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

.article-body h2 {
  font-size: 1.75rem;
  margin: 2.5rem 0 1rem;
}

.article-body h3 {
  font-size: 1.35rem;
  margin: 1.8rem 0 1rem;
}

.article-body p {
  margin-bottom: 1.5rem;
}

.article-body ul, .article-body ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.article-body li {
  margin-bottom: 0.5rem;
}

.article-body code {
  background-color: var(--bg-tertiary);
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-family: monospace;
  font-size: 0.9em;
  color: var(--accent);
  word-break: break-all;
}

.article-body pre {
  background-color: var(--code-bg);
  color: var(--code-text);
  padding: 1.5rem;
  border-radius: 10px;
  overflow-x: auto; /* scroll only inside code block */
  -webkit-overflow-scrolling: touch;
  margin-bottom: 1.5rem;
  font-family: monospace;
  font-size: 0.92rem;
  border: 1px solid var(--border-color);
}

.article-body pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
  word-break: normal;
}

.note-box {
  background-color: var(--accent-light);
  border-left: 4px solid var(--accent);
  padding: 1.25rem 1.5rem;
  border-radius: 0 10px 10px 0;
  margin-bottom: 1.5rem;
}

.note-box p {
  margin-bottom: 0;
  font-weight: 500;
  color: var(--text-primary);
}

/* ============================================
   TOOLS PAGE
   ============================================ */
.tools-grid {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2.5rem;
}

.tools-sidebar {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  height: fit-content;
  min-width: 0;
}

.tool-tab {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  width: 100%;
  border: none;
  background: none;
  color: var(--text-secondary);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.92rem;
  text-align: left;
  border-radius: 8px;
  cursor: pointer;
  margin-bottom: 0.5rem;
  transition: all var(--transition-speed);
}

.tool-tab:last-child { margin-bottom: 0; }
.tool-tab:hover {
  background-color: var(--bg-tertiary);
  color: var(--text-primary);
}

.tool-tab.active {
  background-color: var(--accent-light);
  color: var(--accent);
}

.tool-panel {
  display: none;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--card-shadow);
  min-width: 0;
}

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

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color var(--transition-speed);
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}

textarea.form-control {
  resize: vertical;
  min-height: 150px;
  font-family: monospace;
}

.tool-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.output-container { position: relative; }

.output-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.btn-copy {
  background: none;
  border: none;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.btn-copy:hover { color: var(--primary-hover); }

.tool-output {
  width: 100%;
  min-height: 150px;
  background-color: var(--code-bg);
  color: var(--code-text);
  padding: 1rem;
  border-radius: 8px;
  font-family: monospace;
  font-size: 0.9rem;
  overflow-x: auto; /* code ke andar hi scroll */
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border-color);
  white-space: pre-wrap;
  word-break: break-word;
}

.validation-msg {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  display: none;
}

.validation-msg.success {
  display: block;
  background-color: #d1fae5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.validation-msg.error {
  display: block;
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3.5rem;
}

.contact-info h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.contact-info p { margin-bottom: 2rem; }

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.contact-item-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--accent-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-item-text h4 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.contact-item-text p {
  color: var(--text-muted);
  margin-bottom: 0;
}

.contact-form-wrapper {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2.5rem;
  box-shadow: var(--card-shadow);
}

.contact-form-wrapper h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 4rem 2rem 2rem;
  transition: background-color var(--transition-speed);
  width: 100%;
}

.footer-grid {
  max-width: 1200px;
  margin: 0 auto 3rem;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 2.5rem;
}

.footer-about h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.35rem;
  margin-bottom: 1.25rem;
}

.footer-about h3 span { color: var(--accent); }

.footer-about p {
  font-size: 0.93rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.65;
}

.footer-links h4 {
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-primary);
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.93rem;
  transition: all var(--transition-speed);
}

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

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom p {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.footer-socials {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-speed);
  border: 1px solid var(--border-color);
  font-size: 1rem;
}

.social-link:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-2px);
}

/* ============================================
   COOKIE BANNER
   ============================================ */
.cookie-banner {
  position: fixed;
  bottom: 1.5rem;
  left: 1.5rem;
  max-width: 480px;
  width: calc(100% - 3rem); /* mobile pe edge tak nahi jayega */
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.15);
  border-radius: 16px;
  padding: 1.5rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transform: translateY(150%);
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.cookie-banner.show {
  transform: translateY(0);
}

.cookie-banner-content h4 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.cookie-banner-content p {
  font-size: 0.83rem;
  color: var(--text-secondary);
  margin-bottom: 0;
  line-height: 1.55;
}

.cookie-banner-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.cookie-banner-actions .btn {
  padding: 0.55rem 1.1rem;
  font-size: 0.85rem;
}

/* ============================================
   BACK TO TOP
   ============================================ */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: var(--primary);
  color: white;
  border: none;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--transition-speed);
  z-index: 999;
  font-size: 1rem;
}

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

.back-to-top:hover {
  background-color: var(--primary-hover);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.45);
}

/* ============================================
   LEGAL PAGES
   ============================================ */
.legal-container {
  max-width: 900px;
  margin: 3rem auto;
  padding: 0 2rem;
  width: 100%;
}

.legal-container h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
}

.legal-container p.last-updated {
  color: var(--text-muted);
  margin-bottom: 2.5rem;
  font-size: 0.95rem;
}

.legal-content h2 {
  font-size: 1.55rem;
  margin: 2rem 0 1rem;
  color: var(--text-primary);
}

.legal-content p, .legal-content ul {
  margin-bottom: 1.5rem;
}

.legal-content ul {
  padding-left: 1.5rem;
  list-style-type: disc;
}

.legal-content li { margin-bottom: 0.5rem; }

/* ============================================
   RESPONSIVE — TABLET (max 1024px)
   ============================================ */
@media (max-width: 1024px) {

  .hero {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding: 4rem 1.5rem 3rem;
    background-image: none; /* dot grid off on small screens */
  }

  .hero-content {
    text-align: center;
  }

  .hero-content p {
    margin: 0 auto 2rem;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
  }

  .steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-3,
  .usecase-grid,
  .video-grid,
  .testimonials-grid,
  .tips-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .tools-grid {
    grid-template-columns: 1fr;
  }

  .contact-container {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
}

/* ============================================
   RESPONSIVE — MOBILE (max 768px)
   ============================================ */
@media (max-width: 768px) {
  html { font-size: 15px; }

  .navbar {
    padding: 0.85rem 1rem;
  }

  /* Show hamburger, hide desktop nav */
  .menu-toggle { display: flex; }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 75vw;         /* proportional instead of fixed 280px */
    max-width: 300px;
    height: 100vh;
    background-color: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
    flex-direction: column;
    align-items: flex-start;
    padding: 5rem 1.5rem 2rem;
    gap: 1.5rem;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    z-index: 1050;
  }

  .nav-links.open {
    right: 0;
  }

  .menu-toggle.open span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }
  .menu-toggle.open span:nth-child(2) {
    opacity: 0;
  }
  .menu-toggle.open span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -8px);
  }

  /* All multi-col grids → single column */
  .grid-3,
  .grid-2,
  .steps-grid,
  .usecase-grid,
  .video-grid,
  .testimonials-grid,
  .tips-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 3rem 1rem;
  }

  .section-header h2 {
    font-size: 1.75rem;
  }

  .stats-strip {
    gap: 1.5rem 2rem;
    padding: 2rem 1rem;
  }

  .stat-number { font-size: 1.8rem; }

  .integrations-logos { gap: 0.5rem; }

  .integration-badge {
    font-size: 0.82rem;
    padding: 0.4rem 0.7rem;
  }

  .cta-banner {
    padding: 2rem 1.25rem;
    border-radius: 16px;
  }

  .cta-banner h2 { font-size: 1.4rem; }
  .cta-banner p { font-size: 0.95rem; }

  .comparison-wrapper {
    border-radius: 10px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .article-header h1 { font-size: 1.9rem; }

  .hero-card { padding: 1.5rem; }

  .cookie-banner {
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    max-width: none;
    width: auto;
  }

  .back-to-top {
    bottom: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
  }
}

/* ============================================
   RESPONSIVE — SMALL MOBILE (max 480px)
   ============================================ */
@media (max-width: 480px) {
  html { font-size: 14px; }

  .navbar { padding: 0.75rem; }
  .logo { font-size: 1.3rem; }

  .btn {
    padding: 0.65rem 1.2rem;
    font-size: 0.88rem;
  }

  .hero {
    padding: 3rem 1rem 2rem;
  }

  .hero-content h1 {
    font-size: 1.85rem;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .stats-strip {
    gap: 1.25rem 1.5rem;
  }

  .stat-number { font-size: 1.6rem; }

  .step-number { font-size: 3rem; }

  .card {
    padding: 1.5rem;
    border-radius: 14px;
  }

  .contact-form-wrapper {
    padding: 1.5rem;
  }

  .section-header { margin-bottom: 2rem; }

  .cta-banner-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn-white,
  .btn-outline-white {
    width: 100%;
    max-width: 280px;
    text-align: center;
    justify-content: center;
  }
}