/* ============================================
   Fliway SCS Website - NZ Post Design System
   ============================================ */

/* ===== NZPSans web font (mirrored from nzpost.co.nz) =====
   12 weights × 2 formats; modern browsers pick WOFF2 first. */
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 300; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Light.woff2')           format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Light.woff')           format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 300; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Light-Italic.woff2')    format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Light-Italic.woff')    format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 400; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Regular.woff2')         format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Regular.woff')         format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 400; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Regular-Italic.woff2')  format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Regular-Italic.woff')  format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 500; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Medium.woff2')          format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Medium.woff')          format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 500; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Medium-Italic.woff2')   format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Medium-Italic.woff')   format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 600; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Semibold.woff2')        format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Semibold.woff')        format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 600; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Semibold-Italic.woff2') format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Semibold-Italic.woff') format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 700; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Bold.woff2')            format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Bold.woff')            format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 700; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Bold-Italic.woff2')     format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Bold-Italic.woff')     format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: normal;  font-weight: 900; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Ultra.woff2')           format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Ultra.woff')           format('woff'); }
@font-face { font-family: 'NZPSans'; font-style: italic;  font-weight: 900; font-display: swap; src: url('../fonts/NZPSans/WOFF2/NZPSANSWEB-Ultra-Italic.woff2')    format('woff2'), url('../fonts/NZPSans/WOFF/NZPSANSWEB-Ultra-Italic.woff')    format('woff'); }
:root { --font-sans: 'NZPSans', Arial, 'Helvetica Neue', Helvetica, sans-serif; }


:root {
    /* NZ Post Group palette - matched from nzpost.co.nz computed styles */
    --nzpost-red: #D8291C;           /* NZ Post actual red: rgb(216, 41, 28) */
    --nzpost-red-dark: #B82218;
    --nzpost-blue: #0033A0;          /* NZ Post primary blue: rgb(0, 51, 160) */
    --fliway-blue: #041E42;          /* NZ Post dark navy text: rgb(4, 30, 66) */
    --fliway-blue-light: #1497D4;    /* Fliway official light blue */
    --fliway-blue-pale: #EDF2F8;
    --fliway-green: #00A651;         /* Fliway accent green */
    --fliway-green-dark: #008C44;
    --accent-green: #00A651;
    --link-blue: #0056F4;            /* NZ Post link blue: rgb(0, 86, 244) */
    --text-primary: rgba(28, 32, 35, 0.87);  /* NZ Post body text */
    --text-secondary: rgba(28, 32, 35, 0.62);
    --text-light: rgba(28, 32, 35, 0.42);
    --bg-white: #FFFFFF;
    --bg-light: #F5F6F8;
    --bg-dark: #041E42;              /* Match NZ Post dark navy */
    --border: #E0E4E8;
    --shadow: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-hover: 0 4px 20px rgba(0,0,0,0.10);
    --radius: 0px;                   /* NZ Post cards: 0px radius */
    --radius-btn: 10px;              /* NZ Post buttons: 10px radius (MDC) */
    --radius-lg: 0px;
    --max-width: 1200px;
    --transition: all 0.25s ease;
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    /* NZ Post uses NZPSans; we use Arial as the closest public equivalent */
    font-family: var(--font-sans);
    color: var(--text-primary);
    line-height: 1.5;
    background: var(--bg-white);
    font-size: 18px;                 /* NZ Post body text is 20px; 18px for Fliway */
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--link-blue); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--fliway-green); text-decoration: underline; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 12px; }

/* Typography - NZ Post DS: H1=40px/48px, H2=32px/40px, H3=22px, body=18px */
h1, h2, h3, h4, h5 { font-weight: 700; line-height: 1.2; color: var(--fliway-blue); }
h1 { font-size: 2.222rem; margin-bottom: 1rem; line-height: 1.2; }    /* 40px / 48px */
h2 { font-size: 1.778rem; margin-bottom: 0.75rem; font-weight: 500; line-height: 1.25; }  /* 32px / 40px */
h3 { font-size: 1.375rem; margin-bottom: 0.5rem; line-height: 1.3; }
h4 { font-size: 1.125rem; margin-bottom: 0.5rem; }
p { margin-bottom: 1rem; color: var(--text-secondary); font-size: 1rem; line-height: 1.6; }
.lead { font-size: 1.2rem; color: var(--text-secondary); line-height: 1.6; }

/* Anchor scroll offset for sticky nav */
[id] { scroll-margin-top: 140px; }

/* ========== NAVIGATION (NZ Post MDC Pattern) ========== */

/* Notification alert banner */
/* Hero sections need relative positioning for alert overlay */
[data-hero] { position: relative; }
[data-hero] > .alert-banner {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
}

.alert-banner {
    background: #d32f2f;
    color: #fff;
    padding: 10px 24px;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    display: flex;
    align-items: center;        /* icon + dismiss vertically centred in the ribbon */
    justify-content: center;    /* icon-text-dismiss group horizontally centred */
    gap: 10px;
    animation: slideDown 0.4s ease-out;
}
/* Text span — natural content width on wide screens (group stays centred);
   shrinks and wraps left-aligned on narrow ribbons without stretching to fill */
