/* Export to PDF modal. Reuses the shared .modal-overlay / .modal-overlay.active
   rules (defined in monthly-data-modal.css) for the backdrop + show/hide. */

.export-modal {
    background: white;
    border-radius: 14px;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

.export-modal__header {
    background: linear-gradient(135deg, #1F3D7C, #2a4d8f);
    color: white;
    padding: 1.1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.export-modal__header h2 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-family: 'Red Hat Display', sans-serif;
}

.export-modal__close {
    background: transparent;
    border: none;
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.2s ease;
    line-height: 1;
}

.export-modal__close:hover {
    opacity: 1;
}

.export-modal__subtitle {
    padding: 0.75rem 1.5rem 0;
    font-size: 0.8rem;
    color: var(--slate, #808FAD);
}

.export-modal__body {
    padding: 0.75rem 1.5rem 1rem;
    overflow-y: auto;
}

/* Checkbox rows */
.export-modal__item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 0.25rem;
    border-bottom: 1px solid var(--light-silver, #E3E4E9);
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--secondary-blue, #1F3D7C);
}

.export-modal__item:last-child {
    border-bottom: none;
}

.export-modal__item input {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--primary-blue, #0F9FC4);
}

.export-modal__item--all {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.78rem;
    color: var(--slate, #808FAD);
}

/* Not-yet-implemented views: muted + non-interactive, with a "coming soon" hint. */
.export-modal__item--disabled {
    cursor: not-allowed;
    color: var(--slate, #808FAD);
    opacity: 0.6;
}

.export-modal__item--disabled input {
    cursor: not-allowed;
}

.export-modal__soon {
    margin-left: auto;
    font-size: 0.7rem;
    font-style: italic;
    color: var(--slate, #808FAD);
}

.export-modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.6rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--light-silver, #E3E4E9);
}

.export-modal__btn {
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1.25rem;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    font-family: 'Red Hat Display', sans-serif;
    transition: all 0.2s ease;
}

.export-modal__btn--cancel {
    background: var(--off-white, #F7F7F8);
    color: var(--slate, #808FAD);
    border: 1px solid var(--light-silver, #E3E4E9);
}

.export-modal__btn--cancel:hover {
    background: #ececef;
}

.export-modal__btn--export {
    background: linear-gradient(135deg, var(--primary-blue, #0F9FC4), var(--secondary-blue, #1F3D7C));
    color: white;
}

.export-modal__btn--export:hover {
    box-shadow: 0 4px 12px rgba(15, 159, 196, 0.35);
}

.export-modal__btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ---- Export progress overlay (shown while the PDF is being generated) ---- */
.export-progress {
    position: fixed;
    inset: 0;
    z-index: 11000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 30, 60, 0.55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: exportFadeIn 0.2s ease;
}

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

.export-progress__card {
    background: #fff;
    border-radius: 16px;
    padding: 2rem 2.25rem;
    width: min(420px, 90vw);
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    font-family: 'Red Hat Display', sans-serif;
}

.export-progress__icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 1.6rem;
    color: #fff;
    background: linear-gradient(135deg, #0F9FC4, #1F3D7C);
    animation: exportPulse 1.4s ease-in-out infinite;
}

.export-progress__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1F3D7C;
}

.export-progress__sub {
    font-size: 0.8rem;
    color: #808FAD;
    margin-top: 0.25rem;
    min-height: 1.1em;
}

.export-progress__bar {
    margin-top: 1.1rem;
    height: 10px;
    border-radius: 999px;
    background: #E3E4E9;
    overflow: hidden;
}

.export-progress__fill {
    width: var(--pct, 0%);
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #0F9FC4, #1F3D7C);
    transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

/* moving shimmer along the filled portion */
.export-progress__fill::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55), transparent);
    animation: exportShimmer 1.2s linear infinite;
}

.export-progress__pct {
    margin-top: 0.6rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: #0F9FC4;
}

@keyframes exportPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(15, 159, 196, 0.45); }
    50% { transform: scale(1.06); box-shadow: 0 0 0 10px rgba(15, 159, 196, 0); }
}

@keyframes exportShimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}
