html {
    scroll-behavior: smooth;
}

@font-face {
    font-family: 'EurostyleExtBold';
    src: url('/static/fonts/eurostile_ext_bold_only.woff') format('woff2');
    /* font-display: swap; Optional but recommended: helps avoid FOIT/FOUT issues */
  }

.cogito-title {
    font-family: 'EurostyleExtBold', sans-serif;
}

:root {
    /* --primary-color: #515D9A; -this is the color mentioned in the color theme list, but it doesn't match the logo color*/ 
    --primary-color: #4a5fa4;
    --secondary-color: #f5f6fa;
    --text-color: #333;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --success-color: #28a745;

    --dark-buttons-hover-color: #3a497b;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    color: var(--text-color);
    background-color: var(--secondary-color);
}



.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    background-color: var(--primary-color);
    color: white;
    padding: 1rem;
    margin-bottom: 0.5rem;
    border-radius: 8px;
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto;
    min-width: 0;
    overflow: visible;
}

.header-content {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    align-items: flex-start;
}

.header h1 {
    margin-top: 0;
    margin-bottom: 0;
    margin-left: 1rem;
    font-size: 3rem;
}

.process-tag-value {
    font-size:1.2rem;
    font-weight: bold;
    color: var(--text-color);
}

#start-date, #end-date, #generation-date, #query-duration{
    font-size: 1.2rem;
}

.company-info {
    margin-left: 2rem;
    flex: 1; /* Allows flexible sizing */
    min-width: 200px; /* Ensures readable width before wrapping */
    word-wrap: break-word; /* Prevents text overflow */
}

#company-name, #csv-filename {
    font-size: 1.4rem
}

.period-info {
    font-weight: bold;
    word-break: break-word;  /* Allows breaking of long numbers */
    overflow-wrap: break-word;
    /* text-align: right; */
    /* margin-right: 10rem; */
    margin-left: 1rem;
}

.logo-container {
    
    flex-shrink: 0;
    margin-left: auto;
    margin-top: 0.3rem;
}

.logo {
    max-height: 70px;
    width: auto;
    margin-right: 2rem;
    /* margin-top: 0.5rem; */
}

@media (max-width: 500px) {
    .header-content {
        flex-direction: column; /* Stack elements vertically */
    }
    
    .company-info {
        margin-left: 0;
        padding-left: 0;
    }

    .logo-container {
        align-self: center; /* Centers logo when stacked */
        margin-top: 0.5rem;
        margin-right: 0rem;
        margin-bottom: 0.5rem;
        margin-left: 0;
    }
}

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

.general-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}
.readings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}
.navigation-buttons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.grid-with-resource {
    display: grid;
    grid-template-columns: 145px repeat(auto-fit, minmax(200px, 1fr)); /* Fixed first column, flexible rest */
    gap: 1rem;
    margin-bottom: 1rem;
}

.grid-with-gauge {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Flexible first columns, fixed last */
    gap: 1rem;         
    margin-bottom: 1rem;
}

.metric-card {
    position: relative; /* Added because of info icon */
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    /* Testing if we use 1rem all around, does it interfere with the tooltip icon*/
    /* padding: 1rem 2rem 1rem 1rem; Padding for the tooltip icon */
}

.metric-card.process-tag-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.metric-card.process-tag-card h3{
    margin:0;
}

