:root {
    --primary: #4F46E5;
    --primary-hover: #059669;
    --bg-color: #0F172A;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-primary: #F8FAFC;
    --text-secondary: #94A3B8;
    --success: #10B981;
    --error: #EF4444;
    --accent-glow: rgba(16, 185, 129, 0.3);
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
    padding: 2rem 0;
}

/* Dynamic Background Shapes */
.background-shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.shape {
    position: absolute;
    filter: blur(80px);
    opacity: 0.5;
    border-radius: 50%;
    animation: float 10s infinite ease-in-out alternate;
}

.shape-1 { width: 400px; height: 400px; background: #4F46E5; top: -100px; left: -100px; }
.shape-2 { width: 300px; height: 300px; background: #0EA5E9; bottom: -50px; right: -50px; animation-delay: -5s; }
.shape-3 { width: 250px; height: 250px; background: #8B5CF6; top: 40%; left: 60%; animation-delay: -2s; }

@keyframes float {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(-30px) scale(1.1); }
}

.container {
    width: 100%;
    max-width: 900px;
    padding: 0 2rem;
    position: relative;
    z-index: 10;
}

/* Header & Logo */
.header {
    text-align: center;
    margin-bottom: 2.5rem;
    position: relative;
    padding-top: 0.5rem;
}

/* Left logo */
.header img.header-logo {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 140px;
    width: auto;
    border-radius: 10px;
    object-fit: contain;
    filter: drop-shadow(0 0 12px rgba(27, 235, 203, 0.45));
}

/* Title and badge alignment */
.header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px; /* space between title and badge */
    padding-left: 120px; /* move title + badge to the right */
    color: var(--text-primary);
}

/* IA SENIOR badge image */
.header img.header-badge {
    height: 120px; /* adjust size as needed */
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 0 12px rgba(27, 235, 203, 0.6));
    vertical-align: middle;
    margin-left: 60px; /* move badge to the right */
}

/* Subtitle */
.header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 0;
}

/* Optional: responsive adjustments */
@media (max-width: 768px) {
    .header img.header-logo {
        height: 90px;
        left: 0.5rem;
    }
    .header h1 {
        font-size: 1.8rem;
        padding-left: 100px; /* ensures text never overlaps logo */
    }
    .header img.header-badge {
        height: 48px;
    }
}


/* Form Elements */
.glass-form {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.2rem; margin-bottom: 1.5rem; }
.form-group { display: flex; flex-direction: column; gap: 0.5rem; }
.full-width { grid-column: 1 / -1; }

label { font-size: 0.9rem; font-weight: 500; color: var(--text-secondary); }

input, select {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    width: 100%;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* File Upload */
.file-drop-area {
    border: 2px dashed var(--glass-border);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    background: rgba(15, 23, 42, 0.3);
    cursor: pointer;
    transition: all 0.3s;
}

.file-drop-area:hover { border-color: var(--primary); background: rgba(79, 70, 229, 0.1); }

/* Buttons & Utilities */
.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: transform 0.2s;
}

.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 20px var(--accent-glow); }

.loader {
    border: 3px solid rgba(255,255,255,0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.hidden { display: none !important; }

/* Responsive Grid Adjustments */
@media (max-width: 768px) {
    .glass-form { padding: 1.5rem; }
    .header h1 { font-size: 1.8rem; }
}