/* ICoTA Asia – overrides on top of the global app.css */
.card-news .card-media img[src$=".png"] { background: #fff; }

/* About page: Asia Chapter Board table */
.asia-board { padding-bottom: var(--space-3xl); }
.asia-board .block-header { margin-bottom: var(--space-m); }
.asia-board-intro { max-width: 46rem; margin-bottom: var(--space-l); font-size: var(--step-0); color: #185CA3; }
.asia-board-intro a { text-decoration: underline; }
.asia-board .table-wrap { overflow-x: auto; border-radius: var(--space-s); border: 1px solid #185CA3; }
.asia-board table { width: 100%; border-collapse: collapse; min-width: 36rem; color: #185CA3; font-size: var(--step-0); text-align: left; }
.asia-board th { background: linear-gradient(to right, #185CA3, #48CDFF); color: #fff; font-weight: 900; padding: var(--space-xs) var(--space-s); }
.asia-board td { padding: var(--space-xs) var(--space-s); border-top: 1px solid rgb(24 92 163 / .25); }
.asia-board tbody tr:nth-child(even) { background: #EBFAFF; }

/* Placeholder avatar for people without a supplied photo */
.avatar-ph { display: flex; align-items: center; justify-content: center; width: 100%; aspect-ratio: 1; background-image: linear-gradient(135deg, #185CA3, #48CDFF); color: #fff; font-weight: 900; font-size: var(--step-5); border-radius: inherit; }

/* Globe list: sub-chapters that are not active yet */
.map-link--soon { opacity: .45; cursor: default; pointer-events: auto; display: inline-flex; align-items: center; gap: .4em; }
.map-link--soon small { font-size: .7em; letter-spacing: .04em; text-transform: uppercase; }

.chapter-label.soon:not(.hide) { opacity: .4; }

.events-list-heading { font-size: var(--step-2); font-weight: 900; margin-bottom: var(--space-s); }

/* Membership checkbox on the contact form */
.contact-form .contact-check { display: flex; align-items: flex-start; gap: .75rem; font-size: var(--step--1) !important; line-height: 1.5 !important; cursor: pointer; }
.contact-form .contact-check input[type=checkbox] { flex: 0 0 auto; width: 1.25rem !important; height: 1.25rem !important; min-width: 1.25rem; margin: .15rem 0 0; padding: 0; accent-color: #185CA3; appearance: auto; -webkit-appearance: checkbox; }

/* Contact form helpers */
.contact-form .hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-notice { margin-bottom: var(--space-s); padding: var(--space-xs) var(--space-s); border-radius: var(--space-2xs); font-size: var(--step--1); }
.contact-notice--ok { background: #EBFAFF; color: #185CA3; border: 1px solid #185CA3; }
.contact-notice--error { background: #fff0f0; color: #a31818; border: 1px solid #a31818; }

/* Event photo galleries (core Gallery block): even tiles; a single image such as a poster keeps its own shape */
.rich-text .wp-block-gallery.has-nested-images { --wp--style--unstable-gallery-gap: var(--space-xs); margin-top: var(--space-s); }
.rich-text .wp-block-gallery.has-nested-images figure.wp-block-image img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; }
.rich-text .wp-block-gallery.has-nested-images.columns-1 figure.wp-block-image img { aspect-ratio: auto; object-fit: contain; }

/* Photo lightbox (assets/js/lightbox.js) */
.rich-text .wp-block-gallery.has-nested-images figure.wp-block-image img { cursor: zoom-in; }
.lightbox { position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; padding: var(--space-m); background: rgb(3 20 41 / .94); animation: lightbox-in .2s ease; }
.lightbox[hidden] { display: none; }
.lightbox-stage { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.lightbox-img { display: block; width: min(92vw, calc(82vh * var(--ratio, 1.5)), 1200px); max-width: none; height: auto; aspect-ratio: var(--ratio, 1.5); object-fit: contain; border-radius: .5rem; box-shadow: 0 1rem 3rem rgb(0 0 0 / .5); }
.lightbox .lightbox-btn { position: absolute; display: flex; align-items: center; justify-content: center; width: 3rem; height: 3rem; margin: 0; padding: 0; border: 1px solid rgb(255 255 255 / .7); border-radius: 50%; background: rgb(24 92 163 / .9); color: #fff; cursor: pointer; transition: background-color .15s; }
.lightbox .lightbox-btn:hover { background: #185CA3; }
.lightbox .lightbox-btn:focus-visible { outline: 3px solid #48CDFF; outline-offset: 2px; }
.lightbox .lightbox-btn[hidden] { display: none; }
.lightbox-close { top: var(--space-s); right: var(--space-s); }
.lightbox-prev { left: var(--space-s); top: 50%; transform: translateY(-50%); }
.lightbox-next { right: var(--space-s); top: 50%; transform: translateY(-50%); }
.lightbox-count { position: absolute; bottom: var(--space-s); left: 50%; margin: 0; transform: translateX(-50%); color: #fff; font-size: var(--step--1); letter-spacing: .04em; }
.lightbox-count[hidden] { display: none; }
html.lightbox-open { overflow: hidden; }
@keyframes lightbox-in { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 40rem) {
  .lightbox-img { width: min(92vw, calc(74vh * var(--ratio, 1.5))); }
  .lightbox-prev, .lightbox-next { top: auto; bottom: var(--space-s); transform: none; }
  .lightbox-prev { left: calc(50% - 5rem); }
  .lightbox-next { right: calc(50% - 5rem); }
  .lightbox-count { bottom: calc(var(--space-s) + 3.5rem); }
}
@media (prefers-reduced-motion: reduce) { .lightbox { animation: none; } .lightbox .lightbox-btn { transition: none; } }
