/* Two Brains LLC — landing system (1a Hairline) */

:root {
  --tb-paper: #f5f3ee;
  --tb-ink: #14130f;
  --tb-line: #dcd8d0;
  --tb-mute: #8a8479;
  --tb-header-h: 72px;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--tb-paper);
  color: var(--tb-ink);
  font-family: "Archivo", Helvetica, Arial, sans-serif;
}

.tb-site {
  background: var(--tb-paper);
  color: var(--tb-ink);
}

/* —— Header —— */
.tb-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: color-mix(in srgb, var(--tb-paper) 92%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--tb-line);
}

.admin-bar .tb-header {
  top: 32px;
}

@media screen and (max-width: 782px) {
  .admin-bar .tb-header {
    top: 46px;
  }
}

@media screen and (max-width: 600px) {
  .admin-bar .tb-header {
    top: 0;
  }
}

.tb-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.tb-logo {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--tb-ink);
  white-space: nowrap;
}

.tb-logo:hover {
  opacity: 0.75;
  text-decoration: none;
}

.tb-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.tb-nav a {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--tb-ink);
  text-decoration: none;
}

.tb-nav a:hover {
  opacity: 0.65;
  text-decoration: none;
}

.tb-nav__book {
  border: 1px solid var(--tb-ink);
  background: var(--tb-ink);
  color: var(--tb-paper) !important;
  padding: 0.65rem 1rem;
  transition: opacity 0.2s ease;
}

.tb-nav__book:hover {
  opacity: 0.85 !important;
}

.tb-nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--tb-ink);
  color: var(--tb-ink);
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.55rem 0.8rem;
  cursor: pointer;
}

@media (max-width: 760px) {
  .tb-nav-toggle {
    display: block;
  }

  .tb-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--tb-paper);
    border-bottom: 1px solid var(--tb-line);
    padding: 0.5rem 0;
  }

  .tb-nav.is-open {
    display: flex;
  }

  .tb-nav a {
    padding: 0.9rem 1.5rem;
    border-top: 1px solid var(--tb-line);
  }

  .tb-nav__book {
    margin: 0.75rem 1.5rem 1rem;
    text-align: center;
  }
}

/* —— Shared section —— */
.tb-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 6.5rem 1.5rem;
}

.tb-section + .tb-section {
  border-top: 1px solid var(--tb-line);
}

.tb-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--tb-mute);
  margin: 0 0 1.25rem;
}

