:root {
    --account-primary: #2563eb;
    --account-primary-soft: #eff6ff;
    --account-text: #172033;
    --account-muted: #64748b;
    --account-border: #e2e8f0;
    --account-background: #f7f9fc;
    --account-card: #ffffff;
    --account-danger: #dc2626;
    --account-danger-soft: #fef2f2;
    --account-shadow: 0 10px 35px rgba(15, 23, 42, 0.07);
}

* {
    box-sizing: border-box;
}

.account-page {
    min-height: 100vh;
    background:
        radial-gradient(circle at top right, rgba(37, 99, 235, 0.08), transparent 30%),
        var(--account-background);
    color: var(--account-text);
}

.account-layout {
    display: flex;
    min-height: 100vh;
}

.account-main {
    flex: 1;
    min-width: 0;
    padding: 40px;
}

.account-container {
    width: min(1240px, 100%);
    margin: 0 auto;
}

.account-hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 28px;
    padding: 34px;
    border: 1px solid rgba(37, 99, 235, 0.13);
    border-radius: 26px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(239, 246, 255, 0.95));
    box-shadow: var(--account-shadow);
}

.account-hero::after {
    position: absolute;
    top: -90px;
    right: -80px;
    width: 240px;
    height: 240px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.08);
    content: "";
}

.account-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 13px;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--account-primary-soft);
    color: var(--account-primary);
    font-size: 0.82rem;
    font-weight: 700;
}

.account-title {
    position: relative;
    z-index: 1;
    margin: 0;
    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: 1.08;
    letter-spacing: -0.045em;
}

.account-description {
    position: relative;
    z-index: 1;
    max-width: 720px;
    margin: 15px 0 0;
    color: var(--account-muted);
    font-size: 1.03rem;
    line-height: 1.7;
}

.account-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.account-summary-item {
    padding: 9px 13px;
    border: 1px solid var(--account-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.82);
    color: #475569;
    font-size: 0.9rem;
    font-weight: 650;
}

.account-section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin: 0 2px 18px;
}

.account-section-heading h2 {
    margin: 0;
    font-size: 1.35rem;
}

.account-section-heading p {
    margin: 0;
    color: var(--account-muted);
    font-size: 0.92rem;
}

.account-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.account-card {
    position: relative;
    display: flex;
    min-height: 205px;
    flex-direction: column;
    padding: 23px;
    overflow: hidden;
    border: 1px solid var(--account-border);
    border-radius: 21px;
    background: var(--account-card);
    box-shadow: 0 5px 20px rgba(15, 23, 42, 0.045);
    color: inherit;
    text-decoration: none;
    transition:
        transform 180ms ease,
        box-shadow 180ms ease,
        border-color 180ms ease;
}

.account-card:hover {
    transform: translateY(-5px);
    border-color: rgba(37, 99, 235, 0.35);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.11);
}

.account-card:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.27);
    outline-offset: 3px;
}

.account-card-icon {
    display: grid;
    width: 49px;
    height: 49px;
    place-items: center;
    margin-bottom: 19px;
    border-radius: 15px;
    background: var(--account-primary-soft);
    font-size: 1.4rem;
}

.account-card h3 {
    margin: 0;
    font-size: 1.08rem;
}

.account-card p {
    margin: 9px 0 22px;
    color: var(--account-muted);
    font-size: 0.92rem;
    line-height: 1.55;
}

.account-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    color: var(--account-primary);
    font-size: 0.86rem;
    font-weight: 750;
}

.account-card-arrow {
    display: grid;
    width: 31px;
    height: 31px;
    place-items: center;
    border-radius: 50%;
    background: var(--account-primary-soft);
    transition: transform 180ms ease;
}

.account-card:hover .account-card-arrow {
    transform: translateX(3px);
}

.account-card-danger {
    border-color: #fecaca;
}

.account-card-danger .account-card-icon,
.account-card-danger .account-card-arrow {
    background: var(--account-danger-soft);
}

.account-card-danger .account-card-footer {
    color: var(--account-danger);
}

.account-detail-header {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 25px;
}

.account-back {
    display: grid;
    width: 44px;
    height: 44px;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid var(--account-border);
    border-radius: 14px;
    background: #fff;
    color: var(--account-text);
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
}

.account-detail-header h1 {
    margin: 0;
    font-size: clamp(1.75rem, 3vw, 2.4rem);
    letter-spacing: -0.035em;
}

.account-detail-header p {
    margin: 5px 0 0;
    color: var(--account-muted);
}

.account-panel {
    padding: 27px;
    border: 1px solid var(--account-border);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--account-shadow);
}

.account-panel h2 {
    margin: 0 0 9px;
}

.account-panel p {
    color: var(--account-muted);
    line-height: 1.65;
}

.account-action-list {
    display: grid;
    gap: 13px;
    margin-top: 22px;
}

.account-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 17px;
    border: 1px solid var(--account-border);
    border-radius: 16px;
    color: inherit;
    text-decoration: none;
}

.account-action:hover {
    border-color: rgba(37, 99, 235, 0.35);
    background: #f8fbff;
}

.account-action strong {
    display: block;
    margin-bottom: 4px;
}

.account-action span {
    color: var(--account-muted);
    font-size: 0.88rem;
}

.account-badge {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 999px;
    background: #ecfdf5;
    color: #047857;
    font-size: 0.78rem;
    font-weight: 750;
}

@media (max-width: 1100px) {
    .account-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .account-layout {
        display: block;
    }

    .account-main {
        padding: 20px 15px 32px;
    }

    .account-hero {
        padding: 25px 21px;
        border-radius: 20px;
    }

    .account-grid {
        grid-template-columns: 1fr;
    }

    .account-card {
        min-height: 180px;
    }

    .account-section-heading {
        align-items: start;
        flex-direction: column;
        gap: 5px;
    }
}
/* ===== Recovery Codes ===== */

#generate-form .form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 18px;
}

#generate-form label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #1f2937;
}

#generate-form input {
    width: 100%;
    max-width: 340px;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #d7e2f0;
    border-radius: 10px;
    background: #fff;
    font-size: 15px;
    transition: .2s;
    box-sizing: border-box;
}

#generate-form input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}

#generate-form button,
#copy-button,
#download-button {
    min-width: 170px;
    height: 44px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: .2s;
}

#generate-form button[type="submit"],
#copy-button {
    background: #2563eb;
    color: #fff;
}

#generate-form button[type="submit"]:hover,
#copy-button:hover {
    background: #1d4ed8;
}

#regenerate-button,
#download-button {
    background: #f3f6fb;
    color: #1f2937;
    border: 1px solid #d7e2f0;
}

#regenerate-button:hover,
#download-button:hover {
    background: #e8eef8;
}

#codes-output {
    width: 100%;
    min-height: 240px;
    padding: 16px;
    border: 1px solid #d7e2f0;
    border-radius: 12px;
    background: #f8fafc;
    font-family: "Courier New", monospace;
    font-size: 15px;
    line-height: 1.7;
    box-sizing: border-box;
}

/* =========================
   Sessions
========================= */

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

.sessions-summary{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
    gap:20px;
    margin-bottom:30px;
}

.summary-card{
    background:#fff;
    border:1px solid #e5e7eb;
    border-radius:14px;
    padding:20px;
    text-align:center;
}

.summary-card span{
    display:block;
    color:#6b7280;
    margin-bottom:8px;
}

.summary-card strong{
    font-size:2rem;
    color:#2563eb;
}

.sessions-list{
    display:flex;
    flex-direction:column;
    gap:20px;
}

.session-card{
    background:#fff;
    border:1px solid #e5e7eb;
    border-radius:16px;
    padding:24px;
    box-shadow:0 8px 20px rgba(0,0,0,.05);
}

.session-header{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
    gap:20px;
    margin-bottom:20px;
    flex-wrap:wrap;
}

.session-header h3{
    margin:0 0 10px;
}

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

.session-grid strong{
    color:#374151;
}

.session-badge{
    display:inline-block;
    padding:5px 10px;
    border-radius:999px;
    font-size:.8rem;
    font-weight:600;
    margin-right:8px;
}

.session-badge.current{
    background:#dcfce7;
    color:#166534;
}

.session-badge.revoked{
    background:#fee2e2;
    color:#991b1b;
}

.loading,
.account-empty{
    text-align:center;
    padding:40px;
    color:#6b7280;
}

@media (max-width:768px){

    .session-header{
        flex-direction:column;
    }

    .sessions-header{
        flex-direction:column;
        align-items:stretch;
    }

    .sessions-header button{
        width:100%;
    }

}

/* Ouverture des cartes de sessions */