.resource-card {
    /* width: 80px;
    height: 80px; */
    position: relative; /* Added because of info icon */
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.resource-card img {
    display: block;
    margin: 0 auto;
    width: 45px;
    height: 45px;
}

.button-card {
    display: flex;
    justify-content: center;
    align-items: center;
    background: white;
    padding: 0.3rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: none;
    cursor: pointer;
    transition: all 0.1s ease;
    font-size: 1.2rem;
    /* width: 150px; */
}

.button-card span {
    text-align: center;
}

.button-card.active,
.button-card:hover {
    /* background-color: #f0f0f0; */
    background-color: var(--secondary-color);
    transform: scale(0.95);
}

.button-card:active {
    /* background-color: #e0e0e0; */
    background-color: var(--secondary-color);
    transform: scale(0.95);
}

.import-insights-section {
    display: none;
    margin-top: 2rem auto;
    /* max-width: 600px; */
}

.metric-card .input-file,
.metric-card .input-text {
    width: calc(100% - 16px);
    padding: 0.5rem;
    font-size: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.metric-card .btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.metric-card .btn-primary:hover {
    background-color: var(--dark-buttons-hover-color);
    /* transform: scale(0.95); */
}

/* #loadFileForm {
    padding: 0.5rem;
} */

.start-insight-gen-section {
    display: none;
    margin-top: 1rem;
}

.import-icon {
    display: inline-block;
    width: 24px;
    height: 24px;
    background-image: url('/static/images/shared/import_icon.png');
    background-repeat: no-repeat;
    background-size: contain;
  }
  
.button-card.active .import-icon {
    background-image: url('/static/images/shared/import_icon.png');
}

.start-insight-gen-icon {
    display: inline-block;
    width: 24px;
    height: 24px;
    background-image: url('/static/images/shared/start_insights_generation_icon.png');
    background-repeat: no-repeat;
    background-size: contain;
  }
  
.button-card.active .start-insight-gen-icon {
    background-image: url('/static/images/shared/start_insights_generation_icon.png');
}

#resourceSections {
    margin-top: 1rem;
}

.resource-section {
    display: none; /* Hidden by default */
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 1rem;
}

.resource-section label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.resource-section input {
    width: 100%;
    padding: 0.5rem;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.resource-buttons {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin-bottom: 1rem;
}

.resource-text {
    font-size: 1rem;
    font-weight: bold;
}

.button-card-resource {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 1rem;
    width: 120px;
    height: 120px;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    text-align: center;
}
.button-card-resource.active,
.button-card-resource:hover {
    background-color: var(--dark-buttons-hover-color);
    color:white;
    transform: scale(0.95);
}

.button-card-resource .button-icon {
    width: 40px;
    height: 40px;
    margin-bottom: 0.5rem;
}

#progressBarContainer {
    text-align: center;
}

#progressBar {
    margin-top: 20px;
}

#progressText {
    margin-top: 10px;
    font-size: 16px;
}

#progress {
    text-align: center;
    width: 100%; 
    height: 30px; 
}
.subsection {
    margin-top: 1rem;
    padding: 1rem;
    background: #f9f9f9;
    border-radius: 8px;
    display: none; /* Hidden initially */
}

.subsection label,
.subsection input {
    /* display: block; */
    width: 100%; /* Make the input fields full width */
    height: 30px;
    margin-bottom: 0.4rem; /* Add space between the fields */
}

select {
    padding: 0.5rem;
    border-radius: 4px;
    border: 1px solid #ddd;
    width: 100%; /* Make the dropdown full-width */
    margin-top: 0.5rem;
    height: 40px; 
}


button.generate-button {
    padding: 1rem 2rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 1rem;
    width: 100%;
    font-size: 1rem;
}

button.generate-button:hover {
    background-color: var(--dark-buttons-hover-color); /* Darker shade of primary color */
}

.metric-card h3,
.resource-card h3 {
    margin: 0 0 0.5rem 0;
    color: var(--primary-color);
    font-size: 1rem;
}

.metric-value {
    font-size: 1.8rem;
    font-weight: bold;

    word-break: break-word;  /* Allows breaking of long numbers */
    overflow-wrap: break-word;
}

.metric-value.divided {
    display: flex;
    /* align-items: center; */
    /* justify-content: center; */
    gap: 0.8rem; /* space between numbers and divider in total meters */
    flex-wrap: wrap;  /* Allows wrapping if needed */
    padding: 0 0.5rem;
}

.metric-value.divider {
    color: #666;
    font-weight: normal;
}

.info-icon {
    position: absolute;
    top: 8px;
    right: 8px;
    cursor: pointer;
}

.info-icon img 
{
    width: 22px;
    height: 22px;
    display: block;
}

.tooltip {
    position: absolute;
    /* max-width: 250px; */
    min-width: 180px;
    white-space: normal;
    word-wrap: break-word;
    overflow: hidden;
    background-color: var(--primary-color);
    color: #fff;
    padding: 8px;
    border-radius: 4px;
    font-size: 1rem;
    z-index: 1000;
    display: none;
}


.frequency-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.3rem 0;
    border-bottom: 1px solid #eee;
}

.frequency-item:last-child {
    border-bottom: none;
}

.frequency-interval {
    font-weight: bold;
    color: var(--text-color);
    font-size: 1.2rem;
}

.frequency-count {
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: bold;
}

