/* ===========================================================
   Conectar para Conservar — Modern bilingual site
   =========================================================== */

:root {
  --ocean-900: #0b2a3a;
  --ocean-800: #0e3a4f;
  --ocean-700: #115268;
  --ocean-600: #0e7490;
  --ocean-500: #1595b6;
  --teal-400: #2bb7c4;
  --green-700: #166534;
  --green-600: #1f8a4c;
  --sand-50: #f7f5ef;
  --sand-100: #efece1;
  --ink: #16232b;
  --ink-soft: #435560;
  --white: #ffffff;
  --line: #e3e0d6;
  --shadow-sm: 0 2px 10px rgba(11, 42, 58, .06);
  --shadow-md: 0 12px 30px rgba(11, 42, 58, .12);
  --shadow-lg: 0 24px 60px rgba(11, 42, 58, .18);
  --radius: 18px;
  --radius-sm: 12px;
  --maxw: 1180px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--sand-50);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.12; letter-spacing: -.01em; margin: 0; }

.section { padding: 96px 0; position: relative; }
.section--tint { background: var(--white); }
.section--dark { background: linear-gradient(160deg, var(--ocean-900), var(--ocean-700)); color: #eaf4f7; }

.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ocean-600);
  margin-bottom: 14px;
}
.section--dark .eyebrow { color: var(--teal-400); }

.section-title { font-size: clamp(1.9rem, 3.6vw, 2.9rem); margin-bottom: 18px; }
.section-lead { font-size: 1.08rem; color: var(--ink-soft); max-width: 760px; }
.section--dark .section-lead { color: #cfe4ea; }
.section-head { max-width: 820px; margin-bottom: 54px; }
.section-head--center { margin-left: auto; margin-right: auto; text-align: center; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  transition: background .3s ease, box-shadow .3s ease, padding .3s ease;
  padding: 16px 0;
}
.site-header.scrolled {
  background: rgba(247, 245, 239, .88);
  backdrop-filter: saturate(160%) blur(12px);
  box-shadow: var(--shadow-sm);
  padding: 10px 0;
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--serif); font-weight: 600; font-size: 1.05rem; color: var(--white); }
.brand img { height: 44px; width: auto; }
.scrolled .brand { color: var(--ocean-900); }
.brand-text { line-height: 1.05; }
.brand-text small { display: block; font-family: var(--font); font-weight: 500; font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }

.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav-links a { font-size: .92rem; font-weight: 500; color: rgba(255,255,255,.92); position: relative; padding: 4px 0; }
.scrolled .nav-links a { color: var(--ink); }
.nav-links a::after { content:""; position:absolute; left:0; bottom:-2px; height:2px; width:0; background: var(--teal-400); transition: width .25s ease; }
.nav-links a:hover::after { width: 100%; }

.nav-right { display: flex; align-items: center; gap: 14px; }

.lang-toggle { display: inline-flex; border: 1px solid rgba(255,255,255,.5); border-radius: 999px; overflow: hidden; }
.scrolled .lang-toggle { border-color: var(--line); }
.lang-toggle button {
  border: 0; background: transparent; cursor: pointer;
  font: inherit; font-size: .8rem; font-weight: 700; letter-spacing: .04em;
  color: rgba(255,255,255,.9); padding: 6px 12px; transition: background .2s, color .2s;
}
.scrolled .lang-toggle button { color: var(--ink-soft); }
.lang-toggle button.active { background: var(--teal-400); color: var(--ocean-900); }

