/*
Theme Name: Kolkata FF
Theme URI: https://kolkataff.com
Author: Kolkata FF Team
Author URI: https://kolkataff.com
Description: Kolkata Fatafat Results Website with Live Updates and Tools
Version: 1.0.0
License: GPL v2 or later
Text Domain: kolkata-ff
*/

/* Previous CSS remains exactly the same, no changes needed */
/* Base & Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    background: #f8fafc;
    color: #1e293b;
    line-height: 1.5;
}

.ff-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px;
}

/* Top Header - New Design */
.ff-top-header {
    background: linear-gradient(135deg, #dc2626 0%, #7f1d1d 100%);
    padding: 15px 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    box-shadow: 0 4px 20px rgba(220, 38, 38, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.ff-live-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 12px;
    border-radius: 20px;
    color: white;
    font-weight: 600;
    font-size: 14px;
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.live-pulse {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(34, 197, 94, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

.ff-main-title {
    color: white;
    font-size: 22px;
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-weight: 700;
}

.inline-time {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.1);
    padding: 5px 12px;
    border-radius: 20px;
    color: white;
    font-size: 14px;
    font-weight: 500;
}

.inline-time i {
    font-size: 12px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.next-result-inline {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(0, 0, 0, 0.2);
    padding: 6px 12px;
    border-radius: 20px;
    color: white;
    font-size: 14px;
}

.next-label {
    opacity: 0.9;
    font-size: 12px;
}

.timer-inline {
    color: #fbbf24;
    font-weight: 700;
    font-family: 'Courier New', monospace;
    min-width: 70px;
    text-align: center;
}

.telegram-box-small {
    display: flex;
}

.telegram-btn-small {
    background: #0088cc;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.3s;
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 2px 8px rgba(0, 136, 204, 0.2);
}

.telegram-btn-small:hover {
    background: #0077b5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 136, 204, 0.3);
}

.telegram-text {
    font-size: 13px;
}

/* Date Section */
.ff-date-section {
    margin-bottom: 20px;
}

.date-card {
    background: white;
    padding: 15px 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-left: 4px solid #dc2626;
}

.date-card i {
    color: #dc2626;
    font-size: 24px;
}

.date-content {
    flex: 1;
}

.date-label {
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 3px;
}

.date-value {
    color: #1e293b;
    font-size: 18px;
    font-weight: 600;
}

/* Section Headers */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.section-title {
    color: #1e293b;
    font-size: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.result-count {
    background: #e0f2fe;
    color: #0369a1;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 13px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
}

.yesterday-date {
    color: #64748b;
    font-size: 14px;
    background: #f1f5f9;
    padding: 5px 12px;
    border-radius: 15px;
}

/* Results Sections */
.ff-results-section,
.ff-yesterday-section {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.loading-results {
    text-align: center;
    padding: 30px;
    color: #64748b;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

/* Stats Section */
.ff-stats-section {
    margin-bottom: 25px;
}

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

.stat-card {
    background: white;
    padding: 15px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.stat-icon {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, #dc2626 0%, #f87171 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.stat-card:nth-child(2) .stat-icon {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
}

.stat-card:nth-child(3) .stat-icon {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
}

.stat-card:nth-child(4) .stat-icon {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
}

.stat-content {
    flex: 1;
}

.stat-value {
    color: #1e293b;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 2px;
}

.stat-label {
    color: #64748b;
    font-size: 13px;
}

/* SEO Content */
.ff-seo-content {
    background: white;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.seo-header h1 {
    color: #1e293b;
    font-size: 26px;
    margin-bottom: 15px;
    line-height: 1.3;
}

.seo-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e2e8f0;
    flex-wrap: wrap;
}

.seo-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #64748b;
    font-size: 14px;
}

.seo-intro h2 {
    color: #dc2626;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.seo-intro p {
    color: #334155;
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 25px;
}

/* Features Grid */
.seo-features {
    margin: 30px 0;
}

.seo-features h3 {
    color: #1e293b;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.feature {
    background: #f8fafc;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    border: 2px solid transparent;
    transition: all 0.3s;
}

.feature:hover {
    border-color: #dc2626;
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(220, 38, 38, 0.1);
}

.feature i {
    font-size: 35px;
    color: #dc2626;
    margin-bottom: 15px;
}

.feature h4 {
    color: #1e293b;
    margin-bottom: 10px;
    font-size: 18px;
}

.feature p {
    color: #64748b;
    font-size: 14px;
    line-height: 1.5;
}

/* Detail Cards */
.seo-details {
    margin: 35px 0;
}

.detail-card {
    background: #f8fafc;
    padding: 18px;
    border-radius: 10px;
    margin-bottom: 15px;
    border-left: 4px solid #3b82f6;
    transition: transform 0.3s;
}

.detail-card:hover {
    transform: translateX(5px);
}

.detail-card.warning {
    border-left-color: #dc2626;
    background: #fef2f2;
}

.detail-card h4 {
    color: #1e293b;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
}

.detail-card p,
.detail-card ol,
.detail-card ul {
    color: #334155;
    line-height: 1.7;
    font-size: 15px;
}

.detail-card ol,
.detail-card ul {
    padding-left: 20px;
    margin: 12px 0;
}

.detail-card li {
    margin-bottom: 8px;
}

/* CTA Section */
.seo-cta {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    padding: 25px;
    border-radius: 12px;
    color: white;
    text-align: center;
    margin-top: 35px;
}

.seo-cta h3 {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 20px;
}

.seo-cta p {
    margin-bottom: 20px;
    font-size: 15px;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary,
.btn-secondary {
    padding: 10px 22px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-size: 15px;
}

.btn-primary {
    background: white;
    color: #4f46e5;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Quick Tools */
.ff-tools-compact {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.tools-quick {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.quick-tool {
    background: #f8fafc;
    padding: 15px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 2px solid #e2e8f0;
}

.quick-tool i {
    color: #dc2626;
    font-size: 20px;
    min-width: 24px;
}

.quick-tool span {
    font-weight: 600;
    color: #1e293b;
    min-width: 80px;
    font-size: 14px;
}

.quick-tool input,
.quick-tool select {
    flex: 1;
    padding: 8px 12px;
    border: 2px solid #cbd5e1;
    border-radius: 6px;
    font-size: 14px;
    background: white;
    color: #1e293b;
}

.quick-tool input:focus,
.quick-tool select:focus {
    outline: none;
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.quick-tool button {
    padding: 8px 18px;
    background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
    white-space: nowrap;
}

.quick-tool button:hover {
    background: linear-gradient(135deg, #b91c1c 0%, #dc2626 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

/* Results Table */
#ff-live-box table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    border-radius: 10px;
    overflow: hidden;
}

#ff-live-box th {
    background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
    color: white;
    padding: 14px 10px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
}

#ff-live-box td {
    padding: 12px 10px;
    text-align: center;
    border-bottom: 1px solid #f1f5f9;
    font-weight: 500;
    color: #334155;
}

#ff-live-box tr:hover {
    background: #f8fafc;
}

#ff-live-box td:last-child {
    font-weight: 700;
    color: #dc2626;
    font-size: 18px;
}

.ff-error {
    text-align: center;
    padding: 30px;
    color: #dc2626;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 16px;
}

/* ================= RESPONSIVE DESIGN ================= */
@media (max-width: 768px) {
    .ff-wrap {
        padding: 10px;
    }
    
    .ff-top-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 15px;
    }
    
    .header-left,
    .header-right {
        width: 100%;
        justify-content: space-between;
    }
    
    .ff-main-title {
        font-size: 20px;
    }
    
    .seo-header h1 {
        font-size: 22px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .result-count,
    .yesterday-date {
        align-self: flex-start;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .seo-meta {
        flex-direction: column;
        gap: 8px;
    }
    
    .cta-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .tools-quick {
        grid-template-columns: 1fr;
    }
    
    .quick-tool {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .quick-tool span {
        text-align: center;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .ff-main-title {
        font-size: 18px;
    }
    
    .inline-time,
    .next-result-inline,
    .telegram-btn-small {
        font-size: 12px;
    }
    
    .timer-inline {
        min-width: 60px;
    }
    
    .date-value {
        font-size: 16px;
    }
    
    .section-title {
        font-size: 18px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 12px;
    }
    
    #ff-live-box th,
    #ff-live-box td {
        padding: 10px 5px;
        font-size: 12px;
    }
    
    .seo-intro p {
        font-size: 14px;
    }
    
    .feature {
        padding: 15px;
    }
    
    .detail-card {
        padding: 15px;
    }
    
    .seo-cta {
        padding: 20px;
    }
    
    .ff-results-section,
    .ff-yesterday-section,
    .ff-seo-content {
        padding: 15px;
    }
}

/* Animation for results update */
@keyframes highlight {
    0% { background-color: #fef3c7; }
    100% { background-color: transparent; }
}

.result-updated {
    animation: highlight 2s ease-out;
}

/* Print Styles */
@media print {
    .ff-top-header,
    .telegram-btn-small,
    .ff-tools-compact,
    .seo-cta .cta-buttons,
    .btn-secondary {
        display: none;
    }
    
    .ff-wrap {
        padding: 0;
        max-width: 100%;
    }
    
    body {
        background: white;
        font-size: 12px;
    }
    
    .date-card,
    .ff-results-section,
    .ff-yesterday-section,
    .ff-seo-content {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    body {
        background: #0f172a;
        color: #e2e8f0;
    }
    
    .date-card,
    .ff-results-section,
    .ff-yesterday-section,
    .ff-seo-content,
    .ff-tools-compact,
    .stat-card,
    .feature,
    .detail-card {
        background: #1e293b;
        color: #e2e8f0;
    }
    
    .date-value,
    .section-title,
    .feature h4,
    .detail-card h4,
    .stat-value {
        color: #e2e8f0;
    }
    
    .date-label,
    .result-count,
    .yesterday-date,
    .stat-label,
    .feature p,
    .detail-card p {
        color: #94a3b8;
    }
    
    #ff-live-box th {
        background: linear-gradient(135deg, #991b1b 0%, #dc2626 100%);
    }
    
    #ff-live-box tr:hover {
        background: #334155;
    }
}