:root {
    /* 💖 귀엽고 발랄한 코랄 핑크 메인 컬러 */
    --primary: #FF6B81; 
    --primary-glow: rgba(255, 107, 129, 0.3);
    --primary-light: #FFE3E7;
    
    /* ☁️ 포근한 느낌의 배경색 */
    --bg-base: #FFF9FA; 
    --bg-panel: #FFFFFF;
    
    /* 🖋️ 부드러운 텍스트 색상 */
    --text-main: #2D3436;
    --text-muted: #8395A7;
    
    /* 📦 테두리 및 배경 */
    --border-light: #F1F2F6;
    --ad-bg: #F8F9FA;
}

body {
    margin: 0; padding: 0; 
    background-color: var(--bg-base); color: var(--text-main); 
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif; 
    overflow-x: hidden; display: flex; flex-direction: column; min-height: 100vh;
}

/* =========================================
   1. 헤더 & 네비게이션
========================================= */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 4%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 2px solid var(--border-light);
    gap: 20px;
    
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    box-sizing: border-box;
    z-index: 1000; 
}

.logo { 
    display: flex; 
    align-items: center; 
    text-decoration: none; 
    cursor: pointer;
    margin-left: 20px; 
}

.logo-img {
    height: 50px; 
    width: auto;
    display: block;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.logo:hover .logo-img {
    transform: scale(1.05); 
}

.main-nav { 
    display: flex; 
    gap: 8px; 
    align-items: center;
    white-space: nowrap;
}

/* 🔥 .nav-item이 버튼(<button>)으로 바뀌었으므로 버튼 속성을 초기화해 줍니다! */
.nav-item {
    background: transparent;
    border: none;
    font-family: inherit;
    color: var(--text-main); 
    text-decoration: none; 
    font-size: 1.05rem; 
    font-weight: 800;
    padding: 10px 18px; 
    border-radius: 20px; 
    transition: all 0.25s ease; 
    cursor: pointer;
    letter-spacing: -0.3px;
    outline: none;
}

.nav-item:hover { 
    background: var(--primary-light); 
    color: var(--primary); 
    transform: translateY(-2px);
}

.nav-item.active { 
    background: var(--primary); 
    color: white; 
    box-shadow: 0 4px 12px var(--primary-glow); 
}

/* 🌟 서브메뉴(드롭다운) 애니메이션 스타일 영역 */
.nav-dropdown-container {
    position: relative;
    display: inline-block;
}

.nav-submenu {
    position: absolute;
    top: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: #FFFFFF;
    border: 2px solid var(--border-light);
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    padding: 10px 0;
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    text-align: center;
    display: flex;
    flex-direction: column;
}

/* 마우스를 올리면 스르륵 나타남 */
.nav-dropdown-container:hover .nav-submenu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* 마우스가 서브메뉴로 내려가는 동안 메뉴가 닫히지 않게 투명 다리 추가 */
.nav-dropdown-container::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 0;
    width: 100%;
    height: 20px;
    background: transparent;
}

.nav-submenu a {
    display: block;
    padding: 10px 20px;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    transition: 0.2s;
}

.nav-submenu a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

/* 검색창 (메인 중앙용으로 변경됨) */
.search-bar {
    position: relative;
    width: 100%;
    max-width: 600px;
    margin: 25px auto 0 auto; /* 상단 여백을 주고 화면 가운데 정렬 */
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    pointer-events: none;
    z-index: 2;
}

.search-bar input { 
    width: 100%; 
    padding: 12px 20px 12px 48px;
    border-radius: 30px; 
    background: #FFFFFF; 
    border: 2px solid var(--primary); 
    color: var(--text-main); 
    font-size: 0.95rem; 
    font-weight: 600;
    outline: none; 
    box-sizing: border-box;
    box-shadow: 0 0 18px rgba(255, 107, 129, 0.45);
    transition: all 0.3s ease; 
    font-family: inherit;
}

.search-bar input:focus { 
    border-color: #FF4757; 
    box-shadow: 0 0 25px rgba(255, 107, 129, 0.7); 
    transform: translateY(-1px);
}

.search-bar input::placeholder { 
    color: #A4B0BE; 
    font-weight: 500;
}

.header-right { 
    display: flex; 
    align-items: center; 
    white-space: nowrap; 
}

