/* ==========================================================================
   DESIGN SYSTEM & CUSTOM STYLES — FOUNDATION EMIRES (VISUAL FIXES)
   ========================================================================== */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Montserrat:wght@500;600;700;800&display=swap');

:root {
  /* HSL Color Palette */
  --brand-blue-deep: hsl(206, 69%, 38%); /* #1E6CA6 - Deep Blue (Trust/Clinical) */
  --brand-blue: hsl(201, 61%, 47%); /* #2E8BC0 - Medium Blue */
  --brand-cyan: hsl(186, 53%, 51%); /* #3FB8C4 - Cyan */
  --brand-mint: hsl(163, 50%, 71%); /* #8FD9C4 - Mint Green */
  --brand-gray: hsl(210, 2%, 34%); /* #555759 - Corporate Typography */
  --brand-cream: #f5f1e8; /* #F5F1E8 - Warm Cream */
  --brand-cream-dark: #eae3d2;
  --white: #ffffff;
  --black: #1a1c1d;
  --gray-light: #f0f2f5;
  --gray-border: #e1e4e8;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);

  --healing-gradient: linear-gradient(
    120deg,
    var(--brand-blue-deep) 0%,
    var(--brand-cyan) 55%,
    var(--brand-mint) 100%
  );
  --font-title: 'Montserrat', sans-serif;
  --font-body: 'Inter', sans-serif;

  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
  font-family: var(--font-body);
  background-color: var(--brand-cream);
  color: var(--brand-gray);
  line-height: 1.65;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-title);
  color: var(--brand-blue-deep);
  font-weight: 700;
  line-height: 1.25;
}

a {
  color: var(--brand-blue);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--brand-blue-deep);
}

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

/* Utilities */
.mobile-only {
  display: none !important;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin-right: auto;
  margin-left: auto;
  padding-right: 1.5rem;
  padding-left: 1.5rem;
}

.text-center {
  text-align: center;
}
.py-section {
  padding-top: 5rem;
  padding-bottom: 5rem;
}
.mt-4 {
  margin-top: 1.5rem;
}
.mb-2 {
  margin-bottom: 0.5rem;
}
.mb-4 {
  margin-bottom: 1.5rem;
}

/* Justified Body Texts (Senior Frontend Polish) */
p,
.about-text p,
.pillar-content p,
.value-card p,
.member-bio,
.testimonio-text,
.contact-policy p,
.transparency-intro p,
.doc-card p,
.legal-bullet-list li,
.legal-callout p,
.legal-callout-danger p {
  text-align: justify;
  text-justify: inter-word;
}

.section-title {
  font-size: 2.25rem;
  margin-bottom: 1rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: var(--healing-gradient);
  border-radius: 2px;
}

/* Buttons Styling */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.6rem;
  font-family: var(--font-title);
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  text-align: center;
  box-shadow:
    0 4px 10px rgba(30, 108, 166, 0.1),
    0 1px 3px rgba(0, 0, 0, 0.05);
  white-space: nowrap;
  flex-shrink: 0; /* Never allow buttons to squeeze */
}

.btn-primary {
  background: var(--healing-gradient);
  color: var(--white);
}

.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 8px 20px rgba(30, 108, 166, 0.25),
    0 3px 6px rgba(0, 0, 0, 0.05);
  opacity: 1;
  color: var(--white);
}

.btn-secondary {
  background-color: var(--white);
  color: var(--brand-blue-deep);
  border: 2px solid var(--brand-blue-deep);
}

.btn-secondary:hover {
  background-color: var(--brand-blue-deep);
  color: var(--white);
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 8px 20px rgba(30, 108, 166, 0.2),
    0 3px 6px rgba(0, 0, 0, 0.05);
}

/* Header Action Buttons (More compact for header alignment) */
.header-actions .btn {
  padding: 0.55rem 1.25rem;
  font-size: 0.8rem;
  box-shadow: var(--shadow-sm);
}

.header-actions .btn:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow: var(--shadow-md);
}

.btn-text {
  background: none;
  color: var(--brand-blue-deep);
  border: none;
  box-shadow: none;
  text-decoration: underline;
  padding: 0.5rem 1rem;
}

.btn-text:hover {
  color: var(--brand-blue);
  transform: translateY(-1px);
}

/* Header & Navigation Layout Fixes */
header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--gray-border);
  transition: var(--transition-fast);
}

header.scrolled {
  box-shadow: var(--shadow-sm);
  background-color: rgba(255, 255, 255, 0.95);
}

