/* =========================================================
   AUI - Asociación de Usuarios de Internet
   Identidad visual web
   ========================================================= */

/* ---------------------------------------------------------
   1. VARIABLES CORPORATIVAS
   --------------------------------------------------------- */
:root {
  /* Rojo original del logotipo */
  --aui-logo-red: #cd2a00;

  /* Gama principal de interfaz: burdeos */
  --aui-red: #7a1f2b;
  --aui-red-dark: #5f1822;
  --aui-red-deep: #431119;

  /* Tonos suaves derivados */
  --aui-red-soft: #e8c7cc;
  --aui-red-pale: #f8f0f2;

  --aui-charcoal: #292321;
  --aui-dark: #332c29;

  --aui-gray-900: #3d3633;
  --aui-gray-700: #68615d;
  --aui-gray-500: #958d89;
  --aui-gray-300: #d7d1ce;
  --aui-gray-200: #e9e5e3;
  --aui-gray-100: #f8f6f5;

  --aui-white: #ffffff;

  --aui-font:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Arial,
    sans-serif;

  --aui-serif:
    Georgia,
    "Times New Roman",
    serif;

  --aui-radius: 0.55rem;
  --aui-radius-lg: 0.9rem;

  --aui-shadow:
    0 4px 20px rgba(56, 36, 29, 0.08);

  --aui-shadow-hover:
    0 12px 34px rgba(56, 36, 29, 0.14);

  --aui-section-padding: 5rem;
}

/* ---------------------------------------------------------
   CRITERIO CROMÁTICO
   --------------------------------------------------------- */
/*
   --aui-logo-red se reserva para el logotipo/símbolo original.
   --aui-red y derivados se utilizan para interfaz, textos,
   enlaces, botones y elementos destacados.
*/

/* ---------------------------------------------------------
   2. BASE
   --------------------------------------------------------- */
html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--aui-font);
  color: var(--aui-dark);
  background: var(--aui-white);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--aui-red);
  text-decoration: none;
  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    opacity 0.2s ease;
}

a:hover {
  color: var(--aui-red-dark);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin-top: 0;
  color: var(--aui-charcoal);
  font-weight: 700;
  line-height: 1.18;
}

h1 {
  font-size: clamp(2.35rem, 5vw, 4.35rem);
  letter-spacing: -0.035em;
}

h2 {
  font-size: clamp(1.85rem, 3vw, 2.65rem);
  letter-spacing: -0.02em;
}

h3 {
  font-size: 1.25rem;
}

p:last-child {
  margin-bottom: 0;
}

/* ---------------------------------------------------------
   3. TOPBAR
   --------------------------------------------------------- */
.aui-topbar {
  color: rgba(255, 255, 255, 0.88);
  background: var(--aui-charcoal);
  font-size: 0.84rem;
}

.aui-topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 36px;
}

.aui-topbar-name {
  font-weight: 600;
}

.aui-topbar-links {
  display: flex;
  gap: 1.35rem;
}

.aui-topbar a {
  color: rgba(255, 255, 255, 0.78);
}

.aui-topbar a:hover {
  color: var(--aui-white);
}

/* ---------------------------------------------------------
   4. CABECERA
   --------------------------------------------------------- */
.aui-header {
  z-index: 1020;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--aui-gray-200);
  box-shadow: 0 2px 14px rgba(60, 40, 30, 0.035);
}

.aui-header .navbar {
  padding: 0;
}

.aui-symbol-link {
  display: flex;
  align-items: center;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.aui-header-symbol {
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.aui-header .nav-link {
  position: relative;
  padding: 1.55rem 0.72rem !important;
  color: var(--aui-gray-900);
  font-size: 0.92rem;
  font-weight: 650;
}

.aui-header .nav-link:hover,
.aui-header .nav-link.active {
  color: var(--aui-red);
}

.aui-header .nav-link.active::after {
  content: "";
  position: absolute;
  right: 0.72rem;
  bottom: 0;
  left: 0.72rem;
  height: 3px;
  background: var(--aui-red);
  border-radius: 4px 4px 0 0;
}

.aui-header .dropdown-menu {
  padding: 0.55rem;
  border: 1px solid var(--aui-gray-200);
  border-radius: var(--aui-radius);
  box-shadow: var(--aui-shadow);
}

.aui-header .dropdown-item {
  padding: 0.6rem 0.75rem;
  border-radius: 0.35rem;
  color: var(--aui-gray-900);
  font-size: 0.92rem;
}

.aui-header .dropdown-item:hover {
  color: var(--aui-red-dark);
  background: var(--aui-red-pale);
}

/* ---------------------------------------------------------
   5. HERO
   --------------------------------------------------------- */
.aui-hero {
  position: relative;
  overflow: hidden;
  padding: 6.25rem 0;
  background:
    linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.98) 0%,
      rgba(255, 255, 255, 0.92) 48%,
      rgba(255, 248, 246, 0.80) 100%
    ),
    url("../../img/logo_5.png") center right / cover no-repeat;
  border-bottom: 1px solid var(--aui-gray-200);
}

