/*
Theme Name: DBStore Pro
Theme URI: https://example.com/dbstore
Author: DBStore
Author URI: https://example.com
Description: Professional database subscription sales platform WordPress theme with product management, multiple pricing options, SEO optimization and more.
Version: 1.3.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: dbstore
Tags: e-commerce, one-column, custom-menu, featured-images, theme-options, translation-ready
*/

/* ============ Base Reset ============ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
    background-color: #f9fafb;
    color: #1f2937;
    line-height: 1.6;
}

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

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

/* ============ Utilities ============ */
.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.hidden {
    display: none !important;
}

/* ============ Header Navigation ============ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e5e7eb;
}

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

.site-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.875rem;
    font-weight: 700;
}

.main-nav {
    display: flex;
    gap: 1.5rem;
}

.main-nav a {
    color: #4b5563;
    transition: color 0.2s;
}

.main-nav a:hover {
    color: #6366f1;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-secondary {
    background: white;
    border: 2px solid #e5e7eb;
    color: #374151;
}

.btn-secondary:hover {
    background: #f3f4f6;
}

.admin-link {
    color: #6b7280;
    font-size: 0.875rem;
}

.admin-link:hover {
    color: #6366f1;
}

/* Navigation Dropdown */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-trigger {
    color: #4b5563;
    cursor: pointer;
    transition: color 0.2s;
}

.nav-dropdown-trigger:hover {
    color: #6366f1;
}

.nav-dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 200px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border: 1px solid #e5e7eb;
    padding: 0.5rem 0;
    margin-top: 0.5rem;
    z-index: 100;
}

.nav-dropdown:hover .nav-dropdown-content {
    display: block;
}

