/*
 * Layout fixes and page styles for all screen sizes.
 * Loaded after Styles.css (see includes/head.php).
 */

/* ---------- inner pages: remove the white gap under the menu bar ---------- */
/* The orange top bar (54px) stays in the page flow; the fixed menu bar is 74px tall
   and sits directly below it, so the title bar only needs to clear the menu bar. */
.inner-banner {
    margin-top: 71px !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 34px 0 !important;
    display: flex;
    align-items: center;
}
.inner-banner .container { width: 100%; }
.inner-banner h3, .inner-banner h1 { margin: 0 !important; letter-spacing: .5px; }
.main-content { padding-top: 40px; }

/* ---------- brochure page ---------- */
.brochure-page { padding: 40px 0 60px !important; background: #f6f7f9; }
.brochure-page .row { display: flex; flex-wrap: wrap; }
.brochure-page .row:before, .brochure-page .row:after { display: none; }

.bro-card {
    background: #fff; border-radius: 14px; padding: 32px 32px 28px;
    box-shadow: 0 6px 24px rgba(15, 23, 42, .07); border: 1px solid #eceef2;
    margin-bottom: 24px;
}
.bro-title { font-size: 26px !important; margin: 0 0 8px !important; color: #1f2937 !important; text-align: left !important; }
.bro-title:after, .bro-title:before { display: none !important; }
.bro-sub { color: #5b6472; font-size: 15px; line-height: 1.6; margin: 0 0 22px; text-align: left !important; }
.bro-intro { margin: -6px 0 20px; color: #374151; }

.bro-form .bro-row { display: flex; gap: 16px; }
.bro-form .bro-row > .bro-field { flex: 1 1 0; min-width: 0; }
.bro-form .bro-row > .bro-field-sm { flex: 0 0 110px; }
.bro-form .bro-field { margin-bottom: 16px; }
.bro-form label { display: block; font-size: 13.5px; font-weight: 600; color: #374151; margin: 0 0 6px; }
.bro-form label span { color: #e2552b; }
.bro-form .form-control {
    height: 44px; border-radius: 8px; border: 1px solid #d5d9e0; box-shadow: none;
    font-size: 15px; padding: 8px 12px; background: #fff;
}
.bro-form textarea.form-control { height: auto; min-height: 110px; resize: vertical; }
.bro-form .form-control:focus { border-color: #ff5501; box-shadow: 0 0 0 3px rgba(255, 85, 1, .15); outline: 0; }

.bro-actions { display: flex; gap: 12px; align-items: center; margin-top: 6px; }
.bro-btn {
    background: #ff5501; color: #fff !important; border: 0; border-radius: 8px;
    padding: 12px 26px; font-size: 15px; font-weight: 600;
}
.bro-btn:hover, .bro-btn:focus { background: #e04a00; color: #fff; }
.bro-btn i { margin-right: 6px; }
.bro-reset { background: transparent; border: 1px solid #d5d9e0; border-radius: 8px; padding: 11px 20px; color: #4b5563; font-size: 15px; }
.bro-reset:hover { background: #f3f4f6; }

.bro-side {
    background: #1f2937; color: #e5e7eb; border-radius: 14px; padding: 30px 28px;
    position: sticky; top: 150px;
}
.bro-side-icon {
    width: 52px; height: 52px; border-radius: 12px; background: #ff5501; color: #fff;
    display: flex; align-items: center; justify-content: center; font-size: 26px; margin-bottom: 16px;
}
.bro-side h3 { color: #fff !important; font-size: 21px !important; margin: 0 0 14px !important; text-align: left !important; }
.bro-side ul { list-style: none; padding: 0 !important; margin: 0 0 22px; }
.bro-side li { color: #e5e7eb !important; padding: 8px 0; border-bottom: 1px solid rgba(255, 255, 255, .08); font-size: 15px; line-height: 1.45; display: flex; gap: 10px; }
.bro-side li:last-child { border-bottom: 0; }
.bro-side li i { color: #ff7a3a; margin-top: 4px; }
.bro-help { background: rgba(255, 255, 255, .06); border-radius: 10px; padding: 12px 14px; margin-bottom: 18px; font-size: 14px; }
.bro-help strong { display: block; color: #fff; margin-bottom: 2px; }
.bro-help a { color: #ffb08a; word-break: break-all; }
.bro-links { display: flex; gap: 10px; flex-wrap: wrap; }
.bro-link {
    flex: 1 1 auto; text-align: center; padding: 11px 14px; border-radius: 8px; font-weight: 600; font-size: 14px;
    background: #ff5501; color: #fff !important; text-decoration: none !important;
}
.bro-link-alt { background: transparent; border: 1px solid rgba(255, 255, 255, .35); }
.bro-link:hover { opacity: .9; }

@media (max-width: 991px) {
    .bro-side { position: static; }
}
@media (max-width: 767px) {
    .inner-banner { padding: 24px 0 !important; }
    .brochure-page { padding: 20px 0 40px !important; }
    .bro-card { padding: 22px 18px; border-radius: 12px; }
    .bro-title { font-size: 22px !important; }
    .bro-form .bro-row { flex-direction: column; gap: 0; }
    .bro-form .bro-row > .bro-field-sm { flex: 1 1 auto; }
    .bro-actions { flex-direction: column; align-items: stretch; }
    .bro-btn, .bro-reset { width: 100%; }
    .brochure-page .row > [class*="col-"] { width: 100% !important; }
}

/* ---------- even spacing on every inner page ---------- */
.main-content { padding-top: 40px !important; padding-bottom: 60px !important; }
.main-content > .container > :last-child,
.main-content > .container > .row > :last-child { margin-bottom: 0; }

/* committee / plenary cards: rows size to their content (no fixed 477px height) */
.orgcommeties ul { display: flex; flex-wrap: wrap; padding-left: 0; margin-bottom: 0; }
.orgcommeties ul > li, .orgcommeties ul > a { min-height: 0 !important; margin-bottom: 28px !important; }
.orgcommeties li { min-height: 0 !important; }
.orgcommeties li p { margin-bottom: 0; }
/* Scientific Committee on the home page: each card is wrapped in a link (<a><li>...</li></a>).
   Size the link like a keynote card (23% + 10px margin) and let the card fill it,
   so names and affiliations line up the same way as the Keynote Speakers. */
@media (min-width: 768px) {
    .orgcommeties ul > a { display: block; width: 23%; margin: 10px; color: inherit; text-decoration: none !important; }
    .orgcommeties ul > a > li { width: 100% !important; margin: 0 !important; float: none !important; }
}
.orgcommeties ul > a:hover h4 { text-decoration: underline; }

/* speakers & gallery boxes: no fixed 390px height, rows line up */
.speaker_box { min-height: 0 !important; margin-bottom: 26px; }
.row:has(> [class*="col-"] > .speaker_box) { display: flex; flex-wrap: wrap; }
.row:has(> [class*="col-"] > .speaker_box):before,
.row:has(> [class*="col-"] > .speaker_box):after { display: none; }

/* ---------- tablets & small laptops: keep the menu on one line ---------- */
@media (min-width: 768px) and (max-width: 1199px) {
    .headerHome .navbar-nav > li > a { font-size: 12px !important; padding: 10px 5px !important; letter-spacing: 0; }
    .headerHome a img { max-height: 56px; width: auto; }
}
/* tablets (768-991px): the menu doesn't fit on one line, so use the menu button like phones */
@media (min-width: 768px) and (max-width: 991px) {
    .headerHome .suHeaderContainer { position: relative; display: flow-root; }
    .headerHome .navbar-toggle {
        display: block !important; float: right; background: #fff; border-radius: 6px;
        margin: 14px 0 0; padding: 9px 12px; font-size: 18px; color: #111;
    }
    .headerHome .su-menu { float: none !important; position: absolute; left: 0; right: 0; top: 100%; z-index: 100; }
    .headerHome .navbar-collapse.collapse { display: none !important; }
    .headerHome .navbar-collapse.collapse.in,
    .headerHome .navbar-collapse.collapsing { display: block !important; }
    .headerHome .navbar-collapse { background: #000; width: 100% !important; margin: 0 !important; padding: 6px 0; max-height: 75vh; overflow-y: auto; border-top: 1px solid rgba(255,255,255,.1); }
    .headerHome .navbar-nav { float: none !important; margin: 0 !important; }
    .headerHome .navbar-nav > li { float: none !important; }
    .headerHome .navbar-nav > li > a { font-size: 14px !important; padding: 12px 20px !important; border-bottom: 1px solid rgba(255,255,255,.08); }
}

/* "Will be updated very soon" box for empty committee / speaker lists */
.soon-notice {
    list-style: none; display: block; width: 100% !important; flex: 1 1 100%;
    margin: 10px auto 30px !important; padding: 34px 20px !important; float: none !important;
    text-align: center; font-size: 19px; font-weight: 600; color: #4b5563;
    background: #f6f7f9; border: 1px dashed #cfd5dd; border-radius: 12px; min-height: 0 !important;
}
.soon-notice i { color: #ff5501; margin-right: 8px; }
.featured-speaker .soon-notice { max-width: 900px; }
