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

:root {
  --bg: #e8e8e2;
  --fg: #363636;
  --gutter: minmax(72px, 1fr);
  --content: minmax(0, 4fr);
  --header-height: 72px;
  --content-padding-x: 1.25rem;
}

html,
body {
  margin: 0;
  height: 100%;
}

body {
  background: var(--fg);
  color: var(--fg);
  font-family: "Courier New", Courier, monospace;
}

.site {
  display: grid;
  grid-template-columns: var(--gutter) var(--content) var(--gutter);
  grid-template-rows: var(--header-height) 1fr 1fr;
  min-height: 100dvh;
  gap: 1px;
  background: var(--fg);
}

.site:not(.site--single-main) {
  grid-template-rows: var(--header-height) 1fr min-content min-content min-content min-content;
}

.cell {
  background: var(--bg);
  min-height: 0;
}

.cell--gutter {
  min-width: 0;
}

.cell--gutter-tl {
  grid-column: 1;
  grid-row: 1;
}

.cell--header {
  grid-column: 2;
  grid-row: 1;
  padding: 0 var(--content-padding-x);
}

.cell--gutter-tr {
  grid-column: 3;
  grid-row: 1;
}

.cell--projects-panel {
  grid-column: 1;
  grid-row: 2 / -1;
  padding: 1.25rem 0.75rem;
  overflow: auto;
}

.cell--section-primary {
  grid-column: 2;
  grid-row: 2;
}

.cell--gutter-r2 {
  grid-column: 3;
  grid-row: 2;
}

.cell--section-leads {
  grid-column: 2;
  grid-row: 3;
}

.cell--gutter-r3 {
  grid-column: 3;
  grid-row: 3;
}

.cell--section-pricing {
  grid-column: 2;
  grid-row: 4;
}

.cell--gutter-r4 {
  grid-column: 3;
  grid-row: 4;
}

.cell--section-faq {
  grid-column: 2;
  grid-row: 5;
  align-self: start;
}

.cell--gutter-r5 {
  grid-column: 3;
  grid-row: 5;
}

.cell--section-secondary {
  grid-column: 2;
  grid-row: 6;
}

.cell--gutter-r6 {
  grid-column: 3;
  grid-row: 6;
}

.site--single-main .cell--section-full {
  grid-column: 2;
  grid-row: 2 / -1;
}

.site--single-main .cell--gutter-r2 {
  grid-column: 3;
  grid-row: 2 / -1;
}

.cell--section {
  padding: 0;
}

.header__grid {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  height: 100%;
}

.header__logo {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  text-decoration: none;
}

.header__logo img {
  display: block;
  height: 28px;
  width: auto;
}

.header__nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1.5rem;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: 0.875rem;
  text-transform: lowercase;
}

.header__nav-link {
  color: var(--fg);
  text-decoration: none;
}

.header__nav-link:hover {
  text-decoration: underline;
}

.header__nav-link[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.section-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: repeat(6, 1fr);
  height: 100%;
  min-height: 0;
}

.section-grid--hero {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem var(--content-padding-x);
  overflow: hidden;
}

.hero__copy {
  margin: 0;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: clamp(1.25rem, 2.5vw, 2rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--fg);
  text-transform: lowercase;
}

.hero__line {
  display: block;
}

.hero__mockup {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  min-width: 0;
  height: 100%;
}

