:root {
    --background-color: #222;
    --banner-color: #222;
    --dark-color: #F58F7C;
    --offwhite: #f2f3f4;
}

body {
    font-family: Arial, sans-serif;
    background-color: var(--background-color);
    margin: 0;
    padding: 0;
    color: var(--offwhite);
}

.nav-link.active {
    text-decoration: underline wavy;
    text-underline-offset: 4px;
}

.container-fluid {
    margin-top: -1rem;
    padding-top: 1rem;
    padding-bottom: 0.5rem;
    background-color: var(--banner-color);
    border-bottom: 5px solid var(--dark-color);
    padding-right: 2rem;
    padding-left: 1rem;

    font-family: "DynaPuff", serif;
    font-optical-sizing: auto;
    font-style: normal;
}

.navbar {
    position: sticky;
    top: 0;
    z-index: 1020;
}

.navbar-brand {
    letter-spacing: 0.25rem;
    font-size: 1.5rem;
    color: var(--dark-color);
}

.navbar-brand:hover {
    color: var(--offwhite);
}

.navbar-tagline {
    font-size: 0.9rem;
}

.bio {
    font-family: "Molengo", serif;
    font-size: 1.2rem;
    color: var(--offwhite);
    line-height: 1;
    margin: 20px;
}

.card {
    cursor: pointer;
    border: 1px solid var(--offwhite);
    box-shadow: 3px 3px 10px var(--dark-color);
    border-radius: 0.5rem;
    background-color: var(--offwhite);
}

.modal-content img {
    width: 100%;
    height: auto;
}

.card-columns {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.card {
    width: 24rem;
    margin: 0;
    padding: 1.5rem 1.5rem 0.5rem 1.5rem;
}

.card-title {
    margin-left: -0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 1.5em;
}

.card-text {
    font-size: 1em;
    color: black;
}

.modal-content {
    color: black;
}

.mt-4 {
    padding-left: 1rem;
}

.nav-item.dropdown:hover .dropdown-menu {
    display: block;
}

.nav-item.dropdown {
    position: relative;
}

.dropdown-menu {
    background-color: #333;
    border-radius: 5px;
    right: auto;
    left: 10px;
    width: 100px;
    padding: 0;
    border: none;
    box-sizing: border-box;
    min-width: 0;
}

.dropdown-item {
    color: var(--offwhite);
    padding: 5px;
    padding-left: 10px;
    font-size: 0.75rem;
    overflow: hidden;
    white-space: nowrap;
}

.dropdown-item:hover {
    background-color: #555;
    color: var(--offwhite);
}

.navbar-dark .navbar-nav .nav-link {
    color: var(--offwhite);
}

.carousel-inner {
    aspect-ratio: 3 / 2;
}

.maddie {
    width: 40%;
    min-width: 300px;
    max-width: 400px;
}

.maddie-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 30px;
    padding-right: 10%;
}

.maddie-container img {
    border: 4px solid var(--dark-color);
    border-radius: 50%;
}

.dim {
    font-family: "Orbitron", serif;
    color: lightskyblue;
    text-shadow: 2px 2px 4px black;
    font-weight: 500;
    font-size: 1.1rem;
}

.ece {
    font-family: "Hi Melody", serif;
    font-weight: bold;
    color: plum;
    text-shadow: 2px 2px 4px black;
    font-size: 1.7rem;
}

@media screen and (max-width: 768px) {
    .maddie-container {
        flex-direction: column;
        align-items: center;
        padding: 30px;
    }

    .maddie-container img {
        width: 80%;
        max-width: 300px;
    }

    .bio {
        text-align: center;
        margin-top: 20px;
    }
}

.ribbon {
    position: absolute;
    top: 18px;
    right: -29px;
    background: red;
    color: white;
    padding: 5px 20px;
    font-size: 12px;
    font-weight: bold;
    transform: rotate(45deg);
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    clip-path: polygon(23% 0%, 77% 0%, 100% 100%, 0% 100%);
}

.coming-soon {
    pointer-events: none;
}



/* ------------------------------------------------------ */
/*      NEW — PREVENT IMAGE FLASHING / POP-IN            */
/* ------------------------------------------------------ */

/* Card cover images */
.card img {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.card img.loaded {
    opacity: 1;
}

/* Modal carousel images */
.carousel-inner img {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-inner img.loaded {
    opacity: 1;
}

/* Keep carousel space stable to prevent layout jump */
.carousel-inner {
    aspect-ratio: 16 / 9;
    background-color: #000; /* prevents white flash behind images */
}
