@import url("https://use.typekit.net/hdf2qwx.css");

:root {
  --bg: #f8f8f5;
  --ink: #0d0d0d;
  --muted: #676761;
  --line: #d8d8d0;
  --emerald: #0A4D3C;
  --coral: #71B43A;
  --grid-opacity: 0.045;
  --desktop-grid-width: 8.333vw;
  --mobile-grid-width: 25vw;
  --mono-font: "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --sans-font: "normalidad-text", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --display-font: "sarina", sans-serif;
  --brands-font: "panoptica-script", "IBM Plex Mono", ui-monospace, monospace;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans-font, "normalidad-text", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--ink) calc(var(--grid-opacity) * 100%), transparent) 1px, transparent 1px) 0 0 / var(--desktop-grid-width) 100%,
    var(--bg);
}

html.has-scroll-smoother #smooth-wrapper {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

html.has-scroll-smoother #smooth-content {
  position: relative;
  width: 100%;
  overflow: visible;
}

body::selection {
  background: var(--ink);
  color: var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  padding: 22px clamp(18px, 4vw, 56px);
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
  font-size: 12px;
  letter-spacing: 0;
  mix-blend-mode: difference;
  color: white;
}

.brand {
  display: grid;
  width: 136px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(13, 13, 13, 0.5);
  border-radius: 5px 0 5px 0;
  font-family: var(--brands-font, "panoptica-script", "IBM Plex Mono", ui-monospace, monospace);
}

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

.site-nav {
  display: flex;
  min-width: 0;
  gap: clamp(18px, 3vw, 42px);
  justify-content: flex-end;
  text-transform: uppercase;
}

.site-nav a {
  white-space: nowrap;
}

.section-rail {
  position: fixed;
  z-index: 19;
  top: 50%;
  left: clamp(16px, 3vw, 48px);
  display: grid;
  grid-template-rows: auto 128px auto;
  gap: 14px;
  align-items: center;
  color: var(--muted);
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
  font-size: 11px;
  pointer-events: none;
  text-transform: uppercase;
  transform: translateY(-50%);
}

.section-rail__label {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

.section-rail i {
  position: relative;
  display: block;
  width: 1px;
  height: 128px;
  overflow: hidden;
  background: var(--line);
}

.section-rail i span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--ink);
  transform: scaleY(0);
  transform-origin: top;
}

.section-rail b {
  display: block;
  width: 7px;
  height: 7px;
  margin-left: -3px;
  border-radius: 999px;
  background: var(--emerald);
}

.intro {
  position: relative;
  display: grid;
  min-height: 100svh;
  place-items: center;
  padding: 96px clamp(18px, 4vw, 56px);
}

.intro__inner {
  width: min(1180px, 100%);
}

/* .intro__meta,
.intro__line,
.section-label,
.panel-index,
.case-client,
.contact-card {
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
  letter-spacing: 0;
} */

.intro__meta {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: clamp(12px, 1.25vw, 15px);
  text-transform: uppercase;
}

.intro__name {
  --intro-blur: 22px;
  --reveal-x: 50%;
  --reveal-y: 50%;
  --reveal-size: 0px;
  max-width: 100%;
  min-height: 1.85em;
  margin: 0;
  font-size: clamp(58px, 15vw, 214px);
  font-weight: 800;
  line-height: 0.88;
  letter-spacing: 0;
  opacity: 0.68;
  position: relative;
  transform: translateZ(0);
  overflow-wrap: anywhere;
  will-change: opacity, transform;
  font-family: var(--display-font, "sarina", sans-serif);
}

.intro__name:hover,
.intro__name:focus-within {
  cursor: crosshair;
}

.intro__name-layer {
  display: inline-block;
  white-space: pre-wrap;
}

.intro__name-layer--blur {
  filter: blur(var(--intro-blur));
  transform: translateZ(0);
  will-change: filter;
}