.nav-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 95px;
  gap: 1.5rem;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.logo-img {
  height: 64px;
  width: auto;
}

.logo-text {
  font-family: var(--font-title);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.5px;
  color: var(--brand-gray);
  line-height: 1.1;
  text-transform: uppercase;
  white-space: nowrap; /* Prevent horizontal wrapping of main brand name */
}

.logo-text span {
  display: block;
  font-size: 0.75rem;
  color: var(--brand-blue-deep);
  font-weight: 500;
  letter-spacing: 0.5px;
  white-space: nowrap; /* Prevent horizontal wrapping of tagline */
}

nav {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 1rem;
  align-items: center;
}

.nav-links a {
  font-family: var(--font-title);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--brand-gray);
  position: relative;
  padding: 0.5rem 0;
  white-space: nowrap;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--healing-gradient);
  transition: var(--transition-fast);
}

.nav-links a:hover {
  color: var(--brand-blue-deep);
}

.nav-links a:hover::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

/* Language Switcher Fixes */
.lang-toggle {
  background: none;
  border: 2px solid var(--brand-blue-deep);
  border-radius: 30px;
  padding: 0.45rem 1rem;
  font-family: var(--font-title);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand-blue-deep);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  white-space: nowrap;
  min-width: 85px;
  flex-shrink: 0; /* Never allow language toggle to squeeze */
}

.lang-toggle:hover {
  background-color: var(--brand-blue-deep);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(30, 108, 166, 0.15);
}

/* Mobile Menu Button */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-menu-btn span {
  display: block;
  width: 24px;
  height: 3px;
  background-color: var(--brand-gray);
  margin: 5px 0;
  transition: var(--transition-fast);
}

/* Hero Section */
.hero-section {
  position: relative;
  min-height: calc(100vh - 95px);
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--white);
  padding: 4rem 0;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(30, 108, 166, 0.9) 0%,
    rgba(63, 184, 196, 0.75) 60%,
    rgba(143, 217, 196, 0.4) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
  margin-left: 0;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.25rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 2.5rem;
  max-width: 600px;
}

.hero-actions {
  display: flex;
  gap: 1.25rem;
}

/* About Us Section */
.about-section {
  background-color: var(--white);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-img-container {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.about-img-container::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 10px solid rgba(255, 255, 255, 0.2);
  pointer-events: none;
}

.about-text h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

.about-text p {
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
  color: var(--brand-gray);
}

.about-value-prop {
  background-color: var(--brand-cream);
  padding: 1.5rem;
  border-left: 4px solid var(--brand-cyan);
  border-radius: 0 8px 8px 0;
  font-style: italic;
  font-weight: 500;
}

/* Philosophy Section */
.philosophy-section {
  background-color: var(--brand-cream);
}

.philosophy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.philosophy-card-mv {
  background: var(--white);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  border-top: 5px solid var(--brand-blue-deep);
}

.philosophy-card-mv h3 {
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.philosophy-card-mv blockquote {
  font-size: 1.15rem;
  font-style: italic;
  font-weight: 500;
  color: var(--brand-gray);
  line-height: 1.6;
}

/* Values Grid */
.values-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.value-card {
  background-color: var(--white);
  padding: 1.75rem 1.25rem;
  border-radius: 10px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-normal);
  border: 1px solid var(--gray-border);
}

.value-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-cyan);
}

.value-icon {
  width: 54px;
  height: 54px;
  background: var(--brand-cream);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  color: var(--brand-blue-deep);
  font-size: 1.6rem;
}

.value-card h4 {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
  color: var(--brand-blue-deep);
}

.value-card p {
  font-size: 0.85rem;
  color: var(--brand-gray);
}

/* Pillars Section */
.pillars-title {
  margin-bottom: 2.5rem;
  text-align: center;
}

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.pillar-card {
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition-normal);
}

.pillar-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.pillar-img {
  height: 220px;
  width: 100%;
  object-fit: cover;
}

.pillar-content {
  padding: 2rem;
}

.pillar-content h4 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--brand-blue-deep);
}

.pillar-content p {
  font-size: 0.95rem;
  color: var(--brand-gray);
}

/* Plan de Acción Section */
.plan-section {
  background-color: var(--white);
}

.plan-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  margin-top: 3rem;
}

/* Needs assessment */
.needs-card {
  background: var(--brand-cream);
  padding: 2.5rem;
  border-radius: 12px;
  box-shadow: var(--shadow-sm);
  border-left: 5px solid var(--brand-blue-deep);
}

.needs-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--brand-blue-deep);
}

