/**
 * Advanced Features Styles
 * Save The Planet Token - Market Leading Features
 */

/* ============================================
   LIVE PRICE WIDGET
   ============================================ */

.live-price-widget {
    background: linear-gradient(135deg, rgba(244, 208, 63, 0.1) 0%, rgba(230, 184, 0, 0.1) 100%);
    border: 2px solid #f4d03f;
    border-radius: 20px;
    padding: 30px;
    margin: 40px 0;
    position: relative;
    overflow: hidden;
}

.live-price-widget::before {
    content: '💰';
    position: absolute;
    top: -20px;
    right: -20px;
    font-size: 120px;
    opacity: 0.1;
}

.price-widget-header {
    text-align: center;
    margin-bottom: 30px;
}

.price-widget-header h3 {
    color: #f4d03f;
    font-size: 24px;
    margin-bottom: 5px;
}

.price-widget-header .live-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(46, 204, 113, 0.2);
    border: 1px solid #2ecc71;
    color: #2ecc71;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.live-badge::before {
    content: '●';
    animation: blink 2s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.price-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.price-stat-card {
    background: rgba(10, 31, 31, 0.6);
    border: 1px solid rgba(244, 208, 63, 0.3);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.price-stat-card:hover {
    transform: translateY(-5px);
    border-color: #f4d03f;
    box-shadow: 0 8px 25px rgba(244, 208, 63, 0.2);
}

.price-stat-label {
    color: #b8c5c5;
    font-size: 14px;
    margin-bottom: 10px;
}

.price-stat-value {
    color: #f4d03f;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
}

.price-change {
    font-size: 16px;
    font-weight: 600;
}

.price-change.positive {
    color: #2ecc71;
}

.price-change.negative {
    color: #e74c3c;
}

.price-change.positive::before {
    content: '▲ ';
}

.price-change.negative::before {
    content: '▼ ';
}

/* ============================================
   IMPACT COUNTER SECTION
   ============================================ */

.impact-counter-section {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.1) 0%, rgba(39, 174, 96, 0.1) 100%);
    border: 2px solid #2ecc71;
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
    position: relative;
}

