/* ============================================================
   MORETECH -- PROGRAMS
   First-party markup + CSS (see partials/programs.php's own header for
   the full rationale) -- not derived from the shared platform's own
   programs.css. Every recurring visual value is a real --mt-* token.
   ============================================================ */

.mt-programs {
    padding: var(--mt-section-py) 0;
    background: var(--mt-page-bg);
    font-family: var(--mt-font-sans);
}

.mt-programs__header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto var(--mt-space-10);
}

.mt-programs__eyebrow {
    display: inline-block;
    font-size: var(--mt-text-xs);
    font-weight: var(--mt-weight-bold);
    letter-spacing: var(--mt-tracking-wider);
    text-transform: uppercase;
    color: var(--mt-accent);
    margin-bottom: var(--mt-space-3);
}

.mt-programs__heading {
    /* V2 Phase 2.0: raised from 2xl to 3xl — same section-title
       hierarchy correction as every other card-pattern module. */
    font-size: var(--mt-text-3xl);
    font-weight: var(--mt-weight-black);
    color: var(--mt-text-strong);
    margin: 0 0 var(--mt-space-3);
}

.mt-programs__lead {
    font-size: var(--mt-text-md);
    color: var(--mt-text-muted);
    margin: 0;
}

.mt-programs__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    border-radius: var(--mt-radius-md);
    background: var(--mt-brand-primary-soft);
    color: var(--mt-brand-primary);
    font-size: var(--mt-text-lg);
}

.mt-programs__title {
    font-size: var(--mt-text-md);
    font-weight: var(--mt-weight-bold);
    color: var(--mt-text-strong);
    margin: 0 0 var(--mt-space-2);
}

.mt-programs__desc {
    font-size: var(--mt-text-sm);
    color: var(--mt-text-muted);
    line-height: var(--mt-leading-normal);
    margin: 0;
    /* V2 Phase 2.0: caps readable line length in the wide 'list'
       composition; a no-op in the narrower 'grid' cards. */
    max-width: 60ch;
}

.mt-programs__age {
    display: inline-block;
    margin-top: var(--mt-space-3);
    padding: var(--mt-space-1) var(--mt-space-3);
    border-radius: var(--mt-radius-full);
    background: var(--mt-accent-soft);
    color: var(--mt-accent);
    font-size: var(--mt-text-xs);
    font-weight: var(--mt-weight-semibold);
}

/* ------------------------------------------------------------
   Composition: grid -- bordered, elevated card grid.
   ------------------------------------------------------------ */

/* V2 Phase 2.0: track minimum raised 240px -> 280px and card padding
   space-6 -> space-8 — same card-density correction as Services (sibling
   module, identical card shape: icon + title + description). */
.mt-programs__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--mt-space-6);
}

.mt-programs__item {
    padding: var(--mt-space-8);
    border: 1px solid var(--mt-border-light);
    border-radius: var(--mt-radius-lg);
    background: var(--mt-surface-card);
    box-shadow: var(--mt-shadow-xs);
    transition: box-shadow var(--mt-duration-normal) var(--mt-ease-default),
                transform var(--mt-duration-normal) var(--mt-ease-default);
}

.mt-programs__item:hover {
    box-shadow: var(--mt-shadow-md);
    transform: translateY(-2px);
}

.mt-programs__grid .mt-programs__icon {
    margin-bottom: var(--mt-space-4);
}

/* ------------------------------------------------------------
   Composition: list -- horizontal icon-left row list, better
   suited to longer descriptions or fewer, more detailed items.
   ------------------------------------------------------------ */

.mt-programs--list .mt-programs__grid {
    display: flex;
    flex-direction: column;
    gap: var(--mt-space-5);
}

