/* ===== (15) Free strategy call — Figma 3343:20321 ===== */

.contact { padding: 70px 0 140px; background: #000; color: #fff; }

.contact__body { display: flex; justify-content: space-between; align-items: flex-start; gap: 48px; margin-top: 72px; }

.contact__aside { position: relative; flex: 0 1 515px; padding-top: 127px; }
/* Mascot sitting on the top edge of the "Rather reach us directly?" card.
   Its feet are pinned 14px behind the card's top edge at every size (the PNG has
   transparent space under the feet: visible art ends at 84.5% of its height), so it
   never floats or moves up and down. Idle loop: it breathes, glances left and right,
   and now and then shuffles a little along the edge — all sideways, feet stay put. */
.contact__mascot {
  --mw: 220px;
  --mh: calc(var(--mw) * 0.75);
  --edge: 127px;            /* = .contact__aside padding-top (where the card starts) */
  position: absolute;
  left: 41.9%;              /* 216 / 515 */
  top: calc(var(--edge) - var(--mh) * 0.845 + 14px);
  width: var(--mw); height: var(--mh);
  object-fit: cover;
  z-index: 0;
  transform-origin: 50% 84%;
}
@media (prefers-reduced-motion: no-preference) {
  .contact__mascot { animation: mascot-idle 9s ease-in-out infinite; }
}
@keyframes mascot-idle {
  0%   { transform: translateX(0) rotate(0) scale(1, 1); }
  6%   { transform: translateX(0) rotate(0) scale(1.04, 0.96); }   /* breathe */
  12%  { transform: translateX(0) rotate(0) scale(1, 1); }
  20%  { transform: translateX(0) rotate(-7deg); }                   /* glance left */
  28%  { transform: translateX(0) rotate(-7deg); }
  34%  { transform: translateX(0) rotate(6deg); }                    /* glance right */
  42%  { transform: translateX(0) rotate(6deg); }
  48%  { transform: translateX(0) rotate(0); }
  54%  { transform: translateX(10px) rotate(4deg); }                 /* little shuffle → */
  58%  { transform: translateX(20px) rotate(-4deg); }
  62%  { transform: translateX(30px) rotate(3deg); }
  66%  { transform: translateX(30px) rotate(0) scale(1.04, 0.96); }
  72%  { transform: translateX(30px) rotate(0) scale(1, 1); }
  80%  { transform: translateX(20px) rotate(-4deg); }                /* … and back */
  84%  { transform: translateX(10px) rotate(4deg); }
  88%  { transform: translateX(0) rotate(-2deg); }
  92%  { transform: translateX(0) rotate(0) scale(1.04, 0.96); }
  100% { transform: translateX(0) rotate(0) scale(1, 1); }
}

.contact__card {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; gap: 60px;
  padding: 40px;
  border-radius: 24px;
  background: #0d0d0d; /* rgba(255,255,255,.05) on black, opaque so the mascot sits behind it */
  line-height: 1.5;
}
.contact__card-title { font-size: 24px; letter-spacing: -0.012em; }
.contact__card-text { margin-top: 8px; font-size: 20px; color: rgba(255, 255, 255, 0.6); }
.contact__lines { display: flex; flex-direction: column; gap: 16px; font-size: 20px; }
.contact__lines a { width: fit-content; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size 0.4s var(--ease-out); }
.contact__lines a:hover { background-size: 100% 1px; }

.contact-form {
  position: relative;
  flex: 0 1 948px;
  padding: 40px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.05);
}
.contact-form__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 60px 40px; }

