/**
 * Enquiry Form Styles
 * Responsive and theme-aware styling
 */

.edmark-enquiry-form-box {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 24px;
    margin-top: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.edmark-enquiry-form-box h3 {
    margin: 0 0 20px 0;
    font-size: 20px;
    font-weight: 600;
    color: #2271b1;
}

/* Form Steps */
.form-step {
    animation: fadeIn 0.3s ease-in-out;
}

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

/* Form Groups */


.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
    color: #333;
}

.form-group .required {
    color: #d63638;
}

.form-control {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s ease;
    box-sizing: border-box;
    background-color: #fff;
}

.form-control[type="text"],
.form-control[type="email"],
.form-control[type="tel"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

select.form-control {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    padding-right: 36px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    font-weight: 500;
}

select.form-control option {
    padding: 10px;
    font-weight: 500;
}

select.form-control option:first-child {
    color: #999;
}

select.form-control:hover {
    border-color: #999;
}

.form-control:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 0.2rem rgba(34, 113, 177, 0.2);
}

.form-control.error {
    border-color: #d63638;
}

.form-control.error:focus {
    box-shadow: 0 0 0 0.2rem rgba(214, 54, 56, 0.2);
}

/* Buttons */
.edmark-enquiry-form button[type="button"] {
    width: 100%;
    padding: 12px 20px;
    background-color: #2271b1;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 8px;
}

.edmark-enquiry-form button[type="button"]:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.edmark-enquiry-form button[type="button"]:active {
    transform: translateY(0);
}

.edmark-enquiry-form button[type="button"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

.form-actions button {
    flex: 1;
}

.btn-prev {
    background-color: #6c757d !important;
}

/* OTP Section */
.otp-info {
    background: #f0f6fc;
    border-left: 3px solid #2271b1;
    padding: 12px 16px;
    margin-bottom: 16px;
    border-radius: 4px;
}

.otp-info p {
    margin: 0;
    font-size: 14px;
    color: #333;
}

.resend-otp {
    text-align: center;
    margin-top: 16px;
}

.btn-resend-otp {
    background-color: transparent !important;
    color: #2271b1 !important;
    text-decoration: underline;
    padding: 8px 16px !important;
    font-size: 14px !important;
}

.btn-resend-otp:hover {
    opacity: 0.8 !important;
}

/* Completion Message */
.completion-message {
    text-align: center;
    padding: 20px 0;
}

.success-icon {
    width: 60px;
    height: 60px;
    line-height: 60px;
    margin: 0 auto 16px;
    background: #d4edda;
    color: #155724;
    border-radius: 50%;
    font-size: 32px;
    font-weight: bold;
}

.completion-message h4 {
    margin: 0 0 12px 0;
    font-size: 20px;
    color: #155724;
}

.completion-message p {
    margin: 0 0 20px 0;
    font-size: 14px;
    color: #666;
}

/* Form Messages */
.form-message {
    display: none;
    padding: 12px 16px;
    margin-top: 16px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}

.form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive Design */
@media (max-width: 768px) {
    .edmark-enquiry-form-box {
        padding: 20px;
    }
    
    .edmark-enquiry-form-box h3 {
        font-size: 18px;
    }
    
    .form-control {
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .form-actions {
        flex-direction: column;
    }
}

/* Loading State */
.edmark-enquiry-form button[type="button"]:disabled::after {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-left: 8px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

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

/* Integration with Batch Theme */
.edmark-batch-sidebar .edmark-enquiry-form-box {
    margin-top: 24px;
}

/* Admin Enquiries Page Styles */
.enquiry-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-pending {
    background: #f0f0f1;
    color: #646970;
}

.status-registered {
    background: #d5e5f7;
    color: #135e96;
}

.status-completed {
    background: #d4edda;
    color: #155724;
}

.status-failed {
    background: #f8d7da;
    color: #721c24;
}

/* Accessibility */
.form-control:focus-visible {
    outline: 2px solid #2271b1;
    outline-offset: 2px;
}

button:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* Modern Template Integration */
.edmark-enquiry-section {
    background: #f9fafb;
    padding: 60px 0;
}

.edmark-enquiry-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.enquiry-intro {
    text-align: center;
    margin-bottom: 40px;
}

.enquiry-intro h2 {
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 12px 0;
    color: #1f2937;
}

.enquiry-intro p {
    font-size: 16px;
    color: #6b7280;
    margin: 0;
}

/* Hero Layout with Form */
.hero-layout {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 48px;
    align-items: start;
}

.hero-content {
    flex: 1;
}

.hero-sidebar {
    position: sticky;
    top: 20px;
}

/* Hero Form Styles */
.hero-form {
    background: #fff;
    border: none;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.hero-form .form-header {
    text-align: center;
    margin-bottom: 24px;
    /* padding-bottom: 20px; */
    /* border-bottom: 2px solid #f0f0f0; */
}

.hero-form .form-header h3 {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: #1f2937;
    line-height: 1.2;
}

.hero-form .form-subtitle {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
    font-weight: 400;
    line-height: 1.4;
}

/* Modern template specific styles */
.edmark-batch-modern .edmark-enquiry-form-box {
    background: #fff;
    border: none;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.edmark-batch-modern .edmark-enquiry-form-box h3 {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 12px 0;
    text-align: center;
}

/* Responsive Hero Layout */
@media (max-width: 1024px) {
    .hero-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .hero-sidebar {
        position: static;
        max-width: 500px;
        margin: 0 auto;
    }
}

/* Print Styles */
@media print {
    .edmark-enquiry-form-box,
    .edmark-enquiry-section {
        display: none;
    }
}