.tb-h2 {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: clamp(2rem, 4vw, 3.25rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0 0 1.25rem;
  color: var(--tb-ink);
}

.tb-lead {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  max-width: 38rem;
  color: var(--tb-ink);
  margin: 0;
}

.tb-muted {
  color: var(--tb-mute);
}

/* —— Hero —— */
.tb-hero-wrap {
  padding-top: var(--tb-header-h);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(ellipse 70% 50% at 50% 55%, rgba(20, 19, 15, 0.04), transparent 70%),
    var(--tb-paper);
}

.tb-hero {
  position: relative;
  width: 100%;
  flex: 1;
  min-height: calc(100vh - var(--tb-header-h));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: clamp(1.5rem, 4vh, 3rem) 1.5rem clamp(2rem, 5vh, 3.5rem);
  gap: clamp(1rem, 3vh, 2rem);
  box-sizing: border-box;
}

.tb-hero__top {
  position: relative;
  z-index: 3;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}

.tb-hero__stage {
  position: relative;
  z-index: 1;
  width: min(100%, 720px);
  flex: 1 1 auto;
  min-height: 220px;
  max-height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tb-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(48px, 10vw, 120px);
  z-index: 1;
  pointer-events: none;
  height: 100%;
}

.tb-half {
  width: clamp(120px, 28vw, 240px);
  height: clamp(182px, 42.5vw, 364px);
  max-height: 100%;
  overflow: hidden;
  position: relative;
  aspect-ratio: 300 / 455;
}

.tb-half img {
  position: absolute;
  top: 0;
  height: 100%;
  width: 200%;
  max-width: none;
}

.tb-half.l img {
  left: 0;
}

.tb-half.r img {
  left: -100%;
}

.tb-arc {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.tb-hero__bottom {
  position: relative;
  z-index: 3;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  flex-shrink: 0;
  max-width: 32rem;
}

.tb-word {
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: 800;
  letter-spacing: 0.34em;
  text-indent: 0.34em;
  white-space: nowrap;
  margin: 0;
  line-height: 1;
}

.tb-sub {
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--tb-mute);
  margin: 0;
}

.tb-hero__tagline {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.5;
  margin: 0;
  color: var(--tb-ink);
}

.tb-hero__ctas {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

.tb-btn {
  cursor: pointer;
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.9rem 1.35rem;
  border: 1px solid var(--tb-ink);
  background: var(--tb-ink);
  color: var(--tb-paper);
  text-decoration: none;
  display: inline-block;
  transition: opacity 0.2s ease;
}

.tb-btn:hover {
  opacity: 0.85;
  text-decoration: none;
  color: var(--tb-paper);
}

.tb-btn.ghost {
  background: transparent;
  color: var(--tb-ink);
}

.tb-btn.ghost:hover {
  color: var(--tb-ink);
}

.tb-hero__sound {
  position: absolute;
  right: 1.5rem;
  bottom: 1.25rem;
  z-index: 4;
  font-family: "IBM Plex Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--tb-mute);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
}

.tb-hero__sound:hover {
  color: var(--tb-ink);
}

@media (max-width: 560px) {
  .tb-word {
    letter-spacing: 0.2em;
    text-indent: 0.2em;
    font-size: clamp(1.6rem, 9vw, 2.2rem);
  }

  .tb-hero__sound {
    position: static;
    margin-top: 0.5rem;
  }
}

/* —— Work —— */
.tb-work-list {
  list-style: none;
  margin: 2.5rem 0 0;
  padding: 0;
  border-top: 1px solid var(--tb-line);
}

.tb-work-item {
  border-bottom: 1px solid var(--tb-line);
}

.tb-work-item a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem 2rem;
  align-items: baseline;
  padding: 1.75rem 0.15rem;
  text-decoration: none;
  color: var(--tb-ink);
  transition: padding-left 0.25s ease;
}

.tb-work-item a:hover {
  padding-left: 0.5rem;
  text-decoration: none;
}

.tb-work-item__name {
  font-weight: 800;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  letter-spacing: -0.02em;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.tb-work-item__url {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--tb-mute);
  font-weight: 400;
}

.tb-work-item__desc {
  grid-column: 1 / -1;
  margin: 0.35rem 0 0;
  max-width: 36rem;
  color: var(--tb-mute);
  font-size: 1rem;
  line-height: 1.5;
}

.tb-work-item__arrow {
  font-family: "IBM Plex Mono", monospace;
  font-size: 14px;
  color: var(--tb-mute);
  transition: transform 0.2s ease, color 0.2s ease;
}

.tb-work-item a:hover .tb-work-item__arrow {
  transform: translate(3px, -3px);
  color: var(--tb-ink);
}

@media (min-width: 720px) {
  .tb-work-item a {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.4fr) auto;
  }

  .tb-work-item__desc {
    grid-column: auto;
    margin: 0;
  }
}

/* —— Capabilities —— */
.tb-cap-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin-top: 2.75rem;
  border-top: 1px solid var(--tb-line);
}

.tb-cap {
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--tb-line);
}

.tb-cap h3 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
}

.tb-cap p {
  margin: 0;
  color: var(--tb-mute);
  line-height: 1.55;
  max-width: 28rem;
}

@media (min-width: 800px) {
  .tb-cap-grid {
    grid-template-columns: 1fr 1fr;
    column-gap: 3rem;
  }
}