.btn-login {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 25px;
    font-weight: 800;
    font-size: 1rem;
    cursor: pointer;
    box-shadow: 0 4px 12px var(--primary-glow);
    transition: all 0.2s ease;
    font-family: inherit;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px var(--primary-glow);
}

/* =========================================
   2. 메인 컨텐츠 & 리스트
========================================= */
main { 
    flex: 1; 
    padding: 120px 5% 50px 5%; 
    margin-bottom: 150px; 
    display: flex; 
    flex-direction: column; 
    align-items: center;
}

.hero { text-align: center; margin-bottom: 40px; width: 100%; max-width: 800px;}
.hero h1 { font-size: clamp(2rem, 4vw, 2.8rem); font-weight: 900; margin-bottom: 15px; color: var(--text-main); letter-spacing: -0.5px; }
.hero h1 span { color: var(--primary); }
.seo-text { font-size: 1rem; color: var(--text-muted); line-height: 1.6; margin-bottom: 20px; word-break: keep-all;}

.sub-categories { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 30px; width: 100%; max-width: 900px;}
.category-btn { 
    background: white; border: 1px solid var(--border-light); color: var(--text-muted); 
    padding: 10px 20px; border-radius: 30px; font-weight: 700; cursor: pointer; transition: all 0.3s; font-size: 0.95rem; font-family: inherit;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02); display: flex; align-items: center; gap: 6px;
}
.category-btn:hover { border-color: var(--primary); color: var(--primary); transform: translateY(-2px); }
.category-btn.active { background: var(--primary); border-color: var(--primary); color: white; box-shadow: 0 4px 15px var(--primary-glow); }

.track-list-wrapper { width: 100%; max-width: 1000px; overflow-x: auto; margin-bottom: 20px; padding-bottom: 10px;}
.track-list-table { width: 100%; min-width: 800px; border-collapse: separate; border-spacing: 0 12px; text-align: left; }

.track-list-header { color: var(--text-muted); font-size: 0.9rem; font-weight: 600;}
.track-list-header th { padding: 0 15px 10px 15px; font-weight: 600; }

