* { box-sizing: border-box; }
body.congress-page { margin: 0; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: #f5f5f5; color: #333; }

/* ── Shell: topbar + sidebar + main ── */
.congress-shell { min-height: 100vh; display: flex; flex-direction: column; }
.congress-topbar { display: flex; align-items: center; gap: 14px; background: #0073aa; color: #fff; padding: 12px 20px; position: sticky; top: 0; z-index: 30; }
.congress-topbar-title { font-size: 1.25em; font-weight: 600; flex: 1; margin: 0; padding: 0; background: transparent; border: none; color: inherit; font-family: inherit; text-align: left; cursor: pointer; }
.congress-topbar-title:hover { text-decoration: underline; }

/* Centered header action (e.g. premium "scan a badge" icon). Absolutely centered in the bar. */
.congress-topbar-scan { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; background: transparent; border: none; border-radius: 8px; color: #fff; cursor: pointer; }
.congress-topbar-scan:hover { background: rgba(255,255,255,.15); }
.congress-topbar-scan .dashicons { font-size: 24px; width: 24px; height: 24px; line-height: 24px; }

.congress-burger { display: none; flex-direction: column; justify-content: center; gap: 4px; width: 38px; height: 38px; padding: 8px; background: rgba(255,255,255,.12); border: none; border-radius: 6px; cursor: pointer; }
.congress-burger span { display: block; height: 2px; background: #fff; border-radius: 2px; }

.congress-notice.expired { background: #f8d7da; color: #721c24; padding: 8px 12px; text-align: center; }

.congress-body { display: flex; flex: 1; align-items: flex-start; }

/* Sidebar (desktop) */
.congress-sidebar { width: 240px; flex-shrink: 0; background: #fff; border-right: 1px solid #e2e2e2; align-self: stretch; padding: 16px 0; position: sticky; top: 62px; height: calc(100vh - 62px); overflow-y: auto; }
.congress-nav-list { list-style: none; margin: 0; padding: 0; }
.congress-nav-link { display: block; padding: 11px 22px; color: #333; text-decoration: none; border-left: 3px solid transparent; font-size: 0.97em; }
.congress-nav-link:hover { background: #f0f6fa; }
.congress-nav-link.active { background: #eaf3f9; border-left-color: #0073aa; color: #0073aa; font-weight: 600; }

.congress-overlay { display: none; }

/* Main content */
.congress-main { flex: 1; min-width: 0; padding: 24px 16px; }
.congress-content { max-width: 820px; margin: 0 auto; }
.congress-section { background: #fff; border: 1px solid #ddd; border-radius: 8px; padding: 22px; margin-bottom: 18px; }
.section-title { margin-top: 0; font-size: 1.2em; }
.congress-loading, .congress-empty, .congress-error { text-align: center; color: #888; padding: 40px 0; }
.congress-error { color: #b32d2e; }

/* Section types */
.section-locked { text-align: center; padding: 20px; }
.section-pw-input { padding: 8px; border: 1px solid #ccc; border-radius: 4px; margin-right: 8px; }
.section-unlock-btn { padding: 8px 16px; background: #0073aa; color: #fff; border: none; border-radius: 4px; cursor: pointer; }
.program-table { width: 100%; border-collapse: collapse; font-size: 0.9em; }
.program-table th, .program-table td { padding: 8px; border-bottom: 1px solid #eee; text-align: left; }
.program-day h3 { font-size: 1em; color: #0073aa; margin-bottom: 8px; }
.download-list, .url-list { list-style: none; padding: 0; margin: 0; }
.download-list li, .url-list li { padding: 6px 0; border-bottom: 1px solid #eee; }
.download-list a, .url-list a { color: #0073aa; }
.media-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.media-gallery img { width: 100%; border-radius: 4px; }
.media-gallery figcaption, .section-image figcaption { font-size: 0.85em; color: #666; text-align: center; margin-top: 6px; }
.section-image { margin: 0; }
.section-image img { width: 100%; height: auto; border-radius: 6px; }
.section-image img.is-zoomable { cursor: zoom-in; }

/* Lightbox overlay */
.congress-lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,.85); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px; cursor: zoom-out; }
.congress-lightbox img { max-width: 95%; max-height: 90%; border-radius: 4px; box-shadow: 0 4px 30px rgba(0,0,0,.5); cursor: default; }
.congress-lightbox-caption { color: #fff; margin-top: 12px; font-size: 0.9em; text-align: center; }
.congress-lightbox-close { position: fixed; top: 16px; right: 20px; width: 40px; height: 40px; font-size: 28px; line-height: 1; color: #fff; background: rgba(255,255,255,.15); border: none; border-radius: 50%; cursor: pointer; }
.congress-lightbox-close:hover { background: rgba(255,255,255,.3); }
.section-video .video-embed { position: relative; }
.section-video .video-embed iframe { width: 100%; aspect-ratio: 16/9; border: 0; border-radius: 6px; }
.section-video video { border-radius: 6px; }

/* ── Mobile: hamburger drawer ── */
@media (max-width: 782px) {
    .congress-burger { display: flex; }
    .congress-sidebar {
        position: fixed; top: 0; left: 0; height: 100vh; z-index: 50;
        transform: translateX(-100%); transition: transform .25s ease;
        box-shadow: 2px 0 12px rgba(0,0,0,.18); padding-top: 60px;
    }
    .drawer-open .congress-sidebar { transform: translateX(0); }
    .drawer-open .congress-overlay { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 40; }
}

.congress-card-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(160px,1fr)); gap:16px; padding:8px 0; }
.congress-card { display:flex; flex-direction:column; align-items:center; text-align:center; gap:8px; padding:18px 12px; border:1px solid #e2e2e2; border-radius:12px; background:#fff; cursor:pointer; transition:box-shadow .15s,transform .15s; }
.congress-card:hover { box-shadow:0 4px 16px rgba(0,0,0,.08); transform:translateY(-2px); }
.congress-card-visual { width:64px; height:64px; display:flex; align-items:center; justify-content:center; }
.congress-card-visual img { width:64px; height:64px; object-fit:cover; border-radius:10px; }
.congress-card-visual .dashicons { font-size:44px; width:44px; height:44px; color:var(--congress-accent,#2271b1); }
.congress-card-title { font-weight:600; }
.congress-card-desc { font-size:13px; color:#666; }
/* Synthetic portal extras: icon-only card (no image/description); keep it centered. */
.congress-card-extra { justify-content:center; }
.congress-card-extra .congress-card-visual .dashicons { color:var(--congress-accent,#2271b1); }
.congress-back { background:none; border:none; cursor:pointer; padding:4px 8px; display:inline-flex; align-items:center; }
.congress-back .dashicons { font-size:22px; width:22px; height:22px; color:inherit; }

/* ── Speakers section ── */
.congress-speakers-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.congress-speaker-card { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 16px 12px; border: 1px solid #e2e2e2; border-radius: 12px; background: #fff; cursor: pointer; transition: box-shadow .15s, transform .15s; font: inherit; color: inherit; }
.congress-speaker-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.08); transform: translateY(-2px); }
.congress-speaker-thumb { width: 88px; height: 88px; object-fit: cover; border-radius: 50%; }
.congress-speaker-card-name { font-weight: 600; }
.congress-speaker-card-role { font-size: 13px; color: #666; }
.congress-speaker-full, .congress-speaker-detail { text-align: center; }
.congress-speaker-photo { width: 140px; height: 140px; object-fit: cover; border-radius: 50%; display: block; margin: 0 auto 12px; }
.congress-speaker-name { margin: 0 0 4px; font-size: 1.25em; }
.congress-speaker-role { margin: 0 0 14px; color: #0073aa; font-weight: 600; }
.congress-speaker-bio { white-space: pre-wrap; text-align: left; max-width: 640px; margin: 0 auto; line-height: 1.55; color: #333; }
.congress-speaker-back { background: none; border: none; cursor: pointer; padding: 4px 6px; margin-bottom: 12px; color: #0073aa; font-size: 0.95em; display: inline-flex; align-items: center; }
.congress-speaker-back:hover { text-decoration: underline; }

/* Portal extras (synthetic nav entries: built-in "My ticket" QR + premium-injected). */
.congress-section-title { margin: 0 auto 8px; max-width: 820px; font-size: 1.2em; text-align: center; }
.congress-ticket-qr { max-width: 260px; width: 100%; height: auto; display: block; margin: 16px auto; }
.congress-ticket-id { text-align: center; font-family: monospace; word-break: break-all; color: #555; }
.congress-ticket-wallet { display: block; width: max-content; max-width: 100%; margin: 20px auto 0; padding: 10px 20px; background: #0073aa; color: #fff; font-size: 0.95em; text-decoration: none; border-radius: 8px; text-align: center; }
.congress-ticket-wallet:hover { background: #005d87; }
