:root {
    --brand: #14459e;
    --brand-dark: #0c2c66;
    --brand-light: #e5eff9;
    --cream: #f7f7f5;
    --text-dark: #1c1c1c;
    --text-muted: #5a5a5a;
    --border: #e5e5e0;
    --logo-width: 160px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
    color: var(--text-dark);
    background: #fff;
    line-height: 1.6;
}

h1, h2, h3, h4, .serif {
    font-family: Georgia, 'Times New Roman', serif;
    font-weight: 600;
    margin: 0 0 .5em;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 22px; border-radius: 4px; font-weight: 600;
    text-decoration: none; cursor: pointer; border: 2px solid transparent;
    font-size: 15px; transition: all .15s ease;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); text-decoration: none; }
.btn-outline-light { background: transparent; color: #fff; border-color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,.15); text-decoration: none; }
.btn-outline { background: transparent; color: var(--brand); border-color: var(--brand); }

/* ---- Header ---- */
.site-header {
    position: sticky; top: 0; z-index: 100; background: #fff;
    border-bottom: 1px solid var(--border);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; padding: 14px 24px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text-dark); }
.brand img.logo { width: var(--logo-width); height: auto; }
.brand-text .site-name { font-family: Georgia, serif; font-size: 22px; font-weight: 700; letter-spacing: .5px; line-height: 1.1; }
.brand-text .site-tagline { font-size: 11px; color: var(--text-muted); }
.main-nav { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.main-nav a { color: var(--text-dark); font-size: 15px; font-weight: 500; }
.main-nav a.active { color: var(--brand); border-bottom: 2px solid var(--brand); padding-bottom: 4px; }
.nav-toggle { display: none; background: none; border: none; font-size: 26px; cursor: pointer; }

/* ---- Submenu dropdown (items nested under a top-level nav item) ---- */
.nav-dropdown-wrap { position: relative; }
.nav-dropdown-toggle-row { display: inline-flex; align-items: center; gap: 5px; }
.nav-dropdown-toggle-row > a { display: inline-flex; align-items: center; }
.nav-dropdown-caret {
    -webkit-appearance: none; appearance: none; background: none; border: none; outline: none;
    box-shadow: none; cursor: pointer; padding: 0; margin: 0; line-height: 0;
    display: inline-flex; align-items: center; color: var(--text-dark); opacity: .55;
    transition: transform .18s ease, opacity .15s ease;
}
.nav-dropdown-toggle-row:hover .nav-dropdown-caret,
.nav-dropdown-wrap:hover .nav-dropdown-caret,
.nav-dropdown-wrap:focus-within .nav-dropdown-caret { opacity: 1; }
.nav-dropdown-wrap:hover .nav-dropdown-caret,
.nav-dropdown-wrap:focus-within .nav-dropdown-caret,
.nav-dropdown-caret.open { transform: rotate(180deg); }
.nav-dropdown-menu {
    display: none; position: absolute; top: 100%; left: 0; margin-top: 14px; background: #fff;
    border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 12px 28px rgba(0,0,0,.12);
    padding: 8px; min-width: 220px; z-index: 50;
}
/* Invisible bridge over the gap between the trigger and the panel — without
   this, moving the mouse from the link down into the menu crosses empty
   space with nothing hoverable, which drops :hover and closes the menu
   before the cursor arrives. */
.nav-dropdown-menu::before {
    content: ''; position: absolute; top: -14px; left: 0; right: 0; height: 14px;
}
.nav-dropdown-menu a { display: block; padding: 9px 12px; border-radius: 6px; font-size: 14.5px; white-space: nowrap; }
.nav-dropdown-menu a:hover, .nav-dropdown-menu a.active { background: var(--brand-light); text-decoration: none; border-bottom: none; }
.nav-dropdown-menu.open { display: block; }
@media (min-width: 901px) {
    .nav-dropdown-wrap:hover .nav-dropdown-menu, .nav-dropdown-wrap:focus-within .nav-dropdown-menu { display: block; }
}

@media (max-width: 900px) {
    .nav-toggle { display: block; }
    .main-nav { display: none; width: 100%; flex-direction: column; align-items: flex-start; gap: 14px; padding: 16px 0; }
    .main-nav.open { display: flex; }
    .site-header .container { flex-wrap: wrap; }
    .nav-dropdown-wrap { width: 100%; }
    .nav-dropdown-toggle-row { width: 100%; justify-content: space-between; }
    .nav-dropdown-caret { opacity: .55; padding: 6px; margin: -6px; }
    .nav-dropdown-menu { position: static; box-shadow: none; border: none; padding: 0; margin: 6px 0 0 16px; min-width: 0; }
}

/* ---- Hero ---- */
.hero {
    position: relative; color: #fff; min-height: 560px; display: flex; align-items: center;
    background-size: cover; background-position: center; background-color: #333; overflow: hidden;
}
.hero::before {
    content: ''; position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(90deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.45) 45%, rgba(0,0,0,.15) 100%);
}
.hero-media-bg {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; pointer-events: none; border: 0;
}
/* Iframes (YouTube/Vimeo) can't use object-fit, so oversize + center-crop to a 16:9 background fill instead */
.hero-iframe-bg {
    top: 50%; left: 50%; width: 177.78vh; min-width: 100%; height: 56.25vw; min-height: 100%;
    transform: translate(-50%, -50%); inset: auto;
}
.hero-content { position: relative; z-index: 2; max-width: 620px; padding: 60px 24px; }
.hero h1 { font-size: 44px; line-height: 1.15; margin-bottom: 18px; }
.hero p { font-size: 17px; color: #eee; margin-bottom: 28px; }
.hero-buttons { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---- Section headers ---- */
.section { padding: 70px 0; }
.section-alt { background: var(--cream); }
.section-eyebrow {
    text-align: center; text-transform: uppercase; letter-spacing: 2px; font-size: 13px;
    font-weight: 700; color: var(--brand); margin-bottom: 10px;
}
.section-eyebrow::before, .section-eyebrow::after { content: '—'; margin: 0 10px; color: var(--brand); opacity: .5; }
.section-title { text-align: center; font-size: 34px; margin-bottom: 10px; }
.section-subtitle { text-align: center; color: var(--text-muted); max-width: 560px; margin: 0 auto 40px; }

/* ---- What We Do cards ---- */
.cards-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
@media (max-width: 900px) { .cards-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .cards-grid { grid-template-columns: 1fr; } }
.card {
    background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 32px 24px; text-align: center;
}
.card-icon {
    width: 64px; height: 64px; border-radius: 50%; background: var(--brand-light);
    display: flex; align-items: center; justify-content: center; margin: 0 auto 18px;
}
.card h3 { font-size: 19px; margin-bottom: 10px; }
.card p { color: var(--text-muted); font-size: 14.5px; margin-bottom: 16px; }
.card-link { font-weight: 700; font-size: 14px; }

/* ---- Stats bar ---- */
.stats-bar { background: var(--brand); color: #fff; padding: 46px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); text-align: center; gap: 20px; }
@media (max-width: 700px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } }
.stat-icon { margin-bottom: 10px; opacity: .9; }
.stat-number { font-family: Georgia, serif; font-size: 30px; font-weight: 700; }
.stat-label { font-size: 14px; opacity: .85; }

/* ---- News cards ---- */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
@media (max-width: 900px) { .news-grid { grid-template-columns: 1fr; } }
.news-card { border: 1px solid var(--border); border-radius: 8px; overflow: hidden; background: #fff; }
.news-thumb { position: relative; aspect-ratio: 4/3; background: #ddd; overflow: hidden; }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; }
.news-date-badge {
    position: absolute; top: 12px; left: 12px; background: #fff; border-radius: 4px;
    padding: 6px 10px; text-align: center; line-height: 1.1; font-size: 12px; font-weight: 700;
}
.news-date-badge .day { font-size: 18px; display: block; }
.play-btn {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
}
.play-btn span {
    width: 52px; height: 52px; border-radius: 50%; background: rgba(255,255,255,.9);
    display: flex; align-items: center; justify-content: center; font-size: 18px; color: var(--brand);
}
.news-body { padding: 20px; }
.news-category { text-transform: uppercase; font-size: 11px; font-weight: 700; color: var(--brand); letter-spacing: 1px; }
.news-body h3 { font-size: 18px; margin: 8px 0 10px; }
.news-body p { color: var(--text-muted); font-size: 14px; margin-bottom: 14px; }

.center { text-align: center; }
.mt-40 { margin-top: 40px; }

/* ---- Generic page/post content ---- */
.page-hero {
    background: var(--brand); color: #fff; padding: 60px 0; text-align: center;
}
.page-hero h1 { margin-bottom: 6px; }
.page-content { padding: 60px 0; max-width: 840px; margin: 0 auto; }
.page-content img { border-radius: 8px; margin: 20px 0; }
.page-content h2 { margin-top: 1.4em; }

/* ---- Forms ---- */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 14px; }
.form-group input, .form-group textarea, .form-group select {
    width: 100%; padding: 11px 12px; border: 1px solid #ccc; border-radius: 5px; font-size: 15px; font-family: inherit;
}
.form-group textarea { min-height: 120px; resize: vertical; }
.form-note { font-size: 13px; color: var(--text-muted); margin-top: 6px; }
.alert { padding: 14px 18px; border-radius: 6px; margin-bottom: 20px; font-size: 14.5px; }
.alert-success { background: #e6f4ea; color: #1e5c30; border: 1px solid #b7dfc2; }
.alert-error { background: #fbe9e7; color: #a13a2f; border: 1px solid #f0c0b8; }
/* honeypot field, hidden from real users */
.hp-field { position: absolute; left: -9999px; top: -9999px; }

/* ---- Footer ---- */
.site-footer { background: var(--brand-dark); color: #dbe6f6; padding: 50px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 30px; margin-bottom: 30px; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: #fff; font-size: 15px; margin-bottom: 14px; }
.site-footer a { color: #bcd3ee; }
.site-footer .footer-bottom { border-top: 1px solid rgba(255,255,255,.12); padding-top: 20px; font-size: 13px; color: #96abcc; text-align: center; }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: 9px; line-height: 1.3; }
.footer-contact-btn { display: inline-flex; margin-top: 6px; padding: 9px 16px; font-size: 14px; }

.news-list-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; margin-top: 30px; }
@media (max-width: 900px) { .news-list-grid { grid-template-columns: 1fr; } }
.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 40px; }
.pagination a, .pagination span {
    display: inline-flex; align-items: center; justify-content: center; min-width: 38px; height: 38px;
    padding: 0 12px; border: 1px solid var(--border); border-radius: 6px; font-size: 14px; font-weight: 600;
    color: var(--text-dark); transition: background .12s ease, border-color .12s ease;
}
.pagination a:hover { background: var(--brand-light); border-color: var(--brand); text-decoration: none; }
.pagination .current { background: var(--brand); color: #fff; border-color: var(--brand); cursor: default; }
.pagination .page-nav { font-weight: 700; padding: 0 16px; }
.pagination .disabled { color: #c7c7c7; border-color: var(--border); cursor: not-allowed; }
.pagination .disabled:hover { background: none; border-color: var(--border); }

/* ---- Video gallery ---- */
.video-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
@media (max-width: 1100px) { .video-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) { .video-grid { grid-template-columns: repeat(2, 1fr); gap: 22px; } }
@media (max-width: 640px) { .video-grid { grid-template-columns: 1fr; } }

.video-card {
    display: block; color: var(--text-dark); border-radius: 14px; overflow: hidden; background: #fff;
    box-shadow: 0 1px 3px rgba(16,24,40,.08), 0 1px 2px rgba(16,24,40,.04);
    transition: box-shadow .25s ease, transform .25s ease;
}
.video-card:hover {
    text-decoration: none; transform: translateY(-4px);
    box-shadow: 0 16px 32px rgba(16,24,40,.14), 0 4px 10px rgba(16,24,40,.08);
}

.video-thumb {
    position: relative; aspect-ratio: 16/9; background: #e4e8ed; overflow: hidden;
}
/* Rendered as a CSS background (not an <img>) so a fixed aspect-ratio box
   is always fully covered, edge to edge, regardless of the source image's
   own dimensions — this is the same technique YouTube/Vimeo use. */
.video-thumb-img {
    position: absolute; inset: 0; background-size: cover; background-position: center;
    transition: transform .5s ease;
}
.video-card:hover .video-thumb-img { transform: scale(1.07); }
.video-thumb-placeholder {
    width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
    font-size: 34px; color: rgba(255,255,255,.35); background: linear-gradient(135deg, #1a2130, #12161c);
}
.video-thumb-scrim {
    position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 60%, rgba(0,0,0,.6) 100%);
    pointer-events: none;
}
/* Corner placement (not centered) so the icon never sits over a face or
   subject in the thumbnail, regardless of how the photo is framed. */
.video-thumb .play-btn {
    inset: auto; left: 14px; bottom: 14px; right: auto; top: auto;
}
.video-thumb .play-btn span {
    width: 42px; height: 42px; background: rgba(255,255,255,.94); color: var(--brand);
    box-shadow: 0 3px 10px rgba(0,0,0,.4); transition: transform .25s ease, background .25s ease, color .25s ease;
    font-size: 14px; padding-left: 2px; /* optically center the triangle */
}
.video-card:hover .play-btn span { background: var(--brand); color: #fff; transform: scale(1.12); }

.video-body { padding: 18px 20px 20px; }
.video-body h3 {
    font-size: 16.5px; line-height: 1.35; margin: 0 0 8px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.video-body p {
    color: var(--text-muted); font-size: 13.5px; line-height: 1.5; margin: 0 0 12px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.video-search { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; flex-wrap: wrap; }
.video-search input[type=text] {
    flex: 1; min-width: 220px; padding: 11px 16px; border: 1px solid #ccc; border-radius: 6px;
    font-size: 15px; font-family: inherit;
}
.video-search-clear { font-size: 14px; color: var(--text-muted); text-decoration: underline; }

/* ---- Homepage video carousel ---- */
.video-carousel { position: relative; display: flex; align-items: center; gap: 12px; }
.video-carousel-track {
    display: flex; gap: 26px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
    padding: 4px 4px 12px; -webkit-overflow-scrolling: touch;
}
.video-carousel-track::-webkit-scrollbar { height: 8px; }
.video-carousel-track::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
.video-carousel-item { flex: 0 0 300px; scroll-snap-align: start; }
@media (max-width: 640px) { .video-carousel-item { flex-basis: 260px; } }
.carousel-nav {
    flex-shrink: 0; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border); background: #fff;
    cursor: pointer; font-size: 15px; color: var(--text-dark); display: flex; align-items: center; justify-content: center;
    transition: background .12s ease, border-color .12s ease;
}
.carousel-nav:hover { background: var(--brand-light); border-color: var(--brand); }
@media (max-width: 700px) { .carousel-nav { display: none; } }

.video-modal-backdrop {
    position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 300;
    display: none; align-items: center; justify-content: center; padding: 24px;
}
.video-modal-backdrop.open { display: flex; }
.video-modal { position: relative; width: 100%; max-width: 900px; }
.video-modal h3 { color: #fff; font-size: 18px; margin-bottom: 12px; padding-right: 40px; }
.video-modal-body { position: relative; width: 100%; aspect-ratio: 16/9; background: #000; border-radius: 6px; overflow: hidden; }
.video-modal-close {
    position: absolute; top: -6px; right: 0; background: none; border: none; color: #fff;
    font-size: 32px; line-height: 1; cursor: pointer; padding: 4px 8px;
}
