@font-face { font-family: "Poppins"; font-style: normal; font-display: swap; font-weight: 400; src: url(/fonts/poppins-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-display: swap; font-weight: 600; src: url(/fonts/poppins-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-display: swap; font-weight: 700; src: url(/fonts/poppins-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Poppins"; font-style: normal; font-display: swap; font-weight: 800; src: url(/fonts/poppins-latin-800-normal.woff2) format("woff2"); }

/* xD.de editor pages: same tokens, header and footer as the Nuxt app */
:root {
  --red: #b00808; --red-hover: #8e0606; --coral: #ee7256; --pink: #fdeceb; --pink-deep: #f6d3d0;
  --canvas: #fbf7f6; --card: #fff; --line: #eee2df; --ink: #2a2424; --sub: #5d5555; --faint: #978d8b;
  --shadow: 0 1px 2px rgba(90, 30, 25, .06), 0 10px 26px -14px rgba(90, 30, 25, .22);
  --shadow-up: 0 2px 4px rgba(90, 30, 25, .08), 0 20px 36px -16px rgba(90, 30, 25, .34);
  --font: "Poppins", "Segoe UI", system-ui, -apple-system, Helvetica, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--canvas); color: var(--ink); font: 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--red); text-decoration: none; }
h1, h2 { margin: 0; line-height: 1.15; letter-spacing: -.02em; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid rgba(176, 8, 8, .35); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
main { flex: 1; }

.site-head { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.head-row { display: flex; align-items: center; gap: 28px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); flex: none; }
.brand img { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--ink); }
.brand b { display: block; font-size: 21px; font-weight: 800; letter-spacing: -.03em; line-height: 1; }
.brand b span { color: var(--red); }
.brand small { display: block; font-size: 12px; color: var(--faint); margin-top: 3px; }
.nav { display: flex; gap: 2px; margin-left: auto; }
.nav a { padding: 8px 14px; border-radius: 999px; color: var(--ink); font-weight: 600; font-size: 15px; white-space: nowrap; }
.nav a:hover { background: var(--pink); color: var(--red); }
.nav a.active { background: var(--red); color: #fff; }

.gen-head { background: linear-gradient(135deg, #fff, var(--pink)); border-bottom: 1px solid var(--line); }
.gen-head .wrap { padding-top: 40px; padding-bottom: 36px; text-align: center; }
.gen-head h1 { font-size: clamp(28px, 4vw, 44px); font-weight: 800; }
.gen-head p { margin: 10px auto 0; max-width: 56ch; color: var(--sub); font-size: 18px; }
.crumb { display: inline-block; margin-bottom: 14px; font-size: 14px; font-weight: 600; color: var(--faint); }
.page { padding-top: 36px; padding-bottom: 64px; }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.tile { padding: 0; border: 0; border-radius: 18px; overflow: hidden; background: var(--card); box-shadow: var(--shadow); cursor: pointer; transition: transform .2s ease-out, box-shadow .2s ease-out; }
.tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-up); }
.tile img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 22px; border: 0; border-radius: 999px; font: 700 15px/1 var(--font); cursor: pointer; transition: background-color .15s, transform .1s; }
.btn:active { transform: translateY(1px); }
.btn-red { background: var(--red); color: #fff; box-shadow: 0 10px 22px -10px rgba(176, 8, 8, .7); }
.btn-red:hover { background: var(--red-hover); }
.btn-ghost { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--coral); color: var(--red); }

.editor { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(320px, .75fr); gap: 28px; align-items: start; }
.editor.view-only { grid-template-columns: minmax(0, 1fr); max-width: 820px; margin: 0 auto; }
.stage { position: sticky; top: 92px; padding: 14px; background: var(--card); border-radius: 22px; box-shadow: var(--shadow-up); }
.stage canvas { display: block; width: 100%; height: auto; border-radius: 14px; }
.stage .actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; margin-top: 14px; }
.panel { display: flex; flex-direction: column; gap: 14px; }
.line { padding: 16px; background: var(--card); border-radius: 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 10px; }
.line-head { display: flex; justify-content: space-between; align-items: center; }
.line-head b { font-size: 14px; }
.del { border: 0; background: none; color: var(--faint); font: 600 13px var(--font); cursor: pointer; }
.del:hover { color: var(--red); }
.txt { width: 100%; min-height: 46px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--canvas); font: 16px var(--font); color: var(--ink); }
.txt:focus { outline: none; border-color: var(--red); background: #fff; box-shadow: 0 0 0 4px rgba(176, 8, 8, .12); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; font-size: 13px; color: var(--sub); }
.row label { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 130px; font-weight: 600; }
.row label.color, .row label.chk { flex: none; min-width: 0; }
.row label.off { opacity: .4; }
.row input[type=range] { flex: 1; min-width: 70px; accent-color: var(--red); }
.row input[type=color] { width: 36px; height: 30px; padding: 0; border: 1.5px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; }
.row input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--red); }
.row select { min-height: 34px; padding: 0 8px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; font: 14px var(--font); color: var(--ink); }
.segs { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--canvas); border: 1px solid var(--line); }
.seg { border: 0; background: none; padding: 5px 12px; border-radius: 999px; font: 600 13px var(--font); color: var(--sub); cursor: pointer; }
.seg.on { background: var(--red); color: #fff; }

.foot { background: #221d1d; color: #bdb2b0; }
.foot .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 32px; padding-top: 30px; padding-bottom: 34px; font-size: 14px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.foot a { color: var(--coral); font-weight: 600; }
.foot a:hover { color: #fff; }
.foot .brand { color: #fff; }
.foot .brand img { width: 34px; height: 34px; border-color: #fff; }

@media (max-width: 900px) {
  .editor { grid-template-columns: minmax(0, 1fr); }
  .stage { position: static; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .site-head { position: static; }
  .head-row { flex-wrap: wrap; gap: 4px; min-height: 0; padding-top: 12px; }
  .nav { width: calc(100% + 32px); margin: 0 -16px; padding: 4px 12px 10px; overflow-x: auto; scrollbar-width: none; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
