/* ============================================================
   SavvyCartHub — main stylesheet
   Palette: Primary #FF6B35 · Secondary #1A1A2E · BG #F8F9FA · Text #333
   Fonts:   Poppins (headings) · Open Sans (body)
   Mobile-first.
   ============================================================ */

:root {
    --tcc-primary: #FF6B35;
    --tcc-primary-dark: #e55a2b;
    --tcc-secondary: #1A1A2E;
    --tcc-bg: #F8F9FA;
    --tcc-text: #333333;
    --tcc-card-bg: #ffffff;
    --tcc-border: #e3e6ea;
    --tcc-muted: #6c757d;
}

* { box-sizing: border-box; }

body {
    background: var(--tcc-bg);
    color: var(--tcc-text);
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    line-height: 1.65;
}

h1, h2, h3, h4, h5, h6,
.navbar-brand, .section-title, .widget-title {
    font-family: 'Poppins', sans-serif;
    color: var(--tcc-secondary);
}

a { color: var(--tcc-primary); text-decoration: none; }
a:hover { color: var(--tcc-primary-dark); }

.btn-primary {
    background: var(--tcc-primary);
    border-color: var(--tcc-primary);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
    background: var(--tcc-primary-dark);
    border-color: var(--tcc-primary-dark);
}
.btn-outline-primary {
    color: var(--tcc-primary);
    border-color: var(--tcc-primary);
}
.btn-outline-primary:hover {
    background: var(--tcc-primary);
    border-color: var(--tcc-primary);
    color: #fff;
}
.page-item.active .page-link {
    background: var(--tcc-primary);
    border-color: var(--tcc-primary);
}
.page-link { color: var(--tcc-primary); }

