/* ============================================================
   TECA — Páginas internas: Servicios · Formación · Proyectos
   Se carga DESPUÉS de teca-brand-2026.css y reutiliza sus variables.
   ============================================================ */

/* ---------- Hero de página interna ---------- */
.page-hero { position: relative; min-height: 340px; overflow: hidden; color: #fff; background: var(--navy); display: flex; align-items: center; }
.page-hero-bg {
  position: absolute; inset: 0;
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='1000' height='420' viewBox='0 0 1000 420'><g fill='none' stroke='%2355c8f5' stroke-opacity='.28' stroke-width='2'><rect x='690' y='70' width='230' height='230' transform='rotate(45 805 185)'/><rect x='740' y='120' width='130' height='130' transform='rotate(45 805 185)'/></g><g fill='none' stroke='%2355c8f5' stroke-opacity='.22' stroke-width='1.2'><path d='M420 90 L560 150 L640 60 L760 130'/><path d='M560 150 L610 280 L740 300'/></g><g fill='%2355c8f5' fill-opacity='.55'><circle cx='420' cy='90' r='3.5'/><circle cx='560' cy='150' r='3.5'/><circle cx='640' cy='60' r='3.5'/><circle cx='760' cy='130' r='3.5'/><circle cx='610' cy='280' r='3.5'/><circle cx='740' cy='300' r='3.5'/></g></svg>") no-repeat right center / auto 100%,
    radial-gradient(circle at 80% 45%, rgba(21,159,227,.50), transparent 46%),
    linear-gradient(120deg, #041b31 0%, #0b3558 100%);
}
.page-hero-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(4,27,49,.85) 0%, rgba(5,38,67,.45) 55%, rgba(5,38,67,.05) 100%); }
.page-hero .container { position: relative; z-index: 2; padding: 62px 0; }
.page-hero h1 { font-size: clamp(2.1rem, 3.6vw, 3.25rem); line-height: 1.05; letter-spacing: -.045em; margin: 0 0 16px; max-width: 640px; }
.page-hero h1 span { color: var(--cyan); }
.page-hero p.lead { max-width: 560px; color: #dbe9f3; margin: 0 0 26px; font-size: 1.02rem; }

/* ---------- Imágenes de ejemplo (se reemplazan por fotos de casos reales) ---------- */
.ph { position: relative; overflow: hidden; background: linear-gradient(135deg, #0b3558 0%, #159fe3 150%); }
.ph::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 82% 18%, rgba(85,200,245,.38), transparent 55%); }
.ph > i { position: absolute; right: 18px; bottom: 8px; font-size: 3.6rem; color: rgba(255,255,255,.22); line-height: 1; }
.ph > small { position: absolute; left: 14px; bottom: 12px; font-size: .6rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.72); }
.ph-teal   { background: linear-gradient(135deg, #0b3558 0%, #11979c 150%); }
.ph-purple { background: linear-gradient(135deg, #0b3558 0%, #7655bd 150%); }
.ph-orange { background: linear-gradient(135deg, #0b3558 0%, #f29b27 170%); }
.ph-navy   { background: linear-gradient(135deg, #061f37 0%, #123e6d 130%); }
.sample::after {
  content: "EJEMPLO"; position: absolute; top: 10px; right: 10px; z-index: 3;
  padding: 3px 9px; border-radius: 20px; font-size: .58rem; font-weight: 800; letter-spacing: .12em;
  background: rgba(255,255,255,.92); color: #b3690a;
}

/* ---------- Piezas reutilizables ---------- */
.link-more { display: inline-flex; align-items: center; gap: 6px; color: #0788d2; font-size: .78rem; font-weight: 800; margin-top: auto; padding-top: 20px; }
.link-more:hover { color: var(--navy); }
.check-list { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.check-list li { position: relative; padding-left: 16px; font-size: .84rem; color: var(--muted); }
.check-list li::before { content: ""; position: absolute; left: 0; top: .55em; width: 5px; height: 5px; border-radius: 50%; background: var(--blue); }
.chip { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 20px; font-size: .66rem; font-weight: 700; background: #eaf3fb; color: #0b6aa8; }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.section-alt { background: var(--bg); }

/* ---------- SERVICIOS ---------- */
.svc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.svc-card {
  display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px 24px; min-height: 340px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.svc-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: #bfd3e3; }
.svc-card .service-icon { margin-bottom: 20px; }
.svc-card h3 { margin: 0 0 16px; font-size: 1.12rem; letter-spacing: -.02em; }
.also-strip {
  margin-top: 22px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 16px 22px; border: 1px dashed #bfd3e3; border-radius: var(--radius); background: #fff; font-size: .84rem; color: var(--muted);
}
.also-strip strong { color: var(--text); }
.also-strip a { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 30px; background: #eaf3fb; color: #0b6aa8; font-weight: 700; font-size: .78rem; }

.cta-band { position: relative; display: grid; grid-template-columns: 1fr 1.6fr; min-height: 210px; background: var(--navy); color: #fff; overflow: hidden; }
.cta-band-img { min-height: 210px; clip-path: polygon(0 0, 100% 0, 88% 100%, 0 100%); }
.cta-band-panel { display: flex; align-items: center; gap: 22px; padding: 34px 6% 34px 0; }
.cta-band-badge { width: 58px; height: 58px; min-width: 58px; border-radius: 50%; display: grid; place-items: center; font-size: 1.5rem; color: var(--cyan); border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.06); }
.cta-band-panel h2 { margin: 0 0 6px; font-size: 1.7rem; letter-spacing: -.03em; }
.cta-band-panel p { margin: 0 0 16px; color: #cfe0ec; font-size: .92rem; }

/* ---------- FORMACIÓN ---------- */
.block-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 28px; flex-wrap: wrap; }
.block-head-title { display: flex; align-items: center; gap: 16px; }
.block-head-title .service-icon { margin: 0; }
.block-head-title h2 { margin: 0 0 2px; font-size: 1.6rem; letter-spacing: -.03em; }
.block-head-title p { margin: 0; font-size: .86rem; color: var(--muted); }

.dip-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.dip-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s ease, box-shadow .25s ease; }
.dip-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.dip-card .ph { height: 170px; }
.dip-body { display: flex; flex-direction: column; flex: 1; padding: 22px 22px 20px; }
.dip-body h3 { margin: 0 0 14px; font-size: 1.08rem; line-height: 1.3; letter-spacing: -.015em; }
.meta-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.meta-list li { display: flex; align-items: center; gap: 9px; font-size: .8rem; color: var(--muted); }
.meta-list i { color: var(--blue); font-size: .95rem; }
.meta-list b { color: var(--text); font-weight: 700; }
.meta-list .tbc { font-style: italic; color: #93a3b4; }

.duo { display: grid; grid-template-columns: 1fr 1.25fr; gap: 20px; margin-top: 26px; }
.panel { position: relative; overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.panel h3 { margin: 0 0 8px; font-size: 1.15rem; letter-spacing: -.02em; }
.panel > p, .panel-copy > p { margin: 0 0 18px; color: var(--muted); font-size: .86rem; max-width: 380px; }
.panel-with-img { display: grid; grid-template-columns: 1.2fr 1fr; padding: 0; }
.panel-copy { padding: 28px; }
.panel-with-img .ph { min-height: 100%; clip-path: polygon(14% 0, 100% 0, 100% 100%, 0 100%); }
.chip-strip { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.chip-strip span { display: inline-flex; align-items: center; gap: 7px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: .74rem; font-weight: 700; color: var(--text); background: var(--bg); }
.chip-strip i { color: var(--blue); }

/* ---------- PROYECTOS ---------- */
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 30px; }
.filter-pill { border: 1px solid var(--line); background: #fff; color: var(--muted); padding: 9px 20px; border-radius: 30px; font: inherit; font-size: .8rem; font-weight: 700; cursor: pointer; transition: all .2s ease; }
.filter-pill:hover { border-color: var(--blue); color: var(--blue); }
.filter-pill.active, .filter-pill.active:hover { background: var(--blue); border-color: var(--blue); color: #fff; }

.proj-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.proj-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s ease, box-shadow .25s ease; }
.proj-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.proj-card .ph { height: 190px; }
.proj-body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 20px; }
.proj-body .chip-row { margin-bottom: 12px; }
.proj-body h3 { margin: 0 0 8px; font-size: 1.1rem; letter-spacing: -.02em; }
.proj-body p { margin: 0; font-size: .84rem; color: var(--muted); }
.proj-card.hide { display: none; }

/* Ficha de proyecto (ventana) */
.proj-modal { position: fixed; inset: 0; z-index: 300; display: none; align-items: center; justify-content: center; padding: 30px; background: rgba(4,20,36,.72); backdrop-filter: blur(3px); }
.proj-modal.open { display: flex; }
.proj-sheet { position: relative; width: min(920px, 100%); max-height: 100%; overflow: auto; background: #fff; border-radius: 16px; box-shadow: 0 30px 80px rgba(0,0,0,.4); }
.proj-sheet-head { position: relative; padding: 34px 40px 28px; color: #fff; background: linear-gradient(120deg, #041b31, #0b3558); overflow: hidden; }
.proj-sheet-head::after { content: ""; position: absolute; right: -40px; top: -40px; width: 240px; height: 240px; border: 2px solid rgba(85,200,245,.28); transform: rotate(45deg); }
.proj-sheet-head .chip { background: rgba(255,255,255,.14); color: #dff2fc; }
.proj-sheet-head h2 { margin: 14px 0 6px; font-size: 1.9rem; letter-spacing: -.035em; position: relative; z-index: 1; }
.proj-sheet-head p { margin: 0; color: #cfe0ec; position: relative; z-index: 1; max-width: 560px; }
.proj-close { position: absolute; right: 16px; top: 16px; z-index: 5; width: 36px; height: 36px; border-radius: 50%; border: 1px solid rgba(255,255,255,.35); background: rgba(255,255,255,.08); color: #fff; font-size: 1.1rem; cursor: pointer; }
.proj-close:hover { background: rgba(255,255,255,.2); }
.proj-sheet-body { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 40px; padding: 34px 40px 36px; }
.proj-sheet-body h4 { margin: 0 0 8px; display: flex; align-items: center; gap: 9px; font-size: .78rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #087dc0; }
.proj-sheet-body h4 i { font-size: 1rem; }
.proj-sheet-body p { margin: 0; font-size: .9rem; color: var(--muted); }
.proj-sheet-body .full { grid-column: 1 / -1; }
.proj-sheet-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 40px; border-top: 1px solid var(--line); background: var(--bg); font-size: .8rem; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 1050px) {
  .svc-grid { grid-template-columns: repeat(2, 1fr); }
  .dip-grid, .proj-grid { grid-template-columns: repeat(2, 1fr); }
  .duo { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  .cta-band { grid-template-columns: 1fr; }
  .cta-band-img { clip-path: none; min-height: 140px; }
  .cta-band-panel { padding: 28px 24px; flex-direction: column; align-items: flex-start; }
  .panel-with-img { grid-template-columns: 1fr; }
  .panel-with-img .ph { clip-path: none; min-height: 150px; }
  .proj-sheet-body { grid-template-columns: 1fr; padding: 26px 24px; }
  .proj-sheet-head, .proj-sheet-foot { padding-left: 24px; padding-right: 24px; }
}
@media (max-width: 600px) {
  .svc-grid, .dip-grid, .proj-grid { grid-template-columns: 1fr; }
}

/* ---------- Foto real dentro de una tarjeta (reemplaza el marcador de color) ---------- */
.ph > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; z-index: 1; }
.proj-card .ph { isolation: isolate; }
[hidden] { display: none !important; }
