@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: #e0e7ff;
    --accent: #3b82f6;
    --accent-glow: rgba(99, 102, 241, 0.25);
    --success: #10b981;
    --success-light: #d1fae5;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --bg-main: #0f172a;
    --bg-card: rgba(30, 41, 59, 0.7);
    --bg-card-hover: rgba(30, 41, 59, 0.9);
    --border-color: rgba(255, 255, 255, 0.1);
    --border-highlight: rgba(99, 102, 241, 0.4);

    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-inverse: #0f172a;
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-glow: 0 10px 30px -10px rgba(99, 102, 241, 0.3);
    --glass-backdrop: blur(16px);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    background-image: 
        radial-gradient(at 10% 20%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(59, 130, 246, 0.15) 0px, transparent 50%);
}

/* Header & Nav */
.navbar {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: var(--glass-backdrop);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 12px 0;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 24px;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 1.4rem;
    color: #fff;
    text-decoration: none;
    letter-spacing: -0.5px;
}

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

.logo-badge {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #fff;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    line-height: 1.2;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.credit-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid #10b981;
    color: #61f8bc;
    padding: 5px 14px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.credit-pill:hover {
    background: rgba(16, 185, 129, 0.28);
    transform: translateY(-1px);
    color: #fff;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.user-badge-header {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 0.82rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4px 12px;
    border-radius: 50px;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

html, body {
    max-width: 100vw;
    overflow-x: hidden;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* --- FIX: Modal em orientação paisagem (landscape) - Força scroll vertical --- */
@media (max-width: 956px) and (orientation: landscape) {
    #signerConfigModal:not([style*='display: none']) > div:first-of-type {
        overflow-y: auto !important;          /* Garante rolagem vertical mesmo em paisagem */
        max-height: calc(100vh - 30px) !important; /* Altura máxima baseada na altura disponível */
        scroll-behavior: smooth !important;   /* Rolagem suave */

        /* Padding ajustado para landscape */
        padding-top: 10px !important;
        padding-bottom: 10px !important;
        padding-left: 8px !important;
        padding-right: 8px !important;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 10px 0;
    }
    .nav-content {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }
    .logo-row {
        justify-content: center;
        text-align: center;
        width: 100%;
        margin: 0 auto;
    }
    .logo {
        justify-content: center;
        text-align: center;
        margin: 0 auto;
        width: 100%;
    }
    .nav-links {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        width: 100%;
    }
    .nav-link {
        width: 100% !important;
        justify-content: center !important;
        text-align: center !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        height: 42px !important;
        box-sizing: border-box;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        background: rgba(30, 41, 59, 0.6);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-sm);
        display: inline-flex;
        align-items: center;
    }
    .nav-link.active {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(59, 130, 246, 0.25)) !important;
        border-color: var(--primary) !important;
        color: #ffffff !important;
        font-weight: 700 !important;
        box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2);
    }
    .nav-btn-account {
        grid-column: span 2 !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        height: 42px !important;
        box-sizing: border-box;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .nav-btn-logout {
        grid-column: span 2 !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        height: 42px !important;
        box-sizing: border-box;
    }
    .credit-pill {
        grid-column: span 2 !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        height: 42px !important;
        box-sizing: border-box;
    }
    .lang-selector-wrapper {
        grid-column: span 2 !important;
        width: 100% !important;
        margin: 0 !important;
        display: flex !important;
        height: 42px !important;
    }
    .lang-selector-select {
        width: 100% !important;
        height: 100% !important;
        text-align: center;
        text-align-last: center;
        font-size: 0.82rem !important;
        padding: 0 8px !important;
        border-radius: var(--radius-sm) !important;
        background: rgba(30, 41, 59, 0.8) !important;
        border: 1px solid var(--border-color) !important;
        color: #f8fafc !important;
        outline: none;
        cursor: pointer;
        appearance: auto;
    }
    .signer-header-actions {
        display: flex !important;
        flex-direction: column !important;
        gap: 8px !important;
        width: 100% !important;
        margin-top: 10px;
    }
    .signer-header-actions .btn {
        width: 100% !important;
        padding: 12px 16px !important;
        font-size: 0.88rem !important;
        justify-content: center !important;
    }
    .submit-btn-wrapper {
        width: 100% !important;
        text-align: center !important;
    }
    .submit-btn-wrapper .btn {
        width: 100% !important;
    }
    .container {
        padding: 0 12px;
        width: 100%;
        max-width: 100%;
    }
    .hero {
        padding: 24px 0 16px;
    }
    .hero-title {
        font-size: 1.6rem !important;
        line-height: 1.3;
        margin-bottom: 12px;
    }
    .hero-subtitle {
        font-size: 0.95rem !important;
        margin-bottom: 20px;
    }
    .glass-card {
        padding: 16px 12px !important;
        margin-bottom: 24px !important;
        border-radius: var(--radius-md) !important;
        width: 100%;
        max-width: 100%;
    }
    .stepper {
        flex-direction: row;
        gap: 4px;
        margin-bottom: 20px;
        justify-content: space-around;
    }
    .stepper::before {
        display: none !important; /* Hide floating line on mobile */
    }
    .step-item {
        font-size: 0.7rem;
        text-align: center;
    }
    .step-number {
        width: 32px !important;
        height: 32px !important;
        font-size: 0.85rem !important;
    }
    .step-label {
        font-size: 0.7rem !important;
    }
    .pdf-positioner-container, .pdf-continuous-container {
        padding: 4px !important;
        max-width: 100% !important;
    }
    canvas.signature-pad {
        height: 170px !important;
    }
    .btn {
        width: 100%;
        padding: 12px 16px;
        font-size: 0.9rem;
    }
    .signer-grid {
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }
    .signer-card {
        padding: 14px !important;
    }
    .modal-card {
        padding: 16px !important;
        width: 96% !important;
        max-width: 96% !important;
    }

    /* --- FIX: Modal "Configurações da Assinatura" (signerConfigModal) - Mobile Overflow --- */
    /* Aplica rolagem interna em dispositivos móveis para conter o conteúdo longo do modal de configurações */
    #signerConfigModal:not([style*='display: none']) > div:first-of-type {
        overflow-y: auto;           /* Habilita rolagem vertical quando conteúdo excede altura disponível */
        max-height: 650px;          /* Altura máxima antes de ativar scroll (compensa header + footer do modal) */
        scroll-behavior: smooth;    /* Rolagem suave ao navegar entre opções */

        /* Ajuste fino de padding para compensar as barras de scroll iOS/safari */
        padding-top: 12px !important;
        padding-bottom: 12px !important;
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    /* Garante que elementos longos (selects multi, options) não causem overflow de texto */
    #signerConfigModal > div:first-of-type
        select[multiple],
    #signerConfigModal > div:first-of-type option {
        min-width: auto;
        max-width: 100%;
        font-size: 1rem !important; /* Evita zoom automático no iOS quando o CSS muda */
    }

    .modal-config-header {
        display: grid !important;
        grid-template-columns: 1fr 32px !important;
    }

    /* Ajuste de espaçamento para labels longos em mobile (checkboxes/radios verticais) */
    #signerConfigModal > div:first-of-type
        label[style*='align-items: flex-start']
        div:not(.form-label) {
        line-height: 1.5;       /* Melhora legibilidade em telas pequenas */
        margin-bottom: 4px !important;
    }

    /* --- LAYOUT DO HEADER DO MODAL CONFIGURAÇÕES DA ASSINATURA (Mobile) --- */
    #signerConfigModal:not([style*='display: none']) > div:first-of-type .modal-header-title-container {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 0 !important;                  /* Remove gap para controle manual */
    }

    /* Título ocupa todo o espaço disponível à esquerda */
    #signerConfigModal:not([style*='display: none']) > div:first-of-type .modal-header-title-container h2,
    #signerConfigModal:not([style*='display: none']) > div:first-of-type .modal-header-title-container span,
    #signerConfigModal:not([style*='display: none']) > div:first-of-type .modal-header-title-container strong {
        flex-grow: 1 !important;           /* Título expande para ocupar espaço restante */
        margin-left: 0 !important;         /* Remove margem à esquerda */
        font-size: 1.25rem !important;     /* Mantém título legível */
        line-height: 1.3 !important;
        white-space: normal !important;    /* Permite wrap normal */
        min-width: 0 !important;           /* Permite que flex-grow funcione corretamente */
    }

    /* Botão de fechar com tamanho mínimo natural (apenas o conteúdo) */
    #signerConfigModal:not([style*='display: none']) > div:first-of-type .modal-header-title-container button {
        flex-shrink: 0 !important;         /* Botão não encolhe nem expande */
        width: auto !important;            /* Largura natural do conteúdo (apenas o ícone) */
        height: auto !important;
        min-width: 32px !important;        /* Mínimo para ícone ser visível */
        min-height: 32px !important;
        padding: 6px 10px !important;      /* Padding compacto para botão X */
        font-size: 1.2rem !important;      /* Tamanho do ícone ✖ */
        line-height: 1 !important;
        white-space: nowrap !important;    /* Mantém ícone em uma linha */
        margin-left: auto !important;      /* Empurra o botão para a direita */
    }

    /* --- FOOTER: BOTÕES EMPILHADOS NO MOBILE --- */
    #signerConfigModal:not([style*='display: none']) > div:last-of-type {
        flex-direction: column !important;    /* Empilha botões no mobile */
        align-items: stretch !important;       /* Botões com largura igual ao modal */
        gap: 8px !important;                   /* Espaçamento vertical */
        margin-top: 12px !important;
    }
    #signerConfigModal:not([style*='display: none']) > div:last-of-type .btn {
        width: 100% !important;                /* Botões full-width */
        padding: 12px 8px !important;          /* Ajuste de padding */
        font-size: 0.95rem !important;         /* Legibilidade mobile */
        margin: 0 !important;                  /* Remove margens extras */
    }

    .uploaded-file-card {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 14px !important;
        padding: 16px !important;
        text-align: left !important;
    }
    .uploaded-file-info {
        width: 100% !important;
        align-items: center !important;
    }
    .uploaded-file-name {
        font-size: 0.95rem !important;
        line-height: 1.3;
    }
    .change-file-btn {
        width: 100% !important;
        justify-content: center !important;
        margin-top: 4px;
    }
    .pos-page-nav-wrapper {
        display: flex !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        align-items: center !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 8px !important;
        margin-top: 8px !important;
    }
    .pos-page-nav-wrapper #posPageNumText {
        order: 1 !important;
        width: 100% !important;
        text-align: center !important;
        margin-bottom: 4px !important;
        font-size: 0.9rem !important;
        display: block !important;
    }
    .pos-page-nav-wrapper #posPrevPageBtn {
        order: 2 !important;
        flex: 1 1 calc(50% - 6px) !important;
        width: auto !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        margin: 0 !important;
    }
    .pos-page-nav-wrapper #posNextPageBtn {
        order: 3 !important;
        flex: 1 1 calc(50% - 6px) !important;
        width: auto !important;
        padding: 10px 6px !important;
        font-size: 0.82rem !important;
        justify-content: center !important;
        margin: 0 !important;
    }
    .pix-box {
        padding: 16px 8px !important;
        border: none !important;
        background: transparent !important;
    }
    .pix-header-badge {
        font-size: 0.76rem !important;
        padding: 6px 12px !important;
        white-space: normal !important;
        text-align: center !important;
        line-height: 1.3 !important;
    }
    .pix-socket-status {
        font-size: 0.78rem !important;
        margin-top: 8px !important;
    }
    .pix-box-title {
        font-size: 1.3rem !important;
        margin: 14px 0 6px !important;
    }
    .pix-price-summary {
        font-size: 0.9rem !important;
    }
    .pix-price-summary strong {
        font-size: 1.15rem !important;
    }
    .qr-code-container {
        margin: 14px auto !important;
    }
    .qr-code-img {
        width: 170px !important;
        height: 170px !important;
        padding: 8px !important;
    }
    .pix-payload-wrapper {
        margin-bottom: 16px !important;
    }
    .pix-payload-input {
        font-size: 0.75rem !important;
        padding: 8px !important;
    }
    .pix-copy-btn {
        padding: 12px 14px !important;
        font-size: 0.85rem !important;
    }
    .pix-footer-status {
        padding-top: 16px !important;
        margin-top: 16px !important;
    }
    .pix-waiting-badge {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        padding: 10px 12px !important;
        font-size: 0.8rem !important;
        border-radius: 12px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    .pad-header-row {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 8px !important;
        width: 100% !important;
        margin-bottom: 12px !important;
    }
    .pad-header-label {
        font-size: 0.88rem !important;
        line-height: 1.35 !important;
        width: 100% !important;
        text-align: left !important;
        margin-bottom: 0 !important;
    }
    .pad-clear-btn {
        width: 100% !important;
        padding: 10px 14px !important;
        font-size: 0.85rem !important;
        justify-content: center !important;
        text-align: center !important;
        display: flex !important;
        align-items: center !important;
    }
    .continuous-scroll-wrapper {
        padding: 8px 4px !important;
        border-radius: var(--radius-sm) !important;
        max-height: 520px !important;
    }
    .continuous-pdf-container {
        padding: 0 !important;
        width: 100% !important;
    }
    .lock-btn-wrapper {
        text-align: center !important;
        width: 100% !important;
    }
    .lock-sig-btn {
        width: 100% !important;
        padding: 14px !important;
        font-size: 0.95rem !important;
        justify-content: center !important;
    }
    .pkg-balance-box {
        width: 100% !important;
        text-align: center !important;
        padding: 16px 14px !important;
        margin-top: 16px !important;
        box-sizing: border-box !important;
    }
    .pkg-balance-label {
        font-size: 0.85rem !important;
        margin-bottom: 4px !important;
    }
    .pkg-balance-number {
        font-size: 2.6rem !important;
        margin: 4px 0 !important;
    }
    .pkg-balance-unit {
        font-size: 0.8rem !important;
    }
    .history-table, 
    .history-table thead, 
    .history-table tbody, 
    .history-table th, 
    .history-table td, 
    .history-table tr {
        display: block !important;
        width: 100% !important;
    }
    .history-table thead {
        display: none !important;
    }
    .history-table tbody tr {
        background: rgba(15, 23, 42, 0.7) !important;
        border: 1px solid rgba(255, 255, 255, 0.1) !important;
        border-radius: var(--radius-md) !important;
        padding: 16px !important;
        margin-bottom: 16px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
        box-sizing: border-box !important;
    }
    .history-table tbody tr:hover {
        background: rgba(30, 41, 59, 0.8) !important;
    }
    .history-table td {
        padding: 8px 0 !important;
        border-bottom: 1px dashed rgba(255, 255, 255, 0.08) !important;
        text-align: left !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 4px !important;
        box-sizing: border-box !important;
    }
    .history-table td:last-child {
        border-bottom: none !important;
        padding-bottom: 0 !important;
        margin-top: 4px !important;
    }
    .history-table td::before {
        content: attr(data-label) ":";
        font-size: 0.78rem !important;
        color: #a5b4fc !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.5px !important;
    }
    .history-actions-td {
        margin-top: 8px !important;
        padding-top: 12px !important;
        border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
    }
    .history-actions-wrapper {
        display: flex !important;
        flex-direction: row !important;
        gap: 8px !important;
        width: 100% !important;
    }
    .history-actions-wrapper .btn {
        flex: 1 !important;
        justify-content: center !important;
        padding: 10px !important;
        font-size: 0.82rem !important;
    }
    .pkg-history-heading {
        text-align: center !important;
    }
    .verify-doc-header {
        padding: 16px 14px !important;
        border-radius: var(--radius-sm) !important;
        margin-bottom: 20px !important;
    }
    .verify-doc-code {
        font-size: 0.75rem !important;
        padding: 6px 8px !important;
    }
    .verify-signer-card {
        padding: 14px 12px !important;
        margin-bottom: 14px !important;
    }
    .verify-signer-name {
        font-size: 1rem !important;
    }
    .verify-signer-email {
        font-size: 0.82rem !important;
    }
    .verify-signer-details {
        font-size: 0.82rem !important;
        gap: 10px !important;
    }
    .verify-signer-details div {
        padding-bottom: 6px;
        border-bottom: 1px dashed rgba(255, 255, 255, 0.06);
    }
    .verify-signer-details div:last-child {
        border-bottom: none;
        padding-bottom: 0;
    }
    .verify-download-wrapper {
        text-align: center !important;
        width: 100% !important;
    }
    .verify-download-btn {
        width: 100% !important;
        padding: 14px !important;
        justify-content: center !important;
    }
    .verify-input-group {
        flex-direction: column !important;
        width: 100% !important;
        gap: 12px !important;
    }
    .verify-submit-btn {
        width: 100% !important;
        padding: 14px !important;
        justify-content: center !important;
    }
    .logo-img {
        height: 28px !important;
        max-width: 120px !important;
    }
    .nav-links {
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
}

.nav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.88rem;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.nav-link.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(59, 130, 246, 0.25));
    border-color: var(--primary);
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.2);
    font-weight: 700;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 48px 0 32px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: #a5b4fc;
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.hero-title {
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
    background: linear-gradient(180deg, #ffffff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 680px;
    margin: 0 auto 32px;
    line-height: 1.6;
}

.price-pill {
    display: inline-block;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #6ee7b7;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 700;
}

/* Glass Card & Form */
.glass-card {
    background: var(--bg-card);
    backdrop-filter: var(--glass-backdrop);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    margin-bottom: 48px;
    transition: border-color 0.3s;
}

.glass-card:hover {
    border-color: var(--border-highlight);
}

/* Stepper */
.stepper {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    position: relative;
}

.stepper::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 40px;
    right: 40px;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    z-index: 1;
}

