/* ===========================================================================
   PROPERTY DOCUMENT FORM – scoped to the existing WordPress shortcode.
   =========================================================================== */
.jmg-docs {
  --jmg-ink: #515151;
  --jmg-muted: #656b69;
  --jmg-accent: #5a6f69;
  --jmg-secondary: #7d9c91;
  --jmg-pale: #f1f5f4;
  --jmg-border: #d8dfdc;
  width: 100%; max-width: 1200px; margin: 2.5rem auto;
  color: var(--jmg-ink); background: #fff; font-family: inherit; font-size: 16px; font-weight: 400; line-height: 1.55;
}
.jmg-docs *, .jmg-docs *::before, .jmg-docs *::after { box-sizing: border-box; }
.jmg-docs [hidden] { display: none !important; }
.jmg-docs__icon { display: inline-block; flex-shrink: 0; width: 18px; height: 18px; background-color: currentColor; -webkit-mask: var(--jmg-icon) center / contain no-repeat; mask: var(--jmg-icon) center / contain no-repeat; }
.jmg-docs__icon--envelope { --jmg-icon: url('icon-envelope.svg'); }
.jmg-docs__icon--file { --jmg-icon: url('icon-file-lines.svg'); }
.jmg-docs__icon--upload { --jmg-icon: url('icon-arrow-up-from-bracket.svg'); }
.jmg-docs__icon--info { --jmg-icon: url('icon-info-filled.svg'); }
.jmg-docs__icon--help { --jmg-icon: url('icon-info-outline.svg'); }
.jmg-docs__icon--privacy { --jmg-icon: url('icon-shield-halved.svg'); }
.jmg-docs__icon--chevron { --jmg-icon: url('icon-chevron-down.svg'); }
.jmg-docs__icon--check { --jmg-icon: url('icon-circle-check.svg'); }
.jmg-docs h2, .jmg-docs h3, .jmg-docs h4 { color: var(--jmg-ink); font-family: inherit; font-weight: 700; }
.jmg-docs p { margin: 0 0 1rem; }
.jmg-docs__header { padding-bottom: 1.35rem; border-bottom: 1px solid #a9b0ad; }
.jmg-docs__header h2 { margin: 0 0 .4rem; font-size: clamp(2rem, 3.2vw, 2.65rem); line-height: 1.18; }
.jmg-docs__header p { margin: 0; font-size: clamp(1.05rem, 1.8vw, 1.45rem); line-height: 1.5; }
.jmg-docs__intro { margin: 1.7rem 0 3rem; }
.jmg-docs__intro p:last-child { margin-bottom: 0; }
.jmg-docs__form { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 2rem; align-items: start; margin: 0; }
.jmg-docs__guide { position: sticky; top: 7rem; padding-right: 1.5rem; border-right: 1px solid var(--jmg-border); }
.jmg-docs__guide h3 { margin: 0 0 1.5rem; font-size: 1.1rem; }
.jmg-docs__guide ol { margin: 0 0 0 16px; padding: 0; list-style: none; }
.jmg-docs__guide li { display: flex; gap: .9rem; margin: 0; padding: 0 0 2rem; border-left: 1px solid var(--jmg-border); }
.jmg-docs__guide li:last-child { padding-bottom: 0; border-left-color: transparent; }
.jmg-docs .jmg-docs__guide .jmg-docs__guide-link { display: flex; flex-direction: inherit; gap: inherit; width: 100%; color: inherit; text-decoration: none; }
.jmg-docs__guide-number { flex: 0 0 32px; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin-left: -17px; font-size: .95rem; border-radius: 50%; background: var(--jmg-pale); color: var(--jmg-accent); font-weight: 700; }
.jmg-docs__guide strong { display: block; margin: 0 0 .35rem; font-size: .95rem; line-height: 32px; }
.jmg-docs__guide small { display: block; font-size: .85rem; line-height: 1.5; }
.jmg-docs .jmg-docs__guide-note { display: flex; gap: .6rem; margin: 1.5rem 0 0; padding-top: 1.25rem; border-top: 1px solid var(--jmg-border); color: var(--jmg-muted); font-size: .85rem; }
.jmg-docs__guide-note .jmg-docs__icon { flex: 0 0 16px; width: 16px; height: 16px; margin-top: .12rem; color: var(--jmg-accent); }
.jmg-docs button { font-family: inherit; font-size: 1rem; line-height: 1.4; text-transform: none; letter-spacing: normal; }
.jmg-docs__content { min-width: 0; }
.jmg-docs__panel h3, .jmg-docs__success h3 { margin: 0 0 .6rem; font-size: 1.65rem; line-height: 1.3; }
.jmg-docs__panel > h3 { scroll-margin-top: 7rem; }
@media (prefers-reduced-motion: no-preference) {
  html:has(.jmg-docs__panel > h3:target) { scroll-behavior: smooth; }
}
.jmg-docs__panel + .jmg-docs__panel { margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid #a9b0ad; }
.jmg-docs fieldset { display: grid; gap: 1rem; min-width: 0; margin: 1.5rem 0 0; padding: 0; border: 0; }
.jmg-docs legend { float: none; width: 100%; margin: 0 0 .75rem; padding: 0; font-size: 1.1rem; font-weight: 700; }
.jmg-docs label { margin: 0; font-weight: 600; }
.jmg-docs label span:not(.jmg-docs__icon) { font-weight: 400; }
.jmg-docs__row { display: grid; gap: .45rem; }
.jmg-docs__document-help { position: relative; }
.jmg-docs__label-help { display: flex; align-items: center; gap: .4rem; }
.jmg-docs .jmg-docs__help-toggle { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; color: var(--jmg-accent); background: transparent; cursor: help; }
.jmg-docs__help-toggle .jmg-docs__icon { width: 15px; height: 15px; }
.jmg-docs .jmg-docs__help-toggle:hover, .jmg-docs .jmg-docs__help-toggle[aria-expanded="true"] { background: var(--jmg-pale); }
.jmg-docs__help-panel { position: absolute; z-index: 5; top: 2.1rem; left: 0; width: min(580px, 100%); padding: 1.25rem; border: 1px solid var(--jmg-border); border-radius: 8px; background: #fff; box-shadow: 0 8px 24px #23332c1f; }
.jmg-docs__help-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.jmg-docs__help-columns section { display: flex; flex-direction: column; min-width: 0; }
.jmg-docs__help-columns h4 { margin: 0 0 .55rem; font-size: 1rem; line-height: 1.4; }
.jmg-docs__help-columns p { margin: 0 0 1rem; font-size: .9rem; line-height: 1.5; }
.jmg-docs__help-columns img { display: block; width: 100%; max-width: 136px; height: auto; margin: auto 0 0; border: 1px solid var(--jmg-border); }
.jmg-docs__columns { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1.25rem; }
.jmg-docs input:not([type="checkbox"]):not([type="file"]), .jmg-docs select {
  display: block; width: 100%; max-width: 100%; min-width: 0; min-height: 46px; margin: 0;
  padding: .65rem .75rem; border: 1px solid #a9b6b0; border-radius: 4px;
  color: var(--jmg-ink); background-color: #fff; font: inherit;
}
.jmg-docs select { padding-right: 2rem; }
.jmg-docs small, .jmg-docs__hint { color: var(--jmg-muted); font-size: .875rem; line-height: 1.5; }
.jmg-docs fieldset > .jmg-docs__hint { margin: -.5rem 0 0; }
.jmg-docs :focus-visible { outline: 3px solid #3a696b; outline-offset: 3px; }
.jmg-docs [aria-invalid="true"] { border-color: #a03a31 !important; }
.jmg-docs__field-error { color: #802c25; font-size: .875rem; }
.jmg-docs .jmg-docs__visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.jmg-docs dt { color: var(--jmg-muted); font-size: .85rem; font-weight: 400; }
.jmg-docs dd { margin: .15rem 0 0; overflow-wrap: anywhere; }
.jmg-docs__dropzone { position: relative; display: flex; flex-direction: column; align-items: center; gap: .4rem; padding: 1.2rem 1rem; border: 1px dashed var(--jmg-accent); border-radius: 4px; background: var(--jmg-pale); text-align: center; }
.jmg-docs__dropzone > .jmg-docs__icon { width: 32px; height: 32px; font-size: 32px; color: var(--jmg-accent); }
.jmg-docs__dropzone > strong { font-size: 1.05rem; }
.jmg-docs__dropzone.is-dragging { outline: 3px solid var(--jmg-secondary); outline-offset: 2px; background: #e7efeb; }
.jmg-docs__dropzone input:focus-visible + label { outline: 3px solid #3a696b; outline-offset: 3px; }
.jmg-docs .jmg-docs__button {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 44px;
  padding: .7rem 1.4rem; border: 1px solid var(--jmg-accent); border-radius: 4px;
  background: var(--jmg-accent); color: #fff; font: inherit; font-weight: 600;
  line-height: 1.4; text-align: center; text-decoration: none; cursor: pointer;
}
.jmg-docs .jmg-docs__button:hover { border-color: #455a54; background: #455a54; color: #fff; }
.jmg-docs .jmg-docs__button:disabled { cursor: wait; opacity: .65; }
.jmg-docs .jmg-docs__text-button {
  flex-shrink: 0; min-height: 44px; padding: .4rem .25rem; border: 0; border-radius: 4px;
  background: transparent; color: var(--jmg-accent); font: inherit; font-size: .875rem;
  text-decoration: underline; text-underline-offset: .15em; cursor: pointer;
}
.jmg-docs .jmg-docs__text-button:hover { color: #344c44; background: var(--jmg-pale); }
.jmg-docs__files-count { margin: .15rem 0 0 !important; font-weight: 600; }
.jmg-docs__file-list { display: grid; gap: .6rem; margin: -.25rem 0 0; padding: 0; list-style: none; }
.jmg-docs__file-list:empty { display: none; }
.jmg-docs__file { display: flex; align-items: center; gap: 1rem; min-width: 0; margin: 0; padding: .65rem 1rem; border: 1px solid var(--jmg-border); border-radius: 4px; background: #f8f9f8; font-size: .9rem; }
.jmg-docs__file > .jmg-docs__icon { flex: 0 0 24px; width: 24px; height: 24px; font-size: 24px; }
.jmg-docs__file-detail { min-width: 0; flex: 1; }
.jmg-docs__file-detail strong { display: block; overflow-wrap: anywhere; font-weight: 600; }
.jmg-docs__file-detail small { display: block; }
.jmg-docs__file-state { margin-left: auto; color: var(--jmg-muted); font-size: .85rem; white-space: nowrap; }
.jmg-docs__notice { display: flex; align-items: flex-start; gap: .85rem; margin-top: 1.5rem; padding: 1rem; border-radius: 4px; background: #edf4f1; font-size: .9rem; }
.jmg-docs__notice > .jmg-docs__icon { flex: 0 0 16px; width: 16px; height: 16px; margin-top: calc((1.4 * .95rem - 16px) / 2); color: var(--jmg-accent); }
.jmg-docs__notice > div { min-width: 0; }
.jmg-docs__notice h4 { margin: 0 0 .3rem; font-size: .95rem; line-height: 1.4; }
.jmg-docs__notice p { margin: .25rem 0 0; }
.jmg-docs__notice--muted { margin-top: .75rem; background: #f0f2f2; }
.jmg-docs__notice--muted > .jmg-docs__icon { color: #657176; }
.jmg-docs__quota-check { margin-top: 1.25rem; }
.jmg-docs__quota-check > .jmg-docs__hint { margin: .5rem 0 0; }
.jmg-docs__eligibility { margin: .75rem 0 0 !important; overflow-wrap: anywhere; }
.jmg-docs__eligibility:empty { display: none; }
.jmg-docs__terms { min-width: 0; border: 1px solid var(--jmg-border); border-radius: 6px; background: #fff; }
.jmg-docs__terms summary { display: grid; grid-template-columns: 18px minmax(0, 1fr) 16px; align-items: start; gap: .85rem; min-height: 80px; padding: 1rem 1.25rem; border-radius: 6px; color: var(--jmg-ink); list-style: none; cursor: pointer; }
.jmg-docs__terms summary::-webkit-details-marker { display: none; }
.jmg-docs__terms summary:hover { background: var(--jmg-pale); }
.jmg-docs__terms summary strong { display: block; font-size: 1rem; font-weight: 600; line-height: 1.4; }
.jmg-docs__terms summary small { display: block; margin-top: .25rem; font-size: .85rem; }
.jmg-docs__terms summary > .jmg-docs__icon { width: 18px; height: 18px; margin-top: calc((1.4 * 1rem - 18px) / 2); color: var(--jmg-accent); }
.jmg-docs__terms summary > .jmg-docs__icon:last-child { width: 14px; height: 14px; margin-top: calc((1.4 * 1rem - 14px) / 2); }
.jmg-docs__terms[open] { border-color: #a9b6b0; }
.jmg-docs__terms[open] summary { border-bottom: 1px solid var(--jmg-border); border-radius: 6px 6px 0 0; background: var(--jmg-pale); }
.jmg-docs__terms[open] summary > .jmg-docs__icon:last-child { transform: rotate(180deg); }
.jmg-docs__terms-text { max-width: 74ch; margin: 0 auto; padding: 1.5rem 1.75rem; font-size: .95rem; line-height: 1.75; overflow-wrap: anywhere; }
.jmg-docs__terms-text h4 { margin: 1.5rem 0 .65rem; font-size: 1rem; line-height: 1.5; }
.jmg-docs__terms-text p { margin: 0 0 .85rem; }
.jmg-docs__terms-text > :last-child { margin-bottom: 0; }
.jmg-docs__legal-title strong { display: block; font-size: 1.05rem; line-height: 1.5; }
.jmg-docs__legal-title small { display: block; margin-top: .35rem; }
.jmg-docs .jmg-docs__checkbox { display: flex; align-items: flex-start; gap: .75rem; margin-top: .5rem; font-size: .95rem; }
.jmg-docs__checkbox input { flex: 0 0 16px; width: 16px; height: 16px; margin: calc((1.55 * .95rem - 16px) / 2) 0 0; accent-color: var(--jmg-accent); }
.jmg-docs .jmg-docs__acceptance { margin-top: .25rem; padding: 1rem 1.25rem; border-radius: 6px; background: var(--jmg-pale); cursor: pointer; }
.jmg-docs__actions { display: flex; justify-content: flex-end; gap: 1rem; margin-top: 1.75rem; padding-top: 1.5rem; border-top: 1px solid var(--jmg-border); }
.jmg-docs__transfer { margin-top: 1.5rem; }
.jmg-docs__transfer label { display: block; margin-bottom: .4rem; }
.jmg-docs__transfer progress { display: block; width: 100%; height: 16px; accent-color: var(--jmg-accent); }
.jmg-docs__status { margin: 0; overflow-wrap: anywhere; }
.jmg-docs__status:not(:empty) { margin-top: 1.25rem; padding: 1rem; border-left: 4px solid var(--jmg-accent); background: var(--jmg-pale); }
.jmg-docs__status--error:not(:empty) { border-left: 4px solid #a03a31; padding: 1rem; background: #fff2f0; color: #802c25; }
.jmg-docs__success { margin-top: 1.5rem; display: flex; align-items: flex-start; gap: 1.25rem; padding: 1.5rem; border: 1px solid var(--jmg-border); border-radius: 4px; background: var(--jmg-pale); }
.jmg-docs__success > .jmg-docs__icon { flex: 0 0 36px; width: 36px; height: 36px; color: var(--jmg-accent); font-size: 36px; }
.jmg-docs__success > div { min-width: 0; }
.jmg-docs__success strong, .jmg-docs__success .jmg-docs__hint { overflow-wrap: anywhere; }
@media (max-width: 900px) {
  .jmg-docs__form { grid-template-columns: 190px minmax(0, 1fr); gap: 1.5rem; }
  .jmg-docs__guide { padding-right: 1rem; }
  .jmg-docs__columns { grid-template-columns: 1fr; }
  .jmg-docs__file-state { white-space: normal; }
}
@media (max-width: 680px) {
  .jmg-docs { margin: 1.75rem auto; }
  .jmg-docs__header { padding-bottom: 1rem; }
  .jmg-docs__intro { margin: 1.25rem 0 1.75rem; }
  .jmg-docs__help-panel { padding: 1rem; }
  .jmg-docs__help-columns { gap: 1rem; }
  .jmg-docs__form { grid-template-columns: 1fr; gap: 1.75rem; }
  .jmg-docs__guide { position: static; padding: 0 0 1.25rem; border: 0; border-bottom: 1px solid var(--jmg-border); }
  .jmg-docs__guide h3 { margin-bottom: 1rem; }
  .jmg-docs__guide ol { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; margin: 0; }
  .jmg-docs__guide li { flex-direction: column; gap: .5rem; padding: 0; border: 0; }
  .jmg-docs__guide-number { margin: 0; font-size: .825rem; }
  .jmg-docs__guide strong { margin: 0; font-size: .825rem; line-height: 1.4; }
  .jmg-docs__guide small, .jmg-docs .jmg-docs__guide-note { display: none; }
  .jmg-docs__panel h3, .jmg-docs__success h3 { font-size: 1.45rem; }
  .jmg-docs__dropzone { padding: 1.35rem .75rem; }
  .jmg-docs__file { flex-wrap: wrap; gap: .5rem .75rem; padding: .65rem .75rem; }
  .jmg-docs__file-detail { flex-basis: calc(100% - 48px); }
  .jmg-docs__file-state { margin-left: 0; }
  .jmg-docs__file button { margin-left: auto; }
  .jmg-docs__terms summary { gap: .65rem; padding: 1rem; }
  .jmg-docs__terms-text { padding: 1.25rem 1rem; }
  .jmg-docs .jmg-docs__acceptance { padding: 1rem; }
  .jmg-docs__actions { flex-wrap: wrap; }
  .jmg-docs__actions .jmg-docs__button { flex: 1 1 auto; }
  .jmg-docs__success { gap: .75rem; padding: 1rem; }
}

/* Native contact popup stays in the page; its two inline links replace this button. */
.jmg-contact-popup-source > .uagb-spectra-button-wrapper[hidden] { display: none !important; }
