/*
Theme Name: DealHive Modern
Theme URI: https://dealhivehq.com
Author: DealHiveHQ Team
Description: A fast, mobile-first theme for DealHiveHQ.
Version: 1.0.0
Text Domain: dealhive
*/

:root {
    --color-primary: #FFD700;
    /* Gold */
    --color-secondary: #000000;
    /* Black */
    --color-text: #333333;
    /* Dark Grey */
    --color-bg: #F9F9F9;
    /* Off-white */
    --color-white: #FFFFFF;
    --color-accent: #FF4500;
    /* Orange-Red */
    --color-border: #E0E0E0;

    --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;

    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 32px;
    --spacing-xl: 64px;

    --container-width: 1200px;
    --border-radius: 8px;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: var(--font-main);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

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

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* Header */
.site-header {
    background: var(--color-secondary);
    color: var(--color-primary);
    padding: var(--spacing-md) 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.site-title {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--color-primary);
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: var(--spacing-md);
}

.main-navigation a {
    color: var(--color-white);
    font-weight: 500;
}

.main-navigation a:hover {
    color: var(--color-primary);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: var(--border-radius);
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-secondary);
}

.btn-primary:hover {
    background: #E6C200;
}

.btn-accent {
    background: var(--color-accent);
    color: var(--color-white);
}

.btn-accent:hover {
    background: #CC3700;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--color-white);
    font-size: 1.5rem;
    cursor: pointer;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .main-navigation {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--color-secondary);
        padding: var(--spacing-md);
    }

    .main-navigation.toggled {
        display: block;
    }

    .main-navigation ul {
        flex-direction: column;
        text-align: center;
    }

    .header-inner {
        flex-wrap: wrap;
    }

    .header-cta {
        display: none;
        /* Hide CTA on mobile header to save space, or move it */
    }
}

/* Hero Section */
.hero-section {
    background-color: var(--color-secondary);
    color: var(--color-white);
    padding: var(--spacing-xl) 0;
    text-align: center;
}

.hero-content h1 {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-md);
    color: var(--color-primary);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: var(--spacing-lg);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
}

/* Section Titles */
.section-title {
    text-align: center;
    font-size: 2rem;
    margin: var(--spacing-xl) 0 var(--spacing-lg);
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--color-primary);
    margin: var(--spacing-sm) auto 0;
}

/* Deals Grid */
.deals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.deal-card {
    background: var(--color-white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
}

.deal-card:hover {
    transform: translateY(-5px);
}

.deal-image {
    position: relative;
    padding-top: 100%;
    /* 1:1 Aspect Ratio */
    background: #f0f0f0;
}

.deal-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.deal-content {
    padding: var(--spacing-md);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.deal-title {
    font-size: 1.1rem;
    margin-bottom: var(--spacing-sm);
    line-height: 1.4;
}

.deal-title a {
    color: var(--color-text);
}

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

.deal-meta {
    margin-bottom: var(--spacing-md);
    display: flex;
    align-items: baseline;
    gap: var(--spacing-sm);
}

.deal-price {
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--color-accent);
}

.deal-original-price {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9rem;
}

.deal-content .btn {
    margin-top: auto;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Store Links */
.store-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
}

.store-card {
    background: var(--color-white);
    padding: var(--spacing-lg);
    text-align: center;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    font-weight: bold;
    font-size: 1.2rem;
    transition: background 0.3s, color 0.3s;
    border: 2px solid transparent;
}

.store-card:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

/* Footer */
.site-footer {
    background: var(--color-secondary);
    color: #ccc;
    padding: var(--spacing-xl) 0;
    text-align: center;
    margin-top: var(--spacing-xl);
}

.site-footer a {
    color: var(--color-white);
}

.site-footer a:hover {
    color: var(--color-primary);
}

.affiliate-disclosure {
    font-size: 0.8rem;
    margin-top: var(--spacing-md);
    opacity: 0.7;
}

/* Forms */
.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
}

/* Store Nav on Deals Page */
.store-nav {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
    justify-content: center;
}