.step-item {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.step-number {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #1e293b;
    border: 2px solid #334155;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    transition: all 0.3s;
}

.step-item.active .step-number {
    background: var(--primary);
    border-color: #818cf8;
    color: #fff;
    box-shadow: var(--shadow-glow);
}

.step-item.completed .step-number {
    background: var(--success);
    border-color: #34d399;
    color: #fff;
}

.step-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

.step-item.active .step-label {
    color: #fff;
}

/* Upload Dropzone */
.dropzone {
    border: 2px dashed rgba(99, 102, 241, 0.4);
    background: rgba(15, 23, 42, 0.5);
    border-radius: var(--radius-md);
    padding: 48px 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.dropzone:hover, .dropzone.dragover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
}

.dropzone-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 16px;
}

.uploaded-file-card {
    background: rgba(30, 41, 59, 0.9);
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.uploaded-file-info {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    flex: 1;
}

.uploaded-file-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.uploaded-file-details {
    min-width: 0;
    flex: 1;
}

.uploaded-file-name {
    font-size: 1.05rem;
    color: #f8fafc;
    display: block;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.uploaded-file-size {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 2px;
}

.change-file-btn {
    padding: 10px 18px;
    font-size: 0.85rem;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Upload Progress Bar */
.upload-progress-card {
    background: rgba(30, 41, 59, 0.95);
    border: 1px solid rgba(99, 102, 241, 0.5);
    border-radius: var(--radius-md);
    padding: 22px 24px;
    margin-top: 16px;
    display: none;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.progress-filename {
    font-weight: 600;
    font-size: 0.95rem;
    color: #f8fafc;
    display: flex;
    align-items: center;
    gap: 8px;
}

.progress-percentage {
    font-weight: 700;
    font-size: 0.95rem;
    color: #818cf8;
}

.progress-bar-track {
    width: 100%;
    height: 10px;
    background: rgba(15, 23, 42, 0.8);
    border-radius: 999px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #6366f1 0%, #3b82f6 50%, #10b981 100%);
    border-radius: 999px;
    transition: width 0.15s ease-out;
}

.progress-status {
    font-size: 0.82rem;
    color: #94a3b8;
    margin-top: 10px;
    display: flex;
    justify-content: space-between;
}

/* Form Controls */
.form-group {
    margin-bottom: 24px;
}

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-main);
}

.form-control {
    width: 100%;
    padding: 14px 18px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: #fff;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.2s;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Signer Row */
.signer-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 16px;
    position: relative;
}

.signer-grid {
    display: grid;
    grid-template-columns: 2.5fr 2.5fr 2fr auto;
    gap: 16px;
    align-items: center;
}

@media (max-width: 900px) {
    .signer-grid {
        grid-template-columns: 1fr;
    }
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;
    box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 35px -8px rgba(99, 102, 241, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
}

.btn-danger {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
    padding: 10px;
}

/* Package Balance Card */
.pkg-balance-box {
    text-align: center;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid #10b981;
    padding: 16px 24px;
    border-radius: var(--radius-md);
    min-width: 180px;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.15);
}

.pkg-balance-label {
    display: block;
    font-size: 0.85rem;
    color: #a5b4fc;
    font-weight: 600;
    margin-bottom: 2px;
}

.pkg-balance-number {
    font-size: 2.4rem;
    font-weight: 900;
    color: #61f8bc;
    line-height: 1.1;
    margin: 2px 0;
}

.pkg-balance-unit {
    font-size: 0.82rem;
    font-weight: 500;
    color: #94a3b8;
}

/* PIX Box */
.pix-box {
    text-align: center;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-md);
    padding: 32px;
}

.pix-header-badge {
    background: #10b981;
    font-size: 0.85rem;
    padding: 8px 16px;
}

.pix-socket-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
    color: #a5b4fc;
    font-size: 0.85rem;
    font-weight: 600;
}

