/*
Theme Name: PureDeals Compact
Version: 10.0 (Stability & Horizontal Fix)
*/

/* --- 1. RESET & BASICS --- */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.4;
    color: #333;
    background-color: #f4f4f4;
    overflow-x: hidden;
}

/* --- 2. THE GLOBAL CENTERING ENGINE --- */
.site-wrapper {
    display: grid;
    grid-template-columns: minmax(10px, 1fr) min(900px, 100%) minmax(10px, 1fr);
}

.site-wrapper > header,
.site-wrapper > main,
.site-wrapper > footer {
    grid-column: 2;
    background-color: #ffffff;
    padding: 0 20px;
}

/* --- 3. HEADER & NAV (Horizontal Fix) --- */
header { padding: 20px 0; border-bottom: 1px solid #eee; position: sticky; top: 0; z-index: 1000; background: #fff; }
.nav-container { display: flex; justify-content: space-between; align-items: center; }

/* Desktop Menu Styling */
.header-menu-list { 
    display: flex; 
    flex-direction: row; 
    list-style: none; 
    gap: 25px; 
}

.header-menu-list a { 
    text-decoration: none; 
    color: #111; 
    font-weight: 700; 
    font-size: 14px; 
    text-transform: uppercase; 
}

/* --- 4. HAMBURGER BUTTON (Chrome/Firefox Visibility) --- */
.menu-toggle {
    display: none; /* Hidden on Desktop */
    background: #111;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 4px;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle .bar {
    display: block;
    width: 22px;
    height: 2px;
    background: #fff;
    margin: 4px auto;
    transition: 0.3s;
}

/* --- 5. COMPACT DEAL CARDS --- */
.main-wrapper { display: grid; grid-template-columns: 1fr 300px; gap: 30px; padding: 30px 0; }

.deal-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
    margin-bottom: 12px;
    border: 1px solid #eee;
    border-radius: 6px;
    background: #fff;
}

.deal-thumbnail { width: 70px; height: 70px; flex-shrink: 0; }
.deal-thumbnail img { width: 100%; height: 100%; object-fit: contain; }
.deal-details { flex-grow: 1; display: flex; flex-direction: column; justify-content: center; }

.get-deal-btn {
    background-color: #111;
    color: #fff !important;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.85rem;
}

/* --- 6. MOBILE OVERRIDES (Pixel 9 & Firefox Fixes) --- */
@media (max-width: 768px) {
    .main-wrapper { grid-template-columns: 1fr; }
    
    .menu-toggle { display: block !important; }

    /* Vertical Mobile Menu Drawer */
    #site-navigation {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: #fff;
        z-index: 100;
        border-bottom: 1px solid #eee;
    }

    #site-navigation.active { display: block !important; }

    .header-menu-list { flex-direction: column; gap: 0; }
    .header-menu-list a { display: block; padding: 15px; text-align: center; border-bottom: 1px solid #f9f9f9; }

    /* Animation to X */
    .menu-toggle.is-active .bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
    .menu-toggle.is-active .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.is-active .bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
}