.mt-app {
    --mt-ink: #17302d;
    --mt-accent: #176054;
    --mt-line: #d7e5df;
    --mt-pale: #eaf6f0;
    width: min(1120px, calc(100% - 32px));
    margin: 36px auto;
    color: var(--mt-ink);
    line-height: 1.65;
}
.mt-app [hidden] { display: none !important; }
.mt-app h1, .mt-app h2, .mt-app h3, .mt-app h4 { color: inherit; line-height: 1.2; }
.mt-app a { color: var(--mt-accent); }
.mt-nav, .mt-actions { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 16px 0 24px; }
.mt-nav a { font-weight: 650; text-decoration: underline; text-underline-offset: .2em; }
.mt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 18px; }
.mt-card, .mt-panel { padding: clamp(18px, 3vw, 32px); border: 1px solid var(--mt-line); border-radius: 20px; background: #fff; }
.mt-card { display: flex; flex-direction: column; align-items: flex-start; }
.mt-card .mt-button { margin-top: auto; }
.mt-count, .mt-kicker { color: #3c6359; font-size: .92em; font-weight: 650; }
.mt-hero { padding: clamp(24px, 6vw, 66px); border-radius: 26px; background: linear-gradient(120deg, #e2f4ea, #d9eee9); }
.mt-hero h1 { font-size: clamp(30px, 5vw, 56px); }
.mt-course { max-width: 930px; }
.mt-panel { margin: 20px 0; scroll-margin-top: 24px; }
.mt-map { margin: 20px 0 8px; }
.mt-map-root { width: fit-content; margin: 0 auto; padding: 12px 22px; background: var(--mt-accent); color: #fff; border-radius: 14px; text-align: center; font-weight: 700; }
.mt-branches { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 155px), 1fr)); gap: 12px; padding-top: 24px; position: relative; }
.mt-branches::before { content: ''; width: 2px; height: 24px; position: absolute; top: 0; left: 50%; background: #79a99d; }
.mt-branches details { position: relative; padding: 12px; border: 1px solid var(--mt-line); border-radius: 12px; background: var(--mt-pale); }
.mt-branches details::before { content: ''; position: absolute; top: -1px; left: 0; width: 100%; height: 2px; background: #79a99d; border-radius: 12px; }
.mt-branches summary { cursor: pointer; font-weight: 700; }
.mt-branches p { padding: 8px 0 0; }
.mt-filters, .mt-comparison { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 14px; }
.mt-app input[type="search"], .mt-app select, .mt-app textarea { display: block; width: 100%; padding: 10px 12px; border: 1px solid #77958f; border-radius: 8px; background: #fff; color: var(--mt-ink); font: inherit; }
.mt-app textarea { margin-bottom: 12px; resize: vertical; }
.mt-app .mt-button { display: inline-block; padding: 9px 16px; border-radius: 9px; border: 1px solid var(--mt-accent); background: var(--mt-accent); color: #fff; font: inherit; font-weight: 650; text-decoration: none; cursor: pointer; }
.mt-app .mt-secondary { background: #fff; color: var(--mt-accent); }
.mt-app .mt-button:disabled { opacity: .6; cursor: default; }
.mt-app :focus-visible { outline: 3px solid #297a6b; outline-offset: 3px; }
.mt-interactive fieldset { margin: 16px 0; padding: 12px; border: 1px solid var(--mt-line); border-radius: 10px; min-width: 0; }
.mt-interactive legend { padding: 0 4px; font-weight: 700; }
.mt-choice { display: block; padding: 4px 0; cursor: pointer; }
.mt-comparison, [data-mentora-correction] { margin-top: 12px; padding: 12px; border-radius: 10px; background: var(--mt-pale); overflow-wrap: anywhere; }
.mt-comparison > p { grid-column: 1 / -1; }
.mt-comparison [data-mentora-answer] { white-space: pre-wrap; }
[data-mentora-correction].mt-correct { background: #e4f7ea; }
[data-mentora-score], [data-mentora-time] { margin: 8px; font-weight: 700; }
@media print {
    .mt-course .mt-nav, .mt-course button { display: none; }
    .mt-panel { break-inside: avoid; }
}

.mt-app {
    --mt-ink: #142d29;
    --mt-accent: #155d51;
    --mt-line: #d7e5df;
    --mt-pale: #eaf6f0;
    font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 16px;
}
.mt-masthead {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px 24px;
    padding: 14px 0;
    margin-bottom: 18px;
    border-bottom: 1px solid var(--mt-line);
}
.mt-app .mt-brand {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    color: var(--mt-ink);
    font-size: 1.24rem;
    font-weight: 780;
    letter-spacing: -.045em;
}
.mt-brand img { display: block; width: 42px; height: 42px; object-fit: contain; }
.mt-brand small { font-size: .73em; color: var(--mt-accent); font-weight: 650; letter-spacing: normal; }
.mt-masthead .mt-nav { margin: 0; gap: 4px 8px; }
.mt-nav a { padding: 6px 9px; border-radius: 8px; text-decoration: none; font-size: .9rem; }
.mt-nav a:hover { background: var(--mt-pale); text-decoration: underline; }
.mt-catalogue-hero, .mt-hero {
    border-radius: 24px;
    padding: clamp(24px, 5vw, 58px);
    background: radial-gradient(ellipse at 100% 0%, #236759, transparent 70%), #0d3230;
    color: #fff;
    margin: 0 0 26px;
}
.mt-catalogue-hero h2, .mt-hero h1 {
    font-size: clamp(2rem, 5.2vw, 3.75rem);
    letter-spacing: -.055em;
    font-weight: 770;
}
.mt-catalogue-hero p, .mt-hero p { color: #d7efe5; padding-bottom: 0; }
.mt-hero .mt-kicker { color: #b7ebd8; }
.mt-filters { padding: 16px; background: #f5f9f7; border: 1px solid var(--mt-line); border-radius: 16px; }
.mt-filters label, .mt-interactive label { font-weight: 600; }
.mt-filters input, .mt-filters select, .mt-app textarea { margin-top: 5px; }
.mt-count { margin-top: 14px; }
.mt-card { padding: 23px; border-radius: 17px; box-shadow: 0 4px 16px #183d330a; }
.mt-card .mt-kicker { color: var(--mt-accent); }
.mt-card h3 { font-weight: 730; letter-spacing: -.026em; font-size: 1.27rem; }
.mt-card h3 a { color: var(--mt-ink); }
.mt-card h3 a:hover { color: var(--mt-accent); text-decoration: underline; }
.mt-card .mt-button { background: var(--mt-pale); color: var(--mt-accent); border-color: transparent; }
.mt-card .mt-button::after { content: ' →'; }
.mt-app .mt-button:not(:disabled):hover { background: #10483e; color: #fff; }
.mt-course > article > .mt-nav { padding: 8px; border: 1px solid var(--mt-line); border-radius: 12px; }
.mt-panel h2 { font-weight: 750; letter-spacing: -.035em; }
.mt-panel .mt-interactive { max-width: 720px; margin-inline: auto; }
.mt-interactive textarea { min-height: 100px; background: #f7fbf9; }
.mt-branches details { background: #f3faf6; }
@media (max-width: 560px) {
    .mt-masthead { align-items: flex-start; }
    .mt-masthead .mt-nav { width: 100%; }
    .mt-nav a { padding-inline: 6px; }
    .mt-panel { padding: 16px; }
}

/* The Mentora header replaces Divi's front-end header on Mentora routes. */
.mentora-interface #page-container { padding-top: 0 !important; }
.mentora-interface .et-l--header { display: none; }
.mt-site-header { position: relative; z-index: 20; background: #fff; border-bottom: 1px solid #d7e5df; }
.mt-site-header .mt-masthead {
    width: min(1120px, calc(100% - 32px));
    min-height: 60px;
    box-sizing: border-box;
    margin: 0 auto;
    padding: 8px 0;
    border: 0;
    flex-wrap: nowrap;
    align-items: center;
    gap: 12px;
}
.mt-site-header .mt-brand {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #142d29;
    font: 760 1.12rem/1.1 system-ui, sans-serif;
    letter-spacing: -.035em;
}
.mt-site-header .mt-brand img { width: 34px; height: 34px; flex: none; }
.mt-site-header .mt-brand small { color: #155d51; }
.mt-menu summary {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    min-height: 44px;
    padding: 0 12px;
    border: 1px solid #c9ddd5;
    border-radius: 9px;
    color: #155d51;
    font: 650 .92rem/1 system-ui, sans-serif;
    list-style: none;
}
.mt-menu summary::-webkit-details-marker { display: none; }
.mt-menu nav {
    position: absolute;
    top: 100%;
    right: max(16px, calc((100% - 1120px) / 2));
    width: min(280px, calc(100% - 32px));
    padding: 8px;
    border: 1px solid #d7e5df;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 10px 24px #183d3326;
}
.mt-menu nav a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 5px 10px;
    border-radius: 8px;
    color: #155d51;
    font: 650 .92rem/1.25 system-ui, sans-serif;
}
.mt-menu nav a:hover, .mt-menu nav a[aria-current="page"] { background: #eaf6f0; }
.mt-site-header :focus-visible { outline: 3px solid #297a6b; outline-offset: 3px; }
.mt-menu-wide > summary { display: none; }
.mt-menu-wide nav { display: flex; position: static; width: auto; padding: 0; border: 0; box-shadow: none; }
.mentora-catalogue-page #main-content > .container { padding-top: 14px; }
.mentora-interface .mt-app { margin-top: 16px; }
.mt-catalogue-hero {
    padding: clamp(16px, 3.8vw, 36px);
    margin-bottom: 14px;
    border-radius: 16px;
}
.mt-catalogue-hero h2 { font-size: clamp(1.55rem, 3.5vw, 2.85rem); padding-bottom: 0; }
.mt-filters { gap: 10px; }
.mt-filters input, .mt-filters select { min-height: 44px; }
.mt-course .mt-nav a { min-height: 44px; display: inline-flex; align-items: center; }
@media (max-width: 560px) {
    .mt-course > article > .mt-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; }
    .mt-course .mt-hero { padding: 20px; margin-bottom: 14px; }
    .mt-course .mt-hero h1 { font-size: clamp(1.75rem, 7vw, 2.5rem); }
    .mt-filters { padding: 12px; }
}

/* Keep the WordPress toolbar out of the menu's tap area on phones. */
@media (max-width: 782px) {
    body.mentora-interface.admin-bar > #wpadminbar { position: static; }
}

.mentora-catalogue-page #main-content > .container { width: min(1120px, calc(100% - 32px)); padding-top: 0; }
.mentora-catalogue-page #main-content #left-area { width: 100%; padding-inline: 0; }
.mentora-catalogue-page #main-content #sidebar,
.mentora-catalogue-page #main-content .container::before,
.mentora-catalogue-page #main-content .entry-title.main_title { display: none; }
.mentora-catalogue-page #left-area .mt-catalogue { width: 100%; }
.mt-editorial { display: grid; grid-template-columns: 1.05fr 1fr; overflow: hidden; border-radius: 22px; background: #103c36; color: #fff; }
.mt-editorial-copy { display: grid; align-content: center; padding: clamp(20px, 5vw, 56px); min-width: 0; }
.mt-editorial h1, .mt-editorial h2 { font-size: clamp(2.15rem, 5vw, 4.1rem); line-height: 1.03; font-weight: 780; letter-spacing: -.055em; padding: 0; }
.mt-editorial p { color: #d3eee3; padding: 0; margin-top: 14px; max-width: 34ch; }
.mt-editorial-photo { display: block; width: 100%; height: 100%; min-height: 210px; max-height: 300px; object-fit: cover; }
.mt-resource .mt-editorial-photo { min-height: 132px; max-height: 190px; }
.mt-subject-section, .mt-results-heading { margin-top: clamp(22px, 4vw, 42px); }
.mt-subject-section h2, .mt-results-heading h2 { font-size: clamp(1.38rem, 3vw, 2rem); font-weight: 740; letter-spacing: -.035em; padding-bottom: 0; }
.mt-subject-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(150px, 100%), 1fr)); gap: 10px; margin-top: 13px; }
.mt-tone-mint { --mt-tint: #e8f4ec; --mt-tone-ink: #235d46; }
.mt-tone-sea { --mt-tint: #e5f1f3; --mt-tone-ink: #225663; }
.mt-tone-sand { --mt-tint: #f7efe0; --mt-tone-ink: #76512c; }
.mt-app .mt-subject-link {
    display: flex; align-items: center; gap: 9px;
    min-height: 60px; padding: 9px 11px; border-radius: 12px;
    background: var(--mt-tint); color: var(--mt-tone-ink);
    font-weight: 690; line-height: 1.25; overflow-wrap: anywhere;
}
.mt-subject-link svg { flex: 0 0 24px; width: 24px; height: 24px; }
.mt-subject-link:hover, .mt-subject-link[aria-current="true"] { box-shadow: inset 0 0 0 2px currentColor; }
.mt-results-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.mt-reset { min-height: 44px; padding: 6px 12px; border: 1px solid var(--mt-line); color: var(--mt-accent); border-radius: 8px; background: #fff; cursor: pointer; font: inherit; }
.mt-catalogue .mt-card { display: block; position: relative; border-inline-start: 4px solid var(--mt-tint); min-width: 0; padding: 14px 16px; }
.mt-catalogue .mt-card .mt-kicker { color: var(--mt-tone-ink); padding-bottom: 4px; font-size: .82em; }
.mt-catalogue .mt-card h3 { font-size: 1.1rem; padding: 0; }
.mt-card h3 a { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding-block: 4px; min-height: 42px; }
.mt-card h3 a::after { position: absolute; inset: 0; content: ''; border-radius: 16px; }
.mt-card h3 a:focus-visible::after { outline: 3px solid #297a6b; }
.mt-card-description { font-size: .9rem; line-height: 1.42; padding: 0; }
.mt-catalogue .mt-filters { background: #f5f9f7; border-radius: 12px; }
@media (max-width: 560px) {
    .mt-overview .mt-editorial { grid-template-columns: 1fr; border-radius: 16px; }
    .mt-overview .mt-editorial-photo { min-height: 0; height: clamp(110px, 31vw, 160px); object-position: center 32%; }
    .mt-resource .mt-editorial { grid-template-columns: 1.55fr 1fr; border-radius: 16px; }
    .mt-resource .mt-editorial h1, .mt-resource .mt-editorial h2 { font-size: clamp(1.55rem, 7vw, 2.2rem); overflow-wrap: anywhere; }
    .mt-resource .mt-editorial-photo { min-height: 100px; }
    .mt-editorial p { margin-top: 8px; font-size: .92rem; line-height: 1.45; }
    .mt-subject-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mt-app .mt-subject-link { font-size: .88rem; min-height: 52px; }
    .mt-subject-link svg { flex-basis: 21px; width: 21px; height: 21px; }
}

.mentora-brevet-page #main-content > .container { width: min(1120px, calc(100% - 32px)); padding-top: 0; }
.mentora-brevet-page #main-content #left-area { width: 100%; padding-inline: 0; padding-bottom: 0; }
.mentora-brevet-page #main-content #sidebar,
.mentora-brevet-page #main-content .container::before { display: none; }
.mentora-brevet-page #left-area .mt-brevet { width: 100%; }
.mt-brevet-practice { margin-top: 18px; padding: clamp(16px, 3.8vw, 32px); background: #edf6f1; border-radius: 17px; }
.mt-brevet-intro h2, .mt-brevet-resources h2 { font-size: clamp(1.35rem, 3vw, 2rem); font-weight: 750; letter-spacing: -.035em; }
.mt-brevet-intro p { padding-bottom: 8px; }
.mt-brevet [data-mentora-start] { min-height: 44px; margin-top: 6px; }
.mt-brevet [data-mentora-time] { display: inline-block; }
.mt-brevet [data-mentora-copy] fieldset { background: white; }
.mt-brevet-resources { margin-top: 22px; }
.mt-brevet-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 10px; }
.mt-app .mt-brevet-link { display: grid; gap: 5px; padding: 14px; border-radius: 13px; color: var(--mt-tone-ink); background: var(--mt-tint); }
.mt-brevet-link strong { display: flex; justify-content: space-between; gap: 6px; }
.mt-brevet-link:hover strong { text-decoration: underline; }
.mt-brevet-link > span { font-size: .9rem; line-height: 1.4; }
@media (max-width: 560px) {
    .mt-brevet .mt-editorial { grid-template-columns: 1.55fr 1fr; border-radius: 16px; }
    .mt-brevet .mt-editorial h1 { font-size: clamp(1.6rem, 7vw, 2.2rem); }
    .mt-brevet .mt-editorial-photo { min-height: 130px; }
}
.mentora-brevet-page article:has(.mt-brevet) > .entry-title.main_title { display: none; }
.mt-brevet-practice .mt-panel details { margin: 0 0 1.1rem; }
.mt-brevet-practice summary { cursor: pointer; color: var(--mt-accent); font-weight: 650; }
