/*
 * Maintenance Request Form — /maintenance-request.
 *
 * Loaded only on this page. Same visual language as the online annex forms
 * (request-forms.css): Jost via var(--jost), hairline rules, black buttons.
 * Spacing uses logical properties, so the Arabic page mirrors from
 * dir="rtl" alone; the tracking overrides are at the end.
 *
 * A new filename, so no CloudFront invalidation is needed to ship it.
 */

.maintenance { background: #fff; padding: 4.5rem 0 6rem; font-family: var(--jost), 'Jost', sans-serif; }
.maintenance .mr-inner { max-width: 860px; }

.mr-back { display: inline-block; font-size: 0.78rem; letter-spacing: 0.22em; text-transform: uppercase; color: #6e6e6e; text-decoration: none; margin-bottom: 2.25rem; }
.mr-back:hover { color: #101010; }

.mr-head { margin-bottom: 2.5rem; }
.mr-eyebrow { display: block; font-size: 0.75rem; letter-spacing: 0.32em; text-transform: uppercase; color: #9a9a9a; margin-bottom: 0.9rem; }
.mr-lede { font-size: 1.05rem; line-height: 1.7; color: #4a4a4a; margin: 0 0 0.75rem; max-width: 680px; }
.mr-note { font-size: 0.85rem; color: #6e6e6e; margin: 0; }
.mr-star { color: #b3261e; }
.mr-alert { border-radius: 0; margin-bottom: 2.5rem; }

/* The gate ------------------------------------------------------------ */

.mr-gate { max-width: 520px; }
.mr-gate .form-control { margin-bottom: 0; padding: 12px 14px; font-size: 0.98rem; }
.mr-gate-actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; margin-top: 1.75rem; }
.mr-linkbtn { background: none; border: 0; padding: 0; font: inherit; font-size: 0.86rem; color: #6e6e6e; text-decoration: underline; cursor: pointer; }
.mr-linkbtn:hover { color: #101010; }
.mr-code-input { font-size: 1.6rem; letter-spacing: 0.5em; text-align: center; direction: ltr; }

/* Signed-in strip ----------------------------------------------------- */

.mr-tenant { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; background: #f9f9f9; padding: 1rem 1.3rem; margin-bottom: 2rem; }
.mr-tenant-name { font-size: 0.98rem; color: #101010; margin: 0; }
.mr-tenant-name span { color: #6e6e6e; font-size: 0.82rem; letter-spacing: 0.14em; text-transform: uppercase; margin-inline-end: 0.5rem; }

/* Stepper ------------------------------------------------------------- */

/* An <ol> for the order it carries, but the numbers are drawn as the circles
   below, so the list's own markers are turned off. */
.mr-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.5rem; margin: 0 0 2.5rem; padding: 0; list-style: none; }
.mr-step { text-align: center; position: relative; padding-top: 2.6rem; }
/* The number sits above the rule joining it to the next step. Both are given
   a positive z-index rather than pushing the rule to -1, which would drop it
   behind the section's own background and make it vanish. */
.mr-step::before { content: attr(data-index); position: absolute; top: 0; inset-inline-start: 50%; transform: translateX(-50%); width: 30px; height: 30px; border-radius: 50%; border: 1px solid #d5d5d5; color: #9a9a9a; font-size: 0.85rem; line-height: 28px; background: #fff; z-index: 1; }
.mr-step::after { content: ''; position: absolute; top: 15px; inset-inline-start: 50%; width: 100%; height: 1px; background: #e2e2e2; z-index: 0; }
.mr-step:last-child::after { display: none; }
.mr-step-label { display: block; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase; color: #9a9a9a; line-height: 1.45; }
.mr-step.is-done::before { content: '✓'; border-color: #101010; background: #101010; color: #fff; }
.mr-step.is-done::after { background: #101010; }
.mr-step.is-current::before { border-color: #101010; background: #101010; color: #fff; }
.mr-step.is-current .mr-step-label { color: #101010; }

/* Panels -------------------------------------------------------------- */

.mr-panel { border-top: 1px solid rgba(16, 16, 16, 0.14); padding: 2rem 0 0.5rem; min-width: 0; }
.mr-panel[hidden] { display: none; }
.mr-panel-title { font-size: 0.8rem; font-weight: 500; letter-spacing: 0.26em; text-transform: uppercase; color: #101010; margin: 0 0 1.5rem; }

.mr-field { margin-bottom: 1.5rem; min-width: 0; }
.mr-label { display: block; font-size: 0.9rem; font-weight: 500; color: #101010; margin-bottom: 0.45rem; line-height: 1.4; }
.maintenance .form-control { margin-bottom: 0; padding: 12px 14px; font-size: 0.98rem; }
.maintenance textarea.form-control { min-height: 150px; }
.mr-hint { display: block; font-size: 0.82rem; line-height: 1.55; color: #6e6e6e; margin-top: 0.45rem; }
.mr-error { display: block; font-size: 0.82rem; color: #b3261e; margin-top: 0.4rem; }
/* Author `display` beats the user-agent's [hidden] rule, so without this the
   empty error span kept its margin and `hidden` meant nothing. */
.mr-error[hidden] { display: none; }
.mr-error-line { display: block; }
.mr-error-line + .mr-error-line { margin-top: 0.25rem; }
.mr-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.75rem; }

/* Unit and permission choices, stacked as in the mock-up */
.mr-choices { display: flex; flex-direction: column; gap: 0.6rem; }
.mr-choice { display: flex; align-items: center; justify-content: space-between; gap: 0.9rem; border: 1px solid #ddd; padding: 0.95rem 1.2rem; cursor: pointer; font-size: 0.97rem; margin: 0; transition: border-color 0.2s ease, background 0.2s ease; }
.mr-choice:hover { border-color: #101010; }
.mr-choice input { accent-color: #101010; margin: 0; flex-shrink: 0; }
.mr-choice:has(input:checked) { border-color: #101010; background: #f6f6f6; }

/* Photos */
.mr-drop { border: 1px dashed #c9c9c9; padding: 2.2rem 1.25rem; text-align: center; cursor: pointer; display: block; transition: border-color 0.2s ease, background 0.2s ease; }
.mr-drop:hover, .mr-drop.is-over { border-color: #101010; background: #fafafa; }
/* A refused attachment disappears from the field; the box has to show it. */
.mr-drop.is-invalid { border-color: #b3261e; border-style: solid; background: #fdf4f3; }
.mr-drop.is-invalid .mr-drop-text { color: #b3261e; }
.mr-drop input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.mr-drop-text { font-size: 0.95rem; color: #101010; margin: 0 0 0.35rem; }
.mr-drop-hint { font-size: 0.82rem; color: #6e6e6e; margin: 0; }
.mr-files { list-style: none; margin: 0.9rem 0 0; padding: 0; }
.mr-files li { font-size: 0.88rem; color: #4a4a4a; padding: 0.35rem 0; border-bottom: 1px solid #f0f0f0; }

/* Confirmation table */
.mr-summary { width: 100%; border-collapse: collapse; }
.mr-summary th { width: 38%; text-align: start; font-size: 0.85rem; font-weight: 400; color: #6e6e6e; padding: 0.85rem 0; border-bottom: 1px solid #ececec; vertical-align: top; }
.mr-summary td { font-size: 0.97rem; color: #101010; padding: 0.85rem 0; border-bottom: 1px solid #ececec; text-align: end; vertical-align: top; white-space: pre-line; }

.mr-captcha { display: flex; align-items: flex-start; flex-wrap: wrap; gap: 15px; margin-top: 2rem; }
.mr-captcha-input { flex: 1; min-width: 200px; }
.mr-captcha .captcha-box { max-width: 100%; flex-wrap: wrap; }
.mr-captcha .captcha-box img { max-width: 100%; height: auto; }
.mr-captcha .cf-turnstile { width: 100%; max-width: 400px; }

/* Step navigation */
.mr-actions { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 2.25rem; }
.mr-actions--end { justify-content: flex-end; }
.mr-btn { font-family: inherit; letter-spacing: 0.18em; text-transform: uppercase; font-size: 0.85rem; font-weight: 500; padding: 0.95rem 2.4rem; border: 1px solid #101010; cursor: pointer; transition: background 0.2s ease, color 0.2s ease; }
.mr-btn--primary { background: #101010; color: #fff; flex: 1; }
.mr-btn--primary:hover { background: #2c2c2c; }
.mr-btn--primary:disabled { opacity: 0.6; cursor: progress; }
.mr-btn--ghost { background: #fff; color: #101010; }
.mr-btn--ghost:hover { background: #101010; color: #fff; }

/* Success -------------------------------------------------------------- */

.mr-done { border: 1px solid rgba(16, 16, 16, 0.14); padding: 3rem 2.5rem; text-align: center; }
.mr-done h2 { font-size: 1.5rem; color: #101010; margin: 0 0 1rem; }
.mr-done p { font-size: 1rem; line-height: 1.7; color: #4a4a4a; margin: 0 auto 1.75rem; max-width: 520px; }

@media (max-width: 767px) {
    .maintenance { padding: 3rem 0 4rem; }
    .mr-pair { grid-template-columns: 1fr; }
    .mr-steps { gap: 0.25rem; }
    .mr-step-label { font-size: 0.62rem; letter-spacing: 0.04em; }
    .mr-actions { flex-direction: column-reverse; }
    .mr-btn { width: 100%; }
    .mr-summary th, .mr-summary td { display: block; width: auto; text-align: start; }
    .mr-summary th { border-bottom: 0; padding-bottom: 0.2rem; }
    .mr-done { padding: 2rem 1.25rem; }
}

/* Arabic: a joined script, so no tracking (see FSRE-ar.css for why). */
body.lang-ar .mr-back,
body.lang-ar .mr-eyebrow,
body.lang-ar .mr-panel-title,
body.lang-ar .mr-step-label,
body.lang-ar .mr-tenant-name span,
body.lang-ar .mr-btn { letter-spacing: 0; text-transform: none; }
body.lang-ar .mr-panel-title { font-size: 1rem; }
body.lang-ar .mr-code-input { letter-spacing: 0.5em; }