.track-item-row { background: var(--bg-panel); transition: all 0.3s ease; box-shadow: 0 4px 15px rgba(0,0,0,0.03); }
.track-item-row td:first-child { border-radius: 16px 0 0 16px; }
.track-item-row td:last-child { border-radius: 0 16px 16px 0; }
.track-item-row:hover { transform: translateY(-3px); box-shadow: 0 8px 25px rgba(255, 107, 129, 0.15); border-color: var(--primary-light);}
.track-item-row.playing { border: 2px solid var(--primary); background: #FFFDFD; box-shadow: 0 8px 25px var(--primary-glow); }
.track-item-row td { padding: 16px 15px; vertical-align: middle; border-top: 2px solid transparent; border-bottom: 2px solid transparent;}

.col-play { width: 60px; text-align: center; }
.col-title { width: 250px; }
.col-waveform { width: auto; min-width: 150px;} 
.col-info { width: 150px; }
.col-license { width: 120px; text-align: center;}
.col-actions { width: 140px; text-align: right; }

.btn-list-play { 
    width: 44px; height: 44px; border-radius: 50%; background: var(--bg-base); border: none; color: var(--primary); 
    font-size: 1.2rem; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; transition: all 0.2s;
}
.track-item-row:hover .btn-list-play { background: var(--primary-light); }
.track-item-row.playing .btn-list-play { background: var(--primary); color: white; box-shadow: 0 4px 10px var(--primary-glow); }

.track-title-group h3 { margin: 0 0 5px 0; font-size: 1.05rem; color: var(--text-main); font-weight: 700;}
.track-title-group p { margin: 0; color: var(--text-muted); font-size: 0.85rem; font-weight: 500;}

/* 리스트 속 가짜 파형 */
.mock-waveform { position: relative; display: flex; align-items: center; gap: 3px; height: 40px; cursor: pointer; overflow: hidden; border-radius: 8px;}
.mock-waveform .waveform-bar { flex: 1; background-color: #DFE6E9; border-radius: 4px; pointer-events: none; transition: 0.3s;}
.mock-waveform .waveform-fill { position: absolute; top: 0; left: 0; height: 100%; width: 0%; background-color: var(--primary-glow); pointer-events: none; z-index: 1; border-radius: 8px 0 0 8px;}
.mock-waveform .waveform-playhead { position: absolute; top: 0; left: 0%; width: 3px; height: 100%; background-color: var(--primary); border-radius: 3px; box-shadow: 0 0 5px var(--primary); pointer-events: none; z-index: 2; display: none;}
.track-item-row.playing .mock-waveform .waveform-bar { background-color: var(--primary-light); }
.track-item-row.playing .mock-waveform .waveform-playhead { display: block; }

.tag-group { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px;}
.tag { 
    background: #F1F2F6; color: #576574; font-weight: 600; cursor: pointer;
    padding: 4px 10px; border-radius: 12px; font-size: 0.75rem; transition: 0.2s;
}
.tag:hover { background: var(--primary); color: white; transform: translateY(-1px); }
.duration { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; display: flex; align-items: center; gap: 4px;}

.badge-safe { background: #EAFBF1; color: #20BF6B; font-weight: 700; padding: 6px 10px; border-radius: 8px; font-size: 0.8rem; display: inline-flex; align-items: center; justify-content: center; width: 85px;}

.action-group { display: flex; gap: 8px; justify-content: flex-end; align-items: center; }
.btn-action { 
    background: white; border: 1px solid var(--border-light); color: var(--text-muted); 
    width: 36px; height: 36px; border-radius: 10px; font-size: 1rem; cursor: pointer; 
    display: flex; align-items: center; justify-content: center; transition: all 0.2s; box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}
.btn-action:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-light); transform: translateY(-2px);}
.btn-action.active-heart { border-color: var(--primary); color: var(--primary); background: var(--primary-light); }

/* 리스트에서 제목에 마우스 올렸을 때 */
.clickable-title { cursor: pointer; transition: 0.2s; }
.clickable-title:hover h3 { color: var(--primary); text-decoration: underline; }

/* =========================================
   3. 상세 페이지 (Detail View) & 정밀 파형
========================================= */
.detail-view {
    width: 100%;
    max-width: 1000px;
    background: #FFFFFF;
    border-radius: 24px;
    box-shadow: 0 15px 40px rgba(255, 107, 129, 0.1);
    padding: 40px;
    margin-bottom: 40px;
    display: flex;
    gap: 40px;
    position: relative;
    box-sizing: border-box;
    border: 2px solid var(--primary-light);
    transition: all 0.3s ease;
}

.detail-view.hidden { display: none; }

.btn-close-detail {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #F1F2F6;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: 0.2s;
}
.btn-close-detail:hover { background: var(--primary); color: white; transform: rotate(90deg); }

/* 커버 이미지 뼈대 (고정 크기) */
.detail-cover {
    position: relative;
    width: 240px;
    height: 240px;
    border-radius: 20px;
    background: linear-gradient(135deg, #FFE3E7 0%, #FF9EAB 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    overflow: hidden;
}

/* 썸네일 이미지 및 어두운 오버레이 */
.detail-cover-img {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    z-index: 1;
}
.detail-cover:has(.detail-cover-img)::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.25);
    z-index: 2;
    pointer-events: none;
}

/* 배경 이모지 */
.detail-cover-emoji { font-size: 5rem; opacity: 0.7; transition: 0.3s; z-index: 3; position: relative;}
.detail-cover.playing .detail-cover-emoji { opacity: 0.2; transform: scale(0.9); }

/* 재생 버튼 중앙 정렬 */
.detail-cover-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    font-size: 2.2rem;
    color: var(--primary);
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(255, 107, 129, 0.4);
    display: flex; align-items: center; justify-content: center;
    padding-left: 6px; 
    transition: all 0.2s ease;
    z-index: 10;
}
.detail-cover.playing .detail-cover-play { padding-left: 0; }
.detail-cover-play:hover { background: var(--primary); color: white; transform: translate(-50%, -50%) scale(1.1); }

/* 시간 표시 태그 */
.detail-time-display {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.65);
    color: #ffffff;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    z-index: 10;
    backdrop-filter: blur(4px);
    letter-spacing: 0.5px;
}

