/* ============================================================
   Phone Number Generator – style.css
   ============================================================ */

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

/* ─── CSS Variables ─────────────────────────────────────── */
:root {
  --bg: #f8faff;
  --surface: #ffffff;
  --surface2: #f0f4ff;
  --border: #e2e8f0;
  --text: #0f172a;
  --text-muted: #64748b;
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #e0e7ff;
  --secondary: #06b6d4;
  --accent: #f59e0b;
  --success: #10b981;
  --danger: #ef4444;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(99,102,241,0.08);
  --shadow-lg: 0 12px 40px rgba(99,102,241,0.14);
  --transition: 0.2s ease;
  --header-h: 70px;
}

body.dark {
  --bg: #0b0f1a;
  --surface: #141929;
  --surface2: #1a2035;
  --border: #2a3045;
  --text: #e2e8f0;
  --text-muted: #94a3b8;
  --primary-light: #1e1b4b;
  --shadow: 0 4px 24px rgba(0,0,0,0.3);
  --shadow-lg: 0 12px 40px rgba(0,0,0,0.4);
}

/* ─── Reset ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  transition: background var(--transition), color var(--transition);
}
img { max-width: 100%; }
a { text-decoration: none; color: inherit; }

/* ─── Utility ────────────────────────────────────────────── */
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.hidden { display: none !important; }
.text-center { text-align: center; }

/* ─── Scrollbar ──────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 10px; }

/* ─── Header ─────────────────────────────────────────────── */
.header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  background: rgba(248,250,255,0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}
body.dark .header { background: rgba(11,15,26,0.85); }
.header .container {
  height: 100%; display: flex; align-items: center; justify-content: space-between;
}
.logo {
  display: flex; align-items: center; gap: 10px; font-weight: 800;
  font-size: 1.25rem; color: var(--primary); letter-spacing: -0.5px;
}
.logo-img {
  width: 36px; height: 36px; object-fit: contain; border-radius: 8px;
}
.nav-menu { display: flex; align-items: center; gap: 28px; list-style: none; }
.nav-menu a {
  font-size: 0.9rem; font-weight: 500; color: var(--text-muted);
  transition: color var(--transition); padding: 4px 0;
}
.nav-menu a:hover { color: var(--primary); }
.header-actions { display: flex; align-items: center; gap: 12px; }
.dark-toggle {
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 50%; width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 1.1rem; transition: all var(--transition);
}
.dark-toggle:hover { border-color: var(--primary); transform: rotate(20deg); }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; font-size: 1.5rem; color: var(--text); }

/* ─── Hero ───────────────────────────────────────────────── */
.hero {
  padding: 70px 0 60px;
  background: var(--primary-light);
  overflow: hidden;
  position: relative;
}
.hero::before { display: none; }

.hero-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 60px;
}

