/* ============================================
   تاتِو — Outdoor Adventure Theme
   ============================================ */

:root {
    --forest-900: #081C15;
    --forest-800: #1B4332;
    --forest-700: #2D6A4F;
    --forest-600: #40916C;
    --forest-500: #52B788;
    --forest-100: #D8F3DC;

    --earth-800: #6B4C35;
    --earth-600: #A67C52;
    --earth-400: #D4A373;
    --earth-200: #E9D5B7;

    --stone-900: #1A1A1A;
    --stone-700: #4A4A4A;
    --stone-500: #7A7A7A;
    --stone-300: #C4C4C4;
    --stone-100: #F0EDE6;
    --stone-50: #F7F5F0;

    --white: #FFFFFF;
    --danger: #C0392B;
    --warning: #E09F3E;
    --success: #2D6A4F;

    --font: 'Vazirmatn', Tahoma, sans-serif;
    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --shadow-sm: 0 2px 8px rgba(8, 28, 21, 0.06);
    --shadow: 0 4px 20px rgba(8, 28, 21, 0.08);
    --shadow-lg: 0 12px 40px rgba(8, 28, 21, 0.12);
    --shadow-hover: 0 16px 48px rgba(8, 28, 21, 0.15);
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --header-height: 72px;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--stone-50);
    color: var(--stone-900);
    line-height: 1.75;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

main { flex: 1; }

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

.container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

a {
    color: var(--forest-700);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover { color: var(--forest-600); }

/* ---- Typography ---- */
h1, h2, h3, h4 { line-height: 1.3; font-weight: 700; color: var(--forest-900); }
.section-title {
    font-size: 1.75rem;
    text-align: center;
    margin-bottom: 12px;
}
.section-subtitle {
    text-align: center;
    color: var(--stone-500);
    margin-bottom: 48px;
    font-size: 1.05rem;
}

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-family: var(--font);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--forest-700), var(--forest-800));
    color: var(--white);
    box-shadow: 0 4px 14px rgba(45, 106, 79, 0.35);
}
.btn-primary:hover {
    background: linear-gradient(135deg, var(--forest-600), var(--forest-700));
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(45, 106, 79, 0.4);
}

.btn-accent {
    background: linear-gradient(135deg, var(--earth-400), var(--earth-600));
    color: var(--white);
    box-shadow: 0 4px 14px rgba(212, 163, 115, 0.4);
}
.btn-accent:hover { color: var(--white); transform: translateY(-2px); }

.btn-outline {
    border-color: var(--forest-700);
    color: var(--forest-700);
    background: transparent;
}
.btn-outline:hover {
    background: var(--forest-700);
    color: var(--white);
}

.btn-ghost {
    background: rgba(255,255,255,0.15);
    color: var(--white);
    border-color: rgba(255,255,255,0.4);
    backdrop-filter: blur(8px);
}
.btn-ghost:hover { background: rgba(255,255,255,0.25); color: var(--white); }

.btn-danger { background: var(--danger); color: var(--white); border: none; }
.btn-danger:hover { background: #a93226; color: var(--white); }
.btn-disabled { background: var(--stone-300); color: var(--stone-500); cursor: not-allowed; }
.btn-sm { padding: 8px 18px; font-size: 0.85rem; }
.btn-lg { padding: 16px 36px; font-size: 1.05rem; }

/* ---- Header ---- */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(8, 28, 21, 0.06);
    transition: box-shadow var(--transition);
}

.header.scrolled { box-shadow: var(--shadow); }

.header-inner {
    display: flex;
    align-items: center;
    gap: 20px;
    height: var(--header-height);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--forest-800);
    font-size: 1.5rem;
    font-weight: 800;
    flex-shrink: 0;
}
.logo:hover { color: var(--forest-700); }
.logo-svg { width: 36px; height: 36px; color: var(--forest-700); }

.nav {
    display: flex;
    gap: 4px;
}

.nav-link {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    color: var(--stone-700);
    font-weight: 500;
    font-size: 0.92rem;
    transition: all var(--transition);
}
.nav-link:hover {
    color: var(--forest-700);
    background: var(--forest-100);
}

.search-form {
    flex: 1;
    max-width: 360px;
    position: relative;
    display: flex;
    align-items: center;
}

