/* Content 페이지 공통 스타일 */

/* About, Contact, Privacy 페이지의 플레이어 영역 */
.about-player,
.contact-player,
.privacy-player {
    cursor: default;
    position: relative;
    z-index: 1;
}

/* Container가 클릭 가능한 영역임을 나타내는 스타일 */
.container:has(.about-player),
.container:has(.contact-player),
.container:has(.privacy-player) {
    cursor: pointer;
}

/* 플레이어를 문의 폼으로 변환 */
.contact-player {
    /* 기본 플레이어 스타일 유지하면서 높이 조정 */
    height: auto;
    min-height: 580px;
}

/* 입력 필드 스타일 */
.contact-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    color: white !important;
    font-size: inherit;
    font-family: inherit;
    padding: 5px 0;
    outline: none;
    transition: border-color 0.3s;
}

.contact-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.contact-input:focus {
    border-bottom-color: #667eea;
}

/* 제목 입력 필드 */
.player-title.contact-input {
    font-size: 1.2rem !important;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

/* 이메일 입력 필드 */
.player-artist.contact-input {
    font-size: 0.9rem !important;
    text-align: center;
}

/* 문의 내용 textarea 영역 */
.contact-textarea-wrapper {
    padding: 15px;
    cursor: default;
}

.contact-textarea {
    width: 100%;
    height: 100%;
    min-height: 220px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: white !important;
    font-size: 0.9rem !important;
    font-family: inherit;
    padding: 15px;
    outline: none;
    resize: none;
    transition: all 0.3s;
}

.contact-textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.contact-textarea:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

/* 스크롤바 스타일 */
.contact-textarea::-webkit-scrollbar {
    width: 6px;
}

.contact-textarea::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.contact-textarea::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.contact-textarea::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* 메시지 영역 */
.contact-message {
    margin: 15px 0;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 0.85rem;
    text-align: center;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.success-message {
    background: rgba(76, 175, 80, 0.2);
    color: #a5d6a7;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.error-message {
    background: rgba(244, 67, 54, 0.2);
    color: #ef9a9a;
    border: 1px solid rgba(244, 67, 54, 0.3);
}

/* 개인정보 처리방침 동의 영역 */
.privacy-agreement {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-bottom: 12px;
    padding: 5px;
    /* background: rgba(255, 255, 255, 0.05);
    border-radius: 10px; */
}

.privacy-checkbox {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
}

.privacy-checkbox input[type="checkbox"] {
    width: 13px;
    height: 13px;
    cursor: pointer;
    accent-color: #667eea;
}

.checkbox-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
    user-select: none;
    white-space: nowrap;
}

.privacy-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 5px;
    transition: all 0.3s;
    white-space: nowrap;
}

.privacy-link:hover {
    background: rgba(102, 126, 234, 0.2);
    color: #7c8eea;
}

/* 문의하기 버튼 영역 */
.submit-button-wrapper {
    margin-top: 10px;
}

.submit-contact-btn {
    width: 100%;
    padding: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.submit-contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(102, 126, 234, 0.4);
}

.submit-contact-btn:active {
    transform: translateY(0);
    box-shadow: 0 3px 10px rgba(102, 126, 234, 0.3);
}

.submit-contact-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* 이메일 링크 영역 (About, Privacy 페이지용) */
.contact-email {
    cursor: default;
}

.email-link {
    flex: 1;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.85rem;
    text-align: center;
    padding: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    transition: all 0.3s;
    display: block;
}

.email-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #667eea;
    transform: translateY(-2px);
}

/* 폼 제출 중 로딩 효과 */
.contact-player form.submitting .submit-btn {
    pointer-events: none;
    opacity: 0.6;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* 입력 필드 자동완성 스타일 */
.contact-input:-webkit-autofill,
.contact-input:-webkit-autofill:hover,
.contact-input:-webkit-autofill:focus {
    -webkit-text-fill-color: white;
    -webkit-box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.3) inset;
    transition: background-color 5000s ease-in-out 0s;
}

/* 포커스 상태 향상 */
.contact-input:focus,
.contact-textarea:focus {
    animation: focusGlow 0.3s ease-out;
}

