/* =============================================================
   PTST — Home page (page-home.php) styles
   File: hello-theme-child/css/ptst-home.css

   Uses tokens from colors_and_type.css (loaded site-wide).
   All rules scoped under `.ptst-home` so they cannot leak into
   Elementor-rendered pages.
   ============================================================= */

/* ------------------------------------------------------------
   Layout primitives
   ------------------------------------------------------------ */

.ptst-home {
    font-family: var(--font-sans);
    color: var(--fg-2);
    background: var(--bg);
}

.ptst-home * { box-sizing: border-box; }

.ptst-home img { max-width: 100%; height: auto; display: block; }

.ptst-home .container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-pad);
}

.ptst-home .section { padding: var(--space-20) 0; }
.ptst-home .section.tight { padding: var(--space-12) 0; }
.ptst-home .section.soft { background: var(--bg-soft); }
.ptst-home .section.deep { background: var(--bg-deep); color: #fff; }

/* Force the design-system h2 size — Elementor's global styles otherwise pull
   it down to ~28px even on non-Elementor pages. */
.ptst-home h2,
.ptst-home .section h2 {
    font-size: clamp(28px, 3.4vw, 44px);
    line-height: 1.12;
    font-weight: 700;
    letter-spacing: -0.018em;
    color: var(--fg-1);
    margin: 0 0 var(--space-3);
}
.ptst-home .section h2 { margin-bottom: var(--space-3); }
.ptst-home h3 { font-size: 22px; font-weight: 700; line-height: 1.3; color: var(--fg-1); margin: 0; }
.ptst-home .lead { font-size: clamp(16px, 1.6vw, 19px); line-height: 1.55; color: var(--fg-2); }

/* Eyebrow colour is set globally in colors_and_type.css. The hero override
   below uses --brand-blue-300 so it pops against the dark photo. */

/* Eyebrow → heading spacing. Matches the design-system previews where the
   eyebrow sits with a comfortable breath above the H1/H2. Adjacent-sibling
   selector so standalone eyebrows / headings are unaffected. Consider
   promoting to colors_and_type.css if you want this site-wide. */
.ptst-home .eyebrow + h1,
.ptst-home .eyebrow + h2,
.ptst-home .eyebrow + h3 { margin-top: var(--space-4); }

/* ------------------------------------------------------------
   Buttons
   ------------------------------------------------------------ */

.ptst-home .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 22px;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background .18s, color .18s, transform .12s, border-color .18s;
    line-height: 1.2;
    white-space: nowrap;
}
.ptst-home .btn:active { transform: translateY(1px); }
.ptst-home .btn.sm { padding: 8px 14px; font-size: 13px; }

.ptst-home .btn-primary   { background: var(--brand-blue); color: #fff; }
.ptst-home .btn-primary:hover   { background: var(--brand-blue-deep); color: #fff; text-decoration: none; }

.ptst-home .btn-gold      { background: var(--brand-gold); color: var(--ink); }
.ptst-home .btn-gold:hover      { background: var(--brand-gold-600); color: #fff; text-decoration: none; }

.ptst-home .btn-secondary { background: #fff; color: var(--brand-blue); border-color: var(--brand-blue); }
.ptst-home .btn-secondary:hover { background: var(--brand-blue-50); color: var(--brand-blue); text-decoration: none; }

.ptst-home .btn-ghost-on-dark {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.4);
}
.ptst-home .btn-ghost-on-dark:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-color: rgba(255,255,255,0.7);
    text-decoration: none;
}

/* ------------------------------------------------------------
   Notice band (top)
   ------------------------------------------------------------ */

.ptst-home .notice-band {
    background: var(--brand-gold-50);
    border-bottom: 1px solid var(--brand-gold-300);
    /* Full-width background; .container inside handles the left-margin
       alignment so the notice sits at the same x as the navbar logo. */
    padding: 10px 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--ink);
}
.ptst-home .notice-band .container {
    text-align: left;
}
.ptst-home .notice-band .label {
    display: inline-block;
    background: var(--brand-gold);
    color: var(--ink);
    padding: 2px 10px;
    border-radius: var(--radius-pill);
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-right: 8px;
    vertical-align: 1px;
}
.ptst-home .notice-band a {
    color: var(--brand-blue);
    font-weight: 600;
    margin-left: 4px;
}
.ptst-home .notice-band a:hover { text-decoration: underline; }

/* ------------------------------------------------------------
   Hero
   ------------------------------------------------------------ */

.ptst-home .hero {
    position: relative;
    background: var(--bg-deep);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    min-height: 640px;
    display: flex;
    align-items: center;
    padding: clamp(64px, 9vw, 120px) 0;
}

.ptst-home .hero__bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* Keep edges crisp — don't let the browser blur the bitmap when scaled. */
    image-rendering: -webkit-optimize-contrast;
}

