/* General Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f0f0f0;
}

.container {
    width: 80%;
    margin: auto;
    overflow: hidden;
    padding: 0 20px;
}

/* Header Styles */
header {
    background: #010066;
    color: #ffffff;
    padding-top: 30px;
    min-height: 70px;
    border-bottom: #cc0001 3px solid;
}

header .header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

header .logo img {
    width: 40px;
    height: 40px;
}

header nav ul {
    display: flex;
    list-style: none;
}

header nav ul li {
    padding: 0 20px;
}

header nav ul li a {
    color: #ffffff;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 16px;
}

header nav ul li a:hover {
    color: #e8491d;
    border-bottom: 2px solid #e8491d;
}

/* Home Section */
#home {
    background:  url('Header Pertandingan Video TikTok (2).png') no-repeat center center/cover;
    height: 50vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    color: #ffffff;
	line-height:1.2;
}

#home h1 {
    font-size: 50px;
    margin-bottom: 10px;
}

#home h2 {
    font-size: 30px;
    margin-bottom: 10px;
}

#home h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

#home .highlight {
    color: #e8491d;
}


#countdown {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.countdown-item {
    margin: 0 20px;
}

.countdown-item span {
    font-size: 40px;
    font-weight: bold;
}

.btn {
    display: inline-block;
    background: #cc0001;
    color: #ffffff;
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    font-size: 18px;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.btn:hover {
    background: #ffd100; /* Yellow from Malaysian flag */
    color: #010066; /* Dark blue text on hover for contrast */
}

/* Section Styles */
section {
    padding: 60px 0;
	background-color: #ffffff;
}

.section-title {
    text-align: center;
    font-size: 36px;
    margin-bottom: 40px;
    color: #010066;
}

/* About Section */
#about .about-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 800px;
    margin: 0 auto;
    text-align: left;
}

#about .about-text {
    width: 100%;
    margin-bottom: 30px;
}

#about .about-poster {
    width: 100%;
    text-align: center;
}

#about .poster-image {
    max-width: 60%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

#about .polytechnic-list {
    list-style-type: none;
    padding: 0;
    margin-top: 20px;
}

#about .polytechnic-list li {
    margin-bottom: 10px;
}

/* Ensure consistent spacing */
#about h3 {
    margin-top: 20px;
    margin-bottom: 10px;
}

#about p {
    margin-bottom: 15px;
}

/* Responsive design for smaller screens */
@media (max-width: 768px) {
    #about .about-content {
        padding: 0 20px;
    }
    
    #about .poster-image {
        width: 100%; /* Full width on smaller screens */
    }
}

/* Poster resizing */
@media (min-width: 769px) {
    #about .poster-image {
        width: 70%; /* Adjust this value to resize the poster */
        max-width: 600px; /* Maximum width of the poster */
    }
}
/* Alternating Section Colors */
section:nth-child(even) {
    background-color: #f7f7f7; /* Light grey for every even section */
}

section:nth-child(odd) {
    background-color: #ffffff; /* White for every odd section */
}
#about .poly-list {
    list-style-type: none;
    padding: 0;
}

#about .poly-list li {
    margin-bottom: 10px;
}

/* Rules Section */
.rules-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
}

.rule-item {
    flex-basis: 30%;
    text-align: center;
    margin-bottom: 30px;
}

.rule-item i {
    font-size: 40px;
    color: #e8491d;
    margin-bottom: 15px;
}

/* About Section */
#about .about-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    text-align: left;
}

#about .about-text {
    flex: 1;
    padding-right: 20px;
}

#about .about-poster {
    flex: 1;
    text-align: center;
}

#about .poster-image {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    #about .about-content {
        flex-direction: column;
    }

    #about .about-text {
        padding-right: 0;
        margin-bottom: 20px;
    }
}


/* Participate Section */
.participate-steps {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.step {
    flex-basis: 22%;
    text-align: center;
}

.step i {
    font-size: 40px;
    color: #e8491d;
    margin-bottom: 15px;
}

.qr-code {
    display: block;
    margin: 30px auto;
    width: 200px;
    height: auto;
}

/* Prizes Section */
.prize-container {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
}

.prize-item {
    flex-basis: 20%;  /* Reduced from 30% to 20% to make the box smaller */
    text-align: center;
    margin-bottom: 20px; /* Reduced the bottom margin for tighter spacing */
    padding: 15px;  /* Reduced padding to shrink the box */
    background: #ffffff;
	border: 2px solid #ffd100;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.prize-amount {
    font-size: 24px;
    font-weight: bold;
    color: #cc0001;
}

/* Criteria Section */
.criteria-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.criteria-item {
    width: 80%;
    margin-bottom: 30px;
}

.progress-bar {
    width: 100%;
    background-color: #e0e0e0;
    padding: 3px;
    border-radius: 3px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, .2);
}