/* —— About —— */
.tb-about-grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 840px) {
  .tb-about-grid {
    grid-template-columns: 0.9fr 1.1fr;
    gap: 4rem;
    align-items: start;
  }
}

.tb-about-copy p {
  font-size: 1.1rem;
  line-height: 1.65;
  margin: 0 0 1.25rem;
  max-width: 36rem;
}

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

/* —— Contact —— */
.tb-contact-grid {
  display: grid;
  gap: 3rem;
}

@media (min-width: 840px) {
  .tb-contact-grid {
    grid-template-columns: 0.9fr 1.1fr;
    gap: 4rem;
    align-items: start;
  }
}

.tb-email {
  display: inline-block;
  margin-top: 1.5rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: var(--tb-ink);
  text-decoration: none;
  border-bottom: 1px solid var(--tb-line);
  padding-bottom: 0.15rem;
}

.tb-email:hover {
  border-bottom-color: var(--tb-ink);
  text-decoration: none;
}

.tb-contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.tb-form-shell {
  border: 1px solid var(--tb-line);
  padding: 1.75rem;
  background: color-mix(in srgb, var(--tb-paper) 70%, #fff);
}

.tb-form-shell .ff-el-input--label label,
.tb-form-shell .ff-el-form-check-label,
.tb-form-shell label {
  font-family: "IBM Plex Mono", monospace !important;
  font-size: 11px !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  color: var(--tb-mute) !important;
}

.tb-form-shell input[type="text"],
.tb-form-shell input[type="email"],
.tb-form-shell textarea {
  border: 1px solid var(--tb-line) !important;
  background: var(--tb-paper) !important;
  color: var(--tb-ink) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  font-family: "Archivo", sans-serif !important;
}

.tb-form-shell input:focus,
.tb-form-shell textarea:focus {
  border-color: var(--tb-ink) !important;
  outline: none !important;
}

.tb-form-shell .ff-btn-submit,
.tb-form-shell button[type="submit"] {
  background: var(--tb-ink) !important;
  color: var(--tb-paper) !important;
  border: 1px solid var(--tb-ink) !important;
  border-radius: 0 !important;
  font-family: "IBM Plex Mono", monospace !important;
  font-size: 12px !important;
  letter-spacing: 0.16em !important;
  text-transform: uppercase !important;
  padding: 0.9rem 1.35rem !important;
  width: auto !important;
  min-width: 10rem;
}

/* —— Footer —— */
.tb-footer {
  border-top: 1px solid var(--tb-line);
  padding: 2rem 1.5rem 2.5rem;
}

.tb-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

.tb-footer p,
.tb-footer a {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--tb-mute);
  margin: 0;
  text-decoration: none;
}

.tb-footer a:hover {
  color: var(--tb-ink);
}

/* —— Consultation modal —— */
.tb-modal[hidden] {
  display: none !important;
}

.tb-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
}

.tb-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 19, 15, 0.45);
  backdrop-filter: blur(4px);
}

.tb-modal__panel {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
  max-height: min(90vh, 860px);
  overflow: auto;
  background: var(--tb-paper);
  border: 1px solid var(--tb-line);
  padding: 1.75rem 1.75rem 1.5rem;
  box-shadow: 0 24px 80px rgba(20, 19, 15, 0.18);
}

.admin-bar .tb-modal {
  top: 32px;
}

.tb-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tb-mute);
  cursor: pointer;
}

.tb-modal__close:hover {
  color: var(--tb-ink);
}

.tb-modal__title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem;
  padding-right: 4rem;
}

.tb-modal__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin: 0 0 1.5rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tb-mute);
}

.tb-modal__grid {
  display: grid;
  gap: 1.75rem;
}

@media (min-width: 700px) {
  .tb-modal__grid {
    grid-template-columns: 1fr 1.15fr;
  }
}

.tb-agenda {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--tb-line);
}

.tb-agenda li {
  display: grid;
  grid-template-columns: 1.5rem 1fr;
  gap: 0.65rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--tb-line);
  font-size: 0.95rem;
  line-height: 1.4;
}

