:root {
  --bg: #07090d;
  --bg-2: #0d1117;
  --panel: #11161e;
  --panel-2: #161c26;
  --line: #222a36;
  --text: #e8edf4;
  --muted: #8b96a8;
  --accent: #3aa0ff;
  --accent-2: #7cc4ff;
  --accent-ink: #04111f;
  --sale: #ff5d5d;
  --ok: #3ddc97;
  --radius: 16px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Space Grotesk", var(--font);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 1.1; margin: 0; letter-spacing: -0.02em; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.eyebrow {
  margin: 0 0 10px;
  font: 600 12px/1 var(--font);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.lead { color: var(--muted); font-size: 1.075rem; max-width: 52ch; }
.accent { color: var(--accent); }

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 22px;
  border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
}
.btn:active { transform: scale(.98); }
.btn-sm { height: 38px; padding: 0 16px; font-size: 14px; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-2); }
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); }

/* Header */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 9, 13, .78);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font: 700 18px/1 var(--display); letter-spacing: .04em; }
.brand svg { width: 30px; height: 30px; color: var(--accent); }
.brand b { color: var(--accent); font-weight: 700; }
.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a { color: var(--muted); font-size: 15px; font-weight: 500; transition: color .15s; }
.nav a:hover { color: var(--text); }
.menu-btn { display: none; }

/* Hero */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero-grid-bg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(58,160,255,.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(58,160,255,.07) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 70% at 70% 45%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 70% 45%, #000 20%, transparent 75%);
}
.hero-inner {
  position: relative;
  display: grid; grid-template-columns: 1.05fr 1fr; align-items: center; gap: 40px;
  padding: 72px 0 80px;
}
.hero h1 { font-size: clamp(2.1rem, 4.2vw, 3.3rem); margin-bottom: 20px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 40px; }
.stats { list-style: none; margin: 0; padding: 0; display: flex; gap: 36px; flex-wrap: wrap; }
.stats li { display: grid; }
.stats strong { font: 700 1.5rem/1.2 var(--display); }
.stats span { color: var(--muted); font-size: 13px; }

.hero-visual { position: relative; aspect-ratio: 1; max-width: 520px; justify-self: center; width: 100%; }
.hero-ring {
  position: absolute; inset: 6%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 45%, rgba(58,160,255,.28), rgba(58,160,255,.04) 60%, transparent 70%);
  border: 1px solid rgba(58,160,255,.18);
}
.hero-ring::after {
  content: ""; position: absolute; inset: -9%;
  border-radius: 50%; border: 1px dashed rgba(58,160,255,.15);
  animation: spin 60s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.hero-visual img {
  position: relative; width: 100%; height: 100%; object-fit: contain;
  border-radius: 28px;
  mix-blend-mode: normal;
  filter: drop-shadow(0 30px 40px rgba(0,0,0,.5));
  animation: float 6s ease-in-out infinite;
}
@keyframes float { 50% { transform: translateY(-10px); } }
.hero-tag {
  position: absolute; left: 0; bottom: 8%;
  background: rgba(17,22,30,.9); border: 1px solid var(--line);
  backdrop-filter: blur(8px);
  border-radius: 14px; padding: 12px 16px;
  font-size: 13px; color: var(--muted);
  max-width: 260px;
}
.hero-tag b { display: block; color: var(--text); font-size: 15px; }
.hero-tag strong { color: var(--accent); font-family: var(--display); font-size: 18px; }
.hero-tag:empty { display: none; }

/* Sello autorizado */
.auth-badge {
  display: inline-flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin: 0 0 18px; padding: 8px 14px;
  border: 1px solid rgba(58,160,255,.35); border-radius: 999px;
  background: rgba(58,160,255,.08);
  font-size: 13px; font-weight: 500; color: var(--text);
}
.auth-badge b { color: var(--accent); font-weight: 700; }
.auth-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(61,220,151,.18); flex: none; }

/* DJI Agriculture */
.agro {
  display: grid; grid-template-columns: 1fr 1.15fr; gap: 40px; align-items: center;
  padding: 48px;
  border: 1px solid var(--line); border-radius: 24px;
  background:
    radial-gradient(circle at 0% 100%, rgba(61,220,151,.12), transparent 45%),
    radial-gradient(circle at 100% 0%, rgba(58,160,255,.16), transparent 50%),
    var(--panel);
}
.agro h2 { margin-bottom: 14px; }
.agro .hero-cta { margin: 26px 0 0; }
.agro-pillars { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pillar {
  display: flex; flex-direction: column; gap: 10px;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px;
}
.pillar-tag {
  align-self: start;
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ok); background: rgba(61,220,151,.1); border-radius: 999px; padding: 5px 10px;
}
.pillar h3 { font-size: 20px; }
.pillar ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 14px; display: grid; gap: 6px; flex: 1; }
.pillar ul li::marker { color: var(--ok); }
.pillar a { color: var(--accent); font-weight: 600; font-size: 14px; }
.footer-auth { color: var(--text); font-weight: 600; }

