/* Sample Reports Section Styles - Horizontal Layout */

#sample-reports {
    text-align: center;
    width: 100%;
    margin: auto;
    padding: 60px 0;
    position: relative;
    overflow: visible;  /* Changed to visible to allow tooltips */
    z-index: 500;  /* Higher than surrounding sections */
}

#sample-reports::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    animation: float 15s ease-in-out infinite;
}

#sample-reports h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #ff7b00;
    position: relative;
    z-index: 2;
}

#sample-reports h2 .smaller-text {
    font-size: 1.2rem;
    color: #666;
    font-weight: normal;
}

#sample-reports p {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 1.6;
    position: relative;
    z-index: 2;
}


/* Loading Styles */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #ff7b00;
}

.loading i {
    font-size: 2rem;
    margin-bottom: 10px;
    animation: spin 1s linear infinite;
}

/* Reports Container - Horizontal Scroll */
.reports-container {
    width: 100%;
    position: relative;
    z-index: 100;  /* Increased z-index */
    display: flex;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    transition: all 0.3s ease;
    overflow: visible;  /* Allow tooltips to show above */
}

/* Removed container hover effects that can interfere with scrolling */

/* Scroll Navigation Buttons */
.scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: white;
    border: 2px solid #ff7b00;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    color: #ff7b00;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 123, 0, 0.2);
    z-index: 10;
    opacity: 0.8;
}

.scroll-btn:hover {
    background: #ff7b00;
    color: white;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 20px rgba(255, 123, 0, 0.3);
    opacity: 1;
}

.scroll-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.scroll-btn-left {
    left: -25px;
}

.scroll-btn-right {
    right: -25px;
}

.scroll-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: translateY(-50%) scale(0.9);
}

.scroll-btn:disabled:hover {
    background: white;
    color: #ff7b00;
    transform: translateY(-50%) scale(0.9);
    box-shadow: 0 4px 15px rgba(255, 123, 0, 0.2);
}

.reports-scroll {
    display: flex;
    overflow-x: auto;
    overflow-y: visible;  /* Allow tooltips to show above */
    white-space: nowrap;
    padding: 80px 10px 20px 10px;  /* Extra top padding for tooltip space */
    scroll-behavior: smooth;
    gap: 20px;
    -webkit-overflow-scrolling: touch;
    /* Hide scrollbar */
    scrollbar-width: none;
    -ms-overflow-style: none;
    /* Performance optimization */
    will-change: scroll-position;
    transform: translateZ(0);
}

.reports-scroll::-webkit-scrollbar {
    display: none;
}

/* Visual feedback for pause state */
.reports-container.paused .reports-scroll {
    box-shadow: 0 4px 20px rgba(255, 123, 0, 0.1);
}

/* Report Card Styles */
.report-card {
    display: inline-block;
    background: white;
    border: 2px solid #ddd;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    padding: 20px;
    text-align: center;
    min-width: 200px;
    max-width: 240px;
    width: 220px; /* Fixed width for consistent calculations */
    white-space: normal;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: visible;  /* Changed to visible to allow tooltip to show */
    flex-shrink: 0;
    /* Ensure consistent spacing */
    margin: 0;
}

.report-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #ff7b00, #ff9500);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.report-card:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 20px 40px rgba(255, 123, 0, 0.3);
    border-color: #ff7b00;
    z-index: 1000; /* Much higher z-index for hover state */
}

.report-card:hover::before {
    transform: scaleX(1);
}

/* Global Tooltip Styles - Outside overflow containers */
.global-report-tooltip {
    position: fixed !important;
    background: rgba(0, 0, 0, 0.95);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
    min-width: 280px;
    max-width: 350px;
    z-index: 100000 !important;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    font-size: 0.9rem;
    line-height: 1.5;
    white-space: normal;
}

.global-report-tooltip.active {
    opacity: 1;
}

.global-report-tooltip strong {
    display: block;
    margin-bottom: 8px;
    color: #ff9500;
    font-size: 1.1rem;
}

.global-report-tooltip p {
    margin: 0;
    color: #fff;
    text-align: left;
    font-size: 0.9rem;
}

/* Arrow pointing down */
.global-report-tooltip::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: rgba(0, 0, 0, 0.95);
}

/* Mobile touch feedback */
.report-card.touch-active {
    transform: scale(0.95);
    background: #fff5f0;
    border-color: #ff7b00;
    box-shadow: 0 4px 15px rgba(255, 123, 0, 0.2);
}

.report-card.touch-active::before {
    transform: scaleX(1);
}

.report-icon {
    font-size: 2.2rem;
    margin-bottom: 12px;
    color: #ff7b00;
    animation: pulse 2s ease-in-out infinite;
}

.report-title {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: #333;
    font-weight: 600;
    line-height: 1.3;
}

.report-description {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.4;
    font-size: 0.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.report-stats {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
}

.stat {
    background: #f8f9fa;
    padding: 6px 8px;
    border-radius: 6px;
    text-align: center;
    flex: 1;
}

.stat-number {
    font-size: 0.9rem;
    font-weight: bold;
    color: #ff7b00;
}

.stat-label {
    font-size: 0.65rem;
    color: #666;
    margin-top: 2px;
}

.report-status {
    display: inline-block;
    padding: 4px 10px;
    background: #e8f5e8;
    color: #2e7d32;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-top: 8px;
}

/* Modal Styles */
.report-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background-color: #fefefe;
    margin: 2% auto;
    padding: 0;
    border: none;
    width: 95%;
    max-width: 1400px;
    max-height: 90vh;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: slideIn 0.3s ease-out;
}