.pix-pulse-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    background: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 10px #10b981;
    animation: pulse 1.5s infinite;
}

.pix-box-title {
    margin: 20px 0 8px;
    font-size: 1.8rem;
    color: #ffffff;
}

.pix-price-summary {
    color: var(--text-muted);
    font-size: 1rem;
}

.pix-price-summary strong {
    color: #61f8bc;
    font-size: 1.3rem;
}

.qr-code-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px auto;
}

.qr-code-img {
    width: 220px;
    height: 220px;
    display: block;
    margin: 0 auto;
    background: #fff;
    padding: 12px;
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.pix-payload-wrapper {
    max-width: 500px;
    margin: 0 auto 24px;
}

.pix-payload-input {
    font-family: monospace;
    font-size: 0.85rem;
    background: #090d16;
    color: #94a3b8;
    border: 1px solid #334155;
    border-radius: var(--radius-sm);
    padding: 12px;
    width: 100%;
    resize: none;
}

.pix-copy-btn {
    width: 100%;
    margin-top: 10px;
}

.pix-footer-status {
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    margin-top: 24px;
    text-align: center;
}

.pix-waiting-subtext {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 12px;
}

/* Signature Pad Header Row & Canvas */
.pad-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    gap: 12px;
}

.pad-header-label {
    margin-bottom: 0;
    font-weight: 700;
    color: #a5b4fc;
    font-size: 0.95rem;
}