.search-form input {
    width: 100%;
    padding: 10px 16px 10px 44px;
    border: 1.5px solid var(--stone-300);
    border-radius: 50px;
    font-family: var(--font);
    font-size: 0.9rem;
    background: var(--stone-50);
    transition: all var(--transition);
}

.search-form input:focus {
    outline: none;
    border-color: var(--forest-600);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(45, 106, 79, 0.1);
}

.search-icon {
    position: absolute;
    right: 14px;
    width: 18px;
    height: 18px;
    color: var(--stone-500);
    pointer-events: none;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.header-action-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    color: var(--stone-700);
    font-weight: 500;
    font-size: 0.9rem;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font);
    transition: all var(--transition);
    position: relative;
}
.header-action-btn svg { width: 22px; height: 22px; }
.header-action-btn:hover { background: var(--forest-100); color: var(--forest-700); }

.cart-count {
    position: absolute;
    top: 0;
    left: 0;
    background: var(--earth-400);
    color: var(--white);
    font-size: 0.7rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-menu { position: relative; }
.user-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    min-width: 180px;
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all var(--transition);
}
.user-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.user-dropdown a {
    display: block;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    color: var(--stone-700);
    font-size: 0.9rem;
}
.user-dropdown a:hover { background: var(--forest-100); color: var(--forest-700); }

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}
.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--forest-800);
    border-radius: 2px;
    transition: all var(--transition);
}

/* ---- Toast Messages ---- */
.toast-container {
    position: fixed;
    top: calc(var(--header-height) + 16px);
    left: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    font-size: 0.9rem;
    animation: slideIn 0.3s ease;
    min-width: 280px;
}

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

.toast-success { background: var(--forest-100); color: var(--forest-800); border-right: 4px solid var(--forest-600); }
.toast-error { background: #FDECEA; color: var(--danger); border-right: 4px solid var(--danger); }
.toast-warning { background: #FFF8E7; color: #856404; border-right: 4px solid var(--warning); }
.toast-info { background: #E8F4FD; color: #0c5460; border-right: 4px solid #17a2b8; }
.toast-close { background: none; border: none; font-size: 1.2rem; cursor: pointer; opacity: 0.6; margin-right: auto; }

/* ---- Hero ---- */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(160deg, var(--forest-900) 0%, var(--forest-800) 40%, var(--forest-700) 100%);
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 80%, rgba(212, 163, 115, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(82, 183, 136, 0.1) 0%, transparent 50%);
}

.hero-mountains {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    opacity: 0.15;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 80px 24px;
    max-width: 680px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 8px 18px;
    border-radius: 50px;
    color: var(--earth-200);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 24px;
}

.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    color: var(--white);
    margin-bottom: 20px;
    line-height: 1.2;
    font-weight: 800;
}

.hero p {
    font-size: 1.15rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 36px;
    line-height: 1.8;
}

.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 56px;
    padding-top: 32px;
    border-top: 1px solid rgba(255,255,255,0.15);
}

.hero-stat strong {
    display: block;
    font-size: 1.8rem;
    color: var(--earth-400);
    font-weight: 800;
}
.hero-stat span { color: rgba(255,255,255,0.6); font-size: 0.85rem; }

/* ---- Page Header ---- */
.page-header {
    position: relative;
    padding: 48px 0 40px;
    background: linear-gradient(135deg, var(--forest-900), var(--forest-800));
    overflow: hidden;
}

.page-header-bg {
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120'%3E%3Cpath fill='%23ffffff' fill-opacity='0.03' d='M0,80 L200,40 L400,70 L600,30 L800,60 L1000,20 L1200,50 L1440,10 L1440,120 L0,120Z'/%3E%3C/svg%3E") bottom center / cover no-repeat;
}

.page-header-content { position: relative; z-index: 1; }
.page-header h1 { color: var(--white); font-size: 2rem; margin-top: 8px; }
.page-header-subtitle { color: rgba(255,255,255,0.7); margin-top: 8px; font-size: 1.05rem; }

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    flex-wrap: wrap;
}
.breadcrumb a { color: rgba(255,255,255,0.6); }
.breadcrumb a:hover { color: var(--earth-400); }
.breadcrumb-sep { color: rgba(255,255,255,0.3); }
.breadcrumb-current { color: var(--earth-400); }