.session-card {
    cursor: pointer;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.session-card:hover {
    transform: translateY(-2px);
    border-color: #93c5fd;
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.10);
}

.session-card:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.25);
    outline-offset: 3px;
}

.session-card.is-open {
    border-color: #60a5fa;
}

.session-card-current {
    border-left: 4px solid #22c55e;
}

.session-card-revoked {
    opacity: 0.72;
}

.session-card-summary {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
}

.session-device {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    min-width: 0;
}

.session-device-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    border-radius: 15px;
    background: #eff6ff;
    font-size: 26px;
}

.session-device-main {
    min-width: 0;
}

.session-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.session-title-row h3 {
    margin: 0;
}

.session-chevron {
    color: #64748b;
    font-size: 12px;
}

.session-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 9px;
}

.session-badge.active {
    background: #dbeafe;
    color: #1d4ed8;
}

.session-description,
.session-last-seen {
    margin: 10px 0 0;
    color: #64748b;
}

.session-last-seen {
    font-size: 0.88rem;
}

.session-details {
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid #e5e7eb;
}

.session-information {
    padding: 14px;
    border-radius: 12px;
    background: #f8fafc;
}

.session-information span {
    display: block;
    margin-bottom: 6px;
    color: #64748b;
    font-size: 0.83rem;
}

.session-information strong {
    color: #1e293b;
    overflow-wrap: anywhere;
}

.session-primary-action {
    flex: 0 0 auto;
}

@media (max-width: 700px) {
    .session-card-summary {
        flex-direction: column;
    }

    .session-primary-action,
    .session-primary-action .btn {
        width: 100%;
    }
}

/* MARCUS SUBSCRIPTION START */

.subscription-container {
    padding-bottom: 56px;
}

.subscription-current-card {
    position: relative;
    overflow: hidden;
    margin-bottom: 24px;
    padding: 30px;
    color: #ffffff;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 34%),
        linear-gradient(135deg, #075ee8 0%, #0b76f0 55%, #2e95ff 100%);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 22px;
    box-shadow: 0 18px 45px rgba(12, 97, 220, 0.22);
}

.subscription-current-card::after {
    content: "";
    position: absolute;
    width: 220px;
    height: 220px;
    right: -90px;
    bottom: -130px;
    border: 35px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.subscription-current-top {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}

.subscription-current-card h2 {
    margin: 6px 0 8px;
    color: #ffffff;
    font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.subscription-current-card p {
    max-width: 620px;
    margin: 0;
    color: rgba(255, 255, 255, 0.84);
}

.subscription-section-label {
    display: inline-block;
    color: #1474e8;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.subscription-current-card .subscription-section-label {
    color: rgba(255, 255, 255, 0.72);
}

.subscription-status {
    flex: 0 0 auto;
    padding: 8px 13px;
    font-size: 0.82rem;
    font-weight: 800;
    border-radius: 999px;
}

.subscription-status-active {
    color: #075629;
    background: #d9fbe8;
}

.subscription-current-details {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 28px;
}

.subscription-detail {
    padding: 17px;
    background: rgba(255, 255, 255, 0.11);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 15px;
    backdrop-filter: blur(8px);
}

.subscription-detail span,
.subscription-detail strong {
    display: block;
}

.subscription-detail span {
    margin-bottom: 7px;
    color: rgba(255, 255, 255, 0.68);
    font-size: 0.78rem;
}

.subscription-detail strong {
    color: #ffffff;
    font-size: 0.96rem;
}

.subscription-selected-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    padding: 18px 20px;
    color: #15365d;
    background: #eef7ff;
    border: 1px solid #b9dcff;
    border-radius: 16px;
}

.subscription-selected-banner[hidden] {
    display: none;
}

.subscription-selected-banner strong,
.subscription-selected-banner span {
    display: block;
}

.subscription-selected-banner strong {
    margin-bottom: 4px;
}

.subscription-selected-banner span {
    color: #55708e;
    font-size: 0.9rem;
}

.subscription-section {
    margin-bottom: 24px;
}

.subscription-section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
}

.subscription-section-heading h2 {
    margin: 5px 0 7px;
}

.subscription-section-heading p {
    margin: 0;
    color: #697b90;
}

.subscription-usage-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.subscription-usage-card {
    padding: 19px;
    background: #f8fbff;
    border: 1px solid #e3ebf5;
    border-radius: 15px;
}

.subscription-usage-heading {
    display: flex;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 13px;
}

.subscription-usage-heading span {
    color: #31465e;
    font-weight: 700;
}

.subscription-usage-heading strong {
    color: #0d68d8;
    font-size: 0.88rem;
}

.subscription-progress {
    height: 9px;
    overflow: hidden;
    margin-bottom: 10px;
    background: #dfe8f2;
    border-radius: 999px;
}

.subscription-progress span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #0d67de, #42a2ff);
    border-radius: inherit;
}

.subscription-usage-card small {
    color: #708196;
}

.subscription-plans-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.subscription-plan-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 25px;
    background: #ffffff;
    border: 1px solid #dde6f0;
    border-radius: 18px;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.subscription-plan-card:hover {
    transform: translateY(-4px);
    border-color: #a9cff8;
    box-shadow: 0 16px 32px rgba(31, 87, 148, 0.11);
}

.subscription-plan-card.is-current {
    border: 2px solid #1a76e8;
    background: #f7fbff;
}

.subscription-plan-card.is-selected {
    border: 2px solid #22a26a;
    box-shadow: 0 15px 34px rgba(34, 162, 106, 0.13);
}

.subscription-plan-featured {
    border-color: #78b7fb;
    box-shadow: 0 14px 32px rgba(19, 105, 214, 0.12);
}

.subscription-plan-enterprise {
    grid-column: 1 / -1;
}

.subscription-plan-badge {
    position: absolute;
    top: 17px;
    right: 17px;
    padding: 6px 10px;
    color: #ffffff;
    background: #126ee0;
    font-size: 0.72rem;
    font-weight: 800;
    border-radius: 999px;
}

.subscription-plan-icon {
    display: inline-grid;
    width: 45px;
    height: 45px;
    place-items: center;
    margin-bottom: 15px;
    background: #edf6ff;
    border-radius: 13px;
    font-size: 1.35rem;
}

.subscription-plan-header h3 {
    margin: 0 0 7px;
    color: #18344f;
    font-size: 1.28rem;
}

.subscription-plan-header p {
    min-height: 44px;
    margin: 0;
    color: #718197;
}

.subscription-plan-price {
    margin: 22px 0;
}

.subscription-plan-price strong,
.subscription-plan-price span {
    display: block;
}

.subscription-plan-price strong {
    color: #0b62ce;
    font-size: 1.75rem;
}

.subscription-plan-price span {
    margin-top: 4px;
    color: #7a899b;
    font-size: 0.82rem;
}

.subscription-plan-card ul {
    flex: 1;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
}

.subscription-plan-card li {
    position: relative;
    margin: 10px 0;
    padding-left: 23px;
    color: #4f6074;
    font-size: 0.91rem;
}

.subscription-plan-card li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #15815a;
    font-weight: 900;
}

.subscription-plan-button,
.subscription-primary-button,
.subscription-secondary-button,
.subscription-danger-button {
    display: inline-flex;
    min-height: 43px;
    align-items: center;
    justify-content: center;
    padding: 10px 17px;
    font: inherit;
    font-size: 0.9rem;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
    border-radius: 11px;
    cursor: pointer;
    transition:
        transform 0.18s ease,
        opacity 0.18s ease,
        background 0.18s ease;
}

.subscription-plan-button,
.subscription-primary-button {
    color: #ffffff;
    background: #126fe1;
    border: 1px solid #126fe1;
}

.subscription-plan-button:hover,
.subscription-primary-button:hover {
    transform: translateY(-1px);
    background: #075fca;
}

.subscription-plan-button:disabled {
    color: #2d6a4f;
    background: #e2f7ec;
    border-color: #bee9d2;
    cursor: default;
}

.subscription-secondary-button {
    color: #255b91;
    background: #edf6ff;
    border: 1px solid #c9e1f9;
}

.subscription-danger-button {
    color: #b23838;
    background: #fff1f1;
    border: 1px solid #f3cccc;
}

.subscription-secondary-button:disabled,
.subscription-danger-button:disabled {
    opacity: 0.58;
    cursor: not-allowed;
}

.subscription-management-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
}

.subscription-management-card {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 18px;
    color: inherit;
    text-decoration: none;
    background: #f8fbff;
    border: 1px solid #e0eaf4;
    border-radius: 15px;
    transition:
        transform 0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}

.subscription-management-card:hover {
    transform: translateY(-2px);
    border-color: #b4d5f6;
    box-shadow: 0 10px 23px rgba(29, 80, 138, 0.09);
}

