/* Shared styles — ovejanegra.group */

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

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--white);
  color: var(--dark);
  line-height: 1.6;
}

nav {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 48px;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

section { padding: 80px 48px; }
.container { max-width: 1100px; margin: 0 auto; }

.section-label {
  display: block;
  font-size: 12px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; margin-bottom: 16px; }
.section-sub { font-size: 1rem; color: var(--mid); margin-bottom: 48px; }

.btn-whatsapp {
  display: inline-flex; align-items: center; gap: 8px;
  background: #25d366; color: #fff;
  padding: 13px 24px; border-radius: 10px;
  font-size: 15px; font-weight: 700;
  text-decoration: none;
  transition: background .2s, transform .15s;
}
.btn-whatsapp:hover { background: #1ebe5d; transform: translateY(-1px); }

.social-links { display: flex; gap: 12px; }

.social-link {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 8px;
  background: var(--light); border: 1px solid var(--border);
  color: var(--mid);
  text-decoration: none;
  transition: background .2s, color .2s, border-color .2s;
}
.social-link[title*="WhatsApp"] { background: #25d366; border-color: #25d366; color: #fff; }
.social-link[title*="WhatsApp"]:hover { background: #1ebe5d; border-color: #1ebe5d; color: #fff; }
.social-link[title*="Facebook"] { background: #1877f2; border-color: #1877f2; color: #fff; }
.social-link[title*="Facebook"]:hover { background: #1464d8; border-color: #1464d8; color: #fff; }
.social-link[title*="Instagram"] { background: #e1306c; border-color: #e1306c; color: #fff; }
.social-link[title*="Instagram"]:hover { background: #c72760; border-color: #c72760; color: #fff; }
.social-link[title*="TikTok"] { background: #000; border-color: #000; color: #fff; }
.social-link[title*="TikTok"]:hover { background: #222; border-color: #222; color: #fff; }

footer {
  background: var(--dark); color: rgba(255,255,255,.45);
  text-align: center; padding: 24px 48px;
  font-size: 13px;
}
footer a { color: rgba(255,255,255,.45); text-decoration: none; }
footer a:hover { color: #fff; }

.wa-float { position: fixed; bottom: 28px; right: 28px; z-index: 500; }

.wa-float-btn {
  width: 58px; height: 58px; border-radius: 50%;
  background: #25d366; color: #fff;
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.5);
  text-decoration: none;
  transition: background .2s, transform .2s;
}
.wa-float-btn:hover { background: #1ebe5d; }

@media (max-width: 768px) {
  nav { padding: 14px 20px; }
  section { padding: 52px 20px; }
  footer { padding: 20px; }
}

/* ---- Model hero modifier ---- */
.hero--model { padding: 52px 48px 44px; }
.model-hero-badge-row { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.model-hero-price { font-size: 2rem; font-weight: 800; margin: 16px 0 32px; }
.model-hero-price span { display: block; font-size: 0.9rem; font-weight: 400; opacity: .65; margin-top: 4px; }
@media (max-width: 768px) {
  .hero--model { padding: 40px 20px 36px; }
  .model-hero-price { font-size: 1.6rem; }
}

/* ---- Specs layout ---- */
.specs-section { background: var(--light); }
.specs-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 48px;
  align-items: start;
}
.specs-table { width: 100%; border-collapse: collapse; margin-top: 24px; }
.specs-table th,
.specs-table td { padding: 12px 16px; text-align: left; font-size: 0.9rem; border-bottom: 1px solid var(--border); }
.specs-table th { font-weight: 600; color: var(--mid); width: 42%; background: var(--white); }
.specs-table td { background: var(--white); }
.specs-table tr:first-child th,
.specs-table tr:first-child td { border-top: 1px solid var(--border); border-radius: 8px 8px 0 0; }
.specs-official-link { display: inline-block; margin-top: 16px; font-size: 0.85rem; color: var(--mid); text-decoration: none; }
.specs-official-link:hover { color: var(--accent); }
.specs-disclaimer { margin-top: 20px; font-size: 0.76rem; color: var(--mid); line-height: 1.55; opacity: .75; border-top: 1px solid var(--border); padding-top: 14px; }
@media (max-width: 900px) { .specs-layout { grid-template-columns: 1fr; } }

/* ---- Out-of-stock model card ---- */
.model-card { position: relative; }
.model-card-media { position: relative; }
.model-card--out { opacity: 0.78; }
.model-card--out .stock-badge--out { visibility: hidden; }
.model-card--out .model-card-footer { color: var(--mid); font-weight: 500; }

/* Corner ribbon */
.model-card--out::after {
  content: "Agotado";
  position: absolute;
  top: 26px;
  right: -250px;
  width: 600px;
  padding: 11px 0;
  background: #b91c1c;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .07em;
  text-align: center;
  transform: rotate(45deg);
  z-index: 3;
  pointer-events: none;
}

/* ---- Dealer value + highlights ---- */
.dealer-value, .model-highlights {
  background: var(--white);
  border-radius: 14px;
  padding: 24px;
  border: 1px solid var(--border);
  margin-bottom: 20px;
}
.dealer-value h3, .model-highlights h3 { font-size: 0.95rem; font-weight: 700; margin-bottom: 14px; }
.dealer-value ul, .model-highlights ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.dealer-value li, .model-highlights li { font-size: 0.88rem; color: var(--mid); padding-left: 22px; position: relative; line-height: 1.5; }
.dealer-value li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.model-highlights li::before { content: "→"; position: absolute; left: 0; color: var(--accent); }

/* ---- FAQs ---- */
.faqs-section { background: var(--white); }
.faq-list { display: flex; flex-direction: column; gap: 8px; margin-top: 32px; }
.faq-item { background: var(--light); border-radius: 12px; border: 1px solid var(--border); overflow: hidden; }
.faq-item summary {
  padding: 18px 20px;
  font-weight: 600; font-size: 0.95rem;
  cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.2rem; color: var(--accent); flex-shrink: 0; }
.faq-item[open] summary::after { content: "−"; }
.faq-item p { padding: 0 20px 18px; font-size: 0.9rem; color: var(--mid); line-height: 1.7; }

/* ---- Out-of-stock hero ribbon ---- */
.hero--out { position: relative; overflow: hidden; }
.hero--out::after {
  content: "Agotado";
  position: absolute;
  top: 44px;
  right: -80px;
  width: 340px;
  padding: 16px 0;
  background: rgba(185, 28, 28, 0.88);
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .1em;
  text-align: center;
  transform: rotate(45deg);
  z-index: 3;
  pointer-events: none;
}

/* ---- Brand model rows (horizontal scroll) ---- */
.brand-models-section { padding-bottom: 0; }
.brand-cat-row { margin-bottom: 40px; }
.brand-cat-row-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.brand-cat-row-header h3 { font-size: 1.2rem; font-weight: 800; margin: 0; }
.brand-cat-row-link {
  font-size: 0.85rem; font-weight: 700; color: var(--accent);
  text-decoration: none; white-space: nowrap;
  transition: opacity .15s;
}
.brand-cat-row-link:hover { opacity: .75; }
.brand-cat-container { overflow: hidden; }
.brand-cat-scroll {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 0 16px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.brand-cat-scroll::after {
  content: '';
  flex: 0 0 4px;
}
.brand-cat-scroll::-webkit-scrollbar { display: none; }
.brand-model-card {
  flex: 0 0 240px;
  background: var(--white);
  border-radius: 14px;
  border: 1px solid var(--border);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  scroll-snap-align: start;
  transition: box-shadow .2s, transform .2s;
  position: relative;
}
.brand-model-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,.1); transform: translateY(-2px); }
.brand-model-card--out { opacity: .75; }
.brand-model-card-img {
  position: relative;
  background: var(--light);
  height: 170px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.brand-model-card-img img { width: 100%; height: 100%; object-fit: contain; padding: 8px; box-sizing: border-box; }
.brand-model-card-icon { font-size: 3rem; }
.brand-model-card-badge {
  position: absolute; bottom: 8px; left: 8px;
  background: #b91c1c; color: #fff;
  font-size: 10px; font-weight: 700; text-transform: uppercase;
  padding: 2px 8px; border-radius: 99px;
}
.brand-model-card-body { padding: 12px 14px; }
.brand-model-card-name { font-size: 0.88rem; font-weight: 700; margin: 0 0 4px; }
.brand-model-card-price { font-size: 0.82rem; font-weight: 600; color: var(--accent); margin: 0; }
.brand-cat-scroll--single { justify-content: center; overflow-x: visible; }
.brand-cat-scroll--single::after { display: none; }
@media (max-width: 768px) {
  .brand-cat-scroll--single { justify-content: flex-start; overflow-x: auto; }
  .brand-model-card { flex: 0 0 160px; }
  .brand-model-card-img { height: 120px; }
}
@media (max-width: 480px) {
  .brand-cat-row-header { flex-direction: column; align-items: flex-start; gap: 4px; }
  .brand-cat-row-header h3 { font-size: 1rem; }
  .brand-cat-scroll { gap: 12px; }
  .brand-model-card { flex: 0 0 130px; }
  .brand-model-card-img { height: 100px; }
  .brand-model-card-body { padding: 8px 10px; }
  .brand-model-card-name { font-size: 0.8rem; }
  .brand-model-card-price { font-size: 0.75rem; }
}

/* ---- Stock disclaimer ---- */
.stock-disclaimer {
  margin-top: 20px;
  font-size: 0.78rem;
  color: var(--mid);
  text-align: center;
}
.stock-disclaimer a { color: var(--mid); }
.stock-disclaimer a:hover { color: var(--accent); }

.stock-disclaimer--hero {
  margin-top: 16px;
  font-size: 0.78rem;
  opacity: .6;
}

/* ---- Category card as link ---- */
a.cat-card { text-decoration: none; color: inherit; display: block; }

/* ---- Category hero modifier ---- */
.hero--category { padding: 64px 48px 52px; }
.cat-hero-icon { font-size: 3.5rem; margin-bottom: 16px; }
@media (max-width: 768px) { .hero--category { padding: 48px 20px 40px; } }

/* ---- Category hero split layout ---- */
.hero--split {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  align-items: center;
}
.hero--split .hero-split-text { text-align: center; }
.hero--split .hero-split-text p { margin-left: auto; margin-right: auto; max-width: none; }
.hero--split .hero-split-text .hero-ctas { justify-content: center; }
.hero-split-img {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 8px 40px rgba(0,0,0,.12);
  padding: 24px;
  display: flex; align-items: center; justify-content: center;
  width: 100%;
}
.hero-split-img img {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
  display: block;
}
@media (max-width: 768px) {
  .hero--split { grid-template-columns: 1fr; }
  .hero--split .hero-split-text { text-align: center; }
  .hero--split .hero-split-text p { margin-left: auto; margin-right: auto; }
  .hero--split .hero-split-text .hero-ctas { justify-content: center; }
  .hero-split-img { display: none; }
}


/* ---- Models grid ---- */
.models-section { background: var(--light); }
.models-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}
.model-card {
  background: var(--white);
  border-radius: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s, transform .2s;
}
.model-card-header { padding: 16px 16px 0; display: flex; justify-content: flex-end; }
.model-card-placeholder { font-size: 5rem; text-align: center; padding: 24px 0; }
.model-card-img { width: 100%; height: 300px; object-fit: contain; background: #f8f9fa; }
.model-card-body { padding: 20px; flex: 1; }
.model-card-body h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 6px; }
.model-card-body > p { color: var(--mid); font-size: 0.88rem; }
.model-price { font-size: 1rem; font-weight: 700; color: var(--dark); margin-top: 12px; }
.model-price span { font-weight: 400; font-size: 0.8rem; color: var(--mid); display: block; }
.model-card-footer { padding: 16px 20px; border-top: 1px solid var(--border); font-size: 0.88rem; font-weight: 600; }

/* ---- Stock badge ---- */
.stock-badge {
  display: inline-block;
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
  padding: 3px 10px; border-radius: 99px;
}
.stock-badge--in  { background: #2e7d32; color: #fff; border: 1.5px solid #2e7d32; box-shadow: 0 0 0 0 rgba(46,125,50,.5); animation: stock-pulse 2s ease-in-out infinite; }
.stock-badge--out { background: #f5f5f5; color: #757575; }
@keyframes stock-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(46,125,50,.45); }
  60%  { box-shadow: 0 0 0 6px rgba(46,125,50,0); }
  100% { box-shadow: 0 0 0 0 rgba(46,125,50,0); }
}

/* ---- Use cases ---- */
.use-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.use-card {
  background: var(--white);
  border-radius: 14px;
  padding: 28px 22px;
  border: 1px solid var(--border);
}
.use-icon { font-size: 2rem; margin-bottom: 14px; }
.use-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 8px; }
.use-card p { color: var(--mid); font-size: 0.88rem; }

/* ---- No models state ---- */
.no-models {
  text-align: center;
  padding: 48px 24px;
  background: var(--white);
  border-radius: 16px;
  border: 1px solid var(--border);
}
.no-models p { color: var(--mid); margin-bottom: 24px; }

@media (max-width: 768px) {
  .models-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .models-grid { grid-template-columns: 1fr; }
}

/* ---- Related models ---- */
.related-section { padding: 56px 0; background: var(--light); }
.related-section h2 { margin-bottom: 32px; }

/* ---- Model photo gallery (CSS-only, no JS) ---- */
.model-gallery-section { padding: 0 0 48px; }
.model-gallery { position: relative; }
.gallery-radio { position: absolute; opacity: 0; pointer-events: none; }
.gallery-stage { position: relative; border-radius: 16px; overflow: hidden; background: #fff; border: 1px solid var(--border); }
.gallery-slide { display: none; margin: 0; }
.gallery-slide img { width: 100%; height: 420px; object-fit: contain; display: block; padding: 16px; box-sizing: border-box; }
.gallery-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 2; background: rgba(255,255,255,.85); border: 1px solid var(--border);
  border-radius: 50%; width: 40px; height: 40px; font-size: 1.4rem; line-height: 1;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--dark); transition: background .15s, opacity .15s;
  padding: 0;
}
.gallery-arrow:hover { background: #fff; }
.gallery-arrow--prev { left: 10px; }
.gallery-arrow--next { right: 10px; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; }
.gallery-thumb { flex: 1; cursor: pointer; border-radius: 10px; overflow: hidden; border: 2.5px solid var(--border); background: #fff; transition: border-color .15s, opacity .15s; opacity: .55; }
.gallery-thumb img { width: 100%; height: 88px; object-fit: contain; display: block; padding: 6px; box-sizing: border-box; }

/* Show the selected slide */
#gallery-0:checked  ~ .gallery-stage .gallery-slide:nth-of-type(1),
#gallery-1:checked  ~ .gallery-stage .gallery-slide:nth-of-type(2),
#gallery-2:checked  ~ .gallery-stage .gallery-slide:nth-of-type(3),
#gallery-3:checked  ~ .gallery-stage .gallery-slide:nth-of-type(4),
#gallery-4:checked  ~ .gallery-stage .gallery-slide:nth-of-type(5),
#gallery-5:checked  ~ .gallery-stage .gallery-slide:nth-of-type(6),
#gallery-6:checked  ~ .gallery-stage .gallery-slide:nth-of-type(7),
#gallery-7:checked  ~ .gallery-stage .gallery-slide:nth-of-type(8),
#gallery-8:checked  ~ .gallery-stage .gallery-slide:nth-of-type(9),
#gallery-9:checked  ~ .gallery-stage .gallery-slide:nth-of-type(10),
#gallery-10:checked ~ .gallery-stage .gallery-slide:nth-of-type(11),
#gallery-11:checked ~ .gallery-stage .gallery-slide:nth-of-type(12) { display: block; }

/* Highlight the active thumbnail */
#gallery-0:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(1),
#gallery-1:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(2),
#gallery-2:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(3),
#gallery-3:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(4),
#gallery-4:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(5),
#gallery-5:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(6),
#gallery-6:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(7),
#gallery-7:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(8),
#gallery-8:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(9),
#gallery-9:checked  ~ .gallery-thumbs .gallery-thumb:nth-child(10),
#gallery-10:checked ~ .gallery-thumbs .gallery-thumb:nth-child(11),
#gallery-11:checked ~ .gallery-thumbs .gallery-thumb:nth-child(12) { border-color: var(--accent); opacity: 1; }

@media (max-width: 768px) {
  .gallery-slide img { height: 280px; padding: 12px; }
  .gallery-thumb img { height: 68px; }
}
@media (max-width: 480px) {
  .gallery-arrow { display: none; }
  .gallery-slide img { height: 220px; }
  .gallery-thumb img { height: 56px; }
  .gallery-thumbs { gap: 5px; }
}