.nav-dropdown-content a {
    display: block;
    padding: 0.75rem 1rem;
    color: #4b5563;
    transition: all 0.2s;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.nav-dropdown-content a:hover {
    background: #f3f4f6;
    color: #6366f1;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 700;
    border-radius: 12px;
}

/* ============ Hero Section ============ */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5rem 0;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-title span {
    display: block;
}

.hero-title .highlight {
    color: #c7d2fe;
}

.hero-desc {
    font-size: 1.125rem;
    color: #c7d2fe;
    margin-bottom: 2rem;
    max-width: 600px;
}

.hero-btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: white;
    color: #6366f1;
    font-weight: 700;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

.hero-btn:hover {
    transform: translateY(-2px);
}

/* ============ Category Navigation ============ */
.category-nav {
    margin-top: -2rem;
    position: relative;
    z-index: 10;
    padding-bottom: 1rem;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1rem;
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 0.75rem;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: all 0.2s;
}

.category-card:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.category-icon {
    font-size: 1.75rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Android Emoji", "EmojiSymbols", "EmojiOne Mozilla", sans-serif;
}

.category-name {
    font-weight: 500;
    font-size: 0.875rem;
    text-align: center;
}

/* ============ Products Section ============ */
.products-section {
    padding: 4rem 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 700;
}

.section-subtitle {
    color: #6b7280;
    margin-top: 0.25rem;
}

.section-link {
    color: #6366f1;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

/* ============ Product Card ============ */
.product-card {
    display: block;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #f1f5f9;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

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

.product-card:hover .product-title {
    color: #6366f1;
}

.product-image-wrapper {
    position: relative;
}

.product-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f1f5f9;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-image-emoji {
    position: relative;
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-emoji span {
    font-size: 4rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Android Emoji", "EmojiSymbols", "EmojiOne Mozilla", sans-serif;
}

/* Hot Badge */
.hot-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #f43f5e;
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    z-index: 5;
}

.product-info {
    padding: 1.25rem;
}

.product-title {
    font-weight: 600;
    font-size: 1.125rem;
    color: #1f2937;
    margin-bottom: 0.25rem;
    transition: color 0.3s ease;
}

.product-duration {
    color: #6b7280;
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

.product-price-wrapper {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #6366f1;
}

/* ============ Features Section ============ */
.features-section {
    background: white;
    padding: 4rem 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}

.feature-item {
    padding: 1rem;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Android Emoji", "EmojiSymbols", "EmojiOne Mozilla", sans-serif;
}

.feature-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.feature-desc {
    color: #6b7280;
    font-size: 0.875rem;
}

/* ============ Archive Layout ============ */
.archive-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
    padding: 2rem 0;
}

.archive-sidebar {
    position: sticky;
    top: 80px;
    height: fit-content;
}

.sidebar-box {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
}

.sidebar-title {
    font-weight: 700;
    margin-bottom: 1rem;
    font-size: 1rem;
}

.category-filter {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.filter-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    transition: all 0.2s;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.filter-item:hover {
    background: #f3f4f6;
}

.filter-item.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.filter-count {
    margin-left: auto;
    font-size: 0.75rem;
    color: #9ca3af;
}

.filter-item.active .filter-count {
    color: rgba(255, 255, 255, 0.8);
}

.archive-main {
    min-width: 0;
}

.products-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.search-box {
    margin-bottom: 1.5rem;
}

.search-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: #6366f1;
}

/* ============ Breadcrumb ============ */
.breadcrumb {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
}

.breadcrumb a {
    color: #6366f1;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* ============ Product Detail ============ */
.product-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    background: white;
    border-radius: 24px;
    padding: 2rem;
    border: 1px solid #e5e7eb;
}

.detail-image {
    border-radius: 16px;
    overflow: hidden;
    background: #f1f5f9;
}

.detail-image img {
    width: 100%;
    height: auto;
    display: block;
}

.detail-image-emoji {
    aspect-ratio: 1;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
}

.detail-image-emoji span {
    font-size: 8rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Android Emoji", "EmojiSymbols", "EmojiOne Mozilla", sans-serif;
}

.detail-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.detail-desc {
    color: #6b7280;
    margin-bottom: 1.5rem;
}

/* Pricing Options */
.pricing-options {
    margin-bottom: 1.5rem;
}

.pricing-label {
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.pricing-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pricing-btn {
    padding: 0.75rem 1.25rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.pricing-btn:hover {
    border-color: #6366f1;
}

.pricing-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
    color: white;
}

/* Price Display */
.price-display {
    margin-bottom: 1.5rem;
}

.current-price {
    font-size: 2.5rem;
    font-weight: 700;
    color: #6366f1;
}

.features-list {
    margin-bottom: 2rem;
}

.features-list h3 {
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.features-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.feature-check {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feature-check .check {
    color: #22c55e;
}

.action-buttons {
    display: flex;
    gap: 1rem;
}

.action-buttons .btn-primary {
    flex: 1;
    padding: 1rem 2rem;
    font-size: 1rem;
}

/* ============ Product Badges ============ */
.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #6b7280;
    font-size: 0.875rem;
}

.badge-icon {
    font-size: 1rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Android Emoji", "EmojiSymbols", "EmojiOne Mozilla", sans-serif;
}

.badge-text {
    color: #4b5563;
}

.detail-content {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.detail-content h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.detail-content .content {
    color: #4b5563;
    line-height: 1.8;
}

.detail-content .content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
}

/* ============ Footer ============ */
.site-footer {
    background: #1f2937;
    color: #9ca3af;
    padding: 2.5rem 0 3rem;
    margin-top: 3rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.footer-brand .logo-icon {
    width: 32px;
    height: 32px;
    font-size: 0.875rem;
}

.footer-desc {
    font-size: 0.875rem;
    color: #9ca3af;
    line-height: 1.6;
}

.footer-title {
    color: white;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.footer-links a {
    color: #9ca3af;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid #374151;
    margin-top: 2rem;
    padding-top: 2rem;
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
}

/* ============ Contact Modal ============ */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    max-width: 400px;
    width: 100%;
    margin: 1rem;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 700;
}

.modal-close {
    font-size: 1.5rem;
    color: #9ca3af;
    cursor: pointer;
    border: none;
    background: none;
}

.modal-desc {
    color: #6b7280;
    font-size: 0.875rem;
    margin-bottom: 1.25rem;
    line-height: 1.5;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    margin-bottom: 0.75rem;
    transition: all 0.2s;
    cursor: pointer;
}

.contact-item:hover {
    background: #f9fafb;
    border-color: #d1d5db;
}

.contact-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-icon.telegram { background: #3b82f6; }
.contact-icon.whatsapp { background: #22c55e; }
.contact-icon.wechat { background: #16a34a; }
.contact-icon.email { background: #ef4444; }

.contact-info {
    flex: 1;
}

.contact-info .label {
    font-weight: 600;
    color: #1f2937;
}

.contact-info .value {
    font-size: 0.875rem;
    color: #6b7280;
}

.contact-arrow {
    color: #9ca3af;
    font-size: 1.25rem;
}

/* ============ Responsive ============ */
@media (max-width: 1200px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1024px) {
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .main-nav {
        display: none;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .category-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .products-grid,
    .products-grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .archive-sidebar {
        display: none;
    }
    
    .product-detail {
        grid-template-columns: 1fr;
    }
    
    .features-grid-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .products-grid,
    .products-grid-3 {
        grid-template-columns: 1fr;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* ============ Price Note ============ */
.price-note {
    color: #6b7280;
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

/* ============ Service Page ============ */
.service-page-content {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.service-page-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f3f4f6;
}

.service-page-body {
    color: #4b5563;
    line-height: 1.8;
}

.service-page-body h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin: 1.5rem 0 0.75rem;
}

.service-page-body h3:first-child {
    margin-top: 0;
}

.service-page-body p {
    margin-bottom: 1rem;
}

.service-page-body ul, .service-page-body ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.service-page-body li {
    margin-bottom: 0.5rem;
}

/* Contact Methods Grid */
.contact-methods-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}

.contact-method-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    border-radius: 12px;
    color: white;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.contact-method-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.contact-method-card.telegram { background: #0088cc; }
.contact-method-card.whatsapp { background: #25D366; }
.contact-method-card.wechat { background: #07C160; }
.contact-method-card.email { background: #EA4335; }

.contact-method-icon {
    flex-shrink: 0;
}

.contact-method-info {
    flex: 1;
}

.contact-method-label {
    font-weight: 600;
    font-size: 1rem;
}

.contact-method-value {
    opacity: 0.9;
    font-size: 0.875rem;
}

@media (max-width: 768px) {
    .service-page-content {
        padding: 1.5rem;
    }
    
    .service-page-title {
        font-size: 1.5rem;
    }
    
    .contact-methods-grid {
        grid-template-columns: 1fr;
    }
}
