/* Extracted from theme style.css. Keep cascade order in functions.php. */

/* --------------- USER PROFILE ------------------- */

.profile-user-hero .profile-user-hero__inner,
.profile-user-content {
  max-width: 1500px;
  margin: 0 auto;
  padding-left: 2rem;
  padding-right: 2rem;
  width: 100%;
}

.profile-user-hero {
  position: relative;
  background: var(--gradient-learnio);
  padding: 7rem 2rem 3.5rem;
  overflow: hidden;
  border-radius: 0 0 2.5rem 2.5rem;

  .bubble {
    position: absolute;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 1);
    opacity: 0.1;
    animation: moveBubble 10s infinite ease-in-out;
  }

  .bubble1 {
    width: 150px;
    height: 150px;
    top: 10%;
    left: 20%;
    animation-duration: 15s;
  }

  .bubble2 {
    width: 100px;
    height: 100px;
    top: 40%;
    left: 50%;
    animation-duration: 12s;
  }

  .bubble3 {
    width: 120px;
    height: 120px;
    top: 70%;
    left: 80%;
    animation-duration: 18s;
  }

  .bubble4 {
    width: 90px;
    height: 90px;
    top: 30%;
    left: 80%;
    animation-duration: 14s;
  }

  .bubble5 {
    width: 180px;
    height: 180px;
    top: 60%;
    left: 40%;
    animation-duration: 20s;
  }

  .bubble6 {
    width: 130px;
    height: 130px;
    top: 20%;
    left: 70%;
    animation-duration: 17s;
  }

  .bubble7 {
    width: 110px;
    height: 110px;
    top: 50%;
    left: 10%;
    animation-duration: 16s;
  }

  .bubble8 {
    width: 160px;
    height: 160px;
    top: 80%;
    left: 30%;
    animation-duration: 13s;
  }

  .bubble9 {
    width: 140px;
    height: 140px;
    top: 15%;
    left: 90%;
    animation-duration: 19s;
  }

  .profile-user-hero__circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    pointer-events: none;

    .large {
      width: 420px;
      height: 420px;
      right: -80px;
      top: -80px;
    }

    .small {
      width: 240px;
      height: 240px;
      right: 160px;
      top: 80px;
    }
  }

  .profile-user-hero__inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 2.5rem;
  }

  .profile-user-hero__avatar {
    flex-shrink: 0;

    img {
      width: 150px;
      height: 150px;
      border-radius: 50%;
      object-fit: cover;
      border: 4px solid rgba(255, 255, 255, 0.85);
      box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    }
  }

  .profile-user-hero__info {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
  }

  .profile-user-hero__name-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;

    .profile-user-hero__verified {
      display: flex;
      align-items: center;
      color: var(--brand-orange);
    }

    .profile-user-hero__heart {
      display: flex;
      align-items: center;
      color: var(--purple-stroke-light);
    }
  }

  .profile-user-hero__bio {
    color: rgba(255, 255, 255, 0.85);
    max-width: 480px;
    line-height: 1.4;
  }

  .profile-user-hero__tags {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;

    .profile-user-hero__tag {
      display: inline-flex;
      align-items: center;
      gap: 0.3rem;
      padding: 0.3rem 0.85rem;
      border-radius: var(--radius-pill);
      border: 1.5px solid rgba(255, 255, 255, 0.6);
      color: var(--white);
      font-size: 0.875rem;
      font-weight: 600;
      background: rgba(255, 255, 255, 0.1);
      backdrop-filter: blur(6px);
    }
  }

  .profile-user-hero__stats {
    display: flex;
    align-items: flex-start;
    gap: 2rem;
    margin-top: 0.5rem;

    .profile-user-hero__stat {
      display: flex;
      flex-direction: column;
      gap: 0.1rem;

      .profile-user-hero__stat-value {
        display: flex;
        align-items: center;
        gap: 0.3rem;
        font-size: 1.5rem;
        font-weight: 700;
        color: var(--white);

        .profile-user-hero__star {
          color: var(--brand-orange);
        }
      }

      .profile-user-hero__stat-label {
        font-size: 0.875rem;
        font-weight: 500;
        color: rgba(255, 255, 255, 0.75);
      }
    }
  }
}

