/* =============================================================================
   Oula Wasata — site.css
   Arabic-only stylesheet for the Reports portal.

   - Single (light) theme.
   - RTL throughout. Bootstrap RTL build handles columns/utilities.
   - English digits everywhere (font-feature-settings forces tabular Latin
     digits for numeric columns).
   ========================================================================== */

:root {
    /* Brand palette (sampled from the official logo) */
    --ow-navy:        #1e3a6f;
    --ow-navy-2:      #264a87;
    --ow-navy-3:      #355fa3;
    --ow-accent:      #4eb3c4;
    --ow-accent-2:    #3a96a6;
    --ow-red:         #b00020;

    /* Neutral palette */
    --ow-bg:          #f5f7fb;
    --ow-surface:     #ffffff;
    --ow-surface-2:   #f8fafc;
    --ow-text:        #111827;
    --ow-text-soft:   #4b5563;
    --ow-muted:       #6b7280;
    --ow-border:      #e5e7eb;
    --ow-border-2:    #d1d5db;
    --ow-row-alt:     #fafbfd;
    --ow-row-hover:   #eef3fb;

    --ow-radius:      12px;
    --ow-radius-sm:   8px;
    --ow-shadow:      0 2px 10px rgba(30, 58, 111, 0.05), 0 8px 30px rgba(30, 58, 111, 0.06);

    --ow-font-body:   "Cairo", "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    --ow-font-head:   "Cairo", "Inter", "Segoe UI", system-ui, sans-serif;
}

/* --- Base ----------------------------------------------------------------- */
html, body {
    background: var(--ow-bg);
    color: var(--ow-text);
    font-family: var(--ow-font-body);
    -webkit-font-smoothing: antialiased;
}

a { color: var(--ow-navy-3); text-decoration: none; }
a:hover { color: var(--ow-accent-2); }

h1, h2, h3, h4, h5, h6 { font-family: var(--ow-font-head); color: var(--ow-text); }

/* English digits for any element that displays numbers (the .ow-num class
   on numeric table cells already does this). Some Arabic system fonts render
   Arabic-Indic digits by default; this forces Latin (0–9). */
.ow-num,
.dataTables_info,
.dataTables_paginate,
.ow-meta {
    font-feature-settings: "lnum" 1, "tnum" 1;
    font-variant-numeric: lining-nums tabular-nums;
}

/* --- Header --------------------------------------------------------------- */
.ow-header {
    background: #ffffff;
    border-bottom: 1px solid var(--ow-border);
    box-shadow: 0 1px 4px rgba(30, 58, 111, 0.06);
}
.ow-header__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
}

.ow-brand { display: inline-flex; align-items: center; }
.ow-brand__img {
    height: 56px;
    width: auto;
    max-width: min(360px, 60vw);
    object-fit: contain;
    display: block;
}
@media (max-width: 576px) { .ow-brand__img { height: 44px; } }

.ow-home {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--ow-radius-sm);
    font-weight: 600;
    font-size: 14px;
    color: var(--ow-navy);
    background: transparent;
    border: 1px solid var(--ow-border-2);
    text-decoration: none;
    transition: all 0.15s ease;
    cursor: pointer;
}
.ow-home:hover {
    background: var(--ow-navy);
    color: #fff;
    border-color: var(--ow-navy);
}
.ow-home i { font-size: 16px; }

/* --- Buttons -------------------------------------------------------------- */
.ow-btn-outline {
    background: transparent;
    color: var(--ow-navy);
    border: 1px solid var(--ow-border-2);
    border-radius: var(--ow-radius-sm);
    font-weight: 500;
    transition: all 0.15s ease;
}
.ow-btn-outline:hover {
    background: var(--ow-navy);
    color: #fff;
    border-color: var(--ow-navy);
}