/* Left column */
.hero-text { text-align: left; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: #fff; border: 1px solid rgba(99,102,241,0.25);
  color: var(--primary); border-radius: 999px;
  padding: 6px 16px; font-size: 0.82rem; font-weight: 600;
  margin-bottom: 24px; letter-spacing: 0.3px;
  box-shadow: 0 2px 8px rgba(99,102,241,0.1);
}
.hero h1 {
  font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; line-height: 1.15;
  letter-spacing: -1px; margin-bottom: 18px;
}
.hero h1 span { color: var(--primary); }
.hero-text > p {
  font-size: 1rem; color: var(--text-muted); margin-bottom: 30px; line-height: 1.7;
}
.hero-cta-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 36px; }
.btn-hero-primary {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--primary); color: #fff;
  padding: 14px 28px; border-radius: 12px; font-size: 1rem; font-weight: 700;
  transition: all 0.2s; box-shadow: 0 6px 20px rgba(99,102,241,0.35);
  border: none; cursor: pointer;
}
.btn-hero-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(99,102,241,0.45); }
.btn-hero-secondary {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--primary); font-weight: 600; font-size: 0.95rem;
  background: transparent; border: 1.5px solid rgba(99,102,241,0.35);
  padding: 13px 22px; border-radius: 12px; transition: all 0.2s;
}
.btn-hero-secondary:hover { background: #fff; border-color: var(--primary); }
.hero-stats {
  display: flex; gap: 28px; flex-wrap: wrap; padding-top: 6px;
  border-top: 1px solid rgba(99,102,241,0.15);
}
.stat-item { display: flex; flex-direction: column; }
.stat-num { font-size: 1.6rem; font-weight: 800; color: var(--primary); line-height: 1; }
.stat-label { font-size: 0.75rem; color: var(--text-muted); font-weight: 500; margin-top: 3px; }

/* Right column – animated phone preview cards */
.hero-visual {
  position: relative; height: 340px;
  display: flex; align-items: center; justify-content: center;
}
.hero-visual-glow {
  position: absolute; width: 260px; height: 260px;
  background: rgba(99,102,241,0.12); border-radius: 50%;
  filter: blur(60px); top: 50%; left: 50%;
  transform: translate(-50%, -50%); pointer-events: none;
}
.phone-preview-card {
  position: absolute;
  background: #fff; border: 1px solid rgba(99,102,241,0.18);
  border-radius: 16px; padding: 14px 16px;
  display: flex; align-items: center; gap: 12px;
  box-shadow: 0 8px 28px rgba(99,102,241,0.14);
  min-width: 230px; backdrop-filter: blur(4px);
}
.preview-flag { font-size: 1.8rem; flex-shrink: 0; }
.preview-info { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.preview-country { font-size: 0.72rem; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.preview-number { font-size: 0.95rem; font-weight: 700; color: var(--text); font-family: 'Courier New', monospace; white-space: nowrap; }
.preview-badge {
  font-size: 0.68rem; font-weight: 700; padding: 3px 9px;
  border-radius: 99px; text-transform: uppercase; letter-spacing: 0.4px; flex-shrink: 0;
}
.preview-badge.mobile  { background: rgba(16,185,129,0.12); color: #059669; }
.preview-badge.landline { background: rgba(99,102,241,0.12); color: var(--primary); }
.preview-badge.tollfree { background: rgba(245,158,11,0.12); color: #d97706; }

/* Card positions & float animations */
.card-1 { top: 10px;  left: 0;   animation: floatA 4s ease-in-out infinite; }
.card-2 { top: 100px; right: 0;  animation: floatB 4.5s ease-in-out infinite 0.5s; }
.card-3 { bottom: 60px; left: 20px; animation: floatA 5s ease-in-out infinite 1s; }
.card-4 { bottom: 0;  right: 10px; animation: floatB 4.2s ease-in-out infinite 0.2s; }

@keyframes floatA {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-10px); }
}
@keyframes floatB {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(10px); }
}

/* Responsive hero */
@media (max-width: 900px) {
  .hero-container { grid-template-columns: 1fr; gap: 40px; text-align: center; }
  .hero-text { text-align: center; }
  .hero-cta-row { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { height: 260px; }
  .phone-preview-card { min-width: 190px; }
  .card-3, .card-4 { display: none; }
  .card-1 { top: 20px; left: 10px; }
  .card-2 { top: 20px; right: 10px; left: auto; }
}
@media (max-width: 480px) {
  .hero-visual { display: none; }
}


/* ─── Tool Section ───────────────────────────────────────── */
.tool-section { padding: 60px 0; }
.tool-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 24px; box-shadow: var(--shadow-lg);
  overflow: hidden; max-width: 900px; margin: 0 auto;
}
.tool-header {
  background: var(--primary);
  padding: 28px 36px; color: #fff; text-align: center;
}
.tool-header h2 { font-size: 1.4rem; font-weight: 700; }
.tool-header p { font-size: 0.9rem; opacity: 0.85; margin-top: 4px; }
.tool-body { padding: 32px 36px; }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 28px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group label {
  font-size: 0.82rem; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.5px;
}
.form-group select {
  appearance: none;
  background: var(--surface2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236366f1' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 14px center;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 38px 12px 14px; font-size: 0.95rem; color: var(--text);
  cursor: pointer; transition: border-color var(--transition), box-shadow var(--transition);
  font-family: inherit;
}
.form-group select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(99,102,241,0.12); }

.quantity-row { grid-column: 1 / -1; }
.quantity-control { display: flex; align-items: center; gap: 16px; }
.quantity-slider {
  flex: 1; -webkit-appearance: none; appearance: none;
  height: 6px; border-radius: 99px;
  background: var(--primary);
  cursor: pointer; outline: none;
}
.quantity-slider::-webkit-slider-thumb {
  -webkit-appearance: none; width: 20px; height: 20px;
  border-radius: 50%; background: #fff;
  border: 3px solid var(--primary); box-shadow: 0 2px 8px rgba(99,102,241,0.3);
  cursor: pointer; transition: transform var(--transition);
}
.quantity-slider::-webkit-slider-thumb:hover { transform: scale(1.2); }
.quantity-display {
  min-width: 42px; height: 42px; background: var(--primary);
  color: #fff; border-radius: 10px; display: flex; align-items: center;
  justify-content: center; font-weight: 700; font-size: 1.1rem;
}

.format-preview {
  background: var(--surface2); border: 1px dashed var(--border);
  border-radius: var(--radius-sm); padding: 10px 14px;
  font-size: 0.85rem; color: var(--text-muted); font-family: 'Courier New', monospace;
  margin-bottom: 24px;
}

.btn-generate {
  width: 100%; padding: 18px; font-size: 1.1rem; font-weight: 700;
  background: var(--primary);
  color: #fff; border: none; border-radius: var(--radius); cursor: pointer;
  letter-spacing: 0.3px; transition: all var(--transition);
  box-shadow: 0 6px 20px rgba(99,102,241,0.35);
  position: relative; overflow: hidden;
}
.btn-generate:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(99,102,241,0.45); }
.btn-generate:active { transform: translateY(0); }
.btn-generate.generating::after {
  content: ''; position: absolute; inset: 0;
  background: rgba(255,255,255,0.15);
  animation: shimmer 0.6s ease;
}
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

/* ─── Results ────────────────────────────────────────────── */
#results-section { border-top: 1px solid var(--border); padding-top: 28px; margin-top: 28px; }
.results-header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; flex-wrap: wrap; gap: 12px;
}
.results-header h3 { font-weight: 700; font-size: 1.05rem; }
#results-count { font-size: 0.82rem; color: var(--text-muted); }

