
/* DAV Communication Portal v7.7.0 — isolated profile layout */

.profile-page,
.position-request-admin{
    display:grid;
    grid-template-columns:minmax(0,1fr);
    gap:18px;
    width:100%;
    max-width:100%;
    min-width:0;
    padding-bottom:30px;
    overflow-x:hidden;
}

.profile-page *,
.position-request-admin *{
    box-sizing:border-box;
    min-width:0;
}

.profile-page > *,
.position-request-admin > *{
    width:100%;
    max-width:100%;
}

.profile-hero{
    display:flex;
    align-items:center;
    gap:18px;
}

.profile-hero h1{
    margin:0 0 5px;
}

.profile-hero p{
    margin:0;
    color:#617185;
    line-height:1.45;
}

.profile-avatar{
    display:grid;
    place-items:center;
    flex:0 0 64px;
    width:64px;
    height:64px;
    border-radius:50%;
    background:#174f73;
    color:#fff;
    font-size:1.25rem;
    font-weight:900;
    letter-spacing:.04em;
}

.profile-section-index{
    display:grid;
    grid-template-columns:repeat(6,minmax(0,1fr));
    gap:8px;
    width:100%;
    max-width:100%;
    padding:10px;
    border:1px solid #dbe4ec;
    border-radius:12px;
    background:#fff;
}

.profile-section-index a{
    display:flex;
    align-items:center;
    justify-content:center;
    min-height:42px;
    padding:9px 8px;
    border-radius:8px;
    background:#f5f8fa;
    color:#194d70;
    font-weight:800;
    line-height:1.2;
    text-align:center;
    text-decoration:none;
    overflow-wrap:anywhere;
}

.profile-section-index a:hover,
.profile-section-index a:focus-visible{
    background:#e6f2f8;
    outline:2px solid rgba(25,77,112,.25);
    outline-offset:1px;
}

.profile-section{
    width:100%;
    max-width:100%;
    scroll-margin-top:96px;
}

.profile-section-heading,
.position-request-summary{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:18px;
}

.profile-section-heading h2,
.profile-action-card h2,
.position-request-card h2{
    margin-top:0;
}

.profile-section-heading p{
    margin-bottom:0;
    color:#617185;
}

.profile-status{
    display:inline-flex;
    flex:0 0 auto;
    padding:7px 10px;
    border-radius:999px;
    background:#e8f3f9;
    color:#145677;
    font-weight:900;
}

.profile-form{
    display:grid;
    gap:14px;
    width:100%;
    max-width:100%;
    margin-top:18px;
}

.profile-form .grid{
    width:100%;
    max-width:100%;
}

.profile-form input,
.profile-form select,
.profile-form textarea,
.profile-form button,
.profile-form .button{
    width:100%;
    max-width:100%;
    min-width:0;
}

.profile-form small{
    display:block;
    margin-top:5px;
    color:#6c7b8c;
    line-height:1.4;
}

.profile-security-notice{
    margin-top:16px;
    padding:12px 14px;
    border-left:5px solid #b07712;
    border-radius:8px;
    background:#fff7e4;
    color:#614711;
    font-weight:700;
}

.profile-card-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:18px;
    width:100%;
}

.profile-action-card{
    display:flex;
    flex-direction:column;
    width:100%;
}

.profile-action-card p{
    flex:1;
    color:#617185;
}

.profile-action-buttons,
.position-request-buttons{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
}

.profile-toggle{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:20px;
    width:100%;
    padding:16px;
    border:1px solid #dbe4ec;
    border-radius:12px;
    background:#f8fbfd;
}

.profile-toggle strong,
.profile-toggle small{
    display:block;
}

.profile-toggle small{
    margin-top:5px;
    color:#617185;
    line-height:1.45;
}

.profile-toggle .group-switch{
    flex:0 0 auto;
    margin:0;
}

.profile-request-list{
    display:grid;
    gap:9px;
    width:100%;
}

.profile-request-row{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:14px;
    width:100%;
    padding:12px;
    border:1px solid #dbe4ec;
    border-radius:10px;
}

.profile-request-row strong,
.profile-request-row span{
    display:block;
}

