/* NEWSLETTER POPUP STYLES - FIXED VERSION */
.newsletter-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.newsletter-popup.active {
    display: flex !important;
}

.newsletter-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1;
}

.newsletter-content {
    position: relative;
    background: rgba(29, 29, 29, 0.98);
    border: 2px solid var(--primary);
    border-radius: 20px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 50px rgba(255, 109, 0, 0.3);
    overflow: visible; /* Changed from hidden to visible */
    z-index: 2;
}

.newsletter-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--light);
    font-size: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.newsletter-close:hover {
    color: var(--accent);
    transform: rotate(90deg);
}

.newsletter-header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    z-index: 5;
}

.newsletter-icon {
    font-size: 48px;
    color: var(--accent);
    margin-bottom: 20px;
}

.newsletter-header h2 {
    font-size: 2rem;
    color: var(--light);
    margin-bottom: 10px;
}

.newsletter-header p {
    color: #ccc;
    font-size: 1rem;
}

.newsletter-form {
    position: relative;
    z-index: 5;
}

.form-group {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

/* FORM ELEMENTS STYLING - FIXED DROPDOWN */
.form-group input,
.form-group select {
    flex: 1;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--light);
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.08);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

/* FIXED DROPDOWN STYLING */
.form-group select {
    background-color: rgba(29, 29, 29, 0.95) !important;
    color: var(--light) !important;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M1 1L6 6L11 1' stroke='%23FFFAEB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 12px;
    padding-right: 40px;
}

.form-group select option {
    background: var(--dark) !important;
    color: var(--light) !important;
    padding: 10px;
}

/* For better browser compatibility */
.form-group select::-ms-expand {
    display: none;
}

/* FIXED SUBMIT BUTTON STYLES */
.newsletter-btn {
    width: 100%;
    padding: 18px 30px;
    background: var(--primary) !important;
    color: var(--light) !important;
    border: 2px solid var(--primary) !important;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.3s ease;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 10px;
    z-index: 10;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.newsletter-btn:hover {
    background: var(--accent) !important;
    border-color: var(--accent) !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 109, 0, 0.5);
}

.newsletter-btn:active {
    transform: translateY(0);
}

.newsletter-btn span,
.newsletter-btn i {
    color: var(--light) !important;
    pointer-events: none; /* Ensure child elements don't block click */
}

.form-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
    color: #ccc;
    font-size: 0.9rem;
}

/* FIXED SUBMIT BUTTON STYLES */
.newsletter-btn {
    width: 100%;
    padding: 18px 30px;
    background: var(--primary) !important; /* Force solid background */
    color: var(--light) !important;
    border: 2px solid var(--primary) !important;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.3s ease;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 10px;
    z-index: 10; /* Ensure button is above other elements */
}

.newsletter-btn:hover {
    background: var(--accent) !important;
    border-color: var(--accent) !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 109, 0, 0.5);
}

.newsletter-btn span,
.newsletter-btn i {
    color: var(--light) !important;
}

.newsletter-success {
    display: none;
    text-align: center;
    padding: 40px 0;
}

.newsletter-success.show {
    display: block;
}

.newsletter-success i {
    font-size: 60px;
    color: #06D6A0;
    margin-bottom: 20px;
}

.newsletter-footer {
    text-align: center;
    margin-top: 20px;
    color: #888;
    font-size: 0.85rem;
}

/* Remove all conflicting animations and effects */
.newsletter-btn::before,
.newsletter-btn::after {
    display: none !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .newsletter-content {
        padding: 30px 20px;
    }
    
    .form-group {
        flex-direction: column;
        gap: 15px;
    }
    
    .newsletter-btn {
        padding: 16px 25px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .newsletter-content {
        width: 95%;
        margin: 10px;
    }
    
    .newsletter-btn {
        padding: 14px 20px;
        font-size: 15px;
    }
}

/* Additional fixes for dropdown and button */

/* Force dark theme for select dropdown */
#newsletterPopup select,
#interests {
    background-color: #1D1D1D !important;
    color: #FFFAEB !important;
}

#newsletterPopup select option,
#interests option {
    background-color: #1D1D1D !important;
    color: #FFFAEB !important;
    padding: 8px !important;
}

/* Ensure button is clickable */
#newsletterPopup .newsletter-btn,
#newsletterForm button[type="submit"] {
    pointer-events: auto !important;
    cursor: pointer !important;
    position: relative !important;
    z-index: 999 !important;
}

/* Fix for Chrome/Safari dropdown styling */
@media screen and (-webkit-min-device-pixel-ratio:0) {
    #newsletterPopup select {
        background-color: #1D1D1D !important;
        color: #FFFAEB !important;
    }
}

/* Debug styles - remove after testing */
.newsletter-btn:hover {
    background-color: #FFD166 !important;
    color: #1D1D1D !important;
}

.newsletter-btn:active {
    background-color: #FF6D00 !important;
    transform: scale(0.98);
}

/* Additional CSS for phone input styling */
input[type="tel"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Ensure consistent styling for all input types */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select {
    flex: 1;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--light);
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="tel"]:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.08);
}

/* Style for optional label in placeholder */
.form-group input[type="tel"]::placeholder {
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
}

/* Mobile phone number formatting */
@media (max-width: 768px) {
    input[type="tel"] {
        font-size: 16px; /* Prevents zoom on mobile */
    }
}