/* ==========================================================
   MANEIDR
   COOKIE CONSENT MANAGER
   CSS
   Version 1.0
========================================================== */


/* ==========================================================
   MANEIDR COLOURS
========================================================== */

:root {

    --maneidr-teal: #125952;
    --maneidr-teal-dark: #0A3F3A;
    --maneidr-teal-hover: #0D4742;

    --maneidr-text: #26353A;
    --maneidr-text-light: #66737A;

    --maneidr-border: #E1E7E5;

}


/* ==========================================================
   BOX SIZING
========================================================== */

#maneidr-cookie-banner,
#maneidr-cookie-banner *,
#maneidr-cookie-preferences,
#maneidr-cookie-preferences * {

    box-sizing: border-box;

}


/* ==========================================================
   COOKIE BANNER
========================================================== */

#maneidr-cookie-banner {

    position: fixed;

    left: 50%;

    bottom: 24px;

    transform:
        translateX(-50%)
        translateY(12px);

    width: min(92%, 760px);

    background: #ffffff;

    color: var(--maneidr-text);

    border: 1px solid rgba(18,89,82,.12);

    border-radius: 14px;

    box-shadow:
        0 18px 50px rgba(0,0,0,.22);

    padding: 26px 28px;

    z-index: 999999;

    display: flex;

    flex-direction: column;

    gap: 18px;

    opacity: 0;

    visibility: hidden;

    transition:
        opacity .30s ease,
        transform .30s ease,
        visibility .30s ease;

}


#maneidr-cookie-banner.show {

    opacity: 1;

    visibility: visible;

    transform:
        translateX(-50%)
        translateY(0);

}


/* ==========================================================
   COOKIE HEADER
========================================================== */

.maneidr-cookie-header {

    display: flex;

    align-items: center;

    gap: 16px;

}


.maneidr-cookie-shield {

    width: 48px;

    height: 48px;

    object-fit: contain;

    flex-shrink: 0;

}


#maneidr-cookie-banner h3 {

    margin: 0;

    color: var(--maneidr-teal-dark);

    font-size: 23px;

    font-weight: 700;

    line-height: 1.3;

}


/* ==========================================================
   COOKIE TEXT
========================================================== */

#maneidr-cookie-banner p {

    margin: 0;

    color: #35434A;

    font-size: 15px;

    line-height: 1.7;

}


#maneidr-cookie-banner a {

    color: var(--maneidr-teal);

    text-decoration: none;

    font-weight: 700;

}


#maneidr-cookie-banner a:hover {

    text-decoration: underline;

}


/* ==========================================================
   COOKIE BUTTONS
========================================================== */

.maneidr-cookie-buttons {

    display: flex;

    align-items: center;

    gap: 10px;

    flex-wrap: wrap;

}


.maneidr-cookie-btn {

    appearance: none;

    cursor: pointer;

    padding: 12px 22px;

    font-family: inherit;

    font-size: 15px;

    font-weight: 600;

    line-height: 1.2;

    border-radius: 7px;

    transition:
        background .25s ease,
        color .25s ease,
        border-color .25s ease,
        transform .20s ease;

}


/* ==========================================================
   ACCEPT
========================================================== */

.maneidr-cookie-accept {

    background: var(--maneidr-teal);

    border: 2px solid var(--maneidr-teal);

    color: #ffffff;

}


.maneidr-cookie-accept:hover {

    background: var(--maneidr-teal-hover);

    border-color: var(--maneidr-teal-hover);

    transform:
        translateY(-1px);

}


/* ==========================================================
   REJECT
========================================================== */

.maneidr-cookie-reject {

    background: #ffffff;

    border: 2px solid var(--maneidr-teal);

    color: var(--maneidr-teal);

}


.maneidr-cookie-reject:hover {

    background: #F3F7F6;

    transform:
        translateY(-1px);

}


/* ==========================================================
   MANAGE PREFERENCES
========================================================== */

.maneidr-cookie-manage {

    appearance: none;

    border: none;

    background: transparent;

    color: var(--maneidr-teal);

    cursor: pointer;

    padding: 10px 8px;

    font-family: inherit;

    font-size: 15px;

    font-weight: 600;

}


.maneidr-cookie-manage:hover {

    color: var(--maneidr-teal-hover);

    text-decoration: underline;

}


/* ==========================================================
   FOCUS
========================================================== */

.maneidr-cookie-btn:focus-visible,

.maneidr-cookie-manage:focus-visible,

.maneidr-cookie-close:focus-visible,

.maneidr-cookie-switch input:focus-visible + span {

    outline: 3px solid var(--maneidr-teal);

    outline-offset: 2px;

}


/* ==========================================================
   PREFERENCES OVERLAY
========================================================== */

#maneidr-cookie-preferences {

    position: fixed;

    inset: 0;

    background:
        rgba(10,30,34,.58);

    z-index: 1000000;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 20px;

    opacity: 0;

    visibility: hidden;

    transition:
        opacity .25s ease,
        visibility .25s ease;

}


#maneidr-cookie-preferences.show {

    opacity: 1;

    visibility: visible;

}


/* ==========================================================
   PREFERENCES WINDOW
========================================================== */

.maneidr-cookie-preferences-inner {

    position: relative;

    width: min(100%, 620px);

    max-height:
        calc(100vh - 40px);

    overflow-y: auto;

    background: #ffffff;

    color: var(--maneidr-text);

    border-radius: 14px;

    padding: 30px;

    box-shadow:
        0 20px 60px rgba(0,0,0,.30);

}


