/*
========================
======================== CURSOS
========================
*/

.courses {
  padding-top: 6rem;
}

@media (max-width: 991px) {
  .courses {
    padding-top: 4rem;
  }
}

.courses .container {
  display: flex;
  justify-content: space-between;
  gap: 8rem;
}

@media (max-width: 991px) {
  .courses .container {
    flex-direction: column;
    gap: 4rem;
  }
}

.courses-nav {
  max-width: 30rem;
  padding-top: 59px;
}

@media (max-width: 991px) {
  .courses-nav {
    max-width: 100%;
    padding-top: 0;
    text-align: center;
  }
}

.courses-nav-item {
  margin-bottom: 4rem;
}

.courses-nav-item h2 {
  color: var(--blue-normal);
  font-size: 2.2rem;
  font-weight: 700;
}

.courses-nav-item ul {
  margin-top: 0.5rem;
}

.courses-nav-item-li {
  display: none;
}

.courses-nav-item-li a {
  padding: 0.6rem 0.8rem;
  border-radius: 0.6rem;
  display: flex;
  align-items: center;
  justify-content: space-between;


}

.courses-nav-item-li a.active,
.courses-nav-item-li a:hover {
  background: var(--blue-normal);
  padding-left: 1.2rem;
  transition: 0.4s all;
}

.courses-nav-item-li a p {
  color: var(--blue-normal);
  font-size: 1.4rem;
  font-weight: 400;
}

.courses-nav-item-li a.active p,
.courses-nav-item-li a:hover p {
  color: var(--white-light);
}

.courses-nav-item-li a span {
  background: var(--blue-normal);
  color: var(--white-light);
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 1rem;
  line-height: 1; /* ajuda a centralizar melhor o texto */
  font-weight: bold;
}

.courses-nav-item-li a.active span,
.courses-nav-item-li a:hover span {
  background-color: #f39421;
  color: #000;
}

.more-areas {
  width: 100%;
  margin-top: 20px;
  text-align: center;
  border-top: 1px solid var(--grey-6);
  padding-top: 10px;
}

.more-areas .btn {
  background-color: var(--blue-normal);
  padding: 1rem 2rem;
  font-size: 1.4rem;
  color: var(--white-light);
  border-radius: 6px;
  transition: opacity 0.4s;
  display: inline-block;
}

@media (max-width: 560px) {
  .more-areas .btn {
    width: 100%;
  }
}

.more-areas .btn:hover {
  opacity: 0.8;
}

.more-areas .btn.disabled,
.more-areas .btn.disabled:hover {
  background-color: var(--grey);
  cursor: not-allowed;
  pointer-events: none;
}

.courses-list {
  flex: 1;
}

@media (max-width: 991px) {
  .courses-list {
    max-width: 100%;
  }
}

.courses-list-title {
  margin-bottom: 2rem;
}

@media (max-width: 991px) {
  .courses-list-title {
    text-align: center;
  }
}

.courses-list-title h2 {
  color: var(--blue-normal);
  font-size: 3.2rem;
  font-weight: 400;
  line-height: normal;
}

.courses-list-title h2 strong {
  font-weight: 800;
  text-transform: uppercase;
}

.courses-all {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
}

