:root {
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: #f5f5f5;
    background: #080808;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% 0%, #1a0b0b 0, transparent 35%),
        radial-gradient(circle at 90% 20%, #130808 0, transparent 30%),
        #080808;
}

button, input { font: inherit; }

.app {
    width: min(1400px, calc(100% - 40px));
    margin: auto;
    padding: 42px 0 60px;
}

header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.eyebrow {
    color: #ff3b3b;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .22em;
}

h1 {
    margin: 5px 0;
    font-size: 34px;
}

header p {
    margin: 0;
    color: #777;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(390px, 1fr));
    gap: 18px;
}

.card {
    border: 1px solid #222;
    border-radius: 14px;
    background: #0d0d0d;
    padding: 18px;
    box-shadow: 0 15px 50px rgba(0,0,0,.25);
}

.card-top {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    align-items: flex-start;
}

.account-name {
    font-size: 20px;
    font-weight: 750;
}

.account-id {
    margin-top: 4px;
    color: #555;
    font-size: 10px;
    font-family: monospace;
}

.status {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .08em;
}

.status i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #555;
}

.status.online i { background: #49e28b; box-shadow: 0 0 10px #49e28b; }
.status.connecting i { background: #e2b649; }
.status.error i { background: #e24949; }
.status.offline i { background: #555; }

.info {
    display: grid;
    gap: 10px;
    margin: 20px 0;
}

.info div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.info span {
    color: #555;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.info b {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #ccc;
    font-size: 12px;
    font-family: monospace;
}

.toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

button {
    border: 1px solid #282828;
    border-radius: 8px;
    padding: 9px 12px;
    color: #ddd;
    background: #141414;
    cursor: pointer;
}

button:hover { border-color: #444; }
button.primary { background: #d92323; border-color: #e22c2c; color: white; }
button.primary:hover { background: #ef3030; }
button.danger { background: #351313; border-color: #5a2020; color: #ff8888; }
button.ghost { background: transparent; }

.logs {
    margin-top: 14px;
    height: 130px;
    overflow: auto;
    padding: 10px;
    border-radius: 8px;
    background: #070707;
    border: 1px solid #171717;
    color: #777;
    font: 10px/1.6 monospace;
    white-space: pre-wrap;
}

.empty {
    padding: 70px 20px;
    text-align: center;
    color: #555;
    border: 1px dashed #222;
    border-radius: 14px;
}

.modal {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(0,0,0,.78);
    z-index: 10;
}

.hidden { display: none; }

.modal-card {
    width: min(650px, 100%);
    max-height: 90vh;
    overflow: auto;
    padding: 22px;
    border: 1px solid #282828;
    border-radius: 14px;
    background: #0d0d0d;
}

.modal-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-head h2 { margin: 0; }

.icon {
    border: 0;
    background: transparent;
    font-size: 25px;
    color: #777;
}

form {
    display: grid;
    gap: 14px;
}

label {
    display: grid;
    gap: 7px;
    color: #888;
    font-size: 12px;
}

input {
    width: 100%;
    border: 1px solid #282828;
    border-radius: 8px;
    padding: 11px 12px;
    outline: none;
    color: #eee;
    background: #080808;
}

input:focus { border-color: #8b2828; }

.two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.checks {
    display: flex;
    gap: 20px;
}

.checks label {
    display: flex;
    align-items: center;
    gap: 7px;
}

.checks input {
    width: auto;
}

.hint {
    margin: 0;
    color: #555;
    font-size: 11px;
}

.actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 8px;
}

@media (max-width: 600px) {
    .app { width: min(100% - 20px, 1400px); }
    header { align-items: flex-start; flex-direction: column; }
    .grid { grid-template-columns: 1fr; }
    .two { grid-template-columns: 1fr; }
}