html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

:root {
  font-family: Montserrat;
  font-size: 1vw;
  --color-primary: #283a54;
  --color-secondary: #3e79e1;
  --color-text-muted: #6b6b73;
  --color-text-light: #8e8e93;
  --color-text-dark: #4a4a52;
  --color-card-border: #e3eef9;
  --color-card-bg: #f3f8fe;
  --color-banner-border: #dbeaff;
  --color-ap-border: #bbe3ff;
  --color-rail-gray: #b5b5bd;
  --color-guarantee-accent: #1e4ba3;
  --color-guarantee-green: #1e8a3a;
  --color-ask-accent: #c41e3a;
  --color-ask-border: #f4cdd4;
  --color-ask-bg-end: #fdf4f5;
}

#content {
  min-height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overflow-y: auto;
}

.flex {
  display: flex;
}

.col {
  flex-direction: column;
}

.row {
  flex-direction: row;
}

.even {
  justify-content: space-evenly;
}

.grow {
  flex: 1;
}

.bold {
  font-weight: 500;
}

.gradient {
  background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-secondary) 100%);
}

.container {
  width: 100%;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  overflow-y: auto;
}

.primary-text {
  color: var(--color-primary);
}

.sub-text {
  font-size: 2.5rem;
  margin-top: -0.5rem;
}

/* Header */
.header {
  height: 9rem;
}

.header-title {
  flex: 1;
  padding-left: 4rem;
  padding-bottom: 0.6rem;
  padding-top: 0.6rem;
  font-size: 2.5rem;
  font-weight: 500;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.header > .left {
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: end;
  padding-top: 1rem;
}

.header > .right {
  color: white;
  width: 50%;
  box-sizing: border-box;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 0 3.2rem 1rem 0;
  gap: 0.2rem;
  font-weight: 500;
}

.header-tax-year {
  font-size: 2rem;
  white-space: nowrap;
}

.header-location {
  font-size: 2.8rem;
  line-height: 1.1;
  max-width: 95%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Main */
.main {
  padding: 1.6rem 3.2rem 1.2rem 3.2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  overflow-x: hidden;
  overflow-y: auto;
}

.banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  padding: 0.8rem 1.6rem;
  background: var(--color-card-bg);
  border: 1px solid var(--color-banner-border);
  border-radius: 0.8rem;
  flex: none;
}

.banner .banner-title {
  font-size: 1.8rem;
  font-style: italic;
  font-weight: 600;
  color: var(--color-primary);
  letter-spacing: 0.01em;
  text-align: center;
}

.banner .banner-motto {
  font-size: 1.3rem;
  color: var(--color-secondary);
  font-weight: 600;
  font-style: italic;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  flex: none;
}

/* Audit Defense Guarantee banner */
.guarantee-banner {
  position: relative;
  background: #fff;
  border: 0.15rem solid var(--color-card-border);
  border-radius: 1rem;
  padding: 1.4rem 20rem 1.4rem 1.8rem;
  flex: none;
}

.guarantee-banner::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0.4rem;
  background: linear-gradient(180deg, #3ad065, var(--color-guarantee-green));
  border-radius: 1rem 0 0 1rem;
}

.gb-eyebrow {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--color-guarantee-accent);
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.gb-headline {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--color-primary);
  letter-spacing: 0.02em;
  line-height: 1.2;
}

.gb-promise {
  font-size: 1.4rem;
  color: var(--color-primary);
  line-height: 1.4;
  margin-top: 0.5rem;
}

.gb-promise strong {
  color: var(--color-guarantee-accent);
  font-weight: 700;
}

.guarantee-mark {
  position: absolute;
  right: 1.4rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  filter: drop-shadow(0 0.2rem 0.3rem rgba(0, 0, 0, 0.15));
}

.guarantee-mark .shield {
  width: 6.4rem;
  height: 6.4rem;
  display: block;
  flex: none;
  position: relative;
  z-index: 2;
}

.guarantee-mark .shield-block {
  position: relative;
  background: linear-gradient(180deg, #3a7adb 0%, var(--color-guarantee-accent) 100%);
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.02em;
  border-radius: 0 0.6rem 0.6rem 0;
  padding: 0.6rem 1.6rem 0.6rem 2.2rem;
  margin-left: -1.4rem;
}

.guarantee-mark .shield-block .small {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.95;
}

.guarantee-mark .shield-block .big {
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  margin-top: 0.1rem;
}

/* Top-row media card grid */
.grid {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: minmax(0, 1fr);
  gap: 1.2rem;
  min-height: 0;
}

/* All We Ask In Return band */
.ask-band {
  flex: none;
  background: linear-gradient(180deg, #fff 0%, var(--color-ask-bg-end) 100%);
  border: 0.15rem solid var(--color-ask-border);
  border-radius: 1rem;
  padding: 0.8rem 1.4rem 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 1.2rem;
  align-items: stretch;
}

.ask-band-title {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.6rem;
  margin-bottom: 0.2rem;
  border-bottom: 1px solid var(--color-ask-border);
}

.ask-band-title h3 {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-ask-accent);
  margin: 0;
}

.ask-band-title .coverage {
  font-size: 1.2rem;
  color: var(--color-primary);
  font-style: italic;
  font-weight: 500;
}

.ask-band-title .coverage strong {
  font-style: normal;
  font-weight: 700;
  color: var(--color-ask-accent);
}

.ask-band .condition {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  font-size: 1.2rem;
  line-height: 1.3;
  color: var(--color-primary);
}

.ask-band .condition .lead {
  font-weight: 800;
  color: var(--color-ask-accent);
  font-size: 1.2rem;
  letter-spacing: 0.02em;
}

.tier-pills {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  align-self: center;
  padding-left: 1rem;
  border-left: 1px solid var(--color-ask-border);
}

.tier-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.3rem 0.7rem;
  background: #fff;
  border: 1px solid var(--color-ask-border);
  border-radius: 0.4rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-primary);
}