.modal-header {
    background: #ffffff;
    color: #1a1a1a;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #f0f0f0;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 700;
    color: #ff7b00;
}

.close-modal {
    color: #666;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-modal:hover {
    color: #ff7b00;
    transform: scale(1.2);
}

.modal-body {
    padding: 0;
    max-height: calc(90vh - 100px);
    overflow-y: auto;
}

/* New JSON-based modal content styles */
.modal-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #ff7b00;
    font-size: 1.1rem;
}

.modal-loading i {
    font-size: 2rem;
    margin-bottom: 15px;
}

.report-content {
    padding: 0;
}

.report-header {
    background: #f8f9fa;
    padding: 25px 30px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.report-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.report-type {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ff7b00;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.report-date {
    font-size: 0.9rem;
    color: #666;
}

.report-sections-count {
    background: #ff7b00;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.report-sections {
    padding: 0;
}

.report-section {
    padding: 30px;
    border-bottom: 1px solid #f0f0f0;
}

.report-section:last-child {
    border-bottom: none;
}

.section-title {
    color: #ff7b00;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #ff7b00;
    display: inline-block;
}

.section-content {
    color: #333;
    line-height: 1.8;
    font-size: 1rem;
}

.section-content p {
    margin: 0 0 15px 0;
}

.section-content h2 {
    color: #ff7b00;
    font-size: 1.4rem;
    margin: 25px 0 15px 0;
    font-weight: 600;
}

.section-content h3 {
    color: #333;
    font-size: 1.2rem;
    margin: 20px 0 12px 0;
    font-weight: 600;
}

.section-content strong {
    color: #ff7b00;
    font-weight: 600;
}

.section-content em {
    color: #666;
    font-style: italic;
}

.report-footer {
    background: #f8f9fa;
    padding: 25px 30px;
    border-top: 1px solid #e0e0e0;
}

.report-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.btn-primary, .btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.btn-primary:hover {
    background: #ff9500;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 123, 0, 0.3);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 117, 125, 0.3);
}

/* Iframe container for full reports */
.iframe-container {
    height: 80vh;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.iframe-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 8px;
    background: white;
}

/* Animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(2deg); }
}

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to { 
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    #sample-reports {
        padding: 40px 0;
    }

    #sample-reports h2 {
        font-size: 2rem;
    }

    .reports-container {
        padding: 0 10px;
    }

    .reports-scroll {
        padding: 20px 5px;
        gap: 20px; /* Increased gap for easier touch interaction */
    }

    .report-card {
        min-width: 200px; /* Increased minimum width */
        max-width: 220px; /* Increased maximum width */
        width: 210px; /* Increased fixed width */
        padding: 20px; /* Increased padding */
        margin: 0 5px; /* Added margin for better spacing */
    }


    /* Disable hover effects on mobile */
    .report-card:hover {
        transform: none;
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
        border-color: #ddd;
    }
    
    .report-card:hover::before {
        transform: scaleX(0);
    }
    
    /* Enhanced touch feedback for mobile */
    .report-card.touch-active {
        transform: scale(0.95);
        background: #fff5f0;
        border-color: #ff7b00;
        box-shadow: 0 4px 15px rgba(255, 123, 0, 0.2);
    }
    
    .report-card.touch-active::before {
        transform: scaleX(1);
    }
    
    .report-icon {
        font-size: 2rem;
    }
    
    .report-title {
        font-size: 1rem;
        margin-bottom: 12px; /* Increased margin */
    }
    
    .report-description {
        font-size: 0.85rem; /* Slightly larger text */
        line-height: 1.4;
        margin-bottom: 15px;
    }
    
    .report-stats {
        gap: 4px;
    }
    
    .stat {
        padding: 4px 6px;
    }
    
    .stat-number {
        font-size: 0.9rem; /* Slightly larger numbers */
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .report-status {
        font-size: 0.85rem;
        padding: 8px 12px; /* Increased padding for better touch target */
    }
    
    /* Hide scroll buttons on mobile - touch scrolling is natural */
    .scroll-btn {
        display: none;
    }
    
    /* Disable problematic animations on mobile */
    .report-icon {
        animation: none;
    }
    
    .reports-container:hover {
        transform: none;
    }
    
    .reports-container:hover .reports-scroll {
        box-shadow: none;
    }
    
    .modal-content {
        width: 98%;
        height: 95vh;
        margin: 1% auto;
    }
    
    .modal-header {
        padding: 15px 20px;
    }
    
    .modal-header h3 {
        font-size: 1.2rem;
    }
    
    .modal-body {
        max-height: calc(90vh - 80px);
    }
    
    .report-header {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .report-section {
        padding: 20px;
    }
    
    .section-title {
        font-size: 1.1rem;
    }
    
    .section-content {
        font-size: 0.9rem;
    }
    
    .report-footer {
        padding: 20px;
    }
    
    .report-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-primary, .btn-secondary {
        padding: 10px 20px;
        font-size: 0.9rem;
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .report-card {
        min-width: 180px; /* Slightly reduced for very small screens */
        max-width: 200px;
        width: 190px;
        padding: 15px;
    }
    
    .report-icon {
        font-size: 1.8rem;
    }
    
    .report-title {
        font-size: 0.95rem;
    }
    
    .report-description {
        font-size: 0.8rem;
    }
    
    .stat-number {
        font-size: 0.85rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }
} 