/*
Theme Name: DigitalStore
Theme URI: https://digitalproductsselling.online
Author: DigitalStore
Author URI: https://digitalproductsselling.online
Description: A professional digital products store theme with WhatsApp ordering, product categories, blog system, and all essential pages.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: digitalstore
Tags: e-commerce, blog, custom-menu, featured-images, full-width-template
*/

/* ─────────────────────────────────────────
   RESET & ROOT VARIABLES
───────────────────────────────────────── */
:root {
  --primary: #0057FF;
  --primary-light: #3d80ff;
  --primary-pale: #e8f0ff;
  --accent: #00C6AE;
  --dark: #0a0f1e;
  --text: #1a2340;
  --muted: #64748b;
  --bg: #f8faff;
  --white: #ffffff;
  --shadow: 0 4px 24px rgba(0,87,255,0.10);
  --radius: 18px;
  --wa: #25D366;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'DM Sans', sans-serif; background: var(--bg); color: var(--text); overflow-x: hidden; line-height: 1.6; }
img { max-width: 100%; height: auto; }
a { color: inherit; }

/* ─────────────────────────────────────────
   NAVBAR
───────────────────────────────────────── */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 999;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,87,255,0.08);
  box-shadow: 0 2px 20px rgba(0,87,255,0.07);
}
.header-inner {
  max-width: 1300px; margin: 0 auto;
  padding: 0 5%;
  display: flex; align-items: center; justify-content: space-between;
  height: 68px; gap: 12px;
}
.site-logo {
  font-family: 'Sora', sans-serif; font-weight: 800; font-size: 1.3rem;
  color: var(--primary); letter-spacing: -0.5px; text-decoration: none; white-space: nowrap;
}
.site-logo span { color: var(--accent); }
.main-nav ul { display: flex; gap: 4px; list-style: none; flex-wrap: wrap; }
.main-nav ul li a {
  text-decoration: none; color: var(--text); font-size: 0.85rem; font-weight: 500;
  padding: 7px 13px; border-radius: 10px; transition: all 0.2s; white-space: nowrap; display: block;
}
.main-nav ul li a:hover,
.main-nav ul li.current-menu-item > a,
.main-nav ul li.current_page_item > a {
  background: var(--primary-pale); color: var(--primary);
}
.menu-toggle {
  display: none; background: none; border: 2px solid var(--primary);
  border-radius: 8px; padding: 6px 10px; cursor: pointer; color: var(--primary); font-size: 1.1rem;
}

