.form-grid {
  display: grid;
  gap: 18px;
}

.contact-card textarea {
  min-height: 170px;
}

.contact-card input[type="file"] {
  padding-block: 13px;
}

.submit-btn {
  width: 100%;
  margin-top: 18px;
}

.hint {
  text-align: center;
}

.contact-hero-art,
.contact-field-icon,
.contact-file-presentation,
.contact-submit-icon {
  display: none;
}

.contact-input-shell,
.contact-file-control {
  display: contents;
}

body.theme-male .contact-file-presentation {
  border-color: rgba(72, 108, 255, 0.42);
}

body.theme-male .contact-file-icon {
  background: linear-gradient(145deg, #fff, #eef2ff);
  box-shadow: 0 6px 14px rgba(36, 83, 255, 0.1);
}

body.theme-male .contact-file-button {
  box-shadow: 0 6px 14px rgba(36, 83, 255, 0.16);
}

@media (max-width: 720px) {
  .ec-stack {
    gap: 6px;
  }

  .contact-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 76px;
    column-gap: 8px;
    align-items: center;
    padding-block: 14px;
  }

  .contact-hero-copy {
    display: contents;
  }

  .contact-kicker {
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
  }

  .contact-hero .ec-hero-title {
    grid-column: 1 / -1;
    grid-row: 2;
    margin: 6px 0 8px;
  }

  .contact-hero .ec-hero-copy {
    display: none;
  }

  .contact-hero-art {
    display: block;
    grid-column: 2;
    grid-row: 1;
    width: 76px;
    height: 52px;
    justify-self: end;
    background-image: url("../assets/contact-support-hero.webp?v=1");
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
  }

  .contact-card {
    padding: 14px;
  }

  .form-grid {
    gap: 12px;
  }

  .contact-card .ec-form-field {
    gap: 6px;
    margin-bottom: 0;
  }

  .contact-card .ec-form-field > span:first-child {
    font-size: 0.92rem;
  }

  .contact-input-shell {
    position: relative;
    display: block;
  }

  .contact-field-icon {
    position: absolute;
    top: 50%;
    left: 14px;
    z-index: 1;
    display: block;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    fill: none;
    stroke: var(--ec-pink);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
  }

  .contact-textarea-shell .contact-field-icon {
    top: 16px;
    transform: none;
  }

  .contact-card .contact-input-shell input,
  .contact-card .contact-input-shell textarea {
    padding-left: 44px;
  }

  .contact-card .contact-input-shell input {
    min-height: 50px;
  }

  .contact-card textarea {
    min-height: 128px;
    padding-top: 13px;
  }

  .contact-file-control {
    position: relative;
    display: block;
    min-height: 76px;
  }

  .contact-file-presentation {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    min-height: 76px;
    padding: 8px 10px;
    border: 1px dashed rgba(255, 120, 169, 0.48);
    border-radius: 16px;
    background: rgba(255, 253, 254, 0.88);
  }

  .contact-file-icon {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, #fff, #fff0f6);
    color: var(--ec-pink);
    box-shadow: 0 6px 14px rgba(255, 43, 122, 0.1);
  }

  .contact-file-icon svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .contact-file-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
  }

  .contact-file-row {
    display: grid;
    grid-template-columns: max-content minmax(0, 1fr);
    align-items: center;
    gap: 8px;
    min-width: 0;
    color: var(--ec-muted);
    font-size: 0.76rem;
  }

  .contact-file-button {
    padding: 8px 10px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--ec-pink), var(--ec-pink-strong));
    color: #fff;
    font-size: 0.75rem;
    font-weight: 800;
    box-shadow: 0 6px 14px rgba(255, 43, 122, 0.16);
  }

  #contactFileName {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .contact-file-copy small {
    color: var(--ec-muted);
    font-size: 0.68rem;
    font-weight: 500;
  }

  .contact-card .contact-file-control input[type="file"] {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    opacity: 0;
    cursor: pointer;
  }

  .contact-file-control:focus-within .contact-file-presentation {
    border-color: var(--ec-pink);
    box-shadow: 0 0 0 4px rgba(255, 43, 122, 0.1);
  }

  .submit-btn {
    min-height: 50px;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 14px;
  }

  .contact-submit-icon {
    display: block;
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .contact-card .hint {
    display: none;
  }
}

