/*
Theme Name: Temisca Institucional
Author: Temisca
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Description: Portal institucional de Temisca con Biblioteca, agenda cívica, instituciones y publicaciones oficiales.
Version: 1.9.1
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: temisca
*/

:root {
  --temisca-navy: #10243A;
  --temisca-navy-deep: #0A1726;
  --temisca-gold: #CC8A00;
  --temisca-gold-light: #E3AC38;
  --temisca-ink: #1B2430;
  --temisca-muted: #657181;
  --temisca-line: #DCE2E9;
  --temisca-paper: #FFFFFF;
  --temisca-canvas: #F1F4F7;
  --temisca-content: 820px;
  --temisca-wide: 1160px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--temisca-canvas);
  color: var(--temisca-ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; }
a { color: var(--temisca-navy); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--temisca-gold); }
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible { outline: 3px solid var(--temisca-gold); outline-offset: 3px; }

.container { width: min(calc(100% - 48px), var(--temisca-wide)); margin-inline: auto; }
.content-narrow { width: min(calc(100% - 48px), var(--temisca-content)); margin-inline: auto; }

.skip-link {
  position: absolute; z-index: 1000; top: 12px; left: 12px; padding: 10px 14px;
  transform: translateY(-160%); background: var(--temisca-paper); color: var(--temisca-navy);
  border: 2px solid var(--temisca-gold);
}
.skip-link:focus { transform: translateY(0); }

/* Cabecera institucional */
.site-header {
  position: relative; z-index: 20; background: var(--temisca-paper);
  border-top: 4px solid var(--temisca-gold); border-bottom: 1px solid var(--temisca-line);
  box-shadow: 0 4px 18px rgba(10, 23, 38, .045);
}
.header-inner { min-height: 98px; display: flex; align-items: center; justify-content: space-between; gap: 30px; padding-block: 15px; }
.site-branding { display: flex; align-items: center; gap: 14px; min-width: 0; color: var(--temisca-ink); text-decoration: none; }
.site-branding:hover { color: var(--temisca-ink); }
.site-mark {
  display: grid; width: 52px; height: 52px; flex: 0 0 52px; place-items: center;
  border: 1px solid var(--temisca-gold); outline: 1px solid rgba(204, 138, 0, .28); outline-offset: 3px;
  background: var(--temisca-navy); color: var(--temisca-gold-light);
  font-family: Georgia, "Times New Roman", serif; font-size: 18px; font-weight: 700; letter-spacing: -.08em;
}
.custom-logo-link { display: inline-flex; align-items: center; }
.custom-logo { display: block; max-width: 170px; max-height: 64px; width: auto; }
.brand-copy { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.site-title { color: var(--temisca-navy-deep); font-family: Georgia, "Times New Roman", serif; font-size: clamp(18px, 2vw, 22px); font-weight: 700; letter-spacing: -.025em; line-height: 1.2; }
.site-tagline { margin-top: 6px; color: var(--temisca-muted); font-size: 10px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; }
.primary-navigation ul { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 32px); margin: 0; padding: 0; list-style: none; }
.primary-navigation a {
  position: relative; display: inline-block; padding: 10px 0; color: var(--temisca-navy);
  font-size: 14px; font-weight: 700; letter-spacing: .025em; text-decoration: none;
}
.primary-navigation a::after { position: absolute; right: 0; bottom: 3px; left: 0; height: 2px; background: var(--temisca-gold); content: ""; transform: scaleX(0); transform-origin: left; transition: transform 160ms ease; }
.primary-navigation a:hover::after,
.primary-navigation .current-menu-item > a::after,
.primary-navigation .current_page_item > a::after { transform: scaleX(1); }
.primary-navigation a:hover,
.primary-navigation .current-menu-item > a,
.primary-navigation .current_page_item > a { color: var(--temisca-navy-deep); }
.menu-toggle { display: none; border: 1px solid var(--temisca-line); background: var(--temisca-paper); color: var(--temisca-navy); padding: 8px 12px; font: inherit; font-size: 14px; cursor: pointer; }

