/* ========== DESIGN TOKENS ========== */
:root {
  --color-primary: #1B3FBF;
  --color-primary-dark: #132D8A;
  --color-primary-light: rgba(27, 63, 191, 0.08);
  --color-secondary: #D4952B;
  --color-secondary-light: #F0B84A;
  --color-ocean: #4DA8D4;
  --color-ocean-light: #A8DBF0;
  --color-accent: #25D366;
  --color-dark: #0E1A3D;
  --color-gray-700: #374151;
  --color-gray-400: #9CA3AF;
  --color-gray-100: #F1F5F9;
  --color-white: #FFFFFF;

  --font-heading: 'Montserrat', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --max-width: 1200px;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(14, 26, 61, 0.08);
  --shadow-lg: 0 8px 40px rgba(14, 26, 61, 0.12);
  --shadow-xl: 0 16px 64px rgba(14, 26, 61, 0.16);
}

/* ========== RESET ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  font-family: var(--font-body);
  color: var(--color-gray-700);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  background: var(--color-white);
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* ========== UTILITIES ========== */
.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section-tag {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--color-secondary);
  margin-bottom: 16px;
}
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.2;
  color: var(--color-dark);
  margin-bottom: 16px;
}
.section-title--center { text-align: center; }
.section-subtitle {
  font-size: 1.125rem;
  color: var(--color-gray-400);
  max-width: 600px;
  margin-bottom: 48px;
}
.section-subtitle--center { text-align: center; margin-left: auto; margin-right: auto; }
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: transform 0.2s, box-shadow 0.2s;
  min-height: 52px;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-whatsapp {
  background-color: var(--color-accent);
  color: var(--color-white);
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.35);
}
.btn-whatsapp:hover { box-shadow: 0 6px 28px rgba(37, 211, 102, 0.45); }
.btn-whatsapp svg { width: 22px; height: 22px; fill: currentColor; }
.btn-secondary {
  background-color: var(--color-white);
  color: var(--color-primary);
  box-shadow: var(--shadow);
}
.btn-secondary:hover { box-shadow: var(--shadow-lg); }
.btn-outline {
  background: transparent;
  color: var(--color-white);
  border: 2px solid rgba(255,255,255,0.4);
}
.btn-outline:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.7); }

/* ========== HEADER ========== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0 20px;
  background: var(--color-primary);
  box-shadow: 0 4px 24px rgba(14, 26, 61, 0.2);
  transition: box-shadow 0.3s;
}
.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100px;
}
.logo-img { height: 100px; width: auto; }
.nav { display: flex; align-items: center; gap: 32px; }
.nav a {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-white);
  transition: color 0.2s, opacity 0.2s;
  opacity: 0.85;
}
.nav a:hover { opacity: 1; }
.nav .btn { padding: 10px 24px; font-size: 0.875rem; min-height: 44px; }
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  z-index: 101;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  margin: 6px 0;
  transition: 0.3s;
}

/* ========== CTA SECTION ========== */
.cta-section {
  position: relative;
  text-align: center;
  color: var(--color-white);
  overflow: hidden;
  background: linear-gradient(135deg, var(--color-dark) 0%, var(--color-primary-dark) 50%, var(--color-primary) 100%);
}
.cta-section h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 800;
  margin-bottom: 16px;
}
.cta-section p {
  font-size: 1.125rem;
  opacity: 0.85;
  margin-bottom: 36px;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

/* ========== FOOTER ========== */
.footer {
  background: var(--color-dark);
  color: rgba(255, 255, 255, 0.6);
  padding: 64px 0 24px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand p { max-width: 320px; font-size: 0.875rem; margin-top: 16px; line-height: 1.7; }
.footer-links h4 {
  color: var(--color-white);
  font-family: var(--font-heading);
  font-size: 0.9375rem;
  font-weight: 700;
  margin-bottom: 16px;
}
.footer-links a {
  display: block;
  font-size: 0.875rem;
  margin-bottom: 10px;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--color-white); }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  text-align: center;
  font-size: 0.8125rem;
}

/* ========== WHATSAPP FLOAT ========== */
.whatsapp-float {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 999;
  width: 64px;
  height: 64px;
  background: var(--color-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 24px rgba(37, 211, 102, 0.4);
  transition: transform 0.3s, box-shadow 0.3s;
}
.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 32px rgba(37, 211, 102, 0.5);
}
.whatsapp-float svg { width: 34px; height: 34px; fill: white; }
.whatsapp-float::before {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(37, 211, 102, 0.4);
  animation: whatsappPulse 2s ease-in-out infinite;
}

