:root {
    --bg: #060d18;
    --cyan: #00c8ff;
    --cyan-dim: #0d3a52;
    --cyan-glow: rgba(0, 200, 255, 0.08);
    --text: #a8d4e8;
    --text-muted: #2e5f7a;
    --panel-bg: rgba(8, 15, 30, 0.85);
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: var(--bg);
    font-family: 'Orbitron', sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
    padding: 0;
}

@media (max-width: 768px) {
    body {
        padding: 1rem;
        align-items: flex-start;
        padding-top: 2rem;
    }
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(0, 200, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 200, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

#register_form {
    position: relative;
    z-index: 1;
    background: var(--panel-bg);
    border: 1px solid var(--cyan-dim);
    border-radius: 10px;
    padding: 2.5rem 2rem;
    width: min(420px, 90vw);
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow:
        0 0 40px rgba(0, 0, 0, 0.8),
        0 0 0 1px rgba(0, 200, 255, 0.04),
        inset 0 1px 0 rgba(0, 200, 255, 0.06);
    transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

#register_form:hover {
    border-color: rgba(0, 200, 255, 0.35);
    box-shadow:
        0 0 60px rgba(0, 0, 0, 0.9),
        0 0 20px rgba(0, 200, 255, 0.06),
        inset 0 1px 0 rgba(0, 200, 255, 0.1);
}

@media (max-width: 768px) {
    #register_form {
        width: 100%;
        max-width: 100%;
        padding: 1.5rem 1.25rem;
    }

    #register_form:hover {
        border-color: var(--cyan-dim);
        box-shadow:
            0 0 40px rgba(0, 0, 0, 0.8),
            0 0 0 1px rgba(0, 200, 255, 0.04),
            inset 0 1px 0 rgba(0, 200, 255, 0.06);
    }
}

#register_form h1 {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--cyan);
    margin-bottom: 2rem;
    text-shadow: 0 0 20px rgba(0, 200, 255, 0.4);
}

#register_form form {
    width: 100%;
    display: flex;
    flex-direction: column;
}

label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
    display: block;
}

input[type="email"],
input[type="password"],
input[type="text"] {
    width: 100%;
    background: rgba(0, 200, 255, 0.04);
    border: 1px solid var(--cyan-dim);
    border-radius: 6px;
    padding: 0.6rem 0.75rem;
    color: var(--text);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    outline: none;
    transition: border-color 0.25s var(--ease), background 0.25s var(--ease), box-shadow 0.25s var(--ease);
    margin-bottom: 1rem;
}

input[type="email"]:focus,
input[type="password"]:focus,
input[type="text"]:focus {
    border-color: var(--cyan);
    background: var(--cyan-glow);
    box-shadow: 0 0 0 2px rgba(0, 200, 255, 0.1);
}

@media (max-width: 768px) {
    label {
        font-size: 0.5rem;
    }

    input[type="email"],
    input[type="password"],
    input[type="text"] {
        font-size: 0.6rem;
        padding: 0.5rem 0.6rem;
        margin-bottom: 0.8rem;
    }
}

input::placeholder {
    color: var(--text-muted);
    opacity: 0.6;
}

.error-message {
    color: #dc3545;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    padding: 10px;
    margin-top: 10px;
    font-size: 0.9rem;
    text-transform: none;
}

.oauth-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.oauth-icon {
    width: 60px !important;
    height: auto !important;
    max-width: 60px !important;
    display: block;
    border-radius: 30px;
}

@media (max-width: 768px) {
    .oauth-icon {
        width: 50px !important;
        max-width: 50px !important;
    }
}

button[type="submit"] {
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.65rem 1rem;
    background: transparent;
    border: 1px solid var(--cyan-dim);
    border-radius: 6px;
    color: var(--text-muted);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    cursor: pointer;
    transition: color 0.25s var(--ease), background 0.25s var(--ease), border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

button[type="submit"]:hover {
    color: var(--cyan);
    background: var(--cyan-glow);
    border-color: var(--cyan);
    box-shadow: 0 0 12px rgba(0, 200, 255, 0.15);
}

@media (max-width: 768px) {
    button[type="submit"] {
        font-size: 0.55rem;
        padding: 0.55rem 0.8rem;
        margin-top: 0.4rem;
    }

    button[type="submit"]:hover {
        box-shadow: 0 0 8px rgba(0, 200, 255, 0.1);
    }
}

.error-msg {
    margin-top: 0.75rem;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    color: #ff4d6d;
    text-align: center;
}