/* ==========================
   style.css (COMPLETO)
   - Hero foto centrada móvil/tablet/PC
   - Menú móvil tipo Fuerza Popular (drawer)
   - Mejoras generales
   ========================== */

/* RESET */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  font-family: 'Poppins', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: #f3f4f6;
  color: #111827;
}

/* CONTENEDOR */
.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 16px;
}

/* HEADER */
.header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255,255,255,0.98);
  box-shadow: 0 1px 5px rgba(0,0,0,0.08);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
}

/* LOGO */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.logo-box {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, #ff6a00, #f97316);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  flex: 0 0 auto;
}

.logo-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.logo-name {
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.logo-sub {
  font-size: 11px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* NAV DESKTOP */
.nav {
  display: none;
  gap: 16px;
  align-items: center;
}

.nav a {
  font-size: 13px;
  text-decoration: none;
  color: #4b5563;
  font-weight: 700;
}

.nav a:hover {
  color: #ff6a00;
}

.nav-cta {
  padding: 8px 14px;
  border-radius: 999px;
  background: #ff6a00;
  color: #ffffff !important;
}

/* BOTÓN MENÚ MÓVIL */
.menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(17,24,39,0.12);
  background: #ffffff;
  cursor: pointer;
}

.menu-btn:hover {
  border-color: rgba(249,115,22,0.45);
}

.menu-btn-lines {
  width: 20px;
  height: 2px;
  background: #111827;
  position: relative;
  border-radius: 999px;
}

.menu-btn-lines::before,
.menu-btn-lines::after {
  content: "";
  position: absolute;
  left: 0;
  width: 20px;
  height: 2px;
  background: #111827;
  border-radius: 999px;
}

.menu-btn-lines::before {
  top: -6px;
}

.menu-btn-lines::after {
  top: 6px;
}

/* OVERLAY */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(2,6,23,0.55);
  z-index: 80;
}

/* DRAWER */
.drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: min(88vw, 380px);
  height: 100vh;
  background: #ffffff;
  z-index: 90;
  transform: translateX(105%);
  transition: transform 220ms ease;
  box-shadow: -18px 0 50px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.drawer.open {
  transform: translateX(0);
}

.drawer-top {
  padding: 14px 14px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(17,24,39,0.08);
}

.drawer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.drawer-logo {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, #ff6a00, #f97316);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-weight: 900;
  flex: 0 0 auto;
}

