:root {
    --bg: #f3f6fb;
    --panel: rgba(255, 255, 255, 0.92);
    --panel-strong: #ffffff;
    --line: #dbe4f0;
    --text: #142033;
    --muted: #64748b;
    --primary: #1d4ed8;
    --primary-soft: #e8f0ff;
    --danger: #b91c1c;
    --success: #166534;
    --warning: #b45309;
    --shadow: 0 22px 60px rgba(15, 23, 42, 0.10);
    --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.06);
    --radius: 24px;
    --radius-sm: 16px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: var(--text);
    background: radial-gradient(circle at top left, rgba(29, 78, 216, 0.10), transparent 28%), radial-gradient(circle at bottom right, rgba(59, 130, 246, 0.08), transparent 24%), linear-gradient(180deg, #f7f9fc 0%, #eef3f9 100%);
    min-height: 100vh;
}

.hidden {
    display: none !important;
}

.app {
    max-width: 1440px;
    margin: 0 auto;
    padding: 12px 18px;
}

.auth-layout {
    min-height: calc(100vh - 56px);
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 28px;
    align-items: stretch;
}

.showcase {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(248, 250, 252, 0.9));
    border: 1px solid rgba(219, 228, 240, 0.9);
    border-radius: 32px;
    box-shadow: var(--shadow);
    padding: 36px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    position: relative;
}

.showcase::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 85% 15%, rgba(29, 78, 216, 0.11), transparent 18%), radial-gradient(circle at 10% 85%, rgba(59, 130, 246, 0.08), transparent 20%);
    pointer-events: none;
}

.brand {
    position: relative;
    z-index: 1;
}

.brand h1 {
    margin: 0 0 16px;
    font-size: 35px;
    line-height: 1.05;
    max-width: 900px;
    letter-spacing: -0.04em;
}

.brand p {
    margin: 0;
    max-width: 680px;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.7;
}

.feature-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 30px;
}

.feature-card {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 20px;
    box-shadow: var(--shadow-soft);
    min-height: 155px;
}

.feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-soft);
    color: var(--primary);
    font-size: 20px;
    margin-bottom: 14px;
    font-weight: 700;
}

.feature-card h3 {
    margin: 0 0 8px;
    font-size: 16px;
}

.feature-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.2;
    font-size: 14px;
}

.bottom-note {
    position: relative;
    z-index: 1;
    margin-top: 22px;
    padding: 18px 20px;
    border-radius: 20px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.82);
    color: var(--muted);
    line-height: 1.7;
    font-size: 14px;
}

.auth-card {
    background: rgba(255, 255, 255, 0.97);
    border: 1px solid rgba(219, 228, 240, 0.95);
    border-radius: 32px;
    box-shadow: var(--shadow);
    padding: 30px;
    padding-top: 10px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-height: 100%;
}

.auth-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
}

.auth-logo img {
    width: 250px;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.auth-head {
    margin-bottom: 22px;
}

.auth-head h2 {
    margin: 0 0 8px;
    font-size: 30px;
    letter-spacing: -0.02em;
}

.auth-head p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.auth-tabs,
.main-tabs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.auth-tabs {
    margin-bottom: 22px;
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 6px;
}

.main-tabs {
    margin-bottom: 10px;
}

.auth-tab,
.main-tab,
button {
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    padding: 12px 16px;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 700;
    font-size: 14px;
    transition: 0.18s ease;
}

.auth-tab {
    flex: 1;
    border: none;
    background: transparent;
    text-align: center;
}

.auth-tab.active {
    background: #fff;
    color: var(--primary);
    box-shadow: var(--shadow-soft);
}

.main-tab.active {
    background: var(--primary-soft);
    color: var(--primary);
    border-color: #bfd4ff;
}

button:hover,
.main-tab:hover,
.auth-tab:hover,
.link-btn:hover {
    transform: translateY(-1px);
}

button.primary {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
    border-color: #1d4ed8;
    box-shadow: 0 12px 28px rgba(29, 78, 216, 0.24);
}

button.danger {
    background: #b91c1c;
    color: #fff;
    border-color: #b91c1c;
}

button.ghost {
    background: #fff;
    color: var(--muted);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.stack {
    display: grid;
    gap: 14px;
}

.field-group {
    display: grid;
    gap: 6px;
}

label {
    font-size: 13px;
    font-weight: 700;
    color: var(--muted);
    display: block;
}

input {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 14px 15px;
    font: inherit;
    background: #fff;
    color: var(--text);
    outline: none;
    transition: 0.18s ease;
}

input:focus {
    border-color: #9ec0ff;
    box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.08);
}

.hint,
.message,
.inline-note {
    font-size: 13px;
    line-height: 1.6;
    color: var(--muted);
}

.message {
    min-height: 22px;
    margin-top: 10px;
    font-weight: 700;
}

.message.error {
    color: var(--danger);
}

.message.success {
    color: var(--success);
}

.message.warning {
    color: var(--warning);
}

.inline-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 2px;
}