@media (max-width: 991px) {
  .courses-all {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .courses-all {
    grid-template-columns: 1fr;
  }
}

.courses-item {
  border-bottom: 1px solid #d9d9d9;
  padding-bottom: 2rem;
}

.courses-item-cover {
  width: 100%;
  height: 20rem;
  border-radius: 2rem;
  overflow: hidden;
}

.courses-item-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.courses-item-desc {
  margin-top: 2rem;
  display: flex;
  gap: 15px;
  justify-content: space-between;
  align-items: flex-start;
}

.courses-item-desc .date {
  background-color: var(--orange);
  max-width: 8rem;
  text-align: center;
  padding: 6px;
  border-radius: 10px;

  display: flex;
  flex-direction: column;
  color: #ffffff;
}

.courses-item-desc .date .day {
  font-size: 2.4rem;
  font-weight: 800;
  border-bottom: 1px solid #ffffff;
  padding-bottom: 2px;
}

.courses-item-desc .date .month {
  font-size: 2.4rem;
  font-weight: 800;
}

.courses-item-desc .date .year {
  font-size: 1.4rem;
  font-weight: 800;
  margin-top: -3px;
}

.courses-item-desc .titles {
  flex: 1;
}

.courses-item-desc .titles h3 {
  color: var(--grey);
  font-size: 1.8rem;
  font-weight: 600;
  line-height: 120%;
}

.courses-item:hover .titles h3 {
  text-decoration: underline;
}

.courses-item-desc .titles p {
  color: var(--grey);
  font-size: 1.4rem;
  font-weight: 400;
  margin-top: 0.5rem;
}

.courses-more {
  width: 100%;
  text-align: center;
  margin-top: 6rem;
}

.courses-more .btn {
  background-color: var(--blue-normal);
  padding: 1.3rem 3rem;
  font-size: 1.6rem;
  color: var(--white-light);
  border-radius: 6px;
  transition: opacity 0.4s;
  display: inline-block;
}

@media (max-width: 560px) {
  .courses-more .btn {
    width: 100%;
  }
}

.courses-more .btn:hover {
  opacity: 0.8;
}

.courses-more .btn.disabled,
.courses-more .btn.disabled:hover {
  background-color: var(--grey);
  cursor: not-allowed;
  pointer-events: none;
}

.pagination {
  display: flex;
  margin-top: 35px;
}

.pagination ol {
  margin: 0 auto;
  text-align: center;
}

.pagination ol li {
  float: left;
  list-style: none;
  margin: 0 2.5px;
}

.pagination ol li a {
  display: inline-block;
  padding: 12px 0;
  background: #2d4e8a;
  text-align: center;
  border-radius: 7px;
  min-width: 35px;
  color: #ffffff;
  font-weight: bold;
  font-size: 10px;

  -webkit-transition: all 0.3s ease;
  -moz-transition: all 0.3s ease;
  -o-transition: all 0.3s ease;
  -ms-transition: all 0.3s ease;
  transition: all 0.3s ease;
}

.pagination ol li:first-child a,
.pagination ol li:last-child a {
  min-width: 100px;
  text-transform: uppercase;
  padding: 12px 14px;
}

.pagination ol li a:hover {
  background: #132445;
}

.pagination ol li a.active {
  background: #f39421;
  color: #000000;
  cursor: default;
}

/* Load More Courses */
.load-more-container {
  text-align: center;
  margin: 2rem 0;
}
.load-more-container .btn {
  background-color: var(--blue-normal);
  padding: 1.3rem 4.0rem 1.3rem 3rem; /* top right bottom left */
  font-size: 1.6rem;
  color: var(--white-light);
  border-radius: 6px;
  transition: opacity 0.4s;
  display: inline-block;
  font-family: "Inter", sans-serif;
  font-weight: bold;
  position: relative;
}
/* Spinner dentro do botão */
.load-more-container .btn .spinner {
  display: inline-block;
  width: 1.6rem;
  height: 1.6rem;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: var(--white-light);
  border-radius: 50%;
  position: absolute;
  top: 50%;
  right: 1.5rem;
  transform: translateY(-50%);
  animation: spin 1s linear infinite;
}
@media (max-width: 560px) {
  .load-more-container .btn {
    width: 100%;
  }
}
.load-more-container .btn:hover {
  opacity: 0.8;
}
.load-more-container .btn.disabled,
.load-more-container .btn.disabled:hover {
  background-color: var(--grey);
  cursor: not-allowed;
  pointer-events: none;
}

@keyframes spin {
  from { transform: translateY(-50%) rotate(0deg); }
  to   { transform: translateY(-50%) rotate(360deg); }
}