/* ========================================
   INDEPAR - Estilos Globales
   Instituto de Estrategia Integral para el Retiro
   ======================================== */

/* --- Variables --- */
:root {
  --navy: #1B2A5E;
  --navy-dark: #0F1B3D;
  --gold: #B8943E;
  --gold-light: #D4B15A;
  --bg-alt: #F4F5FA;
  --text-primary: #212529;
  --text-secondary: #6C757D;
  --white: #FFFFFF;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --transition: 0.3s ease;
  --max-width: 1140px;
}

/* --- Reset --- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-primary);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Merriweather', serif;
  font-weight: 700;
  line-height: 1.3;
  color: var(--navy);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; margin-bottom: 1rem; }
h3 { font-size: 1.5rem; margin-bottom: 0.75rem; }
h4 { font-size: 1.25rem; margin-bottom: 0.5rem; }

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

/* --- Layout --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

.section--alt {
  background: var(--bg-alt);
}

.section__header {
  text-align: center;
  margin-bottom: 3rem;
}

.section__header p {
  max-width: 640px;
  margin: 0.5rem auto 0;
  font-size: 1.1rem;
}

/* --- Gold accent line --- */
.gold-line {
  width: 60px;
  height: 3px;
  background: var(--gold);
  margin: 1rem auto;
  border-radius: 2px;
}

.gold-line--left {
  margin-left: 0;
}

/* ========================================
   NAVIGATION
   ======================================== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: 'Merriweather', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy);
}

.nav__brand img {
  height: 44px;
  width: auto;
}

.nav__links {
  display: flex;
  gap: 2rem;
}

.nav__link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  padding: 0.25rem 0;
  transition: color var(--transition);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold);
  transition: width var(--transition);
}

.nav__link:hover,
.nav__link--active {
  color: var(--navy);
}

.nav__link:hover::after,
.nav__link--active::after {
  width: 100%;
}

/* Hamburger */
.nav__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}

.nav__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  transition: var(--transition);
  border-radius: 1px;
}

/* Mobile menu */
.nav__mobile {
  display: none;
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--white);
  padding: 2rem 1.5rem;
  z-index: 999;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity var(--transition), transform var(--transition);
}

.nav__mobile.is-open {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

.nav__mobile a {
  display: block;
  padding: 1rem 0;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-primary);
  border-bottom: 1px solid var(--bg-alt);
}

.nav__mobile a:hover,
.nav__mobile a.nav__link--active {
  color: var(--gold);
}

/* Hamburger active state */
.nav__hamburger.is-active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav__hamburger.is-active span:nth-child(2) {
  opacity: 0;
}

.nav__hamburger.is-active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Body offset for fixed nav */
body {
  padding-top: 72px;
}

/* ========================================
   PAGE HERO (inner pages)
   ======================================== */
.page-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-dark) 100%);
  padding: 4rem 0;
  text-align: center;
}

.page-hero h1 {
  color: var(--white);
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.page-hero .gold-line {
  margin-top: 1rem;
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.7);
  border-top: 3px solid var(--gold);
}

.footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3.5rem 1.5rem 2rem;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2.5rem;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.footer__brand img {
  height: 48px;
  width: auto;
}

.footer__brand span {
  font-family: 'Merriweather', serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
}

.footer__desc {
  font-size: 0.9rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.6);
}

.footer__title {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--gold);
  margin-bottom: 1.25rem;
}

.footer__links a {
  display: block;
  padding: 0.35rem 0;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
  transition: color var(--transition);
}

.footer__links a:hover {
  color: var(--white);
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.4);
}

/* ========================================
   CARDS
   ======================================== */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.card {
  background: var(--white);
  border-radius: 12px;
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  text-align: center;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1.25rem;
  color: var(--gold);
}

.card__icon svg {
  width: 100%;
  height: 100%;
}

.card h3 {
  color: var(--navy);
  font-size: 1.2rem;
}

.card p {
  font-size: 0.95rem;
  margin-bottom: 1.25rem;
}

.card__link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gold);
  transition: gap var(--transition);
}

.card__link:hover {
  gap: 0.7rem;
}

/* ========================================
   VALUES GRID
   ======================================== */
.values-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.value-card {
  text-align: center;
  padding: 2rem 1.5rem;
}

.value-card__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 1rem;
  color: var(--gold);
}

.value-card__icon svg {
  width: 100%;
  height: 100%;
}

.value-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.value-card p {
  font-size: 0.9rem;
}

/* ========================================
   SERVICE BLOCKS
   ======================================== */
.service-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.service-block__content h2 {
  margin-bottom: 0.5rem;
}

.service-block__content > p {
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

.service-item {
  padding: 1.25rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.service-item:last-child {
  border-bottom: none;
}

.service-item h4 {
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.service-item h4 .item-icon {
  width: 20px;
  height: 20px;
  color: var(--gold);
  flex-shrink: 0;
}

.service-item p {
  font-size: 0.95rem;
  margin-bottom: 0;
  padding-left: 1.75rem;
}

/* ========================================
   UTILITIES
   ======================================== */
.text-center { text-align: center; }
.text-gold { color: var(--gold); }
.text-navy { color: var(--navy); }
.mb-0 { margin-bottom: 0; }

/* ========================================
   RESPONSIVE
   ======================================== */

/* Tablet */
@media (max-width: 1024px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  .section { padding: 4rem 0; }
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .values-grid { grid-template-columns: repeat(2, 1fr); }
  .service-block { grid-template-columns: 1fr; gap: 2rem; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

/* Mobile */
@media (max-width: 768px) {
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
  .section { padding: 3rem 0; }
  .container { padding: 0 1rem; }

  .nav__links { display: none; }
  .nav__hamburger { display: flex; }

  .cards-grid { grid-template-columns: 1fr; }
  .values-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 2rem; }
  .page-hero { padding: 3rem 0; }
  .page-hero h1 { font-size: 2rem; }
}