/* ─────────────────────────────────────────
   HERO
───────────────────────────────────────── */
.hero-section {
  min-height: 100vh; display: flex; align-items: center;
  padding: 100px 5% 60px; position: relative; overflow: hidden;
  background: var(--bg);
}
.hero-section::before {
  content: ''; position: absolute; top: -100px; right: -150px;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(0,87,255,0.12) 0%, transparent 70%);
  border-radius: 50%; animation: pulse 6s ease-in-out infinite;
}
.hero-section::after {
  content: ''; position: absolute; bottom: -80px; left: -100px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(0,198,174,0.10) 0%, transparent 70%);
  border-radius: 50%; animation: pulse 8s ease-in-out infinite reverse;
}
@keyframes pulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.08)} }
.hero-content { max-width: 660px; position: relative; z-index: 1; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--primary-pale); color: var(--primary);
  font-size: 0.78rem; font-weight: 600; padding: 6px 16px;
  border-radius: 50px; margin-bottom: 24px; letter-spacing: 0.5px;
}
.hero-badge::before { content: '✦'; font-size: 0.7rem; }
.hero-section h1 {
  font-family: 'Sora', sans-serif; font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 800; line-height: 1.1; color: var(--dark); margin-bottom: 20px;
}
.hero-section h1 em {
  font-style: normal; color: var(--primary); position: relative;
}
.hero-section h1 em::after {
  content: ''; position: absolute; bottom: 4px; left: 0; right: 0;
  height: 4px; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 2px;
}
.hero-section p.hero-desc { font-size: 1.1rem; color: var(--muted); line-height: 1.7; margin-bottom: 36px; }
.hero-btns { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 52px; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--primary); color: white; padding: 14px 28px;
  border-radius: 12px; font-weight: 600; font-size: 0.95rem;
  text-decoration: none; transition: all 0.25s;
  box-shadow: 0 6px 24px rgba(0,87,255,0.3);
}
.btn-primary:hover { background: var(--primary-light); transform: translateY(-2px); color: white; }
.btn-wa {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--wa); color: white; padding: 14px 28px;
  border-radius: 12px; font-weight: 600; font-size: 0.95rem;
  text-decoration: none; transition: all 0.25s;
  box-shadow: 0 6px 24px rgba(37,211,102,0.3);
}
.btn-wa:hover { background: #1fba58; transform: translateY(-2px); color: white; }
.hero-stats { display: flex; gap: 36px; flex-wrap: wrap; }
.stat-item { text-align: center; }
.stat-num { font-family: 'Sora', sans-serif; font-size: 1.8rem; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 0.78rem; color: var(--muted); margin-top: 2px; }

/* ─────────────────────────────────────────
   SECTION COMMONS
───────────────────────────────────────── */
.section-wrap { padding: 90px 5%; }
.section-wrap.bg-white { background: white; }
.section-wrap.bg-light { background: var(--bg); }
.container { max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 52px; }
.section-tag {
  display: inline-block; background: var(--primary-pale); color: var(--primary);
  font-size: 0.72rem; font-weight: 700; padding: 5px 14px;
  border-radius: 50px; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 12px;
}
.section-header h2 {
  font-family: 'Sora', sans-serif; font-size: clamp(1.7rem, 3vw, 2.5rem);
  font-weight: 800; color: var(--dark); margin-bottom: 10px;
}
.section-header p { color: var(--muted); font-size: 0.97rem; max-width: 520px; margin: 0 auto; }

/* ─────────────────────────────────────────
   CATEGORY TABS
───────────────────────────────────────── */
.cat-tabs { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 44px; }
.cat-tab {
  padding: 9px 20px; border-radius: 50px; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; border: 2px solid rgba(0,87,255,0.15);
  background: white; color: var(--muted); transition: all 0.2s; text-decoration: none;
}
.cat-tab:hover, .cat-tab.active {
  background: var(--primary); color: white; border-color: var(--primary);
  box-shadow: 0 4px 16px rgba(0,87,255,0.25);
}

/* ─────────────────────────────────────────
   PRODUCT CARDS
───────────────────────────────────────── */
.products-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 22px; align-items: stretch;
}
.product-card {
  background: var(--bg); border: 1.5px solid rgba(0,87,255,0.08);
  border-radius: var(--radius); padding: 24px 20px;
  transition: all 0.28s; position: relative; overflow: hidden;
  display: flex; flex-direction: column;
}
.product-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform: scaleX(0); transform-origin: left; transition: transform 0.3s;
}
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); border-color: rgba(0,87,255,0.18); }
.product-card:hover::before { transform: scaleX(1); }
.product-badge {
  position: absolute; top: 14px; right: 14px;
  background: #ff4757; color: white; font-size: 0.7rem;
  font-weight: 700; padding: 3px 9px; border-radius: 20px;
}
.product-icon {
  width: 48px; height: 48px; background: var(--primary-pale);
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; margin-bottom: 16px; flex-shrink: 0;
}
.product-cat-label { font-size: 0.72rem; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px; }
.product-card h3 { font-family: 'Sora', sans-serif; font-size: 0.98rem; font-weight: 700; color: var(--dark); margin-bottom: 8px; line-height: 1.35; }
.product-card .product-desc { color: var(--muted); font-size: 0.85rem; line-height: 1.6; margin-bottom: 18px; flex: 1; }
.product-price-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.product-price { font-family: 'Sora', sans-serif; font-size: 1.2rem; font-weight: 800; color: var(--primary); }
.product-price-old { font-size: 0.85rem; color: var(--muted); text-decoration: line-through; }
.buy-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; background: var(--wa); color: white;
  padding: 11px; border-radius: 10px; font-weight: 600; font-size: 0.85rem;
  text-decoration: none; transition: all 0.2s; margin-top: auto;
}
.buy-btn:hover { background: #1fba58; transform: translateY(-1px); color: white; }

/* ─────────────────────────────────────────
   BLOG CARDS
───────────────────────────────────────── */
.blogs-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}
.blog-card {
  background: white; border: 1.5px solid rgba(0,87,255,0.08);
  border-radius: var(--radius); overflow: hidden;
  transition: all 0.28s; display: flex; flex-direction: column; text-decoration: none;
}
.blog-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); border-color: rgba(0,87,255,0.18); }
.blog-thumb {
  width: 100%; height: 200px; overflow: hidden;
  background: linear-gradient(135deg, var(--primary-pale), #e0f5f2);
  display: flex; align-items: center; justify-content: center; font-size: 3rem;
}
.blog-thumb img { width: 100%; height: 100%; object-fit: cover; }
.blog-body { padding: 22px 20px; flex: 1; display: flex; flex-direction: column; }
.blog-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; font-size: 0.75rem; color: var(--muted); flex-wrap: wrap; }
.blog-tag { background: var(--primary-pale); color: var(--primary); padding: 3px 10px; border-radius: 20px; font-weight: 600; font-size: 0.7rem; }
.blog-card h3 { font-family: 'Sora', sans-serif; font-size: 1rem; font-weight: 700; color: var(--dark); line-height: 1.4; margin-bottom: 10px; }
.blog-card .blog-excerpt { color: var(--muted); font-size: 0.85rem; line-height: 1.65; flex: 1; margin-bottom: 18px; }
.read-more-btn {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--primary); font-weight: 600; font-size: 0.85rem;
  text-decoration: none; transition: gap 0.2s; width: fit-content;
}
.read-more-btn:hover { gap: 10px; color: var(--primary-light); }

