:root {
  --bg: #f6f8f4;
  --bg-alt: #edf3ee;
  --surface: #ffffff;
  --primary: #0e7a5a;
  --primary-dark: #0a5c44;
  --primary-soft: rgba(14, 122, 90, 0.10);
  --accent: #f2a33a;
  --accent-soft: rgba(242, 163, 58, 0.16);
  --text: #12251e;
  --text-secondary: #4a5f56;
  --text-muted: #8a9b93;
  --border: rgba(18, 37, 30, 0.10);
  --danger: #c62f24;
  --rank-top3: #1a9850;
  --rank-top10: #fee08b;
  --rank-visible: #fc8d59;
  --rank-deep: #bdbdbd;
  --rank-none: #d73027;
  --font-body: 'Manrope', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(18, 37, 30, 0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

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

/* ========== NAV ========== */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0.9rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(16px);
  background: rgba(246, 248, 244, 0.88);
  border-bottom: 1px solid var(--border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--text);
}

.logo-text { font-size: 1.15rem; font-weight: 800; letter-spacing: -0.3px; }
.logo-text span { color: var(--primary); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--text); }
.nav-links a.btn { color: #fff; }

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  z-index: 101;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 0.3s, opacity 0.3s;
}

.nav-open .nav-hamburger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-open .nav-hamburger span:nth-child(2) { opacity: 0; }
.nav-open .nav-hamburger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.6rem 1.3rem;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}

.btn-lg { padding: 0.9rem 1.8rem; font-size: 1rem; }

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(14, 122, 90, 0.25); }

.btn-outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

.btn-google { background: #fff; color: var(--text); border-color: rgba(18, 37, 30, 0.2); }
.btn-google:hover { border-color: var(--primary); box-shadow: var(--shadow); }

.text-link { font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }

/* ========== SECTIONS ========== */
section { padding: 6rem 2rem; }

.alt-section { background: var(--bg-alt); }

.section-inner { max-width: 1160px; margin: 0 auto; }
.section-inner.narrow { max-width: 760px; }
.section-inner.center { text-align: center; }
.section-inner.center .section-desc { margin-left: auto; margin-right: auto; }

.section-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 0.9rem;
}

.section-title {
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.75;
  max-width: 640px;
  margin-bottom: 2.5rem;
}

.fade-up { opacity: 0; transform: translateY(16px); transition: opacity 0.6s, transform 0.6s; }
.fade-up.visible { opacity: 1; transform: none; }

/* ========== HERO ========== */
.hero {
  padding: 9rem 2rem 6rem;
  background:
    radial-gradient(circle at 85% 20%, var(--accent-soft), transparent 40%),
    radial-gradient(circle at 10% 90%, var(--primary-soft), transparent 45%);
}

.hero-inner {
  max-width: 1160px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem;
  border-radius: 100px;
  background: var(--primary-soft);
  color: var(--primary-dark);
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.hero-badge .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--primary);
  animation: pulse 2s infinite;
}

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }

h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -2px;
  margin-bottom: 1.4rem;
}

h1 .highlight { color: var(--primary); }

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 560px;
  margin-bottom: 1.4rem;
}

.hero-points {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.4rem;
  margin-bottom: 2rem;
  font-size: 0.92rem;
  font-weight: 600;
}

.hero-points li::before { content: "✓"; color: var(--primary); font-weight: 800; margin-right: 0.45rem; }

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

.hero-note { font-size: 0.82rem; color: var(--text-muted); }

/* Example heatmap card */
.sample-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 1.4rem;
  box-shadow: 0 24px 60px rgba(18, 37, 30, 0.12);
}

.sample-head { display: flex; flex-direction: column; gap: 0.2rem; margin-bottom: 1rem; font-size: 0.85rem; color: var(--text-secondary); }
.sample-head strong { color: var(--text); font-size: 1rem; }

.sample-tag {
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  background: var(--accent-soft);
  color: #8a5300;
  padding: 0.15rem 0.5rem;
  border-radius: 6px;
  margin-bottom: 0.4rem;
}

.sample-grid {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  aspect-ratio: 1;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #e9ece6 url("../images/sample-map-belgrade.webp") center / cover no-repeat;
  overflow: hidden;
}

.sample-grid .rank-dot {
  place-self: center;
  width: 48%;
  font-size: 0.6rem;
  border-width: 1px;
  opacity: 0.92;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}

.sample-map-credit {
  display: block;
  text-align: right;
  font-size: 0.65rem;
  color: var(--text-muted);
  margin: 0.3rem 0 0.9rem;
}
.sample-map-credit a { color: inherit; }

.rank-dot {
  aspect-ratio: 1;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 800;
  color: #111;
  border: 1.5px solid rgba(0, 0, 0, 0.55);
}

