/* ==========================================================================
   🏛️ LEGACY MEDIA DESIGN - NYT / The Atlantic Style
   Expert Newspaper & Magazine CSS Architecture
   ========================================================================== */

/* ============================================
   HEADER ARCHITECTURE - Centered & Authoritative
   ============================================ */

/* Center the entire header block */
.article-main-box>header,
header.mb-4 {
    text-align: center !important;
    max-width: 800px;
    margin: 0 auto 40px auto !important;
    padding: 0 20px 30px 20px !important;
    border-bottom: 1px solid #d0d0d0 !important;
    /* Separator line */
}

/* Category Badge - Centered */
.article-main-box header .badge,
header .badge {
    display: inline-block !important;
    margin: 0 auto 15px auto !important;
}

/* Main Headline (H1) - Centered & Tight */
.article-title-pro,
h1.article-title-pro {
    font-family: 'Playfair Display', serif !important;
    font-size: 3.5rem !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    color: #000 !important;
    text-align: center !important;
    margin: 0 auto 20px auto !important;
    padding: 0 !important;
    letter-spacing: -0.5px !important;
    max-width: 100%;
}

/* Subtitle (H2) - Centered */
header .h3,
.h3.text-muted {
    font-family: 'Georgia', serif !important;
    font-size: 1.4rem !important;
    font-weight: 400 !important;
    font-style: italic !important;
    color: #666 !important;
    text-align: center !important;
    line-height: 1.5 !important;
    margin: 0 auto !important;
    padding: 0 !important;
    border: none !important;
}

/* ============================================
   THE DROP CAP - CRITICAL FIX (No More Floating!)
   ============================================ */

.article-body>p:first-of-type::first-letter,
#article-content-body>p:first-of-type::first-letter,
.article-content>p:first-of-type::first-letter {
    float: left !important;
    font-family: 'Playfair Display', serif !important;
    font-size: 5.5rem !important;
    line-height: 0.75 !important;
    /* SECRET: This stops the floating! */
    font-weight: 700 !important;
    color: #000 !important;
    margin-right: 12px !important;
    margin-top: 5px !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
}

/* ============================================
   BODY TYPOGRAPHY - Luxurious Readability
   ============================================ */

.article-body,
#article-content-body {
    font-family: 'Georgia', serif !important;
    font-size: 1.2rem !important;
    line-height: 1.8 !important;
    /* Luxurious air between lines */
    color: #222 !important;
    /* High-contrast dark grey */
    max-width: 720px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
}

.article-body p,
#article-content-body p {
    margin-bottom: 1.6rem !important;
    text-align: left !important;
}

/* ============================================
   SIDEBAR - INTELLIGENT STICKY (Professional Behavior)
   ============================================ */

/* Main sidebar container - Keep white background with subtle separator */
.col-lg-4,
.sidebar-container {
    background-color: #ffffff !important;
    /* WHITE background - restored! */
    border-left: 1px solid #e0e0e0 !important;
    /* Subtle separator line */
    padding: 30px 20px !important;
}

/* Sticky wrapper - Simple sticky behavior, NO overflow restriction */
.sticky-top {
    position: sticky !important;
    top: 120px !important;
    align-self: flex-start !important;
    max-height: none !important;
    /* Allow full content */
    overflow: visible !important;
    /* Show all content */
}

/* Recent Posts section - can be tall, no scrolling needed */
.sticky-top>div:not(.newsletter-widget) {
    margin-bottom: 20px;
}

/* SUBSCRIPTION WIDGET - Must be visible */
.newsletter-widget {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    z-index: 100 !important;
    background: #e9ecef !important;
    /* Light grey background */
    padding: 30px 25px !important;
    margin-top: 30px !important;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 4px !important;
}

/* Newsletter icon circle */
.newsletter-widget .icon-circle {
    width: 50px !important;
    height: 50px !important;
    background-color: #0c2444 !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 auto !important;
}

/* Newsletter heading */
.newsletter-widget h4 {
    color: #000 !important;
    font-family: 'Georgia', serif !important;
    visibility: visible !important;
}

/* Newsletter description */
.newsletter-widget p {
    color: #666 !important;
    visibility: visible !important;
}

/* Newsletter input */
.newsletter-widget input {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    background: #fff !important;
    color: #000 !important;
    border: 1px solid #ddd !important;
}

/* Newsletter button */
.newsletter-widget button,
.newsletter-widget .btn-warning {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    background-color: #ffc107 !important;
    border: none !important;
    color: #0c2444 !important;
    font-weight: 700 !important;
}