.nav-toggle { display: none; background: transparent; border: 0; cursor: pointer; padding: 6px; }
.nav-toggle span { display:block; width: 24px; height: 2px; background: currentColor; margin: 5px 0; color: #fff; transition: .3s; }
.scrolled .nav-toggle span { background: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh; position: relative; display: flex; align-items: center;
  color: #fff; overflow: hidden;
  background: linear-gradient(180deg, rgba(11,42,58,.55), rgba(11,42,58,.78)),
              linear-gradient(140deg, #0e3a4f, #0e7490 60%, #1f8a4c);
}
.hero::after {
  content:""; position:absolute; inset:0;
  background: url("https://conectarparaconservar.org/CPC/assets/imgs/slider/header_penpot.png") center/cover no-repeat;
  opacity: .28; mix-blend-mode: screen;
}
.hero .container { position: relative; z-index: 2; }
.hero-inner { max-width: 780px; padding: 120px 0 90px; }
.hero-kicker { font-weight: 600; letter-spacing: .22em; text-transform: uppercase; font-size: .82rem; color: var(--teal-400); margin-bottom: 20px; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); line-height: 1.02; margin-bottom: 22px; }
.hero p { font-size: 1.2rem; max-width: 600px; color: #dceef2; margin-bottom: 34px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

.btn {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
  font-weight: 600; font-size: .98rem; padding: 14px 26px; border-radius: 999px;
  border: 1px solid transparent; transition: transform .18s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--teal-400); color: var(--ocean-900); box-shadow: var(--shadow-md); }
.btn-primary:hover { background: #46c6d2; }
.btn-ghost { background: rgba(255,255,255,.08); color: #fff; border-color: rgba(255,255,255,.5); }
.btn-ghost:hover { background: rgba(255,255,255,.16); }

.scroll-cue { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 2; color: rgba(255,255,255,.7); font-size: .74rem; letter-spacing: .2em; text-transform: uppercase; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.scroll-cue span { width: 1px; height: 42px; background: linear-gradient(rgba(255,255,255,.7), transparent); }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 60px; align-items: start; }
.about-copy p { color: var(--ink-soft); margin: 0 0 18px; }
.about-side { display: flex; flex-direction: column; gap: 20px; }
.mv-card { background: var(--sand-50); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow-sm); }
.mv-card h3 { font-size: 1.25rem; margin-bottom: 10px; color: var(--ocean-700); }
.mv-card p { margin: 0; color: var(--ink-soft); font-size: .98rem; }
.values-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.values-tags span { background: #e7f3f2; color: var(--green-700); border-radius: 999px; padding: 5px 12px; font-size: .78rem; font-weight: 600; }

/* ---------- Goals 2030 ---------- */
.goals-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 22px; }
.goal-card {
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.14);
  border-radius: var(--radius); padding: 30px 28px; position: relative; overflow: hidden;
  transition: transform .25s ease, background .25s ease, border-color .25s ease;
}
.goal-card:hover { transform: translateY(-4px); background: rgba(255,255,255,.09); border-color: var(--teal-400); }
.goal-num { font-family: var(--serif); font-size: 2.4rem; color: var(--teal-400); line-height: 1; margin-bottom: 14px; display: block; }
.goal-card h3 { font-size: 1.28rem; margin-bottom: 12px; color: #fff; }
.goal-card p { margin: 0; color: #cfe4ea; font-size: .96rem; }

/* ---------- Projects ---------- */
.projects { display: flex; flex-direction: column; gap: 70px; }
.project {
  display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center;
}
.project:nth-child(even) .project-media { order: 2; }
.project-body .project-tag { font-size: .76rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ocean-600); }
.project-body h3 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); margin: 12px 0 16px; }
.project-body p { color: var(--ink-soft); margin: 0 0 20px; }
.project-loc { display: inline-flex; align-items: center; gap: 8px; font-size: .85rem; font-weight: 600; color: var(--green-700); }
.project-media { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; gap: 12px; height: 380px; }
.project-media a { display: block; border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-sm); position: relative; }
.project-media a:first-child { grid-row: 1 / 3; }
.project-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.project-media a:hover img { transform: scale(1.06); }

/* ---------- Project read-more ---------- */
.project-more { max-height: 0; overflow: hidden; opacity: 0; transition: max-height .45s ease, opacity .35s ease; }
.project.expanded .project-more { max-height: 1400px; opacity: 1; margin-top: 4px; }
.project-more p { color: var(--ink-soft); margin: 0 0 16px; }
.readmore-btn {
  background: transparent; border: 0; cursor: pointer; font: inherit;
  color: var(--ocean-600); font-weight: 700; font-size: .9rem; padding: 2px 0; margin-bottom: 16px;
  display: inline-flex; align-items: center; gap: 6px;
}
.readmore-btn::after { content: "↓"; transition: transform .3s ease; }
.project.expanded .readmore-btn::after { transform: rotate(180deg); }
.readmore-btn:hover { text-decoration: underline; }

