/* Upstate Insurance Consultants — static rebuild of the Squarespace 7.0 template.
   Values (sizes, colors, spacing) measured from the live site at 1440px wide. */

@font-face {
  font-family: "Actor";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/actor-latin.woff2") format("woff2");
}

:root {
  --text: #777;
  --dark: #111;
  --heading: #222;
  --nav: #999;
  --rule: #e4e4e4;
  --green: #41a62a;
  --display: "Actor", "Trebuchet MS", Arial, sans-serif;
  --body: Arial, Helvetica, sans-serif;
  --gutter: 17px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font: 14px/1.6 var(--body);
  color: var(--text);
  background: #f2f2f2 url("/assets/img/concrete-texture.png") repeat;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--dark); text-decoration: none; }
a:hover { color: #555; }
a.tel { color: inherit; }

p { margin: 0 0 14px; }
p:last-child { margin-bottom: 0; }

h2 {
  font: 400 21px/1.2 var(--display);
  letter-spacing: 1px;
  color: var(--heading);
  margin: 0 0 15.75px;
}

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: -9999px; top: 0; background: #fff; padding: 8px 12px; z-index: 100; }
.skip-link:focus { left: 8px; top: 8px; }

/* ---------- Canvas (white page on textured background) ---------- */
.canvas {
  max-width: 1140px;
  margin: 0 auto;
  padding: 60px;
  background: #fff;
  box-shadow: 0 0 40px rgba(0, 0, 0, .05);
  min-height: 100vh;
}

/* ---------- Header ---------- */
.site-header { margin-bottom: 21px; position: relative; }
.logo { display: block; width: 965px; max-width: 100%; }
.logo img { width: 100%; }

.main-nav { text-align: right; }
.main-nav ul { list-style: none; margin: 0; padding: 0; }
.main-nav li, .foot-nav li { display: inline-block; }
.main-nav a,
.foot-nav a {
  display: inline;   /* inline like the original so padding doesn't add to header height */
  font: 400 14px/1.6 var(--display);
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--nav);
  padding: 8.25px 16.5px;
}
.main-nav li:last-child a { padding-right: 0; }
.main-nav a:hover, .foot-nav a:hover { color: #555; }
.main-nav a[aria-current="page"] { color: var(--dark); }
.site-header .main-nav { line-height: 23.4px; }

.nav-toggle, .nav-close { display: none; }

.page-divider { border: 0; border-bottom: 1px solid var(--rule); margin: 0 -60px; height: 0; }

/* ---------- Content grid (Squarespace 12-col equivalent) ---------- */
main { margin: 19px 0; }
.row { display: flex; margin: 0 calc(var(--gutter) * -1); }
.col { padding: 0; min-width: 0; }
.span-3  { flex: 0 0 25%; }
.span-4  { flex: 0 0 33.3333%; }
.span-5  { flex: 0 0 41.6667%; }
.span-6  { flex: 0 0 50%; }
.span-7  { flex: 0 0 58.3333%; }
.span-8  { flex: 0 0 66.6667%; }
.span-12 { flex: 0 0 100%; }
.block { padding: 15px var(--gutter); }
main > .row:first-of-type > .col:first-child > .block:first-child,
main > .row:first-of-type > .col > .block:first-child { padding-top: 0; }

hr.rule { border: 0; height: 1px; background: var(--rule); margin: 14px 0; }

/* Images & captions */
figure { margin: 0; }
figure.center img, figure.center { margin-left: auto; margin-right: auto; }
figcaption { font-size: 12px; line-height: 1.68; padding-top: 18px; }
figcaption p { margin: 0 0 12px; }
figcaption.under { color: var(--text); }

figure.overlay { position: relative; }
figure.overlay figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, .7);
  color: #ddd;
  padding: 18px;
}
figure.overlay figcaption strong { color: #fff; }
figure.overlay figcaption a { color: #fff; text-decoration: underline; }

.carrier-logos .block { display: flex; align-items: flex-start; padding-top: 4px; }

/* Contact */
.map-embed { position: relative; width: 100%; aspect-ratio: 527 / 360; background: #eee; }
.map-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: grayscale(1); }

.form .field { margin-bottom: 18px; }
.form fieldset { border: 0; padding: 0; margin: 0 0 18px; }
.form legend, .form .title { font-size: 14px; padding: 0; color: var(--text); }
.form .name-row { display: flex; gap: 2%; }
.form .name-row > div { flex: 1; }
.form label { display: block; font-size: 12px; color: var(--text); }
.form .title + label, .form .req { font-size: 12px; }
.form .req { color: #aaa; margin-left: 4px; }
.form .field > label.title { font-size: 14px; }
.form input[type=text], .form input[type=email], .form textarea {
  width: 100%;
  padding: 10px;
  font: 14px sans-serif;
  color: #000;
  background: #fafafa;
  border: 1px solid #a9a9a9;
  border-radius: 0;
}
.form textarea { height: 100px; resize: vertical; }
.form button {
  font: 14px sans-serif; color: #222; background: #efefef;
  border: 1px solid #767676; border-radius: 2px; padding: 1px 6px; cursor: pointer;
}
.form .hp { position: absolute; left: -9999px; }
.form .cf-turnstile { margin: 0 0 18px; max-width: 100%; }
.form .cf-turnstile iframe { max-width: 100%; }
.form-status { margin-top: 12px; }

/* ---------- Footer ---------- */
.site-footer { margin-top: 0; position: relative; line-height: 30px; }
.site-footer::before { content: ""; display: block; border-top: 1px solid var(--rule); margin: 0 -60px 55px; }
.foot-nav { text-align: right; }
.foot-nav ul { list-style: none; margin: 0; padding: 0; }

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 40px 0; }

/* ---------- Tablet ---------- */
@media (max-width: 1140px) {
  .canvas { box-shadow: none; }
}

/* ---------- Mobile (matches Squarespace's 640px breakpoint) ---------- */
@media (max-width: 640px) {
  body { font-size: 15px; }
  .canvas { padding: 30px; }
  .site-header { margin-bottom: 30px; min-height: 72px; display: flex; align-items: flex-start; justify-content: space-between; }
  .logo { width: 247px; }
  .page-divider { margin: 0 -30px; }
  main { margin: 30px 0; }
  .row { display: block; margin: 0; }
  .block { padding: 15px 0; }
  .carrier-logos .row { display: flex; flex-wrap: wrap; }
  .carrier-logos .col { flex: 0 0 50%; }
  .carrier-logos .block { padding: 10px; }
  .site-footer { margin-top: 0; }
  .site-footer::before { margin: 0 -30px 30px; }
  .foot-nav { text-align: center; }
  .foot-nav ul { display: block; }

  /* Hamburger + full-screen menu, like the original */
  .nav-toggle, .nav-close {
    display: block; background: none; border: 0; padding: 0; cursor: pointer; color: var(--nav);
  }
  .nav-toggle svg { width: 30px; height: 30px; }
  .site-header .main-nav {
    display: none; position: fixed; inset: 0; z-index: 50; background: #fff;
    padding: 30px; margin: 0; text-align: left; overflow-y: auto;
  }
  .site-header .main-nav.open { display: block; }
  .nav-close { position: absolute; right: 30px; top: 30px; }
  .nav-close svg { width: 28px; height: 28px; }
  .site-header .main-nav ul { display: block; margin-top: 60px; }
  .site-header .main-nav li { display: block; }
  .site-header .main-nav a { display: block; padding: 8px 0; font-size: 17px; }
  figure.overlay figcaption { position: static; }
}
