@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600&display=swap');

:root {
    --primary-color: #00f2ff;
    --secondary-color: #7000ff;
    --bg-dark: #050505;
    --text-light: #e0e0e0;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background: var(--bg-dark);
    color: var(--text-light);
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* Drifting Stars Background */
.stars-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at center, #1a1a2e 0%, #050505 100%);
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.5;
    animation: drift linear infinite;
}

@keyframes drift {
    from { transform: translateY(0) translateX(0); }
    to { transform: translateY(-100vh) translateX(20vw); }
}

/* Glassmorphism Card */
.card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    padding: 2.5rem;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 850px;
    animation: float 6s ease-in-out infinite;
    position: relative;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.7), 0 0 20px rgba(0, 242, 255, 0.1);
    transition: all 0.4s ease;
}

h1 {
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-align: center;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 1px;
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    opacity: 0.8;
}

input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    color: white;
    outline: none;
    transition: all 0.3s ease;
}

input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(0, 242, 255, 0.3);
    background: rgba(255, 255, 255, 0.07);
}

button {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 12px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

button:hover {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(112, 0, 255, 0.4);
    filter: brightness(1.1);
}

/* Success State Styles */
#result {
    display: none;
    text-align: center;
    margin-top: 1rem;
}

.code-pill {
    background: rgba(0, 242, 255, 0.1);
    border: 1px solid var(--primary-color);
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
    font-family: monospace;
    font-size: 1.2rem;
    color: var(--primary-color);
    box-shadow: 0 0 15px rgba(0, 242, 255, 0.2);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.copy-btn {
    background: transparent;
    border: 1px solid var(--glass-border);
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    width: auto;
    margin-top: 10px;
}

.tooltip {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: black;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: bold;
    display: none;
}
