/* ---------- Ambient brand background ---------- */
.ambient-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(40% 32% at 15% 18%, rgba(255, 210, 218, 0.85) 0%, rgba(255, 210, 218, 0.55) 35%, transparent 62%),
        radial-gradient(42% 34% at 85% 20%, rgba(203, 224, 255, 0.85) 0%, rgba(203, 224, 255, 0.55) 35%, transparent 62%),
        radial-gradient(45% 36% at 22% 82%, rgba(255, 228, 193, 0.85) 0%, rgba(255, 228, 193, 0.55) 35%, transparent 62%),
        radial-gradient(38% 34% at 80% 80%, rgba(231, 214, 255, 0.85) 0%, rgba(231, 214, 255, 0.55) 35%, transparent 62%),
        radial-gradient(30% 26% at 50% 50%, rgba(253, 226, 255, 0.55) 0%, transparent 60%);
    filter: blur(28px) saturate(115%);
    background-color: #f8f9fb;
}

/* ---------- Layout ---------- */
.nxg-admin .nxg-container {
    max-width: 1100px;
    margin: 24px auto 40px;
    padding: 0 20px;
}

.nxg-hero {
    margin: 12px 0 24px;
    padding: 28px 24px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(8px);
    box-shadow: 0 6px 24px rgba(20, 35, 90, 0.08);
}

.nxg-hero__eyebrow {
    font-size: 12px;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #6b7280;
    margin-bottom: 6px;
}

.nxg-hero__title {
    margin: 0;
    font-size: 28px;
    line-height: 1.25;
    color: #0c5074;
    font-weight: 800;
}

.nxg-hero__subtitle {
    margin: 8px 0 16px;
    color: #374151;
    font-size: 14px;
}

.nxg-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

/* Grid for cards */
.nxg-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 900px) {
    .nxg-grid {
        grid-template-columns: 1.2fr 1fr 1fr;
    }
}

/* ---------- Cards ---------- */
.nxg-card {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 6px 24px rgba(20, 35, 90, 0.08);
    padding: 18px 18px 14px;
    border: 1px solid rgba(12, 80, 116, 0.06);
}

.nxg-card__title {
    margin: 0 0 6px;
    font-size: 16px;
    color: #0c5074;
    font-weight: 700;
}

.nxg-card__desc {
    margin: 0 0 14px;
    color: #4b5563;
    font-size: 13px;
}

/* ---------- Buttons & Links ---------- */
.nxg-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border-radius: 10px;
    padding: 10px 14px;
    font-weight: 600;
    font-size: 13px;
    border: 1px solid rgba(12, 80, 116, 0.16);
    background: #fff;
    color: #0c5074;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(12, 80, 116, 0.08);
    transition: transform .04s ease, box-shadow .12s ease, background .12s ease, border-color .12s ease;
}

.nxg-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(12, 80, 116, 0.12);
}

/* unified brand style for ALL hero actions */
.nxg-btn--brand {
    background: rgba(52, 149, 209, 0.08);
    border-color: rgba(52, 149, 209, 0.22);
    color: #0c5074;
}

.nxg-btn--brand:hover {
    background: rgba(52, 149, 209, 0.14);
    border-color: rgba(52, 149, 209, 0.32);
}

/* Keep primary variant around if needed elsewhere */
.nxg-btn--primary {
    background: #3495d1;
    color: #fff;
    border-color: #3495d1;
}

.nxg-btn--primary:hover {
    background: #2f88c0;
    border-color: #2f88c0;
}

/* ---------- Lists / badges ---------- */
.nxg-list {
    list-style: none;
    margin: 0 0 10px;
    padding: 0;
}

.nxg-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px dashed rgba(12, 80, 116, 0.14);
    font-size: 13px;
}

.nxg-list li:last-child {
    border-bottom: 0;
}

.nxg-badge {
    display: inline-block;
    min-width: 48px;
    text-align: center;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    border: 1px solid transparent;
}

.nxg-badge.is-on {
    color: #065f46;
    background: #d1fae5;
    border-color: #a7f3d0;
}

.nxg-badge.is-off {
    color: #991b1b;
    background: #fee2e2;
    border-color: #fecaca;
}

