/*
 * DC SEO Engine — Single Post Frontend Styles
 * Loaded only on single posts generated by the plugin.
 */

/* ── Reset / base ─────────────────────────────────────────────────────────── */
.dc-single-wrap {
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    padding: 0 20px 60px;
    box-sizing: border-box;
}

/* ── Post header ──────────────────────────────────────────────────────────── */
.dc-post-header {
    padding: 40px 0 28px;
}

.dc-breadcrumb {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 14px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-items: center;
}

.dc-breadcrumb a {
    color: #6b7280;
    text-decoration: none;
}

.dc-breadcrumb a:hover {
    color: #111827;
}

.dc-post-title {
    font-size: clamp(26px, 4vw, 40px);
    font-weight: 800;
    line-height: 1.2;
    color: #111827;
    margin: 0 0 16px;
    letter-spacing: -0.5px;
}

.dc-post-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #6b7280;
}

.dc-post-meta a {
    color: #2563eb;
    text-decoration: none;
}

.dc-dot {
    opacity: .4;
}

/* ── Featured image ───────────────────────────────────────────────────────── */
.dc-post-image-wrap {
    margin: 0 0 36px;
    border-radius: 12px;
    overflow: hidden;
    line-height: 0;
}

.dc-post-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px;
}

/* Placeholder banner (when no featured image) */
.dc-post-image-placeholder {
    line-height: 1;
}

.dc-placeholder-banner {
    background: linear-gradient(135deg, #111827 0%, #1e3a8a 50%, #111827 100%);
    min-height: 260px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
    border-radius: 12px;
    gap: 10px;
}

.dc-placeholder-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #f59e0b;
}

.dc-placeholder-kw {
    font-size: clamp(22px, 4vw, 36px);
    font-weight: 800;
    color: #fff;
    line-height: 1.2;
}

.dc-placeholder-site {
    font-size: 13px;
    color: rgba(255,255,255,.5);
}

/* ── Content area ─────────────────────────────────────────────────────────── */
.dc-post-content-wrap {
    max-width: 760px;
    margin: 0 auto;
}

.dc-post-content {
    font-size: 17px;
    line-height: 1.8;
    color: #1f2937;
    font-family: Georgia, 'Times New Roman', serif;
}

.dc-post-content h2 {
    font-size: clamp(20px, 3vw, 26px);
    font-weight: 700;
    color: #111827;
    margin: 44px 0 16px;
    line-height: 1.3;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    border-bottom: 2px solid #f3f4f6;
    padding-bottom: 10px;
}

.dc-post-content h3 {
    font-size: clamp(17px, 2.5vw, 21px);
    font-weight: 700;
    color: #111827;
    margin: 32px 0 12px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-post-content p {
    margin: 0 0 20px;
}

.dc-post-content ul,
.dc-post-content ol {
    margin: 0 0 20px 24px;
    padding: 0;
}

.dc-post-content li {
    margin-bottom: 8px;
}

.dc-post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 15px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    overflow-x: auto;
    display: block;
}

.dc-post-content thead th {
    background: #1e3a8a;
    color: #fff;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    white-space: nowrap;
}

.dc-post-content tbody td {
    padding: 10px 16px;
    border-bottom: 1px solid #e5e7eb;
    color: #374151;
    vertical-align: top;
}

.dc-post-content tbody tr:last-child td {
    border-bottom: none;
}

.dc-post-content tbody tr:nth-child(even) td {
    background: #f9fafb;
}

.dc-post-content a {
    color: #2563eb;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.dc-post-content a:hover {
    color: #1d4ed8;
}

.dc-post-content em {
    color: #6b7280;
    font-size: 14px;
}

.dc-post-content strong {
    color: #111827;
    font-weight: 700;
}

/* ── CTA box ──────────────────────────────────────────────────────────────── */
.dc-cta-box {
    margin: 48px 0 36px;
    background: linear-gradient(135deg, #1e3a8a, #1e40af);
    border-radius: 12px;
    overflow: hidden;
}

.dc-cta-inner {
    padding: 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.dc-cta-text strong {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-cta-text p {
    font-size: 14px;
    color: rgba(255,255,255,.8);
    margin: 0;
    line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-cta-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
}

.dc-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 22px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    transition: opacity .15s;
}

.dc-cta-btn:hover { opacity: .88; }

.dc-cta-btn-primary {
    background: #f59e0b;
    color: #111827;
}

.dc-cta-btn-secondary {
    background: rgba(255,255,255,.15);
    color: #fff;
    border: 1px solid rgba(255,255,255,.3);
}

/* ── Tags ─────────────────────────────────────────────────────────────────── */
.dc-post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 40px;
}

.dc-tag {
    padding: 4px 12px;
    background: #f3f4f6;
    border-radius: 999px;
    font-size: 12px;
    color: #374151;
    text-decoration: none;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-tag:hover { background: #e5e7eb; }

/* ── Related posts ────────────────────────────────────────────────────────── */
.dc-related {
    margin-top: 40px;
    padding-top: 32px;
    border-top: 2px solid #f3f4f6;
}

.dc-related-title {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.dc-related-card {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    text-decoration: none;
    transition: box-shadow .15s, transform .15s;
    display: block;
}

.dc-related-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,.1);
    transform: translateY(-2px);
}

.dc-related-img {
    width: 100%;
    height: 130px;
    object-fit: cover;
    display: block;
}

.dc-related-card-body {
    padding: 12px;
}

.dc-related-card-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #111827;
    line-height: 1.4;
    margin-bottom: 4px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.dc-related-date {
    font-size: 11px;
    color: #9ca3af;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* ── Page links (paginated posts) ─────────────────────────────────────────── */
.dc-page-links {
    margin: 24px 0;
    font-size: 14px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 680px) {
    .dc-single-wrap {
        padding: 0 16px 40px;
    }

    .dc-post-header {
        padding: 28px 0 20px;
    }

    .dc-cta-inner {
        flex-direction: column;
        padding: 24px;
    }

    .dc-cta-actions {
        width: 100%;
    }

    .dc-cta-btn {
        width: 100%;
        text-align: center;
    }

    .dc-related-grid {
        grid-template-columns: 1fr;
    }

    .dc-post-content table {
        font-size: 13px;
    }

    .dc-post-content thead th,
    .dc-post-content tbody td {
        padding: 8px 10px;
    }
}

@media (max-width: 480px) {
    .dc-related-grid {
        grid-template-columns: 1fr 1fr;
    }
}