.alert-banner > span {
    text-align: left;
    min-width: 0;
    line-height: 1.35;
}
.alert-banner--warning { background: #f57c00; }
.alert-banner--success { background: #4caf50; }
.alert-banner--critical { background: #d32f2f; }
.alert-banner--info { background: #2196f3; }
.alert-banner__cta {
    display: inline-block;
    margin-left: 8px;
    color: #fff;
    text-decoration: underline;
    font-weight: 700;
    white-space: nowrap;
}
.alert-banner__cta:hover { opacity: 0.85; color: #fff;}
.alert-banner__icon {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}
.alert-banner__dismiss {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 4px;
    margin-left: 4px;
    opacity: 0.8;
    transition: opacity 0.15s;
    flex-shrink: 0;
    align-self: center;
}
.alert-banner__dismiss:hover { opacity: 1; }
@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Top navigation bar — full width */
.navigation {
    position: sticky;
    top: 0;
    z-index: 1000;
    font-family: var(--font-sans);
}
.navigation__top {
    background: #fff;
    border-bottom: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}
.navigation__row {
    display: flex;
    align-items: center;
    height: 3.5rem;  /* 56px — matches NZ Post navigation__top height */
    gap: 0;
}

/* Logo group */
.navigation__logo-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-right: .5rem;
    flex-shrink: 0;
    padding: 0;
    border-radius: 0;
    align-self: stretch;
}
.navigation__logo-link {
    display: flex;
    align-items: center;
}
.navigation__logo-img {
    height: 32px;         /* matches NZ Post logo height */
    width: auto;
}
.navigation__scs-logo {
    height: 32px;
    width: auto;
    object-fit: contain;
    border-left: 1px solid rgba(4, 30, 66, 0.2);
    padding-left: 0.75rem;
}

/* Brand text replacing logos */
.navigation__brand-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--fliway-blue);
    text-decoration: none;
    letter-spacing: 0.5px;
    white-space: nowrap;
}
.navigation__brand-img {
    width: auto;          /* 25% larger than the 128px previous size (50% of original 319px) */
    height: 25px;          /* 25% larger than 14px (50% of original 35px) */
    display: block;
    object-fit: contain;
    object-position: left;
}
.navigation__brand-text:hover {
    color: var(--nzpost-blue);
}
.drawer__header .navigation__brand-text {
    color: var(--fliway-blue);
    font-size: 1.1rem;
    font-weight: 600;
}

/* Main top-level links (matches NZ Post .navigation__top-item pattern) */
.navigation__top-items {
    display: block;    /* NZ Post uses block container, not flex, so items stay inline-block */
    flex: 1;
    line-height: 1;
    white-space: nowrap;
}
.navigation__top-item {
    display: inline-block;
    color: var(--bg-dark);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    padding: 0.5rem 0.75rem;
    line-height: 1.25rem;
    letter-spacing: 0.15px;
    border-radius: 0.625rem;
    transition: all 0.15s ease;
    white-space: nowrap;
}
.navigation__top-item:hover {
    color: var(--bg-dark);
    text-decoration: none;
    background-color: rgba(4, 30, 66, 0.06);
}
.navigation__top-item--active {
    background-color: var(--nzpost-blue);
    color: #fff;
}
.navigation__top-item--active:hover {
    background-color: var(--nzpost-blue);
    color: #fff;
}

/* Right-side actions (Search, Portal Login — matches NZ Post end-action pattern) */
.navigation__end-actions {
    display: flex;
    align-items: center;
    gap: 0;
    margin-left: auto;
    flex-shrink: 0;
}
.navigation__action-btn {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    border: none;
    background-color: transparent;
    color: var(--bg-dark);
    text-decoration: none;
    height: 2rem;
    padding: 0;
    margin-left: 1.5rem;
    overflow: hidden;
    font-size: 1rem;
    font-weight: 600;
    white-space: nowrap;
    line-height: 1.25rem;
    transition: all 0.15s ease;
}
.navigation__action-btn:hover {
    color: var(--nzpost-blue);
    text-decoration: none;
}
.navigation__action-btn--active {
    color: var(--nzpost-blue);
}
.navigation__action-btn svg {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

/* Hamburger — hidden on desktop, shown on mobile (matches NZ Post mdc-top-app-bar__navigation-icon) */
.navigation__hamburger {
    display: none;
    background: none;
    border: none;
    color: var(--bg-dark);
    cursor: pointer;
    padding: 12px;
    margin-right: 0;
    border-radius: 50%;
    transition: background 0.15s ease;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
}
.navigation__hamburger:hover {
    background: rgba(4, 30, 66, 0.06);
}
.navigation__hamburger svg {
    width: 24px;
    height: 24px;
}

/* ---- Sub-navigation tab bar (Fliway blue, below white top bar) ---- */
.navigation__bottom {
    background: var(--bg-dark);
    position: relative;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.navigation__tab-bar {
    display: flex;
    align-items: stretch;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 0;
    height: 60px;
    margin-left: -1rem; /* compensate first tab's left padding to align text with logo/breadcrumb */
}
.navigation__tab-bar::-webkit-scrollbar { display: none; }
.navigation__tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.87);
    padding: 0 1rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.15s ease, background 0.15s ease;
    height: 60px;
    position: relative;
    letter-spacing: 0.15px;
    line-height: 1.25rem;
    z-index: 1;
}
/* MDC tab indicator — absolute positioned underline */
.navigation__tab::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: transparent;
    transition: background 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
.navigation__tab:hover {
    color: #fff;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.08);
}
.navigation__tab:hover::after {
    background: #fff;
}
.navigation__tab--active {
    color: #fff;
    font-weight: 600;
}
.navigation__tab--active::after {
    background: #fff;
}

/* ---- Mobile drawer ---- */
.drawer-scrim {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.32);
    z-index: 1100;
    opacity: 0;
    transition: opacity 0.25s ease;
}
.drawer-scrim.active {
    display: block;
    opacity: 1;
}
.drawer {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 304px;           /* matches NZ Post mdc-drawer width */
    max-width: 85vw;
    background: var(--bg-white);
    z-index: 1200;
    transform: translateX(-100%);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    /* mdc-drawer--modal shadow */
    box-shadow: 0 8px 10px -5px rgba(0,0,0,0.2), 0 16px 24px 2px rgba(0,0,0,0.14), 0 6px 30px 5px rgba(0,0,0,0.12);
}
.drawer.open {
    transform: translateX(0);
}
.drawer__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
}
.drawer__header .navigation__logo-img {
    height: 36px;
}
.drawer__close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-primary);
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
}
.drawer__close:hover {
    background: var(--bg-light);
}
.drawer__content {
    padding: 16px 0;
}
.drawer__nav {
    display: flex;
    flex-direction: column;
}
.drawer__section {
    border-bottom: 1px solid var(--border);
}
.drawer__section-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 3rem;
    margin-bottom: 0.25rem;
}
.drawer__section-toggle:hover {
    background: var(--bg-light);
}
.drawer__section-label {
    flex: 1;
    padding: 0 0 0 1rem;
    height: 100%;
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--fliway-blue);
    letter-spacing: 0.1px;
    text-decoration: none;
}
.drawer__section-label:hover { color: var(--fliway-blue); text-decoration: none; }
.drawer__section-chevron-btn {
    flex-shrink: 0;
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
}
.drawer__chevron {
    width: 24px;
    height: 24px;
    transition: transform 0.2s ease;
    color: var(--text-secondary);
    flex-shrink: 0;
}
.drawer__chevron svg {
    width: 24px;
    height: 24px;
}
.drawer__section.open .drawer__chevron {
    transform: rotate(180deg);
}
.drawer__section-content {
    display: none;
    padding: 0 1rem 0.5rem 2.5rem;
    background: var(--bg-light);
}
.drawer__section.open .drawer__section-content {
    display: block;
}
.drawer__sub-item {
    display: block;
    padding: 10px 0;
    font-size: 0.875rem;    /* 14px — matches NZ Post */
    color: var(--text-primary);
    text-decoration: none;
    border-bottom: 1px solid rgba(0,0,0,0.06);
}
.drawer__sub-item:last-child { border-bottom: none; }
.drawer__sub-item:hover { color: var(--nzpost-blue); text-decoration: none; }.drawer__divider {
    padding-left: 1rem;
    margin: 1.5rem 1rem;    /* matches NZ Post mdc-list-divider */
    height: 1px;
    background: var(--border);
}
.drawer__item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0 1rem;
    height: 3rem;           /* matches NZ Post drawer list-item */
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--fliway-blue);
    text-decoration: none;
    letter-spacing: 0.1px;
    margin-bottom: 0.25rem;
}
.drawer__item:hover { background: var(--bg-light); text-decoration: none; color: var(--fliway-blue); }
.drawer__item svg {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

/* Legacy classes kept for backward compat */
.logo-group { display: none; }
.site-header { display: none; }
.header-top { display: none; }
.header-main { display: none; }
.main-nav { display: none; }
.nav-cta { display: none; }
.menu-toggle { display: none; }

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--radius-btn);  /* NZ Post MDC buttons: 10px */
    font-weight: 600;
    font-size: 0.95rem;
    border: 0;
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    text-decoration: none;
    letter-spacing: 0.02em;
}
.btn-primary {
    background: var(--fliway-green);
    color: #fff;
    border-color: var(--fliway-green);
}
.btn-primary:hover {
    background: var(--fliway-green-dark);
    border-color: var(--fliway-green-dark);
    color: #fff;
}
.btn-secondary {
    background: var(--fliway-blue);
    color: #fff;
    border-color: var(--fliway-blue);
}
.btn-secondary:hover {
    background: var(--fliway-blue-light);
    color: #fff;
}
.btn-outline {
    background: transparent;
    color: var(--nzpost-blue);
    border: 2px solid var(--nzpost-blue);
}
.btn-outline:hover {
    background: var(--nzpost-blue);
    color: #fff;
}
.btn-outline.is-highlight {
    background: #90ee90;
    color: var(--nzpost-blue);
}
.btn-outline.is-highlight:hover {
    color: #fff;
}
.btn-white {
    background: #fff;
    color: var(--fliway-blue);
    border-color: #fff;
}
.btn-white:hover {
    background: var(--fliway-blue-pale);
    color: var(--fliway-blue);
}
.btn-sm { padding: 8px 20px; font-size: 0.875rem; }
.btn-lg { padding: 16px 36px; font-size: 1.1rem; }

/* ========== HERO SECTIONS (NZ Post Pattern) ========== */
/* 4-Panel Hero (Freightways style) */
.hero-panels {
    display: flex;
    width: 100%;
    height: 500px;
    overflow: hidden;
}
.hero-panel {
    flex: 1;
    position: relative;
    background-size: cover;
    background-position: center;
    text-decoration: none;
    color: #fff;
    overflow: hidden;
    transition: flex 0.4s ease;
}
.hero-panel:first-child { clip-path: polygon(0 0, 100% 0, calc(100% - 15px) 100%, 0% 100%); }
.hero-panel:last-child { clip-path: polygon(15px 0, 100% 0, 100% 100%, 0% 100%); margin-left: -8px; }
.hero-panel:not(:first-child):not(:last-child) { clip-path: polygon(15px 0, 100% 0, calc(100% - 15px) 100%, 0% 100%); margin-left: -8px; }
.hero-panel:hover { flex: 1.3; }
.hero-panel__overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 140px;
    padding: 24px 24px 32px;
    background: linear-gradient(to top, rgba(4,30,66,0.9) 0%, rgba(4,30,66,0.4) 70%, transparent 100%);
    transition: background 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}
.hero-panel:hover .hero-panel__overlay {
    background: linear-gradient(to top, rgba(4,30,66,0.95) 0%, rgba(4,30,66,0.6) 80%, rgba(4,30,66,0.2) 100%);
}
.hero-panel__overlay h2 {
    font-size: 1.25rem;
    margin-bottom: 4px;
    font-weight: 600;
    color: #fff !important;
}
.hero-panel__overlay p {
    font-size: 0.85rem;
    opacity: 0.85;
    margin: 0;
    color: rgba(255,255,255,0.9);
}

