/* ============================================
   GLOBALIDDEAS — main.css — DEFINITIVO
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Syne:wght@700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&display=swap');

:root {
  --black:    #0c0c0a;
  --white:    #f4f1ea;
  --amber:    #f0a500;
  --amber-dk: #c47d00;
  --gray1:    #161613;
  --gray2:    #1e1e1b;
  --gray3:    #2a2a26;
  --muted:    rgba(244,241,234,0.80);
  --muted2:   rgba(244,241,234,0.55);
  --muted3:   rgba(244,241,234,0.22);
  --amber-gl: rgba(240,165,0,0.10);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { background: var(--black); color: var(--white); font-family: 'DM Sans', sans-serif; font-weight: 300; overflow-x: hidden; cursor: none; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* CURSOR */
.cursor { position: fixed; top: 0; left: 0; width: 8px; height: 8px; background: #f0a500; border-radius: 50%; pointer-events: none; z-index: 9999; will-change: transform; transform: translate(-50%, -50%); }
.cursor-ring { position: fixed; top: 0; left: 0; width: 36px; height: 36px; border: 1px solid rgba(240,165,0,.5); border-radius: 50%; pointer-events: none; z-index: 9998; will-change: transform; transform: translate(-50%, -50%); transition: width .2s, height .2s; }

/* NAV */
.nav { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; background: rgba(12,12,10,0.95); backdrop-filter: blur(20px); border-bottom: 1px solid rgba(244,241,234,0.08); display: flex; align-items: center; justify-content: space-between; padding: 0 60px; height: 80px; gap: 40px; }
.nav-logo { display: flex; align-items: center; flex-shrink: 0; text-decoration: none; }
.nav-logo img { height: 34px; width: auto; display: block; }
.nav-links { display: flex; gap: 32px; align-items: center; list-style: none; margin: 0; padding: 0; flex: 1; justify-content: center; }
.nav-links a { font-family: 'DM Sans', sans-serif; font-weight: 500; font-size: 14px; color: var(--muted); text-decoration: none; transition: color .3s; white-space: nowrap; }
.nav-links a:hover { color: var(--amber); }
.nav-cta { background: var(--amber); color: var(--black); font-family: 'DM Sans', sans-serif; font-weight: 500; font-size: 14px; padding: 8px 16px; border-radius: 4px; text-decoration: none; transition: all .3s; flex-shrink: 0; white-space: nowrap; }
.nav-cta:hover { background: var(--amber-dk); }
.nav-mobile-toggle { display: none; flex-direction: column; justify-content: space-between; width: 24px; height: 18px; cursor: pointer; flex-shrink: 0; }
.nav-mobile-toggle span { display: block; width: 100%; height: 2px; background: var(--white); border-radius: 2px; transition: all .3s; }
.nav-mobile-toggle.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-mobile-toggle.active span:nth-child(2) { opacity: 0; }
.nav-mobile-toggle.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
.nav-mobile-menu { display: none; position: fixed; top: 80px; left: 0; width: 100%; max-height: 0; overflow: hidden; transition: max-height .3s ease; background: rgba(12,12,10,0.98); z-index: 999; border-bottom: 1px solid rgba(244,241,234,.08); }
.nav-mobile-menu.active { max-height: 400px; }
.nav-mobile-menu ul { list-style: none; padding: 20px 24px; margin: 0; }
.nav-mobile-menu ul li { margin-bottom: 16px; }
.nav-mobile-menu ul a { font-family: 'DM Sans', sans-serif; font-size: 16px; font-weight: 500; color: var(--muted); text-decoration: none; }
.nav-mobile-menu ul a:hover { color: var(--amber); }

/* NAV DROPDOWN */
.nav-dropdown { position: relative; }
.nav-dropdown-menu { position: absolute !important; top: 100% !important; left: 0 !important; opacity: 0 !important; visibility: hidden !important; pointer-events: none !important; z-index: 1001; min-width: 200px; background: var(--black); border: 1px solid rgba(244,241,234,.08); padding: 10px 0; }
.nav-dropdown:hover .nav-dropdown-menu { opacity: 1 !important; visibility: visible !important; pointer-events: auto !important; }
.nav-dropdown-menu li { padding: 0 !important; }
.nav-dropdown-menu a { display: block; padding: 8px 20px; font-size: 12px; color: var(--muted); transition: color .2s; font-family: 'DM Sans', sans-serif; }
.nav-dropdown-menu a:hover { color: var(--amber); }

/* TICKER */
.ticker { overflow: hidden; width: 100%; background: var(--gray1); padding: 14px 0; }
.ticker-track { overflow: hidden; white-space: nowrap; width: 100%; }
.ticker-inner { display: inline-flex; white-space: nowrap; animation: ticker 40s linear infinite; }
.ticker-item { display: inline-flex; align-items: center; white-space: nowrap; flex-shrink: 0; font-family: 'DM Sans', sans-serif; font-size: 13px; color: var(--muted2); padding: 0 24px; }
.ticker-dot { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: var(--amber); margin-left: 24px; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* SECTIONS */
.section { padding: 100px 60px; position: relative; }
.sec-label { font-family: 'Bebas Neue', sans-serif; font-size: 14px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted2); margin-bottom: 16px; display: flex; align-items: center; gap: 12px; }
.sec-label::before { content: ''; width: 32px; height: 1px; background: var(--muted3); }
.sec-h2 { font-family: 'Bebas Neue', sans-serif; font-size: clamp(54px, 8vw, 114px); line-height: .88; color: var(--white); margin-bottom: 60px; letter-spacing: -.01em; }
.sec-body { font-size: 16px; line-height: 1.7; color: var(--muted); max-width: 560px; margin-bottom: 24px; }
.sep { height: 1px; background: var(--muted3); margin: 0; }

/* CASOS */
.casos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.caso { background: var(--gray1); padding: 36px 28px; border-top: 2px solid transparent; transition: border-color .3s, background .3s; }
.caso:hover { border-top-color: #ffc133; background: var(--gray2); }
.caso-client { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--amber); margin-bottom: 10px; }
.caso-title { font-family: 'Syne', sans-serif; font-size: 16px; font-weight: 700; line-height: 1.25; margin-bottom: 12px; }
.caso-desc { font-size: 15px; color: var(--muted); line-height: 1.72; margin-bottom: 22px; }
.stats { display: flex; flex-direction: column; gap: 10px; }
.stat { display: flex; align-items: baseline; gap: 10px; }
.stat-n { font-family: 'Bebas Neue', sans-serif; font-size: 30px; color: var(--amber); line-height: 1; }
.stat-l { font-size: 11px; color: var(--muted2); line-height: 1.4; max-width: 160px; }
.caso-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted2); transition: color .2s; }
.caso-link:hover { color: var(--amber); }
.caso-link::after { content: '→'; }

