/* صفحه تماس — هم‌تراز با هویت و نمونه‌کار */

.section-contact .page-header-block {
  margin-bottom: 2rem;
}

.contact-shell {
  display: grid;
  gap: clamp(1.25rem, 3vw, 2rem);
  align-items: start;
}

@media (min-width: 900px) {
  .contact-shell {
    grid-template-columns: minmax(0, 0.38fr) minmax(0, 1fr);
    gap: clamp(1.5rem, 3vw, 2.5rem);
  }
}

/* ——— ستون راه‌های ارتباط ——— */
.contact-aside {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  direction: rtl;
}

.contact-chip {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: clamp(0.85rem, 2vw, 1.1rem);
  text-decoration: none;
  color: inherit;
  border-radius: 14px;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

a.contact-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.06);
}

.contact-chip--static {
  cursor: default;
}

.contact-chip__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  color: var(--accent);
}

.contact-chip__icon .icon {
  width: 20px;
  height: 20px;
}

.contact-chip__body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.contact-chip__label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--text-subtle);
}

.contact-chip__value {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--text-muted);
}

a.contact-chip:hover .contact-chip__value {
  color: var(--accent);
}

.contact-aside__note {
  margin: 0.35rem 0 0;
  padding: 0.65rem 0.85rem;
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--text-subtle);
  border-inline-start: 2px solid color-mix(in srgb, var(--accent) 45%, transparent);
}

/* ——— فرم ——— */
.contact-form {
  padding: clamp(1.25rem, 3vw, 2rem);
  border-radius: var(--radius-lg, 18px);
  scroll-margin-top: 1.25rem;
  direction: rtl;
}

.contact-form__head {
  margin-bottom: 1.35rem;
}

.contact-form__title {
  margin: 0 0 0.45rem;
  font-size: clamp(1.25rem, 2.4vw, 1.55rem);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.contact-form__lead {
  margin: 0;
  font-size: clamp(0.92rem, 1.6vw, 1.02rem);
  line-height: 1.75;
  color: var(--text-muted);
}

.contact-form__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

@media (min-width: 640px) {
  .contact-form__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.contact-field--full {
  grid-column: 1 / -1;
}

.contact-field__label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-subtle);
}

.contact-input {
  width: 100%;
  padding: 0.85rem 1rem;
  font-family: inherit;
  font-size: clamp(0.92rem, 1.5vw, 1rem);
  color: var(--text);
  background: color-mix(in srgb, var(--bg) 55%, var(--surface));
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.contact-input:focus {
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent);
}

.contact-input--area {
  resize: none;
  min-height: 140px;
  line-height: 1.85;
  overflow: hidden;
}

.contact-field--error .contact-input {
  border-color: #ff6b8a;
}

.contact-field__error {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: #ff6b8a;
}

/* ——— کپچا ——— */
.contact-captcha {
  margin-top: 1.15rem;
  padding: 1rem 1.1rem;
  border-radius: 14px;
  background: color-mix(in srgb, var(--accent) 4%, var(--surface));
  border: 1px solid var(--glass-border);
}

.contact-captcha--error {
  border-color: color-mix(in srgb, #ff6b8a 50%, var(--glass-border));
}

.contact-captcha__label {
  margin: 0 0 0.65rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.contact-captcha__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
}

.contact-captcha__question {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  font-weight: 700;
  color: var(--accent);
  white-space: nowrap;
  user-select: none;
}

.contact-captcha__input-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-width: 2.75rem;
  width: var(--captcha-width, 2.75rem);
  max-width: 100%;
  transition: width 0.2s var(--ease);
}

.contact-captcha__ghost {
  position: absolute;
  visibility: hidden;
  white-space: pre;
  font-family: inherit;
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  font-weight: 700;
  padding: 0 0.25rem;
  pointer-events: none;
}

.contact-captcha__input {
  width: 100%;
  min-width: 2.5rem;
  padding: 0.55rem 0.65rem;
  font-family: inherit;
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  font-weight: 700;
  text-align: center;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  outline: none;
  transition: border-color 0.2s;
}

.contact-captcha__input:focus {
  border-color: var(--accent);
}

.contact-captcha__refresh {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  font-size: 1.25rem;
  line-height: 1;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, transform 0.35s var(--ease);
}

.contact-captcha__refresh:hover {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 35%, transparent);
}

.contact-captcha__refresh:active {
  transform: rotate(-180deg);
}

.contact-captcha__hint {
  margin: 0.55rem 0 0;
  font-size: 0.72rem;
  color: var(--text-subtle);
}

.contact-form__actions {
  margin-top: 1.35rem;
  display: flex;
  justify-content: flex-start;
}

.contact-form__submit {
  min-width: min(100%, 220px);
  padding: 0.85rem 1.75rem;
  font-size: 0.95rem;
}

@media (max-width: 639px) {
  .contact-form__actions {
    justify-content: stretch;
  }

  .contact-form__submit {
    width: 100%;
  }
}