.intro__name-layer--clear {
  position: absolute;
  inset: 0;
  color: var(--ink);
  opacity: 1;
  pointer-events: none;
  clip-path: circle(var(--reveal-size) at var(--reveal-x) var(--reveal-y));
  will-change: clip-path;
}

.intro__name span::after {
  content: "";
  display: inline-block;
  width: 0.09em;
  height: 0.73em;
  margin-left: 0.04em;
  background: var(--coral);
  transform: translateY(0.1em);
  animation: cursor-blink 0.9s steps(2) infinite;
}

.intro__line {
  max-width: 760px;
  margin: 26px 0 0;
  color: var(--muted);
  font-size: clamp(15px, 1.8vw, 24px);
}

.scroll-signal {
  position: absolute;
  right: clamp(18px, 4vw, 56px);
  bottom: 34px;
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--muted);
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
  font-size: 12px;
  text-transform: uppercase;
}

.scroll-signal i {
  position: relative;
  display: block;
  width: 84px;
  height: 1px;
  overflow: hidden;
  background: var(--line);
}

.scroll-signal i::before {
  position: absolute;
  inset: 0;
  content: "";
  background: var(--ink);
  transform: translateX(-100%);
  animation: signal-pass 1.8s ease-in-out infinite;
}

.horizontal-story {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.horizontal-story__track {
  display: flex;
  width: max-content;
  height: 100svh;
  will-change: transform;
}

.story-panel {
  display: grid;
  width: 100vw;
  min-width: 100vw;
  align-content: center;
  gap: 26px;
  padding: clamp(80px, 10vw, 144px) clamp(18px, 8vw, 132px);
}

.story-panel h2 {
  max-width: 1200px;
  margin: 0;
  font-size: clamp(54px, 12vw, 176px);
  font-weight: 900;
  line-height: 0.75;
  letter-spacing: 0;
}

.story-panel p:not(.panel-index) {
  max-width: 800px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 28px);
  line-height: 1.35;
}

.story-panel--lead h2 {
  color: var(--ink);
}

.story-panel--statement h2 {
  max-width: 1350px;
}

.panel-index {
  margin: 0;
  color: var(--coral);
  font-size: clamp(15px, 1.33vw, 18px);
}

.story-progress {
  position: absolute;
  right: clamp(18px, 4vw, 56px);
  bottom: 34px;
  left: clamp(18px, 4vw, 56px);
  height: 2px;
  background: var(--line);
}

.story-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--coral);
  transform: scaleX(0);
  transform-origin: left;
}

.story-counter {
  position: absolute;
  right: clamp(18px, 4vw, 56px);
  top: 34px;
  display: flex;
  gap: 8px;
  align-items: baseline;
  color: var(--muted);
  font-family: var(--mono-font);
  font-size: 13px;
}

.story-counter span {
  color: var(--emerald);
}

.proof,
.work,
.contact {
  padding: clamp(24px, 6vw, 88px) clamp(18px, 4vw, 56px) clamp(24px, 6vw, 88px) clamp(18px, 4vw, 56px);
}

.services {
  min-height: 100svh;
  overflow: hidden;
  padding: clamp(18px, 3.6vw, 56px) clamp(18px, 4vw, 56px) clamp(24px, 6vw, 88px);
}

.section-label {
  margin-bottom: 1rem;
  color: var(--coral);
  /* font-size: 12px; */
  text-transform: uppercase;
}

.proof h2,
.work h2,
.services h2,
.contact h2 {
  max-width: 1100px;
  margin: 0 0 clamp(33px, 6vw, 75px);
  font-size: clamp(42px, 7vw, 118px);
  font-weight: 900;
  line-height: 0.75;
  letter-spacing: 0;
}

.proof-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.proof-item {
  min-height: 240px;
  padding: 28px 22px;
  border-right: 1px solid var(--line);
}

.proof-item:last-child {
  border-right: 0;
}

.proof-item strong {
  display: block;
  margin-bottom: 26px;
  font-size: clamp(44px, 6vw, 88px);
  line-height: 0.95;
  font-family: "panoptica-pixel", sans-serif;
}

