/**
 * Artesh Subscription Forms Styles
 */

/* ==========================================================================
   Entity Subscribe Widget
   ========================================================================== */

.artesh-subscribe-widget {
    background: linear-gradient(135deg, #1e3a5f 0%, #0d2137 100%);
    border-radius: 12px;
    padding: 24px;
    margin: 30px 0;
    color: #fff;
}

.artesh-subscribe-widget h4 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
}

.artesh-subscribe-widget p {
    margin: 0 0 16px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.artesh-entity-subscribe-form .artesh-form-row {
    margin-bottom: 12px;
}

.artesh-entity-subscribe-form input,
.artesh-entity-subscribe-form select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 14px;
    transition: all 0.2s;
}

.artesh-entity-subscribe-form input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.artesh-entity-subscribe-form input:focus,
.artesh-entity-subscribe-form select:focus {
    outline: none;
    border-color: #4a90d9;
    background: rgba(255, 255, 255, 0.15);
}

.artesh-entity-subscribe-form select option {
    background: #1e3a5f;
    color: #fff;
}

.artesh-entity-subscribe-form button[type="submit"] {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    background: #4a90d9;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.artesh-entity-subscribe-form button[type="submit"]:hover {
    background: #5a9de9;
    transform: translateY(-1px);
}

.artesh-entity-subscribe-form button[type="submit"]:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.artesh-subscribe-success {
    text-align: center;
    padding: 20px;
}

.artesh-subscribe-success .artesh-success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: #22c55e;
    border-radius: 50%;
    font-size: 24px;
    margin-bottom: 12px;
}

.artesh-subscribe-success p {
    margin: 0;
    color: #fff;
}

/* ==========================================================================
   Footer Newsletter Popup
   ========================================================================== */

.artesh-newsletter-popup {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.artesh-newsletter-popup.artesh-popup-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-content {
    height: 50px;
    overflow: hidden;
}

.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-header h3,
.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-header p,
.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-form,
.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-success {
    display: none !important;
}

.artesh-newsletter-popup.artesh-popup-minimized .artesh-popup-minimize {
    transform: rotate(180deg);
}

.artesh-popup-content {
    width: 340px;
    max-width: calc(100vw - 40px);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    position: relative;
    transition: height 0.3s ease;
}

.artesh-popup-close,
.artesh-popup-minimize {
    position: absolute;
    top: 12px;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.1);
    color: #666;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    line-height: 1;
}

.artesh-popup-close {
    right: 12px;
}

.artesh-popup-minimize {
    right: 48px;
    transition: transform 0.3s;
}

.artesh-popup-close:hover,
.artesh-popup-minimize:hover {
    background: rgba(0, 0, 0, 0.15);
    color: #333;
}

.artesh-popup-header {
    padding: 24px 24px 0;
    text-align: center;
}

.artesh-popup-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.artesh-popup-header h3 {
    margin: 0 0 6px;
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
}

.artesh-popup-header p {
    margin: 0;
    font-size: 14px;
    color: #64748b;
}

.artesh-popup-form {
    padding: 20px 24px 24px;
}

.artesh-popup-form .artesh-form-row {
    margin-bottom: 12px;
}

.artesh-popup-form input,
.artesh-popup-form select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8fafc;
    font-size: 14px;
    color: #334155;
    transition: all 0.2s;
}

.artesh-popup-form input:focus,
.artesh-popup-form select:focus {
    outline: none;
    border-color: #4a90d9;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.1);
}

.artesh-popup-form input::placeholder {
    color: #94a3b8;
}

.artesh-popup-submit {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #1e3a5f 0%, #2d5a8a 100%);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.artesh-popup-submit:hover {
    background: linear-gradient(135deg, #2d5a8a 0%, #1e3a5f 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 58, 95, 0.3);
}

.artesh-popup-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.artesh-popup-privacy {
    margin: 12px 0 0;
    font-size: 12px;
    color: #94a3b8;
    text-align: center;
}

.artesh-popup-success {
    padding: 40px 24px;
    text-align: center;
}

.artesh-popup-success .artesh-success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: #22c55e;
    border-radius: 50%;
    color: #fff;
    font-size: 28px;
    margin-bottom: 16px;
}

.artesh-popup-success h4 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
}

.artesh-popup-success p {
    margin: 0;
    font-size: 14px;
    color: #64748b;
}

/* Form Error */
.artesh-form-error {
    padding: 10px 14px;
    margin-bottom: 12px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    color: #dc2626;
    font-size: 13px;
}

/* ==========================================================================
   Mobile Responsive
   ========================================================================== */

@media (max-width: 480px) {
    .artesh-newsletter-popup {
        bottom: 0;
        right: 0;
        left: 0;
    }
    
    .artesh-popup-content {
        width: 100%;
        max-width: 100%;
        border-radius: 16px 16px 0 0;
    }
    
    .artesh-newsletter-popup.artesh-popup-visible {
        transform: translateY(0);
    }
}

/* ==========================================================================
   Inline Subscribe Form (for articles, etc.)
   ========================================================================== */

.artesh-inline-subscribe {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    margin: 24px 0;
}

.artesh-inline-subscribe h4 {
    margin: 0 0 12px;
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
}

.artesh-inline-subscribe form {
    display: flex;
    gap: 10px;
}

.artesh-inline-subscribe input[type="email"] {
    flex: 1;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
}

.artesh-inline-subscribe button {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    background: #1e3a5f;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

.artesh-inline-subscribe button:hover {
    background: #2d5a8a;
}

@media (max-width: 480px) {
    .artesh-inline-subscribe form {
        flex-direction: column;
    }
    
    .artesh-inline-subscribe button {
        width: 100%;
    }
}
