:root {
  --brand-red: #960a24;
  --brand-red-dark: #6e0819;
  --brand-red-light: #c21432;
  --brand-black: #111111;
  --brand-black-soft: #1f1f1f;
  --brand-gray-50: #f7f7f8;
  --brand-gray-100: #eeeeef;
  --brand-gray-500: #6c6f75;
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--brand-black);
  background-color: #fff;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: -0.01em;
}

a { color: var(--brand-red); text-decoration: none; }
a:hover { color: var(--brand-red-dark); }

section { scroll-margin-top: 84px; }

/* ---------- Buttons ---------- */
.btn-brand {
  background-color: var(--brand-red);
  border-color: var(--brand-red);
  color: #fff;
  font-weight: 600;
}
.btn-brand:hover, .btn-brand:focus {
  background-color: var(--brand-red-dark);
  border-color: var(--brand-red-dark);
  color: #fff;
}
.btn-outline-brand {
  border: 2px solid #fff;
  color: #fff;
  font-weight: 600;
}
.btn-outline-brand:hover {
  background-color: #fff;
  color: var(--brand-black);
}

/* ---------- Header / Nav ---------- */
.site-header {
  background-color: var(--brand-black);
  border-bottom: 3px solid var(--brand-red);
}
.navbar-brand .brand-text {
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
}
.navbar-brand .brand-plus { color: var(--brand-red-light); }
.navbar .nav-link {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
  font-size: 0.95rem;
}
.navbar .nav-link:hover,
.navbar .nav-link:focus { color: #fff; }
.navbar-toggler {
  border-color: rgba(255, 255, 255, 0.4);
}
.navbar-toggler-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255,255,255,0.9)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ---------- Hero / Carousel ---------- */
.hero-carousel { position: relative; background-color: var(--brand-black); }
.hero-slide {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
}
.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(17, 17, 17, 0.88) 0%, rgba(17, 17, 17, 0.55) 45%, rgba(150, 10, 36, 0.45) 100%);
}
.hero-content {
  position: relative;
  z-index: 2;
  color: #fff;
  max-width: 720px;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--brand-red-light);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}
.hero-eyebrow::before {
  content: "";
  display: inline-block;
  width: 2.5rem;
  height: 2px;
  background: var(--brand-red-light);
}
.hero-content h1 {
  font-size: clamp(2.1rem, 5vw, 3.5rem);
  line-height: 1.1;
  margin-bottom: 1rem;
}
.hero-content p {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 2rem;
}
.hero-carousel .carousel-indicators [data-bs-target] {
  background-color: var(--brand-red-light);
  width: 34px;
  height: 4px;
}
.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next {
  width: 4rem;
  opacity: 0.8;
}

/* ---------- Section headers ---------- */
.section-heading { margin-bottom: 3rem; }
.section-eyebrow {
  color: var(--brand-red);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: clamp(1.05rem, 2.2vw, 1.4rem);
  display: inline-block;
}
.section-heading h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
.section-divider {
  width: 64px;
  height: 4px;
  background: var(--brand-red);
  margin: 1rem auto 0;
  border-radius: 2px;
}
.section-heading:not(.text-center) .section-divider { margin-left: 0; }

.bg-soft { background-color: var(--brand-gray-50); }
.bg-black { background-color: var(--brand-black); }

/* ---------- About / Sobre nosotros ---------- */
.about-card {
  background: #fff;
  border-radius: 16px;
  padding: 2rem 1.75rem;
  height: 100%;
  box-shadow: 0 10px 30px rgba(17, 17, 17, 0.06);
  border: 1px solid var(--brand-gray-100);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.about-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px rgba(150, 10, 36, 0.14);
}
.about-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--brand-red);
  color: #fff;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
}
.about-card h3 { font-size: 1.15rem; margin-bottom: 0.6rem; }
.about-card p { color: var(--brand-gray-500); margin-bottom: 0; }

.stat-strip { border-top: 1px solid var(--brand-gray-100); border-bottom: 1px solid var(--brand-gray-100); }
.stat-item h3 {
  color: var(--brand-red);
  font-size: 2.2rem;
  margin-bottom: 0.25rem;
}
.stat-item p { color: var(--brand-gray-500); margin-bottom: 0; font-weight: 600; }

/* ---------- CTA brochure ---------- */
.cta-banner {
  background: linear-gradient(120deg, var(--brand-black) 0%, var(--brand-black-soft) 60%, var(--brand-red-dark) 130%);
  border-radius: 20px;
  color: #fff;
  padding: 3rem;
}
.cta-banner h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
.cta-banner p { color: rgba(255, 255, 255, 0.8); }

/* ---------- Services ---------- */
.service-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  height: 340px;
  display: block;
  isolation: isolate;
}
.service-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.service-card:hover img { transform: scale(1.08); }
.service-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17,17,17,0.05) 40%, rgba(17,17,17,0.92) 100%);
}
.service-card .service-body {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 2;
  padding: 1.5rem;
  color: #fff;
}
.service-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--brand-red);
  font-weight: 700;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}
