/*
 * Subpagina’s: zelfde Editorial / mini-nav / chips / flow als index (licht thema).
 * Vereist theme-tokens.css vóór dit bestand (zie partials/template-head.php).
 */

/* ——— Hero: kicker + icoon-halo (creatief, subtiel) ——— */
.template-hero-kicker {
    margin: 0 0 0.35rem;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--mm-muted);
}

.template-hero-icon {
    position: relative;
    display: inline-block;
    margin-top: 0.25rem;
    filter: drop-shadow(0 0 14px rgba(154, 115, 82, 0.35));
}

.template-hero-chips {
    margin-top: 0.35rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.35rem 0.45rem;
}

/* Lichte “bounce-in” bij load (alleen hero-chips) */
@media (prefers-reduced-motion: no-preference) {
    .template-hero-chips .status-chip {
        animation: chipFadeIn 0.55s ease backwards;
    }
    .template-hero-chips .status-chip:nth-child(1) { animation-delay: 0.04s; }
    .template-hero-chips .status-chip:nth-child(2) { animation-delay: 0.12s; }
    .template-hero-chips .status-chip:nth-child(3) { animation-delay: 0.2s; }
    .template-hero-chips .status-chip:nth-child(4) { animation-delay: 0.28s; }
}

@keyframes chipFadeIn {
    from {
        opacity: 0;
        transform: translateY(6px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.template-hero-actions {
    margin-top: 1.2rem !important;
}

.template-progress-fill {
    width: 52%;
    animation: templateProgressPulse 3.2s ease-in-out infinite alternate;
}

@keyframes templateProgressPulse {
    0% { width: 38%; opacity: 0.85; }
    100% { width: 58%; opacity: 1; }
}

/* ——— Hergebruik index “shell”-stijlen ——— */
.status-chip {
    display: inline-block;
    padding: 0.45em 0.9em;
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.02em;
    margin: 0.3em 0.3em 0;
    border: 1px solid var(--mm-button-border-soft);
    background: var(--mm-bg-card);
    color: var(--mm-text);
}

a.status-chip.status-chip--link {
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s cubic-bezier(0.25, 0.9, 0.35, 1),
        box-shadow 0.24s ease;
}

/* Binnen de hub: champagne / zand (interne route) */
a.status-chip.status-chip--internal {
    border-color: rgba(160, 120, 60, 0.32);
    background: linear-gradient(
        155deg,
        rgba(255, 253, 248, 0.98) 0%,
        rgba(245, 228, 200, 0.82) 48%,
        rgba(232, 210, 170, 0.38) 100%
    );
}

/* GetGrist / extern: warm baken, duidelijk anders dan intern */
a.status-chip.status-chip--external {
    border-color: rgba(234, 88, 12, 0.28);
    background: linear-gradient(
        155deg,
        rgba(255, 255, 255, 0.95) 0%,
        rgba(254, 243, 199, 0.85) 45%,
        rgba(253, 230, 138, 0.4) 100%
    );
}

/* Compact ↗: dunne spatie, iets verhoogd, minder visueel lawaai */
a.status-chip.status-chip--external::after {
    content: "\202f\2197";
    font-size: 0.62em;
    font-weight: 600;
    opacity: 0.78;
    vertical-align: 0.2em;
    margin-left: 0.02em;
    letter-spacing: -0.06em;
    transition: opacity 0.2s ease, color 0.2s ease;
}

a.status-chip.status-chip--link:hover {
    text-decoration: none;
    transform: translateY(-2px);
}

a.status-chip.status-chip--internal:hover {
    background: linear-gradient(
        155deg,
        #fffdf8 0%,
        rgba(237, 214, 175, 0.95) 50%,
        rgba(212, 180, 120, 0.45) 100%
    );
    border-color: rgba(139, 90, 43, 0.48);
    color: #5c3d1c;
    box-shadow: 0 5px 18px rgba(109, 76, 50, 0.16);
}

a.status-chip.status-chip--external:hover {
    background: linear-gradient(
        155deg,
        #ffffff 0%,
        rgba(254, 215, 170, 0.95) 48%,
        rgba(251, 191, 36, 0.35) 100%
    );
    border-color: rgba(234, 88, 12, 0.45);
    color: #9a3412;
    box-shadow: 0 5px 20px rgba(234, 88, 12, 0.15);
}

a.status-chip.status-chip--external:hover::after {
    opacity: 0.92;
    color: #c2410c;
}

.progress-wrap {
    width: 100%;
    max-width: 480px;
    margin: 1.2rem auto 0;
    background: rgba(58, 50, 40, 0.06);
    border-radius: 999px;
    overflow: hidden;
    border: 1px solid var(--mm-flow-strip-border);
}

.progress-fill,
.template-progress-fill {
    height: 12px;
    background: linear-gradient(90deg, var(--mm-accent) 0%, var(--mm-accent-mid) 100%);
    box-shadow: 0 0 12px var(--mm-pulse-ring);
    border-radius: 999px;
}

.top-mini-nav {
    margin: 0 auto 1rem;
    max-width: min(calc(100vw - 1.5rem), 1280px);
    text-align: center;
    padding: 0.6rem 1rem;
    border: 1px solid var(--mm-top-nav-border);
    border-radius: 999px;
    background: var(--mm-top-nav-bg);
    color: var(--mm-text);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    row-gap: 0.35rem;
    box-sizing: border-box;
    font-size: clamp(0.78rem, 1.05vw, 0.95rem);
}

.top-mini-nav a {
    color: inherit;
    text-decoration: none;
    font-weight: 700;
    white-space: nowrap;
    flex-shrink: 0;
}

.top-mini-nav a:hover {
    text-decoration: underline;
}

.top-mini-nav .active {
    color: var(--mm-accent);
}

.top-mini-nav .sep {
    margin: 0 0.5rem;
    color: #94a3b8;
    white-space: nowrap;
    flex-shrink: 0;
}

.flow-strip {
    margin: 1rem auto 0;
    max-width: 980px;
    text-align: center;
    padding: 0.55rem 0.8rem;
    border: 1px solid var(--mm-flow-strip-border);
    border-radius: 12px;
    background: var(--mm-flow-strip-bg);
    font-size: 0.86rem;
    color: var(--mm-text);
}

.flow-strip--embed .page-flow {
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
    box-shadow: none;
}

.flow-strip--embed .page-flow-title {
    margin: 0 0 0.4rem;
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    color: var(--mm-muted);
}

.flow-strip--embed .page-flow-links {
    justify-content: center;
}

.flow-strip--embed .page-flow-link {
    border: 1px solid var(--mm-flow-pill-border);
    background: var(--mm-flow-pill-bg);
    color: var(--mm-flow-pill-text);
}

.flow-strip--embed .page-flow-link:hover {
    color: var(--mm-link-hover);
}

.flow-strip--embed .page-flow-link.active {
    border-color: var(--mm-accent-ring);
    color: var(--mm-link-hover);
}

/* ——— Hoofdcontentblok ——— */
.template-stack {
    padding-top: 0;
}

.template-stack .container {
    max-width: 1020px;
}

.template-stack--wide .container {
    max-width: 1500px;
}

.template-stack .card {
    padding: 1.35rem 1.45rem;
    border-radius: 14px;
    background: var(--mm-bg-card);
    border: 1px solid var(--mm-line);
    text-align: left;
    margin-bottom: 1.25rem;
    box-shadow: 0 8px 24px var(--mm-shadow);
}

.template-stack .card h2,
.template-stack .card h3 {
    margin-top: 0;
}

.template-stack .card p:last-child {
    margin-bottom: 0;
}

.template-stack .major {
    margin-bottom: 1.5rem;
}

/* Knoppen (oude .btn) laten aansluiten op Editorial-buttons */
.template-stack .btn,
.template-stack a.btn,
.template-stack button.btn {
    display: inline-block;
    padding: 0 1.35em;
    min-height: 2.75em;
    line-height: 2.75em;
    border-radius: 0.375em;
    font-size: 0.78em;
    font-weight: 700;
    letter-spacing: 0.075em;
    text-transform: uppercase;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    border: 0;
    box-shadow: inset 0 0 0 2px var(--mm-accent-ring);
    color: var(--mm-text) !important;
    background: transparent;
}

.template-stack .btn.primary,
.template-stack a.btn.primary,
.template-stack button.btn.primary {
    background: linear-gradient(180deg, var(--mm-accent) 0%, var(--mm-accent-end) 100%);
    box-shadow: none;
    color: var(--mm-primary-on-accent) !important;
}

.template-stack .btn:hover,
.template-stack a.btn:hover {
    background-color: var(--mm-accent-ring-soft);
}

.template-stack .btn.primary:hover {
    filter: brightness(1.06);
}

.template-stack .page-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    margin: 1.25rem 0 0.5rem;
    gap: 0.65rem;
}

.template-stack .page-nav .btn {
    min-width: 160px;
}

/* Hero: zelfde knoppenrij als index (#header .actions.special) */
#header .template-hero-actions {
    margin-top: 1.35rem !important;
}

#header .template-hero-actions .button {
    margin: 0.2rem 0.25rem;
}