/* --- Hero ----------------------------------------------------------------- */
.ow-hero {
    background: linear-gradient(135deg, var(--ow-navy) 0%, var(--ow-navy-2) 60%, var(--ow-navy-3) 100%);
    color: #fff;
    padding: 56px 0 80px;
    position: relative;
    overflow: hidden;
}
.ow-hero::before {
    content: ""; position: absolute; inset-inline-end: -120px; top: -80px;
    width: 320px; height: 320px; border-radius: 50%;
    background: radial-gradient(circle, rgba(78, 179, 196, 0.22), transparent 70%);
}
.ow-eyebrow {
    font-size: 13px; color: var(--ow-accent); font-weight: 700;
}
.ow-hero__title {
    color: #fff;
    font-weight: 800;
    font-size: clamp(28px, 4vw, 42px);
    margin: 8px 0 14px;
}
.ow-hero__lead { color: rgba(255, 255, 255, 0.88); max-width: 720px; font-size: 16px; }
.ow-hero__actions .ow-btn-outline { color: #fff; border-color: rgba(255, 255, 255, 0.45); }
.ow-hero__actions .ow-btn-outline:hover { background: #fff; color: var(--ow-navy); border-color: #fff; }

/* --- Section + card ------------------------------------------------------- */
.ow-section { padding: 0 0 80px; }
.ow-main { margin-top: 0; }

.ow-card {
    background: var(--ow-surface);
    border: 1px solid var(--ow-border);
    border-radius: var(--ow-radius);
    box-shadow: var(--ow-shadow);
    margin-top: -40px;
    overflow: hidden;
    position: relative;
}

/* --- Tabs ----------------------------------------------------------------- */
/* Tabs wrap to multiple lines instead of showing a horizontal scrollbar. */
.ow-tabs-wrap {
    background: var(--ow-surface-2);
    border-bottom: 1px solid var(--ow-border);
    padding: 8px 8px 0;
    overflow: visible;
}
.ow-tabs {
    border: 0;
    flex-wrap: wrap;          /* allow tabs to wrap onto multiple rows */
    row-gap: 4px;
}
.ow-tabs .nav-item { margin-bottom: -1px; }
.ow-tabs .nav-link {
    border: 1px solid transparent;
    border-radius: var(--ow-radius-sm) var(--ow-radius-sm) 0 0;
    color: var(--ow-text-soft);
    font-weight: 600;
    padding: 12px 20px;
    background: transparent;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.ow-tabs .nav-link:hover {
    color: var(--ow-navy);
    background: rgba(30, 58, 111, 0.05);
}
.ow-tabs .nav-link.active {
    color: var(--ow-navy);
    background: var(--ow-surface);
    border-color: var(--ow-border) var(--ow-border) var(--ow-surface);
    box-shadow: inset 0 3px 0 var(--ow-accent);
}

/* --- Toolbar -------------------------------------------------------------- */
.ow-toolbar {
    padding: 16px 20px;
    border-bottom: 1px solid var(--ow-border);
    background: var(--ow-surface);
}
.ow-select { min-width: 220px; max-width: 100%; }

/* --- Status / spinner ----------------------------------------------------- */
.ow-status {
    padding: 16px 20px;
    background: var(--ow-surface-2);
    border-bottom: 1px solid var(--ow-border);
    color: var(--ow-text-soft);
    font-size: 14px;
}
.ow-status--error { color: var(--ow-red); background: rgba(176, 0, 32, 0.06); }
.ow-spinner-row { display: flex; align-items: center; gap: 12px; }
.ow-spinner {
    width: 20px; height: 20px;
    border: 3px solid var(--ow-border-2);
    border-top-color: var(--ow-accent);
    border-radius: 50%;
    animation: ow-spin 0.7s linear infinite;
}
@keyframes ow-spin { to { transform: rotate(360deg); } }

/* --- Table ---------------------------------------------------------------- */
.ow-table-wrap { padding: 12px 20px 24px; }
.ow-table thead th,
table.dataTable.ow-table thead th,
table.dataTable.ow-table thead > tr > th {
    background: var(--ow-navy);
    color: #fff;
    font-weight: 600;
    font-size: 12px;
    line-height: 1.4;
    border-bottom: 2px solid var(--ow-accent);
    white-space: normal;
    word-break: break-word;
    overflow-wrap: anywhere;
    vertical-align: top;
    /* !important is required to defeat the DataTables Bootstrap 5 stylesheet,
       which sets its own text-align on sortable headers. */
    text-align: center !important;
    padding: 8px 18px;       /* a bit more horizontal room for centred text */
    min-width: 80px;
    max-width: 220px;
}
.ow-table thead th:focus { outline: none; }
.ow-table tbody td {
    border-color: var(--ow-border);
    color: var(--ow-text);
    font-size: 14px;
    padding: 10px 12px;
    text-align: center;
    vertical-align: middle;
}
.ow-table tbody tr:nth-child(even) td { background: var(--ow-row-alt); }
.ow-table tbody tr:hover td { background: var(--ow-row-hover); }
/* Numeric data cells render LTR so any leading +/- sign (neutral character)
   sits on the LEFT of the digits — Arabic/RTL bidi would otherwise push it
   to the right of the number. Center-aligned to match the header above. */
.ow-table td.ow-num {
    direction: ltr;
    text-align: center;
    font-variant-numeric: tabular-nums;
}
.ow-table th.ow-num { font-variant-numeric: tabular-nums; }

/* Year-over-year change %: green when positive, red when negative.
   Defined as universal classes so they apply anywhere the value travels —
   the data table <td>, the modal <dd> + its inner span, the DataTables
   Responsive plugin's expand-row content (which only carries the cell's
   inner HTML, hence the <span> wrapper in reports.js), AND any descendant
   that inherits these from a wrapping element. */
.ow-pos,
.ow-pos *,
.ow-table td.ow-pos,
.ow-share-field dd.ow-pos,
.ow-share-field dd.ow-pos .ow-share-field__value {
    color: #168a3e !important;
    font-weight: 700;
}
.ow-neg,
.ow-neg *,
.ow-table td.ow-neg,
.ow-share-field dd.ow-neg,
.ow-share-field dd.ow-neg .ow-share-field__value {
    color: #b00020 !important;
    font-weight: 700;
}

/* DataTables sorting arrows — only the actively sorted column shows an
   arrow, so the un-sorted columns stay perfectly centred. */
table.dataTable thead .sorting,
table.dataTable thead .sorting_asc,
table.dataTable thead .sorting_desc { background-image: none !important; }
table.dataTable thead .sorting::after        { content: none !important; }
table.dataTable thead .sorting_asc::after,
table.dataTable thead .sorting_desc::after {
    content: "";
    display: inline-block;
    width: 8px; height: 8px;
    margin-inline-start: 6px;
    border: solid var(--ow-accent);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.15s ease, border-color 0.15s ease;
}
table.dataTable thead .sorting_asc::after  { transform: rotate(-135deg) translateY(2px); }
table.dataTable thead .sorting_desc::after { transform: rotate(45deg)  translateY(-2px); }

/* DataTables widgets (filter input, length, info, pagination) */
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--ow-border-2);
    border-radius: var(--ow-radius-sm);
    padding: 6px 10px;
    background: var(--ow-surface);
    color: var(--ow-text);
}
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter { color: var(--ow-text-soft); padding: 0 8px; }

.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: var(--ow-radius-sm);
    border: 1px solid transparent !important;
    color: var(--ow-text-soft) !important;
    background: transparent !important;
    padding: 4px 12px;
    margin: 0 2px;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--ow-row-hover) !important;
    border-color: var(--ow-border-2) !important;
    color: var(--ow-navy) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: var(--ow-navy) !important;
    border-color: var(--ow-navy) !important;
    color: #fff !important;
}

