/* ========================================
   NBC Constitution Elementor Widget Styles
   Based on PHP Template Design
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --nbc-primary: #1a365d;
    --nbc-primary-light: #2c5282;
    --nbc-accent: #c53030;
    --nbc-accent-light: #e53e3e;
    --nbc-gold: #b7791f;
    --nbc-gold-light: #d69e2e;
    --nbc-text: #2d3748;
    --nbc-text-light: #4a5568;
    --nbc-bg: #f7fafc;
    --nbc-bg-white: #ffffff;
    --nbc-border: #e2e8f0;
    --nbc-shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --nbc-shadow-lg: 0 10px 30px rgba(0,0,0,0.12);
    --nbc-radius-sm: 6px;
    --nbc-radius-md: 12px;
    --nbc-radius-lg: 20px;
}

/* -- Breadcrumb Widget -- */
.nbc-breadcrumb-wrap {
    background: linear-gradient(135deg, var(--nbc-primary) 0%, var(--nbc-primary-light) 100%);
    padding: 16px 0;
}
.nbc-breadcrumb {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.875rem;
    font-family: 'Inter', sans-serif;
}
.nbc-breadcrumb a { color: rgba(255,255,255,0.75); text-decoration: none; font-weight: 500; }
.nbc-breadcrumb a:hover { color: #fff; }
.nbc-sep { color: rgba(255,255,255,0.4); font-size: 0.75rem; }
.nbc-current { color: #fff; font-weight: 600; }

/* -- Hero Widget -- */
.nbc-hero {
    background: linear-gradient(135deg, var(--nbc-primary) 0%, #0d1b2a 100%);
    padding: 80px 24px 100px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.nbc-hero::after {
    content: '';
    position: absolute;
    bottom: -50px;
    left: 0; right: 0;
    height: 100px;
    background: var(--nbc-bg);
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
}
.nbc-hero-content { max-width: 800px; margin: 0 auto; position: relative; z-index: 1; }
.nbc-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.1);
    padding: 8px 20px;
    border-radius: 50px;
    color: var(--nbc-gold-light);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 24px;
    border: 1px solid rgba(255,255,255,0.1);
    font-family: 'Inter', sans-serif;
}
.nbc-hero-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
    margin-bottom: 16px;
}
.nbc-hero-title span { color: var(--nbc-gold-light); }
.nbc-hero-subtitle {
    color: rgba(255,255,255,0.7);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 300;
    font-family: 'Inter', sans-serif;
}
.nbc-hero-divider {
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--nbc-gold), var(--nbc-gold-light));
    margin: 24px auto 0;
    border-radius: 3px;
}

/* -- TOC Widget -- */
.nbc-toc-card {
    background: var(--nbc-bg-white);
    border-radius: var(--nbc-radius-lg);
    box-shadow: var(--nbc-shadow-lg);
    padding: 40px;
    margin-bottom: 40px;
    border: 1px solid var(--nbc-border);
    font-family: 'Inter', sans-serif;
}
.nbc-toc-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--nbc-border);
}
.nbc-toc-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--nbc-primary), var(--nbc-primary-light));
    border-radius: var(--nbc-radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.25rem;
}
.nbc-toc-header h2 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--nbc-primary);
    margin: 0;
}
.nbc-toc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
}
.nbc-toc-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--nbc-radius-sm);
    text-decoration: none;
    color: var(--nbc-text);
    transition: all 0.3s ease;
    border: 1px solid transparent;
    cursor: pointer;
}
.nbc-toc-item:hover {
    background: #edf2f7;
    border-color: var(--nbc-border);
    transform: translateX(4px);
}
.nbc-toc-num {
    width: 32px;
    height: 32px;
    background: var(--nbc-primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}
.nbc-toc-text { font-size: 0.9rem; font-weight: 500; }

/* -- Article Widget -- */
.nbc-article-card {
    background: var(--nbc-bg-white);
    border-radius: var(--nbc-radius-lg);
    box-shadow: var(--nbc-shadow-md);
    margin-bottom: 32px;
    overflow: hidden;
    border: 1px solid var(--nbc-border);
    transition: box-shadow 0.3s ease;
    scroll-margin-top: 20px;
    font-family: 'Inter', sans-serif;
}
.nbc-article-card:hover { box-shadow: var(--nbc-shadow-lg); }
.nbc-article-header {
    background: linear-gradient(135deg, var(--nbc-primary) 0%, var(--nbc-primary-light) 100%);
    padding: 28px 40px;
    position: relative;
}
.nbc-article-header h2 {
    font-family: 'Playfair Display', serif;
    color: #fff;
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
}
.nbc-article-label {
    display: inline-block;
    background: var(--nbc-gold);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 4px 12px;
    border-radius: 50px;
    margin-bottom: 8px;
}
.nbc-article-body { padding: 32px 40px; }
.nbc-article-body h3 {
    font-family: 'Playfair Display', serif;
    color: var(--nbc-primary);
    font-size: 1.15rem;
    margin: 24px 0 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--nbc-border);
}
.nbc-article-body h3:first-child { margin-top: 0; }
.nbc-article-body p {
    margin-bottom: 16px;
    color: var(--nbc-text-light);
    text-align: justify;
}
.nbc-article-body ol, .nbc-article-body ul {
    margin: 12px 0 16px 24px;
    color: var(--nbc-text-light);
}
.nbc-article-body li { margin-bottom: 8px; }

