/* ═══════════════════════════════════════════════════════════════════
   Fecormad — Tema «Pentagrama»
   Diseño editorial de alta gama · Negro, blanco, dorado
   Tipografía: DM Serif Display + DM Sans
   ═══════════════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

:root {
  --primary:        #0D0D0D;
  --primary-dark:   #000000;
  --primary-light:  #1A1A1A;

  --accent:         #C6A55A;
  --accent-light:   #DBBF7A;
  --accent-dim:     rgba(198,165,90,0.15);

  --bg:             #F9F8F6;
  --bg-warm:        #F2F0EC;
  --surface:        #FFFFFF;
  --surface-alt:    #FAFAF9;

  --text:           #111111;
  --text-secondary: #444444;
  --text-muted:     #888888;

  --border:         #E5E2DC;
  --border-light:   #EEEBE6;

  --shadow-sm:      0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:      0 4px 24px rgba(0,0,0,0.06);
  --shadow-lg:      0 12px 48px rgba(0,0,0,0.08);
  --shadow-hover:   0 16px 56px rgba(0,0,0,0.11);

  --radius:         6px;
  --radius-lg:      12px;
  --radius-xl:      20px;

  --font-serif:     'DM Serif Display', Georgia, 'Times New Roman', serif;
  --font-sans:      'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ─── Base ─────────────────────────────────────────────────────────── */

html, body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6,
.banner,
.titulo,
.noticia h1 {
  font-family: var(--font-serif);
}

/* ─── Scroll reveal animation ──────────────────────────────────────── */

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.22,1,0.36,1),
              transform 0.8s cubic-bezier(0.22,1,0.36,1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── Header — glassmorphism on scroll ─────────────────────────────── */

header {
  background: rgba(13,13,13,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  box-shadow: none;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}

header.scrolled {
  background: rgba(0,0,0,0.97);
  box-shadow: 0 4px 30px rgba(0,0,0,0.25);
}

.banner {
  color: #FFFFFF;
  letter-spacing: 2px;
  font-size: 1.5em;
}

.banner small {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 0.4em;
  color: var(--accent);
  letter-spacing: 4px;
  text-transform: uppercase;
  vertical-align: middle;
  margin-left: 10px;
  opacity: 0.9;
}

.menu-toggle {
  color: #FFFFFF;
}

.nav-list li a {
  color: rgba(255,255,255,0.75);
  font-family: var(--font-sans);
  letter-spacing: 0.5px;
  font-size: 0.85em;
  font-weight: 500;
  text-transform: uppercase;
  transition: color 0.3s ease;
}

.nav-list li a:hover {
  background-color: transparent;
  color: var(--accent);
}

.dropdown .submenu {
  background: rgba(13,13,13,0.96);
  backdrop-filter: blur(20px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.06);
}

.submenu li a {
  color: rgba(255,255,255,0.7);
  text-transform: none;
}

.submenu li a:hover {
  background-color: rgba(255,255,255,0.06);
  color: var(--accent);
}

/* ─── Sections ─────────────────────────────────────────────────────── */

section {
  background: var(--surface);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

/* ─── Hero / Carrusel ──────────────────────────────────────────────── */

.carrusel-container {
  border-radius: 0;
  overflow: hidden;
  min-height: 100vh;
  position: relative;
}

/* Crossfade carrusel */
.carrusel-imagenes {
  transition: none !important;
  transform: none !important;
}

.carrusel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
  min-width: 100%;
}

.carrusel-slide.active {
  opacity: 1;
}

.carrusel-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0,0,0,0.55) 0%,
    rgba(0,0,0,0.25) 40%,
    rgba(0,0,0,0.5) 100%
  );
  pointer-events: none;
}

.carrusel-contenido {
  position: relative;
  z-index: 2;
  max-width: 860px;
  padding: 80px 60px;
}

.texto-overlay {
  background: transparent;
  color: #FFF;
  padding: 0;
  border-radius: 0;
  font-size: 1.1em;
  line-height: 1.85;
  text-align: left;
  box-shadow: none;
  border: none;
  font-weight: 300;
  letter-spacing: 0.3px;
}

