/* Modern Estimate Form Styles with Glassmorphism */
.estimate-form-container {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.18);
    transition: all 0.3s ease;
}

/* Form Layout and Spacing */
.form-section {
    padding: 2rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    margin-top: 2rem;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
    margin-top: 1rem;
}

.row {
    margin-bottom: 1.25rem;
}

/* Label Styles */
.form-group label {
    position: absolute;
    left: 1rem;
    top: -12px;
    transform: translateY(-50%);
    background: var(--color-background);
    padding: 0 0.5rem;
    color: var(--color-text-light);
    transition: all 0.3s ease;
    pointer-events: none;
    font-size: 0.85rem;
    z-index: 1;
    line-height: 1;
}

.form-group input:not(:placeholder-shown) ~ label,
.form-group select:not(:placeholder-shown) ~ label,
.form-group input[type="date"] ~ label {
    top: -12px;
    font-size: 0.85rem;
    color: var(--color-highlight);
    background: var(--color-background);
}

/* Input Field Styles */
.form-control {
    height: 50px;
    padding: 0.75rem 1.25rem;
    font-size: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--color-text);
    transition: all 0.3s ease;
    width: 100%;
}

.form-control:focus {
    border-color: var(--color-highlight);
    box-shadow: 0 0 0 2px rgba(207, 140, 41, 0.2);
    background: rgba(255, 255, 255, 0.05);
}

/* Select Field Styles */
select.form-control {
    cursor: pointer;
    appearance: none;
    padding-right: 2.5rem;
}

/* Commodity Selection Container */
.commodity-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

/* HSN Code Search Field */
.hsn-search-container {
    margin-top: 1rem;
}

/* HSN Code Field Spacing */
#airHsnCode,
#oceanHsnCode {
    margin-top: 2rem;
}

.form-group:has(#airHsnCode),
.form-group:has(#oceanHsnCode) {
    margin-top: 2rem;
}

/* Row Spacing */
.row {
    margin-bottom: 1.25rem;
}

.row:last-child {
    margin-bottom: 0;
}

/* Form Section Gaps */
.form-row {
    display: flex;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.form-row > div {
    flex: 1;
}

/* Date Input Specific Styles */
input[type="date"].form-control {
    padding: 0.75rem 1.25rem;
}

input[type="date"].form-control ~ label {
    top: -12px;
    background: var(--color-background);
}

/* Submit Button Styles */
.submit-btn {
    margin-top: 2rem;
    padding: 1rem 3rem;
    font-size: 1.1rem;
    border-radius: 30px;
    background: var(--color-highlight);
    border: none;
    color: var(--color-text);
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(207, 140, 41, 0.3);
}

/* Freight Type Cards */
.freight-type-selector {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.freight-type-card {
    flex: 1;
    padding: 2rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.freight-type-card.active {
    background: rgba(207, 140, 41, 0.1);
    border-color: var(--color-highlight);
}

.freight-type-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.05);
}

/* Animated Icons */
.fa-plane {
    animation: takeoff 2s infinite ease-in-out;
}

.fa-ship {
    animation: float 3s infinite ease-in-out;
}

.fa-truck {
    animation: drive 2s infinite linear;
}

@keyframes takeoff {
    0%, 100% { transform: translateY(0) rotate(-45deg); }
    50% { transform: translateY(-10px) rotate(-45deg); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

@keyframes drive {
    0% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    100% { transform: translateX(-5px); }
}

/* Load Type Selector Styles */
.load-type-selector {
    margin-bottom: 2rem;
}

.load-type-options {
    display: flex;
    gap: 1rem;
    margin: 1rem 0;
}

.load-type-option {
    flex: 1;
    position: relative;
}

.load-type-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 2;
}

.load-type-option label {
    display: block;
    padding: 1rem;
    text-align: center;
    background: var(--color-background-light);
    border: 2px solid var(--color-border);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.load-type-option input[type="radio"]:checked + label {
    background: var(--color-highlight);
    border-color: var(--color-highlight);
    color: white;
}

.load-type-option input[type="radio"]:focus + label {
    box-shadow: 0 0 0 2px var(--color-highlight-light);
}

/* Form Validation Styles */
.error-message {
    color: #ff4444;
    font-size: 0.85rem;
    margin-top: 0.25rem;
    margin-left: 1rem;
    display: block;
    opacity: 0;
    animation: fadeIn 0.3s ease forwards;
}

.form-control.error {
    border-color: #ff4444 !important;
    box-shadow: 0 0 0 0.2rem rgba(255, 68, 68, 0.25);
}

.load-type-selector.error {
    border: 1px solid #ff4444;
    border-radius: 8px;
    padding: 4px;
}

/* SweetAlert2 Custom Styles */
.swal2-popup {
    background: var(--color-background) !important;
    border: 1px solid var(--color-border);
    border-radius: 16px !important;
}

.swal2-title {
    color: var(--color-text) !important;
}

.swal2-html-container {
    color: var(--color-text-light) !important;
}

.swal2-confirm {
    background: var(--color-highlight) !important;
}

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

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.animated {
    animation-duration: 0.3s;
    animation-fill-mode: both;
}

.fadeIn {
    animation-name: fadeIn;
}

.fadeInUp {
    animation-name: fadeInUp;
}

.faster {
    animation-duration: 0.2s;
}

/* Fix Owl Carousel loading issue */
.owl-carousel {
    display: none;
}

.owl-carousel.owl-loaded {
    display: block;
}

/* Responsive Adjustments */
@media (max-width: 576px) {
    .load-type-options {
        flex-direction: column;
        width: 100%;
    }

    .load-type-option.ptl-option,
    .load-type-option.ftl-option {
        width: 100%;
        flex: none;
    }

    .load-type-option label {
        width: 100%;
        justify-content: flex-start;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .form-section {
        padding: 1.5rem;
    }

    .freight-type-selector {
        flex-direction: column;
    }

    .commodity-container {
        grid-template-columns: 1fr;
    }

    .form-row {
        flex-direction: column;
        gap: 1rem;
    }
}

/* Error State Styles */
.form-control.error {
    border-color: #ff4444 !important;
    box-shadow: 0 0 0 0.2rem rgba(255, 68, 68, 0.25);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Loading State */
.form-control.loading {
    background-image: linear-gradient(45deg, rgba(255,255,255,0.05) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.05) 50%, rgba(255,255,255,0.05) 75%, transparent 75%, transparent);
    background-size: 1rem 1rem;
    animation: loading-stripes 1s linear infinite;
}

@keyframes loading-stripes {
    from { background-position: 0 0; }
    to { background-position: 1rem 0; }
}

/* Background Animation */
.Estimate_area::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, 
        rgba(207, 140, 41, 0.1),
        rgba(255, 255, 255, 0.05),
        rgba(207, 140, 41, 0.1));
    filter: blur(100px);
    animation: gradientBG 15s ease infinite;
    z-index: -1;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