.pad-clear-btn {
    font-size: 0.8rem;
    padding: 6px 14px;
    white-space: nowrap;
    flex-shrink: 0;
}

.signature-canvas-wrapper {
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 2px solid var(--border-highlight);
    overflow: hidden;
    position: relative;
    margin-bottom: 16px;
    width: 100%;
}

@keyframes pulse {
    0% { opacity: 0.4; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1.1); }
    100% { opacity: 0.4; transform: scale(0.95); }
}

canvas.signature-pad {
    width: 100%;
    height: 220px;
    display: block;
    cursor: crosshair;
}

/* Continuous PDF Scroll Viewer */
.continuous-scroll-wrapper {
    position: relative;
    overflow-y: auto;
    overflow-x: auto;
    text-align: center;
    max-height: 700px;
    background: #090d16;
    border-radius: var(--radius-md);
    padding: 24px;
    border: 1px solid var(--border-color);
    width: 100%;
    box-sizing: border-box;
}

.continuous-pdf-container {
    display: block;
    width: 100%;
    max-width: 850px;
    margin: 0 auto;
    text-align: center;
    box-sizing: border-box;
}

.pdf-page-block {
    margin: 0 auto 20px auto !important;
    position: relative;
    box-sizing: border-box;
    display: inline-block;
    max-width: 100% !important;
}

