/* =====================================================================
   aqb_home — Landing Page mit Würfel (aus agentiqube-website-v6b)
   Farben nur als var(--aqb-…) aus aqb_theme (DESIGN.md). Hell/Dunkel
   schaltet <html data-theme>, serverseitig gesetzt (aqb_theme/theme.py).
   ===================================================================== */

.aqbh-shell {
  --aqbh-sidebar: 230px;
  position: relative; isolation: isolate;
  display: grid; grid-template-columns: var(--aqbh-sidebar) minmax(0, 1fr);
  min-height: 100vh; min-height: 100dvh;
  background: var(--aqb-work); color: var(--aqb-text);
  font-family: var(--aqb-font);
}
body:has(.aqbh-shell) { margin: 0; }
.aqbh-shell.aqbh-no-sidebar { grid-template-columns: minmax(0, 1fr); }
[data-theme="dark"] .aqbh-shell { background: var(--aqb-frame); }
/* Weltraum-Grund nur dunkel (DESIGN.md Regel 4: nur Einstiegsseiten) */
[data-theme="dark"] .aqbh-shell.aqbh-has-space::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: var(--aqbh-space) center / cover no-repeat;
  opacity: .7; transform: scale(1.28); transform-origin: 65% 48%;
}

/* ---------- Seitenleiste (Website: .sidebar) ---------- */
.aqbh-sidebar {
  position: sticky; top: 0; height: 100vh; height: 100dvh; overflow-y: auto; box-sizing: border-box;
  display: flex; flex-direction: column; padding: 32px 18px;
  background: color-mix(in srgb, var(--aqb-frame) 82%, transparent);
  backdrop-filter: blur(10px);
  border-right: 1px solid var(--aqb-frame-line);
  color: var(--aqb-on-frame); text-align: left;
}
/* Hell: Rahmen deckend Graphit wie die Desk-Seitenleiste (Durchsicht nur über dem Weltraum) */
html:not([data-theme="dark"]) .aqbh-sidebar { background: var(--aqb-frame); backdrop-filter: none; }
.aqbh-brand { display: block; font-size: 19px; letter-spacing: 2px; text-decoration: none; color: var(--aqb-on-frame) !important; }
.aqbh-brand > span { color: var(--aqb-accent) !important; }
.aqbh-sidebar-title, .aqbh-group-title {
  display: block; margin-top: 10px; font-size: 9px; letter-spacing: var(--aqb-track-label);
  text-transform: uppercase; color: var(--aqb-on-frame-muted);
}
.aqbh-group-title { margin: 18px 0 4px 12px; }
.aqbh-nav { display: flex; flex-direction: column; gap: 5px; margin-top: 24px; }
.aqbh-group { display: flex; flex-direction: column; gap: 5px; }
.aqbh-nav a {
  display: flex; align-items: center; gap: 13px; padding: 13px 12px;
  border-left: var(--aqb-strip) solid transparent; border-radius: var(--aqb-radius-sm);
  color: var(--aqb-on-frame-muted) !important; text-decoration: none;
}
.aqbh-nav a:hover, .aqbh-nav a:focus-visible, .aqbh-nav a[aria-current="page"] {
  background: var(--aqb-frame-raised); border-left-color: var(--aqb-accent); color: #fff !important;
}
.aqbh-sidebar-footer { margin-top: auto; padding-top: 24px; font-size: 12px; line-height: 1.7; color: var(--aqb-accent); }
.aqbh-account { margin-bottom: 12px; color: var(--aqb-on-frame-muted); }
.aqbh-account a { color: var(--aqb-on-frame) !important; }

