/* Registration Forms Custom Styling */

/* Form Container Animations */
.registration-container {
    animation: fadeInUp 0.6s ease-out;
}

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

/* Role Selector Enhanced Styling */
.role-selector {
    position: relative;
    overflow: hidden;
}

.role-selector a {
    position: relative;
    transition: all 0.3s ease;
    z-index: 1;
}

.role-selector a:not(.active):hover {
    background-color: #0B3954;
    color: white;
}

.role-selector a.active {
    background: linear-gradient(135deg, #b8986e 0%, #a08660 100%);
    box-shadow: 0 4px 12px rgba(184, 152, 110, 0.3);
}

/* Form Input Enhancements */
.form-input {
    transition: all 0.3s ease;
    position: relative;
}

.form-input:focus {
    border-color: #0B3954;
    transform: none;
    box-shadow: none;
}

.form-input:focus + .form-label {
    color: #b8986e;
}

/* Form Labels */
.form-label {
    transition: color 0.3s ease;
}

/* Required Field Indicator */
.required-indicator {
    color: #ef4444;
    font-weight: 600;
}

/* Form Sections */
.form-section {
    border-left: 3px solid transparent;
    padding-left: 1rem;
    transition: border-color 0.3s ease;
}

.form-section:hover {
    border-left-color: #0B3954;
}

.form-section h3 {
    position: relative;
    padding-bottom: 0.5rem;
}

.form-section h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: linear-gradient(90deg, #b8986e, #a08660);
    border-radius: 1px;
}

/* Submit Button Enhancements */
.submit-button {
    background: #b8986e;
    color: #0B3954;
    border: 2px solid #0B3954;
    padding: 12px 24px;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Playfair Display', serif;
}

.submit-button:hover {
    background: #0B3954;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(11, 57, 84, 0.3);
}

.submit-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(11, 57, 84, 0.2);
}

.submit-button::before {
    display: none;
}

.submit-button:hover::before {
    display: none;
}

/* Checkbox and Radio Styling */
.custom-checkbox,
.custom-radio {
    position: relative;
    cursor: pointer;
}

.custom-checkbox input[type="checkbox"],
.custom-radio input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.custom-checkbox .checkmark,
.custom-radio .checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 18px;
    width: 18px;
    background-color: #f3f4f6;
    border: 2px solid #d1d5db;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.custom-radio .checkmark {
    border-radius: 50%;
}

.custom-checkbox:hover .checkmark,
.custom-radio:hover .checkmark {
    border-color: #0B3954;
    background-color: transparent;
}

.custom-checkbox input:checked ~ .checkmark,
.custom-radio input:checked ~ .checkmark {
    background-color: #b8986e;
    border-color: #b8986e;
}

.custom-checkbox .checkmark:after,
.custom-radio .checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked ~ .checkmark:after,
.custom-radio input:checked ~ .checkmark:after {
    display: block;
}

.custom-checkbox .checkmark:after {
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.custom-radio .checkmark:after {
    top: 4px;
    left: 4px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: white;
}

/* Alert Messages */
.alert {
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    border-left: 4px solid;
    animation: slideInDown 0.4s ease-out;
}

.alert-success {
    background-color: #f0fdf4;
    border-left-color: #16a34a;
    color: #15803d;
}

.alert-error {
    background-color: #fef2f2;
    border-left-color: #ef4444;
    color: #dc2626;
}

.alert-warning {
    background-color: #fffbeb;
    border-left-color: #f59e0b;
    color: #d97706;
}

.alert-info {
    background-color: #eff6ff;
    border-left-color: #3b82f6;
    color: #2563eb;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Business Account Notice */
.business-notice {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 1px solid #f59e0b;
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
}

.business-notice .icon {
    color: #f59e0b;
}

/* Form Validation */
.form-input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input.success {
    border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.error-message {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Loading States */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #16a34a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .registration-container {
        margin: 1rem;
        padding: 1rem;
    }
    
    .role-selector {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .role-selector a {
        text-align: center;
        padding: 0.75rem;
    }
    
    .form-section {
        padding-left: 0.5rem;
        border-left-width: 2px;
    }
    
    .grid-cols-2 {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

/* Focus Management */
.form-input:focus-visible {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .registration-container {
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .submit-button,
    .role-selector {
        display: none;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .form-input {
        border-width: 2px;
    }
    
    .role-selector a.active {
        background: #000;
        color: #fff;
    }
    
    .submit-button {
        background: #b8986e;
        color: #0B3954;
        border: 2px solid #0B3954;
    }
    
    .submit-button:hover {
        background: #0B3954;
        color: white;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}