/*
Theme Name: CineReview
Theme URI: https://cinereview.com
Description: Professional movie review theme with horizontal scroll featured posts, auto thumbnails from content, classic editor support, and watermark on all content images. 100% SEO optimized.
Version: 2.0.0
Author: CineReview
Author URI: https://cinereview.com
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: cinereview
Tags: dark, movies, review, entertainment, responsive, seo-optimized, classic-editor
*/

@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Manrope:wght@400;500;600;700&display=swap');

:root {
    --bg-dark: #0a0a0a;
    --bg-secondary: #141414;
    --bg-card: #1a1a1a;
    --accent-gold: #d4af37;
    --accent-red: #e50914;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --border-subtle: #2a2a2a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Manrope', sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(212, 175, 55, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(229, 9, 20, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.container {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header.site-header {
    background: linear-gradient(180deg, var(--bg-secondary) 0%, transparent 100%);
    padding: 25px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-subtle);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

.site-logo a {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 42px;
    letter-spacing: 3px;
    background: linear-gradient(135deg, var(--accent-gold), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
}

.search-box {
    flex: 1;
    max-width: 500px;
    position: relative;
}

.search-box form {
    width: 100%;
}

.search-box input[type="search"],
.search-box input[type="text"] {
    width: 100%;
    padding: 14px 50px 14px 20px;
    background: var(--bg-card);
    border: 2px solid var(--border-subtle);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 15px;
    font-family: 'Manrope', sans-serif;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
}

.search-box::after {
    content: '🔍';
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    pointer-events: none;
}

/* Navigation */
nav.main-navigation {
    margin: 40px 0;
}

.nav-pills {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    list-style: none;
}

.nav-pills li a {
    display: block;
    padding: 12px 28px;
    background: var(--bg-card);
    border: 2px solid var(--border-subtle);
    border-radius: 30px;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    text-decoration: none;
}

.nav-pills li a:hover,
.nav-pills li.current-cat a,
.nav-pills li.current-menu-item a {
    background: var(--accent-gold);
    color: var(--bg-dark);
    border-color: var(--accent-gold);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.3);
}

/* Sections */
.movies-section {
    padding: 50px 0;
}

.section-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 36px;
    letter-spacing: 2px;
    margin-bottom: 30px;
    color: var(--text-primary);
    position: relative;
    padding-left: 20px;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 40px;
    background: var(--accent-red);
}

/* Featured Posts Horizontal Scroll Section */
.featured-section {
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.05) 0%, transparent 100%);
    padding: 60px 0;
    margin-bottom: 40px;
    overflow: hidden;
}

.featured-scroll-wrapper {
    position: relative;
    margin-bottom: 20px;
}

.featured-scroll {
    display: flex;
    gap: 25px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    padding: 10px 0 30px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-gold) var(--bg-secondary);
}

.featured-scroll::-webkit-scrollbar {
    height: 8px;
}

.featured-scroll::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 10px;
}

.featured-scroll::-webkit-scrollbar-thumb {
    background: var(--accent-gold);
    border-radius: 10px;
}

.featured-scroll::-webkit-scrollbar-thumb:hover {
    background: #ffd700;
}

.featured-item {
    flex: 0 0 220px;
    position: relative;
}

.featured-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--accent-gold);
    color: var(--bg-dark);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    z-index: 3;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.4);
}

.featured-thumbnail {
    width: 220px;
    height: 330px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background: var(--bg-card);
    transition: all 0.4s ease;
    cursor: pointer;
}

.featured-thumbnail:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.featured-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.featured-thumbnail:hover img {
    transform: scale(1.1);
}

/* Movie Grid */
.movie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.movie-card {
    background: var(--bg-card);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    border: 2px solid transparent;
    position: relative;
}

.movie-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.8) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

.movie-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--accent-gold);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.movie-card:hover::before {
    opacity: 1;
}

