/* ==========================================================================
   INAIVOM - Modal
   File: app/static/css/modal.css
   Premium Matrimony Platform
   Theme: Maroon #800020 | Gold #D4AF37 | White
   ========================================================================== */


/* ==========================================================================
   1. MODAL VARIABLES
   ========================================================================== */

:root {
    --modal-maroon: #800020;
    --modal-maroon-dark: #650019;
    --modal-maroon-light: #9b1738;

    --modal-gold: #d4af37;
    --modal-gold-dark: #a9861d;
    --modal-gold-light: #ead77f;

    --modal-white: #ffffff;
    --modal-bg: #ffffff;
    --modal-bg-soft: #fdfafb;

    --modal-text: #2d282b;
    --modal-muted: #766e73;
    --modal-border: #ebe4e7;

    --modal-danger: #dc3545;
    --modal-success: #198754;
    --modal-warning: #d39e00;
    --modal-info: #0d6efd;

    --modal-radius: 16px;
    --modal-radius-lg: 20px;

    --modal-shadow:
        0 24px 70px rgba(29, 14, 20, 0.22);

    --modal-shadow-sm:
        0 14px 40px rgba(29, 14, 20, 0.16);

    --modal-transition:
        220ms cubic-bezier(0.4, 0, 0.2, 1);

    --modal-z-index: 1055;
    --modal-backdrop-z-index: 1050;
}


/* ==========================================================================
   2. BODY STATE
   ========================================================================== */

body.modal-open {
    overflow: hidden;

    padding-right: var(--modal-scrollbar-width, 0);
}


/* ==========================================================================
   3. MODAL BACKDROP
   ========================================================================== */

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: var(--modal-backdrop-z-index);

    width: 100vw;
    height: 100vh;

    background: rgba(24, 11, 16, 0.62);

    opacity: 0;
    visibility: hidden;

    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);

    transition:
        opacity var(--modal-transition),
        visibility var(--modal-transition);
}

.modal-backdrop.show {
    opacity: 1;
    visibility: visible;
}


/* Bootstrap compatibility */

.modal-backdrop.fade {
    opacity: 0;
}

.modal-backdrop.fade.show {
    opacity: 0.62;
}


/* ==========================================================================
   4. MODAL ROOT
   ========================================================================== */

.modal {
    position: fixed;
    inset: 0;
    z-index: var(--modal-z-index);

    display: none;

    width: 100%;
    height: 100%;

    overflow-x: hidden;
    overflow-y: auto;

    outline: 0;

    -webkit-overflow-scrolling: touch;
}

.modal.show {
    display: block;
}


/* ==========================================================================
   5. MODAL DIALOG
   ========================================================================== */

.modal-dialog {
    position: relative;

    width: auto;
    max-width: 560px;

    margin: 1.75rem auto;

    pointer-events: none;

    transform:
        translateY(18px)
        scale(0.985);

    opacity: 0;

    transition:
        transform var(--modal-transition),
        opacity var(--modal-transition);
}

.modal.show .modal-dialog {
    transform:
        translateY(0)
        scale(1);

    opacity: 1;
}


/* Bootstrap fade compatibility */

.modal.fade .modal-dialog {
    transform:
        translateY(20px)
        scale(0.985);

    transition:
        transform var(--modal-transition),
        opacity var(--modal-transition);
}

.modal.fade.show .modal-dialog {
    transform:
        translateY(0)
        scale(1);
}


/* ==========================================================================
   6. CENTERED MODAL
   ========================================================================== */

.modal-dialog-centered {
    display: flex;
    align-items: center;

    min-height: calc(100% - 3.5rem);
}


/* ==========================================================================
   7. SCROLLABLE MODAL
   ========================================================================== */

.modal-dialog-scrollable {
    height: calc(100% - 3.5rem);
}

.modal-dialog-scrollable .modal-content {
    max-height: 100%;

    overflow: hidden;
}

.modal-dialog-scrollable .modal-body {
    overflow-y: auto;

    overscroll-behavior: contain;
}


/* ==========================================================================
   8. MODAL CONTENT
   ========================================================================== */