/* Categorías */
.cats {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px;
  margin-top: -36px; position: relative; z-index: 2;
}
.cat {
  display: grid; gap: 2px; text-align: left;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; cursor: pointer;
  transition: border-color .15s, transform .15s, background .15s;
}
.cat:hover { border-color: var(--accent); transform: translateY(-2px); background: var(--panel-2); }
.cat-ico { color: var(--accent); font-size: 20px; line-height: 1; margin-bottom: 10px; }
.cat b { font-family: var(--display); font-size: 16px; }
.cat small { color: var(--muted); font-size: 12.5px; }

/* Secciones */
.section { padding: 88px 0 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.section h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }

/* Tarjetas de producto */
.card {
  display: flex; flex-direction: column;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
  transition: border-color .15s, transform .15s;
}
.card:hover { border-color: #33415a; transform: translateY(-3px); }
.card-img {
  position: relative; aspect-ratio: 1;
  background: #fff;
}
.card-img img { width: 100%; height: 100%; object-fit: contain; padding: 14px; }
.badge {
  position: absolute; top: 12px; left: 12px;
  background: var(--sale); color: #fff;
  font: 700 12px/1 var(--font); padding: 6px 9px; border-radius: 999px;
}
.badge-out { background: #3a4353; left: auto; right: 12px; }
.card-body { display: flex; flex-direction: column; gap: 6px; padding: 16px 16px 18px; flex: 1; }
.card-serie { color: var(--accent); font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.card h3 { font-size: 16px; line-height: 1.3; font-weight: 600; }
.card h3 a:hover { color: var(--accent); }
.card-img { display: block; }
.card ul { margin: 2px 0 0; padding-left: 16px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.card ul li::marker { color: var(--accent); }
.price { margin: auto 0 0; padding-top: 10px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.price strong { font: 700 22px/1 var(--display); }
.price s { color: var(--muted); font-size: 14px; }
.card-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.card-actions .btn { height: 40px; padding: 0 10px; font-size: 14px; }

.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr);
  gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding-bottom: 10px; scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.rail > * { scroll-snap-align: start; }

/* Catálogo */
.toolbar { display: flex; gap: 12px; margin-bottom: 16px; }
.search {
  flex: 1; display: flex; align-items: center; gap: 10px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 999px;
  padding: 0 18px; height: 50px;
}
.search:focus-within { border-color: var(--accent); }
.search svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; height: 100%; }
.search input::placeholder { color: #5d687a; }
select {
  background: var(--panel); border: 1px solid var(--line); border-radius: 999px;
  height: 50px; padding: 0 18px; cursor: pointer;
}
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.chip {
  background: transparent; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 16px; font-size: 14px; cursor: pointer; color: var(--muted);
  transition: all .15s;
}
.chip:hover { color: var(--text); border-color: #33415a; }
.chip[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }
.result-count { color: var(--muted); font-size: 14px; margin: 0 0 16px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.more { display: flex; justify-content: center; margin-top: 28px; }
.empty { margin: 0; text-align: center; padding: 60px 20px; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); }

/* Servicios */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.service {
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column; gap: 12px;
}
.service-num { font: 700 14px/1 var(--display); color: var(--accent); }
.service h3 { font-size: 22px; }
.service p { color: var(--muted); margin: 0; flex: 1; }
.service a { color: var(--accent); font-weight: 600; }
.service a:hover { color: var(--accent-2); }

/* Contacto */
.contact {
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center;
  background:
    radial-gradient(circle at 100% 0%, rgba(58,160,255,.18), transparent 50%),
    var(--panel);
  border: 1px solid var(--line); border-radius: 24px;
  padding: 48px;
}
.contact-cards { display: grid; gap: 12px; }
.contact-card {
  display: grid; gap: 2px;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px;
  transition: border-color .15s;
}
.contact-card:hover { border-color: var(--accent); }
.contact-card small { color: var(--accent); font-weight: 600; text-transform: uppercase; letter-spacing: .1em; font-size: 11px; }
.contact-card b { font: 700 22px/1.3 var(--display); }
.contact-card a:last-child { color: var(--muted); font-size: 14px; }
.contact-card a:hover { color: var(--accent); }

/* Footer */
.footer { margin-top: 96px; border-top: 1px solid var(--line); background: var(--bg-2); }
.footer-inner { display: flex; justify-content: space-between; gap: 32px; padding: 40px 0 24px; flex-wrap: wrap; }
.footer-inner p { color: var(--muted); font-size: 14px; max-width: 46ch; }
.footer-about { flex: 1 1 280px; }
.footer-col { display: grid; gap: 8px; align-content: start; min-width: 180px; }
.footer-col h2 { font: 600 12px/1 var(--font); letter-spacing: .14em; text-transform: uppercase; color: var(--text); margin: 6px 0 6px; }
.footer-col a { color: var(--muted); font-size: 14px; }
.footer-col a:hover { color: var(--text); }
.footer-inner p a { color: var(--accent); }
.footer-links { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: start; }
.footer-links a { color: var(--muted); font-size: 14px; }
.footer-links a:hover { color: var(--text); }
.legal { border-top: 1px solid var(--line); padding: 18px 0 28px; }
.legal p { margin: 0; color: #5d687a; font-size: 12.5px; }

.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 40;
  width: 56px; height: 56px; border-radius: 50%;
  display: grid; place-items: center;
  background: #25d366; color: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.45);
  transition: transform .15s;
}
.wa-float:hover { transform: scale(1.06); }
.wa-float svg { width: 28px; height: 28px; }

/* Responsive */
@media (max-width: 1024px) {
  .cats { grid-template-columns: repeat(3, 1fr); }
  .agro { grid-template-columns: 1fr; }
  .services { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .topbar-inner { gap: 12px; }
  .topbar-inner > .btn { margin-left: auto; }
  .menu-btn {
    display: grid; gap: 6px; place-content: center;
    width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 12px;
    background: none; cursor: pointer;
  }
  .menu-btn span { display: block; width: 18px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .2s; }
  .menu-btn[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .menu-btn[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
  .nav {
    position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 16px 16px;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 17px; color: var(--text); }
  .hero-inner { grid-template-columns: 1fr; padding: 40px 0 72px; gap: 24px; }
  .hero-visual { max-width: 280px; }
  .contact { grid-template-columns: 1fr; padding: 28px; }
  .agro { padding: 28px; }
  .agro-pillars { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .cats { grid-template-columns: repeat(2, 1fr); }
  .toolbar { flex-direction: column; }
  .search { flex: none; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .card-body { padding: 12px; }
  .card h3 { font-size: 14px; }
  .card ul { display: none; }
  .price strong { font-size: 18px; }
  .card-actions { grid-template-columns: 1fr; }
  .rail { grid-auto-columns: 72%; }
  .section { padding-top: 64px; }
  .stats { gap: 24px; }
  .hero-tag { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* Accesibilidad */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 10px 16px; border-radius: 10px; font-weight: 600; }
.skip:focus { top: 12px; }

/* Páginas internas */
.crumbs { padding-top: 22px; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--muted); }
.crumbs li:not(:last-child)::after { content: "/"; margin-left: 6px; opacity: .5; }
.crumbs a:hover { color: var(--accent); }
.crumbs [aria-current] { color: var(--text); }
.page-hero { padding: 36px 0 8px; }
.page-hero h1 { font-size: clamp(2rem, 4.4vw, 3.2rem); margin-bottom: 16px; max-width: 22ch; }
.page-hero .lead { max-width: 70ch; }
.page-hero .hero-cta { margin: 26px 0 0; }
.cats-inline { margin-top: 0; }
.hero-visual { display: block; }
.services-4 { grid-template-columns: repeat(4, 1fr); }

/* Pasos */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: paso; }
.steps li { counter-increment: paso; position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 24px 24px 76px; }
.steps li::before { content: counter(paso); position: absolute; left: 22px; top: 22px; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font: 700 17px/1 var(--display); }
.steps h3 { font-size: 18px; margin-bottom: 6px; }
.steps p { margin: 0; color: var(--muted); font-size: 14px; }

/* Preguntas frecuentes */
.faq { display: grid; gap: 10px; max-width: 880px; }
.faq details { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 22px; }
.faq details[open] { border-color: #33415a; }
.faq summary { cursor: pointer; list-style: none; padding: 18px 28px 18px 0; position: relative; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%); color: var(--accent); font-size: 22px; font-weight: 400; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0 0 18px; color: var(--muted); }

/* Ficha de producto */
.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; padding-top: 24px; align-items: start; }
.product-media { position: relative; background: #fff; border-radius: 24px; overflow: hidden; aspect-ratio: 1; }
.product-media img { width: 100%; height: 100%; object-fit: contain; padding: 24px; }
.product-info { display: flex; flex-direction: column; gap: 14px; }
.product-info h1 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
.product-info .hero-cta { margin: 8px 0 0; }
.product-info .auth-badge { align-self: start; margin: 0; }
.price-lg { padding: 0; }
.price-lg strong { font-size: 34px; }
.stock { margin: 0; font-size: 14px; color: var(--muted); }
.stock-ok { color: var(--ok); }
.features { margin: 0; padding: 18px 18px 18px 36px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); color: var(--muted); display: grid; gap: 6px; font-size: 15px; }
.features li::marker { color: var(--accent); }
.product-note { margin: 0; font-size: 13px; color: var(--muted); }
.product-note a { color: var(--accent); }

@media (max-width: 1024px) {
  .services-4 { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .product { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 560px) {
  .services-4 { grid-template-columns: 1fr; }
  .footer-col { min-width: 0; flex: 1 1 100%; }
  .product-info .hero-cta .btn { width: 100%; }
}
