/* SHS Messenger — losse schermen: aanmelden, instellingen-rijen, juridisch. */

/* ------------------------------------------------------------------ aanmelden */

.login-page {
  position: fixed; inset: 0; z-index: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 24px 16px 70px; overflow: auto;
}
.login-bg { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: -1; }
.login-bg .petal {
  position: absolute; width: 420px; height: 1100px; border-radius: 50%;
  opacity: .16; filter: blur(2px); transform-origin: 50% 100%;
  animation: petal-sway 18s ease-in-out infinite alternate;
}
.login-bg .p1 { left: -6%; bottom: -55%; background: linear-gradient(#ffd659, #ffab1f); transform: rotate(-38deg); }
.login-bg .p2 { left: 4%; bottom: -60%; background: linear-gradient(#ff9a5c, #f2632f); transform: rotate(-14deg); animation-delay: -4s; }
.login-bg .p3 { right: 2%; bottom: -60%; background: linear-gradient(#7fe08f, #2fb35a); transform: rotate(14deg); animation-delay: -8s; }
.login-bg .p4 { right: -8%; bottom: -55%; background: linear-gradient(#7cc8ff, #2380e8); transform: rotate(38deg); animation-delay: -12s; }
@keyframes petal-sway { to { translate: 0 -40px; rotate: 4deg; } }

.login-win {
  width: min(420px, 100%);
  border-radius: 22px; overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.78));
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 30px 80px rgba(12, 46, 96, 0.25), 0 2px 0 rgba(255,255,255,.9) inset;
}
:root[data-theme="nacht"] .login-win { background: linear-gradient(180deg, rgba(22,40,66,.94), rgba(16,30,52,.88)); border-color: rgba(124,180,255,.18); }
.login-win.shake { animation: shake .45s; }
@keyframes shake { 0%,100% { transform: none; } 20% { transform: translateX(-9px); } 40% { transform: translateX(8px); } 60% { transform: translateX(-6px); } 80% { transform: translateX(4px); } }

.login-top {
  position: relative; display: flex; align-items: center; justify-content: center;
  padding: 22px 18px 6px;
  background: linear-gradient(180deg, rgba(255,255,255,.9), rgba(234,244,255,0));
}
.login-top .ibtn { position: absolute; right: 12px; top: 12px; }
.login-logo { width: 210px; height: auto; display: block; }
:root[data-theme="nacht"] .login-logo { filter: brightness(1.6) saturate(1.1); }
.login-body { padding: 8px 30px 26px; display: flex; flex-direction: column; gap: 14px; }
.login-dp { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 6px; }
.login-hello { font-size: 13.5px; color: var(--ink-2); text-align: center; }
.login-form { gap: 11px; }
.login-h { margin: 0; font-size: 18px; font-weight: 600; color: var(--navy); text-align: center; font-family: var(--font-display); }
:root[data-theme="nacht"] .login-h { color: var(--ink); }
.login-opts { justify-content: space-between; }
.status-pick {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--panel); cursor: pointer; font-size: 13px; font-weight: 600; color: var(--ink);
}
.status-pick:hover { border-color: var(--sel-line); background: var(--panel-2); }
.status-pick .ic { width: 14px; height: 14px; color: var(--muted); }
.linkbtn { border: 0; background: none; padding: 0; color: var(--link); cursor: pointer; font-size: inherit; }
.linkbtn:hover { text-decoration: underline; }
.login-or { display: flex; align-items: center; gap: 10px; color: var(--faint); font-size: 12px; }
.login-or::before, .login-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.panel-sso { gap: 9px; }
.panel-sso img.ic { width: 20px; height: 20px; }
.login-foot {
  position: fixed; left: 0; right: 0; bottom: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); font-size: 12px; color: var(--muted);
}
.login-foot a { color: var(--ink-2); display: inline-flex; align-items: center; gap: 5px; }
.login-foot .ic { width: 15px; height: 15px; }
.mfa-code { text-align: center; font-size: 22px; letter-spacing: 6px; font-family: var(--font-mono); }
.pwmeter { height: 5px; border-radius: 5px; background: var(--panel-3); overflow: hidden; }
.pwmeter span { display: block; height: 100%; width: 0; transition: width .2s, background .2s; }

.signing-in { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 26px 0 30px; }
.spin-petals { width: 120px; height: 120px; position: relative; display: flex; align-items: center; justify-content: center;
  border-radius: 28px; background: linear-gradient(180deg, #fff, #e8f2fd); box-shadow: var(--shadow), inset 0 0 0 1px rgba(47,127,214,.25); }
.spin-petals img { width: 86px; animation: petals-spin 1.4s cubic-bezier(.5, 0, .5, 1) infinite; }
@keyframes petals-spin { 0% { transform: rotate(0) scale(1); } 50% { transform: rotate(180deg) scale(.88); } 100% { transform: rotate(360deg) scale(1); } }

@media (max-width: 760px) {
  .login-page { justify-content: flex-start; padding: calc(16px + env(safe-area-inset-top)) 0 80px; }
  .login-win { width: 100%; border-radius: 0; background: transparent; border: 0; box-shadow: none; }
  .login-top { background: none; padding-top: 28px; }
  .login-body { padding: 8px 22px 20px; }
  .login-foot { background: linear-gradient(180deg, rgba(255,255,255,0), rgba(255,255,255,.7)); }
  :root[data-theme="nacht"] .login-foot { background: linear-gradient(180deg, rgba(15,27,43,0), rgba(15,27,43,.8)); }
}

/* ------------------------------------------------------------------ rijen met instellingen */

.set-row { display: flex; align-items: center; gap: 14px; justify-content: space-between; padding: 6px 0; }
.set-row > div:first-child { min-width: 0; }
.set-row b { font-weight: 600; }

.legal h4 { margin: 14px 0 4px; color: var(--blue-d); }
.legal p, .legal ul { margin: 4px 0; }
.legal li { margin: 3px 0; }

/* ------------------------------------------------------------------ instellingen dialog */

.set-layout {
  display: grid;
  grid-template-columns: 210px 1fr;
  min-height: 480px;
  max-height: 75vh;
  margin: -18px;
}
.set-nav {
  padding: 14px 10px;
  background: var(--panel-2);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 3px;
  overflow-y: auto;
}
.set-nav button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 8px 12px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--ink-2);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}
.set-nav button:hover { background: var(--hover); color: var(--ink); }
.set-nav button.on { background: var(--title); color: #fff; }
.set-nav button.on .ic { color: #fff; }
.set-nav button.danger { color: var(--red); }
.set-nav button.danger:hover { background: rgba(220, 53, 69, 0.1); }
.set-nav button.danger.on { background: var(--red); color: #fff; }
.set-nav .sep { height: 1px; background: var(--line); margin: 6px 0; }
.set-pane {
  padding: 20px 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.set-pane h2 { margin: 0 0 4px; font-size: 18px; font-weight: 700; color: var(--navy); }
:root[data-theme="nacht"] .set-pane h2 { color: #fff; }
.set-pane h3 { margin: 12px 0 4px; font-size: 14px; font-weight: 600; color: var(--ink); }
.set-section { display: flex; flex-direction: column; gap: 10px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.set-section:last-child { border-bottom: 0; }

.preset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 10px; margin-top: 6px; }
.preset-item { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px; border: 2px solid transparent; border-radius: 10px; background: var(--panel-2); cursor: pointer; }
.preset-item:hover { border-color: var(--blue-l); background: var(--hover); }
.preset-item.on { border-color: var(--blue); background: var(--sel-bg, rgba(47,127,214,0.15)); }
.scene-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; margin-top: 6px; }
.scene-item { height: 50px; border-radius: 8px; border: 2px solid transparent; cursor: pointer; background-size: cover; background-position: center; display: flex; align-items: flex-end; padding: 4px 6px; color: #fff; font-size: 11px; font-weight: 700; text-shadow: 0 1px 2px #000; }
.scene-item.on { border-color: #fff; box-shadow: 0 0 0 2px var(--blue); }

.vol-meter { height: 10px; border-radius: 5px; background: var(--panel-3); overflow: hidden; margin-top: 4px; }
.vol-fill { height: 100%; width: 0; background: #28a745; transition: width .1s; }

@media (max-width: 760px) {
  .set-layout { grid-template-columns: 1fr; min-height: 0; margin: -14px; }
  .set-nav { border-right: 0; border-bottom: 1px solid var(--line); flex-direction: row; overflow-x: auto; padding: 6px; }
  .set-nav button { white-space: nowrap; padding: 6px 10px; font-size: 12px; }
  .set-pane { padding: 14px; }
}

/* ------------------------------------------------------------------ server rollen */

.roles-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 16px;
  min-height: 400px;
}
.roles-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-right: 1px solid var(--line);
  padding-right: 12px;
}
.role-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 0;
  background: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}
.role-item:hover { background: var(--hover); }
.role-item.on { background: var(--title); color: #fff; }
.role-item.on .role-dot { box-shadow: 0 0 0 2px #fff; }
.role-edit {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-left: 4px;
  overflow-y: auto;
  max-height: 60vh;
}
.perm-group {
  margin: 16px 0 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .4px;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  padding-bottom: 4px;
}
.perm-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 9px;
  background: var(--panel-2);
  margin-bottom: 4px;
  cursor: pointer;
}
.perm-switch:hover { background: var(--hover); }
.perm-switch .grow {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}
.perm-switch small {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--muted);
}

/* ------------------------------------------------------------------ startpagina (home) */

.home-view, main > .home {
  height: 100%;
  overflow-y: auto;
  padding: 28px 32px 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.home-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px;
  border-radius: var(--r-l, 20px);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.88) 0%, rgba(225, 240, 255, 0.65) 100%);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-s);
  position: relative;
  overflow: hidden;
}
:root[data-theme="nacht"] .home-hero {
  background: linear-gradient(135deg, rgba(28, 52, 86, 0.88) 0%, rgba(18, 36, 62, 0.65) 100%);
  border-color: var(--line-2);
}

.hh-text h1 {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 700;
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
}
:root[data-theme="nacht"] .hh-text h1 { color: #fff; }

.hh-text p {
  margin: 0;
  font-size: 14px;
  color: var(--ink-2);
}

.hh-logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  opacity: 0.9;
  filter: drop-shadow(0 4px 12px rgba(17, 62, 120, 0.15));
}

.home-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
}

.qa {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 10px;
  border-radius: var(--r, 14px);
  border: 1px solid var(--line-2);
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 600;
  transition: all .15s ease;
  box-shadow: 0 1px 3px rgba(17, 62, 120, 0.05);
}
.qa:hover {
  transform: translateY(-2px);
  background: var(--hover);
  box-shadow: var(--shadow-s);
}
.qa-ic {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.qa-ic .ic { width: 20px; height: 20px; }

.qa-blue .qa-ic { background: rgba(47, 127, 214, 0.15); color: #2f7fd6; }
.qa-green .qa-ic { background: rgba(46, 179, 90, 0.15); color: #2eb35a; }
.qa-orange .qa-ic { background: rgba(255, 122, 69, 0.15); color: #ff7a45; }
.qa-pink .qa-ic { background: rgba(255, 90, 176, 0.15); color: #ff5ab0; }
.qa-sky .qa-ic { background: rgba(124, 198, 255, 0.2); color: #1d7ad6; }
.qa-yellow .qa-ic { background: rgba(255, 194, 58, 0.2); color: #d98a12; }

.home-cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.home-card {
  border-radius: var(--r, 14px);
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 18px;
  box-shadow: 0 1px 3px rgba(17, 62, 120, 0.05);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.home-card h3 {
  margin: 0;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: 8px;
}
:root[data-theme="nacht"] .home-card h3 { color: #fff; }
.home-card h3 .ic { width: 17px; height: 17px; color: var(--blue); }

.online-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
  gap: 8px;
}
.og-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 4px;
  border-radius: 10px;
  border: 0;
  background: none;
  cursor: pointer;
  color: var(--ink);
  font-size: 11.5px;
  text-align: center;
  gap: 4px;
}
.og-item:hover { background: var(--hover); }
.og-item .ellipsis { max-width: 72px; }
.og-psm { font-size: 10px; color: var(--muted); }

.recent {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 10px;
  border: 0;
  background: none;
  cursor: pointer;
  color: var(--ink);
  font-size: 13px;
  text-align: left;
}
.recent:hover { background: var(--hover); }
.recent .group-pic {
  display: flex;
  position: relative;
  width: 32px;
  height: 32px;
}
.recent .group-pic .dp { position: absolute; }
.recent .group-pic .dp:nth-child(1) { top: 0; left: 0; z-index: 3; }
.recent .group-pic .dp:nth-child(2) { top: 4px; left: 10px; z-index: 2; }
.recent .group-pic .dp:nth-child(3) { top: 8px; left: 16px; z-index: 1; }

.home-servers {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hs {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 10px;
  border: 1px solid var(--line-2);
  background: var(--panel-2);
  cursor: pointer;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
}
.hs:hover { background: var(--hover); border-color: var(--sel-line); }
.hs .sicon { width: 22px; height: 22px; border-radius: 6px; }

.tip-body {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 8px 4px;
}
.tip-ic {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(255, 194, 58, 0.25), rgba(255, 122, 69, 0.15));
  color: #d98a12;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.tip-ic .ic { width: 20px; height: 20px; }
.tip-body p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.45;
  color: var(--ink-2);
}

.home-foot {
  margin-top: auto;
  padding-top: 16px;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}
.home-foot a { color: var(--ink-2); text-decoration: none; }
.home-foot a:hover { text-decoration: underline; }

@media (max-width: 900px) {
  .home-cols { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .home-view, main > .home { padding: 16px 14px 40px; gap: 16px; }
  .home-hero { padding: 18px 16px; }
  .hh-logo { width: 52px; height: 52px; }
  .home-actions { grid-template-columns: repeat(3, 1fr); }
  .roles-layout { grid-template-columns: 1fr; }
  .roles-list { border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
}

/* ------------------------------------------------------------------ spelletjes */

.game-modal { width: min(600px, 100%); }
.game-board { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 10px 0; }
.ttt-grid { display: grid; grid-template-columns: repeat(3, 80px); grid-template-rows: repeat(3, 80px); gap: 6px; }
.ttt-cell { display: flex; align-items: center; justify-content: center; font-size: 38px; font-weight: 800; border-radius: 12px; border: 2px solid var(--line-2); background: var(--panel); cursor: pointer; user-select: none; }
.ttt-cell:hover:not(:disabled) { background: var(--hover); border-color: var(--blue); }
.ttt-cell.x { color: var(--blue); }
.ttt-cell.o { color: var(--red); }
.c4-grid { display: grid; grid-template-columns: repeat(7, 44px); grid-template-rows: repeat(6, 44px); gap: 6px; padding: 10px; background: #1c64d2; border-radius: 14px; box-shadow: var(--shadow); }
.c4-cell { border-radius: 50%; background: #ffffff; cursor: pointer; transition: transform .15s, background .15s; }
.c4-cell:hover:not(:disabled) { transform: scale(1.08); }
.c4-cell.p1 { background: #e02424; }
.c4-cell.p2 { background: #faca15; }
.mines-grid { display: grid; gap: 2px; background: #999; padding: 3px; border-radius: 6px; }
.mines-cell { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px; background: #c0c0c0; border: 2px outset #fff; cursor: pointer; }
.mines-cell.revealed { border: 1px solid #777; background: #e0e0e0; }
.scribble-canvas { border: 2px solid var(--line-2); border-radius: 8px; background: #fff; cursor: crosshair; }

/* ------------------------------------------------------------------ ontdekken (discover) */

.discover-view, .workshop-view, .developer-view, .admin-view {
  height: 100%; display: flex; flex-direction: column; overflow-y: auto;
}
.discover-hero, .workshop-hero, .developer-hero, .admin-hero {
  padding: 28px 32px;
  background: linear-gradient(180deg, rgba(255,255,255,0.65), rgba(255,255,255,0.15));
  border-bottom: 1px solid var(--line);
  position: relative;
}
:root[data-theme="nacht"] .discover-hero,
:root[data-theme="nacht"] .workshop-hero,
:root[data-theme="nacht"] .developer-hero,
:root[data-theme="nacht"] .admin-hero {
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.01));
}
.dh-content h1, .wh-content h1, .dev-content h1, .ah-content h1 {
  margin: 0 0 6px; font-size: 24px; font-weight: 700; color: var(--navy); display: flex; align-items: center; gap: 10px;
}
:root[data-theme="nacht"] .dh-content h1,
:root[data-theme="nacht"] .wh-content h1,
:root[data-theme="nacht"] .dev-content h1,
:root[data-theme="nacht"] .ah-content h1 { color: #fff; }
.dh-content p, .wh-content p, .dev-content p, .ah-content p {
  margin: 0 0 16px; color: var(--ink-2); font-size: 14px; max-width: 650px;
}
.dh-search, .wh-search {
  position: relative; max-width: 480px; width: 100%;
}
.dh-icon, .wh-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none;
}
.dh-input, .wh-input {
  width: 100%; padding-left: 38px; border-radius: 999px; height: 40px; background: var(--panel);
}

.discover-body, .workshop-body, .developer-body, .admin-body {
  padding: 24px 32px 60px; display: flex; flex-direction: column; gap: 20px;
}
.discover-tags, .workshop-tabs, .dev-tabs, .admin-tabs {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; border-bottom: 1px solid var(--line); padding-bottom: 12px;
}
.dtag, .wtab, .dtab, .atab {
  padding: 7px 16px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--panel);
  font-size: 13px; font-weight: 600; color: var(--ink-2); cursor: pointer; display: flex; align-items: center; gap: 6px;
  transition: all .15s ease;
}
.dtag:hover, .wtab:hover, .dtab:hover, .atab:hover {
  background: var(--hover); color: var(--ink); border-color: var(--sel-line);
}
.dtag.sel, .wtab.sel, .dtab.sel, .atab.sel {
  background: var(--title); color: #fff; border-color: transparent; box-shadow: 0 2px 6px rgba(12, 115, 217, 0.3);
}
.dtag.sel .ic, .wtab.sel .ic, .dtab.sel .ic, .atab.sel .ic { color: #fff; }

.discover-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px;
}
.discover-card {
  border-radius: 14px; padding: 18px; display: flex; flex-direction: column; justify-content: space-between;
  min-height: 180px; gap: 12px; transition: transform .15s, box-shadow .15s;
}
.discover-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
.discover-card.featured { border: 1.5px solid rgba(255, 171, 31, 0.4); background: linear-gradient(180deg, rgba(255, 248, 235, 0.6), var(--panel)); }
:root[data-theme="nacht"] .discover-card.featured { background: linear-gradient(180deg, rgba(255, 171, 31, 0.08), var(--panel)); }
.dc-top { display: flex; gap: 12px; align-items: flex-start; }
.dc-head { flex: 1; min-width: 0; }
.dc-title-row { display: flex; align-items: center; gap: 6px; justify-content: space-between; }
.dc-name { margin: 0; font-size: 15px; font-weight: 700; color: var(--navy); }
:root[data-theme="nacht"] .dc-name { color: #fff; }
.featured-badge { background: #ffab1f; color: #fff; font-size: 11px; padding: 2px 6px; border-radius: 999px; }
.dc-meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); margin-top: 3px; }
.dc-desc { margin: 0; font-size: 13px; color: var(--ink-2); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.dc-foot { margin-top: auto; padding-top: 6px; }

.discover-banner {
  border-radius: 16px; padding: 20px 24px; display: flex; align-items: center; justify-content: space-between;
  gap: 16px; margin-top: 20px; background: linear-gradient(90deg, rgba(79, 148, 245, 0.12), rgba(35, 128, 232, 0.05));
}
.db-info h3 { margin: 0 0 4px; font-size: 16px; font-weight: 700; color: var(--navy); display: flex; align-items: center; gap: 6px; }
:root[data-theme="nacht"] .db-info h3 { color: #fff; }
.db-info p { margin: 0; font-size: 13px; color: var(--ink-2); }

.discover-empty, .workshop-empty, .dev-empty, .admin-empty, .admin-denied {
  grid-column: 1 / -1; padding: 48px 24px; text-align: center; border-radius: 16px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
}
.de-icon, .we-icon, .ae-icon, .ad-icon { width: 44px; height: 44px; color: var(--muted); }
.de-icon.danger, .ae-icon.danger, .ad-icon.danger { color: var(--red); }
.ae-icon.success { color: #28a745; }

/* ------------------------------------------------------------------ werkplaats (workshop) */

.wh-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.workshop-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px;
}
.workshop-card {
  border-radius: 14px; padding: 18px; display: flex; flex-direction: column; justify-content: space-between;
  min-height: 200px; gap: 10px; transition: transform .15s, box-shadow .15s;
}
.workshop-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
.wc-top { display: flex; align-items: center; justify-content: space-between; }
.wc-version { font-size: 11px; color: var(--muted); font-family: var(--font-mono); }
.wc-title { margin: 2px 0 0; font-size: 16px; font-weight: 700; color: var(--navy); }
:root[data-theme="nacht"] .wc-title { color: #fff; }
.wc-summary { margin: 0; font-size: 13px; color: var(--ink-2); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wc-author { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.wc-foot { display: flex; align-items: center; justify-content: space-between; margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.wc-installs { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
.wc-actions { display: flex; align-items: center; gap: 6px; }

.badge.kind-theme { background: rgba(255, 171, 31, 0.15); color: #d97706; }
.badge.kind-plugin { background: rgba(59, 130, 246, 0.15); color: #2563eb; }
.badge.kind-bot { background: rgba(16, 185, 129, 0.15); color: #059669; }

.source-preview {
  background: var(--panel-3); border-radius: 8px; padding: 12px; overflow-x: auto;
  font-family: var(--font-mono); font-size: 12px; line-height: 1.5; max-height: 320px;
}
.source-modal { max-width: 600px; display: flex; flex-direction: column; gap: 12px; }
.sm-meta { display: flex; align-items: center; gap: 12px; font-size: 12.5px; color: var(--muted); }
.sm-desc { font-size: 13.5px; line-height: 1.4; color: var(--ink); }

.mine-sections { display: flex; flex-direction: column; gap: 24px; }
.mine-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; margin-top: 10px; }
.mine-card { padding: 14px; border-radius: 12px; display: flex; flex-direction: column; gap: 6px; }
.mc-head { display: flex; align-items: center; gap: 8px; justify-content: space-between; }
.mc-head h4 { margin: 0; font-size: 14px; font-weight: 700; flex: 1; }
.mc-actions { margin-top: auto; display: flex; gap: 6px; justify-content: flex-end; }

/* ------------------------------------------------------------------ ontwikkelaars (developer) */

.dev-apps-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.dev-app-card { border-radius: 14px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.dac-head { display: flex; align-items: center; gap: 12px; }
.dac-info { flex: 1; min-width: 0; }
.dac-info h3 { margin: 0; font-size: 15px; font-weight: 700; color: var(--navy); }
:root[data-theme="nacht"] .dac-info h3 { color: #fff; }
.dac-desc { margin: 0; font-size: 13px; color: var(--ink-2); line-height: 1.4; }
.dac-meta { display: flex; flex-direction: column; gap: 4px; }
.dac-foot { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 8px; border-top: 1px solid var(--line); }

.app-manage-modal { display: flex; flex-direction: column; gap: 14px; max-width: 540px; }
.cmd-list { display: flex; flex-direction: column; gap: 6px; max-height: 160px; overflow-y: auto; }
.cmd-item { display: flex; align-items: center; justify-content: space-between; padding: 6px 10px; border-radius: 6px; background: var(--panel-2); font-size: 13px; }
.token-box { display: flex; gap: 8px; margin-top: 10px; }

/* ------------------------------------------------------------------ beheer (admin) */

.ah-badge {
  display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; text-transform: uppercase;
  color: #2563eb; background: rgba(37, 99, 235, 0.1); padding: 3px 10px; border-radius: 999px; margin-bottom: 8px;
}
.admin-stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.stat-card {
  border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 6px; position: relative; overflow: hidden;
}
.stat-ic { position: absolute; right: 16px; top: 16px; width: 32px; height: 32px; opacity: .25; }
.stat-num { font-size: 32px; font-weight: 800; color: var(--navy); font-family: var(--font-display); }
:root[data-theme="nacht"] .stat-num { color: #fff; }
.stat-lbl { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.stat-sub { font-size: 12px; color: var(--muted); }

.admin-panel { border-radius: 16px; padding: 22px; display: flex; flex-direction: column; }
.table-wrap { overflow-x: auto; width: 100%; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; text-align: left; }
.admin-table th { padding: 10px 12px; border-bottom: 2px solid var(--line); color: var(--muted); font-weight: 600; text-transform: uppercase; font-size: 11px; }
.admin-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.admin-table tr:hover td { background: var(--hover); }

.reports-list { display: flex; flex-direction: column; gap: 12px; }
.report-card { border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.rc-head { display: flex; align-items: center; justify-content: space-between; }
.rc-details { margin: 0; font-size: 13.5px; line-height: 1.4; color: var(--ink); }

@media (max-width: 760px) {
  .discover-hero, .workshop-hero, .developer-hero, .admin-hero { padding: 18px 16px; }
  .discover-body, .workshop-body, .developer-body, .admin-body { padding: 16px; }
  .discover-grid, .workshop-grid, .dev-apps-grid, .admin-stats-grid { grid-template-columns: 1fr; }
}