.progress-bar .progress {
    display: block;
    height: 22px;
    background-color: #e8491d;
    border-radius: 3px;
    transition: width 500ms ease-in-out;
    color: #ffffff;
    text-align: center;
}

/* Gallery Section */
/* Gallery container styling */
.gallery-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding: 20px;
    gap: 20px;
}

/* Individual gallery item (video) styling */
.gallery-item {
    background-color: white;
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    max-width: 325px; /* Match the iframe width */
    margin-bottom: 20px;
    text-align: center;
}

.video-number {
    font-size: 18px;
    font-weight: bold;
    background-color: #232df5;
    color: white;
    padding: 10px;
    margin-bottom: 10px;
    text-align: center;
    display: inline-block; /* Keeps the width of the number compact */
    border-radius: 5px; /* Optional: Adds rounded corners */
}

/* Gallery item hover effect */
.gallery-item:hover {
    transform: scale(1.05);
}

/* Load more button styling */
#load-more {
    display: block;
    margin: 20px auto;
    padding: 10px 20px;
    background-color: #007BFF;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.2em;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#load-more:hover {
    background-color: #0056b3;
}

/* Iframe styling to ensure proper display */
iframe {
    border: none;
    border-radius: 10px;
    width: 100%; /* Ensures iframe is responsive within gallery item */
    height: 580px; /* Default height for TikTok embed */
}

/* FAQ Section */
.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-question {
    background-color: #e6e6e6;
    color: #010066;
    cursor: pointer;
    padding: 18px;
    width: 100%;
    text-align: left;
    border: none;
    outline: none;
    transition: 0.4s;
    font-size: 18px;
}

.faq-question:hover {
    background-color: #ffd100;
}

.faq-answer {
    padding: 0 18px;
    background-color: white;
    display: none;
    overflow: hidden;
}

/* Contact Section */
.contact-info {
    text-align: center;
}

.contact-info ul {
    list-style-type: none;
    padding: 0;
}

.contact-info ul li {
    margin-bottom: 10px;
}

/* Footer Styles */
footer {
    background: #010066;
    color: #ffffff;
    text-align: center;
    padding: 20px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.social-media a {
    color: #ffffff;
    font-size: 24px;
    margin: 0 10px;
}

/* Back to Top Button */
#backToTop {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 30px;
    z-index: 99;
    font-size: 18px;
    border: none;
    outline: none;
    background-color: #e8491d;
    color: white;
    cursor: pointer;
    padding: 15px;
    border-radius: 4px;
}

#backToTop:hover {
    background-color: #555;
}

/* Responsive Design */
@media (max-width: 768px) {
    header .header-container {
        flex-direction: column;
    }

    header nav ul {
        flex-direction: column;
        text-align: center;
    }

    header nav ul li {
        padding: 10px 0;
    }

    .rule-item, .step, .prize-item {
        flex-basis: 100%;
    }

    .criteria-item {
        width: 100%;
    }
}

/* Winner Announcement Section */
#winner-announcement {
    background-color: #ffffff; /* Maintain consistency with the alternating sections */
    padding: 60px 20px;
}

#winner-announcement .section-title {
    text-align: center;
    font-size: 36px;
    margin-bottom: 40px;
    color: #010066; /* Consistent dark blue for titles */
}

.winner-list {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 50px;
}

.winner-list .winner-item {
    flex-basis: 30%; /* Adjust the width for a neat display */
    background-color: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 10px;
    margin-bottom: 30px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

.winner-list .winner-item h3 {
    color: #cc0001; /* Highlight the winner names */
    font-size: 24px;
    margin-bottom: 15px;
}

.winner-list .winner-item p {
    font-size: 18px;
    color: #333;
}

/* Table for consolation winners */
.consolation-table {
    width: 100%;
    margin-top: 30px;
    border-collapse: collapse;
    background-color: #f9f9f9;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.05);
}

.consolation-table th, .consolation-table td {
    text-align: center;
    padding: 15px;
    border-bottom: 1px solid #ddd;
    font-size: 16px;
}

.consolation-table th {
    background-color: #010066;
    color: #ffffff;
    text-transform: uppercase;
}

.consolation-table td {
    background-color: #ffffff;
}

.consolation-table tr:nth-child(even) {
    background-color: #f7f7f7;
}

/* Responsive Design */
@media (max-width: 768px) {
    .winner-list .winner-item {
        flex-basis: 100%;
        margin-bottom: 20px;
    }

    .consolation-table {
        font-size: 0.9em;
    }

    .consolation-table th, .consolation-table td {
        padding: 10px;
    }
}