.subscription-management-icon {
    display: grid;
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    place-items: center;
    background: #e9f4ff;
    border-radius: 12px;
}

.subscription-management-card div {
    min-width: 0;
    flex: 1;
}

.subscription-management-card strong,
.subscription-management-card span {
    display: block;
}

.subscription-management-card strong {
    margin-bottom: 4px;
    color: #273f58;
}

.subscription-management-card span {
    color: #708095;
    font-size: 0.83rem;
    line-height: 1.4;
}

.subscription-management-card b {
    color: #1774df;
}

.subscription-settings-list {
    overflow: hidden;
    border: 1px solid #e0e8f1;
    border-radius: 15px;
}

.subscription-setting-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 19px;
}

.subscription-setting-row + .subscription-setting-row {
    border-top: 1px solid #e7edf4;
}

.subscription-setting-row strong,
.subscription-setting-row span {
    display: block;
}

.subscription-setting-row strong {
    margin-bottom: 5px;
    color: #2c4158;
}

.subscription-setting-row span {
    color: #738397;
    font-size: 0.87rem;
}

.subscription-toast {
    position: fixed;
    z-index: 9999;
    right: 22px;
    bottom: 22px;
    max-width: min(420px, calc(100vw - 44px));
    padding: 14px 18px;
    color: #ffffff;
    background: #173a60;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(16, 42, 72, 0.25);
    opacity: 0;
    transform: translateY(15px);
    pointer-events: none;
    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.subscription-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1100px) {
    .subscription-current-details {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .subscription-management-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .subscription-current-card {
        padding: 22px;
        border-radius: 18px;
    }

    .subscription-current-top,
    .subscription-selected-banner,
    .subscription-setting-row {
        align-items: stretch;
        flex-direction: column;
    }

    .subscription-current-details,
    .subscription-usage-grid,
    .subscription-plans-grid {
        grid-template-columns: 1fr;
    }

    .subscription-plan-enterprise {
        grid-column: auto;
    }

    .subscription-section-heading {
        flex-direction: column;
    }

    .subscription-status {
        align-self: flex-start;
    }

    .subscription-selected-banner button,
    .subscription-setting-row button {
        width: 100%;
    }
}

/* MARCUS SUBSCRIPTION END */

/* MARCUS BILLING START */

.billing-container {
    padding-bottom: 56px;
}

.billing-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.billing-summary-card {
    padding: 22px;
    background: #ffffff;
    border: 1px solid #e1e9f2;
    border-radius: 17px;
    box-shadow: 0 10px 26px rgba(31, 75, 121, 0.07);
}

.billing-summary-card span,
.billing-summary-card strong,
.billing-summary-card small {
    display: block;
}

.billing-summary-card span {
    margin-bottom: 10px;
    color: #65768a;
    font-size: 0.83rem;
    font-weight: 700;
}

.billing-summary-card strong {
    margin-bottom: 7px;
    color: #126bd8;
    font-size: 1.65rem;
}

.billing-summary-card small {
    color: #8391a2;
}

.billing-section {
    margin-bottom: 24px;
}

.billing-section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 23px;
}

.billing-section-heading h2 {
    margin: 5px 0 7px;
}

.billing-section-heading p {
    margin: 0;
    color: #6f8093;
}

.billing-section-label {
    display: inline-block;
    color: #1474e8;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.billing-export-actions {
    display: flex;
    gap: 10px;
}

.billing-primary-button,
.billing-secondary-button,
.billing-download-button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    font: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    text-decoration: none;
    border-radius: 11px;
    cursor: pointer;
}

.billing-primary-button {
    color: #ffffff;
    background: #116fe0;
    border: 1px solid #116fe0;
}

.billing-secondary-button {
    color: #245f9a;
    background: #edf6ff;
    border: 1px solid #c8e0f8;
}

.billing-download-button {
    min-height: 34px;
    padding: 6px 12px;
    color: #1769cc;
    background: #eef6ff;
    border: 1px solid #c7def7;
}

.billing-filters {
    display: grid;
    grid-template-columns: repeat(3, minmax(145px, 1fr)) minmax(220px, 1.4fr);
    gap: 14px;
    margin-bottom: 20px;
}

.billing-filter-group {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.billing-filter-group label {
    color: #42566e;
    font-size: 0.82rem;
    font-weight: 800;
}

.billing-filter-group select,
.billing-filter-group input {
    min-height: 43px;
    width: 100%;
    padding: 9px 12px;
    color: #31465d;
    background: #ffffff;
    border: 1px solid #d8e2ed;
    border-radius: 11px;
    outline: none;
}

.billing-filter-group select:focus,
.billing-filter-group input:focus {
    border-color: #5ba2ee;
    box-shadow: 0 0 0 3px rgba(36, 128, 225, 0.12);
}

.billing-table-wrapper {
    overflow-x: auto;
    border: 1px solid #e1e8f0;
    border-radius: 15px;
}

.billing-table {
    width: 100%;
    min-width: 920px;
    border-collapse: collapse;
}

.billing-table th,
.billing-table td {
    padding: 15px 14px;
    text-align: left;
    border-bottom: 1px solid #e9eef4;
}

.billing-table th {
    color: #576b80;
    background: #f7faff;
    font-size: 0.77rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.billing-table td {
    color: #425469;
    font-size: 0.88rem;
}

.billing-table tbody tr:last-child td {
    border-bottom: 0;
}

.billing-table tbody tr:hover {
    background: #fbfdff;
}

.billing-status-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    font-size: 0.76rem;
    font-weight: 800;
    border-radius: 999px;
}

.billing-status-paid {
    color: #137148;
    background: #e3f8ed;
}

.billing-status-pending {
    color: #956500;
    background: #fff4d5;
}

.billing-status-refunded {
    color: #265f98;
    background: #e8f3ff;
}

.billing-status-cancelled {
    color: #a33b3b;
    background: #ffebeb;
}

.billing-status-neutral {
    color: #68798a;
    background: #edf1f5;
}

.billing-empty-state {
    margin-top: 18px;
    padding: 30px;
    text-align: center;
    background: #f8fbff;
    border: 1px dashed #cbd9e8;
    border-radius: 15px;
}

.billing-empty-state strong,
.billing-empty-state span {
    display: block;
}

.billing-empty-state strong {
    margin-bottom: 6px;
    color: #334b64;
}

.billing-empty-state span {
    color: #778799;
}

.billing-credit-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.billing-credit-card,
.billing-company-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 19px;
    background: #f8fbff;
    border: 1px solid #e1e9f2;
    border-radius: 15px;
}

.billing-credit-card strong,
.billing-credit-card span,
.billing-company-card strong,
.billing-company-card span {
    display: block;
}

.billing-credit-card strong,
.billing-company-card strong {
    margin-bottom: 5px;
    color: #32485f;
}

.billing-credit-card div > span,
.billing-company-card div > span {
    color: #718297;
    font-size: 0.86rem;
}

.billing-toast {
    position: fixed;
    z-index: 9999;
    right: 22px;
    bottom: 22px;
    max-width: min(420px, calc(100vw - 44px));
    padding: 14px 18px;
    color: #ffffff;
    background: #193d63;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(17, 43, 72, 0.25);
    opacity: 0;
    transform: translateY(14px);
    pointer-events: none;
    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.billing-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1100px) {
    .billing-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .billing-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .billing-summary-grid,
    .billing-filters,
    .billing-credit-list {
        grid-template-columns: 1fr;
    }

    .billing-section-heading,
    .billing-company-card {
        align-items: stretch;
        flex-direction: column;
    }

    .billing-export-actions {
        flex-direction: column;
    }

    .billing-export-actions button,
    .billing-company-card a {
        width: 100%;
    }
}

/* MARCUS BILLING END */

/* MARCUS LANGUAGES START */

.locale-container {
    padding-bottom: 120px;
}

.locale-section {
    margin-bottom: 24px;
}

.locale-section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
}

.locale-section-heading h2 {
    margin: 5px 0 7px;
}

.locale-section-heading p {
    margin: 0;
    color: #6f8093;
    line-height: 1.6;
}

.locale-section-label {
    display: inline-block;
    color: #1474e8;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.locale-status {
    display: inline-flex;
    align-items: center;
    padding: 7px 11px;
    color: #5d6d7e;
    background: #edf1f5;
    border-radius: 999px;
    font-size: 0.76rem;
    font-weight: 800;
    white-space: nowrap;
}

.locale-status.is-automatic {
    color: #176744;
    background: #e2f7eb;
}

.locale-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.locale-form-grid-three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.locale-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.locale-field label {
    color: #354b63;
    font-size: 0.87rem;
    font-weight: 800;
}

