/**
 * TrendNowFB - Complete Styling
 * Minimal, modern design with animations
 */

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    text-align: center;
    padding: 40px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
    margin-bottom: 40px;
}

.header h1 {
    font-size: 3rem;
    margin-bottom: 10px;
}

.tagline {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.article-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.article-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.article-image {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: #e0e0e0;
}

.article-content {
    padding: 20px;
}

.article-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #333;
}

.article-description {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.5;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #999;
}

.article-date {
    color: #999;
}

.article-read-more {
    color: #667eea;
    font-weight: 600;
}

/* Ad Gate Overlay */
.ad-gate {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.ad-gate.active {
    opacity: 1;
    pointer-events: all;
}

.ad-gate-content {
    max-width: 900px;
    width: 90%;
    text-align: center;
    color: white;
}

.ad-gate-content h2 {
    font-size: 1.8rem;
    margin-bottom: 30px;
}

/* Ad Container */
.ad-container {
    width: 100%;
    max-width: 800px;
    margin: 0 auto 30px;
    background: #222;
    border-radius: 10px;
    overflow: hidden;
}

.ad-container iframe {
    width: 100%;
    height: 450px;
    border: none;
    display: block;
}

/* Popup Message */
.popup-message {
    background: #ffc107;
    color: #000;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
}

.popup-instruction {
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Focus Warning */
.focus-warning {
    background: #ff5252;
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 20px;
    display: inline-block;
    animation: pulse-warning 1s infinite;
}

@keyframes pulse-warning {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Countdown Display */
.countdown-display {
    margin: 30px 0;
}

.countdown-circle {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

#countdownNumber {
    font-size: 4rem;
    font-weight: bold;
    color: white;
}

#countdownNumber.pulse {
    animation: pulse-number 0.3s ease;
}

@keyframes pulse-number {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.countdown-text {
    font-size: 1.3rem;
    color: white;
    margin-bottom: 5px;
}

.countdown-subtext {
    font-size: 1rem;
    color: #aaa;
}

/* Continue Button */
.continue-btn {
    background: #666;
    color: white;
    padding: 18px 50px;
    font-size: 1.2rem;
    border: none;
    border-radius: 50px;
    cursor: not-allowed;
    transition: all 0.3s ease;
    font-weight: 600;
    margin-top: 20px;
}

.continue-btn.enabled {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    cursor: pointer;
    animation: button-glow 1.5s infinite;
}

.continue-btn.enabled:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

@keyframes button-glow {
    0%, 100% { box-shadow: 0 5px 20px rgba(102, 126, 234, 0.3); }
    50% { box-shadow: 0 5px 40px rgba(102, 126, 234, 0.6); }
}

/* Article Content Wrapper */
.article-content-wrapper {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.article-content-wrapper.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Article Header */
.article-header {
    background: white;
    padding: 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.back-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 20px;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #764ba2;
}

#articleTitle {
    font-size: 2.5rem;
    line-height: 1.3;
    margin-bottom: 15px;
    color: #333;
}

.article-meta-info {
    color: #999;
    font-size: 1rem;
}

/* Article Hero Image */
.article-image-hero {
    width: 100%;
    height: 400px;
    background-size: cover;
    background-position: center;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

/* Article Body */
.article-body {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}

.article-body h2 {
    font-size: 2rem;
    margin: 30px 0 15px;
    color: #333;
}

.article-body h3 {
    font-size: 1.5rem;
    margin: 25px 0 12px;
    color: #444;
}

.article-body p {
    margin-bottom: 20px;
}

.article-body ul, .article-body ol {
    margin-bottom: 20px;
    padding-left: 30px;
}

.article-body li {
    margin-bottom: 10px;
}

.article-body a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px solid #667eea;
}

.article-body a:hover {
    color: #764ba2;
    border-bottom-color: #764ba2;
}

/* Article Footer */
.article-footer {
    margin-top: 40px;
    padding: 20px;
    text-align: center;
}

/* Footer */
.footer {
    text-align: center;
    padding: 40px 0;
    color: #999;
    border-top: 1px solid #e0e0e0;
    margin-top: 60px;
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.error-message {
    background: white;
    padding: 40px;
    border-radius: 10px;
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
}

.error-message h2 {
    color: #ff5252;
    margin-bottom: 20px;
}

.error-message p {
    color: #666;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

/* Adblocker Detection Element (hidden) */
.ad-test-element {
    position: absolute;
    top: -1px;
    left: -1px;
    width: 1px;
    height: 1px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header h1 {
        font-size: 2rem;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
    
    #articleTitle {
        font-size: 2rem;
    }
    
    .article-body {
        padding: 25px;
        font-size: 1rem;
    }
    
    .countdown-circle {
        width: 120px;
        height: 120px;
    }
    
    #countdownNumber {
        font-size: 3rem;
    }
    
    .continue-btn {
        padding: 15px 40px;
        font-size: 1rem;
    }
}