:root {
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --blue-light: #eaf1ff;
  --navy: #0f1f3d;
  --ink: #0f172a;
  --gray: #64748b;
  --light: #f6f9fe;
  --white: #ffffff;
  --border: #e6ecf5;
  --radius: 18px;
  --font: 'Poppins', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--ink);
  line-height: 1.65;
  background: var(--white);
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
}

h1, h2, h3 { font-weight: 700; line-height: 1.2; color: var(--navy); }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

.eyebrow {
  display: inline-block;
  color: var(--blue);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.muted { color: var(--gray); }

.section { padding: 120px 0; }

.section-head {
  max-width: 640px;
  margin: 0 auto 64px;
  text-align: center;
}
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); margin-bottom: 16px; }
.section-head p { font-size: 1.05rem; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 15px 30px;
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 2px solid transparent;
}
.btn-primary {
  background: var(--blue);
  color: var(--white);
  box-shadow: 0 10px 24px rgba(37,99,235,0.28);
}
.btn-primary:hover { background: var(--blue-dark); transform: translateY(-2px); }
.btn-ghost {
  background: var(--white);
  color: var(--navy);
  border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--blue); color: var(--blue); }
.btn-small { padding: 11px 22px; font-size: 0.85rem; }
.btn-full { width: 100%; }

/* Header */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 1000;
}
.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 1.05rem;
  letter-spacing: 0.3px;
  color: var(--navy);
}
.logo-mark { width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0; }
.logo-text { line-height: 1.25; }
.logo-text small { display: block; font-size: 0.68rem; font-weight: 600; color: var(--blue); letter-spacing: 0.4px; }
.footer-grid .logo-text small { color: rgba(255,255,255,0.65); }
#navMenu {
  display: flex;
  align-items: center;
  gap: 36px;
}
#navMenu ul { display: flex; gap: 30px; }
#navMenu a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink);
  transition: color 0.2s;
}
#navMenu a:hover { color: var(--blue); }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--navy);
}

/* Hero */
.hero {
  padding: 180px 0 100px;
  background:
    linear-gradient(100deg, rgba(8,18,45,0.68) 0%, rgba(8,18,45,0.35) 55%, rgba(8,18,45,0.10) 100%),
    url('img/calidad3.jpg') center/cover no-repeat;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-text h1 {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  margin-bottom: 22px;
  color: #ffffff;
}
.hero-text .accent { color: #60a5fa; }
.hero-text p {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.82);
  max-width: 480px;
  margin-bottom: 34px;
}
.hero-actions { display: flex; gap: 16px; margin-bottom: 50px; flex-wrap: wrap; }
.hero-trust { display: flex; gap: 40px; }
.hero-trust div { display: flex; flex-direction: column; }
.hero-trust strong { font-size: 1.5rem; color: #ffffff; font-weight: 800; }
.hero-trust span { font-size: 0.82rem; color: rgba(255,255,255,0.7); }

.hero .eyebrow { color: #93c5fd; }
.hero .btn-ghost {
  background: transparent;
  color: #ffffff;
  border-color: rgba(255,255,255,0.55);
}
.hero .btn-ghost:hover { border-color: #ffffff; background: rgba(255,255,255,0.12); color: #ffffff; }

.hero-media { position: relative; }
.hero-media > img {
  width: 100%;
  height: 480px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: 0 30px 60px rgba(15,31,61,0.18);
}
.hero-media-card {
  position: absolute;
  bottom: -36px;
  left: -36px;
  width: 180px;
  border-radius: 14px;
  overflow: hidden;
  border: 6px solid var(--white);
  box-shadow: 0 20px 40px rgba(15,31,61,0.2);
}
.hero-media-card img { height: 130px; object-fit: cover; }

/* Features / Services */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
  margin-bottom: 80px;
}
.feature-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 28px;
  transition: transform 0.25s, box-shadow 0.25s;
  overflow: hidden;
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(15,31,61,0.08);
}
.feature-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.feature-card p { color: var(--gray); font-size: 0.92rem; }

/* Feature cards with photo */
.feature-card-img {
  padding: 0;
  display: flex;
  flex-direction: column;
  cursor: pointer;
}
.feature-card-photo {
  width: 100%;
  height: 180px;
  background-size: cover;
  background-position: center;
  border-radius: var(--radius) var(--radius) 0 0;
  transition: transform 0.4s ease;
  flex-shrink: 0;
  overflow: hidden;
}
.feature-card-img:hover .feature-card-photo { transform: scale(1.05); }
.feature-card-body { padding: 24px 24px 28px; flex: 1; }

.card-tap-hint {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.78rem;
  color: var(--blue);
  font-weight: 600;
  letter-spacing: 0.5px;
  opacity: 0.8;
}

/* Service photos modal grid */
.service-modal-box { max-width: 900px; }
.service-modal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 20px 24px 24px;
  overflow-y: auto;
}
.service-modal-grid img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 12px;
  display: block;
  transition: transform 0.3s ease;
}
.service-modal-grid img:hover { transform: scale(1.04); cursor: zoom-in; }
@media (max-width: 600px) {
  .service-modal-grid { grid-template-columns: 1fr; }
}


