@use '../variables' as *;

/* ==================== 移动端首页样式 ==================== */
.home-mobile {
  position: relative;
  width: 100%;
  margin: 0 auto;
  background: #FFFFFF;
  font-size: 0.14rem;
  padding-bottom: 0.94rem; /* 底部固定按钮的高度 */
  overflow-x: hidden;

  /* 背景装饰色块 */
  &__orb {
    position: absolute;
    pointer-events: none;

    &--top {
      width: 5.40rem;
      height: 3.00rem;
      left: -0.80rem;
      top: -1.20rem;
      background: rgba(183, 237, 233, 0.58);
      opacity: 0.5;
      filter: blur(0.35rem);
    }

    &--hero {
      width: 3.00rem;
      height: 2.20rem;
      left: 0.64rem;
      top: 2.10rem;
      background: #EAF8F7;
      opacity: 0.55;
      filter: blur(0.275rem);
    }
  }

  /* 顶部 Logo */
  &__header {
    position: relative;
    padding: 0.16rem 0.20rem;
    z-index: 1;
  }

  &__logo {
    width: 0.95rem;
    height: 0.23rem;
    object-fit: contain;
  }

  /* Hero 区域 */
  &__hero {
    position: relative;
    padding: 0.30rem 0.24rem 0;
    z-index: 1;
  }

  &__eyebrow {
    font-weight: 700;
    font-size: 0.12rem;
    line-height: 0.15rem;
    color: #42A8B3;
    margin-bottom: 0.10rem;
  }

  &__headline {
    font-weight: 700;
    font-size: 0.38rem;
    line-height: 0.46rem;
    color: #12383A;
    margin-bottom: 0.32rem;
  }

  &__subtitle {
    font-weight: 400;
    font-size: 0.14rem;
    line-height: 0.17rem;
    color: #687074;
  }

  /* 指令卡片 */
  &__command-card {
    position: relative;
    width: 3.42rem;
    margin: 0.40rem auto 0;
    padding: 0.29rem 0.24rem 0.28rem;
    background: #12383A;
    box-shadow: 0px 0.16rem 0.28rem rgba(79, 194, 201, 0.16);
    border-radius: 0.18rem;
    z-index: 1;
  }

  &__command-title {
    font-weight: 700;
    font-size: 0.16rem;
    line-height: 0.19rem;
    color: #FFFFFF;
    margin-bottom: 0.11rem;
  }

  &__command-sub {
    font-weight: 400;
    font-size: 0.12rem;
    line-height: 0.15rem;
    color: #B7EDE9;
    margin-bottom: 0.24rem;
  }

  &__progress {
    margin-bottom: 0.18rem;
  }

  &__progress-rail {
    width: 100%;
    height: 0.08rem;
    background: #0F2F32;
    border-radius: 0.05rem;
    overflow: hidden;
  }

  &__progress-fill {
    width: 74%;
    height: 0.08rem;
    background: #4FC2C9;
    border-radius: 0.05rem;
  }

  &__command-chips {
    font-weight: 700;
    font-size: 0.11rem;
    line-height: 0.13rem;
    color: #FFFFFF;
  }

  /* 数据统计卡片 */
  &__stats-card {
    position: relative;
    width: 3.42rem;
    margin: 0.23rem auto 0;
    padding: 0.30rem 0.20rem;
    background: #FFFFFF;
    box-shadow: 0px 0.12rem 0.22rem rgba(17, 17, 17, 0.07);
    border-radius: 0.18rem;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1;
  }

  &__stat {
    text-align: center;
  }

  &__stat-num {
    display: block;
    font-weight: 700;
    font-size: 0.28rem;
    line-height: 0.34rem;
    color: #2A8186;
    margin-bottom: 0.04rem;
  }

  &__stat-label {
    font-weight: 400;
    font-size: 0.11rem;
    line-height: 0.13rem;
    color: #8D9399;
  }

  /* 功能介绍区 */
  &__functions {
    position: relative;
    padding: 0.60rem 0.24rem 0;
    z-index: 1;
  }

  &__section-title {
    font-weight: 700;
    font-size: 0.24rem;
    line-height: 0.29rem;
    color: #111111;
    margin-bottom: 0.09rem;
  }

  &__section-sub {
    font-weight: 400;
    font-size: 0.13rem;
    line-height: 0.16rem;
    color: #687074;
    margin-bottom: 0.26rem;
  }

  &__feature-list {
    display: flex;
    flex-direction: column;
    gap: 0.20rem;
  }

  &__feature-card {
    width: 100%;
    padding: 0.22rem 0.20rem;
    background: #FFFFFF;
    box-shadow: 0px 0.10rem 0.18rem rgba(17, 17, 17, 0.06);
    border-radius: 0.18rem;
    display: flex;
    align-items: center;
    gap: 0.18rem;
  }

  &__feature-icon {
    width: 0.42rem;
    height: 0.42rem;
    border-radius: 0.12rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;

    span {
      font-size: 0.20rem;
    }
  }

  &__feature-text {
    h3 {
      font-weight: 700;
      font-size: 0.17rem;
      line-height: 0.21rem;
      color: #111111;
      margin-bottom: 0.06rem;
    }

    p {
      font-weight: 400;
      font-size: 0.12rem;
      line-height: 0.15rem;
      color: #687074;
    }
  }

  /* 每天都有新机会 */
  &__jobs-section {
    position: relative;
    margin-top: 0.50rem;
    padding: 0.40rem 0.24rem;
    background: #DDF4F2;
    z-index: 1;
  }

  &__job-chips {
    display: flex;
    flex-direction: column;
    gap: 0.16rem;
  }

  &__job-chip {
    padding: 0.14rem 0.20rem;
    border-radius: 0.14rem;

    &--dark {
      width: 100%;
      background: #12383A;

      .home-mobile__job-chip-company {
        font-weight: 700;
        font-size: 0.12rem;
        line-height: 0.15rem;
        color: #4FC2C9;
      }

      .home-mobile__job-chip-role {
        font-weight: 400;
        font-size: 0.13rem;
        line-height: 0.16rem;
        color: #FFFFFF;
      }
    }

    &--light {
      flex: 1;
      background: #FFFFFF;
      box-shadow: 0px 0.08rem 0.16rem rgba(17, 17, 17, 0.06);

      .home-mobile__job-chip-company {
        font-weight: 700;
        font-size: 0.12rem;
        line-height: 0.15rem;
        color: #42A8B3;
      }

      .home-mobile__job-chip-role {
        font-weight: 400;
        font-size: 0.12rem;
        line-height: 0.15rem;
        color: #111111;
      }
    }
  }

  &__job-chip-company,
  &__job-chip-role {
    display: block;
  }

  &__job-chip-company {
    margin-bottom: 0.04rem;
  }

  &__job-chip-row {
    display: flex;
    gap: 0.16rem;
  }

  /* 万千毕业生的信赖之选 */
  &__proof {
    position: relative;
    padding: 0.50rem 0.24rem 0;
    z-index: 1;
  }

  &__quote-card {
    width: 100%;
    padding: 0.30rem 0.24rem;
    background: #12383A;
    border-radius: 0.18rem;
    margin-top: 0.20rem;
  }

  &__quote-text {
    font-weight: 700;
    font-size: 0.15rem;
    line-height: 0.18rem;
    color: #FFFFFF;
    margin-bottom: 0.24rem;
  }

  &__quote-author {
    display: flex;
    align-items: center;
    gap: 0.14rem;
  }

  &__quote-avatar {
    width: 0.38rem;
    height: 0.38rem;
    //background: #D9E3EA;
    border-radius: 50%;
    flex-shrink: 0;
  }

  &__quote-info {
    display: flex;
    flex-direction: column;
    gap: 0.04rem;
  }

  &__quote-name {
    font-weight: 400;
    font-size: 0.12rem;
    line-height: 0.15rem;
    color: #B7EDE9;
  }

  &__quote-school {
    font-weight: 400;
    font-size: 0.12rem;
    line-height: 0.15rem;
    color: #B7EDE9;
  }

  /* 常见问题 */
  &__faq {
    position: relative;
    padding: 0.50rem 0.24rem 0;
    z-index: 1;
  }

  &__faq-list {
    margin-top: 0.20rem;
    display: flex;
    flex-direction: column;
    gap: 0.14rem;
  }

  &__faq-item {
    width: 100%;
    background: #FFFFFF;
    box-shadow: 0px 0.08rem 0.16rem rgba(17, 17, 17, 0.06);
    border-radius: 0.14rem;
    overflow: hidden;
  }

  &__faq-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.18rem 0.20rem;
    cursor: pointer;

    span:first-child {
      font-weight: 700;
      font-size: 0.14rem;
      line-height: 0.17rem;
      color: #111111;
    }
  }

  &__faq-icon {
    font-weight: 700;
    font-size: 0.18rem;
    line-height: 0.22rem;
    color: #111111;
    flex-shrink: 0;
  }

  &__faq-answer {
    padding: 0 0.20rem 0.18rem;

    p {
      font-size: 0.12rem;
      line-height: 0.18rem;
      color: #687074;
    }
  }

  /* 底部 CTA */
  &__bottom-cta {
    position: relative;
    margin-top: 0.50rem;
    padding: 0.40rem 0.24rem;
    background: #12383A;
    z-index: 1;

    h2 {
      font-weight: 700;
      font-size: 0.26rem;
      line-height: 0.31rem;
      color: #FFFFFF;
      margin-bottom: 0.12rem;
    }

    p {
      font-weight: 400;
      font-size: 0.13rem;
      line-height: 0.16rem;
      color: #9AA0A6;
      margin-bottom: 0.32rem;
    }
  }

  &__bottom-footer {
    font-weight: 700;
    font-size: 0.13rem;
    line-height: 0.16rem;
    color: #4FC2C9;
  }

  /* 固定底部按钮 */
  &__fixed-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0.12rem 0.24rem;
    padding-bottom: calc(0.12rem + env(safe-area-inset-bottom, 0px));
    background: #FFFFFF;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  &__pc-hint {
    font-weight: 400;
    font-size: 0.12rem;
    line-height: 0.15rem;
    color: #2A8186;
    margin-bottom: 0.06rem;
  }

  &__cta-btn {
    width: calc(100% - 0.48rem);
    max-width: 3.42rem;
    height: 0.54rem;
    background: #4FC2C9;
    box-shadow: 0px 0.10rem 0.24rem rgba(0, 0, 0, 0.18);
    border-radius: 0.27rem;
    border: none;
    font-weight: 700;
    font-size: 0.16rem;
    line-height: 0.19rem;
    color: #FFFFFF;
    cursor: pointer;

    &:active {
      opacity: 0.85;
    }
  }

  /* 弹窗遮罩 */
  &__overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 200;
    display: flex;
    align-items: flex-end;
    justify-content: center;
  }

  /* 弹窗内容 */
  &__dialog {
    width: 100%;
    max-width: 100%;
    background: #FFFFFF;
    border-radius: 0.24rem;
    padding: 0.16rem 0.20rem 0.2rem 0.2rem;
    position: relative;
    text-align: center;
    margin: 0 0.16rem 0.24rem 0.16rem;
  }

  &__dialog-handle {
    width: 0.60rem;
    height: 0.04rem;
    background: #DDF4F2;
    border-radius: 0.02rem;
    margin: 0 auto 0.20rem;
  }

  &__dialog-close {
    position: absolute;
    top: 0.16rem;
    right: 0.20rem;
    font-size: 0.24rem;
    color: #42A8B3;
    background: none;
    border: none;
    cursor: pointer;
    line-height: 1;
  }

  &__dialog h3 {
    font-weight: 700;
    font-size: 0.22rem;
    line-height: 0.28rem;
    color: #111111;
    margin-bottom: 0.14rem;
    text-align: left;
  }

  &__dialog-desc {
    font-weight: 400;
    font-size: 0.13rem;
    line-height: 0.20rem;
    color: #687074;
    margin-bottom: 0.20rem;
    text-align: left;
  }

  &__dialog-url {
    width: 100%;
    padding: 0.14rem 0.16rem;
    background: #EAF8F7;
    border-radius: 0.12rem;
    font-weight: 400;
    font-size: 0.14rem;
    color: #111111;
    text-align: left;
    margin-bottom: 0.24rem;
  }

  &__dialog-qr-title {
    font-weight: 700;
    font-size: 0.14rem;
    color: #111111;
    text-align: left;
    margin-bottom: 0.14rem;
  }

  &__dialog-qr {
    width: 2.00rem;
    height: 2.00rem;
    margin: 0 auto 0.12rem;
    border-radius: 0.08rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #EAF8F7;
    -webkit-touch-callout: default;
    user-select: none;
  }

  &__dialog-qr-img {
    width: 1.60rem;
    height: 1.60rem;
    object-fit: contain;
  }

  &__dialog-qr-hint {
    font-size: 0.11rem;
    color: #8D9399;
    margin-bottom: 0.14rem;
  }

  &__dialog-btn {
    width: 100%;
    height: 0.50rem;
    background: #4FC2C9;
    border-radius: 0.25rem;
    border: none;
    font-weight: 700;
    font-size: 0.16rem;
    color: #FFFFFF;
    cursor: pointer;

    &:active {
      opacity: 0.85;
    }
  }

  /* 保存成功提示 toast */
  &__toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.75);
    color: #FFFFFF;
    font-size: 0.14rem;
    padding: 0.12rem 0.24rem;
    border-radius: 0.08rem;
    z-index: 300;
    pointer-events: none;
    animation: toastFadeIn 0.2s ease;
  }
}

@keyframes toastFadeIn {
  from { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
  to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