.link-btn {
    border: none;
    background: transparent;
    color: var(--primary);
    padding: 0;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.portal-shell {
    min-height: calc(100vh - 56px);
    display: flex;
    flex-direction: column;
}

.portal-topbar {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 12px 16px;
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(10px);
    overflow: visible;
    min-height: 92px;
}

.title-wrap h2 {
    margin: 0 0 6px;
    font-size: 28px;
    letter-spacing: -0.02em;
}

.title-wrap p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.user-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.settings-menu {
    position: relative;
}

.settings-icon-btn {
    width: 44px;
    height: 44px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    border-radius: 999px;
}

.settings-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 270px;
    display: none;
    gap: 4px;
    padding: 7px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    z-index: 50;
}

.settings-menu.open .settings-dropdown {
    display: grid;
}

.settings-dropdown button {
    width: 100%;
    text-align: left;
    box-shadow: none;
    border-radius: 12px;
    background: #fff;
}

.settings-dropdown button:hover {
    background: #f8fafc;
}

.settings-dropdown button.danger-link {
    color: var(--danger);
    border-color: #fecaca;
    background: #fff5f5;
}

.settings-separator {
    height: 1px;
    background: var(--line);
    margin: 4px 0;
}

.drive-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.48);
    backdrop-filter: blur(4px);
    z-index: 9000;
}

.drive-modal.open {
    display: flex;
}

.drive-modal-card {
    width: min(920px, 100%);
    max-height: min(720px, calc(100vh - 48px));
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

.drive-modal-head {
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.drive-modal-head h3 {
    margin: 0 0 6px;
    font-size: 22px;
}

.drive-modal-head p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
    font-size: 13px;
}

.drive-modal-body {
    padding: 16px 20px 20px;
    overflow: auto;
    display: grid;
    gap: 12px;
}

.hidden-drive-list {
    display: grid;
    gap: 10px;
}

.hidden-drive-item {
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
    background: #fff;
}

.hidden-drive-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.hidden-drive-actions .danger {
    background: var(--danger);
    color: #fff;
    border-color: var(--danger);
}

.hidden-drive-name {
    font-weight: 800;
    word-break: break-word;
}

.hidden-drive-meta {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
    margin-top: 4px;
}

.user-pill {
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 11px 14px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
}

.workspace {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--line);
    border-radius: 28px;
    box-shadow: var(--shadow);
    overflow: hidden;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.workspace-head {
    display: none;
}

.tab-panel {
    display: none;
    flex: 1;
    min-height: 0;
}

.tab-panel.active {
    display: flex;
}

iframe {
    width: 100%;
    height: 3000px;
    border: none;
    display: block;
    background: white;
}

@media (max-width: 1150px) {
    .auth-layout {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 700px) {
    .app {
        padding: 14px;
    }

    .showcase,
    .auth-card,
    .workspace,
    .portal-topbar {
        border-radius: 22px;
    }

    .brand h1 {
        font-size: 34px;
    }

    .auth-head h2 {
        font-size: 26px;
    }

    .title-wrap h2 {
        font-size: 24px;
    }
}

.backup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.52);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.backup-overlay.active {
    display: flex;
}

.backup-overlay-card {
    width: min(520px, 100%);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 26px;
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.24);
    padding: 28px;
    text-align: center;
}

