/* The contact page (/contact), on top of styles.css and account.css. External file only: the page has no inline
   styles or scripts. Phones use the whole width; nothing scrolls sideways. */

.contact{max-width:600px}
.contact-form{gap:var(--space-5)}
.contact-form .field{display:grid;gap:var(--space-2)}
.contact-form .fine{margin:0}
.contact-form .input{max-width:100%}
.contact-form .textarea{min-height:190px;resize:vertical;line-height:1.5;padding:var(--space-3)}
.contact-form select.input{appearance:none;-webkit-appearance:none;padding-right:44px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='M3 6l5 5 5-5' fill='none' stroke='%23191f2b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 14px center;cursor:pointer}
.contact-form select.input:invalid{color:var(--placeholder)}
.contact-form select.input option{color:var(--ink)}

/* Validation messages sit under their field; an empty one takes no room, so the form doesn't jump. */
.contact-form .field-error{margin:0;font-weight:600}
.contact-form .field-error:empty{display:none}
.contact-form .input[aria-invalid="true"]{border-color:var(--error);box-shadow:inset 0 0 0 1px var(--error)}

/* The whole-form message (a failed send, an expired form): hidden while empty. */
.contact-failure{margin:0}
.contact-failure:empty{display:none}

/* The trap field: off-screen for people, present for scripts. Not display:none, which some bots skip. */
.contact-trap{position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden}

/* The button keeps its width while it says "Sending…", and shows a small ring. */
.contact-form .button{min-width:12.5em;position:relative}
.contact-form .button[data-sending]{opacity:.85;cursor:progress}
.contact-form .button[data-sending]::before{content:"";width:16px;height:16px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:contact-spin .8s linear infinite}
@keyframes contact-spin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){.contact-form .button[data-sending]::before{animation:none;border-right-color:currentColor;opacity:.6}}

/* The thank-you: quiet, no big border, the same width the form had. */
.contact-done{margin-top:var(--space-8);display:grid;gap:var(--space-3);max-width:520px}
.contact-done:focus:not(:focus-visible){outline:none}
.contact-done-title{font-size:var(--size-title-1);font-weight:700;line-height:1.3;display:flex;gap:var(--space-3);align-items:flex-start}
.contact-check{flex:none;width:26px;height:26px;margin-top:1px;border-radius:50%;background:var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='26' height='26' viewBox='0 0 26 26'%3E%3Cpath d='M7 13.5l4 4 8-9' fill='none' stroke='%23ffffff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/26px no-repeat}

@media (max-width:800px){
  .contact-form .button{width:100%}
  .contact-done-title{font-size:var(--size-title-1-phone)}
}