/* ---------- Header ---------- */
.site-header {
    background: var(--tcc-secondary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
}
.site-header .nav-link {
    color: #d7d9e8;
    font-weight: 600;
    font-size: .95rem;
    padding: .6rem .8rem;
}
.site-header .nav-link:hover, .site-header .nav-link:focus {
    color: var(--tcc-primary);
}
.site-logo {
    color: #fff;
    font-weight: 700;
    font-size: 1.35rem;
}
.site-logo i { color: var(--tcc-primary); }
.site-logo:hover { color: var(--tcc-primary); }
.navbar-toggler { border-color: rgba(255, 255, 255, .3); }
.navbar-toggler-icon { filter: invert(1); }
.icon-btn {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 50%;
    width: 38px;
    height: 38px;
    padding: 0;
}
.icon-btn:hover { color: var(--tcc-primary); border-color: var(--tcc-primary); }
.search-bar {
    background: #12121f;
    border-top: 1px solid rgba(255, 255, 255, .08);
}

/* ---------- Hero carousel ---------- */
.hero-carousel { border-radius: .75rem; overflow: hidden; }
.hero-img {
    width: 100%;
    height: auto !important;
    object-fit: cover;
    aspect-ratio: 1200 / 628;
    max-height: 480px;
    filter: brightness(.55);
}
.hero-caption {
    text-align: left;
    left: 6%;
    right: 6%;
    bottom: 12%;
}
.hero-badge { background: var(--tcc-primary); }
.hero-title { font-weight: 700; font-size: 1.5rem; }
.hero-title a { color: #fff; }
.hero-title a:hover { color: var(--tcc-primary); }
.hero-excerpt { color: rgba(255, 255, 255, .85); max-width: 640px; }
@media (min-width: 768px) {
    .hero-title { font-size: 2.1rem; }
}

/* ---------- Sections / cards ---------- */
.section-title {
    font-weight: 700;
    border-left: 4px solid var(--tcc-primary);
    padding-left: .75rem;
}

.post-card {
    border: 1px solid var(--tcc-border);
    border-radius: .6rem;
    overflow: hidden;
    background: var(--tcc-card-bg);
    transition: transform .18s ease, box-shadow .18s ease;
}
.post-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(26, 26, 46, .12);
}
.post-card-img {
    width: 100%;
    height: auto !important;
    aspect-ratio: 1200 / 628;
    object-fit: cover;
}
.post-card-cat {
    font-size: .78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.post-card-title { font-size: 1.05rem; font-weight: 600; }
.post-card-title a { color: var(--tcc-secondary); }
.post-card-title a:hover { color: var(--tcc-primary); }
.post-card-excerpt { font-size: .92rem; color: var(--tcc-muted); }

/* ---------- Sidebar ---------- */
.sidebar-widget {
    background: var(--tcc-card-bg);
    border: 1px solid var(--tcc-border);
    border-radius: .6rem;
    padding: 1.25rem;
}
.widget-title {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: .5rem;
    border-bottom: 2px solid var(--tcc-primary);
    display: inline-block;
}
.popular-thumb {
    width: 80px !important;
    height: 60px !important;
    object-fit: cover;
    border-radius: .4rem;
    flex-shrink: 0;
}
.popular-title {
    color: var(--tcc-secondary);
    font-weight: 600;
    font-size: .9rem;
    line-height: 1.35;
    display: block;
}
.popular-title:hover { color: var(--tcc-primary); }
.category-list { list-style: none; margin: 0; padding: 0; }
.category-list li {
    padding: .45rem 0;
    border-bottom: 1px solid var(--tcc-border);
}
.category-list li:last-child { border-bottom: 0; }
.category-list a { color: var(--tcc-text); font-weight: 600; }
.category-list a:hover { color: var(--tcc-primary); }
.cat-count { background: var(--tcc-secondary); }

/* ---------- Newsletter box ---------- */
.newsletter-box {
    background: var(--tcc-secondary);
    color: #e8e9f3;
    border-radius: .6rem;
}
.newsletter-box h3 { color: #fff; }
.newsletter-box h3 i { color: var(--tcc-primary); }

/* ---------- Article ---------- */
.article-title {
    font-weight: 700;
    font-size: 1.75rem;
    margin-bottom: .75rem;
}
@media (min-width: 992px) {
    .article-title { font-size: 2.4rem; }
}
.article-meta { color: var(--tcc-muted); font-size: .9rem; }
.article-meta a { color: var(--tcc-muted); }
.article-meta a:hover { color: var(--tcc-primary); }
.article-content h2 { margin-top: 2rem; font-size: 1.5rem; font-weight: 600; }
.article-content h3 { margin-top: 1.5rem; font-size: 1.2rem; font-weight: 600; }
.article-content img { max-width: 100%; height: auto; }

.author-box {
    background: var(--tcc-card-bg);
    border: 1px solid var(--tcc-border);
    border-left: 4px solid var(--tcc-primary);
    border-radius: .6rem;
}
.author-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--tcc-secondary);
    color: var(--tcc-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    flex-shrink: 0;
}

.share-btn {
    color: #fff;
    font-size: .88rem;
}
.share-btn:hover { color: #fff; opacity: .88; }
.share-facebook { background: #1877f2; }
.share-twitter { background: #14171a; }
.share-pinterest { background: #e60023; }
.share-whatsapp { background: #25d366; }
.share-copy { background: var(--tcc-secondary); }

/* ---------- Comments ---------- */
.comment-item {
    background: var(--tcc-card-bg);
    border: 1px solid var(--tcc-border);
    border-radius: .6rem;
}
.comment-list { list-style: none; padding: 0; margin: 0; }
.comment-form-box, .contact-form-box {
    background: var(--tcc-card-bg);
    border: 1px solid var(--tcc-border);
    border-radius: .6rem;
}

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: .88rem; }
.breadcrumb-item a { color: var(--tcc-muted); }
.breadcrumb-item a:hover { color: var(--tcc-primary); }
.breadcrumb-item.active { color: var(--tcc-secondary); }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--tcc-secondary);
    color: #c7c9d9;
}
.footer-heading { color: #fff; font-size: 1.05rem; font-weight: 600; margin-bottom: 1rem; }
.footer-heading i { color: var(--tcc-primary); }
.footer-blurb { font-size: .9rem; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: .4rem; }
.footer-links a { color: #c7c9d9; font-size: .92rem; }
.footer-links a:hover { color: var(--tcc-primary); }
.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .25);
    color: #fff;
}
.social-links a:hover { background: var(--tcc-primary); border-color: var(--tcc-primary); }
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .1);
    font-size: .85rem;
}

/* ---------- Ads ---------- */
.ad-slot { margin: 1.25rem 0; text-align: center; }

/* ---------- Dark mode ---------- */
[data-theme="dark"] {
    --tcc-bg: #12121f;
    --tcc-text: #d7d9e8;
    --tcc-card-bg: #1e1e30;
    --tcc-border: #2c2c44;
    --tcc-muted: #9a9db8;
}
[data-theme="dark"] body { background: var(--tcc-bg); color: var(--tcc-text); }
[data-theme="dark"] h1, [data-theme="dark"] h2, [data-theme="dark"] h3,
[data-theme="dark"] h4, [data-theme="dark"] h5, [data-theme="dark"] h6,
[data-theme="dark"] .section-title, [data-theme="dark"] .widget-title { color: #f0f1fa; }
[data-theme="dark"] .post-card-title a,
[data-theme="dark"] .popular-title { color: #f0f1fa; }
[data-theme="dark"] .post-card-excerpt { color: var(--tcc-muted); }
[data-theme="dark"] .form-control, [data-theme="dark"] .form-select {
    background: #171728;
    border-color: var(--tcc-border);
    color: var(--tcc-text);
}
[data-theme="dark"] .form-control::placeholder { color: var(--tcc-muted); }
[data-theme="dark"] .breadcrumb-item.active { color: #f0f1fa; }
[data-theme="dark"] .page-link {
    background: var(--tcc-card-bg);
    border-color: var(--tcc-border);
}
[data-theme="dark"] .text-muted { color: var(--tcc-muted) !important; }

/* ---------- Print ---------- */
@media print {
    .site-header, .site-footer, .site-sidebar, .ad-slot,
    .comments-section, .share-box, .newsletter-box,
    .hero-carousel .carousel-control-prev, .hero-carousel .carousel-control-next,
    .breadcrumb, form, .btn { display: none !important; }
    body { background: #fff; color: #000; }
    .article-title { font-size: 1.6rem; }
    a { color: #000; text-decoration: underline; }
}