/* ---------- Team ---------- */
.team-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 26px; }
.team-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); transition: transform .22s ease, box-shadow .22s ease; }
.team-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.team-photo { aspect-ratio: 1/1; background: linear-gradient(160deg, #dcefee, #cfe4ea); overflow: hidden; }
.team-photo img { width: 100%; height: 100%; object-fit: cover; }
.team-info { padding: 20px 22px 24px; }
.team-info h3 { font-size: 1.15rem; margin-bottom: 4px; }
.team-role { font-size: .9rem; color: var(--ocean-600); font-weight: 600; }
.team-sub { font-size: .82rem; color: var(--ink-soft); margin-top: 2px; }
.subhead { font-family: var(--serif); font-size: 1.5rem; color: var(--ocean-800); margin: 64px 0 14px; text-align: center; }
.team-grid--council { max-width: 780px; margin: 0 auto; }

/* team actions: bio + linkedin */
.team-actions { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.bio-btn {
  background: var(--ocean-600); color: #fff; border: 0; cursor: pointer; font: inherit;
  font-size: .82rem; font-weight: 600; padding: 7px 14px; border-radius: 999px; transition: background .2s, transform .18s;
}
.bio-btn:hover { background: var(--ocean-700); transform: translateY(-1px); }
.li-link {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: #eaf3f5; transition: background .2s, transform .18s;
}
.li-link:hover { background: var(--teal-400); transform: translateY(-1px); }
.li-link svg { width: 16px; height: 16px; fill: var(--ocean-700); }
.li-link:hover svg { fill: #fff; }

/* allies strip */
.allies-strip {
  border: 1px dashed var(--line); border-radius: var(--radius); background: var(--sand-50);
  padding: 34px 24px; text-align: center; color: var(--ink-soft); font-size: .95rem;
}

/* ---------- Instagram ---------- */
.insta-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.insta-card { border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-sm); aspect-ratio: 1/1; }
.insta-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.insta-card:hover img { transform: scale(1.05); }

/* ---------- Gallery ---------- */
.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.gallery-item { display: block; border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-sm); aspect-ratio: 4/3; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.gallery-item:hover img { transform: scale(1.06); }

/* ---------- Bio modal ---------- */
.bio-modal { position: fixed; inset: 0; background: rgba(6,20,28,.9); display: none; align-items: center; justify-content: center; z-index: 2000; padding: 24px; }
.bio-modal.open { display: flex; }
.bio-dialog { background: #fff; border-radius: var(--radius); max-width: 620px; width: 100%; max-height: 86vh; overflow-y: auto; padding: 38px 36px; position: relative; box-shadow: var(--shadow-lg); }
.bio-close { position: absolute; top: 14px; right: 18px; background: transparent; border: 0; font-size: 2rem; line-height: 1; cursor: pointer; color: var(--ink-soft); }
.bio-header { display: flex; align-items: center; gap: 18px; margin-bottom: 20px; }
.bio-photo { width: 92px; height: 92px; border-radius: 50%; object-fit: cover; flex: 0 0 auto; background: linear-gradient(160deg, #dcefee, #cfe4ea); box-shadow: var(--shadow-sm); }
.bio-name { font-size: 1.5rem; color: var(--ocean-800); margin-bottom: 4px; }
.bio-role { color: var(--ocean-600); font-weight: 600; font-size: .95rem; }
.bio-text { color: var(--ink-soft); white-space: pre-line; line-height: 1.7; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-info h3 { font-size: 1.3rem; color: #fff; margin-bottom: 18px; }
.contact-item { margin-bottom: 20px; }
.contact-item .label { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--teal-400); font-weight: 700; }
.contact-item a, .contact-item p { color: #dbeef2; margin: 4px 0 0; }
.contact-item a:hover { color: #fff; text-decoration: underline; }
.contact-map { margin-top: 26px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); }
.contact-map iframe { width: 100%; height: 240px; border: 0; display: block; }

.form { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius); padding: 32px; }
.form label { display: block; font-size: .82rem; font-weight: 600; margin-bottom: 6px; color: #dbeef2; }
.form .field { margin-bottom: 18px; }
.form input, .form textarea {
  width: 100%; padding: 13px 15px; border-radius: var(--radius-sm);
  border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.06);
  color: #fff; font: inherit; font-size: .95rem;
}
.form input::placeholder, .form textarea::placeholder { color: rgba(219,238,242,.55); }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--teal-400); background: rgba(255,255,255,.1); }
.form textarea { resize: vertical; min-height: 120px; }
.form .btn { width: 100%; justify-content: center; }
.form-note { font-size: .82rem; color: #bcdbe2; margin-top: 12px; text-align: center; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ocean-900); color: #b9d3db; padding: 48px 0 30px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { height: 42px; }
.footer-brand strong { color: #fff; font-family: var(--serif); font-weight: 600; }
.footer-social { display: flex; gap: 14px; }
.footer-social a { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.08); transition: background .2s, transform .2s; }
.footer-social a:hover { background: var(--teal-400); transform: translateY(-2px); }
.footer-social svg { width: 18px; height: 18px; fill: #fff; }
.footer-bottom { margin-top: 30px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.1); font-size: .82rem; text-align: center; color: #7fa2ad; }

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; background: rgba(6,20,28,.92); display: none; align-items: center; justify-content: center; z-index: 2000; padding: 30px; }
.lightbox.open { display: flex; }
.lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 10px; box-shadow: var(--shadow-lg); }
.lightbox-close { position: absolute; top: 22px; right: 26px; background: transparent; border: 0; color: #fff; font-size: 2.2rem; cursor: pointer; line-height: 1; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid, .project, .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .project:nth-child(even) .project-media { order: 0; }
  .project-media { height: 300px; }
  .nav-links {
    position: fixed; inset: 0 0 0 auto; width: min(300px, 82vw);
    background: var(--ocean-900); flex-direction: column; align-items: flex-start;
    padding: 100px 32px; gap: 22px; transform: translateX(100%); transition: transform .3s ease;
    box-shadow: var(--shadow-lg);
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { color: #fff !important; font-size: 1.05rem; }
  .nav-toggle { display: block; z-index: 1100; }
  .site-header .nav-toggle span { background: #fff; }
  .scrolled .nav-toggle span { background: var(--ink); }
  .section { padding: 72px 0; }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 560px) {
  .hero-inner { padding: 130px 0 80px; }
  .brand-text { display: none; }
  .project-media { grid-template-columns: 1fr; grid-template-rows: none; height: auto; }
  .project-media a:first-child { grid-row: auto; }
  .project-media a { height: 200px; }
  .insta-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .bio-dialog { padding: 30px 22px; }
}
