:root {
    --navy: #131641;
    --gold: #b8960c;
    --gold-light: #d4aa1a;
    --cream: #f9f5ef;
    --dark: #0e0e1a;
    --text: #3a3a3a;
    --text-light: #6a6a6a;
    --white: #ffffff;
  }
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { scroll-behavior: smooth; }
  body { font-family: "Montserrat", sans-serif; font-weight: 300; color: var(--text); background: var(--cream); overflow-x: hidden; }

  nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; display: flex; align-items: center; justify-content: space-between; padding: 0 60px; height: 72px; background: rgba(19,22,65,0.97); backdrop-filter: blur(8px); transition: all 0.3s ease; }
  nav.scrolled { height: 60px; box-shadow: 0 2px 20px rgba(0,0,0,0.3); }
  .nav-logo { display: flex; align-items: center; gap: 14px; text-decoration: none; }
  .nav-logo img { height: 38px; width: auto; }
  .nav-logo-text { font-family: "Cormorant Garamond", serif; color: #fff; font-size: 17px; font-weight: 400; letter-spacing: 0.05em; line-height: 1.2; }
  .nav-logo-text span { display: block; font-size: 11px; font-family: "Montserrat", sans-serif; font-weight: 300; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(255,255,255,0.55); }
  .nav-links { display: flex; gap: 36px; list-style: none; }
  .nav-links a { color: rgba(255,255,255,0.75); text-decoration: none; font-size: 12px; font-weight: 400; letter-spacing: 0.18em; text-transform: uppercase; transition: color 0.25s; position: relative; padding-bottom: 2px; }
  .nav-links a::after { content: ""; position: absolute; bottom: -2px; left: 0; width: 0; height: 1px; background: var(--gold-light); transition: width 0.3s ease; }
  .nav-links a:hover { color: #fff; }
  .nav-links a:hover::after { width: 100%; }

  #hero { position: relative; height: 100vh; min-height: 600px; display: flex; align-items: center; justify-content: center; overflow: hidden; background: var(--dark); }
  .hero-bg { position: absolute; inset: 0; background-image: url("../img/historia2.jpg"); background-size: cover; background-position: center; opacity: 0.35; animation: subtleZoom 18s ease-in-out infinite alternate; }
  @keyframes subtleZoom { from { transform: scale(1.04); } to { transform: scale(1.12); } }
  .hero-overlay { position: absolute; inset: 0; background: linear-gradient(160deg, rgba(19,22,65,0.85) 0%, rgba(14,14,26,0.6) 50%, rgba(184,150,12,0.12) 100%); }
  .hero-content { position: relative; text-align: center; color: #fff; padding: 0 20px; animation: fadeUp 1.2s ease both; }
  @keyframes fadeUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
  .hero-eyebrow { font-size: 11px; font-weight: 400; letter-spacing: 0.35em; text-transform: uppercase; color: var(--gold-light); margin-bottom: 22px; animation: fadeUp 1.2s 0.15s ease both; }
  .hero-title { font-family: "Cormorant Garamond", serif; font-size: clamp(44px, 8vw, 88px); font-weight: 300; line-height: 1.05; letter-spacing: 0.02em; margin-bottom: 8px; animation: fadeUp 1.2s 0.3s ease both; }
  .hero-title em { font-style: italic; color: rgba(255,255,255,0.75); }
  .hero-divider { width: 48px; height: 1px; background: var(--gold); margin: 24px auto; animation: expandW 1s 0.6s ease both; }
  @keyframes expandW { from { width: 0; opacity: 0; } to { width: 48px; opacity: 1; } }
  .hero-sub { font-size: 14px; font-weight: 300; letter-spacing: 0.06em; color: rgba(255,255,255,0.6); max-width: 480px; margin: 0 auto 42px; line-height: 1.8; animation: fadeUp 1.2s 0.45s ease both; }
  .hero-cta { display: inline-flex; align-items: center; gap: 10px; padding: 14px 36px; border: 1px solid rgba(255,255,255,0.3); color: #fff; text-decoration: none; font-size: 11px; font-weight: 400; letter-spacing: 0.22em; text-transform: uppercase; transition: all 0.3s ease; animation: fadeUp 1.2s 0.6s ease both; }
  .hero-cta:hover { background: var(--gold); border-color: var(--gold); color: var(--dark); }
  .hero-scroll { position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px; color: rgba(255,255,255,0.35); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; animation: fadeUp 1.2s 1s ease both; }
  .scroll-line { width: 1px; height: 40px; background: linear-gradient(to bottom, rgba(255,255,255,0.4), transparent); animation: scrollP 2s ease-in-out infinite; }
  @keyframes scrollP { 0%,100% { opacity: 0.3; } 50% { opacity: 0.8; } }

  .stats-bar { background: var(--navy); display: grid; grid-template-columns: repeat(3,1fr); }
  .hero-stats { position: absolute; bottom: 0; left: 0; right: 0; display: grid; grid-template-columns: repeat(3,1fr); background: rgba(19,22,65,0.88); backdrop-filter: blur(6px); border-top: 1px solid rgba(184,150,12,0.25); }
  .stat-item { padding: 36px 20px; text-align: center; border-right: 1px solid rgba(255,255,255,0.08); }
  .stat-item:last-child { border-right: none; }
  .stat-number { font-family: "Cormorant Garamond", serif; font-size: 52px; font-weight: 300; color: var(--gold-light); line-height: 1; display: block; }
  .stat-label { font-size: 10px; font-weight: 400; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(255,255,255,0.45); margin-top: 8px; display: block; }

  section { padding: 100px 60px; }
  .section-eyebrow { font-size: 12px; font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; display: block; }
  .section-title { font-family: "Cormorant Garamond", serif; font-size: clamp(32px,5vw,52px); font-weight: 300; line-height: 1.1; color: var(--navy); margin-bottom: 32px; }
  .section-divider { width: 40px; height: 2px; background: var(--gold); margin-bottom: 32px; }
  .section-text { font-size: 15px; line-height: 1.85; color: var(--text-light); max-width: 540px; }
  .section-text p { margin-bottom: 16px; }
  .section-text strong { color: var(--text); font-weight: 600; }

  #nosotros { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; background: var(--cream); }
  .nosotros-images { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
  .nosotros-images img { position: static; width: 100%; height: auto; object-fit: unset; }
  .nosotros-images img { box-shadow: 0 20px 60px rgba(0,0,0,0.15); border: 6px solid white; transition: transform 0.4s ease; }
  .nosotros-images img:hover { transform: translateY(-4px); }

  #historia { background: var(--navy); display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; padding: 80px 60px; }
  #historia .section-title { color: #fff; }
  #historia .section-text { color: rgba(255,255,255,0.6); }
  #historia .section-text strong { color: rgba(255,255,255,0.9); }
  .historia-img { position: relative; overflow: hidden; display: flex; justify-content: center; }
  .historia-img img { width: 65%; height: auto; display: block; filter: grayscale(20%); transition: filter 0.4s; }
  .historia-img:hover img { filter: grayscale(0%); }
  .historia-img::before { content: ""; position: absolute; top: 16px; left: 16px; right: -16px; bottom: -16px; border: 1px solid rgba(184,150,12,0.3); z-index: 0; pointer-events: none; }

  #servicios { background: var(--cream); text-align: center; }
  #servicios .section-divider { margin: 0 auto 60px; }
  .servicios-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 2px; margin-top: 60px; background: rgba(19,22,65,0.08); }
  .servicio-card { background: #fff; padding: 50px 36px; text-align: center; transition: all 0.3s ease; position: relative; overflow: hidden; }
  .servicio-card::before { content: ""; position: absolute; bottom: 0; left: 0; width: 100%; height: 3px; background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform 0.35s ease; }
  .servicio-card:hover { background: var(--navy); }
  .servicio-card:hover .servicio-icon { color: var(--gold-light); }
  .servicio-card:hover .servicio-nombre { color: #fff; }
  .servicio-card:hover .servicio-desc { color: rgba(255,255,255,0.55); }
  .servicio-card:hover::before { transform: scaleX(1); }
  .servicio-icon { font-size: 42px; margin-bottom: 24px; display: block; color: var(--navy); transition: color 0.3s; }
  .servicio-nombre { font-family: "Cormorant Garamond", serif; font-size: 24px; font-weight: 600; color: var(--navy); margin-bottom: 14px; transition: color 0.3s; }
  .servicio-desc { font-size: 14px; font-weight: 400; line-height: 1.7; color: var(--text-light); transition: color 0.3s; }

  #contacto { background: var(--dark); display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 0; }
  .contacto-info { padding: 90px 70px; display: flex; flex-direction: column; justify-content: center; }
  #contacto .section-title { color: #fff; }
  .contacto-dato { display: flex; align-items: flex-start; gap: 18px; margin-bottom: 30px; color: rgba(255,255,255,0.65); font-size: 14px; line-height: 1.7; }
  .contacto-dato-icon { color: var(--gold); font-size: 18px; margin-top: 2px; flex-shrink: 0; }
  .contacto-dato a { color: inherit; text-decoration: none; transition: color 0.2s; }
  .contacto-dato a:hover { color: var(--gold-light); }
  .contacto-mapa { background: #1a1a2e; }
  .contacto-mapa iframe { width: 100%; height: 100%; min-height: 450px; border: none; filter: grayscale(30%) invert(5%); }
  .social-links { display: flex; gap: 16px; margin-top: 36px; }
  .social-link { width: 40px; height: 40px; border: 1px solid rgba(255,255,255,0.15); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.5); text-decoration: none; font-size: 15px; transition: all 0.3s; font-family: serif; }
  .social-link:hover { border-color: var(--gold); color: var(--gold); }

  footer { background: var(--navy); padding: 28px 60px; text-align: center; border-top: 1px solid rgba(255,255,255,0.06); }
  .footer-copy { font-size: 12px; color: rgba(255,255,255,0.35); letter-spacing: 0.06em; }

  .wa-float { position: fixed; bottom: 28px; right: 28px; width: 54px; height: 54px; background: #25d366; border-radius: 50%; display: flex; align-items: center; justify-content: center; text-decoration: none; box-shadow: 0 4px 20px rgba(37,211,102,0.4); z-index: 999; transition: transform 0.3s, box-shadow 0.3s; }
  .wa-float:hover { transform: scale(1.1); box-shadow: 0 8px 30px rgba(37,211,102,0.55); }

  .reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
  .reveal.visible { opacity: 1; transform: translateY(0); }

  .hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 4px; background: none; border: none; }
  .hamburger span { width: 24px; height: 1px; background: white; display: block; }

  @media (max-width: 900px) {
    nav { padding: 0 24px; }
    .nav-links { display: none; position: absolute; top: 72px; left: 0; right: 0; background: var(--navy); flex-direction: column; padding: 20px 24px; gap: 20px; border-top: 1px solid rgba(255,255,255,0.08); }
    .nav-links.open { display: flex; }
    .hamburger { display: flex; }
    #nosotros, #historia { grid-template-columns: 1fr; padding: 60px 24px; gap: 40px; }
    .nosotros-images { height: 300px; }
    .nosotros-images img:first-child { height: 240px; }
    .nosotros-images img:last-child { height: 180px; }
    .servicios-grid { grid-template-columns: 1fr; }
    #contacto { grid-template-columns: 1fr; }
    .contacto-info { padding: 60px 24px; }
    section { padding: 70px 24px; }
    footer { flex-direction: column; gap: 8px; text-align: center; padding: 20px 24px; }
    .stats-bar { grid-template-columns: 1fr; }
    .stat-item { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.08); }
    .stat-item:last-child { border-bottom: none; }
  }