.backup-spinner {
    width: 44px;
    height: 44px;
    margin: 0 auto 16px;
    border: 4px solid #dbeafe;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: backupSpin 0.9s linear infinite;
}

@keyframes backupSpin {
    to {
        transform: rotate(360deg);
    }
}

.backup-overlay-card h3 {
    margin: 0 0 8px;
    font-size: 24px;
}

.backup-overlay-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
    font-weight: 700;
}

.backup-actions-panel {
    display: grid;
    grid-template-columns: repeat(2, minmax(220px, 1fr));
    gap: 18px;
    padding: 24px;
    width: 100%;
}

.backup-action-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 22px;
    box-shadow: var(--shadow-soft);
    display: grid;
    gap: 12px;
    align-content: start;
}

.backup-action-card h3 {
    margin: 0;
    font-size: 22px;
}

.backup-action-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

@media (max-width: 700px) {
    .backup-actions-panel {
        grid-template-columns: 1fr;
    }
}

.subscription-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(4px);
    z-index: 10000;
}

.subscription-modal.open {
    display: flex;
}

.subscription-modal {
    padding: 14px;
    background: rgba(15, 23, 42, 0.46);
}

.subscription-modal-card {
    width: min(500px, 100%);
    max-height: calc(100vh - 28px);
    overflow-y: auto;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: var(--shadow);
    padding: 18px;
}

.subscription-modal-card h3 {
    margin: 0 0 8px;
    font-size: 22px;
}

.subscription-modal-card p {
    color: var(--muted);
    line-height: 1.45;
    margin: 6px 0;
}

.subscription-plans {
    display: grid;
    gap: 8px;
    margin: 12px 0;
}

.subscription-plans div {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 13px;
    background: #f8fafc;
}

.subscription-payment {
    padding: 12px;
    border-radius: 14px;
    background: var(--primary-soft);
    border: 1px solid #bfd4ff;
    margin-bottom: 12px;
}

.subscription-payment p {
    margin: 3px 0;
    color: var(--text);
}

.subscription-extra {
    margin-top: 10px;
    padding: 12px;
    border-radius: 13px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #9a3412;
    line-height: 1.45;
    font-size: 13px;
}

@media (max-width: 700px) {
    .subscription-modal {
        padding: 10px;
        align-items: flex-start;
    }

    .subscription-modal-card {
        width: 100%;
        max-height: calc(100vh - 20px);
        padding: 14px;
        border-radius: 18px;
    }

    .subscription-modal-card h3 {
        font-size: 20px;
    }
}

/* Tri des fichiers Drive cachés */
.hidden-drive-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #f8fafc;
}

.hidden-drive-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid transparent;
    background: transparent;
    box-shadow: none;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

.hidden-drive-tab:hover {
    background: #fff;
    border-color: var(--line);
    transform: none;
}

.hidden-drive-tab.active {
    background: #fff;
    border-color: #bfd4ff;
    color: var(--primary);
    box-shadow: var(--shadow-soft);
}

.hidden-drive-tab strong {
    min-width: 22px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eef2ff;
    color: var(--primary);
    font-size: 12px;
    line-height: 1;
}

.hidden-drive-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

.hidden-drive-category-badge {
    display: inline-flex;
    align-items: center;
    border: 1px solid #dbeafe;
    background: #eff6ff;
    color: var(--primary);
    border-radius: 999px;
    padding: 3px 8px;
    font-size: 11px;
    font-weight: 800;
}

.hidden-drive-empty {
    border: 1px dashed var(--line);
    border-radius: 16px;
    padding: 18px;
    color: var(--muted);
    background: #f8fafc;
    text-align: center;
}

