/* =========================
   ACREDITACIONES
========================= */

.ac-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid #bbf7d0;
  color: var(--green-dark);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
}

.ac-section {
  padding: 64px 0;
}

.ac-section-alt {
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
}

.ac-section-head {
  margin-bottom: 28px;
}

.ac-section-head h2 {
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.2;
  margin-bottom: 6px;
}

.ac-section-head p {
  color: var(--gray-600);
}

/* ---------- Documentos ---------- */

.ac-docs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.ac-doc {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 24px;
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 18px;
  padding: 24px;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.ac-doc:hover {
  border-color: #bbf7d0;
  box-shadow: 0 14px 32px rgba(17, 24, 39, 0.07);
}

.ac-doc-preview {
  display: block;
  align-self: start;
  aspect-ratio: 210 / 297;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--gray-200);
  box-shadow: 0 6px 16px rgba(17, 24, 39, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ac-doc:hover .ac-doc-preview {
  transform: translateY(-3px) rotate(-1deg);
  box-shadow: 0 12px 24px rgba(17, 24, 39, 0.14);
}

.ac-doc-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.ac-doc-cover {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 18px;
  text-decoration: none;
  color: #fff;
  background:
    radial-gradient(circle at 20% 15%, rgba(255, 255, 255, 0.18), transparent 45%),
    linear-gradient(160deg, var(--green) 0%, #14532d 100%);
}

.ac-cover-seal {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.16);
  font-size: 20px;
}

.ac-cover-title {
  font-weight: 700;
  font-size: 17px;
  line-height: 1.25;
}

.ac-cover-sub {
  font-size: 12px;
  line-height: 1.4;
  opacity: 0.85;
}

.ac-doc-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}

.ac-doc-kicker {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--green-dark);
}

.ac-doc h3 {
  font-size: 20px;
  line-height: 1.3;
}

.ac-doc p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--gray-600);
}

.ac-doc-meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  font-size: 14px;
  color: var(--gray-600);
}

.ac-doc-meta i {
  color: var(--green);
  margin-right: 6px;
}

.ac-doc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: auto;
  padding-top: 8px;
}

.ac-doc-actions .btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* ---------- Línea de tiempo ---------- */

.ac-timeline {
  list-style: none;
  position: relative;
  display: grid;
  gap: 20px;
  max-width: 820px;
}

.ac-timeline::before {
  content: "";
  position: absolute;
  left: 39px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(var(--green), #bbf7d0);
}

.ac-timeline li {
  position: relative;
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 24px;
  align-items: start;
}

.ac-year {
  position: relative;
  z-index: 1;
  justify-self: center;
  background: #fff;
  border: 2px solid var(--green);
  color: var(--green-dark);
  font-weight: 700;
  font-size: 14px;
  border-radius: 999px;
  padding: 4px 12px;
  font-variant-numeric: tabular-nums;
}

.ac-timeline li > div {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 14px;
  padding: 16px 20px;
}

.ac-timeline h3 {
  font-size: 17px;
  margin-bottom: 4px;
}

.ac-timeline p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--gray-600);
}

/* ---------- Tabla ---------- */

.ac-table-wrap {
  background: #fff;
  border: 1px solid var(--gray-200);
  border-radius: 18px;
  overflow: hidden;
}

.ac-table-tools {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-50);
}

.ac-panel-title {
  padding: 14px 20px 0;
  font-size: 14px;
  color: var(--gray-600);
  max-width: none;
}

.ac-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.ac-table th,
.ac-table td {
  padding: 12px 20px;
  text-align: left;
  border-bottom: 1px solid var(--gray-100);
}

.ac-table th {
  position: sticky;
  top: 0;
  background: #fff;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-600);
  white-space: nowrap;
}

.ac-table th button {
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  cursor: pointer;
  padding: 0;
}

.ac-table th button::after {
  content: "\f0dc";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  margin-left: 6px;
  opacity: 0.35;
}

.ac-table th button[aria-sort="ascending"]::after { content: "\f0de"; opacity: 1; color: var(--green); }
.ac-table th button[aria-sort="descending"]::after { content: "\f0dd"; opacity: 1; color: var(--green); }

.ac-table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.ac-table tbody tr {
  transition: background 0.15s ease;
}

.ac-table tbody tr:hover {
  background: #f0fdf4;
}

.ac-table td a {
  color: var(--green-dark);
  font-weight: 600;
  text-decoration: none;
}

.ac-table td a i {
  font-size: 11px;
  margin-left: 4px;
  transition: transform 0.2s ease;
}

.ac-table td a:hover i {
  transform: translateX(3px);
}

.ac-table tfoot td {
  font-weight: 700;
  background: var(--gray-50);
  border-bottom: 0;
}

.ac-note,
.ac-empty {
  padding: 14px 20px;
  font-size: 13px;
  color: var(--gray-600);
  max-width: none;
}

.ac-empty {
  text-align: center;
  font-size: 15px;
  padding: 40px 20px;
}

/* ---------- Responsive ---------- */

@media (max-width: 1150px) {
  .ac-docs { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .ac-section { padding: 44px 0; }
  .ac-doc { grid-template-columns: 1fr; padding: 20px; }
  .ac-doc-preview { width: 150px; }

  .ac-timeline::before { left: 31px; }
  .ac-timeline li { grid-template-columns: 64px 1fr; gap: 14px; }
  .ac-year { font-size: 13px; padding: 3px 9px; }

  /* Tabla como tarjetas */
  .ac-table thead { display: none; }
  .ac-table,
  .ac-table tbody,
  .ac-table tr,
  .ac-table td { display: block; }
  .ac-table tbody tr {
    padding: 12px 20px;
    border-bottom: 1px solid var(--gray-100);
  }
  .ac-table tbody td {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 3px 0;
    border: 0;
    text-align: right;
  }
  .ac-table tbody td::before {
    content: attr(data-label);
    color: var(--gray-600);
    font-size: 13px;
    text-align: left;
  }
  .ac-table tbody td:first-child {
    font-weight: 600;
    font-size: 16px;
    padding-bottom: 6px;
  }
  .ac-table tbody td:first-child::before { display: none; }
  .ac-table tfoot tr { display: flex; justify-content: space-between; flex-wrap: wrap; padding: 12px 20px; }
  .ac-table tfoot td { display: inline; padding: 0 8px 0 0; }
}
