:root {
  color-scheme: light;
  --bg: #fff3ef;
  --paper: #fffaf0;
  --paper-deep: #fff2dc;
  --ink: #51351f;
  --muted: #8f6d5e;
  --rose: #f2a3b7;
  --rose-deep: #b85f76;
  --violet: #c7a7df;
  --mint: #b8cf9b;
  --butter: #f5d884;
  --lace: rgba(255, 255, 255, 0.74);
  --line: #e4baa9;
  --shadow: 0 24px 70px rgba(131, 72, 77, 0.2);
  --soft-shadow: 0 10px 28px rgba(131, 72, 77, 0.14);
  font-family: Georgia, "Times New Roman", serif;
  color: var(--ink);
  background: var(--bg);
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 8% 12%, rgba(242, 163, 183, 0.32), transparent 24%),
    radial-gradient(circle at 92% 8%, rgba(199, 167, 223, 0.34), transparent 22%),
    radial-gradient(circle at 84% 92%, rgba(184, 207, 155, 0.24), transparent 26%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.34) 0 8px, transparent 8px 18px),
    var(--bg);
}

button,
textarea {
  font: inherit;
}

button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.86);
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 4px 0 rgba(180, 95, 118, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 7px 18px rgba(180, 95, 118, 0.16);
}

button:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(242, 163, 183, 0.42);
  outline-offset: 2px;
}

h1,
h2,
p {
  margin: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.scrapbook-page {
  position: relative;
  width: min(1180px, calc(100vw - 28px));
  margin: 0 auto;
  padding: 30px 0 56px;
}

.corner-flower {
  position: fixed;
  z-index: 0;
  width: clamp(150px, 20vw, 280px);
  opacity: 0.88;
  pointer-events: none;
  filter: drop-shadow(0 18px 28px rgba(111, 68, 58, 0.18));
}

.corner-flower-left {
  top: -20px;
  left: -32px;
  transform: rotate(-28deg);
}

.corner-flower-right {
  top: -26px;
  right: -26px;
  transform: scaleX(-1) rotate(-24deg);
}

.scrapbook-hero,
.lace-panel,
.memory-card,
.returned-card,
.toast {
  position: relative;
  z-index: 1;
}

.scrapbook-hero {
  min-height: 184px;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  text-align: center;
}

.brand-heading {
  width: min(700px, 96vw);
  margin: -14px auto -6px;
  line-height: 0;
}

.brand-wordmark {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 8px 18px rgba(143, 87, 75, 0.15));
}

.loading-card .brand-heading {
  width: min(320px, 100%);
  margin: -6px auto -4px;
}

.seo-fallback {
  width: min(720px, calc(100vw - 32px));
  margin: 24px auto;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: var(--soft-shadow);
}

.seo-fallback h2 {
  margin-bottom: 10px;
  font-size: 2rem;
  font-weight: 500;
}

.seo-fallback p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
}