/* SERVICIOS */
.svcs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; margin-top: 44px; padding: 0 60px 60px; }
.svc { background: var(--gray1); position: relative; overflow: hidden; min-height: 280px; cursor: pointer; }
.svc-bg-img { position: absolute; inset: 0; width: 100%; height: 100%; background-size: cover; background-position: center; filter: grayscale(0%) brightness(0.6); transition: filter .5s ease, transform .6s ease; }
.svc:hover .svc-bg-img { filter: grayscale(0%) brightness(0.75); transform: scale(1.04); }
.svc-overlay { position: absolute; inset: 0; background: rgba(12,12,10,0.75); transition: background .5s ease; display: flex; flex-direction: column; justify-content: flex-end; padding: 30px; }
.svc:hover .svc-overlay { background: rgba(12,12,10,0.45); }
.svc-ghost { position: absolute; top: -10px; right: 12px; font-family: 'Bebas Neue', sans-serif; font-size: 72px; color: rgba(240,165,0,.04); line-height: 1; pointer-events: none; }
.svc-title { font-family: 'Syne', sans-serif; font-size: clamp(18px, 2vw, 26px); font-weight: 700; line-height: 1.2; margin-bottom: 10px; position: relative; z-index: 2; }
.svc-desc { font-size: 13px; color: var(--muted); line-height: 1.6; margin-bottom: 14px; position: relative; z-index: 2; }
.svc-tags { display: flex; flex-wrap: wrap; gap: 6px; position: relative; z-index: 2; }
.svc-tag { font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: rgba(244,241,234,0.8); border: 1px solid rgba(244,241,234,.2); padding: 3px 8px; }
.svc-arrow { position: absolute; top: 30px; right: 30px; color: var(--amber); font-size: 24px; opacity: 0; transition: opacity .3s; z-index: 3; }
.svc:hover .svc-arrow { opacity: 1; }

