/* 내 기록 페이지 스타일 */
.records-content {
  background-color: var(--bg-card);
  border-radius: var(--border-radius);
  padding: 30px;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--border-color);
  position: relative;
  width: 100%;
  max-width: 900px; /* 원하는 너비로 조정 */
  margin: 0 auto; /* 가운데 정렬 */
}
  
  .page-header {
    text-align: center;
    margin-top: 40px;
    margin-bottom: 40px;
  }
  
  .page-header h1 {
    font-size: 2.5rem;
    color: var(--text-primary);
    margin-bottom: 10px;
    background: linear-gradient(to right, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    display: inline-block;
  }
  
  .page-header p {
    color: var(--text-secondary);
    font-size: 1rem;
  }

  /* 통계 카드 */
  .records-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
  }
  
  .stats-card {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: var(--border-radius);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid var(--border-color);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed);
  }
  
  .stats-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-soft), var(--shadow-neon);
  }
  
  .stats-icon {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 50%;
    background-color: rgba(255, 177, 0, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .stats-icon i {
    font-size: 1.5rem;
    color: var(--accent-primary);
  }
  
  .stats-info h3 {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 5px;
  }
  
  .stats-info p {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
  }
  
  /* 필터 섹션 */
  .records-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
    align-items: flex-end;
  }
  
  .filter-group {
    flex: 1;
    min-width: 200px;
  }
  
  .filter-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.9rem;
  }
  
  .filter-group input,
  .filter-group select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background-color: rgba(0, 0, 0, 0.2);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-speed);
  }
  
  .filter-group input:focus,
  .filter-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(255, 177, 0, 0.3);
  }
  
  .filter-group input::placeholder {
    color: var(--text-tertiary);
  }
  
  .search-input {
    position: relative;
  }
  
  .search-input i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
  }
  
  .filter-btn {
    height: 44px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 20px;
  }
  
  /* 로딩 컨테이너 */
  .loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 50px 0;
  }
  
  .loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(255, 177, 0, 0.3);
    border-radius: 50%;
    border-top-color: var(--accent-primary);
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
  }
  
  @keyframes spin {
    to {
      transform: rotate(360deg);
    }
  }
  
  .loading-container p {
    color: var(--text-secondary);
  }
  
  /* 기록 리스트 */
  .records-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
  }
  
  .record-card {
    animation: none;
    transform: translateZ(0);
    will-change: transform;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: transform var(--transition-speed) ease-out, box-shadow var(--transition-speed);
    cursor: pointer;
  }
  
  .record-card:hover {
    transform: translateY(-5px) translateZ(0);
    box-shadow: var(--shadow-soft), var(--shadow-neon);
  }
  
  .record-thumbnail {
    width: 100%;
    height: 150px;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border-color);
  }
  
  .record-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed);
  }
  
  .record-card:hover .record-thumbnail img {
    transform: scale(1.05);
  }
  
  .record-grade {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 700;
    font-size: 1.2rem;
  }
  
  .record-details {
    padding: 15px;
  }
  
  .record-song {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  
  .record-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
  }
  
  .record-difficulty {
    display: inline-flex;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
  }
  
  .difficulty-badge {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 5px;
  }
  
  .difficulty-NM {
    background-color: rgba(116, 209, 80, 0.2);
    color: #74d150;
  }
  
  .difficulty-HD {
    background-color: rgba(87, 138, 255, 0.2);
    color: #578aff;
  }
  
  .difficulty-SHD {
    background-color: rgba(255, 152, 48, 0.2);
    color: #ff9830;
  }
  
  .difficulty-EX {
    background-color: rgba(255, 61, 61, 0.2);
    color: #ff3d3d;
  }
  
  .record-date {
    font-size: 0.85rem;
    color: var(--text-tertiary);
  }
  
  .record-score {
    font-weight: 600;
    color: var(--accent-primary);
    font-size: 1.2rem;
    margin-top: 5px;
  }

  /* 모드 이름 스타일 */
