#profileModalOverlay{
    align-items: flex-start !important;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1002;
    overflow-y: auto;
    padding: var(--space-md);
}

.modal-overlay.hidden {
    display: none;
}

.modal-container {
    background-color: var(--bg-secondary);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    animation: modalFadeIn 0.3s ease;
}

.modal-container.small {
    max-width: 400px;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-header {
    padding: var(--space-md);
    border: 1px solid #2FBED2;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;

    animation: modalFadeIn 0.3s ease;

    background-color: var(--bg-quindecennary);
}

.modal-header h3 {
    font-size: var(--font-size-lg);
    color: var(--text-primary);
    margin: 0;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: color var(--transition-fast);
    padding: 0;
}

.close-btn:hover {
    color: var(--text-primary);
}

.close-btn svg {
    width: 18px;
    height: 18px;
}

.modal-body {
    padding: var(--space-lg);
    background-color: var(--bg-primary);
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
}

.status-active {
    background: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid #4CAF50;
}

.status-trialing {
    background: rgba(255, 152, 0, 0.2);
    color: #ff9800;
    border: 1px solid #ff9800;
}

.status-cancelled {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
    border: 1px solid #f44336;
}


.form-value {
    background: var(--bg-tertiary, #3e3e42);
    border-radius: 15px;
    padding: var(--space-sm) var(--space-md) var(--space-sm) var(--space-lg);
    color: var(--text-primary, #ffffff);
    font-size: var(--font-size-md);
    height: 50px;
    display: flex;
    align-items: center;
    position: relative;
    width: 55%;
}
.form-value::before{
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: transparent;
    border: 3px solid #2FBED2;
    filter: blur(2px);
    pointer-events: none;
    z-index: 0;
    mix-blend-mode: normal;
}

.danger-zone h3 {
    font-size: 1rem;
    margin-bottom: 12px;
    color: var(--text-secondary, #cccccc);
    font-weight: 500;
}


.buttons-wrapper {
    margin-top: 20px;
}

.modal-chat-search{
    grid-area: main;
    z-index: 999;
    overflow: hidden;
}

.modal-chat-search .modal-body{
    padding: 0;
    height: 100%;
    background-color: var(--bg-octenennary);
    animation: modalFadeIn 0.3s ease;
}

.chat-search{
    position: relative;
    width: 100%;
    border-radius: 15px;
}
.modal-chat-search .chat-search::before{
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: transparent;
    border: 3px solid #2FBED2;
    filter: blur(2px);
    pointer-events: none;
    z-index: 0;
    mix-blend-mode: normal;
}

.modal-chat-search .search-input{
    border: 0;
    border-radius: 15px;
    background-color: var(--bg-tridenenary);
    padding: var(--space-md) var(--space-md) var(--space-md) 3.5rem;
}
.modal-chat-search .search-input:focus-visible{
    outline: none;
    border: 0;
}

.search-icon {
    position: absolute;
    left: var(--space-md);
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    width: 30px;
    height: 30px;
}

.modal-chat-search .chat-search-item-base{
    background-color: var(--bg-septenennary);

}
.modal-chat-search .modal-body .chat-title-base{
    font-weight: 600;
    font-size: var(--font-size-xl);
    line-height: 1.3;
    letter-spacing: 0;
    color: var(--text-primary);

}
.modal-chat-search .chat-search-item .chat-date-base{
    font-weight: 600;
    font-size: var(--font-size-xl);
    line-height: 1.3;
    letter-spacing: 0;
    color: var(--text-primary);
}


.modal-chat-search .chat-search-item{
    padding: 0;
    border-bottom: 0;
    display: grid;
    grid-template-columns: 80% 15% 5%;
}

.modal-chat-search .modal-body .chat-title{
    padding: 12px 20px;
    border-width: 1px 0 0 1px;
    border-style: solid;
    border-color: #2FBED2;
    margin: 0;
}

.modal-chat-search .chat-search-item .chat-date{
    padding: 12px 20px;
    border-width: 1px 0 0 1px;
    border-style: solid;
    border-color: #2FBED2;

    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-chat-search .chat-search-item .chat-delete{
    border-width: 1px 1px 0 1px;
    border-style: solid;
    border-color: #2FBED2;

    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-chat-search .chat-search-item .chat-delete:hover{
    fill: var(--accent-alert);
}

.modal-chat-search .chat-search-item:last-child .chat-title{
    border-width: 1px 0 1px 1px;
}

.modal-chat-search .chat-search-item:last-child .chat-date{
    border-width: 1px 0 1px 1px;
}

.modal-chat-search .chat-search-item:last-child .chat-delete{
    border-width: 1px 1px 1px 1px;
}


.modal-profile{
    grid-area: main;
    z-index: 999;
    overflow: hidden;
}

#profileModalOverlay .modal-container {
    max-width: 100%;
    height: 100%;
    box-shadow: none;
    border-radius: 0;
    background: var(--bg-log-reg);
    background-position: center center, center center;
    background-repeat: no-repeat, no-repeat;
    background-size: cover;
    overflow-y: auto;
    animation: none;
}

#profileModalOverlay .modal-container .modal-body{
    padding: 0;
    animation: modalFadeIn 0.3s ease;
    background: var(--bg-profile-body);
    background-position: center center, center center;
    background-repeat: no-repeat, no-repeat;
    background-size: cover;
}

.profile-header-wrapper{
    padding: var(--space-lg);
    background: var(--bg-septennary);
    box-shadow: 0 2px 4px 0 rgba(255, 255, 255, 0.25);
    position: relative;
    border: solid #2FBED2;
    border-width: 2px 2px 0 2px;
}

@media (max-width: 490px) {
    .form-value{
        padding: var(--space-sm) var(--space-md) var(--space-sm) var(--space-md);
        height: 35px;
        font-size: 13px;
        border-radius: 5px;
    }

    .form-group label{
        margin-left: var(--space-md);
        font-size: 13px;
    }

}

@media (max-width: 320px) {
    .form-value{
        font-size: 12px;
    }
    .form-group label {

        font-size: 12px;
    }

    .status-badge{
        font-size: 11px;
    }
}