/* Margo Legal mega-navigation, footer and homepage additions (2026-09-15) */
.site-nav { overflow: visible; }
.mnav-item { position: static; }
.mnav-trigger {
  appearance: none; background: none; border: 0; cursor: pointer; font: inherit;
  color: var(--text-muted, #5f625f); font-size: .9rem; font-weight: 500;
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 2px;
  border-bottom: 2px solid transparent; transition: color .2s, border-color .2s;
}
.mnav-trigger:hover, .mnav-trigger[aria-expanded="true"] { color: var(--text, #151615); }
.mnav-trigger[aria-expanded="true"] { border-bottom-color: currentColor; }
.mnav-trigger:focus-visible { outline: 2px solid #17382c; outline-offset: 3px; border-radius: 4px; }
.mnav-caret { width: 7px; height: 7px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform .2s; }
.mnav-trigger[aria-expanded="true"] .mnav-caret { transform: rotate(225deg) translateY(-1px); }
.mnav-panel {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 999;
  background: #fff; border-bottom: 1px solid var(--border, rgba(21,22,21,.1));
  box-shadow: 0 34px 60px rgba(21,22,21,.12);
  animation: mnavIn .18s ease-out;
}
@keyframes mnavIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.mnav-panel-grid { display: grid; grid-template-columns: 1fr 1fr 1.05fr; gap: 24px 56px; padding-top: 30px; padding-bottom: 34px; }
.mnav-col { display: flex; flex-direction: column; gap: 2px; }
.mnav-link { display: block; padding: 10px 12px; border-radius: 10px; transition: background-color .15s; }
.mnav-link:hover, .mnav-link:focus-visible { background: #f0f1ee; }
.mnav-link:focus-visible { outline: 2px solid #17382c; outline-offset: 1px; }
.mnav-name { display: block; font-weight: 600; font-size: .92rem; color: var(--text, #151615); }
.mnav-badge { display: inline-block; margin-left: 7px; padding: 1px 7px 2px; border-radius: 999px; background: #17382c; color: #f5f7f1; font-size: .62rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; vertical-align: 2px; }
.mnav-desc { display: block; font-size: .8rem; line-height: 1.5; color: var(--text-muted, #5f625f); margin-top: 3px; }
.mnav-feature {
  display: flex; flex-direction: column; align-items: flex-start;
  background: #17382c; color: #f5f7f1; border-radius: 16px; padding: 24px 24px 20px;
  transition: background-color .2s;
}
.mnav-feature:hover, .mnav-feature:focus-visible { background: #1f4a39; }
.mnav-feature:focus-visible { outline: 2px solid #17382c; outline-offset: 3px; }
.mnav-feature-kicker { font-size: .66rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; opacity: .72; }
.mnav-feature-title { font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif; font-size: 1.35rem; line-height: 1.25; letter-spacing: -.02em; margin: 10px 0 8px; }
.mnav-feature-desc { font-size: .82rem; line-height: 1.55; opacity: .85; }
.mnav-feature-cta { margin-top: auto; padding-top: 16px; font-weight: 600; font-size: .85rem; }
.mnav-feature-cta::after { content: " ›"; }
@media (max-width: 899px) { .mnav-panel { display: none !important; } }
@media (min-width: 900px) { .site-nav .nav-toggle, .mega-menu-ready .site-nav .nav-toggle.mega-menu-toggle, .home-showcase .site-nav .nav-toggle.mega-menu-toggle { display: none !important; } }
@media (prefers-reduced-motion: reduce) { .mnav-panel { animation: none; } .mnav-caret { transition: none; } }

/* Mobile Explore overlay accordions */
.macc-toggle {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: none; border: 0; padding: 12px 0; font: inherit; cursor: pointer;
  font-weight: 600; font-size: 1rem; color: inherit; text-align: left;
}
.macc-toggle:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 4px; }
.macc-caret { flex: none; width: 8px; height: 8px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg); transition: transform .2s; }
.macc-toggle[aria-expanded="true"] .macc-caret { transform: rotate(225deg); }
.macc-panel { display: flex; flex-direction: column; gap: 2px; padding: 2px 0 14px; }
.macc-panel a { display: block; padding: 7px 0; font-size: .92rem; color: inherit; opacity: .82; }
.macc-panel a:hover, .macc-panel a:focus-visible { opacity: 1; text-decoration: underline; text-underline-offset: 3px; }

/* Five-group footer */
.mfooter { display: grid; grid-template-columns: minmax(220px, 1.1fr) 2.6fr; gap: 56px; padding: 60px 0 44px; }
.mfooter-brand .mfooter-tag { font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif; font-size: 1.05rem; color: var(--text-muted, #5f625f); margin: 10px 0 18px; }
.mfooter-brand .small { font-size: 11px; max-width: 640px; line-height: 1.8; margin: 0 0 6px; color: var(--text-muted, #5f625f); }
.mfooter-groups { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 28px; }
.mfooter-group h2 { font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim, #6b6e69); margin: 0 0 12px; }
.mfooter-group a { display: block; font-size: .85rem; padding: 4px 0; color: var(--text, #151615); }
.mfooter-group a:hover, .mfooter-group a:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 900px) { .mfooter { grid-template-columns: 1fr; gap: 36px; padding: 44px 0 34px; } .mfooter-groups { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; } }

/* Homepage proof + founding sections */
.mproof-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 8px; }
.mproof-grid figure { margin: 0; border: 1px solid var(--border, rgba(21,22,21,.1)); border-radius: 14px; overflow: hidden; background: #fff; box-shadow: var(--shadow-card, 0 22px 60px rgba(30,32,30,.07)); }
.mproof-grid img { width: 100%; height: auto; display: block; }
.mproof-caption { font-size: .78rem; color: var(--text-muted, #5f625f); margin-top: 16px; }
@media (max-width: 900px) { .mproof-grid { grid-template-columns: 1fr; } }
.mfounding-boundary { font-size: .85rem; color: var(--text-muted, #5f625f); margin-top: 18px; }

/* Academy page */
.macad-stages { display: grid; grid-template-columns: repeat(2, 1fr); gap: 40px 48px; margin-bottom: 30px; }
.macad-stages article { border-top: 1px solid #dce0e8; padding-top: 22px; }
.macad-links { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.macad-links a { font-size: .9rem; font-weight: 600; color: var(--native-accent, #17382c); }
.macad-links a:hover, .macad-links a:focus-visible { text-decoration: underline; text-underline-offset: 3px; }
.macad-links span { display: block; font-weight: 400; font-size: .8rem; color: var(--text-muted, #5f625f); margin-top: 1px; }
@media (max-width: 760px) { .macad-stages { grid-template-columns: 1fr; gap: 24px; } }

/* --- Margo Academy: clean redesign (Sep 2026) --- */
.macad-hero { padding: 44px 0 40px; }
.macad-hero .macad-hero-inner { max-width: 660px; margin: 0 auto; text-align: center; }
.macad-hero h1 { margin: 14px 0 0; }
.macad-hero .lede { margin: 20px auto 0; max-width: 34em; }
.macad-hero-actions { display: flex; gap: 18px; justify-content: center; align-items: center; margin-top: 30px; flex-wrap: wrap; }
.macad-text-link { font-size: .92rem; font-weight: 600; color: #17382c; text-decoration: underline; text-underline-offset: 3px; }
.macad-featured { padding: 8px 0 64px; }
.macad-feature { max-width: 920px; margin: 0 auto; background: #17382c; color: #eef3ee; border-radius: 22px; padding: 52px 52px; display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; }
.macad-kicker { text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 700; color: #a8c6b2; margin: 0 0 14px; }
.macad-feature h2 { color: #ffffff; margin: 0 0 14px; }
.macad-feature > .macad-feature-copy > p { color: #cfdccf; margin: 0 0 26px; font-size: 1rem; line-height: 1.6; }
.macad-feature .button { background: #f8f8f6; color: #17382c; border-color: #f8f8f6; }
.macad-feature .button:hover { background: #ffffff; }
.macad-syllabus { background: #f8f8f6; color: #1d2620; border-radius: 16px; padding: 28px 28px 22px; }
.macad-syllabus-title { margin: 0 0 16px; font-weight: 700; font-size: .95rem; }
.macad-syllabus ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: day; }
.macad-syllabus li { font-size: .85rem; color: #3c453e; display: flex; gap: 12px; align-items: baseline; }
.macad-syllabus li::before { counter-increment: day; content: "Day " counter(day); flex: 0 0 44px; font-size: .68rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #17382c; }
.macad-library { padding: 0 0 64px; }
.macad-library .native-section-heading { text-align: center; max-width: 560px; margin: 0 auto; }
.macad-card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; max-width: 1060px; margin: 40px auto 0; }
.macad-card { background: #ffffff; border: 1px solid #e6e3da; border-radius: 16px; padding: 24px 22px 20px; display: flex; flex-direction: column; gap: 10px; text-decoration: none; transition: border-color .15s ease, transform .15s ease; }
.macad-card:hover, .macad-card:focus-visible { border-color: #17382c; transform: translateY(-2px); }
.macad-card-kind { font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; color: #17382c; }
.macad-card h3 { margin: 0; font-size: 1.04rem; line-height: 1.35; color: #152019; }
.macad-card p { margin: 0; font-size: .86rem; line-height: 1.55; color: #5f625f; flex: 1; }
.macad-card-meta { font-size: .75rem; color: #8a8d89; }
.macad-boundary { padding: 0 0 72px; }
.macad-fine { max-width: 620px; margin: 0 auto; text-align: center; font-size: .82rem; line-height: 1.6; color: #8a8d89; }
.macad-fine a { color: #17382c; font-weight: 600; }
@media (max-width: 900px) {
  .macad-feature { grid-template-columns: 1fr; padding: 40px 28px; gap: 32px; }
  .macad-card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .macad-hero { padding: 36px 0 32px; }
  .macad-card-grid { grid-template-columns: 1fr; }
  .macad-featured { padding-bottom: 48px; }
}

/* --- Margo Academy shell (own nav, sign-in entry, search) --- */
.mash-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mash-nav { position: fixed; top: 0; left: 0; right: 0; z-index: 80; background: #f8f8f6; border-bottom: 1px solid #e8e5dc; }
.mash-bar { display: flex; align-items: center; gap: 20px; min-height: 66px; }
.mash-wordmark span { color: #17382c; }
.mash-links { display: flex; gap: 22px; list-style: none; margin: 0 auto; padding: 0; align-items: center; }
.mash-links > li > a, .mash-help-toggle { font-size: .92rem; font-weight: 600; color: #2c3630; text-decoration: none; background: none; border: 0; cursor: pointer; padding: 6px 2px; font-family: inherit; display: inline-flex; align-items: center; gap: 6px; }
.mash-links > li > a:hover, .mash-help-toggle:hover { color: #17382c; text-decoration: underline; text-underline-offset: 4px; }
.mash-caret { width: 7px; height: 7px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor; transform: rotate(45deg) translateY(-2px); display: inline-block; }
.mash-help { position: relative; }
.mash-help-menu { position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%); background: #ffffff; border: 1px solid #e6e3da; border-radius: 12px; padding: 8px; min-width: 210px; box-shadow: 0 14px 34px rgba(20,30,25,.12); display: grid; }
.mash-help-menu a { padding: 9px 12px; border-radius: 8px; font-size: .9rem; font-weight: 600; color: #2c3630; text-decoration: none; }
.mash-help-menu a:hover, .mash-help-menu a:focus-visible { background: #f1efe7; }
.mash-right { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.mash-links { margin-right: 0; }
.mash-search input { width: 168px; padding: 8px 14px 8px 34px; border: 1px solid #dcd9cf; border-radius: 999px; background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%235f625f' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") no-repeat 12px center; font-size: .88rem; font-family: inherit; color: #2c3630; }
.mash-search input:focus { outline: 2px solid #17382c; outline-offset: 1px; }
.mash-signin { font-size: .9rem; font-weight: 700; color: #ffffff; background: #17382c; padding: 9px 18px; border-radius: 999px; text-decoration: none; white-space: nowrap; }
.mash-signin:hover, .mash-signin:focus-visible { background: #0f2a1f; }
.mash-toggle { display: none; font-size: .82rem; font-weight: 700; color: #17382c; background: #ffffff; border: 1px solid #dcd9cf; border-radius: 999px; padding: 8px 16px; cursor: pointer; font-family: inherit; }
.mash-mobile { border-top: 1px solid #e8e5dc; background: #f8f8f6; padding: 8px 22px 16px; display: grid; }
.mash-mobile a { padding: 11px 2px; font-weight: 600; color: #2c3630; text-decoration: none; border-bottom: 1px solid #eeece3; font-size: .95rem; }
.mash-mobile a:last-child { border-bottom: 0; color: #17382c; }
.mash-search-empty { max-width: 1060px; margin: 26px auto 0; text-align: center; font-size: .9rem; color: #5f625f; }
.mash-search-empty a { color: #17382c; font-weight: 600; }
.mash-signin-section { padding: 0 0 72px; }
.mash-signin-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; max-width: 980px; margin: 0 auto; align-items: start; }
.mash-panel { background: #ffffff; border: 1px solid #e6e3da; border-radius: 18px; padding: 36px 32px; }
.mash-panel h2 { margin: 0 0 12px; font-size: 1.45rem; line-height: 1.25; color: #152019; }
.mash-panel-lede { margin: 0 0 22px; font-size: .95rem; line-height: 1.6; color: #5f625f; }
.mash-panel-dim { background: #f4f2ea; }
.mash-panel-dim .check-list { margin: 0 0 18px; }
.mash-panel-note { font-size: .84rem; color: #6d706b; margin: 0 0 16px; }
.mash-kicker-dark { color: #17382c; }
@media (max-width: 900px) {
  .mash-links, .mash-search { display: none; }
  .mash-toggle { display: inline-block; }
  .mash-signin-grid { grid-template-columns: 1fr; }
  .mash-panel { padding: 28px 22px; }
}

/* tighten academy hero rhythm (whitespace correction) */
.macad-hero h1 { margin: 10px 0 0; }
.macad-hero .lede { margin: 14px auto 0; }
.macad-hero-actions { margin-top: 22px; }
.macad-hero .eyebrow { margin-bottom: 0; }

/* brand lock inside mobile Explore overlay: identical to closed header */
.mega-menu .brand { display: inline-flex; align-items: center; text-decoration: none; color: inherit; }
.mega-menu .brand:hover { text-decoration: none; }
.mega-menu-top .brand { margin: 0; }

/* academy account page */
.mash-account-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 24px; max-width: 980px; margin: 0 auto; align-items: start; }
.mash-lessons { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.mash-lessons label { display: flex; gap: 10px; align-items: baseline; font-size: .92rem; color: #2c3630; cursor: pointer; }
.mash-lessons input { accent-color: #17382c; width: 16px; height: 16px; }
.mash-signin-fine { max-width: 46em; margin: 18px auto 0; font-size: .84rem; line-height: 1.6; color: #8a8d89; }
@media (max-width: 900px) { .mash-account-grid { grid-template-columns: 1fr; } }

/* netlify identity widget over academy shell */
.netlify-identity-widget { z-index: 120; }

/* Brand parity: open Explore overlay uses the same wordmark as the closed header */
.mega-menu .company-wordmark { font-family:"Iowan Old Style","Palatino Linotype","Book Antiqua",Georgia,serif; font-weight:500; line-height:1; letter-spacing:-.04em; color:#17382c; font-size:1.42rem; }
@media (max-width:640px) { .mega-menu .company-wordmark { font-size:1.22rem; } }
/* Responsive nav fix (15 Sep): the rule above hides the compact toggle under .mega-menu-ready at all widths,
   leaving the 641-1179px band with no navigation when JS is on. Higher-specificity restore for that band only. */
@media (max-width: 1179px) {
  html.mega-menu-ready .site-nav .nav-toggle.mega-menu-toggle,
  html body.home-showcase .site-nav .nav-toggle.mega-menu-toggle { display: inline-flex !important; }
}
