/* Design-System „Mathias Rauh – Dark“: Navy trägt, Teal strukturiert, Orange
   nur für den einen Hauptknopf. Keine Schatten. */
@font-face { font-family: "Space Grotesk"; src: url("/fonts/SpaceGrotesk.woff2") format("woff2"); font-weight: 300 700; }
@font-face { font-family: "DM Sans"; src: url("/fonts/DMSans.woff2") format("woff2"); font-weight: 100 1000; }
:root {
  --navy: #0a1628; --card: #0f1926; --border: #1a2840; --teal: #00d4c8; --orange: #f09030;
  --cream: #f0ede8; --steel: #7a8a9e; --white: #fff;
  --display: "Space Grotesk", system-ui, sans-serif; --body: "DM Sans", system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--navy); color: var(--cream); font: 16px/1.5 var(--body); }
a { color: var(--teal); text-decoration: none; }
h1, h2, h3, .brand, button, .kicker { font-family: var(--display); }
h1 { color: var(--white); font-size: 26px; margin: 0 0 4px; letter-spacing: -0.01em; }
h2 { color: var(--white); font-size: 18px; margin: 24px 0 8px; }
.kicker { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--steel); margin: 20px 0 8px; }
.muted { color: var(--steel); font-size: 14px; }
.top { display: flex; justify-content: space-between; align-items: center; padding: 16px; max-width: 1100px; margin: 0 auto; }
.brand { color: var(--white); font-size: 20px; font-weight: 600; }
.line { height: 3px; width: 44px; border-radius: 3px; margin-top: 6px; background: linear-gradient(90deg, var(--teal), var(--orange)); }
nav a, nav button { margin-left: 16px; font-size: 14px; }
main { max-width: 1100px; margin: 0 auto; padding: 0 16px 48px; }
button { cursor: pointer; border-radius: 8px; padding: 10px 16px; font-size: 14px; font-weight: 600; border: 1px solid var(--steel); background: transparent; color: var(--teal); }
button.primary { background: var(--orange); border-color: var(--orange); color: var(--navy); }
button.link { border: 0; padding: 0; background: none; color: var(--teal); }
button:disabled { opacity: .45; cursor: default; }
input, select { font: 16px var(--body); color: var(--cream); background: var(--card); border: 1px solid var(--steel); border-radius: 8px; padding: 10px 12px; }
input:focus, select:focus, button:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.panel { background: rgba(0, 212, 200, .08); border: 1px solid rgba(0, 212, 200, .2); border-radius: 8px; padding: 12px 14px; margin: 12px 0; }
.panel.warn { background: rgba(240, 144, 48, .08); border-color: rgba(240, 144, 48, .2); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px 10px; }
.tile { cursor: pointer; }
.tile .cover { aspect-ratio: 1; border: 1.5px solid var(--teal); border-radius: 8px; background: var(--card) center/cover no-repeat; display: grid; place-items: center; color: var(--teal); font-size: 28px; }
.tile .name { font-family: var(--display); font-weight: 500; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile .meta { color: var(--steel); font-size: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 3px; margin-top: 12px; }
.grid .cell { aspect-ratio: 1; background: var(--border) center/cover no-repeat; cursor: pointer; position: relative; }
.grid .cell .play { position: absolute; right: 6px; bottom: 4px; color: var(--white); font-size: 13px; text-shadow: 0 0 4px var(--navy); }
.uploads { margin: 12px 0; }
.up { display: grid; grid-template-columns: 1fr 120px 60px; gap: 8px; align-items: center; font-size: 13px; padding: 4px 0; border-bottom: 1px solid var(--border); }
.up .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar { height: 4px; background: var(--border); border-radius: 4px; overflow: hidden; }
.bar > div { height: 100%; background: var(--teal); width: 0; }
.shares { width: 100%; border-collapse: collapse; font-size: 14px; }
.shares td { padding: 8px 4px; border-bottom: 1px solid var(--border); }
.viewer { position: fixed; inset: 0; background: rgba(10, 22, 40, .97); display: grid; grid-template-rows: auto 1fr; z-index: 10; }
.viewer .bar2 { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; }
.viewer .stage { display: grid; place-items: center; overflow: hidden; padding: 0 8px 16px; }
.viewer img, .viewer video { max-width: 100%; max-height: calc(100vh - 80px); }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--card); border: 1px solid var(--border); border-radius: 8px; padding: 10px 16px; z-index: 20; max-width: 90vw; }
.login { max-width: 420px; margin: 40px auto; }
.login input { width: 100%; margin: 12px 0; }
.grid .cell.picked { outline: 3px solid var(--teal); outline-offset: -3px; }
.grid .cell.picked::after { content: "✓"; position: absolute; left: 6px; top: 2px; color: var(--teal); font-weight: bold; text-shadow: 0 0 4px var(--navy); }