.impact-counter-section::before {
    content: '🌍';
    position: absolute;
    top: -30px;
    left: -30px;
    font-size: 150px;
    opacity: 0.05;
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.impact-card {
    background: rgba(10, 31, 31, 0.7);
    border: 2px solid rgba(46, 204, 113, 0.3);
    border-radius: 15px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.impact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #2ecc71, #27ae60);
}

.impact-card:hover {
    transform: scale(1.05);
    border-color: #2ecc71;
    box-shadow: 0 10px 30px rgba(46, 204, 113, 0.3);
}

.impact-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.impact-number {
    color: #2ecc71;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 10px;
    font-family: 'Courier New', monospace;
}

.impact-label {
    color: #b8c5c5;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.impact-progress {
    margin-top: 30px;
    padding: 20px;
    background: rgba(10, 31, 31, 0.6);
    border-radius: 15px;
}

.progress-label {
    color: #f4d03f;
    font-size: 18px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.progress-bar-container {
    width: 100%;
    height: 30px;
    background: rgba(10, 31, 31, 0.8);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #2ecc71, #27ae60);
    border-radius: 15px;
    transition: width 2s ease;
    position: relative;
}

.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* ============================================
   VISITOR ANALYTICS
   ============================================ */

.visitor-analytics-section {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
    border: 2px solid #3498db;
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
}

.visitor-country-badge {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: rgba(10, 31, 31, 0.95);
    backdrop-filter: blur(10px);
    border: 2px solid #3498db;
    border-radius: 50px;
    padding: 12px 20px;
    display: none;
    align-items: center;
    gap: 10px;
    z-index: 9999;
    box-shadow: 0 4px 20px rgba(52, 152, 219, 0.3);
    animation: slideInLeft 0.5s ease;
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.country-flag {
    font-size: 24px;
}

.country-name {
    color: #3498db;
    font-weight: 600;
}

.top-countries-grid {
    display: grid;
    gap: 15px;
    margin-top: 30px;
}

.country-stat-item {
    background: rgba(10, 31, 31, 0.6);
    border: 1px solid rgba(52, 152, 219, 0.3);
    border-radius: 15px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
}

.country-stat-item:hover {
    transform: translateX(10px);
    border-color: #3498db;
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.2);
}

.country-rank {
    font-size: 24px;
    font-weight: 700;
    color: #3498db;
    min-width: 50px;
    text-align: center;
}

.country-flag-large {
    font-size: 32px;
}

.country-info {
    flex: 1;
}

.country-name-large {
    color: #f4d03f;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
}

.country-visits {
    color: #b8c5c5;
    font-size: 14px;
}

.country-bar {
    width: 200px;
    height: 8px;
    background: rgba(52, 152, 219, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.country-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db, #2980b9);
    border-radius: 4px;
    transition: width 1s ease;
}

/* ============================================
   TRANSPARENCY DASHBOARD
   ============================================ */

.transparency-dashboard {
    background: linear-gradient(135deg, rgba(155, 89, 182, 0.1) 0%, rgba(142, 68, 173, 0.1) 100%);
    border: 2px solid #9b59b6;
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
}

.wallet-balance-card {
    background: rgba(10, 31, 31, 0.8);
    border: 2px solid #9b59b6;
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    margin-bottom: 30px;
}

.wallet-balance-label {
    color: #b8c5c5;
    font-size: 16px;
    margin-bottom: 15px;
}

.wallet-balance-amount {
    color: #9b59b6;
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 10px;
}

.wallet-balance-usd {
    color: #b8c5c5;
    font-size: 20px;
}

.recent-transactions {
    margin-top: 30px;
}

.recent-transactions h4 {
    color: #9b59b6;
    font-size: 20px;
    margin-bottom: 20px;
}

.transaction-item {
    background: rgba(10, 31, 31, 0.6);
    border: 1px solid rgba(155, 89, 182, 0.3);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.transaction-item:hover {
    transform: translateX(5px);
    border-color: #9b59b6;
}

.tx-icon {
    color: #2ecc71;
    font-size: 24px;
}

.tx-details {
    flex: 1;
}

.tx-amount {
    color: #f4d03f;
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
}

.tx-project {
    color: #b8c5c5;
    font-size: 14px;
}

.tx-date {
    color: #95a5a6;
    font-size: 12px;
}

/* ============================================
   WORLD PROJECTS MAP
   ============================================ */

.world-map-section {
    background: linear-gradient(135deg, rgba(10, 31, 31, 0.95) 0%, rgba(15, 40, 40, 0.95) 100%);
    border: 2px solid #f4d03f;
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
}

#projectsMap {
    width: 100%;
    height: 600px;
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid rgba(244, 208, 63, 0.3);
}

.map-popup {
    min-width: 250px;
}

.popup-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.map-popup h4 {
    color: #f4d03f;
    font-size: 16px;
    margin-bottom: 8px;
}

.popup-country {
    color: #b8c5c5;
    font-size: 14px;
    margin-bottom: 8px;
}

.popup-status {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 10px;
}

.status-completed {
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
    border: 1px solid #2ecc71;
}

.status-in-progress {
    background: rgba(52, 152, 219, 0.2);
    color: #3498db;
    border: 1px solid #3498db;
}

.status-planned {
    background: rgba(241, 196, 15, 0.2);
    color: #f1c40f;
    border: 1px solid #f1c40f;
}

.popup-details {
    margin: 10px 0;
    padding: 10px 0;
    border-top: 1px solid rgba(184, 197, 197, 0.2);
    border-bottom: 1px solid rgba(184, 197, 197, 0.2);
}

.popup-details p {
    color: #b8c5c5;
    font-size: 13px;
    margin: 5px 0;
}

.popup-funding {
    color: #f4d03f;
    font-weight: 600;
    font-size: 14px;
    margin-top: 10px;
}

/* ============================================
   VIDEO TESTIMONIALS SECTION
   ============================================ */

.video-testimonials-section {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1) 0%, rgba(192, 57, 43, 0.1) 100%);
    border: 2px solid #e74c3c;
    border-radius: 20px;
    padding: 40px;
    margin: 40px 0;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.video-card {
    background: rgba(10, 31, 31, 0.7);
    border: 2px solid rgba(231, 76, 60, 0.3);
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.video-card:hover {
    transform: translateY(-10px);
    border-color: #e74c3c;
    box-shadow: 0 10px 30px rgba(231, 76, 60, 0.3);
}

.video-thumbnail {
    width: 100%;
    height: 200px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
    transform: scale(1.1);
}

.video-play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(231, 76, 60, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    transition: all 0.3s ease;
}

.video-card:hover .video-play-button {
    background: #e74c3c;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-info {
    padding: 20px;
}

.video-title {
    color: #f4d03f;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
}

.video-description {
    color: #b8c5c5;
    font-size: 14px;
    line-height: 1.6;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
    .live-price-widget,
    .impact-counter-section,
    .visitor-analytics-section,
    .transparency-dashboard,
    .world-map-section,
    .video-testimonials-section {
        padding: 20px;
        margin: 20px 0;
    }
    
    .price-stats-grid,
    .impact-grid,
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    #projectsMap {
        height: 400px;
    }
    
    .visitor-country-badge {
        bottom: 10px;
        left: 10px;
        padding: 8px 15px;
    }
    
    .country-bar {
        width: 100px;
    }
    
    .country-stat-item {
        flex-wrap: wrap;
    }
    
    .price-stat-value {
        font-size: 24px;
    }
    
    .impact-number {
        font-size: 28px;
    }
    
    .wallet-balance-amount {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    .impact-icon {
        font-size: 36px;
    }
    
    .impact-number {
        font-size: 24px;
    }
    
    .price-stat-value {
        font-size: 20px;
    }
    
    .video-thumbnail {
        height: 150px;
    }
}

/* ============================================
   LOADING STATES
   ============================================ */

.loading-skeleton {
    background: linear-gradient(90deg, rgba(244, 208, 63, 0.1) 0%, rgba(244, 208, 63, 0.2) 50%, rgba(244, 208, 63, 0.1) 100%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.no-data {
    text-align: center;
    color: #95a5a6;
    padding: 40px;
    font-style: italic;
}