@keyframes focusGlow {
    0% {
        box-shadow: 0 0 0 0 rgba(102, 126, 234, 0.4);
    }
    100% {
        box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
    }
}

/* ===========================
   메뉴 버튼 & 레이어 스타일
   =========================== */

/* 메뉴 버튼 - 우측 하단 고정 (main.php가 아닌 경우에만 표시) */
.menu-btn:not(.bottom-nav-btn) {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #725d49 0%, #302a33 100%);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s;
    z-index: 1000;
}

/* main.php 페이지에서는 기존 메뉴 버튼 숨기기 */
body:has(.bottom-nav-bar) .menu-btn:not(.bottom-nav-btn) {
    display: none;
}

.menu-btn span {
    width: 25px;
    height: 3px;
    background: white;
    border-radius: 2px;
    transition: all 0.3s;
}

.menu-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* 메뉴 레이어 - 버튼 바로 위에 표시 */
.menu-layer {
    display: none;
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 180px;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 15px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 999;
    animation: slideUp 0.3s ease-out;
}

/* main.php에서 하단 바 위에 메뉴 레이어 표시 */
body:has(.bottom-nav-bar) .menu-layer {
    bottom: 80px;
    right: calc(50% - 250px + 10px);
    left: auto;
    max-width: 180px;
    width: 180px;
    transform: none;
}

/* 모바일에서 메뉴 레이어 위치 조정 */
@media (max-width: 768px) {
    body:has(.bottom-nav-bar) .menu-layer {
        right: 10px;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-layer.show {
    display: block;
}

/* main.php에서 메뉴 레이어 중앙 정렬 */
body:has(.bottom-nav-bar) .menu-layer.show {
    display: block;
}

.menu-item {
    display: block;
    padding: 12px 20px;
    color: white;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s;
    border-left: 3px solid transparent;
}

.menu-item:hover {
    background: rgba(102, 126, 234, 0.3);
    border-left-color: #667eea;
    padding-left: 25px;
}

.menu-item:active {
    background: rgba(102, 126, 234, 0.5);
}

/* 메뉴 버튼 & 레이어 반응형 */
@media (max-width: 768px) {
    .menu-btn {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
    
    .menu-btn span {
        width: 20px;
    }
    
    .menu-layer {
        bottom: 80px;
        right: 20px;
        width: 160px;
    }
    
    .menu-item {
        padding: 10px 15px;
        font-size: 14px;
    }
    
    .menu-item:hover {
        padding-left: 20px;
    }
    
    /* 모바일에서 브랜딩 바 조정 */
    .branding-bar {
        padding: 0 15px;
        gap: 10px;
    }
    
    .branding-logo {
        width: 28px;
        height: 28px;
    }
    
    .branding-text {
        font-size: 1.2rem;
    }
}

/* ===========================
   About 페이지 스타일
   =========================== */

.about-player .album-art {
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-size: 1rem !important;
    text-align: center;
}

.about-content {
    color: white !important;
    line-height: 1.8;
}

.about-content h3 {
    font-size: 1.3rem !important;
    margin-bottom: 15px;
    color: #7e9ee2 !important;
}

.about-content p {
    margin-bottom: 12px;
    font-size: 0.9rem !important;
    color: white !important;
}

/* ===========================
   Privacy 페이지 스타일
   =========================== */

.privacy-player .album-art {
    padding: 15px;
    overflow-y: auto;
    font-size: 0.85rem !important;
    text-align: left;
    height: 250px;
    display: block;
}

.privacy-content {
    color: white !important;
    line-height: 1.6;
    height: 100%;
}

.privacy-content h3 {
    font-size: 1rem !important;
    margin-top: 15px;
    margin-bottom: 10px;
    color: #7e9ee2 !important;
    font-weight: 600;
}

.privacy-content h3:first-child {
    margin-top: 0;
}

.privacy-content p {
    margin-bottom: 10px;
    font-size: 0.85rem !important;
    color: white !important;
}

.privacy-content ul {
    margin: 10px 0;
    padding-left: 20px;
}

.privacy-content li {
    margin-bottom: 5px;
    font-size: 0.85rem !important;
    color: white !important;
}
