/* Variables */
:root {
    --baby-blue: #CDEAFE;
    --midnight-blue: #27516D;
    --cool-blue: #002F63;
    --mirage: #121B25;
    --black: #000;
    --white: #fff;
    --error-color: #dc3545;
    --accent-yellow: rgba(242, 205, 16, 1);
    --accent-yellow-50: rgba(242, 205, 16, 0.5);
    --accent-red: rgba(255, 26, 26, 1);
    --accent-red-50: rgba(255, 26, 26, 0.5);
    --accent-blue: rgba(3, 101, 244, 1);
    --accent-blue-50: rgba(3, 101, 244, 0.5);
    --accent-green: rgba(0, 159, 16, 1);
    --accent-green-50: rgba(0, 159, 16, 0.5);
    --medium-grey: rgba(203, 213, 225, 1);
    --light-grey: rgba(226, 232, 240, 1);
    --dark-grey: rgba(71, 85, 105, 1);
}

/* .league-spartan-<uniquifier> {
  font-family: "League Spartan", sans-serif;
  font-optical-sizing: auto;
  font-weight: <weight>;
  font-style: normal;
} */

/* Reset and Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    line-height: 1.2;
    padding: 5rem 0 10rem;
    margin: 0 auto;
    background-color: var(--baby-blue);
    font-family: "League Spartan", sans-serif;
}

/* Screen Visibility */
.screen {
    display: none;
    max-width: 800px;
    margin: 0 auto;
}

.screen.active {
    display: block;
}

/* Modal */
DIALOG.modal {
    margin: auto;
    width: min(90dvw, 30rem);
    padding: 2rem;
    border-radius: 1rem;
    border: 5px solid var(--midnight-blue);
    background-color: var(--white);
}

/* Links */
A,
A:visited {
    color: var(--accent-blue);
    text-decoration: underline;
}

/* Typography */
h1 {
    font-weight: 800;
    font-style: normal;
    font-size: 3rem;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--mirage);
    line-height: 110%;
    font-family: "Neuton", serif;
}

h2 {
    font-size: 2rem;
    margin-bottom: 0;
    font-family: "Neuton", serif;
}

H1,
H2,
H3 {
    EM {
        font-style: normal;
        text-decoration: underline;
        text-decoration-thickness: 5px;
        text-decoration-color: var(--accent-yellow);
        text-decoration-skip-ink: none;
    }
}

