/* Aldea SOS Paraguay — community site (non-official)
   Minimal stylesheet. The official organization handles everything
   on aldeasinfantiles.org.py.
*/

:root {
  --c-primary: #0066B3;
  --c-primary-dark: #004C82;
  --c-primary-light: #4DB8FF;
  --c-accent: #F4A100;
  --c-accent-light: #FFD966;
  --c-accent-dark: #C57F00;
  --c-text: #1A1A1A;
  --c-text-muted: #595959;
  --c-border: #E0E0E0;
  --c-bg: #FFFFFF;
  --c-bg-alt: #F5F5F5;

  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06);

  --container: 1100px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --c-primary: #4DB8FF;
    --c-bg: #1A1F2E;
    --c-bg-alt: #252B3D;
    --c-text: #F5F5F5;
    --c-text-muted: #B0B0B0;
    --c-border: #3A4253;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.4);
  }
}

[data-theme="dark"] {
  --c-primary: #4DB8FF;
  --c-bg: #1A1F2E;
  --c-bg-alt: #252B3D;
  --c-text: #F5F5F5;
  --c-text-muted: #B0B0B0;
  --c-border: #3A4253;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.4);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--c-text);
  background: var(--c-bg);
}
img { max-width: 100%; height: auto; }
a { color: var(--c-primary); text-decoration: underline; text-underline-offset: 3px; transition: color 0.2s ease; }
a:hover { color: var(--c-primary-light); }
.nav-toggle, .primary-nav a, .brand, .hero-ctas a, .card-link, .btn, footer a { text-decoration: none; }
button, .btn { font: inherit; cursor: pointer; }

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

/* Skip link */
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus {
  left: 1rem; top: 1rem;
  background: var(--c-primary); color: white;
  padding: 0.75rem 1.25rem; border-radius: var(--radius-md); z-index: 1000;
}

/* HEADER */
.site-header { background: white; box-shadow: var(--shadow-sm); position: sticky; top: 0; z-index: 100; }
[data-theme="dark"] .site-header { background: var(--c-bg-alt); }
.header-grid { display: flex; align-items: center; justify-content: space-between; padding: 0.875rem 1.5rem; max-width: var(--container); margin: 0 auto; gap: 1rem; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 0.75rem; color: var(--c-text); font-weight: 700; text-decoration: none; }
.brand-mark { width: 44px; height: 44px; border-radius: var(--radius-md); background: var(--c-accent); color: #1A1A1A; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; font-weight: 800; flex-shrink: 0; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 1.0625rem; color: var(--c-text); }
.brand-text small { font-size: 0.75rem; color: var(--c-text-muted); font-weight: 500; }
.primary-nav { display: flex; gap: 1.5rem; align-items: center; flex-wrap: wrap; }
.primary-nav a { color: var(--c-text); padding: 0.5rem 0.75rem; border-radius: var(--radius-md); font-weight: 500; }
.primary-nav a:hover { background: var(--c-bg-alt); color: var(--c-primary); }
.nav-toggle { display: none; background: transparent; border: 1px solid var(--c-border); padding: 0.5rem 0.75rem; border-radius: var(--radius-md); color: var(--c-text); font-size: 1.25rem; }
@media (max-width: 768px) {
  .primary-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--c-bg); border-top: 1px solid var(--c-border); flex-direction: column; padding: 1rem; box-shadow: var(--shadow-md); }
  .primary-nav.open { display: flex; }
  .nav-toggle { display: block; }
}

