div#intro {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 2em;
}

div#intro button {
    margin: 0 auto;
    display: block;
}

div.calc-section-container {
    display: grid;
    gap: 5px;
    grid-template-columns: 1fr 1fr;
}

div.calc-section {
    font-size: 1.5em;
    background-color: #5c0e0e;
    color: white;
    padding: 0.5em 1em;
    opacity: 1;
    transition: opacity 1s;
}

div.calc-section.active {
    background-color: #cf1f1f;
    grid-column: span 2;
}

div.calc-section.hidden {
    display: none;
    opacity: 0;
    transition: opacity 1s;
}

div.calc-section.remain-hidden {
    display: none;
}

div.calc-section.remain-hidden.active {
    display: block;
}

div.calc-section.active span {
    display: none;
}

div.calc-section a {
    color: yellow;
    float: right;
}

div.calc-section-details {
    display: none;
}

div.calc-section-details.active {
    display: block;
    grid-column: span 2;
}

div.calc-section-details h4 {
    font-size: 1.5em;
    font-weight: 800;
    margin-top: 1em
}

div.calc-section-details .button-wrapper {
    margin: 0.5em 0 0.75em 0;
}
div.calc-section-details .option-button-wrapper {
    margin: 1em 0 0.5em 0;
}
div.calc-section-details .btn-small {
    margin-bottom: 0.5em;
}

div.calc-section-details input.form-control,
div.calc-section-details select.form-control {
    width: 300px;
}

div.calc-section-details textarea.form-control {
    width: 600px;
}

div.calc-section-details .radio-buttons {
    margin: 0.75em 0 1em 0;
}

#calculator.employee .employee {
    display: block;
}

#calculator.employee .myself {
    display: none;
}

#calculator.myself .employee {
    display: none;
}

#calculator.myself .myself {
    display: block;
}

div.calculating {
    font-size: 1.5em;
    text-align: center;
    margin: 2em 0;
}

span.spinner {
    border: 4px solid #f3f3f3; /* Light grey */
    border-top: 4px solid #3498db; /* Blue */
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 2s linear infinite;
    display: inline-block;
    vertical-align: middle;
    margin-right: 10px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

div.result-container {
    display: none;
}

div.result-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 1em;
}

#calculator.myself div.result-grid {
    grid-template-columns: 1fr;
}

#calculator.myself div.video-container {
    display: none;
}

div.started,
div.left {
    display: none;
}

div.calc-section-details .work-pattern input.form-control {
    width: 80px;
    margin: 0 10px 10px 10px;
}

div.calc-section-details .work-pattern .btn.btn-small {
    padding: 18px 16px;
}

#new-pattern-template {
    display: none;
}

div.entitlement-container {
    display: inline-block;
    align-self: center;
    margin: 1em auto;
    text-align: center;
}

div.entitlement {
    background-color: #f7d70f;
    font-size: 3em;
    border-radius: 0.5em;
    font-weight: 700;
    margin: 1em 0 0.5em 0;
    text-align: center;
    padding: 1em 2em;
}

div.entitlement span.type {
    font-size: 0.75em;
    font-weight: 300;
}

div.entitlement span.inc {
    display: block;
    font-size: 0.4em;
    font-weight: 300;
}

div#breakdown {
    overflow-x: auto;
}

table.results {
    margin: 20px auto;
    border-collapse: collapse;
}

table.results > thead th {
    text-align: left;
    font-size: 20px;
}

table.results > tbody > tr > td {
    padding: 10px;
    border: solid 1px #bbb;
    font-size: 20px;
}

table.results > tbody td.work-pattern {
    padding: 0px;
}

table.results > tbody td.equals {
    border-right: 0px;
}

table.results > tbody td.result {
    border-left: 0px;
}

table.results > tfoot th {
    text-align: right;
    font-size: 20px;
}

table.results > tbody > tr > td.work-pattern table thead th {
    font-size: 0.75em;
    width: 40px;
    min-width: 40px;
    background-color: #d4d0f9;
    color: #fff;
    padding: 10px 0;
}

table.results > tbody > tr > td.work-pattern table tbody td {
    text-align: center;
    font-size: 12px;
}

label {
    font-size: 1.25em;
}

table.work-pattern {
    margin: 1em 0;
}

table.work-pattern td.odd {
    background-color: #d4d0f9;
    text-align: center;
    width: 100px;
}

table.work-pattern td.even {
    background-color: #e4e0ff;
    text-align: center;
    width: 100px;
}

table.work-pattern td label {
    display: block;
    padding: 0.75em 1.25em;
    width: 100px;
}

.video-container {
    position: relative;
    align-self: center;
    width: 80%;
    margin: 0 auto;
}

.video-container video {
    width: 100%;
    border: solid 1px #333;
}

.video-container .controls {
    position: absolute;
    top: 0;
    color: #fff;
    padding: 5px;
    cursor: pointer;
}

.video-container a.video-button {
    position: absolute;
    top: 84%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: none;
    z-index: 10;
    border: solid 2px #fff;
    padding: 6px 24px;
}



@media (max-width: 834px) {
    div.page-title h1 {
        margin-top: 0.5em;
        font-size: 4em;
    }

    div.calc-section {
        font-size: 1.2em;
        padding: 5px 10px;
        margin-bottom: 2px;
    }
}
@media (max-width: 1054px) {
    div#intro {
        grid-template-columns: 1fr;
        margin-top: 0;
    }
    div#intro div.video-container {
        margin-top: 1.5em;
        width: 100%;
    }
    div.calc-section-details .button-wrapper {
        margin: 1em 0 1em 0;
    }
    div.calc-section-container {
        display: flex;
        flex-direction: column;
    }
    div.calc-section-details .radio-buttons label {
        display: block;
        margin: 0.5em 0;
    }
    div.result-grid {
        display: flex;
        flex-direction: column;
    }
    div.calc-section-details h4 {
        margin-top: 0.5em
    }
    div.entitlement {
        margin-top: 0.5em;
    }
    div.result-grid div.video-container {
        margin-bottom: 1.5em;
        width: 100%;
    }
    div.mobile-scroll {
        overflow-x: auto;

    }
    div.modal-dialog {
        padding: 1em;
    }
}