.locale-field select {
    width: 100%;
    min-height: 47px;
    padding: 10px 13px;
    color: #334960;
    background: #ffffff;
    border: 1px solid #d5e0eb;
    border-radius: 12px;
    outline: none;
}

.locale-field select:focus {
    border-color: #5b9ee8;
    box-shadow: 0 0 0 3px rgba(32, 126, 224, 0.12);
}

.locale-field select:disabled {
    color: #75869a;
    background: #f0f4f8;
    cursor: not-allowed;
}

.locale-field small {
    color: #7b8999;
    line-height: 1.5;
}

.locale-timezone-field {
    margin-top: 18px;
}

.locale-switch-list {
    display: grid;
    gap: 12px;
    margin-top: 22px;
}

.locale-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 17px 18px;
    background: #f8fbff;
    border: 1px solid #e0e9f2;
    border-radius: 14px;
    cursor: pointer;
}

.locale-switch-row > span:first-child {
    flex: 1;
}

.locale-switch-row strong,
.locale-switch-row small {
    display: block;
}

.locale-switch-row strong {
    margin-bottom: 5px;
    color: #344b62;
}

.locale-switch-row small {
    color: #718196;
    line-height: 1.5;
}

.locale-switch-row input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.locale-switch {
    position: relative;
    flex: 0 0 auto;
    width: 48px;
    height: 27px;
    background: #c6d1dc;
    border-radius: 999px;
    transition: background 0.2s ease;
}

.locale-switch::after {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 19px;
    height: 19px;
    content: "";
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(26, 52, 77, 0.22);
    transition: transform 0.2s ease;
}

.locale-switch-row input:checked + .locale-switch {
    background: #1474e8;
}

.locale-switch-row input:checked + .locale-switch::after {
    transform: translateX(21px);
}

.locale-switch-row input:focus-visible + .locale-switch {
    box-shadow: 0 0 0 3px rgba(20, 116, 232, 0.18);
}

.locale-auto-timezone {
    margin-bottom: 0;
}

.locale-preview-section {
    background:
        linear-gradient(
            135deg,
            rgba(238, 247, 255, 0.9),
            rgba(255, 255, 255, 1)
        );
}

.locale-preview-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.locale-preview-card {
    min-width: 0;
    padding: 17px;
    background: #ffffff;
    border: 1px solid #dce7f2;
    border-radius: 14px;
}

.locale-preview-card span,
.locale-preview-card strong {
    display: block;
}

.locale-preview-card span {
    margin-bottom: 8px;
    color: #758598;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.locale-preview-card strong {
    overflow-wrap: anywhere;
    color: #245e9a;
    font-size: 1rem;
}

.locale-save-bar {
    position: sticky;
    z-index: 20;
    bottom: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 17px 19px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid #d9e5f0;
    border-radius: 16px;
    box-shadow: 0 14px 35px rgba(33, 72, 112, 0.16);
    backdrop-filter: blur(12px);
}

.locale-save-bar strong,
.locale-save-bar span {
    display: block;
}

.locale-save-bar strong {
    margin-bottom: 4px;
    color: #304961;
}

.locale-save-bar span {
    color: #748497;
    font-size: 0.84rem;
}

.locale-save-button {
    min-height: 45px;
    padding: 10px 18px;
    color: #ffffff;
    background: #126fdd;
    border: 1px solid #126fdd;
    border-radius: 12px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.locale-save-button:hover {
    background: #0d61c5;
}

.locale-toast {
    position: fixed;
    z-index: 9999;
    right: 22px;
    bottom: 22px;
    max-width: min(430px, calc(100vw - 44px));
    padding: 14px 18px;
    color: #ffffff;
    background: #193d63;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(17, 43, 72, 0.25);
    opacity: 0;
    transform: translateY(14px);
    pointer-events: none;
    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.locale-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1000px) {
    .locale-form-grid-three,
    .locale-preview-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .locale-form-grid,
    .locale-form-grid-three,
    .locale-preview-grid {
        grid-template-columns: 1fr;
    }

    .locale-section-heading,
    .locale-save-bar {
        align-items: stretch;
        flex-direction: column;
    }

    .locale-status {
        align-self: flex-start;
    }

    .locale-save-button {
        width: 100%;
    }

    .locale-switch-row {
        gap: 14px;
    }
}

/* MARCUS LANGUAGES END */

/* =========================================================
   MARCUS-IA — PRÉFÉRENCES
   ========================================================= */

:root {
    --marcus-accent: #2563eb;
    --marcus-accent-soft: rgba(37, 99, 235, 0.12);
}

.preferences-message {
    margin-bottom: 18px;
    padding: 13px 16px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
}

.preferences-message.is-success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.preferences-message.is-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

.preferences-message.is-error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.preferences-plan-panel {
    overflow: hidden;
    position: relative;
}

.preferences-plan-panel::after {
    content: "";
    position: absolute;
    top: -90px;
    right: -70px;
    width: 230px;
    height: 230px;
    border-radius: 50%;
    background: var(--marcus-accent-soft);
    pointer-events: none;
}

.preferences-plan-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    position: relative;
    z-index: 1;
}

.preferences-plan-summary h2 {
    margin: 10px 0 6px;
}

.preferences-plan-summary p {
    margin: 0;
    color: #64748b;
}

.preferences-current-plan {
    min-width: 180px;
    padding: 16px 18px;
    border: 1px solid var(--marcus-accent-soft);
    border-radius: 14px;
    background: #fff;
    text-align: right;
}

.preferences-current-plan span {
    display: block;
    margin-bottom: 4px;
    color: #64748b;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.preferences-current-plan strong {
    color: var(--marcus-accent);
    font-size: 20px;
}

.preferences-demo-plan {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px dashed #dbe3ee;
    position: relative;
    z-index: 1;
}

.preferences-demo-plan label {
    font-size: 13px;
    font-weight: 700;
}

.preferences-demo-plan select {
    min-width: 180px;
    padding: 9px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 9px;
    background: #fff;
}

.preferences-section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.preferences-section-heading h2 {
    margin: 0 0 5px;
}

.preferences-section-heading p {
    margin: 0;
    color: #64748b;
}

.preferences-subsection + .preferences-subsection {
    margin-top: 30px;
    padding-top: 26px;
    border-top: 1px solid #e5eaf0;
}

.preferences-subsection h3 {
    margin: 0 0 14px;
    font-size: 16px;
}

.preferences-subsection-title {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 16px;
}

.preferences-subsection-title h3 {
    margin-bottom: 4px;
}

.preferences-subsection-title p {
    margin: 0;
    color: #64748b;
    font-size: 13px;
}

.preferences-counter {
    flex: 0 0 auto;
    padding: 7px 10px;
    border-radius: 999px;
    color: var(--marcus-accent);
    background: var(--marcus-accent-soft);
    font-size: 12px;
    font-weight: 800;
}

.preferences-choice-grid {
    display: grid;
    gap: 14px;
}

.preferences-mode-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.preference-choice-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 13px;
    min-height: 185px;
    padding: 15px;
    border: 1px solid #dce3eb;
    border-radius: 15px;
    background: #fff;
    color: #172033;
    text-align: left;
    cursor: pointer;
    transition:
        border-color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.preference-choice-card:not(:disabled):hover {
    transform: translateY(-2px);
    border-color: var(--marcus-accent);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.preference-choice-card.is-selected {
    border-color: var(--marcus-accent);
    box-shadow: 0 0 0 3px var(--marcus-accent-soft);
}

.preference-choice-card.is-locked {
    opacity: 0.64;
    cursor: not-allowed;
}

.preference-choice-preview {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-height: 80px;
    padding: 14px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 11px;
    overflow: hidden;
}

.preference-choice-preview i {
    display: block;
    height: 9px;
    border-radius: 999px;
}

.preference-choice-preview i:first-child {
    width: 58%;
}

.preference-choice-preview i:nth-child(2) {
    width: 82%;
}

.preference-choice-preview i:nth-child(3) {
    width: 68%;
}

.theme-preview-light {
    background: #f8fafc;
}

.theme-preview-light i {
    background: #cbd5e1;
}

.theme-preview-dark {
    background: #111827;
}

.theme-preview-dark i {
    background: #475569;
}

.theme-preview-system {
    background:
        linear-gradient(
            90deg,
            #f8fafc 0%,
            #f8fafc 50%,
            #111827 50%,
            #111827 100%
        );
}

.theme-preview-system i {
    background:
        linear-gradient(
            90deg,
            #cbd5e1 0%,
            #cbd5e1 50%,
            #475569 50%,
            #475569 100%
        );
}

.preference-choice-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.preference-choice-content small {
    color: #64748b;
    line-height: 1.4;
}

.preference-choice-check {
    display: none;
    position: absolute;
    top: 12px;
    right: 12px;
    width: 23px;
    height: 23px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    background: var(--marcus-accent);
    font-size: 13px;
    font-weight: 900;
}

.preference-choice-card.is-selected
.preference-choice-check {
    display: flex;
}

.preference-lock-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    padding: 7px 9px;
    border-radius: 8px;
    color: #64748b;
    background: #f1f5f9;
    font-size: 11px;
    font-weight: 700;
}