.pdf-page-block canvas {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
    border-radius: 4px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

/* Footer */
footer {
    margin-top: auto;
    padding: 32px 0;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* PIX Realtime Waiting Badge */
.pix-waiting-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: rgba(97, 248, 188, 0.1);
    border: 1px solid rgba(97, 248, 188, 0.35);
    color: #61f8bc;
    padding: 14px 28px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(97, 248, 188, 0.15);
}

.pix-spinner {
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    flex-shrink: 0;
    border: 2px solid rgba(97, 248, 188, 0.3);
    border-top-color: #61f8bc;
    border-radius: 50%;
    animation: pixSpin 0.8s linear infinite;
    box-sizing: border-box;
}

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

/* Mobile Responsive Optimizations */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    .hero-title {
        font-size: 1.7rem !important;
    }
    .summary-price-banner {
        flex-direction: column !important;
        align-items: stretch !important;
        text-align: center !important;
        padding: 16px !important;
        gap: 10px !important;
    }
    .summary-price-right {
        text-align: center !important;
        border-top: 1px dashed var(--border-color);
        padding-top: 10px;
    }
    .summary-price-banner #summaryTotalAmount {
        font-size: 1.8rem !important;
    }
    #positionerModal {
        padding: 10px !important;
    }
    #positionerModal > div {
        padding: 14px !important;
        border-radius: var(--radius-md) !important;
    }
    .pdf-positioner-container {
        padding: 6px !important;
        max-height: 420px !important;
    }
    .placed-tag-badge {
        font-size: 0.65rem !important;
        padding: 3px 6px 3px 8px !important;
        max-width: 160px !important;
        border-width: 1px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 4px !important;
        box-sizing: border-box !important;
    }
    .proc-card {
        padding: 16px !important;
    }
    .proc-card-header {
        flex-direction: column !important;
        align-items: stretch !important;
    }
    .proc-card-actions {
        text-align: left !important;
        margin-top: 12px !important;
    }
    .proc-card-actions > div {
        justify-content: flex-start !important;
    }
    .proc-card-actions .btn, .proc-card-actions a {
        flex: 1 1 auto;
        text-align: center;
        justify-content: center;
    }
}

/* History Table Base & Mobile Card Layout */
.history-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.history-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    text-align: left;
}

.history-table th {
    background: rgba(15, 23, 42, 0.6);
    color: #94a3b8;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

.history-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.9rem;
    color: #f8fafc;
    vertical-align: middle;
}

.history-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.history-actions-td {
    white-space: nowrap;
    text-align: right;
}

.history-actions-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

@media (max-width: 640px) {
    .history-table-wrapper {
        overflow-x: visible;
    }

    .history-table, 
    .history-table thead, 
    .history-table tbody, 
    .history-table th, 
    .history-table td, 
    .history-table tr {
        display: block;
    }

    .history-table thead {
        display: none;
    }

    .history-table tr {
        background: rgba(15, 23, 42, 0.85);
        border: 1px solid rgba(99, 102, 241, 0.25);
        border-radius: var(--radius-md);
        margin-bottom: 16px;
        padding: 16px;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    }

    .history-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 0;
        border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
        font-size: 0.88rem;
        text-align: right;
    }

    .history-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #94a3b8;
        font-size: 0.78rem;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        text-align: left;
        margin-right: 12px;
    }

    .history-table td.history-actions-td {
        border-bottom: none;
        display: block !important;
        margin-top: 10px;
        padding-top: 12px;
        text-align: center;
    }

    .history-table td.history-actions-td::before {
        display: none;
    }

    .history-actions-wrapper {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 10px !important;
    }

    .history-actions-wrapper button,
    .history-table td.history-actions-td button {
        width: 100% !important;
        margin: 0 !important;
        justify-content: center !important;
        padding: 10px 16px !important;
        font-size: 0.85rem !important;
        display: flex !important;
        align-items: center !important;
    }

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

/* Audit Verification Details Components */
.verify-doc-header {
    border-left: 4px solid #10b981;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 20px 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.verify-doc-item {
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.verify-doc-item:last-child {
    margin-bottom: 0;
}

.verify-doc-label {
    font-size: 0.82rem;
    color: #a5b4fc;
    font-weight: 600;
}

.verify-doc-code {
    font-family: monospace;
    font-size: 0.82rem;
    background: #090d16;
    color: #94a3b8;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    border: 1px solid #334155;
    word-break: break-all;
    overflow-wrap: anywhere;
    display: block;
}

.verify-signer-card {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    margin-bottom: 16px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.verify-signer-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
}

.verify-signer-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: #ffffff;
    word-break: break-word;
}

.verify-signer-email {
    font-size: 0.88rem;
    color: #a5b4fc;
    word-break: break-word;
}

.verify-signer-status {
    margin-top: 4px;
}

.verify-signer-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 0.85rem;
    color: #94a3b8;
}

.verify-signer-details div {
    display: flex;
    flex-direction: column;
    gap: 2px;
    word-break: break-word;
}

