Models 44

Nemotron 3.5 Lightning (free)

by NVIDIAReasoningClean
Open in new window

Running live in a sandboxed frame. Click inside it before using the keyboard.

How it went

Total time
4 min 21 s
Cost
$0
Output tokens
18,436
Spent thinking
17,337 tokens
Speed
70.6 tok/s
Console errors
0
First token after
248 ms
First visible text after
4 min 9 s
Prompt tokens
375
Code size
3.1 KB
Finish reason
stop
Served by
Nvidia
Model id
nvidia/nemotron-3.5-lightning:free
Reasoning sent
model default
Max output
32,000 tokens
Generated
Nov 9, 2026

What it was asked

The prompt
“a "like" button in pure CSS, no JavaScript, that does a crazy animation when you click it”
System prompt, sent with every prompt
You are generating a self-contained web demo. It will be rendered automatically in a sandboxed iframe and compared side by side with the output of other AI models given the exact same task.

Output rules:
- Reply with exactly ONE fenced code block containing the complete file: ```html (or ```svg when the task asks for an SVG). No text before or after the code block.
- Everything must be inline: CSS in <style>, JavaScript in <script>. No external files, images, fonts or network requests, except the CDN URLs explicitly allowed by the task.
- Do not use localStorage, sessionStorage, cookies, IndexedDB, alert(), confirm(), prompt() or window.open(): they are blocked in the sandbox and will throw.
- The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar.
- Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction.
- Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session.
- Games must start in a self-playing demo mode (a simple AI plays) behind a "Click or press a key to start" message, so the game can be judged in action without playing.
- The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear "Click or press a key to start" message.
- The code must run with zero errors in the console of the latest Chrome.

Code run-1.html · 113 lines

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Crazy CSS Like Button</title>
  <style>
    /* ---- Reset ---- */
    * { box-sizing: border-box; margin: 0; padding: 0; }
    body {
      min-height: 100vh;
      background: #0a0a0f;
      display: flex;
      align-items: center;
      justify-content: center;
      overflow-x: hidden;
      font-family: system-ui, -apple-system, sans-serif;
      color: #ffadad;
    }
    .container {
      position: relative;
      max-width: 380px;
      width: 90%;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 1.2rem;
    }

    /* ---- The Like Button ---- */
    .like-input {
      position: absolute;
      width: 100%;
      height: 100%;
      opacity: 0;
      cursor: pointer;
    }
    .like-btn {
      padding: 14px 28px;
      font-size: 1.3rem;
      font-weight: 700;
      border: none;
      border-radius: 30px;
      background: #e91e63;
      color: #fff;
      transition: transform 0.08s ease, background 0.2s, box-shadow 0.2s;
      box-shadow: 0 6px 20px rgba(233, 30, 99, 0.4);
      cursor: pointer;
    }
    .like-btn:active {
      transform: scale(0.95);
      background: #d81b40;
      box-shadow: 0 4px 10px rgba(216, 27, 64, 0.5);
    }

    /* ---- Crazy Animation on Click ---- */
    .like-input:checked + .like-btn {
      animation: crazyPop 0.65s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
      background: #ffd93d;
      color: #111;
      box-shadow: 0 0 30px rgba(255, 217, 61, 0.5);
    }
    @keyframes crazyPop {
      0%   { transform: scale(1) rotate(0deg); }
      25%  { transform: scale(1.45) rotate(25deg); }
      50%  { transform: scale(1.2) rotate(-10deg); }
      75%  { transform: scale(1.3) rotate(12deg); }
      100% { transform: scale(1) rotate(0deg); }
    }

    /* ---- Floating Hearts ---- */
    .heart {
      position: absolute;
      left: 50%;
      top: 50%;
      transform: translate(-50%, -50%);
      font-size: 1.2rem;
      opacity: 0;
      pointer-events: none;
    }
    .heart::before,
    .heart::after {
      content: '♥';
      position: absolute;
      left: 0;
    }
    .heart::before { color: #ffadad; }
    .heart::after { color: #ff6b6b; transform: rotate(90deg); }

    @keyframes floatAway {
      0%   { opacity: 1; transform: translateY(0) scale(1); }
      100% { opacity: 0; transform: translateY(-120px) scale(0.4); }
    }

    /* ---- Heart stagger delays ---- */
    .like-input:checked ~ .heart {
      animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    }
    .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
    .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.15s; }
    .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.3s; }
  </style>
</head>
<body>
  <div class="container">
    <input type="radio" name="reaction" class="like-input" id="like-input">
    <label for="like-input" class="like-btn">Like</label>
    <span class="heart"></span>
    <span class="heart"></span>
    <span class="heart"></span>
  </div>
</body>
</html>
Reasoning trace (17,337 tokens)
Here's a thinking process:

1.  **Analyze the Request:**
   - User wants a "like" button in pure CSS, no JavaScript
   - It should have a "crazy animation" when clicked
   - Must follow all the strict output rules for the web demo

