// Bootstrap overrides

code {
    color: $color-grey-dark;
}

a, a:hover, a:visited, a:active {
    color: $color-primary-dark;
}

ul.spaced,
ol.spaced {
    > li {
        margin-bottom: 1rem;
    }
}

.list-group {
    border: $color-grey-light 2px solid;
    border-radius: 0;
}

// Custom styles

.page-header {
    padding-bottom: 8px;
    border-bottom: 2px $color-primary solid;

    .logo-highlight {
        color: $color-primary;
    }
}

#tips-box {
    ul {
        max-height: 400px;
        overflow-y: auto;
    }
}

.nav-btns {
    &.nav-btns-top {
        margin-top: 0;
        margin-bottom: 0;
        padding: 0;
    }

    &.nav-btns-bottom {
        margin-top: 1.5rem;
        margin-bottom: 0;
        padding: 0;
    }
}
.nav-btn {
    background-color: lighten($color-primary, 10%);
    border: none;
    border-radius: 10px;
    color: $white;
    padding: 8px 16px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    &:hover {
        background-color: $color-primary-darker;
        text-decoration: none;
    }
    a {
        color: $white;
        text-decoration: none;
    }
    &:disabled {
        color: $color-grey-light;
        background-color: $color-grey;
        border-color: $color-grey-dark;
    }
}

ul.nav-list {
    padding: 0;
    margin: 0;
    list-style-type: none;
    li {
        margin: 0 auto;
        padding: 0;
        display: block;
        text-align: center;
        font-weight: bold;
        &.nav-2 {
            margin: 8px 0;
        }
    }

    @media (min-width: 600px) {
        li {
            display: inline-block;
            &.nav-1 {
                margin: 0 0 8px 0;
            }
            &.nav-2 {
                float: right;
                margin: 0 0 8px 0;
            }
        }
    }
}

footer {
    font-size: 80%;
    color: $color-grey-dark;
}

pre {
    overflow-x: auto;
}

div.tips-list {
    margin: 1em 0;
}

div.frame {
    margin: 0.5em 0;
    padding: 0;
    border: 1px $color-grey solid;
    background-color: $color-grey-light;
    font-size: 90%;
}

div.frame {
    table {
        width: 100%;
        box-sizing: border-box; ;
        margin: 0px;
        padding: 20px;

        caption {
            caption-side: top;
            padding: 4px;
            margin: 0;
            background-color: $color-grey-dark;
            color: $white;
        }

        tr {
            border-bottom: 1px solid $color-grey;
            &:last-child {
                border-bottom: none;
            }
            td {
                background-color: $color-grey-lighter;
                border-right: 1px solid $color-grey;
                vertical-align: top;
                &:last-child {
                    border: none;
                }
            }
            th {
                background-color: $color-grey-light;
                border-right: 1px solid $color-grey;
                vertical-align: middle;
                text-align: center;
                &:last-child {
                    border: none;
                }
            }
        }

    }
}

table.infotable{
    font-size: 80%;
    color: $color-grey-dark;
    margin: 2em 0 0 0;
    border-top: 1px $color-grey solid;
    width: 100%;
    th {
        text-align: left;
        font-weight: normal;
        width: 33%;
    }
}

p.callout,
div.callout {
    background-color: $color-secondary-1-pale;
    border:  $color-secondary-1-lighter 1px solid;
    border-left-width: 4px;
    padding: 4px;

    .caption {
        font-weight: bold;
        margin-bottom: 4px;
    }
    .content {
        margin-bottom: 4px;
    }

    a {
        color: $color-secondary-1-dark;
    }
}

blockquote {
    border-left: 5px solid $color-grey-light;
    padding-left: 1rem;
}

.blockquote{
    margin-bottom: 1rem;
    font-size: 1.25rem
}

.card {
    margin-bottom: 1rem;
}

.xref {
    background-color: $color-complement-pale;
    border: $color-complement-lighter 1px solid;
    border-left-width: 4px;
    padding: 4px;
    a {
        color: $color-complement-dark;
    }
}

.question {
    margin-left: 0;
    margin-right: 0em;
    margin-bottom: 8px;
    border:$color-secondary-2-lighter 1px dotted;
    border-left: $color-secondary-2-lighter 2em solid;
    background-color: $color-secondary-2-pale;
    padding: 0.25em 0.25em 0.25em 0.5em;
    a {
        color: $color-secondary-2-darker;
    }
    .title {
        font-style: italic;
        font-weight: bold;
        font-variant: small-caps;
        color: $color-secondary-2-darker;
    }
    .content {
        margin-top: 0.5em;
    }
}

div.credits,
p.credits {
    background-color: $color-primary-pale;
    border:  $color-primary-lighter 1px solid;
    border-left-width: 4px;
    padding: 4px;
    margin-left: 40px;
    text-align: right;
    font-size: 80%;
}

div.demo-block {
    border: 1px silver solid;
    background-color: $color-grey-lighter;
    padding: 0 0.5em;
    .reporef {
        font-size: 80%;
        background-color: $color-complement-pale;
        border: $color-complement-lighter 1px solid;
        padding: 0.5em;
        a {
            color: $color-complement-dark;
        }
    }
}

// Styling for cookie confirmation pop-up
// ** Custom
#cookie-popup {

    background-color: $color-primary-darker;
    color: white;
    border: 1px white solid;
    padding: 1rem;
    font-size: 0.8rem;
    position: fixed;
    bottom: 0px;
    z-index: 999;
    margin: 0;
    width: 100%;

    &:hover {
        opacity: 1;
    }

    p.cookie-msg {
        padding: 0;
        margin-bottom: 0.3rem;

        a {
            text-decoration: underline;
            color: white;
        }
    }

    p.cookie-btn {

        padding: 0;
        text-align: center;
        margin-bottom: 0;
        margin-top: 0;

        button {

            border: 1px white solid;
            margin-right: 1rem;
            font-size: 0.8rem;
            padding: 2px 8px;

            &:last-child {
                margin-right: 0;
            }
        }
    }
}

#cookie-consent--opt-out-text {
    display: none;
}