@keyframes whatsappPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.15); opacity: 0; }
}

/* ========== BLOG HERO ========== */
.blog-hero {
  background: linear-gradient(135deg, var(--color-dark) 0%, var(--color-primary-dark) 50%, var(--color-primary) 100%);
  color: var(--color-white);
  text-align: center;
  padding: 80px 0 64px;
  margin-top: 100px;
}
.blog-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}
.blog-hero p {
  font-size: 1.125rem;
  opacity: 0.85;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ========== BLOG CATEGORIES BAR ========== */
.blog-categories {
  background: var(--color-white);
  border-bottom: 1px solid rgba(14, 26, 61, 0.08);
  padding: 20px 0;
  position: sticky;
  top: 100px;
  z-index: 100;
}
.blog-categories-inner {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}
.blog-categories a {
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 100px;
  border: 1.5px solid rgba(27, 63, 191, 0.2);
  color: var(--color-gray-700);
  background: var(--color-white);
  transition: all 0.2s;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
}
.blog-categories a:hover {
  background: var(--color-primary-light);
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.blog-categories a.active {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-white);
}

/* ========== POSTS GRID ========== */
.posts-section {
  padding: 64px 0;
  background: var(--color-gray-100);
  min-height: 400px;
}
.posts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

/* ========== POST CARD ========== */
.post-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
}
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.post-card-img-wrap {
  display: block;
  overflow: hidden;
}
.post-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.post-card:hover .post-card-img-wrap img { transform: scale(1.04); }
.post-card-body {
  padding: 24px 24px 28px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.post-card-category {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-secondary);
  margin-bottom: 10px;
}
.post-card h3 {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--color-dark);
  line-height: 1.35;
  margin-bottom: 10px;
  flex: 1;
}
.post-card h3 a { color: inherit; transition: color 0.2s; }
.post-card h3 a:hover { color: var(--color-primary); }
.post-card-excerpt {
  font-size: 0.9rem;
  color: var(--color-gray-400);
  line-height: 1.6;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-card-meta {
  font-size: 0.8125rem;
  color: var(--color-gray-400);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
}
.post-card-meta span { display: flex; align-items: center; gap: 4px; }

/* ========== POST ARTICLE ========== */
.post-wrapper {
  margin-top: 100px;
  padding: 48px 0 80px;
}
.post-article {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Breadcrumb */
.breadcrumb {
  font-size: 0.8125rem;
  color: var(--color-gray-400);
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.breadcrumb a { color: var(--color-primary); transition: opacity 0.2s; }
.breadcrumb a:hover { opacity: 0.75; }
.breadcrumb-sep { opacity: 0.5; }

/* Post header */
.post-header { margin-bottom: 32px; }
.post-header .post-category-link {
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--color-secondary);
  display: inline-block;
  margin-bottom: 14px;
}
.post-header h1 {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 4.5vw, 2.5rem);
  font-weight: 800;
  color: var(--color-dark);
  line-height: 1.2;
  margin-bottom: 20px;
}

/* Post meta (author row) */
.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-top: 1px solid rgba(14, 26, 61, 0.08);
  border-bottom: 1px solid rgba(14, 26, 61, 0.08);
}
.post-meta-author-photo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid var(--color-ocean-light);
}
.post-meta-author-name {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--color-dark);
}
.post-meta-info {
  font-size: 0.8125rem;
  color: var(--color-gray-400);
}
.post-meta-info span + span::before { content: ' · '; }