2.  **Check Constraints:**
   - Output: Exactly ONE fenced code block starting with ```html
   - Everything inline: CSS in `<style>`, JavaScript in `<script>`
   - No external files, images, fonts, network requests except CDN URLs explicitly allowed
   - No localStorage, sessionStorage, cookies, IndexedDB, alert(), confirm(), prompt(), window.open()
   - Must look right in 1280×800 viewport, adapt down to 375px wide, no horizontal scrollbar
   - Something meaningful visible on first paint (screenshot at ~3s)
   - Interesting things visible within first seconds
   - Games must have self-playing demo mode with "Click or press a key to start" - but this is a button, not a game. I need to adapt this: probably need a "Click or press to activate" message initially, but the rule says "if the demo uses the keyboard, display a clear 'Click or press a key to start' message". Since it's a mouse/click interaction, maybe I still need a starter message? Let me re-read: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message". It's about keyboard events. The button will likely use :active or :focus, maybe I should include a focus state. I'll add a "Click or press a key to start" or similar initial message, but maybe I can make it subtle or integrate it.
   - Zero errors in latest Chrome console

   Wait, the "games must start in a self-playing demo mode" and "Click or press a key to start" rules seem specific to games. This is a button demo. I need to interpret the spirit: probably need an initial state that invites interaction. I'll include a subtle prompt like "Click the button" or similar, but ensure it's not violating the rules.

   Actually, re-reading carefully: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message." This means if I use keyboard input, I must show that message. My demo uses mouse click (or touch) on a button. I might not need keyboard interaction at all. But to be safe, I could add a simple focus/keyboard trigger or just have the button respond to :active/:focus and not show the message, or show a generic "Click to animate" message. I'll keep it simple: the button animates on click/press. I'll add a message "Click or press space to animate" maybe, but ensure it's not breaking things.

   Let's look at the core: pure CSS animation on button click. No JS.

3.  **Design the CSS-Only "Like" Button Animation:**
   - I need a button
   - On :active or :focus, trigger a crazy animation
   - Since no JS, I'll use CSS :active, :focus, or :checked with a hidden input trick to trigger keyframe animations
   - "Crazy animation": maybe heart bursts, color explosion, scaling, rotating, morphing, etc.
   - I need to make it work on first paint, visible, no errors.

   Ideas:
   - Use a checkbox hack: `<input type="radio" name="heart">` hidden, and a label that animates when checked. But the prompt says "click it", so maybe just `:active` is enough for a quick burst, but `:active` only lasts while mouse is pressed. To have a persistent animation triggered by click, I need a state toggle. The classic pure CSS trick: use a hidden radio/input, and the label toggles it. On label click, the input state changes, and CSS targets `:checked` to animate.
   - Alternatively, use `:focus` if the button is focusable (e.g., `<button>` element). But `<button>` :focus doesn't toggle a persistent animation easily without JS. However, I can use `:focus-visible` and combine with animation timing.
   - Better: Use the checkbox hack to toggle a "liked" state, and have the animation play when checked.
   - But the rule says "no JavaScript". CSS-only is fine.
   - I'll design a button that, when clicked, triggers a crazy animation using keyframes. I'll use the `:active` for a quick burst, and maybe add a :focus state too. To make it "crazy" and noticeable, I'll do a scaling + color shift + heart explosion using CSS only.
   - Actually, I can simulate a toggle using `:has()`? No, very limited browser support. Checkbox hack is safest.

   Let's plan the HTML structure:
   - A container
   - A hidden radio input
   - A label acting as the button
   - When the radio is checked, the button animates

   Animation ideas:
   - On :checked, the button explodes into a shower of smaller hearts/particles, scales up, changes color, maybe a burst effect.
   - Use keyframes to rotate, scale, translate, change background/color.
   - Use ::before/::after for extra effects.

   Let's keep it simple but "crazy":
   - Default: gray-ish button with "Like" text
   - On click (input becomes :checked), the button transforms: background explodes to a gradient, text becomes "♥", surrounding area gets floating hearts (using CSS ::before/::after with animations), the button itself pulses and rotates.
   - All using keyframes and the :checked state.

   Constraints check:
   - No JS: ✓
   - Pure CSS: ✓
   - Works on click: via checkbox hack
   - Visible on first paint: yes
   - Responsive: yes, viewport units
   - No external files: all inline CSS, maybe system fonts or a Google Font CDN? Rule: "except the CDN URLs explicitly allowed by the task". It doesn't explicitly allow any, but often system fonts are fine, or I can use a web-safe font like system-ui, sans-serif to avoid CDN. I'll use system fonts to be safe.
   - No alert/confirm/prompt: ✓
   - No cookies/localStorage: ✓
   - 1280x800 viewport, adapt to 375px, no horizontal scroll: use max-width, viewport units, box-sizing border-box.
   - Something meaningful on first paint: the button is there.
   - Self-playing demo mode: Not really a game, but I'll have a "Click or press a key to start" message? Maybe I'll phrase it as "Click the button to like" initially, or since it's not a game, I might skip the explicit "Click or press a key to start" but the rule says "if the demo uses the keyboard, display...". My demo doesn't use keyboard input primarily, but I could make it focusable with tab, and show "Press Space to Like". To be safe, I'll include a brief instructional text that disappears or is subtle, or I'll just have the button and maybe a short note "Click or tap". I'll re-read: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message". This seems like a safety rule for keyboard-reliant demos. Since mine is mouse-click based, I might not need it, but I'll add a very minimal "Click or press Space to animate" just in case, but ensure it doesn't break the "no horizontal scroll" etc.

   Actually, to strictly comply, I might avoid any keyboard prompt unless necessary. I'll just have the button with a label "Like". The animation triggers on click. I'll add a note: "The animation plays on click/tap." But maybe better to just make the button self-explanatory.

   Let's design the CSS animation:

   Structure:
   ```html
   <div class="like-container">
     <input type="radio" name="like" class="like-toggle" id="like-btn">
     <label for="like-btn" class="like-btn">Like</label>
   </div>
   ```

   CSS:
   - Reset, box-sizing
   - Container centered, viewport units
   - Input hidden
   - Label styled as button, with transition
   - `:checked` triggers animation keyframes
   - Animation: pulse, color burst, hearts

   Let's flesh out the animation:
   When `:checked`:
   - Button background becomes a vibrant gradient, border disappears
   - Button scales to 1.2x, rotates 15deg
   - Text changes to "♥" or "Liked!"
   - Outward ripple effect using ::before with keyframes
   - Maybe some ::after hearts floating up and fading

   Actually, keeping it to the button itself being "crazy" might be simpler and safer:
   - On :checked, the button undergoes a chaotic transform sequence: background color cycles through a few via animation, border rotates, text morphs, and a burst of small animated elements radiate out.

   Let's use a known pure CSS trick: the "like" button animation from various codepens, but I'll create my own.

   Plan:
   ```html
   <!DOCTYPE html>
   <html lang="en">
   <head>
     <meta charset="UTF-8">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <title>Crazy CSS Like Button</title>
     <style>
       /* reset */
       * { box-sizing: border-box; margin: 0; padding: 0; }
       body { 
         min-height: 100vh; 
         display: flex; 
         align-items: center; 
         justify-content: center; 
         background: #111; 
         color: #fff; 
         font-family: system-ui, sans-serif;
       }
       .like-btn {
         position: relative;
         padding: 16px 32px;
         font-size: 1.2rem;
         font-weight: bold;
         border: none;
         border-radius: 28px;
         background: #e91e63;
         color: #fff;
         cursor: pointer;
         transition: transform 0.1s;
         outline: none;
       }
       .like-btn:active { transform: scale(0.95); }
       
       /* The magic: toggle state */
       .like-btn[type="radio"]:checked + .like-btn {
         /* ... animation ... */
       }
     </style>
   ```

   Wait, I need the checkbox hack correctly:
   ```html
   <input type="radio" class="like-input" id="like-input" hidden>
   <label for="like-input" class="like-btn">Like</label>
   ```
   Then CSS: `.like-input:checked + .like-btn { ... }`

   But `:checked` on radio persists until another is clicked. That's fine for a single button demo.

   Animation on :checked:
   - I'll make the button explode into a heart burst.
   - Use keyframes `burst` that scale out small hearts from the button center.
   - Use keyframes `pulse` on the button itself.
   - Maybe change text to "Liked!" via `::after` content.

   Let's design it step by step.

   HTML:
   ```html
   <div class="demo">
     <input type="radio" name="reaction" id="like" class="reaction-input" hidden>
     <label for="like" class="reaction-btn">Like</label>
   </div>
   ```

   CSS:
   ```css
   .demo { position: relative; padding: 2rem; }
   .reaction-input { position: absolute; opacity: 0; }
   .reaction-btn {
     padding: 1rem 2rem;
     font-size: 1.5rem;
     font-weight: 600;
     border: none;
     border-radius: 30px;
     background: #ff6b6b;
     color: #fff;
     cursor: pointer;
     transition: background 0.2s;
   }
   .reaction-btn:active { background: #ff3b3b; }
   
   /* When checked, trigger crazy animation */
   .reaction-input:checked + .reaction-btn {
     animation: popAndBurst 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
     background: #ffd93d;
     color: #111;
   }
   
   @keyframes popAndBurst {
     0% { transform: scale(1) rotate(0deg); }
     30% { transform: scale(1.3) rotate(10deg); }
     50% { transform: scale(1.1) rotate(-5deg); }
     70% { transform: scale(1.2) rotate(5deg); }
     100% { transform: scale(1) rotate(0deg); }
   }
   
   /* Burst particles */
   .reaction-input:checked + .reaction-btn::before,
   .reaction-input:checked + .reaction-btn::after {
     content: '';
     position: absolute;
     width: 100%; height: 100%;
     border-radius: 30px;
     animation: burstOut 0.6s forwards;
   }
   ```

   This is getting complicated with ::before/::after positioning over the button. Maybe better to have the button itself animate, and some small hearts appear around it using absolute positioning relative to a container.

   Let's simplify drastically. The goal is a "crazy animation when you click it". Pure CSS. No need for complex particle engines. A cool scaling/color/transform + a few decorative elements.

   Revised plan:
   - A button centered on the page.
   - Initially simple.
   - When clicked (via :checked from a hidden radio), the button:
     * Pulses with a gradient shift
     * Rotates slightly
     * Text changes to "♥ Liked!" 
     * Small hearts emerge from the button and fade/float away
   - All using keyframes and the :checked selector.

   To make hearts appear, I can use `::before` and `::after` on the button or container, with keyframes that animate their opacity/scale/translate. But `::before/::after` are only two elements. I can use multiple pseudo-elements via `::first-letter`? No. Better: use a container with `::before` and `::after` that each contain multiple hearts via `::before` of those? Too deep.

   Alternative: Use the `nth-child` of a list, but we need them to appear only on click. I can absolutely position a few `span` elements but that's HTML elements, which is fine as long as no JS. I'll add a few `span.heart` elements in HTML, initially hidden with `opacity: 0`, and on `:checked` they become visible and animate. That's pure CSS, no JS. The rule says "no JavaScript", doesn't forbid HTML elements. It says "Everything must be inline: CSS in <style>, JavaScript in <script>. No external files, images, fonts or network requests". So HTML elements inline are fine.

   Let's do:
   ```html
   <div class="like-wrapper">
     <input type="radio" name="like" id="like-toggle" class="like-input" hidden>
     <label for="like-toggle" class="like-btn">Like</label>
     <span class="heart"></span><span class="heart"></span><span class="heart"></span>
   </div>
   ```
   CSS:
   ```css
   .like-input:checked + .like-btn { ... animate button ... }
   .like-input:checked ~ .heart { ... animate hearts ... }
   ```

   But the `.heart` siblings of the input? The structure: wrapper > input, label, hearts. The hearts are after the label. `.like-input:checked ~ .heart` would select hearts after the input. That works if input is first: `<input ...><label>... hearts`. Then `:checked ~ .heart` selects all hearts after input. I'll use that.

   Let's finalize the design:

   **HTML:**
   ```html
   <!DOCTYPE html>
   <html lang="en">
   <head>
     <meta charset="UTF-8">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <title>Crazy CSS Like Button</title>
     <style>
       /* --- Reset & Base --- */
       * { box-sizing: border-box; margin: 0; padding: 0; }
       body {
         min-height: 100vh;
         display: flex;
         align-items: center;
         justify-content: center;
         background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
         color: #e94560;
         font-family: system-ui, -apple-system, sans-serif;
         overflow-x: hidden;
       }
       .like-wrapper {
         position: relative;
         display: inline-flex;
         flex-direction: column;
         align-items: center;
         gap: 1rem;
       }
       .like-input {
         position: absolute;
         opacity: 0;
         width: 100%; height: 100%;
       }
       .like-btn {
         padding: 14px 32px;
         font-size: 1.4rem;
         font-weight: 700;
         border: none;
         border-radius: 30px;
         background: #e91e63;
         color: #fff;
         cursor: pointer;
         transition: transform 0.1s ease, background 0.2s;
         box-shadow: 0 4px 14px rgba(233, 30, 99, 0.4);
       }
       .like-btn:active {
         transform: scale(0.96);
         background: #d81b40;
       }
       
       /* --- The Crazy Animation on Click --- */
       .like-input:checked + .like-btn {
         animation: crazyPop 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
         background: #ffd93d;
         color: #111;
         box-shadow: 0 0 30px rgba(255, 217, 61, 0.5);
       }
       
       @keyframes crazyPop {
         0%   { transform: scale(1) rotate(0deg); }
         20%  { transform: scale(1.4) rotate(20deg); }
         40%  { transform: scale(1.2) rotate(-15deg); }
         60%  { transform: scale(1.3) rotate(10deg); }
         80%  { transform: scale(1.1) rotate(-5deg); }
         100% { transform: scale(1) rotate(0deg); }
       }
       
       /* --- Floating Hearts --- */
       .heart {
         position: absolute;
         font-size: 1.2rem;
         opacity: 0;
         animation: floatAway 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
         pointer-events: none;
       }
       .heart::before,
       .heart::after {
         content: '♥';
         position: absolute;
         left: 0;
       }
       .heart::before { transform: rotate(0deg); }
       .heart::after { transform: rotate(90deg); }
       
       @keyframes floatAway {
         0%   { opacity: 1; transform: translateY(0) scale(1); }
         100% { opacity: 0; transform: translateY(-100px) scale(0.5); }
       }
       
       /* --- Position hearts randomly around the button initially, then animate on click --- */
       .heart { 
         left: 50%; top: 50%; 
         transform: translate(-50%, -50%);
       }
       .like-input:checked ~ .heart {
         animation: floatAway 0.8s forwards;
         animation-delay: calc(var(--i) * 0.1s);
         --i: var(--idx, 0);
       }
       
       /* Pre-delay for each heart via inline style? But I can't use JS. I'll use nth-child with delays */
       
       /* Actually, I can set --idx using nth-of-type */
       .like-input:checked ~ .heart:nth-child(1) { --idx: 1; }
       .like-input:checked ~ .heart:nth-child(2) { --idx: 2; }
       .like-input:checked ~ .heart:nth-child(3) { --idx: 3; }
       
       /* But CSS variables with :checked and nth-child might not cascade nicely. Let's use explicit delays */
       
       /* Simpler: just give each heart a different animation-delay directly */
       .heart { animation-delay: 0s; }
       .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
       .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.1s; }
       .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.2s; }
     </style>
   </head>
   <body>
     <div class="like-wrapper">
       <input type="radio" name="reaction" class="like-input" id="like-input">
       <label for="like-input" class="like-btn">Like</label>
       <span class="heart"></span>
       <span class="heart"></span>
       <span class="heart"></span>
     </div>
   </body>
   </html>
   ```

   Wait, I need to be careful with CSS variable scope and nth-child in the rule. Actually, I can just set `animation-delay` directly on each `.heart` using inline styles? But the rule says "CSS in <style>". Inline styles (style="") are technically CSS, but usually "inline CSS" means style attributes. To be safe and keep it fully in the `<style>` block, I'll use the `:checked ~ .heart:nth-of-type()` approach, but the `--idx` variable trick might not work as expected because the variable is set on the rule, not cascading from nth-of-type. Let me just give each heart a unique delay directly in the `:checked` rule:

   ```css
   .like-input:checked ~ .heart { animation: floatAway 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }
   .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
   .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.1s; }
   .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.2s; }
   ```

   That should work. The base `.heart` rule sets `animation-name: floatAway;`, and the `:checked` overrides delay. But I need to ensure `animation-name` is set. I'll set it on `.heart` originally.

   Also, the hearts need to be positioned absolutely relative to the wrapper. The wrapper should be relative, and the hearts absolutely positioned with some offset from the button center. I'll position them using `left` and `top` with some random-looking offsets, but since it's pure CSS, I'll use `position: absolute;` and `left: 50%; top: 50%;` then maybe nth-of-type offsets, or just rely on the button's position and have them originate from the button area. Actually, absolute positioning inside a relatively positioned wrapper takes the wrapper as reference. I'll set the wrapper to `position: relative; width: max-content;`, and position the hearts absolutely with some offset, but they'll stack at the same point unless I offset them. I can use `nth-of-type` to offset `left`/`top` slightly.

   Simpler: I'll make the hearts appear right at the button's location by using `::before`/`::after` on the button, but limited to 2 per element. Maybe I'll just do a single burst effect from the button using keyframes that scale and translate the button itself, and maybe a few decorative absolutely positioned elements that fade out.

   Let's rethink to keep it robust and simple.

   **Simpler Approach:**
   - The button itself does the "crazy" animation: scales, rotates, color shifts.
   - Additionally, a few `span` hearts appear and float away. I'll position them using the wrapper's relative positioning and absolute placement with nth-of-type offsets.
   - I'll avoid complex keyframe choreography.

   Let's draft the final code carefully.

   **HTML Structure:**
   ```html
   <!DOCTYPE html>
   <html lang="en">
   <head>
     <meta charset="UTF-8">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <title>Crazy CSS Like Button</title>
     <style>
       /* ---- Reset & Page ---- */
       * { box-sizing: border-box; margin: 0; padding: 0; }
       body {
         min-height: 100vh;
         background: #0d0d0d;
         display: flex;
         align-items: center;
         justify-content: center;
         overflow-x: hidden;
         font-family: system-ui, sans-serif;
         color: #ffadad;
       }
       .container {
         position: relative;
         display: flex;
         flex-direction: column;
         align-items: center;
         gap: 1.5rem;
       }
       .like-input {
         position: absolute;
         width: 100%;
         height: 100%;
         opacity: 0;
         cursor: pointer;
       }
       .like-btn {
         padding: 16px 36px;
         font-size: 1.5rem;
         font-weight: 800;
         border: none;
         border-radius: 34px;
         background: #e91e63;
         color: #fff;
         transition: transform 0.08s ease, background 0.2s;
         box-shadow: 0 6px 20px rgba(233, 30, 99, 0.5);
       }
       .like-btn:active {
         transform: scale(0.95);
         background: #d81b40;
       }
       
       /* ---- Crazy Animation on Click ---- */
       .like-input:checked + .like-btn {
         animation: pop 0.65s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
         background: #ffd93d;
         color: #111;
         box-shadow: 0 0 30px rgba(255, 217, 61, 0.5);
       }
       
       @keyframes pop {
         0%   { transform: scale(1) rotate(0deg); }
         25%  { transform: scale(1.45) rotate(25deg); }
         50%  { transform: scale(1.2) rotate(-10deg); }
         75%  { transform: scale(1.3) rotate(12deg); }
         100% { transform: scale(1) rotate(0deg); }
       }
       
       /* ---- Floating Hearts ---- */
       .heart {
         position: absolute;
         font-size: 1.3rem;
         opacity: 0;
         color: #ff6b6b;
         animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
         pointer-events: none;
       }
       .heart::before,
       .heart::after { content: '♥'; position: absolute; left: 0; }
       .heart::before { color: #ffadad; }
       .heart::after { color: #ff6b6b; transform: rotate(90deg); }
       
       @keyframes floatAway {
         0%   { opacity: 1; transform: translateY(0) scale(1); }
         100% { opacity: 0; transform: translateY(-120px) scale(0.4); }
       }
       
       /* Position 3 hearts around the button using nth-of-type offsets */
       .container { position: relative; width: max-content; }
       .heart { left: 50%; top: 50%; transform: translate(-50%, -50%); }
       .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
       .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.15s; }
       .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.3s; }
       
       /* Slight horizontal offset for each heart so they don't stack exactly */
       .heart:nth-of-type(1) { left: 50%; top: 50%; }
       .heart:nth-of-type(2) { left: 54%; top: 48%; }
       .heart:nth-of-type(3) { left: 46%; top: 52%; }
       
       /* No horizontal scroll */
       body { overflow-x: hidden; }
     </style>
   </head>
   <body>
     <div class="container">
       <input type="radio" name="reaction" class="like-input" id="like-input">
       <label for="like-input" class="like-btn">Like</label>
       <span class="heart"></span>
       <span class="heart"></span>
       <span class="heart"></span>
     </div>
   </body>
   </html>
   ```

   Let's verify all rules:

   1. "Reply with exactly ONE fenced code block containing the complete file: ```html (or ```svg when the task asks for an SVG). No text before or after the code block."
      - I'll output exactly one ```html block.

   2. "Everything must be inline: CSS in <style>, JavaScript in <script>. No external files, images, fonts or network requests, except the CDN URLs explicitly allowed by the task."
   - I have no `<script>` block because no JS. CSS is in `<style>`. No external fonts: I'm using `system-ui, sans-serif` which is system font, no CDN. Good.
   - No network requests.

   3. "Do not use localStorage, sessionStorage, cookies, IndexedDB, alert(), confirm(), prompt() or window.open(): they are blocked in the sandbox and will throw."
   - None used.

   4. "The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar."
   - I have `overflow-x: hidden` on body. Widths are fluid using `max-content`, `padding`, `%` for heart offsets. Should adapt. I'll set `max-width: 100vw;` maybe, but `overflow-x: hidden` on body should prevent scroll. I'll also ensure elements don't exceed viewport width. Using `box-sizing: border-box` globally. Good.

   5. "Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction."
   - The button is visible immediately. On first paint, the "Like" button is there. The hearts are positioned but `opacity: 0` initially, so they're invisible, which is fine. The button animation starts on click, but the initial state is meaningful.

   6. "Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session."
   - The animation triggers on click. But the rule also says: "Games must start in a self-playing demo mode (a simple AI plays) behind a 'Click or press a key to start' message, so the game can be judged in action without playing." This is for games. My demo is a button, not a game. I need to interpret if this applies. The prompt says "a 'like' button in pure CSS, no JavaScript, that does a crazy animation when you click it". It's not a game. However, the sandbox rules about "self-playing demo mode" and "Click or press a key to start" might be automatically applied by the system. But the user is asking for a specific demo. I think the "Click or press a key to start" rule is for game demos. Since this is a button, I might not need it, but to be safe, I could add a subtle "Click the button" message, or maybe the system will handle it. Let me re-read the user's message: they are giving me constraints for the output. The constraints include: "Games must start in a self-playing demo mode... if the demo uses the keyboard, display a clear 'Click or press a key to start' message". My demo doesn't use keyboard, it's a mouse click button. I'll add a very minimal instructional text, maybe "Click or tap the button", but ensure it's not violating "no alert/confirm/prompt". I can just have text content. But the rule says "if the demo uses the keyboard, display...". It doesn't say I must display it if it doesn't use keyboard. I'll omit it to keep it clean, or add a gentle "Click to animate" label.

   Actually, re-reading carefully: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message." This is a conditional: if the demo uses keyboard → display message. My demo doesn't use keyboard input for the animation (it uses `:active`/`:checked` on mouse click / programmatic click). I could make it focusable with tab, but I won't rely on keyboard. I'll just have the button. To be extra safe, I'll add a brief "Click or tap" text, but it might be unnecessary. I'll include a small caption under the button: "Click to go crazy". But I need to ensure no horizontal scroll.

   Wait, there's another rule: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message". This might mean: since the iframe only gets keyboard events after user click, if my demo uses keyboard, I must show that message. My demo doesn't use keyboard, so maybe I'm fine. I'll not add the message to avoid clutter, but I'll keep the button clearly interactive.

   7. "The code must run with zero errors in the console of the latest Chrome."
   - No JS, so no runtime errors. CSS is valid.

   Let's double-check the CSS for any potential errors.
   - `animation: pop 0.65s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;` - valid.
   - `@keyframes pop` - valid.
   - `:checked ~ .heart:nth-of-type(1)` - valid CSS selector.
   - `position: absolute` on `.heart` inside `.container` which is `position: relative` → valid.
   - `min-height: 100vh` on body → valid.
   - `overflow-x: hidden` → valid.
   - No vendor prefixes needed for modern Chrome.

   One thing: The `.like-input` is `position: absolute` with `width: 100%; height: 100%; opacity: 0;`. It's a sibling to `.like-btn` via the `for`/`id` relationship, but in HTML, the input is inside the container, and the label is also inside. The selector `.like-input:checked + .like-btn` uses adjacent sibling combinator. But the HTML structure is:
   ```html
   <div class="container">
     <input type="radio" name="reaction" class="like-input" id="like-input">
     <label for="like-input" class="like-btn">Like</label>
     <span class="heart"></span>
     <span class="heart"></span>
     <span class="heart"></span>
   </div>
   ```
   Here, `<input>` and `<label>` are adjacent siblings. `.like-input:checked + .like-btn` will select the label immediately following the input. That works.

   However, I also have `.like-input:checked ~ .heart:nth-of-type(1)`. The `~` selector selects siblings after the input. The hearts are after the label, which is after the input. So `:checked ~ .heart` will select the hearts. Good.

   But wait: The `:checked` style on `.like-btn` uses `+`, and the heart delays use `~`. Both should work.

   Let's test the flow mentally:
   - Page loads: button looks normal, hearts are at center with `opacity: 0` (since I set `.heart { opacity: 0; }` initially? Actually, I didn't set initial opacity in the CSS block above except in the keyframes definition. I need to ensure `.heart` has `opacity: 0` by default, or they might be visible as black/red hearts. I'll set `.heart { opacity: 0; }` definitely.
   - User clicks the button (or the input gets checked via programmatic means, but in reality, the user clicks the label, which toggles the radio). The `:checked` state triggers:
     a. `.like-btn` animates: scales, rotates, color changes.
     b. `.like-input:checked ~ .heart` activates, with delays, playing `floatAway` animation.
   - The hearts were `opacity: 0`, now they animate to opacity 1 then back to 0 while moving up. That should be visible.

   One issue: The hearts' `animation: floatAway 0.9s ... forwards;` with `forwards` will keep the final state (opacity 0, translate -120px). That's fine, they'll fade out and move up, becoming invisible. But on first paint, they are `opacity: 0`, so invisible. Good.

   Another thing: The hearts use `::before` and `::after` to display hearts. But `::before` and `::after` with `content: '♥'` will show a heart character. That's fine. However, the `.heart` element itself is a `<span>`, which is an empty inline element. With `position: absolute`, it will have no width/height unless given, but `::before`/`::after` provide the content. That should work.

   Let's refine the CSS to ensure hearts are visible during animation. I'll set `.heart { opacity: 0; animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }` and then the `:checked ~ .heart` will override delay but keep the animation name. Actually, I need the animation to only play when `:checked`. So I'll keep the base `.heart` with `animation: none;` or just set animation properties only in the `:checked` rule. Better: base `.heart` has `opacity: 0; position: absolute; ...` and the animation is defined only in the `:checked` rule. But CSS animation can't be conditionally applied without repeating properties. I'll set the animation name in base but with `animation-play-state: paused;` or just use the delay trick. Actually, simplest: base `.heart { opacity: 0; }` and `.like-input:checked ~ .heart { animation: floatAway 0.9s cubic-bezier(...) forwards; animation-delay: ...; }`. That way, the animation only starts when checked. I need to repeat `animation-timing-function`, `animation-direction`, etc. I'll just define the keyframes as `@keyframes floatAway`, and in the rule set `animation: floatAway 0.9s cubic-bezier(...) forwards;`. That's fine.

   Let's restructure CSS cleanly:

   ```css
   .heart {
     position: absolute;
     font-size: 1.3rem;
     opacity: 0;
     color: #ff6b6b;
     pointer-events: none;
   }
   .heart::before,
   .heart::after { content: '♥'; position: absolute; left: 0; }
   .heart::before { color: #ffadad; }
   .heart::after { color: #ff6b6b; transform: rotate(90deg); }
   
   @keyframes floatAway {
     0%   { opacity: 1; transform: translateY(0) scale(1); }
     100% { opacity: 0; transform: translateY(-120px) scale(0.4); }
   }
   
   .like-input:checked ~ .heart {
     animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
   }
   .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
   .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.15s; }
   .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.3s; }
   ```

   Wait, if I set `.like-input:checked ~ .heart { animation: floatAway ... }`, and then `.like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }`, the `animation-delay` is overridden for that specific one, but the `animation-name` from the first rule should cascade. Actually, in CSS, if I have:
   ```
   .checked ~ .heart { animation: floatAway 0.9s forwards; }
   .checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
   ```
   The second rule only sets `animation-delay`, it doesn't override the whole `animation` property, so the name and duration from the first rule still apply. That's correct.

   But I need to make sure the base `.heart` doesn't have an `animation` property that conflicts. I'll keep base `.heart` animation-free.

   Now, about the hearts' initial positioning: they are inside `.container`, which is `position: relative`. I need to position them relative to the button. I'll set `.heart { left: 50%; top: 50%; transform: translate(-50%, -50%); }` so they start centered on the button. Then the `floatAway` animation moves them up and out. That makes sense: they originate from the button center and float away.

   Let's also ensure the button is centered on page load. The `.container` is `display: flex; align-items: center; justify-content: center;` on body. Actually, I had body with `display: flex; align-items: center; justify-content: center; min-height: 100vh;`. That centers `.container`. Good.

   Let's write the complete HTML/html.

   One more thing: The rule "The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar." I need to be careful with absolute positioning of hearts not causing overflow. Since hearts are absolutely positioned inside a relatively positioned container, and the container is centered, the hearts' `left: 54%` etc. might cause them to go beyond viewport width if the container is wide. But the container is `max-content` width, centered. At 375px width, `54%` of 375 is ~202px, which is fine. At 1280px, `54%` is ~691px, also fine. But the hearts are inside the container, which is centered. The `overflow-x: hidden` on body will hide any scroll. However, if the hearts' `left` percentage is based on the container's width, and the container is centered, the absolute positioning is relative to the container, not the viewport. So `left: 54%` means 54% of the container's width. The container width is `max-content`, which depends on content. The button is maybe 300px wide max. So hearts' positions are relative to that. That should be safe. I'll also add `width: 100%; max-width: 360px;` to container to keep it from getting too wide, but `max-content` is okay. To be safe, I'll set `.container { max-width: 380px; width: 90%; }` and centered. That ensures it fits well on mobile and desktop.

   Let's adjust:
   ```css
   .container {
     position: relative;
     max-width: 380px;
     width: 90%;
     display: flex;
     flex-direction: column;
     align-items: center;
     gap: 1.5rem;
   }
   ```
   This will make the container responsive, max 380px, 90% of viewport. Hearts' absolute positions relative to this container will be fine.

   Now, the hearts' `left: 54%;` etc. will be 54% of 380px ≈ 205px from left edge of container. Since container is centered, the hearts might go near the edges, but within the 380px width. Actually, `left: 50%` with `transform: translate(-50%, -50%)` centers the heart. For the second heart, `left: 54%` without adjusting transform might place it offset. I need to be consistent. Let's just use `left` and `top` percentages with `transform` to position them around the center. Or I can use fixed pixel offsets from the center, but that won't be responsive. I'll use `left: 50%; top: 50%; transform: translate(-50%, -50%)` for all, but then they'd stack. I can use `nth-of-type` to offset the `transform` value. For example:
   ```css
   .heart { left: 50%; top: 50%; transform: translate(-50%, -50%); }
   .like-input:checked ~ .heart:nth-of-type(1) { transform: translate(-50%, -50%); }
   .like-input:checked ~ .heart:nth-of-type(2) { transform: translate(-45%, -55%); }
   .like-input:checked ~ .heart:nth-of-type(3) { transform: translate(-55%, -45%); }
   ```
   But the `transform` in base `.heart` sets `translate(-50%, -50%)`, and the `:checked` rules override it. That could work. However, the `floatAway` animation uses `transform: translateY(-120px) scale(0.4)` at the end, which is independent. The initial `transform` for positioning is separate. I need to be careful not to override the animation's transform. Actually, the `floatAway` keyframes define the transform from 0% to 100%. If I set an initial `transform` on the element, it will be at the start of the animation (0%). The keyframes then override it. So if I set `.heart { transform: translate(-50%, -50%); }` and the keyframe has `transform: translateY(0) scale(1)` at 0%, there might be a conflict. CSS animations override the element's transform at the start of the keyframe duration, but it depends on whether the keyframe has `transform` specified. If the keyframe at 0% has `transform: translateY(0) scale(1)`, and the element has `transform: translate(-50%, -50%)`, the browser typically starts the animation from the computed style at 0%, but `animation` keyframes can override. To be safe, I should not set a conflicting `transform` on the element, and instead position the hearts using `left` and `top` only, and let the keyframes handle the movement from the center. But the hearts need to start at the button's center. I can use `left: 50%; top: 50%;` and the keyframes will start from there? Actually, if I set `left: 50%; top: 50%;` in CSS, the element is at 50%/50% of the container. The keyframe `transform: translateY(0) scale(1)` at 0% would be relative to the element's position, but `translateY(0)` means no vertical translation from its current position. So if the element is already at 50%/50%, `translateY(0)` keeps it there. Then at 100%, `translateY(-120px)` moves it up 120px from that center position. That works! The hearts start at the center of the container (which is roughly the button center, if the container is centered on the page and the button is inside). But the hearts are inside the container, and the container is centered. The button is inside the container, likely with some margin. The hearts at `left: 50%; top: 50%;` will be at the center of the container, which might not exactly be the button's center if the button has padding/margin. But it's close enough for a "burst" effect. I can also absolutely position the hearts relative to the button using `position: absolute;` on the hearts and `position: relative;` on the button, but the hearts are siblings of the button in my structure. I could restructure: put the button and hearts inside a wrapper that is relatively positioned, and position hearts absolutely relative to that wrapper. That's what I have with `.container { position: relative; }` and `.heart { position: absolute; }`. The container centers the button and hearts. The button's position within the container is determined by the flex layout. If I use `align-items: center; justify-content: center;` on the container, the button will be centered. The hearts at `left: 50%; top: 50%;` will also be centered. So they'll all originate from the same center point. That's fine for a burst effect.

   To make them spread out slightly without complex transforms, I can use the `nth-of-type` to give slightly different `left`/`top` in the base `.heart` rule, but they start at `opacity: 0` anyway, so their initial position only matters when the animation starts. The animation keyframes will move them from wherever they are. If they all start at the exact center, they'll overlap during the animation, but with different delays, they'll stagger. That's okay. I'll keep it simple: all hearts start at center via `left: 50%; top: 50%;` in the base rule, and the animation moves them up and out. The delays make them appear sequentially.

   Let's finalize:

   Base `.heart`:
   ```css
   .heart {
     position: absolute;
     left: 50%;
     top: 50%;
     transform: translate(-50%, -50%);
     font-size: 1.3rem;
     opacity: 0;
     color: #ff6b6b;
     pointer-events: none;
   }
   ```
   Then `:checked ~ .heart` sets the animation with delay. The keyframes `floatAway` start from the element's current position (which is centered) and move up. At 0%, `transform: translateY(0) scale(1)` — but wait, the element already has `transform: translate(-50%, -50%)` from the base rule. The keyframe `transform: translateY(0) scale(1)` at 0% will override the element's transform? Actually, in CSS, when an animation starts, the element's normal styles are layered with the keyframes. The `animation` property sets the keyframes, and at `0%`, the styles from the `0%` rule are applied, but they override the element's inline/regular styles? I need to recall: CSS animations work by interpolating between the element's beginning state and the keyframes. The beginning state is the element's original styles, but if the keyframe at 0% is specified, it overrides the start state. Actually, the standard says: "At the start of the animation, the element's previous style is overridden by the rules specified in the @keyframes block for 0%." If 0% is specified, it uses that; if not, it uses the element's original style. Since I have `0% { opacity: 1; transform: translateY(0) scale(1); }`, the `0%` rule will override the element's `opacity` and `transform` at the start of the animation. So the heart will suddenly jump to `opacity: 1` and `transform: translateY(0) scale(1)` (which is the center position), and then animate to `opacity: 0; transform: translateY(-120px) scale(0.4)`. But the element already has `transform: translate(-50%, -50%)` which positions it at center. The `0%` keyframe `transform: translateY(0) scale(1)` will reset the transform to just `translateY(0) scale(1)`, which, combined with `left: 50%; top: 50%`, also places it at center. So it should snap to center and then move up. That's fine. But there might be a flash of unstyled content during the 3-second first paint before any click. Since the hearts have `opacity: 0` initially, they're invisible. When the user clicks, they fade in and animate. That's good.

   However, I must ensure that the `0%` keyframe doesn't cause a style conflict that makes the heart visible briefly before the animation starts? The animation only starts when `:checked` is true, which happens on click. Before click, `opacity: 0` keeps it invisible. After click, the animation runs. The `0%` keyframe will set `opacity: 1` momentarily, but that's part of the animation sequence. It should look like a fade-in then float away. That's the intended "crazy animation".

   Let's trace the animation sequence for a heart:
   - Before click: `opacity: 0; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);` → invisible.
   - Click → `:checked` matches.
   - `.like-input:checked ~ .heart { animation: floatAway 0.9s cubic-bezier(...) forwards; animation-delay: Xs; }`
   - Animation starts. At 0%: `opacity: 1; transform: translateY(0) scale(1);` → heart fades in and is at center (since `left: 50%` `top: 50%` already there).
   - At 100%: `opacity: 0; transform: translateY(-120px) scale(0.4);` → heart fades out and moves up 120px and scales down.
   - `forwards` keeps the 100% state, so heart stays faded out and moved up, effectively disappearing.

   This looks good.

   One potential issue: The `animation-delay` is set per heart via nth-of-type. The base rule `.like-input:checked ~ .heart { animation: floatAway ... }` sets the animation for all hearts. Then `.like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }` etc. overrides delay. But does the `animation` property from the first rule get overridden partially? Yes, `animation-delay` is a separate sub-property. So it should work.

   Let's also consider the button's `crazyPop` animation. I have it defined. It scales and rotates. The button also changes background and color on `:checked`. That's good.

   Now, about the "Click or press a key to start" message. Since this isn't a game, but the sandbox might expect it, I'll add a very subtle message. Actually, re-reading the user's constraints: "Games must start in a self-playing demo mode (a simple AI plays) behind a 'Click or press a key to start' message, so the game can be judged in action without playing." and "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message". My demo is not a game, and doesn't use keyboard. I think I can omit the message. But to be absolutely safe and comply with the spirit of the sandbox (which seems to be for AI model comparison on web demos), I'll add a brief "Click the button to animate" text. I'll place it below the button or as a placeholder. But the rule says "if the demo uses the keyboard, display...". It doesn't say I must display it if it doesn't. I'll skip it to keep the demo clean. If the system requires it, it might be flagged, but I'll take the risk. Actually, many of these prompts are from a specific benchmark, and often the "Click or press a key to start" is automatically injected or expected. But the user said "a 'like' button in pure CSS, no JavaScript, that does a crazy animation when you click it". I'll stick to the button.

   Wait, there's also: "Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction." The button is visible on first paint. Good.

   "Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session." The animation is triggered by click, but the "crazy" part is the animation itself. The initial state has the button, which is meaningful. The hearts are invisible until clicked. That's fine; the interesting part is the animation on click.

   Let's do a final pass on the code for any console errors or issues.

   Potential issues:
   - The `::before` and `::after` content `♥` might not render as emoji on all systems, but it's a standard character, should be fine.
   - The `cubic-bezier` values are valid.
   - `animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;` - `forwards` keeps the last keyframe.
   - `overflow-x: hidden` on body.
   - No `@import` or external URLs.
   - Font: `system-ui, sans-serif` is safe.

   Let's write the final HTML.

   I'll structure it as:

   ```html
   <!DOCTYPE html>
   <html lang="en">
   <head>
     <meta charset="UTF-8">
     <meta name="viewport" content="width=device-width, initial-scale=1.0">
     <title>Crazy CSS Like Button</title>
     <style>
       /* ---- Reset ---- */
       * { box-sizing: border-box; margin: 0; padding: 0; }
       body {
         min-height: 100vh;
         background: #0a0a0f;
         display: flex;
         align-items: center;
         justify-content: center;
         overflow-x: hidden;
         font-family: system-ui, -apple-system, sans-serif;
         color: #ffadad;
       }
       .container {
         position: relative;
         max-width: 380px;
         width: 90%;
         display: flex;
         flex-direction: column;
         align-items: center;
         gap: 1.2rem;
       }
       /* ---- The Like Button ---- */
       .like-input {
         position: absolute;
         width: 100%;
         height: 100%;
         opacity: 0;
         cursor: pointer;
       }
       .like-btn {
         padding: 14px 28px;
         font-size: 1.3rem;
         font-weight: 700;
         border: none;
         border-radius: 30px;
         background: #e91e63;
         color: #fff;
         transition: transform 0.08s ease, background 0.2s, box-shadow 0.2s;
         box-shadow: 0 6px 20px rgba(233, 30, 99, 0.4);
         cursor: pointer;
       }
       .like-btn:active {
         transform: scale(0.95);
         background: #d81b40;
         box-shadow: 0 4px 10px rgba(216, 27, 64, 0.5);
       }
       /* ---- Crazy Animation on Click ---- */
       .like-input:checked + .like-btn {
         animation: crazyPop 0.65s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
         background: #ffd93d;
         color: #111;
         box-shadow: 0 0 30px rgba(255, 217, 61, 0.5);
       }
       @keyframes crazyPop {
         0%   { transform: scale(1) rotate(0deg); }
         25%  { transform: scale(1.45) rotate(25deg); }
         50%  { transform: scale(1.2) rotate(-10deg); }
         75%  { transform: scale(1.3) rotate(12deg); }
         100% { transform: scale(1) rotate(0deg); }
       }
       /* ---- Floating Hearts ---- */
       .heart {
         position: absolute;
         left: 50%;
         top: 50%;
         transform: translate(-50%, -50%);
         font-size: 1.2rem;
         opacity: 0;
         pointer-events: none;
       }
       .heart::before,
       .heart::after {
         content: '♥';
         position: absolute;
         left: 0;
       }
       .heart::before { color: #ffadad; }
       .heart::after { color: #ff6b6b; transform: rotate(90deg); }
       
       @keyframes floatAway {
         0%   { opacity: 1; transform: translateY(0) scale(1); }
         100% { opacity: 0; transform: translateY(-120px) scale(0.4); }
       }
       
       /* ---- Heart stagger delays ---- */
       .like-input:checked ~ .heart {
         animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
       }
       .like-input:checked ~ .heart:nth-of-type(1) { animation-delay: 0s; }
       .like-input:checked ~ .heart:nth-of-type(2) { animation-delay: 0.15s; }
       .like-input:checked ~ .heart:nth-of-type(3) { animation-delay: 0.3s; }
     </style>
   </head>
   <body>
     <div class="container">
       <input type="radio" name="reaction" class="like-input" id="like-input">
       <label for="like-input" class="like-btn">Like</label>
       <span class="heart"></span>
       <span class="heart"></span>
       <span class="heart"></span>
     </div>
   </body>
   </html>
   ```

   Let's review once more.

   - One fenced code block ` ```html ` ✓
   - Inline CSS in `<style>` ✓
   - No JavaScript ✓
   - No external files/fonts/CDN ✓ (system font)
   - No alert/confirm/prompt/localStorage etc ✓
   - Viewport 1280x800 and 375px adapt: `max-width: 380px; width: 90%; overflow-x: hidden;` should handle. The container is centered, hearts are absolute inside, shouldn't cause horizontal scroll. I'll double-check: if the heart's `left: 50%` with `transform: translate(-50%, -50%)` stays within the container, which is max 380px wide, centered. The hearts' width is zero (they're just text via ::before), so they won't overflow. The button is maybe 300px wide. All good.
   - First paint: button and text "Like" visible. Hearts invisible (opacity 0). Meaningful.
   - Self-playing demo mode: Not applicable, but I've not added any hidden content behind levels. The animation is immediate on click.
   - Keyboard message: Not adding since no keyboard use. If the system strictly requires it, I might fail, but the rule says "if the demo uses the keyboard, display...". I'll assume it's conditional.
   - Zero console errors: No JS, CSS only. Should be fine.

   One potential problem: The `:checked` selector on a radio input. When the page loads, the input is unchecked. When the user clicks the label, the radio toggles to :checked. That triggers the animation. But what if the sandbox auto-runs and takes a screenshot at 3s? The screenshot is taken 3 seconds after load, without interaction. If the user hasn't clicked, the animation won't have played, and the screenshot might just show the static button. The rule says: "Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction." The button is meaningful on first paint. The animation is a bonus that happens on click, but the first paint shows the button, which is the core demo. That should satisfy "something meaningful visible on first paint". The system might compare outputs, and having the button static is fine; the "crazy animation" is the interactive part. But the rule also says: "Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session." The interesting part is the animation, but it's triggered by click. However, the rule "Games must start in a self-playing demo mode" might be relevant. Since this isn't a game, maybe the system expects the animation to play automatically on load? But the user said "when you click it". I need to reconcile.

   Let's re-read the user's full prompt: "a 'like' button in pure CSS, no JavaScript, that does a crazy animation when you click it". The animation is on click. The sandbox rules are separate constraints on the output format. The "self-playing demo mode" and "Click or press a key to start" rules are part of the output rules given to me. I must follow them. Let's re-examine those:

   "- Games must start in a self-playing demo mode (a simple AI plays) behind a "Click or press a key to start" message, so the game can be judged in action without playing."
   "- The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear "Click or press a key to start" message, so the game can be judged in action without playing."
   "- The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar."
   "- Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction."
   "- Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session."

   These rules seem generic for "demos" but some mention "games". My demo is a button, not a game. However, the system might treat any demo as a "game" or expect the "Click or press a key to start" message if there's interaction. The rule says "if the demo uses the keyboard, display a clear 'Click or press a key to start' message". My demo doesn't use keyboard. But to be safe, I could add a "Click or tap" message. Also, "Games must start in a self-playing demo mode" — I'm not making a game. I'll interpret this as: since it's not a game, I don't need a self-playing AI, but I should still have an initial state that invites interaction. The "Click or press a key to start" message might be required if I use keyboard, but I won't. I'll add a subtle "Click the button" text just in case, but maybe it's better to not add it and risk violation. Let's see: the rule says "if the demo uses the keyboard, display...". It doesn't say "if the demo uses mouse, don't display". It's a conditional. I can safely omit it. However, the "self-playing demo mode" is specifically for games. I'll ignore it since it's a button.

   But there's a critical point: "Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction." If the only interesting thing is the animation on click, and the screenshot is taken at 3s without interaction, the screenshot will show the static button. That's meaningful—the button itself. The "crazy animation" is the interaction effect. The rule says "something meaningful must be visible on first paint", not "the animation must play on first paint". So the static button is fine.

   "Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session." The button is visible immediately. The animation is the interesting part, but it's not "hidden behind a high score". It's just gated by click. I think that's acceptable.

   To be extra cautious, maybe I can make the animation play automatically on load using only CSS? But the user said "when you click it". I'll stick to on-click.

   Let's consider if I should add a "Click or press space to animate" message. I'll add a `<p>` or text below the button: "Click to go crazy". But that might be considered "text visible on first paint", which is fine. However, the rule says no alert/confirm/prompt, but text content is fine. I'll add a simple text node inside the body but outside the container maybe, or as part of the container. But I need to ensure no horizontal scroll.

   Actually, I'll re-read the user's output rules one more time:

   "- Reply with exactly ONE fenced code block containing the complete file: ```html (or ```svg when the task asks for an SVG). No text before or after the code block.
   - Everything must be inline: CSS in <style>, JavaScript in <script>. No external files, images, fonts or network requests, except the CDN URLs explicitly allowed by the task.
   - Do not use localStorage, sessionStorage, cookies, IndexedDB, alert(), confirm(), prompt() or window.open(): they are blocked in the sandbox and will throw.
   - The page must look right in a 1280×800 viewport and adapt gracefully down to 375px wide. No horizontal scrollbar.
   - Something meaningful must be visible on first paint: a screenshot is taken automatically about 3 seconds after load, without any interaction.
   - Everything that makes the demo interesting must be visible within the first seconds: nothing hidden behind a high score, a later level or a long play session.
   - Games must start in a self-playing demo mode (a simple AI plays) behind a "Click or press a key to start" message, so the game can be judged in action without playing.
   - The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear "Click or press a key to start" message, so the game can be judged in action without playing.
   - The code must run with zero errors in the console of the latest Chrome."

   The "Games must start in a self-playing demo mode" and "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display..." are likely part of a standardized test suite for AI model outputs. The task is to generate a demo that fits these. Since the user asked for a "like" button, maybe the system expects me to adapt the button into a game-like intro, or maybe the rules are just general and I should follow the ones that apply. But I must be careful: if I don't include the "Click or press a key to start" message, and the test suite checks for it, I might fail. But the rule says "if the demo uses the keyboard, display...". My demo doesn't use keyboard. I'll assume it's conditional.

   However, there's also: "The iframe only receives keyboard events after the user clicks it: if the demo uses the keyboard, display a clear 'Click or press a key to start' message". This implies that if the demo uses keyboard, the message is required. If it doesn't, it's not. My demo uses mouse click (label click). I could make it focusable with tab, but I won't rely on keyboard.

   Let's think if there's any way the "like" button could be considered a game? No.

   I'll proceed with the button as designed. I'll add a very minimal "Click or tap" text maybe, but I'll keep it optional. Actually, to strictly follow the rules, I'll include a "Click or press a key to start" message but grayed out or something, but that might conflict with "no horizontal scroll" or "meaningful on first paint". I'll just not include it, as the conditional doesn't trigger.

   Wait, maybe the system automatically considers any interactive demo as a "game" for the purpose of those rules. If so, I need a self-playing demo mode. But the user explicitly said "a 'like' button in pure CSS, no JavaScript, that does a crazy animation when you click it". I can't add a self-playing AI without JavaScript (pure CSS AI is possible with complex selectors, but extremely limited and probably not intended). I'll trust that the rules about self-playing demo mode apply to game demos, and since the user specified a button, those rules are relaxed or I should interpret "game" loosely. Maybe I can make the button animate on page load using the `:checked` state pre-set? But that would require the input to be checked on load, which might be considered "self-playing". But the user said "when you click it". I'll keep it on-click.

   Let's look at the "something meaningful visible on first paint" and "screenshot taken automatically about 3 seconds after load, without any interaction". If I set the radio input to be `:checked` by default via HTML attribute `checked`, then on load, the animation would play automatically, and the screenshot would see the "crazy" state. That might actually satisfy both "crazy animation when you click it" (if I explain it's the effect, but it plays on load) and "something meaningful visible on first paint" (the animated state). But the user said "when you click it". I'll not add `checked` attribute. The static button on load is meaningful.

   I'll stick with the on-click trigger. The first paint shows the button. The system takes screenshot at 3s; the button is there. The animation is the interactive hook.

   One more thing: The rule "The code must run with zero errors in the console of the latest Chrome." I need to ensure no CSS errors. I'll validate the CSS in my head.

   Potential CSS errors:
   - `cubic-bezier(0.34, 1.56, 0.64, 1)` is valid.
   - `animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;` - `forwards` is a valid `animation-fill-mode` value, but here it's part of the `animation` shorthand. The shorthand `animation: name duration timing-function delay iteration-count direction fill-mode play-state;`. `forwards` is `fill-mode`. So `animation: floatAway 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;` is valid: name, duration, timing-function, fill-mode. It sets animation-direction to normal (default), iteration-count 1 (default), fill-mode forwards, play-state paused (default). That's fine.
   - `animation-delay` set separately is fine.
   - `::before` and `::after` with `content: '♥';` - the heart character is a valid string.
   - `position: absolute` on `.heart` inside `.container` which is `position: relative` - valid.
   - `min-height: 100vh` on body - valid.
   - `overflow-x: hidden` - valid.
   - `max-width: 380px; width: 90%;` - valid.
   - `display: flex; align-items: center; justify-content: center;` on body - valid.

   Everything looks solid.

   Let's produce the final code block.