.movie-poster {
    width: 100%;
    aspect-ratio: 2/3;
    background: var(--bg-secondary);
    position: relative;
    overflow: hidden;
}

.movie-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.movie-card:hover .movie-poster img {
    transform: scale(1.1);
}

/* Logo Watermark Overlay on Thumbnails */
.watermark-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40%;
    height: auto;
    opacity: 0.5;
    pointer-events: none;
    z-index: 2;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
}

.movie-info {
    padding: 18px;
    position: relative;
    z-index: 2;
}

.movie-date {
    font-size: 12px;
    color: var(--accent-gold);
    font-weight: 600;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.movie-date::before {
    content: '📅';
    font-size: 14px;
}

.movie-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 120px;
}

.movie-title a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.movie-title a:hover {
    color: var(--accent-gold);
}

.movie-meta {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Related Movies Section */
.related-movies {
    background: var(--bg-secondary);
    padding: 60px 0;
    margin-top: 80px;
    border-top: 2px solid var(--border-subtle);
}

.related-movies .section-title {
    color: var(--text-primary);
}

.related-movies .movie-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 25px;
}

/* Single Post Page */
.single-post-content {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 20px;
}

.post-header {
    margin-bottom: 40px;
}

.post-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 48px;
    letter-spacing: 2px;
    margin-bottom: 20px;
    line-height: 1.2;
}

.post-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 30px;
}

.post-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-thumbnail {
    position: relative;
    margin-bottom: 40px;
    border-radius: 16px;
    overflow: hidden;
}

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

/* Classic Editor Content Styles */
.post-content {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-secondary);
}

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

/* Headings h1-h6 */
.post-content h1 {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 42px;
    color: var(--text-primary);
    margin: 40px 0 20px;
    letter-spacing: 1.5px;
    line-height: 1.2;
}

.post-content h2 {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 36px;
    color: var(--text-primary);
    margin: 35px 0 18px;
    letter-spacing: 1.2px;
    line-height: 1.3;
}

.post-content h3 {
    font-size: 28px;
    color: var(--text-primary);
    margin: 30px 0 15px;
    font-weight: 700;
    line-height: 1.4;
}

.post-content h4 {
    font-size: 24px;
    color: var(--text-primary);
    margin: 25px 0 12px;
    font-weight: 700;
    line-height: 1.4;
}

.post-content h5 {
    font-size: 20px;
    color: var(--text-primary);
    margin: 20px 0 10px;
    font-weight: 700;
    line-height: 1.5;
}

.post-content h6 {
    font-size: 18px;
    color: var(--text-primary);
    margin: 18px 0 8px;
    font-weight: 700;
    line-height: 1.5;
}

/* Bold, Italic, Underline */
.post-content b,
.post-content strong {
    font-weight: 700;
    color: var(--text-primary);
}

.post-content i,
.post-content em {
    font-style: italic;
    color: var(--accent-gold);
}

.post-content u {
    text-decoration: underline;
    text-decoration-color: var(--accent-gold);
    text-underline-offset: 3px;
}

/* Lists */
.post-content ul,
.post-content ol {
    margin: 20px 0 20px 30px;
    color: var(--text-secondary);
}

.post-content ul li,
.post-content ol li {
    margin-bottom: 10px;
    line-height: 1.8;
}

.post-content ul {
    list-style-type: disc;
}

.post-content ol {
    list-style-type: decimal;
}

/* Blockquote */
.post-content blockquote {
    border-left: 4px solid var(--accent-gold);
    padding: 20px 30px;
    margin: 30px 0;
    background: var(--bg-card);
    border-radius: 8px;
    font-style: italic;
    color: var(--text-secondary);
}

/* Links */
.post-content a {
    color: var(--accent-gold);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.post-content a:hover {
    color: var(--accent-red);
    border-bottom-color: var(--accent-red);
}

/* Images in Content with Watermark Overlay */
.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 30px 0;
    display: block;
}

