/* Content-to-footer spacing and footer size overrides */

/* Ensure page scrolls on all viewports (fix tablet/landscape content not visible) */
html {
    overflow-y: auto;
    overflow-x: hidden;
}

/* Headings use primary dynamic color (theme customizer) */
h1, h2, h3, h4 {
    color: var(--vd-color-primary);
}

/* Tablet and short viewports: prevent hero/parallax from filling viewport so content is visible */
@media (max-height: 700px), (min-width: 768px) and (max-width: 1024px) {
    section.hero.parallax {
        min-height: 0 !important;
        height: auto !important;
    }
}

/* Center nav links between logo and theme button (desktop only) */
@media (min-width: 768px) {
    .vd-navbar-container {
        display: flex !important;
        align-items: center !important;
        position: relative !important;
    }

    .vd-navbar-menu {
        flex: 1 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
    }

    .vd-navbar-nav {
        position: absolute !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
    }
}

/* Sticky footer: main content grows so footer always sits at bottom */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

#main-content {
    flex: 1 0 auto;
    margin-bottom: 5rem;
}

/* Shrink footer height and fonts (~50% reduction) */
.vd-footer {
    padding-top: 0.75rem;
    padding-bottom: 0.5rem;
}

.vd-footer-container {
    padding-top: 0;
    padding-bottom: 0;
}

.vd-footer .vd-footer-section h4 {
    font-size: 0.8rem;
    margin-bottom: 0.2rem;
    font-weight: 600;
}

.vd-footer .vd-footer-section p,
.vd-footer .vd-footer-links,
.vd-footer .vd-footer-links a {
    font-size: 0.7rem;
    line-height: 1.3;
}

.vd-footer .vd-footer-links li {
    margin-bottom: 0;
    padding: 0;
}

.vd-footer .vd-footer-section {
    margin-bottom: 0.25rem;
}

.vd-footer .vd-footer-section:last-child {
    margin-bottom: 0;
}

.vd-footer .vd-row {
    margin-bottom: 0.25rem;
}

.vd-footer-bottom {
    padding-top: 0.35rem;
    padding-bottom: 0.25rem;
}

.vd-footer-bottom p {
    font-size: 0.7rem;
    margin: 0;
}

/* Article / long-form content (blog and random full posts) */
.article-header {
    padding-top: 100px;
    padding-bottom: 2rem;
}

.article-hero-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: var(--vd-btn-border-radius);
    margin-bottom: 2rem;
}

.article-meta {
    display: flex;
    gap: 1.5rem;
    font-size: var(--vd-font-size-sm);
    color: var(--vd-text-muted);
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.article-content {
    max-width: 65ch;
    margin: 0 auto;
    font-size: 1.2rem;
    line-height: 1.75;
}

.article-content h2 {
    margin-top: 3.5rem;
    margin-bottom: 1rem;
    color: var(--vd-color-primary);
}

.article-content h3 {
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}

.article-content p {
    margin-bottom: 1.75rem;
}

.article-content blockquote {
    border-left: 4px solid var(--vd-color-primary);
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: var(--vd-text-muted);
}

.article-content blockquote p {
    margin-bottom: 1rem;
}

.article-content blockquote p:last-child {
    margin-bottom: 0;
}

.article-content hr {
    margin: 3rem 0;
    border: none;
    border-top: 1px solid var(--vd-border-color);
}

.article-content a {
    color: var(--vd-color-primary);
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.75rem;
    padding-left: 1.5rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--vd-text-muted);
    text-decoration: none;
    margin-bottom: 2rem;
}

.back-link:hover {
    color: var(--vd-color-primary);
}

/* Video Link Card Styles */
.video-link {
    display: block;
    position: relative;
    width: 100%;
    border-radius: var(--vd-btn-border-radius);
    overflow: hidden;
    margin: 2rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    text-decoration: none;
}

.video-link:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

.video-link img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

.video-link:hover img {
    transform: scale(1.05);
}

.video-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
    transition: background 0.2s ease;
    z-index: 1;
}

.video-link:hover .video-play-overlay {
    background: rgba(0, 0, 0, 0.2);
}

.video-play-icon {
    font-size: 5rem;
    color: var(--vd-color-white);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
    transition: transform 0.2s ease;
}

.video-link:hover .video-play-icon {
    transform: scale(1.1);
    color: var(--vd-color-primary);
}