/* Agivey: shared stylesheet (used by agivey.com and agiveyit.com).
   System fonts only: the site's Content-Security-Policy does not allow web fonts. */

:root {
  color-scheme: light dark;
  --bg: #eef2f1;
  --panel: #f8faf9;
  --field-bg: #ffffff;
  --ink: #17252b;
  --muted: #4d6068;
  --line: #c9d6d4;
  --field: #6a7f86;
  --river: #1f6f78;
  --river-hover: #185861;
  --on-river: #ffffff;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1c20;
    --panel: #15262b;
    --field-bg: #0f1c20;
    --ink: #e4ecea;
    --muted: #9fb3b8;
    --line: #27393f;
    --field: #5f7880;
    --river: #6bbcc3;
    --river-hover: #8ad0d6;
    --on-river: #0f1c20;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body {
  font: 1.0625rem/1.65 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-text-size-adjust: 100%;
}
a { color: var(--ink); text-decoration-color: var(--river); text-underline-offset: 0.2em; text-decoration-thickness: 2px; }
a:focus-visible, .btn:focus-visible { outline: 2px solid var(--river); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: 0.75rem; top: -4rem; padding: 0.5rem 0.9rem; background: var(--ink); color: var(--bg); z-index: 10; }
.skip:focus { top: 0.75rem; }

.wrap { max-width: 66rem; margin: 0 auto; padding-left: 1.5rem; padding-right: 1.5rem; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.5rem; padding-top: 1.1rem; padding-bottom: 1.1rem; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink); text-decoration: none; font-family: var(--serif); font-weight: 600; font-size: 1.2rem; }
.brand svg { width: 2rem; height: auto; }
.brand .river { stroke: var(--river); }
.site-header nav { margin-left: auto; }
.site-header nav a { margin-left: 1.5rem; padding: 0.25rem 0; color: var(--muted); text-decoration: none; border-bottom: 2px solid transparent; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--river); }

@media (max-width: 30rem) {
  .site-header .wrap { gap: 0.5rem 1rem; }
  .site-header nav a { margin-left: 1rem; }
}

/* Type */
h1, h2, h3 { margin: 0; }
h1, h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.25rem, 1.3rem + 3.8vw, 3.75rem); line-height: 1.08; }
h2 { font-size: clamp(1.45rem, 1.15rem + 1vw, 1.85rem); line-height: 1.2; }
h3 { font-size: 1.125rem; line-height: 1.3; font-weight: 650; }
p, ul { margin: 0 0 1.1rem; max-width: 38rem; color: var(--muted); }
p:last-child, ul:last-child { margin-bottom: 0; }
strong { color: var(--ink); font-weight: 600; }
.lede { max-width: 40rem; margin: 1.25rem 0 0; font-size: 1.25rem; line-height: 1.5; color: var(--ink); }
.rule { width: 3.5rem; height: 3px; margin: 1.75rem 0 0; border: 0; background: var(--river); border-radius: 2px; }

/* Buttons */
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem 1rem; margin-top: 2rem; }
.btn { display: inline-block; padding: 0.8rem 1.4rem; border: 2px solid var(--river); border-radius: 4px; background: var(--river); color: var(--on-river); font: inherit; font-weight: 600; line-height: 1.2; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--river-hover); border-color: var(--river-hover); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: transparent; border-color: var(--ink); }

/* Hero (home pages) and page heads (inner pages) */
.hero { padding-top: clamp(2.5rem, 7vw, 5.5rem); padding-bottom: clamp(2.5rem, 7vw, 5.5rem); }
.hero .wrap { display: grid; gap: 2.5rem; align-items: center; }
@media (min-width: 56rem) {
  .hero .wrap.has-visual { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 4rem; }
}
.page-head { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: clamp(2.5rem, 6vw, 4rem); }
.page-head h1 { font-size: clamp(2.1rem, 1.3rem + 3vw, 3.25rem); }

