/* 누리보이스 파트너 포털 - 기본 스타일 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1976d2;
    --secondary-color: #424242;
    --success-color: #4caf50;
    --error-color: #f44336;
    --warning-color: #ff9800;
    --background-color: #f5f5f5;
    --card-background: #ffffff;
    --text-color: #333333;
    --border-color: #e0e0e0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* 헤더 */
.main-header {
    background-color: #1976d2;
    color: white;
    padding: 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-logo-box {
    display: flex;
    align-items: center;
    height: 40px;
    padding: 0 16px;
    border-radius: 12px;
    background-color: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.2s ease-in-out;
    cursor: pointer;
}

.header-logo-box:hover {
    background-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.header-logo-img {
    height: 28px;
    width: auto;
    object-fit: contain;
    filter: brightness(0) invert(1);
    transition: all 0.2s ease-in-out;
}

.header-logo-fallback {
    color: white;
    font-weight: 600;
    font-size: 14px;
    font-family: 'Roboto', sans-serif;
    letter-spacing: 0.3px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.header-logo {
    font-size: 20px;
    font-weight: bold;
    color: white;
}

.header-title {
    font-size: 18px;
    font-weight: bold;
    color: white;
    flex-grow: 1;
}

.header-user {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-user-name {
    font-size: 14px;
    color: white;
}

.header-user-icon {
    font-size: 24px;
    color: white;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.header-user-icon:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.header-exit-icon {
    font-size: 24px;
    color: white;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.header-exit-icon:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 언어 선택 드롭다운 */
.header-language-dropdown {
    position: relative;
    display: inline-block;
}

.header-language-icon {
    font-size: 24px;
    color: white;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.header-language-icon:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.language-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background-color: white;
    min-width: 180px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    z-index: 1001;
    overflow: hidden;
}

.language-dropdown-menu.show {
    display: block;
}

.language-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.2s;
    border-bottom: 1px solid #f0f0f0;
}

.language-option:last-child {
    border-bottom: none;
}

.language-option:hover {
    background-color: #f5f5f5;
}

.language-option.active {
    background-color: #e3f2fd;
}

.language-flag {
    font-size: 24px;
    line-height: 1;
}

.language-name {
    font-size: 14px;
    color: #333;
    font-weight: 500;
}

/* 네비게이션 바 */
.main-navbar {
    background-color: #f5f5f5;
    border-bottom: 1px solid #e0e0e0;
    padding: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    position: sticky;
    top: 64px;
    z-index: 999;
}

.main-navbar .nav-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    gap: 8px;
    align-items: center;
    height: 56px;
    overflow-x: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    text-decoration: none;
    color: #333;
    border-radius: 4px;
    transition: background-color 0.2s;
    white-space: nowrap;
    position: relative;
}

.nav-item:hover {
    background-color: rgba(25, 118, 210, 0.08);
    color: #1976d2;
}

.nav-icon {
    font-size: 20px;
    color: inherit;
}

.nav-text {
    font-size: 14px;
    font-weight: 500;
}

.nav-dropdown {
    cursor: pointer;
    position: relative;
}

.nav-dropdown-arrow {
    font-size: 18px;
    color: inherit;
    transition: transform 0.2s;
}

.nav-dropdown.active .nav-dropdown-arrow {
    transform: rotate(180deg);
}

.nav-dropdown-icon {
    font-size: 20px;
    color: inherit;
}

.nav-dropdown-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    background: white;
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border: 1px solid #e0e0e0;
    min-width: 200px;
    max-width: 300px;
    z-index: 10000;
    padding: 8px 0;
    overflow: hidden;
}

.nav-dropdown.active .nav-dropdown-menu {
    display: block !important;
    animation: dropdownFadeIn 0.2s ease-in-out;
}

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

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    text-decoration: none;
    color: #333;
    transition: background-color 0.2s;
    font-size: 14px;
    width: 100%;
}

.nav-dropdown-item:hover {
    background-color: rgba(25, 118, 210, 0.08);
    color: #1976d2;
}

.nav-dropdown-item .nav-dropdown-icon {
    font-size: 20px;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 기존 네비게이션 (하위 호환성) */
.navbar {
    background-color: var(--card-background);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 1rem 0;
    margin-bottom: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.nav-link:hover {
    background-color: var(--background-color);
}

.btn-logout {
    background-color: var(--error-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-logout:hover {
    background-color: #d32f2f;
}

/* 컨테이너 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 메인 콘텐츠 */
.main-content {
    min-height: calc(100vh - 200px);
}

/* 인증 페이지 */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
}

.auth-card {
    background-color: var(--card-background);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 500px;
}

.auth-card h2 {
    margin-bottom: 1.5rem;
    text-align: center;
    color: var(--primary-color);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* 버튼 */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

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

.btn-primary:hover {
    background-color: #1565c0;
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background-color: #212121;
}

.btn-block {
    width: 100%;
}

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

.btn-danger:hover {
    background-color: #d32f2f;
}

/* 링크 */
.link {
    color: var(--primary-color);
    text-decoration: none;
}

.link:hover {
    text-decoration: underline;
}

/* 메시지 */
.error-message {
    background-color: #ffebee;
    color: var(--error-color);
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
}

.success-message {
    background-color: #e8f5e9;
    color: var(--success-color);
    padding: 1rem;
    border-radius: 4px;
    margin-top: 1rem;
}

/* 통계 카드 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.stat-card {
    background-color: var(--card-background);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.stat-card h3 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.stat-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    color: var(--secondary-color);
}

.stat-value {
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--primary-color);
}

/* 히어로 섹션 */
.hero {
    text-align: center;
    padding: 3rem 0;
}

.hero h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-bottom: 2rem;
}

.auth-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* 기능 카드 */
.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.feature-card {
    background-color: var(--card-background);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

.feature-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* 테이블 */
.table-container {
    background-color: var(--card-background);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

table th,
table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

table th {
    background-color: var(--background-color);
    font-weight: 600;
}

table tr:hover {
    background-color: var(--background-color);
}

/* 푸터 */
.footer {
    background-color: var(--card-background);
    padding: 1.5rem;
    text-align: center;
    margin-top: 3rem;
    border-top: 1px solid var(--border-color);
}

/* 유틸리티 */
.text-center {
    text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* 반응형 */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-menu {
        flex-direction: column;
        width: 100%;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .stats-grid,
    .features {
        grid-template-columns: 1fr;
    }
}

