/* Basic Reset & Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    color: #e0e0e0;
    background-color: #0a0a1f; /* Dark space blue/purple */
    line-height: 1.6;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Specific to index.html to prevent scroll */
body:has(.main-content) {
    overflow-y: hidden;
}

h1, h2 {
    font-family: 'Orbitron', sans-serif;
    color: #00ffff; /* Cyan - high tech glow */
    text-shadow: 0 0 5px #00ffff, 0 0 10px #00ffff, 0 0 15px #00aaff;
    margin-bottom: 20px;
}

a {
    color: #ff00ff; /* Magenta for links */
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

a:hover {
    color: #ffa0ff;
    text-shadow: 0 0 5px #ff00ff;
}

/* Particles Background */
#particles-js, #particles-js-about {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
}

/* Main Landing Page Content (index.html) */
.main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    position: relative;
    z-index: 1;
    max-width: 700px;
    animation: fadeInContent 1.5s ease-out forwards;
}

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

.logo {
    width: 100px;
    height: auto;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 10px #00ffff);
    animation: pulseGlow 4s infinite ease-in-out;
}

.logo-small {
    width: 60px;
    height: auto;
    margin-bottom: 10px;
    filter: drop-shadow(0 0 8px #00ffff);
}

.main-content h1 {
    font-size: 3em;
    letter-spacing: 2px;
}

#tagline-container {
    min-height: 2.5em;
    margin: 15px 0;
}

.tagline {
    font-size: 1.5em;
    font-weight: 300;
    color: #cccccc;
    display: inline-block;
    opacity: 0;
    animation: fadeInOut 6s infinite ease-in-out;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0; transform: translateY(10px); }
    10%, 90% { opacity: 1; transform: translateY(0); }
}

.intro-text {
    font-size: 1.1em;
    margin-bottom: 30px;
    color: #b0b0b0;
    max-width: 500px;
}

/* Beta Signup Form */
#beta-signup-form {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
    width: 100%;
    max-width: 450px;
}

#beta-signup-form input[type="email"] {
    flex-grow: 1;
    padding: 12px 15px;
    border: 1px solid #00ffff;
    background-color: rgba(0, 20, 40, 0.7);
    color: #e0e0e0;
    font-size: 1em;
    border-radius: 5px 0 0 5px;
    outline: none;
    transition: box-shadow 0.3s ease;
}

#beta-signup-form input[type="email"]::placeholder {
    color: #777;
}

#beta-signup-form input[type="email"]:focus {
    box-shadow: 0 0 10px #00ffff;
}

#beta-signup-form button[type="submit"] {
    padding: 12px 20px;
    background-color: #00ffff;
    color: #0a0a1f;
    border: none;
    font-family: 'Orbitron', sans-serif;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    border-radius: 0 5px 5px 0;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

#beta-signup-form button[type="submit"]:hover {
    background-color: #00dddd;
    box-shadow: 0 0 15px #00ffff;
}

.form-message {
    min-height: 1.2em;
    font-size: 0.9em;
}

.form-message.success {
    color: #00ffaa;
}

.form-message.error {
    color: #ff4444;
}

.main-nav a {
    font-size: 1em;
    margin-top: 30px;
    display: inline-block;
    padding: 8px 15px;
    border: 1px solid #ff00ff;
    border-radius: 5px;
}

.main-nav a:hover {
    background-color: rgba(255, 0, 255, 0.1);
    text-shadow: 0 0 8px #ff00ff;
}

/* About Page Specific Styles */
.page-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 30px;
    background-color: rgba(10, 10, 31, 0.85);
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
    position: relative;
    z-index: 1;
}

.about-page header {
    text-align: center;
    margin-bottom: 30px;
}

.about-page h1 {
    font-size: 2.5em;
}

.about-content p {
    margin-bottom: 1.5em;
    color: #c0c0c0;
    font-size: 1.05em;
}

.contact-info {
    margin-top: 40px;
    text-align: center;
}

.contact-info h2 {
    margin-bottom: 10px;
    font-size: 1.8em;
}

.email-link {
    font-size: 1.2em;
    font-weight: bold;
}

.page-nav {
    text-align: center;
    margin-top: 40px;
}

.page-nav a {
    padding: 10px 18px;
    border: 1px solid #ff00ff;
    border-radius: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .main-content h1 {
        font-size: 2.5em;
    }
    .tagline {
        font-size: 1.2em;
    }
    #beta-signup-form {
        flex-direction: column;
        gap: 10px;
    }
    #beta-signup-form input[type="email"],
    #beta-signup-form button[type="submit"] {
        width: 100%;
        border-radius: 5px;
    }
}

@media (max-width: 480px) {
    .main-content h1 {
        font-size: 2em;
    }
    .tagline {
        font-size: 1em;
    }
    .intro-text {
        font-size: 1em;
    }
    .about-page h1 {
        font-size: 2em;
    }
}