.results-table-wrap { overflow-x: auto; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.results-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.results-table th {
  background: var(--surface2); padding: 12px 14px; text-align: left;
  font-size: 0.78rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; color: var(--text-muted); border-bottom: 1px solid var(--border);
}
.results-table td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.results-table tr:last-child td { border-bottom: none; }
.results-table tr:hover td { background: var(--surface2); }

.phone-number { font-family: 'Courier New', monospace; font-weight: 600; font-size: 1rem; color: var(--primary); }
.type-badge {
  display: inline-block; padding: 3px 10px; border-radius: 99px;
  font-size: 0.75rem; font-weight: 600; text-transform: capitalize;
}
.type-mobile { background: rgba(16,185,129,0.12); color: #059669; }
.type-landline { background: rgba(99,102,241,0.12); color: var(--primary); }
.type-tollfree { background: rgba(245,158,11,0.12); color: #d97706; }

.copy-btn {
  display: flex; align-items: center; gap: 5px; padding: 6px 12px;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 8px; font-size: 0.82rem; font-weight: 500;
  cursor: pointer; color: var(--text-muted); transition: all var(--transition);
  white-space: nowrap;
}
.copy-btn:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }
.copy-btn.copied { border-color: var(--success); color: var(--success); background: rgba(16,185,129,0.08); }

.result-actions {
  display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap;
}
.btn-action {
  display: flex; align-items: center; gap: 6px; padding: 10px 18px;
  border-radius: 10px; font-size: 0.88rem; font-weight: 600;
  cursor: pointer; border: 1.5px solid var(--border);
  background: var(--surface2); color: var(--text);
  transition: all var(--transition);
}
.btn-action:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }
.btn-action.primary { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-action.primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }

@keyframes fadeInRow {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-in-row { animation: fadeInRow 0.3s ease both; }

/* ─── Privacy Notice ─────────────────────────────────────── */
.privacy-notice {
  display: flex; align-items: flex-start; gap: 12px;
  background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.25);
  border-radius: var(--radius-sm); padding: 14px 18px;
  margin-top: 24px; font-size: 0.85rem; color: var(--text-muted);
}
.privacy-notice .notice-icon { font-size: 1.1rem; flex-shrink: 0; }

/* ─── Section Shared ─────────────────────────────────────── */
.section { padding: 70px 0; }
.section-alt { background: var(--surface2); }
.section-header { text-align: center; margin-bottom: 50px; }
.section-header .eyebrow {
  display: inline-block; font-size: 0.78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; color: var(--primary);
  background: var(--primary-light); padding: 4px 14px; border-radius: 99px;
  margin-bottom: 14px;
}
.section-header h2 { font-size: clamp(1.6rem,3.5vw,2.4rem); font-weight: 800; letter-spacing: -0.5px; }
.section-header p { color: var(--text-muted); margin-top: 12px; max-width: 560px; margin-left: auto; margin-right: auto; }

/* ─── Use Cases ──────────────────────────────────────────── */
.use-cases-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.use-case-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 24px;
  transition: transform var(--transition), box-shadow var(--transition);
  position: relative; overflow: hidden;
}
.use-case-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--primary);
}
.use-case-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.use-case-icon {
  width: 52px; height: 52px; background: var(--primary-light);
  border-radius: 14px; display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 16px;
}
.use-case-card h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 8px; }
.use-case-card p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.6; }

