
/* --------------------------------
   ROACHCRAFT
   general living conditions
-------------------------------- */

:root {
  --paper: #f8f7f3;
  --ink: #262521;
  --faded: #89867d;
  --line: #ddd9cf;
  --highlight: #e6e5d9;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Courier New", Courier, monospace;
  font-size: 16px;
  line-height: 1.7;
}

::selection {
  background: var(--highlight);
}

/* --------------------------------
   THE HOUSE
-------------------------------- */

.site {
  width: min(100% - 48px, 960px);
  margin: 0 auto;
}

.site-header {
  padding-top: 55px;
}

.site-name {
  display: inline-block;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.04em;
}

.dot {
  color: var(--faded);
  margin-left: 20px;
}

/* NAVIGATION */

.navigation {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 30px;
  margin-top: 30px;
}

.navigation a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.95rem;
}

.navigation a:hover {
  text-decoration: underline;
  text-underline-offset: 5px;
}

a:focus-visible,
summary:focus-visible {
  outline: 2px dashed var(--ink);
  outline-offset: 5px;
}

/* --------------------------------
   THE ENTRANCE
-------------------------------- */

.entryway {
  position: relative;
  min-height: 78vh;
  padding-top: clamp(110px, 17vh, 190px);
  padding-bottom: 130px;
  max-width: 650px;
}

.annotation {
  font-size: 0.72rem;
  color: var(--faded);
  letter-spacing: 0.02em;
  margin-bottom: 35px;
}

h1, h2, h3 {
  font-family: inherit;
  font-weight: normal;
}

.entryway h1 {
  font-size: 1.2rem;
  margin: 0 0 36px;
}

.greeting {
  max-width: 520px;
}

.greeting p {
  margin: 0 0 25px;
}

.enter-link {
  display: inline-block;
  margin-top: 22px;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 5px;
}

.enter-link:hover {
  background: var(--highlight);
}

/* A SMALL DISTURBANCE */

.corner {
  width: fit-content;
  margin-top: 110px;
  margin-left: auto;
  color: var(--faded);
  font-size: 0.75rem;
}

.corner summary {
  cursor: pointer;
  list-style: none;
}

.corner summary::-webkit-details-marker {
  display: none;
}

.corner summary:hover {
  text-decoration: underline;
}

.corner p {
  max-width: 260px;
  margin-top: 15px;
  color: var(--ink);
}

/* --------------------------------
   THE ROOMS
-------------------------------- */

.rooms {
  padding: 100px 0 140px;
  border-top: 1px solid var(--line);
}

.rooms h2 {
  font-size: 1.1rem;
  margin-bottom: 65px;
}

.room-list {
  max-width: 660px;
}

.room {
  padding: 25px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 40px;
}

.room h3 {
  margin: 0 0 5px;
  font-size: 1rem;
}

.room p {
  color: var(--faded);
  font-size: 0.85rem;
  margin: 0;
}

.index-note {
  margin-top: 70px;
  color: var(--faded);
  font-size: 0.75rem;
}

/* --------------------------------
   BOTTOM OF THE HOUSE
-------------------------------- */

.site-footer {
  padding: 30px 0 60px;
  color: var(--faded);
  font-size: 0.7rem;
}

/* --------------------------------
   SMALLER WINDOWS
-------------------------------- */

