/*!
 * Newsletter Section Component
 * Responsive newsletter signup section matching Church Fund theme
 */

/* Newsletter Section */
.newsletter-section {
    background-color: var(--background-color);
    padding: 80px 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
}

.newsletter-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.newsletter-header {
    margin-bottom: 20px;
}

.newsletter-label {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 14px;
    font-weight: 400;
    color: var(--text-light);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin: 0;
}

.newsletter-title {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 64px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--text-heading);
    margin: 0 0 30px;
    letter-spacing: -1px;
}

.newsletter-title-italic {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-style: italic;
    font-weight: 400;
}

.newsletter-description {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 18px;
    line-height: 1.6;
    color: var(--text-dark);
    margin: 0 0 50px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* Newsletter Form */
.newsletter-form {
    max-width: 600px;
    margin: 0 auto;
}

.newsletter-form-group {
    margin-bottom: 30px;
    text-align: left;
}

.newsletter-label-input {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 12px;
    font-weight: 400;
    color: var(--text-dark);
    letter-spacing: 1px;
    text-transform: uppercase;
    display: block;
    margin-bottom: 10px;
}

.newsletter-input {
    font-family: 'Libre Baskerville', Georgia, serif;
    width: 100%;
    padding: 15px 20px;
    border: 1px solid var(--border-color);
    border-radius: 3px;
    font-size: 16px;
    color: var(--text-dark);
    background-color: var(--white);
    transition: border-color 0.3s ease;
}

.newsletter-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(27, 45, 70, 0.1);
}

.newsletter-input::placeholder {
    color: var(--text-muted);
    opacity: 0.7;
}

/* Checkbox Group */
.newsletter-checkbox-group {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
    text-align: left;
}

.newsletter-checkbox {
    width: 18px;
    height: 18px;
    margin: 0;
    margin-right: 12px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
}

.newsletter-checkbox-label {
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 11px;
    font-weight: 400;
    color: var(--text-dark);
    letter-spacing: 1px;
    text-transform: uppercase;
    line-height: 1.6;
    margin: 0;
    cursor: pointer;
}

.newsletter-checkbox-label a {
    color: var(--primary-color);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.newsletter-checkbox-label a:hover {
    color: var(--accent-color);
}

/* Submit Button */
.newsletter-submit-btn {
    font-family: 'Libre Baskerville', Georgia, serif;
    width: 100%;
    padding: 16px 40px;
    background-color: #C5C5C5;
    color: var(--white);
    border: none;
    border-radius: 3px;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.newsletter-submit-btn:hover {
    background-color: #A8A8A8;
    transform: translateY(-2px);
}

.newsletter-submit-btn:active {
    transform: translateY(0);
}

/* Message Display */
.newsletter-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 3px;
    font-family: 'Libre Baskerville', Georgia, serif;
    font-size: 14px;
    text-align: center;
}

.newsletter-message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.newsletter-message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive Design */
@media (max-width: 768px) {
    .newsletter-section {
        padding: 60px 0;
    }
    
    .newsletter-title {
        font-size: 42px;
        margin-bottom: 20px;
    }
    
    .newsletter-description {
        font-size: 16px;
        margin-bottom: 40px;
    }
    
    .newsletter-form {
        padding: 0 10px;
    }
    
    .newsletter-submit-btn {
        padding: 14px 30px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .newsletter-section {
        padding: 40px 0;
    }
    
    .newsletter-title {
        font-size: 32px;
        letter-spacing: -0.5px;
    }
    
    .newsletter-description {
        font-size: 15px;
        margin-bottom: 30px;
    }
    
    .newsletter-input {
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .newsletter-checkbox-label {
        font-size: 10px;
    }
    
    .newsletter-submit-btn {
        padding: 12px 25px;
        font-size: 12px;
    }
}

/* Loading State */
.newsletter-form.loading .newsletter-submit-btn {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.newsletter-form.loading .newsletter-submit-btn::after {
    content: '...';
    animation: loading-dots 1.5s infinite;
}

@keyframes loading-dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}