.field { position: relative; display: flex; flex-direction: column; gap: 40px; }
.field--wide { grid-column: 1 / -1; }
.field__label { font-size: 24px; line-height: 1.5; letter-spacing: -0.012em; color: #fff; }
.field__optional { font-size: 0.66em; letter-spacing: 0; color: rgba(255, 255, 255, 0.45); vertical-align: 0.12em; }
.field__input {
  width: 100%;
  padding: 0 0 12px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0;
  background: transparent;
  color: #fff;
  font: inherit;
  font-size: 20px;
  line-height: 1.5;
  outline: none;
  transition: border-color 0.25s;
  appearance: none;
}
.field__input::placeholder { color: rgba(255, 255, 255, 0.6); }
.field__input:focus { border-bottom-color: #fff; }
.field__input--area { min-height: 100px; resize: vertical; }
select.field__input { cursor: pointer; padding-right: 32px; }
select.field__input:invalid { color: rgba(255, 255, 255, 0.6); }
select.field__input option { color: #000; }
.field__chevron { position: absolute; right: 0; bottom: 18px; width: 20px; height: 20px; pointer-events: none; color: #fff; }
.field__error { position: absolute; left: 0; bottom: -24px; font-size: 13px; color: #ff7a59; opacity: 0; transition: opacity 0.2s; }
.field.is-invalid .field__input { border-bottom-color: #ff7a59; }
.field.is-invalid .field__error { opacity: 1; }

.contact-form__actions { display: flex; flex-direction: column; gap: 24px; margin-top: 60px; }
.btn-cta--block { width: 100%; }
.contact-form__alt { text-align: center; font-size: 16px; color: rgba(255, 255, 255, 0.7); }
.contact-form__alt a { color: #fff; }
.contact-form__alt a:hover { text-decoration: underline; }
.contact-form.is-sending .btn-cta { opacity: 0.7; pointer-events: none; }

.contact-form__done {
  position: absolute; inset: 0; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  padding: 40px;
  border-radius: 24px;
  overflow: hidden;
  background:
    radial-gradient(60% 55% at 50% 30%, rgba(249, 61, 13, 0.22), rgba(249, 61, 13, 0) 70%),
    radial-gradient(40% 40% at 85% 95%, rgba(47, 107, 255, 0.14), rgba(47, 107, 255, 0) 70%),
    #0d0d0d;
}
.done-confetti { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; }
.done { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; max-width: 620px; text-align: center; }

/* The check badge: pops in, draws its tick, then sends out one soft ring */
.done__badge {
  position: relative;
  display: grid; place-items: center;
  width: 88px; height: 88px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 18px 50px rgba(249, 61, 13, 0.45);
}
.done__badge::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid var(--accent); opacity: 0;
}
.done__badge svg { width: 52px; height: 52px; }
.done__check { fill: none; stroke: #fff; stroke-width: 4.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; }

.done__eyebrow {
  margin-top: 28px;
  font-family: var(--font-ui); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase;
  color: #ff7a59;
}
.done__title { margin-top: 10px; font-size: clamp(36px, 3.2vw, 56px); line-height: 1.05; letter-spacing: -0.035em; color: #fff; outline: none; }
.done__text { margin-top: 14px; font-size: 20px; line-height: 1.5; color: rgba(255, 255, 255, 0.65); }

.done__steps {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px;
  width: 100%; margin: 36px 0 0; padding: 0; list-style: none;
}
.done__steps li {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 18px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 15px; line-height: 1.35; color: rgba(255, 255, 255, 0.8);
}
.done__num {
  display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  background: rgba(249, 61, 13, 0.16); color: #ff7a59;
  font-family: var(--font-ui); font-size: 13px; font-weight: 500;
}
.done__again {
  margin-top: 32px; padding: 14px 26px;
  border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 99px;
  color: #fff; font-size: 16px; line-height: 1;
  transition: background-color 0.25s, border-color 0.25s, color 0.25s;
}
.done__again:hover { background: #fff; border-color: #fff; color: #000; }

/* Entrance, step by step */
.contact-form__done.is-shown { animation: done-in 0.45s var(--ease-out) both; }
.contact-form__done.is-shown .done__badge { animation: done-pop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both; }
.contact-form__done.is-shown .done__badge::after { animation: done-ring 1.2s var(--ease-out) 0.55s both; }
.contact-form__done.is-shown .done__check { animation: done-draw 0.45s var(--ease-out) 0.45s forwards; }
.contact-form__done.is-shown .done > :not(.done__badge) { animation: fade-up 0.6s var(--ease-out) both; }
.contact-form__done.is-shown .done__eyebrow { animation-delay: 0.35s; }
.contact-form__done.is-shown .done__title { animation-delay: 0.42s; }
.contact-form__done.is-shown .done__text { animation-delay: 0.5s; }
.contact-form__done.is-shown .done__steps { animation-delay: 0.6s; }
.contact-form__done.is-shown .done__again { animation-delay: 0.7s; }
@keyframes done-in { from { opacity: 0; } }
@keyframes done-pop { from { opacity: 0; transform: scale(0.4); } }
@keyframes done-draw { to { stroke-dashoffset: 0; } }
@keyframes done-ring { 0% { opacity: 0.7; transform: scale(1); } 100% { opacity: 0; transform: scale(1.9); } }
@media (prefers-reduced-motion: reduce) {
  .contact-form__done.is-shown, .contact-form__done.is-shown * { animation: none !important; }
  .done__check { stroke-dashoffset: 0; }
}
@media (max-width: 640px) {
  .contact-form__done { padding: 24px; align-items: flex-start; overflow-y: auto; }
  .done { padding-top: 12px; }
  .done__badge { width: 72px; height: 72px; }
  .done__badge svg { width: 42px; height: 42px; }
  .done__steps { grid-template-columns: minmax(0, 1fr); }
  .done__steps li { flex-direction: row; text-align: left; padding: 14px 16px; }
}
@keyframes fade-up { from { opacity: 0; transform: translateY(12px); } }

@media (max-width: 1280px) {
  .contact__body { flex-direction: column-reverse; align-items: stretch; }
  .contact__aside { flex-basis: auto; max-width: 515px; }
  .contact-form { flex-basis: auto; }
}
@media (max-width: 640px) {
  .contact-form { padding: 24px; }
  .contact-form__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .field { gap: 16px; }
  .field__label { font-size: 20px; }
}

/* ===== Custom dropdown (select_controller.js) =====
   Closed it looks exactly like the other fields (underline, 20px text); open, a
   dark rounded panel drops in with the options grouped by track. */
.field--select.is-custom select {
  position: absolute; left: 0; bottom: 0;
  width: 1px; height: 1px; opacity: 0; pointer-events: none;
}
.field__trigger {
  display: flex; align-items: baseline; gap: 10px;
  width: 100%;
  padding: 0 36px 12px 0;
  border: 0; border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: #fff;
  font: inherit; font-size: 20px; line-height: 1.5; text-align: left;
  cursor: pointer;
  outline: none;
  transition: border-color 0.25s, color 0.25s;
}
.field__trigger.is-placeholder { color: rgba(255, 255, 255, 0.6); }
.field__trigger:hover, .field__trigger:focus-visible, .field--select.is-open .field__trigger { border-bottom-color: #fff; }
.field__trigger[data-group]:not([data-group=""])::before {
  content: attr(data-group);
  flex: none;
  font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.field__trigger-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field.is-invalid .field__trigger { border-bottom-color: #ff7a59; }
.field--select .field__chevron { transition: transform 0.4s var(--ease-expo, cubic-bezier(0.16, 1, 0.3, 1)); }
.field--select.is-open .field__chevron { transform: rotate(180deg); }

.select-panel {
  position: absolute; left: -12px; right: -12px; top: calc(100% + 12px);
  z-index: 30;
  max-height: min(460px, 60vh);
  overflow-y: auto; overscroll-behavior: contain;
  padding: 8px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #17171a;
  box-shadow: 0 40px 80px -24px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  opacity: 0; visibility: hidden;
  transform: translateY(-8px) scale(0.985);
  transform-origin: 50% 0;
  transition: opacity 0.2s, transform 0.3s var(--ease-expo, cubic-bezier(0.16, 1, 0.3, 1)), visibility 0s 0.3s;
}
.field--select.is-open .select-panel {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity 0.25s, transform 0.45s var(--ease-expo, cubic-bezier(0.16, 1, 0.3, 1)), visibility 0s;
}

.select-panel__head {
  display: flex; align-items: center; gap: 8px;
  padding: 14px 16px 6px;
  font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}
.select-panel__head::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent, #f93d0d); }
.select-panel__group + .select-panel__group .select-panel__head::before { background: #8fb4ff; }

.select-panel__option {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 16px;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px; line-height: 1.3;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.select-panel__text { flex: 1; min-width: 0; }
.select-panel__note {
  flex: none;
  padding: 3px 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 99px;
  font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.select-panel__check { flex: none; width: 16px; height: 16px; color: var(--accent, #f93d0d); opacity: 0; transform: scale(0.6); transition: opacity 0.2s, transform 0.3s var(--ease-expo, cubic-bezier(0.16, 1, 0.3, 1)); }
.select-panel__option.is-active { background: rgba(255, 255, 255, 0.07); color: #fff; }
.select-panel__option[aria-selected="true"] { color: #fff; }
.select-panel__option[aria-selected="true"] .select-panel__check { opacity: 1; transform: none; }
.select-panel__option[aria-selected="true"] .select-panel__note { border-color: rgba(249, 61, 13, 0.6); color: #fff; }
.select-panel__sep { display: block; height: 1px; margin: 8px 16px; background: rgba(255, 255, 255, 0.08); }

/* rows slide in one after another when the panel opens */
@media (prefers-reduced-motion: no-preference) {
  .select-panel__option, .select-panel__head { opacity: 0; transform: translateY(-4px); transition: background-color 0.2s, color 0.2s, opacity 0.2s, transform 0.3s; }
  .field--select.is-open .select-panel__option,
  .field--select.is-open .select-panel__head {
    opacity: 1; transform: none;
    transition: background-color 0.2s, color 0.2s, opacity 0.35s calc(var(--n, 0) * 22ms), transform 0.45s var(--ease-expo, cubic-bezier(0.16, 1, 0.3, 1)) calc(var(--n, 0) * 22ms);
  }
}

@media (max-width: 767px) {
  .select-panel { left: -8px; right: -8px; }
  .select-panel__option { font-size: 16px; padding: 12px 12px; }
  .field__trigger { font-size: 18px; }
  .field__trigger[data-group]:not([data-group=""])::before { display: none; }
}

/* small phones: keep the peeking mascot inside the screen */
@media (max-width: 480px) {
  .contact__aside { padding-top: 96px; }
  .contact__mascot { --mw: 150px; --edge: 96px; left: auto; right: 44px; }
}

/* Honeypot for bots (ContactMessage#spam?): out of sight and out of the tab order. */
.contact-form__trap { display: none !important; }
/* Shown when the server refuses the message (validation, rate limit, network). */
.contact-form__error { margin: 0 0 16px; padding: 12px 16px; border-radius: 12px; background: rgba(255, 90, 54, 0.12); color: #ffb4a3; font-size: 14px; line-height: 1.5; }
