/* 기본 초기화 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* 메인 컨테이너 */
main {
  /* 화면 전체 높이 확보 */
  min-height: 100vh;
  /* 상하좌우 여백 */

  margin: 100px auto;
  /* 공통 너비 변수 설정 (top/bottom 동일 폭 유지) */
  --detail-width: min(1200px, 92vw);
}

/* PC 버전 */
@media (min-width: 769px) {


  .playerdetail {

    margin-top: 70px;

  }

  /* 상단: 사진 + 카드 */
  .playerdetail_top {
    display: flex;
    align-items: center;
    /* 사진 중앙과 카드 중앙 맞춤 */
    justify-content: center;
    gap: 160px;
    /* 사진-카드 간격 */
    margin-bottom: 100px;
    width: var(--detail-width);
    margin-left: auto;
    margin-right: auto;
    /* background-color: bisque; 확인용, 나중에 삭제 가능 */
  }

  /* 선수 사진 영역 */
  /* .playerpicture {
    flex: 0 0 clamp(260px, 35%, 400px); /* 화면 크기에 따라 유연하게 
    max-width: 400px;
    margin-right: 20px;
    background-color: red;
  }

  .playerpicture img {
    width: 100%;
    height: auto;
    border: 3px solid black;
  } */


  .playerpicture {
    flex: 0 0 clamp(260px, 35%, 500px);
    max-width: 500px;
    margin-right: 20px;
    /* background-color: red; */

    /* ✅ 비율 고정 (예: 4:5 비율) */
    aspect-ratio: 4 / 5;

    /* 내부 이미지가 비율에 맞게 채워지도록 */
    overflow: hidden;
  }

  .playerpicture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* 이미지가 꽉 차도록, 잘릴 수 있음 */
    border: 3px solid black;
  }




  /* 선수 소개 하단 영역 */
  .playerdetail_bottom {
    width: var(--detail-width);
    margin-left: auto;
    margin-right: auto;
    /* background-color: aquamarine; 확인용, 나중에 삭제 가능 */
    text-align: justify;
  }

  .playerdetail_bottom table {
    border-collapse: collapse;
    /* 테두리 겹침 제거 */
    border: none;
    /* 테이블 자체 테두리 제거 */
    width: 100%;
  }

  .playerdetail_bottom table td {
    border: none;
    /* 각 셀 테두리 제거 */
    padding: 10px 0;
    /* 위아래 여백 */
  }

  td.brief {
    font-weight: bold;
    font-size: 40px;
    padding-bottom: 30px;
  }

  td.detailed {
    font-size: 25px;
    /* background-color: red; */
  }

  /* 선수 카드 스타일 */
  .playercard {
    max-width: 560px;
  }

  .meta-top {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 8px;
  }

  .number {
    font-size: 65px;
    font-weight: 700;
    color: #666;
    line-height: 1;
  }

  .position {
    font-size: 32px;
    font-weight: 700;
    color: blue;
    /* 포지션 색상 */
  }

  .hand {
    font-size: 32px;
    color: #888;
  }

  .player-name {
    font-size: 80px;
    font-weight: 800;
    margin: 8px 0 40px;
    /* 이름 아래 여백 늘림 */
    line-height: 1.1;
  }

  .meta-line {
    color: #888;
    font-size: 28px;
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .meta-line .dot {
    margin: 0 4px;
  }

  .meta-sub {
    color: #9a9a9a;
    font-size: 28px;
    margin-top: 6px;
  }

}

/* 모바일 버전 */
/* 모바일 버전 */
@media (max-width: 768px) {

  main {
    margin: 60px auto;
    /* 상하 여백 줄이기 */
    /* padding: 0 4vw; */
    /* 좌우 약간의 여백 */
  }

  /* 사진 + 카드 세로 정렬 */
  .playerdetail_top {
    display: flex;
    flex-direction: column;
    /* 세로로 쌓이게 */
    align-items: center;
    /* 가운데 정렬 */
    gap: 30px;
    /* 사진과 카드 간 간격 */
    width: 100%;
    margin-bottom: 30px;
  }

  /* .playerpicture {
    width: 80%;
    /* 화면 폭에 맞게 
    max-width: 350px;
    margin-right: 0;
  }

  .playerpicture img {
    width: 100%;
    height: auto;
    border: 2px solid black;
  } */

  .playerpicture {
    margin-top: 50px;
    width: 60%;
    max-width: 350px;
    margin-right: 0;

    /* ✅ 비율 고정 (예: 4:5 인물 비율) */
    aspect-ratio: 4 / 5;

    /* 비율 유지하면서 넘치는 부분 숨김 */
    overflow: hidden;

  }

  .playerpicture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* 비율 유지하며 꽉 채우기 */
    border: 2px solid black;
  }




  .playercard {
    width: 90%;
    text-align: center;
    /* 텍스트 중앙 정렬 */
  }

  .meta-top {
    justify-content: center;
    gap: 8px;
    margin-bottom: 6px;
  }

  .number {
    font-size: 38px;
  }

  .position {
    font-size: 22px;
    color: blue;
  }

  .hand {
    font-size: 22px;
    color: #888;
  }

  .player-name {
    font-size: 40px;
    margin: 4px 0 24px;
    line-height: 1.2;
  }

  .meta-line {
    font-size: 18px;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    color: #777;
  }

  .meta-line .dot {
    margin: 0 2px;
  }

  .meta-sub {
    font-size: 17px;
    color: #999;
    margin-top: 4px;
  }

  /* 하단 설명 영역 */
  .playerdetail_bottom {
    width: 95%;
    margin: 0 auto;
  }

  .playerdetail_bottom table {
    width: 100%;
  }

  td.brief {
    font-size: 28px;
    padding-bottom: 20px;
    font-weight: bold;
    text-align: center;
  }

  td.detailed {
    font-size: 18px;

  }
}