/**
 * ChasbShop Pro - Premium Store Design
 * Bold, Industrial, Professional, Modern
 */

/* ===== CSS Variables ===== */
:root {
    --primary: #e74c3c;
    --primary-dark: #c0392b;
    --primary-light: #ff6b81;
    --secondary: #2c3e50;
    --secondary-dark: #1a252f;
    --accent: #16213e;
    --gold: #f39c12;
    --success: #27ae60;
    --danger: #e74c3c;
    --text-dark: #1a1a2e;
    --text-gray: #4a5568;
    --text-light: #718096;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --light-gray: #edf2f7;
    --border: #e2e8f0;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 30px rgba(0,0,0,0.15);
    --shadow-xl: 0 20px 50px rgba(0,0,0,0.2);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Global Reset ===== */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: "Vazirmatn", "Vazir", "Tahoma", sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-dark);
    background-color: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: "Vazirmatn", "Vazir", "Tahoma", sans-serif;
    font-weight: 800;
    line-height: 1.3;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); }

p {
    color: var(--text-gray);
    line-height: 1.8;
    margin-bottom: 1rem;
}

/* ===== Links ===== */
a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* ===== Buttons ===== */
.wp-block-button__link,
.button,
button[type="submit"],
input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-family: "Vazirmatn", "Vazir", "Tahoma", sans-serif;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    line-height: 1;
}

.wp-block-button:not(.is-style-outline) .wp-block-button__link,
.button:not(.alt),
button[type="submit"] {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.3);
}

.wp-block-button:not(.is-style-outline) .wp-block-button__link:hover,
.button:not(.alt):hover,
button[type="submit"]:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(233, 69, 96, 0.4);
}

.wp-block-button.is-style-outline .wp-block-button__link {
    background: transparent;
    border: 2px solid var(--white);
    color: var(--white);
}

.wp-block-button.is-style-outline .wp-block-button__link:hover {
    background: var(--white);
    color: var(--secondary-dark);
}

/* ===== Hero Section ===== */
.wp-block-cover {
    position: relative;
    overflow: hidden;
}

.wp-block-cover__background {
    background: linear-gradient(135deg, var(--secondary-dark) 0%, var(--secondary) 50%, var(--accent) 100%) !important;
}

.wp-block-cover::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width=\"60\" height=\"60\" viewBox=\"0 0 60 60\" xmlns=\"http://www.w3.org/2000/svg\"%3E%3Cg fill=\"none\" fill-rule=\"evenodd\"%3E%3Cg fill=\"%23ffffff\" fill-opacity=\"0.03\"%3E%3Cpath d=\"M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z\"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
    z-index: 0;
}

.wp-block-cover__inner-container {
    position: relative;
    z-index: 1;
}

/* ===== Cards ===== */
.wp-block-group {
    transition: var(--transition);
}

.category-card,
.product-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.category-card:hover,
.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

/* ===== Features Section ===== */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.feature-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: var(--transition);
}

.feature-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* ===== Navigation ===== */
.wp-block-navigation {
    background: transparent !important;
}

.wp-block-navigation-item__content {
    font-weight: 500;
    transition: var(--transition);
}

.wp-block-navigation-item__content:hover {
    color: var(--primary) !important;
}

/* ===== Site Header ===== */
.site-header {
    background: var(--secondary-dark) !important;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
}