p,
li {
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.details {
    font-size: 1rem;
}

.centered {
    text-align: center;
}

.subtext {
    font-size: 14px;
    color: #666;
}

.privacy-notice {
    font-size: 14px;
    padding: 10px;
    background: #f0f0f0;
    margin-bottom: 20px;
}

/* Boxes */
.box {
    padding: 1.5rem;
    margin-bottom: 2rem;
    background-color: var(--white);
    border-radius: 1rem;
    border: 5px solid var(--midnight-blue);

    UL {
        margin-left: 2rem;
    }

    P:last-child {
        margin-bottom: 0;
    }
}

.dashed {
    border-style: dashed;
    background-color: var(--baby-blue);

    H2 {
        background-color: var(--baby-blue);
        padding: 1rem;
        position: relative;
        margin-top: -4rem;
        width: fit-content;
        margin-inline: auto;
        margin-bottom: 0;
    }
}

/* Buttons */
button,
A.button {
    padding: 12px 24px;
    font-size: 16px;
    cursor: pointer;
    border: none;
    background: var(--mirage);
    color: var(--white);
    border-radius: 4rem;
    display: inline-block;
    text-transform: uppercase;
    text-decoration: none;
    font-weight: bold;
}

button:hover,
A.button:hover {
    background: var(--cool-blue);
}

BUTTON.secondary,
A.button.secondary {
    background: var(--light-grey);
    color: var(--midnight-blue);
}

BUTTON.secondary:hover,
A.button.secondary:hover {
    background: var(--light-grey);
    color: var(--mirage);
}

/* Forms */
form {
    margin: 20px 0;
}

label {
    display: block;
    margin: 10px 0;
    cursor: pointer;
}

input[type="radio"] {
    margin-right: 8px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input[type="date"],
.form-group input[type="text"] {
    width: 100%;
    padding: 8px;
    font-size: 16px;
    border: 1px solid #ccc;
}

.form-group input.error {
    border-color: red;
}

.error-message {
    color: red;
    font-size: 14px;
    margin-top: 5px;
}

/* Trips List */
.trips-list {
    margin: 20px 0;
}

.trip-card {
    display: grid;
    grid-template-columns: auto min-content;
    gap: 1rem;
    align-items: center;
}

.trip-card-header {
    grid-column: 1 / 2;
}

.trip-card-dates {
    font-weight: bold;
}

.trip-card-countries {
    color: #666;
}

.trip-card-countries .country-emoji {
    display: inline-block;
    font-size: 1.5rem;
    vertical-align: middle;
}

.trip-card-actions {
    grid-column: 2 / 3;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.trip-card-actions button {
    padding: 8px 16px;
    font-size: 14px;
}

.issue-card {}

.issue-card H2 {
    margin-bottom: 1rem;
    display: grid;
    grid-template-columns: min-content auto;
    gap: 1rem;
    align-items: center;
}

.issue-card H2 .issue-icon {
    font-size: 3rem;
}

.issue-card .issue-remediation {}

.issue-card.all_clear {
    .issue-remediation {
        display: none;
    }
}

.btn-add-trip {
    display: block;
    width: 100%;
    margin: 20px 0;
}

/* Navigation Buttons */
.navigation-buttons {
    margin-top: 30px;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

/* Modal Actions */
.modal-actions {
    margin-top: 30px;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

/* Countries Autocomplete */
.countries-dropdown {
    border: 1px solid #ccc;
    max-height: 200px;
    overflow-y: auto;
    display: none;
    background: white;
    position: relative;
    z-index: 10;
}

.countries-dropdown.open {
    display: block;
}

.country-option {
    padding: 8px;
    cursor: pointer;
}

.country-option:hover {
    background: #f0f0f0;
}

.selected-countries {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.country-tag {
    background: #e0e0e0;
    padding: 5px 10px;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.country-tag-remove {
    cursor: pointer;
    font-weight: bold;
}

/* Results Screen */
.results-headline {}

.results-headline.no-issues {
    color: green;
}

.results-headline.issues {
    color: red;
}

.results-summary {
    font-size: 18px;
    margin-bottom: 15px;
}

.results-message {
    font-size: 16px;
    margin-bottom: 20px;
}

.results-context {
    padding: 15px;
    background: #f0f0f0;
    margin: 20px 0;
}

#learn-more {
    margin-top: 3rem;

    P {
        font-size: 1.25rem;
        text-align: center;
    }
}


LABEL.box:has(INPUT[type="radio"]:checked) {
    box-shadow: inset 0 0 0 4px var(--accent-yellow);
    background-image: url('../radio-selected.svg');
}

LABEL.box:has(INPUT[type="radio"]) {
    padding-left: 5rem;
    background-image: url('../radio-unselected.svg');
    background-repeat: no-repeat;
    background-position: 1.5rem 1.75rem;
}

LABEL.box INPUT[type="radio"] {
    display: none;
}

FOOTER {
    position: fixed;
    bottom: 0;
    width: 100%;
    padding: 1rem 2rem;
    background-color: var(--mirage);
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;

    A#footer-logo-link {
        display: block;
        padding: 0;

        IMG {
            max-width: 10rem;
            display: block;
        }
    }

    P {
        color: var(--white);
        margin: 0;

        A,
        A:visited {
            color: var(--white);
            text-decoration: none;
        }

        A:hover {
            text-decoration: underline;
        }
    }
}


P.calculating-message {
    background-color: var(--midnight-blue);
    color: var(--white);
    padding: 1rem;
    border-radius: 1rem;
    animation: 1s ease-in-out fade-in;
    animation-delay: var(--animation-delay);
    animation-fill-mode: forwards;
    opacity: 0;
}

@keyframes fade-in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}



@media (max-width: 762px) {
    BODY {
        padding: 1rem;
    }

    H1 {
        font-size: 2.5rem;
    }

    H2 {
        font-size: 1.5rem;
    }

    .issue-card H2 {
        align-items: start;
    }

    .trip-card {
        display: grid;
        grid-template-columns: 1fr;
        grid-template-rows: min-content auto;
        gap: 1rem;
        align-items: center;
        padding-top: 1rem;

        .trip-card-actions {
            grid-row: 2;
            grid-column: 1;
            display: flex;
            flex-direction: row;
            gap: 1rem;
        }
    }

    FOOTER {
        position: relative;
        margin-top: 8rem;
        margin-bottom: 2rem;
        border-radius: 1rem;
        flex-direction: column;
        gap: 1rem;

        P {
            text-align: center;
        }
    }
}