/* ---- Sections ---- */
.section { padding: 80px 0; }
.section-alt { background: var(--stone-100); }
.section-dark {
    background: linear-gradient(135deg, var(--forest-900), var(--forest-800));
    color: var(--white);
}
.section-dark .section-title { color: var(--white); }
.section-dark .section-subtitle { color: rgba(255,255,255,0.6); }
.section-footer { text-align: center; margin-top: 48px; }

/* ---- Category Cards ---- */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.category-card {
    position: relative;
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
    transition: all var(--transition);
    overflow: hidden;
    color: var(--stone-900);
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--forest-600), var(--earth-400));
    transform: scaleX(0);
    transition: transform var(--transition);
}

.category-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    color: var(--forest-800);
}
.category-card:hover::before { transform: scaleX(1); }

.category-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    background: linear-gradient(135deg, var(--forest-100), var(--earth-200));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.category-card h3 { font-size: 1rem; margin-bottom: 6px; }
.category-card p { font-size: 0.82rem; color: var(--stone-500); line-height: 1.6; }

/* ---- Product Cards ---- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.product-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
    transition: all var(--transition);
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
}

.product-card-link { color: inherit; display: block; }

.product-image {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--forest-100), var(--stone-100));
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img { transform: scale(1.06); }

.product-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 3.5rem;
    background: linear-gradient(135deg, var(--forest-100) 0%, var(--earth-200) 100%);
}

.product-placeholder.large { height: 420px; font-size: 5rem; border-radius: var(--radius-lg); }

.discount-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    background: linear-gradient(135deg, var(--earth-400), var(--earth-600));
    color: var(--white);
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(212, 163, 115, 0.4);
}

.product-info { padding: 20px; }
.product-brand {
    font-size: 0.78rem;
    color: var(--earth-600);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.product-info h3 {
    font-size: 0.95rem;
    margin: 8px 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price { margin-top: 12px; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.price-current { font-weight: 800; color: var(--forest-800); font-size: 1.05rem; }
.price-old { text-decoration: line-through; color: var(--stone-500); font-size: 0.82rem; }
.out-of-stock {
    display: inline-block;
    margin-top: 8px;
    padding: 3px 10px;
    background: #FDECEA;
    color: var(--danger);
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
}

.activity-badge {
    display: inline-block;
    padding: 4px 14px;
    background: var(--forest-100);
    color: var(--forest-700);
    border-radius: 50px;
    font-size: 0.82rem;
    font-weight: 600;
}

/* ---- Features ---- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 24px;
}

.feature-card {
    background: var(--white);
    padding: 36px 28px;
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
    transition: all var(--transition);
}

.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.feature-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    background: linear-gradient(135deg, var(--forest-100), var(--forest-100));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.feature-card h3 { font-size: 1rem; margin-bottom: 8px; }
.feature-card p { font-size: 0.88rem; color: var(--stone-500); }

/* ---- Shop Layout ---- */
.shop-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 32px;
    align-items: start;
}

.sidebar { position: sticky; top: calc(var(--header-height) + 24px); }

.filter-box {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
}

.filter-box h3 {
    font-size: 0.95rem;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--forest-100);
    color: var(--forest-800);
}

.filter-list { list-style: none; }
.filter-list li { margin-bottom: 4px; }
.filter-list a {
    display: block;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    color: var(--stone-700);
    font-size: 0.9rem;
    transition: all var(--transition);
}
.filter-list a:hover { background: var(--forest-100); color: var(--forest-700); }
.filter-list a.active {
    background: var(--forest-700);
    color: var(--white);
    font-weight: 600;
}

.shop-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 16px 20px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.sort-select {
    width: auto;
    padding: 8px 16px;
    border: 1.5px solid var(--stone-300);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    background: var(--stone-50);
}

/* ---- Product Detail ---- */
.product-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    margin-bottom: 64px;
}

