:root { --ink: #12395c; --muted: #46688a; --accent: #14679b; --card: rgb(255 255 255 / .82); --top: #c9eefb; --bottom: #8fd0ee; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; color: var(--ink); font: 1rem/1.5 ui-rounded, "Nunito", "Segoe UI", system-ui, sans-serif; background: linear-gradient(var(--top), var(--bottom)) fixed; overflow-x: hidden; }
.mood-sobbing { --top: #aebcd3; --bottom: #7489ad; --muted: #2a4565; }
.mood-crying { --top: #b9c9de; --bottom: #7f9cc2; --muted: #2f4c6d; }
.mood-teary { --top: #bfd0e4; --bottom: #87a8cc; --muted: #2f4c6d; }
.mood-sad { --top: #c3d6ea; --bottom: #8fb4d6; --muted: #34536f; }
.mood-glum { --top: #c5dff0; --bottom: #8dbee0; }
.mood-calm { --top: #c8ebf7; --bottom: #8bcbe8; }
.mood-happy { --top: #cdf3f5; --bottom: #86d8de; }
.mood-joyful { --top: #f3f3e1; --bottom: #84dcdc; }
.mood-radiant { --top: #fff0d9; --bottom: #82dfdc; }
header, main { position: relative; width: min(960px, 100% - 32px); margin: auto; }
header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 24px; padding: 16px 0; }
.brand { font-size: 1.25rem; font-weight: 800; color: inherit; text-decoration: none; }
nav { display: flex; flex-wrap: wrap; gap: 4px 18px; align-items: center; }
a, .link { color: var(--ink); }
.link { all: unset; cursor: pointer; text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 8px; text-wrap: balance; }
h3 { font-size: 1rem; color: var(--muted); }
p { margin: 0 0 8px; }
.hero { text-align: center; padding: 8px 0 32px; }
.hero h1 { font-size: clamp(1.5rem, 5vw, 2.2rem); }
.timer { display: flex; justify-content: center; gap: clamp(14px, 5vw, 36px); margin: 8px 0 0; }
.timer span { display: grid; min-width: 2.6rem; }
.timer b { font-size: clamp(2rem, 8vw, 3.2rem); line-height: 1.1; font-variant-numeric: tabular-nums; }
.timer small, .caption { color: var(--ink); }
.caption { font-size: 1.15rem; font-weight: 600; }
.creature { display: block; width: min(460px, 100%); max-height: 52vh; margin: 8px auto; overflow: visible; animation: float 5s ease-in-out infinite; }
.mood-joyful .creature, .mood-radiant .creature { animation-duration: 3s; }
.mood-sobbing .creature { animation: sob .5s ease-in-out infinite; }
.stream-flow { animation: flow .6s linear infinite; }
.fountain { animation: spray .5s linear infinite; }
.wail { animation: wail .9s ease-in-out infinite; transform-box: fill-box; transform-origin: top center; }
.sparkles { animation: twinkle 2s ease-in-out infinite alternate; }
.happiness { display: flex; justify-content: center; align-items: center; gap: 10px; font-size: 1.4rem; }
progress { appearance: none; width: min(280px, 60%); height: 12px; border: 0; border-radius: 9px; overflow: hidden; background: rgb(255 255 255 / .6); }
progress::-webkit-progress-bar { background: rgb(255 255 255 / .6); }
progress::-webkit-progress-value { background: var(--accent); border-radius: 9px; }
progress::-moz-progress-bar { background: var(--accent); border-radius: 9px; }
.actions, .creatures, .row-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions, .creatures { justify-content: center; margin-top: 18px; }
button, .button { display: inline-block; font: inherit; font-weight: 600; padding: 8px 16px; border: 2px solid transparent; border-radius: 99px; color: var(--ink); background: rgb(255 255 255 / .75); text-decoration: none; cursor: pointer; white-space: nowrap; }
button:hover, .button:hover { background: #fff; }
.primary { background: var(--accent); color: #fff; }
.primary:hover { background: #0e5583; }
.danger { color: #a3263f; }
[aria-pressed="true"] { border-color: var(--accent); background: #fff; }
:focus-visible { outline: 3px solid #0b4f7d; outline-offset: 2px; }
.card, .message { background: var(--card); border-radius: 24px; padding: clamp(18px, 4vw, 30px); margin-bottom: 20px; }
.message { padding: 10px 20px; }
.narrow { max-width: 460px; margin-inline: auto; }
.record { text-align: center; }
.big { font-size: 2.6rem; font-weight: 800; line-height: 1.1; }
.pill { padding: 4px 14px; border-radius: 99px; background: var(--card); }
.chart { width: 100%; margin-bottom: 12px; font-size: 13px; }
.chart text { fill: var(--muted); text-anchor: middle; }
.axis { stroke: #b4cbdd; }
.fill { fill: #2a78b8; }
.hit { fill: transparent; }
.bar:hover .hit { fill: rgb(42 120 184 / .1); }
.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 8px 10px; text-align: right; white-space: nowrap; border-bottom: 1px solid #d5e4ef; }
th:first-child { text-align: left; }
td[colspan] { color: var(--muted); }
.title { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.rows { list-style: none; padding: 0; margin: 16px 0 0; }
.rows li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 0; border-top: 1px solid #d5e4ef; }
.grow { flex: 1 1 280px; min-width: 0; overflow-wrap: anywhere; }
.revoked { color: var(--muted); }
small { color: var(--muted); }
.fields p { display: grid; gap: 4px; margin: 0 0 14px; }
.fields label { font-weight: 600; }
.inline { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.inline p { flex: 1 1 220px; margin: 0; }
input { font: inherit; width: 100%; padding: 9px 12px; color: var(--ink); background: #fff; border: 1px solid #8fb1cb; border-radius: 12px; }
fieldset { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; border: 0; padding: 0; margin: 0 0 8px; }
legend { font-weight: 600; margin-bottom: 4px; }
fieldset label { font-weight: 400; }
.errorlist { color: #a3263f; font-weight: 600; list-style: none; padding: 0; margin: 4px 0; }
.helptext, .helptext ul { color: var(--muted); font-size: .9rem; }
.login .creature { max-height: 34vh; }
.bubbles { position: fixed; inset: 0; pointer-events: none; overflow: hidden; }
.bubbles i { position: absolute; bottom: -40px; width: 18px; aspect-ratio: 1; border: 2px solid rgb(255 255 255 / .7); border-radius: 50%; animation: rise 16s linear infinite; }
.bubbles i:nth-child(1) { left: 6%; }
.bubbles i:nth-child(2) { left: 21%; width: 10px; animation-delay: -5s; }
.bubbles i:nth-child(3) { left: 43%; width: 26px; animation-delay: -11s; }
.bubbles i:nth-child(4) { left: 64%; width: 12px; animation-delay: -3s; }
.bubbles i:nth-child(5) { left: 81%; width: 22px; animation-delay: -8s; }
.bubbles i:nth-child(6) { left: 94%; animation-delay: -13s; }
.tear { animation: fall 1.6s ease-in infinite; }
.late { animation-delay: -.8s; }
.fin-left, .fin-right, .tail { animation: wave 3s ease-in-out infinite alternate; transform-box: fill-box; }
.fin-left { transform-origin: right center; --turn: 7deg; }
.fin-right { transform-origin: left center; --turn: -7deg; }
.tail { transform-origin: top center; --turn: 4deg; }
@keyframes float { 50% { transform: translateY(-12px); } }
@keyframes rise { to { transform: translate(24px, -110vh); opacity: 0; } }
@keyframes fall { 0% { transform: translateY(-4px); opacity: 0; } 20% { opacity: 1; } 100% { transform: translateY(80px); opacity: 0; } }
@keyframes sob { 0%, 100% { transform: translate(0, 0) rotate(0); } 25% { transform: translate(-4px, 2px) rotate(-1deg); } 75% { transform: translate(4px, 2px) rotate(1deg); } }
@keyframes flow { to { stroke-dashoffset: -22; } }
@keyframes spray { to { stroke-dashoffset: -36; } }
@keyframes wail { 50% { transform: scaleY(.85); } }
@keyframes twinkle { to { opacity: .3; } }
@keyframes wave { from { transform: rotate(0); } to { transform: rotate(var(--turn)); } }
@media (prefers-reduced-motion: reduce) { *, .bubbles i { animation: none !important; } }