.proof-item span {
  display: block;
  max-width: 280px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.45;
}

.case-list {
  border-top: 1px solid var(--ink);
}

.case-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(260px, 1fr) minmax(180px, 0.45fr);
  gap: clamp(24px, 4vw, 72px);
  align-items: start;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.case-row::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 100%;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(0, 255, 34, 0.14), transparent);
  opacity: 0;
  pointer-events: none;
  transform: translateX(-100%);
  transition: opacity 240ms ease, transform 680ms ease;
}

.case-row:hover::before,
.case-row:focus-within::before {
  opacity: 1;
  transform: translateX(100%);
}

.case-client {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 12px;
  text-transform: uppercase;
}

.case-row h3,
.service-columns h3 {
  margin: 0;
  font-size: clamp(22px, 2.5vw, 36px);
  line-height: 1.05;
  letter-spacing: 0;
}

.case-row p:not(.case-client),
.service-columns p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
}

.case-row strong {
  font-size: clamp(20px, 2.5vw, 34px);
  line-height: 1.05;
  transition: color 220ms ease, transform 220ms ease;
}

.case-row:hover strong,
.case-row:focus-within strong {
  color: var(--emerald);
  transform: translateX(8px);
}

.case-details {
  grid-column: 2 / -1;
  max-height: 0;
  margin-top: -20px;
  overflow: hidden;
  opacity: 0;
  transition: max-height 360ms ease, opacity 260ms ease, margin-top 360ms ease;
}

.case-details p {
  max-width: 760px;
  color: var(--ink);
  font-family: var(--mono-font);
  font-size: 13px;
  line-height: 1.5;
}

.case-details a {
  display: inline-block;
  margin-top: 14px;
  color: var(--emerald);
  font-family: var(--mono-font);
  font-size: 12px;
  text-transform: uppercase;
}

.case-row:hover .case-details,
.case-row:focus-within .case-details {
  max-height: 140px;
  margin-top: 0;
  opacity: 1;
}

.service-columns {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.services-status {
  position: sticky;
  z-index: 2;
  top: 78px;
  display: flex;
  width: fit-content;
  gap: 14px;
  align-items: baseline;
  margin: -6px 0 22px;
  padding: 6px 0;
  background: var(--bg);
  color: var(--muted);
  font-family: var(--mono-font);
  font-size: 13px;
  text-transform: uppercase;
}

.services-status span {
  color: var(--emerald);
}

.services-status b {
  color: var(--ink);
  font-weight: 500;
}

.service-columns article {
  position: relative;
  min-height: 480px;
  padding: 28px 24px;
  background: var(--bg);
  opacity: 1;
  transform: none;
  filter: none;
  transform-origin: left center;
  will-change: transform, opacity, filter;
}

.service-columns article::after {
  position: absolute;
  right: 24px;
  bottom: 20px;
  left: 24px;
  height: 2px;
  content: "";
  background: var(--emerald);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 280ms ease;
}

.service-columns article.is-active {
  filter: blur(0);
}

.service-columns article.is-active::after {
  transform: scaleX(1);
}

.service-columns h3 {
  margin-bottom: 24px;
}

.service-columns p {
  margin-bottom: 30px;
}

.service-details {
  color: var(--muted);
  font-size: 16px;
}

.service-details summary {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  cursor: pointer;
  font-family: var(--mono-font);
  /* font-size: 12px; */
  list-style: none;
  text-transform: uppercase;
}

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

.service-details summary::before {
  /* width: 10px; */
  color: var(--emerald);
  content: "+";
  font-size: 1.5rem;
  line-height: 1;
  font-family: var(--sans-font);
  font-weight: 600;
}

.service-details summary:focus-visible {
  outline: 1px solid var(--emerald);
  outline-offset: 4px;
}

.service-details[open] summary::before {
  content: "-";
}

.service-details ul {
  list-style: none;
  padding: 0;
  margin: 22px 0 0;
  position: relative;
}

.service-details ul::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 10px;
  bottom: 10px;
  width: 1px;
  background: linear-gradient(to bottom, var(--emerald), transparent);
}