.aui-hero-watermark {
  position: absolute;
  top: -150px;
  right: -90px;
  width: 520px;
  height: 520px;
  background:
    url("../../img/logo_1.png")
    center / contain
    no-repeat;
  opacity: 0.022;
  pointer-events: none;
}

.aui-hero .aui-kicker {
  margin-bottom: 1.15rem;
}

.aui-hero h1 {
  max-width: 760px;
}

.aui-hero h1 span {
  display: block;
  color: var(--aui-red);
}

.aui-hero-lead {
  max-width: 700px;
  margin-top: 1.4rem;
  color: var(--aui-gray-700);
  font-size: 1.23rem;
  line-height: 1.65;
}

.aui-hero-identity {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  padding: 2rem;
}

.aui-hero-logo {
  width: min(100%, 560px);
  max-height: 230px;
  object-fit: contain;
}

/* ---------------------------------------------------------
   6. ELEMENTOS DE IDENTIDAD
   --------------------------------------------------------- */
.aui-kicker {
  display: inline-block;
  margin-bottom: 0.7rem;
  color: var(--aui-red);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.aui-kicker-on-dark {
  color: #ddb0b7;
}

.aui-kicker-on-red {
  color: rgba(255, 255, 255, 0.78);
}

/* ---------------------------------------------------------
   7. BOTONES
   --------------------------------------------------------- */
.btn-aui-primary {
  padding: 0.72rem 1.4rem;
  color: var(--aui-white);
  background: var(--aui-red);
  border: 2px solid var(--aui-red);
  border-radius: var(--aui-radius);
  font-weight: 700;
}

.btn-aui-primary:hover {
  color: var(--aui-white);
  background: var(--aui-red-dark);
  border-color: var(--aui-red-dark);
}

.btn-aui-outline {
  padding: 0.72rem 1.4rem;
  color: var(--aui-red);
  background: transparent;
  border: 2px solid var(--aui-red);
  border-radius: var(--aui-radius);
  font-weight: 700;
}

.btn-aui-outline:hover {
  color: var(--aui-white);
  background: var(--aui-red);
}

.btn-aui-light {
  padding: 0.72rem 1.4rem;
  color: var(--aui-red-dark);
  background: var(--aui-white);
  border: 2px solid var(--aui-white);
  border-radius: var(--aui-radius);
  font-weight: 700;
}

.btn-aui-light:hover {
  color: var(--aui-red-dark);
  background: #f6e9ec;
  border-color: #f6e9ec;
}

/* ---------------------------------------------------------
   8. SECCIONES
   --------------------------------------------------------- */
.aui-section {
  padding: var(--aui-section-padding) 0;
}

.aui-section-soft {
  position: relative;
  background:
    linear-gradient(
      rgba(248, 246, 245, 0.96),
      rgba(248, 246, 245, 0.96)
    ),
    url("../../img/logo_4.png") center / 520px auto repeat;
}

.aui-section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 2rem;
  margin-bottom: 2.8rem;
}

.aui-section-title {
  position: relative;
  margin-bottom: 0.8rem;
  padding-bottom: 0.85rem;
}

.aui-section-title::after {
  content: "";
  display: block;
  width: 58px;
  height: 4px;
  margin-top: 0.8rem;
  background: var(--aui-red);
  border-radius: 999px;
}

.aui-section-subtitle {
  max-width: 760px;
  margin: 0;
  color: var(--aui-gray-700);
  font-size: 1.05rem;
}

.aui-section-title-light {
  color: var(--aui-white);
}

.aui-section-title-light::after {
  background: var(--aui-red-soft);
}

.aui-link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--aui-red);
  font-weight: 700;
  white-space: nowrap;
}