.icon-btn {
    width: 46px;
    height: 46px;
    padding: 0;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

@media (max-width: 700px) {
    .hidden-drive-tabs {
        flex-direction: column;
        align-items: stretch;
    }

    .hidden-drive-tab {
        justify-content: space-between;
        width: 100%;
    }
}

.topbar-logo {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 1;
}

.topbar-logo img {
    max-height: 64px;
    width: auto;
    object-fit: contain;
    display: block;
}

.main-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.tab-icon {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.tab-icon-devis {
    background: #e0f2fe;
}

.tab-icon-compta {
    background: #dcfce7;
}

.tab-icon-client {
    background: #ffedd5;
}

.tab-icon-impots {
    background: #f3e8ff;
}

/* ================================
   Correctif responsive mobile BastCompta
   ================================ */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    .app {
        max-width: none;
        width: 100%;
        padding: 8px;
    }

    .portal-shell {
        min-height: 100vh;
    }

    .portal-topbar {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 10px;
        min-height: 0;
        border-radius: 20px;
    }

    .topbar-logo {
        position: static;
        transform: none;
        order: -1;
        width: 100%;
        pointer-events: auto;
        margin-bottom: 2px;
    }

    .topbar-logo img {
        max-height: 48px;
        margin: 0 auto;
    }

    .main-tabs {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 0;
    }

    .main-tab {
        width: 100%;
        min-width: 0;
        justify-content: flex-start;
        padding: 10px;
        border-radius: 16px;
        font-size: 14px;
        gap: 8px;
    }

    .main-tab span:last-child {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .tab-icon {
        width: 30px;
        height: 30px;
        min-width: 30px;
        font-size: 16px;
    }

    .user-actions {
        width: 100%;
        justify-content: space-between;
        gap: 8px;
    }

    .user-pill {
        flex: 1;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        text-align: center;
        padding: 10px 12px;
    }

    .icon-btn,
    .settings-icon-btn {
        width: 42px;
        height: 42px;
        min-width: 42px;
    }

    .settings-dropdown {
        right: 0;
        left: auto;
        min-width: min(320px, calc(100vw - 24px));
        max-width: calc(100vw - 24px);
    }

    .workspace {
        border-radius: 18px;
        min-height: 0;
    }

    iframe {
        width: 100%;
        height: 2200px;
        min-height: 100vh;
    }

    .auth-layout {
        grid-template-columns: 1fr;
        gap: 14px;
        min-height: auto;
    }

    .showcase,
    .auth-card {
        padding: 18px;
        border-radius: 22px;
    }

    .feature-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
}

@media (max-width: 420px) {
    .main-tabs {
        grid-template-columns: 1fr;
    }

    .main-tab {
        justify-content: flex-start;
    }
}


/* ================================
   Centre d'aide BastCompta
   ================================ */

.help-center-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.52);
    backdrop-filter: blur(4px);
    z-index: 9500;
}

.help-center-modal.open {
    display: flex;
}

.help-center-card {
    width: min(1320px, 100%);
    height: min(820px, calc(100vh - 48px));
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 26px;
    box-shadow: 0 30px 90px rgba(15, 23, 42, 0.25);
    display: grid;
    grid-template-columns: 310px 1fr;
    overflow: hidden;
}

.help-center-sidebar {
    background: linear-gradient(180deg, #f8fafc 0%, #eef4fb 100%);
    border-right: 1px solid var(--line);
    padding: 18px;
    overflow: auto;
}

.help-center-head h3 {
    margin: 0 0 6px;
    font-size: 22px;
}

.help-center-head p {
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
}

.help-search-wrap {
    display: grid;
    gap: 6px;
    margin-bottom: 14px;
}

#helpSearchInput {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 13px;
    font: inherit;
    background: #fff;
}

.help-search-count {
    min-height: 18px;
    color: var(--muted);
    font-size: 12px;
}

.help-tabs {
    display: grid;
    gap: 8px;
}

.help-tab {
    width: 100%;
    text-align: left;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    padding: 12px 13px;
    border-radius: 13px;
    cursor: pointer;
    font-weight: 800;
    box-shadow: none;
}

.help-tab:hover {
    transform: none;
    border-color: #bfd4ff;
}

.help-tab.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