.product-gallery {
    background: var(--white);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.product-main-image {
    width: 100%;
    border-radius: var(--radius-xl);
}

.product-detail-info {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.product-detail-info h1 { font-size: 1.6rem; margin: 12px 0 16px; }
.product-price.large { margin: 24px 0; }
.product-price.large .price-current { font-size: 1.6rem; }
.product-description { color: var(--stone-700); margin: 24px 0; line-height: 1.9; }

.product-meta {
    background: var(--stone-50);
    padding: 20px;
    border-radius: var(--radius);
    margin: 24px 0;
}
.product-meta p {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 0.9rem;
    border-bottom: 1px dashed var(--stone-300);
}
.product-meta p:last-child { border-bottom: none; }

.add-to-cart-form {
    display: flex;
    align-items: end;
    gap: 16px;
    margin-top: 28px;
    flex-wrap: wrap;
}

.quantity-input label { display: block; margin-bottom: 6px; font-weight: 500; font-size: 0.9rem; }
.quantity-input input { width: 90px; text-align: center; }

/* ---- Reviews ---- */
.reviews-section { margin: 48px 0; }
.reviews-section h2 { margin-bottom: 24px; }
.rating { color: var(--earth-400); font-size: 1.1rem; }

.review-card {
    background: var(--white);
    padding: 24px;
    border-radius: var(--radius);
    margin-bottom: 12px;
    box-shadow: var(--shadow-sm);
    border-right: 4px solid var(--forest-600);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.stars { color: var(--earth-400); letter-spacing: 2px; }

.related-products { margin-top: 64px; }
.related-products h2 { margin-bottom: 28px; }

/* ---- Blog ---- */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 28px;
}

.blog-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
    transition: all var(--transition);
}

.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.blog-card-image {
    height: 200px;
    background: linear-gradient(135deg, var(--forest-800), var(--forest-600));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

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

.blog-card-image-placeholder {
    font-size: 3rem;
    opacity: 0.3;
}

.blog-card-body { padding: 28px; }
.blog-category {
    display: inline-block;
    background: var(--forest-100);
    color: var(--forest-700);
    padding: 4px 14px;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.blog-card h2, .blog-card h3 { font-size: 1.1rem; margin-bottom: 10px; line-height: 1.5; }
.blog-card h2 a, .blog-card h3 a { color: var(--forest-900); }
.blog-card h2 a:hover, .blog-card h3 a:hover { color: var(--forest-600); }
.blog-card p { color: var(--stone-500); font-size: 0.9rem; line-height: 1.7; }
.blog-meta {
    display: flex;
    gap: 16px;
    color: var(--stone-500);
    font-size: 0.82rem;
    margin: 14px 0;
}
.read-more {
    font-weight: 600;
    color: var(--forest-700);
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.read-more:hover { gap: 8px; }

.blog-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 36px;
}
.blog-filters .btn.active {
    background: var(--forest-700);
    color: var(--white);
    border-color: var(--forest-700);
}

/* ---- Post Detail ---- */
.post-header { margin-bottom: 40px; max-width: 800px; }
.post-header h1 { font-size: 2rem; margin: 16px 0; }
.post-image {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    border-radius: var(--radius-xl);
    margin-bottom: 40px;
    box-shadow: var(--shadow);
}

.post-content {
    max-width: 760px;
    font-size: 1.05rem;
    line-height: 2;
    color: var(--stone-700);
}
.post-content p { margin-bottom: 20px; }

.related-posts { margin-top: 64px; padding-top: 48px; border-top: 2px solid var(--stone-100); }
.related-posts h2 { margin-bottom: 28px; }

/* ---- Cart ---- */
.cart-table-wrapper {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 32px;
}

.cart-table { width: 100%; border-collapse: collapse; }
.cart-table th {
    background: var(--forest-800);
    color: var(--white);
    padding: 16px 20px;
    text-align: right;
    font-size: 0.88rem;
    font-weight: 600;
}
.cart-table td {
    padding: 16px 20px;
    border-bottom: 1px solid var(--stone-100);
    font-size: 0.92rem;
}
.cart-table tfoot td {
    background: var(--stone-50);
    font-size: 1.05rem;
    border-bottom: none;
}

.cart-product-cell {
    display: flex;
    align-items: center;
    gap: 16px;
}
.cart-product-thumb {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    background: var(--forest-100);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    overflow: hidden;
}
.cart-product-thumb img { width: 100%; height: 100%; object-fit: cover; }

.qty-input { width: 70px; display: inline-block; text-align: center; }
.inline-form { display: flex; gap: 8px; align-items: center; }

.cart-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

/* ---- Checkout ---- */
.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 32px;
    align-items: start;
}

.checkout-form, .order-summary {
    background: var(--white);
    padding: 36px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.checkout-form h2, .order-summary h2 {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--forest-100);
    font-size: 1.2rem;
}

.order-summary { position: sticky; top: calc(var(--header-height) + 24px); }

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px dashed var(--stone-300);
    font-size: 0.9rem;
}
.summary-total {
    display: flex;
    justify-content: space-between;
    padding-top: 20px;
    margin-top: 8px;
    font-size: 1.15rem;
    color: var(--forest-800);
}

/* ---- Orders ---- */
.orders-list { display: flex; flex-direction: column; gap: 16px; }

.order-card {
    background: var(--white);
    padding: 28px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(8, 28, 21, 0.04);
    transition: all var(--transition);
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    gap: 20px;
}

.order-card:hover { box-shadow: var(--shadow); }

.order-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.order-card-id { font-weight: 700; color: var(--forest-800); font-size: 1.05rem; }
.order-card-date { color: var(--stone-500); font-size: 0.85rem; }
.order-card-price { font-weight: 800; color: var(--forest-800); font-size: 1.1rem; }

.status-badge {
    display: inline-block;
    padding: 5px 14px;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
}
.status-pending { background: #FFF8E7; color: #856404; }
.status-paid { background: var(--forest-100); color: var(--forest-800); }
.status-processing { background: #E8F4FD; color: #0c5460; }
.status-shipped { background: #E0F7FA; color: #006064; }
.status-delivered { background: var(--forest-100); color: var(--forest-800); }
.status-cancelled { background: #FDECEA; color: var(--danger); }

.order-detail-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 28px;
}

.order-info, .order-items {
    background: var(--white);
    padding: 32px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.order-info h2, .order-items h2 {
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--forest-100);
    font-size: 1.15rem;
}

.order-info p {
    padding: 8px 0;
    display: flex;
    justify-content: space-between;
    border-bottom: 1px dashed var(--stone-300);
    font-size: 0.92rem;
}

/* ---- Auth ---- */
.auth-page {
    min-height: calc(100vh - var(--header-height) - 200px);
    display: flex;
    align-items: center;
    padding: 60px 0;
    background:
        linear-gradient(135deg, rgba(8,28,21,0.03) 0%, transparent 50%),
        linear-gradient(225deg, rgba(45,106,79,0.05) 0%, transparent 50%);
}

.auth-form-wrapper {
    max-width: 460px;
    margin: 0 auto;
    background: var(--white);
    padding: 48px 40px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(8, 28, 21, 0.04);
}

.auth-form-wrapper h1 {
    text-align: center;
    margin-bottom: 8px;
    font-size: 1.5rem;
}
.auth-subtitle {
    text-align: center;
    color: var(--stone-500);
    margin-bottom: 32px;
    font-size: 0.9rem;
}

.auth-form .form-group { margin-bottom: 20px; }
.auth-link { text-align: center; margin-top: 24px; font-size: 0.9rem; color: var(--stone-500); }

/* ---- Forms ---- */
.form-group { margin-bottom: 18px; }
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.88rem;
    color: var(--stone-700);
}

.form-control,
.auth-form input, .auth-form textarea, .auth-form select,
.checkout-form input, .checkout-form textarea,
.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--stone-300);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.92rem;
    background: var(--stone-50);
    transition: all var(--transition);
}

.form-control:focus,
.auth-form input:focus, .auth-form textarea:focus,
.checkout-form input:focus, .checkout-form textarea:focus,
.contact-form input:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--forest-600);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(45, 106, 79, 0.1);
}

