/* ============================================
   DEALHUNTER - Global Styles
   ============================================ */

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

:root {
  --red:       #CC0000;
  --red-dark:  #a30000;
  --orange:    #E8630A;
  --green:     #1a7a1a;
  --navy:      #1C2B3A;
  --gray-dark: #333333;
  --gray-mid:  #666666;
  --gray-light:#f2f2f2;
  --border:    #dddddd;
  --white:     #ffffff;
  --yellow:    #FFD700;
}

html { scroll-behavior: smooth; }

body {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 14px;
  color: var(--gray-dark);
  background: var(--gray-light);
  line-height: 1.5;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

/* ── Utility ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.btn {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: background .2s, color .2s;
}
.btn-red   { background: var(--red);    color: var(--white); }
.btn-red:hover { background: var(--red-dark); }
.btn-outline { background: transparent; border: 2px solid var(--red); color: var(--red); }
.btn-outline:hover { background: var(--red); color: var(--white); }

/* ============================================
   TOP BAR
   ============================================ */
.topbar {
  background: var(--navy);
  color: #ccc;
  font-size: 12px;
  padding: 5px 0;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.topbar a { color: #ccc; }
.topbar a:hover { color: var(--white); }
.topbar-left span { margin-right: 16px; }
.topbar-right a { margin-left: 14px; }

/* ============================================
   HEADER
   ============================================ */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--red);
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 2px 6px rgba(0,0,0,.12);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px 16px;
  max-width: 1200px;
  margin: 0 auto;
}
.logo { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.logo-icon {
  background: var(--red);
  color: var(--white);
  font-size: 22px;
  font-weight: 900;
  width: 44px; height: 44px;
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
}
.logo-text { font-size: 22px; font-weight: 900; color: var(--navy); letter-spacing: -0.5px; }
.logo-text span { color: var(--red); }

.header-search {
  flex: 1;
  display: flex;
  border: 2px solid var(--red);
  border-radius: 4px;
  overflow: hidden;
}
.header-search input {
  flex: 1;
  padding: 8px 12px;
  border: none;
  outline: none;
  font-size: 14px;
}
.header-search button {
  background: var(--red);
  border: none;
  color: var(--white);
  padding: 0 18px;
  cursor: pointer;
  font-size: 16px;
}
.header-search button:hover { background: var(--red-dark); }

.header-actions { display: flex; gap: 12px; align-items: center; flex-shrink: 0; }
.header-actions a {
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
  padding: 6px 14px;
  border-radius: 4px;
  border: 2px solid var(--border);
  white-space: nowrap;
}
.header-actions a:hover { border-color: var(--red); color: var(--red); }
.header-actions a.btn-red { border-color: var(--red); color: var(--white); }

/* ============================================
   CATEGORY NAV
   ============================================ */
.category-nav {
  background: var(--navy);
}
.category-nav .container {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
.category-nav .container::-webkit-scrollbar { display: none; }
.category-nav a {
  color: #ddd;
  font-size: 13px;
  font-weight: 700;
  padding: 10px 16px;
  white-space: nowrap;
  display: block;
  border-right: 1px solid rgba(255,255,255,.1);
  transition: background .2s, color .2s;
}
.category-nav a:hover,
.category-nav a.active { background: var(--red); color: var(--white); }

/* ============================================
   LIVE TICKER
   ============================================ */
.live-ticker {
  background: #fff8e1;
  border-bottom: 1px solid #ffe082;
  padding: 7px 0;
  overflow: hidden;
}
.ticker-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}
.ticker-label {
  background: var(--red);
  color: var(--white);
  font-size: 11px;
  font-weight: 900;
  padding: 3px 9px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: .5px;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 5px;
}
.live-dot {
  width: 8px; height: 8px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.2s infinite;
}
@keyframes pulse {
  0%,100% { opacity: 1; }
  50%      { opacity: .3; }
}
.ticker-track {
  overflow: hidden;
  flex: 1;
}
.ticker-list {
  display: flex;
  gap: 40px;
  animation: tickerScroll 40s linear infinite;
  white-space: nowrap;
}
.ticker-list:hover { animation-play-state: paused; }
@keyframes tickerScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.ticker-list a {
  font-size: 13px;
  color: var(--navy);
  font-weight: 600;
}
.ticker-list a:hover { color: var(--red); }
.ticker-list .price { color: var(--red); font-weight: 900; margin-left: 4px; }

/* ============================================
   LAYOUT: two-col main + sidebar
   ============================================ */
.page-body {
  max-width: 1200px;
  margin: 20px auto;
  padding: 0 16px;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
}

/* ============================================
   SECTION HEADER
   ============================================ */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.section-title {
  font-size: 17px;
  font-weight: 900;
  color: var(--navy);
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title::before {
  content: '';
  display: block;
  width: 4px; height: 20px;
  background: var(--red);
  border-radius: 2px;
}
.section-title .badge {
  background: var(--red);
  color: var(--white);
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 20px;
  font-weight: 700;
}
.see-all { color: var(--red); font-size: 13px; font-weight: 700; }
.see-all:hover { text-decoration: underline; }

/* ============================================
   DEAL CARD
   ============================================ */
.deals-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}
.deals-grid.two-col { grid-template-columns: repeat(2, 1fr); }
.deals-grid.four-col { grid-template-columns: repeat(4, 1fr); }

.deal-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  transition: box-shadow .2s, transform .2s;
  cursor: pointer;
  position: relative;
}
.deal-card:hover {
  box-shadow: 0 4px 18px rgba(0,0,0,.14);
  transform: translateY(-2px);
}

.deal-card .badge-hot {
  position: absolute;
  top: 10px; left: 10px;
  background: var(--orange);
  color: var(--white);
  font-size: 10px;
  font-weight: 900;
  padding: 3px 8px;
  border-radius: 3px;
  z-index: 2;
  text-transform: uppercase;
}
.deal-card .badge-new {
  background: var(--green);
}
.deal-card .badge-exp {
  background: #888;
}

.deal-img {
  width: 100%;
  height: 160px;
  object-fit: contain;
  background: #fafafa;
  padding: 10px;
}
.deal-body { padding: 12px; }
.deal-store {
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-mid);
  text-transform: uppercase;
  letter-spacing: .3px;
  margin-bottom: 4px;
}
.deal-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-dark);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.deal-prices {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}
.deal-price-now {
  font-size: 20px;
  font-weight: 900;
  color: var(--red);
}
.deal-price-was {
  font-size: 13px;
  color: var(--gray-mid);
  text-decoration: line-through;
}
.deal-save {
  font-size: 11px;
  font-weight: 700;
  color: var(--green);
  background: #e8f5e9;
  padding: 2px 6px;
  border-radius: 3px;
}
.deal-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--gray-light);
}
.deal-time { font-size: 11px; color: var(--gray-mid); }
.deal-time span { color: var(--red); font-weight: 700; }
.deal-cta {
  background: var(--red);
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 4px;
}
.deal-cta:hover { background: var(--red-dark); }
.deal-votes {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--gray-mid);
}
.vote-btn {
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: 4px;
  padding: 2px 8px;
  cursor: pointer;
  font-size: 12px;
  transition: .15s;
}
.vote-btn:hover { background: var(--gray-light); }
.vote-btn.up:hover { border-color: var(--green); color: var(--green); }
.vote-btn.down:hover { border-color: #c0392b; color: #c0392b; }

/* ============================================
   LIST VIEW (Trending)
   ============================================ */
.deals-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.deal-row {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  display: flex;
  gap: 12px;
  padding: 12px;
  transition: box-shadow .2s;
}
.deal-row:hover { box-shadow: 0 3px 12px rgba(0,0,0,.1); }
.deal-row-img {
  width: 90px;
  height: 90px;
  object-fit: contain;
  flex-shrink: 0;
  background: #fafafa;
  border-radius: 4px;
  padding: 4px;
}
.deal-row-info { flex: 1; }
.deal-row-info .deal-title { font-size: 14px; -webkit-line-clamp: 2; }
.deal-row-prices {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 4px 0;
}
.deal-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}
.rank-badge {
  background: var(--navy);
  color: var(--white);
  font-size: 11px;
  font-weight: 900;
  padding: 3px 8px;
  border-radius: 3px;
}

