/* Climate Scorecards - Static Frontend Styles */
/* Matches Flask/Jinja2 base.html styles */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f5f5f5;
}

.header {
    background: #2c3e50;
    color: white;
    padding: 1rem 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.header h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

.header nav {
    margin-top: 0.5rem;
}

.header nav a {
    color: #ecf0f1;
    text-decoration: none;
    margin-right: 1.5rem;
    font-size: 0.9rem;
}

.header nav a:hover {
    color: #3498db;
}

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

.card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* Summary cards (dashboard) */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: white;
    padding: 1.25rem;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    text-align: center;
}

.summary-card .number {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.1;
}

.summary-card .label {
    font-size: 0.8rem;
    color: #7f8c8d;
    margin-top: 0.25rem;
}

.summary-card .sub {
    font-size: 0.75rem;
    color: #95a5a6;
    margin-top: 0.15rem;
}

.color-blue { color: #2c3e50; }
.color-green { color: #27ae60; }
.color-orange { color: #f39c12; }
.color-red { color: #e74c3c; }
.color-teal { color: #17a2b8; }

/* Coverage table */
.doc-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.75rem;
}

.doc-table th {
    text-align: left;
    padding: 0.6rem 0.75rem;
    background: #f8f9fa;
    font-size: 0.8rem;
    font-weight: 600;
    color: #555;
    border-bottom: 2px solid #dee2e6;
}

.doc-table td {
    padding: 0.6rem 0.75rem;
    font-size: 0.9rem;
    border-bottom: 1px solid #ecf0f1;
}

.doc-table tr:last-child td {
    font-weight: 600;
    border-top: 2px solid #dee2e6;
    background: #f8f9fa;
}

.bar-container {
    background: #ecf0f1;
    border-radius: 4px;
    height: 8px;
    width: 100%;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s;
}

.bar-green { background: #27ae60; }
.bar-orange { background: #f39c12; }
.bar-red { background: #e74c3c; }
.bar-blue { background: #3498db; }

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

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.2s;
}

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

.btn-primary:hover {
    background: #2980b9;
}

.btn-success {
    background: #27ae60;
    color: white;
}

.btn-success:hover {
    background: #229954;
}

.btn-danger {
    background: #e74c3c;
    color: white;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

.btn-sm {
    padding: 0.25rem 0.75rem;
    font-size: 0.85rem;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background: #d4edda;
    color: #155724;
}

.badge-warning {
    background: #fff3cd;
    color: #856404;
}

.badge-danger {
    background: #f8d7da;
    color: #721c24;
}

.badge-info {
    background: #d1ecf1;
    color: #0c5460;
}

.badge-secondary {
    background: #e2e3e5;
    color: #383d41;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #ecf0f1;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    font-size: 0.9rem;
    color: #2c3e50;
}

tr:hover {
    background: #f8f9fa;
}

/* Filter bar */
.filter-bar {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.filter-bar input,
.filter-bar select {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-right: 0.5rem;
}

.filter-bar input[type="text"] {
    width: 250px;
}

.url-display {
    font-family: monospace;
    font-size: 0.85rem;
    color: #555;
    word-break: break-all;
}

/* Loading state */
#loading {
    text-align: center;
    padding: 2rem;
    color: #7f8c8d;
    font-size: 1.1rem;
}

/* Q&A results card */
.qa-result-card {
    border: 1px solid #ecf0f1;
    border-radius: 4px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.qa-result-card.qa-yes { background: #d4edda; border-color: #c3e6cb; }
.qa-result-card.qa-no { background: #f8d7da; border-color: #f5c6cb; }
.qa-result-card.qa-failed { background: #fff3cd; border-color: #ffeeba; }