.service-details li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 15px;
  color: var(--muted);
  padding: 6px 0;
  line-height: 1.4;
  position: relative;
  transition: color 0.2s ease;
}

.service-details li:hover {
  color: var(--ink);
}

.service-details li::before {
  content: '';
  width: 9px;
  height: 9px;
  min-width: 9px;
  border-radius: 50%;
  border: 1.5px solid var(--emerald);
  background: var(--bg);
  margin-top: 3px;
  position: relative;
  z-index: 1;
  transition: background 0.2s ease;
}

.service-details li:hover::before {
  background: var(--emerald);
}

@keyframes fb-item-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.service-details[open] li {
  animation: fb-item-in 0.3s ease both;
}

.service-details[open] li:nth-child(1) { animation-delay: 0.04s; }
.service-details[open] li:nth-child(2) { animation-delay: 0.09s; }
.service-details[open] li:nth-child(3) { animation-delay: 0.14s; }
.service-details[open] li:nth-child(4) { animation-delay: 0.19s; }
.service-details[open] li:nth-child(5) { animation-delay: 0.24s; }

.services__footer {
  margin: 0 auto;
  /* padding-left: calc(25% + 1px); */
  color: var(--muted);
  font-family: var(--mono-font);
  font-size: 1rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.68fr);
  gap: clamp(36px, 7vw, 120px);
  align-items: end;
  min-height: 65dvh;
}

.contact h2 {
  margin-bottom: 0;
  line-height: 0.75;
}

.contact-card {
  display: grid;
  gap: 18px;
  padding: 28px 0 0;
  border-top: 1px solid var(--ink);
  font-size: clamp(15px, 2.45vw, 22px);
}

.contact-card::after {
  display: block;
  width: 0;
  height: 2px;
  content: "";
  background: var(--emerald);
  transition: width 420ms ease;
}

.contact-card.is-complete::after {
  width: min(220px, 60%);
}

.contact-card p {
  margin: 0 0 20px;
  color: var(--muted);
}

.contact-card p b {
  color: var(--muted);
  font-weight: 500;
}

.contact-card span {
  color: var(--coral);
}

