/*
Theme Name: DealHunter ID
Theme URI: https://dealhunter.id
Author: DealHunter ID
Author URI: https://dealhunter.id
Description: Tema affiliate modern untuk TikTok Shop dan Shopee. Responsif, SEO-friendly, dengan tampilan produk grid dan filter kategori. Cocok untuk website affiliate marketing.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: dealhunter
Tags: affiliate, e-commerce, grid-layout, custom-colors, featured-images, sticky-post, threaded-comments, translation-ready

*/

/* ======================================================
   RESET & BASE
====================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --tt: #010101;
  --sp: #EE4D2D;
  --accent: #FF6B35;
  --gold: #FFB800;
  --bg: #F9F7F4;
  --card: #FFFFFF;
  --text: #1A1A1A;
  --muted: #666666;
  --border: #E8E3DC;
  --radius: 16px;
  --font-heading: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
}

html { scroll-behavior: smooth; }

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

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

a { color: inherit; }

/* ======================================================
   TYPOGRAPHY
====================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
}

/* ======================================================
   LAYOUT
====================================================== */
.site-wrapper { min-height: 100vh; display: flex; flex-direction: column; }
.site-main { flex: 1; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 5vw; }

/* ======================================================
   HEADER / NAVIGATION
====================================================== */
.site-header {
  background: var(--tt);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 2px solid #222;
}

.header-inner {
  max-width: 1200px;
  margin: auto;
  padding: 0 5vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-branding .site-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.4rem;
  color: #fff;
  text-decoration: none;
  letter-spacing: -0.5px;
  margin: 0;
}

.site-title span { color: var(--gold); }

.main-navigation ul {
  list-style: none;
  display: flex;
  gap: 0;
}

.main-navigation ul li a {
  color: #ccc;
  text-decoration: none;
  font-size: 0.85rem;
  margin-left: 1.5rem;
  transition: color .2s;
}

.main-navigation ul li a:hover,
.main-navigation ul li.current-menu-item a {
  color: var(--gold);
}

/* Mobile nav toggle */
.menu-toggle {
  display: none;
  background: none;
  border: 1px solid #444;
  color: #fff;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  font-family: var(--font-body);
}

/* ======================================================
   HERO SECTION
====================================================== */
.hero-section {
  background: var(--tt);
  padding: 80px 5vw 90px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 40px,
    rgba(255,255,255,0.015) 40px,
    rgba(255,255,255,0.015) 41px
  );
  pointer-events: none;
}

.hero-inner { position: relative; z-index: 1; max-width: 760px; margin: auto; }

.hero-badges {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.3px;
}