.modal-content {
    position: relative;

    display: flex;
    flex-direction: column;

    width: 100%;

    overflow: hidden;

    border: 1px solid rgba(128, 0, 32, 0.08);
    border-radius: var(--modal-radius-lg);

    background:
        linear-gradient(
            180deg,
            #ffffff 0%,
            #fffefe 100%
        );

    color: var(--modal-text);

    box-shadow: var(--modal-shadow);

    pointer-events: auto;

    outline: 0;
}


/* ==========================================================================
   9. PREMIUM TOP ACCENT
   ========================================================================== */

.modal-content::before {
    content: "";

    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    z-index: 2;

    height: 3px;

    background:
        linear-gradient(
            90deg,
            transparent 0%,
            var(--modal-maroon) 24%,
            var(--modal-gold) 50%,
            var(--modal-maroon) 76%,
            transparent 100%
        );
}


/* ==========================================================================
   10. MODAL HEADER
   ========================================================================== */

.modal-header {
    position: relative;

    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 1rem;

    padding: 1.35rem 1.5rem 1.15rem;

    border-bottom: 1px solid var(--modal-border);

    background:
        linear-gradient(
            180deg,
            #ffffff,
            #fffdfd
        );
}

.modal-header-content {
    min-width: 0;

    flex: 1 1 auto;
}


/* ==========================================================================
   11. MODAL TITLE
   ========================================================================== */

.modal-title {
    margin: 0;

    color: var(--modal-maroon);

    font-size: 1.08rem;
    font-weight: 700;
    line-height: 1.35;
}

.modal-subtitle,
.modal-description {
    margin: 0.3rem 0 0;

    color: var(--modal-muted);

    font-size: 0.75rem;
    line-height: 1.55;
}


/* ==========================================================================
   12. MODAL CLOSE BUTTON
   ========================================================================== */

.modal-close,
.btn-close {
    position: relative;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;

    flex: 0 0 36px;

    margin: -0.25rem -0.3rem -0.25rem 0;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: transparent;
    color: #81777c;

    font-size: 1.15rem;
    line-height: 1;

    cursor: pointer;

    opacity: 1;

    transition:
        background-color var(--modal-transition),
        color var(--modal-transition),
        transform var(--modal-transition);
}

.modal-close:hover,
.btn-close:hover {
    background: rgba(128, 0, 32, 0.07);
    color: var(--modal-maroon);

    transform: rotate(4deg);
}

.modal-close:focus-visible,
.btn-close:focus-visible {
    outline: 3px solid rgba(212, 175, 55, 0.3);
    outline-offset: 2px;
}


/* Custom X if no icon is supplied */

.modal-close:not(:has(*))::before,
.modal-close:not(:has(*))::after {
    content: "";

    position: absolute;

    width: 15px;
    height: 1.5px;

    border-radius: 999px;

    background: currentColor;
}

.modal-close:not(:has(*))::before {
    transform: rotate(45deg);
}

.modal-close:not(:has(*))::after {
    transform: rotate(-45deg);
}


/* ==========================================================================
   13. MODAL BODY
   ========================================================================== */

.modal-body {
    position: relative;

    flex: 1 1 auto;

    padding: 1.5rem;

    color: var(--modal-text);

    font-size: 0.84rem;
    line-height: 1.65;
}

.modal-body > :first-child {
    margin-top: 0;
}

.modal-body > :last-child {
    margin-bottom: 0;
}


/* ==========================================================================
   14. MODAL FOOTER
   ========================================================================== */

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;

    gap: 0.65rem;

    padding: 1rem 1.5rem;

    border-top: 1px solid var(--modal-border);

    background: var(--modal-bg-soft);
}

.modal-footer-left {
    justify-content: flex-start;
}

.modal-footer-center {
    justify-content: center;
}

.modal-footer-between {
    justify-content: space-between;
}


/* ==========================================================================
   15. MODAL SIZES
   ========================================================================== */

.modal-sm {
    max-width: 400px;
}

.modal-md {
    max-width: 560px;
}

.modal-lg {
    max-width: 800px;
}

.modal-xl {
    max-width: 1140px;
}

.modal-xxl {
    max-width: 1320px;
}


/* ==========================================================================
   16. FULLSCREEN MODAL
   ========================================================================== */

.modal-fullscreen {
    width: 100vw;
    max-width: none;

    height: 100%;
    min-height: 100%;

    margin: 0;
}