.frequency-percentage {
    color: #666;
    font-size: 1.1rem;
    margin-left: 0.5rem;
    font-weight: bold;
}

.average-item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 0.3rem 0;
    border-bottom: 1px solid #eee;
}

.average-item:last-child {
    border-bottom: none;
}

.frequency-interval {
    font-weight: bold;
    color: var(--text-color);
    font-size: 1.2rem;
}

.frequency-value {
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: bold;
}

.between-section-header{
    /* display: flex; */
    margin-left: 1rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.csv-export-icon {
    position: absolute;
    top: 10px;
    right: 15px;
    width: 20px;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NCAyNTQuMjA5LDQwNi4yMTUgNDM4LjA4MiwxNzcuNjY0IDM3NC4zMzIsMTc3LjY2NCAzNzQuMzMyLDEzLjAwNSAxMzQuMDg2LDEzLjAwNSAiLz4gPC9nPiA8L2c+IDwvZz4KDTwvc3ZnPg==");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.scrollable-table-container {
    position:relative;
    max-height: 300px;
    overflow-y: auto;
    margin: 1rem 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}


.missing-timestamps-table, .over-perc-zero-table, .not-corr-period-table, .zscore-of-mean-table, .missing-values-table-gas, .ad-model-table, .gen-cust-list-table, .nilm-data-table {
    width: 100%;
    border-collapse: collapse;
    position: relative;
}

.missing-timestamps-table th, .over-perc-zero-table th, .not-corr-period-table th, .zscore-of-mean-table th, .missing-values-table-gas th, .ad-model-table th, .gen-cust-list-table th, .nilm-data-table th{
    position: sticky;
    top: 0;
    background-color: var(--primary-color);
    color: white;
    z-index: 1;
    border: none;
    /* display: flex; */
    justify-content: space-between;
    align-items: center;
}

.missing-timestamps-table th, .over-perc-zero-table th,.not-corr-period-table th, .zscore-of-mean-table th, .missing-values-table-gas th, .ad-model-table th, .gen-cust-list-table th, 
.missing-timestamps-table td , .over-perc-zero-table td, .not-corr-period-table td, .zscore-of-mean-table td, .missing-values-table-gas td, .ad-model-table td, .gen-cust-list-table td{
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid #eee;
    /* Add some space for the download button.*/
    padding-right: 40px;
    /* z-index: 1; */
    
}

.nilm-data-table th, .nilm-data-table td {
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid #eee;
    /* Add some space for the download button.*/
    /* padding-right: 40px; */
}

.nilm-data-table tr:nth-child(even) {
    background-color: #f2f2f2;
}

.missing-timestamps-table tbody tr:hover, 
.over-perc-zero-table tbody tr:hover, 
.not-corr-period-table tbody tr:hover,
.zscore-of-mean-table tbody tr:hover,
.missing-values-table-gas tbody tr:hover,
.ad-model-table tbody tr:hover,
.gen-cust-list-table tbody tr:hover,
.nilm-data-table tbody tr:hover {
    background-color: var(--secondary-color);
    
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
}

.data-table th,
.data-table td {
    padding: 0.5rem;
    text-align: left;
    border-bottom: 1px solid #eee;
}

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

.data-table tbody tr:hover {
    background-color: var(--secondary-color);
}

/* PDF export specific styles */

.pdf-export-container {
    display: flex;
    justify-content: end;
    align-items: center;
    margin-top: 10px;
    margin-bottom: 10px;
}

.spinner {
  border: 2px solid #f3f3f3; /* Light grey */
  border-top: 2px solid #555; /* Darker grey */
  border-radius: 50%;
  width: 14px;
  height: 14px;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  margin-right: 8px;
  vertical-align: middle;
}

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


/* VIEW BUTTON STYLES */

/* Similar styles to the 'Sign In' button */
.view-button {
    padding: 0.5rem 1rem;
    background-color: #4CAF50; 
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.view-button:hover {
    background-color: #45a049;
}

/* ANOMALY CHARTS VIEW BUTTON STYLES END*/


/* GAS SPECIFIC STYLES */


/* GAS SPECIFIC STYLES END*/

.footer {
    background-color: var(--primary-color);
    color: white;
    border-radius: 8px;
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto;
    min-width: 0;
    overflow: hidden;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    align-items: flex-start;
    justify-content: center;
}

.zipcode-label {
    pointer-events: none;
    z-index: 650;
}