/* Track & Trace bar below hero panels */
.track-bar {
    background: var(--bg-dark);
    color: #fff;
    padding: 40px 0;
    text-align: center;
}
.track-bar h1 { font-size: 1.75rem; margin-bottom: 8px; color: #fff; }
.track-bar .lead { font-size: 1rem; opacity: 0.8; margin-bottom: 24px; color: rgba(255,255,255,0.85); }
.track-bar .track-trace { max-width: 600px; margin: 0 auto; }

/* Split hero (2 panels) */
.hero-split {
    display: flex;
    width: 100%;
    height: 400px;
    overflow: hidden;
}
.hero-split__panel {
    flex: 1;
    position: relative;
    background-image: var(--hero-bg-image-small, var(--hero-bg-image, none));
    background-size: var(--hero-bg-size-mobile, cover);
    background-position: var(--hero-bg-pos-mobile-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-mobile-y, var(--hero-bg-pos-desktop-y, 50%));
    color: #fff;
    display: flex;
    align-items: flex-end;
    text-decoration: none;
    transition: flex 0.4s ease;
}
.hero-split__panel:hover { flex: 1.15; }
/* Use :not(:last-child) instead of :first-child so the divider stays when the
   alert banner is injected as the first DOM child of .hero-split. */
.hero-split__panel:not(:last-child) { border-right: 2px solid #fff; }
.hero-split__label {
    width: 100%;
    padding: 24px 32px;
    background: linear-gradient(to top, rgba(4,30,66,0.9) 0%, transparent 100%);
}
.hero-split__label h2 { font-size: 1.5rem; margin-bottom: 4px; color: #fff !important; }
.hero-split__label p { font-size: 0.9rem; opacity: 0.9; margin: 0; color: rgba(255,255,255,0.9); }

.hero {
    padding: 0;
    background-color: var(--bg-dark);
    background-image: var(--hero-bg-image-small, var(--hero-bg-image, none));
    background-size: var(--hero-bg-size-mobile, cover);
    background-position: var(--hero-bg-pos-mobile-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-mobile-y, var(--hero-bg-pos-desktop-y, 50%));
    background-repeat: no-repeat;
    color: #fff;
    position: relative;
    overflow: hidden;
    min-height: 430px;
    display: flex;
    align-items: center;
}
/* Left-side gradient overlay for text readability (NZ Post pattern) */
.hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; bottom: 0;
    width: var(--hero-overlay-width, 60%);
    background: var(--hero-overlay-gradient, linear-gradient(to right, rgba(4,30,66,0.88) 0%, rgba(4,30,66,0.7) 60%, rgba(4,30,66,0) 100%));
    z-index: 1;
    pointer-events: none;
}
.hero::after {
    content: none; /* Remove old overlay */
}
.hero .container {
    /* Flex item needs an explicit width so the content inside respects
       `.container`'s max-width/margin-auto (without it the flex item
       shrinks to its content width and auto-margins push it off-centre). */
    width: 100%;
    position: relative;
    z-index: 2;
    padding-top: 72px;
    padding-bottom: 72px;
}
.hero h1 {
    color: #fff;
    font-size: 2.5rem;
    max-width: 580px;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 1rem;
}
.hero .overline { color:rgba(255,255,255,0.87);}
.hero .lead {
    color: rgba(255,255,255,0.87);
    max-width: 520px;
    font-size: 1.1rem;
    line-height: 1.6;
}
.hero-actions {
    display: flex;
    gap: 12px;
    margin-top: 28px;
    flex-wrap: wrap;
}
/* NZ Post CTA button style: white outline on dark bg */
.hero .btn-white,
.hero .btn-outline {
    background: transparent;
    color: #fff;
    border: 2px solid #fff;
    border-radius: var(--radius-btn);
}
.hero .btn-white:hover,
.hero .btn-outline:hover {
    background: #fff;
    color: var(--nzpost-blue);
}
/* NZ Post primary CTA in hero: filled navy blue */
.hero .btn-primary {
    background: var(--nzpost-blue);
    border: 2px solid var(--nzpost-blue);
}
.hero .btn-primary:hover {
    background: #002080;
    border-color: #002080;
}
.hero-image {
    position: absolute;
    right: -50px;
    top: 50%;
    transform: translateY(-50%);
    width: 45%;
    opacity: 0.15;
}

/* Homepage hero — taller, with Track & Trace form */
.hero-home {
    min-height: 480px;
    background-position: center;
}

/* Contact page — no hero image, white bg, centered text (NZ Post pattern) */
.hero-minimal {
    background-image: none !important;
    background-color: var(--bg-white);
    min-height: auto;
    padding: 0;
    color: var(--text-primary);
}
.hero-minimal::before {
    display: none;
}
.hero-minimal .container {
    padding-top: 48px;
    padding-bottom: 24px;
    text-align: center;
}
.hero-minimal h1 {
    color: var(--fliway-blue);
    max-width: none;
    font-size: 2.5rem;
}
.hero-minimal .lead {
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}
.hero-minimal .hero-actions {
    justify-content: center;
}

/* ========== SECTIONS ========== */
.section { padding: 80px 0; }
.section-alt { background: var(--bg-light); }
.section-dark {
    background: var(--bg-dark);
    color: #fff;
}
.section-dark h2, .section-dark h3 { color: #fff; }
.section-dark p { color: rgba(255,255,255,0.7); }

/* ========== SEARCH PAGE ========== */
.search-form-panel {
    max-width: 760px;
    margin-top: 1.5rem;
    padding: 1.5rem;
    border: 1px solid var(--border);
    background: linear-gradient(180deg, #fff 0%, #f9fbfd 100%);
    box-shadow: var(--shadow);
}
.search-form-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.875rem;
    align-items: center;
}
.search-form-row .btn {
    justify-content: center;
    min-width: 120px;
}

.search-results {
    margin-top: 2rem;
}
.search-results-summary {
    margin-bottom: 1rem;
    color: var(--text-primary);
}
.search-results-list {
    display: grid;
    gap: 0.9rem;
}

.search-result-card {
    padding: 1rem 1.25rem;
    border: 1px solid var(--border);
    border-left: 4px solid var(--fliway-green);
    background: #fff;
    transition: var(--transition);
}
.search-result-card:hover {
    border-color: #cdd5dc;
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}
.search-result-card.is-collapsed {
    display: none;
}
.search-result-card__heading {
    margin-top: 0.1rem;
    margin-bottom: 0.15rem;
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    align-items: start;
    column-gap: 0.5rem;
    min-width: 0;
}
.search-result-card__text {
    min-width: 0;
}
.search-result-card__type {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin: 0;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    padding: 0;
    font-size: 0.62rem;
    line-height: 1;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border: 1px solid transparent;
}
.search-result-card__type-icon {
    width: 42px;
    height: 42px;
    display: block;
}
.search-result-card__type--page {
}
.search-result-card__type--pdf {
    transform: scale(1.28);
    transform-origin: center;
}
.search-result-card__title {
    margin: 0;
    font-size: .95rem;
    line-height: 1.15;
}
.search-result-card__url {
    display: block;
    margin-top: 0.1rem;
    min-width: 0;
    max-width: 100%;
    font-size: 0.82rem;
    color: #5f6d79;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.search-result-card__url:hover {
    color: var(--fliway-blue);
    text-decoration: underline;
}
.search-result-card__snippet {
    margin: 0.6rem 0 0;
}
.search-result-card mark {
    background: rgba(20, 151, 212, 0.18);
    color: var(--fliway-blue);
    padding: 0 0.1em;
    font-weight: 600;
}

.search-empty-state {
    max-width: 760px;
    padding: 1rem 1.25rem;
    border-left: 4px solid var(--fliway-blue-light);
    background: var(--fliway-blue-pale);
}
.search-empty-state p:last-child {
    margin-bottom: 0;
}

.search-results-actions {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
}

@media (max-width: 768px) {
    .search-form-panel {
        padding: 1rem;
    }

    .search-form-row {
        grid-template-columns: 1fr;
    }

    .search-form-row .btn {
        width: 100%;
    }

    .search-result-card__heading {
        grid-template-columns: 32px minmax(0, 1fr);
    }

    .search-result-card__url {
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
    }
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 48px;
}
.section-header .overline {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--fliway-green);
    margin-bottom: 12px;
}

/* ========== CARDS (NZ Post DS: clickable cards, rows of 3) ========== */
.card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);  /* NZ Post: cards in rows of 3 */
    gap: 24px;
}
.card-grid.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid.grid-4 { grid-template-columns: repeat(2, 1fr); }  /* 4 items: 2x2 */
.card-grid.grid-5 { grid-template-columns: repeat(5, 1fr); }
.card-grid.card-grid-centered {
    grid-template-columns: repeat(auto-fit, minmax(0, 45%)); /* 1-2 cards: keep card width, center under header */
    justify-content: center;
}
.card {
    background: var(--bg-white);
    border: none;                    /* NZ Post cards: no border */
    border-radius: 0;               /* NZ Post cards: 0px radius */
    padding: 32px 24px;
    transition: var(--transition);
    box-shadow: none;                /* NZ Post cards: no shadow at rest */
    border-bottom: 3px solid var(--nzpost-blue);
    cursor: pointer;                 /* NZ Post: clickable cards */
    position: relative;
}
.card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.10);
    border-bottom-color: var(--fliway-green);
    transform: translateY(-2px);
}
.card-icon {
    width: 64px;
    height: 64px;
    margin-bottom: 16px;
}
.card-icon img {
    width: 64px;
    height: 64px;
}
.card-icon svg {
    width: 64px;
    height: 64px;
}
.card h3 a { color: var(--fliway-blue); }
.card h3 a:hover { color: var(--fliway-green); }