/* PILLARS */
.pillars { display: flex; flex-direction: column; gap: 0; }
.pillar { display: flex; align-items: center; gap: 28px; padding: 20px 0; cursor: default; }
.pillar + .pillar { border-top: 1px solid rgba(244,241,234,.06); }
.pillar-circle { width: 110px; height: 110px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-family: 'Bebas Neue', sans-serif; font-size: 22px; font-weight: bold; transition: transform .3s; }
.pillar:nth-child(1) .pillar-circle { background: var(--black); border: 2px solid var(--white); color: var(--white); }
.pillar:nth-child(2) .pillar-circle { background: #f0a500; color: var(--black); }
.pillar:nth-child(3) .pillar-circle { background: var(--black); border: 2px solid var(--white); color: var(--white); }
.pillar:nth-child(4) .pillar-circle { background: #f0a500; color: var(--black); }
.pillar:nth-child(5) .pillar-circle { background: var(--black); border: 2px solid var(--white); color: var(--white); }
.pillar:hover .pillar-circle { transform: scale(1.12); box-shadow: 0 0 0 3px rgba(240,165,0,.35); }
.pillar-body { flex: 1; }
.pillar-title { font-family: 'Syne', sans-serif; font-size: 18px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 5px; }
.pillar-desc { font-size: 15px; color: rgba(244,241,234,0.85); line-height: 1.6; }
.chain-bar { margin-top: 24px; background: #f0a500; padding: 14px 18px; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #0c0c0a; font-weight: 700; display: block; }

/* CLIENTES */
.clientes-desktop { display: block; width: 100%; height: auto; }
.clientes-mobile { display: none; }
.clients-img { width: 100%; opacity: .3; filter: grayscale(0%) brightness(1.5); transition: opacity .5s, filter .5s; }
.clients-img:hover { opacity: .88; filter: grayscale(0%) brightness(1); }

/* CONTACTO */
.cta-section { background: var(--amber); padding: 100px 60px; position: relative; overflow: hidden; }
.cta-section::before { content: 'PLUG IN'; position: absolute; right: -10px; top: 50%; transform: translateY(-50%); font-family: 'Bebas Neue', sans-serif; font-size: clamp(80px, 15vw, 220px); color: rgba(12,12,10,.06); line-height: 1; pointer-events: none; white-space: nowrap; }
.cta-label { font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: rgba(12,12,10,.4); margin-bottom: 18px; display: flex; align-items: center; gap: 12px; }
.cta-label::before { content: ''; width: 26px; height: 1px; background: rgba(12,12,10,.4); }
.cta-h { font-family: 'Bebas Neue', sans-serif; font-size: clamp(54px, 8vw, 114px); line-height: .88; color: var(--black); margin-bottom: 48px; letter-spacing: -.01em; max-width: 700px; }
.cta-contacts { display: flex; gap: 48px; flex-wrap: wrap; }
.contact-card { display: flex; align-items: center; gap: 16px; }
.c-avatar { width: 68px; height: 68px; border-radius: 50%; overflow: hidden; flex-shrink: 0; }
.c-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.c-name { font-family: 'DM Sans', sans-serif; font-weight: 700; font-size: 18px; color: var(--black); margin-bottom: 4px; }
.c-role { font-family: 'DM Sans', sans-serif; font-size: 14px; color: rgba(12,12,10,.6); margin-bottom: 8px; }
.c-email { font-family: 'DM Sans', sans-serif; font-size: 14px; color: var(--black); text-decoration: underline; margin-bottom: 4px; display: block; }
.c-tel { font-size: 11px; color: rgba(12,12,10,.45); margin-top: 3px; }

/* FOOTER */
.footer { background: var(--black); border-top: 1px solid rgba(244,241,234,.05); }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 40px; padding: 60px 60px 40px; }
.footer-col-title { font-family: 'DM Sans', sans-serif; font-size: 12px; color: #f0a500; text-transform: uppercase; letter-spacing: .15em; margin-bottom: 16px; }
.footer-desc { font-family: 'DM Sans', sans-serif; font-size: 14px; color: rgba(244,241,234,0.75); line-height: 1.5; }
.footer-links { font-family: 'DM Sans', sans-serif; font-size: 14px; color: rgba(244,241,234,0.6); text-decoration: none; line-height: 2.2; transition: color .2s; display: block; }
.footer-links:hover { color: #f0a500; }
.footer-bottom { padding: 20px 60px; border-top: 1px solid rgba(244,241,234,0.08); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-bottom-text { font-family: 'DM Sans', sans-serif; font-size: 13px; color: rgba(244,241,234,0.65); }
.footer-contact-info { font-family: 'DM Sans', sans-serif; font-size: 13px; font-weight: 500; color: rgba(244,241,234,0.8); }

/* PORTFOLIO */
.portfolio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; margin-bottom: 80px; }
.portfolio-item { position: relative; overflow: hidden; border-radius: 8px; cursor: pointer; }
.portfolio-item img { width: 100%; height: 300px; object-fit: cover; }
.portfolio-overlay { position: absolute; inset: 0; background: linear-gradient(rgba(12,12,10,0) 0%, rgba(12,12,10,.6) 100%); display: flex; flex-direction: column; justify-content: flex-end; padding: 20px; opacity: 0; transition: opacity .3s; }
.portfolio-item:hover .portfolio-overlay { opacity: 1; }

/* GRIDS INTERIORES */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2-1 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 40px; }

/* BUTTONS */
.btn-primary { background: var(--amber); color: var(--black); font-family: 'DM Sans', sans-serif; font-weight: 500; font-size: 14px; padding: 12px 24px; border-radius: 4px; text-decoration: none; transition: all .3s; display: inline-flex; align-items: center; gap: 8px; }
.btn-primary:hover { background: var(--amber-dk); transform: translateY(-2px); }
.btn-ghost { color: var(--white); font-family: 'DM Sans', sans-serif; font-weight: 500; font-size: 14px; padding: 12px 24px; border: 1px solid var(--muted3); border-radius: 4px; text-decoration: none; transition: all .3s; display: inline-flex; align-items: center; gap: 8px; }
.btn-ghost:hover { border-color: var(--amber); color: var(--amber); }
.btn-ghost-down { border-color: rgba(244,241,234,.35); }

/* FILTERS */
.filter-btn { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); border: 1px solid rgba(244,241,234,.12); padding: 9px 18px; background: transparent; cursor: pointer; transition: color .2s, border-color .2s, background .2s; font-family: 'DM Sans', sans-serif; }
.filter-btn:hover, .filter-btn.active { color: var(--black); background: var(--amber); border-color: var(--amber); }

/* ANIMATIONS */
.rv { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.rv.active { opacity: 1; transform: translateY(0); }



/* ===== TABLET 1024px ===== */
@media (max-width: 1024px) {
  .nav { padding: 0 40px; gap: 24px; }
  .section { padding: 80px 40px; }
  .svcs-grid { padding: 0 40px 60px; grid-template-columns: repeat(2, 1fr); }
  .casos-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; padding: 40px; }
  .footer-bottom { padding: 20px 40px; }
  .grid-2-1 { grid-template-columns: 1fr; }
  .cta-contacts { flex-direction: column; gap: 24px; }
}

/* ===== MÓVIL 768px ===== */
@media (max-width: 768px) {

  /* CURSOR */
  .cursor, .cursor-ring { display: none !important; }
  body { cursor: auto !important; }

  /* NAV */
  .nav { padding: 0 20px; height: 64px; gap: 16px; }
  .nav-links { display: none !important; }
  .nav-cta { display: none !important; }
  .nav-mobile-toggle { display: flex !important; }
  .nav-mobile-menu { display: block; top: 64px; }

  /* SECTIONS */
  .section { padding: 60px 20px; }
  .sep { margin: 0; }

  /* CASOS */
  .casos-grid { grid-template-columns: 1fr !important; }

  /* SERVICIOS */
  .svcs-grid { grid-template-columns: 1fr !important; padding: 0 20px 40px !important; }
  .svc-bg-img { filter: grayscale(0%) brightness(0.7) !important; }
  .svc-overlay { background: rgba(12,12,10,0.55) !important; }
  .svc-arrow { display: none !important; }

  /* PILLARS */
  .pillar { flex-direction: column; align-items: center; text-align: center; gap: 12px; }
  .pillar-circle { width: 88px; height: 88px; font-size: 16px; }

  /* CLIENTES */
  .clientes-desktop { display: none !important; }
  .clientes-mobile { display: block !important; width: 100%; }

  /* CONTACTO */
  .cta-section { padding: 60px 20px; }
  .cta-section::before { display: none; }
  .cta-h { font-size: clamp(36px, 10vw, 60px); margin-bottom: 32px; }
  .cta-contacts { flex-direction: column !important; gap: 24px; }
  .contact-card { flex-direction: column; text-align: center; align-items: center; gap: 12px; }

  /* FOOTER */
  .footer-grid { grid-template-columns: 1fr !important; gap: 24px; padding: 40px 20px 30px; }
  .footer-bottom { padding: 16px 20px; flex-direction: column; text-align: center; gap: 8px; }

  /* GRIDS INTERIORES */
  .grid-2, .grid-3, .grid-4, .grid-2-1 { grid-template-columns: 1fr !important; gap: 3px; }

  /* PORTFOLIO */
  .portfolio-grid { grid-template-columns: 1fr !important; }
  .portfolio-overlay { opacity: 1 !important; }

  /* REVEAL — visible siempre */
  .rv { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ===== FIX SCROLL HORIZONTAL MÓVIL ===== */
body {
  max-width: 100%;
  overflow-x: clip;
}
html {
  overflow-x: clip;
}
* { box-sizing: border-box; }
.nav {
  max-width: 100vw;
  box-sizing: border-box;
}
.nav-mobile-menu {
  max-width: 100vw;
  box-sizing: border-box;
}
@media (max-width: 768px) {
  .nav { width: 100% !important; left: 0 !important; right: 0 !important; }
  .nav-mobile-menu { width: 100% !important; left: 0 !important; right: 0 !important; }
  .section, .reel-section, .sys-section, .cta-section { max-width: 100vw; overflow-x: hidden; }
  .footer-grid { max-width: 100vw; }
  /* Footer compartido en móvil */
  #footer-grid { grid-template-columns: 1fr !important; padding: 40px 20px !important; gap: 32px !important; }
  #footer-bottom { padding: 16px 20px !important; flex-direction: column !important; align-items: flex-start !important; gap: 8px !important; }
  /* Ticker no desborde */
  .ticker { max-width: 100vw; overflow: hidden !important; }
}

/* ===== PÁGINAS INTERIORES — FIX MOBILE TEXTO ESTRECHO ===== */
@media (max-width: 768px) {
  .intro-block { grid-template-columns: 1fr !important; padding: 48px 20px !important; gap: 32px !important; }
  .proj-grid-2 { grid-template-columns: 1fr !important; direction: ltr !important; gap: 32px !important; }
  .proj-grid-2.reverse { direction: ltr !important; }
  .proj-content { padding: 48px 20px !important; }
  .proj-body-text { font-size: 15px !important; line-height: 1.7 !important; }
  .meta-bar { grid-template-columns: 1fr 1fr !important; }
  .stats-band { grid-template-columns: 1fr 1fr !important; padding: 32px 20px !important; }
  .results-grid { grid-template-columns: 1fr 1fr !important; }
  .img-grid-2, .img-grid-3, .img-grid-4 { grid-template-columns: 1fr !important; gap: 3px !important; }
  .photo-section { padding: 40px 20px !important; }
  .servicios-cards { grid-template-columns: 1fr !important; }
  .cta-mini { padding: 40px 20px !important; flex-direction: column !important; }
}
