:root {
    --bg: #f3f7f9;
    --surface: #ffffff;
    --surface-soft: #eaf4f7;
    --text: #17252d;
    --muted: #4c626d;
    --border: #cfdee4;
    --brand: #0b4f6c;
    --brand-dark: #083a50;
    --brand-light: #d9edf3;
    --accent: #b24a36;
    --accent-soft: #fff1ed;
    --success: #256342;
    --success-soft: #e8f5ed;
    --warning: #7a4a00;
    --warning-soft: #fff5dc;
    --danger: #982c2c;
    --danger-soft: #fff0f0;
    --shadow-sm: 0 1px 2px rgba(20, 53, 65, 0.06);
    --shadow-md: 0 12px 28px rgba(20, 53, 65, 0.09);
    --radius: 16px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    color-scheme: light;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 1rem;
    line-height: 1.65;
    text-rendering: optimizeLegibility;
}

body.modal-open {
    overflow: hidden;
}

[hidden] {
    display: none !important;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: var(--brand);
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}

a:hover {
    color: var(--brand-dark);
}

:focus-visible {
    outline: 3px solid #f2b84b;
    outline-offset: 3px;
}

.page {
    width: min(100% - 2rem, 1120px);
    margin-inline: auto;
}

.skip-link {
    position: fixed;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 20000;
    padding: 0.7rem 1rem;
    border-radius: 8px;
    background: #ffffff;
    color: var(--brand-dark);
    font-weight: 700;
    transform: translateY(-180%);
    transition: transform 0.15s ease;
}

.skip-link:focus {
    transform: translateY(0);
}

.site-header {
    min-height: 280px;
    display: grid;
    align-items: center;
    background-color: #e7f2f7;
    background-image:
        linear-gradient(90deg, rgba(238, 247, 250, 0.98) 0%, rgba(238, 247, 250, 0.9) 47%, rgba(238, 247, 250, 0.35) 75%, rgba(238, 247, 250, 0.18) 100%),
        url("tlo-logo.png");
    background-image:
        linear-gradient(90deg, rgba(238, 247, 250, 0.98) 0%, rgba(238, 247, 250, 0.9) 47%, rgba(238, 247, 250, 0.35) 75%, rgba(238, 247, 250, 0.18) 100%),
        image-set(url("hero.webp") type("image/webp"), url("tlo-logo.png") type("image/png"));
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    border-bottom: 1px solid #c4dce5;
}

.site-header__content {
    padding-block: 2.5rem;
}

.brand {
    display: inline-block;
    color: var(--brand-dark);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.13em;
    text-decoration: none;
}

.eyebrow {
    margin: 1.4rem 0 0.35rem;
    color: var(--brand);
    font-size: 0.82rem;
    font-weight: 750;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    color: #102d3a;
    line-height: 1.23;
}

h1 {
    max-width: 780px;
    margin: 0;
    font-size: clamp(2rem, 4.8vw, 3.45rem);
    font-weight: 760;
    letter-spacing: -0.035em;
}

h2 {
    margin: 0 0 0.75rem;
    font-size: clamp(1.3rem, 2vw, 1.65rem);
    letter-spacing: -0.015em;
}

h3 {
    margin: 1.35rem 0 0.45rem;
    font-size: 1.08rem;
}

.subtitle {
    max-width: 720px;
    margin: 0.85rem 0 0;
    color: #385662;
    font-size: clamp(1rem, 1.8vw, 1.14rem);
}

