:root {
    /* Brand Colors */
    --primary: #003366; /* Deep blue from GTO */
    --primary-light: #00509e;
    --secondary: #e6b800; /* Gold/Yellow accent */
    --accent: #00a859; /* Green accent */
    --accent-pink: #e6007e; /* Pink from "Turismo al 100" or generic GTO */
    
    /* Glassmorphism Variables */
    --glass-bg: rgba(255, 255, 255, 0.15);
    --glass-border: rgba(255, 255, 255, 0.3);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --glass-blur: blur(16px);
    
    /* Form elements */
    --text-color: #ffffff;
    --input-bg: rgba(255, 255, 255, 0.1);
    --input-border: rgba(255, 255, 255, 0.4);
    --input-focus: rgba(255, 255, 255, 0.8);
    --error-color: #ff4d4d;
    --success-color: #00cc66;
}

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

body {
    font-family: 'Outfit', sans-serif;
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 1rem;
    overflow-x: hidden;
}

/* Background */
.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Using the local image, adding a dark gradient overlay for better text readability */
    background: linear-gradient(135deg, rgba(0, 20, 60, 0.8) 0%, rgba(20, 60, 100, 0.7) 100%),
                url('image/DSC_0039.JPG') center/cover no-repeat;
    z-index: -1;
    animation: bgPulse 20s infinite alternate;
}

@keyframes bgPulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.05); }
}

/* Glass Container */
.glass-container {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    border-radius: 24px;
    width: 100%;
    max-width: 900px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
}

/* Header */
.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.logos-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.logo-sectur, .logo-gto {
    max-height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3));
}

.form-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    background: linear-gradient(to right, #fff, var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0px 4px 10px rgba(0,0,0,0.2);
}

.form-header .subtitle {
    font-size: 1.1rem;
    font-weight: 300;
    opacity: 0.9;
}

/* Progress Bar */
.progress-bar-container {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    margin-top: 1.5rem;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--secondary), var(--accent-pink));
    width: 14%; /* initial width */
    transition: width 0.5s ease-in-out;
}

/* Steps System */
.form-step {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.form-step.active {
    display: block;
}

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

.form-step h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 0.5rem;
    color: var(--secondary);
}

.step-desc {
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    opacity: 0.8;
}

/* Grid Layouts */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 1.5rem;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

/* Inputs & Labels */
label {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="url"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 8px;
    color: var(--text-color);
    font-family: inherit;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

input::placeholder, textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

input:focus, select:focus, textarea:focus {
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--input-focus);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

select option {
    background: var(--primary);
    color: white;
}

/* Error States */
input.error, select.error, textarea.error {
    border-color: var(--error-color);
    background: rgba(255, 77, 77, 0.1);
}

.error-msg {
    color: var(--error-color);
    font-size: 0.8rem;
    margin-top: 0.3rem;
}

/* Radio Cards */
.radio-cards {
    display: flex;
    gap: 1.5rem;
}

.radio-card {
    flex: 1;
    cursor: pointer;
    position: relative;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.radio-card .card-content {
    background: var(--input-bg);
    border: 2px solid var(--input-border);
    border-radius: 12px;
    padding: 2rem 1rem;
    text-align: center;
    transition: all 0.3s ease;
}

.radio-card .icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
}

.radio-card input:checked + .card-content {
    background: rgba(255, 255, 255, 0.25);
    border-color: var(--secondary);
    box-shadow: 0 0 15px rgba(230, 184, 0, 0.4);
    transform: translateY(-5px);
}

/* File Upload */
.file-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.file-upload {
    background: rgba(0, 0, 0, 0.2);
    padding: 1rem;
    border-radius: 8px;
    border: 1px dashed var(--input-border);
}

.file-upload input[type="file"] {
    background: transparent;
    border: none;
    padding: 0;
    margin-top: 0.5rem;
    font-size: 0.85rem;
}

.file-upload input[type="file"]::file-selector-button {
    background: var(--primary-light);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    transition: 0.3s;
    font-family: inherit;
    margin-right: 1rem;
}

.file-upload input[type="file"]::file-selector-button:hover {
    background: var(--primary);
}

/* Privacy Box */
.privacy-box {
    background: rgba(0, 0, 0, 0.3);
    padding: 1.5rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

.privacy-box a {
    color: var(--secondary);
    text-decoration: none;
}

.privacy-box a:hover {
    text-decoration: underline;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* Buttons */
.form-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.btn {
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 50px;
    font-family: inherit;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--secondary), #d4a000);
    color: #333;
    box-shadow: 0 4px 15px rgba(230, 184, 0, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(230, 184, 0, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-submit {
    background: linear-gradient(135deg, var(--accent), #008f4c);
    color: white;
    width: 100%;
    padding: 1rem;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(0, 168, 89, 0.4);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 168, 89, 0.6);
}

.submit-action {
    margin-top: 2rem;
    display: none; /* Shown in step 7 via JS */
}

/* Loader */
.loader-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 20, 50, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 100;
    border-radius: 24px;
}

.glass-spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--secondary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

@keyframes spin { 
    to { transform: rotate(360deg); }
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 3rem 1rem;
}

.icon-success {
    font-size: 5rem;
    color: var(--success-color);
    margin-bottom: 1rem;
    text-shadow: 0 0 20px rgba(0, 204, 102, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
    .form-row, .file-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .radio-cards {
        flex-direction: column;
    }
    .glass-container {
        padding: 1.5rem;
    }
    .form-header h1 {
        font-size: 2rem;
    }
}