/* ========== NEWS ARTICLES ========== */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
    margin-top: 48px;
}
.news-card {
    background: var(--bg-white);
    box-shadow: var(--shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.news-card-body {
    padding: 32px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.news-card h3 {
    color: var(--fliway-blue);
    margin-bottom: 12px;
    font-size: 1.25rem;
}
.news-card h3 a {
    color: inherit;
}
.news-card p {
    flex: 1;
    line-height: 1.7;
    margin-bottom: 16px;
}
.news-card .news-date {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

/* ========== STATS BAR ========== */
.stats-bar {
    background: var(--nzpost-blue);
    padding: 48px 0;
    color: #fff;
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 32px;
    text-align: center;
}
.stat-item .stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: #fff;
    display: block;
}
.stat-item .stat-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.7);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ========== LOGO STRIP ========== */
.logo-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 48px;
    flex-wrap: wrap;
    opacity: 0.5;
    filter: grayscale(100%);
}
.logo-strip img { height: 32px; }

/* ========== TESTIMONIAL ========== */
.testimonial {
    background: var(--bg-light);
    padding: 80px 0;
    text-align: center;
}
.testimonial blockquote {
    font-size: 1.25rem;
    font-style: italic;
    color: var(--text-primary);
    line-height: 1.8;
    max-width: 800px;
    margin: 0 auto 24px;
    padding: 0 24px;
    border-left: 4px solid var(--nzpost-blue);
    padding-left: 32px;
    text-align: left;
}
.testimonial cite {
    display: block;
    font-style: normal;
    font-weight: 600;
    color: var(--fliway-blue);
    max-width: 800px;
    margin: 0 auto;
    padding-left: 36px;
    text-align: left;
}

/* ========== FEATURE SECTION ========== */
.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
    margin-bottom: 80px;
}
.feature-row.reverse, .feature-row--reverse { direction: rtl; }
.feature-row.reverse > *, .feature-row--reverse > * { direction: ltr; }
.feature-content h3 { font-size: 1.75rem; }
.feature-content ul {
    list-style: none;
    margin-top: 16px;
}
.feature-content li {
    padding: 8px 0 8px 28px;
    position: relative;
    color: var(--text-secondary);
}
.feature-content li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--accent-green);
    font-weight: 700;
}
/* paragraph variant — replaces .feature-bullets visual layout */
.feature-paragraph { font-size: 1rem; line-height: 1.7; color: var(--text-secondary, #444); margin-top: 16px; max-width: 60ch; }
.feature-paragraph strong { color: var(--fliway-blue, #041E42); }

.feature-image {
    background: var(--bg-light);
    border-radius: 0;               /* NZ Post: 0px radius */
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 280px;
    color: var(--text-light);
    font-size: 0.9rem;
    overflow: hidden;
    /* Subtle pattern for placeholder images */
    background-image: linear-gradient(135deg, var(--bg-light) 25%, transparent 25%),
                      linear-gradient(225deg, var(--bg-light) 25%, transparent 25%),
                      linear-gradient(315deg, var(--bg-light) 25%, transparent 25%),
                      linear-gradient(45deg, var(--bg-light) 25%, transparent 25%);
    background-size: 20px 20px;
    background-color: #E8ECF0;
}
.feature-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
}
.feature-image video {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: contain;
    background: #000;
}

/* ========== CTA BANNER ========== */
.cta-banner {
    background: var(--fliway-green-dark);
    padding: 64px 0;
    margin-top: 48px;
    margin-bottom: 48px;
    text-align: center;
    color: #fff;
}
.cta-banner h2 { color: #fff; font-size: 2.5rem; }
.cta-banner p { color: rgba(255,255,255,0.85); font-size: 1.2rem; }
.cta-banner .btn { margin-top: 24px; }
.cta-banner .btn-outline { color: #fff; border-color: #fff; }
.cta-banner .stats-grid {
    margin-top: 56px;
    padding-top: 40px;
    border-top: 1px solid rgba(255,255,255,0.25);
}
.cta-banner .stat-item .stat-number { color: #fff; }
.cta-banner .stat-item .stat-label { color: rgba(255,255,255,0.85); }
/* ========== FOOTER (NZ Post DS: dark navy, generous spacing) ========== */
.site-footer {
    background: var(--bg-dark);
    color: rgba(255,255,255,0.7);
    padding: 80px 0 24px;           /* NZ Post DS: generous top padding */
}
.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-bottom: 48px;
}
.footer-brand .logo-group { margin-bottom: 16px; }
.footer-brand .logo { margin-bottom: 0; display: inline-flex; }
.footer-brand .logo img { height: 40px; filter: brightness(0) invert(1); }
.footer-brand .scs-logo { height: 36px; filter: brightness(0) invert(1); border-left-color: rgba(255,255,255,0.3); }
.footer-brand p { font-size: 0.9rem; max-width: 300px; }
.footer-col h4 {
    color: #fff;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 16px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 8px; }
.footer-col a {
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
}
.footer-col a:hover { color: #fff; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
}
.footer-bottom a { color: rgba(255,255,255,0.5); }
.footer-bottom__left, .footer-bottom__right { display: flex; align-items: center; gap: 12px; }
.footer-bottom__right { text-align: right; }
.footer-bottom__sep { color: rgba(255,255,255,0.3); }
.nzpost-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
}

/* ========== TRACKING FORM ========== */
.track-label {
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
}
.track-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 500px;
}
.track-input {
    display: flex;
    gap: 8px;
}
.track-input__field {
    flex: 1;
    min-width: 0;
}

.track-input input[type="text"] {
    width: 100%;
    box-sizing: border-box;
    padding: 14px 20px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: var(--radius);
    font-size: 1rem;
    background: rgba(255,255,255,0.1);
    color: #fff;
}
.track-input input[type="text"]::placeholder { color: rgba(255,255,255,0.5); }
.track-input input[type="text"]:focus {
    outline: none;
    border-color: #fff;
    background: rgba(255,255,255,0.15);
}

.track-input__error {
    margin: 6px 0 0;
    font-size: 0.82rem;
    color: #b42424;
    min-height: 1.1em;
}

/* Track form on light backgrounds (outside .track-bar) */
.section .track-trace {
    max-width: 600px;
    margin: 0 auto;
}
.section .track-form {
    max-width: 600px;
    margin: 0 auto;
}
.section .track-label {
    color: var(--fliway-blue);
}
.section .track-input input[type="text"] {
    background: #fff;
    color: var(--fliway-blue);
    border: 2px solid var(--fliway-blue);
}
.section .track-input input[type="text"]::placeholder {
    color: rgba(4, 30, 66, 0.45);
}
.section .track-input input[type="text"]:focus {
    border-color: var(--nzpost-blue);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(0, 51, 160, 0.15);
}

/* ========== FORM ELEMENTS (NZ Post DS) ========== */
.form-group { margin-bottom: 24px; }
.form-group label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--fliway-blue);
    margin-bottom: 8px;
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.form-group textarea,
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border);
    border-radius: 0;               /* NZ Post DS: 0px radius for inputs */
    font-size: 1rem;
    font-family: inherit;
    color: var(--text-primary);
    background: var(--bg-white);
    transition: var(--transition);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
input[type="text"]:focus,
input[type="email"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--nzpost-blue);
    box-shadow: 0 0 0 3px rgba(0, 51, 160, 0.15);
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}
.form-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
/* Radio / checkbox groups */
.radio-group, .checkbox-group {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.radio-group label, .checkbox-group label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 400;
    cursor: pointer;
}
.radio-group input[type="radio"],
.checkbox-group input[type="checkbox"] {
    width: auto;
    accent-color: var(--nzpost-blue);
}

/* ========== SCHEDULE FORM ========== */
.schedule-location-picker {
    position: relative;
}

.address-search-controls {
    display: flex;
    gap: 0.875rem;
    align-items: stretch;
}

.address-search-picker {
    position: relative;
    flex: 1;
}

.address-search-submit {
    min-width: 120px;
    justify-content: center;
    align-self: stretch;
}

.address-search-result {
    margin-top: 1rem;
    padding: 1rem 1.25rem;
    border: 1px solid var(--border);
    background: linear-gradient(180deg, #fff 0%, #f9fbfd 100%);
    box-shadow: var(--shadow);
}

.address-search-result__title {
    margin: 0 0 0.75rem;
    font-size: 1rem;
    color: var(--fliway-blue);
}

.address-search-result__list {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 1rem;
}

.address-search-result__item dt {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-light);
}

.address-search-result__item dd {
    margin: 0.25rem 0 0;
    font-weight: 600;
    color: var(--text-primary);
    word-break: break-word;
}

.schedule-suggestions {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 20;
    margin: 0;
    padding: 6px 0;
    list-style: none;
    border: 1px solid var(--border);
    background: var(--bg-white);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    max-height: 220px;
    overflow-y: auto;
}

.schedule-suggestion {
    width: 100%;
    border: 0;
    background: transparent;
    text-align: left;
    padding: 10px 12px;
    color: var(--text-primary);
    cursor: pointer;
}

.schedule-suggestion:hover,
.schedule-suggestion:focus-visible {
    background: #eef4ff;
    outline: none;
}

.schedule-field-error,
.schedule-submit-error {
    min-height: 1.1em;
    margin: 6px 0 0;
    font-size: 0.82rem;
    color: #b42424;
}

.schedule-help-text {
    display: block;
    margin-top: 6px;
    color: var(--text-light);
    font-size: 0.82rem;
}

.schedule-result {
    margin: 14px 0 0;
    color: var(--fliway-blue);
    font-weight: 600;
}

@media (max-width: 768px) {
    .schedule-form .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .address-search-controls {
        flex-direction: column;
    }

    .address-search-submit {
        width: 100%;
    }

    .address-search-result__list {
        grid-template-columns: 1fr;
    }
}

/* ========== BREADCRUMB ========== */
.breadcrumb {
    padding: 16px 0;
    font-size: 0.85rem;
    color: var(--text-light);
}

/* ========== TABLES (NZ Post DS) ========== */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}
.data-table th {
    background: var(--fliway-blue);
    color: #fff;
    padding: 12px 16px;
    text-align: left;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
    color: var(--text-primary);
}
.data-table tbody tr:hover {
    background: var(--fliway-blue-pale);
}
.data-table tbody tr:nth-child(even) {
    background: var(--bg-light);
}

