/*
Theme Name: APACPH GeneratePress
Theme URI: https://www.apacph.org/
Description: GeneratePress child theme for the APACPH consortium and membership website.
Author: APACPH
Version: 2.1.0
Template: generatepress
Text Domain: apacph
License: GPL-2.0-or-later
*/

:root {
    --apacph-navy-950: #082747;
    --apacph-navy-900: #0b345f;
    --apacph-blue-700: #005f8f;
    --apacph-blue-600: #0088cc;
    --apacph-teal-600: #008f8c;
    --apacph-teal-100: #dff5f2;
    --apacph-gold-500: #d99b2b;
    --apacph-ink: #17324d;
    --apacph-muted: #587087;
    --apacph-surface: #ffffff;
    --apacph-canvas: #f4f8fb;
    --apacph-border: #d9e5ee;
    --apacph-success: #247a4d;
    --apacph-warning: #a85d00;
    --apacph-danger: #aa2f3b;
    --apacph-content: 1180px;
    --apacph-radius-sm: 10px;
    --apacph-radius-md: 18px;
    --apacph-radius-lg: 28px;
    --apacph-shadow: 0 18px 48px -34px rgb(8 39 71 / 55%);
    --apacph-font-display: "Fjalla One", "Arial Narrow", Arial, sans-serif;
    --apacph-font-body: Cantarell, "Segoe UI", Arial, sans-serif;
}

body {
    color: var(--apacph-ink);
    background: var(--apacph-canvas);
    font-family: var(--apacph-font-body);
    line-height: 1.65;
}

a { color: var(--apacph-blue-700); }
a:hover { color: var(--apacph-navy-950); }

h1, h2, h3, h4, h5, h6,
.site-branding,
.main-navigation {
    color: var(--apacph-navy-950);
}

h1, h2 {
    letter-spacing: -.025em;
}

:focus-visible {
    outline: 3px solid var(--apacph-gold-500);
    outline-offset: 3px;
}

.site-header {
    border-top: 5px solid var(--apacph-blue-700);
    border-bottom: 1px solid var(--apacph-border);
    background: rgb(255 255 255 / 96%);
}

.inside-header,
.main-navigation .inside-navigation {
    max-width: var(--apacph-content);
}

.site-logo img {
    width: auto;
    max-height: 64px;
}

.main-navigation {
    background: var(--apacph-surface);
}

.main-navigation .main-nav ul li a {
    color: var(--apacph-ink);
    font-size: .94rem;
    font-weight: 700;
    letter-spacing: .015em;
}

.main-navigation .main-nav ul li a:hover,
.main-navigation .main-nav ul li[class*="current-menu-"] > a {
    color: var(--apacph-blue-700);
    background: var(--apacph-teal-100);
}

.page-template-template-apacph-landing .site-header{border-top:0;box-shadow:0 8px 35px rgb(8 39 71 / 7%)}
.page-template-template-apacph-landing .site-header .inside-header{min-height:86px}
.page-template-template-apacph-landing .main-navigation .main-nav ul li a{padding-inline:17px}
.page-template-template-apacph-landing .menu-item.apacph-menu-cta>a{min-height:44px;margin-left:12px;border-radius:0;background:var(--apacph-gold-500);border-color:var(--apacph-gold-500);color:var(--apacph-navy-950)!important}
.apacph-landing-header{position:relative;z-index:20;border-bottom:1px solid var(--apacph-border);background:#fff}.apacph-landing-header__inner{display:flex;align-items:center;width:min(1180px,calc(100% - 44px));min-height:88px;margin:auto;gap:30px}.apacph-landing-brand{display:flex;align-items:center;gap:13px;margin-right:auto;color:var(--apacph-navy-950);text-decoration:none}.apacph-landing-brand__logo{display:block;width:auto;max-width:230px;max-height:62px}.apacph-landing-brand>span:last-child{display:flex;flex-direction:column}.apacph-landing-brand strong{font-size:1.72rem;line-height:1;letter-spacing:.02em}.apacph-landing-brand small{margin-top:5px;color:var(--apacph-muted);font-size:.59rem;font-weight:800;line-height:1.2;text-transform:uppercase}.apacph-landing-brand__mark{position:relative;width:45px;height:45px;border-radius:50%}.apacph-landing-brand__mark i{position:absolute;width:10px;height:10px;border-radius:50%;background:var(--apacph-blue-700)}.apacph-landing-brand__mark i:nth-child(1){left:18px;top:0}.apacph-landing-brand__mark i:nth-child(2){right:2px;top:11px;background:var(--apacph-teal-600)}.apacph-landing-brand__mark i:nth-child(3){right:5px;bottom:5px;background:var(--apacph-gold-500)}.apacph-landing-brand__mark i:nth-child(4){left:8px;bottom:2px}.apacph-landing-brand__mark i:nth-child(5){left:0;top:13px;background:var(--apacph-gold-500)}.apacph-landing-nav ul{display:flex;align-items:center;gap:4px;margin:0;padding:0;list-style:none}.apacph-landing-nav a{display:block;padding:12px 10px;color:var(--apacph-ink);font-size:.9rem;font-weight:800;text-decoration:none}.apacph-landing-nav a:hover{color:var(--apacph-blue-700)}.apacph-landing-header__cta{display:inline-flex;align-items:center;gap:18px;padding:13px 18px;background:var(--apacph-gold-500);color:var(--apacph-navy-950);font-weight:900;text-decoration:none}.apacph-landing-header__cta:hover{background:var(--apacph-navy-950);color:#fff}

.menu-item.apacph-menu-cta > a,
.apacph-button,
.wp-block-button__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 11px 22px;
    border: 2px solid var(--apacph-blue-700);
    border-radius: 999px;
    background: var(--apacph-blue-700);
    color: #fff !important;
    font-weight: 800;
    text-decoration: none;
}