/* Chatbot Styles */
:root {
    --primary-color: #00ffff; /* Cyan, matching the theme */
    --accent-color: #ff00ff;  /* Magenta, matching the theme */
    --background-color: #0a0a1f; /* Dark space blue/purple */
    --container-bg: rgba(15, 15, 35, 0.9); /* Slightly more opaque for chat */
    --text-color: #e0e0e0;
    --bot-message-bg: #1a1a3a;
    --user-message-bg: #2a2a4a;
}

.chat-bubble {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background-color: var(--accent-color);
    color: var(--background-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(255, 0, 255, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.chat-bubble:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(255, 0, 255, 0.6);
}

.chat-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 350px;
    max-width: 90vw;
    height: 500px;
    max-height: 80vh;
    background-color: var(--container-bg);
    border: 1px solid var(--primary-color);
    border-radius: 10px;
    box-shadow: 0 0 25px rgba(0, 255, 255, 0.3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 1001;
    transform: scale(0.95) translateY(20px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s;
}

.chat-container.active {
    transform: scale(1) translateY(0);
    opacity: 1;
    visibility: visible;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background-color: rgba(0, 255, 255, 0.1);
    border-bottom: 1px solid var(--primary-color);
    color: var(--primary-color);
    font-family: 'Orbitron', sans-serif;
}

.close-chat-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 24px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-chat-btn:hover {
    color: #ffffff;
}

.chat-messages {
    flex-grow: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Custom scrollbar for chat */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}
.chat-messages::-webkit-scrollbar-track {
    background: transparent;
}
.chat-messages::-webkit-scrollbar-thumb {
    background-color: var(--accent-color);
    border-radius: 3px;
}

.message {
    padding: 10px 15px;
    border-radius: 18px;
    max-width: 80%;
    line-height: 1.4;
    word-wrap: break-word;
}

.bot-message {
    background-color: var(--bot-message-bg);
    color: var(--text-color);
    border-bottom-left-radius: 4px;
    align-self: flex-start;
}

.user-message {
    background-color: var(--user-message-bg);
    color: #ffffff;
    border-bottom-right-radius: 4px;
    align-self: flex-end;
}

.chat-input-area {
    display: flex;
    padding: 10px;
    border-top: 1px solid var(--primary-color);
    background-color: rgba(0, 255, 255, 0.05);
}

#chatInput {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid var(--accent-color);
    background-color: rgba(0, 20, 40, 0.8);
    color: var(--text-color);
    border-radius: 20px;
    outline: none;
    transition: box-shadow 0.3s ease;
    margin-right: 10px;
}

#chatInput::placeholder {
    color: #888;
}

#chatInput:focus {
    box-shadow: 0 0 10px var(--accent-color);
}

#sendChatBtn {
    width: 44px;
    height: 44px;
    background-color: var(--accent-color);
    color: var(--background-color);
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

#sendChatBtn:hover {
    background-color: #ff40ff;
    transform: scale(1.05);
}

#sendChatBtn:disabled {
    background-color: #555;
    cursor: not-allowed;
}

/* Spotlight Cursor Effect */
body {
    --cursor-x: 50vw;
    --cursor-y: 50vh;
    /* Add a radial gradient that follows the cursor */
    background: radial-gradient(
        circle 500px at var(--cursor-x) var(--cursor-y),
        rgba(20, 20, 50, 0.9),
        #0a0a1f
    );
    cursor: none; /* Hide the default system cursor */
}

/* Custom Cursor Styles */
.cursor-dot, .cursor-outline {
    pointer-events: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, transform 0.2s ease-in-out;
}

/* Show cursor once it moves */
body:hover .cursor-dot,
body:hover .cursor-outline {
    opacity: 1;
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background-color: #00ffff;
}

/* New class to hide the cursor dot */
.cursor-dot.cursor-hidden {
    opacity: 0;
}

.cursor-outline {
    width: 30px;
    height: 30px;
    border: 2px solid rgba(255, 0, 255, 0.7);
}

/* Cursor Hover State */
.cursor-outline.hover {
    transform: translate(-50%, -50%) scale(1.4);
    background-color: rgba(255, 0, 255, 0.2);
}

/* Pre-loader Styles */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #0a0a1f;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.75s ease-out;
}

#preloader.loaded {
    opacity: 0;
    pointer-events: none;
}

.preloader-logo {
    width: 100px;
    height: auto;
    filter: drop-shadow(0 0 10px #00ffff);
    animation: pulseLoader 2s infinite ease-in-out;
}

@keyframes pulseLoader {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

/* Pulsing Logo Animation */
@keyframes pulseGlow {
    0%, 100% {
        filter: drop-shadow(0 0 10px #00ffff);
    }
    50% {
        filter: drop-shadow(0 0 15px #00ffff) drop-shadow(0 0 5px #ffffff);
    }
}