:root {
    --bg: #fff533;
    --fg: #1a1605;
    --muted: #6b6433;
    --link: #1a1605;
    --link-hover: #000000;
    --rule: rgba(0, 0, 0, 0.18);
    --selection: rgba(0, 0, 0, 0.18);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

::selection {
    background: var(--selection);
    color: var(--fg);
}

html, body {
    height: 100%;
}

body {
    background:
        radial-gradient(ellipse 90% 70% at 25% 20%, rgba(255, 255, 255, 0.85) 0%, rgba(255, 255, 255, 0) 60%),
        radial-gradient(ellipse 70% 60% at 80% 80%, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0) 55%),
        var(--bg);
    background-attachment: fixed;
    color: var(--fg);
    font-family: ui-monospace, "SF Mono", "JetBrains Mono", "Fira Code", Menlo, Consolas, monospace;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

main {
    min-height: 100%;
    max-width: 36rem;
    margin: 0 auto;
    padding: 3rem 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.5rem;
}

header {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.avatar {
    width: 80px;
    height: 80px;
    display: block;
    user-select: none;
    -webkit-user-drag: none;
    cursor: pointer;
    transition: transform 120ms ease;
}

.avatar:active {
    transform: scale(0.94);
}

.heart {
    position: fixed;
    pointer-events: none;
    user-select: none;
    font-size: 1.5rem;
    line-height: 1;
    z-index: 100;
    animation: heart-burst 1.4s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
    will-change: transform, opacity;
}

@keyframes heart-burst {
    0% {
        transform: translate(-50%, -50%) scale(0.4) rotate(0);
        opacity: 0;
    }
    15% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.1) rotate(0);
    }
    100% {
        transform: translate(calc(-50% + var(--drift-x)), calc(-50% + var(--drift-y))) scale(0.7) rotate(var(--rot));
        opacity: 0;
    }
}

header h1 {
    font-size: 1.25rem;
    font-weight: 500;
    letter-spacing: -0.01em;
}

section p {
    font-size: 1rem;
    color: var(--fg);
}

a {
    color: var(--link);
    text-decoration: underline;
    text-decoration-color: var(--muted);
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    transition: color 120ms ease, text-decoration-color 120ms ease;
}

a:hover,
a:focus-visible {
    color: var(--link-hover);
    text-decoration-color: var(--link-hover);
}

a:focus-visible {
    outline: 1px solid var(--link-hover);
    outline-offset: 4px;
    border-radius: 2px;
}

footer {
    padding-top: 3rem;
    border-top: 1px solid var(--rule);
}

.muted {
    color: var(--muted);
    font-size: 0.875rem;
}

@media (max-width: 480px) {
    main {
        padding: 2rem 1.25rem;
    }

    header h1 {
        font-size: 1.125rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}