.verify-signer-details strong {
    color: #cbd5e1;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.verify-cert-info {
    font-size: 0.8rem;
    color: #10b981 !important;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    margin-top: 6px;
}

.verify-download-wrapper {
    margin-top: 24px;
    text-align: right;
}

.verify-download-btn {
    padding: 14px 28px;
    font-size: 0.95rem;
}

.verify-input-group {
    display: flex;
    gap: 12px;
    align-items: center;
}

.verify-submit-btn {
    white-space: nowrap;
    padding: 12px 24px;
}

.remove-signer-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
    font-size: 1.1rem !important;
    line-height: 1 !important;
    text-align: center !important;
    box-sizing: border-box !important;
}

/* Placed Tag Badges in PDF Positioner */
.placed-tag-badge {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 6px !important;
    box-sizing: border-box !important;
}

.placed-tag-badge .tag-label-text {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

.placed-tag-badge .remove-tag-btn {
    flex-shrink: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    min-height: 18px !important;
    border-radius: 50% !important;
    background: rgba(0, 0, 0, 0.45) !important;
    color: #ffffff !important;
    cursor: pointer !important;
    user-select: none !important;
    line-height: 1 !important;
    font-size: 0.65rem !important;
    transition: background-color 0.15s ease, transform 0.15s ease !important;
}

.placed-tag-badge .remove-tag-btn:hover {
    background: rgba(239, 68, 68, 0.9) !important;
    transform: scale(1.15) !important;
}

/* ==========================================================================
   Stylized Tutorial Inline Helper Button
   ========================================================================== */
.tutorial-inline-trigger-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.16) 0%, rgba(59, 130, 246, 0.18) 100%);
    border: 1.5px solid rgba(99, 102, 241, 0.45);
    border-radius: 50px;
    padding: 6px 14px 6px 8px;
    color: #c7d2fe;
    font-size: 0.84rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3), 0 0 16px rgba(99, 102, 241, 0.18);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    user-select: none;
}

.tutorial-inline-trigger-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.22), transparent);
    transition: left 0.6s ease;
}

.tutorial-inline-trigger-btn:hover::before {
    left: 100%;
}

.tutorial-inline-trigger-btn:hover {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.32) 0%, rgba(59, 130, 246, 0.32) 100%);
    border-color: #818cf8;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5), 0 0 25px rgba(99, 102, 241, 0.35);
}

.tutorial-inline-trigger-btn:active {
    transform: translateY(0);
}

.tutorial-trigger-icon-pulse {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.7);
    flex-shrink: 0;
    position: relative;
}

.tutorial-trigger-icon-pulse::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1.5px solid rgba(99, 102, 241, 0.8);
    animation: tutorialTriggerGlow 2s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
}

@keyframes tutorialTriggerGlow {
    0% { transform: scale(0.9); opacity: 0.9; }
    60% { transform: scale(1.35); opacity: 0; }
    100% { transform: scale(1.35); opacity: 0; }
}

.tutorial-trigger-tag {
    font-size: 0.68rem;
    font-weight: 700;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.15);
    border: 1px solid rgba(56, 189, 248, 0.35);
    padding: 2px 7px;
    border-radius: 20px;
    margin-left: 2px;
}

/* ==========================================================================
   Video Tutorials Modal & Cards System
   ========================================================================== */
.tutorial-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    max-width: 100vw;
    background: rgba(10, 15, 30, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    padding: 20px;
    box-sizing: border-box;
    overflow-x: hidden;
    animation: fadeInTutorial 0.25s ease-out;
}

@keyframes fadeInTutorial {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tutorial-modal-container {
    background: #0f172a;
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 820px;
    max-height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 22px 24px;
    box-sizing: border-box;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), 0 0 30px rgba(99, 102, 241, 0.2);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tutorial-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 12px;
    width: 100%;
    box-sizing: border-box;
}

.tutorial-modal-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.tutorial-modal-icon {
    font-size: 1.6rem;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 12px;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.tutorial-modal-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
    margin: 0;
}

.tutorial-modal-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin: 3px 0 0 0;
}

.tutorial-modal-close-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #94a3b8;
    font-size: 1.1rem;
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.tutorial-modal-close-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.4);
    color: #ef4444;
    transform: rotate(90deg);
}

/* Clean Segmented Tab Control (No Horizontal Overflow) */
.tutorial-tabs-bar {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
    background: rgba(15, 23, 42, 0.6);
    padding: 4px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.tutorial-tab-btn {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 10px 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    min-width: 0;
    box-sizing: border-box;
    color: #94a3b8;
}

.tutorial-tab-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
}

.tutorial-tab-btn.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.35), rgba(59, 130, 246, 0.3));
    border-color: #6366f1;
    color: #fff;
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.35);
}

.tutorial-tab-icon {
    font-size: 1.15rem;
    flex-shrink: 0;
    line-height: 1;
}

.tutorial-tab-label {
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tutorial-tab-btn.active .tutorial-tab-label {
    color: #fff;
}

.tutorial-tab-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* ==========================================================================
   Custom Stylized Video Player (JaSign Glass Player)
   ========================================================================== */
.jp-player-wrapper {
    position: relative;
    background: #020617;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(99, 102, 241, 0.4);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.7), 0 0 30px rgba(99, 102, 241, 0.2);
    width: 100%;
    min-height: 380px;
    height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    flex-shrink: 0;
    box-sizing: border-box;
}

.jp-player-wrapper:hover {
    border-color: rgba(99, 102, 241, 0.6);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 35px rgba(99, 102, 241, 0.3);
}

.jp-player-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
    cursor: pointer;
    display: block;
}

/* Big Center Play Button */
.jp-center-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(1);
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.95), rgba(59, 130, 246, 0.95));
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 2px solid rgba(255, 255, 255, 0.45);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.6), inset 0 0 15px rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.jp-center-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #fff;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}

