html,
body {
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
    overflow: hidden;
    background-color: #313132;
}

.background-container {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Tiled background image */
.background-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/images/dbgrid@2x.png');
    background-repeat: repeat;
    background-attachment: fixed;
    background-size: 26px 26px;
    /* grid image size */
    z-index: 2;

    opacity: 0;
    animation: gridFade .5s ease-in forwards;
}

@keyframes gridFade {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Radial gradient as solid colors, no blending */
.background-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle,
            #313132 0%,
            #272728 40%,
            #1d1d1d 70%,
            #1c1c1b 100%);
    background-blend-mode: overlay;
    z-index: 1;
    pointer-events: none;
}

.content {
    font-family: "Lucida Grande";
    color: white;
    position: relative;
    z-index: 3;
    padding: 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
    height: 100%;
    box-sizing: border-box;
}

.interactive-example {
    position: relative;
    width: 100%;
    min-height: 300px;
    /* tallest iframe */
    display: flex;
    justify-content: center;
    align-items: center;
}

.interactive-example iframe {
    position: absolute;
    transition: transform 0.3s ease;
}

/* middle one always centered */
.interactive-example iframe:nth-child(2) {
    position: relative;
    /* center stays in flow */
    z-index: 2;
}

/* left one */
.interactive-example iframe:nth-child(1) {
    transform: translateX(-220px);
}

/* right one */
.interactive-example iframe:nth-child(3) {
    transform: translateX(220px);
}


.ultrabutton {
    display: inline-block;
    padding: 8px 22px;
    font-size: 14px;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
    border-radius: 12px;
    border: 1px solid #4a4a4a;

    /* aqua gradient */
    background: linear-gradient(to bottom,
            #6cb6ff 0%,
            /* light highlight */
            #3a9eff 50%,
            /* mid */
            #1f7fe0 51%,
            /* subtle split for shine */
            #1365c2 100%
            /* deep bottom */
        );

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.6),
        /* top inner highlight */
        0 2px 4px rgba(0, 0, 0, 0.4);
    /* drop shadow */

    text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.4);
    /* embossed text */
    transition: all 0.15s ease;
    cursor: pointer;
}

.ultrabutton:hover {
    background: linear-gradient(to bottom,
            #7bc2ff 0%,
            #45a7ff 50%,
            #238ae6 51%,
            #1871c9 100%);
}

.ultrabutton.secondary {
    background: linear-gradient(to bottom,
            #555 0%, #444 50%, #333 51%, #222 100%);
    border-color: #333;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 1px 2px rgba(0, 0, 0, 0.4);
    font-weight: normal;
    color: #eee;
}

.ultrabutton:active {
    box-shadow:
        inset 0 2px 4px rgba(0, 0, 0, 0.5);
    /* pressed look */
    transform: translateY(1px);
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.breadcrumb {
    background-image: url("/images/breadcrumb_background_dark.png");
    bottom: 0px;
    font-size: 10px;
    height: 15px;
    left: 0px;
    right: 0px;
    padding: 3px 10px 0px 30px;
    position: fixed;
    z-index: 901;
    overflow: visible;
    border-top: 1px solid rgb(36, 37, 41);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.breadcrumb-left {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.breadcrumb-right {
    overflow: visible;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.breadcrumb-left {
    text-align: left;
}

.breadcrumb-right {
    text-align: right;
    padding-right: 20px;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: white;
    text-decoration: underline;
}

/* Dropdown styles */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    cursor: pointer;
    user-select: none;
    color: #6cb6ff !important;
}

.dropdown-toggle:hover {
    color: #7bc2ff !important;
}

.dropdown-menu {
    position: absolute;
    bottom: 100%;
    right: 0;
    background-color: #2a2a2b;
    border: 1px solid #4a4a4a;
    border-radius: 4px;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.3);
    min-width: 180px;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(3px);
    transition: all 0.2s ease;
    margin-bottom: -3px;
    pointer-events: none;
    padding-bottom: 3px;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-menu a {
    display: block;
    padding: 8px 12px;
    color: white;
    text-decoration: none;
    font-size: 10px;
    border-bottom: 1px solid #3a3a3b;
    white-space: nowrap;
}

.dropdown-menu a:last-child {
    border-bottom: none;
}

.dropdown-menu a:hover {
    background-color: #3a3a3b;
    text-decoration: none;
}

.dropdown-menu a.disabled {
    color: #666;
    cursor: not-allowed;
    opacity: 0.5;
}

.dropdown-menu a.disabled:hover {
    background-color: transparent;
    color: #666;
}

.section {
    width: 100%;
    text-align: center;
}

@media (max-width: 700px) {

    /* place first section at top and last at bottom; middle section will be centered between them */
    .content {
        justify-content: space-between;
        align-items: center;
        height: 100%;
        /* restore original inset so title/buttons aren't flush to the edges */
        padding: 20px;
        /* give extra bottom room so buttons sit above the fixed breadcrumb */
        padding-bottom: 60px;
    }

    .interactive-example {
        /* occupy the flexible middle area and center the visible iframe */
        flex: 1;
        min-height: 0;
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        box-sizing: border-box;
        margin-top: auto;
        margin-bottom: auto;
        overflow: visible;
        /* do not clip native-sized iframe */
    }

    .interactive-example iframe {
        /* hide all iframes by default on mobile but keep their native sizes intact */
        display: none !important;
        position: relative !important;
        /* bring into normal flow */
        transform: none !important;
        left: auto !important;
        right: auto !important;
        top: auto !important;
        margin: 0 auto;
        /* DO NOT set width/height/max-width/max-height — preserve iframe attributes */
    }

    .interactive-example iframe.mobile-visible {
        display: block !important;
        position: relative !important;
    }

    .button-group {
        flex-direction: column;
        gap: 0.5rem;
        /* keep similar vertical spacing to desktop */
        margin-top: 20px;
        margin-bottom: 8px;
    }

    /* Mobile dropdown adjustments */
    .dropdown-menu {
        right: -10px;
        min-width: 160px;
    }
}