.main-nav {
    position: relative;
    z-index: 40;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.main-nav__inner {
    min-height: 58px;
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.45rem;
    margin: 0;
    padding: 0.5rem 0;
    list-style: none;
}

.nav-list a {
    display: block;
    padding: 0.55rem 0.72rem;
    border-radius: 9px;
    color: #3c5661;
    font-size: 0.9rem;
    font-weight: 650;
    text-decoration: none;
}

.nav-list a:hover {
    background: var(--surface-soft);
    color: var(--brand-dark);
}

.nav-list a.active {
    background: var(--brand);
    color: #ffffff;
}

.nav-toggle {
    width: 100%;
    min-height: 48px;
    align-items: center;
    justify-content: space-between;
    padding: 0.55rem 0;
    border: 0;
    background: transparent;
    color: var(--brand-dark);
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}

.nav-toggle__icon,
.nav-toggle__icon::before,
.nav-toggle__icon::after {
    width: 24px;
    height: 2px;
    display: block;
    position: relative;
    border-radius: 10px;
    background: currentColor;
    transition: transform 0.15s ease;
}

.nav-toggle__icon::before,
.nav-toggle__icon::after {
    content: "";
    position: absolute;
    left: 0;
}

.nav-toggle__icon::before { top: -7px; }
.nav-toggle__icon::after { top: 7px; }

.nav-toggle[aria-expanded="true"] .nav-toggle__icon { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__icon::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__icon::after { top: 0; transform: rotate(-45deg); }

.safety-strip {
    background: #173f50;
    color: #f4fafc;
    font-size: 0.9rem;
}

.safety-strip .page {
    padding-block: 0.68rem;
}

.safety-strip a {
    color: #ffffff;
    font-weight: 800;
}

.main-content {
    padding-block: clamp(1.5rem, 4vw, 3.2rem) 4rem;
}

.main-content > :first-child {
    margin-top: 0;
}

.intro {
    max-width: 78ch;
    color: #304b56;
    font-size: 1.08rem;
}

.section-heading {
    margin: 2.4rem 0 1rem;
}

.card {
    margin: 0 0 1rem;
    padding: clamp(1.2rem, 3vw, 1.75rem);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.card > :last-child,
.callout > :last-child {
    margin-bottom: 0;
}

.card p {
    max-width: 80ch;
    margin: 0.45rem 0 0.9rem;
}

.card ul,
.card ol,
.callout ul,
.callout ol {
    max-width: 80ch;
    margin: 0.6rem 0 0.8rem;
    padding-left: 1.35rem;
}

.card li,
.callout li {
    margin-bottom: 0.38rem;
    padding-left: 0.15rem;
}

.card-emphasis {
    border-color: #a8ccd9;
    background: linear-gradient(135deg, #ffffff, #eef8fa);
    box-shadow: var(--shadow-md);
}

.card-contact {
    border-left: 5px solid var(--brand);
}

.badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 0.8rem;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    background: var(--brand-light);
    color: var(--brand-dark);
    font-size: 0.78rem;
    font-weight: 780;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.button-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-top: 1.25rem;
}

.button,
.button-link {
    border-radius: 9px;
    font: inherit;
    font-weight: 720;
    cursor: pointer;
}

.button {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1rem;
    border: 1px solid transparent;
    text-decoration: none;
}

.button-primary {
    background: var(--brand);
    color: #ffffff;
}

.button-primary:hover {
    background: var(--brand-dark);
    color: #ffffff;
}

.button-secondary {
    border-color: #b8cbd3;
    background: #ffffff;
    color: var(--brand-dark);
}

.button-secondary:hover {
    background: #edf5f7;
}

.button-quiet {
    border-color: transparent;
    background: transparent;
    color: inherit;
    text-decoration: underline;
}

.button-link {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--brand);
    text-decoration: underline;
    text-underline-offset: 0.18em;
}

.link-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.link-card {
    min-height: 170px;
    display: flex;
    flex-direction: column;
    padding: 1.35rem;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.link-card:hover {
    border-color: #86b7c9;
    box-shadow: var(--shadow-md);
    color: var(--text);
    transform: translateY(-2px);
}

.link-card__kicker {
    color: var(--brand);
    font-size: 0.78rem;
    font-weight: 780;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.link-card strong {
    margin: 0.35rem 0;
    color: #102d3a;
    font-size: 1.15rem;
}

.link-card span:last-child {
    color: var(--muted);
    font-size: 0.92rem;
}

.process-list {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.85rem;
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
    counter-reset: steps;
}

.process-list li {
    position: relative;
    padding: 3.2rem 1rem 1rem;
    border-radius: 12px;
    background: var(--surface-soft);
    counter-increment: steps;
}

.process-list li::before {
    content: counter(steps);
    position: absolute;
    top: 0.85rem;
    left: 1rem;
    width: 1.9rem;
    height: 1.9rem;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--brand);
    color: #ffffff;
    font-size: 0.82rem;
    font-weight: 800;
}

.callout {
    margin: 1rem 0;
    padding: 1.15rem 1.3rem;
    border: 1px solid;
    border-left-width: 5px;
    border-radius: 12px;
}

.callout h2,
.callout h3 {
    margin-top: 0;
}

.callout-info {
    border-color: #9ac7d7;
    background: #edf8fb;
}

.callout-warning {
    border-color: #e5b75c;
    background: var(--warning-soft);
    color: #4f350c;
}

.callout-danger {
    border-color: #dfa4a4;
    background: var(--danger-soft);
    color: #5f2020;
}

.callout-success {
    border-color: #9dcbb1;
    background: var(--success-soft);
    color: #204f36;
}

.sub-nav {
    position: sticky;
    top: 0.5rem;
    z-index: 30;
    margin-bottom: 1.25rem;
    padding: 0.55rem;
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-md);
    scrollbar-width: thin;
}

.sub-nav ul {
    width: max-content;
    display: flex;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sub-nav a {
    display: block;
    padding: 0.45rem 0.7rem;
    border-radius: 8px;
    color: #385662;
    font-size: 0.85rem;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
}

.sub-nav a:hover,
.sub-nav a:focus-visible {
    background: var(--brand-light);
    color: var(--brand-dark);
}

[id] {
    scroll-margin-top: 5.6rem;
}

details.more-box {
    margin-top: 1rem;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #f7fafb;
}

details.more-box[open] {
    background: #f0f7f9;
}

details.more-box summary {
    position: relative;
    padding: 0.8rem 3rem 0.8rem 1rem;
    color: var(--brand-dark);
    font-weight: 720;
    cursor: pointer;
    list-style: none;
}

details.more-box summary::-webkit-details-marker {
    display: none;
}

details.more-box summary::after {
    content: "+";
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    font-size: 1.35rem;
    line-height: 1;
}

details.more-box[open] summary::after {
    content: "−";
}

details.more-box > :not(summary) {
    margin-right: 1rem;
    margin-left: 1rem;
}

.contact-number {
    display: inline-block;
    margin: 0.35rem 0 0.8rem;
    padding: 0.55rem 0.8rem;
    border-radius: 9px;
    background: var(--brand-light);
    color: var(--brand-dark);
    font-size: 1.18rem;
    font-weight: 800;
    text-decoration: none;
}

.meta-list {
    display: grid;
    grid-template-columns: 12rem 1fr;
    gap: 0.5rem 1.25rem;
    margin: 0;
}

.meta-list dt {
    font-weight: 750;
}

.meta-list dd {
    margin: 0;
}

.source-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.source-list li {
    padding: 0.85rem 0;
    border-bottom: 1px solid var(--border);
}

.source-list li:last-child {
    border-bottom: 0;
}

.source-list small {
    display: block;
    margin-top: 0.18rem;
    color: var(--muted);
}

.site-footer {
    border-top: 1px solid #bfd3db;
    background: #e5f0f4;
    color: #2f4a55;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 1fr;
    gap: 2rem;
    padding-block: 2.3rem 1.6rem;
    font-size: 0.9rem;
}

.footer-grid p {
    margin: 0.25rem 0 0.7rem;
}

.footer-brand,
.footer-heading {
    color: var(--brand-dark);
    font-weight: 800;
}

.footer-brand {
    letter-spacing: 0.08em;
}

.footer-links {
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-links li {
    margin: 0 0 0.45rem;
}

.footer-bottom {
    padding-block: 0.9rem 1.2rem;
    border-top: 1px solid #c8dce3;
    font-size: 0.8rem;
}

.footer-bottom p {
    margin: 0;
}

.cookie-banner {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 10000;
    padding: 1rem;
    border-top: 1px solid #678795;
    background: #102f3c;
    color: #f2f8fa;
    box-shadow: 0 -12px 30px rgba(7, 30, 39, 0.2);
}

.cookie-banner__content {
    width: min(100%, 1120px);
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 1.5rem;
    margin-inline: auto;
}

.cookie-banner h2 {
    margin: 0 0 0.25rem;
    color: #ffffff;
    font-size: 1.1rem;
}

.cookie-banner p {
    max-width: 76ch;
    margin: 0;
    color: #dfecef;
    font-size: 0.9rem;
}

.cookie-banner a {
    color: #ffffff;
}

.cookie-actions,
.cookie-modal__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.cookie-modal {
    position: fixed;
    inset: 0;
    z-index: 11000;
    display: grid;
    place-items: center;
    padding: 1rem;
    background: rgba(6, 27, 35, 0.76);
}

.cookie-modal__panel {
    width: min(100%, 560px);
    max-height: min(90vh, 720px);
    overflow-y: auto;
    padding: 1.4rem;
    border-radius: 15px;
    background: #ffffff;
    box-shadow: 0 24px 70px rgba(6, 27, 35, 0.35);
}

.cookie-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.cookie-modal__header h2 {
    margin: 0;
}

.icon-button {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: #ffffff;
    color: var(--brand-dark);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.cookie-toggle {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    margin: 1.2rem 0;
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: #f7fafb;
    cursor: pointer;
}

.cookie-toggle input {
    width: 1.25rem;
    height: 1.25rem;
    flex: 0 0 auto;
    margin-top: 0.15rem;
    accent-color: var(--brand);
}

.cookie-toggle small {
    display: block;
    margin-top: 0.25rem;
    color: var(--muted);
    line-height: 1.45;
}

.cookie-modal__actions {
    justify-content: flex-end;
    margin-top: 1.2rem;
}

.error-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 1rem;
}

.error-card {
    width: min(100%, 640px);
    text-align: center;
}

@media (max-width: 920px) {
    .link-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .process-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 760px) {
    .page {
        width: min(100% - 1.25rem, 1120px);
    }

    .site-header {
        min-height: 230px;
        background-position: 58% center;
    }

    .site-header__content {
        padding-block: 1.8rem;
    }

    .eyebrow {
        margin-top: 1rem;
    }

    .main-nav__inner {
        display: block;
        min-height: 48px;
    }

    .nav-toggle:not([hidden]) {
        display: flex;
    }

    .main-nav.nav-ready .nav-list:not(.is-open) {
        display: none;
    }

    .nav-list {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.35rem;
        padding: 0 0 0.65rem;
    }

    .nav-list a {
        height: 100%;
        padding: 0.65rem;
        border: 1px solid var(--border);
        background: #ffffff;
    }

    .safety-strip {
        font-size: 0.84rem;
    }

    .cookie-banner__content {
        grid-template-columns: 1fr;
        gap: 0.8rem;
    }

    .cookie-actions .button {
        flex: 1 1 auto;
    }

    .meta-list {
        grid-template-columns: 1fr;
        gap: 0.15rem;
    }

    .meta-list dd {
        margin-bottom: 0.65rem;
    }
}

@media (max-width: 560px) {
    body {
        font-size: 0.97rem;
    }

    .link-grid,
    .process-list,
    .footer-grid,
    .nav-list {
        grid-template-columns: 1fr;
    }

    .link-card {
        min-height: 0;
    }

    .card {
        border-radius: 12px;
    }

    .button-row .button,
    .cookie-modal__actions .button {
        width: 100%;
    }

    .footer-grid {
        gap: 1.25rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

@media print {
    body {
        background: #ffffff;
        color: #000000;
        font-size: 11pt;
    }

    .site-header {
        min-height: 0;
        background: none;
        border: 0;
    }

    .site-header__content {
        padding-block: 1rem;
    }

    .main-nav,
    .safety-strip,
    .sub-nav,
    .cookie-banner,
    .cookie-modal,
    .button-row,
    .site-footer {
        display: none !important;
    }

    .main-content {
        padding: 0;
    }

    .card,
    .callout {
        break-inside: avoid;
        border-color: #999999;
        box-shadow: none;
    }

    details.more-box > * {
        display: block !important;
    }
}