.nxg-card__footer {
    margin-top: 8px;
}

.nxg-link {
    color: #0c5074;
    text-decoration: none;
    border-bottom: 1px dashed rgba(12, 80, 116, 0.35);
}

.nxg-link:hover {
    color: #3495d1;
    border-bottom-color: #3495d1;
}

/* Bulleted help list */
.nxg-bullets {
    margin: 8px 0 0;
    padding-left: 18px;
    color: #4b5563;
    font-size: 13px;
}

.nxg-bullets li {
    margin: 6px 0;
}

/* ---------- Setup form beautification ---------- */

/* Use full width, remove table feel */
.nxg-form .form-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 10px;
    /* vertical gaps between rows */
}

/* Each row becomes a soft card row using grid */
.nxg-form .form-table tr {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(12, 80, 116, 0.08);
    border-radius: 12px;
    padding: 12px 14px;
}

/* Labels on the left, nice color/weight */
.nxg-form .form-table th {
    display: block;
    margin: 0;
    padding: 0;
    font-size: 14px;
    color: #0c5074;
    font-weight: 700;
}

/* Controls on the right */
.nxg-form .form-table td {
    display: block;
    margin: 0;
    padding: 0;
    text-align: right;
}

/* App ID input stretches nicely */
.nxg-form .regular-text {
    width: 100%;
    max-width: none;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid rgba(12, 80, 116, 0.18);
    box-shadow: 0 1px 3px rgba(12, 80, 116, 0.06) inset;
}

/* Convert the plain checkbox + "Enable" text into a clean switch */
.nxg-form .form-table td label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0;
    /* hide the literal "Enable" text */
    margin: 0;
}

/* Switch base */
.nxg-form .form-table input[type="checkbox"] {
    -webkit-appearance: none;
    appearance: none;
    width: 44px;
    height: 24px;
    background: #e5e7eb;
    border: 1px solid rgba(12, 80, 116, 0.22);
    border-radius: 999px;
    position: relative;
    cursor: pointer;
    outline: none;
    transition: background .15s ease, border-color .15s ease;
}

/* Switch thumb */
.nxg-form .form-table input[type="checkbox"]::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
    transition: transform .15s ease;
}

/* Remove WP admin's dashicon ✔ overlay inside checked checkboxes */
.nxg-form .form-table input[type="checkbox"]::before,
.nxg-form .form-table input[type="checkbox"]:checked::before {
    content: none !important;
    display: none !important;
}

/* Center the thumb at the right edge when ON (44px track, 18px thumb, 2px gutters) */
.nxg-form .form-table input[type="checkbox"]:checked::after {
    transform: translateX(22px);
    /* was 20px */
}


/* Checked state */
.nxg-form .form-table input[type="checkbox"]:checked {
    background: #3495d1;
    border-color: #3495d1;
}

.nxg-form .form-table input[type="checkbox"]:checked::after {
    transform: translateX(20px);
}

/* Submit button polish */
.nxg-form .submit .button-primary {
    background: #3495d1;
    border-color: #3495d1;
    box-shadow: 0 2px 8px rgba(12, 80, 116, 0.08);
    border-radius: 10px;
    padding: 8px 14px;
    font-weight: 700;
}

.nxg-form .submit .button-primary:hover {
    background: #2f88c0;
    border-color: #2f88c0;
    transform: translateY(-1px);
}

/* App ID input – tiny tweak only (≈2px wider feel, ~2px shorter) */
.nxg-form input[name="cybexo_cmp_options[settings_id]"].regular-text,
.nxg-form input[name="nexaguard_cmp_options[settings_id]"].regular-text {
    width: 100%;
    box-sizing: border-box;
    padding: 7px 11px;
    height: auto;
    font-size: 13px;
    line-height: 1.2;
    border-radius: 1px;
}


/* On narrow admin screens, let it span full width */
@media (max-width: 900px) {
    .nxg-form input[name="cybexo_cmp_options[settings_id]"].regular-text,
    .nxg-form input[name="nexaguard_cmp_options[settings_id]"].regular-text {
        width: 100%;
    }
}
