:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --background: #f8fafc;
    --card-background: rgba(255, 255, 255, 0.8);
    --text-primary: #1f2937;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --error-color: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, var(--background), #f1f5f9);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

header {
    text-align: center;
    margin-bottom: 3rem;
}

h1 {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
}

header p {
    color: var(--text-secondary);
}

.card {
    background: var(--card-background);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.upload-container {
    margin-bottom: 0.5rem;
}

.upload-area {
    display: block;
    border: 2px dashed var(--border-color);
    border-radius: 0.75rem;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s;
}

.upload-area:hover {
    border-color: var(--primary-color);
}

.upload-icon {
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
    color: var(--text-secondary);
}

.upload-hint {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

.input-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
    margin-bottom: 2rem;
}

.input-group {
    display: flex;
    flex-direction: column;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

input[type="number"] {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: border-color 0.2s;
}

input[type="number"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.button-container {
    text-align: center;
}

.primary-button {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.primary-button:hover:not(:disabled) {
    background: var(--primary-hover);
}

.primary-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* New styling for buttons-container */
.buttons-container {
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px; /* Space between buttons */
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

#printResultsBtn, #exportResultsBtn {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: background-color 0.2s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

#printResultsBtn:hover, #exportResultsBtn:hover {
    background-color: #e9ecef;
}

#printResultsBtn:disabled, #exportResultsBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.new-tab-indicator {
    font-size: 12px;
    color: #6c757d;
    margin-left: 3px;
}

/* Media query to handle button layout on smaller screens */
@media (max-width: 480px) {
    .buttons-container {
        flex-direction: column;
        align-items: stretch;
    }
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* Result card component - used across main UI, printable report and embed demo */
.result-card {
    background: white;
    padding: 1rem;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.result-card.featured-result {
    background: #f0f9ff;
    border: 2px solid #2563eb;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
    transform: scale(1.02);
    transition: transform 0.2s ease;
}

.result-card.featured-result h3 {
    color: #1e40af;
    font-weight: 600;
}

.result-card.featured-result .result-value {
    font-size: 1.5rem;
    font-weight: 500;
    color: #2563eb;
}

.result-card h3 {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 1.5rem;
    font-weight: 300;
}

.separator {
    margin: 0 0.5rem;
    color: var(--text-secondary);
}

.chart-container {
    flex: 2; /* Takes up 2/3 of the available space */
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 15px;
    height: 350px;
    display: flex;
    flex-direction: column;
}

.hidden {
    display: none;
}

.file-info {
    margin-top: 0.5rem;
    font-size: 0.875rem;
}

.file-info.error {
    color: var(--error-color);
}

/* Animation */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

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

/* Responsive adjustments */
@media (max-width: 640px) {
    .container {
        padding: 1rem;
    }

    h1 {
        font-size: 2rem;
    }

    .card {
        padding: 1rem;
    }

    .results-grid {
        grid-template-columns: 1fr;
    }
}

/* Add these to your existing CSS */
.drag-active {
    border-color: var(--primary-color);
    background-color: rgba(37, 99, 235, 0.05);
}

.error {
    color: var(--error-color);
}

.error-container {
    margin-top: 1rem;
    padding: 0.5rem;
    border-radius: 0.5rem;
    background-color: #fef2f2;
    border: 1px solid #fee2e2;
}

.error-summary {
    color: var(--error-color);
    font-weight: 500;
}

.error-toggle {
    margin-top: 0.5rem;
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    background: none;
    border: 1px solid var(--border-color);
    border-radius: 0.25rem;
    cursor: pointer;
}

.error-toggle:hover {
    background-color: #f9fafb;
}

.error-details {
    margin-top: 0.5rem;
    padding: 0.5rem;
    background-color: white;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    max-height: 200px;
    overflow-y: auto;
}

.error-item {
    padding: 0.25rem 0;
    color: var(--text-secondary);
}

.error-item:not(:last-child) {
    margin-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 8px;
}

.info-container {
    margin-bottom: 2rem;
    padding: 0.5rem;
    border-radius: 0.5rem;
    background-color: #f0f9ff;
    border: 1px solid #e0f2fe;
}

.info-summary {
    color: var(--text-primary);
    font-weight: 500;
}

.info-toggle {
    margin-top: 0.5rem;
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    background: none;
    border: 1px solid var(--border-color);
    border-radius: 0.25rem;
    cursor: pointer;
}

.info-toggle:hover {
    background-color: #f9fafb;
}

.info-details {
    margin-top: 0.5rem;
    padding: 0.5rem;
    background-color: white;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}

.info-item {
    padding: 0.25rem 0;
    color: var(--text-secondary);
}

.info-item:not(:last-child) {
    border-bottom: 1px solid var(--border-color);
}

.warning-message {
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
    padding: 0.75rem;
    margin-bottom: 1rem;
    border-radius: 0.5rem;
    font-weight: 500;
}

.sample-data-container {
    margin-top: 1rem;
    margin-bottom: 1rem;
    text-align: center;
}

.sample-divider {
    color: var(--text-secondary);
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.sample-header {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

.sample-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.sample-button {
    background: white;
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
}

.sample-button:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background-color: #f8fafc;
}

@media (max-width: 640px) {
    .sample-buttons {
        flex-direction: column;
    }
    
    .sample-button {
        width: 100%;
    }
}

.help-icon {
    color: #4a6da7;
    cursor: help;
    display: inline-flex;
    align-items: center;
    margin-left: 5px;
}

.help-icon:hover {
    color: #3a5a8f;
}

.help-icon-svg {
    width: 1.2rem;
    height: 1.2rem;
}

/* Style for the tooltip */
[title] {
    position: relative;
    cursor: help;
}

/* Add these styles */
.span-full {
    grid-column: 1 / -1;
}

select {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: border-color 0.2s;
    background-color: white;
}

select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.method-info {
    margin-top: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-align: center;
}

.print-button-container {
    display: flex;
    justify-content: flex-start;
    margin-top: 20px;
    gap: 10px;
}

#printResultsBtn, #exportResultsBtn {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f9fa;
    border: 1px solid #ddd;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

#printResultsBtn:hover, #exportResultsBtn:hover {
    background-color: #e9ecef;
    border-color: #ced4da;
}

#printResultsBtn:disabled, #exportResultsBtn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Add this to your styles.css file */
.negative-value {
    color: #b71c1c !important; /* Dark red color */
    font-weight: bold;
}

/* Add these styles to your styles.css file */
.info-message {
    background-color: #e0f2fe;
    border-left: 4px solid #0ea5e9;
    color: #0c4a6e;
    padding: 0.75rem 1rem;
    margin: 1rem 0;
    border-radius: 0.25rem;
    font-size: 0.9rem;
}

.file-info.info {
    color: #1565c0;
}

/* Add these styles to make tooltips appear immediately */
[title] {
    position: relative;
    cursor: help;
}

[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    width: max-content;
    max-width: 300px;
    white-space: normal;
    text-align: center;
}

/* Add a small triangle at the bottom of the tooltip */
[title]:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px;
    border-style: solid;
    border-color: #333 transparent transparent transparent;
    z-index: 1000;
    pointer-events: none;
}

/* Adjust position for help icons */
.help-icon[title]:hover::after,
.help-icon[title]:hover::before {
    bottom: 125%;
}

/* Add these styles to your CSS file */
.app-footer {
    margin-top: 30px;
    padding: 15px 0;
    border-top: 1px solid #e9ecef;
    color: #6c757d;
    font-size: 0.9rem;
}

.report-issue-link {
    color: #6c757d;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: color 0.2s;
}

.report-issue-link:hover {
    color: #0d6efd;
    text-decoration: underline;
}

.version-info {
    margin-left: 15px;
    color: #adb5bd;
    font-size: 0.8rem;
}

/* Make sure the footer stays at the bottom */
@media (min-height: 800px) {
    .app-footer {
        position: relative;
        margin-top: auto;
    }
    
    body {
        min-height: 100vh;
        display: flex;
        flex-direction: column;
    }
}

/* Remove loading indicator styles */
/* Loading Indicator */
.loading-indicator {
    display: none; /* Hide it completely but keep the class in case it's referenced elsewhere */
}

.spinner {
    display: none;
}

.loading-text {
    display: none;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Scroll Indicator */
.scroll-indicator {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background-color: var(--primary-color);
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: bounceIn 0.5s ease-out;
    transition: transform 0.2s, opacity 0.3s;
}

.scroll-indicator:hover {
    transform: translateY(-5px);
}

.scroll-text {
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.scroll-arrow {
    font-size: 1.25rem;
    animation: bounce 1.5s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    70% {
        transform: scale(1.1) translateY(-5px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.fade-out {
    opacity: 0;
    transform: translateY(20px);
}

/* Responsive adjustments for indicators */
@media (max-width: 640px) {
    .scroll-indicator {
        bottom: 1rem;
        right: 1rem;
        padding: 0.5rem 1rem;
    }
    
    .loading-indicator {
        padding: 0.5rem;
    }
}

/* Instructions Section */
.instructions-container {
    margin-bottom: 2rem;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.basic-instructions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.basic-instructions p {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin: 0;
}

.instructions-toggle {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    border-radius: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
}

.instructions-toggle:hover {
    background-color: var(--primary-color);
    color: white;
}

.detailed-instructions {
    margin-top: 1.5rem;
    padding: 1.5rem;
    background-color: #f8fafc;
    border-radius: 0.75rem;
    border-left: 4px solid var(--primary-color);
}

.detailed-instructions h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.detailed-instructions ol {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.detailed-instructions li {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.detailed-instructions a {
    color: var(--primary-color);
    text-decoration: none;
}

.detailed-instructions a:hover {
    text-decoration: underline;
}

.detailed-instructions code {
    background-color: #f1f5f9;
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-family: monospace;
    font-size: 0.9em;
    color: #0f172a;
}

.detailed-instructions pre {
    background-color: #f1f5f9;
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: monospace;
    font-size: 0.9em;
    overflow-x: auto;
    white-space: pre;
    color: #0f172a;
    border-left: 3px solid var(--primary-color);
    margin: 1rem 0 1.5rem 0;
}

@media (max-width: 640px) {
    .basic-instructions {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .instructions-toggle {
        align-self: flex-start;
    }
}

/* Add styles for the new tab indicator */
.new-tab-indicator {
    font-size: 0.8em;
    color: #666;
    font-style: italic;
    margin-left: 4px;
}

/* Style for the export button to match */
#exportResultsBtn {
    background-color: #f8f9fa;
    border: 1px solid #ddd;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-left: 10px;
}

#exportResultsBtn:hover {
    background-color: #e9ecef;
    border-color: #ced4da;
}

.report-format-container {
    margin-top: 16px;
    text-align: center;
}

#reportFormatBtn {
    background-color: #4b5563;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s;
}

#reportFormatBtn:hover {
    background-color: #374151;
}

.method-info-notification {
    animation: fadeIn 0.5s ease-out;
    margin: 0.5rem 0 1rem;
    position: relative;
}

.method-info-notification .info-message {
    background-color: #eff6ff;
    border-left: 4px solid #3b82f6;
    color: #1e40af;
    padding-right: 30px; /* Make room for the close button */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

.method-info-notification .info-message strong {
    font-weight: 600;
}

.close-notification {
    position: absolute;
    top: 8px;
    right: 10px;
    background: none;
    border: none;
    color: #1e40af;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-notification:hover {
    background-color: rgba(59, 130, 246, 0.1);
}

.file-info + .method-info-notification {
    margin-top: 10px;
    margin-bottom: 20px;
    z-index: 10;
}

/* Add styles for the visualizations container and panel visualization */
.visualizations-container {
    display: flex;
    gap: 20px;
    margin-bottom: 1.5rem;
}

.panel-vis-container {
    flex: 1; /* Takes up 1/3 of the available space */
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 15px;
    height: 350px;
    display: flex;
    flex-direction: column;
    min-width: 180px; /* Ensure minimum width for readability */
}

.chart-title {
    font-size: 16px;
    margin: 0 0 5px 0;
    color: var(--text-primary);
    font-weight: 600;
}

#panelVisCanvas, #chartCanvas {
    flex: 1;
    width: 100%;
    height: auto;
    max-height: 100%;
    object-fit: contain;
}

.panel-description {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 0;
    font-style: italic;
}

.warning-note {
    color: #dc3545;
    font-weight: bold;
}

/* Media query for smaller screens */
@media (max-width: 768px) {
    .visualizations-container {
        flex-direction: column;
    }
    
    .chart-container, .panel-vis-container {
        width: 100%;
        height: 350px; /* Set a fixed height for mobile devices to prevent stretching */
        min-height: 300px; /* Ensure minimum height for content visibility */
        max-height: 350px; /* Limit maximum height to prevent excessive scrolling */
    }
}

/* Value Proposition Section */
.value-proposition {
    background-color: #f0f9ff;
    border-left: 4px solid #2563eb;
    padding: 1.5rem;
    margin: 2rem 0;
    border-radius: 0.5rem;
}

.value-proposition h2 {
    color: #1e40af;
    margin-top: 0;
    font-size: 1.5rem;
}

.value-proposition .highlight {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e40af;
    margin: 1rem 0;
}

.value-proposition p {
    margin: 0.5rem 0;
    line-height: 1.5;
}

.info-note {
    font-size: 0.75rem;
    color: #666666;
    font-style: italic;
    margin-top: 3px;
}

.seasonal-load-applied {
    font-size: 0.75rem;
    color: #666666;
    font-style: italic;
    margin-top: 3px;
} 