/* Portada */
.home-hero,
.archive-hero,
.single-header,
.page-header {
  position: relative; isolation: isolate; overflow: hidden;
  background: linear-gradient(118deg, var(--temisca-navy-deep), var(--temisca-navy) 72%, #193653);
  color: var(--temisca-paper);
}
.home-hero { padding: clamp(76px, 9vw, 112px) 0 clamp(70px, 8vw, 98px); }
.home-hero::before,
.archive-hero::before,
.single-header::before,
.page-header::before {
  position: absolute; z-index: -1; top: 0; right: 0; width: min(45vw, 560px); height: 100%;
  background: linear-gradient(135deg, transparent 25%, rgba(255,255,255,.025) 70%, transparent),
              repeating-linear-gradient(90deg, transparent 0 39px, rgba(255,255,255,.018) 40px 41px);
  background-size: 14px 14px, auto, auto; content: ""; pointer-events: none;
}
.home-hero::after { position: absolute; top: 0; bottom: 0; left: max(24px, calc((100vw - var(--temisca-wide)) / 2)); width: 5px; background: var(--temisca-gold); content: ""; }
.hero-inner { position: relative; max-width: 950px; padding-left: clamp(24px, 5vw, 66px); }
.eyebrow { display: inline-block; margin: 0 0 18px; color: var(--temisca-gold-light); font-size: 11px; font-weight: 800; letter-spacing: .17em; text-transform: uppercase; }
.home-hero h1 { max-width: 850px; margin: 0; color: var(--temisca-paper); font-family: Georgia, "Times New Roman", serif; font-size: clamp(40px, 6vw, 68px); font-weight: 600; letter-spacing: -.045em; line-height: 1.06; }
.hero-description { max-width: 650px; margin: 22px 0 0; color: #E0E7EF; font-size: clamp(17px, 1.8vw, 19px); line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button-link {
  display: inline-flex; min-height: 46px; align-items: center; justify-content: center; padding: 10px 18px;
  border: 1px solid var(--temisca-gold); background: var(--temisca-gold); color: var(--temisca-navy-deep);
  font-size: 12px; font-weight: 800; letter-spacing: .045em; text-decoration: none; text-transform: uppercase;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease, transform 140ms ease;
}
.button-link:hover { transform: translateY(-2px); border-color: var(--temisca-gold-light); background: var(--temisca-gold-light); color: var(--temisca-navy-deep); }
.button-link-secondary,
.button-link-tertiary { border-color: rgba(255,255,255,.5); background: rgba(255,255,255,.035); color: var(--temisca-paper); }
.button-link-secondary:hover,
.button-link-tertiary:hover { border-color: var(--temisca-paper); background: var(--temisca-paper); color: var(--temisca-navy); }

/* Bloques de la portada */
.section-block { padding-block: clamp(48px, 6vw, 74px); background: var(--temisca-paper); }
.section-block-muted { background: #E9EEF3; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 25px; padding-bottom: 16px; border-bottom: 1px solid var(--temisca-line); }
.section-kicker { margin: 0 0 5px; color: var(--temisca-gold-dark, #A97000); font-size: 10px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.section-heading h2 { margin: 0; color: var(--temisca-navy-deep); font-family: Georgia, "Times New Roman", serif; font-size: clamp(27px, 3.2vw, 34px); font-weight: 600; letter-spacing: -.03em; line-height: 1.18; }
.text-link { color: var(--temisca-navy); font-size: 12px; font-weight: 800; letter-spacing: .035em; text-decoration: none; white-space: nowrap; text-transform: uppercase; }
.text-link::after { content: "  →"; color: var(--temisca-gold-dark, #A97000); }

/* Tarjetas editoriales */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.post-card {
  display: flex; min-width: 0; flex-direction: column; overflow: hidden; background: var(--temisca-paper);
  border: 1px solid #E0E5EA; box-shadow: 0 7px 22px rgba(10, 23, 38, .055);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}
.post-card:hover { transform: translateY(-4px); border-color: #CBD4DE; box-shadow: 0 14px 30px rgba(10, 23, 38, .11); }
.post-card-image { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--temisca-navy); }
.post-card-image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 240ms ease; }
.post-card:hover .post-card-image img { transform: scale(1.035); }
.post-card-placeholder {
  position: relative; display: grid; width: 100%; height: 100%; min-height: 155px; place-items: center;
  overflow: hidden; background: linear-gradient(135deg, #0A1726, #183653); color: var(--temisca-gold-light);
  font-family: Georgia, "Times New Roman", serif; font-size: 48px; font-weight: 600;
}
.post-card-placeholder::before { position: absolute; inset: 14px; border: 1px solid rgba(255,255,255,.10); content: ""; }
.post-card-placeholder::after { position: absolute; right: 0; bottom: 0; width: 42%; height: 4px; background: rgba(227,172,56,.65); content: ""; }
.post-card-placeholder-simbolo { font-size: 56px; }
.post-card-body { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 20px 21px 22px; }
.post-card-meta-line { display: flex; width: 100%; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 7px 12px; margin-bottom: 10px; }
.content-label { display: inline-flex; align-items: center; padding: 4px 8px; background: #F7EBD3; color: #765000; font-size: 10px; font-weight: 800; letter-spacing: .055em; line-height: 1.35; text-transform: uppercase; }
.content-label-on-dark { margin-bottom: 13px; border: 1px solid rgba(227,172,56,.5); background: rgba(204,138,0,.15); color: #F2C66E; }
.post-meta { margin: 0; color: var(--temisca-muted); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.post-card h3 { margin: 0; color: var(--temisca-navy-deep); font-family: Georgia, "Times New Roman", serif; font-size: 21px; font-weight: 600; line-height: 1.25; }
.post-card h3 a { color: inherit; text-decoration: none; }
.post-card h3 a:hover { color: var(--temisca-gold-dark, #A97000); }
.post-card-reference { margin: -2px 0 9px; color: var(--temisca-muted); font-size: 11px; line-height: 1.45; }
.post-card-reference strong { color: var(--temisca-navy); font-weight: 800; text-transform: uppercase; letter-spacing: .035em; }
.post-card-excerpt { margin: 11px 0 0; color: var(--temisca-muted); font-size: 14px; line-height: 1.6; }
.post-card-more { margin-top: auto; padding-top: 17px; color: var(--temisca-navy); font-size: 10px; font-weight: 800; letter-spacing: .065em; text-decoration: none; text-transform: uppercase; }
.post-card-more span { color: var(--temisca-gold-dark, #A97000); font-size: 15px; }

/* Archivos de noticias, legislación y símbolos */
.archive-main { min-height: 60vh; padding-bottom: 76px; }
.archive-hero { padding-block: clamp(48px, 6.5vw, 74px); }
.archive-hero::after,
.single-header::after,
.page-header::after { position: absolute; right: max(24px, calc((100vw - var(--temisca-wide)) / 2)); bottom: 0; width: 100px; height: 4px; background: var(--temisca-gold); content: ""; }
.archive-hero-inner { position: relative; }
.archive-hero .eyebrow { margin-bottom: 10px; }
.archive-hero h1,
.page-header h1 { margin: 0; color: var(--temisca-paper); font-family: Georgia, "Times New Roman", serif; font-size: clamp(36px, 5vw, 50px); font-weight: 600; letter-spacing: -.04em; line-height: 1.1; }
.archive-description { max-width: 720px; margin: 15px 0 0; color: #DCE5EE; font-size: 16px; line-height: 1.55; }
.archive-content { padding-top: 38px; }
.archive-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.archive-list-symbols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pagination,
.nav-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 34px; }
.page-numbers { display: inline-flex; min-width: 40px; min-height: 40px; align-items: center; justify-content: center; padding: 6px 11px; border: 1px solid #D4DCE4; background: var(--temisca-paper); color: var(--temisca-navy); font-size: 13px; text-decoration: none; }
.page-numbers.current,
.page-numbers:hover { border-color: var(--temisca-navy); background: var(--temisca-navy); color: var(--temisca-paper); }
.empty-state { position: relative; margin-block: 12px; padding: 44px 30px; border: 1px solid var(--temisca-line); border-top: 3px solid var(--temisca-gold); background: var(--temisca-paper); box-shadow: 0 8px 24px rgba(10,23,38,.05); text-align: center; }
.empty-state-mark { display: grid; width: 52px; height: 52px; place-items: center; margin: 0 auto 15px; border: 1px solid rgba(204,138,0,.65); background: var(--temisca-navy); color: var(--temisca-gold-light); font-family: Georgia, "Times New Roman", serif; font-size: 20px; }
.empty-state h1,
.empty-state h2 { margin: 0 0 8px; color: var(--temisca-navy); font-family: Georgia, "Times New Roman", serif; font-size: 27px; }
.empty-state p { margin: 0; color: var(--temisca-muted); font-size: 15px; }

/* Cabeceras de publicaciones y cuerpo editorial */
.single-main { padding-bottom: 64px; }
.single-header { padding-block: clamp(48px, 6.5vw, 76px) 45px; }
.single-header-inner { position: relative; }
.single-header .eyebrow { margin-bottom: 12px; }
.single-header h1 { max-width: 780px; margin: 0; color: var(--temisca-paper); font-family: Georgia, "Times New Roman", serif; font-size: clamp(34px, 4.7vw, 46px); font-weight: 600; letter-spacing: -.035em; line-height: 1.14; }
.single-header .entry-summary { max-width: 740px; margin: 18px 0 0; color: #DCE5EE; font-size: 17px; line-height: 1.55; }
.single-date { display: flex; align-items: center; gap: 9px; margin: 17px 0 0; color: #DCE5EE; font-size: 12px; font-weight: 700; letter-spacing: .035em; text-transform: uppercase; }
.date-symbol { color: var(--temisca-gold-light); font-size: 8px; }
.document-details { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.document-details span { display: inline-flex; flex-wrap: wrap; gap: 5px; padding: 7px 11px; border: 1px solid rgba(255,255,255,.2); background: rgba(255,255,255,.06); color: #E5EBF1; font-size: 11px; }
.document-details strong { color: var(--temisca-gold-light); font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.entry-featured-image { position: relative; z-index: 1; margin-top: 28px; }
.entry-featured-image img { display: block; width: 100%; max-height: 510px; object-fit: cover; border: 1px solid #DDE3E9; box-shadow: 0 12px 30px rgba(10,23,38,.1); }
.symbol-featured-image img { object-fit: contain; background: var(--temisca-paper); padding: 24px; }
.entry-panel { position: relative; margin-top: 30px; padding: 34px 42px 45px; border: 1px solid #E0E5EA; border-top: 4px solid var(--temisca-gold); background: var(--temisca-paper); box-shadow: 0 10px 32px rgba(10,23,38,.065); }
.entry-content { font-size: 18px; line-height: 1.72; overflow-wrap: break-word; }
.entry-content > * { max-width: 100%; }
.entry-content > * + * { margin-top: 1.05em; }
.entry-content p { margin-bottom: 1.05em; }
.entry-content h2,
.entry-content h3,
.entry-content h4 { color: var(--temisca-navy-deep); font-family: Georgia, "Times New Roman", serif; font-weight: 600; line-height: 1.25; }
.entry-content h2 { margin-top: 1.65em; font-size: 1.48em; }
.entry-content h3 { margin-top: 1.45em; font-size: 1.25em; }
.entry-content h4 { font-size: 1.08em; }
.entry-content blockquote { margin-inline: 0; padding: 9px 0 9px 22px; border-left: 4px solid var(--temisca-gold); color: var(--temisca-muted); background: linear-gradient(90deg, #F7F9FB, transparent); }
.entry-content table { width: 100%; border-collapse: collapse; font-size: .9em; }
.entry-content th,
.entry-content td { padding: 10px 12px; border: 1px solid var(--temisca-line); text-align: left; }
.entry-content th { background: #EDF1F5; color: var(--temisca-navy); }
.entry-content .wp-block-button__link,
.entry-content .wp-block-file__button { background: var(--temisca-navy); color: var(--temisca-paper); text-decoration: none; }
.entry-content .wp-block-separator { border: 0; border-top: 1px solid var(--temisca-line); }
.entry-content .alignwide { width: min(100% + 120px, calc(100vw - 48px)); max-width: none; margin-left: 50%; transform: translateX(-50%); }
.entry-content .alignfull { width: 100vw; max-width: 100vw; margin-left: 50%; transform: translateX(-50%); }

/* Páginas estáticas */
.page-header { padding-block: clamp(45px, 5.5vw, 65px); }
.page-header-inner { position: relative; }
.page-header .eyebrow { margin-bottom: 9px; }
.page-header h1 { font-size: clamp(34px, 4.6vw, 46px); }

/* Pie */
.site-footer { padding-block: 25px; border-top: 4px solid rgba(204,138,0,.75); background: var(--temisca-navy-deep); color: #DCE3EB; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; font-size: 12px; }
.footer-inner p { margin: 0; }
.site-footer a { color: #FFFFFF; }

/* Formularios de búsqueda y estados secundarios */
.search-form { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 20px; }
.search-form label { flex: 1 1 240px; }
.search-field { width: 100%; min-height: 42px; padding: 8px 11px; border: 1px solid var(--temisca-line); font: inherit; font-size: 14px; }
.search-submit { min-height: 42px; padding: 8px 16px; border: 1px solid var(--temisca-navy); background: var(--temisca-navy); color: white; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; }

@media (max-width: 900px) {
  .header-inner { min-height: 88px; gap: 16px; }
  .primary-navigation ul { gap: 15px; }
  .primary-navigation a { font-size: 13px; }
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .archive-list-symbols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .header-inner { flex-wrap: wrap; gap: 12px; }
  .menu-toggle { display: inline-flex; margin-left: auto; }
  .primary-navigation { display: none; width: 100%; padding-top: 9px; border-top: 1px solid var(--temisca-line); }
  .primary-navigation.is-open { display: block; }
  .primary-navigation ul { align-items: flex-start; flex-direction: column; gap: 0; }
  .primary-navigation a { width: 100%; padding: 10px 0; }
  .primary-navigation a::after { display: none; }
}

@media (max-width: 600px) {
  .container,
  .content-narrow { width: min(calc(100% - 36px), var(--temisca-wide)); }
  .site-mark { width: 44px; height: 44px; flex-basis: 44px; font-size: 16px; }
  .site-title { max-width: 230px; font-size: 16px; }
  .site-tagline { font-size: 9px; letter-spacing: .1em; }
  .home-hero { padding-block: 60px 62px; }
  .home-hero::after { left: 0; }
  .hero-inner { padding-left: 18px; }
  .home-hero h1 { font-size: clamp(34px, 9vw, 44px); }
  .hero-description { margin-top: 17px; font-size: 16px; }
  .hero-actions { align-items: stretch; flex-direction: column; gap: 9px; margin-top: 25px; }
  .button-link { width: 100%; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 10px; }
  .post-grid,
  .archive-list,
  .archive-list-symbols { grid-template-columns: 1fr; }
  .archive-hero { padding-block: 44px; }
  .archive-content { padding-top: 25px; }
  .archive-hero h1 { font-size: 36px; }
  .archive-description { font-size: 15px; }
  .single-header { padding-block: 44px 37px; }
  .single-header h1 { font-size: clamp(30px, 8vw, 38px); }
  .single-header .entry-summary { font-size: 16px; }
  .entry-featured-image { margin-top: 20px; }
  .entry-panel { margin-top: 20px; padding: 25px 22px 32px; }
  .entry-content { font-size: 17px; line-height: 1.68; }
  .entry-content h2 { font-size: 1.38em; }
  .entry-content .alignwide,
  .entry-content .alignfull { width: 100%; margin-left: 0; transform: none; }
  .document-details span { font-size: 10px; }
  .footer-inner { align-items: flex-start; flex-direction: column; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}


/* Acta Diurna: identidad editorial de la gaceta oficial */
.acta-masthead,
.acta-single-masthead {
  position: relative; isolation: isolate; overflow: hidden;
  color: #fff; text-align: center;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(204,138,0,.19), transparent 46%),
    linear-gradient(132deg, #081522 0%, #10243A 58%, #1B3855 100%);
  border-bottom: 5px solid var(--temisca-gold);
}
.acta-masthead::before,
.acta-single-masthead::before {
  position: absolute; z-index: -1; inset: 18px;
  border: 1px solid rgba(227,172,56,.28); content: "";
  pointer-events: none;
}
.acta-masthead-inner { padding-block: clamp(54px, 8vw, 88px) clamp(48px, 7vw, 76px); }
.acta-overline {
  margin: 0; color: #E8C77F; font-size: 11px; font-weight: 800;
  letter-spacing: .19em; text-transform: uppercase;
}
.acta-rule {
  display: flex; align-items: center; justify-content: center; gap: 16px;
  width: min(250px, 70%); margin: 24px auto 16px; color: var(--temisca-gold-light);
}
.acta-rule::before, .acta-rule::after {
  height: 1px; flex: 1; background: linear-gradient(90deg, transparent, var(--temisca-gold));
  content: "";
}
.acta-rule::after { transform: rotate(180deg); }
.acta-rule span { font-size: 17px; }
.acta-masthead h1,
.acta-single-masthead h1 {
  margin: 0; color: #fff; font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 7vw, 76px); font-weight: 700;
  letter-spacing: -.045em; line-height: 1.04;
}
.acta-subtitle {
  margin: 17px 0 0; color: #D7E0E9; font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(15px, 2vw, 19px); font-style: italic; letter-spacing: .035em;
}
.acta-imprint {
  display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  margin-top: 40px; padding-top: 15px; border-top: 1px solid rgba(255,255,255,.2);
  color: #D4DDE6; font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
}
.acta-content { padding-top: 48px; padding-bottom: 76px; }
.acta-section-heading { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; }
.acta-section-mark {
  display: grid; width: 48px; height: 48px; flex: 0 0 48px; place-items: center;
  border: 1px solid var(--temisca-gold); background: var(--temisca-navy);
  color: var(--temisca-gold-light); font-family: Georgia, serif; font-size: 22px;
}
.acta-section-heading h2 { margin: 0; color: var(--temisca-navy); font: 700 clamp(25px, 3vw, 32px)/1.15 Georgia, serif; }
.acta-section-heading .section-kicker { margin: 0 0 5px; }
.acta-grid .post-card { border-top: 3px solid var(--temisca-gold); }
.acta-grid .post-card-placeholder-acta { background: linear-gradient(145deg, #0A1726, #244361); color: #E3AC38; font: 700 64px Georgia, serif; }
.acta-empty {
  position: relative; overflow: hidden; padding: 48px 28px; text-align: center;
  border: 1px solid #D7DEE7; border-top: 3px solid var(--temisca-gold);
  background: linear-gradient(120deg, #fff, #F7F9FB);
  box-shadow: 0 14px 36px rgba(10,23,38,.06);
}
.acta-empty-symbol { display: block; color: rgba(204,138,0,.35); font: 700 64px/1 Georgia, serif; }
.acta-empty h2 { margin: 12px 0 8px; color: var(--temisca-navy); font: 700 27px Georgia, serif; }
.acta-empty p { max-width: 580px; margin: auto; color: var(--temisca-muted); }
.acta-single-masthead { padding-block: 54px 60px; }
.acta-single-inner { position: relative; }
.acta-edition-label { margin: 0 0 12px; color: #E8C77F; font: italic 18px Georgia, serif; }
.acta-single-masthead h1 { font-size: clamp(34px, 5vw, 54px); }
.acta-date { margin: 18px 0 0; color: #D7E0E9; font-size: 13px; letter-spacing: .08em; }
.acta-single-masthead .entry-summary { max-width: 650px; margin: 20px auto 0; color: #E4EAF0; }
.acta-featured { margin-top: 30px; }
.acta-article { margin-top: 30px; }
@media (max-width: 640px) {
  .acta-masthead::before, .acta-single-masthead::before { inset: 10px; }
  .acta-imprint { justify-content: center; margin-top: 27px; text-align: center; }
  .acta-single-masthead { padding-block: 44px; }
}


/* La Micronación: portal periodístico propio dentro del portal institucional de Temisca. */
.temisca-micronacion { --paper-blue: #00249C; --paper-blue-deep: #00165F; --paper-gold: #CC8A00; }
.paper-masthead { color: #fff; background: linear-gradient(135deg, #00165F 0%, #00249C 58%, #1744B5 100%); border-bottom: 6px solid var(--paper-gold); box-shadow: 0 12px 30px rgba(0,20,90,.16); }
.paper-masthead-inner { padding-top: 20px; }
.paper-topline { display:flex; justify-content:space-between; gap:16px; padding: 5px 0 14px; border-bottom:1px solid rgba(255,255,255,.25); color:#E2E9FF; font-size:10px; font-weight:800; letter-spacing:.13em; }
.paper-brand-rule { display:flex; align-items:center; justify-content:center; gap:16px; width:min(190px,60%); margin:22px auto 8px; color:#F2C45D; }
.paper-brand-rule:before,.paper-brand-rule:after { content:""; height:1px; flex:1; background:linear-gradient(90deg,transparent,#E7B84C); }
.paper-brand-rule:after { transform:rotate(180deg); }
.paper-brand-rule span { font-size:16px; }
.paper-kicker { margin:0; text-align:center; color:#F4D58C; font-size:11px; font-weight:800; letter-spacing:.2em; text-transform:uppercase; }
.paper-masthead h1,.paper-name-link { display:block; margin:4px 0 0; color:#fff; text-align:center; text-decoration:none; font:700 clamp(46px,8vw,88px)/1.02 Georgia,"Times New Roman",serif; letter-spacing:-.055em; text-shadow:0 3px 14px rgba(0,0,0,.18); }
.paper-deck { margin:12px 0 0; color:#E4EAFF; text-align:center; font:italic 16px Georgia,serif; }
.paper-nav { display:flex; justify-content:center; flex-wrap:wrap; gap:0; margin-top:28px; border-top:1px solid rgba(255,255,255,.2); }
.paper-nav a { padding:13px 17px 15px; color:#fff; text-decoration:none; font-size:12px; font-weight:800; letter-spacing:.04em; border-bottom:3px solid transparent; }
.paper-nav a:hover,.paper-nav a:focus { color:#FFE2A0; border-bottom-color:var(--paper-gold); }
.paper-content { padding-top:34px; padding-bottom:76px; }
.paper-datebar { display:flex; justify-content:space-between; gap:12px; padding:10px 0; margin-bottom:25px; border-top:1px solid #D5DCEB; border-bottom:3px double #AAB6D0; color:#52617E; font-size:10px; font-weight:800; letter-spacing:.12em; text-transform:uppercase; }
.paper-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:26px; }
.paper-lead { grid-column:1/-1; display:grid; grid-template-columns:1.15fr 1fr; overflow:hidden; background:#fff; border:1px solid #DCE2ED; box-shadow:0 12px 32px rgba(0,25,100,.07); }
.paper-lead-image,.paper-story-image { display:block; overflow:hidden; background:linear-gradient(135deg,#00165F,#1744B5); min-height:220px; }
.paper-lead-image img,.paper-story-image img { display:block; width:100%; height:100%; min-height:inherit; object-fit:cover; transition:transform .35s ease; }
.paper-lead-image:hover img,.paper-story-image:hover img { transform:scale(1.035); }
.paper-lead-image span,.paper-story-image span { display:grid; height:100%; min-height:inherit; place-items:center; color:#F2C45D; font:700 76px Georgia,serif; }
.paper-lead-copy { align-self:center; padding:clamp(24px,4vw,48px); }
.paper-category { margin:0 0 10px; color:#00249C; font-size:10px; font-weight:900; letter-spacing:.16em; text-transform:uppercase; }
.paper-lead h2 { margin:0; color:#111D3A; font:700 clamp(27px,3.8vw,42px)/1.12 Georgia,serif; letter-spacing:-.025em; }
.paper-lead h2 a,.paper-story h3 a { color:inherit; text-decoration:none; }
.paper-lead h2 a:hover,.paper-story h3 a:hover { color:#00249C; }
.paper-meta { margin:11px 0; color:#778198; font-size:11px; font-weight:700; letter-spacing:.04em; }
.paper-lead-copy>p:not(.paper-category):not(.paper-meta),.paper-story div>p:not(.paper-category):not(.paper-meta) { color:#46516A; font-size:15px; line-height:1.7; }
.paper-read { display:inline-flex; gap:12px; align-items:center; margin-top:8px; padding-bottom:4px; color:#00249C; border-bottom:2px solid #CC8A00; font-size:12px; font-weight:900; text-decoration:none; text-transform:uppercase; letter-spacing:.06em; }
.paper-story { display:grid; grid-template-columns:145px 1fr; gap:18px; padding:17px; background:#fff; border:1px solid #DCE2ED; box-shadow:0 7px 20px rgba(0,25,100,.045); }
.paper-story-image { min-height:140px; } .paper-story-image span { min-height:140px; font-size:38px; }
.paper-story h3 { margin:0; color:#111D3A; font:700 22px/1.2 Georgia,serif; }
.paper-empty { max-width:760px; margin:20px auto; padding:58px 30px; text-align:center; background:#fff; border:1px solid #DCE2ED; border-top:5px solid #CC8A00; box-shadow:0 16px 40px rgba(0,25,100,.08); }
.paper-empty>span { display:block; color:#00249C; font:700 66px Georgia,serif; }
.paper-empty h2 { margin:8px 0; color:#111D3A; font:700 30px Georgia,serif; } .paper-empty p:last-child { max-width:570px; margin:auto; color:#657181; }
.paper-single-masthead .paper-masthead-inner { padding-bottom:30px; } .paper-single-masthead .paper-name-link { font-size:clamp(38px,6vw,64px); }
.paper-article-wrap { padding-top:45px; padding-bottom:80px; } .paper-article { max-width:850px; margin:auto; padding:clamp(25px,5vw,58px); background:#fff; border:1px solid #DCE2ED; border-top:4px solid #CC8A00; box-shadow:0 14px 38px rgba(0,25,100,.07); }
.paper-article h1 { margin:0; color:#111D3A; font:700 clamp(34px,5vw,52px)/1.1 Georgia,serif; letter-spacing:-.035em; } .paper-standfirst { color:#4A5875; font:italic 21px/1.5 Georgia,serif; } .paper-article-image { margin:26px 0; } .paper-article-image img { width:100%; height:auto; } .paper-article .entry-content { font-size:18px; line-height:1.78; }
.paper-back { display:inline-block; margin-top:32px; color:#00249C; font-weight:800; text-decoration:none; border-bottom:2px solid #CC8A00; }
.temisca-micronacion .site-header { border-bottom-color:#00249C; }
@media(max-width:760px) { .paper-topline { flex-direction:column; align-items:center; text-align:center; font-size:9px; } .paper-grid { grid-template-columns:1fr; } .paper-lead { grid-template-columns:1fr; } .paper-lead-image { min-height:210px; } .paper-story { grid-template-columns:112px 1fr; gap:13px; padding:12px; } .paper-story-image { min-height:115px; } .paper-story-image span { min-height:115px; } .paper-story h3 { font-size:19px; } .paper-datebar { flex-direction:column; text-align:center; } .paper-nav a { padding:11px 10px; font-size:11px; } }


/* Refuerzo del efecto "portal dentro del portal" para La Micronación. */
.temisca-micronacion { background: #EEF1F7; }
.temisca-micronacion .site-header { background: #fff; border-bottom: 3px solid #00249C; }
.temisca-micronacion .site-title { color: #00165F; }
.temisca-micronacion .site-tagline { color: #53617D; }
.temisca-micronacion .primary-navigation a { color: #00165F; }
.temisca-micronacion .primary-navigation a:hover,
.temisca-micronacion .primary-navigation a:focus { color: #00249C; }
.temisca-micronacion .site-footer { border-top: 4px solid #CC8A00; }


/* Imágenes ausentes: composiciones gráficas editoriales, no huecos ni bloques planos. */
.temisca-no-image {
  --fallback-a: #0A1726;
  --fallback-b: #1B3B5B;
  --fallback-accent: #E3AC38;
  position: relative; display: flex; width: 100%; height: 100%; min-height: 100%;
  flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  overflow: hidden; isolation: isolate; padding: 24px;
  color: #fff; text-align: center;
  background:
    radial-gradient(ellipse at 50% 115%, rgba(227,172,56,.2), transparent 48%),
    linear-gradient(135deg, var(--fallback-a), var(--fallback-b));
}
.temisca-no-image::before,
.temisca-no-image::after { position:absolute; z-index:-1; content:""; pointer-events:none; }
.temisca-no-image::before {
  inset: 24px auto 24px 50%; width: 1px; background: linear-gradient(transparent, rgba(255,255,255,.12), transparent);
}
.temisca-no-image::after {
  inset:12px; border:1px solid rgba(227,172,56,.34);
  background:repeating-linear-gradient(135deg,transparent 0 22px,rgba(255,255,255,.018) 23px 24px);
}
.temisca-no-image-frame { position:absolute; inset:19px; border:1px solid rgba(255,255,255,.09); pointer-events:none; }
.temisca-no-image-mark {
  display:grid; width:92px; height:92px; place-items:center; flex:0 0 auto;
  border:0; color:var(--fallback-accent); font:700 29px/1 Georgia,"Times New Roman",serif; letter-spacing:-.06em;
  text-shadow:0 3px 15px rgba(0,0,0,.2);
}
.temisca-no-image-mark img { display:block; width:100%; height:100%; object-fit:contain; opacity:.92; }
.temisca-no-image-caption { display:flex; flex-direction:column; gap:5px; max-width:90%; }
.temisca-no-image-caption strong { color:#fff; font:600 clamp(14px,1.8vw,19px)/1.2 Georgia,"Times New Roman",serif; letter-spacing:.015em; }
.temisca-no-image-caption small { color:rgba(238,243,248,.76); font-size:9px; font-weight:800; letter-spacing:.16em; text-transform:uppercase; }
.temisca-no-image-card { min-height:190px; aspect-ratio:16/9; }
.temisca-no-image-feature { min-height:260px; aspect-ratio:16/7; }
.temisca-no-image-noticia { --fallback-a:#0A1726; --fallback-b:#254461; }
.temisca-no-image-legislacion { --fallback-a:#101B2A; --fallback-b:#34465A; }
.temisca-no-image-simbolo { --fallback-a:#10243A; --fallback-b:#6C5426; --fallback-accent:#F0C86D; }
.temisca-no-image-acta { --fallback-a:#081522; --fallback-b:#1B3855; }
.temisca-no-image-micronacion { --fallback-a:#00165F; --fallback-b:#1744B5; --fallback-accent:#F2C45D; }
.post-card-image .temisca-no-image { transition:filter .25s ease, transform .25s ease; }
.post-card:hover .post-card-image .temisca-no-image { filter:brightness(1.12); transform:scale(1.025); }
.entry-featured-fallback { margin-top:28px; }
.entry-featured-fallback .temisca-no-image { min-height:260px; box-shadow:0 12px 30px rgba(10,23,38,.1); }
.paper-lead-image .temisca-no-image { min-height:100%; aspect-ratio:auto; }
.paper-story-image .temisca-no-image { min-height:140px; padding:12px; }
.paper-story-image .temisca-no-image-mark { width:52px; height:52px; font-size:20px; }
.paper-story-image .temisca-no-image-caption strong { font-size:13px; }
.paper-story-image .temisca-no-image-caption small { font-size:8px; }
.paper-article-no-image { margin:26px 0; }
.paper-article-no-image .temisca-no-image { min-height:250px; }
@media(max-width:760px) {
  .temisca-no-image-feature,.entry-featured-fallback .temisca-no-image { min-height:190px; aspect-ratio:16/9; }
  .paper-lead-image .temisca-no-image { min-height:210px; }
  .paper-story-image .temisca-no-image { min-height:115px; }
  .paper-article-no-image .temisca-no-image { min-height:190px; }
}


/* Escudo oficial y selector de apariencia */
.site-mark { overflow:hidden; padding:4px; background:#fff; border-color:var(--temisca-gold); }
.site-mark img { display:block; width:100%; height:100%; object-fit:contain; }
.theme-toggle {
  display:inline-flex; flex:0 0 auto; align-items:center; justify-content:center; gap:7px;
  min-height:38px; padding:7px 11px; border:1px solid var(--temisca-line); border-radius:2px;
  background:var(--temisca-paper); color:var(--temisca-navy); font-family:inherit; font-size:12px; font-weight:700; line-height:1.2; cursor:pointer;
}
.theme-toggle:hover { border-color:var(--temisca-gold); }
.theme-toggle-icon { font-size:17px; line-height:1; }
.acta-crest { display:block; width:104px; height:104px; object-fit:contain; margin:0 auto 22px; padding:0; background:transparent; filter:drop-shadow(0 3px 12px rgba(0,0,0,.22)); }
.acta-crest-small { width:76px; height:76px; margin-bottom:18px; }
.acta-rule { margin-top:12px; }



/* ==========================================================================
   TEMISCA 1.8.0 — sistema integral de apariencia y lenguaje visual
   ========================================================================== */
:root {
  --t-bg: #F1F4F7;
  --t-surface: #FFFFFF;
  --t-surface-alt: #E9EEF3;
  --t-text: #1B2430;
  --t-heading: #0A1726;
  --t-muted: #657181;
  --t-border: #DCE2E9;
  --t-link: #10243A;
  --t-gold: #CC8A00;
  --t-shadow: 0 8px 26px rgba(10,23,38,.06);
}
html[data-theme="dark"] {
  color-scheme: dark;
  --t-bg: #091421;
  --t-surface: #102033;
  --t-surface-alt: #14283D;
  --t-text: #E4EBF3;
  --t-heading: #F3F6FA;
  --t-muted: #B0BDCC;
  --t-border: #2A4056;
  --t-link: #E7BD68;
  --t-gold: #E3AC38;
}
body { background:var(--t-bg); color:var(--t-text); transition:background-color .22s ease,color .22s ease; }
a { color:var(--t-link); }
.site-header { background:var(--t-surface); border-color:var(--t-border); }
.site-title,.site-branding,.primary-navigation a { color:var(--t-heading); }
.site-tagline,.post-meta,.post-card-reference,.post-card-excerpt { color:var(--t-muted); }
.menu-toggle,.theme-toggle { background:var(--t-surface); color:var(--t-text); border-color:var(--t-border); }
.section-block { background:var(--t-surface); }
.section-block-muted { background:var(--t-surface-alt); }
.section-heading h2,.post-card h3,.post-card h3 a,.empty-state h1,.empty-state h2,
.acta-section-heading h2,.acta-empty h2,.entry-content h2,.entry-content h3,.entry-content h4 { color:var(--t-heading); }
.section-kicker { color:var(--t-gold); }
.section-heading,.post-card,.entry-panel,.empty-state,.page-numbers { border-color:var(--t-border); }
.post-card,.entry-panel,.empty-state,.acta-empty,.search-field { background:var(--t-surface); color:var(--t-text); box-shadow:var(--t-shadow); }
.post-card-body { color:var(--t-text); }
.content-label { background:rgba(204,138,0,.16); color:#805600; }
.site-footer { background:var(--t-surface); color:var(--t-muted); border-color:var(--t-border); }
.entry-content,.entry-content p,.entry-content li { color:var(--t-text); }
.entry-content blockquote { background:var(--t-surface-alt); border-left-color:var(--t-gold); color:var(--t-text); }
.entry-content th { background:var(--t-surface-alt); color:var(--t-heading); }
.entry-content td,.entry-content th { border-color:var(--t-border); }
input,select,textarea,.search-field { background:var(--t-surface); color:var(--t-text); border-color:var(--t-border); }
.page-numbers { background:var(--t-surface); color:var(--t-link); }
.page-numbers.current,.page-numbers:hover { background:var(--temisca-navy); color:#fff; }
html[data-theme="dark"] body { background:var(--t-bg); color:var(--t-text); }
html[data-theme="dark"] .site-header { background:#0C1B2A; border-bottom-color:var(--t-border); }
html[data-theme="dark"] .site-title,html[data-theme="dark"] .site-branding,
html[data-theme="dark"] .primary-navigation a { color:#F0F4F8; }
html[data-theme="dark"] .site-tagline { color:#AEBCCD; }
html[data-theme="dark"] .menu-toggle,html[data-theme="dark"] .theme-toggle { background:#14283D; color:#F0F4F8; border-color:#38516B; }
html[data-theme="dark"] .home-hero,html[data-theme="dark"] .archive-hero,
html[data-theme="dark"] .single-header,html[data-theme="dark"] .page-header {
  background:linear-gradient(112deg,#071321 0%,#10243A 64%,#17334E 100%);
}
html[data-theme="dark"] .home-hero::before,html[data-theme="dark"] .archive-hero::before,
html[data-theme="dark"] .single-header::before,html[data-theme="dark"] .page-header::before {
  background:linear-gradient(135deg,transparent 25%,rgba(255,255,255,.035) 70%,transparent),
  repeating-linear-gradient(90deg,transparent 0 39px,rgba(255,255,255,.025) 40px 41px);
}
html[data-theme="dark"] .section-block { background:#0D1C2B; }
html[data-theme="dark"] .section-block-muted { background:#112438; }
html[data-theme="dark"] .section-heading h2,html[data-theme="dark"] .post-card h3,
html[data-theme="dark"] .post-card h3 a,html[data-theme="dark"] .entry-content h2,
html[data-theme="dark"] .entry-content h3,html[data-theme="dark"] .entry-content h4,
html[data-theme="dark"] .acta-section-heading h2,html[data-theme="dark"] .empty-state h1,
html[data-theme="dark"] .empty-state h2,html[data-theme="dark"] .acta-empty h2 { color:#F0F4F8; }
html[data-theme="dark"] .post-card,html[data-theme="dark"] .entry-panel,
html[data-theme="dark"] .empty-state,html[data-theme="dark"] .acta-empty,
html[data-theme="dark"] .page-numbers,html[data-theme="dark"] .search-field {
  background:#102033; border-color:#2A4056; color:#E4EBF3;
}
html[data-theme="dark"] .post-card:hover { border-color:#49627B; }
html[data-theme="dark"] .content-label { background:#493819; color:#F4D38D; }
html[data-theme="dark"] .post-meta,html[data-theme="dark"] .post-card-reference,
html[data-theme="dark"] .post-card-excerpt,html[data-theme="dark"] .empty-state p { color:#B0BDCC; }
html[data-theme="dark"] .entry-content,html[data-theme="dark"] .entry-content p,
html[data-theme="dark"] .entry-content li { color:#E0E8F1; }
html[data-theme="dark"] .entry-content blockquote { background:#172D43; color:#D5DFEA; }
html[data-theme="dark"] .entry-content th { background:#1A3047; color:#F0F4F8; }
html[data-theme="dark"] .entry-content td,html[data-theme="dark"] .entry-content th { border-color:#40566C; }
html[data-theme="dark"] .page-numbers.current,html[data-theme="dark"] .page-numbers:hover,
html[data-theme="dark"] .search-submit { background:#D99A22; border-color:#D99A22; color:#091421; }
html[data-theme="dark"] .site-footer { background:#0C1B2A; border-top-color:#2A4056; color:#AEBCCD; }
html[data-theme="dark"] .site-footer a { color:#E7BD68; }
html[data-theme="dark"] .acta-empty { background:linear-gradient(120deg,#102033,#14283D); }
html[data-theme="dark"] .acta-section-mark { background:#14283D; }
html[data-theme="dark"] .acta-masthead,html[data-theme="dark"] .acta-single-masthead {
  background:linear-gradient(132deg,#071321 0%,#10243A 58%,#1B3855 100%);
}
html[data-theme="dark"] .temisca-micronacion { background:#091421; }
html[data-theme="dark"] .temisca-micronacion .site-header { background:#0B1B31; }
html[data-theme="dark"] .temisca-micronacion .site-title,
html[data-theme="dark"] .temisca-micronacion .primary-navigation a { color:#EAF0FF; }
html[data-theme="dark"] .temisca-micronacion .paper-lead,
html[data-theme="dark"] .temisca-micronacion .paper-story,
html[data-theme="dark"] .temisca-micronacion .paper-article,
html[data-theme="dark"] .temisca-micronacion .paper-empty {
  background:#122541; border-color:#30486B; color:#E7ECF7;
}
html[data-theme="dark"] .temisca-micronacion .paper-lead h2,
html[data-theme="dark"] .temisca-micronacion .paper-story h3,
html[data-theme="dark"] .temisca-micronacion .paper-article h1,
html[data-theme="dark"] .temisca-micronacion .paper-article h2,
html[data-theme="dark"] .temisca-micronacion .paper-article h3 { color:#F0F3FA; }
html[data-theme="dark"] .temisca-micronacion .paper-lead-copy>p:not(.paper-category):not(.paper-meta),
html[data-theme="dark"] .temisca-micronacion .paper-story div>p:not(.paper-category):not(.paper-meta),
html[data-theme="dark"] .temisca-micronacion .paper-article .entry-content,
html[data-theme="dark"] .temisca-micronacion .paper-standfirst { color:#D1DCEF; }
html[data-theme="dark"] .temisca-micronacion .paper-meta,
html[data-theme="dark"] .temisca-micronacion .paper-datebar { color:#B5C4DE; border-color:#40577B; }
html[data-theme="dark"] .temisca-micronacion .paper-category { color:#AFC5FF; }
html[data-theme="dark"] .temisca-micronacion .paper-read,
html[data-theme="dark"] .temisca-micronacion .paper-back { color:#E7BD68; }
html[data-theme="dark"] .temisca-no-image { filter:saturate(.88) brightness(.92); }
html[data-theme="dark"] .temisca-no-image::after { border-color:rgba(227,172,56,.38); }
html[data-theme="dark"] .theme-toggle { border-color:#52677D; }
.theme-toggle { transition:background-color .2s ease,border-color .2s ease,color .2s ease; }
.theme-toggle-icon { display:inline-grid; width:1.2em; place-items:center; }
@media (prefers-reduced-motion:reduce) { body,.theme-toggle { transition:none; } }

/* Escudo de portada: elemento decorativo absoluto, independiente del flujo del texto. */
.home-hero { background-color:#10243A; }
.home-hero-crest {
  position:absolute;
  z-index:0;
  top:50%;
  right:max(24px, calc((100vw - var(--temisca-wide)) / 2));
  display:block;
  width:min(30vw,360px);
  aspect-ratio:444 / 411;
  transform:translateY(-50%);
  background:url("assets/escudo-temisca-blanco.png") center / contain no-repeat;
  opacity:.16;
  pointer-events:none;
}
.hero-inner {
  z-index:1;
  max-width:min(68%,800px);
}
@media(max-width:900px) {
  .home-hero-crest { right:24px; width:min(28vw,250px); opacity:.12; }
  .hero-inner { max-width:68%; }
}
@media(max-width:760px) {
  .home-hero-crest { right:-55px; width:180px; opacity:.08; }
  .hero-inner { max-width:100%; }
}
@media(max-width:600px) {
  .home-hero-crest { display:none; }
}

/* Versión 1.9.0: navegación agrupada del portal. */
.primary-navigation { margin-left:auto; }
.primary-navigation > .menu { display:flex; align-items:center; gap:clamp(10px,1.35vw,20px); margin:0; padding:0; list-style:none; }
.primary-navigation .menu > .menu-item { position:relative; display:flex; align-items:center; gap:2px; }
.primary-navigation .menu > .menu-item > a { padding:12px 0; font-size:12px; letter-spacing:.015em; white-space:nowrap; }
.primary-navigation .submenu-toggle {
  display:inline-grid; width:24px; height:28px; place-items:center; padding:0; border:0;
  background:transparent; color:var(--temisca-navy); font-size:16px; line-height:1; cursor:pointer;
}
.primary-navigation .submenu-toggle span { display:block; transition:transform 150ms ease; }
.primary-navigation .menu-item.is-submenu-open > .submenu-toggle span { transform:rotate(180deg); }
.primary-navigation .sub-menu {
  position:absolute; z-index:40; top:100%; left:-14px; display:none; min-width:245px; flex-direction:column;
  align-items:stretch; gap:2px; margin:0; padding:9px; list-style:none; background:var(--temisca-paper);
  border:1px solid var(--temisca-line); border-top:3px solid var(--temisca-gold); box-shadow:0 16px 34px rgba(10,23,38,.14);
}
.primary-navigation .menu-item:hover > .sub-menu,
.primary-navigation .menu-item:focus-within > .sub-menu,
.primary-navigation .menu-item.is-submenu-open > .sub-menu { display:flex; }
.primary-navigation .sub-menu .menu-item { display:block; width:100%; }
.primary-navigation .sub-menu a { display:block; width:100%; padding:9px 11px; color:var(--temisca-navy); font-size:13px; font-weight:650; white-space:normal; }
.primary-navigation .sub-menu a::after { display:none; }
.primary-navigation .sub-menu a:hover { background:#F1F4F7; color:var(--temisca-navy-deep); }
.primary-navigation .menu-group-link::after { bottom:4px; }

/* Portada editorial: el menú ya es la navegación; la cabecera queda libre de botones repetidos. */
.home-hero { padding-block:clamp(76px,8.5vw,110px); }
.hero-inner { max-width:min(72%,820px); }
.home-hero h1 { max-width:790px; }
.hero-description { max-width:700px; }

/* Biblioteca de Temisca. */
.library-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:22px; }
.library-card { display:flex; min-width:0; flex-direction:column; overflow:hidden; background:var(--temisca-paper); border:1px solid #E0E5EA; box-shadow:0 7px 22px rgba(10,23,38,.055); transition:transform 160ms ease,box-shadow 160ms ease; }
.library-card:hover { transform:translateY(-3px); box-shadow:0 14px 30px rgba(10,23,38,.11); }
.library-card-cover { display:grid; aspect-ratio:4/3; overflow:hidden; background:#142A40; text-decoration:none; }
.library-card-cover img { display:block; width:100%; height:100%; object-fit:cover; }
.library-cover-placeholder { position:relative; display:flex; min-height:180px; flex-direction:column; align-items:center; justify-content:center; gap:12px; color:#E3AC38; background:linear-gradient(145deg,#0A1726,#193653); }
.library-cover-placeholder::before { position:absolute; inset:13px; border:1px solid rgba(227,172,56,.35); content:""; }
.library-cover-placeholder > span { font-family:Georgia,"Times New Roman",serif; font-size:50px; }
.library-cover-placeholder small { position:relative; color:#E0E7EF; font-size:10px; font-weight:800; letter-spacing:.14em; text-transform:uppercase; }
.library-card-body { display:flex; flex:1; flex-direction:column; align-items:flex-start; padding:19px 20px 21px; }
.library-card-meta { display:flex; width:100%; align-items:center; justify-content:space-between; gap:8px; margin-bottom:11px; }
.library-year { color:var(--temisca-muted); font-size:12px; font-weight:700; }
.library-card h3 { margin:0 0 6px; color:var(--temisca-navy-deep); font-family:Georgia,"Times New Roman",serif; font-size:23px; line-height:1.22; }
.library-card h3 a { color:inherit; text-decoration:none; }
.library-author { margin:0 0 9px; color:var(--temisca-muted); font-size:13px; font-weight:650; }
.library-excerpt { margin:0 0 13px; color:var(--temisca-muted); font-size:14px; }
.library-card .post-card-more { margin-top:auto; }
.collection-nav { display:flex; flex-wrap:wrap; gap:8px; margin:0 0 28px; }
.collection-chip { display:inline-flex; align-items:center; min-height:36px; padding:6px 12px; border:1px solid var(--temisca-line); border-radius:2px; background:var(--temisca-paper); color:var(--temisca-navy); font-size:12px; font-weight:750; text-decoration:none; }
.collection-chip:hover,.collection-chip.is-current { border-color:var(--temisca-gold); background:#F7EBD3; color:#765000; }
.library-single-author { margin:15px 0 0; color:#E0E7EF; font-size:18px; }
.library-single-details { margin:8px 0 0; color:#C8D4E1; font-size:13px; }
.library-single-image { margin:28px auto 0; }
.library-single-image img { display:block; max-height:430px; margin-inline:auto; object-fit:contain; }
.library-document-link { margin:0 0 24px !important; }
.library-back-link { margin-top:22px; margin-bottom:45px; }

/* Agenda de actividades cívicas. */
.activity-list { display:flex; flex-direction:column; border-top:1px solid var(--temisca-line); }
.activity-row { display:grid; grid-template-columns:76px minmax(0,1fr) 32px; align-items:center; gap:20px; padding:20px 0; border-bottom:1px solid var(--temisca-line); }
.activity-date { display:flex; width:66px; min-height:70px; flex-direction:column; align-items:center; justify-content:center; border:1px solid var(--temisca-line); background:var(--temisca-paper); color:var(--temisca-navy); }
.activity-date strong { font-family:Georgia,"Times New Roman",serif; font-size:27px; line-height:1.05; }
.activity-date span { margin-top:3px; color:var(--temisca-muted); font-size:11px; font-weight:800; text-transform:uppercase; }
.activity-meta { margin:0 0 4px; color:var(--temisca-muted); font-size:11px; font-weight:750; letter-spacing:.035em; }
.activity-copy h3 { margin:0; color:var(--temisca-navy-deep); font-family:Georgia,"Times New Roman",serif; font-size:22px; line-height:1.25; }
.activity-copy h3 a { color:inherit; text-decoration:none; }
.activity-copy > p:last-child { margin:5px 0 0; color:var(--temisca-muted); font-size:14px; }
.activity-arrow { display:grid; width:30px; height:30px; place-items:center; border:1px solid var(--temisca-line); border-radius:50%; color:var(--temisca-navy); font-size:18px; text-decoration:none; }
.activity-archive-section + .activity-archive-section { margin-top:58px; }
.activity-past { opacity:.83; }
.activity-facts { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin:0 0 24px; padding:18px; background:var(--temisca-canvas); border:1px solid var(--temisca-line); }
.activity-facts p { display:flex; flex-direction:column; gap:3px; margin:0; font-size:14px; }
.activity-facts strong { color:var(--temisca-muted); font-size:10px; letter-spacing:.08em; text-transform:uppercase; }
.activity-facts span { color:var(--temisca-ink); }

/* Bloque compacto de documentación oficial en portada. */
.official-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:22px; }
.official-panel { min-width:0; padding:24px; background:var(--temisca-paper); border:1px solid var(--temisca-line); }
.official-panel h3 { margin:0 0 15px; color:var(--temisca-navy-deep); font-family:Georgia,"Times New Roman",serif; font-size:23px; }
.official-list-item { display:flex; flex-direction:column; gap:3px; padding:11px 0; border-top:1px solid var(--temisca-line); }
.official-list-item a { color:var(--temisca-navy); font-weight:750; text-decoration:none; }
.official-list-item span,.official-date { margin:0; color:var(--temisca-muted); font-size:12px; }
.official-panel > .text-link { display:inline-block; margin-top:18px; }
.official-panel-acta { background:linear-gradient(135deg,#10243A,#183653); color:#E5ECF3; border-color:#183653; }
.official-panel-acta h3 { margin-bottom:4px; color:#fff; }
.official-panel-acta .official-date { color:#C8D4E1; }
.official-panel-acta > p:not(.section-kicker):not(.official-date) { color:#E0E7EF; }

/* Directorio institucional. */
.institution-placeholder { display:grid; width:100%; height:100%; min-height:155px; place-items:center; background:linear-gradient(135deg,#0A1726,#193653); color:#E3AC38; font:600 52px Georgia,"Times New Roman",serif; }

/* Modo oscuro para los nuevos componentes. */
html[data-theme="dark"] .primary-navigation .submenu-toggle { color:#F0F4F8; }
html[data-theme="dark"] .primary-navigation .sub-menu { background:#102033; border-color:#2A4056; border-top-color:#D99A22; box-shadow:0 16px 34px rgba(0,0,0,.32); }
html[data-theme="dark"] .primary-navigation .sub-menu a { color:#EAF0F8; }
html[data-theme="dark"] .primary-navigation .sub-menu a:hover { background:#1A3047; color:#fff; }
html[data-theme="dark"] .library-card,html[data-theme="dark"] .official-panel { background:#102033; border-color:#2A4056; color:#E0E8F1; }
html[data-theme="dark"] .library-card h3,html[data-theme="dark"] .activity-copy h3,html[data-theme="dark"] .official-panel h3 { color:#F0F4F8; }
html[data-theme="dark"] .library-author,html[data-theme="dark"] .library-excerpt,html[data-theme="dark"] .library-year,html[data-theme="dark"] .activity-meta,html[data-theme="dark"] .activity-copy > p:last-child,html[data-theme="dark"] .official-list-item span,html[data-theme="dark"] .official-date { color:#B0BDCC; }
html[data-theme="dark"] .collection-chip { background:#102033; border-color:#40566C; color:#EAF0F8; }
html[data-theme="dark"] .collection-chip:hover,html[data-theme="dark"] .collection-chip.is-current { background:#493819; border-color:#D99A22; color:#F4D38D; }
html[data-theme="dark"] .activity-date { background:#102033; border-color:#40566C; color:#F0F4F8; }
html[data-theme="dark"] .activity-date span { color:#B0BDCC; }
html[data-theme="dark"] .activity-arrow { border-color:#40566C; color:#EAF0F8; }
html[data-theme="dark"] .activity-facts { background:#14283D; border-color:#40566C; }
html[data-theme="dark"] .activity-facts strong { color:#B0BDCC; }
html[data-theme="dark"] .activity-facts span { color:#E0E8F1; }
html[data-theme="dark"] .official-list-item { border-color:#40566C; }
html[data-theme="dark"] .official-list-item a { color:#E7BD68; }
html[data-theme="dark"] .official-panel-acta { background:linear-gradient(135deg,#071321,#10243A); }

@media (max-width:1100px) {
  .header-inner { gap:16px; }
  .site-tagline { letter-spacing:.08em; }
  .primary-navigation .menu > .menu-item > a { font-size:11px; }
}
@media (max-width:900px) {
  .header-inner { flex-wrap:wrap; }
  .menu-toggle { display:inline-flex; margin-left:auto; }
  .theme-toggle { order:3; }
  .primary-navigation { display:none; order:4; width:100%; margin:0; padding:10px 0 0; border-top:1px solid var(--temisca-line); }
  .primary-navigation.is-open { display:block; }
  .primary-navigation > .menu { align-items:stretch; flex-direction:column; gap:0; }
  .primary-navigation .menu > .menu-item { display:flex; flex-wrap:wrap; justify-content:space-between; border-bottom:1px solid var(--temisca-line); }
  .primary-navigation .menu > .menu-item > a { flex:1; padding:11px 0; font-size:14px; }
  .primary-navigation .submenu-toggle { width:42px; height:42px; }
  .primary-navigation .sub-menu { position:static; display:none; width:100%; min-width:0; margin:0 0 10px; padding:5px 8px; border:0; border-left:2px solid var(--temisca-gold); box-shadow:none; background:var(--temisca-canvas); }
  .primary-navigation .menu-item.is-submenu-open > .sub-menu { display:flex; }
  .primary-navigation .sub-menu a { padding:9px 11px; }
  html[data-theme="dark"] .primary-navigation .sub-menu { background:#0D1C2B; }
  .library-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:760px) {
  .hero-inner { max-width:100%; }
}
@media (max-width:700px) {
  .official-grid { grid-template-columns:1fr; }
  .hero-inner { max-width:100%; }
  .activity-row { grid-template-columns:62px minmax(0,1fr) 28px; gap:12px; }
  .activity-date { width:58px; min-height:62px; }
  .activity-copy h3 { font-size:19px; }
  .activity-facts { grid-template-columns:1fr; }
}
@media (max-width:560px) {
  .library-grid { grid-template-columns:1fr; }
  .library-card-cover { aspect-ratio:16/9; }
  .activity-meta { font-size:10px; }
}

/* Ajustes de contraste y bordes para los nuevos bloques. */
.activity-list { border-color:var(--t-border); }
.activity-row { border-color:var(--t-border); }
.activity-date,.activity-arrow { border-color:var(--t-border); }
.activity-facts { border-color:var(--t-border); }
.activity-pagination { display:flex; justify-content:center; gap:7px; margin-top:26px; }
html[data-theme="dark"] .official-list-item { border-color:var(--t-border); }


/* Participación cívica: formulario de propuestas moderadas. */
.civic-submit-panel { margin:34px auto 0; padding:28px; max-width:820px; border:1px solid var(--t-border); border-radius:var(--t-radius,14px); background:var(--t-surface); }
.civic-submit-panel h2 { margin-top:0; }
.civic-proposal-form p { margin:0 0 18px; }
.civic-proposal-form label { display:block; margin-bottom:7px; }
.civic-proposal-form input[type="text"],.civic-proposal-form select,.civic-proposal-form textarea { width:100%; padding:12px 13px; border:1px solid var(--t-border); border-radius:7px; color:var(--t-text); background:var(--t-canvas); font:inherit; }
.civic-proposal-form textarea { resize:vertical; }
.civic-notice { padding:12px 15px; border-left:3px solid var(--temisca-gold); background:var(--t-surface-alt); }
.civic-notice-warning { border-left-color:#B45A38; }
.civic-honeypot { position:absolute!important; left:-10000px!important; width:1px!important; height:1px!important; overflow:hidden!important; }
html[data-theme="dark"] .civic-submit-panel { background:#102033; border-color:#40566C; }
