/* =============================================================
   Template 1106_new_v1 — Stylesheet
   Self-contained · no framework · no external fonts.
   Content-first layout. Secondary labels are <span>, not headings.
   ============================================================= */

:root {
  --brand:   #16915e;
  --brand-d: #0f6f48;
  --brand-l: #e7f5ee;
  --head:    #15201b;
  --text:    #37433d;
  --text-2:  #6b766f;
  --bg:      #ffffff;
  --bg-2:    #f3f7f4;
  --bg-3:    #f1f6f3;
  --edge:    #e3ebe6;
  --edge-2:  #edf2ef;

  --ff:   system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --ff-h: Georgia, "Iowan Old Style", "Times New Roman", "Noto Serif", serif;
  --ff-m: ui-monospace, "SFMono-Regular", Consolas, Menlo, monospace;

  --rad-s: 6px;
  --rad-m: 10px;
  --rad-l: 16px;

  --sh-s: 0 1px 2px rgba(15, 40, 28, .06);
  --sh-m: 0 7px 24px rgba(15, 40, 28, .08);
  --sh-l: 0 18px 48px rgba(15, 40, 28, .12);

  --tr: .25s cubic-bezier(.4, 0, .2, 1);
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html, body, p, ul, ol, li, figure, blockquote, h1, h2, h3, h4 { margin: 0; padding: 0; }

html {
  height: 100%;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100%;
  font-family: var(--ff);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--brand); text-decoration: none; transition: color var(--tr); }
a:hover { color: var(--brand-d); }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 3px; }
::selection { background: var(--brand-l); color: var(--head); }
::-webkit-scrollbar { width: 9px; }
::-webkit-scrollbar-track { background: var(--bg-2); }
::-webkit-scrollbar-thumb { background: #bfccc5; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: #a0b0a8; }

.gone {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 22px;
}

/* ---- real headings: ONLY the article uses them --------------- */
h1, h2, h3, h4 {
  font-family: var(--ff-h);
  color: var(--head);
  font-weight: 700;
  line-height: 1.25;
}
h1 { font-size: clamp(1.85rem, 1.25rem + 2.4vw, 2.55rem); letter-spacing: -.012em; }

/* ---- span labels styled to look like section titles --------- */
.label {
  display: block;
  font-family: var(--ff);
  font-weight: 700;
  font-size: 1.18rem;
  color: var(--head);
  line-height: 1.3;
  margin-bottom: 16px;
}
.label--sm { font-size: 1rem; margin-bottom: 12px; }

/* ---- progress rail ------------------------------------------ */
.progress {
  position: fixed; inset: 0 auto auto 0;
  width: 0; height: 3px;
  background: linear-gradient(90deg, var(--brand), #4fd39c);
  z-index: 1200; transition: width .1s linear;
}

/* ---- masthead (slim, content sits right under it) ----------- */
.masthead {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--edge-2);
  transition: box-shadow var(--tr);
}
.masthead.pinned { box-shadow: 0 2px 16px rgba(15,40,28,.08); }
.masthead-row { display: flex; align-items: center; gap: 18px; height: 58px; }

.brand { display: inline-flex; align-items: center; }
.brand img { height: 30px; width: auto; }

.nav { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.nav-list { display: flex; align-items: center; gap: 4px; list-style: none; }
.nav-link {
  display: block; padding: 8px 13px;
  font-size: .9rem; font-weight: 500; color: var(--text);
  border-radius: var(--rad-s); transition: background var(--tr), color var(--tr);
}
.nav-link:hover { color: var(--brand); background: var(--brand-l); }

.nav-auth { display: flex; align-items: center; gap: 8px; }
.nav-signin { font-size: .9rem; font-weight: 600; color: var(--head); padding: 8px 6px; }
.nav-signin:hover { color: var(--brand); }

.burger { display: none; flex-direction: column; gap: 5px; padding: 9px; margin-left: auto; }
.burger span { display: block; width: 22px; height: 2px; background: var(--head); border-radius: 2px; transition: transform var(--tr), opacity var(--tr); }
.burger.x span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.x span:nth-child(2) { opacity: 0; }
.burger.x span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 820px) {
  .burger { display: flex; }
  .nav {
    position: absolute; inset: 58px 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 14px;
    padding: 18px 22px 24px; background: var(--bg);
    border-bottom: 1px solid var(--edge); box-shadow: var(--sh-l);
    transform: translateY(-12px); opacity: 0; pointer-events: none;
    transition: transform var(--tr), opacity var(--tr);
  }
  .nav.open { transform: none; opacity: 1; pointer-events: auto; }
  .nav-list { flex-direction: column; align-items: stretch; }
  .nav-auth { padding-top: 12px; border-top: 1px solid var(--edge); justify-content: flex-start; }
}

/* ---- content shell ------------------------------------------ */
.content { padding: 40px 0 72px; }
.lane { width: 100%; max-width: 760px; margin-inline: auto; }

/* ---- article (the only real content) ------------------------ */
.entry {
  background: var(--bg);
  border: 1px solid var(--edge-2);
  border-radius: var(--rad-l);
  box-shadow: var(--sh-s);
  padding: 44px;
}
@media (max-width: 620px) { .entry { padding: 26px 20px; border-radius: var(--rad-m); } }

.entry-head { margin-bottom: 28px; }
.entry-title { margin-bottom: 16px; }
.entry-facts { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; font-size: .82rem; color: var(--text-2); }
.fact { display: inline-flex; align-items: center; gap: 6px; }
.fact svg { flex: none; opacity: .6; }

/* table of contents (collapsible, inside article) */
.toc { margin-bottom: 28px; }
.toc-box { background: var(--bg-2); border: 1px solid var(--edge); border-radius: var(--rad-m); padding: 18px 22px; }
.toc-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.toc-key { color: var(--brand); font-size: .8rem; }
.toc-list ol { list-style: none; counter-reset: t; }
.toc-list li { counter-increment: t; margin-bottom: 7px; }
.toc-list li::before { content: counter(t) ". "; color: var(--brand); font-weight: 600; }
.toc-list a { color: var(--text); font-size: .9rem; }
.toc-list a:hover { color: var(--brand); }

/* article body — real H2/H3 live here */
.prose { font-size: 1.06rem; line-height: 1.82; color: var(--text); }
.prose > * + * { margin-top: 1.15em; }
.prose h2 { font-size: clamp(1.45rem, 1.1rem + 1.3vw, 1.75rem); margin-top: 1.9em; }
.prose h3 { font-size: 1.32rem; margin-top: 1.5em; }
.prose p { margin: 0 0 1.15em; }
.prose ul, .prose ol { margin: 0 0 1.15em; padding-left: 1.45em; }
.prose li { margin-bottom: .45em; }
.prose a { text-decoration: underline; text-underline-offset: 2px; text-decoration-color: rgba(22,145,94,.45); }
.prose a:hover { text-decoration-color: var(--brand); }
.prose img { border-radius: var(--rad-m); margin: 1.5em 0; }
.prose blockquote {
  border-left: 4px solid var(--brand); background: var(--brand-l);
  padding: 1em 1.3em; border-radius: 0 var(--rad-s) var(--rad-s) 0;
  font-style: italic; color: var(--head); margin: 1.5em 0; font-family: var(--ff-h);
}
.prose pre {
  background: #15241c; color: #e3efe8; padding: 1.15em 1.3em;
  border-radius: var(--rad-m); overflow-x: auto; font-family: var(--ff-m); font-size: .88rem; margin: 1.5em 0;
}
.prose code { font-family: var(--ff-m); font-size: .9em; background: var(--bg-2); padding: 2px 6px; border-radius: 4px; color: #126b46; }
.prose pre code { background: none; color: inherit; padding: 0; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: .95rem; }
.prose th, .prose td { padding: 11px 15px; border: 1px solid var(--edge); text-align: left; }
.prose th { background: var(--bg-2); font-weight: 600; color: var(--head); font-family: var(--ff); }

/* share */
.share { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--edge-2); }
.share-key { font-size: .86rem; font-weight: 600; color: var(--head); }
.share-set { display: flex; gap: 9px; }
.share-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--bg-2); border: 1px solid var(--edge); color: var(--text-2);
  transition: transform var(--tr), background var(--tr), color var(--tr), border-color var(--tr), box-shadow var(--tr);
}
.share-btn:hover { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-2px); box-shadow: 0 5px 14px rgba(22,145,94,.3); }

