:root{
    --bg: #0b1020;
    --card: rgba(255,255,255,0.06);
    --line: rgba(255,255,255,0.12);
    --text: #e9eefc;
    --muted: #a8b3d6;
    --accent: #6aa6ff;
    --danger: #ff6a6a;
    --shadow: 0 18px 60px rgba(0,0,0,0.45);
    --radius: 18px;
    --font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  }
  
  *{box-sizing:border-box}
  html,body{height:100%}
  body{
    margin:0;
    font-family: var(--font);
    background: radial-gradient(1200px 600px at 20% 10%, rgba(106,166,255,0.18), transparent 60%),
                radial-gradient(900px 500px at 80% 30%, rgba(255,106,106,0.12), transparent 55%),
                var(--bg);
    color: var(--text);
  }
  
  .page{
    min-height:100%;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:24px;
  }
  
  .grid{
    width:100%;
    max-width: 980px;
    display:grid;
    grid-template-columns: 420px 1fr;
    gap:18px;
  }
  
  @media (max-width: 900px){
    .grid{grid-template-columns:1fr; max-width:520px;}
  }
  
  .card{
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding:22px;
    backdrop-filter: blur(10px);
  }
  
  .brand{
    font-size:12px;
    letter-spacing:0.12em;
    text-transform:uppercase;
    color: var(--muted);
    margin-bottom:10px;
  }
  
  h1{
    margin:0 0 12px 0;
    font-size:22px;
    line-height:1.2;
  }
  
  .langbar{
    display:flex;
    align-items:center;
    gap:10px;
    padding:10px 0 14px 0;
    border-bottom:1px solid var(--line);
    margin-bottom:14px;
  }
  
  .langbar .label{color:var(--muted); font-size:13px}
  .flag{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:34px;
    height:26px;
    border-radius:8px;
    border:1px solid rgba(255,255,255,0.16);
    text-decoration:none;
    font-size:16px;
    line-height:1;
  }
  .flag:hover{
    border-color: rgba(106,166,255,0.55);
    background: rgba(106,166,255,0.08);
  }
  
  .alert{
    background: rgba(255,106,106,0.12);
    border: 1px solid rgba(255,106,106,0.30);
    color: #ffd0d0;
    padding:10px 12px;
    border-radius:12px;
    margin-bottom:12px;
    font-size:14px;
  }
  
  .form{
    display:flex;
    flex-direction:column;
    gap:10px;
  }
  
  label{
    font-size:13px;
    color: var(--muted);
    margin-top:6px;
  }
  
  input{
    width:100%;
    padding:12px 12px;
    border-radius:12px;
    border: 1px solid var(--line);
    background: rgba(0,0,0,0.18);
    color: var(--text);
    outline:none;
  }
  input:focus{
    border-color: rgba(106,166,255,0.65);
    box-shadow: 0 0 0 4px rgba(106,166,255,0.15);
  }
  
  .btn{
    margin-top:10px;
    padding:12px 14px;
    border:0;
    border-radius:12px;
    cursor:pointer;
    color:#06102a;
    font-weight:700;
    background: linear-gradient(180deg, rgba(106,166,255,1), rgba(106,166,255,0.80));
  }
  .btn:hover{ filter: brightness(1.05); }
  
  .info h2{
    margin:0 0 10px 0;
    font-size:18px;
  }
  .info p{
    margin:0 0 10px 0;
    color: var(--muted);
    line-height:1.55;
  }
  
  .small{
    color: var(--muted);
    font-size:12px;
    border-top:1px solid var(--line);
    padding-top:12px;
    margin-top:12px;
  }
  

  .pwwrap {
    position: relative;
    display: flex;
    align-items: center;
  }
  
  .pwwrap input {
    width: 100%;
    padding-right: 44px;
  }
  
  .pwtoggle {
    position: absolute;
    right: 10px;
    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.9);
    width: 34px;
    height: 34px;
    border-radius: 10px;
    cursor: pointer;
    display: grid;
    place-items: center;
  }
  
  .pwtoggle:hover {
    background: rgba(255,255,255,.10);
  }

  
  .checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    text-align: left;
  }
  
  .checkbox-row input[type="checkbox"] {
    margin-top: 4px;
    flex-shrink: 0;
  }

  .company-box {
    font-size: 0.95rem;
    line-height: 1.5;
    opacity: 0.9;
    margin-bottom: 16px;
  }

  /* normale Inputs, aber NICHT checkbox/radio */
.form input:not([type="checkbox"]):not([type="radio"]),
.form select,
.form textarea {
  width: 100%;
  box-sizing: border-box;
}

/* checkbox rows immer volle Breite, links */
.form .checkbox-row{
  display:flex;
  align-items:flex-start;
  gap:10px;
  width:100%;
  text-align:left;
}

/* checkbox selbst NICHT auf 100% aufblasen */
.form .checkbox-row input[type="checkbox"]{
  width:auto;
  margin-top:4px;
  flex:0 0 auto;
}

/* Text darf umbrechen und bleibt im Container */
.form .checkbox-row span{
  flex:1 1 auto;
  min-width:0;
  word-break: break-word;
}

a.link,
a.link:visited {
  color: #ffffff;
  text-decoration: underline;
}

a.link:hover {
  color: #e5e5e5;
}

/* tables on small screens */
table.models {
  width: 100%;
  table-layout: fixed;
}