.profile-request-row > div span{
    margin-top:3px;
    color:#6b7888;
    font-size:.84rem;
}

.profile-request-status{
    display:inline-flex;
    padding:6px 9px;
    border-radius:999px;
    font-size:.78rem;
    font-weight:900;
    text-transform:uppercase;
}

.status-pending{
    background:#fff1c8;
    color:#795700;
}

.status-approved{
    background:#dff4e8;
    color:#17633c;
}

.status-denied,
.status-cancelled{
    background:#f7dfdf;
    color:#8a2929;
}

.position-request-card{
    display:grid;
    gap:16px;
    width:100%;
}

.position-request-details{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:12px;
    width:100%;
    margin:0;
}

.position-request-details > div{
    padding:12px;
    border-radius:9px;
    background:#f5f8fa;
}

.position-request-details dt{
    color:#6a7888;
    font-size:.78rem;
    font-weight:800;
    text-transform:uppercase;
}

.position-request-details dd{
    margin:4px 0 0;
    font-weight:800;
}

.position-request-reason{
    padding:13px;
    border-left:4px solid #2b6e9f;
    background:#f3f8fb;
}

.position-request-reason p{
    margin-bottom:0;
}

.position-request-reviewed{
    margin:0;
    color:#5f6e7f;
}

@media(max-width:850px){
    .profile-section-index{
        grid-template-columns:repeat(3,minmax(0,1fr));
    }

    .profile-card-grid,
    .position-request-details{
        grid-template-columns:1fr;
    }
}

@media(max-width:700px){
    .profile-page,
    .position-request-admin{
        gap:12px;
        width:100%;
        max-width:100%;
        overflow-x:hidden;
    }

    .profile-hero{
        align-items:flex-start;
        gap:12px;
    }

    .profile-avatar{
        flex-basis:52px;
        width:52px;
        height:52px;
        font-size:1rem;
    }

    .profile-section-index{
        grid-template-columns:repeat(2,minmax(0,1fr));
        gap:7px;
        padding:8px;
    }

    .profile-section-index a{
        min-height:44px;
        padding:8px 6px;
        font-size:.9rem;
    }

    .profile-section-heading,
    .position-request-summary{
        display:grid;
    }

    .profile-status{
        justify-self:start;
    }

    .profile-toggle{
        align-items:flex-start;
    }

    .profile-action-buttons,
    .position-request-buttons{
        display:grid;
        grid-template-columns:1fr;
    }

    .profile-action-buttons .button,
    .position-request-buttons .button,
    .position-request-buttons button{
        width:100%;
    }
}

@media(max-width:380px){
    .profile-section-index{
        grid-template-columns:1fr;
    }
}


/*
 * Version 7.7.1 — iOS Profile viewport stabilization.
 */
@media(max-width:700px){
    .profile-page{
        position:relative;
        left:auto;
        right:auto;
        width:100% !important;
        max-width:100% !important;
        min-width:0 !important;
        margin-left:0 !important;
        margin-right:0 !important;
        padding-left:0 !important;
        padding-right:0 !important;
        transform:none !important;
        translate:none !important;
        overflow-x:hidden !important;
        contain:layout paint;
    }

    .profile-page .card,
    .profile-page .profile-section-index,
    .profile-page .profile-card-grid,
    .profile-page .profile-form,
    .profile-page .profile-form .grid,
    .profile-page .profile-form p{
        width:100% !important;
        max-width:100% !important;
        min-width:0 !important;
        margin-left:0 !important;
        margin-right:0 !important;
        transform:none !important;
    }

    .profile-page input,
    .profile-page select,
    .profile-page textarea{
        display:block;
        width:100% !important;
        max-width:100% !important;
        min-width:0 !important;
        font-size:16px !important;
        line-height:1.35 !important;
        transform:none !important;
    }

    .profile-page button,
    .profile-page .button{
        max-width:100% !important;
        min-width:0 !important;
        font-size:16px !important;
    }

    .profile-page .profile-section-index{
        box-sizing:border-box !important;
    }

    .profile-page .profile-section-index a{
        width:100% !important;
        max-width:100% !important;
        min-width:0 !important;
    }
}
