/* ===========================
   출석·체크리스트 보드 스타일
   =========================== */

/* ===========================
   출석·체크리스트 보드 스타일
   =========================== */

/* 페이지 컨테이너 오버라이드 */
.page-container {
    padding: 20px;
}

.page-container .container {
    max-width: 1200px;
    margin: 0 auto;
    display: block;
    grid-template-columns: 1fr;
    grid-template-rows: auto;
}

.main-content {
    width: 100%;
    padding: 20px 0;
}

/* 컨트롤 패널 */
.control-panel {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
}

.control-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.control-row:not(:last-child) {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.control-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

.form-input,
.form-select {
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: var(--transition);
    background: var(--bg-color);
    color: var(--text-color);
    min-width: 150px;
}

.form-select {
    cursor: pointer;
}

.color-input {
    width: 60px;
    height: 44px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    padding: 2px;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-color);
    color: var(--text-color);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--card-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* 체크리스트 섹션 */
.checklist-section {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-sm);
}

.checklist-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.filter-badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    margin-left: 10px;
}

.view-options {
    display: flex;
    gap: 10px;
}

.view-btn {
    padding: 8px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-color);
    color: var(--text-color);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
}

.view-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.view-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.checklist-header h2 {
    font-size: 1.5rem;
    color: var(--text-color);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.checklist-header h2 i {
    color: var(--primary-color);
}

.stats-summary {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.stat-item {
    font-size: 0.95rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

.stat-item i {
    color: var(--primary-color);
}

.stat-item strong {
    color: var(--text-color);
    font-weight: 700;
}

/* 체크리스트 보드 */
.checklist-board {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.checklist-item {
    background: var(--bg-color);
    border: 2px solid var(--border-color);
    border-left: 4px solid var(--item-color, var(--border-color));
    border-radius: var(--radius-lg);
    padding: 20px;
    transition: var(--transition);
    margin-bottom: 20px;
}

.checklist-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
}

.checklist-item.priority-high {
    border-left-color: #f59e0b;
}

.checklist-item.priority-urgent {
    border-left-color: #ef4444;
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.item-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.item-meta {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.item-category,
.item-priority {
    display: inline-block;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 600;
}

.item-category {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary-color);
}

.item-priority.priority-low {
    background: rgba(107, 114, 128, 0.1);
    color: #6b7280;
}

.item-priority.priority-normal {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.item-priority.priority-high {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.item-priority.priority-urgent {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.item-note {
    margin-top: 10px;
    padding: 10px;
    background: var(--card-bg);
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.item-name i {
    color: var(--primary-color);
}

.item-actions {
    display: flex;
    gap: 10px;
}

.btn-icon {
    background: none;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-muted);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-icon:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-icon.delete:hover {
    border-color: #ef4444;
    color: #ef4444;
}

.date-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.date-row {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    background: var(--card-bg);
    border-radius: var(--radius-md);
    transition: var(--transition);
    position: relative;
}

.date-row:hover {
    background: rgba(37, 99, 235, 0.05);
}

.date-row.has-note::before {
    content: '📝';
    position: absolute;
    right: 10px;
    top: 10px;
    font-size: 0.8rem;
}

.date-label {
    min-width: 120px;
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.95rem;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.custom-checkbox {
    width: 24px;
    height: 24px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    position: relative;
    transition: var(--transition);
    flex-shrink: 0;
    background: var(--bg-color);
}

.custom-checkbox:hover {
    border-color: var(--primary-color);
}

.custom-checkbox.checked {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.custom-checkbox.checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 14px;
    font-weight: bold;
}

.checkbox-label {
    font-size: 0.95rem;
    color: var(--text-color);
    cursor: pointer;
    user-select: none;
    flex: 1;
}

.check-count {
    min-width: 60px;
    text-align: right;
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 600;
}

.check-count .count-value {
    color: var(--primary-color);
    font-size: 1.1rem;
}

/* 빈 상태 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 20px;
    color: var(--border-color);
}

.empty-state h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--text-color);
}

.empty-state p {
    font-size: 0.95rem;
}

/* 통계 대시보드 */
.stats-dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-sm);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-icon i {
    font-size: 1.5rem;
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-color);
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* 모달 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 20px;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    display: flex;
    flex-direction: column;
}

.modal-header {
    padding: 25px;
    border-bottom: 2px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 1.3rem;
    color: var(--text-color);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-header h3 i {
    color: var(--primary-color);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-muted);
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-color);
    transform: rotate(90deg);
}

.modal-body {
    padding: 25px;
    flex: 1;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.form-textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    transition: var(--transition);
    box-sizing: border-box;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.modal-footer {
    padding: 25px;
    border-top: 2px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* 반응형 */
@media (max-width: 768px) {
    .main-content {
        padding: 15px;
    }
    
    .control-panel {
        padding: 20px;
    }
    
    .control-row {
        flex-direction: column;
        align-items: stretch;
    }
    
    .control-group {
        width: 100%;
    }
    
    .form-input {
        width: 100%;
        min-width: auto;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .checklist-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .stats-summary {
        width: 100%;
        justify-content: space-between;
    }
    
    .item-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .date-row {
        flex-wrap: wrap;
    }
    
    .date-label {
        min-width: 100px;
        width: 100%;
    }
    
    .check-count {
        width: 100%;
        text-align: left;
    }
    
    .stats-dashboard {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        max-width: 100%;
        margin: 0;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    
    .modal-footer .btn {
        width: 100%;
    }
}

/* ===== FAQ/QNA 섹션 (페이지 하단) ===== */
.faq-section {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
    padding: 40px 32px;
    margin: 40px auto 0 auto;
    max-width: 900px;
}

.faq-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 2px solid #e2e8f0;
    text-align: center;
}

.faq-title i {
    color: #2563eb;
    font-size: 1.5rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

.faq-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px 24px;
    transition: all 0.3s ease;
    width: 100%;
}

.faq-item.active,
.faq-item:hover {
    border-color: #2563eb;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
    background: #f8fafc;
}

.faq-question {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
    line-height: 1.6;
    width: 100%;
}

.faq-question span:not(.faq-icon) {
    flex: 1;
    word-break: keep-all;
}

.faq-icon {
    background: #2563eb;
    color: #fff;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    flex-shrink: 0;
}

.faq-arrow {
    margin-left: auto;
    color: #64748b;
    font-size: 0.9rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.faq-item.active .faq-arrow {
    transform: rotate(180deg);
    color: #2563eb;
}

.faq-item .faq-answer {
    display: none;
    margin-top: 16px;
    padding-top: 16px;
    padding-left: 0;
    border-top: 1px solid #e2e8f0;
    color: #475569;
    font-size: 1rem;
    line-height: 1.8;
    width: 100%;
}

.faq-item.active .faq-answer {
    display: block;
}

.faq-answer p {
    margin: 0;
    margin-bottom: 8px;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-answer strong {
    color: #1e293b;
    font-weight: 600;
}

@media (max-width: 768px) {
    .faq-section {
        padding: 24px 20px;
        margin: 24px 0 0;
    }
    
    .faq-title {
        font-size: 1.3rem;
        margin-bottom: 20px;
        flex-direction: column;
        gap: 8px;
    }
    
    .faq-item {
        padding: 16px 18px;
    }
    
    .faq-question {
        font-size: 1rem;
        gap: 10px;
    }
    
    .faq-icon {
        width: 28px;
        height: 28px;
        font-size: 0.9rem;
    }
    
    .faq-item .faq-answer {
        font-size: 0.95rem;
    }
}