/* ---------- Hauptbereich (Website: .main) ---------- */
.aqbh-main { min-width: 0; text-align: center; padding: 20px 16px 40px; }
.aqbh-main header { padding-top: 45px; }
.aqbh-eyebrow { font-size: 12px; letter-spacing: var(--aqb-track-label); color: var(--aqb-text-muted); }
.aqbh-main h1 { margin: 6px 0 0; font-size: clamp(25px, 5vw, 65px); color: var(--aqb-text-strong); }
.aqbh-main h1 > span { color: var(--aqb-accent-text); }
[data-theme="dark"] .aqbh-main h1 > span { color: var(--aqb-accent); }
.aqbh-claim { margin: 12px 0 0; color: var(--aqb-text); }
.aqbh-tagline { margin: 4px 0 0; font-size: 15px; color: var(--aqb-accent-text); }
.aqbh-intro { max-width: 560px; margin: 16px auto 0; color: var(--aqb-text-muted); }
.aqbh-hint { padding: 0 12px; font-size: 13px; color: var(--aqb-text-muted); }
.aqbh-toggle {
  cursor: pointer; font: inherit; color: var(--aqb-text-strong);
  background: var(--aqb-card); border: 1px solid var(--aqb-input-border);
  border-radius: var(--aqb-radius); padding: 10px 15px;
}
[data-theme="dark"] .aqbh-toggle { background: var(--aqb-frame-raised); border-color: var(--aqb-metal); color: var(--aqb-metal-light); }
.aqbh-toggle:hover { border-color: var(--aqb-accent-text); }

