/*modals*/

#ce21-faculty-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
}
.ce21-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.6);
}
.ce21-modal-box {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 6px;
    max-width: 680px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    padding: 30px;
    box-sizing: border-box;
}
.ce21-modal-close {
    position: absolute;
    top: 12px;
    right: 16px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    line-height: 1;
}
.ce21-modal-profile {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}
.ce21-modal-photo {
    width: 120px;
    height: auto;
    border-radius: 4px;
    flex-shrink: 0;
}
.ce21-modal-info h2 { margin-top: 0; }
.ce21-modal-title  { font-weight: bold; margin: 4px 0; }
.ce21-modal-org    { color: #555; margin: 4px 0; }
.ce21-modal-bio    { margin-top: 10px; }
.ce21-modal-programs { margin-top: 20px; border-top: 1px solid #eee; padding-top: 15px; }
.ce21-modal-program  { margin-bottom: 12px; }
body.ce21-modal-open { overflow: hidden; }

/* faculty list */

.ce21-faculty-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.ce21-faculty-member {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.ce21-faculty-member img {
    width: 100%;
    max-width: 200px;
    height: auto;
    border-radius: 4px;
    cursor: pointer;
}
.ce21-faculty-name { font-weight: bold; margin: 8px 0 2px; }
.ce21-faculty-title { font-size: 15px; margin: 2px 0; }
.ce21-faculty-org   { font-size: 15px; margin: 2px 0; }

@media (max-width: 768px) {
    .ce21-faculty-list { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .ce21-faculty-list { grid-template-columns: 1fr; }
}
/* exhibitor list */

.ce21-exhibitors-list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 20px;
}
.ce21-exhibitor {
    display: flex;
    align-items: center;
    justify-content: center;
}
.ce21-exhibitor-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    text-decoration: none;
    transition: box-shadow 0.15s ease;
}
.ce21-exhibitor-trigger:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.ce21-exhibitor-trigger img {
    max-width: 100%;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
}
.ce21-exhibitor-name-only {
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    color: #333;
}

/* exhibitor modal */

#ce21-exhibitor-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
}
.ce21-modal-exhibitor-header {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 20px;
}
.ce21-modal-exhibitor-logo {
    max-width: 160px;
    max-height: 100px;
    width: auto;
    height: auto;
    object-fit: contain;
    flex-shrink: 0;
}
.ce21-modal-exhibitor-meta h2 { margin: 0 0 6px; }
.ce21-modal-exhibitor-meta p  { margin: 0; }
.ce21-modal-exhibitor-card {
    border-top: 1px solid #eee;
    padding-top: 15px;
    margin-top: 15px;
}
.ce21-modal-exhibitor-card h3 { margin-top: 0; font-size: 16px; }
.ce21-modal-exhibitor-images {
    margin-top: 15px;
    border-top: 1px solid #eee;
    padding-top: 15px;
}
.ce21-modal-exhibitor-images img {
    max-width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .ce21-exhibitors-list { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 480px) {
    .ce21-exhibitors-list { grid-template-columns: repeat(2, 1fr); }
    .ce21-modal-exhibitor-header { flex-direction: column; }
}

.ce21-exhibitors-names {
	column-count: 2;
	column-gap: 16px;
	margin-top: 20px;
}
.ce21-exhibitors-names .ce21-exhibitor {
	break-inside: avoid;
	margin-bottom: 8px;
}
.ce21-exhibitors-names .ce21-exhibitor-trigger {
	border: none;
	padding: 4px 0;
	justify-content: flex-start;
}
.ce21-exhibitors-names .ce21-exhibitor-name-only {
	font-size: 15px;
	font-weight: normal;
}
@media (max-width: 480px) {
	.ce21-exhibitors-names { column-count: 1; }
}
/* ── Schedule-row speaker name links (span.clsFacultyDetail) ────────────
   CE21 renders these as plain spans; we style them to look interactive
   without adding markup. Scoped inside .ce21-element so the style only
   applies to the scraped schedule HTML, not the Speakers tab grid.      */

.ce21-element span.clsFacultyDetail {
    cursor: pointer;
    color: #0073aa;
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 2px;
    transition: color 0.15s ease;
}

.ce21-element span.clsFacultyDetail:hover {
    color: #005177;
    text-decoration-style: solid;
}

/* ── Faculty members without a photo (schedule-only speakers) ───────────
   render_faculty() outputs a card for every fetched speaker. If there's
   no imageUrl the card has no trigger link — just the name/title text.
   Keep those cards tidy in the grid.                                     */

.ce21-faculty-member:not(:has(.ce21-faculty-trigger)) {
    /* No photo — left-align rather than centering an orphaned text block */
    align-items: flex-start;
    text-align: left;
    padding: 8px 0;
}
