/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
        sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background: #000000;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    color: #ffffff;
    overflow: hidden;
    margin: 0;
    padding: 0;
    touch-action: none;
    overscroll-behavior: none;
    -webkit-overflow-scrolling: touch;
}

/* Stable container - sized to initial viewport, never changes */
#app-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    overflow: hidden;
    pointer-events: auto;
    /* Width and height set via JavaScript on load */
}

/* Connection lines canvas */
#connections {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
    pointer-events: none;
    /* Sized to match container */
}

/* Agent container */
#agentContainer {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    pointer-events: none;
    /* Sized to match container */
}

/* Agent icons */
.agent-icon {
    position: absolute;
    display: block;
    transform: translate(-50%, -50%);
}

/* Signup Section */
.signup-section {
    position: fixed;
    top: 2rem;
    right: 2rem;
    opacity: 0;
    z-index: 100;
}

.signup-form {
    display: flex;
}

.form-group {
    position: relative;
    display: flex;
    align-items: center;
    border-radius: 8px;
    background: linear-gradient(90deg,
        #FF3B3B,
        #FF8C00,
        #FFD700,
        #00FF41,
        #00CED1,
        #0080FF,
        #9D00FF
    );
    padding: 1px;
}

.email-input {
    width: 320px;
    padding: 1rem 3.5rem 1rem 1.5rem;
    border: none;
    border-radius: 7px;
    background: #080809;
    font-size: 0.9375rem;
    color: #F4F5F7;
    outline: none;
    transition: all 0.3s ease;
}

.email-input:focus {
    background: #0a0a0b;
}

.email-input::placeholder {
    color: #5B5F6B;
    transition: color 0.3s ease;
}

/* Error state - red placeholder */
.email-input.error::placeholder {
    color: #FF3B3B;
}

/* Success state - green placeholder */
.email-input.success::placeholder {
    color: #00FF41;
}

/* Prevent browser autofill from changing background to white */
.email-input:-webkit-autofill,
.email-input:-webkit-autofill:hover,
.email-input:-webkit-autofill:focus,
.email-input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #080809 inset !important;
    -webkit-text-fill-color: #F4F5F7 !important;
    box-shadow: 0 0 0 1000px #080809 inset !important;
    transition: background-color 5000s ease-in-out 0s;
}

.submit-btn {
    position: absolute;
    right: 1rem;
    padding: 0.75rem;
    border: none;
    background: transparent;
    color: #3A7CFF;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.submit-btn .material-symbols-rounded {
    font-size: 24px;
    font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24;
}

.submit-btn:hover {
    color: #5A9CFF;
    transform: scale(1.05);
}

.submit-btn:active {
    transform: scale(0.95);
}

.hidden {
    display: none;
}

/* Honeypot spam trap - invisible to users */
.bot-trap {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* Responsive */
@media (max-width: 768px) {
    .signup-section {
        top: auto;
        bottom: 0;
        right: 0;
        left: 0;
        padding: 0;
        background: rgba(0, 0, 0, 0.8);
        backdrop-filter: blur(10px);
    }

    .signup-form {
        padding: 1rem;
        padding-bottom: max(1rem, env(safe-area-inset-bottom));
        padding-left: max(1rem, env(safe-area-inset-left));
        padding-right: max(1rem, env(safe-area-inset-right));
    }

    .form-group {
        width: 100%;
    }

    .email-input {
        width: 100%;
    }
}