.hero__mockup-link {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.hero__mockup-link .browser-wrap {
  max-width: min(100%, 440px);
  transition: transform 0.15s ease;
}

.hero__mockup-link:hover .browser-wrap {
  transform: translateY(-2px);
}

.cell--section-primary {
  overflow: hidden;
}

.section-grid--leads {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem var(--content-padding-x);
  overflow: hidden;
}

.leads-feature__mockup {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  min-width: 0;
}

.leads-feature__copy {
  font-family: "Roboto Mono", "Courier New", monospace;
  text-transform: lowercase;
  color: var(--fg);
}

.leads-feature__title {
  margin: 0;
  font-size: clamp(1.25rem, 2.5vw, 2rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.leads-feature__sub {
  margin: 0.5rem 0 0;
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 400;
  line-height: 1.35;
  opacity: 0.85;
}

.section-grid--pricing {
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  align-content: start;
  padding: 1.5rem var(--content-padding-x);
  gap: 1rem;
}

.pricing__title {
  margin: 0;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 400;
  line-height: 1.15;
  color: var(--fg);
  text-transform: lowercase;
}

.pricing__card {
  max-width: 40rem;
  border: 1px solid var(--fg);
  padding: 1.25rem 1rem;
  font-family: "Roboto Mono", "Courier New", monospace;
  color: var(--fg);
  text-transform: lowercase;
}

.pricing__label {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.35;
}

.pricing__price {
  margin: 0.75rem 0 0;
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.02em;
}

.section-grid--faq {
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  align-content: start;
  height: auto;
  padding: 1.5rem var(--content-padding-x);
  gap: 1rem;
}

.faq__title {
  margin: 0;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 400;
  line-height: 1.15;
  color: var(--fg);
  text-transform: lowercase;
}

.faq__list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 40rem;
}

.faq__item {
  border: 1px solid var(--fg);
  background: var(--bg);
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: 0.875rem;
  color: var(--fg);
  text-transform: lowercase;
}

.faq__question {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  width: 100%;
  margin: 0;
  padding: 0.9rem 1rem;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.faq__icon {
  flex-shrink: 0;
  width: 1rem;
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.2;
  text-align: center;
}

.faq__icon::before {
  content: "+";
  display: block;
  transition: transform 0.2s ease;
}

.faq__item.is-open .faq__icon::before {
  content: "−";
}

.faq__question-text {
  flex: 1;
  line-height: 1.35;
}

.faq__answer-wrap[hidden] {
  display: none;
}

.faq__answer {
  margin: 0;
  padding: 0 1rem 0.9rem 2.75rem;
  line-height: 1.45;
  text-transform: none;
  opacity: 0.85;
}

.section-grid--lead {
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  align-content: start;
  padding: 1.5rem var(--content-padding-x);
}

.lead-form {
  max-width: 32rem;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: 0.875rem;
  text-transform: lowercase;
  color: var(--fg);
}

.lead-form__title {
  margin: 0;
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 400;
  line-height: 1.15;
}

.lead-form__intro {
  margin: 0.5rem 0 1.25rem;
  opacity: 0.75;
  line-height: 1.4;
  text-transform: none;
}

.lead-form__fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 1.25rem;
}

.lead-form__field {
  display: grid;
  gap: 0.35rem;
}

.lead-form__field--full {
  grid-column: 1 / -1;
}

.lead-form__label {
  font-size: 0.8125rem;
}

.lead-form__field input,
.lead-form__field textarea {
  width: 100%;
  margin: 0;
  padding: 0.5rem 0.65rem;
  border: 1px solid var(--fg);
  border-radius: 0;
  background: var(--bg);
  color: var(--fg);
  font: inherit;
  text-transform: none;
  resize: vertical;
}

.lead-form__field input:focus,
.lead-form__field textarea:focus {
  outline: 2px solid var(--fg);
  outline-offset: 1px;
}

.lead-form__submit {
  margin-top: 1.25rem;
  padding: 0.55rem 1.25rem;
  border: 1px solid var(--fg);
  border-radius: 0;
  background: var(--fg);
  color: var(--bg);
  font: inherit;
  cursor: pointer;
}

.lead-form__submit:hover {
  opacity: 0.85;
}

.projects-panel {
  height: 100%;
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: 0.875rem;
  text-transform: lowercase;
}

.projects-panel__label {
  margin: 0 0 0.75rem;
  color: var(--fg);
}

.projects-panel__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.projects-panel__link {
  display: block;
  padding: 0.25rem 0;
  color: var(--fg);
  text-decoration: none;
}

.projects-panel__link:hover {
  text-decoration: underline;
}

.projects-panel__link[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.section-grid--projects-main {
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  align-content: start;
  padding: 1.5rem var(--content-padding-x);
  gap: 0.5rem;
}

.section-grid--project {
  grid-template-columns: 1fr;
  grid-template-rows: auto 1fr auto;
  align-content: start;
  padding: 1.5rem var(--content-padding-x);
  gap: 1rem;
  min-height: 0;
}

.project-story {
  font-family: "Roboto Mono", "Courier New", monospace;
  font-size: 0.875rem;
  color: var(--fg);
  text-transform: lowercase;
  max-width: 40rem;
}

.project-story__date {
  margin: 0 0 0.5rem;
  opacity: 0.75;
}

.project-story__text {
  margin: 0;
  line-height: 1.5;
  text-transform: none;
}

.project-preview {
  min-height: min(65vh, 520px);
  height: 100%;
}

.project-preview iframe {
  width: 100%;
  height: 100%;
  min-height: min(65vh, 520px);
  border: 1px solid var(--fg);
  background: #fff;
  display: block;
}

.page-intro {
  display: grid;
  gap: 0.5rem;
  font-family: "Roboto Mono", "Courier New", monospace;
  text-transform: lowercase;
}

.page-external {
  color: var(--fg);
  font-size: 0.875rem;
  text-decoration: none;
}

.page-external:hover {
  text-decoration: underline;
}

.page-title {
  margin: 0.25rem 0 0;
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  font-weight: 400;
  line-height: 1.15;
  color: var(--fg);
}

.page-meta {
  margin: 0;
  font-size: 0.875rem;
  color: var(--fg);
  opacity: 0.75;
}

.page-external {
  margin-top: 0.25rem;
}

@media (max-width: 640px) {
  .cell--projects-panel {
    grid-row: 2;
    grid-column: 1 / -1;
    padding: 0.75rem var(--content-padding-x);
    border-bottom: none;
  }

  .projects-panel__list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0 1rem;
  }

  .site--single-main .cell--section-full {
    grid-row: 3;
    grid-column: 1 / -1;
  }

  .site--single-main .cell--gutter-r2 {
    display: none;
  }

  .cell--section-primary {
    grid-row: 3;
    grid-column: 1 / -1;
  }

  .cell--gutter-r3,
  .cell--gutter-r4,
  .cell--gutter-r5,
  .cell--gutter-r6 {
    display: none;
  }

  .cell--gutter-r2 {
    display: none;
  }

  .cell--section-leads {
    grid-row: 4;
    grid-column: 1 / -1;
  }

  .cell--section-pricing {
    grid-row: 5;
    grid-column: 1 / -1;
  }

  .cell--section-faq {
    grid-row: 6;
    grid-column: 1 / -1;
  }

  .cell--section-secondary {
    grid-row: 7;
    grid-column: 1 / -1;
  }

  .site:not(.site--single-main) {
    grid-template-rows: var(--header-height) min-content 1fr min-content min-content min-content min-content;
  }
}

@media (max-width: 640px) {
  .section-grid--hero {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 1.25rem;
    padding: 1.25rem var(--content-padding-x);
  }

  .hero__mockup {
    justify-content: center;
  }

  .hero__mockup-link .browser-wrap {
    max-width: 100%;
  }

  .section-grid--leads {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 1.25rem;
    padding: 1.25rem var(--content-padding-x);
  }

  .leads-feature__mockup {
    justify-content: center;
  }

  .section-grid--projects-main,
  .section-grid--project,
  .section-grid--pricing,
  .section-grid--faq,
  .section-grid--lead {
    padding: 1.25rem var(--content-padding-x);
  }

  .lead-form__fields {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  :root {
    --gutter: minmax(24px, 0.5fr);
    --content: minmax(0, 6fr);
    --header-height: 64px;
    --content-padding-x: 0.75rem;
  }

  .header__logo img {
    height: 22px;
  }
}