.aui-link-arrow::after {
  content: "→";
}

.aui-link-arrow:hover {
  gap: 0.7rem;
}

/* ---------------------------------------------------------
   9. NOTICIAS
   --------------------------------------------------------- */
.aui-card {
  height: 100%;
  overflow: hidden;
  background: var(--aui-white);
  border: 1px solid var(--aui-gray-200);
  border-radius: var(--aui-radius-lg);
  transition:
    transform 0.22s ease,
    border-color 0.22s ease,
    box-shadow 0.22s ease;
}

.aui-card:hover {
  transform: translateY(-5px);
  border-color: rgba(205, 42, 0, 0.30);
  box-shadow: var(--aui-shadow-hover);
}

.aui-card-image {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--aui-red-pale);
}

.aui-card-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      circle at top right,
      rgba(205, 42, 0, 0.12),
      transparent 50%
    );
}

.aui-card-image img {
  position: relative;
  width: 92px;
  opacity: 0.16;
}

.aui-card-image-sustainability {
  background: #f7f5f1;
}

.aui-card-image-history {
  background: #efe9e6;
}

.aui-card-body {
  padding: 1.55rem;
}

.aui-card-meta {
  margin-bottom: 0.65rem;
  color: var(--aui-red);
  font-size: 0.81rem;
  font-weight: 700;
}

.aui-card-title {
  margin-bottom: 0.85rem;
  font-size: 1.22rem;
}

.aui-card-title a {
  color: var(--aui-charcoal);
}

.aui-card-title a:hover {
  color: var(--aui-red);
}

.aui-card-text {
  color: var(--aui-gray-700);
}

.aui-card-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-weight: 700;
}

/* ---------------------------------------------------------
   10. ÁREAS
   --------------------------------------------------------- */
.aui-topic {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 2rem;
  color: var(--aui-dark);
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--aui-gray-200);
  border-top: 5px solid var(--aui-red);
  border-radius: var(--aui-radius-lg);
  box-shadow: 0 2px 10px rgba(60, 40, 30, 0.035);
  transition:
    transform 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease;
}

.aui-topic:hover {
  color: var(--aui-white);
  background: var(--aui-red);
  transform: translateY(-4px);
  box-shadow: var(--aui-shadow-hover);
}

.aui-topic-number {
  margin-bottom: 1.45rem;
  color: var(--aui-red);
  font-size: 0.78rem;
  font-weight: 800;
}

.aui-topic h3 {
  margin-bottom: 0.8rem;
  color: var(--aui-charcoal);
  font-size: 1.35rem;
}

.aui-topic p {
  flex-grow: 1;
  color: var(--aui-gray-700);
}

.aui-topic-link {
  font-weight: 700;
}

.aui-topic-link::after {
  content: " →";
}

.aui-topic:hover h3,
.aui-topic:hover p,
.aui-topic:hover .aui-topic-number,
.aui-topic:hover .aui-topic-link {
  color: var(--aui-white);
}

/* ---------------------------------------------------------
   11. AGENDA
   --------------------------------------------------------- */
.aui-event {
  display: flex;
  gap: 1.3rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--aui-gray-200);
}

.aui-event-date {
  flex: 0 0 76px;
  align-self: flex-start;
  padding: 0.7rem 0.4rem;
  color: var(--aui-white);
  background: var(--aui-red);
  border-radius: var(--aui-radius);
  text-align: center;
}

.aui-event-day {
  display: block;
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1;
}