/* Featured image */
.post-featured-image {
  margin: 32px 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.post-featured-image img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

/* Article body typography */
.post-content { margin-bottom: 40px; }
.post-content h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-dark);
  margin: 2.5em 0 0.75em;
  line-height: 1.3;
}
.post-content h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-dark);
  margin: 2em 0 0.6em;
  line-height: 1.35;
}
.post-content p {
  font-size: 1.0625rem;
  line-height: 1.85;
  margin-bottom: 1.5em;
  color: var(--color-gray-700);
}
.post-content img {
  width: 100%;
  border-radius: var(--radius);
  margin: 2em 0;
  box-shadow: var(--shadow);
}
.post-content figure {
  margin: 2em 0;
}
.post-content .instagram-embed-wrap {
  margin: 2em auto;
  max-width: 540px;
  text-align: center;
}
.post-content .instagram-embed-wrap iframe {
  border: none;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.post-content figure img {
  margin: 0 0 0.5em 0;
}
.post-content figcaption {
  font-size: 0.8125rem;
  color: var(--color-gray-500, #888);
  text-align: center;
  line-height: 1.4;
}
.post-content blockquote {
  border-left: 4px solid var(--color-primary);
  padding: 16px 24px;
  margin: 2em 0;
  background: var(--color-primary-light);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 1rem;
  color: var(--color-dark);
  line-height: 1.7;
}
.post-content blockquote p { margin-bottom: 0; color: var(--color-dark); }
.post-content blockquote a { color: var(--color-primary); font-weight: 600; text-decoration: underline; }
.post-content ul, .post-content ol {
  padding-left: 1.5em;
  margin-bottom: 1.5em;
}
.post-content ul { list-style: disc; }
.post-content ol { list-style: decimal; }
.post-content li { margin-bottom: 0.5em; font-size: 1.0625rem; line-height: 1.8; }
.post-content strong { font-weight: 700; color: var(--color-dark); }
.post-content a { color: var(--color-primary); text-decoration: underline; transition: opacity 0.2s; }
.post-content a:hover { opacity: 0.75; }

/* Inline WhatsApp CTA */
.cta-whatsapp-inline {
  background: linear-gradient(135deg, var(--color-dark) 0%, var(--color-primary) 100%);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  text-align: center;
  margin: 2.5em 0;
  color: var(--color-white);
}
.cta-whatsapp-inline p {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 18px;
  color: var(--color-white);
  line-height: 1.4;
}
.cta-whatsapp-inline .btn-whatsapp {
  font-size: 1rem;
  padding: 14px 28px;
}

/* Post tags */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 32px 0;
}
.post-tag {
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 100px;
  background: var(--color-gray-100);
  color: var(--color-gray-700);
  border: 1px solid rgba(14, 26, 61, 0.1);
  transition: all 0.2s;
}
.post-tag:hover {
  background: var(--color-primary-light);
  color: var(--color-primary);
  border-color: var(--color-primary);
}

/* Author card */
.post-author-card {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  background: var(--color-gray-100);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  margin: 40px 0;
}
.post-author-card img {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 3px solid var(--color-white);
  box-shadow: var(--shadow);
}
.post-author-info { flex: 1; }
.post-author-name {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-dark);
  margin-bottom: 2px;
}
.post-author-role {
  font-size: 0.8125rem;
  color: var(--color-secondary);
  font-weight: 600;
  margin-bottom: 10px;
}
.post-author-bio {
  font-size: 0.9rem;
  color: var(--color-gray-400);
  line-height: 1.7;
  margin-bottom: 0;
}

/* Related posts */
.related-posts {
  background: var(--color-gray-100);
  padding: 64px 0;
}
.related-posts-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.related-posts h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-dark);
  margin-bottom: 32px;
  text-align: center;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
  .posts-grid { grid-template-columns: repeat(2, 1fr); }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .section { padding: 56px 0; }

  /* Header mobile */
  .header-inner { height: 72px; }
  .logo-img { height: 60px; }
  .nav { display: none; }
  .nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--color-primary);
    padding: 24px;
    box-shadow: var(--shadow-lg);
    gap: 16px;
  }
  .nav.open a { color: var(--color-white); opacity: 0.9; }
  .menu-toggle { display: block; }

  /* Blog hero */
  .blog-hero { padding: 60px 0 48px; margin-top: 72px; }
  .blog-categories { top: 72px; }

  /* Grids */
  .posts-grid { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 32px; }

  /* Article */
  .post-wrapper { margin-top: 72px; padding: 32px 0 60px; }
  .post-author-card { flex-direction: column; gap: 16px; }
  .post-meta-info span + span::before { content: '\A'; white-space: pre; }
}

@media (max-width: 480px) {
  .blog-categories-inner { gap: 8px; }
  .blog-categories a { font-size: 0.75rem; padding: 7px 14px; }
  .cta-whatsapp-inline { padding: 24px 20px; }
}