/* Content sections: heading on the left, text on the right */
.sec { padding-top: clamp(2.5rem, 6vw, 4.5rem); padding-bottom: clamp(2.5rem, 6vw, 4.5rem); border-top: 1px solid var(--line); }
.sec .wrap { display: grid; gap: 1.1rem 4rem; }
@media (min-width: 56rem) {
  .sec .wrap.split { grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); }
}
.sec .wrap > h2 { align-self: start; }
.sec-body > p { max-width: 38rem; }

/* Open columns (home page, outcomes) */
.cols { display: grid; gap: 2rem; margin-top: 0.75rem; }
@media (min-width: 46rem) { .cols { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem; } }
.cols > div { padding-top: 1rem; border-top: 3px solid var(--river); }
.cols h3 { margin-bottom: 0.5rem; }
.cols p { max-width: none; font-size: 1rem; }
.sec .wrap.outcomes { display: block; margin-top: 3rem; }
.sec .wrap.outcomes .cols { margin-top: 0; }
.more { margin-top: 2rem; }
.note { margin-top: 1.25rem; }

/* The level stack: the architecture diagram */
.stack { display: grid; grid-template-columns: minmax(0, 1fr); margin: 0; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--panel); }
.stack ul.levels { list-style: none; display: grid; gap: 1px; margin: 0; padding: 0; max-width: none; background: var(--line); }
.stack .levels li { display: grid; grid-template-columns: 6.75rem minmax(0, 1fr); gap: 1rem; margin: 0; padding: 0.95rem 1.1rem; background: var(--panel); color: var(--muted); font-size: 0.975rem; line-height: 1.5; }
.stack .lv { font-family: var(--serif); font-weight: 600; font-size: 1.05rem; color: var(--ink); }
.stack .band { max-width: none; margin: 0; padding: 0.8rem 1.1rem; background: var(--river); color: var(--on-river); font-weight: 600; font-size: 0.975rem; line-height: 1.4; }
.stack figcaption { grid-column: 1 / -1; max-width: none; margin: 0; padding: 0.7rem 1.1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.9rem; }
@media (min-width: 34rem) {
  .stack { grid-template-columns: minmax(0, 1fr) 3.25rem; }
  .stack ul.levels { grid-template-rows: repeat(4, 1fr); }
  .stack .levels li { align-items: center; }
  .stack .band { writing-mode: vertical-rl; text-align: center; padding: 1.5rem 0.5rem; letter-spacing: 0.01em; }
}
.sec-body .stack { margin: 1.75rem 0; }
.stack.roomy .levels li { grid-template-columns: 8rem minmax(0, 1fr); padding: 1.2rem 1.4rem; font-size: 1.025rem; }
@media (max-width: 33.99rem) {
  .stack .levels li, .sec-body .stack { margin: 1.75rem 0; }
.stack.roomy .levels li { grid-template-columns: 1fr; gap: 0.15rem; }
}

