body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #0000e8;
    color: #ffffff;
    overflow: hidden;
    height: 100vh;
    height: 100dvh;
}

/* Hide scrollbar */
body::-webkit-scrollbar {
    display: none;
}

body {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Text selection styling */
::selection {
    background: #ffff00;
    color: #000000;
}

::-moz-selection {
    background: #ffff00;
    color: #000000;
}

#container {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
}

/* Scroll-snap slideshow */
.slide-container {
    width: 100%;
    height: 100vh;
    height: 100dvh; /* exclude mobile browser chrome so slide-info isn't cut off */
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    -webkit-overflow-scrolling: touch;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.slide-container::-webkit-scrollbar {
    display: none;
}

.slide {
    width: 100%;
    height: 100vh;
    height: 100dvh; /* match container so canvas + info fit the visible viewport */
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
}

.slide-canvas {
    width: 100%;
    flex: 1;
    min-height: 0;
    cursor: pointer;
}

.slide-canvas canvas {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

.slide-info {
    padding: 16px 30px 24px;
    color: #ffffff;
    background: #0000e8;
    flex-shrink: 0;
}

.slide-info .location-name {
    font-weight: bold;
    margin-bottom: 6px;
    font-size: 20px;
    color: #ffffff;
}

.slide-info .weather-data {
    font-size: 20px;
    color: #ffffff;
    line-height: 1.5;
}

.loading {
    text-align: center;
    padding: 50px;
    font-size: 18px;
    color: #ffffff;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
}

.loading-spinner {
    display: inline-block;
    width: 30px;
    height: 30px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-dots {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 80px;
    margin: 20px auto;
}

.loading-dots div {
    position: absolute;
    top: 33px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffffff;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.loading-dots div:nth-child(1) {
    left: 8px;
    animation: lds-ellipsis1 0.6s infinite;
}

.loading-dots div:nth-child(2) {
    left: 8px;
    animation: lds-ellipsis2 0.6s infinite;
}

.loading-dots div:nth-child(3) {
    left: 32px;
    animation: lds-ellipsis2 0.6s infinite;
}

.loading-dots div:nth-child(4) {
    left: 56px;
    animation: lds-ellipsis3 0.6s infinite;
}

@keyframes lds-ellipsis1 {
    0% {
        transform: scale(0);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes lds-ellipsis3 {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(0);
    }
}

@keyframes lds-ellipsis2 {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(24px, 0);
    }
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
}

.modal-content {
    position: relative;
    background-color: #fefefe;
    margin: 5% auto;
    padding: 0;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.close {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 25px;
    font-size: 35px;
    font-weight: bold;
    z-index: 1001;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: white;
}

.modal-body {
    padding: 20px;
    text-align: left;
}

.modal-body iframe {
    width: 100%;
    height: 300px;
    border: 0;
}

.button-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.modal-body a {
    display: block;
    padding: 12px 20px;
    background: #0000e8;
    color: white;
    text-decoration: none;
    font-size: 13px;
    text-align: center;
    border-radius: 3px;
}

.modal-body a:hover {
    background: #555555;
}

.modal-note {
    font-size: 14px;
    color: white;
    margin-top: 10px;
    line-height: 1.4;
}


.location-prompt {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
    text-align: center;
    z-index: 2000;
    color: black;
    max-width: 400px;
}

.location-prompt h3 {
    margin-bottom: 20px;
    font-size: 18px;
    font-family: "Times New Roman", Times, serif;
}

.location-prompt p {
    margin-bottom: 25px;
    font-size: 14px;
    line-height: 1.5;
    font-family: "Times New Roman", Times, serif;
}

.button-group {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.btn {
    background: transparent;
    color: #000;
    border: 1px solid #000;
    padding: 8px 20px;
    cursor: pointer;
    font-size: 16px;
    font-family: "Times New Roman", Times, serif;
    transition: all 0.2s;
}

.btn:hover {
    background: #000;
    color: white;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 1999;
}

.info-button {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 30px;
    height: 30px;
    background: transparent;
    border: 3px solid white;
    border-radius: 50%;
    cursor: pointer;
    z-index: 3000;
    font-size: 16px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-family: Arial, sans-serif;
}

/* Mobile adjustments */
@media (max-width: 767px) {
    .info-button {
        display: flex;
    }

    .slide-info {
        padding: 10px 16px 14px;
    }

    .slide-info .location-name {
        font-size: 13px;
        margin-bottom: 4px;
    }

    .slide-info .weather-data {
        font-size: 11px;
        line-height: 1.4;
    }

    .description {
        font-size: 14px;
        padding: 16px;
    }

    .description h3 {
        font-size: 14px;
    }

    .api-list {
        font-size: 14px;
    }

    .close-button {
        font-size: 24px;
    }

    #distant-winds-references,
    #distant-winds-references h2,
    #distant-winds-references h3,
    #distant-winds-references p,
    #distant-winds-references ul,
    #distant-winds-references li,
    #distant-winds-references code {
        font-size: 14px;
    }

    .location-prompt h3 {
        font-size: 14px;
    }

    .location-prompt p {
        font-size: 12px;
    }

    .location-prompt button {
        font-size: 14px;
    }

    .modal-note {
        font-size: 12px;
    }
}

.info-button:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ffff00;
    color: #ffff00;
}

.description {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.9);
    border: 1px solid #ffffff;
    padding: 20px;
    width: 90%;
    max-width: 500px;
    color: white;
    font-size: 20px;
    font-family: "Times New Roman", Times, serif;
    line-height: 1.4;
    z-index: 2500;
    display: none;
    box-sizing: border-box;
}

.description h3 {
    font-size: 20px;
    font-weight: normal;
    margin-bottom: 10px;
    margin-top: 12px;
}

.description p {
    margin-bottom: 10px;
}

.api-list {
    margin-top: 10px;
    font-size: 20px;
}

.description-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    display: none;
}

/* Reference section styling */
#distant-winds-references {
    padding: 40px 20px 20px;
    width: 100%;
    max-width: 800px;
    color: white;
    font-size: 25px;
    font-family: "Times New Roman", Times, serif;
    line-height: 1.4;
    text-align: left;
}

#distant-winds-references h2 {
    font-size: 25px;
    font-weight: bold;
    margin-bottom: 10px;
}

#distant-winds-references h3 {
    font-size: 25px;
    font-weight: bold;
    margin-bottom: 10px;
}

#distant-winds-references p {
    margin-bottom: 10px;
    font-size: 25px;
}

#distant-winds-references ul {
    margin-bottom: 10px;
    font-size: 25px;
}

#distant-winds-references li {
    margin-bottom: 5px;
    font-size: 25px;
}

#distant-winds-references code {
    font-family: monospace;
    font-size: 25px;
}

/* Desktop version - smaller font */
@media (min-width: 768px) {
    #distant-winds-references {
        font-size: 25px;
    }
    
    #distant-winds-references h2 {
        font-size: 25px;
        font-weight: bold;
    }
    
    #distant-winds-references h3 {
        font-size: 25px;
        font-weight: bold;
    }
    
    #distant-winds-references p {
        font-size: 25px;
    }
    
    #distant-winds-references ul {
        font-size: 25px;
    }
    
    #distant-winds-references li {
        font-size: 25px;
    }
    
    #distant-winds-references code {
        font-size: 25px;
    }
}