/* /css/text-campaign.css
   Professional text campaign display styles for car detail pages */

.text-campaign-container {
    margin: 20px 0;
    padding: 0;
    display: none; /* Hidden by default, shown by JS when campaign available */
}

.text-campaign-wrapper {
    background: #152fa3; /* Dark blue background */
    border: 1px solid #0d1f75;
    border-left: 4px solid #99d8ff; /* Light blue accent */
    border-radius: 8px;
    padding: 16px 20px;
    margin: 16px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.text-campaign-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #99d8ff 0%, #ffffff 100%);
}

.text-campaign-wrapper:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-left-color: #ffffff;
}

.text-campaign-content {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.5;
}

.publicity-indicator {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-weight: 700;
    font-size: 16px; /* Reduced from 50px but still visible */
    padding: 6px 10px; /* Increased padding for better visibility */
    border-radius: 4px;
    min-width: 32px;
    text-align: center;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3); /* Enhanced shadow */
    border: 1px solid rgba(255, 255, 255, 0.3); /* Added border for contrast */
}

.campaign-message {
    color: #ffffff;
    font-size: 16px; /* Reduced from 20px */
    font-weight: 500;
    margin: 0;
    flex-shrink: 0;
}

.campaign-link {
    color: #152fa3;
    text-decoration: none;
    font-weight: 600;
    font-size: 16px; /* Reduced from 25px */
    padding: 8px 16px; /* Adjusted padding */
    border-radius: 6px;
    background: #99d8ff;
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.25s ease;
    position: relative;
    flex-shrink: 0;
}

.campaign-link:hover {
    color: #0d1f75;
    background: #ffffff; /* White background on hover */
    border-color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.campaign-link:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(21, 47, 163, 0.2);
}

.campaign-link::after {
    content: '↗';
    margin-left: 6px;
    font-size: 12px;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.campaign-link:hover::after {
    opacity: 1;
}

/* Responsive design */
@media (max-width: 768px) {
    .text-campaign-wrapper {
        margin: 12px 0;
        padding: 12px 16px;
    }
    
    .text-campaign-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        text-align: left;
    }
    
    .campaign-message {
        font-size: 14px;
    }
    
    .campaign-link {
        font-size: 14px;
        padding: 8px 12px;
        align-self: flex-start;
    }
    
    .publicity-indicator {
        font-size: 14px; /* Smaller on mobile but still visible */
        padding: 5px 8px;
    }
}

@media (max-width: 480px) {
    .text-campaign-wrapper {
        margin: 8px 0;
        padding: 10px 12px;
    }
    
    .text-campaign-content {
        gap: 6px;
    }
    
    .campaign-message {
        font-size: 13px;
    }
    
    .campaign-link {
        font-size: 13px;
        padding: 6px 10px;
    }
    
    .publicity-indicator {
        font-size: 12px;
        padding: 4px 6px;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .text-campaign-wrapper {
        border: 2px solid #000;
        background: #fff;
    }
    
    .publicity-indicator {
        background: #000;
        color: #fff;
    }
    
    .campaign-link {
        background: #fff;
        border: 2px solid #152fa3;
        color: #152fa3;
    }
    
    .campaign-link:hover {
        background: #152fa3;
        color: #fff;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .text-campaign-wrapper,
    .campaign-link {
        transition: none;
    }
    
    .text-campaign-wrapper:hover {
        transform: none;
    }
    
    .campaign-link:hover {
        transform: none;
    }
}

/* Focus styles for accessibility */
.campaign-link:focus {
    outline: 2px solid #152fa3;
    outline-offset: 2px;
}