/* EVMAX on WordPress: Contact Form 7 markup and editor content in the design's styles (on top of main.css). */

/* ---------- Admin bar (logged-in editors) ---------- */
.admin-bar .site-header { top: calc(16px + 32px); }
@media (max-width: 782px) { .admin-bar .site-header { top: calc(10px + 46px); } }
@media (max-width: 600px) { .admin-bar .site-header { top: 10px; } } /* the admin bar scrolls away on phones */

/* ---------- Contact Form 7 ---------- */
.wpcf7 { min-width: 0; }
.wpcf7 form { margin: 0; }
.wpcf7 .hidden-fields-container { display: none; border: 0; padding: 0; margin: 0; }
.wpcf7-form-control-wrap { position: relative; display: block; }
.wpcf7 .field > .wpcf7-form-control-wrap, .wpcf7 .select > .wpcf7-form-control-wrap { display: flex; flex-direction: column; gap: 6px; }
.wpcf7 .form-actions .field { min-width: 0; }

/* Selects: the design's chevron, drawn in CSS because CF7 form templates hold no icons. */
.wpcf7 .select select {
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230089cf' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 14px center / 18px 18px;
}

/* Submit buttons are <input type="submit">: no icon, and a dimmed state while sending. main.js puts each in a box with
   its spinner, which then spins inside the button at its right end; the label moves left to make room, and the button
   keeps its size. */
.wpcf7-submit.btn { -webkit-appearance: none; appearance: none; }
.submit-box { position: relative; display: inline-flex; }
.submit-box > .wpcf7-submit { flex: 1; }
.modal .submit-box { display: flex; }
.wpcf7-form.submitting .wpcf7-submit { opacity: .7; pointer-events: none; cursor: progress; padding-left: 8px; padding-right: 40px; }
.wpcf7-spinner { display: none; }
.wpcf7-form.submitting .wpcf7-spinner { display: block; position: absolute; top: 50%; right: 14px; width: 18px; height: 18px; margin: -9px 0 0; border: 2px solid #fff; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }

/* Errors under a field (the design's .field__error) */
.wpcf7-not-valid-tip { display: block; margin-top: 2px; font-size: 13px; color: var(--error); }
.wpcf7 .field .wpcf7-not-valid { border-color: var(--error); }
.wpcf7 .field--check .wpcf7-not-valid-tip { margin-top: 6px; }

/* reCAPTCHA: Google's floating badge is hidden (visibility keeps it working), and each form carries Google's notice. */
.grecaptcha-badge { visibility: hidden; }
.wpcf7 .form-recaptcha { margin: 14px 0 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
.wpcf7 .form-recaptcha a { color: inherit; text-decoration: underline; }
.on-blue .wpcf7 .form-recaptcha { color: rgba(255, 255, 255, .8); }

/* The message under the form (the design's .form-status) */
.wpcf7-response-output { margin-top: 16px; padding: 12px 16px; border-radius: 10px; font-size: 14px; }
.wpcf7-response-output:empty, .wpcf7 form.init .wpcf7-response-output, .wpcf7 form.resetting .wpcf7-response-output, .wpcf7 form.submitting .wpcf7-response-output { display: none; }
.wpcf7 form.sent .wpcf7-response-output { background: #e7f6ee; color: var(--success); }
.wpcf7 form.invalid .wpcf7-response-output, .wpcf7 form.unaccepted .wpcf7-response-output, .wpcf7 form.failed .wpcf7-response-output,
.wpcf7 form.aborted .wpcf7-response-output, .wpcf7 form.spam .wpcf7-response-output { background: #fdecee; color: var(--error); }
.on-blue .wpcf7 form.sent .wpcf7-response-output, .on-blue .wpcf7 form .wpcf7-response-output { background: rgba(255, 255, 255, .95); }
.form-card .wpcf7-response-output { margin-top: 20px; }
.screen-reader-response { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Consent checkbox (CF7 acceptance) */
.field--check .wpcf7-list-item { display: block; margin: 0; }
.field--check .wpcf7-list-item label { display: flex; align-items: flex-start; gap: 12px; font-size: 13px; color: var(--text); cursor: pointer; }
.field--check .wpcf7-list-item input { width: 20px; height: 20px; min-height: 0; margin: 1px 0 0; padding: 0; flex: none; accent-color: var(--blue); cursor: pointer; }
.field--check .wpcf7-not-valid .wpcf7-list-item label { color: var(--error); }

/* Form cards: the form element itself is the card (html_class). */
.wpcf7 .form-card__title + .form-grid { margin-top: 0; }

/* Support hub: blue band with the quick message form */
.support-message .wpcf7-not-valid-tip { color: #fff; }
.support-message .form-actions .submit-box { align-self: flex-start; }
.support-message .form-actions .wpcf7-submit { min-height: 46px; }

/* Data sheet modal: the panel is a div around the form */
.modal__panel .wpcf7-submit { margin-top: 0; }
/* The popup keeps its size: each error sits in room kept under its field (the rows' gap, and the space before the
   button under the consent box), and the box saying "Please check the highlighted fields." stays out of sight, as the
   errors say it; screen readers still hear Contact Form 7's own summary. A failure to send still shows its box. */
.modal .form-grid { row-gap: 26px; }
.modal .wpcf7-form-control-wrap { position: relative; display: block; }
.modal .wpcf7-not-valid-tip { position: absolute; top: 100%; left: 0; right: 0; }
.modal form.invalid .wpcf7-response-output, .modal form.unaccepted .wpcf7-response-output { display: none; }

/* ---------- Editor content (articles and ordinary pages) ---------- */
.article__body > .wp-block-group, .article__body > figure, .article__body > ul, .article__body > ol, .article__body > blockquote { margin: 0 0 20px; }
.article__body ul, .article__body ol { padding-left: 22px; line-height: 1.9; font-size: 15px; }
.article__body ul { list-style: disc; }
.article__body h3 { font-size: 19px; color: var(--ink); margin: 32px 0 14px; }
.article__body h2:not(:first-child):not(.eyebrow + h2) { margin-top: 40px; }
.article__body img { border-radius: var(--radius); }
.article__body figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); }
.article__body blockquote { padding: 4px 0 4px 20px; border-left: 4px solid var(--blue); color: var(--ink); font-style: italic; }
.article__body > .article__highlight { margin: 32px 0 0; }
.article__body .article__highlight p { margin: 0; }
.article__body .article__highlight p:first-child { font-size: 16px; } /* holds the <strong> title, as in the design's <aside> */
.prose ol { padding-left: 22px; margin-bottom: 16px; line-height: 1.8; }
.prose img { border-radius: var(--radius); }

/* Featured image of logos/artwork on the Blog page */
.blog-hero__media--contain { background: var(--bg-tint); }
.blog-hero__media--contain img { object-fit: contain; padding: 24px; mix-blend-mode: multiply; }

/* Archive pagination */
.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.pagination .page-numbers { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--navy); }
.pagination .page-numbers.current { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Old posts imported from the previous theme can carry wide embeds and tables */
.article__body iframe, .article__body table { max-width: 100%; }