.needs-list {
  list-style: none;
}

.needs-list li {
  margin-bottom: 1.5rem;
  position: relative;
  padding-left: 2rem;
}

.needs-list li::before {
  content: '✦';
  color: var(--brand-cyan);
  position: absolute;
  left: 0;
  top: 0;
  font-size: 1.25rem;
}

.needs-list h4 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.needs-list p {
  font-size: 0.95rem;
  color: var(--brand-gray);
}

/* Chart Allocation */
.chart-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.chart-svg {
  width: 250px;
  height: 250px;
  transform: rotate(-90deg);
}

.chart-ring-bg {
  fill: none;
  stroke: var(--gray-light);
  stroke-width: 24;
}

.chart-ring-segment {
  fill: none;
  stroke-width: 24;
  stroke-linecap: round;
  transition: stroke-dasharray 1s ease-out;
}

.chart-ring-seg1 {
  stroke: var(--brand-blue-deep);
}
.chart-ring-seg2 {
  stroke: var(--brand-blue);
}
.chart-ring-seg3 {
  stroke: var(--brand-cyan);
}
.chart-ring-seg4 {
  stroke: var(--brand-mint);
}

.chart-legend {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 2rem;
  width: 100%;
}

.legend-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  text-align: left;
}

.legend-color {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 3px;
}

.color-seg1 {
  background-color: var(--brand-blue-deep);
}
.color-seg2 {
  background-color: var(--brand-blue);
}
.color-seg3 {
  background-color: var(--brand-cyan);
}
.color-seg4 {
  background-color: var(--brand-mint);
}

.legend-item h4 {
  font-size: 0.95rem;
  margin-bottom: 0.15rem;
  color: var(--brand-gray);
}

/* Timeline */
.timeline-title {
  margin-top: 5rem;
  margin-bottom: 3rem;
  text-align: center;
}

.timeline-flow {
  position: relative;
  max-width: 1000px;
  margin: 0 auto 5rem;
}

.timeline-flow::after {
  content: '';
  position: absolute;
  width: 4px;
  background-color: var(--brand-cream-dark);
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -2px;
}

.timeline-node {
  padding: 10px 40px;
  position: relative;
  background-color: inherit;
  width: 50%;
}

.timeline-node::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  right: -10px;
  background-color: var(--white);
  border: 4px solid var(--brand-blue);
  top: 15px;
  border-radius: 50%;
  z-index: 1;
}

.timeline-left {
  left: 0;
}

.timeline-right {
  left: 50%;
}

.timeline-right::after {
  left: -10px;
}

.timeline-content {
  padding: 2rem;
  background-color: var(--brand-cream);
  position: relative;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  border-top: 4px solid var(--brand-blue);
  transition: var(--transition-normal);
}

.timeline-content:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-top-color: var(--brand-mint);
}

.timeline-right .timeline-content {
  border-top-color: var(--brand-cyan);
}

.timeline-content h3 {
  font-size: 1.15rem;
  color: var(--brand-blue-deep);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.timeline-content h4 {
  font-size: 0.95rem;
  font-family: var(--font-body);
  font-weight: 600;
  margin-bottom: 1rem;
}

.timeline-content ul {
  list-style: none;
}

.timeline-content ul li {
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  position: relative;
  padding-left: 1.25rem;
}

.timeline-content ul li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--brand-blue);
  font-weight: bold;
}

/* KPIs grid */
.kpi-title {
  margin-bottom: 2rem;
  text-align: center;
}

.kpis-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.kpi-card {
  background: var(--brand-cream);
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border-bottom: 4px solid var(--brand-blue);
}

.kpi-number {
  font-family: var(--font-title);
  font-size: 2.5rem;
  font-weight: 800;
  background: var(--healing-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.5rem;
}

.kpi-card h4 {
  font-size: 1.05rem;
  color: var(--brand-blue-deep);
  margin-bottom: 0.5rem;
}

.kpi-card p {
  font-size: 0.85rem;
  color: var(--brand-gray);
  line-height: 1.45;
}

/* Board / Junta Section */
.board-section {
  background-color: var(--brand-cream);
}

.board-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 3rem;
}

.member-card {
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition-normal);
  text-align: center;
}

.member-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.member-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--brand-cream);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 2rem auto 1.5rem;
  font-family: var(--font-title);
  font-size: 2rem;
  font-weight: 700;
  color: var(--brand-blue-deep);
  border: 4px solid var(--brand-cyan);
}

.member-content {
  padding: 0 2rem 2rem;
}

