/* ===== DASHBOARD PAGE STYLES ===== */

/* ===== 공통 컴포넌트 (meal-record.css에서 참조) ===== */
.back-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 8px 16px;
    border-radius: 50px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: all 0.2s ease;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.6);
    color: #ec4899;
}

.page-title-area { margin-top: 1.5rem; }

.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    animation: overlayFadeIn 0.2s ease;
}

.modal-overlay.hidden { display: none; }

@keyframes overlayFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-sheet {
    background: white;
    border-radius: 24px 24px 0 0;
    padding: 24px;
    width: 100%;
    max-width: 480px;
    animation: sheetSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.1);
}

@keyframes sheetSlideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

.modal-handle {
    width: 36px;
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    margin: 0 auto 16px;
}

.modal-title {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 20px;
}

/* ===== 헤더 ===== */
.dashboard-header {
    padding-bottom: 2rem;
}

.dashboard-header .page-title-area {
    margin-top: 1.5rem;
    text-align: left;
}

.dashboard-header h1 {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ec4899, #a855f7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
    margin: 0 0 6px;
}

.dashboard-header .subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* ===== SECTION A: 목표 상태 ===== */
.goal-section {
    margin-bottom: 1.25rem;
    animation: slideUp 0.5s ease-out both;
    animation-delay: 0.05s;
}

.goal-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 24px;
    padding: 24px 20px 20px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 4px 24px rgba(168, 85, 247, 0.1), 0 1px 4px rgba(0,0,0,0.05);
    position: relative;
    overflow: hidden;
}

.goal-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ec4899, #a855f7, #6366f1);
    border-radius: 24px 24px 0 0;
}

.goal-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.goal-card-label {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.goal-diet-badge {
    font-size: 0.78rem;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(236,72,153,0.12), rgba(168,85,247,0.12));
    color: #a855f7;
    border: 1px solid rgba(168,85,247,0.2);
    padding: 4px 12px;
    border-radius: 20px;
}

/* 도넛 차트 */
.goal-chart-wrap {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 0 auto 20px;
}

.goal-chart-wrap canvas {
    width: 100% !important;
    height: 100% !important;
}

.goal-chart-center {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    pointer-events: none;
}

.goal-cal-value {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.goal-cal-unit {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-top: 4px;
    white-space: nowrap;
}

/* 매크로 범례 */
.goal-legend {
    display: flex;
    justify-content: space-around;
    gap: 8px;
    padding: 16px 8px 4px;
    border-top: 1px solid rgba(0,0,0,0.05);
}

.goal-legend-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.legend-color-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.legend-carbs .legend-color-dot { background: #FF6B8A; }
.legend-protein .legend-color-dot { background: #A78BFA; }
.legend-fat .legend-color-dot { background: #FBBF24; }

.legend-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.legend-name {
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-muted);
}

.legend-grams {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-color);
    font-family: 'Outfit', 'Inter', sans-serif;
    transition: all 0.4s ease;
}

.legend-pct {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-muted);
    background: rgba(0,0,0,0.04);
    padding: 2px 7px;
    border-radius: 10px;
}

/* 미완성 프로필 안내 */
.goal-incomplete-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 16px;
    padding: 10px 14px;
    background: rgba(99, 102, 241, 0.07);
    border-radius: 10px;
    border: 1px solid rgba(99, 102, 241, 0.12);
    color: #6366f1;
    font-size: 0.8rem;
    font-weight: 500;
}

/* ===== SECTION B: 핵심 지표 ===== */
.key-metrics-section {
    margin-bottom: 1.25rem;
    animation: slideUp 0.5s ease-out both;
    animation-delay: 0.12s;
}

.metrics-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.metric-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    padding: 18px 16px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    position: relative;
    overflow: hidden;
}