/* ===== Top Bar ===== */
.top-bar {
    background: linear-gradient(90deg, var(--secondary) 0%, var(--accent) 100%);
    color: var(--white);
    padding: 0.5rem 0;
    font-size: 0.875rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.top-bar a {
    color: var(--white);
    text-decoration: none;
}

.top-bar a:hover {
    color: var(--primary-light);
}

/* ===== Footer ===== */
.site-footer {
    background: linear-gradient(180deg, var(--secondary-dark) 0%, #0d1117 100%);
    color: var(--white);
    padding: 4rem 0 2rem;
}

.site-footer h3,
.site-footer h4 {
    color: var(--white);
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.site-footer a {
    color: #a0aec0;
    transition: var(--transition);
}

.site-footer a:hover {
    color: var(--primary);
    text-decoration: none;
}

.site-footer ul {
    list-style: none;
    padding: 0;
}

.site-footer li {
    margin-bottom: 0.75rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 2rem;
    margin-top: 2rem;
}

/* ===== Social Links ===== */
.wp-block-social-links {
    gap: 0.75rem !important;
}

.wp-block-social-link {
    background: rgba(255,255,255,0.1);
    border-radius: var(--radius-full);
    padding: 0.5rem;
    transition: var(--transition);
}

.wp-block-social-link:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

/* ===== WooCommerce ===== */
.woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.woocommerce ul.products li.product {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.woocommerce ul.products li.product a img {
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    margin: 0;
    transition: var(--transition);
}

.woocommerce ul.products li.product:hover a img {
    transform: scale(1.05);
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-family: "Vazirmatn", "Vazir", "Tahoma", sans-serif;
    font-weight: 700;
    font-size: 1rem;
    padding: 1rem 1rem 0.5rem;
    color: var(--text-dark);
}

.woocommerce ul.products li.product .price {
    color: var(--primary);
    font-weight: 700;
    font-size: 1.125rem;
    padding: 0 1rem;
}

.woocommerce ul.products li.product .button {
    margin: 1rem;
    width: calc(100% - 2rem);
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border-radius: var(--radius-full);
    padding: 0.875rem 1.5rem;
    font-weight: 600;
}

.woocommerce ul.products li.product .button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 69, 96, 0.35);
}

.woocommerce .onsale {
    background: var(--primary);
    color: var(--white);
    border-radius: var(--radius-full);
    font-weight: 700;
    padding: 0.5rem 1rem;
    min-height: auto;
    min-width: auto;
    line-height: 1.4;
}

/* Single Product */
.woocommerce div.product .product_title {
    font-family: "Vazirmatn", "Vazir", "Tahoma", sans-serif;
    font-weight: 800;
    font-size: 2rem;
    color: var(--text-dark);
}

.woocommerce div.product p.price {
    color: var(--primary);
    font-size: 1.75rem;
    font-weight: 700;
}

.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border-radius: var(--radius-full);
    padding: 1rem 2rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.3);
}

.woocommerce #respond input#submit:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(233, 69, 96, 0.4);
}

/* Cart */
.woocommerce table.shop_table {
    border-radius: var(--radius-md);
    overflow: hidden;
}

.woocommerce table.shop_table th {
    background: var(--secondary-dark);
    color: var(--white);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
}

/* ===== Badges ===== */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-primary {
    background: var(--primary);
    color: var(--white);
}

.badge-success {
    background: var(--success);
    color: var(--white);
}

.badge-gold {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: var(--white);
}

/* ===== Trust Section ===== */
.trust-section {
    background: linear-gradient(135deg, var(--secondary-dark) 0%, var(--secondary) 100%);
    color: var(--white);
    padding: 4rem 2rem;
    border-radius: var(--radius-xl);
    margin: 3rem 0;
}

.trust-item {
    text-align: center;
    padding: 1.5rem;
}

.trust-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.trust-title {
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--white);
    margin-bottom: 0.5rem;
}

.trust-desc {
    color: rgba(255,255,255,0.7);
    font-size: 0.875rem;
}

/* ===== CTA Section ===== */
.cta-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 4rem 2rem;
    border-radius: var(--radius-xl);
    text-align: center;
    margin: 3rem 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.cta-title {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 800;
    color: var(--white);
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.cta-desc {
    font-size: 1.125rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out forwards;
}

.animate-fadeIn {
    animation: fadeIn 0.6s ease-out forwards;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .woocommerce ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .woocommerce ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 1rem;
    }
    
    .wp-block-columns {
        flex-wrap: wrap;
    }
    
    .wp-block-column {
        flex-basis: 100% !important;
    }
    
    .trust-section,
    .cta-section {
        padding: 2rem 1rem;
        border-radius: var(--radius-md);
    }
}

@media (max-width: 480px) {
    .woocommerce ul.products {
        grid-template-columns: 1fr !important;
    }
    
    body {
        font-size: 14px;
    }
    
    .wp-block-button__link {
        width: 100%;
        text-align: center;
    }
}

/* ===== Accessibility ===== */
:focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 2px;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}