/* ========== ALERT/INFO BOXES ========== */
.info-box {
    padding: 20px 24px;
    background: var(--fliway-blue-pale);
    border-left: 4px solid var(--nzpost-blue);
    margin-bottom: 24px;
    border-radius: 0;
}
.info-box p { color: var(--text-primary); margin-bottom: 0; }
.info-box strong { color: var(--fliway-blue); }
.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--fliway-blue); }
.breadcrumb span { margin: 0 8px; }

/* ========== CONTACT US MODAL ========== */
.contact-modal-scrim {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}
.contact-modal-scrim--active {
    display: flex;
}
.contact-modal {
    background: #fff;
    border-radius: 12px;
    width: 90%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.25s ease;
}
@keyframes modalSlideIn {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
.contact-modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 28px 8px;
    border-bottom: 1px solid #eee;
}
.contact-modal__header h2 {
    font-size: 1rem;
    color: var(--fliway-blue);
    margin: 0;
}
.contact-modal__close {
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: #666;
    padding: 2px 6px;
    border-radius: 4px;
    line-height: 1;
}
.contact-modal__close:hover { background: #f0f0f0; }
.contact-modal__form {
    padding: 10px 28px 12px;
}
.contact-modal__field {
    margin-bottom: 6px;
}
.contact-modal__field label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    color: #333;
    margin-bottom: 3px;
}
.contact-modal__field input,
.contact-modal__field select,
.contact-modal__field textarea {
    width: 100%;
    padding: 4px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 0.85rem;
    font-family: inherit;
    transition: border-color 0.2s;
    box-sizing: border-box;
}
.contact-modal__field textarea {
    min-height: 52px;
}
.contact-modal__field input:focus,
.contact-modal__field select:focus,
.contact-modal__field textarea:focus {
    outline: none;
    border-color: var(--nzpost-blue);
    box-shadow: 0 0 0 3px rgba(0,51,160,0.1);
}
.contact-modal__submit {
    width: 100%;
    margin-top: 0;
    padding: 8px 16px;
    font-size: 0.9rem;
}
.contact-modal__success {
    text-align: center;
    padding: 40px 28px;
    color: var(--fliway-blue);
}
.contact-modal__success h3 {
    margin-bottom: 8px;
}
@media (max-width: 600px) {
    .contact-modal__header { padding: 8px 20px 6px; }
    .contact-modal__form { padding: 8px 20px 10px; }
    .contact-modal__field { margin-bottom: 4px; }
    .contact-modal__field label { margin-bottom: 2px; }
    .contact-modal__field textarea { min-height: 44px; }
}