.profile-user-content {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 5rem;
  padding-top: 3rem;
  padding-bottom: 3rem;
  align-items: start;

  .profile-user-left {
    display: flex;
    flex-direction: column;
    gap: 2rem;
  }

  .profile-user-about__card {
    background: var(--white);
    padding: 2rem 2.5rem;
    box-shadow: 2px 7px 20px rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-2);

    h2 {
      font-size: 2rem;
      font-family: var(--title-font);
      margin-bottom: 1rem;
      background: none;
      -webkit-text-fill-color: var(--purple-stroke);
      color: var(--purple-stroke);
    }

    p {
      line-height: 1.7;
    }
  }

  .profile-user-reviews {
    display: flex;
    flex-direction: column;
    gap: 1rem;

    .profile-user-reviews__title {
      font-size: 2rem;
      font-family: var(--title-font);
      color: var(--purple-stroke);
      font-weight: 700;

      .profile-user-reviews__count {
        font-size: 1rem;
        color: var(--gray-2);
        font-weight: 400;
      }
    }

    .profile-user-reviews__list {
      display: flex;
      flex-direction: column;
      gap: 0.75rem;
      background-color: var(--bg);
    }

    .profile-user-reviews__actions {
      display: flex;
      justify-content: center;
      margin-top: 0.75rem;
    }

    .profile-user-reviews__card {
      background: var(--white);
      padding: 1rem 1.25rem;
      box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
      border-radius: var(--radius-2);
      display: flex;
      flex-direction: column;
      gap: 0.5rem;

      .profile-user-reviews__card-header {
        display: flex;
        align-items: center;
        gap: 0.75rem;
      }

      .profile-user-reviews__avatar {
        width: 2.25rem;
        height: 2.25rem;
        border-radius: 50%;
        background: var(--brand-orange);
        color: var(--white);
        font-family: var(--title-font);
        font-weight: 700;
        font-size: 1rem;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
      }

      .profile-user-reviews__stars {
        display: flex;
        gap: 0.15rem;
        margin-top: 0.2rem;

        .profile-user-reviews__star {
          width: 14px;
          height: 14px;

          &.empty {
            opacity: 0.25;
          }
        }
      }

      p {
        color: var(--gray);
        line-height: 1.5;
        font-size: 0.875rem;
      }
    }
  }
}

.profile-user-reviews .profile-user-reviews__card--hidden {
  display: none !important;
}


.profile-user-classes {
  margin-top: 1rem;

  .profile-user-classes__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
  }

  .profile-user-classes__grid {
    display: grid;
    grid-template-columns: repeat(3, 280px);
    gap: 1rem;
  }

  .profile-user-classes__actions {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
  }

  .profile-user-class-card {
    background: var(--white);
    border-radius: var(--radius-2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    display: flex;
    flex-direction: column;

    .profile-user-class-card__header {
      background: linear-gradient(90deg, var(--brand-orange) 0%, var(--brand-pink) 100%);
      padding: 1.25rem 1rem;
      min-height: 100px;
      display: flex;
      align-items: center;
      justify-content: center;

      h3 {
        font-family: var(--title-font);
        text-align: center;
        line-height: 1.2;
      }
    }

    .profile-user-class-card__body {
      padding: 0.75rem 1.25rem 1.5rem;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      flex: 1;
      min-height: 310px;

      .profile-user-class-card__body-upper {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
      }
    }

    .profile-user-class-card__tags {
      display: flex;
      flex-wrap: wrap;
      gap: 0.3rem;
      align-items: center;
      justify-content: center;

      .profile-user-class-card__tag {
        padding: 0.2rem 0.65rem;
        border-radius: var(--radius-pill);
        font-size: 0.75rem;
        font-family: var(--body-font);
        font-weight: 500;
        line-height: 1.4;

        &.outline {
          border: 1.5px solid var(--brand-orange);
          color: var(--brand-orange);
          background: transparent;
        }

        &.popular {
          background: var(--brand-orange);
          color: var(--white);
          border: none;
        }
      }
    }


    .profile-user-class-card__desc {
      color: var(--gray);
      font-size: 0.875rem;
      font-family: var(--body-font);
      font-weight: 500;
      line-height: 1.7;
      margin-top: -2rem;
    }

    .profile-user-class-card__stats {
      display: flex;
      gap: 1.5rem;
      padding-top: 0;
      justify-content: center;

      .profile-user-class-card__stat {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.1rem;

        span:first-child {
          color: var(--gray);
          font-size: 1.5rem;
          font-family: var(--title-font);
          font-weight: 700;
          line-height: 1;
          text-align: center;
        }

        span:last-child {
          color: var(--gray-2);
          font-size: 0.75rem;
          font-family: var(--body-font);
          font-weight: 400;
          text-align: center;
        }
      }
    }

    .profile-user-class-card__cta {
      display: flex;
      align-items: center;
      justify-content: center;
      width: 100%;
      height: 42px;
      background-color: var(--purple-stroke);
      color: var(--white) !important;
      border-radius: var(--radius-button);
      font-size: 0.875rem;
      font-family: var(--body-font);
      font-weight: 600;
      text-decoration: none;
      transition: background-color 0.3s;

      &:hover {
        background-color: var(--purple-stroke-hover);
      }
    }
  }

  .profile-user-class__footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
}


.profile-user-classes .profile-user-class-card--hidden {
  display: none !important;
}

.profile-user-class-card--sold-out {
  opacity: 0.82;
}

.profile-user-class-card--sold-out .profile-user-class-card__header {
  filter: grayscale(0.25);
}

.profile-user-class-card__tag.unavailable {
  background: rgba(255, 0, 0, 0.12);
  border: 1px solid rgba(190, 45, 45, 0.35);
  color: #b12a2a;
}

.profile-user-class-card__cta--disabled,
.profile-user-class-card__cta--disabled:hover {
  background-color: var(--gray-3);
  color: var(--gray-2) !important;
  cursor: not-allowed;
  pointer-events: none;
}