/* ============================================
   SIDEBAR
   ============================================ */
.sidebar { display: flex; flex-direction: column; gap: 20px; }

.sidebar-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}
.sidebar-card-header {
  background: var(--navy);
  color: var(--white);
  font-size: 14px;
  font-weight: 900;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar-card-body { padding: 12px; }

/* Top Stores */
.store-list { display: flex; flex-direction: column; gap: 2px; }
.store-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 0;
  border-bottom: 1px solid var(--gray-light);
  font-size: 13px;
}
.store-item:last-child { border-bottom: none; }
.store-name { font-weight: 700; color: var(--navy); }
.store-count {
  background: var(--gray-light);
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px;
  color: var(--gray-mid);
  font-weight: 700;
}

/* Price Alert */
.price-alert-form { display: flex; flex-direction: column; gap: 8px; }
.price-alert-form input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  outline: none;
}
.price-alert-form input:focus { border-color: var(--red); }
.price-alert-form button { width: 100%; }

/* Newsletter */
.newsletter-form { display: flex; flex-direction: column; gap: 8px; }
.newsletter-form input {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  outline: none;
}
.newsletter-form input:focus { border-color: var(--red); }
.newsletter-form button { width: 100%; }

/* Categories Sidebar */
.cat-sidebar-list { display: flex; flex-direction: column; }
.cat-sidebar-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 1px solid var(--gray-light);
  font-size: 13px;
  cursor: pointer;
  transition: background .15s;
}
.cat-sidebar-item:hover { background: var(--gray-light); }
.cat-sidebar-item span:first-child { display: flex; align-items: center; gap: 8px; }

