/* Roleplay Studio — Häkchen auf Papier (Startseite, Anmeldung, Abo).
   Die ganze Zeile ist die Klickfläche (label.haken > input + span). Das Kästchen ist ein kleines Stempelfeld; beim
   Anhaken füllt es sich mit Kerzenglut, der Haken zieht sich wie ein Federstrich von links nach rechts, und die Zeile
   wird zur hinterlegten Karte. Fehlt ein Haken beim Absenden, bekommt die Zeile die Klasse .fehlt (rot, kurzes Wackeln). */
.haken { --hk: 28px; position: relative; display: grid; grid-template-columns: var(--hk) 1fr; gap: 13px; align-items: start; margin: 0; padding: 12px 15px 12px 13px;
  border-radius: 10px; cursor: pointer; font-size: 17px; line-height: 1.42; color: #3f2913; text-align: left; -webkit-tap-highlight-color: transparent;
  background: rgba(255, 250, 235, .45); box-shadow: inset 0 0 0 1px rgba(120, 80, 30, .26); transition: background .25s ease, box-shadow .25s ease; }
.haken:hover { background: rgba(255, 250, 235, .75); box-shadow: inset 0 0 0 1px rgba(150, 90, 30, .5); }
.haken:has(input:checked) { background: linear-gradient(180deg, rgba(255, 238, 200, .92), rgba(250, 224, 172, .78)); box-shadow: inset 0 0 0 1.5px #c47a22, 0 8px 18px -12px rgba(140, 70, 10, .8); }
.haken > span { padding-top: 1px; }
.haken b { color: #2c1808; }
.haken a { color: #8a4a12; text-underline-offset: 2px; }

.haken input { appearance: none; -webkit-appearance: none; position: relative; display: grid; place-content: center; flex: none; width: var(--hk); height: var(--hk); margin: -1px 0 0;
  border-radius: 8px; cursor: pointer; color: inherit; font: inherit;
  background: linear-gradient(180deg, #fffaf0, #f2e2c0); border: 2px solid rgba(110, 70, 25, .62);
  box-shadow: inset 0 2px 4px rgba(120, 80, 30, .22), 0 1px 0 rgba(255, 255, 255, .75);
  transition: background .25s ease, border-color .25s ease, box-shadow .3s ease, transform .15s ease; }
/* der Haken: ein Federstrich als Maske, der sich beim Anhaken von links aufzieht */
.haken input::before { content: ""; width: 19px; height: 19px; background: #fff8e4;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3.6 13.1c1.7 1.1 3.5 2.9 5.1 5.2C11.4 12.4 15.2 7.9 20.6 4.4' fill='none' stroke='%23000' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3.6 13.1c1.7 1.1 3.5 2.9 5.1 5.2C11.4 12.4 15.2 7.9 20.6 4.4' fill='none' stroke='%23000' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / contain no-repeat;
  clip-path: inset(0 100% 0 0); transition: clip-path .34s cubic-bezier(.65, 0, .25, 1) .06s; }
.haken input:checked { border-color: #7a3608;
  background: radial-gradient(circle at 34% 28%, #ffc56e, #e0842a 52%, #a04a0e);
  box-shadow: 0 0 0 3px rgba(240, 160, 60, .25), 0 0 16px rgba(255, 150, 40, .55), inset 0 1px 0 rgba(255, 232, 175, .75), inset 0 -2px 3px rgba(90, 30, 0, .35);
  animation: haken-pop .38s cubic-bezier(.3, 1.6, .5, 1); }
.haken input:checked::before { clip-path: inset(0 0 0 0); }
.haken:active input { transform: scale(.9); }
.haken input:focus-visible { outline: 3px solid #23407a; outline-offset: 3px; }
@keyframes haken-pop { 0% { transform: scale(.8); } 55% { transform: scale(1.14); } 100% { transform: scale(1); } }

.haken.fehlt { background: rgba(170, 45, 20, .09); box-shadow: inset 0 0 0 1.5px #a2361c; animation: haken-wackeln .42s ease; }
.haken.fehlt input { border-color: #a2361c; box-shadow: 0 0 0 3px rgba(162, 54, 28, .18), inset 0 2px 4px rgba(120, 80, 30, .22); }
@keyframes haken-wackeln { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }

@media (max-width: 560px) { .haken { --hk: 26px; gap: 11px; padding: 11px 12px 11px 11px; font-size: 16.5px; } }
@media (prefers-reduced-motion: reduce) { .haken, .haken input, .haken input::before { animation: none !important; transition: none !important; } }
