/* 기본 스타일 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.app-container {
    max-width: 414px;
    margin: 0 auto;
    min-height: 100vh;
    background: #f8f9fa;
    position: relative;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
}

/* 웰컴 페이지 */
.welcome-container {
    padding: 40px 20px;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.welcome-header {
    margin-bottom: 40px;
}

.app-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.3);
}

.app-icon i {
    font-size: 36px;
    color: white;
}

.welcome-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.welcome-header p {
    font-size: 16px;
    color: #666;
    line-height: 1.5;
}

.welcome-buttons {
    margin-bottom: 40px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 24px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 8px;
    min-width: 140px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-secondary:hover {
    background: #667eea;
    color: white;
}

.btn-full {
    width: 100%;
    margin: 8px 0;
}

.btn i {
    margin-right: 8px;
}

.welcome-features {
    display: flex;
    justify-content: space-around;
    margin-top: 40px;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.feature-item i {
    font-size: 24px;
    color: #667eea;
    margin-bottom: 8px;
}

.feature-item span {
    font-size: 12px;
    color: #666;
    text-align: center;
}

/* 모달 스타일 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #333;
}

/* 폼 스타일 */
form {
    padding: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.eye-selection {
    display: flex;
    gap: 16px;
}

.eye-option {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.eye-option input {
    opacity: 0;
    position: absolute;
    pointer-events: none;
}

.eye-option input:checked + span {
    color: #667eea;
    font-weight: 600;
}

.eye-option:has(input:checked) {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.1);
}

.eye-option span {
    font-size: 16px;
}

.modal-footer {
    padding: 20px;
    text-align: center;
    border-top: 1px solid #eee;
}

.modal-footer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.modal-footer a:hover {
    text-decoration: underline;
}

/* 대시보드 스타일 */
.dashboard-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.dashboard-header {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.user-avatar {
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
}

.user-avatar i {
    font-size: 24px;
}

.user-details h2 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
}

.user-details p {
    font-size: 14px;
    opacity: 0.9;
}

.logout-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    padding: 8px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}

.logout-btn:hover {
    background: rgba(255,255,255,0.3);
}

/* 네비게이션 */
.bottom-nav {
    background: white;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-around;
    padding: 8px 0 60px 0; /* 하단에 저작권 공간 확보 */
    position: sticky;
    bottom: 0;
    z-index: 100;
}

.nav-btn {
    background: none;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px 12px;
    cursor: pointer;
    color: #999;
    transition: color 0.3s ease;
}

.nav-btn.active {
    color: #667eea;
}

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

.nav-btn span {
    font-size: 12px;
    font-weight: 500;
}

/* 메인 콘텐츠 */
.main-content {
    flex: 1;
    padding: 20px;
    padding-bottom: 100px;
}

.tab-content {
    display: none;
}

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

/* 달력 스타일 */
.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.nav-month {
    background: none;
    border: none;
    font-size: 18px;
    color: #667eea;
    cursor: pointer;
    padding: 8px;
}

.calendar-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: #e1e5e9;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.calendar-day-header {
    background: #667eea;
    color: white;
    padding: 12px 8px;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
}

.calendar-day {
    background: white;
    padding: 12px 8px;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-day:hover {
    background: #f0f0f0;
}

.calendar-day.other-month {
    color: #ccc;
}

.calendar-day.today {
    background: #667eea;
    color: white;
    font-weight: 600;
}

.calendar-day.has-treatment {
    background: #4CAF50;
    color: white;
    font-weight: 600;
}

/* 통계 스타일 */
.stats-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.stat-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
}

.stat-icon i {
    font-size: 20px;
    color: white;
}

.stat-info h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 4px;
}

.stat-info p {
    font-size: 14px;
    color: #666;
}