.member-content h3 {
  font-size: 1.35rem;
  color: var(--brand-blue-deep);
  margin-bottom: 0.25rem;
}

.member-role {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--brand-cyan);
  margin-bottom: 1rem;
}

.member-bio {
  font-size: 0.9rem;
  color: var(--brand-gray);
}

/* Testimonios & Feedback Section */
.testimonials-section {
  background-color: var(--white);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 4rem;
}

.muro-title {
  margin-bottom: 2rem;
}

.muro-testimonios {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.testimonio-card {
  background: var(--brand-cream);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.testimonio-card::before {
  content: '“';
  font-family: Georgia, serif;
  font-size: 5rem;
  color: rgba(63, 184, 196, 0.2);
  position: absolute;
  top: -10px;
  left: 15px;
  line-height: 1;
}

.testimonio-text {
  font-size: 1rem;
  font-style: italic;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 2;
  color: var(--brand-gray);
}

.testimonio-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.testimonio-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--brand-blue-deep);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.95rem;
}

.testimonio-name {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--brand-blue-deep);
}

/* Form Styles */
.form-card {
  background: var(--brand-cream);
  padding: 2.5rem;
  border-radius: 12px;
  box-shadow: var(--shadow-md);
}

.form-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--brand-blue-deep);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
  color: var(--brand-blue-deep);
}

.form-control {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid var(--brand-cream-dark);
  border-radius: 8px;
  background-color: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--brand-gray);
  transition: var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--brand-cyan);
  box-shadow: 0 0 0 3px rgba(63, 184, 196, 0.15);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-top: 1rem;
}

.checkbox-group input {
  margin-top: 4px;
  flex-shrink: 0;
}

.checkbox-label {
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--brand-gray);
}

.checkbox-label a {
  text-decoration: underline;
}

/* Contact Info Section */
.contact-section {
  background-color: var(--brand-cream);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.contact-info h3 {
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
}

.contact-details {
  list-style: none;
  margin-bottom: 2rem;
}

.contact-details li {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
}

.contact-icon {
  font-size: 1.5rem;
  color: var(--brand-blue-deep);
  flex-shrink: 0;
}

.contact-policy {
  background: var(--white);
  padding: 1.5rem;
  border-radius: 8px;
  border-left: 4px solid var(--brand-blue-deep);
  font-size: 0.95rem;
}

.contact-socials {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.social-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-blue-deep);
  font-size: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}

.social-icon:hover {
  background: var(--healing-gradient);
  color: var(--white);
  transform: translateY(-2px);
}

/* Footer */
footer {
  background-color: var(--brand-gray);
  color: var(--white);
  padding: 4rem 0 2rem;
  font-family: var(--font-body);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 3rem;
}

.footer-brand .logo-text {
  color: var(--white);
}

.footer-brand .logo-text span {
  color: var(--brand-mint);
}

.footer-desc {
  font-size: 0.9rem;
  opacity: 0.8;
  margin-top: 1.5rem;
  max-width: 320px;
}

.footer-col h4 {
  color: var(--white);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: var(--brand-mint);
  padding-left: 5px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  opacity: 0.7;
}

.footer-legal-links {
  display: flex;
  gap: 1.5rem;
}

.footer-legal-links a {
  color: var(--white);
}

/* ==========================================================================
   SUBPAGES: TRANSPARENCIA, DONAR, SOLICITAR AYUDA
   ========================================================================== */
.subpage-hero {
  background: var(--healing-gradient);
  color: var(--white);
  padding: 5rem 0 3rem;
  text-align: center;
}

.subpage-hero h1 {
  font-size: 3rem;
  color: var(--white);
  margin-bottom: 1rem;
}

.subpage-hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
}

/* Transparency layout */
.transparency-intro {
  max-width: 800px;
  margin: 0 auto 3rem;
  text-align: center;
}

.docs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.doc-card {
  background: var(--white);
  border-radius: 12px;
  padding: 2.5rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  border-top: 4px solid var(--brand-blue-deep);
  transition: var(--transition-normal);
}

.doc-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.doc-icon {
  font-size: 3rem;
  color: var(--brand-blue-deep);
  margin-bottom: 1.5rem;
}

.doc-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.doc-card p {
  font-size: 0.9rem;
  color: var(--brand-gray);
  margin-bottom: 1.5rem;
}

/* Donate page */
.donate-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
}

.donate-options {
  background: var(--white);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
}

.frequency-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  background: var(--gray-light);
  padding: 0.35rem;
  border-radius: 30px;
  margin-bottom: 2rem;
}