.ptst-home .hero__scrim {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        linear-gradient(100deg, rgba(11, 27, 51, 0.85) 0%, rgba(11, 27, 51, 0.55) 50%, rgba(11, 27, 51, 0.20) 100%),
        linear-gradient(180deg, rgba(11, 27, 51, 0.30) 0%, rgba(11, 27, 51, 0.50) 100%);
}

/* Hero content sits at the LEFT of the standard container, not centred.
   Because .hero is a flex parent, the container would otherwise size by
   its content (~880px) instead of the full 1240px max-width — forcing
   width:100% makes it span the flex track so margins auto-centre against
   the viewport, putting the inner left edge at the same x as the navbar
   logo and other section content. */
.ptst-home .hero .container {
    position: relative;
    z-index: 1;
    width: 100%;
    text-align: left;
}
.ptst-home .hero .container > * { max-width: 720px; }
.ptst-home .hero .container > .hero__stats { max-width: 880px; }

.ptst-home .hero .eyebrow {
    color: var(--brand-blue-300);
    margin-bottom: var(--space-4);
    display: inline-block;
}

.ptst-home .hero h1 {
    color: #fff;
    font-size: clamp(36px, 6vw, var(--type-h1-size));
    line-height: 1.06;
    font-weight: 800;
    letter-spacing: var(--type-h1-track);
    max-width: 14ch;
    margin-bottom: var(--space-5);
}

.ptst-home .hero .lead {
    color: rgba(255,255,255,0.86);
    max-width: 56ch;
    margin-bottom: var(--space-8);
}

.ptst-home .hero__ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: var(--space-12);
}

.ptst-home .hero__stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--space-8);
    padding-top: var(--space-6);
    border-top: 1px solid rgba(255,255,255,0.2);
    max-width: 800px;
}

.ptst-home .hero__stat .n {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
    letter-spacing: -0.01em;
}

.ptst-home .hero__stat .l {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.7);
    margin-top: 6px;
}

/* ------------------------------------------------------------
   Wayfinding grid — tall tiles with prominent icons
   ------------------------------------------------------------ */

.ptst-home .wayfinding {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2px;
    background: var(--brand-blue-deep);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.ptst-home .tile {
    position: relative;
    background: var(--brand-blue);
    color: #fff;
    padding: 40px 28px 36px;
    text-decoration: none;
    transition: background .2s, transform .2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-height: 280px;
    gap: var(--space-4);
}

/* Alternating pattern with meaningful contrast (the previous
   --brand-blue / --brand-blue-deep pair were nearly identical). */
.ptst-home .tile:nth-child(even) { background: var(--brand-blue-700); }

.ptst-home .tile:hover {
    background: var(--brand-blue-deep);
    color: #fff;
    text-decoration: none;
}
.ptst-home .tile:nth-child(even):hover { background: var(--brand-blue); }

.ptst-home .tile__icon {
    width: 76px;
    height: 76px;
    color: #fff;
    flex-shrink: 0;
}
.ptst-home .tile__icon svg {
    width: 100%;
    height: 100%;
    display: block;
    color: inherit;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.ptst-home .tile__title {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.2;
}

.ptst-home .tile__desc {
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255,255,255,0.82);
    margin: 0;
    max-width: 24ch;
}

.ptst-home .tile__arrow {
    margin-top: auto;
    color: var(--brand-gold);
    font-size: 18px;
    font-weight: 700;
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .2s, transform .2s;
}
.ptst-home .tile:hover .tile__arrow {
    opacity: 1;
    transform: translateX(0);
}

/* ------------------------------------------------------------
   About + 32-year box
   ------------------------------------------------------------ */

.ptst-home .about-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: var(--space-12);
    align-items: start;
}

.ptst-home .about-grid .lead { margin-top: var(--space-4); }
.ptst-home .about-grid p { margin-bottom: var(--space-4); color: var(--fg-2); }
.ptst-home .about-grid h2 { margin-top: var(--space-3); }

.ptst-home .mv-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-6);
    margin-top: var(--space-6);
    margin-bottom: var(--space-8);
}
.ptst-home .mv-card {
    border-left: 3px solid var(--brand-gold);
    padding: 6px 0 6px var(--space-4);
}
.ptst-home .mv-card h3 {
    font-size: 24px;
    color: var(--ink);
    margin-bottom: 6px;
}
.ptst-home .mv-card p {
    font-size: 13px;
    color: var(--ink-3);
    line-height: 1.5;
    margin: 0;
}

