/* Shared account-backed weekly goal component. */
.weekly-goal { perspective: 1000px; }
.goal-turn { display: grid; transform-style: preserve-3d; transition: transform .38s ease; }
.weekly-goal.is-editing .goal-turn { transform: rotateY(180deg); }
.goal-front, .goal-back { grid-area: 1 / 1; display: grid; align-content: start; gap: 12px; min-width: 0; backface-visibility: hidden; background: #FBF5EA; }
.goal-back { transform: rotateY(180deg); }
.goal-progress { display: flex; gap: 3px; }
.goal-progress i { height: 22px; flex: 1; border-radius: 3px; background: linear-gradient(to right, var(--primary, #C13A63) var(--fill, 0%), #EADFCB var(--fill, 0%)); }
.goal-back label, .goal-back small { color: #6E6559; font: 12px/1.5 Geist, sans-serif; }
.goal-back input { width: 100%; min-width: 0; box-sizing: border-box; padding: 10px; border: 1px solid #C9C0AE; border-radius: 8px; background: #FFFAF2; color: #1C1815; font: 28px Georgia, serif; }
.goal-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-bottom: 4px; }
.goal-cancel { background: none; border: 0; padding: 8px 0; color: var(--primary-container, #B61D55); font: 600 12px Geist, sans-serif; cursor: pointer; }
.goal-edit { justify-self: end; margin-bottom: 4px; }
.goal-percent { font-weight: inherit; }
.goal-error { color: #A33E22; font-size: 13px; }
.goal-error:empty { display: none; }

@media (prefers-reduced-motion: reduce) { .goal-turn { transition: none; } }


.weekly-goal .goal-edit:disabled { opacity: .45; cursor: not-allowed; color: #6E6559; }
.goal-owner { color: #6E6559; font-size: 12px; line-height: 1.5; }
.weekly-goal[data-goal-reached="true"] .goal-headline { color: #94711f; font-weight: 750; }
.weekly-goal[data-goal-reached="true"] .goal-progress i { background: #dfb74d; }
