body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #e6ffe6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    box-sizing: border-box;
}

#competition {
    scroll-margin-top: 80px;
}

#results {
    scroll-margin-top: 80px;
}

.content-box {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 128, 0, 0.1);
    text-align: center;
    color: #333;
    max-width: 1200px;
    min-width: 300px;
}

.content-box > a > img { 
    width: auto;
    height: 100%;
    max-width: 100%;
    max-height: 120px;
}

h1 {
    color: #006400;
    margin-bottom: 20px;
}

h2 {
    color: #006400;
    margin-top: 50px;
    margin-bottom: 15px;
}

.content-text {
    line-height: 1.6;
    margin: 0px 40px 0px 40px;
    text-align: justify;
    text-indent: 1.5em;
}

p {
    line-height: 1.6;
}

.button-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 10px;
}

.year-button-section {
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 20px;
    margin-bottom: 20px;
}

.btn {
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1em;
    transition: background-color 0.3s ease, transform 0.1s ease;
    text-decoration: none;
    display: inline-block;
    min-width: 120px;
    box-sizing: border-box;
    width: 80%;
    max-width: 250px;
}

.btn-primary {
    background-color: #111;
    color: #fff;
}

.btn-primary:hover {
    background-color: #777;
}

.btn-primary:active,
.btn-primary-active {
    background-color: #444;
    transform: translateY(1px);
    font-weight: bold;
}

.btn-secondary {
    background-color: #93c47d;
    color: #333;
}

.btn-secondary:hover {
    background-color: #7ba866;
}

.btn-secondary:active,
.btn-secondary-active {
    background-color: #679155;
    transform: translateY(1px);
}

.results-links-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
    margin-bottom: 30px;
}

.results-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    font-size: 1em;
    font-weight: bold;
    transition: transform 0.2s ease-in-out, box-shadow 0.3s ease;
    text-align: center;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 10px 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    background-color: #f9f9f9;
}

.results-link img {
    width: auto;
    height: 100%;
    max-width: 150px;
    max-height: 75px;
    margin-top: 5px;
    margin-bottom: 5px;
}

.results-link:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.iframe-container iframe.loaded {
    opacity: 1;
}

.loader {
    border: 8px solid #f3f3f3;
    border-top: 8px solid #3498db;
    border-radius: 50%;
    width: 100px;
    height: 100px;
    animation: spin 1s linear infinite;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.tab-buttons {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    margin-top: 20px;
    margin-bottom: 0;
    border-bottom: 2px solid #e0e0e0;
}

.tab-button {
    flex-grow: 1;
    background-color: #e0e0e0;
    color: #333;
    padding: 10px 20px;
    border: none;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s ease, color 0.3s ease;
    text-align: center;
    position: relative;
    bottom: 0;
}

.tab-button.active {
    background-color: #ffffff;
    color: #006400;
    font-weight: bold;
    border-bottom: 2px solid #ffffff;
    z-index: 1;
}

.tab-button:hover:not(.active) {
    background-color: #c0c0c0;
}

.sheet-switcher {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 10px 5px;
    box-sizing: border-box;
    border-bottom: 2px solid #e0e0e0;
    background-color: #ffffff;
    position: sticky;
    top: 0;
    z-index: 999;
}

.switcher-wrapper {
    display: flex;
    flex-grow: 1;
    scroll-behavior: smooth;
    gap: 10px;
    padding: 0 10px;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.switcher-wrapper::-webkit-scrollbar {
    display: none;
}

.switcherItem {
    flex-shrink: 0;
    background-color: #e0e0e0;
    color: #333;
    padding: 8px 12px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    white-space: nowrap;
    transition: background-color 0.3s ease;
}

.switcherItem.active {
    background-color: #006400;
    color: white;
}

.switcherItem:hover:not(.active) {
    background-color: #c0c0c0;
}

.switcherArrow {
    background-color: transparent;
    border: none;
    color: #006400;
    font-size: 20px;
    cursor: pointer;
    padding: 5px 10px;
    flex-shrink: 0;
}

.fullscreen-button {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 3px;
    right: 15px;
    z-index: 10;
    background-color: rgba(40, 167, 69, 0.8);
    color: #ffffff;
    padding: 5px 12px;
    font-size: 0.8em;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    gap: 5px;
    -webkit-text-stroke-width: 0;
    -webkit-text-fill-color: currentColor;
}

.fullscreen-button:hover {
    background-color: #218838;
}

.fullscreen-title {
    display: none;
    color: #006400;
    margin: 15px 0px 5px 0px;
    font-size: 1.5em;
}

.tab-content {
    display: none;
    border: none;
    border-radius: 0 0 8px 8px;
    background-color: #ffffff;
    padding: 0;
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden; 
}

.tab-content.active {
    display: block;
}

.iframe-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    background-color: #f0f0f0;
}

.iframe-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

#results {
    display: none;
    flex-direction: column;
    padding-bottom: 0;
    height: 73vh;
}

#results.active {
    display: flex;
}