.dataTables_scrollHead, .fixedHeader-floating { background: var(--ow-surface); }

/* -----------------------------------------------------------------------
   Custom DataTables layout — driven by dom: "<'ow-dt-top'fB>...<'ow-dt-bot'ip>"
   ow-dt-top is a flex row. In RTL, the first DOM child (filter `f`) ends up
   on the visual LEFT and the second child (buttons `B`) on the visual RIGHT,
   which is exactly what we want.
   ----------------------------------------------------------------------- */
.ow-dt-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin: 0 0 12px;
}
.ow-dt-top .dataTables_filter { margin: 0; padding: 0; }
.ow-dt-top .dataTables_filter label { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.ow-dt-top .dataTables_filter input { min-width: 220px; }

.ow-dt-top .dt-buttons { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.ow-dt-top .dt-buttons .btn { display: inline-flex; align-items: center; gap: 4px; }

.ow-dt-bot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
}

/* --- Notes (Last Updated + disclaimer) ----------------------------------- */
.ow-notes {
    padding: 14px 20px 20px;
    border-top: 1px solid var(--ow-border);
    background: var(--ow-surface);
}
.ow-notes__updated {
    color: var(--ow-text-soft);
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
    font-feature-settings: "lnum" 1, "tnum" 1;
}
.ow-notes__updated i { color: var(--ow-accent); }
.ow-notes__disclaimer {
    color: var(--ow-red);
    font-size: 13.5px;
    line-height: 1.7;
    margin: 0;
}
.ow-notes__disclaimer + .ow-notes__disclaimer { margin-top: 8px; }

/* --- Overall statistics strip -------------------------------------------- */
.ow-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    padding: 18px 20px 4px;
    background: var(--ow-surface);
}
.ow-stat {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 14px;
    background: var(--ow-surface-2);
    border: 1px solid var(--ow-border);
    border-radius: 12px;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
    min-width: 0;
}
.ow-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(30,58,111,0.08);
}
.ow-stat__icon {
    width: 42px; height: 42px;
    flex: 0 0 42px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 10px;
    background: var(--ow-navy);
    color: #fff;
    font-size: 20px;
}
.ow-stat__body { min-width: 0; flex: 1; }
.ow-stat__label {
    font-size: 12px;
    color: var(--ow-muted);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 2px;
}
.ow-stat__value {
    font-size: 18px;
    font-weight: 800;
    color: var(--ow-text);
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-feature-settings: "lnum" 1, "tnum" 1;
}
.ow-stat__hint {
    font-size: 11px;
    color: var(--ow-muted);
    font-weight: 600;
    margin-top: 2px;
    font-feature-settings: "lnum" 1, "tnum" 1;
}