.modal-fullscreen .modal-content {
    height: 100%;

    border: 0;
    border-radius: 0;
}

.modal-fullscreen .modal-body {
    overflow-y: auto;
}


/* ==========================================================================
   17. MODAL ICON
   ========================================================================== */

.modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 58px;
    height: 58px;

    margin: 0 auto 1rem;

    border-radius: 50%;

    background: rgba(128, 0, 32, 0.07);
    color: var(--modal-maroon);

    font-size: 1.45rem;
}

.modal-icon-sm {
    width: 44px;
    height: 44px;

    font-size: 1.05rem;
}

.modal-icon-lg {
    width: 72px;
    height: 72px;

    font-size: 1.8rem;
}


/* ==========================================================================
   18. MODAL STATUS ICONS
   ========================================================================== */

.modal-icon-success {
    background: rgba(25, 135, 84, 0.09);
    color: var(--modal-success);
}

.modal-icon-danger {
    background: rgba(220, 53, 69, 0.09);
    color: var(--modal-danger);
}

.modal-icon-warning {
    background: rgba(212, 175, 55, 0.13);
    color: #8b6a08;
}

.modal-icon-info {
    background: rgba(13, 110, 253, 0.08);
    color: var(--modal-info);
}

.modal-icon-premium {
    border: 1px solid rgba(212, 175, 55, 0.28);

    background:
        linear-gradient(
            145deg,
            #fffdf6,
            #fff6d7
        );

    color: var(--modal-gold-dark);
}


/* ==========================================================================
   19. CENTERED MESSAGE MODAL
   ========================================================================== */

.modal-message {
    text-align: center;
}

.modal-message-title {
    margin: 0 0 0.45rem;

    color: var(--modal-text);

    font-size: 1.1rem;
    font-weight: 700;
}

.modal-message-text {
    max-width: 440px;

    margin: 0 auto;

    color: var(--modal-muted);

    font-size: 0.8rem;
    line-height: 1.65;
}


/* ==========================================================================
   20. CONFIRMATION MODAL
   ========================================================================== */

.confirm-modal .modal-body {
    padding-top: 1.8rem;
    padding-bottom: 1.6rem;

    text-align: center;
}

.confirm-modal .modal-footer {
    justify-content: center;
}


/* ==========================================================================
   21. DELETE / DANGER MODAL
   ========================================================================== */

.modal-danger .modal-content::before {
    background:
        linear-gradient(
            90deg,
            transparent,
            var(--modal-danger),
            transparent
        );
}

.modal-danger .modal-title {
    color: var(--modal-danger);
}

.modal-danger .modal-header {
    background:
        linear-gradient(
            180deg,
            #ffffff,
            #fffafb
        );
}


/* ==========================================================================
   22. SUCCESS MODAL
   ========================================================================== */

.modal-success .modal-content::before {
    background:
        linear-gradient(
            90deg,
            transparent,
            var(--modal-success),
            transparent
        );
}

.modal-success .modal-title {
    color: var(--modal-success);
}


/* ==========================================================================
   23. WARNING MODAL
   ========================================================================== */

.modal-warning .modal-content::before {
    background:
        linear-gradient(
            90deg,
            transparent,
            var(--modal-gold),
            transparent
        );
}

.modal-warning .modal-title {
    color: #7e6008;
}


/* ==========================================================================
   24. PREMIUM MODAL
   ========================================================================== */

.modal-premium .modal-content {
    border-color: rgba(212, 175, 55, 0.3);

    background:
        linear-gradient(
            145deg,
            #ffffff 0%,
            #fffdf8 100%
        );

    box-shadow:
        0 26px 75px rgba(68, 48, 8, 0.19);
}

.modal-premium .modal-content::before {
    height: 4px;

    background:
        linear-gradient(
            90deg,
            var(--modal-maroon),
            var(--modal-gold),
            var(--modal-maroon)
        );
}

.modal-premium .modal-header {
    background:
        linear-gradient(
            145deg,
            #fffefe,
            #fffaf0
        );
}


/* ==========================================================================
   25. MEMBERSHIP / UPGRADE MODAL
   ========================================================================== */

