/* FarmDay v2.59 — loaded LAST, inlined for cache-safe nighttime fixes. */
@layer fd259fix{}
/* Unified dark footer — every page using farmgo_footer(). */
html[data-theme="dark"] body .workspace>.fg-footer,
html[data-theme="dark"] body .fg-footer,
html[data-theme="dark"] body.portal-page .fg-footer {
 background:linear-gradient(170deg,#203a2c,#13251b)!important;
 background-color:#1b3025!important;
 border:1px solid #46654e!important;
 border-radius:16px!important;
 box-shadow:0 9px 24px #0004!important;
 color:#edf6e7!important;
}
html[data-theme="dark"] body .fg-footer .fg-footer-top,
html[data-theme="dark"] body .fg-footer .footer-links,
html[data-theme="dark"] body .fg-footer .fg-footer-bottom {border-color:#46634d!important}
html[data-theme="dark"] body .fg-footer :is(.fg-footer-intro,.fg-footer-intro p,.fg-footer-bottom,.fg-footer-bottom small,.fg-footer-bottom span) {color:#c8d9c7!important}
html[data-theme="dark"] body .fg-footer .footer-links a,
html[data-theme="dark"] body .fg-footer .footer-links a:visited {color:#e2f3df!important;opacity:1!important;text-decoration:none!important}
html[data-theme="dark"] body .fg-footer .footer-links a:hover {color:#ffffff!important;background:#32523b!important}
html[data-theme="dark"] body .fg-footer .fg-footer-rewards,
html[data-theme="dark"] body .fg-footer .fg-footer-rewards:visited {
 background:linear-gradient(145deg,#315e3f,#214730)!important;
 border:1px solid #709774!important;
 color:#f9fae7!important;
 box-shadow:none!important;
 opacity:1!important;
}
html[data-theme="dark"] body .fg-footer .fg-footer-rewards span {color:#f9fae7!important}
html[data-theme="dark"] body .fg-footer .fd13-brand small,
html[data-theme="dark"] body .fg-footer .fg-brand-tagline {color:#cedfc5!important}
/* Farm overview / access shortcuts — bright cream on dark background fixed. */
html[data-theme="dark"] body #main .farm-links626 .activity-card,
html[data-theme="dark"] body #main .farm-links626.cards>article.card,
html[data-theme="dark"] body #main .activity-card {
 background:#21392c!important;border-color:#557159!important;color:#ebf5e8!important;
 box-shadow:0 3px 12px #0002!important;
}
html[data-theme="dark"] body #main .farm-links626 .activity-card :is(h3,h2,strong,b),
html[data-theme="dark"] body #main .activity-card :is(h3,h2,strong,b){color:#f0f8e9!important;opacity:1!important}
html[data-theme="dark"] body #main .farm-links626 .activity-card :is(p,small),
html[data-theme="dark"] body #main .activity-card :is(p,small){color:#c4d8c6!important;opacity:1!important}
html[data-theme="dark"] body #main .farm-links626 .activity-card .activity-top,
html[data-theme="dark"] body #main .farm-links626 .activity-card .activity-top small{color:#d7e6d0!important}
html[data-theme="dark"] body #main .fd-decor-slots .fd-decor {
 background:#243d30!important;color:#e8f6df!important;border-color:#55735b!important;
}
html[data-theme="dark"] body #main .fd-decor-slots .fd-decor :is(strong,small){color:#e3f0db!important;opacity:1!important}
/* Missions: first steps / rewards / states. */
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .grid3>.panel,
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .grid3>article,
html[data-theme="dark"] body #main .fd255-missions .fd255-starter [data-mission-period="starter"],
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .welcome-mission,
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .welcome-mission-card {
 background:#213a2c!important;background-image:none!important;
 border:1px solid #56745b!important;color:#ecf6e9!important;
 box-shadow:0 3px 12px #0002!important;
 opacity:1!important;
}
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .panel :is(h2,h3,h4,strong,b,span),
html[data-theme="dark"] body #main .fd255-missions .fd255-starter [data-mission-period="starter"] :is(h2,h3,h4,strong,b) {
 color:#f2f9ed!important;opacity:1!important;
}
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .panel :is(p,small,label),
html[data-theme="dark"] body #main .fd255-missions .fd255-starter [data-mission-period="starter"] :is(p,small,label) {
 color:#c9dac9!important;opacity:1!important;
}
html[data-theme="dark"] body #main .fd255-missions .fd255-starter :is(.reward,.pill,.status,.mission-progress,.mission-reward) {
 background:#34523c!important;color:#f3f7e8!important;border-color:#719174!important;
}
html[data-theme="dark"] body #main .fd255-missions .fd255-starter .btn:not(:disabled) {color:white!important;background:#326c49!important;border-color:#6b9b73!important}
/* Real-money prizes — avoid washed-out cream blocks and pale player names. */
html[data-theme="dark"] body #main .fd-first,
html[data-theme="dark"] body #main .fd255-missions .fd-first {background:#1c3226!important;border-color:#4e6b53!important;color:#eff7e9!important}
html[data-theme="dark"] body #main .fd-first .fd-prize-category .fd-prize-grid>article,
html[data-theme="dark"] body #main .fd-first .fd-prize-grid article {
 background:#263e2e!important;background-image:none!important;
 color:#f4f8e9!important;border:1px solid #5d795c!important;
 box-shadow:0 3px 10px #0002!important;
}
html[data-theme="dark"] body #main .fd-first .fd-prize-category :is(h2,h3,strong,b),
html[data-theme="dark"] body #main .fd-first .fd-prize-grid article :is(h2,h3,strong,b),
html[data-theme="dark"] body #main .fd-first .fd13-race :is(b,strong,small,li){color:#eef7e9!important;opacity:1!important}
html[data-theme="dark"] body #main .fd-first .fd-prize-grid article :is(p,small,span),
html[data-theme="dark"] body #main .fd-first .fd13-own-progress,
html[data-theme="dark"] body #main .fd-first .fd13-race-empty{color:#c8d9c5!important;opacity:1!important}
html[data-theme="dark"] body #main .fd-first .fd-prize-grid article .fd-prize-status {
 color:#f4d98e!important;letter-spacing:.035em;
}
html[data-theme="dark"] body #main .fd-first .fd-prize-grid article>strong {color:#ffdb83!important}
html[data-theme="dark"] body #main .fd-first .fd13-race,
html[data-theme="dark"] body #main .fd-first .fd13-race li,
html[data-theme="dark"] body #main .fd-first .fd-prize-category>h3 {border-color:#4b684f!important}
html[data-theme="dark"] body #main .fd-first .fd13-race progress {accent-color:#8cc170!important}
html[data-theme="dark"] body #main .fd-first .fd-prize-tabs16 button[aria-selected="false"] {
 background:#294332!important;color:#e7f2dd!important;border-color:#647b61!important;
}
html[data-theme="dark"] body #main .fd-first .fd-prize-tabs16 button[aria-selected="true"] {
 background:#346f4c!important;color:white!important;border-color:#a6ca7f!important;
}
/* No layout/color changes in daylight. */
/* Polished footer layout: no oversized empty card below its content. */
html[data-theme="dark"] body .fg-footer{
 padding:19px 22px 18px!important;
 margin-top:24px!important;
}
html[data-theme="dark"] body .fg-footer .fg-footer-top{
 display:flex!important;justify-content:space-between!important;
 gap:12px!important;align-items:center!important;
}
html[data-theme="dark"] body .fg-footer .fg-footer-rewards{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 min-height:38px!important;padding:9px 13px!important;border-radius:10px!important;
 background-color:#2a5139!important;
 text-decoration:none!important;font-weight:700!important;line-height:1.3!important;
}
html[data-theme="dark"] body .fg-footer .footer-links{
 display:flex!important;flex-wrap:wrap!important;justify-content:center!important;
 padding:11px 0!important;gap:6px 11px!important;margin-top:12px!important;
}
html[data-theme="dark"] body .fg-footer .footer-links a{
 min-height:29px!important;width:auto!important;padding:5px 9px!important;
 background:#254232!important;border:1px solid #3e6347!important;
 color:#e7f4dd!important;line-height:1.25!important;
}
html[data-theme="dark"] body .fg-footer .fg-footer-bottom{
 display:flex!important;flex-wrap:wrap!important;justify-content:space-between!important;
 padding-top:10px!important;gap:3px 14px!important;
}
@media(max-width:760px){
 html[data-theme="dark"] body .workspace>.fg-footer,
 html[data-theme="dark"] body .fg-footer{
   padding:17px 16px 16px!important;
   margin:20px auto calc(145px + env(safe-area-inset-bottom))!important;
   max-width:calc(100% - 12px)!important;
 }
 html[data-theme="dark"] body .fg-footer .fg-footer-top{
   flex-direction:column!important;align-items:flex-start!important;
 }
 html[data-theme="dark"] body .fg-footer .footer-links{
   display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
   gap:6px!important;justify-content:stretch!important;
 }
 html[data-theme="dark"] body .fg-footer .footer-links a{
   justify-content:center!important;text-align:center!important;min-width:0!important;
 }
}