/* Tone variants */
.ow-stat--positive .ow-stat__icon { background: #168a3e; }
.ow-stat--positive .ow-stat__value { color: #168a3e; }
.ow-stat--negative .ow-stat__icon { background: #b00020; }
.ow-stat--negative .ow-stat__value { color: #b00020; }
.ow-stat--accent   .ow-stat__icon { background: var(--ow-accent); color: #0a1628; }
.ow-stat--accent   .ow-stat__value { color: var(--ow-accent-2); }

/* --- Branded Excel / PDF / Print buttons --------------------------------- */
.ow-btn-action {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: var(--ow-radius-sm);
    font-weight: 600;
    border: 1px solid transparent;
    background: var(--ow-surface);
    color: var(--ow-text);
    transition: all 0.18s ease;
}
.ow-btn-action i { font-size: 16px; line-height: 1; }
.ow-btn-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(0,0,0,0.10);
}

/* Excel — green */
.ow-btn-excel { border-color: rgba(22,138,62,0.35); color: #0f5b2c; background: #f1f8f2; }
.ow-btn-excel i { color: #168a3e; }
.ow-btn-excel:hover { background: #168a3e; color: #fff; border-color: #168a3e; }
.ow-btn-excel:hover i { color: #fff; }

/* PDF — red */
.ow-btn-pdf { border-color: rgba(176,0,32,0.30); color: #7a000d; background: #fdf3f4; }
.ow-btn-pdf i { color: #b00020; }
.ow-btn-pdf:hover { background: #b00020; color: #fff; border-color: #b00020; }
.ow-btn-pdf:hover i { color: #fff; }

/* Print — navy */
.ow-btn-print { border-color: rgba(30,58,111,0.30); color: var(--ow-navy); background: #f1f4fb; }
.ow-btn-print i { color: var(--ow-navy); }
.ow-btn-print:hover { background: var(--ow-navy); color: #fff; border-color: var(--ow-navy); }
.ow-btn-print:hover i { color: #fff; }

/* --- Per-share KPI strip in modal ---------------------------------------- */
.ow-kpi-strip {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}
.ow-kpi {
    background: var(--ow-surface-2);
    border: 1px solid var(--ow-border);
    border-radius: 10px;
    padding: 10px 12px;
    min-width: 0;
}
.ow-kpi__label {
    font-size: 11px;
    color: var(--ow-muted);
    font-weight: 700;
    margin-bottom: 2px;
}
.ow-kpi__value {
    font-size: 18px;
    font-weight: 800;
    color: var(--ow-text);
    font-feature-settings: "lnum" 1, "tnum" 1;
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.ow-kpi__value i { font-size: 18px; }
.ow-kpi__unit { font-size: 12px; color: var(--ow-muted); font-weight: 500; }
.ow-kpi--positive { background: #ecf7f0; border-color: #c1e5cd; }
.ow-kpi--positive .ow-kpi__value { color: #168a3e; }
.ow-kpi--negative { background: #fdf0f2; border-color: #f1c2cc; }
.ow-kpi--negative .ow-kpi__value { color: #b00020; }
.ow-kpi--accent   { background: #ecf7fa; border-color: #c2e4ec; }
.ow-kpi--accent   .ow-kpi__value { color: var(--ow-accent-2); }

/* --- Row action column (details button) ---------------------------------- */
.ow-table th.ow-action-col,
.ow-table td.ow-action-col {
    width: 44px;
    min-width: 44px;
    text-align: center;
    padding: 6px 4px;
    background: var(--ow-surface-2) !important;   /* always neutral, no zebra */
}
.ow-row-btn {
    width: 32px; height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--ow-border-2);
    border-radius: 50%;
    background: var(--ow-surface);
    color: var(--ow-navy);
    transition: all 0.18s ease;
    cursor: pointer;
}
.ow-row-btn:hover {
    background: var(--ow-navy);
    border-color: var(--ow-navy);
    color: #fff;
    transform: scale(1.08);
    box-shadow: 0 6px 14px rgba(30,58,111,0.20);
}
.ow-row-btn i { font-size: 14px; line-height: 1; }

/* --- Share details modal -------------------------------------------------- */
.ow-share-modal .modal-content {
    border: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(30,58,111,0.25);
}

/* Custom scale + slide-from-top entrance animation. Bootstrap's default fade
   handles the opacity; we layer transform on top via .show. */
.ow-share-modal .modal-dialog {
    transform: translateY(-30px) scale(0.96);
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.32s ease;
    opacity: 0;
}
.ow-share-modal.show .modal-dialog {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.ow-share-modal__header {
    background: linear-gradient(135deg, var(--ow-navy) 0%, var(--ow-navy-2) 50%, var(--ow-navy-3) 100%);
    color: #fff;
    border: 0;
    padding: 22px 26px;
    position: relative;
    overflow: hidden;
}
.ow-share-modal__header::after {
    content: "";
    position: absolute;
    inset-inline-end: -50px;
    top: -40px;
    width: 180px; height: 180px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(78,179,196,0.30), transparent 70%);
    pointer-events: none;
}
.ow-share-modal__title-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    position: relative;
    z-index: 1;
}
.ow-share-modal__symbol {
    display: inline-block;
    width: fit-content;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--ow-accent);
    color: #0a1628;
    font-weight: 800;
    font-size: 12px;
    letter-spacing: 0.04em;
    font-feature-settings: "lnum" 1, "tnum" 1;
}
.ow-share-modal .modal-title {
    color: #fff;
    font-weight: 800;
    font-size: 22px;
    line-height: 1.25;
    margin: 0;
}
.ow-share-modal__subtitle {
    color: rgba(255,255,255,0.82);
    font-size: 13px;
}
.ow-share-modal .btn-close {
    filter: invert(1) grayscale(100%) brightness(2);
    opacity: 0.85;
    position: relative;
    z-index: 1;
}

.ow-share-modal .modal-body {
    padding: 22px 26px;
    background: var(--ow-surface);
}
.ow-share-modal .modal-footer {
    border-top: 1px solid var(--ow-border);
    padding: 14px 26px;
    background: var(--ow-surface-2);
}

.ow-share-modal__sections {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.ow-share-section {
    background: var(--ow-surface-2);
    border: 1px solid var(--ow-border);
    border-radius: 12px;
    padding: 14px 16px;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.ow-share-section:hover {
    box-shadow: 0 6px 18px rgba(30,58,111,0.06);
}
.ow-share-section__title {
    font-size: 14px;
    color: var(--ow-accent-2);
    font-weight: 800;
    margin: 0 0 12px;
    padding: 0 0 8px;
    border-bottom: 2px solid var(--ow-accent);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: 100%;
}
.ow-share-section__icon {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--ow-navy);
    color: #fff;
    border-radius: 8px;
    font-size: 14px;
    flex: 0 0 28px;
}

.ow-share-fields {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 10px 18px;
    margin: 0;
}

/* Year-comparison card: one metric per row, its year cells side by side. */
.ow-cmp-rows {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
}
.ow-cmp-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
}
.ow-cmp-row .ow-share-field {
    flex: 1 1 200px;
    min-width: 0;
}

/* --- Daily market reports tab -------------------------------------------- */
.ow-tab-daily { font-weight: 700; }
.ow-daily-actions {
    display: flex;
    gap: 8px;
    white-space: nowrap;
}
.ow-daily-actions .btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.ow-share-field {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    padding: 8px 10px;
    background: var(--ow-surface);
    border: 1px solid var(--ow-border);
    border-radius: 8px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.ow-share-field:hover {
    border-color: var(--ow-accent);
    box-shadow: 0 2px 8px rgba(30,58,111,0.07);
}
.ow-share-field dt {
    color: var(--ow-muted);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
}
.ow-share-field dd {
    color: var(--ow-text);
    font-size: 16px;
    font-weight: 700;
    margin: 0;
    word-break: break-word;
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    flex-wrap: wrap;
}
.ow-share-field__value { display: inline-block; }
.ow-share-field__unit {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    color: var(--ow-accent-2);
    background: rgba(78,179,196,0.12);
    padding: 1px 8px;
    border-radius: 999px;
    letter-spacing: 0;
}
.ow-share-field dd.ow-num {
    font-feature-settings: "lnum" 1, "tnum" 1;
}
.ow-share-field dd.ow-num .ow-share-field__value {
    direction: ltr;          /* digits read left-to-right */
}
.ow-share-field dd.ow-neg .ow-share-field__value { color: var(--ow-red); }
.ow-share-field__empty { color: var(--ow-muted); font-weight: 500; font-size: 14px; }

/* --- Footer --------------------------------------------------------------- */
.ow-footer {
    background: var(--ow-navy);
    color: rgba(255, 255, 255, 0.85);
    padding: 18px 0;
    margin-top: 40px;
    font-size: 13px;
}
.ow-footer__row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    justify-content: space-between;
    align-items: center;
}
.ow-footer__link { color: #fff; font-weight: 600; }
.ow-footer__link:hover { color: var(--ow-accent); }

/* --- Responsive ----------------------------------------------------------- */
/* ---------- TABLET (≤ 992 px) -------------------------------------------- */
@media (max-width: 992px) {
    .container { padding-inline: 16px; }

    .ow-card { margin-top: -28px; }

    .ow-hero { padding: 44px 0 64px; }
    .ow-hero__title { font-size: clamp(24px, 4vw, 36px); }

    .ow-tabs .nav-link { padding: 10px 14px; font-size: 14px; }

    /* DataTables custom toolbar — wrap nicely and keep right side balanced */
    .ow-dt-top, .ow-dt-bot { gap: 10px; }
    .ow-dt-top .dataTables_filter input { min-width: 180px; }
}

/* ---------- PHONE (≤ 768 px) --------------------------------------------- */
@media (max-width: 768px) {
    /* Header / chrome */
    .ow-header__row { padding: 10px 0; }
    .ow-brand__img  { height: 40px; }
    .ow-home        { padding: 8px 10px; }
    .ow-home span   { display: none; }     /* icon-only Home button */
    .ow-home i      { font-size: 18px; }

    /* Hero */
    .ow-card  { margin-top: -24px; border-radius: var(--ow-radius-sm); }
    .ow-hero  { padding: 32px 0 56px; }
    .ow-hero__title { font-size: 22px; margin-bottom: 0; }
    .ow-hero__actions .btn span { display: none; }   /* refresh = icon only */
    .ow-hero__actions .btn i    { font-size: 18px; }

    /* Toolbar */
    .ow-toolbar { padding: 12px; flex-direction: column; align-items: stretch; }
    .ow-toolbar > label { margin-bottom: 4px; }
    .ow-select  { width: 100%; min-width: 0; }

    /* Table */
    .ow-table-wrap { padding: 6px 6px 14px; }
    .ow-table thead th { font-size: 11px; padding: 6px 8px; }
    .ow-table tbody td { font-size: 13px; padding: 8px 6px; }

    /* Larger touch target for the row-details eye */
    .ow-row-btn { width: 38px; height: 38px; }

    /* Subtle background tint behind change-% cells makes the green / red
       jump out even on small screens with imperfect contrast. */
    .ow-table td.ow-pos {
        background-color: rgba(22, 138, 62, 0.10) !important;
        border-radius: 6px;
    }
    .ow-table td.ow-neg {
        background-color: rgba(176, 0, 32, 0.10) !important;
        border-radius: 6px;
    }

    /* DataTables toolbar wraps to two rows */
    .ow-dt-top {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .ow-dt-top .dataTables_filter,
    .ow-dt-top .dt-buttons { width: 100%; justify-content: center; }
    .ow-dt-top .dataTables_filter input { width: 100%; box-sizing: border-box; }
    .ow-dt-top .dt-buttons .btn { flex: 1 1 0; justify-content: center; }

    /* Notes block */
    .ow-notes { padding: 14px 12px; }
    .ow-notes__updated { font-size: 13px; }
    .ow-notes__disclaimer { font-size: 12.5px; line-height: 1.7; }

    /* Footer single-column */
    .ow-footer__row { flex-direction: column; gap: 6px; text-align: center; }
}

/* ---------- SMALL PHONE (≤ 576 px) — modal goes full-screen ------------- */
@media (max-width: 576px) {
    .ow-brand__img   { height: 36px; }
    .ow-hero         { padding: 24px 0 48px; }
    .ow-hero__title  { font-size: 20px; }
    .ow-eyebrow      { font-size: 11px; }

    .ow-tabs .nav-link { padding: 8px 12px; font-size: 13px; }

    .ow-table thead th { font-size: 10.5px; padding: 6px 4px; line-height: 1.3; }
    .ow-table tbody td { font-size: 12.5px; padding: 7px 4px; }

    .ow-action-col   { width: 38px; min-width: 38px; padding: 4px 2px !important; }
    .ow-row-btn      { width: 34px; height: 34px; }
    .ow-row-btn i    { font-size: 13px; }

    /* Full-screen modal: edge-to-edge cards inside, easier to read on a phone */
    .ow-share-modal.modal-fullscreen-sm-down .modal-content { border-radius: 0; }
    .ow-share-modal .modal-body { padding: 16px 14px; }
    .ow-share-modal__header     { padding: 16px 18px; }
    .ow-share-modal .modal-title { font-size: 18px; }
    .ow-share-modal__sections   { gap: 14px; }
    .ow-share-fields {
        grid-template-columns: 1fr;   /* single column on a phone */
        gap: 8px;
    }
    .ow-share-field    { padding: 10px 12px; }
    .ow-share-field dd { font-size: 15px; }
}

/* ---------- Tiny phones (≤ 360 px) — strip every spare pixel ----------- */
@media (max-width: 360px) {
    .container { padding-inline: 10px; }
    .ow-hero__title { font-size: 18px; }
    .ow-table thead th { font-size: 10px; padding: 4px 2px; }
    .ow-table tbody td { font-size: 12px; padding: 6px 3px; }
}