/* -- Vision/Mission Boxes -- */
.nbc-vision-box {
    border-left: 4px solid;
    padding: 24px;
    border-radius: 0 var(--nbc-radius-sm) var(--nbc-radius-sm) 0;
    margin: 20px 0;
}
.nbc-vision-primary {
    background: linear-gradient(135deg, #ebf8ff 0%, #bee3f8 100%);
    border-left-color: var(--nbc-primary-light);
}
.nbc-vision-primary h4 {
    color: var(--nbc-primary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}
.nbc-vision-primary p {
    margin: 0;
    color: var(--nbc-primary-light);
    font-weight: 500;
    font-size: 1.05rem;
}
.nbc-vision-mission {
    background: linear-gradient(135deg, #f0fff4 0%, #c6f6d5 100%);
    border-left-color: #38a169;
}
.nbc-vision-mission h4 {
    color: #276749;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}
.nbc-vision-mission p {
    margin: 0;
    color: #276749;
    font-weight: 500;
    font-size: 1.05rem;
}

/* -- Principle Items -- */
.nbc-principle-item {
    background: #f8fafc;
    border-radius: var(--nbc-radius-sm);
    padding: 20px 24px;
    margin: 12px 0;
    border: 1px solid var(--nbc-border);
}
.nbc-principle-item strong {
    color: var(--nbc-primary);
    display: block;
    margin-bottom: 6px;
}

/* -- Duty List -- */
.nbc-duty-list {
    list-style: none;
    margin-left: 0 !important;
    padding: 0;
}
.nbc-duty-list li {
    padding: 10px 0 10px 32px;
    position: relative;
    border-bottom: 1px dashed var(--nbc-border);
}
.nbc-duty-list li:last-child { border-bottom: none; }
.nbc-duty-list li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: var(--nbc-accent);
    font-weight: 700;
}

/* -- Regulation Header -- */
.nbc-regulation-header {
    background: linear-gradient(135deg, var(--nbc-accent) 0%, var(--nbc-accent-light) 100%) !important;
}
.nbc-regulation-header h2 { color: #fff; }

/* -- Back to Top Link -- */
.nbc-back-to-top {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--nbc-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    margin-top: 20px;
    transition: color 0.3s ease;
    cursor: pointer;
}
.nbc-back-to-top:hover { color: var(--nbc-gold); }

/* -- Signatures Widget -- */
.nbc-signature-card {
    background: linear-gradient(135deg, var(--nbc-primary) 0%, #0d1b2a 100%);
    color: #fff;
    padding: 40px;
    border-radius: var(--nbc-radius-lg);
    margin-top: 40px;
    text-align: center;
    font-family: 'Inter', sans-serif;
}
.nbc-signature-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--nbc-gold-light);
}
.nbc-signatures {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    text-align: left;
}
.nbc-sig-item {
    background: rgba(255,255,255,0.05);
    padding: 16px;
    border-radius: var(--nbc-radius-sm);
    border: 1px solid rgba(255,255,255,0.1);
}
.nbc-sig-name { font-weight: 600; color: #fff; font-size: 0.9rem; }
.nbc-sig-role { font-size: 0.8rem; color: rgba(255,255,255,0.6); margin-top: 4px; }
.nbc-attendance { margin-top: 24px; color: rgba(255,255,255,0.5); font-size: 0.85rem; }

/* -- Scroll Top Button Widget -- */
.nbc-scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--nbc-primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: var(--nbc-shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 9999;
}
.nbc-scroll-top.visible { opacity: 1; visibility: visible; }
.nbc-scroll-top:hover { background: var(--nbc-gold); transform: translateY(-3px); }

/* -- Container -- */
.nbc-container {
    max-width: 1100px;
    margin: -40px auto 80px;
    padding: 0 24px;
    position: relative;
    z-index: 2;
}

/* -- Responsive -- */
@media (max-width: 768px) {
    .nbc-hero { padding: 60px 20px 80px; }
    .nbc-toc-card, .nbc-article-body { padding: 24px; }
    .nbc-article-header { padding: 20px 24px; }
    .nbc-signatures { grid-template-columns: 1fr; }
    .nbc-scroll-top {
        width: 44px;
        height: 44px;
        bottom: 20px;
        right: 20px;
    }
}

/* -- Print -- */
@media print {
    .nbc-scroll-top, .nbc-breadcrumb-wrap { display: none !important; }
    .nbc-article-card { break-inside: avoid; box-shadow: none; border: 1px solid #ddd; }
}

/* -- Elementor Editor Fixes -- */
.elementor-editor-active .nbc-scroll-top {
    position: relative;
    bottom: auto;
    right: auto;
    margin: 20px auto;
    opacity: 1;
    visibility: visible;
}
