/**
 * XPEL Korea Single Post Styles
 * Narrow centered content for optimal reading experience
 */

/* ==========================================================================
   Post Header
   ========================================================================== */
.single-post {
    background-color: #FFFFFF;
}

.post-header {
    padding: calc(80px + 3rem) 1.5rem 3rem;
    background-color: #FFFFFF;
    text-align: center;
}

.post-header__inner {
    max-width: 800px;
    margin: 0 auto;
}

/* Breadcrumbs */
.post-breadcrumbs {
    font-size: 0.875rem;
    color: #737373;
    margin-bottom: 2rem;
}

.post-breadcrumbs a {
    color: #525252;
    text-decoration: none;
    transition: color 0.2s ease;
}

.post-breadcrumbs a:hover {
    color: #FDB521;
}

.post-breadcrumbs .separator {
    margin: 0 0.5rem;
    color: #A3A3A3;
}

/* Title */
.post-header__title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: #000000;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

/* Meta */
.post-header__meta {
    font-size: 0.875rem;
    color: #737373;
}

.post-header__date {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* ==========================================================================
   Hero Image (Full Width)
   ========================================================================== */
.post-hero {
    max-width: 1000px;
    margin: 0 auto 3rem;
    padding: 0 1.5rem;
    background-color: #FFFFFF;
}

.post-hero__image {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.post-hero__image img {
    width: 100%;
    height: auto;
    display: block;
}

/* ==========================================================================
   Post Content (Narrow Column)
   ========================================================================== */
.post-content {
    padding: 0 1.5rem 4rem;
    background-color: #FFFFFF;
}

.post-content__inner {
    max-width: 700px;
    margin: 0 auto;
}

/* Typography */
.post-content__inner p {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #404040;
    margin-bottom: 1.5rem;
}

.post-content__inner h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #000000;
    margin: 3rem 0 1.5rem;
    line-height: 1.3;
}

.post-content__inner h3 {
    font-size: 1.375rem;
    font-weight: 600;
    color: #000000;
    margin: 2.5rem 0 1rem;
    line-height: 1.4;
}

.post-content__inner h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #000000;
    margin: 2rem 0 1rem;
}

/* Links */
.post-content__inner a {
    color: #FDB521;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.post-content__inner a:hover {
    color: #000000;
}

/* Lists */
.post-content__inner ul,
.post-content__inner ol {
    margin: 0 0 1.5rem 1.5rem;
    font-size: 1.125rem;
    line-height: 1.8;
    color: #404040;
}

.post-content__inner li {
    margin-bottom: 0.5rem;
}

/* ==========================================================================
   Pull Quotes / Blockquotes
   ========================================================================== */
.post-content__inner blockquote {
    position: relative;
    margin: 3rem 0;
    padding: 2rem 0 2rem 2rem;
    border-left: 4px solid #FDB521;
    background: transparent;
}

.post-content__inner blockquote p {
    font-size: 1.375rem;
    font-weight: 500;
    font-style: italic;
    color: #000000;
    line-height: 1.6;
    margin: 0;
}

.post-content__inner blockquote p:last-child {
    margin-bottom: 0;
}

.post-content__inner blockquote cite {
    display: block;
    margin-top: 1rem;
    font-size: 0.875rem;
    font-style: normal;
    color: #737373;
}

/* Large Pull Quote (add class .wp-block-quote.is-style-large in Gutenberg) */
.post-content__inner .wp-block-quote.is-style-large,
.post-content__inner .pull-quote {
    margin: 4rem -2rem;
    padding: 2.5rem;
    border-left: none;
    border-top: 3px solid #FDB521;
    border-bottom: 3px solid #FDB521;
    text-align: center;
}

.post-content__inner .wp-block-quote.is-style-large p,
.post-content__inner .pull-quote p {
    font-size: 1.5rem;
    font-style: normal;
}

/* ==========================================================================
   Images in Content
   ========================================================================== */
.post-content__inner img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 2rem 0;
}

/* Full width images - break out of narrow column */
.post-content__inner .alignfull,
.post-content__inner .wp-block-image.is-style-full {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    max-width: 100vw;
    width: 100vw;
}

.post-content__inner .alignfull img {
    border-radius: 0;
    width: 100%;
}

/* Wide images */
.post-content__inner .alignwide {
    margin-left: -100px;
    margin-right: -100px;
    max-width: calc(100% + 200px);
}

@media (max-width: 900px) {
    .post-content__inner .alignwide {
        margin-left: 0;
        margin-right: 0;
        max-width: 100%;
    }
}