/* Hero */
.hero { background: var(--c-primary); color: white; padding: 4rem 0 3rem; position: relative; overflow: hidden; }
[data-theme="dark"] .hero { background: #003C75; }
.hero::before {
  content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 60%;
  background: radial-gradient(circle at 70% 30%, rgba(244, 161, 0, 0.25) 0%, transparent 60%);
  pointer-events: none;
}
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 3rem; align-items: center; position: relative; z-index: 1; }
.hero-eyebrow { display: inline-block; background: rgba(255,255,255,0.18); color: white; padding: 0.5rem 1rem; border-radius: var(--radius-full); font-size: 0.875rem; font-weight: 600; margin-bottom: 1.25rem; backdrop-filter: blur(8px); }
.hero h1 { font-size: clamp(2rem, 5vw, 3.25rem); margin: 0 0 1rem; line-height: 1.1; font-weight: 800; letter-spacing: -0.02em; max-width: 16ch; }
.hero h1 .accent { color: var(--c-accent-light); font-weight: 800; }
.hero-lead { font-size: clamp(1rem, 2vw, 1.1875rem); opacity: 0.95; line-height: 1.6; margin: 0 0 1.5rem; }
.hero-ctas { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.hero-illustration svg { width: 100%; max-width: 360px; height: auto; }
@media (max-width: 968px) { .hero-grid { grid-template-columns: 1fr; gap: 2rem; } .hero-illustration { display: none; } }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.875rem 1.75rem; border-radius: var(--radius-md); font-weight: 600; border: 2px solid transparent; transition: all 0.2s ease; text-decoration: none; font-size: 1rem; line-height: 1.2; }
.btn-primary { background: var(--c-accent); color: #1A1A1A; border-color: var(--c-accent); }
.btn-primary:hover { background: #FFB724; border-color: #FFB724; transform: translateY(-2px); box-shadow: var(--shadow-md); color: #1A1A1A; }
.btn-outline { background: transparent; color: var(--c-primary); border-color: var(--c-primary); }
.btn-outline:hover { background: var(--c-primary); color: white; }
.btn-large { padding: 1.0625rem 2rem; font-size: 1.0625rem; }

/* Sections */
.section { padding: 4rem 0; }
.section-alt { background: var(--c-bg-alt); }
.section-eyebrow { display: inline-block; padding: 0.25rem 0.75rem; background: rgba(0,102,179,0.1); color: var(--c-primary); border-radius: var(--radius-full); font-size: 0.8125rem; font-weight: 600; margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 0.05em; }
.section h2 { font-size: clamp(1.75rem, 4vw, 2.25rem); margin: 0 0 1rem; color: var(--c-text); font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; }
.section-header { text-align: center; margin-bottom: 2.5rem; }

/* Cards */
.card { background: var(--c-bg); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 1.5rem; }
.card h3 { font-size: 1.0625rem; margin: 0 0 0.5rem; color: var(--c-text); font-weight: 700; }
.card p { color: var(--c-text-muted); font-size: 0.9375rem; margin: 0 0 1rem; line-height: 1.6; }
.card ul { margin: 0.5rem 0 1rem; padding-left: 1.25rem; color: var(--c-text-muted); font-size: 0.9375rem; line-height: 1.8; }
.card ul li { margin-bottom: 0.25rem; }
.card-highlight { border-left: 4px solid var(--c-accent); }
.card-link { display: inline-block; color: var(--c-primary); font-weight: 600; margin-top: 0.5rem; text-decoration: none; }
.card-link:hover { color: var(--c-primary-light); }

/* Grids */
.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 768px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

/* Stats */
.problem-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; margin: 2rem 0; }
.problem-stat { text-align: center; padding: 1.5rem; background: rgba(0,102,179,0.05); border-radius: var(--radius-lg); border: 1px solid rgba(0,102,179,0.1); }
.problem-stat-num { font-size: 2.25rem; font-weight: 800; color: var(--c-primary); line-height: 1; }
.problem-stat-label { font-size: 0.875rem; color: var(--c-text-muted); margin-top: 0.5rem; line-height: 1.4; }
@media (max-width: 768px) { .problem-stats { grid-template-columns: 1fr; } }

/* Steps */
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.step { text-align: center; }
.step-num { width: 56px; height: 56px; border-radius: 50%; background: var(--c-primary); color: white; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.5rem; margin: 0 auto 1rem; }
.step h3 { font-size: 1rem; margin: 0 0 0.5rem; font-weight: 700; }
.step p { font-size: 0.9375rem; color: var(--c-text-muted); }
@media (max-width: 968px) { .steps-grid { grid-template-columns: repeat(2, 1fr); } }

/* Page hero */
.page-hero { background: var(--c-primary); color: white; padding: 2.5rem 0; }
.page-hero h1 { margin: 0; font-size: clamp(1.75rem, 4vw, 2.5rem); color: white; }
.page-hero p { margin: 0.75rem 0 0; opacity: 0.95; max-width: 700px; }
.breadcrumb { display: flex; gap: 0.5rem; font-size: 0.875rem; margin-bottom: 1rem; flex-wrap: wrap; }
.breadcrumb a { color: rgba(255,255,255,0.85); text-decoration: none; }
.breadcrumb a:hover { color: white; text-decoration: underline; }
.breadcrumb span { color: rgba(255,255,255,0.55); }

/* Panel */
.panel { background: var(--c-bg); border: 1px solid var(--c-border); border-radius: var(--radius-lg); padding: 1.5rem; }
.panel h3 { font-size: 1.125rem; margin: 0 0 0.75rem; }

/* Footer */
.site-footer { background: #1A1F2E; color: #C0C5D0; padding: 3rem 0 1.5rem; margin-top: 4rem; }
[data-theme="dark"] .site-footer { background: #0F131F; }
.site-footer h4 { color: white; font-size: 0.875rem; margin: 0 0 1rem; text-transform: uppercase; letter-spacing: 0.05em; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; margin-bottom: 2rem; }
.footer-about p { font-size: 0.9375rem; line-height: 1.6; }
.footer-list { list-style: none; padding: 0; margin: 0; }
.footer-list li { margin-bottom: 0.5rem; }
.footer-list a { color: #C0C5D0; text-decoration: none; font-size: 0.9375rem; }
.footer-list a:hover { color: white; text-decoration: underline; }
.footer-bottom { padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,0.1); text-align: center; }
.footer-bottom p { margin: 0; font-size: 0.875rem; color: rgba(255,255,255,0.6); }
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr; } }

/* Theme toggle button */
.theme-toggle { background: var(--c-bg-alt); border: 1px solid var(--c-border); border-radius: var(--radius-full); width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; color: var(--c-text); font-size: 1rem; }

/* Accessibility */
:focus-visible { outline: 3px solid var(--c-primary); outline-offset: 3px; border-radius: 2px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* Mobile tap targets (WCAG AA) */
@media (max-width: 768px) {
  button, .btn, .primary-nav a, .footer-list a {
    min-height: 44px;
  }
  .btn { min-height: 44px; }
}

/* Utilities */
.text-center { text-align: center; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