.icon-circle {
  width: 56px; height: 56px;
  border-radius: 16px;
  background: var(--blue-light);
  color: var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.icon-circle svg { width: 26px; height: 26px; }
.icon-circle.small { width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0; }
.icon-circle.small svg { width: 20px; height: 20px; }

/* Profile catalog */
.profiles { background: var(--light); }
.profiles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.profile-chip {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 20px;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.profile-chip:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px rgba(15,31,61,0.08);
  border-color: var(--blue);
}
.profile-chip h4 { font-size: 0.98rem; margin-bottom: 2px; }
.profile-chip span { font-size: 0.8rem; color: var(--gray); }

.profiles-note {
  text-align: center;
  margin-top: 36px;
  color: var(--gray);
  font-size: 0.95rem;
}
.profiles-note a { color: var(--blue); font-weight: 600; }
.profiles-note a:hover { text-decoration: underline; }

.custom-cta {
  margin-top: 40px;
  background: linear-gradient(135deg, var(--navy) 0%, #1e3a6e 100%);
  border-radius: 20px;
  padding: 32px 36px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.custom-cta-icon {
  width: 64px;
  height: 64px;
  background: rgba(255,255,255,0.12);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7eb3ff;
  flex-shrink: 0;
}
.custom-cta-text { flex: 1; min-width: 200px; }
.custom-cta-text h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 6px;
}
.custom-cta-text p {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.65);
  line-height: 1.6;
}
.custom-cta .btn-primary {
  background: var(--blue);
  flex-shrink: 0;
  white-space: nowrap;
}
.custom-cta .btn-primary:hover { background: #3b82f6; transform: translateY(-2px); }

.profile-chip[data-modal-img] { cursor: pointer; }
.chip-hint {
  margin-left: auto;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--blue);
  opacity: 0;
  transition: opacity 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.profile-chip:hover .chip-hint { opacity: 1; }

/* Modal */
.catalog-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,31,61,0.75);
  backdrop-filter: blur(6px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.catalog-modal.open { display: flex; }
.catalog-modal-box {
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  max-width: 760px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 40px 80px rgba(15,31,61,0.3);
  animation: modalIn 0.25s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(0.94) translateY(16px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.catalog-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy);
  flex-shrink: 0;
}
.catalog-modal-close {
  background: none;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  color: var(--gray);
  padding: 0 4px;
  transition: color 0.2s;
}
.catalog-modal-close:hover { color: var(--navy); }
#catalogModalImg {
  width: 100%;
  display: block;
  max-height: 70vh;
  object-fit: contain;
  background: var(--light);
}

/* Work / Masonry gallery */
.work { background: var(--light); }
.masonry {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 220px;
  gap: 22px;
}
.masonry-item {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(15,31,61,0.08);
}
.masonry-item.tall { grid-row: span 2; }
.masonry-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.masonry-item:hover img { transform: scale(1.06); }
.masonry-item { cursor: pointer; }

/* Work lightbox */
.lightbox { padding: 0; }
.lightbox img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 40px 80px rgba(15,31,61,0.4);
  animation: modalIn 0.25s ease;
}
.lightbox-close,
.lightbox-nav {
  position: fixed;
  background: rgba(255,255,255,0.12);
  border: none;
  color: var(--white);
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.lightbox-close:hover,
.lightbox-nav:hover { background: rgba(255,255,255,0.25); }
.lightbox-close {
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  font-size: 1.8rem;
  line-height: 1;
}
.lightbox-nav {
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  font-size: 1.1rem;
}
.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }
@media (max-width: 640px) {
  .lightbox-nav { width: 42px; height: 42px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-close { top: 12px; right: 12px; }
}

/* Profile / About */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 70px;
  align-items: center;
}
.profile-media img {
  border-radius: var(--radius);
  height: 460px;
  width: 100%;
  object-fit: cover;
  box-shadow: 0 30px 60px rgba(15,31,61,0.15);
}
.profile-text p { color: var(--gray); margin: 18px 0 24px; font-size: 1.05rem; }
.profile-text h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
blockquote {
  border-left: 4px solid var(--blue);
  padding-left: 18px;
  font-style: italic;
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--navy);
  margin-bottom: 32px;
}