.service-card h3 { font-size: 1.15rem; margin-bottom: 0; }

/* ---------- Portfolio ---------- */
.portfolio-item {
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  aspect-ratio: 4 / 3;
  cursor: pointer;
}
.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.portfolio-item:hover img { transform: scale(1.06); }
.portfolio-item .zoom-hint {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: #fff;
  background: rgba(17, 17, 17, 0.35);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}
.portfolio-item:hover .zoom-hint,
.portfolio-item:focus-visible .zoom-hint { opacity: 1; }

/* ---------- Clients (sliding marquee) ---------- */
.clients-marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.clients-track {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  width: max-content;
  animation: clients-scroll 28s linear infinite;
}
.clients-marquee:hover .clients-track { animation-play-state: paused; }
.client-logo {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  width: 190px;
  height: 110px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid var(--brand-gray-100);
}
.client-logo img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(35%);
  transition: filter 0.25s ease;
}
.client-logo:hover img { filter: grayscale(0%); }

@keyframes clients-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Contact ---------- */
.contact-section {
  position: relative;
  background-size: cover;
  background-position: center;
  color: #fff;
}
.contact-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(17, 17, 17, 0.86);
}
.contact-section .container { position: relative; z-index: 2; }
.contact-info-list { list-style: none; padding: 0; margin: 0; }
.contact-info-list li {
  display: flex;
  gap: 0.75rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.contact-info-list i { color: var(--brand-red-light); font-size: 1.2rem; margin-top: 0.1rem; }

.contact-form-card {
  background: #fff;
  border-radius: 18px;
  padding: 2rem;
  color: var(--brand-black);
}
.contact-form-card .form-label { font-weight: 600; }
.contact-form-card .form-control:focus {
  border-color: var(--brand-red);
  box-shadow: 0 0 0 0.2rem rgba(150, 10, 36, 0.15);
}
.field-website { position: absolute; left: -9999px; top: -9999px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--brand-black); color: rgba(255, 255, 255, 0.75); }
.footer-heading { color: #fff; font-weight: 700; margin-bottom: 1rem; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.06em; }
.footer-links { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-links a, .footer-links li { color: rgba(255, 255, 255, 0.7); font-size: 0.92rem; }
.footer-links a:hover { color: #fff; }
.footer-muted { color: rgba(255, 255, 255, 0.6); }
.footer-divider { border-color: rgba(255, 255, 255, 0.12); margin: 2.5rem 0 1.5rem; }
.social-list { margin: 0; padding: 0; }
.social-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.1rem;
  transition: background 0.2s ease, color 0.2s ease;
}
.social-icon:hover { background: var(--brand-red); color: #fff; }

/* ---------- Service modal ---------- */
.modal-service-img {
  max-height: 380px;
  object-fit: cover;
}

/* ---------- Portfolio lightbox ---------- */
.lightbox-modal .modal-dialog { max-width: 92vw; }
.lightbox-modal .modal-content {
  align-items: center;
  justify-content: center;
}
.lightbox-img {
  max-width: 100%;
  max-height: 86vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.lightbox-close {
  position: absolute;
  top: -2.5rem;
  right: 0;
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox-nav:hover { background: rgba(255, 255, 255, 0.3); }
.lightbox-prev { left: -1.5rem; }
.lightbox-next { right: -1.5rem; }

@media (max-width: 767.98px) {
  .lightbox-prev { left: 0.25rem; }
  .lightbox-next { right: 0.25rem; }
  .lightbox-close { top: 0.5rem; right: 0.5rem; }
}

/* ---------- WhatsApp floating button ---------- */
.whatsapp-float {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 1050;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
  animation: whatsapp-pulse 2.4s infinite;
}
.whatsapp-float:hover { color: #fff; background: #1ebe5b; }

@keyframes whatsapp-pulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5), 0 8px 24px rgba(0,0,0,0.28); }
  70% { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0), 0 8px 24px rgba(0,0,0,0.28); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0), 0 8px 24px rgba(0,0,0,0.28); }
}

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {
  .navbar-collapse { background: var(--brand-black); margin-top: 0.75rem; padding: 1rem; border-radius: 12px; }
  section { scroll-margin-top: 70px; }
}

@media (max-width: 767.98px) {
  .hero-slide { min-height: 78vh; text-align: center; }
  .hero-content { max-width: 100%; }
  .cta-banner { padding: 2rem 1.25rem; text-align: center; }
  .whatsapp-float { width: 52px; height: 52px; font-size: 1.6rem; right: 1rem; bottom: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .whatsapp-float { animation: none; }
  .service-card img, .portfolio-item img { transition: none; }
  .clients-track { animation: none; }
}
