:root {
    --primary-color: #D4AF37;
    --bg-color: #1C1C1C;
    --text-color: #FFFFFF;
    --secondary-text-color: #A9A9A9;
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.welcome-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(28, 28, 28, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 0.5s ease-in-out;
}

.circle {
    height: 24px;
    width: 24px;
    border-radius: 24px;
    background-color: black;
    position: fixed; 
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 99999999; /* so that it stays on top of all other elements */
}

.welcome-content {
    text-align: center;
    color: var(--primary-color);
    padding: 3rem;
    border: 2px solid var(--primary-color);
    animation: fadeIn 1s ease-out;
    background-color: rgba(28, 28, 28, 0.7);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 2rem;
}

.welcome-content:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

h1 {
    font-size: 3.5em;
    margin-bottom: 20px;
    font-weight: 600;
    letter-spacing: 2px;
}

p {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: var(--secondary-text-color);
    font-weight: 300;
}

.btn {
    padding: 12px 24px;
    font-size: 1em;
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 30px;
    margin: 10px;
    font-weight: 400;
}

.btn:hover {
    background-color: var(--primary-color);
    color: var(--bg-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.4);
}

.model-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 20px;
    box-sizing: border-box;
    display: none;
    background: var(--bg-color);
    flex-direction: column;
    align-items: center;
}

.iframe-container {
    position: relative;
    width: 100%;
    height: calc(100% - 120px);
    margin-bottom: 20px;
}

iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 15px;
}

.cover-attribution {
    position: absolute;
    bottom: 0px;
    right: 0px;
    width: 1700px;
    height: 80px;
    background-color: var(--bg-color);
    z-index: 5;
}

.loading {
    color: var(--primary-color);
    font-size: 1.5em;
    text-align: center;
    padding-top: 20px;
}

.plant-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-color);
    z-index: 999;
    padding: 2rem;
    box-sizing: border-box;
    overflow-y: auto;
}

.plant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 4rem auto;
}

.plant-card {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--primary-color);
    border-radius: 15px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.plant-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(212, 175, 55, 0.2);
}

.plant-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.plant-card p {
    font-size: 0.9em;
    color: var(--secondary-text-color);
}

.development-notice {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(28, 28, 28, 0.95);
    border: 2px solid var(--primary-color);
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    z-index: 1002;
}

.popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(28, 28, 28, 0.95);
    border: 2px solid var(--primary-color);
    padding: 30px;
    z-index: 1001;
    max-width: 80%;
    max-height: 80%;
    overflow-y: auto;
    animation: popupFadeIn 0.5s ease-out;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
}

/* Falling leaves styles */
@keyframes fall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(360deg);
    opacity: 0;
  }
}

.leaf {
  position: fixed;
  top: -50px;
  width: 30px;
  height: 30px;
  background-image: url('https://raw.githubusercontent.com/krishnakoushik9/AyurVerse/main/leaf.jpg'); /* Direct GitHub link */
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0;
  animation: fall linear infinite;
}


@keyframes popupFadeIn {
    from { opacity: 0; transform: translate(-50%, -60%); }
    to { opacity: 1; transform: translate(-50%, -50%); }
}

.popup h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
}

.popup ul {
    color: var(--secondary-text-color);
    text-align: left;
    padding-left: 20px;
}

.popup li {
    margin-bottom: 10px;
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.5em;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.close-btn:hover {
    transform: scale(1.1);
}

.button-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
}

.external-buttons {
    display: flex;
    justify-content: center;
    width: 100%;
}

.home-btn-container {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 1001;
}

.slider-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 20px;
}

.slider {
    -webkit-appearance: none;
    width: 400px;
    height: 48px;
    background: #d3d3d3;
    outline: none;
    opacity: 0.7;
    -webkit-transition: .2s;
    transition: opacity .2s;
    border-radius: 15px;
}

.slider:hover {
    opacity: 1;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 50px;
    height: 48px;
    background: var(--primary-color);
    cursor: pointer;
    border-radius: 30%;
}

.slider::-moz-range-thumb {
    width: 50px;
    height: 48px;
    background: var(--primary-color);
    cursor: pointer;
    border-radius: 30%;
}

/* Media Queries for Responsiveness */
@media (max-width: 768px) {
    .welcome-content {
        padding: 2rem;
        margin: 1rem;
    }

    h1 {
        font-size: 2.5em;
    }

    .slider {
        width: 300px;
    }

    .plant-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1rem;
        margin: 2rem auto;
    }

    .popup {
        width: 90%;
        max-height: 90%;
        padding: 20px;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2em;
    }

    .slider {
        width: 250px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.9em;
    }

    .plant-grid {
        grid-template-columns: 1fr;
    }
}
