/* ==========================================================
   JP Notary & Tax Services – estilos
   Paleta: azul marino + dorado (según la identidad de la marca)
   ========================================================== */

:root {
  --navy: #0b1f4b;
  --navy-dark: #071539;
  --navy-light: #16306b;
  --gold: #c9a227;
  --gold-light: #e2c35a;
  --cream: #f7f5f0;
  --white: #ffffff;
  --text: #1e2333;
  --muted: #5b6275;
  --border: #e4e2dc;
  --whatsapp: #25d366;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(11, 31, 75, .10);
  --font-head: 'Playfair Display', Georgia, serif;
  --font-body: 'Montserrat', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
}
img, video { max-width: 100%; display: block; }
a { color: var(--navy); text-decoration: none; }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.15; margin: 0 0 .5em; color: var(--navy); }
h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }

.container { width: min(1140px, 92%); margin-inline: auto; }
.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.section-alt { background: var(--cream); }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.lead { color: var(--muted); font-size: 1.05rem; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .75rem;
  font-weight: 600;
  color: var(--gold);
  margin-bottom: .6em;
}
.text-center { text-align: center; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .85rem 1.6rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, background .15s, color .15s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-primary { background: var(--navy); color: var(--white); }
.btn-gold { background: var(--gold); color: var(--navy-dark); }
.btn-gold:hover { background: var(--gold-light); }
.btn-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline:hover { background: var(--navy); color: var(--white); }
.btn-outline-light { background: transparent; color: var(--white); border-color: rgba(255,255,255,.7); }
.btn-outline-light:hover { background: var(--white); color: var(--navy); }
.btn-whatsapp { background: var(--whatsapp); color: var(--white); }
.btn-whatsapp:hover { background: #1ebe5b; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 31, 75, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(201, 162, 39, .35);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: .75rem; color: var(--white); }
.brand-logo {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--white); object-fit: cover;
  box-shadow: 0 0 0 2px var(--gold);
}
.brand-logo--lg { width: 72px; height: 72px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-family: var(--font-head); font-size: 1.15rem; }
.brand-text small { font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-light); }

.nav { display: flex; align-items: center; gap: 1.5rem; }
.nav a { color: var(--white); font-weight: 500; font-size: .92rem; position: relative; }
.nav a:not(.btn)::after {
  content: ''; position: absolute; left: 0; bottom: -6px; height: 2px; width: 0;
  background: var(--gold); transition: width .2s;
}
.nav a:not(.btn):hover::after { width: 100%; }
.nav-cta { padding: .55rem 1.1rem; font-size: .85rem; }

.lang-switch {
  display: inline-flex; border: 1px solid rgba(255,255,255,.35); border-radius: 999px; overflow: hidden;
}
.lang-btn {
  background: transparent; border: 0; color: rgba(255,255,255,.75);
  font: inherit; font-size: .75rem; font-weight: 700; letter-spacing: .05em;
  padding: .35rem .7rem; cursor: pointer; transition: .15s;
}
.lang-btn:hover { color: var(--white); }
.lang-btn.is-active { background: var(--gold); color: var(--navy-dark); }

.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer; padding: .5rem;
  flex-direction: column; gap: 5px;
}
.nav-toggle span { display: block; width: 26px; height: 2px; background: var(--white); transition: .2s; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: grid; place-items: center;
  color: var(--white);
  overflow: hidden;
  background: var(--navy-dark);
}
.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(7, 21, 57, .92) 0%, rgba(11, 31, 75, .78) 55%, rgba(11, 31, 75, .55) 100%);
}
.hero-content { position: relative; text-align: center; padding: 5rem 0; max-width: 820px; }
.hero h1 { color: var(--white); }
.hero h1::after {
  content: ''; display: block; width: 90px; height: 3px;
  background: var(--gold); margin: 1rem auto 0;
}
.hero-sub { font-size: 1.1rem; color: rgba(255,255,255,.88); max-width: 640px; margin: 1.2rem auto 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-bottom: 2.5rem; }
.hero-badges {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; justify-content: center;
  font-size: .9rem; color: var(--gold-light); font-weight: 500;
}

/* ---------- Servicios ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: transform .2s, border-color .2s;
  display: flex; flex-direction: column;
}
.service-card:hover { transform: translateY(-4px); border-color: var(--gold); }
.service-card p { color: var(--muted); flex: 1; }
.service-icon {
  width: 56px; height: 56px; display: grid; place-items: center;
  background: var(--cream); border-radius: 12px; font-size: 1.7rem; margin-bottom: 1rem;
}
.link-more { font-weight: 600; color: var(--gold); }
.link-more:hover { color: var(--navy); }
.service-card--cta { background: var(--navy); border-color: var(--navy); color: var(--white); }
.service-card--cta h3 { color: var(--white); }
.service-card--cta p { color: rgba(255,255,255,.85); }

/* ---------- Precios ---------- */
.tabs {
  display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; margin-bottom: 2rem;
}
.tab {
  background: var(--white);
  border: 1px solid var(--border);
  padding: .65rem 1.3rem;
  border-radius: 999px;
  font: inherit; font-weight: 600; font-size: .9rem;
  color: var(--navy);
  cursor: pointer;
  transition: .15s;
}
.tab:hover { border-color: var(--gold); }
.tab.is-active { background: var(--navy); color: var(--white); border-color: var(--navy); }