.preferences-color-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.preference-color-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 72px;
    padding: 12px;
    border: 1px solid #dce3eb;
    border-radius: 13px;
    background: #fff;
    color: #172033;
    text-align: left;
    cursor: pointer;
    transition:
        border-color 0.2s ease,
        transform 0.2s ease;
}

.preference-color-card:not(:disabled):hover {
    transform: translateY(-1px);
    border-color: var(--marcus-accent);
}

.preference-color-card.is-selected {
    border-color: var(--marcus-accent);
    box-shadow: 0 0 0 3px var(--marcus-accent-soft);
}

.preference-color-card.is-locked {
    opacity: 0.52;
    cursor: not-allowed;
}

.preference-color-card > span:nth-child(2) {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.preference-color-card strong {
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preference-color-card small {
    color: #64748b;
    font-size: 11px;
}

.preference-color-swatch {
    flex: 0 0 auto;
    width: 31px;
    height: 31px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: var(--swatch-color);
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.15);
}

.preference-color-check {
    display: none;
    margin-left: auto;
    width: 21px;
    height: 21px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    background: var(--marcus-accent);
    font-size: 12px;
    font-weight: 900;
}

.preference-color-card.is-selected
.preference-color-check {
    display: flex;
}

.preference-color-card.is-fixed {
    cursor: default;
}

.preferences-custom-color {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.preferences-custom-color p {
    max-width: 600px;
    margin: 5px 0 0;
    color: #64748b;
    font-size: 13px;
}

.preferences-custom-color-control {
    display: flex;
    align-items: center;
    gap: 9px;
}

.preferences-custom-color-control input[type="color"] {
    width: 48px;
    height: 42px;
    padding: 3px;
    border: 1px solid #cbd5e1;
    border-radius: 9px;
    background: #fff;
    cursor: pointer;
}

.preferences-custom-color-control input[type="text"] {
    width: 105px;
    height: 42px;
    padding: 0 11px;
    border: 1px solid #cbd5e1;
    border-radius: 9px;
    font-weight: 700;
    text-transform: uppercase;
}

.preferences-secondary-button,
.preferences-reset-button,
.preferences-save-button {
    min-height: 42px;
    padding: 0 17px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.preferences-secondary-button,
.preferences-reset-button {
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #334155;
}

.preferences-save-button {
    border: 1px solid var(--marcus-accent);
    background: var(--marcus-accent);
    color: #fff;
}

.preferences-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

.preferences-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.preferences-field label {
    color: #1e293b;
    font-size: 13px;
    font-weight: 800;
}

.preferences-field select {
    width: 100%;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    background: #fff;
    color: #172033;
}

.preferences-field small {
    color: #64748b;
    font-size: 12px;
}

.preferences-toggle-list {
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.preferences-toggle-row {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 17px 18px;
    cursor: pointer;
}

.preferences-toggle-row + .preferences-toggle-row {
    border-top: 1px solid #e2e8f0;
}

.preferences-toggle-row > span:first-child {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.preferences-toggle-row strong {
    color: #172033;
    font-size: 14px;
}

.preferences-toggle-row small {
    color: #64748b;
    line-height: 1.45;
}

.preferences-toggle-row input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.preferences-switch {
    flex: 0 0 auto;
    position: relative;
    width: 44px;
    height: 24px;
    border-radius: 999px;
    background: #cbd5e1;
    transition: background 0.2s ease;
}

.preferences-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 5px rgba(15, 23, 42, 0.22);
    transition: transform 0.2s ease;
}

.preferences-toggle-row input:checked +
.preferences-switch {
    background: var(--marcus-accent);
}

.preferences-toggle-row input:checked +
.preferences-switch::after {
    transform: translateX(20px);
}

.preferences-toggle-row input:focus-visible +
.preferences-switch {
    outline: 3px solid var(--marcus-accent-soft);
}

.preferences-preview {
    --preview-accent: #2563eb;

    display: grid;
    grid-template-columns: 86px 1fr;
    min-height: 310px;
    border: 1px solid #dbe3ee;
    border-radius: 17px;
    overflow: hidden;
    background: #f8fafc;
    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.preferences-preview-sidebar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 20px 14px;
    background: #fff;
    border-right: 1px solid #e2e8f0;
}

.preferences-preview-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 39px;
    height: 39px;
    margin-bottom: 10px;
    border-radius: 11px;
    color: #fff;
    background: var(--preview-accent);
    font-weight: 900;
}

.preferences-preview-sidebar > span:not(.preferences-preview-logo) {
    display: block;
    width: 35px;
    height: 8px;
    border-radius: 999px;
    background: #dbe3ee;
}

.preferences-preview-content {
    padding: 20px;
}

.preferences-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 42px;
}

.preferences-preview-header span:first-child {
    width: 150px;
    height: 13px;
    border-radius: 999px;
    background: #dbe3ee;
}

.preferences-preview-header span:last-child {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--preview-accent);
}

.preferences-preview-card {
    max-width: 500px;
    padding: 25px;
    border: 1px solid #e2e8f0;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.preferences-preview-badge {
    display: inline-flex;
    margin-bottom: 13px;
    padding: 6px 9px;
    border-radius: 999px;
    color: var(--preview-accent);
    background: color-mix(
        in srgb,
        var(--preview-accent) 12%,
        transparent
    );
    font-size: 11px;
    font-weight: 800;
}

.preferences-preview-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 18px;
}

.preferences-preview-card p {
    margin: 0 0 18px;
    color: #64748b;
    line-height: 1.55;
}

.preferences-preview-card button {
    padding: 10px 15px;
    border: 0;
    border-radius: 9px;
    color: #fff;
    background: var(--preview-accent);
    font-weight: 800;
}

.preferences-preview[data-theme="dark"] {
    color: #f8fafc;
    background: #0f172a;
    border-color: #334155;
}

.preferences-preview[data-theme="dark"]
.preferences-preview-sidebar,
.preferences-preview[data-theme="dark"]
.preferences-preview-card {
    background: #172033;
    border-color: #334155;
}

.preferences-preview[data-theme="dark"]
.preferences-preview-card p {
    color: #94a3b8;
}

.preferences-preview[data-theme="dark"]
.preferences-preview-sidebar > span:not(.preferences-preview-logo),
.preferences-preview[data-theme="dark"]
.preferences-preview-header span:first-child {
    background: #475569;
}

.preferences-preview[data-density="compact"]
.preferences-preview-content {
    padding: 13px;
}

.preferences-preview[data-density="compact"]
.preferences-preview-card {
    padding: 17px;
}

.preferences-preview[data-density="spacious"]
.preferences-preview-content {
    padding: 30px;
}

.preferences-preview[data-density="spacious"]
.preferences-preview-card {
    padding: 32px;
}

.preferences-preview[data-text-size="small"] {
    font-size: 13px;
}

.preferences-preview[data-text-size="large"] {
    font-size: 17px;
}

.preferences-save-bar {
    position: sticky;
    bottom: 16px;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 11px;
    margin-top: 22px;
    padding: 14px 16px;
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 14px 38px rgba(15, 23, 42, 0.13);
    backdrop-filter: blur(16px);
}

.preferences-save-bar > div {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.preferences-save-bar strong {
    font-size: 13px;
}

.preferences-save-bar span {
    color: #64748b;
    font-size: 12px;
}

/* Préférences globales enregistrées */

html[data-text-size="small"] {
    font-size: 14px;
}

html[data-text-size="normal"] {
    font-size: 16px;
}

html[data-text-size="large"] {
    font-size: 18px;
}

html[data-animations="disabled"] *,
html[data-animations="disabled"] *::before,
html[data-animations="disabled"] *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
}

html[data-interface-density="compact"] .account-panel {
    padding-top: 17px;
    padding-bottom: 17px;
}

html[data-interface-density="spacious"] .account-panel {
    padding-top: 30px;
    padding-bottom: 30px;
}

html[data-marcus-theme="dark"] body.account-page {
    color: #e5e7eb;
    background: #0f172a;
}

