
/* Modal animation 
@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#veetelecom-error-modal > div {
    animation: modalFadeIn 0.3s ease;
}
*/
/* Prevent border color change on Escape key */
.woocommerce-error:focus {
    outline: none !important;
    border-left: 4px solid #a40000 !important;
    border-top: none !important;
    border-right: none !important;
    border-bottom: none !important;
}

/* Ensure focus doesn't change styling */
.woocommerce-error:focus-visible {
    outline: none !important;
}

/* ===== ENHANCED WOOCOMMERCE ERROR STYLING - GLASS MORPHISM ===== */
.woocommerce-error {
    display: block !important;
    background: rgba(255, 236, 236, 0.95) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    border-left: 4px solid #a40000 !important;
    color: #a40000 !important;
    padding: 20px 24px !important;
    margin: 10px 0 !important;
    border-radius: 16px !important;
    list-style: none !important;
    font-weight: 400 !important;
    border-top: none !important;
    border-right: none !important;
    border-bottom: none !important;
    box-shadow: 0 20px 40px rgba(164, 0, 0, 0.2), 0 8px 20px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(255, 255, 255, 0.2) inset !important;
    
    /* Floating properties */
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    z-index: 999999 !important;
    width: 90% !important;
    max-width: 420px !important;
    text-align: center !important;
    animation: floatIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    
    /* Additional polish */
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    border: 1px solid rgba(164, 0, 0, 0.2) !important;
    line-height: 1.5 !important;
}

/* Style for the list item inside error */
.woocommerce-error li {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 16px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

/* Add an icon before the message */
.woocommerce-error li::before {
    content: "⚠️" !important;
    font-size: 20px !important;
    display: inline-block !important;
    margin-right: 4px !important;
}

/* Add a close button */
.woocommerce-error::after {
    /*content: "✕" !important;*/
    position: absolute !important;
    top: 12px !important;
    right: 16px !important;
    font-size: 18px !important;
    color: #a40000 !important;
    cursor: pointer !important;
    opacity: 0.7 !important;
    transition: opacity 0.2s ease, transform 0.2s ease !important;
    width: 24px !important;
    height: 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 50% !important;
    background: rgba(164, 0, 0, 0.1) !important;
}

.woocommerce-error:hover::after {
    opacity: 1 !important;
    transform: scale(1.1) !important;
    background: rgba(164, 0, 0, 0.2) !important;
}

/* Add a subtle shine effect */
.woocommerce-error::before {
    content: "" !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: 2px !important;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent) !important;
    border-radius: 16px 16px 0 0 !important;
}

