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

body {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 50%, #667eea 100%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.registration-container {
    width: 100%;
    max-width: 560px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 40px;
    backdrop-filter: blur(10px);
    animation: slideUp 0.5s ease-out;
}

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

.header {
    text-align: center;
    margin-bottom: 32px;
}

.header .icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-size: 32px;
    color: white;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.header h1 {
    color: #1e3c72;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.header p {
    color: #6c757d;
    font-size: 0.95rem;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    color: #495057;
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 6px;
}

.form-group label .required {
    color: #dc3545;
    margin-left: 2px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    color: #495057;
    transition: all 0.2s ease;
    background: #f8f9fa;
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.15);
}

.form-group input.error,
.form-group textarea.error {
    border-color: #dc3545;
    background: #fff5f5;
}

.form-group .error-text {
    color: #dc3545;
    font-size: 0.8rem;
    margin-top: 4px;
    display: none;
}

.form-group .error-text.visible {
    display: block;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.btn-submit {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 8px;
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.btn-submit:active:not(:disabled) {
    transform: translateY(0);
}

.btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.spinner {
    display: none;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.btn-submit.loading .spinner {
    display: inline-block;
}

.btn-submit.loading .btn-text {
    display: none;
}

.btn-submit.loading .loading-text {
    display: inline;
}

.btn-submit .loading-text {
    display: none;
}

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

.footer-links {
    text-align: center;
    margin-top: 24px;
}

.footer-links a {
    color: #667eea;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #764ba2;
    text-decoration: underline;
}

.alert {
    padding: 14px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    display: none;
}

.alert.visible {
    display: block;
}

.alert-error {
    background: #fff5f5;
    border: 1px solid #fecaca;
    color: #dc3545;
}

@media (max-width: 576px) {
    body {
        padding: 12px;
    }

    .registration-container {
        padding: 24px 16px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .header h1 {
        font-size: 1.3rem;
    }

    .header p {
        font-size: 0.85rem;
    }

    .form-group input,
    .form-group textarea {
        padding: 10px 14px;
        font-size: 0.9rem;
    }

    .btn-submit {
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .header .icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
    }
}

@media (max-width: 380px) {
    .registration-container {
        padding: 20px 12px;
    }

    .header h1 {
        font-size: 1.15rem;
    }

    .form-group label {
        font-size: 0.8rem;
    }

    .footer-links a {
        font-size: 0.8rem;
    }
}

.swal2-popup {
    border-radius: 16px !important;
    padding: 32px !important;
}

.swal2-title {
    color: #1e3c72 !important;
    font-size: 1.3rem !important;
}

.swal2-html-container {
    color: #6c757d !important;
    font-size: 0.95rem !important;
}

.swal2-icon-success {
    border-color: #667eea !important;
    color: #667eea !important;
}