/* ============================================
   HERO BANNER
   ============================================ */
.hero-banner {
  background: linear-gradient(135deg, var(--navy) 0%, #2c3e50 100%);
  color: var(--white);
  border-radius: 8px;
  padding: 28px 32px;
  margin-bottom: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  position: relative;
  overflow: hidden;
}
.hero-banner::after {
  content: '🏷️';
  position: absolute;
  right: 180px;
  font-size: 120px;
  opacity: .08;
  pointer-events: none;
}
.hero-text h1 { font-size: 26px; font-weight: 900; margin-bottom: 6px; }
.hero-text h1 span { color: var(--yellow); }
.hero-text p { color: #aaa; font-size: 14px; margin-bottom: 14px; }
.hero-stats {
  display: flex;
  gap: 24px;
  margin-top: 10px;
}
.hero-stat { text-align: center; }
.hero-stat strong { display: block; font-size: 22px; font-weight: 900; color: var(--yellow); }
.hero-stat small { font-size: 11px; color: #aaa; }

/* ============================================
   FILTER BAR
   ============================================ */
.filter-bar {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.filter-bar label { font-size: 12px; font-weight: 700; color: var(--gray-mid); margin-right: 2px; }
.filter-btn {
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  background: var(--white);
  color: var(--gray-dark);
  transition: .15s;
}
.filter-btn:hover, .filter-btn.active {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
}
.filter-sep { color: var(--border); }
.sort-select {
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 12px;
  outline: none;
  margin-left: auto;
}

/* ============================================
   FEATURED / DOUBLE DEAL
   ============================================ */
.featured-deal {
  background: var(--white);
  border: 2px solid var(--red);
  border-radius: 8px;
  padding: 18px;
  margin-bottom: 24px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 20px;
  align-items: center;
  position: relative;
}
.featured-label {
  position: absolute;
  top: -1px; right: 16px;
  background: var(--red);
  color: var(--white);
  font-size: 11px;
  font-weight: 900;
  padding: 4px 12px;
  border-radius: 0 0 6px 6px;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.featured-img {
  width: 100%;
  height: 180px;
  object-fit: contain;
  background: #fafafa;
  border-radius: 6px;
  padding: 10px;
}
.featured-info .deal-title { font-size: 18px; -webkit-line-clamp: 3; }
.featured-info .deal-price-now { font-size: 28px; }
.featured-info p { color: var(--gray-mid); font-size: 13px; margin: 8px 0 12px; }
.featured-actions { display: flex; gap: 10px; align-items: center; }
.countdown {
  display: flex;
  gap: 8px;
  margin: 10px 0;
}
.countdown-unit {
  text-align: center;
  background: var(--navy);
  color: var(--white);
  padding: 6px 10px;
  border-radius: 4px;
  min-width: 48px;
}
.countdown-unit strong { display: block; font-size: 18px; font-weight: 900; }
.countdown-unit small { font-size: 10px; color: #aaa; }

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--navy);
  color: #aaa;
  margin-top: 40px;
}
.footer-top {
  max-width: 1200px;
  margin: 0 auto;
  padding: 36px 16px 20px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 28px;
}
.footer-brand .logo-text { color: var(--white); font-size: 20px; margin-bottom: 10px; }
.footer-brand p { font-size: 13px; line-height: 1.7; }
.footer-socials { display: flex; gap: 10px; margin-top: 14px; }
.social-btn {
  width: 34px; height: 34px;
  background: rgba(255,255,255,.1);
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  transition: background .2s;
}
.social-btn:hover { background: var(--red); }
.footer-col h4 {
  color: var(--white);
  font-size: 13px;
  font-weight: 900;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.footer-col ul li { margin-bottom: 7px; }
.footer-col ul li a { font-size: 13px; color: #aaa; }
.footer-col ul li a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 14px 16px;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}
.footer-bottom a { color: #888; margin-left: 16px; }
.footer-bottom a:hover { color: var(--white); }

/* ============================================
   INNER PAGE HERO
   ============================================ */
.inner-hero {
  background: var(--navy);
  color: var(--white);
  padding: 32px 0;
}
.inner-hero h1 { font-size: 28px; font-weight: 900; margin-bottom: 6px; }
.inner-hero p { color: #aaa; font-size: 14px; }
.breadcrumb { font-size: 12px; color: #888; margin-bottom: 10px; }
.breadcrumb a { color: #aaa; }
.breadcrumb a:hover { color: var(--white); }

/* ============================================
   CONTENT PAGE
   ============================================ */
.content-page {
  max-width: 860px;
  margin: 32px auto;
  padding: 0 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.content-page-inner { padding: 36px; }
.content-page h2 {
  font-size: 20px;
  font-weight: 900;
  color: var(--navy);
  margin: 28px 0 10px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--gray-light);
}
.content-page h2:first-child { margin-top: 0; }
.content-page h3 { font-size: 15px; font-weight: 700; color: var(--gray-dark); margin: 16px 0 6px; }
.content-page p { font-size: 14px; color: var(--gray-mid); line-height: 1.8; margin-bottom: 12px; }
.content-page ul { padding-left: 20px; list-style: disc; margin-bottom: 12px; }
.content-page ul li { font-size: 14px; color: var(--gray-mid); line-height: 1.8; margin-bottom: 4px; }

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 28px 0;
}
.about-stat {
  background: var(--gray-light);
  border-radius: 8px;
  padding: 20px;
  text-align: center;
}
.about-stat strong {
  display: block;
  font-size: 28px;
  font-weight: 900;
  color: var(--red);
}
.about-stat span { font-size: 13px; color: var(--gray-mid); }

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 20px 0;
}
.team-card {
  background: var(--gray-light);
  border-radius: 8px;
  padding: 20px;
  text-align: center;
}
.team-avatar {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  font-size: 26px;
  font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 12px;
}
.team-card h4 { font-size: 14px; font-weight: 900; margin-bottom: 4px; }
.team-card p { font-size: 12px; color: var(--gray-mid); margin: 0; }

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 24px;
}
.contact-info-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.contact-icon {
  width: 40px; height: 40px;
  background: var(--red);
  border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.contact-info-item h4 { font-size: 14px; font-weight: 900; margin-bottom: 4px; }
.contact-info-item p { font-size: 13px; color: var(--gray-mid); margin: 0; }

.contact-form { display: flex; flex-direction: column; gap: 12px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-group { display: flex; flex-direction: column; gap: 4px; }
.form-group label { font-size: 12px; font-weight: 700; color: var(--gray-dark); }
.form-group input,
.form-group select,
.form-group textarea {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  outline: none;
  font-family: inherit;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--red); }
.form-group textarea { resize: vertical; min-height: 120px; }

/* ============================================
   LOAD MORE
   ============================================ */
.load-more-wrap { text-align: center; margin: 20px 0 40px; }
.load-more-wrap .btn {
  padding: 12px 36px;
  font-size: 14px;
  border: 2px solid var(--red);
  color: var(--red);
  background: var(--white);
}
.load-more-wrap .btn:hover { background: var(--red); color: var(--white); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 960px) {
  .page-body { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .deals-grid { grid-template-columns: repeat(2, 1fr); }
  .about-stats { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-grid { grid-template-columns: 1fr; }
  .featured-deal { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .header-inner { flex-wrap: wrap; }
  .header-actions { display: none; }
  .topbar-right { display: none; }
  .deals-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .hero-banner { flex-direction: column; text-align: center; }
  .hero-stats { justify-content: center; }
  .about-stats { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
}