.menu-item.apacph-menu-cta > a:hover,
.apacph-button:hover,
.wp-block-button__link:hover {
    border-color: var(--apacph-navy-950);
    background: var(--apacph-navy-950);
}

.page-template-template-apacph-landing .site-content,
.page-template-template-apacph-full-width .site-content,
.page-template-template-apacph-landing .content-area,
.page-template-template-apacph-full-width .content-area,
.page-template-template-apacph-landing main,
.page-template-template-apacph-full-width main {
    width: 100%;
    max-width: none;
    padding: 0;
}

.page-template-template-apacph-landing .inside-article,
.page-template-template-apacph-full-width .inside-article {
    padding: 0;
    background: transparent;
}

.apacph-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.apacph-site-footer {
    padding: 64px 22px 24px;
    color: #d9e8f3;
    background: var(--apacph-navy-950);
}

.apacph-site-footer__inner {
    width: min(100%, var(--apacph-content));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(260px, 1.1fr) 2fr;
    gap: 48px 72px;
}

.apacph-site-footer h2,
.apacph-site-footer h3 { color: #fff; }
.apacph-site-footer h2 { margin: 0 0 12px; }
.apacph-site-footer p { color: #c4d7e6; }

.apacph-site-footer__nav ul {
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 28px;
    list-style: none;
}

.apacph-site-footer a { color: #fff; font-weight: 700; }
.apacph-site-footer a:hover { color: #8ee0d8; }

.apacph-site-footer__meta {
    grid-column: 1 / -1;
    padding-top: 24px;
    border-top: 1px solid rgb(255 255 255 / 15%);
    display: flex;
    justify-content: space-between;
    gap: 24px;
    font-size: .88rem;
}

@media (max-width: 768px) {
    .site-header .inside-header { padding: 14px 18px; }
    .site-logo img { max-height: 52px; }
    .apacph-site-footer__inner { grid-template-columns: 1fr; }
    .apacph-site-footer__nav ul { grid-template-columns: 1fr; }
    .apacph-site-footer__meta { flex-direction: column; }
    .apacph-landing-header__inner{width:min(100% - 32px,1180px);min-height:76px;flex-wrap:wrap;padding-block:12px}.apacph-landing-brand__logo{max-width:180px;max-height:50px}.apacph-landing-brand small{display:none}.apacph-landing-nav{order:3;width:100%;overflow-x:auto;border-top:1px solid var(--apacph-border);scrollbar-width:none}.apacph-landing-nav::-webkit-scrollbar{display:none}.apacph-landing-nav ul{justify-content:flex-start;min-width:max-content}.apacph-landing-nav a{padding:12px 9px}.apacph-landing-header__cta{padding:10px 13px;font-size:.82rem}.apacph-landing-header__cta span{display:none}
}

/* ---------------------------------------------------------------------------
   Single post: featured image removed in functions.php. GeneratePress still
   prints the wrapper, so drop it here to avoid an empty block holding margin.
   --------------------------------------------------------------------------- */
.single-post .featured-image.page-header-image-single { display: none; }

/* ---------------------------------------------------------------------------
   Title-less pages that open with a full-width image.

   GeneratePress gives .inside-article 40px of padding. That normally sits
   behind the page title. With the title disabled and the content starting on
   an alignfull image, it reads as a white band between the header and the
   artwork. Remove the top padding in exactly that case, and leave every other
   page alone.

   Escape hatch: if the automatic match does not fire, add the class
   apacph-flush-top to the first block under Advanced > Additional CSS class(es).
   --------------------------------------------------------------------------- */
.inside-article:not(:has(> .entry-header)):has(> .entry-content > .alignfull:first-child),
.inside-article:not(:has(> .entry-header)):has(> .entry-content > .alignwide:first-child),
.inside-article:has(> .entry-content > .apacph-flush-top:first-child) {
    padding-top: 0;
}

/* The image sits flush to the container edge, so its own top margin has to go too. */
.inside-article:not(:has(> .entry-header)) > .entry-content > .alignfull:first-child,
.inside-article:not(:has(> .entry-header)) > .entry-content > .alignwide:first-child,
.inside-article > .entry-content > .apacph-flush-top:first-child {
    margin-top: 0;
}