.price-panel { display: none; }
.price-panel.is-active { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.5rem; }
.price-group {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow);
}
.price-group h3 {
  font-family: var(--font-body); font-size: .8rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--navy); border-bottom: 2px solid var(--gold); padding-bottom: .6rem; margin-bottom: .8rem;
}
.price-list { list-style: none; padding: 0; margin: 0; }
.price-list li {
  display: flex; align-items: baseline; gap: .5rem;
  padding: .45rem 0; font-size: .95rem;
}
.price-list li span:first-child { flex: 0 1 auto; }
.price-list li::after { content: ''; flex: 1; border-bottom: 1px dotted #b8b5ad; margin-bottom: .3em; order: 2; }
.price-list li span:first-child { order: 1; }
.price-list li .price { order: 3; font-weight: 700; color: var(--navy); white-space: nowrap; }
.price-loading { text-align: center; color: var(--muted); padding: 2rem 0; }
.price-loading a { font-weight: 600; }
.price-note { font-size: .8rem; color: var(--muted); margin-top: .8rem; font-style: italic; }

.disclaimer {
  margin: 2.5rem auto 0; max-width: 760px; text-align: center;
  background: #fff8e1; border: 1px solid #f1dc95; border-radius: 10px;
  padding: 1rem 1.25rem; font-size: .9rem;
}

/* ---------- Galería (carrusel) ---------- */
.carousel {
  background: #0d1117;
  border-radius: var(--radius);
  padding: 1rem;
  position: relative;
  box-shadow: var(--shadow);
  outline: none;
}
.carousel:focus-visible { box-shadow: 0 0 0 3px var(--gold); }
.carousel-viewport { position: relative; }
.carousel-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  max-height: 600px;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}
.stage-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity .5s ease;
}
.stage-img.is-active { opacity: 1; }
.carousel-btn {
  position: absolute; top: 0; bottom: 0; margin: auto 0;
  height: 56px; width: 44px;
  background: rgba(11, 31, 75, .65); color: var(--white);
  border: 0; border-radius: 8px; font-size: 1.4rem; cursor: pointer;
  transition: background .15s;
}
.carousel-btn:hover { background: var(--gold); color: var(--navy-dark); }
.carousel-prev { left: .75rem; }
.carousel-next { right: .75rem; }
.carousel-counter {
  position: absolute; top: .75rem; right: .75rem;
  background: rgba(0,0,0,.55); color: var(--white);
  font-size: .8rem; font-weight: 600; padding: .25rem .6rem; border-radius: 999px;
}
.carousel-thumbs {
  display: flex; gap: .6rem;
  margin-top: .8rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.25) transparent;
  padding-bottom: .3rem;
}
.thumb {
  flex: 0 0 auto;
  width: 120px; aspect-ratio: 1;
  border: 2px solid transparent; border-radius: 6px;
  padding: 0; background: #000; cursor: pointer;
  overflow: hidden; opacity: .55;
  scroll-snap-align: center;
  transition: opacity .15s, border-color .15s;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb:hover { opacity: .85; }
.thumb.is-active { opacity: 1; border-color: var(--gold); }

/* ---------- Nosotros ---------- */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.about-media video { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); background: #000; }
.checklist { list-style: none; padding: 0; margin: 0 0 1.8rem; }
.checklist li { padding: .35rem 0 .35rem 1.8rem; position: relative; }
.checklist li::before {
  content: '✔'; position: absolute; left: 0; color: var(--gold); font-weight: 700;
}

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 2rem; }
.contact-cards { display: grid; gap: 1rem; align-content: start; }
.contact-card {
  display: flex; align-items: center; gap: 1rem;
  background: var(--white); border: 1px solid var(--border); border-radius: 12px;
  padding: 1.1rem 1.3rem; box-shadow: var(--shadow); color: var(--text);
  transition: border-color .15s, transform .15s;
}
a.contact-card:hover { border-color: var(--gold); transform: translateX(4px); }
.contact-icon {
  width: 48px; height: 48px; flex: none; display: grid; place-items: center;
  background: var(--navy); color: var(--white); border-radius: 10px; font-size: 1.4rem;
}
.map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); min-height: 360px; }
.map iframe { width: 100%; height: 100%; min-height: 360px; border: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-dark); color: rgba(255,255,255,.85); padding: 3rem 0 2rem; }
.footer-inner { display: grid; grid-template-columns: 1.2fr 1fr 1.2fr; gap: 2rem; align-items: start; }
.footer-inner p { font-size: .9rem; margin-top: .8rem; }
.footer-inner p a { color: rgba(255,255,255,.85); }
.footer-inner p a:hover { color: var(--gold); }
.footer-nav { display: flex; flex-direction: column; gap: .5rem; }
.footer-nav a { color: rgba(255,255,255,.85); }
.footer-nav a:hover { color: var(--gold); }
.footer-legal { font-size: .8rem; color: rgba(255,255,255,.6); text-align: right; }

/* ---------- WhatsApp flotante ---------- */
.wa-float {
  position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 60;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--whatsapp); color: var(--white);
  display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(37, 211, 102, .45);
  transition: transform .15s;
}
.wa-float:hover { transform: scale(1.08); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about, .contact-grid, .footer-inner { grid-template-columns: 1fr; }
  .footer-legal { text-align: left; }
}
@media (max-width: 768px) {
  .nav-toggle { display: flex; }
  .nav {
    position: absolute; top: 72px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--navy-dark);
    border-bottom: 1px solid rgba(201,162,39,.35);
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
  }
  .nav.is-open { max-height: 480px; }
  .nav a { padding: 1rem 4%; border-top: 1px solid rgba(255,255,255,.08); }
  .nav a:not(.btn)::after { display: none; }
  .nav-cta { margin: 1rem 4%; justify-content: center; }
  .lang-switch { margin: 0 4% 1rem; align-self: flex-start; }
  .hero { min-height: 80vh; }
  .carousel { padding: .5rem; }
  .carousel-stage { aspect-ratio: 1; }
  .thumb { width: 84px; }
  .brand-text small { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-video { display: none; }
}