/* Contact page */
.contact-grid { display: grid; gap: 3rem; padding-bottom: clamp(3rem, 7vw, 5rem); }
@media (min-width: 56rem) {
  .contact-grid { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 4.5rem; align-items: start; }
}
.form-panel { padding: clamp(1.25rem, 4vw, 2.25rem); border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.form-panel h2 { margin-bottom: 1.5rem; }
.fields { display: grid; gap: 1.25rem; }
@media (min-width: 40rem) {
  .fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fields .full { grid-column: 1 / -1; }
}
label { display: block; margin-bottom: 0.35rem; font-weight: 600; color: var(--ink); }
.hint { display: block; margin-top: 0.1rem; font-weight: 400; font-size: 0.95rem; color: var(--muted); }
input, textarea { display: block; width: 100%; padding: 0.7rem 0.8rem; border: 1px solid var(--field); border-radius: 4px; background: var(--field-bg); color: var(--ink); font: inherit; line-height: 1.4; }
textarea { min-height: 9.5rem; resize: vertical; }
input:focus-visible, textarea:focus-visible { outline: 2px solid var(--river); outline-offset: 2px; border-color: var(--river); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; margin-top: 1.5rem; }
.form-foot p { margin: 0; font-size: 0.95rem; max-width: 24rem; }

.aside { padding-left: 1.5rem; border-left: 3px solid var(--river); }
.aside h2 { margin-bottom: 0.75rem; font-size: 1.35rem; }
.aside dl { margin: 1.25rem 0 1.5rem; }
.aside dt { margin-top: 1.1rem; font-weight: 600; color: var(--ink); }
.aside dd { margin: 0.15rem 0 0; }
.aside dd a { font-size: 1.1rem; overflow-wrap: anywhere; }

/* Plain list in a ruled grid (IT services) */
.cover { list-style: none; display: grid; gap: 0 3rem; margin: 0; padding: 0; max-width: none; }
@media (min-width: 40rem) { .cover { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.cover li { margin: 0; padding: 0.95rem 0; border-top: 1px solid var(--line); color: var(--ink); }

/* Call to action band */
.cta .wrap { display: block; }
.cta h2 { margin-bottom: 0.75rem; }
.cta .actions { margin-top: 1.5rem; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); font-size: 0.925rem; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 2rem; padding-top: 1.75rem; padding-bottom: 2.25rem; }
.site-footer p { margin: 0; max-width: none; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--ink); }

/* Form feedback */
:root { --danger: #9b1c1c; }
@media (prefers-color-scheme: dark) { :root { --danger: #ff9f9f; } }
.form-error { margin: 1.25rem 0 0; padding: 0.8rem 1rem; border-left: 4px solid var(--danger); background: var(--field-bg); color: var(--ink); max-width: none; }
.form-error[hidden] { display: none; }
.btn[disabled] { opacity: 0.7; cursor: progress; }

/* IT: what is covered (grouped rows) */
.groups { margin-top: 0.5rem; }
.group { display: grid; gap: 0.9rem 4rem; padding-top: 1.75rem; padding-bottom: 1.75rem; border-top: 1px solid var(--line); }
@media (min-width: 56rem) { .group { grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); } }
.group h3 { font-family: var(--serif); font-size: 1.3rem; font-weight: 600; letter-spacing: -0.005em; }
.group ul { max-width: 42rem; margin: 0; padding-left: 1.15rem; }
.group li { margin-bottom: 0.65rem; color: var(--muted); }
.group li:last-child { margin-bottom: 0; }
.intro { margin-bottom: 1.25rem; }

/* IT: where it works */
.area { display: grid; gap: 2rem; margin-top: 1.75rem; }
@media (min-width: 48rem) { .area { grid-template-columns: minmax(9rem, 11rem) minmax(0, 1fr); gap: 3rem; align-items: start; } }
.towns { list-style: none; columns: 2; margin: 0; padding: 0; max-width: none; }
@media (min-width: 48rem) { .towns { columns: 1; } }
.towns li { margin: 0 0 0.4rem; color: var(--ink); break-inside: avoid; }
.towns li::marker { content: ""; }
.areamap { margin: 0; }
.areamap svg { display: block; width: 100%; height: auto; }
.areamap .disc { fill: var(--river); fill-opacity: 0.1; stroke: var(--river); stroke-width: 2; }
.areamap .reach { stroke: var(--river); stroke-width: 2; stroke-dasharray: 6 6; fill: none; }
.areamap text { font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; font-size: 15px; fill: var(--muted); paint-order: stroke; stroke: var(--bg); stroke-width: 4px; stroke-linejoin: round; }
.areamap .dot { fill: var(--muted); }
.areamap .major .dot { fill: var(--ink); }
.areamap .major text { font-size: 17px; font-weight: 600; fill: var(--ink); }
.areamap .home .dot { fill: var(--river); stroke: var(--bg); stroke-width: 3px; }
.areamap .home text { font-size: 20px; font-weight: 700; fill: var(--ink); }
.areamap .reach-label { font-style: italic; }
.areamap figcaption { margin-top: 0.6rem; font-size: 0.9rem; color: var(--muted); }
@media (max-width: 40rem) {
  .areamap .minor { display: none; }
  .areamap text { font-size: 22px; }
  .areamap .major text { font-size: 24px; }
  .areamap .home text { font-size: 27px; }
}