.btn-outline {
    border: 2px solid var(--color-secondary);
    color: var(--color-secondary);
    background: transparent;
}

.btn-outline:hover {
    background: var(--color-secondary);
    color: var(--color-white);
}

/* Single Deal Page Styles (Ported) */
.single-deal-card {
    background: #fff;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
}

@media (min-width: 768px) {
    .single-deal-card {
        flex-direction: row;
        align-items: start;
    }

    .single-deal-image-col {
        width: 45%;
        flex-shrink: 0;
    }

    .single-deal-content-col {
        width: 55%;
        padding: 30px;
    }
}

.single-deal-image-col {
    background: #fff;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #f0f0f0;
}

.single-deal-image-col .main-img {
    max-width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: contain;
}

.thumbnail-row {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.thumb {
    width: 60px;
    height: 60px;
    background: #eee;
    border-radius: 4px;
    object-fit: cover;
    opacity: 0.6;
}

.single-deal-content-col {
    padding: 20px;
}

.merchant-badge {
    display: inline-block;
    background: #f0f0f0;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    color: #555;
    margin-bottom: 10px;
    font-weight: 600;
}

.price-block {
    margin-bottom: 20px;
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.current-price {
    font-size: 2rem;
    font-weight: 800;
    color: #D32F2F;
}

.retail-price {
    text-decoration: line-through;
    color: #999;
    font-size: 1.1rem;
}

.you-save {
    background: #ffebee;
    color: #c62828;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
}

.cta-button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    background: var(--color-primary);
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    padding: 16px;
    border-radius: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 6px rgba(255, 153, 0, 0.3);
    transition: transform 0.1s, box-shadow 0.1s;
    margin-bottom: 10px;
}

.cta-button:hover {
    background: #e68a00;
    box-shadow: 0 6px 8px rgba(255, 153, 0, 0.4);
    transform: translateY(-1px);
}

.cta-trust {
    text-align: center;
    font-size: 0.75rem;
    color: #888;
    margin-bottom: 20px;
    display: block;
}

.mobile-sticky-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #fff;
    padding: 12px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 900;
    display: flex;
    gap: 10px;
}

.mobile-sticky-footer .cta-button {
    margin-bottom: 0;
    width: 100%;
    font-size: 1rem;
    padding: 12px;
}

@media (min-width: 768px) {
    .mobile-sticky-footer {
        display: none;
    }
}

.details-box {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #eee;
    margin-top: 30px;
    font-size: 0.9rem;
}

.details-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid #eee;
}

.details-row:last-child {
    border-bottom: none;
}

.dt-label {
    font-weight: 600;
    color: #555;
}

.action-links {
    display: flex;
    gap: 15px;
    margin-top: 10px;
    justify-content: center;
}

.text-link-btn {
    background: none;
    border: none;
    font-size: 0.85rem;
    color: #e68a00;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}

/* Social Share Bar (compact) */
.social-share {
    background: #f8f9fb;
    border-bottom: 1px solid #e5e7eb;
    padding: 6px 0;
    margin-bottom: 16px;
}

.share-inner {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #555;
}

.share-inner span {
    font-weight: 600;
    color: #555;
    margin-right: 2px;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    height: 22px;
    line-height: 1;
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    background: #fff;
    color: #333;
    transition: background 0.15s ease, transform 0.1s ease;
}

.share-btn:hover {
    background: #f1f5f9;
    transform: translateY(-1px);
}

/* Platform accents */
.share-btn.fb { color: #1877F2; background: #fff; }
.share-btn.x { color: #000; background: #fff; }
.share-btn.insta { color: #E1306C; background: #fff; }

.share-icon {
    width: 12px;
    height: 12px;
    fill: currentColor;
}

/* Mobile: icon-only (keeps bar tidy) */
@media (max-width: 600px) {
    .share-inner span { display: none; }
    .share-btn {
        padding: 6px;
        height: 30px;
        font-size: 0; /* hide label text */
        gap: 0;
    }
    .share-icon {
        width: 16px;
        height: 16px;
    }
}