.membership-modal-header,
.upgrade-modal-header {
    position: relative;

    padding: 2rem 1.5rem 1.5rem;

    text-align: center;

    background:
        linear-gradient(
            145deg,
            #fff9fb,
            #fffdf5
        );
}

.membership-modal-badge,
.upgrade-modal-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;

    margin-bottom: 0.75rem;
    padding: 0.35rem 0.7rem;

    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 999px;

    background: rgba(212, 175, 55, 0.1);
    color: #80620a;

    font-size: 0.68rem;
    font-weight: 700;

    letter-spacing: 0.04em;
    text-transform: uppercase;
}


/* ==========================================================================
   26. PROFILE PREVIEW MODAL
   ========================================================================== */

.profile-preview-modal .modal-dialog {
    max-width: 920px;
}

.profile-preview-layout {
    display: grid;
    grid-template-columns:
        minmax(280px, 0.85fr)
        minmax(0, 1.15fr);

    min-height: 500px;
}

.profile-preview-media {
    position: relative;

    min-height: 500px;

    overflow: hidden;

    background: #eee9eb;
}

.profile-preview-media img {
    width: 100%;
    height: 100%;

    object-fit: cover;
}

.profile-preview-content {
    min-width: 0;

    padding: 1.75rem;
}


/* ==========================================================================
   27. IMAGE / PHOTO MODAL
   ========================================================================== */

.image-modal .modal-dialog,
.photo-modal .modal-dialog,
.gallery-modal .modal-dialog {
    max-width: min(1100px, calc(100vw - 2rem));
}

.image-modal .modal-content,
.photo-modal .modal-content,
.gallery-modal .modal-content {
    border: 0;

    background: #111111;

    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.4);
}

.image-modal .modal-content::before,
.photo-modal .modal-content::before,
.gallery-modal .modal-content::before {
    display: none;
}

.modal-image-viewer,
.gallery-viewer {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 520px;

    background: #111111;
}

.modal-image-viewer img,
.gallery-viewer img {
    display: block;

    max-width: 100%;
    max-height: calc(100vh - 120px);

    object-fit: contain;
}


/* ==========================================================================
   28. GALLERY CONTROLS
   ========================================================================== */

.gallery-prev,
.gallery-next {
    position: absolute;
    top: 50%;
    z-index: 5;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;

    padding: 0;

    transform: translateY(-50%);

    border: 0;
    border-radius: 50%;

    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;

    cursor: pointer;

    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);

    transition:
        background var(--modal-transition),
        transform var(--modal-transition);
}

.gallery-prev {
    left: 1rem;
}

.gallery-next {
    right: 1rem;
}

.gallery-prev:hover,
.gallery-next:hover {
    background: rgba(255, 255, 255, 0.22);
}

.gallery-prev:focus-visible,
.gallery-next:focus-visible {
    outline: 3px solid rgba(212, 175, 55, 0.55);
    outline-offset: 2px;
}


/* ==========================================================================
   29. GALLERY COUNTER
   ========================================================================== */

.gallery-counter {
    position: absolute;
    right: 1rem;
    bottom: 1rem;
    z-index: 5;

    padding: 0.35rem 0.65rem;

    border-radius: 999px;

    background: rgba(0, 0, 0, 0.5);
    color: #ffffff;

    font-size: 0.7rem;
    font-weight: 600;

    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}


/* ==========================================================================
   30. VIDEO CALL MODAL
   ========================================================================== */

.video-call-modal .modal-dialog {
    max-width: 1100px;
}

.video-call-modal .modal-content {
    overflow: hidden;

    border: 0;

    background: #101010;
    color: #ffffff;
}

.video-call-modal .modal-content::before {
    display: none;
}

.video-call-area {
    position: relative;

    min-height: 600px;

    background: #101010;
}


/* ==========================================================================
   31. REPORT MODAL
   ========================================================================== */

.report-modal .report-options {
    display: grid;
    grid-template-columns: 1fr;

    gap: 0.55rem;
}

.report-option {
    display: flex;
    align-items: flex-start;

    gap: 0.7rem;

    padding: 0.8rem;

    border: 1px solid var(--modal-border);
    border-radius: 10px;

    background: #ffffff;

    cursor: pointer;

    transition:
        border-color var(--modal-transition),
        background var(--modal-transition),
        box-shadow var(--modal-transition);
}