.tier-pill .check {
  color: var(--color-ask-accent);
  font-size: 1.1rem;
  font-weight: 900;
  line-height: 1;
}

.tier-pill .tier-name {
  margin-top: 0.1rem;
  font-size: 0.95rem;
}

.closing-disclaimer {
  font-size: 1rem;
  font-style: italic;
  color: var(--color-text-light);
  text-align: center;
  padding: 0.4rem 3.2rem 0;
  letter-spacing: 0.01em;
  flex: none;
}

.card {
  border: 0.15rem solid var(--color-card-border);
  border-radius: 1rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  min-height: 0;
}

.card .card-header {
  background: var(--color-primary);
  color: #fff;
  padding: 0.6rem 1.2rem;
  border-radius: 1rem 1rem 0 0;
  flex: none;
}

.card .card-header .card-title {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.card .card-body {
  padding: 0.8rem 1.2rem 1rem;
  font-size: 1.4rem;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.card .card-body p {
  margin: 0;
}

.card .card-body .lead {
  font-weight: 600;
  color: var(--color-primary);
}

.card .card-body .why {
  color: var(--color-secondary);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 0.2rem;
}

sup.fn {
  color: var(--color-secondary);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0 0.1rem;
}

.card .media {
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  background: var(--color-card-bg);
}

.card .media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card .media.aerial {
  max-height: 28rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card .media.aerial img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 100%;
  object-fit: contain;
  background: var(--color-card-bg);
}

/* Site-Level Substantiation card: all-white treatment so the SiteWize
   screenshot reads as the hero and the title feels like a caption. */
.card.site-sub {
  border: none;
}

.card.site-sub .card-header {
  background: #ffffff;
  color: var(--color-primary);
  text-align: center;
  padding: 0.8rem 1.2rem 0.4rem;
}

.card.site-sub .card-header .card-title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.card.site-sub .media {
  background: #ffffff;
  padding: 0.2rem 0.2rem 0;
}

.card.site-sub .media img {
  object-fit: contain;
  transform: scale(1.25);
  transform-origin: center center;
}

.card.media-card .card-body {
  flex: 0 0 auto;
  padding: 0.7rem 1.2rem;
}

/* Audit-protection block */
.ap-block {
  background: #fff;
  border: 0.15rem solid var(--color-ap-border);
  border-radius: 1rem;
  padding: 1rem 1.4rem 0.8rem;
  flex: none;
}

.ap-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--color-primary);
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 0.2rem;
}

.ap-sub {
  font-size: 1rem;
  color: var(--color-text-muted);
  text-align: center;
  margin-bottom: 0.8rem;
}

.track {
  position: relative;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  padding: 0 0.8rem;
}

.rail {
  position: absolute;
  left: 3rem;
  right: 3rem;
  top: 1.6rem;
  height: 0.25rem;
  background: linear-gradient(
    90deg,
    var(--color-secondary) 0%, var(--color-secondary) 50%,
    var(--color-rail-gray) 50%, var(--color-rail-gray) 100%
  );
}

.node {
  text-align: center;
  position: relative;
  z-index: 1;
  padding: 0 0.2rem;
}

.dot {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  margin: 1rem auto 0.6rem;
  background: #fff;
  border: 0.25rem solid var(--color-secondary);
}

.node.csa.done .dot {
  background: var(--color-secondary);
  box-shadow: 0 0 0 0.35rem var(--color-ap-border);
}

.node.csa.current .dot {
  background: #fff;
  box-shadow: 0 0 0 0.35rem var(--color-ap-border);
}

.node.irs .dot {
  border-color: var(--color-rail-gray);
}

.stage {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-light);
}

.node.csa .stage {
  color: var(--color-secondary);
}

.node .label {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-primary);
  line-height: 1.15;
}

.node.irs .label {
  color: var(--color-text-muted);
  font-weight: 500;
}

.phase-labels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.phase-labels .csa {
  color: var(--color-secondary);
  text-align: center;
  border-top: 0.25rem solid var(--color-secondary);
  padding-top: 0.4rem;
  margin-right: 0.6rem;
}

.phase-labels .irs {
  color: var(--color-text-light);
  text-align: center;
  border-top: 0.25rem solid var(--color-rail-gray);
  padding-top: 0.4rem;
  margin-left: 0.6rem;
}

.footnotes {
  margin-top: 0.8rem;
  border-top: 1px solid var(--color-card-border);
  padding-top: 0.6rem;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--color-text-dark);
  letter-spacing: 0.01em;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.2rem;
}

.footnotes .fn-item {
  margin: 0;
  padding: 0;
}

.footnotes .fn-num {
  color: var(--color-secondary);
  font-weight: 700;
  margin-right: 0.3rem;
}

.footnotes .cite {
  font-weight: 700;
  color: var(--color-primary);
}

/* Footer */
footer {
  margin-top: auto;
}

.footer-container {
  padding-left: 5%;
  padding-right: 5%;
  padding-bottom: 2%;
}

.footer-left {
  justify-content: left;
  align-items: center;
  min-width: 50%;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.footer-right {
  justify-content: right;
  align-items: center;
  min-width: 50%;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.csa-logo-container {
  display: flex;
  flex-direction: column;
  align-items: end;
}

.csa-cpy-txt {
  font-size: 1rem;
  margin-top: -0.5rem;
}