.rank-top3 { background: var(--rank-top3); }
.rank-top10 { background: var(--rank-top10); }
.rank-visible { background: var(--rank-visible); }
.rank-deep { background: var(--rank-deep); }
.rank-none { background: var(--rank-none); }

.legend { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; font-size: 0.8rem; color: var(--text-secondary); }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 0.35rem; vertical-align: -1px; border: 1px solid rgba(0, 0, 0, 0.4); }

.legend-list { list-style: none; flex-direction: column; gap: 0.9rem; font-size: 1rem; }
.legend-list li { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 0.9rem 1.1rem; }
.legend-list i { width: 16px; height: 16px; margin-right: 0.6rem; vertical-align: -3px; }
.legend-list strong { display: inline-block; min-width: 3.2rem; }

/* Google AI service */
.ai-note { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.7; margin: -0.5rem 0 1.8rem; padding-left: 1rem; border-left: 3px solid var(--accent); }
.ai-list { list-style: none; display: flex; flex-direction: column; gap: 0.9rem; }
.ai-list li { background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--primary); border-radius: 12px; padding: 0.9rem 1.1rem; }
.ai-list strong { display: block; margin-bottom: 0.2rem; }
.ai-list span { color: var(--text-secondary); font-size: 0.92rem; line-height: 1.6; }

.heatmap-row { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }

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

.step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
}

.step-number {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.2rem;
}

.step h3, .feature-card h3, .audience-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.6rem; }
.step p, .feature-card p, .audience-card p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.7; }

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

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s, box-shadow 0.25s;
}

.feature-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature-card p { flex: 1; margin-bottom: 1.2rem; }

.feature-icon { font-size: 1.6rem; margin-bottom: 1rem; }

.feature-tag {
  align-self: flex-start;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  background: var(--primary-soft);
  color: var(--primary-dark);
}

.feature-tag.tag-paid { background: var(--accent-soft); color: #8a5300; }

/* ========== AUDIENCE ========== */
.audience-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }

.audience-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 2.2rem;
}

.audience-card + .audience-card { border-top-color: var(--accent); }
.audience-card p { margin-bottom: 1.2rem; }

.audience-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 0.8rem;
}

/* ========== FAQ ========== */
.faq details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.1rem 1.4rem;
  margin-bottom: 0.8rem;
}

.faq summary { cursor: pointer; font-weight: 700; list-style: none; position: relative; padding-right: 2rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: -2px; font-size: 1.3rem; color: var(--primary); }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--text-secondary); margin-top: 0.8rem; line-height: 1.7; }

/* ========== CTA ========== */
.cta-band { background: linear-gradient(135deg, var(--primary-soft), var(--accent-soft)); }

.cta-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.9rem; margin-bottom: 1rem; }
.cta-actions.left { justify-content: flex-start; margin-top: 1.2rem; }

/* ========== CONTACT FORM ========== */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.contact-form label, .audit-form label.keyword-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.contact-form input, .contact-form textarea, .audit-form input[type=text] {
  font: inherit;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text);
  background: var(--surface);
  border: 1px solid rgba(18, 37, 30, 0.18);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  transition: border-color 0.2s;
}

.contact-form textarea { resize: vertical; }

.contact-form input:focus, .contact-form textarea:focus, .audit-form input[type=text]:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-soft);
}

.contact-form .cta-actions { margin-top: 0.5rem; justify-content: flex-start; }

.contact-hp { position: absolute; left: -9999px; }

.field-error { color: var(--danger); font-size: 0.8rem; font-weight: 600; }

.form-message { margin-bottom: 1.5rem; padding: 0.9rem 1.2rem; border-radius: 10px; font-size: 0.95rem; }
.form-message-success, .form-message-info { background: var(--primary-soft); border: 1px solid rgba(14, 122, 90, 0.25); }
.form-message-error { background: rgba(198, 47, 36, 0.08); border: 1px solid var(--danger); }

/* ========== AUDIT PAGES ========== */
.page-section { padding-top: 8rem; min-height: 70vh; }

.page-title { font-size: 2.4rem; font-weight: 800; letter-spacing: -1px; line-height: 1.15; margin-bottom: 0.8rem; }

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
}

.checklist { list-style: none; counter-reset: step; margin-bottom: 2rem; }

.checklist li {
  counter-increment: step;
  position: relative;
  padding-left: 2.8rem;
  margin-bottom: 1.2rem;
  display: flex;
  flex-direction: column;
}

.checklist li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 30px; height: 30px;
  border-radius: 9px;
  background: var(--primary-soft);
  color: var(--primary-dark);
  font-weight: 800;
  display: flex; align-items: center; justify-content: center;
}

.checklist span { color: var(--text-secondary); font-size: 0.95rem; }

.fine-print { margin-top: 1.2rem; font-size: 0.82rem; color: var(--text-muted); line-height: 1.6; }

.audit-form fieldset { border: none; margin-bottom: 1.5rem; }
.audit-form legend { font-weight: 700; margin-bottom: 0.8rem; }