.drawer-brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.drawer-brand-text strong {
  font-size: 13px;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.drawer-brand-text span {
  font-size: 11px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.drawer-close {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid rgba(17,24,39,0.12);
  background: #ffffff;
  cursor: pointer;
  font-size: 16px;
}

.drawer-close:hover {
  border-color: rgba(249,115,22,0.45);
}

/* BLOQUE SUPERIOR (IMAGEN + ACCIONES + REDES) */
.drawer-hero {
  padding: 12px 14px 14px;
  border-bottom: 1px solid rgba(17,24,39,0.08);
}

.drawer-hero img {
  width: 100%;
  height: 170px;
  border-radius: 16px;
  object-fit: cover;
  object-position: 50% 12%;
  border: 1px solid rgba(17,24,39,0.10);
  background: #f3f4f6;
}

.drawer-hero-actions {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

.drawer-social {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.social-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 10px;
  font-size: 12px;
  border-radius: 999px;
  text-decoration: none;
  border: 1px solid rgba(17,24,39,0.12);
  color: #111827;
  background: #ffffff;
  font-weight: 700;
}

.social-pill:hover {
  border-color: rgba(249,115,22,0.55);
  color: #c2410c;
}

/* NAV DENTRO DEL DRAWER */
.drawer-nav {
  padding: 10px 0;
  display: flex;
  flex-direction: column;
  overflow: auto;
}

.drawer-nav a {
  padding: 12px 16px;
  text-decoration: none;
  color: #111827;
  font-weight: 800;
  border-left: 4px solid transparent;
}

.drawer-nav a:hover {
  background: #fff7ed;
  border-left-color: #ff6a00;
  color: #c2410c;
}

/* FOOTER DRAWER */
.drawer-footer {
  margin-top: auto;
  padding: 12px 14px 16px;
  border-top: 1px solid rgba(17,24,39,0.08);
  background: #f9fafb;
}

.drawer-footer p {
  margin: 0 0 10px;
  font-size: 12px;
  color: #374151;
}

.drawer-share {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 800;
  font-size: 13px;
  border: 1px solid rgba(17,24,39,0.12);
  background: #ffffff;
  color: #111827;
}

.share-btn:hover {
  border-color: rgba(249,115,22,0.55);
  color: #c2410c;
}

.drawer-footer small {
  display: block;
  color: #6b7280;
  font-size: 11px;
}

/* HERO */
.hero {
  position: relative;
  color: #ffffff;
  padding: 42px 0 44px;
  overflow: hidden;
  background-image: url('../img/fondo.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,0.18), transparent 60%),
    linear-gradient(135deg, rgba(15,23,42,0.88), rgba(148,27,11,0.90));
}

.hero-inner {
  position: relative;
  display: flex;
  flex-direction: column-reverse;
  gap: 24px;
  align-items: center;
  z-index: 1;
}

.hero-text {
  text-align: center;
}

.hero-tag {
  margin: 0 0 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fed7aa;
  font-weight: 800;
}

.hero-text h1 {
  margin: 0 0 10px;
  font-size: 26px;
  line-height: 1.28;
  letter-spacing: -0.01em;
}

.hero-text h1 span {
  color: #fbbf24;
}

.hero-desc {
  margin: 0;
  font-size: 14px;
  color: #e5e7eb;
  line-height: 1.75;
}

/* PÍLDORAS */
.hero-pills {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.hero-pills span {
  font-size: 11px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(15,23,42,0.70);
  border: 1px solid rgba(248,250,252,0.18);
}

/* ACCIONES */
.hero-actions {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

/* STATS */
.hero-mini-stats {
  margin-top: 18px;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 11px;
}

.hero-mini-stats > div {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(15,23,42,0.75);
  border: 1px solid rgba(248,250,252,0.18);
  min-width: 120px;
}

.hero-mini-stats strong {
  display: block;
  font-size: 14px;
}

/* TARJETA FOTO */
.hero-photo-card {
  position: relative;
  width: 100%;
  max-width: 320px;
  border-radius: 22px;
  background: rgba(15,23,42,0.88);
  box-shadow: 0 18px 45px rgba(0,0,0,0.60);
  overflow: hidden;
  border: 1px solid rgba(248,250,252,0.16);
  --focus-y: 12%;
}

.hero-ribbon {
  position: absolute;
  top: 10px;
  left: -42px;
  transform: rotate(-12deg);
  background: #f97316;
  color: #111827;
  padding: 5px 42px;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  z-index: 2;
}

.hero-photo {
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  height: clamp(300px, 46vw, 430px);
  background: #0b1220;
}

.hero-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;

  /* CLAVE: esto centra “cara/pecho” mejor en todas las pantallas */
  object-position: 50% var(--focus-y);
}

.hero-photo-info {
  padding: 12px 14px 14px;
}

.hero-photo-info h2 {
  margin: 0 0 4px;
  font-size: 16px;
  color: #f9fafb;
}

.hero-photo-info p {
  margin: 0 0 8px;
  font-size: 12px;
  color: #e5e7eb;
}

.hero-photo-info ul {
  margin: 0;
  padding-left: 18px;
  font-size: 11px;
  color: #d1d5db;
}

/* BOTONES */
.btn {
  display: inline-block;
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  text-align: center;
  border: none;
  cursor: pointer;
  letter-spacing: 0.01em;
}

.btn-primary {
  background: #ff6a00;
  color: #ffffff;
}

.btn-primary:hover { opacity: 0.92; }

.btn-outline {
  border: 1px solid #ffedd5;
  color: #ffedd5;
  background: transparent;
}

.btn-outline:hover {
  background: #ffedd5;
  color: #7c2d12;
}

.btn-whatsapp {
  background: #22c55e;
  color: #ffffff;
}

.btn-whatsapp:hover { opacity: 0.92; }

.btn-block { width: 100%; }

/* SECCIONES */
.section {
  padding: 44px 0;
  background: #ffffff;
}

.section-light { background: #f9fafb; }

.section-cta {
  background: radial-gradient(circle at top, #111827, #020617);
}

.section-header {
  text-align: center;
  margin-bottom: 26px;
}

.section-header h2 {
  margin: 0 0 6px;
  font-size: 22px;
}

.section-header p {
  margin: 0;
  font-size: 14px;
  color: #6b7280;
}

/* EJES */
.ejes-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.eje-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 18px 16px 20px;
  box-shadow: 0 10px 28px rgba(0,0,0,0.05);
  text-align: center;
  border: 1px solid rgba(17,24,39,0.05);
}

.eje-icon {
  width: 60px;
  height: 60px;
  border-radius: 999px;
  border: 2px solid #ff6a00;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 10px;
  font-size: 26px;
}

.eje-card h3 {
  margin: 0 0 6px;
  font-size: 15px;
  color: #111827;
}

.eje-card p {
  margin: 0;
  font-size: 13px;
  color: #4b5563;
  line-height: 1.6;
}

/* PROYECTOS (TARJETAS MODERNAS) */
.title-proyectos {
  font-size: 32px;
  font-weight: 900;
  color: #1f2937;
}

.subtitle-proyectos {
  font-size: 15px;
  color: #6b7280;
  margin-bottom: 30px;
}

.proyectos-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.proyecto-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 24px 22px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
  border: 1px solid #f5f5f5;
  position: relative;
  transition: 0.25s ease;
}

.proyecto-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.18);
  border-color: #ff6a00;
}

.proyecto-card h3 {
  margin-top: 12px;
  margin-bottom: 6px;
  font-size: 17px;
  font-weight: 900;
  color: #ff6a00;
}

.proyecto-card p {
  font-size: 14px;
  color: #374151;
  line-height: 1.5;
}

.proyecto-card .num {
  width: 42px;
  height: 42px;
  background: #ff6a00;
  color: white;
  font-weight: 900;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  position: absolute;
  top: -15px;
  left: -15px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}

/* ACTIVIDADES */
.news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.news-card {
  background: #ffffff;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0,0,0,0.05);
  border: 1px solid rgba(17,24,39,0.05);
}

.news-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.news-body {
  padding: 14px 16px 16px;
}

.news-body h3 {
  margin: 0 0 6px;
  color: #ea580c;
  font-size: 16px;
  font-weight: 900;
}

.news-body p {
  margin: 0;
  font-size: 13px;
  color: #4b5563;
}

/* CONTACTO */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
}

.contact-info h3 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 900;
}

.contact-info p {
  margin: 4px 0;
  font-size: 13px;
  color: #4b5563;
}

.contact-note {
  margin-top: 10px;
  font-size: 12px;
  color: #6b7280;
}

.contact-form {
  background: #f9fafb;
  border-radius: 18px;
  padding: 16px 14px 18px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.04);
  border: 1px solid rgba(17,24,39,0.06);
}