.tb-agenda__n {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  color: var(--tb-mute);
  letter-spacing: 0.08em;
}

.tb-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 0.9rem;
}

.tb-field label,
.tb-field__label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tb-mute);
}

.tb-field input,
.tb-field select {
  border: 1px solid var(--tb-line);
  background: #fff;
  color: var(--tb-ink);
  font-family: "Archivo", sans-serif;
  font-size: 1rem;
  padding: 0.7rem 0.75rem;
  border-radius: 0;
}

.tb-field input:focus,
.tb-field select:focus {
  outline: none;
  border-color: var(--tb-ink);
}

/* Custom calendar (replaces native date picker) */
.tb-cal {
  border: 1px solid var(--tb-line);
  background: #fff;
  padding: 0.85rem 0.75rem 0.75rem;
}

.tb-cal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.tb-cal__month {
  margin: 0;
  font-family: "Archivo", sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--tb-ink);
}

.tb-cal__nav {
  width: 2rem;
  height: 2rem;
  border: 1px solid var(--tb-line);
  background: transparent;
  color: var(--tb-ink);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.tb-cal__nav:hover:not(:disabled) {
  border-color: var(--tb-ink);
  background: var(--tb-ink);
  color: var(--tb-paper);
}

.tb-cal__nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.tb-cal__dows {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.2rem;
  margin-bottom: 0.35rem;
}

.tb-cal__dows span {
  font-family: "IBM Plex Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--tb-mute);
  text-align: center;
  padding: 0.2rem 0;
}

.tb-cal__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.2rem;
}

.tb-cal__day {
  aspect-ratio: 1;
  min-height: 2rem;
  border: 1px solid transparent;
  background: transparent;
  color: var(--tb-ink);
  font-family: "Archivo", sans-serif;
  font-size: 0.9rem;
  cursor: pointer;
  padding: 0;
}

.tb-cal__day:hover:not(:disabled):not(.is-selected) {
  border-color: var(--tb-ink);
}

.tb-cal__day.is-selected {
  background: var(--tb-ink);
  color: var(--tb-paper);
  border-color: var(--tb-ink);
}

.tb-cal__day.is-today:not(.is-selected) {
  border-color: var(--tb-line);
}

.tb-cal__day.is-outside {
  visibility: hidden;
  pointer-events: none;
}

.tb-cal__day:disabled {
  color: var(--tb-line);
  cursor: not-allowed;
}

.tb-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.4rem;
  max-height: 180px;
  overflow: auto;
  margin-bottom: 0.9rem;
}

.tb-slot {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.06em;
  padding: 0.55rem 0.3rem;
  border: 1px solid var(--tb-line);
  background: transparent;
  color: var(--tb-ink);
  cursor: pointer;
}

.tb-slot.is-selected,
.tb-slot:hover {
  border-color: var(--tb-ink);
  background: var(--tb-ink);
  color: var(--tb-paper);
}

.tb-slot:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.tb-modal__note {
  font-size: 0.85rem;
  color: var(--tb-mute);
  line-height: 1.45;
  margin: 0 0 1rem;
}

.tb-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.tb-modal__error {
  color: #8b2e2e;
  font-size: 0.9rem;
  margin: 0 0 0.75rem;
  min-height: 1.2em;
}

body.tb-modal-open {
  overflow: hidden;
}

/* Motion accents */
@media (prefers-reduced-motion: no-preference) {
  .tb-hero__content {
    animation: tb-rise 1s ease both;
  }

  .tb-art {
    animation: tb-fade 1.4s ease both;
  }

  .tb-section {
    animation: tb-rise 0.8s ease both;
    animation-timeline: view();
    animation-range: entry 0% entry 35%;
  }
}

@keyframes tb-rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes tb-fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Hide legacy sticky header when landing is active */
.tb-site .site-header {
  display: none !important;
}