@keyframes moveBubble {
  0% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(100px, 100px);
  }

  100% {
    transform: translate(0, 0);
  }
}

@keyframes heroFloat {
  from {
    transform: translateY(0);
  }

  to {
    transform: translateY(-14px);
  }
}


/* Star empty */
.profile-user-reviews__star--empty {
  opacity: 0.25;
}

.profile-user-reviews__card-header {
  align-items: flex-start;
}

.profile-user-reviews__card-meta {
  flex: 1;
}

.profile-user-reviews__delete-form {
  margin-left: auto;
}

.profile-user-reviews__delete-btn {
  appearance: none;
  background: transparent;
  border: 0;
  color: #c62828;
  cursor: pointer;
  font-family: var(--body-font);
  font-size: var(--small);
  font-weight: 600;
  padding: 0.2rem 0;
  text-decoration: underline;
}

.profile-user-reviews__delete-btn:hover,
.profile-user-reviews__delete-btn:focus-visible {
  color: #8e1b1b;
  outline: none;
}

.profile-user-review-form {
  margin-top: 1.5rem;
  padding: 1.5rem;
  background: var(--white);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  border-radius: var(--radius-2);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.profile-user-review-form h3 {
  color: var(--purple-stroke);
}

.profile-user-review-form form {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.profile-user-review-form textarea {
  width: 100%;
  min-height: 100px;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--gray-3);
  border-radius: var(--radius-3);
  font-family: var(--body-font);
  font-size: var(--small);
  resize: vertical;
  box-sizing: border-box;
}

.profile-user-review-form textarea:focus {
  outline: none;
  border-color: var(--purple-stroke);
}

.profile-user-review-stars {
  display: flex;
  gap: 0.2rem;
}

.profile-user-review-stars .star-btn {
  font-size: 1.75rem;
  color: var(--gray-3);
  cursor: pointer;
  transition: color 0.15s;
  user-select: none;
  background: none;
  border: none;
  padding: 0;
}

.profile-user-review-stars .star-btn.active,
.profile-user-review-stars .star-btn.hover {
  color: var(--brand-orange);
}

/* Review messages */
.profile-user-review-msg {
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-3);
  font-size: var(--small);
}

.profile-user-review-msg--ok {
  background: #e8f5e9;
  color: #2e7d32;
}

.profile-user-review-msg--err {
  background: #fdecea;
  color: #c62828;
}

.profile-user-review-login {
  margin-top: 1rem;
  font-size: var(--small);
  color: var(--gray-2);
}

.profile-user-review-login a {
  color: var(--purple-stroke);
  font-weight: 600;
  text-decoration: underline;
}

.profile-user-toast {
  position: fixed;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 10000;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  width: min(420px, calc(100vw - 3rem));
  padding: 1rem;
  border-radius: var(--radius-3);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.16);
}

.profile-user-toast--success {
  border: 1px solid #badbcc;
  background: #e8f5e9;
  color: #1f6b3a;
}

.profile-user-toast p {
  flex: 1;
  margin: 0;
  font-size: var(--small);
  font-weight: 700;
  line-height: 1.45;
}

.profile-user-toast button {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-size: 1.25rem;
  line-height: 1;
  padding: 0;
}

@media (max-width: 640px) {
  .profile-user-toast {
    right: 1rem;
    bottom: 1rem;
    left: 1rem;
    width: auto;
  }
}

.profile-user-hero__cta {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin-top: 1rem;
}

.profile-user-hero__name-row .profile-user-hero__cta {
  align-self: center;
  margin-top: 0;
}

.profile-user-hero__icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.5);
  transition: background 0.2s, border-color 0.2s;
  text-decoration: none;
  flex-shrink: 0;
}

.profile-user-hero__icon-btn svg {
  width: 16px;
  height: 16px;
}

.profile-user-hero__icon-btn:hover {
  background: rgba(255, 255, 255, 0.35);
  border-color: rgba(255, 255, 255, 0.8);
}

.pcr-box {
  width: min(440px, 92vw);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 2rem;
}

.pcr-header {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.pcr-header h3 {
  margin: 0;
  font-size: 1.1rem;
}

.pcr-stars {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.pcr-star {
  width: 2.5rem;
  height: 2.5rem;
}

.pcr-footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

@media (max-width: 1200px) {
  .profile-user-content {
    gap: 3rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

@media (max-width: 900px) {
  .profile-user-hero {
    padding: 5rem 1.5rem 2.5rem;
  }

  .profile-user-content {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  .profile-user-classes .profile-user-classes__grid {
    grid-template-columns: repeat(2, 280px);
    justify-content: center;
  }
}

@media (max-width: 620px) {
  .profile-user-classes .profile-user-classes__grid {
    grid-template-columns: repeat(1, 280px);
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .profile-user-hero {
    padding: 4.5rem 1.25rem 2rem;

    .profile-user-hero__inner {
      flex-direction: column;
      align-items: flex-start;
      gap: 1rem;
    }

    .profile-user-hero__avatar img {
      width: 100px;
      height: 100px;
    }

    .profile-user-hero__stats {
      gap: 1.25rem;
      flex-wrap: wrap;
    }
  }

  .profile-user-content {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