/* Hero elements */
.hero-pretitle {
  font-family: var(--font-sans);
  font-size: 0.8em;
  font-weight: 500;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-pretitle .note-icon {
  font-size: 1.6em;
  line-height: 1;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 4em;
  font-weight: 400;
  color: #FFFFFF;
  line-height: 1.1;
  margin-bottom: 28px;
}

.hero-title em {
  font-style: italic;
  color: var(--accent-light);
}

.hero-stats {
  display: flex;
  gap: 56px;
  margin-top: 48px;
  padding-top: 40px;
  border-top: 1px solid rgba(255,255,255,0.15);
}

.hero-stat {
  text-align: left;
}

.hero-stat-number {
  display: block;
  font-family: var(--font-serif);
  font-size: 3em;
  font-weight: 400;
  color: #FFFFFF;
  line-height: 1;
}

.hero-stat-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.78em;
  color: rgba(255,255,255,0.5);
  margin-top: 8px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* ─── Decorative staff lines (pentagrama) ──────────────────────────── */

.staff-divider {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 32px 0;
  max-width: 120px;
  margin: 0 auto;
  opacity: 0.2;
}

.staff-divider span {
  display: block;
  height: 1px;
  background: var(--text);
  width: 100%;
}

/* ─── Sección Misión (home) ────────────────────────────────────────── */

.home-mision {
  background: var(--surface);
  padding: 100px 80px;
  max-width: 900px;
  margin: 0 auto;
}

.home-mision-pretitle {
  font-family: var(--font-sans);
  font-size: 0.78em;
  font-weight: 600;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.home-mision-title {
  font-family: var(--font-serif);
  font-size: 2.6em;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 28px;
  line-height: 1.2;
}

.home-mision-divider {
  width: 48px;
  height: 1px;
  background: var(--accent);
  margin-bottom: 32px;
}

.home-mision-text {
  font-size: 1.05em;
  line-height: 1.9;
  color: var(--text-secondary);
  max-width: 640px;
}

.home-quote {
  margin-top: 56px;
  padding: 36px 44px;
  border-left: 2px solid var(--accent);
  background: transparent;
  border-radius: 0;
}

.home-quote p {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.25em;
  line-height: 1.65;
  color: var(--text);
  margin: 0;
}

.home-quote cite {
  display: block;
  margin-top: 16px;
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 0.82em;
  color: var(--text-muted);
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* ─── Principios (home) ────────────────────────────────────────────── */

.home-principios {
  background: var(--primary);
  padding: 100px 80px;
  text-align: center;
  color: #FFFFFF;
}

.home-principios-pretitle {
  font-family: var(--font-sans);
  font-size: 0.78em;
  font-weight: 600;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.home-principios-title {
  font-family: var(--font-serif);
  font-size: 2.2em;
  font-weight: 400;
  color: #FFFFFF;
  margin-bottom: 56px;
}

.principios-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto;
}

.principio-card {
  background: transparent;
  padding: 40px 28px;
  border-radius: 0;
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: none;
  text-align: left;
  transition: border-color 0.4s ease;
}

.principio-card:hover {
  border-color: var(--accent);
  box-shadow: none;
  transform: none;
}

.principio-numeral {
  font-family: var(--font-serif);
  font-size: 1.6em;
  font-weight: 400;
  color: var(--accent);
  margin-bottom: 20px;
}

.principio-card h4 {
  font-family: var(--font-serif);
  font-size: 1.25em;
  font-weight: 400;
  color: #FFFFFF;
  margin-bottom: 14px;
}

.principio-card p {
  font-size: 0.92em;
  line-height: 1.75;
  color: rgba(255,255,255,0.6);
}

/* ─── Noticias preview (home) ──────────────────────────────────────── */

.home-noticias {
  background: var(--surface);
  padding: 100px 80px;
  text-align: center;
}

.home-noticias-pretitle {
  font-family: var(--font-sans);
  font-size: 0.78em;
  font-weight: 600;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.home-noticias-title {
  font-family: var(--font-serif);
  font-size: 2.2em;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 16px;
}

.home-noticias-divider {
  width: 48px;
  height: 1px;
  background: var(--accent);
  margin: 0 auto 56px;
}

.noticias-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  max-width: 1000px;
  margin: 0 auto;
  text-align: left;
}

.noticia-preview {
  padding: 36px 0;
  border: none;
  border-top: 1px solid var(--border);
  border-radius: 0;
  transition: all 0.3s ease;
  background: transparent;
}

.noticia-preview:hover {
  box-shadow: none;
  border-color: var(--accent);
}

.noticia-preview-fecha {
  font-family: var(--font-sans);
  font-size: 0.75em;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.noticia-preview h4 {
  font-family: var(--font-serif);
  font-size: 1.2em;
  font-weight: 400;
  color: var(--text);
  margin-bottom: 12px;
  line-height: 1.4;
}

.noticia-preview p {
  font-size: 0.9em;
  line-height: 1.7;
  color: var(--text-muted);
}

/* ─── Tarjetas ─────────────────────────────────────────────────────── */

.tarjeta {
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  transition: all 0.4s cubic-bezier(0.22,1,0.36,1);
}

.tarjeta:hover {
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
  transform: translateY(-6px);
}

.tarjeta h3 { color: var(--text); }
.tarjeta p  { color: var(--text-secondary); }

.tarjeta-mini {
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
}

.tarjeta-mini:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}

.tarjeta-mini h3 { color: var(--text); }

/* ─── Noticia (detalle) ────────────────────────────────────────────── */

.noticia {
  background: var(--surface);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.noticia h1 { color: var(--text); }

.noticia-coro {
  color: var(--accent);
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 1.1em;
  margin-bottom: 16px;
}

.noticia h2 {
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-weight: 400;
}

.noticia .autor { color: var(--text-muted); }

.noticia .extracto {
  color: var(--text);
  background: var(--surface-alt);
  padding: 24px 28px;
  border-left: 2px solid var(--accent);
  border-radius: 0;
}

.noticia .contenido { color: var(--text-secondary); }

.noticia a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.noticia a:hover {
  border-bottom-color: var(--accent);
}

/* ─── Botones ──────────────────────────────────────────────────────── */

.btn-inicio {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: var(--primary);
  color: #FFF;
  text-decoration: none;
  border-radius: 0;
  font-weight: 500;
  font-size: 0.85em;
  font-family: var(--font-sans);
  letter-spacing: 1px;
  text-transform: uppercase;
  box-shadow: none;
  transition: all 0.3s ease;
  margin-bottom: 24px;
}

.btn-inicio:hover {
  background: var(--accent);
  color: var(--primary);
  box-shadow: none;
  transform: none;
}

.btn-pdf {
  background: var(--primary);
  border-radius: 0;
  font-family: var(--font-sans);
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 0.88em;
}

.btn-pdf:hover { background: var(--accent); color: var(--primary); }

.btn-login {
  background: var(--primary);
  border-radius: 0;
  font-family: var(--font-sans);
  letter-spacing: 1px;
  text-transform: uppercase;
}

.btn-login:hover { background: var(--accent); color: var(--primary); }

.btn-submit {
  margin-top: 24px;
  padding: 14px 32px;
  background: var(--primary);
  color: #FFF;
  border: none;
  border-radius: 0;
  font-weight: 600;
  font-size: 0.88em;
  font-family: var(--font-sans);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-submit:hover {
  background: var(--accent);
  color: var(--primary);
}

/* ─── Login box ────────────────────────────────────────────────────── */

.login-box {
  background: var(--surface);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-lg);
}

.login-box h2 { color: var(--text); }
.login-field label { color: var(--text-secondary); }

.login-field input {
  border-color: var(--border);
  background: var(--surface-alt);
  border-radius: var(--radius);
  transition: border-color 0.3s;
}

.login-field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

/* ─── Session nav items ─────────────────────────────────────────────── */

#nav-login a,
#nav-logout a { font-weight: 600; }

#nav-logout a {
  color: rgba(255,255,255,0.45);
  font-size: 0.85em;
}

#nav-username { color: var(--accent); }

/* ─── Footer ───────────────────────────────────────────────────────── */

footer {
  background: var(--primary);
  color: rgba(255,255,255,0.4);
  border-top: 1px solid rgba(255,255,255,0.06);
  box-shadow: none;
}

footer p { color: rgba(255,255,255,0.4); }

/* ─── Links generales ──────────────────────────────────────────────── */

a {
  color: var(--accent);
  transition: color 0.3s ease;
}

a:hover { color: var(--text); }

/* ─── About page ───────────────────────────────────────────────────── */

.about-container {
  max-width: 1000px;
  margin: 0 auto;
  text-align: center;
}

.about-container .titulo {
  color: var(--text);
  font-size: 2.4em;
  font-weight: 400;
  margin-bottom: 16px;
}

.about-container .subtitulo {
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 1.05em;
  font-weight: 400;
  margin-bottom: 48px;
  line-height: 1.75;
}

.directiva-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
}

.miembro {
  background: var(--surface-alt);
  padding: 32px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  flex: 0 0 200px;
  transition: all 0.3s ease;
}

.miembro:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.miembro.resaltado {
  flex: 1 1 100%;
  background: var(--primary);
  border: none;
  box-shadow: var(--shadow-lg);
  margin-bottom: 16px;
}

.miembro.resaltado .nombre { color: #FFF; }
.miembro.resaltado .cargo  { color: var(--accent); }

.miembro img {
  border-radius: 50%;
  margin-bottom: 14px;
  height: 80px;
  opacity: 0.85;
}

.miembro .nombre {
  color: var(--text);
  font-weight: 600;
  margin: 0 0 4px;
  font-size: 0.95em;
}

.miembro .cargo {
  color: var(--text-muted);
  font-weight: 400;
  margin: 0;
  font-size: 0.82em;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.seccion-info {
  margin-top: 48px;
  text-align: left;
}

.seccion-info h4 {
  color: var(--text);
  font-family: var(--font-serif);
  font-size: 1.3em;
  font-weight: 400;
  margin-bottom: 12px;
  margin-top: 32px;
}

.seccion-info h4:first-child { margin-top: 0; }

.seccion-info p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 8px;
}

.seccion-info ul {
  color: var(--text-secondary);
  padding-left: 24px;
  line-height: 1.9;
}


/* ─── Contacto ─────────────────────────────────────────────────────── */

.contacto-container {
  max-width: 1000px;
  margin: 0 auto;
}

.contacto-container .titulo {
  text-align: center;
  color: var(--text);
  font-size: 2.4em;
  font-weight: 400;
  margin-bottom: 12px;
}

.contacto-container .subtitulo {
  text-align: center;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 1.05em;
  margin-bottom: 48px;
}

.contacto-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
}

.contacto-form {
  flex: 1 1 400px;
  background: var(--surface-alt);
  padding: 36px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.contacto-form label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.88em;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.contacto-form input,
.contacto-form textarea,
.contacto-form select {
  width: 100%;
  padding: 12px 16px;
  margin-bottom: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 0.95em;
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.3s;
  box-sizing: border-box;
}

.contacto-form input:focus,
.contacto-form textarea:focus,
.contacto-form select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.contacto-info {
  flex: 1 1 400px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

.contacto-info h4 {
  color: var(--text);
  font-family: var(--font-serif);
  font-size: 1.1em;
  font-weight: 400;
  margin: 24px 0 6px;
}

.contacto-info h4:first-child { margin-top: 0; }

.contacto-info p {
  color: var(--text-secondary);
  line-height: 1.65;
  margin: 0;
}

/* ─── Tablas ───────────────────────────────────────────────────────── */

table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-sans);
  font-size: 0.95em;
}

table thead {
  background: var(--primary);
  color: #FFF;
}

table th {
  padding: 14px 18px;
  text-align: left;
  font-weight: 600;
  letter-spacing: 0.5px;
  font-size: 0.85em;
  text-transform: uppercase;
}

table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-secondary);
}