html[data-marcus-theme="dark"] .account-panel,
html[data-marcus-theme="dark"] .preferences-save-bar,
html[data-marcus-theme="dark"] .preferences-current-plan,
html[data-marcus-theme="dark"] .preference-choice-card,
html[data-marcus-theme="dark"] .preference-color-card {
    color: #e5e7eb;
    background: #172033;
    border-color: #334155;
}

html[data-marcus-theme="dark"] .account-panel p,
html[data-marcus-theme="dark"] .preference-choice-content small,
html[data-marcus-theme="dark"] .preference-color-card small,
html[data-marcus-theme="dark"] .preferences-field small,
html[data-marcus-theme="dark"] .preferences-toggle-row small,
html[data-marcus-theme="dark"] .preferences-save-bar span {
    color: #94a3b8;
}

html[data-marcus-theme="dark"] .preferences-field label,
html[data-marcus-theme="dark"] .preferences-toggle-row strong,
html[data-marcus-theme="dark"] .preference-choice-card,
html[data-marcus-theme="dark"] .preference-color-card {
    color: #f8fafc;
}

html[data-marcus-theme="dark"] .preferences-field select,
html[data-marcus-theme="dark"]
.preferences-custom-color-control input {
    color: #e5e7eb;
    background: #0f172a;
    border-color: #475569;
}

html[data-marcus-theme="dark"] .preferences-toggle-list,
html[data-marcus-theme="dark"] .preferences-toggle-row,
html[data-marcus-theme="dark"] .preferences-subsection {
    border-color: #334155;
}

@media (max-width: 1000px) {
    .preferences-color-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .preferences-plan-summary,
    .preferences-custom-color,
    .preferences-subsection-title {
        flex-direction: column;
        align-items: stretch;
    }

    .preferences-current-plan {
        width: 100%;
        text-align: left;
    }

    .preferences-mode-grid,
    .preferences-form-grid {
        grid-template-columns: 1fr;
    }

    .preferences-color-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .preferences-custom-color-control {
        flex-wrap: wrap;
    }

    .preferences-preview {
        grid-template-columns: 60px 1fr;
    }

    .preferences-preview-sidebar {
        padding-right: 10px;
        padding-left: 10px;
    }

    .preferences-preview-sidebar > span:not(.preferences-preview-logo) {
        width: 26px;
    }

    .preferences-save-bar {
        position: static;
        flex-wrap: wrap;
    }

    .preferences-save-bar > div {
        flex-basis: 100%;
    }

    .preferences-reset-button,
    .preferences-save-button {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .preferences-color-grid {
        grid-template-columns: 1fr;
    }

    .preferences-toggle-row {
        padding: 15px;
    }

    .preferences-preview-content {
        padding: 13px;
    }

    .preferences-preview-header {
        margin-bottom: 24px;
    }
}

/* =========================================================
   MARCUS-IA — CONFIDENTIALITE V2
   ========================================================= */

.privacy-message {
    margin-bottom: 18px;
    padding: 13px 16px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
}

.privacy-message.is-success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.privacy-message.is-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

.privacy-message.is-error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.privacy-overview {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    overflow: hidden;
    position: relative;
}

.privacy-overview::after {
    content: "";
    position: absolute;
    top: -100px;
    right: -90px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.08);
    pointer-events: none;
}

.privacy-overview-main {
    display: flex;
    align-items: center;
    gap: 18px;
    position: relative;
    z-index: 1;
}

.privacy-overview-main h2 {
    margin: 10px 0 7px;
}

.privacy-overview-main p {
    max-width: 730px;
    margin: 0;
    color: #64748b;
    line-height: 1.55;
}

.privacy-shield {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 20px;
    background: #eff6ff;
    font-size: 31px;
}

.privacy-score {
    flex: 0 0 205px;
    position: relative;
    z-index: 1;
    padding: 17px;
    border: 1px solid #dbe5f0;
    border-radius: 15px;
    background: #fff;
}

.privacy-score > span,
.privacy-score small {
    display: block;
    color: #64748b;
    font-size: 12px;
}

.privacy-score strong {
    display: block;
    margin: 5px 0 10px;
    color: #2563eb;
    font-size: 28px;
}

.privacy-score-track,
.privacy-progress-track {
    overflow: hidden;
    height: 7px;
    border-radius: 999px;
    background: #e2e8f0;
}

.privacy-score-track {
    margin-bottom: 8px;
}

.privacy-score-track span,
.privacy-progress-track span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #2563eb, #06b6d4);
    transition: width 0.35s ease;
}

.privacy-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 18px 0;
}

.privacy-stat-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 17px;
    border: 1px solid #e0e7ef;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 7px 20px rgba(15, 23, 42, 0.035);
}

.privacy-stat-icon {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 39px;
    height: 39px;
    border-radius: 11px;
    background: #f1f5f9;
    font-size: 18px;
}

.privacy-stat-card div {
    min-width: 0;
}

.privacy-stat-card small {
    display: block;
    margin-bottom: 3px;
    color: #64748b;
    font-size: 11px;
}

.privacy-stat-card strong {
    display: block;
    overflow: hidden;
    color: #172033;
    font-size: 14px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.privacy-section-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.privacy-section-title {
    display: flex;
    align-items: flex-start;
    gap: 13px;
}

.privacy-section-title h2 {
    margin: 0 0 5px;
}

.privacy-section-title p {
    margin: 0;
    color: #64748b;
}

.privacy-section-icon {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 39px;
    height: 39px;
    border-radius: 11px;
    background: #eff6ff;
    font-size: 18px;
}

.privacy-status-badge {
    flex: 0 0 auto;
    padding: 7px 10px;
    border-radius: 999px;
    color: #475569;
    background: #f1f5f9;
    font-size: 11px;
    font-weight: 800;
}

.privacy-status-badge.is-success {
    color: #047857;
    background: #ecfdf5;
}

.privacy-toggle-list {
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.privacy-toggle-row {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 17px 18px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.privacy-toggle-row:hover {
    background: #f8fafc;
}

.privacy-toggle-row + .privacy-toggle-row {
    border-top: 1px solid #e2e8f0;
}

.privacy-toggle-copy {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.privacy-toggle-copy strong {
    color: #172033;
    font-size: 14px;
}

.privacy-toggle-copy small {
    color: #64748b;
    line-height: 1.45;
}

.privacy-toggle-copy em {
    align-self: flex-start;
    margin-top: 2px;
    padding: 3px 7px;
    border-radius: 999px;
    color: #475569;
    background: #f1f5f9;
    font-size: 10px;
    font-style: normal;
    font-weight: 800;
}

.privacy-toggle-row input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.privacy-switch {
    flex: 0 0 auto;
    position: relative;
    width: 44px;
    height: 24px;
    border-radius: 999px;
    background: #cbd5e1;
    transition: background 0.2s ease;
}

.privacy-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 5px rgba(15, 23, 42, 0.22);
    transition: transform 0.2s ease;
}

.privacy-toggle-row input:checked + .privacy-switch {
    background: #2563eb;
}

.privacy-toggle-row input:checked + .privacy-switch::after {
    transform: translateX(20px);
}

.privacy-toggle-row input:disabled + .privacy-switch {
    opacity: 0.65;
}

.privacy-section-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
    margin-top: 18px;
}

.privacy-section-actions > span {
    flex: 1;
    color: #64748b;
    font-size: 12px;
}

.privacy-primary-button,
.privacy-secondary-button,
.privacy-danger-button {
    min-height: 42px;
    padding: 0 17px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.privacy-primary-button {
    border: 1px solid #2563eb;
    color: #fff;
    background: #2563eb;
}

.privacy-primary-button:hover {
    background: #1d4ed8;
}

.privacy-primary-button:disabled {
    opacity: 0.65;
    cursor: wait;
}

.privacy-secondary-button {
    border: 1px solid #cbd5e1;
    color: #334155;
    background: #fff;
}

.privacy-export-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 13px;
}

.privacy-export-option {
    cursor: pointer;
}

.privacy-export-option input {
    position: absolute;
    opacity: 0;
}

.privacy-export-format {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 90px;
    padding: 15px;
    border: 1px solid #dce3eb;
    border-radius: 13px;
    background: #fff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.privacy-export-option:hover .privacy-export-format {
    transform: translateY(-1px);
    border-color: #93c5fd;
}

.privacy-export-option input:checked + .privacy-export-format {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.privacy-export-format > b {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 43px;
    height: 43px;
    border-radius: 11px;
    color: #2563eb;
    background: #eff6ff;
    font-size: 12px;
}

.privacy-export-format span {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.privacy-export-format strong {
    color: #172033;
    font-size: 13px;
}

.privacy-export-format small {
    color: #64748b;
    font-size: 11px;
}

.privacy-information-box {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 16px;
    padding: 13px 15px;
    border: 1px solid #bfdbfe;
    border-radius: 11px;
    color: #1e40af;
    background: #eff6ff;
}

.privacy-information-box p {
    margin: 0;
    font-size: 12px;
    line-height: 1.5;
}

.privacy-export-progress {
    margin-top: 18px;
    padding: 15px;
    border: 1px solid #dbe5f0;
    border-radius: 12px;
    background: #f8fafc;
}

.privacy-export-progress > div:first-child {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 9px;
    font-size: 12px;
}

.privacy-retention-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 20px;
}

.privacy-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.privacy-field label {
    color: #172033;
    font-size: 13px;
    font-weight: 800;
}

.privacy-field select {
    min-height: 45px;
    padding: 0 12px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    color: #172033;
    background: #fff;
}

.privacy-field small {
    color: #64748b;
    line-height: 1.45;
}

.privacy-retention-preview {
    padding: 18px;
    border: 1px solid #dbe5f0;
    border-radius: 14px;
    background: #f8fafc;
}

.privacy-retention-preview span {
    color: #64748b;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.privacy-retention-preview strong {
    display: block;
    margin: 5px 0 8px;
    color: #2563eb;
    font-size: 23px;
}

.privacy-retention-preview p {
    margin: 0;
    color: #64748b;
    font-size: 12px;
    line-height: 1.5;
}

.privacy-secondary-toggles {
    margin-top: 18px;
}

.privacy-text-link {
    color: #2563eb;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
}

.privacy-activity-list {
    overflow: hidden;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.privacy-activity-item {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 13px;
    padding: 15px 17px;
}

.privacy-activity-item + .privacy-activity-item {
    border-top: 1px solid #e2e8f0;
}

.privacy-activity-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 37px;
    height: 37px;
    border-radius: 10px;
    background: #f1f5f9;
}

.privacy-activity-item strong {
    color: #172033;
    font-size: 13px;
}

.privacy-activity-item p {
    margin: 3px 0 0;
    color: #64748b;
    font-size: 12px;
}

.privacy-activity-item time {
    color: #94a3b8;
    font-size: 11px;
    white-space: nowrap;
}

.privacy-empty-state {
    padding: 34px 20px;
    text-align: center;
}

.privacy-empty-state span {
    display: block;
    margin-bottom: 8px;
    font-size: 28px;
}

.privacy-empty-state strong {
    display: block;
}

.privacy-empty-state p {
    margin: 5px 0 0;
    color: #64748b;
}

.privacy-danger-zone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
    border-color: #fecaca;
    background: #fffafa;
}

.privacy-danger-zone > div {
    display: flex;
    align-items: center;
    gap: 15px;
}

.privacy-danger-icon {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 47px;
    height: 47px;
    border-radius: 13px;
    background: #fee2e2;
    font-size: 21px;
}

.privacy-danger-zone h2 {
    margin: 0 0 5px;
    color: #991b1b;
}

.privacy-danger-zone p {
    margin: 0;
    color: #7f1d1d;
}

.privacy-danger-button {
    flex: 0 0 auto;
    border: 1px solid #ef4444;
    color: #b91c1c;
    background: #fff;
}

.privacy-modal[hidden] {
    display: none;
}

.privacy-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.privacy-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.62);
    backdrop-filter: blur(4px);
}