.freq-btn {
  padding: 0.75rem;
  border-radius: 25px;
  border: none;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  background: none;
  color: var(--brand-gray);
  transition: var(--transition-fast);
}

.freq-btn.active {
  background: var(--white);
  color: var(--brand-blue-deep);
  box-shadow: var(--shadow-sm);
}

.amounts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.amount-btn {
  padding: 1rem;
  border-radius: 8px;
  border: 2px solid var(--gray-border);
  background: var(--white);
  font-family: var(--font-title);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--brand-blue-deep);
  cursor: pointer;
  transition: var(--transition-fast);
}

.amount-btn:hover,
.amount-btn.active {
  border-color: var(--brand-blue-deep);
  background-color: rgba(30, 108, 166, 0.05);
}

.custom-amount-input {
  position: relative;
  margin-bottom: 2.5rem;
}

.custom-amount-input span {
  position: absolute;
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--brand-blue-deep);
}

.custom-amount-input input {
  padding-left: 2.5rem;
  font-size: 1.25rem;
  font-weight: 700;
}

/* Encrypted Client Portal */
.portal-layout {
  max-width: 800px;
  margin: 0 auto;
}

.encryption-seal {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background-color: #e6f4ea;
  color: #137333;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

.encryption-seal i {
  font-size: 1.2rem;
}

/* ==========================================================================
   ADMIN PANEL: admin.html
   ========================================================================== */
.admin-login-wrapper {
  max-width: 420px;
  margin: 100px auto;
  background: var(--white);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  border-top: 5px solid var(--brand-blue-deep);
}

.admin-dashboard {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: calc(100vh - 95px);
}

.admin-sidebar {
  background-color: var(--brand-gray);
  color: var(--white);
  padding: 2rem 1rem;
}

.admin-sidebar h2 {
  color: var(--white);
  font-size: 1.25rem;
  margin-bottom: 2rem;
  padding-left: 1rem;
  border-left: 3px solid var(--brand-mint);
}

.admin-menu {
  list-style: none;
}

.admin-menu li {
  margin-bottom: 0.5rem;
}

.admin-menu button {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.75);
  padding: 0.75rem 1rem;
  font-family: var(--font-title);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 6px;
  transition: var(--transition-fast);
}

.admin-menu button.active,
.admin-menu button:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--brand-mint);
}

.admin-content-area {
  padding: 3rem;
  background-color: var(--white);
  overflow-y: auto;
}

.admin-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  border-bottom: 2px solid var(--gray-border);
  padding-bottom: 1.5rem;
}

.admin-section-panel {
  display: none;
}

.admin-section-panel.active {
  display: block;
}

/* Edit in live content tables */
.admin-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1.5rem;
}

.admin-table th,
.admin-table td {
  padding: 1rem;
  border: 1px solid var(--gray-border);
  text-align: left;
}

.admin-table th {
  background-color: var(--gray-light);
  font-family: var(--font-title);
  color: var(--brand-blue-deep);
}

.admin-input-textarea {
  width: 100%;
  min-height: 80px;
  padding: 0.5rem;
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  font-family: var(--font-body);
}

/* Request Viewer inside Admin */
.request-card-admin {
  background-color: var(--gray-light);
  border: 1px solid var(--gray-border);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.request-card-admin.encrypted {
  border-left: 4px solid var(--brand-blue-deep);
}

.request-card-admin.decrypted {
  border-left: 4px solid #137333;
  background-color: #f1f9f3;
}

.request-meta-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.request-badge {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-encrypted {
  background-color: #e2ecf5;
  color: var(--brand-blue-deep);
}
.badge-decrypted {
  background-color: #e6f4ea;
  color: #137333;
}

.decrypt-btn {
  background-color: var(--brand-blue-deep);
  color: var(--white);
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
}

.decrypt-btn:hover {
  background-color: var(--brand-blue);
}

.admin-alert-log {
  background-color: #fff4e5;
  border-left: 4px solid #ff9800;
  padding: 1rem;
  border-radius: 0 4px 4px 0;
  margin-top: 2rem;
  font-size: 0.85rem;
  color: #663c00;
}

/* Media queries consolidated and moved to the end of the stylesheet to preserve rule priority and spec order */

/* ==========================================================================
   PREMIUM FRONTEND VISUAL REVAMP (GLASSMORPHISM, INTERACTIVE DONUT & TIMELINE)
   ========================================================================== */

/* 1. Floating WhatsApp Button */
.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 30px;
  right: 30px;
  background-color: #25d366;
  color: #ffffff;
  border-radius: 50%;
  text-align: center;
  font-size: 30px;
  box-shadow:
    0 8px 25px rgba(37, 211, 102, 0.35),
    0 3px 6px rgba(0, 0, 0, 0.05);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.whatsapp-float:hover {
  transform: scale(1.1) rotate(8deg);
  background-color: #20ba5a;
  box-shadow:
    0 12px 30px rgba(37, 211, 102, 0.45),
    0 4px 10px rgba(0, 0, 0, 0.08);
  color: #ffffff;
}

/* 2. Interactive SVG Donut Chart Overrides */
.donut-wrapper {
  position: relative;
  width: 260px;
  height: 260px;
  margin: 0 auto;
}

.donut-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  pointer-events: none;
  z-index: 10;
  width: 140px;
  height: 140px;
  background-color: var(--white);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow:
    inset 0 2px 6px rgba(0, 0, 0, 0.05),
    var(--shadow-sm);
  border: 1px solid rgba(0, 0, 0, 0.02);
}

.donut-center-title {
  font-family: var(--font-title);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--brand-gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
  line-height: 1.2;
}

.donut-center-val {
  font-family: var(--font-title);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--brand-blue-deep);
  line-height: 1.1;
}

