/* 실업급여 테스트 스타일 - 비즈니스/법적 테마 */

:root {
    --primary-color: #1976d2;      /* 신뢰감 있는 블루 */
    --secondary-color: #1565c0;    /* 진한 블루 */
    --accent-color: #ff5722;       /* 경고 오렌지 */
    --success-color: #4caf50;      /* 성공 그린 */
    --warning-color: #ff9800;      /* 주의 오렌지 */
    --background-color: #f5f7fa;   /* 밝은 회색 */
    --card-bg: #ffffff;
    --text-primary: #212121;
    --text-secondary: #757575;
    --border-color: #e0e0e0;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);
    --vh: 1vh;
}

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

body {
    font-family: 'Segoe UI', 'Malgun Gothic', sans-serif;
    background: linear-gradient(135deg, var(--background-color) 0%, #eceff1 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    min-height: calc(var(--vh, 1vh) * 100);
}

.container {
    max-width: 430px;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    min-height: calc(var(--vh, 1vh) * 100);
    display: flex;
    flex-direction: column;
}

.page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: calc(var(--vh, 1vh) * 100);
}

.hidden {
    display: none !important;
}

/* 광고 스타일 */
.ad-container {
    width: 100%;
    text-align: center;
    margin: 10px 0;
    padding: 10px;
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.ad-container.top {
    margin-bottom: 20px;
}

/* 시작 페이지 스타일 */
.header {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.icon-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

.icon {
    font-size: 3rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow);
    animation: float 3s ease-in-out infinite;
}

.icon:nth-child(2) {
    animation-delay: 0.5s;
}

.icon:nth-child(3) {
    animation-delay: 1s;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.title {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 15px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-weight: 500;
}

.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 30px;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 15px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 12px;
    border: 2px solid var(--border-color);
    transition: transform 0.3s;
}

.feature-item:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 1.5rem;
}

.feature-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.info-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.info-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 15px;
    box-shadow: var(--shadow);
}

.info-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.info-title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 4px;
}

.info-desc {
    font-size: 0.9rem;
    opacity: 0.9;
}

.start-btn {
    background: linear-gradient(135deg, var(--accent-color), #ff6f00);
    color: white;
    border: none;
    padding: 18px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: var(--shadow-lg);
}

.start-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(255, 87, 34, 0.4);
}

/* 질문 페이지 스타일 */
.progress-container {
    margin-bottom: 30px;
}

.progress-bar {
    background: #e0e0e0;
    height: 8px;
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    height: 100%;
    border-radius: 10px;
    transition: width 0.5s ease;
}

.progress-text {
    text-align: center;
    font-weight: 600;
    color: var(--text-secondary);
}

.question-container {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.question-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-primary);
    line-height: 1.4;
}

.question-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.answers-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.answer-option {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 15px;
    padding: 18px 20px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
    color: var(--text-primary);
}

.answer-option:hover {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    transform: translateX(5px);
}

.answer-option.selected {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-color: var(--primary-color);
    transform: scale(1.02);
}

/* 모달 스타일 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-content {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.analysis-header {
    text-align: center;
    margin-bottom: 30px;
}

.analysis-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.analysis-steps {
    margin-bottom: 30px;
}

.step-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    margin-bottom: 10px;
    background: #f8f9fa;
    border-radius: 12px;
    border-left: 4px solid var(--border-color);
    transition: all 0.5s;
}

.step-item.active {
    border-left-color: var(--primary-color);
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
}

.step-icon {
    font-size: 1.5rem;
}

.step-text {
    flex: 1;
    font-weight: 600;
    color: var(--text-primary);
}

.step-check {
    font-size: 1.2rem;
    font-weight: 700;
}

.timer-container {
    text-align: center;
    margin-bottom: 20px;
}

.timer-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    border: 4px solid var(--primary-color);
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
}

.popup-ad-space {
    text-align: center;
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

/* 결과 페이지 스타일 */
.result-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: var(--card-bg);
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: var(--shadow);
}

.result-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.result-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.result-content {
    margin-bottom: 30px;
}

.result-content > div {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 15px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.action-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.action-buttons button {
    padding: 15px 20px;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.detail-btn, .restart-btn {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.share-btn, .other-test-btn {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.action-buttons button:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* 가이드 모달 스타일 */
.guide-modal {
    max-width: 650px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 0;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-bottom: 2px solid var(--border-color);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    margin: 0;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
}

.close-btn {
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: white;
    line-height: 1;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.close-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.modal-body {
    padding: 24px;
}

.guide-section {
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.guide-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.guide-section h3 {
    color: var(--primary-color);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.reason-list {
    display: grid;
    gap: 16px;
}

.reason-item {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 16px;
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
}

.reason-item h4 {
    color: var(--primary-color);
    font-size: 1rem;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.reason-item p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.9rem;
}

.document-checklist {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.document-checklist label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: background-color 0.3s;
}

.document-checklist label:hover {
    background-color: var(--background-color);
}

.document-checklist input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-color);
}

.guide-section ul,
.guide-section ol {
    padding-left: 20px;
    margin-bottom: 12px;
}

.guide-section li {
    margin-bottom: 8px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.guide-section li strong {
    color: var(--primary-color);
    font-weight: 600;
}

.useful-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.useful-links a {
    display: inline-block;
    padding: 12px 16px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s;
    text-align: center;
}

.useful-links a:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* 모바일 최적화 */
@media (max-width: 480px) {
    .container {
        padding: 16px;
    }
    
    .title {
        font-size: 1.8rem;
    }
    
    .features {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    .info-card {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
    
    .action-buttons {
        grid-template-columns: 1fr;
    }
    
    .detail-btn,
    .restart-btn {
        grid-column: 1;
    }
    
    .guide-modal {
        max-width: 95vw;
        margin: 10px;
    }
    
    .modal-header {
        padding: 16px;
    }
    
    .modal-header h2 {
        font-size: 1.2rem;
    }
    
    .modal-body {
        padding: 16px;
    }
    
    .document-checklist {
        grid-template-columns: 1fr;
    }
}

/* 다크모드 지원 */
@media (prefers-color-scheme: dark) {
    :root {
        --background-color: #212121;
        --card-bg: #424242;
        --text-primary: #f5f5f5;
        --text-secondary: #bdbdbd;
        --border-color: #616161;
    }
}

/* 유틸리티 클래스 */
.hidden {
    display: none !important;
}

.visible {
    display: block !important;
}