.privacy-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 530px);
    padding: 28px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.3);
}

.privacy-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    border: 0;
    color: #64748b;
    background: transparent;
    font-size: 27px;
    cursor: pointer;
}

.privacy-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 51px;
    height: 51px;
    margin-bottom: 15px;
    border-radius: 14px;
    background: #fee2e2;
    font-size: 23px;
}

.privacy-modal-dialog h2 {
    margin: 0 0 9px;
}

.privacy-modal-dialog p,
.privacy-modal-dialog li {
    color: #64748b;
    line-height: 1.55;
}

.privacy-modal-dialog ul {
    margin: 17px 0 22px;
    padding-left: 20px;
}

body.privacy-modal-open {
    overflow: hidden;
}

@media (max-width: 1050px) {
    .privacy-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .privacy-overview,
    .privacy-section-header,
    .privacy-danger-zone {
        flex-direction: column;
        align-items: stretch;
    }

    .privacy-score {
        flex-basis: auto;
    }

    .privacy-export-grid,
    .privacy-retention-layout {
        grid-template-columns: 1fr;
    }

    .privacy-section-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .privacy-primary-button,
    .privacy-danger-button {
        width: 100%;
    }

    .privacy-activity-item {
        grid-template-columns: 40px minmax(0, 1fr);
    }

    .privacy-activity-item time {
        grid-column: 2;
    }
}

@media (max-width: 480px) {
    .privacy-stat-grid {
        grid-template-columns: 1fr;
    }

    .privacy-overview-main {
        align-items: flex-start;
    }

    .privacy-shield {
        width: 52px;
        height: 52px;
        border-radius: 15px;
        font-size: 23px;
    }

    .privacy-toggle-row {
        padding: 15px;
    }
}

/* ==========================================================
   DEVELOPER CENTER
========================================================== */

.developer-container {
    padding-bottom: 60px;
}

.developer-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 24px;
    padding: 28px;
    overflow: hidden;
    border: 1px solid #bfdbfe;
    border-radius: 20px;
    background:
        radial-gradient(
            circle at top right,
            rgba(37, 99, 235, 0.14),
            transparent 36%
        ),
        linear-gradient(135deg, #f8fbff, #eff6ff);
}

.developer-hero-content {
    display: flex;
    align-items: flex-start;
    gap: 18px;
}

.developer-hero-icon {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 62px;
    height: 62px;
    border-radius: 18px;
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #4f46e5);
    font-size: 28px;
    font-weight: 900;
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.24);
}

.developer-hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.developer-badge {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
}

.developer-badge-primary {
    color: #1d4ed8;
    background: #dbeafe;
}

.developer-badge-success {
    color: #166534;
    background: #dcfce7;
}

.developer-hero h2 {
    margin: 0 0 8px;
    color: #172033;
    font-size: 23px;
}

.developer-hero p {
    max-width: 720px;
    margin: 0;
    color: #64748b;
    line-height: 1.65;
}

.developer-plan {
    flex: 0 0 190px;
    padding: 18px;
    border: 1px solid rgba(37, 99, 235, 0.18);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.82);
    text-align: right;
}

.developer-plan span,
.developer-plan small {
    display: block;
    color: #64748b;
    font-size: 12px;
}

.developer-plan strong {
    display: block;
    margin: 4px 0;
    color: #1d4ed8;
    font-size: 21px;
}

.developer-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 15px;
    margin-bottom: 24px;
}

.developer-stat-card {
    display: flex;
    align-items: center;
    gap: 13px;
    min-width: 0;
    padding: 18px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.developer-stat-icon {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 43px;
    height: 43px;
    border-radius: 13px;
    background: #eff6ff;
    font-size: 19px;
}

.developer-stat-card span,
.developer-stat-card small {
    display: block;
    color: #64748b;
    font-size: 11px;
}

.developer-stat-card strong {
    display: block;
    margin: 3px 0;
    color: #172033;
    font-size: 21px;
}

.developer-panel {
    margin-bottom: 22px;
}

.developer-section-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.developer-section-kicker {
    display: block;
    margin-bottom: 4px;
    color: #2563eb;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.developer-section-header h2 {
    margin: 0 0 6px;
    color: #172033;
}

.developer-section-header p {
    margin: 0;
    color: #64748b;
    line-height: 1.55;
}

.developer-primary-button,
.developer-secondary-button {
    min-height: 42px;
    padding: 10px 16px;
    border-radius: 11px;
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition:
        transform 0.16s ease,
        box-shadow 0.16s ease,
        opacity 0.16s ease;
}

.developer-primary-button {
    border: 1px solid #2563eb;
    color: #fff;
    background: #2563eb;
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.18);
}

.developer-secondary-button {
    border: 1px solid #cbd5e1;
    color: #334155;
    background: #fff;
}

.developer-primary-button:hover,
.developer-secondary-button:hover {
    transform: translateY(-1px);
}

.developer-primary-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.developer-full-button {
    width: 100%;
}

.developer-security-note {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-bottom: 18px;
    padding: 13px 15px;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    background: #eff6ff;
}

.developer-security-note p {
    margin: 0;
    color: #1e40af;
    font-size: 12px;
    line-height: 1.55;
}

.developer-empty-state {
    padding: 38px 20px;
    border: 1px dashed #cbd5e1;
    border-radius: 15px;
    background: #f8fafc;
    text-align: center;
}