.terminal-output {
  display: grid;
  gap: 10px;
  min-height: 88px;
  margin: -12px 0 16px;
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.terminal-output span::before {
  color: var(--emerald);
  content: "> ";
}

.contact-card a {
  width: fit-content;
  border-bottom: 1px solid currentColor;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 320ms ease, transform 320ms ease;
}

.contact-card.is-complete a {
  opacity: 1;
  transform: translateY(0);
}

html {
  font-family: "normalidad-text", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-family: var(--sans-font, "normalidad-text", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
}

.site-header,
.intro__meta,
.intro__line,
.section-label,
.panel-index,
.case-client,
.contact-card,
.section-rail,
.scroll-signal,
.story-counter,
.case-details p,
.case-details a,
.services-status,
.service-details summary,
.services__footer {
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
}

.brand {
  font-family: var(--brands-font, "panoptica-script", "IBM Plex Mono", ui-monospace, monospace);
}

.intro__name {
  font-family: var(--display-font, "sarina", sans-serif);
}

.proof-item strong {
  font-family: "panoptica-pixel", "IBM Plex Mono", ui-monospace, monospace;
}

h2{
  font-family: var(--mono-font, "panoptica-octagonal", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
}

@keyframes cursor-blink {
  50% {
    opacity: 0;
  }
}

@keyframes signal-pass {
  0% {
    transform: translateX(-100%);
  }

  55%,
  100% {
    transform: translateX(100%);
  }
}

@media (max-width: 900px) {
  body {
    background:
      linear-gradient(90deg, color-mix(in srgb, var(--ink) calc(var(--grid-opacity) * 100%), transparent) 1px, transparent 1px) 0 0 / var(--mobile-grid-width) 100%,
      var(--bg);
  }

  .site-nav {
    gap: 16px;
  }

  .proof-grid,
  .contact {
    grid-template-columns: 1fr;
  }

  .proof-item {
    min-height: 180px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .proof-item:last-child {
    border-bottom: 0;
  }

  .case-row {
    grid-template-columns: 1fr;
  }

  .case-details {
    grid-column: 1;
  }

  .services .service-columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    background: transparent;
  }

  .services .service-columns article {
    width: 100%;
    min-height: auto;
    padding-right: 0;
    padding-left: 0;
    border-bottom: 1px solid var(--line);
  }

  .services .service-columns article:last-child {
    border-bottom: 0;
  }

  .services .service-columns article::after {
    right: 0;
    bottom: 0;
    left: 0;
  }

  .services .service-columns h3 {
    margin-bottom: 22px;
  }

  .services .service-columns p {
    margin-bottom: 22px;
  }

  .services__footer {
    padding-left: 0;
  }
}

@media (max-width: 640px) {
  .admin-bar .site-header {
    top: 46px;
  }

  .site-header {
    gap: 20px;
    padding-top: 16px;
  }

  .site-nav {
    display: none;
  }

  .section-rail {
    display: none;
  }

  .intro__name {
    font-size: clamp(48px, 15.2vw, 72px);
  }

  .intro__line {
    max-width: 330px;
    font-size: 15px;
    line-height: 1.45;
  }

  .contact-card {
    font-size: 15px;
  }

  .terminal-output {
    font-size: 12px;
    line-height: 1.45;
  }

  .scroll-signal {
    right: 18px;
    left: 18px;
    justify-content: space-between;
  }

  .scroll-signal i {
    flex: 1;
  }

  .story-panel {
    padding-right: 24px;
    padding-left: 24px;
  }

  .services-status {
    position: static;
    margin: 0 0 18px;
    padding: 0;
  }

  .services h2 {
    margin-bottom: 34px;
    font-size: clamp(46px, 14vw, 62px);
    line-height: 0.75;
  }

  .service-details {
    font-size: 15px;
  }

  .service-details li {
    font-size: 14px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ─── Contact Form Modal - v1.0.0 ─────────────────────────────────────────── */

/* Backdrop overlay */
.cf-overlay {
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: var(--ink);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.38s ease;
}

.cf-overlay.is-open {
  opacity: 0.72;
  pointer-events: auto;
}

/* Modal panel - expands from a small circle, inspired by the sample */
.cf-modal {
  position: fixed;
  z-index: 1200;
  inset: auto;
  bottom: 5vh;
  left: 50%;
  transform: translateX(-50%) scale(0.4);
  transform-origin: center bottom;

  display: flex;
  flex-direction: column;
  gap: 0;

  width: min(92vw, 580px);
  max-height: 90svh;
  overflow: hidden;
  overflow-y: auto;

  background: var(--emerald);
  color: #fff;
  border-radius: 3px;

  opacity: 0;
  pointer-events: none;
  transition:
    transform 0.38s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.22s ease,
    border-radius 0.38s ease;
}

.cf-modal.is-open {
  transform: translateX(-50%) scale(1);
  opacity: 1;
  pointer-events: auto;
  border-radius: 3px;
}

/* Close button */
.cf-close {
  position: absolute;
  top: 18px;
  right: 20px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  border-radius: 50%;
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  transition: background 0.18s ease;
  z-index: 1;
}

.cf-close:hover,
.cf-close:focus-visible {
  background: rgba(255, 255, 255, 0.26);
  outline: none;
}

/* Head */
.cf-head {
  position: relative;
  padding: 36px 28px 24px;
  overflow: hidden;
}

.cf-head__pre,
.cf-head__post {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
}

.cf-head__post {
  position: absolute;
  inset: 36px 28px auto;
  transform: translateY(60%);
  opacity: 0;
  pointer-events: none;
}

/* Success state */
.cf-modal.is-submitted .cf-head__pre {
  transform: translateY(-120%);
  opacity: 0;
}

.cf-modal.is-submitted .cf-head__post {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.cf-head__title {
  margin: 0 0 6px;
  font-family: var(--mono-font);
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: 0;
  color: #fff;
}

.cf-head__sub {
  margin: 0;
  font-family: var(--mono-font);
  font-size: 14px;
  color: rgba(255, 255, 255, 0.65);
}

/* Form */
.cf-form {
  padding: 0 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: opacity 0.4s ease, transform 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.cf-modal.is-submitted .cf-form {
  opacity: 0;
  transform: translateX(40%);
  pointer-events: none;
}

/* Inputs */
.cf-field {
  display: flex;
  flex-direction: column;
}

.cf-input {
  width: 100%;
  height: 52px;
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  color: #fff;
  font-family: var(--sans-font);
  font-size: 15px;
  outline: none;
  transition: border-color 0.18s ease, background 0.18s ease;
  appearance: none;
}

.cf-input:focus {
  border-color: rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.16);
}

.cf-input.is-error {
  border-color: #ff6b6b;
  animation: cf-shake 0.5s ease;
}

.cf-input::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.cf-select {
  cursor: pointer;
}

.cf-select option {
  background: var(--emerald);
  color: #fff;
}

.cf-textarea {
  height: 130px;
  padding: 12px 14px;
  resize: none;
}

/* Submit button */
.cf-field--submit {
  margin-top: 4px;
}

.cf-submit {
  position: relative;
  width: 100%;
  height: 56px;
  background: #fff;
  color: var(--emerald);
  border: none;
  border-radius: 2px;
  font-family: var(--mono-font);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  overflow: hidden;
  transition: background 0.18s ease, transform 0.1s ease;
}

.cf-submit:hover {
  background: rgba(255, 255, 255, 0.92);
}

.cf-submit:active {
  transform: scale(0.98);
}

.cf-submit__sending {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--emerald);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.cf-submit.is-sending .cf-submit__label {
  opacity: 0;
}

.cf-submit.is-sending .cf-submit__sending {
  opacity: 1;
}

/* Error message */
.cf-error-msg {
  font-family: var(--mono-font);
  font-size: 13px;
  color: #ff9b9b;
  min-height: 0;
  transition: min-height 0.2s ease;
}

.cf-error-msg:not(:empty) {
  min-height: 20px;
}

/* Shake animation for invalid fields */
@keyframes cf-shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

/* ── Custom fields (v1.2.0) ─────────────────────────────────────────────────── */

/* Field label above input */
.cf-label {
  display: block;
  font-family: var(--mono-font);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--color-mid, #676761);
  margin-bottom: 6px;
}

/* Required asterisk */
.cf-required {
  color: #ff9b9b;
  margin-left: 2px;
}

/* Radio group */
.cf-radio-group {
  border: none;
  padding: 0;
  margin: 0;
}

.cf-radio-group legend.cf-label {
  margin-bottom: 8px;
}

.cf-radio-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono-font);
  font-size: 13px;
  color: var(--color-body, #0d0d0d);
  cursor: pointer;
  padding: 4px 0;
}

.cf-radio-label input[type="radio"] {
  accent-color: var(--color-accent, #0A4D3C);
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

/* Checkbox label (inline layout) */
.cf-checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-family: var(--mono-font);
  font-size: 13px;
  color: var(--color-body, #0d0d0d);
  cursor: pointer;
  line-height: 1.5;
}

.cf-checkbox-label input[type="checkbox"] {
  accent-color: var(--color-accent, #0A4D3C);
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  margin-top: 2px;
}

/* Mobile: full-screen on small viewports */
@media (max-width: 600px) {
  .cf-modal {
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-height: 100svh;
    transform: translateX(0) translateY(8%) scale(0.96);
    transform-origin: center bottom;
  }

  .cf-modal.is-open {
    transform: translateX(0) translateY(0) scale(1);
  }
}
