/* siteports shared theme — brand tokens come from brand.css (generated per site) */
@import url('/assets/brand.css');
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--body-font); font-size: 17px; line-height: 1.7;
  color: #1c1c22; background: #fdfbf8; -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--heading-font); font-weight: 600; line-height: 1.18; margin: 0 0 0.5em; }
h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
h3 { font-size: 1.35rem; }
.wrap { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 760px; }

/* header */
.site-header {
  position: sticky; top: 0; z-index: 50; background: rgba(253, 251, 248, 0.94);
  backdrop-filter: blur(10px); border-bottom: 1px solid rgba(0,0,0,0.07);
}
.header-inner { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px 0 12px; }
.logo { font-family: var(--heading-font); font-size: 1.4rem; font-weight: 700; letter-spacing: 0.06em; color: #1c1c22; text-transform: uppercase; }
.logo:hover { text-decoration: none; }
.nav-list { display: flex; align-items: center; gap: 24px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; justify-content: center; }
.nav-list a, .nav-sub-toggle {
  color: #1c1c22; font-size: 0.95rem; font-family: var(--heading-font);
  background: none; border: 0; cursor: pointer; padding: 0;
}
.nav-list a:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 5px; }
.has-sub { position: relative; }
.sub {
  display: none; position: absolute; top: calc(100% + 10px); left: -14px; background: #fff;
  border-radius: 12px; box-shadow: 0 12px 40px rgba(0,0,20,0.14); list-style: none;
  padding: 10px 0; margin: 0; min-width: 200px; z-index: 60;
}
.sub::before { content: ""; position: absolute; top: -14px; left: 0; right: 0; height: 14px; }
.has-sub.open .sub, .has-sub:hover .sub { display: block; }
.sub a { display: block; padding: 8px 18px; }
.nav-toggle { display: none; }