.help-center-content {
    overflow: auto;
    padding: 24px 28px 34px;
    background: #fff;
}

.help-content-top {
    position: sticky;
    top: -24px;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 18px 0 16px;
    margin-top: -24px;
    background: rgba(255,255,255,.96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(8px);
}

.help-content-top h2 {
    margin: 0 0 6px;
    font-size: 30px;
    letter-spacing: -0.03em;
}

.help-content-top p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.help-close-btn {
    flex-shrink: 0;
}

.help-page {
    display: none;
    padding-top: 18px;
}

.help-page.active {
    display: grid;
    gap: 16px;
}

.help-center-modal.searching .help-page {
    display: grid;
    gap: 16px;
}

.help-article {
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 18px;
    background: #fff;
    line-height: 1.65;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.help-article h3 {
    margin: 0 0 10px;
    font-size: 20px;
}

.help-article p {
    margin: 0 0 10px;
}

.help-article p:last-child {
    margin-bottom: 0;
}

.help-article ul,
.help-article ol {
    margin: 8px 0 10px;
    padding-left: 22px;
}

.help-article li {
    margin-bottom: 6px;
}

.help-article mark {
    background: #fef3c7;
    color: inherit;
    padding: 0 2px;
    border-radius: 3px;
}

.help-article.hidden-by-search,
.help-page.hidden-by-search {
    display: none !important;
}

@media (max-width: 900px) {
    .help-center-card {
        grid-template-columns: 1fr;
        height: calc(100vh - 32px);
    }

    .help-center-sidebar {
        max-height: 310px;
        border-right: none;
        border-bottom: 1px solid var(--line);
    }

    .help-center-content {
        padding: 18px;
    }

    .help-content-top {
        top: -18px;
        margin-top: -18px;
    }
}


/* ================================
   Modal abonnement compact sans scroll
   ================================ */

.subscription-modal {
    padding: 12px !important;
    align-items: center !important;
}

.subscription-modal-card {
    width: min(880px, 96vw) !important;
    max-height: calc(100vh - 24px) !important;
    overflow: hidden !important;
    padding: 16px !important;
    border-radius: 20px !important;
    font-size: 14px !important;
}

.subscription-modal-card h3 {
    margin: 0 0 6px !important;
    font-size: 19px !important;
    line-height: 1.2 !important;
}

.subscription-modal-card p {
    margin: 4px 0 !important;
    font-size: 14px !important;
    line-height: 1.35 !important;
}

.subscription-modal-card button {
    padding: 10px 14px !important;
    font-size: 14px !important;
}

.subscription-modal-card > div:first-child {
    display: grid !important;
    grid-template-columns: 1fr 350px !important;
    gap: 16px !important;
    align-items: start !important;
}

.subscription-status-card,
.subscription-status-box {
    padding: 12px 14px !important;
    min-height: 0 !important;
}

.subscription-status-card h3,
.subscription-status-box h3 {
    font-size: 18px !important;
    margin-bottom: 6px !important;
}

.subscription-trial,
.trial-card {
    padding: 12px 14px !important;
    margin: 10px 0 !important;
}

.subscription-extra {
    margin-top: 8px !important;
    padding: 10px 12px !important;
    font-size: 13px !important;
    line-height: 1.3 !important;
}

.subscription-plans {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 8px !important;
    margin: 10px 0 !important;
}

.subscription-plans div {
    padding: 9px 11px !important;
    border-radius: 12px !important;
    font-size: 14px !important;
}

.subscription-payment {
    padding: 10px 12px !important;
    margin-bottom: 0 !important;
    font-size: 13px !important;
    line-height: 1.3 !important;
}

@media (max-width: 760px) {
    .subscription-modal {
        align-items: flex-start !important;
    }

    .subscription-modal-card {
        width: 100% !important;
        max-height: calc(100vh - 20px) !important;
        overflow-y: auto !important;
        padding: 14px !important;
    }

    .subscription-modal-card > div:first-child {
        display: block !important;
    }

    .subscription-plans {
        grid-template-columns: 1fr !important;
    }
}