@media (max-width: 360px) {
  .contact-hero {
    grid-template-columns: minmax(0, 1fr) 64px;
  }

  .contact-hero-art {
    width: 64px;
    height: 44px;
  }
}

@media (min-width: 721px) {
  .ec-page-shell {
    max-width: 1260px;
    padding-top: 12px;
  }

  .ec-stack {
    gap: 10px;
  }

  .contact-hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: center;
    min-height: 220px;
    padding: 24px 44px;
    overflow: hidden;
  }

  .contact-kicker {
    display: none;
  }

  .contact-hero-copy {
    position: relative;
    z-index: 1;
    min-width: 0;
  }

  .contact-hero .ec-hero-title {
    max-width: 760px;
    margin: 0 0 12px;
    font-size: clamp(2.5rem, 4vw, 3.45rem);
    line-height: 0.98;
  }

  .contact-hero .ec-hero-copy {
    max-width: 740px;
    font-size: 1rem;
    line-height: 1.48;
  }

  .contact-hero-art {
    display: block;
    width: 320px;
    height: 190px;
    justify-self: end;
    background-image: url("../assets/contact-support-hero.webp?v=1");
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
  }

  .contact-card {
    padding: 20px 34px 18px;
  }

  .form-grid {
    gap: 12px;
  }

  .contact-card .ec-form-field {
    gap: 6px;
    margin-bottom: 0;
  }

  .contact-card .ec-form-field > span:first-child {
    font-size: 0.92rem;
  }

  .contact-input-shell {
    position: relative;
    display: block;
  }

  .contact-field-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    z-index: 1;
    display: block;
    width: 20px;
    height: 20px;
    transform: translateY(-50%);
    fill: none;
    stroke: var(--ec-pink);
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    pointer-events: none;
  }

  .contact-textarea-shell .contact-field-icon {
    top: 18px;
    transform: none;
  }

  .contact-card .contact-input-shell input,
  .contact-card .contact-input-shell textarea {
    padding-left: 50px;
  }

  .contact-card .contact-input-shell input {
    min-height: 50px;
  }

  .contact-card textarea {
    min-height: 120px;
    padding-top: 14px;
  }

  .contact-file-control {
    position: relative;
    display: block;
    min-height: 88px;
  }

  .contact-file-presentation {
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    min-height: 88px;
    padding: 10px 16px;
    border: 1px dashed rgba(255, 120, 169, 0.48);
    border-radius: 18px;
    background: rgba(255, 253, 254, 0.88);
  }

  .contact-file-icon {
    width: 52px;
    height: 52px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, #fff, #fff0f6);
    color: var(--ec-pink);
    box-shadow: 0 8px 18px rgba(255, 43, 122, 0.1);
  }

  .contact-file-icon svg {
    width: 26px;
    height: 26px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .contact-file-copy {
    display: grid;
    gap: 6px;
    min-width: 0;
  }

  .contact-file-row {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    color: var(--ec-muted);
    font-size: 0.88rem;
  }

  .contact-file-button {
    flex: 0 0 auto;
    padding: 10px 16px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--ec-pink), var(--ec-pink-strong));
    color: #fff;
    font-size: 0.84rem;
    font-weight: 800;
    box-shadow: 0 8px 16px rgba(255, 43, 122, 0.18);
  }

  #contactFileName {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .contact-file-copy small {
    color: var(--ec-muted);
    font-size: 0.78rem;
    font-weight: 500;
  }

  .contact-card .contact-file-control input[type="file"] {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    opacity: 0;
    cursor: pointer;
  }

  .contact-file-control:focus-within .contact-file-presentation {
    border-color: var(--ec-pink);
    box-shadow: 0 0 0 4px rgba(255, 43, 122, 0.1);
  }

  .submit-btn {
    min-height: 50px;
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border-radius: 14px;
  }

  .contact-submit-icon {
    display: block;
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .contact-card .hint {
    display: none;
  }
}

@media (min-width: 721px) and (max-height: 820px) {
  .contact-hero {
    min-height: 190px;
    padding-block: 18px;
  }

  .contact-hero-art {
    height: 166px;
  }

  .contact-card textarea {
    min-height: 92px;
  }

  .contact-file-control,
  .contact-file-presentation {
    min-height: 70px;
  }
}

@media (min-width: 1280px) {
  .contact-hero .ec-hero-copy {
    max-width: none;
    white-space: nowrap;
    font-size: 0.92rem;
  }
}
