/* =====================================================
   Layout (grid, navigation, toolbars)
   ===================================================== */


/* --- Source: sade-layout.css --- */

/*==============================
=         Typography           =
==============================*/
.text-content,
.navbar-brand
{
    color: var(--text-light);
}

/*==============================
=           Layout             =
==============================*/
.layout
{
    display: flex;
    height: 100vh;
    overflow: hidden;
}

.sidebar
{
    width: 220px;
    background-color: var(--sidebar-background-light);
    overflow-y: auto;
    scrollbar-width: none;
    padding: 1rem;
}

/* --- Dark theme variant for: .sidebar --- */
body.dark-theme .sidebar
    {
        background-color: var(--sidebar-background-dark);
    }


    .sidebar.collapsed
    {
        padding: 0rem !important;
    }

.sidebar-logo-powered
{
    width: 100%;
    height: 200px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 0em;
    display: block;
    margin-bottom: 15px;
}

.sidebar .sidebar-role-label
{
    width: 100%;
    text-align: center;
    margin-top: 0em;
    margin-bottom: 1em;
    font-size: 20px;
    font-size-adjust: 0.6;
}

.sidebar ul
{
    list-style: none;
    padding-left: 10px;
    color: var(--text-dark);
}

.sidebar li
{
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.sidebar a
{
    font-weight: bold;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    color: var(--text-dark);
    fill: var(--text-dark);
}

.sidebar svg
{
    height: 1.5em;
    width: 1.5em;
    margin-right: 1em;
}

.main
{
    overflow-y: auto;
    width: 100%;
}

.topbar
{
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f3f4f6;
    padding: 0.5rem 1rem;
    border-bottom: 1px solid #ddd;
    background-color: black;
    border-bottom: 1px solid var(--card-dark);
}

/* --- Dark theme variant for: .topbar --- */
body.dark-theme .topbar
    {
        background-color: var(--background-dark);
        border-bottom: 1px solid var(--card-dark);
    }


    .topbar .left img,
    .topbar .left svg
    {
        height: 40px;
        width: 40px;
        border-radius: 50%;
    }

    .topbar .search-input
    {
        background: url('../Contents/Logo/SaDe_logo3_trimmed.png') no-repeat 5px center;
        background-size: 2.3em 2.3em;
        padding-left: 2.7em; /* adjust based on image size */
        height: 2.3em;
        margin-top: auto;
        margin-bottom: auto;
        font-size: 1.1em;
    }


    .topbar .center
    {
        display: flex;
        align-items: center;
        gap: 0.7rem;
        padding-bottom: 0px;
        height: 100%;
        width: 700px;
        max-width: 700px;
    }

@media (max-width: 768px)
{
    /* If tablet or mobile */
    .topbar .center
    {
        width: 70%;
    }
}


.topbar .right
{
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding-bottom: 0px;
    height: 100%;
}

    .topbar .right .button
    {
        border: 0;
        height: 100%;
    }

main
{
    padding: 1.5rem;
    overflow-y: auto;
}

/*==============================
=         Profile UI           =
==============================*/



/*==============================
=         Profile UI           =
==============================*/
.layout-navbar-sade-logo
{
    width: 70px;
    height: 100%;
    border-radius: 15%;
    background-color: black !important;
}

.layout-navbar-admin-profile-label
{
    padding-left: 20px;
    margin-top: auto;
    margin-bottom: auto;
    color: var(--text-dark);
}

@media (max-width: 768px)
{
    /* If tablet or mobile */
    .layout-navbar-admin-profile-label
    {
        display: none;
    }
}

.layout-navbar-profile-dropdown
{
    height: 100% !important;
    padding: 0px !important;
    margin: 0px !important;
    display: flex;
    border: 0px !important;
}

    .layout-navbar-profile-dropdown .dropdown-toggle
    {
        border: 0px !important;
    }

.layout-navbar-dropdown-content
{
    height: 100%;
    display: flex;
}

/*Loading spinner icon*/
.layout-navbar-admin-profile-icon
{
    width: 20px;
    height: 20px;
    margin-top: auto;
    margin-bottom: auto;
    background-color: white;
    border-radius: 25px;
    padding-left: 20px;
    fill: white;
    color: white;
}

/*Profile image*/
.layout-navbar-admin-profile-img
{
    width: 40px;
    height: 40px;
    margin-top: auto;
    margin-bottom: auto;
    background-color: transparent;
    border-radius: 25px;
}

/*Fallback icon if profile img not defined or fails*/
.layout-navbar-profileicon-svg
{
    margin-top: auto;
    margin-bottom: auto;
    fill: var(--text-light);
    opacity: 0.8;
}

/* --- Dark theme variant for: .layout-navbar-profileicon-svg --- */
body.dark-theme .layout-navbar-profileicon-svg
    {
        fill: var(--text-dark);
    }


    .layout-navbar-profileicon-svg svg
    {
        height: 40px;
        width: 40px;
    }

/*==============================
=            Logo              =
==============================*/
.logo,
.logo-powered
{
    max-width: 400px;
    background-color: transparent;
}

.logo-powered
{
    margin-top: 2rem;
    margin-bottom: 2rem;
    margin-left: auto;
    margin-right: auto;
    display: block;
}

/*==============================
=         Removal Btn          =
==============================*/
.removalBttn
{
    margin-left: auto;
    margin-right: 10px;
}

/* --- Dark theme variant for: .removalBttn --- */
body.dark-theme .removalBttn
    {
    }



/* --- Source: contact-toolbar.css --- */

.card-tools
{
    flex-direction: column;
    display: flex;
}

.card-tools-buttons {
    display:flex;
    flex-direction:column;
}

.card-header, .tool-header, .card-footer
{
    font-family: 'Roboto', sans-serif; /* Yhdenmukaistetaan fontti koko kortissa */
    color: orange; /* Säilytetään otsikoiden oranssi väri */
    text-align: center;
}

.tool-header
{
    font-size: 14px; /* Suurempi fontti otsikoille */
    font-weight: 400; /* Lihavoitu teksti otsikoille */
    margin-bottom: 10px;
}

.tool-button
{
    background: none;
    border: none;
    color: white;
    padding: 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    font-size: 2em; /* Asettaa kuvakkeen kolme kertaa suuremmaksi */
    margin: 0 10px; /* Väli ikonien välille */
    transition: background 0.3s, color 0.3s; /* Lisää sujuvan hover-animaation */
}

    .tool-button:hover
    {
        background: rgba(255, 255, 255, 0.2); /* Lievä taustavärin muutos hoverilla */
        color: #cccccc; /* Himmeä valkoinen hoverilla */
        border-radius: 8px; /* Pyöristää painikkeen reunat hover-tilassa */
    }


    .tool-button i
    {
        margin-bottom: 5px;
        vertical-align: middle; /* Varmistaa, että ikonit ovat keskellä pystysuunnassa */
    }

    .card-tools, .tool-button span
    {
        font-family: 'Roboto', sans-serif; /* Käytetään Robotoa myös työkalupalkissa */
        font-size: 12px; /* Pienempi fonttikoko työkalupalkin teksteille */
    }


.whatsapp-qr
{
    text-align: center;
    padding: 20px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin: 20px auto;
    width: fit-content;
}

    .whatsapp-qr h2
    {
        color: #4CAF50;
    }

    .whatsapp-qr p
    {
        color: #333;
        max-width: 300px;
        margin: 10px auto;
    }

.qr-container img
{
    width: 200px; /* Aseta QR-koodin koko */
    height: auto;
    margin: 20px 0;
}



/* Specific styles for tablet and mobile */
@media (max-width: 900px)
{ /* This covers both mobile and tablet */


    .card-tools-buttons
    {
        margin-left:auto;
        margin-right:auto;
        flex-direction: row;
        width: 100%;
        justify-content: space-evenly;
    }

    .card-tools
    {
        order: 3; /* Tools go to the bottom */
        width: 100%; /* Full width for easier access */
        flex-direction: row; /* Align tools horizontally */
        flex-wrap: wrap;
    }

    .tool-button i
    {
        font-size: 1.3em; /* Smaller icons for mobile */
    }

    .tool-header
    {
        font-size: 1.5em; /* Even smaller icons for mobile */
        flex-basis: 100%;
        margin-left: auto;
        margin-right: auto;
    }

}

@media (max-width: 600px)
{ /* Mobile specific styles */

    .tool-button i
    {
        font-size: 1.2em; /* Even smaller icons for mobile */
    }
}