.location-option {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
  padding: 1rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 0.6rem;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.location-option:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.location-option.disabled { opacity: 0.55; cursor: not-allowed; }
.location-option input { margin-top: 0.3rem; accent-color: var(--primary); }
.location-text { display: flex; flex-direction: column; gap: 0.15rem; }
.location-text span { font-size: 0.88rem; color: var(--text-secondary); }
.location-text em { font-size: 0.8rem; color: var(--danger); font-style: normal; font-weight: 600; }

.keyword-field { margin-bottom: 1.5rem; }
.hint { font-weight: 400; color: var(--text-muted); line-height: 1.5; }

.audit-meta { color: var(--text-secondary); margin-bottom: 2rem; }

.status-panel { display: flex; gap: 1.5rem; align-items: flex-start; }
.status-panel h2 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.status-panel p { color: var(--text-secondary); }

.spinner {
  flex-shrink: 0;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 4px solid var(--primary-soft);
  border-top-color: var(--primary);
  animation: spin 1s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.verdict {
  border-radius: 12px;
  padding: 1.1rem 1.4rem;
  margin-bottom: 1.5rem;
  border-left: 5px solid;
  background: var(--surface);
  line-height: 1.6;
}

.verdict-strong { border-color: var(--rank-top3); }
.verdict-growing { border-color: var(--accent); }
.verdict-weak, .verdict-absent { border-color: var(--rank-none); }

.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.5rem; }

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.2rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.stat-label { font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); }
.stat-value { font-size: 1.9rem; font-weight: 800; }
.stat-value small { font-size: 1rem; color: var(--text-muted); font-weight: 600; }
.stat-hint { font-size: 0.8rem; color: var(--text-secondary); }

.map-frame {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  margin-bottom: 0.9rem;
  height: 640px;
}

.map-frame iframe { width: 100%; height: 100%; border: 0; display: block; }

.subsection-title { font-size: 1.4rem; font-weight: 800; margin: 3rem 0 1rem; }

.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; margin-bottom: 2.5rem; }

.comp-table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
.comp-table th, .comp-table td { padding: 0.8rem 1rem; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.comp-table td:first-child { white-space: normal; min-width: 180px; }
.comp-table th { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); background: var(--bg-alt); }
.comp-table tr:last-child td { border-bottom: none; }
.comp-table tr.me td { background: var(--primary-soft); font-weight: 700; }
.comp-table em { font-weight: 500; color: var(--text-secondary); }

.cta-panel h2 { font-size: 1.4rem; margin-bottom: 0.6rem; }
.cta-panel p { color: var(--text-secondary); margin-bottom: 1.3rem; }

.prose h2 { font-size: 1.25rem; margin: 2rem 0 0.6rem; }
.prose p { color: var(--text-secondary); line-height: 1.75; margin-bottom: 0.9rem; }

/* ========== FOOTER ========== */
footer { border-top: 1px solid var(--border); padding: 2.5rem 2rem; background: var(--surface); }

.footer-inner {
  max-width: 1160px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1.2rem;
  justify-content: space-between;
  align-items: center;
}

.footer-left { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.footer-copy { font-size: 0.8rem; color: var(--text-muted); }
.footer-links { display: flex; gap: 1.5rem; list-style: none; }
.footer-links a { font-size: 0.85rem; color: var(--text-secondary); text-decoration: none; }
.footer-links a:hover { color: var(--text); }
.footer-contact { font-family: var(--font-mono); font-size: 0.8rem; color: var(--text-secondary); text-decoration: none; }

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .hero-inner, .heatmap-row { grid-template-columns: 1fr; gap: 3rem; }
  .hero-visual { max-width: 460px; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  nav { padding: 0.8rem 1rem; }
  .nav-hamburger { display: flex; }
  .nav-links {
    position: fixed;
    top: 0; right: -100%;
    width: 280px;
    height: 100vh;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.4rem;
    padding: 5rem 2rem 2rem;
    background: #fff;
    box-shadow: -10px 0 40px rgba(18, 37, 30, 0.12);
    transition: right 0.3s;
  }
  .nav-open .nav-links { right: 0; }
  .nav-links a { font-size: 1rem; }
}

@media (max-width: 768px) {
  section { padding: 4rem 1rem; }
  .hero { padding: 7rem 1rem 4rem; }
  .page-section { padding-top: 6.5rem; }
  h1 { font-size: 2.4rem; letter-spacing: -1px; }
  .section-title, .page-title { font-size: 1.9rem; }
  .steps, .features-grid, .audience-grid, .contact-row { grid-template-columns: 1fr; }
  .hero-actions .btn, .cta-actions .btn { width: 100%; }
  .panel { padding: 1.4rem; }
  .status-panel { flex-direction: column; }
  .map-frame { height: 520px; }
  .sample-grid .rank-dot { width: 58%; font-size: 0.5rem; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