.badge-tt { background: #1a1a1a; color: #fff; border: 1px solid #333; }
.badge-sp { background: var(--sp); color: #fff; }
.badge-deal { background: var(--gold); color: #000; }

.hero-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(2rem, 5vw, 3.4rem);
  color: #fff;
  line-height: 1.15;
  margin-bottom: 16px;
  letter-spacing: -1px;
}

.hero-title em { color: var(--gold); font-style: normal; }

.hero-desc {
  color: #aaa;
  font-size: 1rem;
  max-width: 500px;
  margin: 0 auto 32px;
}

.hero-cta {
  display: inline-flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ======================================================
   BUTTONS
====================================================== */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 100px;
  font-weight: 500;
  font-size: 0.9rem;
  text-decoration: none;
  transition: transform .18s, opacity .18s;
  cursor: pointer;
  border: none;
  font-family: var(--font-body);
}

.btn:hover { transform: translateY(-2px); opacity: .9; }
.btn-gold { background: var(--gold); color: #000; }
.btn-outline { background: transparent; color: #fff; border: 1.5px solid #444; }
.btn-tt { background: #000; color: #fff; }
.btn-tt:hover { background: #222; color: #fff; }
.btn-sp { background: var(--sp); color: #fff; }
.btn-sp:hover { background: #d43c1e; color: #fff; }

/* ======================================================
   STATS STRIP
====================================================== */
.stats-strip {
  background: var(--tt);
  padding: 32px 5vw;
}

.stats-grid {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 24px;
  text-align: center;
}

.stat-number {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  color: var(--gold);
}

.stat-label { color: #888; font-size: 0.8rem; margin-top: 4px; }

/* ======================================================
   SECTION / PAGE CONTENT
====================================================== */
.section { padding: 48px 5vw; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 12px;
}

.section-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.platform-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.dot-tt { background: #fff; border: 2px solid #000; box-shadow: 0 0 0 2px #888; }
.dot-sp { background: var(--sp); }

/* ======================================================
   FILTER CHIPS
====================================================== */
.filter-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.filter-label {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 500;
}

.chip {
  padding: 6px 16px;
  border-radius: 100px;
  border: 1.5px solid var(--border);
  background: var(--card);
  font-size: 0.8rem;
  cursor: pointer;
  color: var(--muted);
  transition: all .15s;
  font-family: var(--font-body);
}

.chip:hover, .chip.active {
  border-color: var(--text);
  background: var(--text);
  color: #fff;
}

/* ======================================================
   PRODUCT GRID
====================================================== */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

/* ======================================================
   PRODUCT CARD
====================================================== */
.product-card {
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
  position: relative;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.1);
}

.platform-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 600;
  z-index: 2;
  letter-spacing: 0.3px;
}

.tag-tt { background: #000; color: #fff; }
.tag-sp { background: var(--sp); color: #fff; }

.card-thumbnail {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}

.card-thumbnail-placeholder {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  background: #F0EDE8;
}

.card-body { padding: 16px; }

.card-category {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 500;
}

.card-title {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 10px;
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.pill {
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 500;
}

.pill-green { background: #E8F5E9; color: #2E7D32; }
.pill-orange { background: #FFF3E0; color: #E65100; }
.pill-blue { background: #E3F2FD; color: #1565C0; }
.pill-red { background: #FFEBEE; color: #B71C1C; }

.card-cta {
  display: block;
  width: 100%;
  padding: 10px;
  border-radius: 10px;
  text-align: center;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  transition: all .18s;
  font-family: var(--font-body);
}

.cta-tt { background: #000; color: #fff; }
.cta-tt:hover { background: #222; color: #fff; }
.cta-sp { background: var(--sp); color: #fff; }
.cta-sp:hover { background: #d43c1e; color: #fff; }

/* ======================================================
   VOUCHER BANNER
====================================================== */
.voucher-banner {
  background: linear-gradient(135deg, #EE4D2D 0%, #FF6B35 100%);
  border-radius: var(--radius);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 32px;
}

.voucher-text h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  color: #fff;
  font-size: 1.3rem;
  margin-bottom: 6px;
}

.voucher-text p { color: rgba(255,255,255,0.85); font-size: 0.9rem; }

.btn-voucher {
  background: #fff;
  color: var(--sp);
  padding: 12px 28px;
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  white-space: nowrap;
  transition: transform .18s;
  display: inline-block;
}

.btn-voucher:hover { transform: scale(1.04); }

/* ======================================================
   SINGLE POST / PAGE
====================================================== */
.entry-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 5vw;
}

.entry-content h1, .entry-content h2, .entry-content h3 {
  margin-bottom: .75em;
  margin-top: 1.5em;
}

.entry-content p { margin-bottom: 1em; }

.entry-content a {
  color: var(--sp);
  text-decoration: underline;
}

/* ======================================================
   WIDGET AREAS (SIDEBAR)
====================================================== */
.widget-area { padding: 24px; }
.widget { margin-bottom: 32px; }
.widget-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--gold);
}

/* ======================================================
   FOOTER
====================================================== */
.site-footer {
  background: #0D0D0D;
  color: #666;
  padding: 40px 5vw;
  text-align: center;
  font-size: 0.8rem;
  line-height: 1.8;
  border-top: 1px solid #1a1a1a;
}

.footer-inner { max-width: 1200px; margin: auto; }

.footer-nav { margin-bottom: 12px; }
.footer-nav a {
  color: #888;
  text-decoration: none;
  margin: 0 8px;
  transition: color .2s;
}
.footer-nav a:hover { color: var(--gold); }

.footer-disclaimer {
  color: #555;
  font-size: 0.78rem;
  max-width: 700px;
  margin: 0 auto 8px;
}

.site-info { color: #444; font-size: 0.75rem; }

/* ======================================================
   REVEAL ANIMATION
====================================================== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .5s ease, transform .5s ease;
}
.revealed { opacity: 1; transform: translateY(0); }

/* ======================================================
   RESPONSIVE
====================================================== */
@media (max-width: 768px) {
  .hero-section { padding: 56px 5vw 64px; }
  .main-navigation { display: none; }
  .main-navigation.toggled { display: block; }
  .main-navigation.toggled ul { flex-direction: column; padding: 16px 0; }
  .main-navigation.toggled ul li a { margin-left: 0; padding: 8px 0; display: block; }
  .menu-toggle { display: block; }
  .voucher-banner { text-align: center; justify-content: center; }
  .section-header { flex-direction: column; align-items: flex-start; }
  .product-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
}

@media (max-width: 480px) {
  .product-grid { grid-template-columns: 1fr 1fr; }
  .hero-title { font-size: 1.8rem; }
}