.mt-programs--list .mt-programs__item {
    display: flex;
    align-items: flex-start;
    gap: var(--mt-space-5);
    padding: var(--mt-space-5) 0;
    border: none;
    border-bottom: 1px solid var(--mt-border-light);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.mt-programs--list .mt-programs__item:hover {
    transform: none;
    box-shadow: none;
}

.mt-programs--list .mt-programs__item:last-child {
    border-bottom: none;
}

.mt-programs--list .mt-programs__body {
    flex: 1;
    min-width: 0;
}

/* ------------------------------------------------------------
   Composition: spotlight -- Phase 3B (MDQ-032). Large, centered,
   single-column treatment -- the same "spotlight" visual language
   moretech-testimonials.css's own .mt-testimonials--spotlight
   already established (large/centered/borderless/stacked),
   applied to Programs. Deliberately distinct from BOTH 'grid'
   (bordered multi-column cards, left-aligned content) and 'list'
   (full-width, left-aligned, hairline-divided rows): centered,
   no dividers, enlarged icon/title, narrower max-width column.
   ------------------------------------------------------------ */

.mt-programs--spotlight .mt-programs__grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--mt-space-10);
    max-width: 640px;
    margin: 0 auto;
}

.mt-programs--spotlight .mt-programs__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.mt-programs--spotlight .mt-programs__item:hover {
    transform: none;
    box-shadow: none;
}

.mt-programs--spotlight .mt-programs__icon {
    width: 64px;
    height: 64px;
    font-size: var(--mt-text-xl);
    margin-bottom: var(--mt-space-4);
}

.mt-programs--spotlight .mt-programs__title {
    font-size: var(--mt-text-xl);
}

.mt-programs--spotlight .mt-programs__desc {
    max-width: 60ch;
}

.mt-programs--spotlight .mt-programs__age {
    margin-top: var(--mt-space-4);
}


/* ============================================================
   PLUSFAB PROGRAMS (2026-10-01, design only) -- "CHAMFERED PLATE".
   Appended presentation layer (wins by source order); same markup,
   content and compositions (grid / list / spotlight).
   Distinct motif from the Services nameplate, same language: each grid
   card is a sheet-metal panel with its top-right corner SHEARED at 45deg
   (clip-path) and a steel line drawn along the cut; a graphite side rail
   that turns copper on hover; DARK graphite icon tiles with copper
   glyphs; Archivo titles; the age/tag pill becomes a square stamped
   steel tag with a copper notch. Header = PlusFab label + Archivo
   heading + steel rule with copper segment (as Services / Projects).
============================================================ */
.mt-programs {
    background: #FFFFFF;
    border-top: 1px solid var(--mt-border-light);
}

/* -- Header (left-aligned, as the other PlusFab sections) -- */
.mt-programs__header {
    position: relative;
    text-align: left;
    max-width: none;
    margin: 0 0 var(--mt-space-12);
    padding-bottom: var(--mt-space-8);
    border-bottom: 1px solid #D5DADE;
}
.mt-programs__header::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 72px;
    height: 2px;
    background: var(--mt-accent);
}
.mt-programs__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: var(--mt-space-3);
    font-size: 0.75rem;
    font-weight: var(--mt-weight-semibold);
    letter-spacing: 0.16em;
    color: #555C63;
    margin-bottom: var(--mt-space-4);
}
.mt-programs__eyebrow::before {
    content: "";
    flex-shrink: 0;
    width: var(--mt-kicker-rule, 28px);
    height: 2px;
    background: var(--mt-accent);
}
.mt-programs__heading {
    font-family: var(--mt-font-heading);
    font-size: clamp(1.9rem, 1.3rem + 1.6vw, 2.6rem);
    font-weight: var(--mt-weight-bold);
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--ally-navy-700);
    margin-bottom: var(--mt-space-4);
    max-width: 22ch;
    text-wrap: balance;
}
.mt-programs__lead {
    font-size: 1.02rem;
    line-height: 1.65;
    color: #555C63;
    max-width: 62ch;
}