/* ─────────────────────────────────────────
   SINGLE BLOG POST
───────────────────────────────────────── */
.single-post-wrap { max-width: 820px; margin: 0 auto; padding: 100px 5% 80px; }
.post-header { margin-bottom: 36px; }
.post-header .blog-tag { margin-bottom: 16px; display: inline-block; }
.post-header h1 { font-family: 'Sora', sans-serif; font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; color: var(--dark); line-height: 1.2; margin-bottom: 16px; }
.post-meta { display: flex; gap: 16px; color: var(--muted); font-size: 0.85rem; flex-wrap: wrap; margin-bottom: 28px; }
.post-featured-img { width: 100%; border-radius: var(--radius); margin-bottom: 36px; height: 360px; object-fit: cover; }
.post-content { font-size: 1rem; line-height: 1.85; color: var(--text); }
.post-content h2 { font-family: 'Sora', sans-serif; font-size: 1.4rem; font-weight: 700; color: var(--dark); margin: 36px 0 14px; }
.post-content h3 { font-family: 'Sora', sans-serif; font-size: 1.15rem; font-weight: 700; color: var(--dark); margin: 28px 0 10px; }
.post-content p { margin-bottom: 18px; color: var(--muted); }
.post-content ul, .post-content ol { padding-left: 24px; margin-bottom: 18px; color: var(--muted); }
.post-content li { margin-bottom: 8px; }
.post-content strong { color: var(--text); }