.jp-center-play-btn:hover {
    transform: translate(-50%, -50%) scale(1.12);
    background: linear-gradient(135deg, #6366f1, #3b82f6);
    box-shadow: 0 14px 40px rgba(99, 102, 241, 0.8), inset 0 0 20px rgba(255, 255, 255, 0.5);
    border-color: #fff;
}

.jp-center-icon-pulse {
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid rgba(99, 102, 241, 0.6);
    animation: jpPulseRing 2s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
}

@keyframes jpPulseRing {
    0% { transform: scale(0.9); opacity: 0.8; }
    50% { transform: scale(1.2); opacity: 0; }
    100% { transform: scale(1.2); opacity: 0; }
}

.jp-player-wrapper.playing .jp-center-play-btn {
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, -50%) scale(0.75);
}

/* Feedback Ripple Animation on click */
.jp-feedback-ripple {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.6);
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(99, 102, 241, 0.5);
    color: #fff;
    padding: 12px 20px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    pointer-events: none;
    opacity: 0;
    z-index: 12;
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.jp-feedback-ripple.animate {
    animation: jpRipplePop 0.6s ease-out forwards;
}

@keyframes jpRipplePop {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0.5); }
    30% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
    70% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
}

/* End / Replay Screen Overlay */
.jp-end-overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 15, 30, 0.88);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 15;
    animation: fadeInTutorial 0.3s ease;
}

.jp-end-card {
    background: rgba(30, 41, 59, 0.85);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: var(--radius-md);
    padding: 24px 32px;
    text-align: center;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    max-width: 380px;
}

.jp-end-sparkle {
    font-size: 2.2rem;
    display: block;
    margin-bottom: 8px;
}

.jp-end-card h4 {
    font-size: 1.3rem;
    color: #fff;
    margin-bottom: 6px;
}

.jp-end-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 18px;
}

.jp-replay-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    padding: 10px 22px;
}

/* Custom Controls Bar */
.jp-controls-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.98) 0%, rgba(15, 23, 42, 0.75) 60%, transparent 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 18px 18px 10px 18px;
    z-index: 11;
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
}

.jp-player-wrapper.show-controls .jp-controls-bar,
.jp-player-wrapper.paused .jp-controls-bar {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Scrubber / Progress Bar */
.jp-progress-track {
    position: relative;
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.16);
    border-radius: 6px;
    cursor: pointer;
    transition: height 0.15s ease;
}

.jp-progress-track:hover {
    height: 9px;
}

.jp-progress-buffered {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    pointer-events: none;
    transition: width 0.2s linear;
}

.jp-progress-filled {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #6366f1, #38bdf8);
    border-radius: 6px;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.6);
    pointer-events: none;
}

.jp-progress-handle {
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%) scale(0);
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid #6366f1;
    box-shadow: 0 0 10px #38bdf8;
    transition: transform 0.15s ease;
}

.jp-progress-track:hover .jp-progress-handle {
    transform: translateY(-50%) scale(1);
}

.jp-progress-tooltip {
    position: absolute;
    bottom: 16px;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(99, 102, 241, 0.4);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    font-family: monospace;
    padding: 3px 8px;
    border-radius: 6px;
    pointer-events: none;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.jp-progress-track:hover .jp-progress-tooltip {
    display: block;
}

/* Controls Row */
.jp-controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.jp-controls-left,
.jp-controls-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.jp-btn {
    background: transparent;
    border: none;
    color: #f8fafc;
    font-size: 1rem;
    padding: 6px 8px;
    border-radius: 8px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    line-height: 1;
}

.jp-btn svg {
    display: block;
}

.jp-btn:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    transform: scale(1.08);
}

.jp-btn:active {
    transform: scale(0.95);
}

.jp-play-toggle {
    width: 34px;
    height: 34px;
    padding: 0;
    color: #818cf8;
}

.jp-play-toggle:hover {
    color: #a5b4fc;
}

.jp-skip-btn {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    padding: 4px 8px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.jp-skip-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

/* Time display */
.jp-time-display {
    font-size: 0.78rem;
    font-family: monospace;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: rgba(0, 0, 0, 0.35);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.jp-time-divider {
    color: var(--text-muted);
}

/* Volume Cluster */
.jp-volume-cluster {
    display: flex;
    align-items: center;
    gap: 4px;
}

.jp-volume-slider-wrap {
    width: 0;
    overflow: hidden;
    transition: width 0.2s ease;
    display: flex;
    align-items: center;
}

.jp-volume-cluster:hover .jp-volume-slider-wrap {
    width: 65px;
}

.jp-volume-range {
    width: 60px;
    height: 4px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    outline: none;
    cursor: pointer;
}

.jp-volume-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #6366f1;
    border: 2px solid #fff;
    cursor: pointer;
}

/* Speed Selector Menu */
.jp-speed-selector-wrap {
    position: relative;
}

.jp-speed-btn {
    font-size: 0.78rem;
    font-weight: 700;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    color: #818cf8;
}

.jp-speed-menu {
    position: absolute;
    bottom: calc(100% + 8px);
    right: 0;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: 10px;
    padding: 6px;
    display: none;
    flex-direction: column;
    gap: 3px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    z-index: 20;
    min-width: 115px;
}

.jp-speed-menu.open {
    display: flex;
    animation: fadeInTutorial 0.15s ease-out;
}

.jp-speed-opt {
    background: transparent;
    border: none;
    color: #cbd5e1;
    padding: 6px 10px;
    font-size: 0.78rem;
    font-weight: 600;
    border-radius: 6px;
    text-align: left;
    cursor: pointer;
    transition: all 0.15s ease;
}

.jp-speed-opt:hover {
    background: rgba(99, 102, 241, 0.2);
    color: #fff;
}

.jp-speed-opt.active {
    background: #6366f1;
    color: #fff;
}

.tutorial-details-box {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tutorial-details-header {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.tutorial-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid #6366f1;
    color: #818cf8;
}

.tutorial-heading {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.tutorial-desc {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
}

.tutorial-points-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 4px;
}

.tutorial-point-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.85rem;
    color: #e2e8f0;
}

.tutorial-point-check {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 1px;
}

.tutorial-actions-row {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-wrap: wrap;
}

/* Quick Tutorial Section & Cards */
.tutorial-quick-section {
    margin: 24px 0 32px;
}

.tutorial-quick-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 10px;
}

