/**
 * Long Island Today (LIT) - Production Styles
 * Cookie Consent, PWA Install Prompt
 */

/* ============================================
   COOKIE CONSENT BANNER - Minimal Modern Style
   ============================================ */

#cookie-consent-banner {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    max-width: 420px;
    background: #171717;
    color: #ffffff;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 768px) {
    #cookie-consent-banner {
        left: 20px;
        right: auto;
    }
}

#cookie-consent-banner.visible {
    opacity: 1;
    transform: translateY(0);
}

.cookie-consent-content {
    padding: 20px;
}

.cookie-consent-text {
    margin-bottom: 16px;
}

.cookie-consent-icon {
    display: none;
}

.cookie-consent-text h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 6px 0;
}

.cookie-consent-text p {
    font-size: 0.8rem;
    color: #a3a3a3;
    margin: 0;
    line-height: 1.5;
}

.cookie-consent-actions {
    display: flex;
    gap: 8px;
}

.cookie-btn {
    padding: 10px 18px;
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    font-family: inherit;
}

.cookie-btn-primary {
    background: #E86A33;
    color: white;
    flex: 1;
}

.cookie-btn-primary:hover {
    background: #d35a24;
}

.cookie-btn-secondary {
    background: #404040;
    color: #e5e5e5;
}

.cookie-btn-secondary:hover {
    background: #525252;
}

.cookie-btn-outline {
    background: transparent;
    color: #a3a3a3;
    border: 1px solid #404040;
    padding: 10px 14px;
}

.cookie-btn-outline:hover {
    background: #262626;
    color: #ffffff;
    border-color: #525252;
}

/* Cookie Customize Panel */
.cookie-consent-customize {
    border-top: 1px solid #333;
    padding: 16px 20px;
    background: #1a1a1a;
    border-radius: 0 0 16px 16px;
}

.cookie-option {
    padding: 10px 0;
    border-bottom: 1px solid #333;
}

.cookie-option:last-of-type {
    border-bottom: none;
}

.cookie-option label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 0.8rem;
    color: #e5e5e5;
    color: var(--gray-700, #404040);
    line-height: 1.5;
}

.cookie-option label strong {
    color: var(--gray-900, #171717);
}

.cookie-option input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--primary, #E86A33);
    cursor: pointer;
    flex-shrink: 0;
}

.cookie-option input[type="checkbox"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.cookie-customize-actions {
    padding-top: 16px;
    display: flex;
    justify-content: flex-end;
}


/* ============================================
   PWA INSTALL PROMPT
   ============================================ */

#pwa-install-prompt {
    position: fixed;
    bottom: 24px;
    left: 24px;
    right: 24px;
    max-width: 400px;
    background: var(--white, #ffffff);
    border-radius: 20px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
    z-index: 9998;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@media (min-width: 500px) {
    #pwa-install-prompt {
        left: auto;
        right: 24px;
        bottom: 24px;
    }
}

#pwa-install-prompt.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.pwa-prompt-content {
    padding: 24px;
    position: relative;
}

.pwa-prompt-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: var(--gray-100, #f5f5f5);
    border: none;
    border-radius: 50%;
    font-size: 1.25rem;
    color: var(--gray-500, #737373);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.pwa-prompt-close:hover {
    background: var(--gray-200, #e5e5e5);
    color: var(--gray-700, #404040);
}

.pwa-prompt-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    border-radius: 16px;
    overflow: hidden;
    background: var(--primary-lighter, #fff5f0);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pwa-prompt-icon img {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.pwa-prompt-text {
    text-align: center;
    margin-bottom: 20px;
}

.pwa-prompt-text h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-900, #171717);
    margin: 0 0 8px 0;
}

.pwa-prompt-text p {
    font-size: 0.9rem;
    color: var(--gray-600, #525252);
    margin: 0;
    line-height: 1.5;
}

.pwa-prompt-actions {
    display: flex;
    gap: 12px;
}

.pwa-btn {
    flex: 1;
    padding: 12px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.pwa-btn-primary {
    background: var(--primary, #E86A33);
    color: white;
}

.pwa-btn-primary:hover {
    background: var(--primary-dark, #d35a24);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(232, 106, 51, 0.3);
}

.pwa-btn-secondary {
    background: var(--gray-100, #f5f5f5);
    color: var(--gray-700, #404040);
}

.pwa-btn-secondary:hover {
    background: var(--gray-200, #e5e5e5);
}


/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */

@media (max-width: 500px) {
    .cookie-consent-actions {
        flex-direction: column;
    }
    
    .cookie-btn {
        width: 100%;
        text-align: center;
    }
    
    #pwa-install-prompt {
        bottom: 16px;
        left: 16px;
        right: 16px;
    }
    
    .pwa-prompt-content {
        padding: 20px;
    }
}


/* ============================================
   PRINT: HIDE ALL OVERLAYS
   ============================================ */

@media print {
    #cookie-consent-banner,
    #pwa-install-prompt {
        display: none !important;
    }
}


/* ============================================
   REDUCED MOTION
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    #cookie-consent-banner,
    #pwa-install-prompt {
        transition: none;
    }
    
    #cookie-consent-banner.visible,
    #pwa-install-prompt.visible {
        transition: none;
    }
}
