/**
 * Content Layout + Sidebar + Single Conference
 *
 * Two-column content wrapper, sticky sidebar widgets,
 * and full single-conference page styling.
 *
 * @package IBCES
 */

/* ========================================
   Content Layout (Generic)
======================================== */
.content-wrapper {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: var(--spacing-2xl);
}

.content-wrapper.full-width {
    grid-template-columns: 1fr;
}

.main-content {
    min-width: 0;
}

/* ----------------------------------------
   Sidebar (Generic)
---------------------------------------- */
.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.sidebar-widget {
    background-color: var(--color-gray);
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-lg);
}

.sidebar-widget h4 {
    font-size: 1.125rem;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid var(--color-primary);
}

/* ========================================
   Single Conference — Layout
======================================== */
.sc-section {
    padding-top: var(--spacing-2xl);
    padding-bottom: var(--spacing-3xl);
}

.sc-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: var(--spacing-2xl);
    align-items: start;
}

.sc-main {
    min-width: 0;
}

/* Mobile details — hidden on desktop, shown on mobile */
.sc-details-mobile {
    display: none;
    margin-bottom: var(--spacing-lg);
}

/* ========================================
   Page Header — Conference Meta
======================================== */
.sc-header-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 20px;
    margin-top: var(--spacing-sm);
}

.sc-header-meta__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.sc-header-meta__item i {
    font-size: 0.8rem;
    opacity: 0.7;
}

/* ========================================
   Status Badge — All Pages
======================================== */
.sc-status {
    display: inline-block;
    padding: 3px 14px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    line-height: 1.6;
}

.sc-status--upcoming {
    background: rgba(16, 185, 129, 0.15);
    color: #059669;
}

.sc-status--ongoing {
    background: rgba(59, 130, 246, 0.15);
    color: #2563eb;
}

.sc-status--completed {
    background: rgba(107, 114, 128, 0.12);
    color: #6b7280;
}

.sc-status--cancelled {
    background: rgba(239, 68, 68, 0.12);
    color: #dc2626;
}

/* In header, make badge lighter */
.sc-header-meta .sc-status {
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
}

/* ========================================
   Featured Image
======================================== */
.sc-featured-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: var(--spacing-lg);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.sc-featured-image img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}

/* ========================================
   Content Body — Typography
======================================== */
.sc-body {
    line-height: 1.8;
    color: var(--color-text);
    font-size: 1rem;
}

.sc-body h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 2rem 0 0.75rem;
    color: var(--color-black);
    padding-bottom: 0.5rem;
    border-bottom: 2px solid rgba(30, 58, 138, 0.1);
}

.sc-body h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin: 1.75rem 0 0.6rem;
    color: var(--color-black);
}

.sc-body h4 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 1.5rem 0 0.5rem;
    color: var(--color-black);
}

.sc-body p {
    margin-bottom: 1rem;
}

.sc-body ul,
.sc-body ol {
    margin: 0.5rem 0 1.25rem 1.5rem;
}

.sc-body li {
    margin-bottom: 0.4rem;
}

.sc-body strong {
    color: var(--color-black);
}

.sc-body a {
    color: var(--color-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.sc-body a:hover {
    color: var(--color-primary-dark);
}

.sc-body blockquote {
    border-left: 4px solid var(--color-primary);
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
    background: var(--color-gray);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-style: italic;
    color: var(--color-text-light);
}

/* ========================================
   Sidebar — Card
======================================== */
.sc-sidebar {
    position: sticky;
    top: 100px;
    align-self: start;
    height: fit-content;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.sc-card {
    background: var(--color-white);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: var(--radius-lg);
    padding: 0;
    margin-bottom: var(--spacing-lg);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.sc-card__heading {
    font-size: 1rem;
    font-weight: 700;
    padding: 18px 22px;
    margin: 0;
    background: var(--color-primary);
    color: #fff;
    letter-spacing: 0.2px;
}

/* ========================================
   Details List
======================================== */
.sc-details {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sc-details__item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 22px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.sc-details__item:last-child {
    border-bottom: none;
}

.sc-details__icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(30, 58, 138, 0.08);
    color: var(--color-primary);
    border-radius: 8px;
    font-size: 0.85rem;
    margin-top: 2px;
}

.sc-details__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.sc-details__label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 600;
    color: var(--color-text-light);
}

.sc-details__value {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--color-black);
    word-break: break-word;
}

/* ========================================
   Register Button (sidebar / mobile)
======================================== */
.sc-card__action {
    padding: 16px 22px 20px;
}

.sc-card__action .btn-block {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius-md);
}

/* ========================================
   Share Section (full-width, after content)
======================================== */
.sc-share-section {
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-xl);
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.sc-share-section__heading {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 14px;
    color: var(--color-black);
}

.sc-share {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.sc-share__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--radius-full);
    color: #fff;
    font-size: 0.9rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sc-share__btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #fff;
}

.sc-share__btn--fb { background: #1877f2; }
.sc-share__btn--tw { background: #1da1f2; }
.sc-share__btn--li { background: #0a66c2; }
.sc-share__btn--wa { background: #25d366; }
.sc-share__btn--em { background: var(--color-primary); }

/* ========================================
   Related Conferences — List View
======================================== */
.sc-related {
    margin-top: var(--spacing-2xl);
    padding-top: var(--spacing-2xl);
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.sc-related__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-lg);
}

.sc-related__header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 0;
    color: var(--color-black);
}

.sc-related__view-all {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-primary);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: gap 0.2s ease;
}

.sc-related__view-all:hover {
    gap: 9px;
    color: var(--color-primary-dark);
}

.sc-related__list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}
@media (max-width: 768px) {
    .sc-related__list {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Responsive — Tablet (≤ 1024px)
======================================== */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: relative;
        top: 0;
    }

    /* Single conference: stack to 1 column */
    .sc-layout {
        grid-template-columns: 1fr;
    }

    /* Hide desktop sidebar, show inline mobile details */
    .sc-sidebar {
        display: none;
    }

    .sc-details-mobile {
        display: block;
    }
}


/* ========================================
   Responsive — Mobile (≤ 768px)
======================================== */
@media (max-width: 768px) {
    .sc-section {
        padding-top: var(--spacing-lg);
        padding-bottom: var(--spacing-2xl);
    }

    .sc-featured-image {
        border-radius: var(--radius-md);
        margin-bottom: var(--spacing-md);
    }

    .sc-body h2 {
        font-size: 1.3rem;
    }

    .sc-body h3 {
        font-size: 1.1rem;
    }

    .sc-share-section {
        margin-top: var(--spacing-lg);
        padding-top: var(--spacing-lg);
    }

    .sc-related {
        margin-top: var(--spacing-xl);
        padding-top: var(--spacing-xl);
    }

    .sc-related__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .sc-related__header h2 {
        font-size: 1.2rem;
    }

}