/* ---- comments (directly under article) ---------------------- */
.respond {
  background: var(--bg); border: 1px solid var(--edge-2);
  border-radius: var(--rad-l); box-shadow: var(--sh-s); padding: 32px; margin-top: 26px;
}

/* ---- forms & controls --------------------------------------- */
.form { margin-top: 6px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 15px; }
.form-cell { margin-bottom: 15px; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }

.field {
  width: 100%; padding: 12px 15px; font: inherit; font-size: .92rem; color: var(--text);
  background: var(--bg); border: 1px solid var(--edge); border-radius: var(--rad-m);
  transition: border-color var(--tr), box-shadow var(--tr);
}
.field::placeholder { color: #a4b0a9; }
.field:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-l); }
.area { resize: vertical; min-height: 130px; line-height: 1.6; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 24px; font: inherit; font-size: .92rem; font-weight: 600; border-radius: var(--rad-m);
  transition: transform var(--tr), background var(--tr), color var(--tr), box-shadow var(--tr), border-color var(--tr);
  white-space: nowrap;
}
.btn-fill { background: var(--brand); color: #fff; box-shadow: 0 4px 14px rgba(22,145,94,.24); }
.btn-fill:hover { background: var(--brand-d); color: #fff; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(22,145,94,.34); }
.btn-line { background: transparent; color: var(--brand); border: 1.5px solid var(--brand); padding: 8px 18px; }
.btn-line:hover { background: var(--brand); color: #fff; }
.btn-soft { background: var(--bg-2); color: var(--text); border: 1px solid var(--edge); }
.btn-soft:hover { background: var(--edge-2); color: var(--head); }
.btn-sq { width: 46px; padding: 0; flex: none; }
.btn-wide { width: 100%; }

/* ---- extras zone (everything else, pushed below content) ---- */
.extras { background: var(--bg-2); border-top: 1px solid var(--edge); padding: 56px 0; }

.contact {
  display: grid; grid-template-columns: 1fr 1.25fr; gap: 34px; align-items: start;
  background: var(--bg); border: 1px solid var(--edge); border-radius: var(--rad-l);
  box-shadow: var(--sh-s); padding: 34px; margin-bottom: 34px;
}
@media (max-width: 720px) { .contact { grid-template-columns: 1fr; gap: 22px; } }
.contact-note { font-size: .9rem; color: var(--text-2); }

.extras-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(248px, 1fr)); gap: 22px; }
.block { background: var(--bg); border: 1px solid var(--edge); border-radius: var(--rad-l); box-shadow: var(--sh-s); padding: 26px; }
.block-note { font-size: .85rem; color: var(--text-2); margin-bottom: 15px; }

.inline-form { display: flex; gap: 9px; }
.inline-form .field { flex: 1; }

.mini-list { list-style: none; }
.mini-list li a { display: block; padding: 11px 0; font-size: .88rem; color: var(--text); border-bottom: 1px solid var(--edge-2); transition: color var(--tr), padding-left var(--tr); }
.mini-list li:last-child a { border-bottom: 0; }
.mini-list li a:hover { color: var(--brand); padding-left: 4px; }

/* ---- footer ------------------------------------------------- */
.footer { background: var(--bg-3); border-top: 1px solid var(--edge); }
.footer-top { padding: 52px 0 36px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 34px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: 26px; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-brand img { height: 30px; width: auto; margin-bottom: 14px; }
.footer-copy { font-size: .82rem; color: var(--text-2); margin-bottom: 16px; max-width: 320px; }
.footer-nav { list-style: none; }
.footer-nav li { margin-bottom: 10px; }
.footer-nav a { font-size: .87rem; color: var(--text-2); }
.footer-nav a:hover { color: var(--brand); }
.footer-base { border-top: 1px solid var(--edge); padding: 18px 0; text-align: center; }
.footer-base p { font-size: .8rem; color: var(--text-2); }

/* ---- reworked social icons (square tiles, monoline glyphs) --- */
.socials { display: flex; gap: 10px; list-style: none; }
.socials a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: var(--rad-m);
  background: var(--bg-2); border: 1px solid var(--edge); color: var(--text-2);
  transition: transform var(--tr), background var(--tr), color var(--tr), border-color var(--tr);
}
.socials a:hover { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-3px); }
.socials svg { width: 18px; height: 18px; }

