:root {
    --ink: #182126;
    --muted: #66717a;
    --line: #d9dedb;
    --paper: #f4f1ea;
    --paper-strong: #e8e1d5;
    --steel: #28343a;
    --green: #245d4b;
    --green-dark: #173d32;
    --oxide: #b65b35;
    --white: #ffffff;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: 'Inter', Arial, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 28px;
    min-height: 78px;
    padding: 12px clamp(18px, 4vw, 56px);
    background: rgba(250, 248, 242, 0.92);
    border-bottom: 1px solid rgba(24, 33, 38, 0.12);
    backdrop-filter: blur(14px);
}

.brand-link {
    display: inline-flex;
    align-items: center;
}

.brand-logo {
    width: 280px;
    max-width: 45vw;
    height: auto;
    display: block;
}

.main-nav {
    justify-self: center;
    display: flex;
    align-items: center;
    gap: clamp(18px, 3vw, 34px);
    color: var(--steel);
    font-size: 0.86rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.main-nav a,
.site-footer a,
.contact-panel a {
    transition: color 180ms ease, border-color 180ms ease, background 180ms ease;
}

.main-nav a:hover,
.main-nav a:focus-visible,
.site-footer a:hover,
.contact-panel a:hover {
    color: var(--oxide);
}

.header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.icon-link,
.contact-button,
.primary-action,
.secondary-action {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.icon-link {
    width: 44px;
    border: 1px solid var(--line);
    color: var(--green);
    background: rgba(255, 255, 255, 0.65);
}

.icon-link svg {
    width: 19px;
    height: 19px;
    fill: currentColor;
}

.contact-button {
    padding: 0 18px;
    color: var(--white);
    background: var(--green);
    font-size: 0.86rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.contact-button:hover,
.contact-button:focus-visible,
.primary-action:hover,
.primary-action:focus-visible {
    background: var(--green-dark);
}

.hero-section {
    position: relative;
    min-height: 92vh;
    display: grid;
    align-items: end;
    padding: 150px clamp(22px, 5vw, 76px) 58px;
    color: var(--white);
    isolation: isolate;
}

.hero-media,
.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.hero-media {
    background-image: url('/static/images/tbros-penang-construction-hero.webp');
    background-size: cover;
    background-position: center;
}

.hero-overlay {
    z-index: -1;
    background:
        linear-gradient(90deg, rgba(16, 24, 28, 0.88) 0%, rgba(16, 24, 28, 0.66) 45%, rgba(16, 24, 28, 0.18) 78%),
        linear-gradient(0deg, rgba(16, 24, 28, 0.66) 0%, rgba(16, 24, 28, 0.08) 48%);
}

.hero-inner {
    width: min(720px, 100%);
    max-width: 1180px;
    margin: 0 auto;
    padding-bottom: clamp(58px, 9vh, 108px);
}

.hero-copy-block {
    padding: 0;
}

.eyebrow,
.section-kicker {
    margin: 0 0 14px;
    color: var(--oxide);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.hero-inner h1,
.intro-grid h2,
.section-heading h2,
.region-section h2,
.contact-section h2 {
    margin: 0;
    font-family: 'Barlow', Arial, sans-serif;
    font-weight: 800;
    line-height: 0.98;
    letter-spacing: 0;
}

.hero-inner h1 {
    font-size: clamp(2.75rem, 6.2vw, 5.7rem);
    max-width: 780px;
}

.hero-copy {
    margin: 28px 0 0;
    max-width: 640px;
    color: rgba(255, 255, 255, 0.84);
    font-size: clamp(1rem, 1.5vw, 1.18rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 40px;
}

.primary-action,
.secondary-action {
    padding: 13px 22px;
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.primary-action {
    color: var(--white);
    background: var(--green);
}

.secondary-action {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.52);
    background: rgba(255, 255, 255, 0.08);
}

.secondary-action:hover,
.secondary-action:focus-visible {
    border-color: var(--white);
    background: rgba(255, 255, 255, 0.16);
}

.hero-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    width: min(980px, 100%);
    margin: 48px auto 0;
    background: var(--line);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.hero-facts div {
    min-height: 124px;
    padding: 22px;
    background: rgba(14, 24, 28, 0.68);
}

.hero-facts strong {
    display: block;
    font-family: 'Barlow', Arial, sans-serif;
    font-size: clamp(1.35rem, 2.5vw, 2rem);
    line-height: 1;
}

.hero-facts span {
    display: block;
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.9rem;
}

.intro-section,
.projects-section,
.region-section,
.contact-section {
    padding: clamp(82px, 9vw, 136px) clamp(22px, 5vw, 76px);
}

.intro-grid,
.section-heading,
.region-section,
.contact-section {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    gap: clamp(36px, 6vw, 88px);
    align-items: start;
    max-width: 1180px;
    margin: 0 auto;
}

.intro-grid h2,
.section-heading h2,
.region-section h2,
.contact-section h2 {
    font-size: clamp(2rem, 3.75vw, 3.85rem);
    line-height: 1.04;
}

.intro-grid p,
.section-heading p,
.region-section p,
.contact-section p {
    margin: 0;
    color: var(--muted);
    font-size: 1.05rem;
}

.contact-section h2 + p {
    margin-top: 28px;
}

.services-section {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: var(--white);
}

.services-section article {
    min-height: 380px;
    padding: clamp(34px, 4.8vw, 62px);
    border-right: 1px solid var(--line);
}

.services-section article:last-child {
    border-right: 0;
}

.services-section span {
    display: block;
    color: var(--oxide);
    font-family: 'Barlow', Arial, sans-serif;
    font-size: 1rem;
    font-weight: 800;
}

.services-section h3,
.project-row h3 {
    margin: 34px 0 14px;
    font-family: 'Barlow', Arial, sans-serif;
    font-size: clamp(1.3rem, 2vw, 1.8rem);
    line-height: 1.14;
    font-weight: 800;
}

.services-section p,
.project-row p {
    margin: 0;
    color: var(--muted);
}

.projects-section {
    background: var(--paper-strong);
}

.site-gallery {
    display: grid;
    grid-template-columns: 1.2fr 0.9fr 0.9fr;
    gap: clamp(16px, 2vw, 26px);
    padding: clamp(36px, 5vw, 78px) clamp(22px, 5vw, 76px);
    background: var(--paper);
}

.site-gallery figure {
    margin: 0;
    min-height: clamp(280px, 30vw, 460px);
    overflow: hidden;
    background: var(--steel);
}

.site-gallery figure:first-child {
    min-height: clamp(340px, 34vw, 540px);
}

.section-heading {
    margin-bottom: 52px;
}

.project-list {
    max-width: 1180px;
    margin: 0 auto;
    border-top: 1px solid rgba(24, 33, 38, 0.22);
}

.project-row {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr) auto;
    gap: clamp(18px, 4vw, 46px);
    align-items: start;
    padding: 32px 0;
    border-bottom: 1px solid rgba(24, 33, 38, 0.18);
}

.project-year {
    color: var(--green);
    font-family: 'Barlow', Arial, sans-serif;
    font-size: 1.32rem;
    font-weight: 800;
}

.project-row h3 {
    margin: 0 0 12px;
}

.project-row > span {
    align-self: start;
    padding: 7px 11px;
    color: var(--green-dark);
    border: 1px solid rgba(36, 93, 75, 0.28);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.more-projects {
    border-bottom: 1px solid rgba(24, 33, 38, 0.18);
}

.more-projects summary {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 0;
    color: var(--green-dark);
    cursor: pointer;
    list-style: none;
    font-size: 0.86rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

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

.more-projects summary svg {
    width: 22px;
    height: 22px;
    flex: 0 0 auto;
    fill: currentColor;
    transition: transform 180ms ease;
}

.more-projects[open] summary svg {
    transform: rotate(180deg);
}

.more-project-list {
    border-top: 1px solid rgba(24, 33, 38, 0.12);
}

.more-project-list .project-row:last-child {
    border-bottom: 0;
}

.region-section {
    color: var(--white);
    background: var(--steel);
}

.region-section .section-kicker {
    color: #e2a47f;
}

.region-section p {
    color: rgba(255, 255, 255, 0.72);
}

.contact-section {
    background: var(--paper);
}

.contact-panel {
    display: grid;
    gap: 12px;
    padding: 34px;
    color: var(--steel);
    background: var(--white);
    border: 1px solid var(--line);
}

.contact-panel a,
.contact-panel span {
    display: block;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
    overflow-wrap: anywhere;
}

.contact-panel span {
    padding-bottom: 0;
    border-bottom: 0;
}

.site-footer {
    display: flex;
    justify-content: center;
    text-align: center;
    padding: 18px clamp(20px, 5vw, 72px);
    color: rgba(255, 255, 255, 0.68);
    background: #11181b;
    font-size: 0.74rem;
}

:focus-visible {
    outline: 3px solid rgba(182, 91, 53, 0.55);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

@media (max-width: 860px) {
    .site-header {
        grid-template-columns: 1fr auto;
        gap: 14px;
        min-height: 72px;
    }

    .main-nav {
        grid-column: 1 / -1;
        justify-self: start;
        order: 3;
        width: 100%;
        gap: 20px;
        overflow-x: auto;
        padding-top: 4px;
        font-size: 0.76rem;
    }

    .header-actions {
        gap: 8px;
    }

    .contact-button {
        padding: 0 14px;
    }

    .hero-section {
        min-height: 94vh;
        padding-top: 148px;
        padding-bottom: 42px;
    }

    .hero-overlay {
        background:
            linear-gradient(90deg, rgba(16, 24, 28, 0.9) 0%, rgba(16, 24, 28, 0.68) 100%),
            linear-gradient(0deg, rgba(16, 24, 28, 0.68) 0%, rgba(16, 24, 28, 0.08) 50%);
    }

    .hero-facts,
    .services-section,
    .site-gallery,
    .intro-grid,
    .section-heading,
    .region-section,
    .contact-section {
        grid-template-columns: 1fr;
    }

    .services-section article {
        min-height: auto;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }

    .services-section article:last-child {
        border-bottom: 0;
    }

    .project-row {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 30px 0;
    }

    .site-footer {
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .brand-logo {
        width: 190px;
    }

    .icon-link {
        display: none;
    }

    .hero-inner h1 {
        font-size: clamp(2.3rem, 11.5vw, 3.55rem);
        line-height: 1.03;
    }

    .hero-actions {
        display: grid;
    }

    .hero-inner {
        padding-bottom: 46px;
    }

    .hero-copy {
        margin-top: 22px;
    }

    .hero-facts div {
        min-height: 108px;
    }

    .site-gallery figure,
    .site-gallery figure:first-child {
        min-height: 280px;
    }
}

.site-gallery img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}