/* Remove any height restrictions */
.col-lg-4,
.sidebar-container {
    min-height: auto !important;
    height: auto !important;
}

/* Prevent sidebar from overlapping footer */
.sticky-top {
    margin-bottom: 60px !important;
    /* Space before footer */
}

/* Stop sticky behavior near footer */
footer,
.footer {
    position: relative;
    z-index: 100 !important;
    /* Ensure footer is above sticky sidebar */
}

/* Remove excess empty space from sidebar widgets */
.newsletter-widget,
.card,
.sidebar-widget {
    background: #ffffff !important;
    /* White cards on grey background */
    margin-bottom: 20px !important;
    min-height: auto !important;
    height: auto !important;
    padding: 25px !important;
    border: 1px solid #e0e0e0 !important;
    border-radius: 4px !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
}

/* Newsletter widget specific styling */
.newsletter-widget {
    padding: 30px 25px !important;
}

/* Limit recent posts list if too long */
.sidebar-widget ul,
.recent-posts-list {
    max-height: 600px !important;
    /* Limit list height */
    overflow-y: auto !important;
    padding-right: 5px !important;
}

/* Recent posts item spacing */
.sidebar-widget li,
.recent-posts-item {
    margin-bottom: 15px !important;
    padding-bottom: 15px !important;
    border-bottom: 1px solid #f0f0f0 !important;
}

.sidebar-widget li:last-child,
.recent-posts-item:last-child {
    border-bottom: none !important;
}

/* Sidebar headings */
.sidebar-widget h4,
.sidebar-widget h5 {
    font-family: 'Georgia', serif !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    color: #000 !important;
    margin-bottom: 20px !important;
    padding-bottom: 10px !important;
    border-bottom: 2px solid #000 !important;
}

/* ============================================
   META BAR - Centered & Clean
   ============================================ */

.meta-bar {
    max-width: 720px !important;
    margin: 0 auto 40px auto !important;
    padding: 20px !important;
    border-top: 1px solid #e0e0e0 !important;
    border-bottom: 1px solid #e0e0e0 !important;
}

/* ============================================
   FEATURED IMAGE - Centered
   ============================================ */

.article-main-box .text-center {
    max-width: 720px !important;
    margin: 0 auto 30px auto !important;
}

.article-main-box .text-center img {
    width: 100% !important;
    height: auto !important;
    border-radius: 2px !important;
}

/* ============================================
   HEADINGS - Classic Newspaper Style
   ============================================ */

.article-body h2,
#article-content-body h2 {
    font-family: 'Playfair Display', serif !important;
    font-size: 2rem !important;
    font-weight: 700 !important;
    color: #000 !important;
    margin-top: 2.5rem !important;
    margin-bottom: 1rem !important;
    line-height: 1.3 !important;
    border: none !important;
    background: none !important;
    padding: 0 !important;
}

.article-body h3,
#article-content-body h3 {
    font-family: 'Georgia', serif !important;
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    color: #222 !important;
    margin-top: 2rem !important;
    margin-bottom: 0.8rem !important;
    border: none !important;
    padding: 0 !important;
}

/* ============================================
   BLOCKQUOTES - Classic Pull Quote
   ============================================ */

.article-body blockquote,
#article-content-body blockquote {
    font-family: 'Georgia', serif !important;
    font-size: 1.3rem !important;
    font-style: italic !important;
    color: #444 !important;
    line-height: 1.6 !important;
    margin: 2rem 0 !important;
    padding: 1.5rem 2rem !important;
    border-left: 4px solid #000 !important;
    background: #f9f9f9 !important;
    max-height: none !important;
    overflow: visible !important;
}

.article-body blockquote::before,
#article-content-body blockquote::before {
    display: none !important;
}

/* ============================================
   LINKS - Subtle Underline
   ============================================ */

.article-body a:not(.btn),
#article-content-body a:not(.btn) {
    color: #000 !important;
    text-decoration: underline !important;
    text-decoration-color: rgba(0, 0, 0, 0.3) !important;
    transition: all 0.2s ease !important;
}

.article-body a:not(.btn):hover,
#article-content-body a:not(.btn):hover {
    text-decoration-color: #000 !important;
    background: rgba(0, 0, 0, 0.05) !important;
}

/* ============================================
   BREADCRUMB - Centered
   ============================================ */

nav.mb-3,
nav[aria-label="breadcrumb"] {
    max-width: 720px !important;
    margin: 0 auto 20px auto !important;
    text-align: center !important;
}

.breadcrumb {
    justify-content: center !important;
}