/* heads & heroes */
.page-plain-head { padding: 56px 0 8px; }
.page-hero {
  background-size: cover; background-position: center; padding: 120px 0;
  position: relative; color: #fff;
}
.page-hero::before { content: ""; position: absolute; inset: 0; background: rgba(10,10,25,0.35); }
.page-hero .wrap { position: relative; }
.page-hero h1 { color: #fff; text-shadow: 0 2px 18px rgba(0,0,20,0.45); }

/* blog */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 30px; margin: 34px 0 60px; }
.post-card {
  background: #fff; border-radius: 14px; overflow: hidden; color: inherit;
  box-shadow: 0 6px 26px rgba(0,0,20,0.07); transition: transform 0.18s, box-shadow 0.18s;
  display: flex; flex-direction: column;
}
.post-card:hover { transform: translateY(-4px); box-shadow: 0 14px 40px rgba(0,0,20,0.12); text-decoration: none; }
.post-card img, .post-card .ph { height: 210px; object-fit: cover; width: 100%; background: linear-gradient(120deg, var(--accent), var(--accent2)); }
.pc-body { padding: 20px 22px 24px; }
.pc-body h2 { font-size: 1.15rem; margin: 4px 0 8px; }
.pc-excerpt { font-size: 0.92rem; color: #555; margin: 0; }
.post-meta { font-family: var(--heading-font); font-size: 0.8rem; letter-spacing: 0.05em; text-transform: uppercase; color: var(--accent); margin: 0 0 4px; }
.post-head { padding: 48px 0 10px; }
.post-hero { margin: 20px 0 30px; }
.post-hero img { border-radius: 14px; width: 100%; }
.pager { display: flex; justify-content: space-between; margin: 0 0 60px; font-family: var(--heading-font); }

/* prose (post/page bodies straight from WP) */
.prose { padding-bottom: 70px; }
.prose img { border-radius: 12px; margin: 1.2em auto; }
.prose figure { margin: 1.5em 0; }
.prose figcaption { font-size: 0.85rem; color: #777; text-align: center; margin-top: 6px; }
.prose blockquote {
  border-left: 3px solid var(--accent); margin: 1.5em 0; padding: 4px 0 4px 20px;
  font-style: italic; color: #444;
}
.prose iframe { max-width: 100%; border: 0; }
.prose .wp-block-button__link, .prose .wp-block-button a {
  display: inline-block; background: var(--accent2); color: #fff; padding: 12px 26px;
  border-radius: 999px; font-family: var(--heading-font); font-size: 0.95rem;
}
.prose table { border-collapse: collapse; width: 100%; overflow-x: auto; display: block; }
.prose td, .prose th { border: 1px solid rgba(0,0,0,0.12); padding: 8px 12px; }
.prose .wp-block-gallery, .prose .gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.prose .wp-block-gallery figure, .prose .gallery figure { margin: 0; }

/* related */
.related { max-width: 1140px; margin: 0 auto 70px; padding: 0 24px; }
.rel-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 22px; }
.rel-card { background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 5px 20px rgba(0,0,20,0.08); color: inherit; }
.rel-card img { height: 140px; width: 100%; object-fit: cover; }
.rel-card span { display: block; padding: 12px 16px 16px; font-size: 0.95rem; font-family: var(--heading-font); }
.rel-card:hover { text-decoration: none; transform: translateY(-3px); }

/* footer */
.site-footer { background: var(--accent2); color: rgba(255,255,255,0.85); padding: 40px 0; margin-top: 40px; font-size: 0.9rem; }

@media (max-width: 760px) {
  .header-inner { flex-direction: row; justify-content: space-between; padding: 14px 24px; }
  .nav-toggle { display: block; background: none; border: 0; font-size: 1.5rem; cursor: pointer; }
  .site-nav { display: none; position: absolute; top: 56px; left: 0; right: 0; background: #fff; box-shadow: 0 16px 30px rgba(0,0,20,0.12); padding: 18px 24px; }
  .site-nav.open { display: block; }
  .nav-list { flex-direction: column; align-items: flex-start; gap: 14px; }
  .sub { position: static; display: block; box-shadow: none; padding: 6px 0 0 16px; }
}

/* forms */
.join-form { max-width: 460px; display: grid; gap: 16px; margin: 2em 0; }
.join-form label { font-family: var(--heading-font); font-size: 0.92rem; font-weight: 600; }
.join-form input {
  width: 100%; padding: 12px 14px; border: 1.5px solid rgba(0,0,0,0.18); border-radius: 10px;
  font: inherit; margin-top: 6px;
}
.join-form input:focus { outline: 2px solid var(--accent); border-color: transparent; }
.join-form button {
  background: var(--accent); color: #fff; border: 0; padding: 14px 30px; border-radius: 999px;
  font-family: var(--heading-font); font-size: 1rem; font-weight: 600; cursor: pointer;
}
.join-form button:hover { filter: brightness(0.92); }
.join-status { font-weight: 600; min-height: 1.3em; }

/* post tags */
.post-tags { max-width: 760px; margin: 8px auto 60px; padding: 0 24px; display: flex; flex-wrap: wrap; gap: 10px; }
.post-tags a {
  display: inline-block; font-family: var(--heading-font); font-size: 0.78rem;
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--accent2);
  background: rgba(0,0,0,0.05); padding: 6px 14px; border-radius: 999px;
}
.post-tags a:hover { background: var(--accent); color: #fff; text-decoration: none; }

/* ---- forms (contact, join, download) ---- */
.site-form { max-width: 620px; margin: 10px 0 60px; }
.site-form .field { margin-bottom: 20px; }
.site-form label { display: block; font-family: var(--heading-font); font-size: 0.9rem; font-weight: 600; margin-bottom: 7px; color: #2a2a2a; }
.site-form input, .site-form textarea, .site-form select {
  width: 100%; font: inherit; padding: 13px 15px; border: 1.5px solid rgba(0,0,0,0.18);
  border-radius: 10px; background: #fff; color: inherit; transition: border-color .15s, box-shadow .15s;
}
.site-form textarea { min-height: 150px; resize: vertical; }
.site-form input:focus, .site-form textarea:focus, .site-form select:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}
.site-form .req { color: var(--accent); }
.site-form button {
  background: var(--accent2); color: #fff; border: 0; cursor: pointer;
  padding: 14px 34px; border-radius: 999px; font-family: var(--heading-font);
  font-size: 1rem; font-weight: 600; transition: filter .15s, transform .1s;
}
.site-form button:hover { filter: brightness(1.08); }
.site-form button:active { transform: translateY(1px); }
.site-form .form-status { min-height: 1.4em; margin-top: 14px; font-weight: 600; }
.site-form .form-status.ok { color: #217a3d; }
.site-form .form-status.err { color: #b23b3b; }
.contact-intro { font-size: 1.05rem; margin-bottom: 26px; }
.contact-details { margin: 0 0 30px; line-height: 1.9; }
.contact-details strong { font-family: var(--heading-font); }

/* overflow safety net: nothing in article bodies may blow out the viewport */
.prose { overflow-wrap: break-word; word-wrap: break-word; }
.prose pre { white-space: pre-wrap; word-break: break-word; max-width: 100%; overflow-x: auto; }
/* WP "Preformatted" block is prose, not code — render it as normal body text */
.prose pre.wp-block-preformatted {
  font-family: inherit; font-size: inherit; line-height: inherit;
  white-space: pre-wrap; background: none; padding: 0; margin: 0 0 1.2em;
}
.prose code, .prose kbd { white-space: pre-wrap; word-break: break-word; }
.prose table { display: block; overflow-x: auto; max-width: 100%; }
.prose img, .prose iframe, .prose video { max-width: 100%; height: auto; }
