/* styles.css */

/* General Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
}

/* Theme Selector Styling */
.theme-selector {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 1rem;
    gap: 1rem;
}

.theme-selector label {
    font-size: 1rem;
    font-weight: bold;
}

.theme-button {
    background-color: #ddd;
    color: #333;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.theme-button:hover {
    background-color: #ccc;
}

/* Base Styles */
body {
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.container {
    background: var(--container-bg);
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    box-shadow: var(--box-shadow);
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-top: 1rem;
}

h1 {
    font-size: 1.5rem;
    font-weight: normal;
    margin-bottom: 1rem;
}

p {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

/* Button Styling */
.button-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1rem;
}

button {
    background-color: var(--button-bg);
    color: var(--button-text);
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

button:hover {
    background-color: var(--button-hover-bg);
}

#back-button-container {
    margin-top: 1rem;
}

#back-button {
    background: none;
    color: var(--link-color);
    font-size: 1rem;
    border: none;
    cursor: pointer;
}

#back-button:hover {
    color: var(--link-hover-color);
}

/* Footer Styling */
footer {
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-color);
}

footer a {
    color: var(--link-color);
    text-decoration: none;
}

footer a:hover {
    text-decoration: underline;
}

/* Path Visualization Styles */
#path-visualization {
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.path-card {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 5px;
    padding: 0.8rem 1rem;
    margin: 0.5rem 0;
    width: 80%;
    max-width: 500px;
    position: relative;
    text-align: left;
}

.path-card::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    width: 2px;
    height: 20px;
    background-color: var(--link-color);
    transform: translateX(-50%);
}

.path-card:first-child::before {
    display: none;
}

.path-card p {
    margin-bottom: 0.3rem;
    font-size: 1rem;
}

.path-card .question {
    font-weight: bold;
}

.path-card .answer {
    color: #555;
}

/* Animations */
.fade {
    animation: fadeIn 0.5s ease-in-out;
}

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

.slide-left {
    animation: slideLeft 0.5s forwards;
}

@keyframes slideLeft {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

/* Theme Variables */
:root {
    --bg-color: #f7f7f7;
    --text-color: #333;
    --container-bg: white;
    --box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    --button-bg: #4a90e2;
    --button-hover-bg: #357ab8;
    --button-text: #fff;
    --link-color: #666;
    --link-hover-color: #333;
    --card-bg: #fff;
    --card-border: #ddd;
}

/* Renaissance Theme */
body.renaissance {
    --bg-color: #f2e6d9;
    --text-color: #4b3832;
    --container-bg: #fff7f0;
    --box-shadow: 0 4px 12px rgba(75, 56, 50, 0.3);
    --button-bg: #854442;
    --button-hover-bg: #6e3836;
    --button-text: #fff;
    --link-color: #854442;
    --link-hover-color: #6e3836;
    --card-bg: #fff7f0;
    --card-border: #d9c3b0;
}

/* Disco Theme */
body.disco {
    --bg-color: #1a1a1a;
    --text-color: #e6e6e6;
    --container-bg: #262626;
    --box-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    --button-bg: #ff00ff;
    --button-hover-bg: #cc00cc;
    --button-text: #fff;
    --link-color: #ff00ff;
    --link-hover-color: #cc00cc;
    --card-bg: #333333;
    --card-border: #555555;
}

/* Disco Theme Animations */
body.disco .container {
    animation: discoGlow 2s infinite alternate;
}

@keyframes discoGlow {
    from { box-shadow: 0 0 15px rgba(255, 0, 255, 0.5); }
    to { box-shadow: 0 0 25px rgba(0, 255, 255, 0.5); }
}

/* Mobile Styles */
@media (max-width: 600px) {
    .container {
        padding: 1rem;
        width: 100%;
        margin-top: 0.5rem;
    }

    h1 {
        font-size: 1.2rem;
    }

    p {
        font-size: 1.2rem;
    }

    .theme-selector {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
        margin-top: 0.5rem;
    }

    .theme-selector label {
        text-align: center;
        margin-bottom: 0.5rem;
    }

    .theme-button {
        width: 100%;
        padding: 0.7rem;
        font-size: 1rem;
    }

    .button-container {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    button {
        padding: 1rem;
        font-size: 1.2rem;
    }

    #back-button {
        font-size: 1rem;
    }

    footer {
        font-size: 0.8rem;
        text-align: center;
    }

    .path-card {
        width: 100%;
        padding: 1rem;
        margin: 0.3rem 0;
    }

    .path-card p {
        font-size: 1rem;
    }
}