.tutorial-quick-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tutorial-quick-header p {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.tutorial-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.tutorial-card {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.tutorial-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #6366f1, #3b82f6);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.tutorial-card:hover {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(99, 102, 241, 0.5);
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4), 0 0 20px rgba(99, 102, 241, 0.2);
}

.tutorial-card:hover::before {
    opacity: 1;
}

.tutorial-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.tutorial-card-icon-pill {
    font-size: 1.3rem;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    padding: 6px 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tutorial-card-duration {
    font-size: 0.72rem;
    font-weight: 700;
    color: #6ee7b7;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 3px 8px;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.tutorial-card-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
    line-height: 1.3;
}

.tutorial-card-desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin-bottom: 12px;
}

.tutorial-card-play-btn {
    font-size: 0.78rem;
    font-weight: 600;
    color: #818cf8;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.tutorial-card:hover .tutorial-card-play-btn {
    color: #a5b4fc;
    transform: translateX(4px);
}

/* ==========================================================================
   Mobile Responsive Optimizations for Tutorial Modal & Video Player
   ========================================================================== */
@media (max-width: 768px) {
    .tutorial-modal-overlay {
        padding: 10px;
        align-items: center;
        width: 100vw;
        max-width: 100vw;
        box-sizing: border-box;
        overflow-x: hidden;
    }

    .tutorial-modal-container {
        padding: 14px 14px 18px;
        max-height: 94vh;
        border-radius: 18px;
        gap: 12px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }

    .tutorial-modal-header {
        padding-bottom: 10px;
    }

    .tutorial-modal-icon {
        width: 36px;
        height: 36px;
        font-size: 1.2rem;
        border-radius: 10px;
    }

    .tutorial-modal-title {
        font-size: 1.05rem;
    }

    .tutorial-modal-subtitle {
        font-size: 0.72rem;
    }

    .tutorial-modal-close-btn {
        width: 34px;
        height: 34px;
        font-size: 0.95rem;
        flex-shrink: 0;
    }

    /* 3-Video Segment Control on Mobile */
    .tutorial-tabs-bar {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 4px;
        padding: 3px;
        border-radius: 12px;
        width: 100%;
        box-sizing: border-box;
    }

    .tutorial-tab-btn {
        padding: 8px 4px;
        border-radius: 8px;
        gap: 4px;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        text-align: center;
        min-width: 0;
        box-sizing: border-box;
    }

    .tutorial-tab-icon {
        font-size: 1rem;
        line-height: 1;
    }

    .tutorial-tab-label {
        font-size: 0.7rem;
        font-weight: 700;
        white-space: normal;
        line-height: 1.15;
        text-align: center;
        word-break: break-word;
    }

    /* Custom Player on Mobile */
    .jp-player-wrapper {
        border-radius: 12px;
        min-height: 240px;
        height: 260px;
        width: 100%;
        box-sizing: border-box;
        overflow: hidden;
        flex-shrink: 0;
    }

    .jp-center-play-btn {
        width: 54px;
        height: 54px;
    }

    .jp-controls-bar {
        padding: 10px 8px 6px 8px;
        gap: 4px;
        width: 100%;
        box-sizing: border-box;
        overflow: hidden;
    }

    .jp-controls-row {
        width: 100%;
        box-sizing: border-box;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 4px;
        min-width: 0;
    }

    .jp-controls-left,
    .jp-controls-right {
        display: flex;
        align-items: center;
        gap: 4px;
        min-width: 0;
        flex-shrink: 1;
    }

    .jp-progress-track {
        height: 8px;
        margin-bottom: 2px;
    }

    .jp-btn {
        padding: 4px 5px;
        font-size: 0.8rem;
    }

    .jp-skip-btn {
        display: none;
    }

    .jp-time-display {
        font-size: 0.68rem;
        padding: 2px 4px;
        gap: 2px;
    }

    .jp-volume-slider-wrap {
        display: none !important;
    }

    .jp-speed-btn {
        font-size: 0.7rem;
        padding: 2px 5px;
    }

    /* Details box & Action Buttons */
    .tutorial-details-box {
        padding: 12px 12px;
        gap: 8px;
        border-radius: 12px;
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }

    .tutorial-badge {
        font-size: 0.68rem;
        padding: 2px 8px;
    }

    .tutorial-heading {
        font-size: 0.92rem;
    }

    .tutorial-desc {
        font-size: 0.78rem;
        line-height: 1.35;
    }

    .tutorial-points-list {
        gap: 6px;
        width: 100%;
        box-sizing: border-box;
    }

    .tutorial-point-item {
        font-size: 0.76rem;
        gap: 6px;
    }

    .tutorial-point-check {
        width: 16px;
        height: 16px;
        font-size: 0.62rem;
    }

    .tutorial-actions-row {
        flex-direction: column-reverse;
        gap: 6px;
        margin-top: 4px;
        padding-top: 6px;
        width: 100%;
        box-sizing: border-box;
    }

    .tutorial-primary-btn,
    .tutorial-secondary-btn {
        width: 100% !important;
        justify-content: center;
        padding: 9px 12px;
        font-size: 0.85rem;
        box-sizing: border-box;
    }
}

@media (max-width: 480px) {
    .tutorial-modal-overlay {
        padding: 8px 4px;
    }

    .tutorial-modal-container {
        padding: 12px 10px 16px;
        max-height: 96vh;
    }

    .jp-player-wrapper {
        min-height: 210px;
        height: 230px;
    }
}

