html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    font-size: 14px;
    background-color: #f0f2f5;
    color: #1a1a2e;
    margin: 0;
    padding: 0;
}

/* ── Links ──────────────────────────────────────── */
a, .btn-link {
    color: #1a5fa8;
}

a:hover {
    color: #c0392b;
}

/* ── Dashboard panel cards ──────────────────────── */
.panel {
    background: #ffffff;
    border: 1px solid #dde3ea;
    border-radius: 4px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.panel-header {
    background-color: #0d2344;
    color: #ffffff;
    padding: 0.5rem 0.85rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.panel-header a {
    color: #a0b8d0;
    font-size: 0.72rem;
    font-weight: 400;
    text-decoration: none;
    letter-spacing: 0;
    text-transform: none;
}

.panel-header a:hover {
    color: #ffffff;
}

.panel-body {
    flex: 1;
    overflow-y: auto;
}

/* Home dashboard: cap each panel to the screen height so long lists
   scroll inside their block instead of stretching the page. */
@media (min-width: 992px) {
    .home-grid .panel {
        max-height: calc(100vh - 160px);
    }
}

/* ── News items ─────────────────────────────────── */
.news-item {
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid #eef0f3;
    transition: background 0.12s;
}

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

.news-item:hover {
    background-color: #f7f9fc;
}

.news-item-date {
    font-size: 0.7rem;
    color: #7a8a9a;
    margin-bottom: 0.2rem;
}

.news-item-title {
    font-size: 0.88rem;
    font-weight: 600;
    color: #1a3560;
    text-decoration: none;
    line-height: 1.35;
    display: block;
}

.news-item-title:hover {
    color: #c0392b;
    text-decoration: none;
}

/* ── FPSO table ─────────────────────────────────── */
.fpso-table {
    width: 100%;
    font-size: 0.8rem;
    border-collapse: collapse;
}

.fpso-table thead tr {
    background-color: #1a3560;
    color: #c8d8e8;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.fpso-table thead th {
    padding: 0.45rem 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.fpso-table tbody tr {
    border-bottom: 1px solid #eef0f3;
}

.fpso-table tbody tr:hover {
    background-color: #f0f5fc;
}

.fpso-table tbody td {
    padding: 0.4rem 0.75rem;
    vertical-align: middle;
}

/* ── Chart placeholder ──────────────────────────── */
.chart-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 180px;
    color: #8a9bb0;
    font-size: 0.8rem;
    border: 2px dashed #d0d8e4;
    border-radius: 4px;
    margin: 0.75rem;
    gap: 0.5rem;
}

.chart-placeholder-icon {
    font-size: 2rem;
    opacity: 0.4;
}

/* ── Shared utilities ───────────────────────────── */
.section-badge {
    display: inline-block;
    background-color: #c0392b;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 0.1rem 0.4rem;
    border-radius: 2px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-right: 0.4rem;
}

/* ── Page headings ──────────────────────────────── */
h1 {
    font-size: 1.5rem;
    color: #0d2344;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* ── Breadcrumb ─────────────────────────────────── */
.breadcrumb {
    font-size: 0.8rem;
    background: none;
    padding: 0;
    margin-bottom: 0.75rem;
}

/* ── Tables (generic) ───────────────────────────── */
.table thead.table-dark th {
    background-color: #1a3560;
    border-color: #1a3560;
}

/* ── Blazor misc ─────────────────────────────────── */
h1:focus { outline: none; }

.valid.modified:not([type=checkbox]) { outline: 1px solid #26b050; }
.invalid { outline: 1px solid #c0392b; }
.validation-message { color: #c0392b; }

.blazor-error-boundary {
    background: #c0392b;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

/* ══════════════ Responsive / mobile ══════════════ */

/* Wide tables scroll horizontally instead of breaking the layout */
@media (max-width: 768px) {
    .table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap;
    }

    h1 { font-size: 1.25rem; }
}

/* Filter row wraps and controls stretch on small screens */
@media (max-width: 640px) {
    .row.g-2 > .col-auto,
    .row.g-2 > .col-auto .form-control,
    .row.g-2 > .col-auto .form-select,
    .row.g-2 > .col-auto .filter-dd-btn {
        width: 100%;
    }

    .row.g-2 > .col-auto { flex: 1 1 100%; }

    /* Hero blocks: tighter padding on phones */
    .fps-list-hero,
    .fps-unit-hero { padding: 18px 16px !important; }
    .fps-list-hero h1,
    .fps-unit-hero h1 { font-size: 24px !important; }
}
