.status-online {
    background: #dcfae6;
    color: #067647;
}

.status-offline,
.status-pending {
    background: #fff1c2;
    color: #7a2e0e;
}

.status-disabled {
    background: #eef2f4;
    color: #52636e;
}

.gateway-title {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.gateway-main {
    display: grid;
    gap: 3px;
}

.gateway-main small {
    display: block;
    color: var(--muted);
}

.gateway-actions {
    align-items: center;
    flex-wrap: wrap;
}

.gateway-test-result {
    width: 100%;
    margin-top: 12px;
    padding: 14px;
    border: 1px solid var(--line);
    border-left-width: 4px;
    border-radius: 10px;
    background: #f8fafb;
}

.gateway-test-result-success {
    border-left-color: #067647;
    background: #f0fdf4;
}

.gateway-test-result-error {
    border-left-color: #b42318;
    background: #fff7f6;
}

.gateway-test-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.gateway-test-result p {
    margin: 8px 0 12px;
}

.gateway-test-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
    gap: 10px;
    margin: 0;
}

.gateway-test-details div {
    min-width: 0;
}

.gateway-test-details dt {
    color: var(--muted);
    font-size: 12px;
}

.gateway-test-details dd {
    margin: 3px 0 0;
    overflow-wrap: anywhere;
    font-weight: 600;
}

.gateway-help {
    margin-top: 20px;
}

.gateway-help ol {
    line-height: 1.7;
}

.gateway-registration-layout {
    display: grid;
    grid-template-columns: minmax(280px, 360px) 1fr;
    gap: 28px;
    align-items: center;
}

.qr-frame {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 10px;
}

.qr-frame img {
    display: block;
    width: 100%;
    height: auto;
}

.gateway-registration textarea {
    font-size: 11px;
    word-break: break-all;
}

.gateway-private-note {
    padding: 13px 15px;
    border: 1px solid #9bd8d1;
    border-radius: 10px;
    background: #f0fdfb;
    color: var(--brand);
    font-weight: 700;
}

.gateway-access-options {
    display: grid;
    gap: 8px;
}

.gateway-access-options legend {
    padding: 0 6px;
    font-weight: 800;
}

.gateway-user-board {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.gateway-user-column {
    min-width: 0;
    padding: 15px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #f8fafb;
}

.gateway-user-column-assigned {
    border-color: #9bd8d1;
    background: #f7fcfb;
}

.gateway-user-heading {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.gateway-user-heading h3,
.gateway-user-heading p {
    margin: 0;
}

.gateway-user-heading p {
    color: var(--muted);
    font-size: 12px;
}

.gateway-user-list {
    display: flex;
    min-height: 210px;
    max-height: 330px;
    overflow-y: auto;
    flex-direction: column;
    gap: 8px;
    padding: 8px;
    border: 2px dashed #cfdae0;
    border-radius: 10px;
}

.gateway-user-list.is-drag-over {
    border-color: var(--brand2);
    background: #eaf8f6;
}

.gateway-user-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    cursor: grab;
}

.gateway-user-item.is-dragging {
    opacity: .45;
}

.gateway-user-data {
    min-width: 0;
    flex: 1;
}

.gateway-user-data strong,
.gateway-user-data small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.gateway-user-data small {
    color: var(--muted);
}

.gateway-user-empty {
    margin: auto;
    padding: 20px;
    color: var(--muted);
    text-align: center;
}

@media (max-width: 760px) {
    .gateway-registration-layout {
        grid-template-columns: 1fr;
    }

    .gateway-user-board {
        grid-template-columns: 1fr;
    }
}
