/* weed.css */
body {
    margin: 0;
    font-family: Audiowide;
    background-color: #8989AB;
    color: #8989AB;
    position: relative;
    min-height: 100vh;
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    overflow-x: hidden; /* Prevent horizontal scrolling */
    width: 100%; /* Ensure body takes full viewport width */
}
header {
    background-color: black;
    color: white;
    padding: 10px 20px;
    position: relative; /* Ensure proper positioning for logo cube */
    width: 100%;
    box-sizing: border-box; /* Include padding in width */
}
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px; /* Match section and footer width */
    margin: 0 auto; /* Center the navbar */
    box-sizing: border-box; /* Include padding in width */
}
.logo {
    width: 150px; /* Adjusted for cube size */
    height: 150px; /* Adjusted for cube size */
    position: relative;
    background-color: black;
}
.nav-links {
    list-style: none;
    display: flex;
    margin: 0;
    padding: 0;
}
.nav-links li {
    margin-left: 20px;
}
.nav-links a {
    color: white;
    font-size: 25px;
    text-decoration: none;
    text-shadow: 0 .5rem 1rem black;
}
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}
.hamburger span {
    height: 3px;
    width: 25px;
    background: white;
    margin-bottom: 5px;
}
#trends-section h2{
    font-size: 30px;
    background-image: url(folder-img/ca4.jpg);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 1px black;
    backdrop-filter: blur(10px);
    animation: text-background 8s linear infinite;
}
#gallery-section h2{
    font-size: 30px;
    background-image: url(folder-img/ca4.jpg);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    -webkit-text-stroke: 1px black;
    backdrop-filter: blur(10px);
    animation: text-background 8s linear infinite;
}
@keyframes text-background {
    from { background-position: 0 0; }
    to { background-position: 100% 100%; }
}
@media (max-width: 800px) {
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 60px;
        left: 0;
        background: #333;
    }
    .nav-links.active {
        display: flex;
    }
    .nav-links li {
        margin: 10px 0;
        text-align: center;
    }
    .hamburger {
        display: flex;
    }
    .navbar {
        padding: 10px;
        max-width: 100%; /* Full width on mobile */
    }
    .nav-links a {
        font-size: 25px; /* Reduce font size for mobile */
        padding: 10px; /* Adjust padding to fit */
    }
}
section {
    padding: 20px;
    text-align: center;
    background-color: #C5C5D6;
    flex: 1 0 auto; /* Allow section to grow but not shrink */
    max-width: 1600px; /* Constrain section width */
    margin: 0 auto; /* Center the section */
    border: 1px solid;
    box-sizing: border-box; /* Include padding in width calculation */
}
.cubes-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 50px;
    width: 100%; /* Ensure container fits screen */
   
    margin: 0 auto; /* Center the container */
    padding: 0 10px; /* Add minimal padding */
}
.cube-wrapper {
    border-bottom: 5px solid #8989AB;
    padding: 20px;
    margin: 30px;
    border-radius: 15px;
    width: 380px;
    text-align: center;
    box-sizing: border-box;
    position: relative; /* For overlay positioning */
    display: flex;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    flex-direction: column;
    justify-content: space-between;
    height: 500px; /* Fixed height for equal divs */
    background-color: #F8E1FA;
    border: 1px solid black;
}
.canvas-container {
    width: 300px;
    height: 300px;
    margin: 0 auto 50px auto;
    flex-grow: 1;
    touch-action: none; /* Disable default touch actions for better control */
}
.controls {
    margin-bottom: 10px;
    display: flex;
    flex-direction: column; /* Arrange in column */
    align-items: center;
}
.controls span {
    font-size: 1.5em; /* Larger letters for cube name */
    font-weight: bold;
}
.read-about-cube {
    color: #8989AB;
    margin-top: 5px;
    cursor: pointer;
    font-size: 30px;
}
button {
    margin: 2px;
    padding: 5px;
    background-color: #333;
    color: white;
    border: none;
    cursor: pointer;
    width: 100%; /* Full width for column layout */
}
button:hover {
    background-color: #555;
}
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    cursor: pointer;
    padding: 10px; /* Padding for smaller screens */
}
.overlay img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    width: auto;
    height: auto;
}
@media (max-width: 600px) {
    .cube-wrapper {
        width: 100%; /* Full width on mobile */
        margin: 10px 0; /* Remove horizontal margins, keep vertical spacing */
        height: auto; /* Adjust height for small screens */
    }
    .canvas-container {
        width: 100%;
        height: auto;
        aspect-ratio: 1/1; /* Keep square aspect ratio */
    }
    .cubes-container {
        gap: 10px; /* Reduce gap on mobile */
        width: 100%; /* Ensure container fits screen */
        padding: 0; /* Remove padding to avoid overflow */
    }
    section {
        padding: 10px; /* Reduce padding on mobile */
    }
    footer {
        padding: 10px; /* Reduce footer padding on mobile */
    }
    .footer-content {
        max-width: 100%; /* Allow full width on mobile */
        padding: 0 10px; /* Add minimal padding */
    }
    #contact-form textarea {
        max-width: 100%; /* Ensure textarea fits mobile */
    }
    .overlay {
        padding: 10px; /* Reduced padding on very small screens */
    }
    .overlay img {
        max-width: 100%;
        max-height: 100%;
    }
    .navbar {
        padding: 5px; /* Further reduce padding on mobile */
    }
    .logo {
        width: 100px; /* Reduce logo size on mobile */
        height: 100px;
    }
}
footer {
    background-color: #8989AB;
    color: white;
    padding: 20px;
    text-align: center;
    width: 100%;
    flex-shrink: 0; /* Prevent footer from shrinking */
    max-width: 1200px; /* Constrain footer width */
    margin: 0 auto; /* Center the footer */
    box-sizing: border-box; /* Include padding in width */
}
.footer-content {
    max-width: 600px;
    margin: 0 auto;
}
footer h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: white;
}
footer p {
    margin: 10px 0;
    font-size: 1.1em;
}
#contact-form {
    display: flex;
    flex-direction: column;
    align-items: center;
}
#contact-form textarea {
    width: 100%;
    max-width: 400px;
    margin-bottom: 10px;
    padding: 10px;
    border: 1px solid red;
    border-radius: 5px;
    resize: vertical;
}
#contact-form button {
    padding: 10px 20px;
    background-color: #C1C1E8;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 5px;
}
#contact-form button:hover {
    background-color: #555;
}
#scroll-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background-color: #333;
    color: lightblue;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    cursor: pointer;
    opacity: 1;
    transition: opacity 0.3s ease;
    z-index: 1000;
}
#scroll-to-top.visible {
    opacity: 1;
}
#scroll-to-top:hover {
    background-color: pink;
}
.popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 20px;
    border: 2px solid #F1D0F5;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    z-index: 2000;
    max-width: 80%;
    max-height: 80%;
    overflow-y: auto;
}
.popup-content {
    position: relative;
}
.close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 24px;
    cursor: pointer;
    color: #B327C2;
}
#popup-title {
    color: #4D4DF0;
    margin-bottom: 10px;
}
#popup-text {
    font-size: 1.1em;
    line-height: 1.5;
}