/* ==========================================================================
   NIAITE BLOG PAGE STYLES (V1)
   Description: Unified styles for blog detail pages, replacing inline CSS.
   Prefix: .nd-b- (Niaite Design Blog)
   ========================================================================== */

/* --- Hero Section (overrides page-header for blog pages) --- */
.nd-b-hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: white;
    padding: var(--spacing-4xl) 0;
}

.nd-b-hero-inner {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.nd-b-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: var(--spacing-lg);
    backdrop-filter: blur(10px);
}

.nd-b-badge svg {
    width: 18px;
    height: 18px;
}

.nd-b-title {
    color: white;
    font-size: 3rem;
    margin-bottom: var(--spacing-lg);
}

.nd-b-breadcrumb {
    margin-top: var(--spacing-xl);
}

.nd-b-breadcrumb a {
    color: rgba(255, 255, 255, 0.8);
}

.nd-b-breadcrumb .nd-b-sep {
    color: rgba(255, 255, 255, 0.6);
}

.nd-b-breadcrumb .nd-b-current {
    color: white;
}

/* --- Category Label (listing page hero) --- */
.nd-b-category-label {
    font-size: var(--font-size-sm);
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* --- Article Layout --- */
.nd-b-article {
    max-width: 800px;
}

.nd-b-meta {
    margin-bottom: var(--spacing-2xl);
    color: var(--color-text-light);
    font-size: var(--font-size-sm);
}

.nd-b-featured-img {
    width: 100%;
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-2xl);
}

/* --- Article Content --- */
.nd-b-content {
    line-height: 1.8;
    font-size: var(--font-size-lg);
}

.nd-b-content h2 {
    font-size: 1.75rem;
    color: var(--color-primary);
    margin-top: 2rem;
}

.nd-b-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5rem;
}

.nd-b-content ul {
    list-style: disc;
    padding-left: var(--spacing-xl);
    margin-bottom: var(--spacing-lg);
}

/* --- Callout Box --- */
.nd-b-callout {
    background: rgba(41, 98, 255, 0.05);
    padding: 1.5rem;
    border-left: 4px solid var(--color-primary);
    margin: 2rem 0;
    border-radius: 0 0.5rem 0.5rem 0;
}

.nd-b-callout h4 {
    margin-bottom: 0.5rem;
    color: var(--color-primary-dark);
}

.nd-b-callout p {
    margin: 0;
    font-size: 0.95rem;
}

/* --- FAQ Section --- */
.nd-b-faq {
    margin-top: var(--spacing-3xl);
    padding: var(--spacing-xl);
    background: var(--color-bg-light);
    border-radius: var(--radius-lg);
    color: var(--color-text-primary);
}

.nd-b-faq > h2 {
    margin-bottom: var(--spacing-xl);
}

.nd-b-faq .faq-item {
    margin-bottom: var(--spacing-lg);
}

.nd-b-faq .faq-item h3 {
    font-size: var(--font-size-lg);
    margin-bottom: var(--spacing-sm);
    color: var(--color-primary);
}

.nd-b-faq .faq-item p {
    color: var(--color-text-primary);
}

/* --- Related Posts --- */
.nd-b-related {
    margin-top: var(--spacing-3xl);
}

.nd-b-related > h3 {
    margin-bottom: var(--spacing-xl);
}

.nd-b-related .grid {
    gap: var(--spacing-xl);
}

.nd-b-related .card__text {
    color: var(--color-text-primary);
}

/* --- Share Bar --- */
.nd-b-share {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: var(--spacing-2xl);
    padding: 0.75rem 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    font-size: var(--font-size-sm);
    color: var(--color-text-light);
}

.nd-b-share a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background: var(--color-bg-light);
    color: var(--color-text-primary);
    transition: background 0.2s, color 0.2s;
}

.nd-b-share a:hover {
    background: var(--color-primary);
    color: white;
}

/* --- Prev/Next Navigation --- */
.nd-b-prevnext {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    margin-top: var(--spacing-2xl);
    padding-top: var(--spacing-xl);
    border-top: 1px solid var(--color-border);
}

.nd-b-prevnext a {
    display: block;
    padding: 1rem;
    border-radius: var(--radius-md);
    background: var(--color-bg-light);
    text-decoration: none;
    transition: background 0.2s;
}

.nd-b-prevnext a:hover {
    background: rgba(41, 98, 255, 0.08);
}

.nd-b-prevnext .nd-b-pn-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-text-light);
    margin-bottom: 0.25rem;
}

.nd-b-prevnext .nd-b-pn-title {
    font-weight: 600;
    color: var(--color-primary);
    font-size: var(--font-size-sm);
}

.nd-b-prevnext a:last-child {
    text-align: right;
}

@media (max-width: 480px) {
    .nd-b-prevnext {
        grid-template-columns: 1fr;
    }
}

/* --- Newsletter Subscribe --- */
.nd-b-subscribe {
    margin-top: var(--spacing-3xl);
    padding: var(--spacing-2xl);
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    border-radius: var(--radius-lg);
    text-align: center;
    color: white;
}

.nd-b-subscribe h3 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.nd-b-subscribe p {
    color: rgba(255, 255, 255, 0.85);
    font-size: var(--font-size-sm);
    margin-bottom: var(--spacing-lg);
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.nd-b-subscribe form {
    display: flex;
    gap: 0.5rem;
    max-width: 440px;
    margin: 0 auto;
}

.nd-b-subscribe input[type="email"] {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-size: var(--font-size-sm);
    backdrop-filter: blur(4px);
}

.nd-b-subscribe input[type="email"]::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.nd-b-subscribe input[type="email"]:focus {
    outline: none;
    border-color: white;
    background: rgba(255, 255, 255, 0.25);
}

.nd-b-subscribe button {
    padding: 0.75rem 1.5rem;
    background: white;
    color: var(--color-primary);
    border: none;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: var(--font-size-sm);
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.2s;
}

.nd-b-subscribe button:hover {
    opacity: 0.9;
}

.nd-b-subscribe .nd-b-sub-note {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 0.75rem;
}

@media (max-width: 480px) {
    .nd-b-subscribe form {
        flex-direction: column;
    }
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .nd-b-title {
        font-size: 2rem;
    }
}