.grist-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.anchor-target {
    scroll-margin-top: 1rem;
}

.template-flashes p {
    margin: 0.35rem 0;
}

/* Footer */
#footer .template-footer-back {
    margin: 0 0 0.75rem;
}

#footer .template-footer-back .button {
    margin: 0;
}

/*
 * Licht hero (#header): overschrijft legacy main.css (wit op donker) — dit bestand laadt ná main.css.
 * Geldt voor template-pagina’s; index.php heeft dezelfde regels inline voor de Tech Hub-startpagina.
 */
#header h1,
#header h2,
#header h3 {
    color: var(--mm-heading) !important;
}

#header .icon.major,
#header .icon.major:before,
#header .template-hero-icon:before {
    color: var(--mm-hero-icon) !important;
}

#header ul.actions.special a.button:not(.primary),
#header ul.actions.special .button:not(.primary),
#header .template-hero-actions a.button:not(.primary),
#header .template-hero-actions .button:not(.primary) {
    color: var(--mm-text) !important;
    background: var(--mm-bg-card) !important;
    border: 1px solid var(--mm-line-strong) !important;
    box-shadow: 0 2px 10px var(--mm-shadow) !important;
}

#header ul.actions.special a.button:not(.primary):hover,
#header ul.actions.special .button:not(.primary):hover,
#header .template-hero-actions a.button:not(.primary):hover,
#header .template-hero-actions .button:not(.primary):hover {
    color: var(--mm-heading) !important;
    background: var(--mm-bg-mid) !important;
    border-color: var(--mm-muted) !important;
}

#header ul.actions.special a.button.primary,
#header .template-hero-actions a.button.primary {
    color: var(--mm-primary-on-accent) !important;
}