.mode-name {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-left: 8px;
  display: inline-block;
}
  
  /* 페이지네이션 */
  .records-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
  }
  
  .pagination-btn {
    background-color: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 8px 15px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all var(--transition-speed);
    cursor: pointer;
  }
  
  .pagination-btn:hover:not(:disabled) {
    background-color: rgba(255, 177, 0, 0.1);
    color: var(--accent-primary);
  }
  
  .pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }
  
  .pagination-info {
    color: var(--text-secondary);
    font-size: 0.9rem;
  }
  
  /* 결과 없음 메시지 */
  .no-results, .no-records {
    text-align: center;
    padding: 50px 0;
    color: var(--text-secondary);
  }
  
  .no-results i, .no-records i {
    font-size: 3rem;
    color: var(--text-tertiary);
    margin-bottom: 20px;
  }
  
  .no-results p, .no-records h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
  }
  
  .no-results .sub-text {
    font-size: 0.9rem;
    color: var(--text-tertiary);
  }
  
  .no-records p {
    color: var(--text-tertiary);
    margin-bottom: 20px;
  }
  
  .no-records .btn {
    margin-top: 10px;
  }
  
  /* 인증 필요 메시지 */
  .auth-required {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
    border-radius: var(--border-radius);
  }
  
  .auth-message {
    text-align: center;
    padding: 40px;
    background-color: var(--bg-card);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    max-width: 400px;
  }
  
  .auth-message i {
    font-size: 3rem;
    color: var(--accent-primary);
    margin-bottom: 20px;
  }
  
  .auth-message h2 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin-bottom: 15px;
  }
  
  .auth-message p {
    color: var(--text-secondary);
    margin-bottom: 20px;
  }
  
  /* 모달 */
  .record-modal, .confirm-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
  }
  
  .record-modal.show, .confirm-modal.show {
    opacity: 1;
    visibility: visible;
  }
  
  .modal-content {
    background-color: var(--bg-card);
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    animation: modalIn 0.3s ease-out;
  }
  
  .confirm-modal .modal-content {
    max-width: 500px;
  }
  
  @keyframes modalIn {
    from {
      opacity: 0;
      transform: translateY(30px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
  }
  
  .modal-header h2 {
    font-size: 1.5rem;
    color: var(--text-primary);
    margin: 0;
  }
  
  .modal-close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color var(--transition-speed);
  }
  
  .modal-close-btn:hover {
    color: var(--accent-primary);
  }
  
  .modal-body {
    padding: 20px;
  }
  
  /* 기록 상세 정보 */
  .record-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
  }
  
  .record-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
  
  .info-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
  }
  
  .info-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
  }
  
  .info-value {
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 500;
  }
  
  .info-value.score {
    color: var(--accent-primary);
    font-size: 1.3rem;
  }
  
  .info-value.grade {
    font-size: 1.4rem;
    font-weight: 700;
  }
  
  /* 기록 이미지 */
  .record-image {
    border-radius: var(--border-radius);
    overflow: hidden;
    border: 1px solid var(--border-color);
  }
  
  .record-image img {
    width: 100%;
    height: auto;
    display: block;
  }
  
  /* 기록 액션 버튼 */
  .record-actions {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
  }
  
  /* 삭제 확인 모달 */
  .confirm-modal .modal-body {
    text-align: center;
    padding: 30px 20px;
  }
  
  .confirm-modal p {
    color: var(--text-secondary);
    margin-bottom: 10px;
    font-size: 1.1rem;
  }
  
  .confirm-modal .warning {
    color: #ff3d3d;
    font-size: 0.9rem;
    margin-bottom: 30px;
  }
  
  .confirm-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
  }
  
  .btn-danger {
    background-color: #ff3d3d;
    color: white;
  }
  
  .btn-danger:hover {
    background-color: #e03131;
  }
  
  /* 등급 색상 */
  .grade-S\+\+\+\+ {
    color: white;
  }  
  
  .grade-S\+\+\+ {
    color: #ffd700;
  }
  
  .grade-S\+\+ {
    color: #A9A9A9;
  }
  
  .grade-S\+ {
    color: #f4a460;
  }
  
  .grade-S {
    color: #E0E0E0;
  }
  
  .grade-A\+ {
    color: #ffc400;
  }

  .grade-A {
    color: #ffc400;
  }

  .grade-B {
    color: #ffc400;
  }

  .grade-C {
    color: #ffc400;
  }
  
  .grade-D {
    color: #ffc400;
  }

  .grade-E {
    color: #ffc400;
  }

  .grade-F {
    color: #ffc400;
  }
  
  /* 스크롤바 스타일 */
  .modal-content::-webkit-scrollbar {
    width: 8px;
  }
  
  .modal-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
  }
  
  .modal-content::-webkit-scrollbar-thumb {
    background-color: var(--accent-primary);
    border-radius: 4px;
  }

  /* 점수와 모드 이름 컨테이너 */
.score-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 5px;
}

.record-score {
  font-weight: 600;
  color: var(--accent-primary);
  font-size: 1.2rem;
}

.record-mode {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-left: auto; /* 오른쪽 정렬 */
}

/* 선택된 옵션이 보이지 않는 경우 색상 명확히 지정 */
.filter-group select option {
    background-color: var(--bg-card);
    color: var(--text-primary);
}

/* 선택 시 가독성을 위해 색상 유지 */
.filter-group select:focus,
.filter-group select:hover {
    background-color: rgba(0, 0, 0, 0.3);
    color: var(--text-primary);
}
  
  /* 반응형 디자인 */
  @media (max-width: 768px) {
    .records-container {
      margin: 20px auto;
    }
    
    .page-header h1 {
      font-size: 2rem;
    }
    
    .records-content {
      padding: 20px 15px;
    }
    
    .records-stats {
      grid-template-columns: 1fr 1fr;
    }
    
    .records-filters {
      flex-direction: column;
      gap: 15px;
    }
    
    .filter-group {
      width: 100%;
    }
    
    .filter-btn {
      width: 100%;
    }
    
    .records-list {
      grid-template-columns: 1fr;
    }
    
    .record-details {
      grid-template-columns: 1fr;
    }
    
    .record-actions {
      flex-direction: column;
    }
    
    .record-actions .btn {
      width: 100%;
    }
    
    .pagination-btn {
      padding: 8px 10px;
      font-size: 0.8rem;
    }
  }
  
  /* 애니메이션 */
  @keyframes fadeIn {
    from {
      opacity: 0;
      transform: translateY(20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .record-card {
    animation: fadeIn 0.3s ease-in-out;
  }
  
  .stats-card:nth-child(1) {
    animation: fadeIn 0.2s ease-in-out;
  }
  
  .stats-card:nth-child(2) {
    animation: fadeIn 0.3s ease-in-out;
  }
  
  .stats-card:nth-child(3) {
    animation: fadeIn 0.4s ease-in-out;
  }
  
  .stats-card:nth-child(4) {
    animation: fadeIn 0.5s ease-in-out;
  }
  
  .hidden {
    display: none !important;
  }
