/* ============================================
   AnyPDF – Premium Design System
   Modern, Clean, AdSense-Friendly
   ============================================ */
@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap");

:root {
  /* Primary Palette – Deep Indigo to Electric Blue */
  --primary-color: #4f46e5;
  --primary-hover: #4338ca;
  --primary-light: #eef2ff;
  --primary-glow: rgba(79, 70, 229, 0.15);

  /* Accent */
  --accent-color: #06b6d4;
  --accent-light: #ecfeff;

  /* Surfaces */
  --bg-body: #f8fafc;
  --bg-card: #ffffff;
  --bg-elevated: #ffffff;

  /* Text */
  --text-dark: #0f172a;
  --text-medium: #334155;
  --text-light: #64748b;
  --text-muted: #94a3b8;

  /* Borders */
  --border-color: #e2e8f0;
  --border-light: #f1f5f9;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  --shadow-primary: 0 4px 14px rgba(79, 70, 229, 0.25);

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #06b6d4 100%);
  --gradient-hero: linear-gradient(135deg, #eef2ff 0%, #ecfeff 50%, #f0fdf4 100%);
  --gradient-card-hover: linear-gradient(135deg, rgba(79, 70, 229, 0.03), rgba(6, 182, 212, 0.03));

  /* Transition */
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   RESET & BASE
   ============================================ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text-dark);
  background-color: var(--bg-body);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* ============================================
   HEADER / NAVBAR
   ============================================ */
header {
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow-xs);
}

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

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-dark);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  letter-spacing: -0.02em;
}

.logo span {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo i {
  color: var(--primary-color);
  font-size: 1.6rem;
}

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

.nav-link {
  font-weight: 500;
  color: var(--text-medium);
  font-size: 0.9rem;
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
}

.nav-link:hover {
  color: var(--primary-color);
  background-color: var(--primary-light);
}

.auth-buttons {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.btn-login {
  font-weight: 600;
  color: var(--text-medium);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
}

.btn-login:hover {
  color: var(--primary-color);
  background-color: var(--primary-light);
}

.btn-signup {
  background: var(--gradient-primary);
  color: #fff;
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.9rem;
  box-shadow: var(--shadow-primary);
  transition: var(--transition);
}

.btn-signup:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.menu-toggle {
  display: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text-dark);
  padding: 0.5rem;
  border-radius: var(--radius-sm);
}

.menu-toggle:hover {
  background-color: var(--border-light);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  text-align: center;
  padding: 5rem 1.5rem 3.5rem;
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -25%;
  width: 150%;
  height: 200%;
  background: radial-gradient(ellipse at center, rgba(79, 70, 229, 0.06) 0%, transparent 60%);
  pointer-events: none;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 800;
  color: var(--text-dark);
  margin-bottom: 1rem;
  line-height: 1.15;
  letter-spacing: -0.03em;
  position: relative;
}

.hero p {
  font-size: 1.2rem;
  color: var(--text-light);
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.7;
  position: relative;
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
  flex: 1;
}

/* ============================================
   TOOLS GRID (Homepage)
   ============================================ */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.25rem;
}

.tool-card {
  background-color: var(--bg-card);
  padding: 1.75rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  border: 1px solid var(--border-color);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.tool-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient-card-hover);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.tool-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(79, 70, 229, 0.25);
}

.tool-card:hover::before {
  opacity: 1;
}

.tool-icon {
  font-size: 2.25rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-light);
  border-radius: var(--radius-md);
}

.tool-info {
  position: relative;
  z-index: 1;
}

.tool-info h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0.375rem;
}

.tool-info p {
  font-size: 0.875rem;
  color: var(--text-light);
  line-height: 1.55;
}

/* Tool Badges */
.badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background-color: var(--primary-light);
  color: var(--primary-color);
  font-size: 0.65rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  z-index: 1;
  border: 1px solid rgba(79, 70, 229, 0.15);
}

.badge.popular {
  background-color: #fff7ed;
  color: #ea580c;
  border-color: rgba(234, 88, 12, 0.15);
}

