/*
Theme Name: Flyershop
Theme URI: https://flyershop.co
Author: Flyershop
Description: Flyershop - Creative Flyer Templates Store
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: flyershop
*/

/* =============================================
   VARIABLES & RESET
   ============================================= */
:root {
    --primary-teal: #668E8B;
    --accent-beige: #C5B4A1;
    --accent-red: #FF0000;
    --text-dark: #FFFFFF;
    --text-light: #F0F0F0;
    --bg-light: #F9F9F9;
    --bg-dark: #050505;
    --white: #FFFFFF;
}

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

body {
    overflow-x: hidden;
    width: 100%;
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-dark);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center top;
    background-attachment: fixed;
}

/* =============================================
   HEADER
   ============================================= */
.main-header {
    padding: 15px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #000000;
    border-bottom: 1px solid #333;
    position: sticky;
    top: 0;
    z-index: 1000;
    flex-wrap: nowrap;
    gap: 15px;
}

.logo {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFFFFF;
    text-decoration: none;
}

.logo img {
    height: 50px;
    width: auto;
    filter: brightness(1.2);
}

/* =============================================
   NAVIGATION
   ============================================= */
.main-header nav {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.nav-menu,
.main-header nav > ul {
    display: flex;
    gap: 35px;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
}

/* WordPress nav_menu compatibility */
.main-header nav > ul > li > a,
.nav-link {
    text-decoration: none;
    color: #FFFFFF;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: color 0.2s;
}

.main-header nav > ul > li > a:hover,
.nav-link:hover,
.main-header nav > ul > li.current-menu-item > a {
    color: #FF0000;
}

/* Dropdowns */
.dropdown,
.main-header nav > ul > li.menu-item-has-children {
    position: relative;
}

.dropdown-content,
.main-header nav > ul > li.menu-item-has-children > ul.sub-menu {
    display: none;
    position: absolute;
    background-color: #1a1a1a;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.5);
    z-index: 1000;
    border-radius: 8px;
    padding: 10px 0;
    top: 100%;
    left: 0;
    border: 1px solid #333;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.2s, transform 0.2s;
    list-style: none;
}

.dropdown.active .dropdown-content,
.main-header nav > ul > li.menu-item-has-children.active > ul.sub-menu {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.dropdown-content a,
.main-header nav > ul > li.menu-item-has-children > ul.sub-menu > li > a {
    color: #ccc;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
}

.dropdown-content a:hover,
.main-header nav > ul > li.menu-item-has-children > ul.sub-menu > li > a:hover {
    background-color: #333;
    color: #FF0000;
}

/* =============================================
   HEADER ACTIONS (Search + User)
   ============================================= */
.header-actions {
    flex: 1;
    min-width: 0;
    flex-shrink: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
}

.search-bar {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 200px;
    padding: 8px 15px 8px 40px;
    border: 1px solid #FFFFFF;
    background: #000000;
    border-radius: 20px;
    outline: none;
    font-family: 'Poppins', sans-serif;
    color: #FFFFFF;
    font-size: 0.9rem;
    height: 36px;
}

.search-input::placeholder { color: #AAAAAA; }

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-icon svg {
    width: 16px;
    height: 16px;
    stroke: #FFFFFF;
    stroke-width: 2;
}

.user-icon-btn {
    width: 40px;
    height: 40px;
    background: transparent;
    border: 2px solid #FFFFFF;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
    flex-shrink: 0;
}

.user-icon-btn svg {
    width: 20px;
    height: 20px;
    fill: #FFFFFF;
}

.user-icon-btn:hover {
    background-color: #FFFFFF;
}

.user-icon-btn:hover svg {
    fill: #000000;
}

/* =============================================
   HAMBURGER MENU
   ============================================= */
.hamburger-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.hamburger-lines {
    display: block;
    width: 25px;
    height: 3px;
    background: #FFFFFF;
    position: relative;
}

.hamburger-lines::before,
.hamburger-lines::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: #FFFFFF;
    transition: all 0.3s;
}

.hamburger-lines::before { top: -8px; }
.hamburger-lines::after  { top: 8px; }

.hamburger-btn.active .hamburger-lines { background: transparent; }
.hamburger-btn.active .hamburger-lines::before { top: 0; transform: rotate(45deg); }
.hamburger-btn.active .hamburger-lines::after  { top: 0; transform: rotate(-45deg); }

/* =============================================
   HERO SECTION
   ============================================= */
.hero-container { padding: 20px 40px; }

.hero-banner {
    background-color: #1a1a1a;
    background-size: cover;
    background-position: center;
    border-radius: 20px;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 60px;
    position: relative;
    overflow: hidden;
    text-align: left;
}

.hero-text {
    flex: 1;
    max-width: 550px;
    color: #FFFFFF;
    z-index: 2;
    padding: 0;
    position: relative;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 30px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}

.hero-description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 30px;
    color: #f0f0f0;
    max-width: 480px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.hero-btn {
    display: inline-block;
    background-color: #FF0000;
    color: white;
    padding: 12px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(255,0,0,0.3);
    transition: transform 0.2s;
}

.hero-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 25px rgba(255,0,0,0.6);
    color: white;
}

.hero-subtext {
    font-style: italic;
    font-weight: 300;
    opacity: 0.9;
    font-size: 1rem;
}

.hero-images {
    flex: 1;
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.flyer-card {
    position: absolute;
    width: 220px;
    height: 300px;
    background-size: cover;
    background-position: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    border-radius: 4px;
    transition: transform 0.3s;
}

.flyer-1 { transform: rotate(-15deg) translate(-120px, 20px); z-index: 1; }
.flyer-2 { transform: rotate(0deg) translate(0, 0) scale(1.1); z-index: 3; }
.flyer-3 { transform: rotate(15deg) translate(120px, 20px); z-index: 2; }

/* =============================================
   CART
   ============================================= */
.cart-fab {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 56px;
    height: 56px;
    background: #FF0000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(255,0,0,0.4);
    z-index: 999;
    text-decoration: none;
    color: white;
    transition: transform 0.2s;
}

.cart-fab:hover { transform: scale(1.1); color: white; }

.cart-icon-container { position: relative; }

.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: white;
    color: #FF0000;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
}

.cart-overlay.active { display: block; }

.cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 380px;
    height: 100vh;
    background: #111;
    z-index: 1001;
    transition: right 0.3s ease;
    display: flex;
    flex-direction: column;
    border-left: 1px solid #333;
}