.chart-ring-segment {
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.05));
}

.chart-ring-segment:hover,
.chart-ring-segment.highlighted {
  stroke-width: 28px;
  filter: drop-shadow(0 4px 10px rgba(30, 108, 166, 0.25));
}

.chart-ring-segment.dimmed {
  opacity: 0.35;
}

/* Legend items interactive hover */
.legend-item {
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  border: 1px solid transparent;
  transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
  cursor: pointer;
}

.legend-item:hover,
.legend-item.active {
  background-color: var(--white);
  border-color: rgba(63, 184, 196, 0.3);
  box-shadow: var(--shadow-sm);
  transform: translateX(5px);
}

/* 3. Glassmorphism & Soft Shadow Cards Overrides */
.value-card,
.pillar-card,
.kpi-card,
.member-card,
.doc-card,
.testimonio-card,
.form-card,
.needs-card,
.philosophy-card-mv {
  background: var(--white) !important;
  border: 1px solid rgba(255, 255, 255, 0.8) !important;
  border-radius: 16px !important;
  box-shadow:
    0 10px 30px -10px rgba(30, 108, 166, 0.06),
    0 1px 3px rgba(0, 0, 0, 0.02) !important;
  transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
}

.value-card:hover,
.pillar-card:hover,
.kpi-card:hover,
.member-card:hover,
.doc-card:hover,
.testimonio-card:hover,
.needs-card:hover,
.philosophy-card-mv:hover {
  transform: translateY(-6px);
  box-shadow:
    0 20px 40px -15px rgba(30, 108, 166, 0.16),
    0 2px 8px rgba(0, 0, 0, 0.04) !important;
  border-color: rgba(63, 184, 196, 0.35) !important;
}

/* 4. Timeline Polish */
.timeline-flow::after {
  background: linear-gradient(
    to bottom,
    var(--brand-blue-deep) 0%,
    var(--brand-cyan) 50%,
    var(--brand-mint) 100%
  ) !important;
  width: 4px;
}

.timeline-content {
  border-top-width: 5px !important;
}

.timeline-node::after {
  border-width: 4px;
  width: 20px;
  height: 20px;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.timeline-node:hover::after {
  transform: scale(1.3);
  box-shadow: 0 0 12px rgba(30, 108, 166, 0.4);
  background-color: var(--brand-mint);
}

/* Bilingual i18n Utilities */
html[lang='es'] .lang-en {
  display: none !important;
}
html[lang='en'] .lang-es {
  display: none !important;
}

/* Volunteer Section */
.volunteer-section {
  background-color: var(--white);
}

.volunteer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
}

.volunteer-info h3 {
  margin-top: 2rem;
  margin-bottom: 1.5rem;
  color: var(--brand-blue-deep);
}

.volunteer-options {
  list-style: none;
  margin-top: 1.5rem;
}

.volunteer-options li {
  margin-bottom: 2rem;
}

.volunteer-options li strong {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.15rem;
  color: var(--brand-blue-deep);
  margin-bottom: 0.5rem;
}

.volunteer-options li strong i {
  color: var(--brand-cyan);
}

.volunteer-options li p {
  font-size: 0.95rem;
  color: var(--brand-gray);
  line-height: 1.6;
  padding-left: 1.85rem;
}