.scrapbook-hero p {
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.flourish {
  color: var(--rose-deep);
  font-size: 1.25rem;
  letter-spacing: 0;
}

.bow {
  width: 74px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #fff6f5;
  border: 1px solid #d98da2;
  border-radius: 50% 50% 46% 46%;
  background: linear-gradient(135deg, #ef91a9, #f7bdcb);
  box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.34), var(--soft-shadow);
}

.language-toggle {
  position: absolute;
  top: 18px;
  right: 16px;
  display: flex;
  padding: 4px;
  border: 1px solid #ddadbd;
  border-radius: 16px;
  background: rgba(255, 250, 240, 0.76);
  box-shadow: var(--soft-shadow);
}

.language-toggle button {
  min-height: 34px;
  min-width: 54px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  box-shadow: none;
  font-size: 0.95rem;
}

.language-toggle button.is-active {
  background: #ffdce5;
  color: #7f334a;
}

.local-note {
  position: absolute;
  top: 66px;
  right: 24px;
  color: var(--rose-deep);
  font-size: 0.98rem;
}

.lace-panel {
  min-height: 320px;
  padding: clamp(22px, 4vw, 46px);
  border: 1px solid #e4bda8;
  border-radius: 28px;
  background:
    linear-gradient(90deg, var(--lace) 0 22px, transparent 22px),
    radial-gradient(circle at 0 50%, transparent 0 10px, rgba(255,255,255,.72) 11px 15px, transparent 16px) left / 28px 28px repeat-y,
    linear-gradient(180deg, rgba(255,255,255,.5), rgba(255, 244, 232, .84)),
    var(--paper);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.lace-panel::before,
.lace-panel::after {
  content: "❦ ✿ ❦ ✿ ❦ ✿ ❦ ✿ ❦";
  position: absolute;
  left: 50%;
  width: max-content;
  color: rgba(184, 95, 118, 0.42);
  transform: translateX(-50%);
  pointer-events: none;
}

.lace-panel::before {
  top: 10px;
}

.lace-panel::after {
  bottom: 10px;
}

.panel-ornament,
.section-heading {
  text-align: center;
  color: var(--rose-deep);
}

.compose-panel h2 {
  margin-bottom: 20px;
  text-align: center;
  font-size: clamp(1.75rem, 4vw, 2.7rem);
  font-weight: 500;
}

textarea {
  display: block;
  width: min(760px, 100%);
  min-height: 128px;
  margin: 0 auto;
  padding: 18px 20px;
  resize: vertical;
  border: 1px solid #dcb39d;
  border-radius: 14px;
  background: rgba(255, 253, 247, 0.84);
  color: var(--ink);
  font-size: 1.16rem;
  line-height: 1.55;
  box-shadow: inset 0 2px 12px rgba(177, 108, 88, 0.08);
}

textarea::placeholder {
  color: #b79487;
  font-style: italic;
}

.pressed-bouquet {
  position: absolute;
  right: clamp(12px, 5vw, 58px);
  top: 74px;
  width: 124px;
  opacity: 0.92;
  transform: rotate(7deg);
  pointer-events: none;
}

.return-row {
  display: grid;
  grid-template-columns: minmax(140px, auto) minmax(280px, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 26px;
}

.return-label {
  color: var(--muted);
  font-size: 1.08rem;
  font-style: italic;
}

.window-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid #dcb39d;
  border-radius: 18px;
  background: rgba(255, 248, 237, 0.78);
}

.window-button {
  display: grid;
  gap: 2px;
  min-height: 62px;
  padding: 8px 14px;
  border: 0;
  border-right: 1px solid #ead0c1;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.window-button:last-child {
  border-right: 0;
}

.window-button.is-active {
  background: #ffdce5;
  color: #7f334a;
}

.window-button span {
  font-size: 1.08rem;
}

.window-button small {
  color: var(--muted);
  font-size: 0.78rem;
}

.keep-button {
  min-height: 64px;
  padding: 0 30px;
  border: 1px solid #c66d83;
  border-radius: 16px;
  background: linear-gradient(180deg, #f7a8b9, #df7891);
  color: white;
  font-size: 1.15rem;
  box-shadow: inset 0 0 0 4px rgba(255,255,255,.32), 0 12px 24px rgba(184, 95, 118, .24);
}

.lower-garden {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.96fr);
  gap: 28px;
  margin-top: 28px;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  font-weight: 500;
  color: #70482c;
}

.memory-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.memory-card,
.returned-card,
.empty-kitsch {
  border: 1px solid #e2bda8;
  background: rgba(255, 250, 239, 0.9);
  box-shadow: var(--soft-shadow);
}

.memory-card {
  position: relative;
  min-height: 240px;
  padding: 22px 18px 54px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 12px;
  border-radius: 18px;
  overflow: hidden;
}

.memory-card:nth-child(2n) {
  transform: rotate(0.7deg);
}

.memory-card:nth-child(3n) {
  transform: rotate(-0.7deg);
}

.paper-lace {
  position: absolute;
  top: 0;
  right: 0;
  width: 58px;
  height: 58px;
  border-left: 1px solid rgba(194, 141, 126, .38);
  border-bottom: 1px solid rgba(194, 141, 126, .38);
  border-bottom-left-radius: 18px;
  background:
    radial-gradient(circle at 12px 12px, transparent 0 8px, rgba(255,255,255,.72) 9px 12px, transparent 13px),
    rgba(255,255,255,.54);
}

.tiny-heart {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: auto;
  max-width: calc(100% - 24px);
  min-width: 0;
  min-height: 32px;
  padding: 0 10px;
  border-color: #d98da2;
  background: rgba(255, 241, 245, 0.94);
  color: var(--rose-deep);
  font-size: 1.05rem;
  line-height: 1;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.42), var(--soft-shadow);
}

.tiny-heart::after {
  content: attr(aria-label);
  overflow: hidden;
  max-width: 18ch;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.76rem;
  font-style: italic;
}

.card-flower {
  width: 92px;
  height: 98px;
  margin: 0 auto;
}

.memory-card p {
  align-self: center;
  color: #5c402a;
  font-size: 1.05rem;
  line-height: 1.45;
  text-align: center;
}

.memory-card footer {
  color: var(--muted);
  font-size: 0.92rem;
}

.accent-rose {
  background: linear-gradient(180deg, rgba(255, 241, 245, 0.95), rgba(255, 250, 239, 0.94));
}

.accent-violet {
  background: linear-gradient(180deg, rgba(244, 237, 255, 0.96), rgba(255, 250, 239, 0.94));
}

.accent-mint {
  background: linear-gradient(180deg, rgba(242, 250, 233, 0.96), rgba(255, 250, 239, 0.94));
}

.accent-butter,
.accent-lavender {
  background: linear-gradient(180deg, rgba(255, 248, 215, 0.96), rgba(255, 250, 239, 0.94));
}

.returned-card {
  position: relative;
  min-height: 324px;
  padding: 24px;
  border-radius: 22px;
  background:
    radial-gradient(circle at 92% 88%, rgba(199, 167, 223, .32), transparent 28%),
    linear-gradient(180deg, rgba(249, 237, 255, 0.96), rgba(255, 246, 251, 0.96));
  overflow: hidden;
}

.returned-card::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px dashed rgba(140, 92, 74, .32);
  border-radius: 16px;
  pointer-events: none;
}