#results .iframe-container {
    position: relative;
    height: auto;
    flex-grow: 1;
}

#results .iframe-container iframe {
    position: static;
    height: 100%;
    top: auto;
    left: auto;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.gallery-scroll-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    padding: 14px;
    box-sizing: border-box;
}

.gallery-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    background-color: #ffffff;
}

.gallery-thumbnail-link {
    border: 2px solid #ccc;
    border-radius: 5px;
    overflow: hidden;
    transition: transform 0.2s, border-color 0.2s;
    cursor: pointer;
}

.gallery-thumbnail-link:hover {
    border-color: #006400;
    transform: scale(1.05);
}

.gallery-thumbnail-link img {
    display: block;
    width: auto;
    height: 150px;
    max-width: 200px;
}

.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.lightbox-content {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 95%;
    max-height: 95%;
    position: relative;
    padding: 0 50px;
    box-sizing: border-box;
}

.close-btn,
.download-btn {
    cursor: pointer;
    position: fixed;
    top: 20px;
    color: white;
    font-weight: bold;
    transition: 0.3s;
    user-select: none;
    text-shadow: 0 0 5px black;
    z-index: 1001;
    text-decoration: none;
    background-color: rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: center;
    /* align-items: center; */
    padding: 15px 20px;
    width: 20px;
    height: 20px;
    -webkit-text-stroke-width: 0;
    -webkit-text-fill-color: currentColor;
}

.close-btn {
    right: 20px;
    font-size: 30px;
}

.download-btn {
    right: 90px;
    /* text-decoration: underline; */
    font-size: 23px;
}

.close-btn:hover,
.download-btn:hover {
    background-color: rgba(255, 255, 255, 0.09);
}

.prev-btn, .next-btn {
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s, opacity 0.3s;
    z-index: 1001;
    user-select: none;
    text-decoration: none;
    background-color: rgba(255, 255, 255, 0.05);
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    padding: 15px 10px;
}

.prev-btn {
    left: 0;
}

.next-btn {
    right: 0;
}

.prev-btn::before, .next-btn::before {
    content: '\276E';
    font-size: 40px;
    font-weight: bold;
    color: white;
    text-shadow: 0 0 5px black;
    opacity: 0.3;
    transition: opacity 0.3s;
}

.next-btn::before {
    content: '\276F';
}

.prev-btn:hover, .next-btn:hover {
    background-color: rgba(255, 255, 255, 0.09);
    color: white;
}

.prev-btn:hover::before, .next-btn:hover::before {
    opacity: 1;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
}

.social-links-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    padding: 0px 0px 10px 0px;
    border-bottom: 1px solid #e0e0e0;
}

.social-links-container a {
    text-decoration: none;
    transition: transform 0.2s ease;
}

.social-links-container a img {
    width: 35px;
    height: 35px;
    display: block;
    filter: grayscale(10%);
}

.social-links-container a:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 0 5px rgba(0, 100, 0, 0.5));
}


.video-container {
    padding-bottom: 56.25%; 
    position: relative;
    height: 0;
}

.video-link-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    background-size: cover;
    background-position: center;
    cursor: pointer;
}

.video-link-overlay .play-icon {
    font-size: 80px;
    color: white;
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    padding: 10px;
    transition: all 0.2s ease;
}

.video-link-overlay:hover .play-icon {
    font-size: 90px;
    background-color: rgba(0, 0, 0, 0.8);
}

.video-container {
    padding-bottom: 0 !important; 
    height: auto !important;
    position: relative !important;
    min-height: 400px;
}

@media (min-width: 768px) {
    .content-box {
        padding: 30px;
    }
    .button-container {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        align-items: flex-start;
    }
    .btn {
        width: auto;
        min-width: 150px;
        margin: 5px;
    }
    .button-container > p {
        flex-basis: 100%;
        order: -1;
        margin-bottom: 5px;
    }
    
    .results-links-wrapper {
        flex-direction: row;
    }
}

@media (max-width: 767px) {
    body {
        padding: 20px 10px;
    }

    .content-box {
        padding: 20px 10px;
    }

    .button-container {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 80%;
        max-width: 250px;
    }

    .results-link img {
        max-width: 100px; 
        max-height: 50px;
    }

    .tab-button {
        padding: 8px 15px;
        font-size: 0.9em;
    }

    .gallery-thumbnail-link img {
        max-width: 180px;
        height: 135px;
    }
    
    .tab-content {
        padding-bottom: 80%;
    }
    
    #results {
        padding-bottom: 0;
    }
}

@media (max-width: 480px) {
    body {
        padding: 20px 5px;
    }
    
    .content-box {
        padding: 20px 5px;
    }

    .gallery-thumbnail-link img {
        max-width: 160px;
        height: 120px;
    }
    
    .tab-content {
        padding-bottom: 150%;
    }
    
    #results {
        padding-bottom: 0;
    }

    .social-links-container a img {
        width: 30px;
        height: 30px;
    }
}