/* ─── About / Info Sections ──────────────────────────────── */
.info-section { padding: 70px 0; }
.info-section .container { max-width: 800px; }
.info-section h2 { font-size: 1.8rem; font-weight: 800; margin-bottom: 16px; letter-spacing: -0.5px; }
.info-section h3 { font-size: 1.1rem; font-weight: 700; margin: 28px 0 10px; color: var(--primary); }
.info-section p { font-size: 0.95rem; color: var(--text-muted); line-height: 1.8; margin-bottom: 14px; }
.info-section ul { margin: 10px 0 14px 20px; }
.info-section ul li { font-size: 0.92rem; color: var(--text-muted); margin-bottom: 7px; line-height: 1.6; }

/* ─── SEO Keywords Section ───────────────────────────────── */
.keywords-section { padding: 40px 0; }
.keywords-cloud { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.kw-tag {
  padding: 6px 14px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 99px; font-size: 0.8rem; color: var(--text-muted);
  transition: all var(--transition);
}
.kw-tag:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }

/* ─── FAQ ────────────────────────────────────────────────── */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  transition: box-shadow var(--transition);
}
.faq-item.open { box-shadow: var(--shadow); }
.faq-question {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px; cursor: pointer; font-weight: 600; font-size: 0.97rem;
  transition: color var(--transition); user-select: none;
}
.faq-item.open .faq-question { color: var(--primary); }
.faq-icon {
  width: 26px; height: 26px; border-radius: 50%; background: var(--surface2);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; transition: transform var(--transition); flex-shrink: 0;
}
.faq-item.open .faq-icon { transform: rotate(45deg); background: var(--primary); color: #fff; }
.faq-answer {
  max-height: 0; overflow: hidden;
  transition: max-height 0.35s ease, padding var(--transition);
  padding: 0 22px; color: var(--text-muted); font-size: 0.92rem; line-height: 1.7;
}
.faq-item.open .faq-answer { max-height: 300px; padding: 0 22px 18px; }

/* ─── CTA ────────────────────────────────────────────────── */
.cta-section {
  padding: 80px 0;
  background: var(--primary);
  text-align: center; color: #fff;
}
.cta-section h2 { font-size: clamp(1.6rem,3.5vw,2.4rem); font-weight: 800; margin-bottom: 16px; letter-spacing: -0.5px; }
.cta-section p { font-size: 1.05rem; opacity: 0.9; margin-bottom: 36px; }
.btn-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; color: var(--primary); padding: 16px 36px;
  border-radius: var(--radius); font-size: 1.05rem; font-weight: 700;
  transition: all var(--transition); box-shadow: 0 6px 20px rgba(0,0,0,0.15);
  border: none; cursor: pointer;
}
.btn-cta:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(0,0,0,0.2); }

/* ─── Footer ─────────────────────────────────────────────── */
.footer { background: var(--surface); border-top: 1px solid var(--border); padding: 50px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-about p { font-size: 0.88rem; color: var(--text-muted); margin-top: 12px; line-height: 1.7; max-width: 280px; }
.footer-col h4 { font-weight: 700; font-size: 0.9rem; margin-bottom: 16px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a { font-size: 0.88rem; color: var(--text-muted); transition: color var(--transition); }
.footer-col ul li a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border); padding-top: 22px;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-size: 0.82rem; color: var(--text-muted);
}
.footer-bottom a { color: var(--text-muted); transition: color var(--transition); }
.footer-bottom a:hover { color: var(--primary); }

/* ─── Responsive ─────────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-menu { display: none; flex-direction: column; position: absolute; top: var(--header-h); left: 0; right: 0; background: var(--surface); border-bottom: 1px solid var(--border); padding: 20px; gap: 16px; box-shadow: var(--shadow); }
  .nav-menu.open { display: flex; }
  .nav-toggle { display: block; }
  .header { position: sticky; }

  .form-grid { grid-template-columns: 1fr; }
  .tool-body { padding: 24px 20px; }
  .tool-header { padding: 22px 20px; }

  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero { padding: 50px 0 40px; }
  .hero-stats { gap: 24px; }
  .result-actions { justify-content: center; }
  .results-header { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .results-table th:nth-child(2), .results-table td:nth-child(2) { display: none; }
}