.aui-event-month {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.aui-event-type {
  display: block;
  margin-bottom: 0.2rem;
  color: var(--aui-red);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.aui-event h3 {
  margin-bottom: 0.3rem;
}

.aui-event p {
  margin-bottom: 0.35rem;
  color: var(--aui-gray-700);
}

/* ---------------------------------------------------------
   12. PARTICIPA
   --------------------------------------------------------- */
.aui-participa-box {
  position: relative;
  height: 100%;
  overflow: hidden;
  padding: 2.4rem;
  background: var(--aui-red-pale);
  border: 1px solid #ead7db;
  border-radius: var(--aui-radius-lg);
}

.aui-participa-symbol {
  position: absolute;
  top: -35px;
  right: -35px;
  width: 180px;
  opacity: 0.055;
  pointer-events: none;
}

.aui-participa-box h2 {
  position: relative;
  margin-bottom: 1rem;
  font-size: 1.85rem;
}

.aui-participa-box p {
  position: relative;
  margin-bottom: 1.6rem;
  color: var(--aui-gray-700);
}

/* ---------------------------------------------------------
   13. DOCUMENTOS
   --------------------------------------------------------- */
.aui-document {
  display: flex;
  gap: 1rem;
  height: 100%;
  padding: 1.45rem;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--aui-gray-200);
  border-radius: var(--aui-radius);
}

.aui-document-icon {
  display: grid;
  place-items: center;
  flex: 0 0 58px;
  width: 58px;
  height: 58px;
  color: var(--aui-white);
  background: var(--aui-red);
  border-radius: 0.45rem;
  font-size: 0.72rem;
  font-weight: 800;
}

.aui-document-meta {
  margin-bottom: 0.3rem;
  color: var(--aui-red);
  font-size: 0.78rem;
  font-weight: 700;
}

.aui-document h3 {
  margin-bottom: 0.45rem;
  font-size: 1.06rem;
}

.aui-document h3 a {
  color: var(--aui-charcoal);
}

.aui-document h3 a:hover {
  color: var(--aui-red);
}

.aui-document p {
  color: var(--aui-gray-700);
  font-size: 0.94rem;
}

/* ---------------------------------------------------------
   14. PROYECTOS
   --------------------------------------------------------- */
.aui-project-card {
  position: relative;
  height: 100%;
  padding: 2rem;
  overflow: hidden;
  background: var(--aui-white);
  border: 1px solid var(--aui-gray-200);
  border-radius: var(--aui-radius-lg);
}

.aui-project-card::after {
  content: "";
  position: absolute;
  right: -45px;
  bottom: -45px;
  width: 130px;
  height: 130px;
  background:
    url("../../img/logo_1.png")
    center / contain
    no-repeat;
  opacity: 0.035;
}

.aui-project-status {
  display: inline-block;
  margin-bottom: 1.15rem;
  padding: 0.3rem 0.65rem;
  color: var(--aui-red-dark);
  background: var(--aui-red-pale);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.aui-project-card h3 {
  font-size: 1.35rem;
}

.aui-project-card p {
  color: var(--aui-gray-700);
}

/* ---------------------------------------------------------
   15. HISTORIA DE INTERNET
   --------------------------------------------------------- */
.aui-history {
  position: relative;
  overflow: hidden;
  color: var(--aui-white);
  background:
    radial-gradient(
      circle at 0% 0%,
      rgba(205, 42, 0, 0.22),
      transparent 32%
    ),
    var(--aui-charcoal);
}

.aui-history-symbol {
  position: absolute;
  right: -130px;
  bottom: -170px;
  width: 560px;
  opacity: 0.035;
  pointer-events: none;
}

.aui-history-intro {
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.12rem;
}

.aui-timeline {
  position: relative;
  margin-left: 1rem;
  padding-left: 2.2rem;
  border-left: 3px solid rgba(255, 255, 255, 0.16);
}

.aui-timeline-item {
  position: relative;
  margin-bottom: 2rem;
}

.aui-timeline-item:last-child {
  margin-bottom: 0;
}

.aui-timeline-item::before {
  content: "";
  position: absolute;
  top: 0.35rem;
  left: -2.72rem;
  width: 15px;
  height: 15px;
  background: var(--aui-red);
  border: 3px solid var(--aui-charcoal);
  border-radius: 50%;
}

.aui-timeline-year {
  margin-bottom: 0.18rem;
  color: #d8a5ad;
  font-weight: 800;
}

.aui-timeline h3 {
  margin-bottom: 0.35rem;
  color: var(--aui-white);
}

.aui-timeline p {
  color: rgba(255, 255, 255, 0.72);
}

/* ---------------------------------------------------------
   16. ÁLBUM
   --------------------------------------------------------- */
.aui-album {
  position: relative;
  display: block;
  overflow: hidden;
  background: var(--aui-gray-100);
  border-radius: var(--aui-radius-lg);
  box-shadow: var(--aui-shadow);
}

.aui-album-placeholder {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background:
    linear-gradient(
      145deg,
      #f6f1f2,
      #e8dde0
    );
}

.aui-album-placeholder img {
  width: 120px;
  opacity: 0.12;
  transition: transform 0.3s ease;
}

.aui-album:hover .aui-album-placeholder img {
  transform: scale(1.08) rotate(3deg);
}

.aui-album-info {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  padding: 3rem 1.3rem 1.2rem;
  color: var(--aui-white);
  background:
    linear-gradient(
      transparent,
      rgba(41, 35, 33, 0.92)
    );
}

.aui-album-info span {
  display: block;
  margin-bottom: 0.15rem;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
}

.aui-album-info h3 {
  margin: 0;
  color: var(--aui-white);
  font-size: 1.6rem;
}

/* ---------------------------------------------------------
   17. CTA
   --------------------------------------------------------- */
.aui-cta {
  position: relative;
  overflow: hidden;
  padding: 4rem 0;
  color: var(--aui-white);
  background: var(--aui-red);
}

.aui-cta-pattern {
  position: absolute;
  inset: 0;
  background:
    url("../../img/logo_4.png")
    center / 430px auto
    repeat;
  opacity: 0.05;
  mix-blend-mode: screen;
}

.aui-cta h2 {
  margin-bottom: 0.7rem;
  color: var(--aui-white);
}

.aui-cta p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 1.08rem;
}

/* ---------------------------------------------------------
   18. FOOTER
   --------------------------------------------------------- */
.aui-footer {
  padding: 4.5rem 0 2rem;
  color: rgba(255, 255, 255, 0.72);
  background: #211c1a;
}

.aui-footer-symbol {
  width: 82px;
  margin-bottom: 1.3rem;
}

.aui-footer-intro {
  max-width: 320px;
}

.aui-footer h2 {
  margin-bottom: 1rem;
  color: var(--aui-white);
  font-size: 1rem;
}

.aui-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.aui-footer li {
  margin-bottom: 0.45rem;
}

.aui-footer a {
  color: rgba(255, 255, 255, 0.68);
}

.aui-footer a:hover {
  color: #ddb0b7;
}

.aui-footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.83rem;
}