.chart-container {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* 리그 스타일 */
.leagues-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.leagues-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

.leagues-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.league-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.league-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.league-header h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.league-rank {
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

.league-members {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.member-item {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 8px;
}

.member-item .rank {
    width: 24px;
    height: 24px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    margin-right: 12px;
}

.member-item .name {
    flex: 1;
    font-weight: 500;
}

.member-item .score {
    color: #666;
    font-size: 14px;
}

.empty-message {
    text-align: center;
    color: #999;
    padding: 40px 20px;
    font-style: italic;
}

/* 프로필 스타일 */
.profile-container {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.profile-avatar i {
    font-size: 36px;
    color: white;
}

.profile-info h3 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.profile-info p {
    color: #666;
    margin-bottom: 20px;
}

/* 처방 정보 표시 */
.prescription-info {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    text-align: left;
}

.prescription-info h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
    text-align: center;
}

.prescription-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.prescription-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e1e5e9;
}

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

.prescription-item .label {
    font-weight: 500;
    color: #666;
}

.prescription-item span:last-child {
    font-weight: 600;
    color: #333;
}

.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* 애니메이션 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* 반응형 디자인 */
@media (max-width: 375px) {
    .welcome-container {
        padding: 20px 16px;
    }
    
    .welcome-header h1 {
        font-size: 24px;
    }
    
    .btn {
        min-width: 120px;
        padding: 14px 20px;
    }
    
    .main-content {
        padding: 16px;
    }
    
    .calendar-day {
        min-height: 45px;
        font-size: 14px;
    }
}

/* 초기 설정 페이지 스타일 */
.setup-container {
    padding: 20px;
    min-height: 100vh;
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #fecfef 100%);
}

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

.setup-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    border-radius: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 32px rgba(255, 107, 107, 0.3);
}

.setup-icon i {
    font-size: 48px;
    color: white;
}

.setup-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 10px;
}

.setup-header p {
    font-size: 16px;
    color: #666;
    line-height: 1.5;
}

.setup-form {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.eye-selection-large {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.eye-option-large {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    border: 3px solid #e1e5e9;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.eye-option-large input {
    display: none;
}

.eye-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.eye-option-large span {
    font-size: 16px;
    font-weight: 600;
    color: #666;
}

.eye-option-large:has(input:checked) {
    border-color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
    transform: scale(1.05);
}

.eye-option-large:has(input:checked) .eye-icon {
    transform: scale(1.2);
}

.eye-option-large:has(input:checked) span {
    color: #ff6b6b;
}

.time-input-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.time-input-container input {
    flex: 1;
    padding: 16px;
    border: 3px solid #e1e5e9;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
}

.time-input-container input:focus {
    border-color: #ff6b6b;
    outline: none;
}

.time-unit {
    font-size: 18px;
    font-weight: 600;
    color: #666;
}

.help-text {
    display: block;
    margin-top: 8px;
    font-size: 14px;
    color: #999;
    font-style: italic;
}

.btn-large {
    padding: 20px;
    font-size: 18px;
    font-weight: 600;
    border-radius: 16px;
}

.setup-tips {
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}

.setup-tips h3 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.setup-tips ul {
    list-style: none;
    padding: 0;
}

.setup-tips li {
    padding: 8px 0;
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* 진행률에 따른 색상 클래스 */
.calendar-day.progress-red {
    background: #ff6b6b !important;
    color: white;
    font-weight: 600;
}

.calendar-day.progress-green {
    background: #51cf66 !important;
    color: white;
    font-weight: 600;
}

.calendar-day.progress-blue {
    background: #339af0 !important;
    color: white;
    font-weight: 600;
}

.calendar-day.progress-gold {
    background: linear-gradient(135deg, #ffd43b, #fab005) !important;
    color: white;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 212, 59, 0.4);
}

/* 아이들 친화적 색상 개선 */
.btn-primary {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
}

.btn-secondary {
    background: white;
    color: #ff6b6b;
    border: 2px solid #ff6b6b;
}

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

/* 달력 개선 */
.calendar-day-header {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    padding: 12px 8px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
}

.calendar-day.today {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

/* 통계 카드 개선 */
.stat-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 16px;
}

/* 대시보드 헤더 개선 */
.dashboard-header {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* 네비게이션 개선 */
.nav-btn.active {
    color: #ff6b6b;
}

/* 모달 개선 */
.modal-header h2 {
    font-size: 22px;
    font-weight: 700;
    color: #333;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff6b6b;
}

.eye-option:has(input:checked) {
    border-color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
}

/* 체크박스 스타일 */
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    padding: 16px 20px;
    background: rgba(255, 107, 107, 0.05);
    border: 2px solid #ff6b6b;
    border-radius: 12px;
    margin: 16px 0;
    transition: all 0.3s ease;
}

.checkbox-label:hover {
    background: rgba(255, 107, 107, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.2);
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 24px;
    height: 24px;
    border: 3px solid #ff6b6b;
    border-radius: 6px;
    margin-right: 16px;
    position: relative;
    transition: all 0.3s ease;
    background: white;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.2);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: #ff6b6b;
    border-color: #ff6b6b;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 16px;
    font-weight: bold;
}

.checkbox-label input[type="checkbox"]:checked ~ span {
    color: #ff6b6b;
    font-weight: 700;
}

.checkbox-label:hover .checkmark {
    border-color: #ff6b6b;
    transform: scale(1.05);
}

/* 치료 세부사항 숨기기/보이기 */
#treatmentDetails {
    transition: all 0.3s ease;
}

#treatmentDetails.hidden {
    opacity: 0.5;
    pointer-events: none;
}