/* Contact */
.contact { background: var(--light); }
.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.contact-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px 34px;
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 44px rgba(15,31,61,0.14);
}
.contact-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  flex-shrink: 0;
}
.contact-card-icon svg { width: 26px; height: 26px; }
.contact-card-label {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--gray);
}
.contact-card-value {
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.4;
  word-break: break-word;
}
.contact-card-arrow {
  position: absolute;
  top: 26px;
  right: 22px;
  color: var(--blue);
  font-size: 1.2rem;
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 0.2s, transform 0.2s;
}
.contact-card:hover .contact-card-arrow { opacity: 1; transform: translateX(0); }

.contact-card-phone .contact-card-icon { background: var(--blue); }
.contact-card-phone:hover { border-color: var(--blue); }

.contact-card-email .contact-card-icon { background: var(--navy); }
.contact-card-email:hover { border-color: var(--navy); }

.contact-card-instagram .contact-card-icon { background: linear-gradient(135deg, #f58529, #dd2a7b 45%, #8134af 70%, #515bd4); }
.contact-card-instagram:hover { border-color: #dd2a7b; }
.contact-card-instagram .contact-card-arrow { color: #dd2a7b; }

.contact-card-address .contact-card-icon { background: #16a34a; }
.contact-card-address:hover { border-color: #16a34a; }
.contact-card-address .contact-card-arrow { color: #16a34a; }

/* Footer */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.6);
  padding: 36px 0;
}
.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-grid .logo { color: var(--white); }
.footer-grid p { font-size: 0.85rem; }

/* Responsive */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { order: -1; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .profiles-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; }
  .masonry { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  .section { padding: 80px 0; }
  .nav-toggle { display: flex; }
  #navMenu {
    position: absolute;
    top: 84px; left: 0; right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: stretch;
    padding: 20px 28px 28px;
    display: none;
    gap: 20px;
  }
  #navMenu.open { display: flex; }
  #navMenu ul { flex-direction: column; gap: 16px; }
  .features-grid { grid-template-columns: 1fr; }
  .profiles-grid { grid-template-columns: 1fr; }
  .masonry { grid-template-columns: 1fr; grid-auto-rows: 260px; }
  .masonry-item.tall { grid-row: span 1; }
  .hero-media-card { display: none; }
  .contact-grid { grid-template-columns: 1fr; }
}