.field-error { color: var(--danger); font-size: 0.82rem; margin-top: 4px; display: block; }
.help-text { color: var(--stone-500); font-size: 0.8rem; margin-top: 4px; display: block; }

/* ---- Contact & About ---- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 32px;
}

.contact-info, .contact-form {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.contact-info h2 { margin-bottom: 28px; font-size: 1.3rem; }

.contact-item {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
    align-items: flex-start;
}

.contact-item-icon {
    width: 48px;
    height: 48px;
    background: var(--forest-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.contact-item-icon svg { width: 22px; height: 22px; color: var(--forest-700); }
.contact-item strong { display: block; margin-bottom: 4px; color: var(--forest-800); }
.contact-item p { color: var(--stone-500); font-size: 0.9rem; }

.content-page {
    max-width: 800px;
    margin: 0 auto;
    background: var(--white);
    padding: 48px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    line-height: 1.9;
}

.content-page h2 {
    margin: 32px 0 12px;
    color: var(--forest-800);
    font-size: 1.2rem;
}
.content-page p { margin-bottom: 16px; color: var(--stone-700); }
.content-page ul { padding-right: 24px; margin: 16px 0; }
.content-page li { margin-bottom: 8px; color: var(--stone-700); }

.about-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
    margin-bottom: 48px;
}

.about-image {
    height: 360px;
    background: linear-gradient(135deg, var(--forest-800), var(--forest-600));
    border-radius: var(--radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    opacity: 0.8;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
    margin-top: 48px;
}

.value-card {
    background: var(--white);
    padding: 32px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    text-align: center;
    border-top: 4px solid var(--forest-600);
}

.value-card h3 { margin-bottom: 8px; font-size: 1rem; }
.value-card p { font-size: 0.88rem; color: var(--stone-500); }

/* ---- Empty State ---- */
.empty-state {
    text-align: center;
    padding: 80px 40px;
    background: var(--white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.4;
}
.empty-state h3 { margin-bottom: 8px; font-size: 1.2rem; }
.empty-state p { color: var(--stone-500); margin-bottom: 28px; font-size: 1rem; }

.subcategory-list {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 32px;
}

/* ---- Footer ---- */
.footer { margin-top: auto; }

.footer-top {
    background: var(--forest-900);
    color: rgba(255,255,255,0.75);
    padding: 64px 0 48px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 40px;
}

.footer-logo { color: var(--white); margin-bottom: 16px; }
.footer-brand p { line-height: 1.8; font-size: 0.9rem; margin-bottom: 20px; }

.footer-social { display: flex; gap: 12px; }
.footer-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}
.footer-social a:hover { background: var(--forest-600); }
.footer-social svg { width: 18px; height: 18px; color: var(--white); }