#treatmentDetails.hidden input {
    background: #f5f5f5;
    color: #999;
}

.eye-selection.hidden {
    opacity: 0.5;
    pointer-events: none;
}

.eye-selection.hidden .eye-option {
    background: #f5f5f5;
    color: #999;
    border-color: #e1e5e9;
}

/* 다크 모드 지원 */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
    
    .app-container {
        background: #1a1a1a;
        color: #fff;
    }
    
    /* 웰컴 페이지 다크모드 */
    .welcome-header h1 {
        color: #fff !important;
    }
    
    .welcome-header p {
        color: #ccc !important;
    }
    
    .feature-item span {
        color: #ccc !important;
    }
    
    .feature-item i {
        color: #ff6b6b !important;
    }
    
    /* 모달 다크모드 */
    .modal-content {
        background: #2d2d2d;
        color: #fff;
    }
    
    .modal-header h2 {
        color: #fff !important;
    }
    
    .form-group label {
        color: #fff !important;
    }
    
    .form-group input,
    .form-group textarea {
        background: #3d3d3d;
        border-color: #555;
        color: #fff;
    }
    
    .form-group input:focus,
    .form-group textarea:focus {
        border-color: #ff6b6b;
    }
    
    .modal-footer {
        color: #ccc;
    }
    
    .modal-footer a {
        color: #ff6b6b;
    }
    
    /* 카드들 다크모드 */
    .stat-card,
    .league-card,
    .profile-container,
    .chart-container,
    .calendar-legend {
        background: #2d2d2d;
        color: #fff;
    }
    
    .stat-info h3,
    .league-header h4,
    .profile-info h3,
    .calendar-header h3,
    .leagues-header h3 {
        color: #fff !important;
    }
    
    .stat-info p,
    .profile-info p {
        color: #ccc !important;
    }
    
    /* 달력 다크모드 */
    .calendar-day {
        background: #3d3d3d;
        color: #fff;
    }
    
    .calendar-day:hover {
        background: #4d4d4d;
    }
    
    .calendar-day.other-month {
        color: #666;
    }
    
    /* 네비게이션 다크모드 */
    .bottom-nav {
        background: #2d2d2d;
        border-top-color: #555;
        padding-bottom: 60px; /* 저작권 공간 확보 */
    }
    
    .nav-btn {
        color: #ccc;
    }
    
    .nav-btn.active {
        color: #ff6b6b;
    }
    
    /* 체크박스 다크모드 */
    .checkbox-label {
        background: rgba(255, 107, 107, 0.1);
        border-color: #ff6b6b;
        color: #fff;
    }
    
    .checkbox-label:hover {
        background: rgba(255, 107, 107, 0.2);
    }
    
    .checkmark {
        background: #3d3d3d;
        border-color: #ff6b6b;
    }
    
    /* 설정 페이지 다크모드 */
    .setup-container {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
    
    .setup-header h1 {
        color: #fff !important;
    }
    
    .setup-header p {
        color: #ccc !important;
    }
    
    .setup-form {
        background: #2d2d2d;
    }
    
    .setup-tips {
        background: rgba(45, 45, 45, 0.9);
    }
    
    .setup-tips h3 {
        color: #fff !important;
    }
    
    .setup-tips li {
        color: #ccc !important;
    }
    
    /* 대시보드 다크모드 */
    .welcome-message {
        background: #2d2d2d;
    }
    
    .welcome-message h3 {
        color: #fff !important;
    }
    
    .welcome-message p {
        color: #ccc !important;
    }
    
    /* 치료 기록 다크모드 */
    .treatment-item {
        background: #3d3d3d;
        border-left-color: #ff6b6b;
    }
    
    .treatment-date {
        color: #fff !important;
    }
    
    .treatment-eye {
        color: #ff6b6b !important;
    }
    
    .treatment-duration,
    .treatment-notes {
        color: #ccc !important;
    }
    
    .recent-treatments h4 {
        color: #fff !important;
    }
    
    /* 설정 다크모드 */
    .settings-content h4 {
        color: #fff !important;
    }
    
    .profile-info p {
        color: #ccc !important;
    }
    
    .profile-info strong {
        color: #fff !important;
    }
    
    .form-group select {
        background: #3d3d3d;
        border-color: #555;
        color: #fff;
    }
    
    .form-group select:focus {
        border-color: #ff6b6b;
    }
    
    /* 탭 다크모드 */
    .calendar-container h3,
    .progress-container h3,
    .settings-container h3 {
        color: #fff !important;
    }
    
    .calendar-placeholder {
        background: #2d2d2d;
    }
    
    .calendar-placeholder i {
        color: #ff6b6b !important;
    }
    
    .calendar-placeholder p {
        color: #ccc !important;
    }
    
    .settings-card {
        background: #2d2d2d;
    }
    
    .settings-card span {
        color: #fff !important;
    }
    
    .settings-card i {
        color: #ff6b6b !important;
    }
    
    /* 달력 특정 날 치료 기록 모달 다크모드 */
    .day-summary {
        background: #3d3d3d;
    }
    
    .day-summary h4 {
        color: #fff !important;
    }
    
    .day-summary p {
        color: #ccc !important;
    }
    
    /* 달력 특정 날 치료 기록 입력 모달 다크모드 */
    .existing-treatments h4,
    .add-treatment-section h4 {
        color: #fff !important;
    }
    
    .add-treatment-section {
        border-top-color: #555;
    }
    
    /* 월별 차트 다크모드 */
    .monthly-chart h4 {
        color: #fff !important;
    }
    
    .monthly-chart .chart-container {
        background: #2d2d2d;
    }
    
    /* 알림 모달 다크모드 */
    .notification-content h3 {
        color: #fff !important;
    }
    
    .notification-content p {
        color: #ccc !important;
    }
    
    /* 시간 입력 필드 다크모드 */
    .form-group input[type="time"] {
        background: #3d3d3d;
        border-color: #555;
        color: #fff;
    }
    
    .form-group input[type="time"]:focus {
        border-color: #ff6b6b;
    }
    
    /* 치료 기록 액션 버튼 다크모드 */
    .btn-edit {
        color: #8b9cff !important;
        background: rgba(139, 156, 255, 0.2) !important;
    }
    
    .btn-edit:hover {
        background: rgba(139, 156, 255, 0.3) !important;
    }
    
    .btn-delete {
        color: #ff8a8a !important;
        background: rgba(255, 138, 138, 0.2) !important;
    }
    
    .btn-delete:hover {
        background: rgba(255, 138, 138, 0.3) !important;
    }
    
    /* 프로필 사진 다크모드 */
    .profile-photo-placeholder,
    .user-photo-placeholder {
        background: #3d3d3d;
        border-color: #555;
        color: #ccc;
    }
    
    .profile-photo-container img,
    .user-avatar img {
        border-color: #ff6b6b;
    }
    
    /* 저작권 정보 다크모드 */
    .copyright {
        background: rgba(45, 45, 45, 0.95);
        border-top-color: #555;
    }
    
    .copyright p {
        color: #ccc;
    }
    
    /* 별모으기 다크모드 */
    .star-collection {
        background: linear-gradient(135deg, #3d3d3d 0%, #4d4d4d 100%);
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    }
    
    .star-collection h4 {
        color: #fff;
    }
    
    .star-count span:first-child {
        color: #ff8a8a;
        text-shadow: 2px 2px 4px rgba(255, 138, 138, 0.3);
    }
    
    .star-label {
        color: #ccc;
    }
    
    .star-bar {
        background: rgba(255, 255, 255, 0.1);
    }
    
    .star-message {
        color: #fff;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    }
    
    /* 설정 카드 다크모드 */
    .settings-card {
        background: #2d2d2d;
        border-color: #555;
        color: #fff;
    }
    
    .settings-card:hover {
        border-color: #ff6b6b;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    }
    
    .settings-card i {
        color: #ff6b6b;
    }
    
    .settings-card span {
        color: #fff;
    }
    
    /* 치료못함 체크박스 다크모드 */
    .no-treatment-checkbox {
        background: #3a3a3a;
        border-color: #555;
    }
    
    .no-treatment-checkbox:hover {
        background: #4a4a4a;
        border-color: #ff6b6b;
    }
    
    .no-treatment-checkbox:has(input[type="checkbox"]:checked) {
        background: #ff6b6b;
        border-color: #ff6b6b;
    }
    
    .no-treatment-checkbox label {
        color: #fff;
    }
    
    .no-treatment-checkbox:has(input[type="checkbox"]:checked) label {
        color: white;
    }
}

/* 달력 색상 범례 */
.calendar-legend {
    margin: 20px 0;
    padding: 15px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.calendar-legend h4 {
    margin-bottom: 12px;
    color: #333;
    font-size: 16px;
    font-weight: 600;
}

.legend-items {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #555;
}

.legend-color {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    border: 2px solid rgba(255,255,255,0.3);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.legend-color.progress-red {
    background: #ff6b6b;
}

.legend-color.progress-green {
    background: #51cf66;
}

.legend-color.progress-blue {
    background: #339af0;
}

.legend-color.progress-gold {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
}

@media (max-width: 480px) {
    .legend-items {
        grid-template-columns: 1fr;
        gap: 6px;
    }
    
    .legend-item {
        font-size: 12px;
    }
    
    .legend-color {
        width: 14px;
        height: 14px;
    }
}

/* 대시보드 메인 콘텐츠 스타일 */
.welcome-message {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.welcome-message h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

.welcome-message p {
    font-size: 16px;
    color: #666;
    margin: 0;
}

.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.quick-actions .btn {
    margin: 0;
    padding: 20px;
    font-size: 18px;
    font-weight: 600;
    border-radius: 16px;
}

/* 치료 기록 관련 스타일 */
.progress-content {
    padding: 20px;
}

.recent-treatments {
    margin-top: 20px;
}

.recent-treatments h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.treatments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.treatment-item {
    background: #f8f9fa;
    padding: 16px;
    border-radius: 8px;
    border-left: 4px solid #ff6b6b;
}

.treatment-date {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.treatment-details {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.treatment-eye {
    color: #ff6b6b;
    font-weight: 500;
}

.treatment-duration {
    color: #666;
    font-size: 14px;
}

.treatment-notes {
    color: #666;
    font-size: 14px;
    font-style: italic;
    margin-top: 8px;
}

/* 치료 기록 액션 버튼 */
.treatment-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    justify-content: flex-end;
}

.btn-edit,
.btn-delete {
    background: none;
    border: none;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-edit {
    color: #667eea;
    background: rgba(102, 126, 234, 0.1);
}

.btn-edit:hover {
    background: rgba(102, 126, 234, 0.2);
    transform: translateY(-1px);
}

.btn-delete {
    color: #ff6b6b;
    background: rgba(255, 107, 107, 0.1);
}

.btn-delete:hover {
    background: rgba(255, 107, 107, 0.2);
    transform: translateY(-1px);
}

.btn-edit i,
.btn-delete i {
    font-size: 12px;
}

/* 설정 관련 스타일 */
.settings-content {
    padding: 20px;
}

.settings-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
    margin-top: 24px;
}

.settings-content h4:first-child {
    margin-top: 0;
}

.user-profile,
.treatment-settings,
.app-settings {
    margin-bottom: 24px;
}

.profile-info p {
    margin-bottom: 8px;
    color: #666;
}

.profile-info strong {
    color: #333;
}

.settings-actions {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.settings-actions .btn {
    margin: 0;
}

/* 셀렉트 박스 스타일 */
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 16px;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.form-group select:focus {
    outline: none;
    border-color: #ff6b6b;
}

/* 탭 네비게이션 관련 스타일 */
.calendar-container,
.progress-container,
.settings-container {
    padding: 20px;
}

.calendar-container h3,
.progress-container h3,
.settings-container h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
}

.calendar-placeholder {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.calendar-placeholder i {
    font-size: 48px;
    color: #ff6b6b;
    margin-bottom: 16px;
}

.calendar-placeholder p {
    color: #666;
    margin-bottom: 8px;
    font-size: 16px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 20px;
}

.settings-card {
    background: white;
    border: none;
    border-radius: 12px;
    padding: 24px 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.settings-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.settings-card i {
    font-size: 32px;
    color: #ff6b6b;
    margin-bottom: 12px;
}

.settings-card span {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

/* 달력 특정 날 치료 기록 모달 */
.day-treatments-content {
    padding: 20px;
}

.day-summary {
    text-align: center;
    margin-bottom: 20px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
}

.day-summary h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.day-summary p {
    color: #666;
    margin: 0;
}

/* 달력 특정 날 치료 기록 입력 모달 */
.existing-treatments {
    margin-bottom: 24px;
}

.existing-treatments h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.add-treatment-section {
    border-top: 1px solid #eee;
    padding-top: 24px;
}

.add-treatment-section h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

/* 월별 차트 스타일 */
.monthly-chart {
    margin: 20px 0;
}

.monthly-chart h4 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
    text-align: center;
}

.monthly-chart .chart-container {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

#monthlyChart {
    max-width: 100%;
    height: auto;
}

/* 알림 모달 스타일 */
.notification-modal {
    max-width: 400px;
    text-align: center;
}

.notification-content {
    padding: 20px;
}

.notification-icon {
    font-size: 48px;
    color: #ff6b6b;
    margin-bottom: 16px;
}

.notification-content h3 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.notification-content p {
    color: #666;
    margin-bottom: 24px;
    line-height: 1.5;
}

.notification-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.notification-actions .btn {
    margin: 0;
}

/* 시간 입력 필드 스타일 */
.form-group input[type="time"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 16px;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.form-group input[type="time"]:focus {
    outline: none;
    border-color: #ff6b6b;
}

/* 프로필 사진 관련 스타일 */
.profile-photo-section {
    margin-bottom: 20px;
    text-align: center;
}

.profile-photo-container {
    position: relative;
    display: inline-block;
    margin-bottom: 16px;
}

.profile-photo-container img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #667eea;
}

.profile-photo-placeholder {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #e1e5e9;
    color: #999;
    font-size: 24px;
}

.profile-photo-actions {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.profile-photo-actions .btn {
    padding: 8px 16px;
    font-size: 14px;
}

/* 메인페이지 사용자 아바타 스타일 */
.user-avatar {
    position: relative;
    width: 50px;
    height: 50px;
}

.user-avatar img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #667eea;
}

.user-photo-placeholder {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e1e5e9;
    color: #999;
    font-size: 18px;
}

/* 저작권 정보 */
.copyright {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid #e1e5e9;
    padding: 12px 20px;
    text-align: center;
    z-index: 1000;
}

.copyright p {
    margin: 0;
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

/* 아이들 친화적인 스타일 */
.welcome-message h3 {
    color: #667eea;
    font-size: 24px;
    margin-bottom: 8px;
}

.welcome-message p {
    color: #666;
    font-size: 16px;
    margin: 0;
}

.quick-actions .btn {
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    padding: 16px 20px;
    transition: all 0.3s ease;
}

.quick-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
}

.btn-secondary {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border: none;
    color: white;
}

/* 달력 아이들 친화적 스타일 */
.calendar-legend h4 {
    color: #667eea;
    font-size: 18px;
    font-weight: 700;
}

.legend-item span {
    font-size: 14px;
    font-weight: 600;
    color: #333;
}

/* 통계 카드 아이들 친화적 스타일 */
.stat-card {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(252, 182, 159, 0.3);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(252, 182, 159, 0.4);
}

.stat-card:nth-child(2) {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
    box-shadow: 0 4px 15px rgba(168, 237, 234, 0.3);
}

.stat-card:nth-child(2):hover {
    box-shadow: 0 8px 25px rgba(168, 237, 234, 0.4);
}

.stat-card:nth-child(3) {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
    box-shadow: 0 4px 15px rgba(255, 154, 158, 0.3);
}

.stat-card:nth-child(3):hover {
    box-shadow: 0 8px 25px rgba(255, 154, 158, 0.4);
}

.stat-info h3 {
    color: #333;
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.stat-info p {
    color: #666;
    font-size: 14px;
    font-weight: 600;
    margin: 0;
}

/* 치료못함 체크박스 스타일 */
.no-treatment-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.no-treatment-checkbox:hover {
    background: #e9ecef;
    border-color: #ff6b6b;
}

.no-treatment-checkbox input[type="checkbox"] {
    margin: 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.no-treatment-checkbox:has(input[type="checkbox"]:checked) {
    background: #ff6b6b;
    border-color: #ff6b6b;
    color: white;
}

.no-treatment-checkbox:has(input[type="checkbox"]:checked) label {
    color: white;
    font-weight: 600;
}

.no-treatment-checkbox label {
    margin: 0;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

.settings-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    border-color: #667eea;
}

.settings-card i {
    color: #667eea;
    font-size: 20px;
    margin-bottom: 8px;
}

.settings-card span {
    color: #333;
    font-weight: 600;
}

/* 별모으기 스타일 */
.star-collection {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    border-radius: 16px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 4px 15px rgba(252, 182, 159, 0.3);
    text-align: center;
}

.star-collection h4 {
    color: #333;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
}

.star-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.star-count {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.star-count span:first-child {
    font-size: 48px;
    font-weight: 700;
    color: #ff6b6b;
    text-shadow: 2px 2px 4px rgba(255, 107, 107, 0.3);
}

.star-label {
    font-size: 18px;
    font-weight: 600;
    color: #666;
}

.star-progress {
    width: 100%;
    max-width: 300px;
}

.star-bar {
    width: 100%;
    height: 12px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}

.star-fill {
    height: 100%;
    background: linear-gradient(90deg, #ffd700 0%, #ffed4e 100%);
    border-radius: 6px;
    transition: width 0.5s ease;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4);
}

.star-message {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}


/* 프로필 이미지 관련 스타일 */
.profile-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.profile-image-container {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.profile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.profile-image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 50%;
    cursor: pointer;
}

.profile-image-container:hover .profile-image-overlay {
    opacity: 1;
}

.profile-image-upload {
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.profile-image-upload:hover {
    color: #ffd700;
}

.profile-info {
    text-align: center;
    margin-bottom: 30px;
}

.profile-info h3 {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

.profile-info p {
    font-size: 16px;
    color: #666;
    margin: 0;
}

/* 헤더 프로필 이미지 스타일 */
.header-profile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* 별 카드 스타일 */
.star-card {
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    border: 2px solid #ffd700;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}

.star-card .stat-icon {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.star-card .stat-info h3 {
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.star-card .stat-info p {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 600;
}