.developer-empty-state span {
    display: block;
    margin-bottom: 10px;
    font-size: 30px;
}

.developer-empty-state strong {
    display: block;
    color: #172033;
}

.developer-empty-state p {
    margin: 6px auto 0;
    max-width: 520px;
    color: #64748b;
    font-size: 13px;
}

.developer-table-wrapper {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.developer-table {
    width: 100%;
    min-width: 850px;
    border-collapse: collapse;
    background: #fff;
}

.developer-table th,
.developer-table td {
    padding: 13px 15px;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
    vertical-align: middle;
}

.developer-table th {
    color: #64748b;
    background: #f8fafc;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.developer-table td {
    color: #334155;
    font-size: 12px;
}

.developer-table tbody tr:last-child td {
    border-bottom: 0;
}

.developer-table code {
    display: block;
    margin-top: 4px;
    color: #64748b;
    font-size: 11px;
}

.developer-table-empty {
    padding: 30px !important;
    color: #64748b !important;
    text-align: center !important;
}

.developer-environment,
.developer-status,
.developer-method,
.developer-mini-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 24px;
    padding: 3px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 900;
}

.developer-environment.sandbox {
    color: #6d28d9;
    background: #ede9fe;
}

.developer-environment.production {
    color: #1d4ed8;
    background: #dbeafe;
}

.developer-status.success {
    color: #166534;
    background: #dcfce7;
}

.developer-status.danger {
    color: #991b1b;
    background: #fee2e2;
}

.developer-method.post {
    color: #166534;
    background: #dcfce7;
}

.developer-method.get {
    color: #1d4ed8;
    background: #dbeafe;
}

.developer-mini-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.developer-mini-badge {
    color: #475569;
    background: #f1f5f9;
}

.developer-row-actions,
.developer-webhook-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.developer-row-actions button,
.developer-webhook-actions button {
    min-height: 30px;
    padding: 5px 9px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    color: #334155;
    background: #fff;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

.developer-row-actions button.danger,
.developer-webhook-actions button.danger {
    border-color: #fecaca;
    color: #b91c1c;
    background: #fffafa;
}

.developer-permissions-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 13px;
}

.developer-permission-card {
    padding: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
}

.developer-permission-card span {
    display: block;
    margin-bottom: 9px;
    font-size: 22px;
}

.developer-permission-card strong {
    display: block;
    color: #172033;
}

.developer-permission-card p {
    margin: 5px 0 0;
    color: #64748b;
    font-size: 12px;
    line-height: 1.45;
}

.developer-webhooks-list {
    display: grid;
    gap: 12px;
}

.developer-webhook-card {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
}

.developer-webhook-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 43px;
    height: 43px;
    border-radius: 12px;
    background: #eff6ff;
}

.developer-webhook-title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 5px;
}

.developer-webhook-main code {
    display: block;
    overflow: hidden;
    color: #334155;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.developer-webhook-main p {
    margin: 5px 0 0;
    color: #64748b;
    font-size: 11px;
}

.developer-filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.developer-filter {
    min-height: 34px;
    padding: 6px 11px;
    border: 1px solid #cbd5e1;
    border-radius: 9px;
    color: #475569;
    background: #fff;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

.developer-filter.active {
    border-color: #2563eb;
    color: #1d4ed8;
    background: #eff6ff;
}

.developer-docs-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 13px;
}

.developer-doc-card {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    align-items: center;
    gap: 11px;
    padding: 15px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    color: inherit;
    background: #fff;
    text-decoration: none;
    transition:
        transform 0.16s ease,
        border-color 0.16s ease,
        box-shadow 0.16s ease;
}

.developer-doc-card:hover {
    transform: translateY(-2px);
    border-color: #bfdbfe;
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.08);
}

.developer-doc-card > span {
    font-size: 21px;
}

.developer-doc-card strong {
    color: #172033;
}

.developer-doc-card p {
    margin: 4px 0 0;
    color: #64748b;
    font-size: 11px;
}

.developer-doc-card b {
    color: #2563eb;
}

.developer-playground {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 15px;
}

.developer-playground-editor,
.developer-playground-response {
    padding: 17px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #f8fafc;
}

.developer-request-line {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 9px;
    margin-bottom: 14px;
}

.developer-playground select,
.developer-playground input,
.developer-playground textarea,
.developer-modal input,
.developer-modal select {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    color: #172033;
    background: #fff;
    font: inherit;
}

.developer-playground select,
.developer-playground input,
.developer-modal input,
.developer-modal select {
    min-height: 42px;
    padding: 9px 11px;
}

.developer-playground label,
.developer-modal label,
.developer-modal legend {
    display: block;
    margin-bottom: 7px;
    color: #334155;
    font-size: 12px;
    font-weight: 800;
}

.developer-playground textarea {
    min-height: 220px;
    margin-bottom: 12px;
    padding: 13px;
    resize: vertical;
    font-family: Consolas, Monaco, monospace;
    font-size: 12px;
    line-height: 1.55;
}

.developer-response-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
    color: #334155;
    font-size: 12px;
    font-weight: 800;
}

.developer-response-header strong.success {
    color: #166534;
}

.developer-response-header strong.danger {
    color: #b91c1c;
}

.developer-playground-response pre {
    min-height: 287px;
    margin: 0;
    overflow: auto;
    padding: 15px;
    border-radius: 11px;
    color: #dbeafe;
    background: #0f172a;
    font-size: 11px;
    line-height: 1.6;
    white-space: pre-wrap;
}

.developer-modal[hidden] {
    display: none;
}

.developer-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.developer-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.64);
    backdrop-filter: blur(4px);
}

.developer-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(100%, 520px);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 27px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 25px 75px rgba(15, 23, 42, 0.3);
}

.developer-modal-close {
    position: absolute;
    top: 11px;
    right: 14px;
    border: 0;
    color: #64748b;
    background: transparent;
    font-size: 28px;
    cursor: pointer;
}

.developer-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 49px;
    height: 49px;
    margin-bottom: 14px;
    border-radius: 14px;
    background: #eff6ff;
    font-size: 22px;
}

.developer-modal-dialog h2 {
    margin: 0 0 20px;
}

.developer-modal form {
    display: grid;
    gap: 9px;
}

.developer-modal fieldset {
    margin: 8px 0 11px;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.developer-modal-permissions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.developer-modal-permissions label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 9px;
    border: 1px solid #e2e8f0;
    border-radius: 9px;
}

.developer-modal-permissions input {
    width: auto;
    min-height: auto;
}

.developer-created-key-warning {
    margin-bottom: 13px;
    padding: 13px;
    border: 1px solid #fde68a;
    border-radius: 11px;
    background: #fffbeb;
}

.developer-created-key-warning strong {
    color: #92400e;
}

.developer-created-key-warning p {
    margin: 4px 0 0;
    color: #a16207;
    font-size: 12px;
}

#developerCreatedKeyValue {
    display: block;
    margin-bottom: 13px;
    overflow-wrap: anywhere;
    padding: 14px;
    border-radius: 10px;
    color: #dbeafe;
    background: #0f172a;
    font-size: 12px;
}

body.developer-modal-open {
    overflow: hidden;
}

.developer-toast {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 11000;
    max-width: 360px;
    padding: 12px 16px;
    border-radius: 11px;
    color: #fff;
    background: #172033;
    box-shadow: 0 14px 35px rgba(15, 23, 42, 0.25);
    font-size: 13px;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
    transform: translateY(12px);
    transition:
        opacity 0.2s ease,
        transform 0.2s ease;
}

.developer-toast.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1050px) {
    .developer-stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .developer-permissions-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .developer-docs-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .developer-hero,
    .developer-section-header {
        flex-direction: column;
        align-items: stretch;
    }

    .developer-plan {
        flex-basis: auto;
        text-align: left;
    }

    .developer-playground {
        grid-template-columns: 1fr;
    }

    .developer-webhook-card {
        grid-template-columns: 44px minmax(0, 1fr);
    }

    .developer-webhook-actions {
        grid-column: 2;
    }

    .developer-section-header .developer-primary-button,
    .developer-section-header .developer-secondary-button {
        width: 100%;
    }
}

@media (max-width: 520px) {
    .developer-hero {
        padding: 20px;
    }

    .developer-hero-content {
        flex-direction: column;
    }

    .developer-stats-grid,
    .developer-permissions-grid,
    .developer-docs-grid {
        grid-template-columns: 1fr;
    }

    .developer-request-line {
        grid-template-columns: 1fr;
    }

    .developer-modal-permissions {
        grid-template-columns: 1fr;
    }

    .developer-toast {
        right: 12px;
        bottom: 12px;
        left: 12px;
        max-width: none;
    }
}