/* ========== MOBILE RESPONSIVE ========== */
@media (max-width: 768px) {
    /* Alert banner: normal flow on mobile instead of overlay */
    [data-hero] > .alert-banner {
        position: relative;
    }
    .alert-banner {
        padding: 8px 12px;
        gap: 6px;
    }
    .alert-banner__dismiss {
        padding: 2px;
        margin-left: 0;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }

    /* Hero: shorter, tighter on mobile; switch to block so the alert banner
       (position: relative on mobile) stacks above the container instead of
       sitting beside it as a flex row item. */
    .hero { display: block; min-height: auto; padding: 0; background-image: var(--hero-bg-image-small, var(--hero-bg-image, none));}
    .hero .container { padding-top: 48px; padding-bottom: 48px; }
    .hero h1 { font-size: 1.75rem; }
    .hero .lead { font-size: 0.95rem; }
    [data-hero] > .alert-banner { width: 100%; }
    .hero-actions { flex-direction: column; }
    .hero-actions .btn { width: 100%; text-align: center; }

    /* 4-panel hero stacks to 2x2 grid on mobile */
    .hero-panels { flex-wrap: wrap; height: auto; }
    .hero-panel {
        flex: 0 0 50%;
        height: 200px;
        clip-path: none !important;
        margin-left: 0 !important;
    }
    .hero-panel:hover { flex: 0 0 50%; }
    .hero-panel__overlay h2 { font-size: 1rem; }
    .hero-panel__overlay p { font-size: 0.75rem; }
    .track-bar h1 { font-size: 1.25rem; }

    /* Split hero stacks vertically on mobile */
    .hero-split { flex-direction: column; height: auto; }
    .hero-split__panel { height: 220px; }
    .hero-split__panel:first-child { border-right: none; border-bottom: 2px solid #fff; }

    .section { padding: 48px 0; }
    .feature-row { grid-template-columns: 1fr; gap: 32px; }
    .feature-row.reverse { direction: ltr; }

    /* Footer: accordion on mobile (NZ Post pattern) */
    .footer-grid { grid-template-columns: 1fr; gap: 0; margin-bottom: 24px; }
    .footer-col { border-bottom: 1px solid rgba(255,255,255,0.15); }
    .footer-col h4 {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 18px 0;
        margin-bottom: 0;
        cursor: pointer;
    }
    .footer-col h4::after {
        content: '';
        width: 10px; height: 10px;
        border-right: 2px solid rgba(255,255,255,0.6);
        border-bottom: 2px solid rgba(255,255,255,0.6);
        transform: rotate(45deg);
        transition: transform 0.25s ease;
        flex-shrink: 0;
    }
    .footer-col.footer-col--open h4::after {
        transform: rotate(-135deg);
    }
    .footer-col ul {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
        padding-bottom: 0;
    }
    .footer-col.footer-col--open ul {
        max-height: 300px;
        padding-bottom: 16px;
    }

    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .card-grid { grid-template-columns: 1fr; }
    .card-grid.grid-4 { grid-template-columns: 1fr; }
    .card-grid.grid-5 { grid-template-columns: 1fr; }
    .form-row { grid-template-columns: 1fr; }
    .form-grid-3 { grid-template-columns: 1fr; }

    /* Navigation mobile adjustments (NZ Post pattern) */
    .navigation__hamburger { display: flex; align-items: center; }
    .navigation__top-items { display: none; }
    .navigation__end-actions span { display: none; }
    .navigation__end-actions { gap: 0; }
    .navigation__action-btn { margin-left: 0; padding: 8px; }
    .navigation__logo-group { margin-right: auto; }

    /* Hide 2nd-level tab bar and breadcrumb on mobile — nav lives in drawer only */
    .navigation__bottom { display: none; }
    .breadcrumb { display: none; }

    /* Header layout on mobile */
    .header-main .container { position: relative; }
}

@media (max-width: 480px) {
    .footer-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .track-form { flex-direction: column; }
}

/* Sitemap page */
.sitemap-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 40px; }
.sitemap-section h3 { font-size: 1rem; font-weight: 600; margin-bottom: 12px; color: var(--fliway-blue); }
.sitemap-section ul { list-style: none; }
.sitemap-section li { margin-bottom: 8px; }
.sitemap-section a { color: #444; font-size: 0.9rem; }
.sitemap-section a:hover { color: var(--nzpost-blue); }
@media (max-width: 768px) { .sitemap-grid { grid-template-columns: 1fr; gap: 32px; } }

/* Terms page */
.terms-content h2 { font-size: 1.25rem; margin-top: 48px; margin-bottom: 16px; padding-bottom: 8px; border-bottom: 2px solid var(--nzpost-blue); color: var(--fliway-blue); }
.terms-content h3 { font-size: 1.05rem; margin-top: 32px; margin-bottom: 10px; color: var(--fliway-blue); }
.terms-content p { margin-bottom: 16px; line-height: 1.7; color: #444; }
.terms-content ul { margin-bottom: 16px; padding-left: 24px; }
.terms-content li { margin-bottom: 8px; line-height: 1.7; color: #444; }
.terms-content > ul:first-of-type { background: var(--bg-light); padding: 20px 20px 20px 40px; border-radius: 8px; margin-bottom: 32px; }
.terms-content > ul:first-of-type li { margin-bottom: 4px; }
.terms-content > ul:first-of-type a { color: var(--nzpost-blue); font-weight: 500; }

/* ========== HERO ASPECT RATIO ==========
   Homepage carousel (.scroll-hero) = 2.4:1 cinematic frame.
   Every other page hero (.hero, .hero-split) = 6.3:1 slim banner.
   Narrow viewports fall back to a min-height so content isn't clipped.    */
.scroll-hero {
    aspect-ratio: 2.4 / 1;
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
}

@media (min-width: 641px) {
    .hero,
    .hero-split__panel {
        background-image: var(--hero-bg-image-medium, var(--hero-bg-image, none));
    }

    .hero,
    .hero-split{
        aspect-ratio: auto;
        min-height: 400px !important;
    }
}

@media (min-width: 1025px) {
    .hero,
    .hero-split__panel {
        background-image: var(--hero-bg-image-large, var(--hero-bg-image, none));
        background-size: var(--hero-bg-size-desktop, cover);
        background-position: var(--hero-bg-pos-desktop-x, 50%) var(--hero-bg-pos-desktop-y, 50%);
        
    }

    .hero {
        background-image: linear-gradient(to right, rgba(4,30,66,1) 0%, rgba(4,30,66,0.85) 16%, rgba(4,30,66,0.45) 32%, rgba(4,30,66,0) 46%), var(--hero-bg-image-large, var(--hero-bg-image, none));
        background-size: var(--hero-bg-size-desktop, cover), var(--hero-bg-size-desktop, cover);
        background-position: var(--hero-bg-pos-desktop-x, 50%) var(--hero-bg-pos-desktop-y, 50%), var(--hero-bg-pos-desktop-x, 50%) var(--hero-bg-pos-desktop-y, 50%);
        background-repeat: no-repeat;
        --hero-overlay-width: 100%;
        --hero-overlay-gradient: linear-gradient(to right, rgba(4,30,66,0.62) 0%, rgba(4,30,66,0.44) 30%, rgba(4,30,66,0.24) 52%, rgba(4,30,66,0.08) 70%, rgba(4,30,66,0) 84%);
    }
}

@media (min-width: 1366px) {
    .hero,
    .hero-split__panel {
        background-size: var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover));
        background-position: var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%));
    }

    .hero {
        background-image: linear-gradient(to right, rgba(4,30,66,1) 0%, rgba(4,30,66,0.84) 14%, rgba(4,30,66,0.42) 29%, rgba(4,30,66,0) 42%), var(--hero-bg-image-large, var(--hero-bg-image, none));
        background-size: var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover)), var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover));
        background-position: var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%)), var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%));
        background-repeat: no-repeat;
        --hero-overlay-width: 100%;
        --hero-overlay-gradient: linear-gradient(to right, rgba(4,30,66,0.56) 0%, rgba(4,30,66,0.38) 28%, rgba(4,30,66,0.2) 50%, rgba(4,30,66,0.06) 68%, rgba(4,30,66,0) 82%);
    }

    
    .hero,
    .hero-split {
        aspect-ratio: 4 / 1;
        height: auto !important;
        max-height: none !important;
        min-height: 0 !important;
    }
}

@media (min-width: 1920px) {
    .hero,
    .hero-split__panel {
        background-size: var(--hero-bg-size-desktop-large, var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover)));
        background-position: var(--hero-bg-pos-desktop-large-x, var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%))) var(--hero-bg-pos-desktop-large-y, var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%)));
    }

    .hero {
        background-image: linear-gradient(to right, rgba(4,30,66,1) 0%, rgba(4,30,66,0.82) 13%, rgba(4,30,66,0.38) 27%, rgba(4,30,66,0) 40%), var(--hero-bg-image, none);
        background-size: var(--hero-bg-size-desktop-large, var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover))), var(--hero-bg-size-desktop-large, var(--hero-bg-size-desktop-medium, var(--hero-bg-size-desktop, cover)));
        background-position: var(--hero-bg-pos-desktop-large-x, var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%))) var(--hero-bg-pos-desktop-large-y, var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%))), var(--hero-bg-pos-desktop-large-x, var(--hero-bg-pos-desktop-medium-x, var(--hero-bg-pos-desktop-x, 50%))) var(--hero-bg-pos-desktop-large-y, var(--hero-bg-pos-desktop-medium-y, var(--hero-bg-pos-desktop-y, 50%)));
        background-repeat: no-repeat;
        --hero-overlay-width: 100%;
        --hero-overlay-gradient: linear-gradient(to right, rgba(4,30,66,0.5) 0%, rgba(4,30,66,0.34) 26%, rgba(4,30,66,0.18) 48%, rgba(4,30,66,0.05) 66%, rgba(4,30,66,0) 80%);
    }
}

/* Homepage hero carousel */
.scroll-hero {
    position: relative;
    width: 100%;
}
.scroll-hero__sticky {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: #041E42;
}
.scroll-hero__slides {
    position: absolute;
    inset: 0;
}
.scroll-hero__slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity .9s ease;
    background-size: var(--hero-bg-size-mobile, var(--hero-bg-size-desktop, cover));
    background-position: var(--hero-bg-pos-mobile-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-mobile-y, var(--hero-bg-pos-desktop-y, 50%));
    background-image: var(--hero-bg-image-small, var(--hero-bg-image, none));
}
.scroll-hero__slide.active {
    opacity: 1;
}

@media (min-width: 641px) {
    .scroll-hero__slide {
        background-size: var(--hero-bg-size-mobile, var(--hero-bg-size-desktop, cover));
        background-position: var(--hero-bg-pos-mobile-x, var(--hero-bg-pos-desktop-x, 50%)) var(--hero-bg-pos-mobile-y, var(--hero-bg-pos-desktop-y, 50%));
        background-image: var(--hero-bg-image-medium, var(--hero-bg-image, none));
    }
}

@media (min-width: 1025px) {
    .scroll-hero__slide {
        background-size: var(--hero-bg-size-desktop, cover);
        background-position: var(--hero-bg-pos-desktop-x, 50%) var(--hero-bg-pos-desktop-y, 50%);
        background-image: var(--hero-bg-image-large, var(--hero-bg-image, none));
    }
}

@media (min-width: 1920px) {
    .hero-split__panel,
    .scroll-hero__slide {
        background-image: var(--hero-bg-image, none);
    }
}

.scroll-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    background: linear-gradient(to right, rgba(4,30,66,0.88) 0%, rgba(4,30,66,0.65) 40%, rgba(4,30,66,0.15) 75%, transparent 100%);
    display: flex;
    align-items: center;
}
.scroll-hero__container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 24px;
}
.scroll-hero__copy-stack {
    display: grid;
    max-width: 720px;
    width: 100%;
    margin-top: 32px;
}
.scroll-hero__copy {
    grid-column: 1;
    grid-row: 1;
    opacity: 0;
    pointer-events: none;
    transition: opacity .7s ease, transform .7s ease;
    transform: translateY(12px);
}
.scroll-hero__copy.active {
    opacity: 1;
    pointer-events: auto;
    transform: none;
}
.scroll-hero__overline {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: rgba(255,255,255,.55);
    margin-bottom: 14px;
}
.scroll-hero__title {
    font-size: clamp(28px, 4vw, 46px);
    font-weight: 700;
    line-height: 1.1;
    color: #fff;
    letter-spacing: -0.5px;
    margin: 0 0 18px;
}
.scroll-hero__desc {
    font-size: 16px;
    line-height: 1.6;
    color: rgba(255,255,255,.8);
    margin: 0 0 28px;
    max-width: 600px;
}
.scroll-hero__desc:last-of-type { margin-bottom: 22px; }
.scroll-hero__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    color: #041E42;
    font-size: 14px;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 6px;
    text-decoration: none;
    transition: transform .2s, box-shadow .2s;
}
.scroll-hero__cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0,0,0,.25);
}