/* Image captions */
.post-content__inner figcaption,
.post-content__inner .wp-caption-text {
    font-size: 0.875rem;
    color: #737373;
    text-align: center;
    margin-top: 0.75rem;
}

/* ==========================================================================
   Image Gallery
   ========================================================================== */
.post-content__inner .wp-block-gallery {
    margin: 3rem 0;
}

.post-content__inner .wp-block-gallery.columns-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.post-content__inner .wp-block-gallery.columns-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.post-content__inner .wp-block-gallery.columns-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
}

@media (max-width: 768px) {
    .post-content__inner .wp-block-gallery.columns-3,
    .post-content__inner .wp-block-gallery.columns-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

.post-content__inner .wp-block-gallery figure {
    margin: 0;
}

.post-content__inner .wp-block-gallery img {
    margin: 0;
    border-radius: 8px;
}

/* ==========================================================================
   Video Embeds
   ========================================================================== */
.post-content__inner .wp-block-embed,
.post-content__inner iframe {
    margin: 2.5rem 0;
}

.post-content__inner .wp-block-embed-youtube,
.post-content__inner .wp-block-embed-vimeo {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 8px;
}

.post-content__inner .wp-block-embed-youtube iframe,
.post-content__inner .wp-block-embed-vimeo iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    margin: 0;
}

/* ==========================================================================
   Related Posts
   ========================================================================== */
.post-related {
    padding: 4rem 1.5rem;
    background-color: #171717;
}

.post-related__inner {
    max-width: 1200px;
    margin: 0 auto;
}

.post-related__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.post-related__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFFFFF;
}

.post-related__view-all {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 9999px;
    transition: all 0.2s ease;
}

.post-related__view-all:hover {
    color: #FFFFFF;
    border-color: #FFFFFF;
}

/* Related Posts Grid */
.post-related__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

@media (max-width: 992px) {
    .post-related__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .post-related__grid {
        grid-template-columns: 1fr;
    }
}

/* Related Card */
.related-card {
    background: #262626;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.related-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.related-card a {
    text-decoration: none;
    color: inherit;
}

.related-card__image {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.related-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-card:hover .related-card__image img {
    transform: scale(1.05);
}

.related-card__placeholder {
    width: 100%;
    height: 100%;
    background: #404040;
}

.related-card__category {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.25rem 0.625rem;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    background-color: #FDB521;
    color: #000000;
    border-radius: 4px;
}

.related-card__content {
    padding: 1rem;
}

.related-card__title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #FFFFFF;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ==========================================================================
   Bottom CTAs
   ========================================================================== */
.post-ctas {
    padding: 4rem 1.5rem;
    background-color: #000000;
}

.post-ctas__inner {
    max-width: 1200px;
    margin: 0 auto;
}

.post-ctas__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

@media (max-width: 768px) {
    .post-ctas__grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.post-cta {
    text-align: center;
    padding: 1.5rem;
}

.post-cta__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    color: #FDB521;
}

.post-cta__title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 0.5rem;
}

.post-cta__text {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.post-cta__link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #FDB521;
    text-decoration: none;
}

.post-cta__link:hover {
    text-decoration: underline;
}

/* ==========================================================================
   Share Buttons (Optional - Add if needed)
   ========================================================================== */
.post-share {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem 0;
    border-top: 1px solid #E5E5E5;
    margin-top: 3rem;
}

.post-share__label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #737373;
}

.post-share__buttons {
    display: flex;
    gap: 0.5rem;
}

.post-share__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #F5F5F5;
    color: #525252;
    transition: all 0.2s ease;
}

.post-share__btn:hover {
    background: #000000;
    color: #FFFFFF;
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
    .post-header {
        padding: calc(80px + 2rem) 1rem 2rem;
    }
    
    .post-header__title {
        font-size: 1.75rem;
    }
    
    .post-hero {
        padding: 0 1rem;
        margin-bottom: 2rem;
    }
    
    .post-content {
        padding: 0 1rem 3rem;
    }
    
    .post-content__inner p {
        font-size: 1rem;
    }
    
    .post-content__inner blockquote {
        margin: 2rem 0;
        padding: 1.5rem 0 1.5rem 1.5rem;
    }
    
    .post-content__inner blockquote p {
        font-size: 1.125rem;
    }
    
    .post-related {
        padding: 3rem 1rem;
    }
    
    .post-related__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .post-ctas {
        padding: 3rem 1rem;
    }
}