.ptst-home .anniversary {
    position: relative;
    background:
        radial-gradient(circle at 20% 110%, rgba(245,168,35,0.18), transparent 60%),
        linear-gradient(160deg, var(--brand-blue-deep) 0%, var(--bg-deep) 100%);
    border-radius: var(--radius-xl);
    padding: var(--space-12) var(--space-10);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
    min-height: 320px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.ptst-home .anniversary::after {
    /* Faint anniversary badge watermark */
    content: '';
    position: absolute;
    right: -40px;
    top: 50%;
    transform: translateY(-50%);
    width: 320px;
    height: 320px;
    background-image: var(--anniv-badge, none);
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    opacity: 0.10;
    z-index: -1;
    pointer-events: none;
}
.ptst-home .anniversary__years {
    font-size: clamp(72px, 8vw, 110px);
    font-weight: 800;
    color: var(--brand-gold);
    letter-spacing: -0.04em;
    line-height: 1;
    display: inline-block;
}
.ptst-home .anniversary__years-label {
    display: inline-block;
    margin-left: var(--space-3);
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.04em;
}
.ptst-home .anniversary__est {
    margin-top: var(--space-3);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.85);
}
.ptst-home .anniversary__sub {
    margin-top: var(--space-4);
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255,255,255,0.78);
    max-width: 28ch;
}

/* ------------------------------------------------------------
   Logo strip (accreditation / partners)
   ------------------------------------------------------------ */

.ptst-home .logo-strip { text-align: center; }
.ptst-home .logo-strip .lead { margin: var(--space-3) auto var(--space-10); max-width: 60ch; }

.ptst-home .logo-strip__logos {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: clamp(28px, 5vw, 72px);
    margin-top: var(--space-8);
}
.ptst-home .logo-strip__logos img {
    /* Square 512px logo canvases — rendered size is height-limited.
       192px display × 2 (retina) = 384px, inside the 512px source. */
    max-height: 192px;
    height: auto;
    width: auto;
    max-width: 360px;
    object-fit: contain;
    transition: transform .2s;
}
.ptst-home .logo-strip__logos img:hover {
    transform: scale(1.04);
}

/* ------------------------------------------------------------
   Upcoming training preview (schedule list)
   ------------------------------------------------------------ */

.ptst-home .section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: var(--space-8);
    gap: var(--space-4);
    flex-wrap: wrap;
}
.ptst-home .section-head h2 { margin-top: var(--space-2); }
.ptst-home .section-head p { color: var(--ink-3); margin-top: var(--space-2); margin-bottom: 0; }

.ptst-home .schedule-list {
    display: grid;
    gap: var(--space-3);
}
.ptst-home .schedule-row {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--space-5);
    padding: var(--space-4) var(--space-5);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: #fff;
    transition: border-color .15s, box-shadow .15s, transform .15s;
}
.ptst-home .schedule-row:hover {
    border-color: var(--brand-blue);
    box-shadow: var(--shadow-sm);
}

.ptst-home .schedule-row__date {
    text-align: center;
    background: var(--bg-soft);
    border-radius: var(--radius-sm);
    padding: 10px 4px;
    align-self: center;
}
.ptst-home .schedule-row__date .d {
    display: block;
    font-size: 26px;
    font-weight: 800;
    color: var(--brand-blue);
    line-height: 1;
}
.ptst-home .schedule-row__date .m {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin-top: 4px;
}

.ptst-home .schedule-row__main { min-width: 0; }

.ptst-home .schedule-row__code {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--brand-blue);
    background: var(--brand-blue-50);
    padding: 3px 8px;
    border-radius: var(--radius-xs);
    margin-bottom: 6px;
}
.ptst-home .schedule-row__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.3;
    margin-bottom: 6px;
}
.ptst-home .schedule-row__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--ink-3);
}
.ptst-home .schedule-row__meta-item { white-space: nowrap; }
.ptst-home .schedule-row__sep { color: var(--ink-4); }

.ptst-home .schedule-row__actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;
}

.ptst-home .chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
}
.ptst-home .chip-success { background: var(--success-50); color: var(--success); }
.ptst-home .chip-warning { background: var(--warning-50); color: var(--warning); }
.ptst-home .chip-info    { background: var(--info-50); color: var(--brand-blue); }

.ptst-home .schedule-empty {
    text-align: center;
    padding: var(--space-12) var(--space-6);
    color: var(--ink-3);
    background: var(--bg-soft);
    border-radius: var(--radius-md);
}

/* ------------------------------------------------------------
   News grid
   ------------------------------------------------------------ */

.ptst-home .news-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-6);
}
.ptst-home .news-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform .2s, box-shadow .2s, border-color .2s;
}
.ptst-home .news-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--brand-blue-100);
}
.ptst-home .news-card__cover {
    aspect-ratio: 16/9;
    background: linear-gradient(160deg, var(--brand-blue), var(--brand-blue-deep));
    background-size: cover;
    background-position: center;
}
.ptst-home .news-card__body {
    padding: var(--space-5);
    display: flex;
    flex-direction: column;
    flex: 1;
}
.ptst-home .news-card__meta {
    font-size: 12px;
    color: var(--ink-3);
    margin-bottom: var(--space-2);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}