/* ============================================
   TOOL PAGE HERO
   ============================================ */
.tool-page-hero {
  background: var(--gradient-hero);
  padding: 5rem 1.5rem;
  text-align: center;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 55vh;
  position: relative;
}

.tool-page-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at top center, rgba(79, 70, 229, 0.08) 0%, transparent 65%);
  pointer-events: none;
}

.hero-icon {
  font-size: 3rem;
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(79, 70, 229, 0.1);
  animation: floatIcon 4s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.tool-page-hero h1 {
  font-size: 2.75rem;
  color: var(--text-dark);
  margin-bottom: 0.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  position: relative;
  z-index: 1;
}

.tool-page-hero p {
  font-size: 1.15rem;
  color: var(--text-light);
  margin-bottom: 2.5rem;
  max-width: 600px;
  line-height: 1.6;
  position: relative;
  z-index: 1;
}

/* Upload Area */
.upload-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.btn-upload {
  background: var(--gradient-primary);
  color: #fff;
  padding: 1.25rem 3rem;
  font-size: 1.25rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-primary);
  cursor: pointer;
  transition: var(--transition);
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  letter-spacing: -0.01em;
}

.btn-upload:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(79, 70, 229, 0.4);
}

.cloud-providers {
  display: flex;
  gap: 0.75rem;
}

.btn-drive,
.btn-dropbox {
  background-color: var(--bg-card);
  color: var(--text-light);
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--border-color);
  cursor: pointer;
}

.btn-drive:hover,
.btn-dropbox:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ============================================
   DESCRIPTION & STEPS SECTION
   ============================================ */
.tool-description-section {
  padding: 4rem 2rem;
  background-color: var(--bg-card);
  text-align: center;
}

.tool-description-section h2 {
  font-size: 2.25rem;
  margin-bottom: 3rem;
  color: var(--text-dark);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

.step-card {
  text-align: center;
  padding: 2rem 1.5rem;
  border-radius: var(--radius-lg);
  background: var(--bg-body);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.step-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.step-number {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  background: var(--gradient-primary);
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-primary);
}

.step-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
  font-weight: 700;
}

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

/* Feature Cards */
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 2rem;
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-card i {
  color: var(--primary-color) !important;
}

.feature-card h3 {
  color: var(--text-dark);
}

.feature-card p {
  color: var(--text-light);
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  background-color: var(--text-dark);
  color: #cbd5e1;
  padding: 4rem 2rem 2rem;
  margin-top: auto;
  border-top: none;
}

.footer-content {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2.5rem;
}

.footer-section h4 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: #f1f5f9;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.8rem;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section ul li a {
  color: #94a3b8;
  font-size: 0.9rem;
  transition: var(--transition-fast);
}

.footer-section ul li a:hover {
  color: #e2e8f0;
  padding-left: 4px;
}

.copyright {
  text-align: center;
  padding-top: 2.5rem;
  margin-top: 3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: #64748b;
  font-size: 0.85rem;
}

/* ============================================
   AD SLOTS
   ============================================ */
.ad-slot {
  background: rgba(0, 0, 0, 0.02);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-md);
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.85rem;
  width: 100%;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .navbar {
    padding: 0.875rem 1rem;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg);
    padding: 1.5rem 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    z-index: 999;
    gap: 0.25rem;
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a {
    display: block;
    padding: 0.875rem 1.5rem;
    width: 100%;
  }

  .auth-buttons {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .hero {
    padding: 3.5rem 1rem 2.5rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

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

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

  .tool-page-hero {
    padding: 3rem 1rem;
    min-height: auto;
  }

  .tool-page-hero h1 {
    font-size: 2rem;
  }

  .btn-upload {
    padding: 1rem 2rem;
    font-size: 1.1rem;
  }

  .upload-container {
    flex-direction: column;
  }

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

@media (max-width: 480px) {
  .hero h1 {
    font-size: 1.75rem;
  }

  .tool-card {
    padding: 1.5rem;
  }
}