.report-option:hover {
    border-color: rgba(128, 0, 32, 0.3);

    background: #fffafb;
}

.report-option.selected {
    border-color: var(--modal-maroon);

    background: rgba(128, 0, 32, 0.04);

    box-shadow:
        0 0 0 3px rgba(128, 0, 32, 0.05);
}


/* ==========================================================================
   32. BLOCK USER MODAL
   ========================================================================== */

.block-user-modal .modal-icon {
    background: rgba(220, 53, 69, 0.08);
    color: var(--modal-danger);
}


/* ==========================================================================
   33. VERIFICATION MODAL
   ========================================================================== */

.verification-modal .verification-summary {
    padding: 1rem;

    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 12px;

    background:
        linear-gradient(
            145deg,
            #fffdf7,
            #ffffff
        );
}


/* ==========================================================================
   34. PAYMENT MODAL
   ========================================================================== */

.payment-modal .modal-dialog {
    max-width: 620px;
}

.payment-modal-summary {
    margin-bottom: 1.25rem;
    padding: 1rem;

    border: 1px solid rgba(212, 175, 55, 0.24);
    border-radius: 12px;

    background:
        linear-gradient(
            145deg,
            #fffdf7,
            #ffffff
        );
}


/* ==========================================================================
   35. MODAL FORM SUPPORT
   ========================================================================== */

.modal-body .form-group:last-child {
    margin-bottom: 0;
}

.modal-body .form-control,
.modal-body .form-select {
    box-shadow: none;
}

.modal-body .form-control:focus,
.modal-body .form-select:focus {
    box-shadow:
        0 0 0 3px rgba(128, 0, 32, 0.08);
}


/* ==========================================================================
   36. MODAL DIVIDER
   ========================================================================== */

.modal-divider {
    width: 100%;
    height: 1px;

    margin: 1.25rem 0;

    border: 0;

    background:
        linear-gradient(
            90deg,
            transparent,
            var(--modal-border),
            transparent
        );
}


/* ==========================================================================
   37. MODAL INFO BOX
   ========================================================================== */

.modal-info-box {
    padding: 0.85rem 1rem;

    border: 1px solid rgba(128, 0, 32, 0.1);
    border-radius: 10px;

    background: rgba(128, 0, 32, 0.035);

    color: #665d62;

    font-size: 0.75rem;
    line-height: 1.6;
}

.modal-info-box + .modal-info-box {
    margin-top: 0.75rem;
}


/* ==========================================================================
   38. MODAL WARNING BOX
   ========================================================================== */

.modal-warning-box {
    padding: 0.85rem 1rem;

    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 10px;

    background: rgba(212, 175, 55, 0.08);
    color: #72580c;

    font-size: 0.75rem;
    line-height: 1.6;
}


/* ==========================================================================
   39. MODAL ERROR BOX
   ========================================================================== */

.modal-error-box {
    padding: 0.85rem 1rem;

    border: 1px solid rgba(220, 53, 69, 0.2);
    border-radius: 10px;

    background: rgba(220, 53, 69, 0.055);
    color: #a52834;

    font-size: 0.75rem;
    line-height: 1.6;
}


/* ==========================================================================
   40. MODAL SUCCESS BOX
   ========================================================================== */

.modal-success-box {
    padding: 0.85rem 1rem;

    border: 1px solid rgba(25, 135, 84, 0.2);
    border-radius: 10px;

    background: rgba(25, 135, 84, 0.055);
    color: #146c43;

    font-size: 0.75rem;
    line-height: 1.6;
}


/* ==========================================================================
   41. LOADING MODAL
   ========================================================================== */

.modal-loading .modal-body {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;

    min-height: 220px;

    text-align: center;
}

.modal-loader {
    width: 38px;
    height: 38px;

    margin-bottom: 1rem;

    border: 3px solid rgba(128, 0, 32, 0.12);
    border-top-color: var(--modal-maroon);
    border-radius: 50%;

    animation: modal-spin 0.8s linear infinite;
}

@keyframes modal-spin {
    to {
        transform: rotate(360deg);
    }
}


/* ==========================================================================
   42. MODAL EMPTY STATE
   ========================================================================== */

.modal-empty-state {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;

    min-height: 250px;

    padding: 1.5rem;

    text-align: center;
}