.ptst-home .news-card__meta .dot { margin: 0 6px; }
.ptst-home .news-card__title {
    font-size: 18px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.3;
    margin: 0 0 var(--space-2);
}
.ptst-home .news-card__excerpt {
    font-size: 14px;
    color: var(--ink-3);
    line-height: 1.55;
    margin: 0 0 var(--space-4);
    flex: 1;
}
.ptst-home .news-card__more {
    color: var(--brand-blue);
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    margin-top: auto;
}
.ptst-home .news-card__more:hover { text-decoration: underline; }

/* ------------------------------------------------------------
   Contact band (footer CTA)
   ------------------------------------------------------------ */

.ptst-home .contact-band {
    background: linear-gradient(140deg, var(--brand-blue-deep), var(--bg-deep));
    border-radius: var(--radius-xl);
    padding: var(--space-12);
    color: #fff;
    box-shadow: var(--shadow-md);
}
.ptst-home .contact-band__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: var(--space-12);
    align-items: center;
}
.ptst-home .contact-band h2 {
    color: #fff;
    margin-top: var(--space-3);
    margin-bottom: var(--space-4);
}
.ptst-home .contact-band p {
    color: rgba(255,255,255,0.78);
    margin-bottom: var(--space-6);
    max-width: 50ch;
}
.ptst-home .contact-band .eyebrow { color: var(--brand-blue-300); }

.ptst-home .contact-band__info {
    display: grid;
    gap: var(--space-4);
}
.ptst-home .contact-band__info a {
    color: #fff;
    text-decoration: none;
    padding: var(--space-4) var(--space-5);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.04);
    transition: background .15s, border-color .15s;
    display: block;
}
.ptst-home .contact-band__info a:hover {
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.35);
    color: #fff;
    text-decoration: none;
}
.ptst-home .contact-band__info .label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand-blue-300);
    margin-bottom: 4px;
}
.ptst-home .contact-band__info .value {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
}
.ptst-home .contact-band__info .value.lg {
    font-size: 22px;
    font-weight: 800;
}

/* ------------------------------------------------------------
   Responsive
   ------------------------------------------------------------ */

/* Tablet */
@media (max-width: 1024px) {
    .ptst-home .wayfinding {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .ptst-home .about-grid { grid-template-columns: 1fr; gap: var(--space-10); }
    .ptst-home .anniversary { min-height: 240px; }
    .ptst-home .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ptst-home .contact-band__inner { grid-template-columns: 1fr; gap: var(--space-8); }
    .ptst-home .hero__stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Small tablet / large mobile */
@media (max-width: 768px) {
    .ptst-home .section { padding: var(--space-16) 0; }
    .ptst-home .hero { min-height: 540px; padding: 80px 0 64px; }
    .ptst-home .hero h1 { font-size: clamp(32px, 8vw, 44px); max-width: none; }
    .ptst-home .hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-5); }
    .ptst-home .mv-grid { grid-template-columns: 1fr; }
    .ptst-home .news-grid { grid-template-columns: 1fr; }
    /* Schedule row collapses to: date | main on row 1, actions span both on row 2.
       Both buttons share that bottom row side-by-side. The status chip stays
       inline with the meta line — no more full-width pill. */
    .ptst-home .schedule-row {
        grid-template-columns: 56px minmax(0, 1fr);
        grid-template-rows: auto auto;
        gap: var(--space-3) var(--space-4);
        padding: var(--space-4);
    }
    .ptst-home .schedule-row__date { grid-row: 1; }
    .ptst-home .schedule-row__main { grid-row: 1; grid-column: 2; }
    .ptst-home .schedule-row__actions {
        grid-row: 2;
        grid-column: 1 / -1;
        justify-content: flex-end;
    }
    .ptst-home .schedule-row__actions .btn { flex: 1; min-width: 0; }
    .ptst-home .contact-band { padding: var(--space-8); }
}

/* Phone */
@media (max-width: 480px) {
    .ptst-home .wayfinding { grid-template-columns: 1fr; }
    .ptst-home .tile { min-height: 220px; padding: 32px 24px; }
    .ptst-home .anniversary { padding: var(--space-8); }
    .ptst-home .anniversary__years { font-size: 72px; }
    .ptst-home .anniversary__years-label { font-size: 22px; }
    .ptst-home .anniversary::after { width: 240px; height: 240px; right: -60px; opacity: 0.06; }
    .ptst-home .notice-band { text-align: left; }
}