.cart-sidebar.active { right: 0; }

.cart-header {
    padding: 20px;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}

.cart-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

.cart-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    color: #ccc;
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid #333;
}

.checkout-btn {
    width: 100%;
    background: #FF0000;
    color: white;
    border: none;
    padding: 14px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.checkout-btn:hover { opacity: 0.9; }

/* =============================================
   GENERAL SECTIONS
   ============================================= */
.section-container { padding: 40px; }

.section-title-main {
    font-size: 1.8rem;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 8px;
}

.section-subtitle {
    color: #999;
    font-size: 0.95rem;
    margin-bottom: 30px;
}

/* Product / Flyer Cards */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.product-card {
    background: #1a1a1a;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    border: 1px solid #2a2a2a;
}

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

.product-card img {
    width: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
    display: block;
}

.product-card-info {
    padding: 12px 15px;
}

.product-card-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
}

.product-card-price {
    font-size: 1rem;
    font-weight: 700;
    color: #FF0000;
}

/* =============================================
   FOOTER
   ============================================= */
.site-footer {
    background: #000;
    border-top: 1px solid #222;
    padding: 40px;
    margin-top: 60px;
    color: #888;
    font-size: 0.9rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-col h4 {
    color: #fff;
    margin-bottom: 15px;
    font-size: 1rem;
}

.footer-col a {
    display: block;
    color: #888;
    text-decoration: none;
    margin-bottom: 8px;
    transition: color 0.2s;
}

.footer-col a:hover { color: #FF0000; }

.footer-bottom {
    border-top: 1px solid #222;
    padding-top: 20px;
    text-align: center;
}

/* =============================================
   WORDPRESS SPECIFICS
   ============================================= */
.wp-block-image img { max-width: 100%; height: auto; }

img { max-width: 100%; height: auto; }

a { transition: color 0.2s; }

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1150px) {
    .logo { flex: 0 0 auto; font-size: 1.2rem; }
    .logo img { height: 40px !important; }
    .nav-menu, .main-header nav > ul { gap: 15px; }
    .main-header nav > ul > li > a, .nav-link { font-size: 0.85rem; }
    .header-actions { gap: 10px; }
    .search-input { width: 160px; }
}

@media (max-width: 1024px) {
    .main-header nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: #000000;
        border-bottom: 2px solid #333;
        padding: 20px 0;
        flex-direction: column;
        z-index: 999;
        justify-content: flex-start;
    }

    .main-header nav.active { display: flex; }

    .nav-menu,
    .main-header nav > ul {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }

    .main-header nav > ul > li,
    .nav-menu li {
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #1a1a1a;
    }

    .main-header nav > ul > li > a,
    .nav-link {
        padding: 15px;
        justify-content: center;
        width: 100%;
        font-size: 1.1rem;
    }

    .dropdown-content,
    .main-header nav > ul > li.menu-item-has-children > ul.sub-menu {
        position: static;
        background: #111;
        width: 100%;
        border: none;
        box-shadow: none;
        padding: 0;
        display: none;
        opacity: 1;
        transform: none;
    }

    .dropdown.active .dropdown-content,
    .main-header nav > ul > li.menu-item-has-children.active > ul.sub-menu {
        display: block;
    }

    .dropdown-content a,
    .main-header nav > ul > li.menu-item-has-children > ul.sub-menu > li > a {
        padding-left: 20px;
        background: #0a0a0a;
    }

    .hamburger-btn {
        display: block;
        margin-left: 10px;
    }

    .search-bar { max-width: 160px; }
}

@media (max-width: 768px) {
    .main-header { padding: 10px 15px; gap: 10px; }
    .logo img { height: 32px !important; }
    .header-actions { gap: 8px; }
    .search-input { width: 100%; max-width: 180px; min-width: 100px; padding: 6px 10px 6px 32px; height: 34px; font-size: 0.85rem; }
    .search-icon svg { width: 14px; height: 14px; }
    .user-icon-btn { width: 34px; height: 34px; }
    .hero-container { padding: 15px 20px; }
    .hero-banner { height: 350px; padding: 0 30px; }
    .hero-title { font-size: 2.2rem; }
    .hero-images { display: none; }
    .section-container { padding: 25px 20px; }
    .products-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 15px; }
    .site-footer { padding: 30px 20px; }
}

@media (max-width: 480px) {
    .search-bar { display: none; }
    .hero-banner { height: 280px; }
    .hero-title { font-size: 1.8rem; }
}

@media (max-width: 420px) {
    .logo img { height: 28px !important; }
    .main-header { padding: 10px; }
}