/* 🌊 상세페이지 정밀 파형 고정 영역 */
.detail-cover-waveform {
    position: absolute;
    bottom: 12px;
    left: 12px;
    right: 12px;
    height: 32px;
    cursor: pointer;
    z-index: 10;
}

/* 1. 바탕 흰색 파형 */
.detail-cover-waveform .waveform-base {
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 2px;
    width: 100%; 
    height: 100%;
    position: absolute; 
    top: 0; 
    left: 0;
}
.detail-cover-waveform .waveform-base .waveform-bar {
    flex: 1;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 2px;
    pointer-events: none;
}

/* 2. 채워지는 분홍 파형 마스크 컨테이너 (JS가 width 퍼센트를 조절) */
.detail-cover-waveform .waveform-active-container {
    position: absolute; 
    top: 0; 
    left: 0;
    height: 100%; 
    width: 0%; 
    overflow: hidden; 
    pointer-events: none;
    z-index: 2;
}

/* 3. 내부에 들어가는 분홍 파형 (부모 크기와 똑같은 가로 폭 유지) */
.detail-cover-waveform .waveform-active {
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 2px;
    width: 216px; /* 앨범 커버 내부 파형 가로 폭에 맞춘 고정 값 (240px - 좌우 패딩 24px) */
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.detail-cover-waveform .waveform-active .waveform-bar {
    flex: 1;
    background: #FF2D55;
    border-radius: 2px;
    box-shadow: 0 0 6px rgba(255, 45, 85, 0.8);
    pointer-events: none;
}

/* 4. 재생 헤드라인 */
.detail-cover-waveform .waveform-playhead {
    position: absolute;
    top: 0; 
    left: 0%;
    width: 2px; 
    height: 100%;
    background: #ffffff;
    box-shadow: 0 0 6px #ffffff;
    z-index: 3;
    pointer-events: none;
}

/* 우측 텍스트 영역 */
.detail-info { flex: 1; display: flex; flex-direction: column; justify-content: center; }
.detail-category-text { font-size: 0.9rem; color: var(--primary); font-weight: 800; margin-bottom: 10px; letter-spacing: 1px; }
.detail-title { font-size: 2.2rem; color: var(--text-main); margin: 0 0 5px 0; font-weight: 900; letter-spacing: -1px; }
.detail-artist { font-size: 1.1rem; color: var(--text-muted); margin: 0 0 20px 0; font-weight: 600; }

.detail-license-box {
    background: #F8F9FA; padding: 15px 20px; border-radius: 12px; margin: 20px 0; border-left: 4px solid var(--primary);
}
.detail-license-box p { margin: 5px 0; font-size: 0.95rem; color: var(--text-main); }
.detail-license-box strong { color: var(--primary); }

.detail-action-group { display: flex; gap: 12px; margin-top: auto; }
.btn-detail-main {
    flex: 1; background: var(--primary); color: white; border: none; padding: 15px 20px;
    border-radius: 16px; font-size: 1.1rem; font-weight: 800; cursor: pointer;
    box-shadow: 0 6px 20px var(--primary-glow); transition: 0.2s;
}
.btn-detail-main:hover { transform: translateY(-3px); box-shadow: 0 10px 25px rgba(255,107,129,0.5); }
.btn-detail-sub {
    background: white; color: var(--text-main); border: 2px solid var(--border-light);
    padding: 15px 25px; border-radius: 16px; font-size: 1rem; font-weight: 800; cursor: pointer; transition: 0.2s;
}
.btn-detail-sub:hover { border-color: var(--primary); color: var(--primary); }

/* =========================================
   4. 기타 요소 (페이지네이션, 플레이어, 푸터)
========================================= */
.pagination { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 30px; margin-bottom: 20px; }
.page-btn {
    padding: 8px 14px; border: 1px solid #FFE3E7; background: white; border-radius: 10px;
    font-weight: 600; color: #555; cursor: pointer; transition: all 0.2s ease;
}
.page-btn:hover { background: #FFE3E7; color: var(--primary); }
.page-btn.active { background: var(--primary); color: white; border-color: var(--primary); box-shadow: 0 4px 10px rgba(255, 107, 129, 0.3); }
.page-btn:disabled { opacity: 0.35; cursor: not-allowed; background: #f5f5f5; border-color: #eee; }
.page-btn:disabled:hover { background: #f5f5f5; color: #555; }

.player { 
    position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
    width: 90%; max-width: 900px; height: 80px; 
    background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(15px); 
    border: 1px solid var(--border-light); border-radius: 40px;
    display: flex; align-items: center; justify-content: space-between; padding: 0 25px; 
    box-sizing: border-box; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08); z-index: 1000;
}
.player-info { width: 25%; min-width: 120px; }
.player-info h4 { margin: 0 0 4px 0; color: var(--text-main); font-size: 1rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-info p { margin: 0; font-size: 0.8rem; color: var(--primary); font-weight: 600; display: flex; align-items: center; gap: 4px;}
.player-controls { display: flex; align-items: center; gap: 15px; flex: 1; justify-content: center; }
.btn-play { 
    background: var(--primary); border: none; color: white; width: 48px; height: 48px; 
    border-radius: 50%; font-size: 1.2rem; cursor: pointer; box-shadow: 0 4px 15px var(--primary-glow);
    display: flex; align-items: center; justify-content: center; transition: 0.2s;
}
.btn-play:hover { transform: scale(1.05); }
.track-actions { background: none; border: none; color: var(--text-muted); font-size: 1.4rem; cursor: pointer; transition: 0.2s; }
.track-actions:hover { color: var(--primary); }
.progress-container { width: 35%; display: flex; align-items: center; gap: 10px; font-size: 0.8rem; color: var(--text-muted); font-weight: 600; justify-content: flex-end;}
.progress-bar { flex: 1; max-width: 120px; height: 6px; background: #F1F2F6; border-radius: 4px; position: relative; cursor: pointer; overflow: hidden; }
.progress-fill { position: absolute; left: 0; top: 0; height: 100%; width: 0%; background: var(--primary); border-radius: 4px; pointer-events: none;}
.volume-control { display: flex; align-items: center; gap: 5px; margin-left: 10px; }
.btn-mute { background: none; border: none; font-size: 1.1rem; cursor: pointer; color: var(--text-muted); padding: 0; }
.volume-slider { width: 60px; accent-color: var(--primary); cursor: pointer; }

.site-footer { width: 100%; padding: 40px 5%; box-sizing: border-box; background: white; border-top: 1px solid var(--border-light); margin-top: auto; padding-bottom: 130px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 15px;}
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; justify-content: center; font-weight: 600;}
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.9rem; transition: 0.2s; }
.footer-links a:hover { color: var(--primary); }
.footer-copy { color: #A4B0BE; font-size: 0.85rem; margin: 0; }

/* 드래그 탐색 시 텍스트 선택 및 스크롤 방지 */
.progress-bar, .mock-waveform, .detail-cover-waveform { touch-action: none; user-select: none; -webkit-user-select: none; }

/* =========================================
   5. 모바일 통합 반응형 (단 하나로 완벽 관리)
========================================= */
@media (max-width: 768px) {
    /* 상단 헤더 */
    header { flex-direction: column; padding: 12px 15px; gap: 12px; }
    .header-right { width: 100%; justify-content: space-between; margin-top: 5px; }
    .logo { margin-left: 0; }
    .search-bar { max-width: 100%; margin: 0; }
    .nav-menu { overflow-x: auto; white-space: nowrap; width: 100%; padding-bottom: 5px; display: flex; gap: 6px; }

    /* 상세 페이지 뷰 */
    .detail-view { flex-direction: column; padding: 25px 20px 160px 20px; align-items: center; text-align: center; }
    .detail-cover { margin: 0 auto 20px auto; }
    .detail-license-box { text-align: left; }
    .detail-action-group { flex-direction: column; width: 100%; }
    
    /* 하단 플로팅 플레이어 */
    .player { width: 95%; height: auto; padding: 15px 20px; flex-wrap: wrap; border-radius: 25px; bottom: 15px; gap: 12px; }
    .player-info { width: 100%; text-align: center; }
    .progress-container { width: 100%; justify-content: center; }
    .progress-bar { max-width: 100%; }
    .volume-control, .col-info, .col-license { display: none; }

    /* 하단 플레이어가 컨텐츠를 가리지 않도록 전체 여백 추가 */
    main { padding-bottom: 200px; }
}

.btn-google-login {
            width: 100%; background: #FFFFFF; color: #3C4043; border: 2px solid var(--border-light);
            padding: 14px; border-radius: 12px; font-size: 1rem; font-weight: 700;
            cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 10px;
            margin-top: 10px; transition: 0.2s; box-sizing: border-box;
            box-shadow: 0 2px 8px rgba(0,0,0,0.04);
        }
        .btn-google-login:hover { background: #F8F9FA; border-color: #dadce0; transform: translateY(-2px); }

        /* ==========================================
   👤 프로필 드롭다운 메뉴 (라이트 테마)
   ========================================== */
.profile-container {
    position: relative;
    display: inline-block;
}

/* 상단에 표시되는 프로필 버튼 */
.btn-profile {
    background: #FFFFFF;
    color: var(--text-main);
    border: 2px solid var(--border-light);
    padding: 6px 14px 6px 6px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}
.btn-profile:hover { 
    border-color: var(--primary); 
    transform: translateY(-1px); 
}

/* 프로필 버튼 안의 작은 동그라미 아이콘 */
.profile-icon {
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

/* 드롭다운 메뉴 창 */
.profile-dropdown {
    position: absolute;
    top: calc(100% + 4px); 
    right: 0;
    width: 240px;
    background: #FFFFFF;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(255, 107, 129, 0.15);
    color: var(--text-main);
    z-index: 1000;
    overflow: hidden;
    border: 2px solid var(--border-light);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-5px); 
    transition: all 0.2s ease;
}

/* 마우스를 올렸을 때 메뉴가 스르륵 나타남 */
.profile-container:hover .profile-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* 버튼과 메뉴 사이의 틈새를 메꿔주는 투명 다리 */
.profile-container::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 0;
    width: 100%;
    height: 20px;
    background: transparent;
}

/* 프로필 정보 영역 */
.profile-header {
    padding: 20px 20px 15px;
}
.profile-name { margin: 0; font-size: 1.1rem; font-weight: 800; color: var(--text-main); }
.profile-email { margin: 5px 0 0; font-size: 0.85rem; color: var(--text-muted); }

/* 멤버십 포인트 박스 */
.profile-membership {
    background: #F8F9FA;
    margin: 0 15px 15px;
    border-radius: 12px;
    padding: 12px;
    border: 1px solid var(--border-light);
}
.membership-status {
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
}
.membership-points {
    background: #FFFFFF;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 800;
    color: var(--text-main);
    border: 1px solid var(--border-light);
}
.point-icon {
    background: var(--primary);
    color: white;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    font-weight: bold;
}

/* 하단 메뉴 리스트 */
.profile-links {
    list-style: none;
    margin: 0;
    padding: 10px 0;
    border-top: 1px solid var(--border-light);
}
.profile-links li a {
    display: block;
    padding: 12px 20px;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: 0.2s;
}
.profile-links li a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

/* =========================================
   6. 모달 팝업 디자인
========================================= */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    visibility: visible;
    transition: all 0.3s ease;
}
.modal-overlay.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}
.modal-content {
    background: #FFFFFF;
    width: 90%;
    max-width: 400px;
    border-radius: 24px;
    padding: 35px 30px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(255, 107, 129, 0.2);
    border: 2px solid var(--primary-light);
    transform: translateY(0);
    transition: all 0.3s ease;
}
.modal-overlay.hidden .modal-content {
    transform: translateY(20px);
}
.modal-icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
}
.modal-title {
    font-size: 1.3rem;
    font-weight: 900;
    color: var(--text-main);
    margin: 0 0 15px 0;
}
.modal-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 30px;
}
.modal-desc strong {
    color: var(--primary);
}
.modal-btn-group {
    display: flex;
    gap: 10px;
    justify-content: center;
}
.btn-modal-cancel {
    flex: 1;
    background: #F1F2F6;
    color: var(--text-main);
    border: none;
    padding: 14px;
    border-radius: 14px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s;
}
.btn-modal-cancel:hover {
    background: #DFE6E9;
}
.btn-modal-confirm {
    flex: 1.5;
    background: var(--primary);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 14px;
    font-size: 0.95rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 4px 15px var(--primary-glow);
    transition: 0.2s;
}
.btn-modal-confirm:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255,107,129,0.5);
}