table tbody tr:hover { background: var(--surface-alt); }

/* ─── Placeholder pages ───────────────────────────────────────────── */

.page-placeholder {
  max-width: 1000px;
  margin: 0 auto;
  text-align: center;
  padding: 80px 20px;
  color: var(--text-muted);
  font-size: 1.1em;
}

/* ─── Buscador / Paginación ────────────────────────────────────────── */

.lp-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.lp-btn-pag:hover {
  background: var(--bg-warm);
  border-color: var(--primary);
  color: var(--primary);
}

.lp-btn-activo {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.lp-btn-activo:hover {
  background: var(--accent);
  color: var(--primary);
}

/* ─── Responsive ───────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .nav-list {
    background: rgba(0,0,0,0.97);
    backdrop-filter: blur(20px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
    border: none;
    border-radius: 0;
  }

  .dropdown .submenu {
    background: rgba(0,0,0,0.98);
    border: none;
    box-shadow: none;
  }

  .contacto-grid { gap: 24px; }
  .directiva-container { gap: 12px; }
  .miembro { flex: 0 0 calc(50% - 8px); }

  .hero-title { font-size: 2.6em; }

  .hero-stats {
    gap: 28px;
    flex-wrap: wrap;
  }

  .hero-stat-number { font-size: 2.2em; }

  .carrusel-contenido { padding: 40px 24px; }
  .carrusel-container { min-height: 90vh; }

  .home-mision,
  .home-principios,
  .home-noticias {
    padding: 60px 24px;
  }

  .principios-grid {
    grid-template-columns: 1fr;
  }

  .noticias-preview-grid {
    grid-template-columns: 1fr;
  }
}