/* Add animation */
@keyframes floatIn {
    0% {
        opacity: 0;
        transform: translate(-50%, -40%) scale(0.9);
    }
    50% {
        transform: translate(-50%, -52%) scale(1.02);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Add pulse effect for attention */
@keyframes gentlePulse {
    0% {
        box-shadow: 0 20px 40px rgba(164, 0, 0, 0.2), 0 8px 20px rgba(0, 0, 0, 0.1);
    }
    50% {
        box-shadow: 0 25px 45px rgba(164, 0, 0, 0.3), 0 10px 25px rgba(0, 0, 0, 0.15);
    }
    100% {
        box-shadow: 0 20px 40px rgba(164, 0, 0, 0.2), 0 8px 20px rgba(0, 0, 0, 0.1);
    }
}

.woocommerce-error {
    animation: floatIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), gentlePulse 2s infinite !important;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .woocommerce-error {
        max-width: 90% !important;
        padding: 18px 20px !important;
    }
    
    .woocommerce-error li {
        font-size: 15px !important;
    }
    
    .woocommerce-error::after {
        top: 10px !important;
        right: 12px !important;
        width: 22px !important;
        height: 22px !important;
        font-size: 16px !important;
    }
}



/* =====================================================
   ENHANCED CHECKOUT PAGE STYLES - MODERN & ATTRACTIVE
===================================================== */

/* Main container for pincode validation */
.veetelecom-box {
    margin-top: 12px;
    font-weight: 400;
    animation: slideIn 0.3s ease;
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Validation message styling */
.veetelecom-box .veetelecom-validation-message {
    border-radius: 12px;
    padding: 14px 16px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

/* Success state */
.veetelecom-box .veetelecom-validation-success {
    background: linear-gradient(135deg, #f0f9f0 0%, #e6f3e6 100%);
    border-left: 4px solid #0a8a0a;
    color: #0a8a0a;
}

/* Error state */
.veetelecom-box .veetelecom-validation-error {
    background: linear-gradient(135deg, #fff0f0 0%, #ffe6e6 100%);
    border-left: 4px solid #a40000;
    color: #a40000;
    font-weight: 400 !important;
    margin-top: 5px;
}

/* Checking state */
.veetelecom-box .veetelecom-validation-checking {
    background: linear-gradient(135deg, #f5f5f5 0%, #eeeeee 100%);
    border-left: 4px solid #999;
    color: #666;
}

/* City info display */
.veetelecom-city {
    margin-top: 10px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #e8f0fe 0%, #d4e4fc 100%);
    border-radius: 12px;
    color: #0D47A1;
    font-size: 13px;
    border: 1px solid rgba(13, 71, 161, 0.2);
    box-shadow: 0 2px 8px rgba(13, 71, 161, 0.1);
    display: flex;
    align-items: center;
    gap: 8px;
    animation: fadeIn 0.3s ease;
}

.veetelecom-city::before {
    content: "📍";
    font-size: 16px;
}

/* View available link */
.veetelecom-view-area {
    color: #0066FF !important;
    text-decoration: none !important;
    font-size: 13px;
    font-weight: 400;
    font-style: italic;
    padding: 6px 12px;
    background: rgba(0, 102, 255, 0.05);
    border-radius: 20px;
    transition: all 0.2s ease;
    display: inline-block;
    margin-left: 8px;
}

.veetelecom-view-area:hover {
    background: rgba(0, 102, 255, 0.1);
    color: #0052cc !important;
    transform: translateY(-1px);
}

/* Pincodes dropdown container - Base styles */
.veetelecom-available-pincodes {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    animation: dropDown 0.25s ease;
    /* Hidden by default - completely invisible */
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    box-shadow: none !important;
}

@keyframes dropDown {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Show when open class is added */
.veetelecom-available-pincodes.open {
    display: flex !important;
    height: auto !important;
    min-height: auto !important;
    max-height: 280px !important;
    margin-top: 12px !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    box-shadow: 0 12px 30px rgba(0,0,0,0.15) !important;
}

/* Scroll area for pins */
.veetelecom-pin-scroll {
    max-height: 280px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 8px;
    background: #fafafa;
}

/* Individual pin items */
.veetelecom-pin {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    margin: 6px 0;
    font-size: 15px;
    font-weight: 500;
    background: #ffffff;
    color: #0D47A1;
    border-radius: 12px;
    cursor: pointer;
    border: 1px solid rgba(13, 71, 161, 0.15);
    width: 100%;
    text-align: left;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}

.veetelecom-pin:hover {
    background: linear-gradient(135deg, #E3F0FF 0%, #d1e4ff 100%);
    border-color: #0D47A1;
    transform: translateX(2px);
    box-shadow: 0 6px 12px rgba(13, 71, 161, 0.15);
}

.veetelecom-pin small {
    font-weight: normal;
    font-size: 12px;
    color: #666;
    background: rgba(0,0,0,0.03);
    padding: 4px 10px;
    border-radius: 30px;
    white-space: nowrap;
    margin-left: 10px;
}

.veetelecom-pin:hover small {
    background: rgba(13, 71, 161, 0.1);
    color: #0D47A1;
}

/* Toggle button for more/less */
.veetelecom-toggle {
    display: block;
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #a40000 0%, #b30000 100%);
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    border: none;
    transition: all 0.2s ease;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

.veetelecom-toggle:hover {
    background: linear-gradient(135deg, #b30000 0%, #c40000 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(164, 0, 0, 0.3);
}

.veetelecom-toggle:active {
    transform: translateY(0);
}

/* Hidden pins */
.veetelecom-pin.veetelecom-hidden {
    display: none !important;
}

/* Loading animation for city names */
.veetelecom-pin small.city-name {
    background: none;
    padding: 0;
    font-style: italic;
    color: #888;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { opacity: 0.6; }
    50% { opacity: 1; }
    100% { opacity: 0.6; }
}

/* ===== DESKTOP STYLES ===== */
@media (min-width: 768px) {
    .veetelecom-box {
        width: 360px !important;
        max-width: 360px !important;
        padding: 10px !important;
    }
    
    .veetelecom-available-pincodes.open {
        display: block !important;
        max-height: 300px !important;
    }
    
    .veetelecom-pin-scroll {
        max-height: 280px;
        padding-bottom: 60px;
        box-sizing: border-box !important;
    }
    
    .veetelecom-pin {
        padding: 16px 14px;
        font-size: 16px;
    }
    
    .veetelecom-toggle {
        position: sticky;
        bottom: 0;
        height: 56px;
        line-height: 56px;
        padding: 0 !important;
        border-radius: 0;
        box-shadow: 0 -4px 10px rgba(0,0,0,0.1);
        box-sizing: border-box !important;
    }
}

/* ===== MOBILE STYLES ===== */
@media (max-width: 767px) {
    .veetelecom-box {
        width: 100% !important;        /* Takes full width of screen */
        max-width: 100% !important;     /* Prevents overflow */
        padding: 10px !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    .veetelecom-available-pincodes.open {
        display: block !important;
        max-height: 300px !important;
    }
    
    .veetelecom-pin-scroll {
        max-height: 280px;
        padding-bottom: 60px;
        box-sizing: border-box !important;
    }
    
    .veetelecom-pin {
        padding: 16px 14px;
        font-size: 16px;
    }
    
    .veetelecom-toggle {
        position: sticky;
        bottom: 0;
        height: 56px;
        line-height: 56px;
        padding: 0 !important;
        border-radius: 0;
        box-shadow: 0 -4px 10px rgba(0,0,0,0.1);
        box-sizing: border-box !important;
    }
}

/* Enhance the input field styling */
.veetelecom-box + input[name="billing_postcode"],
.veetelecom-box + input[name="shipping_postcode"] {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 14px;
    font-size: 16px;
    transition: all 0.2s ease;
}

.veetelecom-box + input[name="billing_postcode"]:focus,
.veetelecom-box + input[name="shipping_postcode"]:focus {
    border-color: #a40000;
    box-shadow: 0 0 0 3px rgba(164, 0, 0, 0.1);
    outline: none;
}

/* Global box-sizing */
.veetelecom-box,
.veetelecom-available-pincodes,
.veetelecom-pin,
.veetelecom-toggle,
.veetelecom-pin-scroll {
    box-sizing: border-box;
}

/* Remove any extra space after plugin */
.veetelecom-box + * {
    margin-top: 0 !important;
}