/* 移动端carousel优化样式 */

/* 针对小屏幕设备的优化 */
@media (max-width: 768px) {
  .career-carousel {
    width: 100%;
    height: 2.5rem;
    padding: 0 ;
    box-sizing: border-box;
  }
  
  .carousel-container {
    width: calc(100% - 4rem);
    max-width: none;
    height: auto;
    overflow: visible;
    margin: 0 auto;
  }
  
  .carousel-arrow {
    top: 50%;
    /* transform: translateY(-50%); */
    z-index: 10;
    width: 30px;
    height: 30px;
  }
  
  .carousel-arrow-left {
    left: 0;
  }
  
  .carousel-arrow-right {
    right: 0;
  }
  
  .carousel-arrow img {
    width: 100%;
    height: auto;
  }
  
  .carousel-track {
    display: flex;
    gap: 15px;
    transform: translateX(0);
    justify-content: center;
    align-items: flex-end; /* 底部对齐 */
  }
  
  .student-card {
    position: relative;
    width: 70px;
    height: 100px;
    flex-shrink: 0;
    transition: all 0.3s ease;
    transform: scale(0.8);
  }
  
  .student-card-active {
    width: 90px;
    height: 125px;
    top: 0;
    transform: scale(1);
    z-index: 5;
  }
  
  .card-border {
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    border-radius: 6px;
  }
  
  .card-border-active {
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;

  }
  
  .card-image {
    width: 100%;
    height: 80%;
    border-radius: 4px;
    overflow: hidden;
  }
  
  .student-card-active .card-image {
    width: 100%;
    height: 80%;
  }
  
  .image-bg {
    width: 100%;
    height: 100%;
    border-radius: 4px;
  }
  
  .card-image img {
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    object-fit: cover;
    border-radius: 4px;
  }
  
  .student-card-active .card-image img {
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
  }
  
  .card-name {
    position: absolute;
    left: 50%;
    bottom: 0px;
    transform: translateX(-50%);
    font-size: 12px;
    white-space: nowrap;
  }
  
  .student-card-active .card-name {
    left: 50%;
    bottom: 0px;
    transform: translateX(-50%);
    font-size: 14px;
  }
}

/* 针对更小屏幕设备的优化 */
@media (max-width: 480px) {
  .career-carousel {
    padding: 0;
  }
  
  .carousel-track {
    gap: 10px;
    align-items: flex-end; /* 底部对齐 */
  }
  
  .student-card {
    width: 60px;
    height: 85px;
    transform: scale(0.7);
  }
  
  .student-card-active {
    width: 75px;
    height: 105px;
    transform: scale(0.9);
  }
  
  .card-name {
    font-size: 10px;
  }
  
  .student-card-active .card-name {
    font-size: 12px;
  }
}

/* 修复移动端点击区域过小的问题 */
@media (max-width: 768px) {
  .carousel-arrow {
    width: 20px;
    height: 20px;

  }
  
  /* 增加触摸区域 */
  .carousel-arrow::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50px;
    height: 50px;
  }
}

/* 修复移动端滑动问题 */
@media (max-width: 768px) {
  .carousel-container {
    touch-action: pan-x;
  }
  
  .student-card {
    cursor: pointer;
    user-select: none;
  }
}

/* 视频模态框移动端优化 */
@media (max-width: 768px) {
  .video-modal-content {
    width: 95%;
    max-width: 95%;
    margin: 10px;
  }
  
  .video-modal-header {
    padding: 12px 15px;
  }
  
  .video-modal-title {
    font-size: 16px;
  }
  
  .video-modal-body {
    padding: 15px;
  }
  
  .video-modal-body video {
    max-height: 60vh;
  }
}

@media (max-width: 480px) {
  .video-modal-content {
    width: 98%;
    max-width: 98%;
  }
  
  .video-modal-header {
    padding: 10px 12px;
  }
  
  .video-modal-title {
    font-size: 14px;
  }
  
  .video-modal-close {
    font-size: 20px;
    width: 25px;
    height: 25px;
  }
  
  .video-modal-body {
    padding: 10px;
  }
  
  .video-modal-body video {
    max-height: 50vh;
  }
}