.modal-empty-state-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 60px;
    height: 60px;

    margin-bottom: 0.85rem;

    border-radius: 50%;

    background: rgba(128, 0, 32, 0.06);
    color: var(--modal-maroon);

    font-size: 1.4rem;
}


/* ==========================================================================
   43. MODAL LIST
   ========================================================================== */

.modal-list {
    margin: 0;
    padding: 0;

    list-style: none;
}

.modal-list-item {
    display: flex;
    align-items: center;

    gap: 0.75rem;

    padding: 0.75rem 0;

    border-bottom: 1px solid var(--modal-border);
}

.modal-list-item:first-child {
    padding-top: 0;
}

.modal-list-item:last-child {
    padding-bottom: 0;

    border-bottom: 0;
}


/* ==========================================================================
   44. MODAL ACTION GRID
   ========================================================================== */

.modal-action-grid {
    display: grid;
    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 0.75rem;
}


/* ==========================================================================
   45. SHARE MODAL
   ========================================================================== */

.share-options {
    display: grid;
    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    gap: 0.75rem;
}

.share-option {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;

    gap: 0.45rem;

    min-width: 0;

    padding: 0.8rem 0.4rem;

    border: 1px solid var(--modal-border);
    border-radius: 12px;

    background: #ffffff;
    color: var(--modal-text);

    font-size: 0.68rem;

    text-decoration: none;

    cursor: pointer;

    transition:
        border-color var(--modal-transition),
        background var(--modal-transition),
        transform var(--modal-transition);
}

.share-option:hover {
    border-color: rgba(128, 0, 32, 0.25);

    background: #fffafb;

    transform: translateY(-2px);
}

.share-option-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    border-radius: 50%;

    background: rgba(128, 0, 32, 0.06);
    color: var(--modal-maroon);

    font-size: 1rem;
}


/* ==========================================================================
   46. MODAL USER SUMMARY
   ========================================================================== */

.modal-user-summary {
    display: flex;
    align-items: center;

    gap: 0.85rem;

    padding: 0.85rem;

    border: 1px solid var(--modal-border);
    border-radius: 12px;

    background: #fdfbfc;
}

.modal-user-avatar {
    width: 52px;
    height: 52px;

    flex: 0 0 52px;

    overflow: hidden;

    border-radius: 50%;

    background: #eee9eb;
}

.modal-user-avatar img {
    width: 100%;
    height: 100%;

    object-fit: cover;
}

.modal-user-info {
    min-width: 0;

    flex: 1;
}

.modal-user-name {
    overflow: hidden;

    margin: 0;

    color: var(--modal-text);

    font-size: 0.85rem;
    font-weight: 700;

    white-space: nowrap;
    text-overflow: ellipsis;
}

.modal-user-meta {
    margin-top: 0.15rem;

    color: var(--modal-muted);

    font-size: 0.7rem;
}


/* ==========================================================================
   47. MODAL BADGE
   ========================================================================== */

.modal-badge {
    display: inline-flex;
    align-items: center;

    padding: 0.28rem 0.55rem;

    border-radius: 999px;

    background: rgba(128, 0, 32, 0.07);
    color: var(--modal-maroon);

    font-size: 0.64rem;
    font-weight: 700;
}

.modal-badge-premium {
    border: 1px solid rgba(212, 175, 55, 0.25);

    background: rgba(212, 175, 55, 0.1);
    color: #80620a;
}


/* ==========================================================================
   48. MODAL TABS SUPPORT
   ========================================================================== */

.modal-tabs {
    display: flex;

    overflow-x: auto;

    padding: 0 1.5rem;

    border-bottom: 1px solid var(--modal-border);

    background: #ffffff;

    scrollbar-width: none;
}

.modal-tabs::-webkit-scrollbar {
    display: none;
}

.modal-tab {
    position: relative;

    flex: 0 0 auto;

    padding: 0.85rem 0.75rem;

    border: 0;

    background: transparent;
    color: var(--modal-muted);

    font-size: 0.75rem;
    font-weight: 600;

    cursor: pointer;
}