.contact-form label {
  display: block;
  font-size: 12px;
  margin-bottom: 10px;
  color: #4b5563;
  font-weight: 700;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  margin-top: 4px;
  padding: 10px 10px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
  font-family: inherit;
  font-size: 13px;
  outline: none;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: rgba(249,115,22,0.7);
  box-shadow: 0 0 0 3px rgba(249,115,22,0.15);
}

/* CTA (WHATSAPP + QR) */
.cta-box {
  max-width: 920px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  align-items: center;
  background: rgba(15,23,42,0.95);
  border-radius: 24px;
  padding: 24px 20px 26px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.7);
}

.cta-text h2 {
  margin: 0 0 8px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.cta-text p {
  margin: 0 0 12px;
  color: #e5e7eb;
  font-size: 14px;
  line-height: 1.7;
}

.cta-text ul {
  margin: 0 0 16px;
  padding-left: 18px;
  font-size: 13px;
  color: #e5e7eb;
}

.cta-qr {
  text-align: center;
}

.qr-placeholder {
  width: 180px;
  height: 180px;
  margin: 0 auto;
  border-radius: 16px;
  border: 2px dashed #4b5563;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.cta-qr img {
  width: 180px;
  height: 180px;
  border-radius: 16px;
  object-fit: cover;
}

.cta-qr-text {
  margin-top: 10px;
  font-size: 12px;
  color: #9ca3af;
}

/* FOOTER */
.footer {
  background: #020617;
  color: #e5e7eb;
  font-size: 12px;
}

.footer-inner {
  text-align: center;
  padding: 12px 0;
}

/* ==========================
   RESPONSIVE (MÓVIL/TABLET/PC)
   ========================== */

/* MÓVIL */
@media (max-width: 600px) {
  /* mejor encuadre de cara en móvil */
  .hero-photo-card { --focus-y: 9%; }
  .hero-photo { height: clamp(290px, 92vw, 370px); }

  /* CTA en 1 columna */
  .cta-box {
    grid-template-columns: 1fr;
  }
}

/* TABLET: subimos un poquito la cara */
@media (min-width: 601px) and (max-width: 900px) {
  .hero-photo-card { --focus-y: 11%; }
  .hero-photo { height: clamp(340px, 44vw, 430px); }
}

/* TABLET+ */
@media (min-width: 768px) {
  .hero-inner {
    flex-direction: row;
    align-items: center;
    gap: 40px;
  }

  .hero-text {
    flex: 1.5;
    text-align: left;
  }

  .hero-actions { justify-content: flex-start; }
  .hero-mini-stats { justify-content: flex-start; }

  .hero-photo-card { flex: 1; }

  .ejes-grid {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .news-grid {
    grid-template-columns: repeat(3, minmax(0,1fr));
  }

  .contact-grid {
    grid-template-columns: 1.1fr 1.2fr;
  }
}

/* DESKTOP */
@media (min-width: 1024px) {
  .nav { display: flex; }
  .menu-btn { display: none; }

  .hero-text h1 { font-size: 34px; }
}

/* si hay desktop, ocultamos drawer por defecto (solo se usa en móvil) */
@media (min-width: 1024px) {
  .drawer,
  .drawer-overlay {
    display: none !important;
  }
}