/* ---------- Würfel (Website: .scene/.cube/.face/.relief) ---------- */
.aqbh-scene {
  --edge: min(210px, 32vw); --half: calc(var(--edge) / 2);
  width: var(--edge); height: var(--edge); margin: 80px auto;
  perspective: 1000px; touch-action: none;
}
.aqbh-cube {
  position: relative; width: var(--edge); height: var(--edge);
  transform-style: preserve-3d; transform-origin: 50% 50% 0;
  transform: rotateX(-23deg) rotateY(30deg);
}
.aqbh-face {
  appearance: none; position: absolute; inset: 0; width: var(--edge); height: var(--edge); padding: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  background: var(--aqb-metal-gradient); border: 1px solid var(--aqb-accent); border-radius: 0;
  box-shadow: inset 0 0 12px color-mix(in srgb, #fff 9%, transparent);
  color: var(--aqb-on-frame); font: 600 18px var(--aqb-font);
  backface-visibility: hidden; transform-style: preserve-3d; overflow: visible;
}
.aqbh-face.is-link { cursor: pointer; }
.aqbh-face::before {
  content: ""; position: absolute; inset: 8px; pointer-events: none; transform: translateZ(1px);
  border: 1px solid color-mix(in srgb, var(--aqb-metal-light) 27%, transparent);
}
.aqbh-face.is-link:hover, .aqbh-face.is-link:focus-visible,
.aqbh-split button:hover .relief, .aqbh-split button:focus-visible .relief {
  outline: none;
}
.aqbh-face.is-link:hover, .aqbh-face.is-link:focus-visible {
  background: linear-gradient(145deg, var(--aqb-metal-light), var(--aqb-frame-raised) 50%, var(--aqb-frame));
}
.aqbh-front  { transform: translateZ(var(--half)); }
.aqbh-back   { transform: rotateY(180deg) translateZ(var(--half)); }
.aqbh-right  { transform: rotateY(90deg)  translateZ(var(--half)); }
.aqbh-left   { transform: rotateY(-90deg) translateZ(var(--half)); }
.aqbh-top    { transform: rotateX(90deg)  translateZ(var(--half)); }
.aqbh-bottom { transform: rotateX(-90deg) translateZ(var(--half)); }

.aqbh-relief { position: relative; display: grid; place-items: center; transform-style: preserve-3d; pointer-events: none; flex: none; }
.aqbh-relief.icon { width: 50px; height: 50px; }
.aqbh-relief.word { width: 100%; height: 24px; font-size: 18px; font-weight: 800; letter-spacing: .025em; }
.aqbh-relief .layer {
  position: absolute; inset: 0; display: grid; place-items: center;
  backface-visibility: hidden; pointer-events: none; color: var(--aqb-frame);
}
.aqbh-relief .layer svg { width: 46px; height: 46px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.aqbh-relief .layer.cap { color: var(--aqb-on-frame); text-shadow: 0 1px 0 color-mix(in srgb, #fff 53%, transparent); }
.aqbh-relief.icon .layer.cap { color: var(--aqb-on-frame); }
.aqbh-relief .layer.cap svg { filter: drop-shadow(0 0 2px color-mix(in srgb, #fff 33%, transparent)); }

/* Zwei Einträge auf einer Fläche (Website: Governance/Security) */
.aqbh-split { gap: 10px; }
.aqbh-split button {
  appearance: none; width: 85%; padding: 0; background: transparent; border: 0;
  color: inherit; cursor: pointer; transform-style: preserve-3d; overflow: visible;
}
.aqbh-split button:hover .layer.cap, .aqbh-split button:focus-visible .layer.cap { color: var(--aqb-accent); }
.aqbh-split .aqbh-relief.word { font-size: 15px; height: 20px; }
.aqbh-split .aqbh-relief.icon { width: 35px; height: 35px; }
.aqbh-split .aqbh-relief.icon svg { width: 32px; height: 32px; }

/* ---------- Schmal (Website: max-width 650px) ---------- */
@media (max-width: 650px) {
  .aqbh-shell { --aqbh-sidebar: 135px; }
  .aqbh-sidebar { padding: 20px 7px; }
  .aqbh-brand { font-size: 12px; letter-spacing: 1px; }
  .aqbh-nav a { font-size: 12px; gap: 6px; padding: 12px 4px; }
  .aqbh-main { padding: 12px 4px; }
  .aqbh-main h1 { font-size: clamp(16px, 4vw, 30px); }
  .aqbh-eyebrow { font-size: 9px; }
  .aqbh-scene { --edge: min(135px, 32vw); margin: 65px auto; }
  .aqbh-face { gap: 4px; }
  .aqbh-relief.icon { width: 34px; height: 34px; }
  .aqbh-relief .layer svg { width: 30px; height: 30px; }
  .aqbh-relief.word { font-size: 13px; }
  .aqbh-split .aqbh-relief.word { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) { .aqbh-shell * { scroll-behavior: auto; } }

/* ---------- Frappes Website-Stylesheet neutralisieren ----------
   Seit 7cfb0d6 lädt die Landing Page Frappes website.bundle.css (vorher scheiterte der Link mit 404).
   Es bringt Grundtypografie und Bootstrap-Reset mit (Strichstärke 420, Zeilenhöhe 24px, Zeichen-
   abstand .02em, Kantenglättung, optische Größe 24, border-box, Links ohne Unterstrich, eigene Absatzränder). Die Seite
   ist ohne diese Werte gestaltet: hier zurück auf das Verhalten von vorher.
   Alles über :where() — Gewicht 0 bzw. nur das Element. Das schlägt Frappes ebenso leichte Regeln,
   weil es später geladen wird, aber nie eine Klassen-Regel dieser Datei (z. B. .aqbh-sidebar mit
   border-box, .aqbh-sidebar-footer mit line-height 1.7, .aqbh-brand ohne Unterstrich). */
:where(.aqbh-shell) {
  font-weight: 400; line-height: normal; letter-spacing: normal;
  -webkit-font-smoothing: auto; -moz-osx-font-smoothing: auto;
  font-variation-settings: normal;   /* Frappe: "opsz" 24 — kleine Texte liefen schmaler */
}
:where(.aqbh-shell, .aqbh-shell *, .aqbh-shell *::before, .aqbh-shell *::after) { box-sizing: content-box; }
:where(.aqbh-shell) :where(button, input, select, textarea) { box-sizing: border-box; }
:where(.aqbh-shell) h1, :where(.aqbh-shell) p { line-height: normal; }
:where(.aqbh-shell) p { margin-top: 1em; margin-bottom: 1em; }
:where(.aqbh-shell) a { text-decoration: underline; }