/* -- Shared item internals -- */
.mt-programs__icon {
    width: 48px;
    height: 48px;
    border-radius: 2px;
    background: var(--ally-navy-700);
    color: var(--mt-accent);
    font-size: 1.1rem;
}
.mt-programs__title {
    font-family: var(--mt-font-heading);
    font-size: 1.15rem;
    font-weight: var(--mt-weight-bold);
    letter-spacing: -0.01em;
    color: var(--ally-navy-700);
    margin-bottom: var(--mt-space-3);
}
.mt-programs__desc {
    font-size: 0.92rem;
    line-height: 1.65;
    color: #555C63;
}
/* Stamped spec tag (was a rounded pill) */
.mt-programs__age {
    position: relative;
    margin-top: var(--mt-space-5);
    padding: 5px 10px 5px 14px;
    border: 1px solid #C5CBD0;
    border-radius: 0;
    background: transparent;
    color: var(--ally-navy-700);
    font-family: var(--mt-font-heading);
    font-size: 0.68rem;
    font-weight: var(--mt-weight-semibold);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.mt-programs__age::before {                       /* copper notch */
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 4px;
    height: 10px;
    transform: translateY(-50%);
    background: var(--mt-accent);
}

/* -- grid: chamfered sheet-metal panels -- */
.mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__grid { gap: var(--mt-space-5); }
.mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item {
    --pf-cut: 22px;
    position: relative;
    padding: var(--mt-space-8) var(--mt-space-8) var(--mt-space-8) calc(var(--mt-space-8) + 3px);
    border: 1px solid #D5DADE;
    border-radius: 0;
    background:
        linear-gradient(var(--ally-navy-700), var(--ally-navy-700)) 0 0 / 3px 100% no-repeat,
        #FFFFFF;
    box-shadow: none;
    clip-path: polygon(0 0, calc(100% - var(--pf-cut)) 0, 100% var(--pf-cut), 100% 100%, 0 100%);
    transition: border-color var(--mt-duration-normal) var(--mt-ease-default);
}
.mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item::after {   /* steel line along the cut */
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: var(--pf-cut);
    height: var(--pf-cut);
    background: linear-gradient(to top right, transparent calc(50% - 0.75px), #C5CBD0 calc(50% - 0.75px), #C5CBD0 calc(50% + 0.75px), transparent calc(50% + 0.75px));
    pointer-events: none;
}
.mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:hover {
    transform: none;
    box-shadow: none;
    border-color: #8A939B;
    background:
        linear-gradient(var(--mt-accent), var(--mt-accent)) 0 0 / 3px 100% no-repeat,
        #FFFFFF;
}
.mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:hover::after {
    background: linear-gradient(to top right, transparent calc(50% - 0.75px), var(--mt-accent) calc(50% - 0.75px), var(--mt-accent) calc(50% + 0.75px), transparent calc(50% + 0.75px));
}
.mt-programs__grid .mt-programs__icon { margin-bottom: var(--mt-space-5); }

/* Balanced grid (no empty slot), same rule as Services / Products */
@media (min-width: 992px) {
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item { grid-column: span 2; }
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:nth-last-child(2):nth-child(3n+1),
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:last-child:nth-child(3n+2) { grid-column: span 3; }
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:last-child:nth-child(3n+1) { grid-column: 1 / -1; }
}
@media (min-width: 576px) and (max-width: 991.98px) {
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

/* -- list / spotlight: same palette, hairline language -- */
.mt-programs--list .mt-programs__item { border-bottom-color: #D5DADE; }
.mt-programs--spotlight .mt-programs__icon { width: 60px; height: 60px; }

@media (max-width: 767px) {
    .mt-programs__header { margin-bottom: var(--mt-space-8); padding-bottom: var(--mt-space-6); }
    .mt-programs:not(.mt-programs--list):not(.mt-programs--spotlight) .mt-programs__item {
        --pf-cut: 16px;
        padding: var(--mt-space-6) var(--mt-space-6) var(--mt-space-6) calc(var(--mt-space-6) + 3px);
    }
}
