/* /public/css/home.css */

/* 상단 네비게이션 */
.top-nav {
    background: var(--surface);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--surface-light);
}

.nav-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-title {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.user-name {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* [신규] 메일 버튼 스타일 */
.mail-btn {
    position: relative;
    background: var(--surface-light);
    border: none;
    color: var(--text-secondary);
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.mail-btn:hover {
    background: var(--primary-color);
    color: white;
}

/* [신규] 알림 점 스타일 */
.notification-dot {
    position: absolute;
    top: 6px;  /* 버튼 상단에서 6px 아래 */
    right: 6px; /* 버튼 우측에서 6px 왼쪽 */
    width: 8px;
    height: 8px;
    background-color: var(--error);
    border-radius: 50%;
    border: 1px solid var(--surface);
    box-shadow: 0 0 5px var(--error);
}

.notification-dot.hidden {
    display: none;
}

.logout-btn {
    background: var(--surface-light);
    border: none;
    color: var(--text-secondary);
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.logout-btn:hover {
    background: var(--error);
    color: white;
}

/* 메인 컨텐츠 */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px;
    min-height: calc(100vh - 180px);
    padding-bottom: 120px;
}

.content-header {
    margin-bottom: 24px;
}

.content-header h2 {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
}

.tab-content {
    display: none;
    animation: fadeInContent 0.3s ease-out;
}

.tab-content.active {
    display: block;
}

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

.placeholder-text {
    text-align: center;
    color: var(--text-muted);
    font-size: 18px;
    margin-top: 60px;
}

/* 캐릭터 그리드 */
.character-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 24px;
}

.character-card {
    background: var(--surface);
    border-radius: var(--border-radius);
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
    border: 2px solid transparent;
}

.character-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.character-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: linear-gradient(135deg, var(--surface-light), var(--primary-dark));
}

.character-info {
    padding: 16px;
}

.character-name {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.character-worldview {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.character-stats {
    display: flex;
    gap: 12px;
    font-size: 13px;
    color: var(--text-secondary);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 캐릭터 생성 카드 */
.create-character-card {
    background: var(--surface);
    border: 2px dashed var(--surface-light);
    border-radius: var(--border-radius);
    padding: 32px 24px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.create-character-card:hover {
    border-color: var(--primary-color);
    background: var(--surface-light);
    transform: translateY(-4px);
}

.create-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    font-size: 28px;
    color: white;
}

.create-text {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.create-subtext {
    font-size: 13px;
    color: var(--text-muted);
}

.character-count-info {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* 하단 플로팅 네비게이션 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface);
    border-top: 1px solid var(--surface-light);
    box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    z-index: 90;
}

.nav-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: var(--transition);
    font-size: 12px;
    min-width: 60px;
    flex: 1;
}

.nav-btn i {
    font-size: 20px;
}

.nav-btn:hover {
    background: var(--surface-light);
    color: var(--text-secondary);
}

.nav-btn.active {
    color: var(--primary-color);
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .nav-content {
        padding: 12px 16px;
    }
    
    .nav-title {
        font-size: 18px;
    }
    
    .user-name {
        display: none;
    }
    
    .main-content {
        padding: 16px;
    }
    
    .character-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 16px;
    }
    
    .bottom-nav {
        padding: 4px 0;
    }
    
    .nav-btn {
        padding: 6px 8px;
        min-width: 60px;
    }
    
    .nav-btn i {
        font-size: 18px;
    }
    
    .nav-btn span {
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .character-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-btn {
        padding: 6px 4px;
        min-width: 50px;
        font-size: 10px;
    }
    
    .nav-btn i {
        font-size: 16px;
    }
    
    /* Note: 10px font size is below accessibility guidelines but necessary
       for 6 tabs on very small screens. Consider hiding text on smallest screens. */
    .nav-btn span {
        font-size: 10px;
    }
}