/* ==========================================================
   PREFERENCES HEADER
========================================================== */

.maneidr-preferences-header {

    display: flex;

    align-items: center;

    gap: 16px;

    padding-right: 40px;

    margin-bottom: 12px;

}


.maneidr-preferences-shield {

    width: 48px;

    height: 48px;

    object-fit: contain;

    flex-shrink: 0;

}


.maneidr-preferences-header h3 {

    margin: 0;

    color: var(--maneidr-teal-dark);

    font-size: 24px;

    font-weight: 700;

    line-height: 1.3;

}


/* ==========================================================
   INTRO
========================================================== */

.maneidr-cookie-preferences-intro {

    margin: 0 0 22px;

    color: #35434A;

    font-size: 15px;

    line-height: 1.7;

}


/* ==========================================================
   CLOSE BUTTON
========================================================== */

.maneidr-cookie-close {

    position: absolute;

    top: 20px;

    right: 22px;

    width: auto;

    height: auto;

    padding: 0;

    border: none;

    background: transparent !important;

    color: var(--maneidr-teal);  !important;

    box-shadow: none;  !important;

    font-family: Arial, sans-serif;

    font-size: 28px;

    font-weight: 400;

    line-height: 1;

    cursor: pointer;

    box-shadow: none;

}


.maneidr-cookie-close:hover {

    background: transparent;  !important;

    color: var(--maneidr-teal);  !important;

    box-shadow: none;  !important;

}


/* ==========================================================
   COOKIE OPTIONS
========================================================== */

.maneidr-cookie-option {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 20px;

    padding: 18px 0;

    border-top:
        1px solid var(--maneidr-border);

}


.maneidr-cookie-option-content {

    flex: 1;

    min-width: 0;

}


.maneidr-cookie-option strong {

    display: block;

    margin-bottom: 6px;

    color: var(--maneidr-teal-dark);

    font-size: 16px;

    font-weight: 700;

}


.maneidr-cookie-option p {

    margin: 0;

    color: var(--maneidr-text-light);

    font-size: 14px;

    line-height: 1.6;

}


/* ==========================================================
   ALWAYS ACTIVE
========================================================== */

.maneidr-cookie-always-on {

    flex-shrink: 0;

    color: var(--maneidr-teal);

    font-size: 13px;

    font-weight: 600;

}


/* ==========================================================
   TOGGLE
========================================================== */

.maneidr-cookie-switch {

    position: relative;

    display: block;

    flex-shrink: 0;

    width: 48px;

    height: 26px;

}


.maneidr-cookie-switch input {

    position: absolute;

    opacity: 0;

    width: 0;

    height: 0;

}


.maneidr-cookie-switch span {

    position: absolute;

    inset: 0;

    background: #D2DBD9;

    border-radius: 30px;

    cursor: pointer;

    transition:
        background .25s ease;

}


.maneidr-cookie-switch span::before {

    content: "";

    position: absolute;

    width: 20px;

    height: 20px;

    left: 3px;

    top: 3px;

    background: #ffffff;

    border-radius: 50%;

    transition:
        transform .25s ease;

}


.maneidr-cookie-switch input:checked + span {

    background:
        var(--maneidr-teal);

}


.maneidr-cookie-switch input:checked + span::before {

    transform:
        translateX(22px);

}


/* ==========================================================
   SAVE BUTTON
========================================================== */

.maneidr-cookie-preferences-buttons {

    display: flex;

    justify-content: flex-end;

    padding-top: 20px;

}


.maneidr-cookie-save {

    background:
        var(--maneidr-teal);

    border:
        2px solid var(--maneidr-teal);

    color: #ffffff;

}


.maneidr-cookie-save:hover {

    background:
        var(--maneidr-teal-hover);

    border-color:
        var(--maneidr-teal-hover);

    transform:
        translateY(-1px);

}


/* ==========================================================
   MOBILE
========================================================== */

@media (max-width: 768px) {

    #maneidr-cookie-banner {

        width:
            calc(100% - 24px);

        left: 12px;

        right: 12px;

        transform:
            translateY(12px);

        bottom: 12px;

        padding: 20px;

    }


    #maneidr-cookie-banner.show {

        transform:
            translateY(0);

    }


    #maneidr-cookie-banner h3 {

        font-size: 20px;

    }


    .maneidr-cookie-buttons {

        flex-direction: column;

        align-items: stretch;

    }


    .maneidr-cookie-btn {

        width: 100%;

    }


    .maneidr-cookie-manage {

        width: 100%;

    }


    #maneidr-cookie-preferences {

        padding: 12px;

    }


    .maneidr-cookie-preferences-inner {

        padding: 24px 20px;

        max-height:
            calc(100vh - 24px);

    }


    .maneidr-preferences-header {

        gap: 12px;

    }


    .maneidr-preferences-shield {

        width: 42px;

        height: 42px;

    }


    .maneidr-preferences-header h3 {

        font-size: 21px;

    }


    .maneidr-cookie-option {

        align-items: flex-start;

    }


    .maneidr-cookie-always-on {

        margin-top: 2px;

    }

}


/* ==========================================================
   REDUCED MOTION
========================================================== */

@media (prefers-reduced-motion: reduce) {

    #maneidr-cookie-banner,

    #maneidr-cookie-preferences,

    .maneidr-cookie-btn,

    .maneidr-cookie-manage,

    .maneidr-cookie-switch span,

    .maneidr-cookie-switch span::before {

        transition: none;

    }

}