/* ==========================================================================
   HEADER ACTIONS & BUTTON STANDARDIZATION
   ========================================================================== */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Estandarizar botones de Idioma (ES/EN) y Get Help */
.lang-toggle,
.header-actions .btn-secondary {
  height: 40px !important;
  font-size: 0.8rem !important;
  padding: 0 1.25rem !important;
  border-radius: 50px !important;
  border: 2px solid var(--brand-blue-deep) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
  min-width: auto !important;
  white-space: nowrap !important;
  background-color: var(--white) !important;
  color: var(--brand-blue-deep) !important;
  transition: all 0.3s ease !important;
}

.lang-toggle:hover,
.header-actions .btn-secondary:hover {
  background-color: var(--brand-blue-deep) !important;
  color: var(--white) !important;
  transform: translateY(-2px) !important;
}

/* Botón de Donar más grande */
.header-actions .btn-primary {
  height: 44px !important;
  font-size: 0.85rem !important;
  padding: 0 1.6rem !important;
  border-radius: 50px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-sizing: border-box !important;
  white-space: nowrap !important;
  background: var(--healing-gradient) !important;
  color: var(--white) !important;
  transition: all 0.3s ease !important;
}

.header-actions .btn-primary:hover {
  transform: translateY(-2px) scale(1.02) !important;
}

/* ==========================================================================
   ADVANCED RESPONSIVE DESIGN POLISH (CONSOLIDATED BREAKPOINTS)
   ========================================================================== */
@media (max-width: 1280px) {
  .py-section {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }
  .mobile-menu-btn {
    display: block;
  }

  /* Force single-column layout for grids on tablet/mobile */
  .about-grid,
  .philosophy-grid,
  .plan-grid,
  .testimonials-grid,
  .contact-grid,
  .donate-layout,
  .volunteer-grid {
    grid-template-columns: 1fr !important;
    gap: 2.5rem;
  }

  .hero-section {
    min-height: auto;
    padding: 6rem 0;
  }
  .hero-title {
    font-size: 2.5rem;
  }
  .values-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .pillars-grid {
    grid-template-columns: 1fr;
  }
  .board-grid {
    grid-template-columns: 1fr 1fr;
  }
  .kpis-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .timeline-flow::after {
    left: 31px;
  }
  .timeline-node {
    width: 100%;
    padding-left: 70px;
    padding-right: 20px;
  }
  .timeline-node::after {
    left: 21px;
  }
  .timeline-right {
    left: 0%;
  }
  .timeline-right::after {
    left: 21px;
  }

  .docs-grid {
    grid-template-columns: 1fr;
  }
  .admin-dashboard {
    grid-template-columns: 1fr;
  }
  .admin-sidebar {
    padding: 1rem;
  }
  .admin-menu {
    display: flex;
    overflow-x: auto;
    gap: 0.5rem;
  }
  .admin-menu li {
    margin-bottom: 0;
  }
  .admin-menu button {
    white-space: nowrap;
  }
  .mobile-only {
    display: block !important;
  }

  /* Prevent hide of donate button, only hide secondary button */
  .nav-links,
  .header-actions .btn-secondary {
    display: none !important;
  }

  .header-actions .btn-primary {
    display: inline-flex !important;
  }

  /* Flex order to group actions on the right */
  .logo-container {
    order: 1;
  }

  .header-actions {
    order: 2;
    margin-left: auto;
  }

  nav {
    order: 3;
    margin-left: 0.5rem;
  }

  /* Navigation menu responsive setup */
  .nav-links {
    display: none !important;
    flex-direction: column;
    position: absolute;
    top: 95px;
    left: 0;
    right: 0;
    background-color: white;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    border-bottom: 1px solid var(--gray-border);
    z-index: 1000;
    gap: 1.5rem !important;
    text-align: center;
  }

  .nav-links.active {
    display: flex !important;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    width: 100%;
    padding: 0.75rem 0;
  }
}

@media (max-width: 768px) {
  .section-title {
    font-size: 1.85rem;
  }
  .values-grid {
    grid-template-columns: 1fr 1fr;
  }
  .board-grid {
    grid-template-columns: 1fr;
  }

  /* Justified text alignment for mobile/tablets to ensure beautiful layout and avoid river spacing */
  p,
  .about-text p,
  .pillar-content p,
  .value-card p,
  .member-bio,
  .testimonio-text,
  .contact-policy p,
  .transparency-intro p,
  .doc-card p,
  .legal-bullet-list li,
  .legal-callout p,
  .legal-callout-danger p,
  .volunteer-info p,
  .volunteer-options li p {
    text-align: justify !important;
  }

  .nav-wrapper {
    height: 75px !important;
  }

  .logo-img {
    height: 50px !important;
  }

  .logo-text {
    font-size: 1rem !important;
  }

  .logo-text span {
    display: none !important;
  }

  .nav-links {
    top: 75px !important;
  }
}