/* Ghost variant for secondary CTAs in the multi-button hero row */
.scroll-hero__cta--ghost {
    background: transparent; color: #fff;
    border: 1.5px solid rgba(255,255,255,.6);
}
.scroll-hero__cta--ghost:hover { background: rgba(255,255,255,.1); border-color: #fff; }
/* Wrap multiple CTAs on a single line with consistent gap */
.scroll-hero__cta-row {
    display: flex; flex-wrap: wrap; gap: 12px;
}

.scroll-hero__brand-track {
    max-width: 1152px;
    margin: 0 auto;
    box-sizing: border-box;
    background: #fff;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 32px;
}
.scroll-hero__logos {
    display: flex;
    align-items: center;
    gap: 28px;
    flex: 0 0 auto;
    background: transparent;
    border: none;
}
.scroll-hero__logo-btn {
    display: inline-flex;
    align-items: center;
    background: none;
    border: 0;
    padding: 4px 0;
    cursor: pointer;
    text-decoration: none;
    opacity: .55;
    filter: saturate(.6);
    transition: opacity .4s ease, filter .4s ease, transform .2s ease;
}
.scroll-hero__logo-btn img {
    max-height: 38px;
    width: auto;
    object-fit: contain;
    display: block;
}
.scroll-hero__logo-btn:hover {
    transform: translateY(-1px);
}
.scroll-hero__logos[data-active="0"] .scroll-hero__logo-btn {
    opacity: .88;
    filter: saturate(1);
}
.scroll-hero__logo-btn.active {
    opacity: 1;
    filter: saturate(1);
}
.scroll-hero__logo-btn.dim {
    opacity: .28;
    filter: saturate(.35);
}

.track-panel {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    padding: 0;
    background: transparent;
}
.track-panel .track-form {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
}
.track-panel .track-label {
    color: #041E42;
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
    white-space: nowrap;
}
.track-panel .track-input {
    display: flex;
    gap: 0;
    flex: 1;
    min-width: 0;
    position: relative;
}
.track-panel .track-input__field {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
}
.track-panel .track-input input[type="text"] {
    background: #f8f9fa;
    color: #041E42;
    border: 2px solid #d1d5db;
    border-right: none;
    border-radius: 6px 0 0 6px;
    padding: 10px 16px;
    flex: 1;
    width: 100%;
    font-size: 14px;
}
.track-panel .track-input input[type="text"]::placeholder {
    color: #9ca3af;
}
.track-panel .track-input input[type="text"]:focus {
    border-color: #1497D4;
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(20,151,212,.15);
}
.track-panel .track-input .btn {
    border-radius: 0 6px 6px 0;
    white-space: nowrap;
}

.track-panel .track-input__error {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    margin-top: 4px;
}

@media (min-width: 961px) and (max-width: 1280px) {
    .track-panel .track-form {
        flex-direction: column;
        align-items: flex-start;
        max-width: none;
        margin: 0;
        gap: 8px;
    }
    .track-panel .track-input {
        width: 100%;
    }
}

@media (max-width: 960px) {
    .scroll-hero {
        aspect-ratio: auto;
        min-height: 480px !important;
    }
    .scroll-hero__brand-track {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        padding: 16px;
    }
    .scroll-hero__logos {
        justify-content: center;
        gap: 24px;
    }
    .scroll-hero__logo-btn img {
        max-height: 30px;
    }
    .track-panel .track-form {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    .track-panel .track-label {
        white-space: normal;
    }
}

@media (max-width: 600px) {
    .scroll-hero { min-height: 720px !important; }
    .scroll-hero__overlay {
        padding: 0 24px;
    }
    .scroll-hero__desc {
        font-size: 14px;
    }
}

/* ========== PLACEHOLDER IMAGE ==========
   Render placeholder.svg centered at 50% of available height, preserving
   aspect ratio (no distortion). The remaining space is padded out with a
   neutral background.                                                        */

/* <img> placeholder — both the site-wide placeholder.svg and the per-slot
   placeholders/<slug>-N.svg are matched by the "placeholder" substring. */
img[src*="placeholder"] {
    height: 50% !important;
    width: auto !important;
    max-width: 60%;
    max-height: 50%;
    object-fit: contain !important;
    display: block;
    margin: auto;
}

/* When used as an inline background-image on hero/feature sections */
section[style*="placeholder"],
div[style*="placeholder"],
a[style*="placeholder"] {
    background-size: auto 50% !important;
    background-repeat: no-repeat !important;
    background-position: center center !important;
    background-color: #E8ECF0;
}

/* ===== CONTACTS AND LOCATIONS (circular-map cards, used on contact-support pages) ===== */
.branch-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;   /* fixed 2 columns so contact text stays readable on wide screens */
    gap: 32px;
    margin-top: 32px;
}
.branch-card {
    display: flex;
    gap: 28px;
    padding: 28px;
    background: var(--bg-white);
    box-shadow: var(--shadow);
    align-items: flex-start;
    text-align: left;
}
.branch-map-wrap {
    flex-shrink: 0;
    width: 160px;
    height: 160px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.branch-map-wrap iframe {
    width: 300px;
    height: 300px;
    margin-top: -70px;
    margin-left: -70px;
    border: 0;
    pointer-events: none;
}
.branch-map-wrap:hover iframe {
    pointer-events: auto;
}
.branch-details {
    flex: 1;
    min-width: 0;
}
.branch-details h3 {
    margin: 0 0 6px;
    font-size: 1.25rem;
}
.branch-details .branch-role {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}
.branch-details .branch-contact {
    font-size: 0.95rem;
    margin: 0;
    line-height: 1.8;
}
.branch-details .branch-contact a { color: var(--link-blue); }
.branch-details .branch-contact strong { color: var(--fliway-blue); }
.branch-map-link {
    display: inline-block;
    margin-top: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--nzpost-blue);
}
.branch-map-link:hover { color: var(--nzpost-red); }
/* Simpler cards used for After Hours / Special Projects (no map) */
.contact-simple-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 32px;
}
.contact-simple-card {
    padding: 28px;
    background: var(--bg-white);
    box-shadow: var(--shadow);
}
.contact-simple-card h3 {
    margin: 0 0 16px;
    font-size: 1.1rem;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}
.contact-simple-card p {
    margin: 0;
    line-height: 1.9;
    font-size: 0.95rem;
}
.contact-simple-card a { color: var(--link-blue); }
@media (max-width: 600px) {
    .branch-grid { grid-template-columns: 1fr; }
    .branch-card { flex-direction: column; align-items: center; text-align: center; }
}


.leadership-card__avatar{
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: #e0e0e0;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.leadership-card__avatar img{
    width: 100%;
    height: 100%;
    border-radius: inherit;
    object-fit: cover;
}

.leadership-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.leadership-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: default;
}

.leadership-card__name {
    font-size: 1.375rem;
    font-weight: 600;
    margin: 0 0 4px;
}

.leadership-card__role {
    font-weight: normal;
    font-size: 1.0625rem;
    margin: 0 0 16px;
}

.leadership-card__bio {
    font-size: 0.9375rem;
    line-height: 1.55;
    margin: 0 0 16px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.leadership-card__more {
    margin-top: auto;
    border-radius: 999px;
    padding: 10px 24px;
    font-size: 0.875rem;
}

.leadership-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(4, 30, 66, 0.55);
}
.leadership-modal[hidden] { display: none; }

.leadership-modal__dialog {
    position: relative;
    width: 100%;
    max-width: 640px;
    max-height: 85vh;
    overflow-y: auto;
    padding: 40px;
    background: #fff;
    border-radius: 4px;
}

.leadership-modal__header { text-align: center; }

.leadership-modal__avatar {
    width: 110px;
    height: 110px;
    margin-bottom: 20px;
}

.leadership-modal .leadership-card__name { font-size: 1.625rem; }
.leadership-modal .leadership-card__role { margin-bottom: 20px; }

.leadership-modal__bio {
    margin: 0;
    font-size: 1rem;
    line-height: 1.7;
    text-align: left;
}

.leadership-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    padding: 6px;
    background: none;
    border: none;
    font-size: 1.625rem;
    line-height: 1;
    color: var(--nzpost-blue);
    cursor: pointer;
}

@media (max-width: 600px) {
    .leadership-modal__dialog { padding: 32px 24px; }
}

/* ===== RESPONSIVE HEROES (auto-generated by wire_placeholders.py) ===== */

/* Single image per hero; CSS controls position, zoom, and edge fade. */