.post-content figure,
.post-content .wp-block-image,
.post-content .content-image-wrapper {
    position: relative;
    display: inline-block;
    margin: 30px 0;
    width: 100%;
}

.post-content figure img,
.post-content .wp-block-image img {
    margin: 0;
}

/* Watermark on content images */
.content-image-watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30%;
    height: auto;
    opacity: 0.4;
    pointer-events: none;
    z-index: 2;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
}

/* Tables */
.post-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    background: var(--bg-card);
    border-radius: 8px;
    overflow: hidden;
}

.post-content table th {
    background: var(--accent-gold);
    color: var(--bg-dark);
    padding: 12px;
    text-align: left;
    font-weight: 700;
}

.post-content table td {
    padding: 12px;
    border-bottom: 1px solid var(--border-subtle);
}

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

/* Code */
.post-content code {
    background: var(--bg-card);
    padding: 2px 8px;
    border-radius: 4px;
    font-family: monospace;
    color: var(--accent-gold);
    font-size: 0.9em;
}

.post-content pre {
    background: var(--bg-card);
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 20px 0;
}

.post-content pre code {
    background: none;
    padding: 0;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 60px 0;
    flex-wrap: wrap;
}

.pagination a,
.pagination span {
    display: inline-block;
    min-width: 50px;
    height: 50px;
    background: var(--bg-card);
    border: 2px solid var(--border-subtle);
    border-radius: 10px;
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Manrope', sans-serif;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 15px;
}

.pagination a:hover,
.pagination span.current {
    background: var(--accent-gold);
    color: var(--bg-dark);
    border-color: var(--accent-gold);
    transform: scale(1.1);
}

.pagination .dots {
    cursor: default;
    pointer-events: none;
}

/* Footer */
footer.site-footer {
    background: var(--bg-secondary);
    padding: 40px 0;
    margin-top: 80px;
    border-top: 1px solid var(--border-subtle);
}

.footer-content {
    text-align: center;
    color: var(--text-secondary);
    font-size: 14px;
}

.footer-logo {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 32px;
    letter-spacing: 2px;
    background: linear-gradient(135deg, var(--accent-gold), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 768px) {
    .site-logo a {
        font-size: 32px;
    }

    .header-content {
        flex-direction: column;
        gap: 20px;
    }

    .search-box {
        max-width: 100%;
    }

    .movie-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 20px;
    }

    .section-title {
        font-size: 28px;
    }

    .nav-pills {
        gap: 8px;
    }

    .nav-pills li a {
        padding: 10px 20px;
        font-size: 12px;
    }

    .post-title {
        font-size: 32px;
    }

    .movie-title {
        min-height: 100px;
    }

    .featured-item {
        flex: 0 0 180px;
    }

    .featured-thumbnail {
        width: 180px;
        height: 270px;
    }

    .post-content h1 {
        font-size: 32px;
    }

    .post-content h2 {
        font-size: 28px;
    }

    .post-content h3 {
        font-size: 24px;
    }
}

/* Loading Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.movie-card {
    animation: fadeIn 0.6s ease forwards;
}

.movie-card:nth-child(1) { animation-delay: 0.1s; }
.movie-card:nth-child(2) { animation-delay: 0.15s; }
.movie-card:nth-child(3) { animation-delay: 0.2s; }
.movie-card:nth-child(4) { animation-delay: 0.25s; }
.movie-card:nth-child(5) { animation-delay: 0.3s; }
.movie-card:nth-child(6) { animation-delay: 0.35s; }

/* SEO Optimizations */
img {
    max-width: 100%;
    height: auto;
}

a {
    transition: all 0.3s ease;
}

/* WordPress Alignment Classes */
.alignleft {
    float: left;
    margin: 10px 20px 20px 0;
}

.alignright {
    float: right;
    margin: 10px 0 20px 20px;
}

.aligncenter {
    display: block;
    margin: 20px auto;
}

.alignnone {
    margin: 20px 0;
}