.metric-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.metric-icon-wrap {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.weight-icon {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    color: #059669;
}

.diet-icon {
    background: linear-gradient(135deg, #ede9fe, #ddd6fe);
    color: #7c3aed;
}

.metric-card-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

/* 체중 카드 */
.weight-metric-card {
    display: flex;
    flex-direction: column;
}

.metric-record-btn.hidden {
    display: none;
}

.metric-value-row {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: 10px;
}

.metric-value {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1;
    transition: all 0.3s ease;
}

.metric-unit {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
}

.metric-record-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    width: fit-content;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.metric-record-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.metric-record-btn:active {
    transform: scale(0.96);
}

/* 인라인 체중 입력 */
.weight-input-wrap {
    margin-top: 10px;
    animation: expandDown 0.25s ease-out;
}

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

.weight-input-row {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(0,0,0,0.04);
    border-radius: 12px;
    padding: 8px 12px;
    border: 1.5px solid rgba(16, 185, 129, 0.3);
    margin-bottom: 8px;
}

.weight-input {
    background: none;
    border: none;
    outline: none;
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-color);
    width: 100%;
    min-width: 0;
}

.weight-input::placeholder { color: rgba(0,0,0,0.2); }

.weight-input::-webkit-inner-spin-button,
.weight-input::-webkit-outer-spin-button { -webkit-appearance: none; }

.weight-input-unit {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    flex-shrink: 0;
}

.weight-input-actions {
    display: flex;
    gap: 6px;
}

.input-cancel-btn {
    flex: 1;
    background: rgba(0,0,0,0.06);
    border: none;
    border-radius: 9px;
    padding: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s;
}

.input-cancel-btn:hover { background: rgba(0,0,0,0.1); }

.input-save-btn {
    flex: 1.5;
    background: linear-gradient(135deg, #10b981, #059669);
    border: none;
    border-radius: 9px;
    padding: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    box-shadow: 0 2px 6px rgba(16,185,129,0.25);
}

.input-save-btn:hover { transform: translateY(-1px); }
.input-save-btn:active { transform: scale(0.97); }

/* 식단 타입 카드 */
.diet-metric-card {
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.diet-metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(168, 85, 247, 0.15);
}

.diet-metric-card:active { transform: scale(0.98); }

.diet-type-name-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.diet-type-name {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1;
}

.chevron-icon {
    color: var(--text-muted);
    opacity: 0.6;
    flex-shrink: 0;
}

/* 비율 바 */
.diet-type-ratio-bar {
    display: flex;
    height: 6px;
    border-radius: 3px;
    overflow: hidden;
    gap: 2px;
    margin-bottom: 10px;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.ratio-segment {
    border-radius: 3px;
    transition: flex 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.ratio-carbs { background: #FF6B8A; }
.ratio-protein { background: #A78BFA; }
.ratio-fat { background: #FBBF24; }

.diet-type-goal-row {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.diet-goal-badge,
.diet-activity-badge {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 8px;
}

.diet-goal-badge {
    background: rgba(168, 85, 247, 0.1);
    color: #7c3aed;
    border: 1px solid rgba(168,85,247,0.15);
}

.diet-activity-badge {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
    border: 1px solid rgba(16,185,129,0.15);
}

/* ===== SECTION C: 기본 신체 정보 ===== */
.body-info-section {
    margin-bottom: 2rem;
    animation: slideUp 0.5s ease-out both;
    animation-delay: 0.2s;
}

.body-info-card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

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

.body-info-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.edit-icon-btn {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.15);
    color: #6366f1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.edit-icon-btn:hover {
    background: rgba(99, 102, 241, 0.14);
    transform: scale(1.05);
}

.edit-icon-btn:active { transform: scale(0.95); }

/* 정보 표시 */
.info-row {
    display: flex;
    gap: 0;
}

.info-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    padding: 12px 8px;
    border-radius: 14px;
    background: rgba(0,0,0,0.025);
    margin: 0 4px;
    transition: background 0.2s;
}

.info-item:first-child { margin-left: 0; }
.info-item:last-child { margin-right: 0; }

.info-label {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.info-value {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-color);
}

/* 편집 모드 */
.body-info-edit {
    animation: expandDown 0.25s ease-out;
}

.edit-fields {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 20px;
}

.edit-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.edit-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    padding-left: 2px;
}

.edit-input-with-unit {
    display: flex;
    align-items: center;
    background: rgba(0,0,0,0.04);
    border-radius: 12px;
    border: 1.5px solid rgba(99, 102, 241, 0.2);
    padding: 10px 14px;
    gap: 8px;
    transition: border-color 0.2s;
}

.edit-input-with-unit:focus-within {
    border-color: rgba(99, 102, 241, 0.5);
    background: rgba(99, 102, 241, 0.04);
}

.edit-input {
    background: none;
    border: none;
    outline: none;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    width: 100%;
    min-width: 0;
}

.edit-date-input {
    background: rgba(0,0,0,0.04);
    border: 1.5px solid rgba(99, 102, 241, 0.2);
    border-radius: 12px;
    padding: 10px 14px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.edit-date-input:focus {
    outline: none;
    border-color: rgba(99, 102, 241, 0.5);
    background: rgba(99, 102, 241, 0.04);
}

.edit-unit {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    flex-shrink: 0;
}

/* 성별 토글 */
.gender-toggle-group {
    display: flex;
    gap: 8px;
}

.gender-toggle-btn {
    flex: 1;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1.5px solid rgba(0,0,0,0.08);
    background: rgba(0,0,0,0.04);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.gender-toggle-btn.active {
    background: linear-gradient(135deg, rgba(236,72,153,0.1), rgba(168,85,247,0.1));
    border-color: rgba(168, 85, 247, 0.35);
    color: #a855f7;
}

/* 편집 액션 버튼 */
.edit-actions {
    display: flex;
    gap: 10px;
}

.edit-cancel-btn {
    flex: 1;
    padding: 12px;
    border-radius: 12px;
    border: 1.5px solid rgba(0,0,0,0.1);
    background: rgba(0,0,0,0.04);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s;
}

.edit-cancel-btn:hover { background: rgba(0,0,0,0.08); }

.edit-save-btn {
    flex: 2;
    padding: 12px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    font-size: 0.9rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.edit-save-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(99, 102, 241, 0.35); }
.edit-save-btn:active { transform: scale(0.98); }

/* ===== 식단 설정 모달 ===== */
.diet-settings-sheet {
    max-height: 90vh;
    overflow-y: auto;
    padding-bottom: calc(env(safe-area-inset-bottom) + 16px);
}

.diet-settings-sheet::-webkit-scrollbar { display: none; }

.modal-section {
    margin-bottom: 24px;
}

.modal-section-title {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin: 0 0 12px;
}

/* 식단 타입 그리드 */
.diet-type-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.diet-type-option {
    padding: 14px;
    border-radius: 14px;
    border: 2px solid rgba(0,0,0,0.06);
    background: rgba(0,0,0,0.02);
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.diet-type-option:hover {
    background: rgba(168, 85, 247, 0.06);
    border-color: rgba(168, 85, 247, 0.2);
}

.diet-type-option.selected {
    background: linear-gradient(135deg, rgba(236,72,153,0.08), rgba(168,85,247,0.1));
    border-color: #a855f7;
}

.diet-type-option:active { transform: scale(0.97); }

.diet-option-name {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 4px;
}

.diet-option-desc {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.diet-option-ratio {
    display: flex;
    gap: 2px;
    height: 4px;
    border-radius: 2px;
    overflow: hidden;
    margin-top: 8px;
}

.diet-option-ratio-seg { border-radius: 2px; }
.diet-option-ratio-seg.r-carbs { background: #FF6B8A; }
.diet-option-ratio-seg.r-protein { background: #A78BFA; }
.diet-option-ratio-seg.r-fat { background: #FBBF24; }

.diet-option-check {
    display: none;
    position: absolute;
    top: 10px; right: 10px;
    color: #a855f7;
}

.diet-type-option {
    position: relative;
}

.diet-type-option.selected .diet-option-check { display: block; }

/* 목표 탭 */
.goal-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.goal-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 12px 8px;
    border-radius: 14px;
    border: 2px solid rgba(0,0,0,0.06);
    background: rgba(0,0,0,0.02);
    cursor: pointer;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.goal-tab.active {
    background: linear-gradient(135deg, rgba(236,72,153,0.08), rgba(168,85,247,0.1));
    border-color: #a855f7;
}

.goal-tab:active { transform: scale(0.97); }

.goal-tab-icon { font-size: 1.2rem; }

.goal-tab-name {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-color);
}

.goal-tab-sub {
    font-size: 0.68rem;
    color: var(--text-muted);
}

/* 활동량 리스트 */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.activity-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1.5px solid rgba(0,0,0,0.06);
    background: rgba(0,0,0,0.02);
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    width: 100%;
}

.activity-item.active {
    background: rgba(99, 102, 241, 0.07);
    border-color: rgba(99, 102, 241, 0.25);
}

.activity-item:active { transform: scale(0.99); }

.activity-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.activity-name {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-color);
}

.activity-desc {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.activity-check {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #6366f1;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* 모달 푸터 */
.modal-footer {
    display: flex;
    gap: 10px;
    padding-top: 8px;
}

.modal-cancel-btn {
    flex: 1;
    padding: 14px;
    border-radius: 14px;
    border: 1.5px solid rgba(0,0,0,0.1);
    background: rgba(0,0,0,0.04);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s;
}

.modal-cancel-btn:hover { background: rgba(0,0,0,0.08); }

.modal-save-btn {
    flex: 2;
    padding: 14px;
    border-radius: 14px;
    border: none;
    background: linear-gradient(135deg, #ec4899, #a855f7);
    font-size: 0.95rem;
    font-weight: 700;
    color: white;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
}

.modal-save-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(168, 85, 247, 0.4); }
.modal-save-btn:active { transform: scale(0.98); }

/* ===== 토스트 ===== */
.toast {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(0);
    background: rgba(30, 41, 59, 0.92);
    backdrop-filter: blur(12px);
    color: white;
    padding: 12px 22px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    z-index: 9999;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.toast.hidden {
    opacity: 0;
    transform: translateX(-50%) translateY(12px);
    pointer-events: none;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.toast.success { background: rgba(16, 185, 129, 0.92); }
.toast.error { background: rgba(239, 68, 68, 0.92); }

/* ===== 스켈레톤 로딩 ===== */
.skeleton {
    background: linear-gradient(90deg, rgba(0,0,0,0.06) 25%, rgba(0,0,0,0.1) 50%, rgba(0,0,0,0.06) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
    display: inline-block;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ===== 반응형 ===== */
@media (max-width: 360px) {
    .metrics-grid { grid-template-columns: 1fr; }
    .info-row { flex-direction: column; gap: 8px; }
    .info-item { flex-direction: row; justify-content: space-between; padding: 10px 14px; }
    .goal-type-grid { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 480px) {
    .goal-chart-wrap { width: 200px; height: 200px; }
    .goal-cal-value { font-size: 2rem; }
}