@media (max-width: 480px) {
  .values-grid,
  .kpis-grid {
    grid-template-columns: 1fr;
  }
  .hero-actions {
    flex-direction: column;
    gap: 0.75rem;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
  .amounts-grid {
    grid-template-columns: 1fr;
  }

  .logo-text {
    display: none !important;
  }

  .header-actions {
    gap: 0.4rem;
  }

  .lang-toggle {
    padding: 0 0.75rem !important;
    font-size: 0.75rem !important;
  }

  .header-actions .btn-primary {
    padding: 0 1rem !important;
    font-size: 0.8rem !important;
  }
}

/* ==========================================================================
   LEGAL PAGES STYLES (PRIVACIDAD & TERMINOS)
   ========================================================================== */
.legal-content-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--gray-border);
  border-radius: 16px;
  padding: 3rem;
  box-shadow: var(--shadow-md);
  margin-top: 2rem;
  text-align: left;
}
.legal-doc-section {
  margin-bottom: 3rem;
}
.legal-doc-section:last-child {
  margin-bottom: 0;
}
.legal-doc-title {
  color: var(--brand-blue-deep);
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--brand-cyan);
  padding-bottom: 0.5rem;
  text-transform: uppercase;
}
.legal-sub-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--brand-blue);
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}
.legal-text {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--brand-gray);
  margin-bottom: 1.25rem;
  text-align: justify;
  text-justify: inter-word;
}
.legal-bullet-list {
  margin-left: 1.5rem;
  margin-bottom: 1.25rem;
}
.legal-bullet-list li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
  text-align: justify;
  text-justify: inter-word;
}
.legal-meta {
  font-size: 0.85rem;
  opacity: 0.8;
  margin-bottom: 1rem;
  font-style: italic;
}
.legal-callout {
  background: rgba(30, 108, 166, 0.08);
  border-left: 4px solid var(--brand-blue-deep);
  padding: 1.25rem;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
}
.legal-callout p {
  text-align: justify;
  text-justify: inter-word;
}
.legal-callout-danger {
  background: rgba(211, 47, 47, 0.08);
  border-left: 4px solid #d32f2f;
  padding: 1.25rem;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
}
.legal-callout-danger p {
  text-align: justify;
  text-justify: inter-word;
}
@media (max-width: 768px) {
  .legal-content-card {
    padding: 2rem 1.5rem;
  }
  .legal-text,
  .legal-bullet-list li,
  .legal-callout p,
  .legal-callout-danger p {
    text-align: left !important;
  }
}

/* ==========================================================================
   CUSTOM DECRYPTION MODAL DIALOG
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  transition: opacity 0.3s ease;
}

.modal-card {
  background: var(--white);
  border-radius: 12px;
  width: 90%;
  max-width: 450px;
  box-shadow: var(--shadow-lg);
  border-top: 4px solid var(--brand-blue-deep);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalFadeIn 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--gray-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  margin: 0;
  font-size: 1.2rem;
  color: var(--brand-blue-deep);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.modal-close-icon {
  background: none;
  border: none;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--brand-gray);
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: var(--transition-fast);
}

.modal-close-icon:hover {
  color: red;
}

.modal-body {
  padding: 1.5rem;
}

.modal-body p {
  font-size: 0.9rem;
  color: var(--brand-gray);
  margin-bottom: 1.25rem;
  line-height: 1.45;
}

.modal-error {
  color: red;
  font-size: 0.8rem;
  margin-top: 0.5rem;
}

.modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--gray-border);
  background-color: var(--gray-light);
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

.modal-footer .btn {
  padding: 0.6rem 1.2rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

/* Custom Admin Logout Button styles to prevent selector clashes in headers */
.btn-admin-logout {
  background-color: var(--brand-gray) !important;
  color: var(--white) !important;
  border: 1px solid var(--gray-border) !important;
  padding: 0.5rem 1.2rem !important;
  border-radius: 4px !important;
  cursor: pointer !important;
  font-family: var(--font-title) !important;
  font-weight: 600 !important;
  transition: var(--transition-fast) !important;
}
.btn-admin-logout:hover {
  background-color: #d93025 !important;
  color: var(--white) !important;
}
