:root {
    --primary-color: #0d2b4d;
    --secondary-color: #435d7d;
    --accent-color: #1a75ff;
    --background-color: #f8f9fa;
    --text-color: #333;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text-color);
    background-color: var(--background-color);
}

.navbar {
    background-color: var(--primary-color) !important;
}

.card {
    border: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.card:hover {
    transform: translateY(-2px);
}

.search-container {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.filter-container button {
    border-color: var(--secondary-color);
    color: var(--secondary-color);
}

.filter-container button.active {
    background-color: var(--secondary-color);
    color: white;
}

.refinery-card {
    margin-bottom: 20px;
}

.refinery-card img {
    height: 200px;
    object-fit: cover;
}

.lazy-image {
    opacity: 0;
    transition: opacity 0.3s;
}

.lazy-image.loaded {
    opacity: 1;
}

/* Comparison Tool Styles */
.comparison-table {
    background-color: white;
    margin-bottom: 2rem;
}

.comparison-table th {
    background-color: var(--primary-color);
    color: white;
    vertical-align: middle;
}

.comparison-table td {
    vertical-align: middle;
}

.comparison-controls {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

.comparison-chart {
    height: 400px;
    background-color: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.remove-refinery {
    color: white;
    padding: 0;
}

.remove-refinery:hover {
    color: #ff4444;
}

/* AdSense Responsive Styles */
.adsbygoogle {
    margin: 20px 0;
    background-color: #f1f1f1;
    border-radius: 4px;
}

/* Compare Button Styles */
.compare-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 0.875rem;
    opacity: 0;
    transition: opacity 0.2s;
}

.card:hover .compare-btn {
    opacity: 1;
}

.compare-btn.active {
    background-color: var(--accent-color);
}

/* Print Report Styles */
.print-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

.report-header {
    text-align: center;
    margin-bottom: 40px;
}

.print-logo {
    width: 60px;
    height: 60px;
    margin-bottom: 20px;
}

.report-date {
    color: #666;
    font-style: italic;
}

.report-section {
    margin-bottom: 40px;
}

.report-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.report-table th,
.report-table td {
    padding: 12px;
    border: 1px solid #ddd;
    text-align: left;
}

.report-table th {
    background-color: var(--primary-color);
    color: white;
}

.report-footer {
    margin-top: 60px;
    text-align: center;
    color: #666;
    border-top: 1px solid #ddd;
    padding-top: 20px;
}

/* Print-specific styles */
@media print {
    body {
        background: white;
    }

    .navbar,
    .adsbygoogle,
    .no-print {
        display: none !important;
    }

    .print-container {
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .report-table {
        page-break-inside: avoid;
    }

    .report-section {
        page-break-inside: avoid;
    }
}

/* Print button style */
.print-report-btn {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.print-report-btn:hover {
    background-color: var(--accent-color);
}

/* Container spacing */
.search-container {
    padding: 16px;
    background-color: #f8f9fa; /* Light gray background for contrast */
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Search input field */
.search-input {
    font-size: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.search-input:focus {
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
    outline: none;
}

/* Filter buttons */
.filter-buttons .btn {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.filter-buttons .btn.active {
    box-shadow: 0 4px 6px rgba(0, 123, 255, 0.3);
}

.filter-buttons .btn:hover {
    background-color: rgba(0, 123, 255, 0.1);
}

/* Dropdown styling */
.country-dropdown {
    width: 100%;
    max-width: 200px; /* Limits dropdown width */
    font-size: 0.9rem;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
}

/* Mobile adjustments */
@media (max-width: 576px) {
    .search-container {
        padding: 12px;
    }

    .filter-container {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-buttons {
        justify-content: space-between;
        width: 100%;
    }

    .country-dropdown {
        width: 100%;
    }
}

/* Tablet adjustments */
@media (min-width: 577px) and (max-width: 992px) {
    .search-input {
        font-size: 0.95rem;
    }

    .filter-buttons .btn {
        font-size: 0.85rem;
        padding: 0.4rem 0.9rem;
    }

    .country-dropdown {
        max-width: 160px;
    }
}

.search-container {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  }
  
  .search-row {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
  }
  
  .filter-row {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
  }
  
  .search-input {
    flex: 1;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    border: none;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
  }
  
  .search-input:focus {
    outline: none;
    background: rgba(0, 0, 0, 0.08);
    box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.3);
  }
  
  .filter-button {
    padding: 0.75rem 1.25rem;
    font-size: 0.95rem;
    border: none;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.05);
    color: #333;
    transition: all 0.2s ease;
    cursor: pointer;
    flex-shrink: 0;
  }
  
  .filter-button:hover {
    background: rgba(0, 0, 0, 0.08);
  }
  
  .filter-button.active {
    background: #007AFF;
    color: white;
  }
  
  .country-select {
    padding: 0.75rem 2.5rem 0.75rem 1rem;
    font-size: 0.95rem;
    border: none;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.05);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1rem;
    margin-left: auto;
  }
  
  .country-select:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.3);
  }
  
  @media (max-width: 768px) {
    .country-select {
      margin-left: 0;
      width: 100%;
    }
  }

  .charts-container {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
    padding: 1.5rem;
  }
  
  .chart-wrapper {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 
      0 4px 6px -1px rgba(0, 0, 0, 0.1),
      0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 20px;
    margin: 20px;
  }
  
  .chart-wrapper:hover {
    transform: translateY(-2px);
    box-shadow: 
      0 10px 15px -3px rgba(0, 0, 0, 0.1),
      0 4px 6px -2px rgba(0, 0, 0, 0.05);
  }
  
  .capacity-chart {
    grid-column: span 8;
  }
  
  .status-chart {
    grid-column: span 4;
  }
  
  .chart-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
  }
  
  .chart-title {
    font-size: 1.1rem;
    font-weight: 500;
    color: #1c1c1e;
    margin: 0;
  }
  
  .chart-actions {
    display: flex;
    gap: 10px;
  }
  
  .chart-action-btn {
    padding: 0.5rem;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: #007AFF;
    cursor: pointer;
    transition: background-color 0.2s ease;
    padding: 8px;
  }
  
  .chart-action-btn:hover {
    background-color: #f5f5f5;
  }
  
  .chart-content {
    padding: 1.5rem;
    position: relative;
    margin-bottom: 20px;
  }
  
  .chart-legend {
    display: flex;
    gap: 20px;
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    justify-content: center;
  }
  
  .legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #666;
  }
  
  .legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
  }
  
  @media (max-width: 992px) {
    .capacity-chart,
    .status-chart {
      grid-column: span 12;
    }
  }
  
  /* Custom scrollbar for charts */
  .chart-content::-webkit-scrollbar {
    width: 8px;
    height: 8px;
  }
  
  .chart-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
  }
  
  .chart-content::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
  }
  
  .chart-content::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
  }

  