/* ─────────────────────────────────────────
   INNER PAGES (About, Contact, etc.)
───────────────────────────────────────── */
.page-wrap { max-width: 900px; margin: 0 auto; padding: 100px 5% 80px; }
.page-wrap h1 { font-family: 'Sora', sans-serif; font-size: 2.2rem; font-weight: 800; color: var(--dark); margin-bottom: 8px; }
.page-divider { width: 60px; height: 4px; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 2px; margin-bottom: 32px; }
.page-wrap .page-content { font-size: 0.97rem; line-height: 1.8; color: var(--muted); }
.page-wrap .page-content h2 { font-family: 'Sora', sans-serif; font-size: 1.25rem; font-weight: 700; color: var(--dark); margin: 28px 0 10px; }
.page-wrap .page-content p { margin-bottom: 16px; }
.page-wrap .page-content ul { padding-left: 20px; margin-bottom: 16px; }
.page-wrap .page-content li { margin-bottom: 8px; }
.contact-card { background: white; border: 1.5px solid rgba(0,87,255,0.1); border-radius: var(--radius); padding: 32px; margin: 24px 0; }
.contact-item { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid rgba(0,87,255,0.06); }
.contact-item:last-child { border-bottom: none; }
.contact-icon { width: 42px; height: 42px; background: var(--primary-pale); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; flex-shrink: 0; }
.contact-item strong { display: block; font-size: 0.9rem; color: var(--dark); margin-bottom: 2px; }
.contact-item span { font-size: 0.85rem; color: var(--muted); }

/* ─────────────────────────────────────────
   WHATSAPP FLOATING BUTTON
───────────────────────────────────────── */
.wa-float { position: fixed; bottom: 28px; right: 28px; z-index: 9999; display: flex; align-items: center; gap: 12px; }
.wa-float-label {
  background: white; color: var(--text); font-size: 0.82rem; font-weight: 600;
  padding: 8px 14px; border-radius: 10px; box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  opacity: 0; transform: translateX(10px); transition: all 0.3s;
  pointer-events: none; white-space: nowrap;
}
.wa-float:hover .wa-float-label { opacity: 1; transform: translateX(0); }
.wa-float-btn {
  width: 58px; height: 58px; background: var(--wa); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 24px rgba(37,211,102,0.5);
  text-decoration: none; animation: waFloat 3s ease-in-out infinite; position: relative;
}
.wa-float-btn:hover { animation: none; transform: scale(1.1); }
.wa-float-btn svg { width: 30px; height: 30px; fill: white; }
@keyframes waFloat { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-7px)} }
.wa-pulse { position: absolute; top: 0; right: 0; width: 16px; height: 16px; background: #ff4757; border-radius: 50%; border: 2px solid white; animation: ripple 2s infinite; }
@keyframes ripple { 0%{box-shadow:0 0 0 0 rgba(255,71,87,0.4)} 70%{box-shadow:0 0 0 8px rgba(255,71,87,0)} 100%{box-shadow:0 0 0 0 rgba(255,71,87,0)} }

/* ─────────────────────────────────────────
   FOOTER
───────────────────────────────────────── */
.site-footer { background: var(--dark); color: rgba(255,255,255,0.6); text-align: center; padding: 40px 5%; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; margin-bottom: 16px; }
.footer-links a { color: rgba(255,255,255,0.8); text-decoration: none; padding: 6px 12px; border-radius: 8px; font-size: 0.85rem; transition: color 0.2s; }
.footer-links a:hover { color: var(--accent); }
.footer-copy { font-size: 0.82rem; }

/* ─────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────── */
@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .main-nav { display: none; width: 100%; }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; padding: 12px 0; gap: 2px; }
  .header-inner { flex-wrap: wrap; height: auto; padding: 12px 5%; }
  .hero-btns { flex-direction: column; }
  .btn-primary, .btn-wa { justify-content: center; }
  .hero-stats { gap: 20px; }
  .products-grid { grid-template-columns: 1fr 1fr; }
  .blogs-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .products-grid { grid-template-columns: 1fr; }
}