@media (max-width: 600px) {

  .site {
    width: calc(100% - 36px);
  }

  .site-header {
    padding-top: 30px;
  }

  .navigation {
    gap: 8px 18px;
  }

  .navigation a {
    font-size: 0.85rem;
  }

  .entryway {
    padding-top: 100px;
    padding-bottom: 80px;
  }

  .corner {
    margin-top: 90px;
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}


/* --------------------------------
   INTERIOR ROOMS
-------------------------------- */

.interior-page {
  max-width: 660px;
  padding-top: clamp(90px, 14vh, 160px);
  padding-bottom: 160px;
}

.interior-page h1 {
  font-size: 1.15rem;
  font-weight: bold;
  margin-bottom: 65px;
}

.page-content {
  line-height: 1.85;
}

.page-content p {
  margin-bottom: 30px;
}

.page-content h2 {
  font-size: 1rem;
  margin-top: 85px;
  margin-bottom: 30px;
}

.page-content img {
  max-width: 100%;
  height: auto;
}

.page-content a {
  color: var(--ink);
  text-underline-offset: 5px;
}

/* A quieter note tucked between thoughts */

.small-note {
  font-size: 0.75rem;
  color: var(--faded);
  margin: 70px 0;
}


/* --------------------------------
   INTERIOR PAGES
   places inside the house
-------------------------------- */

.interior-page {
  max-width: 660px;
  min-height: 65vh;
  padding-top: clamp(80px, 12vh, 150px);
  padding-bottom: 140px;
}

.interior-page h1 {
  margin: 0 0 70px;
  font-size: 1.25rem;
  font-weight: normal;
}

/* PHILOSOPHY */

.philosophy-copy {
  max-width: 610px;
  font-size: 0.95rem;
  line-height: 1.9;
}

.philosophy-copy > p {
  margin: 0 0 2.5rem;
}

/* thoughts that deserve a little more room */

.philosophy-copy blockquote {
  margin: 85px 0;
  padding: 5px 0 5px 25px;
  border-left: 1px solid var(--line);
}

.philosophy-copy blockquote p {
  margin: 0 0 1.5rem;
}

.philosophy-copy blockquote p:last-child {
  margin-bottom: 0;
}

/* the closing thoughts */

.philosophy-closing {
  margin-top: 100px;
}

.philosophy-closing p {
  margin: 0 0 2.5rem;
}

/* a tiny resident */

.resident-mark {
  width: fit-content;
  margin: 100px 0 0 auto;
  text-align: right;
}

.resident-mark summary {
  list-style: none;
  cursor: pointer;
  font-size: 1.1rem;
}

.resident-mark summary::-webkit-details-marker {
  display: none;
}

.resident-mark p {
  color: var(--faded);
  font-size: 0.75rem;
  margin-top: 10px;
}

/* SMALLER SCREENS */

@media (max-width: 600px) {
  .interior-page {
    padding-top: 80px;
    padding-bottom: 90px;
  }

  .interior-page h1 {
    margin-bottom: 50px;
  }

  .philosophy-copy blockquote {
    margin: 60px 0;
    padding-left: 16px;
  }

  .philosophy-closing {
    margin-top: 75px;
  }
}


/* --------------------------------
   COCKROACH
   the resident's quarters
-------------------------------- */

.cockroach-page {
  max-width: 860px;
}

/* INTRODUCTION */

.resident-intro {
  display: grid;
  grid-template-columns: 1fr minmax(190px, 320px);
  align-items: center;
  gap: clamp(30px, 6vw, 90px);
  margin-bottom: 150px;
}

.resident-hello h1 {
  margin-bottom: 65px;
}

.resident-hello p {
  margin: 0 0 30px;
}

.resident-portrait {
  margin: 0;
  text-align: center;
}

.resident-portrait img {
  display: block;
  width: 100%;
  height: auto;
  transform: rotate(-4deg);
  transition: transform 0.3s ease;
}

.resident-portrait img:hover {
  transform: rotate(2deg) translateY(-5px);
}

.resident-portrait figcaption {
  margin-top: 20px;
  font-size: 0.7rem;
  color: var(--faded);
}

/* SECTIONS */

.resident-section {
  max-width: 620px;
  margin-bottom: 145px;
}

.resident-section h2 {
  margin: 0 0 45px;
  font-size: 1rem;
  font-weight: normal;
}

.resident-section > p {
  margin-bottom: 30px;
}

.resident-link,
.direct-email a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 5px;
}

.resident-link:hover,
.direct-email a:hover {
  background: var(--highlight);
}

.small-note {
  color: var(--faded);
  font-size: 0.75rem;
  margin-top: 35px;
}

/* THE KITTEN INCIDENT */

.incident-report {
  margin-top: 45px;
}

.incident-report summary {
  width: fit-content;
  cursor: pointer;
  color: var(--faded);
  font-size: 0.85rem;
  text-decoration: underline;
  text-underline-offset: 5px;
}

.incident-report summary:hover {
  color: var(--ink);
}

.incident-copy {
  max-width: 540px;
  margin-top: 30px;
  padding: 12px 0 12px 25px;
  border-left: 1px solid var(--line);
}

.incident-copy p {
  margin: 0 0 24px;
}

.incident-copy p:last-child {
  margin-bottom: 0;
}

/* CORRESPONDENCE */

.direct-email {
  margin: 55px 0 65px;
}

.contact-form {
  max-width: 540px;
}

.form-field {
  margin-bottom: 38px;
}

.form-field label {
  display: block;
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.form-field input,
.form-field textarea {
  display: block;
  width: 100%;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 15px;
  font: inherit;
  font-size: 0.9rem;
  line-height: 1.6;
}

.form-field textarea {
  resize: vertical;
  min-height: 160px;
}

.form-field input:focus,
.form-field textarea:focus {
  outline: 1px solid var(--ink);
  outline-offset: 3px;
}

.field-hint {
  margin: 0 0 15px;
  color: var(--faded);
  font-size: 0.75rem;
}

.send-note {
  padding: 12px 0;
  background: transparent;
  border: none;
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  text-decoration: underline;
  text-underline-offset: 5px;
  cursor: pointer;
}

.send-note:hover {
  background: var(--highlight);
}

.send-note:focus-visible {
  outline: 2px dashed var(--ink);
  outline-offset: 5px;
}

.form-note {
  margin-top: 22px;
  font-size: 0.7rem;
  color: var(--faded);
}

.contact-trap {
  position: absolute;
  left: -9999px;
}

/* SOMETHING IN THE MARGIN */

.resident-footnote {
  width: fit-content;
  margin: 20px 0 50px auto;
  color: var(--faded);
}

.resident-footnote summary {
  cursor: pointer;
  font-size: 0.85rem;
}

.resident-footnote p {
  margin-top: 15px;
  font-size: 0.75rem;
  text-align: right;
}

/* SMALL WINDOWS */

@media (max-width: 650px) {
  .resident-intro {
    grid-template-columns: 1fr;
    gap: 45px;
    margin-bottom: 110px;
  }

  .resident-hello h1 {
    margin-bottom: 45px;
  }

  .resident-portrait {
    width: min(100%, 260px);
    margin: 0 auto;
  }

  .resident-section {
    margin-bottom: 100px;
  }

  .incident-copy {
    padding-left: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .resident-portrait img {
    transition: none;
  }
}


.room-navigation {
  margin-top: 25px;
  font-size: 0.8rem;
}

.room-navigation a {
  color: var(--faded);
  text-decoration: none;
}

.room-navigation a:hover,
.room-navigation a:focus-visible {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 5px;
}