.modal-tab::after {
    content: "";

    position: absolute;
    right: 0.75rem;
    bottom: 0;
    left: 0.75rem;

    height: 2px;

    border-radius: 999px 999px 0 0;

    background: var(--modal-maroon);

    transform: scaleX(0);

    transition:
        transform var(--modal-transition);
}

.modal-tab.active {
    color: var(--modal-maroon);
}

.modal-tab.active::after {
    transform: scaleX(1);
}


/* ==========================================================================
   49. SIDE MODAL / DRAWER
   ========================================================================== */

.modal-drawer .modal-dialog {
    position: absolute;
    top: 0;
    right: 0;

    width: min(440px, 100%);
    max-width: none;
    height: 100%;

    margin: 0;

    transform: translateX(100%);

    opacity: 1;
}

.modal-drawer.show .modal-dialog {
    transform: translateX(0);
}

.modal-drawer .modal-content {
    height: 100%;

    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.modal-drawer .modal-body {
    overflow-y: auto;
}


/* ==========================================================================
   50. LEFT DRAWER
   ========================================================================== */

.modal-drawer-left .modal-dialog {
    right: auto;
    left: 0;

    transform: translateX(-100%);
}

.modal-drawer-left.show .modal-dialog {
    transform: translateX(0);
}

.modal-drawer-left .modal-content {
    border-radius:
        0
        var(--modal-radius-lg)
        var(--modal-radius-lg)
        0;
}


/* ==========================================================================
   51. BOTTOM SHEET
   ========================================================================== */

.modal-bottom-sheet {
    display: none;

    align-items: flex-end;
}

.modal-bottom-sheet.show {
    display: flex;
}

.modal-bottom-sheet .modal-dialog {
    width: 100%;
    max-width: none;

    margin: 0;

    transform: translateY(100%);

    opacity: 1;
}

.modal-bottom-sheet.show .modal-dialog {
    transform: translateY(0);
}

.modal-bottom-sheet .modal-content {
    max-height: 90vh;

    border-radius:
        var(--modal-radius-lg)
        var(--modal-radius-lg)
        0
        0;
}

.modal-bottom-sheet-handle {
    width: 42px;
    height: 4px;

    margin: 0.55rem auto 0;

    border-radius: 999px;

    background: #d8d1d4;
}


/* ==========================================================================
   52. MODAL SCROLLBAR
   ========================================================================== */

.modal-body::-webkit-scrollbar,
.modal-dialog-scrollable::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track,
.modal-dialog-scrollable::-webkit-scrollbar-track {
    background: transparent;
}

.modal-body::-webkit-scrollbar-thumb,
.modal-dialog-scrollable::-webkit-scrollbar-thumb {
    border-radius: 999px;

    background: #d5cdd1;
}

.modal-body::-webkit-scrollbar-thumb:hover,
.modal-dialog-scrollable::-webkit-scrollbar-thumb:hover {
    background: #bdb3b8;
}


/* ==========================================================================
   53. ACCESSIBILITY
   ========================================================================== */

.modal[aria-hidden="true"] {
    pointer-events: none;
}

.modal[aria-hidden="false"] {
    pointer-events: auto;
}

.modal-content:focus {
    outline: none;
}


/* ==========================================================================
   54. RESPONSIVE - TABLET
   ========================================================================== */

@media (max-width: 991.98px) {

    .modal-xl,
    .modal-xxl {
        max-width: calc(100% - 2rem);
    }

    .profile-preview-modal .modal-dialog {
        max-width: calc(100% - 2rem);
    }

    .profile-preview-layout {
        grid-template-columns:
            minmax(240px, 0.8fr)
            minmax(0, 1.2fr);
    }

    .video-call-modal .modal-dialog {
        max-width: calc(100% - 2rem);
    }
}


/* ==========================================================================
   55. RESPONSIVE - MOBILE
   ========================================================================== */

@media (max-width: 767.98px) {

    .modal-dialog {
        max-width: calc(100% - 1.5rem);

        margin: 0.75rem auto;
    }

    .modal-dialog-centered {
        min-height: calc(100% - 1.5rem);
    }

    .modal-dialog-scrollable {
        height: calc(100% - 1.5rem);
    }

    .modal-content {
        border-radius: 16px;
    }

    .modal-header {
        padding: 1.15rem 1rem 1rem;
    }

    .modal-body {
        padding: 1.15rem 1rem;
    }

    .modal-footer {
        padding: 0.9rem 1rem;
    }

    .modal-title {
        font-size: 1rem;
    }

    .modal-footer {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .modal-footer .btn,
    .modal-footer button {
        width: 100%;
    }

    .modal-footer-between {
        align-items: stretch;
    }

    .modal-action-grid {
        grid-template-columns: 1fr;
    }

    .share-options {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .profile-preview-layout {
        grid-template-columns: 1fr;
    }

    .profile-preview-media {
        min-height: 360px;
    }

    .profile-preview-content {
        padding: 1.25rem 1rem;
    }

    .modal-image-viewer,
    .gallery-viewer {
        min-height: 420px;
    }

    .video-call-area {
        min-height: 480px;
    }

    .modal-tabs {
        padding-right: 1rem;
        padding-left: 1rem;
    }
}


/* ==========================================================================
   56. RESPONSIVE - SMALL MOBILE
   ========================================================================== */

@media (max-width: 575.98px) {

    .modal {
        padding: 0;
    }

    .modal-dialog {
        max-width: calc(100% - 1rem);

        margin: 0.5rem auto;
    }

    .modal-dialog-centered {
        min-height: calc(100% - 1rem);
    }

    .modal-dialog-scrollable {
        height: calc(100% - 1rem);
    }

    .modal-header {
        padding: 1rem;
    }

    .modal-body {
        padding: 1rem;
    }

    .modal-footer {
        padding: 0.85rem 1rem;
    }

    .modal-close,
    .btn-close {
        width: 34px;
        height: 34px;

        flex-basis: 34px;
    }

    .modal-icon {
        width: 54px;
        height: 54px;
    }

    .profile-preview-media {
        min-height: 300px;
    }

    .modal-image-viewer,
    .gallery-viewer {
        min-height: 360px;
    }

    .gallery-prev,
    .gallery-next {
        width: 38px;
        height: 38px;
    }

    .gallery-prev {
        left: 0.5rem;
    }

    .gallery-next {
        right: 0.5rem;
    }

    .modal-drawer .modal-dialog {
        width: 100%;
    }

    .modal-drawer .modal-content,
    .modal-drawer-left .modal-content {
        border-radius: 0;
    }
}


/* ==========================================================================
   57. MOBILE FULLSCREEN UTILITY
   ========================================================================== */

@media (max-width: 575.98px) {

    .modal-fullscreen-sm-down {
        width: 100vw;
        max-width: none;

        height: 100%;
        min-height: 100%;

        margin: 0;
    }

    .modal-fullscreen-sm-down .modal-content {
        height: 100%;

        border: 0;
        border-radius: 0;
    }

    .modal-fullscreen-sm-down .modal-body {
        overflow-y: auto;
    }
}


/* ==========================================================================
   58. TOUCH DEVICES
   ========================================================================== */

@media (hover: none) and (pointer: coarse) {

    .modal-close,
    .btn-close {
        min-width: 40px;
        min-height: 40px;
    }

    .gallery-prev,
    .gallery-next {
        min-width: 44px;
        min-height: 44px;
    }

    .modal-tab {
        min-height: 44px;
    }
}


/* ==========================================================================
   59. REDUCED MOTION
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {

    .modal,
    .modal-dialog,
    .modal-backdrop,
    .modal-close,
    .btn-close,
    .gallery-prev,
    .gallery-next,
    .share-option,
    .report-option,
    .modal-tab::after {
        transition: none !important;
    }

    .modal-loader {
        animation-duration: 1.5s;
    }
}


/* ==========================================================================
   60. PRINT
   ========================================================================== */

@media print {

    .modal-backdrop {
        display: none !important;
    }

    .modal {
        position: static;

        display: block !important;

        width: auto;
        height: auto;

        overflow: visible;
    }

    .modal-dialog {
        width: 100%;
        max-width: none;

        margin: 0;

        transform: none !important;

        opacity: 1 !important;
    }

    .modal-content {
        overflow: visible;

        border: 1px solid #cccccc;
        border-radius: 0;

        box-shadow: none;
    }

    .modal-content::before,
    .modal-close,
    .btn-close,
    .modal-footer {
        display: none !important;
    }

    .modal-body {
        overflow: visible;
    }
}