/* ---- back to top -------------------------------------------- */
.totop {
  position: fixed; right: 28px; bottom: 28px; width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg); border: 1px solid var(--edge); color: var(--head); border-radius: 12px;
  box-shadow: var(--sh-m); opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity var(--tr), visibility var(--tr), transform var(--tr), background var(--tr), color var(--tr); z-index: 900;
}
.totop.show { opacity: 1; visibility: visible; transform: none; }
.totop:hover { background: var(--brand); border-color: var(--brand); color: #fff; transform: translateY(-2px); }

/* ---- cookie ------------------------------------------------- */
.cookie {
  position: fixed; left: 0; right: 0; bottom: 0; background: var(--head); color: rgba(255,255,255,.86);
  padding: 16px 0; z-index: 1100; transform: translateY(100%); transition: transform .4s ease;
}
.cookie.show { transform: none; }
.cookie-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.cookie p { font-size: .85rem; line-height: 1.5; }
.cookie a { color: #6fe0ac; }
.cookie .btn { flex: none; }
@media (max-width: 600px) { .cookie-row { flex-direction: column; text-align: center; } }

/* ---- :target auth modals (markup lives at end of body) ------ */
.modal {
  position: fixed; inset: 0; z-index: 1300;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s ease;
}
.modal:target { opacity: 1; visibility: visible; }
.modal-veil { position: absolute; inset: 0; background: rgba(10,26,18,.55); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
.modal-card {
  position: relative; width: 100%; max-width: 410px;
  background: var(--bg); border-radius: var(--rad-l); box-shadow: var(--sh-l);
  padding: 34px; transform: translateY(14px) scale(.98); transition: transform .25s ease;
}
.modal:target .modal-card { transform: none; }
.modal-shut {
  position: absolute; top: 14px; right: 14px; width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center; border-radius: 8px;
  color: var(--text-2); font-size: 20px; line-height: 1; transition: background var(--tr), color var(--tr);
}
.modal-shut:hover { background: var(--bg-2); color: var(--head); }
.modal-note { font-size: .85rem; color: var(--text-2); margin-bottom: 18px; }
.modal-foot { margin-top: 16px; text-align: center; font-size: .85rem; color: var(--text-2); }

/* ---- reveal ------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

@media print {
  .masthead, .progress, .share, .respond, .extras, .totop, .cookie, .modal, .burger { display: none !important; }
  .lane { max-width: 100%; }
  .entry { border: 0; box-shadow: none; padding: 0; }
  body { font-size: 12pt; }
}
