/* =====================================================================
   CR-0006.2 — Administrator GUI
   Isoliertes Styling; verändert keine Trading-, Journal- oder MT5-Regeln.
   ===================================================================== */
.tde-admin-nav { color: #5ac8fa !important; }
.tde-admin-workspace.active {
    display: flex !important;
    flex-direction: column;
    gap: 14px;
    height: calc(100vh - 205px);
    min-height: 0;
    overflow: hidden;
}
.tde-admin-header { flex: 0 0 auto; }
.tde-admin-header-actions { display:flex; align-items:center; gap:10px; }
.tde-admin-stat-grid {
    display:grid;
    grid-template-columns:repeat(5,minmax(145px,1fr));
    gap:10px;
    flex:0 0 auto;
}
.tde-admin-stat-card {
    min-height:92px;
    padding:14px 16px;
    border:1px solid #34363c;
    border-radius:7px;
    background:linear-gradient(180deg,rgba(41,98,255,.08),rgba(255,255,255,.01)),#17181b;
    box-sizing:border-box;
}
.tde-admin-stat-card span,.tde-admin-stat-card small { display:block; color:#8e8e93; }
.tde-admin-stat-card span { font-size:10px; font-weight:800; letter-spacing:.65px; text-transform:uppercase; }
.tde-admin-stat-card strong { display:block; margin:6px 0 3px; color:#f2f2f7; font-size:25px; line-height:1; }
.tde-admin-stat-card small { font-size:10px; }
.tde-admin-table-card { display:flex; flex-direction:column; min-height:0; flex:1 1 auto; overflow:hidden; }
.tde-admin-toolbar { display:flex; justify-content:space-between; align-items:flex-end; gap:18px; padding:14px; border-bottom:1px solid #303238; }
.tde-admin-toolbar h2 { margin:2px 0 0; }
.tde-admin-search-group { display:flex; align-items:center; gap:8px; }
.tde-admin-search-group label { width:auto; color:#aeb1b8; font-weight:700; }
.tde-admin-search-group input { width:260px; min-height:32px; }
.tde-admin-message { display:none; margin:10px 14px 0; padding:9px 11px; border-radius:5px; font-size:12px; font-weight:650; }
.tde-admin-message.visible { display:block; }
.tde-admin-message.info { color:#d9efff; background:rgba(0,122,255,.12); border:1px solid rgba(90,200,250,.3); }
.tde-admin-message.error { color:#ffe6e8; background:rgba(255,69,58,.12); border:1px solid rgba(255,69,58,.35); }
.tde-admin-message.success { color:#ddffe8; background:rgba(48,209,88,.10); border:1px solid rgba(48,209,88,.32); }
.tde-admin-table-scroll { flex:1 1 auto; max-height:none !important; min-height:0; border-left:0; border-right:0; border-radius:0; }
.tde-admin-table td { vertical-align:middle; }
.tde-admin-user-name { color:#f2f2f7; font-weight:750; }
.tde-admin-user-uuid { display:block; max-width:180px; overflow:hidden; text-overflow:ellipsis; color:#636366; font-size:9px; }
.tde-admin-role,.tde-admin-status { display:inline-flex; align-items:center; margin:1px 4px 1px 0; padding:3px 7px; border-radius:4px; font-size:9px; font-weight:850; letter-spacing:.35px; }
.tde-admin-role { color:#d9efff; border:1px solid rgba(90,200,250,.30); background:rgba(0,122,255,.12); }
.tde-admin-role.role-admin { color:#fff0ce; border-color:rgba(255,159,10,.4); background:rgba(255,159,10,.13); }
.tde-admin-role.role-demo { color:#e5dcff; border-color:rgba(175,130,255,.38); background:rgba(140,90,220,.14); }
.tde-admin-status.active { color:#dffff0; border:1px solid rgba(48,209,88,.38); background:rgba(48,209,88,.12); }
.tde-admin-status.locked,.tde-admin-status.disabled { color:#ffe4e6; border:1px solid rgba(255,69,58,.4); background:rgba(255,69,58,.13); }
.tde-admin-action { min-width:92px; min-height:29px !important; }
.tde-admin-action.lock { background:#55242d !important; border:1px solid rgba(255,69,58,.45) !important; }
.tde-admin-action.unlock { background:#1c6f4b !important; border:1px solid rgba(48,209,88,.45) !important; }
.tde-admin-action:disabled { opacity:.45; cursor:not-allowed; }
.tde-admin-empty { padding:30px !important; text-align:center; color:#8e8e93 !important; }
.tde-admin-table-footer { display:flex; justify-content:space-between; padding:9px 14px; color:#75757b; font-size:10px; border-top:1px solid #303238; }
@media(max-width:1200px){.tde-admin-stat-grid{grid-template-columns:repeat(3,1fr)}.tde-admin-toolbar{align-items:stretch;flex-direction:column}.tde-admin-search-group{flex-wrap:wrap}.tde-admin-search-group input{flex:1;min-width:220px}}
@media(max-width:760px){.tde-admin-stat-grid{grid-template-columns:repeat(2,1fr)}.tde-admin-workspace.active{overflow-y:auto}.tde-admin-header-actions{align-items:stretch;flex-direction:column}.tde-admin-table-card{min-height:520px}}

/* CR-0006.3 Rollenverwaltung */
.tde-admin-actions { display:flex; gap:.45rem; flex-wrap:wrap; }
.tde-admin-action.roles { border-color:#5b7cfa; }
.tde-role-dialog { position:fixed; inset:0; z-index:10000; display:none; align-items:center; justify-content:center; padding:1.25rem; background:rgba(3,8,20,.72); backdrop-filter:blur(4px); }
.tde-role-dialog.visible { display:flex; }
.tde-role-dialog-card { width:min(560px,100%); border:1px solid rgba(148,163,184,.28); border-radius:16px; background:#111827; box-shadow:0 24px 80px rgba(0,0,0,.45); overflow:hidden; }
.tde-role-dialog-card header,.tde-role-dialog-card footer { display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:1rem 1.2rem; }
.tde-role-dialog-card header { border-bottom:1px solid rgba(148,163,184,.18); }
.tde-role-dialog-card footer { border-top:1px solid rgba(148,163,184,.18); justify-content:flex-end; }
.tde-role-dialog-card h3 { margin:0 0 .2rem; }
.tde-role-dialog-card p { margin:0; color:#94a3b8; font-size:.88rem; }
.tde-role-dialog-close { border:0; background:transparent; color:#cbd5e1; font-size:1.8rem; cursor:pointer; }
.tde-role-options { display:grid; gap:.65rem; padding:1.2rem; max-height:55vh; overflow:auto; }
.tde-role-option { display:flex; align-items:center; gap:.8rem; padding:.85rem 1rem; border:1px solid rgba(148,163,184,.2); border-radius:12px; cursor:pointer; }
.tde-role-option:hover { border-color:rgba(91,124,250,.7); }
.tde-role-option input { width:18px; height:18px; }
.tde-role-option span { display:flex; flex-direction:column; gap:.15rem; }
.tde-role-option small { color:#94a3b8; }

/* CR-0006.4 Demo-Verwaltung */
.tde-admin-action.demo { border-color:#9b6cff; color:#eadfff; }
.tde-demo-status {
    display:inline-flex;
    align-items:center;
    padding:3px 7px;
    border:1px solid rgba(148,163,184,.28);
    border-radius:4px;
    color:#cbd5e1;
    background:rgba(148,163,184,.09);
    font-size:9px;
    font-weight:850;
    letter-spacing:.35px;
}
.tde-demo-status.active {
    color:#ddffe8;
    border-color:rgba(48,209,88,.38);
    background:rgba(48,209,88,.12);
}
.tde-demo-status.expired {
    color:#fff0ce;
    border-color:rgba(255,159,10,.4);
    background:rgba(255,159,10,.13);
}
.tde-demo-status.revoked {
    color:#ffe4e6;
    border-color:rgba(255,69,58,.4);
    background:rgba(255,69,58,.13);
}
.tde-demo-remaining {
    display:block;
    margin-top:3px;
    color:#7f8a9d;
    font-size:9px;
    white-space:nowrap;
}
.tde-demo-form {
    display:grid;
    gap:1rem;
    padding:1.2rem;
}
.tde-demo-current-status {
    padding:.75rem .9rem;
    border:1px solid rgba(91,124,250,.28);
    border-radius:9px;
    color:#d9e4ff;
    background:rgba(91,124,250,.09);
    font-weight:700;
}
.tde-demo-toggle {
    display:flex;
    align-items:center;
    gap:.7rem;
    color:#f2f2f7;
    font-weight:750;
}
.tde-demo-toggle input { width:18px; height:18px; }
.tde-demo-date-grid {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:.8rem;
}
.tde-demo-date-grid label,
.tde-demo-note {
    display:grid;
    gap:.35rem;
    color:#aeb1b8;
    font-size:.82rem;
    font-weight:700;
}
.tde-demo-date-grid input,
.tde-demo-note textarea,
.tde-demo-extension input {
    box-sizing:border-box;
    width:100%;
    border:1px solid rgba(148,163,184,.3);
    border-radius:7px;
    color:#f2f2f7;
    background:#0b1220;
}
.tde-demo-date-grid input { min-height:38px; padding:.45rem .6rem; }
.tde-demo-note textarea { padding:.65rem; resize:vertical; }
.tde-demo-extension {
    display:grid;
    grid-template-columns:auto 90px auto 1fr;
    align-items:center;
    gap:.6rem;
    color:#aeb1b8;
}
.tde-demo-extension input { min-height:34px; padding:.35rem .5rem; }
.tde-demo-extension button { justify-self:end; }
@media(max-width:620px) {
    .tde-demo-date-grid { grid-template-columns:1fr; }
    .tde-demo-extension { grid-template-columns:1fr 1fr; }
    .tde-demo-extension button { justify-self:stretch; }
}

/* CR-0006.3 Rollenverwaltung */
.tde-admin-actions { display:flex; gap:.45rem; flex-wrap:wrap; }
.tde-admin-action.roles { border-color:#5b7cfa; }
.tde-role-dialog { position:fixed; inset:0; z-index:10000; display:none; align-items:center; justify-content:center; padding:1.25rem; background:rgba(3,8,20,.72); backdrop-filter:blur(4px); }
.tde-role-dialog.visible { display:flex; }
.tde-role-dialog-card { width:min(560px,100%); border:1px solid rgba(148,163,184,.28); border-radius:16px; background:#111827; box-shadow:0 24px 80px rgba(0,0,0,.45); overflow:hidden; }
.tde-role-dialog-card header,.tde-role-dialog-card footer { display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:1rem 1.2rem; }
.tde-role-dialog-card header { border-bottom:1px solid rgba(148,163,184,.18); }
.tde-role-dialog-card footer { border-top:1px solid rgba(148,163,184,.18); justify-content:flex-end; }
.tde-role-dialog-card h3 { margin:0 0 .2rem; }
.tde-role-dialog-card p { margin:0; color:#94a3b8; font-size:.88rem; }
.tde-role-dialog-close { border:0; background:transparent; color:#cbd5e1; font-size:1.8rem; cursor:pointer; }
.tde-role-options { display:grid; gap:.65rem; padding:1.2rem; max-height:55vh; overflow:auto; }
.tde-role-option { display:flex; align-items:center; gap:.8rem; padding:.85rem 1rem; border:1px solid rgba(148,163,184,.2); border-radius:12px; cursor:pointer; }
.tde-role-option:hover { border-color:rgba(91,124,250,.7); }
.tde-role-option input { width:18px; height:18px; }
.tde-role-option span { display:flex; flex-direction:column; gap:.15rem; }
.tde-role-option small { color:#94a3b8; }


/* HOTFIX-67 — sicherer JForex-System-Credential-Wechsel */
.tde-jforex-dialog .tde-role-dialog-card{width:min(620px,100%)}
.tde-jforex-dialog .tde-demo-note input{box-sizing:border-box;width:100%;min-height:38px;padding:.45rem .6rem;border:1px solid rgba(148,163,184,.3);border-radius:7px;color:#f2f2f7;background:#0b1220}
.tde-admin-secret-note{margin:0;padding:.75rem .9rem;border-left:3px solid #5b7cfa;background:rgba(91,124,250,.08);color:#aeb8c8!important;font-size:.78rem!important;line-height:1.45}
.tde-jforex-dialog .tde-admin-message{margin:0}
