/* ==========================================================================
   Fernando Rodríguez · Portal Privado de Recursos
   Hoja de estilos propia (complementa Bootstrap 5)
   ========================================================================== */

:root {
  /* Paleta neutra: blanco / gris / azul */
  --color-bg: #ffffff;
  --color-bg-subtle: #f5f7fa;
  --color-bg-muted: #eef1f5;
  --color-border: #e2e8f0;
  --color-border-strong: #cbd5e1;

  --color-text-primary: #101828;
  --color-text-secondary: #475467;
  --color-text-muted: #667085;

  --color-blue-50: #eff6ff;
  --color-blue-100: #dbeafe;
  --color-blue-600: #2563eb;
  --color-blue-700: #1d4ed8;
  --color-blue-900: #1e3a5f;

  --color-success: #16a34a;

  --font-display: "Manrope", "Segoe UI", sans-serif;
  --font-body: "Inter", "Segoe UI", sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow-md: 0 4px 16px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 12px 32px rgba(16, 24, 40, 0.10);
}

/* ---------- Base ---------- */
html {
  scroll-behavior: smooth;
}

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

h1, h2, h3, h4,
.font-display {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  color: var(--color-text-primary);
}

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

a {
  color: var(--color-blue-600);
}

/* Enlace de salto para accesibilidad por teclado */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-blue-600);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 2000;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus {
  left: 0;
}

:focus-visible {
  outline: 2px solid var(--color-blue-600);
  outline-offset: 2px;
}

/* ---------- Header / navegación ---------- */
.site-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--color-blue-600), var(--color-blue-900));
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.1;
  color: var(--color-text-primary);
}

.brand-tagline {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.nav-link-custom {
  color: var(--color-text-secondary);
  font-size: 0.925rem;
  font-weight: 500;
  padding: 0.5rem 0.9rem !important;
}
.nav-link-custom:hover,
.nav-link-custom:focus {
  color: var(--color-blue-700);
}

/* ---------- Botones ---------- */
.btn-primary-custom {
  background-color: var(--color-blue-600);
  border-color: var(--color-blue-600);
  color: #fff;
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary-custom:hover,
.btn-primary-custom:focus {
  background-color: var(--color-blue-700);
  border-color: var(--color-blue-700);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline-custom {
  border: 1px solid var(--color-border-strong);
  color: var(--color-text-primary);
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-sm);
  background: #fff;
}
.btn-outline-custom:hover,
.btn-outline-custom:focus {
  border-color: var(--color-blue-600);
  color: var(--color-blue-700);
  background: var(--color-blue-50);
}

/* ---------- Status badge ---------- */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  background: var(--color-bg-subtle);
  border: 1px solid var(--color-border);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
}
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-success);
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.15);
  flex-shrink: 0;
}

/* ---------- Hero ---------- */
.hero-section {
  background: linear-gradient(180deg, var(--color-bg-subtle) 0%, #ffffff 65%);
  padding-top: 4.5rem;
  padding-bottom: 4.5rem;
  overflow: hidden;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--color-blue-700);
}

.hero-title {
  font-size: clamp(2.1rem, 4vw, 3rem);
  font-weight: 800;
  margin-bottom: 0.35rem;
}

.hero-subtitle {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  margin-bottom: 1.25rem;
}

.hero-description {
  font-size: 1.02rem;
  max-width: 42rem;
}

/* Panel visual del hero: representa un panel de control genérico y privado,
   sin datos reales, para transmitir "herramienta de trabajo" de forma clara
   tanto a personas como a sistemas de análisis de contenido. */
.mockup-panel {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 1.1rem;
  position: relative;
}

.mockup-panel__topbar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.mockup-panel__dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-border-strong);
}

.mockup-panel__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
}

.mockup-panel__tile {
  background: var(--color-bg-subtle);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 1.1rem;
}

.mockup-panel__lockstrip {
  margin-top: 0.9rem;
  background: var(--color-blue-50);
  border: 1px dashed var(--color-blue-100);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-blue-700);
}

/* ---------- Secciones genéricas ---------- */
.section {
  padding: 4rem 0;
}

.section-subtle {
  background: var(--color-bg-subtle);
}

.section-heading {
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  font-weight: 800;
  margin-bottom: 0.75rem;
}

.section-lead {
  max-width: 42rem;
  margin-inline: auto;
}

/* ---------- Aviso de acceso restringido ---------- */
.restricted-banner {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  box-shadow: var(--shadow-sm);
}

.restricted-banner__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--color-blue-50);
  color: var(--color-blue-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

/* ---------- Tarjetas de recursos ---------- */
.resource-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 1.6rem;
  height: 100%;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.resource-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-border-strong);
}

.resource-card__icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-sm);
  background: var(--color-blue-50);
  color: var(--color-blue-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  margin-bottom: 1rem;
}

.resource-card__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 0.4rem;
}

.resource-card__desc {
  font-size: 0.9rem;
  color: var(--color-text-secondary);
  margin-bottom: 1rem;
}

.resource-card__tag {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

/* ---------- Seguridad ---------- */
.security-feature {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1.5rem;
}

.security-feature__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--color-bg-muted);
  color: var(--color-blue-700);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.security-feature h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.security-feature p {
  font-size: 0.9rem;
  margin-bottom: 0;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--color-border);
  padding: 2rem 0;
  background: var(--color-bg-subtle);
}

.site-footer p {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 0;
}

/* ---------- Utilidades de accesibilidad ---------- */
.visually-hidden-focusable:not(:focus):not(:focus-within) {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .resource-card,
  .btn-primary-custom {
    transition: none;
  }
}

@media (max-width: 767.98px) {
  .hero-section {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
    text-align: center;
  }
  .hero-description {
    margin-inline: auto;
  }
  .restricted-banner {
    flex-direction: column;
    text-align: left;
  }
}