/* Base (mobile-first defaults) */
.hero--about {
    background-image: url("../img/photos/about.jpg");
    background-size: cover;
    background-position: 55% 30%;
}
.hero--air-ocean-air-freight {
    background-image: url("../img/photos/air-ocean-air-freight.jpg");
    background-size: cover;
    background-position: 50% 50%;
}
.hero--air-ocean-ocean-freight {
    background-image: url("../img/photos/air-ocean-ocean-freight.jpg");
    background-size: cover;
    background-position: 55% 55%;
}
.hero--air-ocean-customs {
    background-image: url("../img/photos/air-ocean-customs.jpg");
    background-size: cover;
    background-position: 75% 25%;
}
.hero--transport-business {
    background-image: url("../img/photos/transport-business.jpg");
    background-size: cover;
    background-position: 40% 30%;
}
.hero--transport-home-delivery {
    background-image: url("../img/photos/transport-home-delivery.jpg");
    background-size: cover;
    background-position: 65% 30%;
}
.hero--transport-small-package {
    background-image: url("../img/photos/transport-small-package.jpg");
    background-size: cover;
    background-position: 55% 30%;
}
.hero--transport-special-services {
    background-image: url("../img/photos/transport-special-services.jpg");
    background-size: cover;
    background-position: 50% 50%;
}
.hero--transport-tracking {
    background-image: url("../img/photos/transport-tracking.jpg");
    background-size: cover;
    background-position: 22% 30%;
}
.hero--warehousing-bulk {
    background-image: url("../img/photos/warehousing-bulk.jpg");
    background-size: cover;
    background-position: 32% 28%;
}
.hero--warehousing-pallet {
    background-image: url("../img/photos/warehousing-pallet.jpg");
    background-size: cover;
    background-position: 50% 50%;
}
.hero--warehousing-split-case {
    background-image: url("../img/photos/warehousing-split-case.jpg");
    background-size: cover;
    background-position: 50% 45%;
}
.hero--warehousing-spare-parts {
    background-image: url("../img/photos/warehousing-spare-parts.jpg");
    background-size: cover;
    background-position: 50% 50%;
}
.hero--warehousing-value-add {
    background-image: url("../img/photos/warehousing-value-add.jpg");
    background-size: cover;
    background-position: 50% 55%;
}
.hero--warehousing-hi-tech {
    background-image: url("../img/photos/warehousing-hi-tech.jpg");
    background-size: cover;
    background-position: 50% 55%;
}
.hero--warehousing-ecommerce {
    background-image: url("../img/photos/warehousing-ecommerce.jpg");
    background-size: cover;
    background-position: 45% 30%;
}
.hero--contact-support {
    background-image: url("../img/photos/contact-support.jpg");
    background-size: cover;
    background-position: 50% 50%;
}
.hero--contact-support-air-ocean {
    background-image: url("../img/photos/contact-support-air-ocean.jpg");
    background-size: cover;
    background-position: 25% 25%;
}
.hero--contact-support-warehousing {
    background-image: url("../img/photos/contact-support-warehousing.jpg");
    background-size: cover;
    background-position: 30% 30%;
}
.hero--contact-support-transport {
    background-image: url("../img/photos/contact-support-transport.jpg");
    background-size: cover;
    background-position: 75% 40%;
}
.hero--contact-support-news {
    background-image: url("../img/photos/contact-support-news.jpg");
    background-size: cover;
    background-position: 55% 50%;
}
.hero--contact-support-tracking {
    background-image: url("../img/photos/contact-support-tracking.jpg");
    background-size: cover;
    background-position: 55% 50%;
}

/* ===== END RESPONSIVE HEROES ===== */

/* ===== TRACKING PAGE ===== */
.tracking-page {
    background: #f2f5fb;
}

.tracking-page__title {
    margin-bottom: 16px;
}

.tracking-page__search {
    margin-bottom: 20px;
}

.tracking-page .track-form {
    max-width: 720px;
}

.tracking-page .track-label {
    color: #041e42;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.82rem;
}

.tracking-page .track-input input[type="text"] {
    background: #fff;
    color: #041e42;
    border: 2px solid #b7c3d4;
}

.tracking-page .track-input input[type="text"]::placeholder {
    color: rgba(4, 30, 66, 0.45);
}

.tracking-page .track-input input[type="text"]:focus {
    border-color: #3a5f95;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(58, 95, 149, 0.15);
}

.tracking-ticket-records {
    margin-top: 14px;
}

.tracking-ticket-records ul {
    margin: 8px 0 0;
    padding-left: 20px;
    color: #213a62;
}

.tracking-page__message {
    background: #fff;
    border: 1px solid #d4dbe6;
    border-left: 4px solid #3a5f95;
    padding: 12px 14px;
    margin-bottom: 20px;
}

.tracking-page__message--error {
    border-left-color: #b42424;
}

.tracking-job-header {
    background: #fff;
    border: 1px solid #d7dfec;
    padding: 14px 16px;
    margin-bottom: 16px;
}

.tracking-job-header h2 {
    margin: 0;
    font-size: 1.2rem;
    color: #041e42;
}

.tracking-job-header p {
    margin: 6px 0 0;
    color: #213a62;
}

.tracking-card {
    border: 1px solid #d7dfec;
    background: #fff;
    margin-bottom: 16px;
}

.tracking-card__header {
    background: #3a5f95;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 7px 12px;
}

.tracking-card--collapsible > .tracking-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    list-style: none;
}

.tracking-card--collapsible > .tracking-card__header:hover,
.tracking-card--collapsible > .tracking-card__header:hover * {
    cursor: pointer;
}

.tracking-card--collapsible > .tracking-card__header::-webkit-details-marker {
    display: none;
}

.tracking-card__toggle {
    width: 8px;
    height: 8px;
    border-right: 2px solid rgba(255, 255, 255, 0.95);
    border-bottom: 2px solid rgba(255, 255, 255, 0.95);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    margin-left: 12px;
    flex-shrink: 0;
}

.tracking-card--collapsible[open] .tracking-card__toggle {
    transform: rotate(-135deg);
}

.tracking-card__body {
    padding: 18px 14px;
}

.tracking-card__empty {
    margin: 0;
    color: #4a5f7f;
}

.tracking-timeline {
    position: relative;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
    gap: 8px;
    padding-top: 14px;
}

.tracking-timeline__rail {
    position: absolute;
    top: 39px;
    left: 4%;
    right: 4%;
    height: 2px;
    background: #d4dbe6;
}

.tracking-milestone {
    position: relative;
    text-align: center;
    z-index: 1;
}

.tracking-milestone__icon-wrap {
    position: relative;
    width: 52px;
    margin: 0 auto 10px;
}

.tracking-milestone__icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 2px solid #d0d8e88f;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #a0afc4;
    line-height: 1;
}

.tracking-milestone__icon img {
    max-width: 28px;
    max-height: 28px;
}

.tracking-milestone__fallback {
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.04em;
}

.tracking-milestone.is-reached .tracking-milestone__icon {
    border-color: #19a15f;
}

.tracking-milestone__check {
    position: absolute;
    right: -4px;
    bottom: -3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #19a15f;
    color: #fff;
    border: 2px solid #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.68rem;
    font-weight: 500;
}

.tracking-milestone__name {
    margin: 0;
    font-weight: 500;
    color: #041e42;
    font-size: 0.9rem;
}

.tracking-milestone__date {
    margin: 4px 0 0;
    color: #5f7393;
    font-size: 0.78rem;
}

.tracking-pod {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: start;
}

.tracking-pod--stacked {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 2px solid #c9d8ee;
    box-shadow: inset 0 1px 0 #eef3fb;
}

.tracking-pod__title {
    margin: 0 0 2px;
    color: #041e42;
    font-size: 0.95rem;
    font-weight: 600;
    grid-column: 1 / -1;
}

.tracking-pod__details {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tracking-pod__label {
    margin: 0 0 2px;
    font-size: 0.72rem;
    text-transform: uppercase;
    color: #677b99;
}

.tracking-pod__value {
    margin: 0;
    color: #041e42;
    font-weight: 500;
}

.tracking-pod__signature-label {
    margin: 0 0 8px;
    font-size: 0.72rem;
    text-transform: uppercase;
    color: #677b99;
}

.tracking-pod__signature-box {
    border: 1px solid #d7dfec;
    background: #f6f8fc;
    min-height: 104px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
}

.tracking-pod__signature {
    max-width: 100%;
    max-height: 132px;
    display: block;
}

.tracking-pod__signature-empty {
    color: #5f7393;
    font-size: 0.86rem;
}

.tracking-status-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.tracking-status-grid__label {
    margin: 0 0 4px;
    font-size: 0.72rem;
    text-transform: uppercase;
    color: #677b99;
}

.tracking-status-grid__value {
    margin: 0;
    color: #041e42;
    font-weight: 500;
}

@media (max-width: 992px) {
    .tracking-timeline {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 16px;
    }

    .tracking-timeline__rail {
        display: none;
    }

    .tracking-pod {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .tracking-status-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .tracking-card__body {
        padding: 14px 10px;
    }

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