.ribbon {
  position: absolute;
  right: 22px;
  bottom: 18px;
  display: grid;
  place-items: center;
  width: 74px;
  height: 48px;
  color: white;
  border-radius: 50%;
  background: linear-gradient(135deg, #b98bd9, #d8b9ef);
  transform: rotate(-8deg);
}

.returned-inner {
  position: relative;
  display: grid;
  gap: 14px;
  max-width: 520px;
  margin: 0 auto;
}

.daisy {
  width: 100px;
  height: 98px;
}

.returned-inner p {
  font-size: 1.14rem;
  line-height: 1.52;
}

.returned-inner strong {
  font-size: 1.05rem;
  font-weight: 500;
}

.stitched-line {
  color: var(--muted);
  letter-spacing: 0;
  text-align: center;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.button-row button {
  flex: 1;
  min-width: 145px;
  padding: 0 16px;
}

.button-row button:last-child {
  background: #dfe9c8;
}

.empty-kitsch {
  padding: 28px;
  border-radius: 18px;
  color: var(--muted);
  text-align: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  padding: 12px 18px;
  border: 1px solid #dfaab8;
  border-radius: 999px;
  background: rgba(255, 250, 240, .94);
  color: #7f334a;
  box-shadow: var(--soft-shadow);
  transform: translateX(-50%);
}

.site-footer {
  position: relative;
  z-index: 1;
  margin-top: 34px;
  padding: 18px 0 4px;
  color: var(--muted);
  text-align: center;
}

.footer-links {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  border: 1px solid rgba(226, 189, 168, 0.7);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.64);
  box-shadow: var(--soft-shadow);
}

.footer-link {
  min-height: 28px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
  font-size: 0.95rem;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.footer-link:hover {
  color: var(--rose-deep);
  box-shadow: none;
  transform: none;
}

.legal-page {
  max-width: 940px;
}

.legal-hero {
  min-height: 230px;
  padding-top: 36px;
}

.legal-hero h1 {
  font-size: clamp(3.2rem, 8vw, 5.8rem);
}

.legal-topbar {
  position: absolute;
  top: 18px;
  left: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.legal-back {
  color: var(--rose-deep);
  font-size: 0.98rem;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.legal-language-toggle {
  display: flex;
  padding: 4px;
  border: 1px solid #ddadbd;
  border-radius: 16px;
  background: rgba(255, 250, 240, 0.76);
  box-shadow: var(--soft-shadow);
}

.legal-language-toggle a {
  min-width: 48px;
  min-height: 32px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--ink);
  font-size: 0.92rem;
  text-decoration: none;
}

.legal-language-toggle .lang-de-choice {
  background: #ffdce5;
  color: #7f334a;
}

body[data-language="en"] .legal-language-toggle .lang-de-choice {
  background: transparent;
  color: var(--ink);
}

body[data-language="en"] .legal-language-toggle .lang-en-choice {
  background: #ffdce5;
  color: #7f334a;
}

.lang-en-inline,
.lang-en-block {
  display: none;
}

body[data-language="en"] .lang-de-inline,
body[data-language="en"] .lang-de-block {
  display: none;
}

body[data-language="en"] .lang-en-inline {
  display: inline;
}

body[data-language="en"] .lang-en-block {
  display: block;
}

.legal-document {
  width: min(840px, 100%);
  min-height: auto;
  margin: 0 auto;
  text-align: left;
}

.legal-document h2 {
  margin: 12px 0 8px;
  color: #70482c;
  font-size: clamp(1.65rem, 3.4vw, 2.3rem);
  font-weight: 500;
  text-align: center;
}

.legal-document h3 {
  margin: 24px 0 8px;
  color: #70482c;
  font-size: 1.12rem;
  font-weight: 600;
}

.legal-document p {
  margin-top: 10px;
  color: #6d4d3b;
  font-size: 1rem;
  line-height: 1.65;
}

.legal-document a,
.legal-back:hover {
  color: var(--rose-deep);
}

.legal-date {
  text-align: center;
  font-style: italic;
}

.legal-panel {
  width: min(760px, 100%);
  margin: 14px auto 0;
  padding: 18px 20px;
  border: 1px solid #e2bda8;
  border-radius: 18px;
  background: rgba(255, 250, 239, 0.9);
  box-shadow: var(--soft-shadow);
  text-align: left;
}

.legal-panel h2 {
  margin-bottom: 10px;
  color: #70482c;
  font-size: 1.2rem;
  font-weight: 500;
}

.legal-panel p {
  margin: 10px 0 0;
  color: #6d4d3b;
  font-size: 0.95rem;
  line-height: 1.55;
}

.legal-panel a {
  color: var(--rose-deep);
}

.flower-svg {
  display: block;
  width: 100%;
  height: auto;
}

.flower-corner {
  transform: rotate(18deg);
}

@media (max-width: 920px) {
  .language-toggle,
  .local-note {
    position: static;
  }

  .scrapbook-hero {
    gap: 10px;
    padding-top: 12px;
  }

  .return-row,
  .lower-garden {
    grid-template-columns: 1fr;
  }

  .memory-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pressed-bouquet {
    opacity: 0.2;
  }
}

@media (max-width: 620px) {
  .scrapbook-page {
    width: min(100% - 16px, 1180px);
    padding-top: 12px;
  }

  .brand-heading {
    width: min(470px, 100%);
    margin: -8px auto -4px;
  }

  .legal-hero {
    padding-top: 12px;
  }

  .legal-topbar {
    position: static;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 8px;
  }

  .legal-back {
    width: 100%;
    text-align: center;
  }

  .lace-panel {
    padding: 22px 16px;
  }

  .window-buttons,
  .memory-grid {
    grid-template-columns: 1fr;
  }

  .keep-button {
    width: 100%;
  }

  .corner-flower {
    width: 130px;
    opacity: 0.44;
  }

  .memory-card {
    min-height: 210px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