/* ---------------------------------------------------------
   19. ACCESIBILIDAD
   --------------------------------------------------------- */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.nav-link:focus-visible {
  outline: 3px solid #c77f8b;
  outline-offset: 3px;
}

/* ---------------------------------------------------------
   20. RESPONSIVE
   --------------------------------------------------------- */
@media (max-width: 1199.98px) {

  .aui-header .navbar {
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }

  .aui-header .nav-link {
    padding: 0.85rem 0 !important;
  }

  .aui-header .nav-link.active::after {
    right: auto;
    bottom: 0.3rem;
    left: 0;
    width: 34px;
  }

  .aui-header .navbar-collapse {
    padding: 0.75rem 0 1.15rem;
  }
}

@media (max-width: 991.98px) {

  :root {
    --aui-section-padding: 4rem;
  }

  .aui-hero {
    padding: 4.5rem 0;
  }

  .aui-hero-identity {
    min-height: 180px;
    justify-content: flex-start;
    padding: 1rem 0 0;
  }

  .aui-hero-logo {
    width: min(100%, 470px);
  }

  .aui-section-header {
    display: block;
  }

  .aui-section-header .aui-link-arrow {
    margin-top: 1rem;
  }

  .aui-history-symbol {
    width: 420px;
  }
}

@media (max-width: 767.98px) {

  :root {
    --aui-section-padding: 3.35rem;
  }

  body {
    font-size: 0.97rem;
  }

  .aui-topbar-name {
    display: none;
  }

  .aui-topbar-inner {
    justify-content: flex-end;
  }

  .aui-hero {
    padding: 3.7rem 0;
  }

  .aui-hero-lead {
    font-size: 1.08rem;
  }

  .aui-event {
    gap: 0.9rem;
  }

  .aui-event-date {
    flex-basis: 66px;
  }

  .aui-footer-bottom {
    flex-direction: column;
  }
}

@media (max-width: 575.98px) {

  .aui-topbar {
    display: none;
  }

  .aui-header-symbol {
    width: 50px;
    height: 50px;
  }

  .aui-hero {
    background:
      linear-gradient(
        rgba(255, 255, 255, 0.94),
        rgba(255, 255, 255, 0.96)
      ),
      url("../../img/logo_5.png")
      70% center / cover
      no-repeat;
  }

  .aui-hero-identity {
    display: none;
  }

  .aui-document {
    flex-direction: column;
  }

  .aui-timeline {
    margin-left: 0.5rem;
    padding-left: 1.7rem;
  }

  .aui-timeline-item::before {
    left: -2.22rem;
  }
}