.footer-section h4 {
    color: var(--white);
    margin-bottom: 20px;
    font-size: 1rem;
}
.footer-section ul { list-style: none; }
.footer-section li { margin-bottom: 10px; }
.footer-section a { color: rgba(255,255,255,0.65); font-size: 0.9rem; }
.footer-section a:hover { color: var(--earth-400); }

.footer-contact li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 0.88rem;
}
.footer-contact svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--earth-400); }

.footer-bottom {
    background: rgba(0,0,0,0.2);
    padding: 20px 0;
}
.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.5);
}
.footer-tagline { color: var(--earth-400); }

/* ---- Responsive ---- */
@media (max-width: 1024px) {
    .shop-layout, .checkout-layout, .order-detail-grid, .contact-grid, .about-hero {
        grid-template-columns: 1fr;
    }
    .sidebar, .order-summary { position: static; }
    .product-detail { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .mobile-menu-btn { display: flex; }

    .nav {
        position: fixed;
        top: var(--header-height);
        right: 0;
        left: 0;
        background: var(--white);
        flex-direction: column;
        padding: 16px;
        box-shadow: var(--shadow-lg);
        transform: translateY(-120%);
        opacity: 0;
        transition: all var(--transition);
        z-index: 999;
    }
    .nav.active { transform: translateY(0); opacity: 1; }
    .nav-link { padding: 12px 16px; }

    .search-form { order: 3; max-width: 100%; width: 100%; }
    .header-inner { flex-wrap: wrap; height: auto; padding: 12px 20px; }
    .header-actions { margin-right: auto; }

    .hero { min-height: 70vh; }
    .hero-stats { gap: 24px; }
    .section { padding: 56px 0; }

    .order-card { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .footer-bottom-inner { flex-direction: column; gap: 8px; text-align: center; }

    .auth-form-wrapper { padding: 32px 24px; }
    .cart-table th, .cart-table td { padding: 10px 12px; font-size: 0.82rem; }
}