table.models th, table.models td {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* allow wrap for email + name */
td.col-email, td.col-name {
  white-space: normal;
  word-break: break-word;
}

/* keep action tiny */
td.col-action {
  width: 44px;
  text-align: center;
}

a.icon-link {
  display: inline-block;
  width: 34px;
  height: 34px;
  line-height: 34px;
  text-align: center;
  text-decoration: none;
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
}

a.icon-link:hover {
  background: rgba(255,255,255,0.12);
}


.model-list{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.model-row{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:12px 14px;
  border-radius:14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
}

.model-row:hover{
  background: rgba(255,255,255,0.07);
}

.model-row .left{
  min-width:0;
  flex:1;
}

.model-row .line1{
  display:flex;
  gap:10px;
  align-items:baseline;
  min-width:0;
}

.model-row .mid{
  opacity:.75;
  font-size:12px;
  flex:0 0 auto;
}

.model-row .name{
  font-weight:700;
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.model-row .line2{
  margin-top:4px;
  opacity:.8;
  font-size:13px;
  word-break: break-word;
}

.model-row .right{
  display:flex;
  gap:8px;
  flex:0 0 auto;
}

.pill{
  width:36px;
  height:36px;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  background: rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.10);
}


.tabs {
  display: flex;
  gap: 10px;              /* Abstand zwischen Buttons */
  width: 100%;
  margin-bottom: 14px;
}

.tabs .tab {
  flex: 1;                /* alle gleich breit */
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;

  text-decoration: none;  /* underline weg */
  border-radius: 14px;

  font-size: 18px;
  line-height: 1;

  transition: background 0.15s ease, transform 0.05s ease;
}


.tabs .tab:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}


.tabs .tab.active {
  background: linear-gradient(135deg, #6aa9ff, #4f86ff);
  color: #fff;
}

.tabs .tab:not(.active) {
  opacity: 0.85;
}

.audit-hash-info {
  margin-top: 10px;
  font-size: 0.85em;
  line-height: 1.4;
  opacity: 0.85;
}
.navbtn{
  display:block;
  margin-bottom:8px;
  text-decoration:none;
}

.navbtn.active{
  outline: 2px solid rgba(120,170,255,.55);
  outline-offset: 2px;
}


.uid{
  min-width:22px;
  height:18px;
  padding:0 4px;
  margin-right:6px;   /* enger an den Namen */
  font-size:.7em;
  border-radius:5px;
}

.roleBadge{
  width:18px;
  height:18px;
  font-size:.7em;
  margin-right:4px;   /* vorher zu groß */
  border-radius:50%;
}

.role-model{ color: #ffd86b; }
.role-admin{ color: #ff7b7b; }
.role-superadmin{ color: #ff7b7b; }
.role-auditor{ color: #7dff9e; }


.name{
  display:flex;
  align-items:center;
  gap:0;              /* ganz wichtig */
  white-space:nowrap; /* verhindert Umbruch */
}

.mail{
  font-size:.85em;
  opacity:.85;
  margin-top:2px;
}

.user-card, .card.user{
  padding:12px 14px; /* statt z.B. 18px */
}

.iconbtn,
.icon-link{
  width:32px;
  height:32px;
  padding:0;
  border-radius:10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size:15px;
}

.btn.iconbtn{
  width:32px;
  height:32px;
  padding:0;
  border-radius:10px;
  font-size:15px;
}
.user-card{
  min-height:auto;
}

.card.user-item{
  padding:10px 12px;      /* weniger Innenabstand */
}

.card.user-item .row2{
  gap:10px;               /* falls row2 viel Abstand macht */
}

.card.user-item .u2{
  gap:2px;                /* falls du u2 als column mit gap nutzt */
}

.card.user-item .name{
  line-height:1.15;
}

.card.user-item .mail{
  margin-top:2px;
  line-height:1.1;
}


.statusLine{
  display:flex;
  gap:10px;
  align-items:flex-start;
  padding:10px 0;
  border-bottom:1px solid rgba(255,255,255,.08);
}
.statusLine:last-child{ border-bottom:none; }

.statusText{ line-height:1.25; }

.page{
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px;
}
.grid{
  display:grid;
  grid-template-columns: minmax(520px, 1fr) 360px; /* links flexibel, rechts fix */
  gap: 18px;
  align-items: start;
}

@media (max-width: 980px){
  .grid{ grid-template-columns: 1fr; }
}

/* blockierte / inaktive User */
.user-item.is-blocked{
  background:
    linear-gradient(
      0deg,
      rgba(255, 70, 70, 0.22),
      rgba(255, 70, 70, 0.22)
    ),
    var(--card-bg, rgba(255,255,255,0.04));
}


.user-item.is-blocked .iconbtn{
  opacity: .85;
}


.navbtn.disabled {
  opacity: .45;
  pointer-events: none;
  cursor: not-allowed;
}

.blurred .thumb img { filter: blur(10px); }
.blurred .thumb { position: relative; }
.blurred .thumb::after{
  content:"";
  position:absolute; inset:0;
  background: rgba(0,0,0,.18);
}

.statusBadge{
  display:inline-flex; align-items:center; gap:10px;
  padding:10px 14px; border-radius:12px;
  font-weight:700; font-size:16px;
  border:1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.06);
}
.statusBadge .dot{
  width:10px; height:10px; border-radius:50%;
  background: rgba(255,255,255,.55);
}

.status-pending { border-color: rgba(255,200,90,.35); background: rgba(255,200,90,.12); color:#ffd48a; }
.status-approved { border-color: rgba(106,255,180,.35); background: rgba(106,255,180,.12); color:#b9ffd9; }
.status-rejected { border-color: rgba(255,90,90,.35); background: rgba(255,90,90,.12); color:#ffb0b0; }

.btn.disabled, .btn:disabled{
  opacity:.45;
  cursor:not-allowed;
  filter: grayscale(100%);
}