diff --git a/about.php b/about.php index 646ba772..10436039 100644 --- a/about.php +++ b/about.php @@ -30,29 +30,29 @@ require_once 'includes/header.php';

ارزش‌های ما

-
-
-
- +
    +
  • +
    +

    تعهد به کیفیت

    استفاده از بهترین مواد اولیه و کنترل کیفی دقیق در تمام مراحل تولید.

    -
-
-
- + +
  • +
    +

    هنر دست

    تمام محصولات ما با عشق و دقت توسط هنرمندان ماهر ساخته می‌شوند.

    -
  • -
    -
    - + +
  • +
    +

    طراحی ماندگار

    خلق آثاری مدرن و در عین حال کلاسیک که هیچ‌گاه از مد نمی‌افتند.

    -
  • -
    + +
    diff --git a/admin/api.php b/admin/api.php index f6e2f0e8..c58a5666 100644 --- a/admin/api.php +++ b/admin/api.php @@ -132,5 +132,120 @@ if ($action === 'get_stats') { exit; } +if ($action === 'get_reports_data') { + try { + // 1. General Stats + $stats_query = " + SELECT + (SELECT SUM(total_amount) FROM orders WHERE status = 'Delivered') as total_revenue, + (SELECT COUNT(*) FROM orders) as total_orders, + (SELECT COUNT(*) FROM users WHERE is_admin = 0) as total_users, + (SELECT COUNT(*) FROM products) as total_products + "; + $stats_stmt = $pdo->query($stats_query); + $stats = $stats_stmt->fetch(PDO::FETCH_ASSOC); + + // 2. Recent Orders + $recent_orders_query = " + SELECT o.id, o.total_amount, o.status, COALESCE(CONCAT(u.first_name, ' ', u.last_name), o.billing_name) AS customer_display_name + FROM orders o + LEFT JOIN users u ON o.user_id = u.id + ORDER BY o.created_at DESC + LIMIT 5 + "; + $recent_orders_stmt = $pdo->query($recent_orders_query); + $recent_orders = $recent_orders_stmt->fetchAll(PDO::FETCH_ASSOC); + + // 3. Top Selling Products (Calculated in PHP) + $orders_for_products_query = "SELECT items_json FROM orders WHERE status = 'Delivered'"; + $orders_for_products_stmt = $pdo->query($orders_for_products_query); + $all_orders_items = $orders_for_products_stmt->fetchAll(PDO::FETCH_ASSOC); + + $product_sales = []; + foreach ($all_orders_items as $order_items) { + $items = json_decode($order_items['items_json'], true); + if (is_array($items)) { + foreach ($items as $item) { + if (isset($item['name']) && isset($item['quantity'])) { + $product_name = $item['name']; + $quantity = (int)$item['quantity']; + if (!isset($product_sales[$product_name])) { + $product_sales[$product_name] = 0; + } + $product_sales[$product_name] += $quantity; + } + } + } + } + + arsort($product_sales); + $top_products = []; + $count = 0; + foreach ($product_sales as $name => $total_sold) { + $top_products[] = ['name' => $name, 'total_sold' => $total_sold]; + $count++; + if ($count >= 5) break; + } + + echo json_encode([ + 'stats' => [ + 'total_revenue' => (float)($stats['total_revenue'] ?? 0), + 'total_orders' => (int)($stats['total_orders'] ?? 0), + 'total_users' => (int)($stats['total_users'] ?? 0), + 'total_products' => (int)($stats['total_products'] ?? 0), + ], + 'recent_orders' => $recent_orders, + 'top_products' => $top_products + ]); + + } catch (PDOException $e) { + http_response_code(500); + error_log("API Error (get_reports_data): " . $e->getMessage()); + echo json_encode(['error' => 'Database error while fetching report data.']); + } + exit; +} + +if ($action === 'get_monthly_sales') { + require_once __DIR__ . '/../includes/jdf.php'; + try { + $stmt = $pdo->prepare(" + SELECT + YEAR(created_at) as year, + MONTH(created_at) as month, + SUM(total_amount) as total_sales + FROM orders + WHERE status = 'Delivered' + GROUP BY year, month + ORDER BY year ASC, month ASC + "); + $stmt->execute(); + $sales_data = $stmt->fetchAll(PDO::FETCH_ASSOC); + + $labels = []; + $values = []; + $jalali_months = [ + 1 => 'فروردین', 2 => 'اردیبهشت', 3 => 'خرداد', + 4 => 'تیر', 5 => 'مرداد', 6 => 'شهریور', + 7 => 'مهر', 8 => 'آبان', 9 => 'آذر', + 10 => 'دی', 11 => 'بهمن', 12 => 'اسفند' + ]; + + foreach ($sales_data as $row) { + $jalali_date = gregorian_to_jalali($row['year'], $row['month'], 1); + $labels[] = $jalali_months[(int)$jalali_date[1]] . ' ' . $jalali_date[0]; + $values[] = (float)$row['total_sales']; + } + + echo json_encode(['labels' => $labels, 'values' => $values]); + + } catch (PDOException $e) { + http_response_code(500); + error_log("API Error (get_monthly_sales): " . $e->getMessage()); + echo json_encode(['error' => 'Database error while fetching monthly sales.']); + } + exit; +} + http_response_code(400); echo json_encode(['error' => 'Invalid action']); diff --git a/admin/assets/css/admin_main.css b/admin/assets/css/admin_main.css deleted file mode 100644 index 8227edfd..00000000 --- a/admin/assets/css/admin_main.css +++ /dev/null @@ -1,347 +0,0 @@ -/* - * Admin Panel Main Stylesheet - * A clean, modern, and professional light theme. - */ - -@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700&display=swap'); -@import url('https://cdn.jsdelivr.net/npm/remixicon@4.2.0/fonts/remixicon.css'); - -:root { - --admin-bg-light: #f4f7f9; /* Light gray background */ - --admin-surface-light: #ffffff; /* White surface for cards, sidebar */ - --admin-border-light: #e0e5ec; /* Soft border color */ - --admin-text-primary: #2d3748; /* Dark text for high contrast */ - --admin-text-secondary: #718096; /* Lighter text for muted info */ - --admin-primary: #4a5568; /* A neutral, professional primary color */ - --admin-primary-active: #2d3748; - --admin-success: #38a169; - --admin-danger: #e53e3e; - --admin-warning: #dd6b20; - --admin-info: #3182ce; -} - -body.admin-theme { - background-color: var(--admin-bg-light); - color: var(--admin-text-primary); - font-family: 'Vazirmatn', sans-serif; - line-height: 1.6; - margin: 0; - padding: 0; - display: flex; - min-height: 100vh; -} - -.admin-wrapper { - display: flex; - width: 100%; -} - -/* --- Sidebar / Navigation --- */ -.admin-sidebar { - width: 250px; - background-color: var(--admin-surface-light); - border-right: 1px solid var(--admin-border-light); - padding: 1.5rem 0; - display: flex; - flex-direction: column; - transition: width 0.3s ease; - box-shadow: 0 0 20px rgba(0,0,0,0.03); -} - -.sidebar-header { - padding: 0 1.5rem 1.5rem 1.5rem; - text-align: center; - border-bottom: 1px solid var(--admin-border-light); -} - -.sidebar-header h2 a { - color: var(--admin-text-primary); - text-decoration: none; - font-size: 1.5rem; - font-weight: 700; -} - -.sidebar-header h2 a span { - color: var(--admin-primary-active); -} - -.admin-nav { - flex-grow: 1; - list-style: none; - padding: 1.5rem 0 0 0; - margin: 0; -} - -.admin-nav-item { - margin: 0 1rem; -} - -.admin-nav-link { - display: flex; - align-items: center; - gap: 0.9rem; - padding: 0.8rem 1rem; - color: var(--admin-text-secondary); - text-decoration: none; - font-weight: 600; - font-size: 0.9rem; - border-radius: 8px; - transition: all 0.3s ease; -} - -.admin-nav-link i { - font-size: 1.2rem; - width: 20px; - text-align: center; -} - -.admin-nav-link:hover { - background-color: var(--admin-bg-light); - color: var(--admin-primary-active); -} - -.admin-nav-link.active { - background-color: var(--admin-primary); - color: #ffffff; - font-weight: 700; -} - -.admin-nav-link.active:hover { - color: #ffffff; - background-color: var(--admin-primary-active); -} -.admin-nav-link.active i { - color: #ffffff; -} - -.sidebar-footer { - padding: 1.5rem; - text-align: center; - border-top: 1px solid var(--admin-border-light); -} - -.sidebar-footer a { - color: var(--admin-text-secondary); - text-decoration: none; - font-size: 0.9rem; -} -.sidebar-footer a:hover { - color: var(--admin-primary-active); -} - -/* --- Main Content --- */ -.admin-main-content { - flex-grow: 1; - padding: 2rem; - overflow-y: auto; -} - -.admin-header { - display: flex; - justify-content: space-between; - align-items: center; - margin-bottom: 2rem; -} - -.admin-header h1 { - margin: 0; - font-size: 1.8rem; - font-weight: 700; -} - -/* --- General Components --- */ -.card { - background-color: var(--admin-surface-light); - border: 1px solid var(--admin-border-light); - border-radius: 12px; - margin-bottom: 2rem; - box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03); -} - -.card-header { - padding: 1rem 1.5rem; - border-bottom: 1px solid var(--admin-border-light); - font-size: 1.1rem; - font-weight: 600; -} - -.card-body { - padding: 1.5rem; -} - -.table { - width: 100%; - border-collapse: collapse; -} - -.table th, .table td { - padding: 1rem 1.2rem; - text-align: right; - border-bottom: 1px solid var(--admin-border-light); -} - -.table th { - font-weight: 700; - color: var(--admin-text-secondary); - font-size: 0.8rem; - text-transform: uppercase; - letter-spacing: 0.5px; -} - -.table tbody tr:last-child td { - border-bottom: none; -} - -.table tbody tr:hover { - background-color: var(--admin-bg-light); -} - -.btn { - padding: 0.6rem 1.2rem; - border-radius: 8px; - text-decoration: none; - font-weight: 600; - transition: all 0.3s ease; - border: 1px solid transparent; - cursor: pointer; - display: inline-flex; - align-items: center; - gap: 0.5rem; -} - -.btn-primary { - background-color: var(--admin-primary-active); - border-color: var(--admin-primary-active); - color: #fff; -} -.btn-primary:hover { - background-color: #2c3e50; /* Slightly darker */ -} - -.btn-danger { - background-color: var(--admin-danger); - color: #fff; -} - -/* --- Stat Cards --- */ -.stat-card { - background-color: var(--admin-surface-light); - border-radius: 12px; - padding: 1.5rem; - display: flex; - align-items: center; - gap: 1.5rem; - border: 1px solid var(--admin-border-light); - box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03); -} - -.stat-card .icon { - font-size: 1.8rem; - padding: 1rem; - border-radius: 50%; - display: flex; - align-items: center; - justify-content: center; - color: #fff; -} - -.stat-card .stat-info p { - margin: 0; - font-size: 0.9rem; - color: var(--admin-text-secondary); -} - -.stat-card .stat-info h3 { - margin: 0; - font-size: 2rem; - font-weight: 700; -} - -.icon.bg-success { background-color: var(--admin-success); } -.icon.bg-danger { background-color: var(--admin-danger); } -.icon.bg-warning { background-color: var(--admin-warning); } -.icon.bg-info { background-color: var(--admin-info); } - - -/* --- Chart Container --- */ -.chart-container { - background-color: var(--admin-surface-light); - padding: 2rem; - border-radius: 12px; - border: 1px solid var(--admin-border-light); - box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03); -} - -.chart-container h5 { - font-weight: 700; - margin-bottom: 1.5rem; - font-size: 1.2rem; -} - -/* --- Form styles --- */ -.form-group { - margin-bottom: 1.5rem; -} - -.form-label { - display: block; - margin-bottom: 0.5rem; - font-weight: 600; - color: var(--admin-text-primary); -} - -.form-control { - width: 100%; - padding: 0.8rem 1rem; - background-color: var(--admin-surface-light); - border: 1px solid var(--admin-border-light); - color: var(--admin-text-primary); - border-radius: 8px; - box-sizing: border-box; - transition: border-color 0.3s ease, box-shadow 0.3s ease; -} - -.form-control:focus { - outline: none; - border-color: var(--admin-primary); - box-shadow: 0 0 0 3px rgba(74, 85, 104, 0.1); -} - -textarea.form-control { - min-height: 120px; - resize: vertical; -} - -/* Admin Login Page */ -.admin-login-wrapper { - display: flex; - align-items: center; - justify-content: center; - width: 100%; - min-height: 100vh; - background-color: var(--admin-bg-light); -} - -.admin-login-box { - width: 100%; - max-width: 400px; - padding: 3rem; - background: var(--admin-surface-light); - border-radius: 12px; - box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.07), 0 4px 6px -2px rgba(0, 0, 0, 0.04); -} - -.admin-login-box h2 { - font-weight: 700; - text-align: center; - margin-bottom: 0.5rem; -} - -.admin-login-box p { - text-align: center; - color: var(--admin-text-secondary); - margin-bottom: 2rem; -} - -/* Responsive adjustments will be added later if needed */ - diff --git a/admin/assets/css/admin_style.css b/admin/assets/css/admin_style.css index 8121f4ee..846bd302 100644 --- a/admin/assets/css/admin_style.css +++ b/admin/assets/css/admin_style.css @@ -1,348 +1,331 @@ -@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;600;700&display=swap'); -@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css'); +/* + * Admin Panel Luxury Redesign + * This file centralizes all styles for the admin panel. + */ +/* --- Variable Imports & Overrides --- +We can re-use variables from the main theme.css. Let's define some admin-specific ones. +*/ :root { - --admin-bg: #111214; - --admin-surface: #1a1b1e; - --admin-text: #eceff1; - --admin-text-muted: #90a4ae; - --admin-primary: #c09f80; /* Soft gold from luxury theme */ - --admin-border: #37474f; - --admin-success: #4caf50; - --admin-danger: #f44336; - --admin-warning: #ff9800; - --admin-info: #2196f3; + --admin-bg: #111111; /* Deep Dark */ + --admin-surface: #1a1a1a; /* Slightly lighter surface */ + --admin-card-bg: #242424; /* Card background */ + --admin-border: #333333; + --admin-text: #E0E0E0; + --admin-text-muted: #888; + --admin-gold: #e5b56e; + --admin-blue: #4a90e2; + --admin-success: #50e3c2; + --admin-danger: #e35050; + --admin-warning: #f5a623; + --admin-info: #4a90e2; + --sidebar-width: 260px; + --sidebar-width-collapsed: 80px; } -body.admin-dark-theme { +body.admin-body { background-color: var(--admin-bg); color: var(--admin-text); font-family: 'Vazirmatn', sans-serif; - line-height: 1.6; - margin: 0; - padding: 0; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +/* --- Main Layout --- */ +.admin-wrapper { display: flex; min-height: 100vh; } -.admin-wrapper { - display: flex; - width: 100%; -} - -/* --- Sidebar / Navigation --- */ .admin-sidebar { - width: 260px; + width: var(--sidebar-width); background-color: var(--admin-surface); - border-right: 1px solid var(--admin-border); - padding: 1.5rem 0; + border-left: 1px solid var(--admin-border); display: flex; flex-direction: column; transition: width 0.3s ease; + position: fixed; + top: 0; + right: 0; + bottom: 0; + z-index: 1000; } +.admin-main-content { + flex-grow: 1; + padding: 2rem; + margin-right: var(--sidebar-width); + transition: margin-right 0.3s ease; + background-color: var(--admin-bg); +} + +/* Sidebar Header */ .sidebar-header { - padding: 0 1.5rem 1.5rem 1.5rem; + padding: 1.5rem; text-align: center; border-bottom: 1px solid var(--admin-border); } - .sidebar-header h2 a { - color: var(--admin-text); - text-decoration: none; - font-size: 1.5rem; + color: var(--admin-gold); font-weight: 700; + text-decoration: none; + font-size: 1.8rem; +} +.sidebar-header h2 span { + color: var(--admin-text); } -.sidebar-header h2 a span { - color: var(--admin-primary); -} - +/* Sidebar Navigation */ .admin-nav { - flex-grow: 1; + padding: 1rem 0; list-style: none; - padding: 1.5rem 0 0 0; - margin: 0; -} - -.admin-nav-item { - margin: 0; + flex-grow: 1; } .admin-nav-link { display: flex; align-items: center; - gap: 0.8rem; - padding: 0.9rem 1.5rem; + padding: 1rem 1.5rem; color: var(--admin-text-muted); text-decoration: none; - font-weight: 600; - font-size: 0.95rem; - border-left: 4px solid transparent; transition: all 0.3s ease; + font-weight: 500; + border-right: 4px solid transparent; } .admin-nav-link i { - font-size: 1.1rem; - width: 20px; + font-size: 1.2rem; + width: 30px; text-align: center; + margin-left: 0.8rem; } .admin-nav-link:hover { background-color: var(--admin-bg); - color: var(--admin-primary); - border-left-color: var(--admin-primary); + color: var(--admin-gold); } .admin-nav-link.active { - background-color: var(--admin-bg); - color: var(--admin-text); - border-left-color: var(--admin-primary); + color: var(--admin-gold); font-weight: 700; + background-color: var(--admin-bg); + border-right-color: var(--admin-gold); } +/* Sidebar Footer */ .sidebar-footer { padding: 1.5rem; - text-align: center; border-top: 1px solid var(--admin-border); } - .sidebar-footer a { + display: block; color: var(--admin-text-muted); text-decoration: none; - font-size: 0.9rem; + margin-bottom: 0.5rem; + transition: color 0.3s ease; } .sidebar-footer a:hover { - color: var(--admin-primary); + color: var(--admin-gold); } -/* --- Main Content --- */ -.admin-main-content { - flex-grow: 1; - padding: 2rem; - overflow-y: auto; -} - -.admin-header { +/* --- Header Bar --- */ +.admin-header-bar { display: flex; justify-content: space-between; align-items: center; - margin-bottom: 2rem; -} - -.admin-header h1 { - margin: 0; - font-size: 2rem; - font-weight: 700; -} - -/* --- General Components --- */ -.card { + padding: 1rem 2rem; background-color: var(--admin-surface); - border: 1px solid var(--admin-border); - border-radius: 12px; + border-bottom: 1px solid var(--admin-border); + position: sticky; + top: 0; + z-index: 999; margin-bottom: 2rem; } -.card-header { - padding: 1rem 1.5rem; - border-bottom: 1px solid var(--admin-border); - font-size: 1.1rem; - font-weight: 600; -} - -.card-body { - padding: 1.5rem; -} - -.table { - width: 100%; - border-collapse: collapse; -} - -.table th, .table td { - padding: 1rem; - text-align: right; - border-bottom: 1px solid var(--admin-border); -} - -.table th { - font-weight: 700; - color: var(--admin-text-muted); - font-size: 0.9rem; - text-transform: uppercase; -} - -.table tbody tr:last-child td { - border-bottom: none; -} - -.table tbody tr:hover { - background-color: var(--admin-bg); -} - -.btn { - padding: 0.6rem 1.2rem; - border-radius: 8px; - text-decoration: none; - font-weight: 600; - transition: all 0.3s ease; +#sidebar-toggle { + background: none; border: none; + color: var(--admin-text); + font-size: 1.5rem; cursor: pointer; } -.btn-primary { - background-color: var(--admin-primary); - color: var(--admin-bg); -} -.btn-primary:hover { - opacity: 0.9; -} - -.btn-danger { - background-color: var(--admin-danger); +.admin-header-title h1 { + font-size: 1.5rem; + margin: 0; color: var(--admin-text); } -/* --- Stat Cards (from dashboard) --- */ -.stat-card { - background-color: var(--admin-surface); - border-radius: 12px; - padding: 1.5rem; - display: flex; - align-items: center; - gap: 1.5rem; + +/* --- Main Content Styling --- */ + +/* Cards */ +.card { + background-color: var(--admin-card-bg); border: 1px solid var(--admin-border); - transition: transform 0.3s ease, box-shadow 0.3s ease; + border-radius: 12px; + box-shadow: 0 4px 20px rgba(0,0,0,0.2); +} +.card-header { + background-color: rgba(0,0,0,0.2); + border-bottom: 1px solid var(--admin-border); + font-weight: 600; + color: var(--admin-text); } +/* Stat Cards on Dashboard */ +.stat-cards-grid { + display: grid; + grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); + gap: 1.5rem; + margin-bottom: 2rem; +} + +.stat-card { + display: flex; + align-items: center; + padding: 1.5rem; + background-color: var(--admin-card-bg); + border-radius: 12px; + border: 1px solid var(--admin-border); + transition: transform 0.3s, box-shadow 0.3s; +} .stat-card:hover { transform: translateY(-5px); - box-shadow: 0 5px 15px rgba(0,0,0,0.2); + box-shadow: 0 8px 30px rgba(0,0,0,0.3); } .stat-card .icon { font-size: 2rem; padding: 1rem; border-radius: 50%; - display: flex; - align-items: center; - justify-content: center; - color: var(--admin-text); + margin-left: 1rem; + color: #fff; } +.stat-card .icon.bg-primary { background-color: var(--admin-blue); } +.stat-card .icon.bg-warning { background-color: var(--admin-warning); } +.stat-card .icon.bg-success { background-color: var(--admin-success); } +.stat-card .icon.bg-danger { background-color: var(--admin-danger); } + .stat-card .stat-info p { margin: 0; - font-size: 0.9rem; color: var(--admin-text-muted); } - .stat-card .stat-info h3 { margin: 0; font-size: 2rem; font-weight: 700; + color: var(--admin-text); } -.icon.bg-success { background-color: var(--admin-success); } -.icon.bg-danger { background-color: var(--admin-danger); } -.icon.bg-warning { background-color: var(--admin-warning); } -.icon.bg-info { background-color: var(--admin-info); } -.icon.bg-primary { background-color: var(--admin-primary); } - - -/* --- Chart Container --- */ -.chart-container { - background-color: var(--admin-surface); - padding: 2rem; - border-radius: 12px; - border: 1px solid var(--admin-border); +/* Tables */ +.table { + border-color: var(--admin-border); } - -.chart-container h5 { - font-weight: 700; - margin-bottom: 1.5rem; - font-size: 1.2rem; -} - -/* --- Form styles --- */ -.form-group { - margin-bottom: 1.5rem; -} - -.form-label { - display: block; - margin-bottom: 0.5rem; +.table th { + color: var(--admin-gold); font-weight: 600; - color: var(--admin-text-muted); + border-bottom-width: 2px; + border-color: var(--admin-border) !important; +} +.table td { + color: var(--admin-text); + vertical-align: middle; +} +.table-hover tbody tr:hover { + background-color: var(--admin-surface); + color: var(--admin-text); } -.form-control { - width: 100%; - padding: 0.8rem 1rem; - background-color: var(--admin-bg); - border: 1px solid var(--admin-border); +/* Status Badges */ +.status-badge { + padding: 0.4em 0.8em; + border-radius: 8px; + font-size: 0.85rem; + font-weight: 600; + color: #111; +} +.status-processing, .status-badge.bg-info { background-color: var(--admin-info); } +.status-shipped, .status-badge.bg-warning { background-color: var(--admin-warning); } +.status-completed, .status-badge.bg-success { background-color: var(--admin-success); } +.status-cancelled, .status-badge.bg-danger { background-color: var(--admin-danger); } +.status-pending, .status-badge.bg-secondary { background-color: var(--admin-text-muted); color: #fff; } + + +/* Forms */ +.form-control, .form-select { + background-color: var(--admin-surface); + border-color: var(--admin-border); color: var(--admin-text); border-radius: 8px; - box-sizing: border-box; +} +.form-control:focus, .form-select:focus { + background-color: var(--admin-surface); + border-color: var(--admin-gold); + color: var(--admin-text); + box-shadow: 0 0 0 0.2rem rgba(229, 181, 110, 0.2); } -.form-control:focus { - outline: none; - border-color: var(--admin-primary); - box-shadow: 0 0 0 2px rgba(192, 159, 128, 0.2); +.btn-primary { + background-color: var(--admin-gold); + border-color: var(--admin-gold); + color: #111; + font-weight: 600; +} +.btn-primary:hover { + background-color: #d4a55a; + border-color: #d4a55a; } -textarea.form-control { - min-height: 120px; - resize: vertical; -} +/* --- Responsive & Collapsed State --- */ -/* Responsive */ @media (max-width: 992px) { .admin-sidebar { - width: 70px; + position: fixed; + top: 0; + right: -100%; + height: 100vh; + z-index: 1050; /* Above bootstrap backdrop */ + transition: right 0.4s ease; } - .sidebar-header h2 { + .admin-sidebar.open { + right: 0; + } + .admin-main-content { + margin-right: 0; + } + .sidebar-backdrop { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: rgba(0,0,0,0.5); + z-index: 1040; display: none; } - .admin-nav-link { - justify-content: center; - } - .admin-nav-link span { - display: none; + .sidebar-backdrop.show { + display: block; } } -@media (max-width: 768px) { - .admin-wrapper { - flex-direction: column; + +@media (min-width: 993px) { + .admin-wrapper.sidebar-collapsed .admin-sidebar { + width: var(--sidebar-width-collapsed); } - .admin-sidebar { - width: 100%; - height: auto; - border-right: none; - border-bottom: 1px solid var(--admin-border); - flex-direction: row; - align-items: center; - padding: 0; + .admin-wrapper.sidebar-collapsed .admin-main-content { + margin-right: var(--sidebar-width-collapsed); } - .sidebar-header { + .admin-wrapper.sidebar-collapsed .admin-sidebar .sidebar-header h2 a { + font-size: 1.5rem; + } + .admin-wrapper.sidebar-collapsed .admin-sidebar .sidebar-header h2 span, + .admin-wrapper.sidebar-collapsed .admin-sidebar .admin-nav-link span, + .admin-wrapper.sidebar-collapsed .admin-sidebar .sidebar-footer { display: none; } - .admin-nav { - display: flex; - justify-content: space-around; - flex-grow: 1; - padding: 0; + .admin-wrapper.sidebar-collapsed .admin-sidebar .admin-nav-link { + justify-content: center; } - .admin-nav-link { - border-left: none; - border-bottom: 4px solid transparent; - } - .admin-nav-link:hover, .admin-nav-link.active { - border-left-color: transparent; - border-bottom-color: var(--admin-primary); - } - .sidebar-footer { - display: none; - } -} \ No newline at end of file +} diff --git a/admin/dashboard.php b/admin/dashboard.php index fb340499..3101f34e 100644 --- a/admin/dashboard.php +++ b/admin/dashboard.php @@ -3,111 +3,88 @@ $page_title = 'داشبورد'; require_once __DIR__ . '/header.php'; ?> - - -

    -
    +
    + +
    +
    +

    گزارشات فروش

    +
    +
    +

    مجموع فروش (تکمیل شده)

    +

    ...

    +
    +
    +

    مجموع کاربران

    +

    ...

    +
    +
    +

    سفارشات در حال پردازش

    +

    ...

    +
    +
    -
    -
    -
    -
    -
    -

    مجموع فروش (تحویل شده)

    -

    ...

    +
    +
    نمودار فروش ماهانه (سفارشات تحویل شده)
    +
    + +
    -
    -
    -
    -

    مجموع کاربران

    -

    ...

    -
    -
    -
    -
    -
    -

    سفارشات در حال ارسال

    -

    ...

    -
    -
    -
    -
    -
    -

    سفارشات لغو شده

    -

    ...

    -
    -
    -
    -
    -
    -

    سفارشات در حال پردازش

    -

    ...

    -
    -
    -
    -
    -
    -

    کل بازدید صفحات

    -

    ...

    -
    +
    +

    تنظیمات

    +

    این بخش برای تنظیمات آینده در نظر گرفته شده است.

    - - -
    -
    نمودار فروش ماهانه (سفارشات تحویل شده)
    -
    diff --git a/admin/handler.php b/admin/handler.php index d484e426..4cb0231f 100644 --- a/admin/handler.php +++ b/admin/handler.php @@ -32,6 +32,46 @@ if ($action === 'update_order_status') { } } +if ($action === 'add_user') { + $first_name = filter_input(INPUT_POST, 'first_name', FILTER_SANITIZE_STRING); + $last_name = filter_input(INPUT_POST, 'last_name', FILTER_SANITIZE_STRING); + $email = filter_input(INPUT_POST, 'email', FILTER_VALIDATE_EMAIL); + $phone = filter_input(INPUT_POST, 'phone', FILTER_SANITIZE_STRING); + $password = $_POST['password'] ?? ''; + $is_admin = filter_input(INPUT_POST, 'is_admin', FILTER_VALIDATE_INT) ? 1 : 0; + + if ($first_name && $last_name && $email && !empty($password)) { + try { + $pdo = db(); + + // Check if user already exists + $stmt = $pdo->prepare("SELECT id FROM users WHERE email = ?"); + $stmt->execute([$email]); + if ($stmt->fetch()) { + $_SESSION['error_message'] = "کاربری با این ایمیل از قبل وجود دارد."; + header('Location: users.php'); + exit; + } + + // Hash password + $hashed_password = password_hash($password, PASSWORD_DEFAULT); + + // Insert user + $stmt = $pdo->prepare("INSERT INTO users (first_name, last_name, email, phone, password, is_admin, created_at) VALUES (?, ?, ?, ?, ?, ?, NOW())"); + $stmt->execute([$first_name, $last_name, $email, $phone, $hashed_password, $is_admin]); + + $_SESSION['success_message'] = "کاربر جدید با موفقیت اضافه شد."; + } catch (PDOException $e) { + error_log("Add user failed: " . $e->getMessage()); + $_SESSION['error_message'] = "خطایی در افزودن کاربر جدید رخ داد."; + } + } else { + $_SESSION['error_message'] = "اطلاعات وارد شده نامعتبر است. لطفاً تمام فیلدهای ستاره‌دار را پر کنید."; + } + header('Location: users.php'); + exit; +} + header('Location: orders.php'); exit; ?> \ No newline at end of file diff --git a/admin/header.php b/admin/header.php index afa860d8..6778182e 100644 --- a/admin/header.php +++ b/admin/header.php @@ -5,8 +5,15 @@ <?php echo isset($page_title) ? $page_title . ' - ' : ''; ?>پنل مدیریت آتیمه + + + + + + + + - @@ -15,8 +22,17 @@ - +
    - -
    \ No newline at end of file + +
    +
    + +
    +

    +
    +
    +
    \ No newline at end of file diff --git a/admin/index.php b/admin/index.php index ffad9de9..487eed8a 100644 --- a/admin/index.php +++ b/admin/index.php @@ -2,6 +2,8 @@ session_start(); require_once __DIR__ . '/auth_check.php'; require_once __DIR__ . '/../db/config.php'; + +$page_title = 'داشبورد'; require_once __DIR__ . '/header.php'; $dashboard_error = null; @@ -48,30 +50,7 @@ function get_status_badge_class($status) { } ?> - -
    -

    داشبورد اصلی

    -
    + + + + \ No newline at end of file diff --git a/admin/users.php b/admin/users.php new file mode 100644 index 00000000..e4aaa576 --- /dev/null +++ b/admin/users.php @@ -0,0 +1,136 @@ +query("SELECT id, first_name, last_name, email, phone, created_at FROM users WHERE is_admin = 0 ORDER BY created_at DESC"); + $users = $stmt->fetchAll(PDO::FETCH_ASSOC); + $user_count = count($users); +} catch (PDOException $e) { + die("Error fetching users: " . $e->getMessage()); +} +?> + +
    +

    +
    + + تعداد کل کاربران: + +
    +
    + + +
    + + +
    + + + + + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    #نامایمیلشماره تلفنتاریخ عضویت
    هیچ کاربری یافت نشد.
    +
    +
    +
    + + \ No newline at end of file diff --git a/api/get_order_details.php b/api/get_order_details.php index 9dac021f..19ea9bbf 100644 --- a/api/get_order_details.php +++ b/api/get_order_details.php @@ -1,89 +1,143 @@ $message]); + exit(); } -$response = ['success' => false, 'message' => 'Invalid request']; +if ($_SERVER['REQUEST_METHOD'] !== 'POST') { + send_error('Invalid request method.'); +} -if ($_SERVER['REQUEST_METHOD'] === 'POST') { - try { - // Read JSON from the request body - $json_data = file_get_contents('php://input'); - $data = json_decode($json_data, true); - $tracking_id = $data['tracking_id'] ?? ''; +$input_data = json_decode(file_get_contents('php://input'), true); - if (empty($tracking_id)) { - throw new Exception('کد رهگیری سفارش الزامی است.'); - } +if (!isset($input_data['tracking_id']) || empty($input_data['tracking_id'])) { + send_error('شناسه رهگیری مشخص نشده است.'); +} - $db = db(); - $stmt = $db->prepare( - "SELECT - o.*, - o.billing_name AS full_name - FROM orders o - WHERE o.tracking_id = :tracking_id" - ); - $stmt->execute([':tracking_id' => $tracking_id]); - $order = $stmt->fetch(PDO::FETCH_ASSOC); +$tracking_id = $input_data['tracking_id']; - if ($order) { - $items_json = $order['items_json']; - $items = json_decode($items_json, true); - $products = []; - - if (is_array($items)) { - $product_stmt = $db->prepare("SELECT name, price, image_url FROM products WHERE id = :product_id"); - foreach ($items as $item) { - $product_stmt->execute([':product_id' => $item['id']]); - $product_details = $product_stmt->fetch(PDO::FETCH_ASSOC); - - if ($product_details) { - $products[] = [ - 'name' => $product_details['name'], - 'price' => $product_details['price'], - 'image_url' => $product_details['image_url'], - 'quantity' => $item['quantity'], - 'color' => $item['color'] ?? null, - ]; - } - } - } - - // Format data for response - $order['created_at_jalali'] = jdate('Y/m/d H:i', strtotime($order['created_at'])); - $order['status_jalali'] = get_persian_status($order['status']); - - - $response['success'] = true; - $response['message'] = 'سفارش یافت شد.'; - $response['order'] = $order; - $response['products'] = $products; - } else { - $response['message'] = 'سفارشی با این مشخصات یافت نشد.'; - } - } catch (PDOException $e) { - error_log("Order tracking PDO error: " . $e->getMessage()); - $response['message'] = 'خطا در پایگاه داده رخ داد: ' . $e->getMessage(); - } catch (Exception $e) { - error_log("Order tracking general error: " . $e->getMessage()); - $response['message'] = $e->getMessage(); // Show the specific error message for now - } - - echo json_encode($response); +try { + $db = db(); + // 1. Fetch the order by tracking_id + $stmt = $db->prepare( + "SELECT id, billing_name, billing_email, billing_address, billing_city, billing_province, billing_postal_code, total_amount, items_json, created_at, status + FROM orders + WHERE tracking_id = :tracking_id" + ); + $stmt->bindParam(':tracking_id', $tracking_id, PDO::PARAM_STR); + $stmt->execute(); + + $order = $stmt->fetch(PDO::FETCH_ASSOC); + + if (!$order) { + send_error('سفارشی با این کد رهگیری یافت نشد.'); + } + + // 2. Decode items JSON and fetch product details + $items_from_db = json_decode($order['items_json'], true); + $products_response = []; + $product_ids = []; + + if (is_array($items_from_db)) { + foreach ($items_from_db as $item) { + if (isset($item['product_id'])) { + $product_ids[] = $item['product_id']; + } + } + } + + if (!empty($product_ids)) { + $placeholders = implode(',', array_fill(0, count($product_ids), '?')); + // Price is taken from items_json, not the products table, which is correct. + // The selected color is also in items_json. + $stmt_products = $db->prepare("SELECT id, name, image_url FROM products WHERE id IN ($placeholders)"); + $stmt_products->execute($product_ids); + $products_data = $stmt_products->fetchAll(PDO::FETCH_ASSOC); + $products_by_id = []; + foreach ($products_data as $product) { + $products_by_id[$product['id']] = $product; + } + + foreach ($items_from_db as $item) { + $product_id = $item['product_id']; + if (isset($products_by_id[$product_id])) { + $product = $products_by_id[$product_id]; + $products_response[] = [ + 'id' => $product['id'], + 'name' => $product['name'], + 'price' => number_format($item['price']) . ' تومان', + 'image_url' => $product['image_url'], + 'quantity' => $item['quantity'], + 'color' => $item['color'] ?? null // Add the selected color from the order + ]; + } + } + } + + + // 3. Format the response + $status_map = [ + 'pending' => 'در انتظار پرداخت', + 'processing' => 'در حال پردازش', + 'shipped' => 'ارسال شده', + 'completed' => 'تکمیل شده', + 'delivered' => 'تحویل شده', // Add mapping for Delivered + 'cancelled' => 'لغو شده', + 'refunded' => 'مسترد شده' + ]; + $status_persian = $status_map[strtolower($order['status'])] ?? $order['status']; + + // Robust date formatting to prevent errors + try { + // Create DateTime object to reliably parse the date from DB + $date = new DateTime($order['created_at']); + $timestamp = $date->getTimestamp(); + // Format the timestamp into Jalali date + $order_date_jalali = jdate('Y/m/d ساعت H:i', $timestamp); + } catch (Exception $e) { + // If parsing fails, log the error and return a safe value + error_log("Jalali date conversion failed for order ID {$order['id']}: " . $e->getMessage()); + $order_date_jalali = 'تاریخ نامعتبر'; + } + + $order_response = [ + 'id' => $order['id'], + 'order_date' => $order_date_jalali, + 'total_amount' => number_format($order['total_amount']) . ' تومان', + 'discount_amount' => '0 تومان', + 'status' => $order['status'], // Pass original status to JS for logic + 'status_persian' => $status_persian, // Pass Persian status for display + 'shipping_name' => $order['billing_name'], + 'shipping_address' => trim(implode(', ', array_filter([$order['billing_province'], $order['billing_city'], $order['billing_address']]))), + 'shipping_postal_code' => $order['billing_postal_code'] + ]; + + // Final JSON structure + $response = [ + 'success' => true, + 'order' => $order_response, + 'products' => $products_response + ]; + + echo json_encode($response, JSON_UNESCAPED_UNICODE); + +} catch (PDOException $e) { + error_log("API Error in get_order_details.php: " . $e->getMessage()); + send_error('خطای سرور: مشکل در ارتباط با پایگاه داده.'); +} catch (Exception $e) { + error_log("API Error in get_order_details.php: " . $e->getMessage()); + send_error('خطای سرور: یک مشکل پیش بینی نشده رخ داد.'); } + ?> \ No newline at end of file diff --git a/assets/css/custom.css b/assets/css/custom.css index 35870e74..66c6d7bf 100644 --- a/assets/css/custom.css +++ b/assets/css/custom.css @@ -1,3 +1,333 @@ -.empty-cart-container .btn-checkout i { - color: inherit !important; +/* Resetting styles for the new theme. */ + +.about-us-list { + width: 80vw; + display: grid; + list-style: none; + padding: 0; + grid-template-columns: repeat(3, 1fr); + justify-items: center; + margin: 0 auto; + gap: 20px; +} + +.about-us-item { + width: 20vw; + min-width: 200px; + border-radius: 20px; + text-align: center; + border: 1px solid #ebebeb; +} + +.inner { + position: relative; + inset: 0px; + overflow: hidden; + transition: inherit; +} + +.inner::before { + content: ""; + position: absolute; + inset: 0; + background: linear-gradient(-65deg, #0000 40%, #fff7 50%, #0000 70%); + background-size: 200% 100%; + background-repeat: no-repeat; + animation: thing 1.5s ease infinite; + border-radius: 20px; +} + +@keyframes thing { + 0% { + background-position: 130%; + opacity: 1; + } + to { + background-position: -166%; + opacity: 0; + } +} + +@media (max-width: 768px) { + .about-us-list { + grid-template-columns: 1fr; + } + .about-us-item { + width: 80%; + } +} + +/* --- Order Tracking Modal Styles --- */ + +.tracking-modal-container { + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: 1050; + display: flex; + align-items: center; + justify-content: center; + opacity: 0; + visibility: hidden; + transition: opacity 0.3s ease, visibility 0.3s ease; +} + +.tracking-modal-container.visible { + opacity: 1; + visibility: visible; +} + +.modal-overlay { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-color: rgba(0, 0, 0, 0.6); + backdrop-filter: blur(5px); + -webkit-backdrop-filter: blur(5px); +} + +.modal-content { + position: relative; + background-color: #2c2c2c; + color: #f0f0f0; + border-radius: 15px; + width: 90%; + max-width: 800px; + max-height: 90vh; + overflow-y: auto; + box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3); + border: 1px solid rgba(255, 255, 255, 0.1); + transform: scale(0.95); + transition: transform 0.3s ease; +} + +.tracking-modal-container.visible .modal-content { + transform: scale(1); +} + +.modal-header { + display: flex; + justify-content: space-between; + align-items: center; + padding: 1.5rem; + border-bottom: 1px solid rgba(255, 255, 255, 0.1); +} + +.modal-header h3 { + margin: 0; + font-size: 1.5rem; + font-weight: 500; +} + +#modal-order-id { + font-weight: bold; + color: var(--bs-primary); +} + +.modal-close-btn { + background: none; + border: none; + color: #f0f0f0; + font-size: 2rem; + line-height: 1; + cursor: pointer; + opacity: 0.7; + transition: opacity 0.2s; +} + +.modal-close-btn:hover { + opacity: 1; +} + +.modal-body { + padding: 1.5rem; + display: grid; + gap: 2rem; +} + +.order-summary, +.shipping-details, +.products-list, +.status-details { + background-color: rgba(255, 255, 255, 0.05); + padding: 1.5rem; + border-radius: 10px; +} + +.order-summary { + display: grid; + grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); + gap: 1rem; +} + +.modal-body h4 { + margin-top: 0; + margin-bottom: 1rem; + font-weight: 500; + border-bottom: 1px solid rgba(255, 255, 255, 0.1); + padding-bottom: 0.5rem; +} + +.detail-item { + font-size: 0.95rem; +} + +.detail-item strong { + color: #a0a0a0; + margin-left: 8px; +} + +/* --- Status Tracker --- */ +.status-tracker { + position: relative; + display: flex; + justify-content: space-between; + padding: 20px 0; + margin-top: 20px; +} + +.status-tracker::before { + content: ''; + position: absolute; + top: 50%; + transform: translateY(-50%); + right: 0; + width: calc(100% - 40px); + margin: 0 20px; + height: 4px; + background-color: #444; + z-index: 1; +} + +.status-progress { + position: absolute; + top: 50%; + transform: translateY(-50%); + right: 20px; + height: 4px; + background-color: var(--bs-primary); + z-index: 2; + transition: width 0.5s ease; +} + +.status-step { + position: relative; + z-index: 3; + text-align: center; + width: 100px; +} + +.status-step .dot { + width: 20px; + height: 20px; + border-radius: 50%; + background-color: #444; + border: 3px solid #2c2c2c; + margin: 0 auto; + transform: translateY(-8px); + transition: background-color 0.5s ease; +} + +.status-step .label { + display: block; + margin-top: 10px; + font-size: 0.8rem; + color: #a0a0a0; + transition: color 0.5s ease; +} + +/* State Styling */ +.status-step.completed .dot { + background-color: var(--bs-primary); +} + +.status-step.active .dot { + background-color: #fff; + box-shadow: 0 0 10px var(--bs-primary); +} + +.status-step.completed .label { + color: #f0f0f0; + font-weight: 500; +} + +.status-tracker.is-cancelled ~ .status-step:not([data-status="cancelled"]) { + opacity: 0.3; +} +.status-tracker.is-cancelled .status-step[data-status="cancelled"] .dot { + background-color: var(--bs-danger); +} +.status-tracker.is-cancelled .status-step[data-status="cancelled"] .label { + color: var(--bs-danger); + font-weight: bold; +} + + +/* --- Products List --- */ +#modal-products-list { + display: flex; + flex-direction: column; + gap: 1rem; +} + +.product-item { + display: flex; + align-items: center; + gap: 1rem; + background: rgba(255, 255, 255, 0.05); + padding: 10px; + border-radius: 8px; +} + +.product-item img { + width: 60px; + height: 60px; + object-fit: cover; + border-radius: 6px; +} + +.product-info { + flex-grow: 1; +} + +.product-name { + display: block; + font-weight: 500; +} + +.product-quantity { + font-size: 0.9rem; + color: #a0a0a0; +} + +.product-price { + font-weight: bold; +} + +/* --- Product Color Dot --- */ +.product-meta { + display: flex; + align-items: center; + gap: 1rem; + font-size: 0.9rem; + color: #a0a0a0; + margin-top: 4px; +} + +.product-color-wrapper { + display: inline-flex; + align-items: center; + gap: 0.5rem; +} + +.product-color-dot { + width: 16px; + height: 16px; + border-radius: 50%; + border: 1px solid rgba(255, 255, 255, 0.2); + display: inline-block; } \ No newline at end of file diff --git a/assets/css/dark_luxury.css b/assets/css/dark_luxury.css deleted file mode 100644 index 9e54d23e..00000000 --- a/assets/css/dark_luxury.css +++ /dev/null @@ -1,2276 +0,0 @@ -@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;600;700&display=swap'); - -:root { - --luxury-bg: #111214; - --luxury-surface: #1a1b1e; - --luxury-text: #eceff1; - --luxury-text-muted: #90a4ae; - --luxury-primary: #c09f80; /* A soft gold for a touch of luxury */ - --luxury-border: #37474f; -} - -body.dark-luxury { - background-color: var(--luxury-bg); - color: var(--luxury-text); - font-family: 'Vazirmatn', sans-serif; - line-height: 1.8; -} - -.dark-luxury h1, .dark-luxury h2, .dark-luxury h3, .dark-luxury h4, .dark-luxury h5, .dark-luxury h6 { - color: var(--luxury-text); - font-weight: 600; -} - -.dark-luxury .text-muted { - color: var(--luxury-text-muted) !important; -} - -.dark-luxury a { - color: var(--luxury-text); - text-decoration: none; - transition: color 0.3s ease; -} - -.dark-luxury a:hover { - color: var(--luxury-primary); -} - -.dark-luxury .section-title h1 { - font-size: 3rem; - font-weight: 700; - position: relative; - display: inline-block; - padding-bottom: 0.5rem; -} - -.dark-luxury .section-title h1::after { - content: ''; - position: absolute; - bottom: 0; - left: 50%; - transform: translateX(-50%); - width: 60px; - height: 3px; - background-color: var(--luxury-primary); -} - -.dark-luxury .contact-card, .dark-luxury .about-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - transition: transform 0.3s ease, box-shadow 0.3s ease; -} - -.dark-luxury .contact-card:hover, .dark-luxury .about-card:hover { - transform: translateY(-5px); - box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2); -} - -.dark-luxury .form-control { - background-color: var(--luxury-bg); - border: 1px solid var(--luxury-border); - color: var(--luxury-text); - border-radius: 8px; - padding: 0.8rem 1rem; -} - -.dark-luxury .form-control:focus { - background-color: var(--luxury-bg); - color: var(--luxury-text); - border-color: var(--luxury-primary); - box-shadow: 0 0 0 0.2rem rgba(192, 159, 128, 0.25); -} - -.dark-luxury .form-label { - font-weight: 600; - color: var(--luxury-text-muted); -} - -.dark-luxury .btn-primary { - background-color: var(--luxury-primary); - border-color: var(--luxury-primary); - color: #111214; - font-weight: 700; - padding: 0.8rem 2rem; - border-radius: 50px; - transition: all 0.3s ease; -} - -.dark-luxury .btn-primary:hover { - background-color: #d4b090; - border-color: #d4b090; - transform: translateY(-2px); - box-shadow: 0 4px 15px rgba(192, 159, 128, 0.2); -} - -.dark-luxury .contact-info i { - color: var(--luxury-primary); - font-size: 1.5rem; -} - -.dark-luxury .contact-info a { - color: var(--luxury-text); - text-decoration: none; - transition: color 0.3s ease; -} - -.dark-luxury .contact-info a:hover { - color: var(--luxury-primary); -} - -.dark-luxury .about-image { - border-radius: 15px; - object-fit: cover; -} - -.dark-luxury .values-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 10px; - padding: 2rem; -} - -.dark-luxury .values-card i { - font-size: 2.5rem; - color: var(--luxury-primary); -} - -/* Product Grid Styles */ -.dark-luxury .product-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - overflow: hidden; - display: flex; - flex-direction: column; - transition: transform 0.3s ease, box-shadow 0.3s ease; -} - -.dark-luxury .product-card:hover { - transform: translateY(-5px); - box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2); -} - -.dark-luxury .product-image { - width: 100%; - aspect-ratio: 3 / 4; /* Enforce 3:4 aspect ratio */ - overflow: hidden; -} - -.dark-luxury .product-image img { - width: 100%; - height: 100%; - object-fit: cover; /* Crop image to fit, don't distort */ - transition: transform 0.4s ease; -} - -.dark-luxury .product-card:hover .product-image img { - transform: scale(1.05); -} - -.dark-luxury .product-info { - padding: 1.25rem; - flex-grow: 1; - display: flex; - flex-direction: column; - justify-content: center; -} - -.dark-luxury .product-title { - font-size: 1.1rem; - font-weight: 600; - margin-bottom: 0.5rem; -} - -.dark-luxury .product-title a { - color: var(--luxury-text); -} - -.dark-luxury .product-title a:hover { - color: var(--luxury-primary); -} - -.dark-luxury .product-price { - font-size: 1.2rem; - font-weight: 700; - color: var(--luxury-primary); - margin-bottom: 0; -} - -/* Cart Page Styles */ -.dark-luxury .cart-page-wrapper { - padding: 4rem 0; -} - -.dark-luxury .empty-cart-container { - text-align: center; - background-color: var(--luxury-surface); - padding: 4rem 2rem; - border-radius: 20px; - border: 1px solid var(--luxury-border); -} - -.dark-luxury .empty-cart-container i { - font-size: 5rem; - color: var(--luxury-primary); - margin-bottom: 1.5rem; - display: block; -} - -.dark-luxury .empty-cart-container h2 { - font-size: 2.5rem; - font-weight: 700; - margin-bottom: 1rem; -} - -.dark-luxury .empty-cart-container p { - color: var(--luxury-text-muted); - font-size: 1.1rem; - max-width: 450px; - margin: 0 auto 2rem auto; -} - -.dark-luxury .cart-item-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - padding: 1.5rem; - margin-bottom: 1.5rem; - position: relative; -} - -.dark-luxury .remove-item-btn { - position: absolute; - top: 10px; - left: 10px; -} - -.dark-luxury .remove-item-btn .btn i { - font-size: 1.5rem; - color: var(--luxury-text-muted); - transition: color 0.3s ease; -} - -.dark-luxury .remove-item-btn .btn:hover i { - color: #ef5350; /* A soft red for delete */ -} - -.dark-luxury .cart-item-image img { - border-radius: 10px; - width: 100%; - height: auto; - object-fit: cover; -} - -.dark-luxury .cart-item-details h5 a { - font-weight: 600; - font-size: 1.1rem; - color: var(--luxury-text); -} -.dark-luxury .cart-item-details h5 a:hover { - color: var(--luxury-primary); -} - -.dark-luxury .cart-item-color-swatch { - display: inline-block; - width: 20px; - height: 20px; - border-radius: 50%; - border: 1px solid var(--luxury-border); - vertical-align: middle; -} - -.dark-luxury .quantity-selector { - display: flex; - align-items: center; - background-color: var(--luxury-bg); - border: 1px solid var(--luxury-border); - border-radius: 50px; - max-width: 120px; - justify-content: space-between; -} - -.dark-luxury .quantity-selector .btn { - color: var(--luxury-text); - font-size: 1.2rem; - padding: 0.2rem 0.8rem; -} - -.dark-luxury .quantity-selector .btn:disabled { - opacity: 0.5; -} - -.dark-luxury .quantity-selector .quantity-input { - background: transparent; - border: none; - color: var(--luxury-text); - text-align: center; - width: 40px; - font-weight: 700; - padding: 0; -} - -.dark-luxury .item-price { - font-size: 1.2rem; - font-weight: 700; - color: var(--luxury-text); -} - -.dark-luxury .order-summary-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - padding: 2rem; - position: sticky; - top: 120px; -} - -.dark-luxury .order-summary-card .card-title { - font-size: 1.8rem; - font-weight: 700; - margin-bottom: 2rem; - text-align: center; - border-bottom: 1px solid var(--luxury-border); - padding-bottom: 1rem; -} - -.dark-luxury .order-summary-card .summary-item { - display: flex; - justify-content: space-between; - margin-bottom: 1rem; - font-size: 1.1rem; -} - -.dark-luxury .order-summary-card .summary-item .label { - color: var(--luxury-text-muted); -} - -.dark-luxury .order-summary-card .summary-item .value { - font-weight: 600; -} - -.dark-luxury .order-summary-card .summary-total { - border-top: 1px solid var(--luxury-border); - padding-top: 1.5rem; - margin-top: 1.5rem; -} -.dark-luxury .order-summary-card .summary-total .label, -.dark-luxury .order-summary-card .summary-total .value { - font-size: 1.3rem; - font-weight: 700; - color: var(--luxury-primary); -} - -/* - * SweetAlert2 Dark Theme Customizations - * Moved from product.php for global use - */ -body.swal2-shown > [aria-hidden="true"] { - filter: blur(5px); - transition: filter 0.3s ease-out; -} -.swal2-popup.dark-theme-popup { - background-color: #2a2a2e !important; - border-radius: 20px; -} -.swal2-title.dark-theme-title { - color: #e8e6e3 !important; -} -.swal2-html-container.dark-theme-content { - color: #b0b0b0 !important; -} -.swal2-confirm.dark-theme-button { - background-color: var(--luxury-primary) !important; - border-radius: 10px; - padding: .6em 2em; - box-shadow: none !important; - transition: background-color 0.2s; -} - .swal2-confirm.dark-theme-button:hover { - background-color: #c89c6c !important; /* A slightly lighter shade of primary for hover */ -} - -/* Toast Styles */ -.swal2-toast.dark-theme-toast { - background-color: #2a2a2e !important; - color: #e8e6e3 !important; - border-radius: 10px; - box-shadow: 0 4px 15px rgba(0,0,0,0.2); -} -.swal2-toast.dark-theme-toast .swal2-title { - color: #e8e6e3 !important; - font-size: 1em; -} -.swal2-toast.dark-theme-toast .swal2-timer-progress-bar { - background-color: var(--luxury-primary); -} - - -/* - * Single Product Page Styles - */ -.product-image-gallery .img-fluid { - border-radius: 20px !important; - border: 1px solid var(--luxury-border); -} - -.dark-luxury .color-swatches { - display: flex; - flex-wrap: wrap; - gap: 0.75rem; - align-items: center; -} - -.dark-luxury .color-swatches .btn { - width: 32px; - height: 32px; - border-radius: 50%; - border: 2px solid var(--luxury-border); - padding: 0; - transition: all 0.3s ease; - cursor: pointer; - box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); -} - -.dark-luxury .color-swatches .btn:hover { - transform: scale(1.1); - border-color: var(--luxury-text-muted); -} - -.dark-luxury .color-swatches .btn-check:checked + .btn { - border-color: var(--luxury-primary); - transform: scale(1.1); - box-shadow: 0 0 0 3px var(--luxury-primary); - outline: none; -} - -.dark-luxury .form-control.quantity-input { - background-color: var(--luxury-surface); - max-width: 120px; - text-align: center; - font-size: 1.2rem; - font-weight: 700; - border-width: 1px; - padding: 0.5rem; -} - -.dark-luxury .add-to-cart-btn .btn { - width: 100%; - padding: 1rem; - font-size: 1.1rem; - display: flex; - align-items: center; - justify-content: center; - gap: 0.75rem; - border-radius: 10px; -} - -/* - * Contact Page Styles - */ -.dark-luxury .contact-info .social-btn { - width: 42px; - height: 42px; - display: inline-flex; - align-items: center; - justify-content: center; - border-radius: 50%; - color: var(--luxury-text-muted); - border-color: var(--luxury-border); - transition: all 0.3s ease; - font-size: 1.2rem; -} - -.dark-luxury .contact-info .social-btn:hover { - background-color: var(--luxury-primary); - border-color: var(--luxury-primary); - color: var(--luxury-bg); - transform: translateY(-3px); -} - -/* Header Navbar Toggler */ -.dark-luxury .navbar-toggler { - border-color: var(--luxury-border); -} - -.dark-luxury .navbar-toggler:focus { - box-shadow: 0 0 0 0.25rem rgba(192, 159, 128, 0.25); -} - -.dark-luxury .navbar-toggler-icon { - background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(236, 239, 241, 0.8)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e"); -} - -/* - * Checkout Page Styles - */ - -.dark-luxury .checkout-page-wrapper { - padding: 4rem 0; -} - -.dark-luxury .checkout-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - margin-bottom: 1.5rem; -} - -.dark-luxury .checkout-card .card-header { - background-color: transparent; - border-bottom: 1px solid var(--luxury-border); - padding: 1.5rem; - font-size: 1.25rem; - font-weight: 600; -} - -.dark-luxury .checkout-card .card-body { - padding: 1.5rem; -} - -.dark-luxury .form-select { - background-color: var(--luxury-bg); - border: 1px solid var(--luxury-border); - color: var(--luxury-text); - border-radius: 8px; - padding: 0.8rem 1rem; - background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2390a4ae' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e"); -} - -.dark-luxury .form-select:focus { - background-color: var(--luxury-bg); - color: var(--luxury-text); - border-color: var(--luxury-primary); - box-shadow: 0 0 0 0.2rem rgba(192, 159, 128, 0.25); -} - -.dark-luxury .checkout-order-summary .summary-item-list { - list-style: none; - padding: 0; -} - -.dark-luxury .checkout-order-summary .summary-item-list li { - display: flex; - justify-content: space-between; - align-items: center; - padding: 0.75rem 0; - border-bottom: 1px solid var(--luxury-border); -} -.dark-luxury .checkout-order-summary .summary-item-list li:last-child { - border-bottom: none; -} - -.dark-luxury .checkout-order-summary .product-name { - font-weight: 600; -} - -.dark-luxury .checkout-order-summary .product-total { - font-weight: 600; - color: var(--luxury-text); -} - -.dark-luxury .checkout-order-summary .summary-totals { - border-top: 2px solid var(--luxury-border); - margin-top: 1rem; - padding-top: 1rem; -} - -.dark-luxury .checkout-order-summary .summary-totals .total-row { - display: flex; - justify-content: space-between; - font-size: 1.1rem; - margin-bottom: 0.5rem; -} - -.dark-luxury .checkout-order-summary .summary-totals .grand-total { - font-size: 1.4rem; - font-weight: 700; - color: var(--luxury-primary); -} - -/* - * Profile Page Styles - */ - -.dark-luxury .profile-container { - display: flex; - align-items: flex-start; - gap: 30px; -} - -.dark-luxury .profile-sidebar { - flex: 0 0 280px; - background-color: var(--luxury-surface); - border-radius: 15px; - border: 1px solid var(--luxury-border); - padding: 20px; - position: sticky; - top: 120px; -} - -.dark-luxury .profile-content { - flex: 1; -} - -.dark-luxury .user-card { - text-align: center; - padding: 20px 10px; - border-bottom: 1px solid var(--luxury-border); - margin-bottom: 20px; -} - -.dark-luxury .user-card .user-avatar { - width: 90px; - height: 90px; - border-radius: 50%; - background-color: var(--luxury-primary); - color: var(--luxury-bg); - display: flex; - align-items: center; - justify-content: center; - font-size: 2.5rem; - margin: 0 auto 15px auto; - font-weight: 700; -} - -.dark-luxury .user-card h5 { - font-weight: 600; - margin-bottom: 5px; - color: var(--luxury-text); -} - -.dark-luxury .user-card p { - color: var(--luxury-text-muted); - font-size: 0.9rem; -} - -.dark-luxury .profile-nav .nav-link { - display: flex; - align-items: center; - gap: 12px; - padding: 12px 15px; - border-radius: 10px; - color: var(--luxury-text-muted); - font-weight: 500; - transition: all 0.3s ease; - margin-bottom: 5px; -} - -.dark-luxury .profile-nav .nav-link i { - font-size: 1.3rem; - transition: all 0.3s ease; -} - -.dark-luxury .profile-nav .nav-link.active, -.dark-luxury .profile-nav .nav-link:hover { - background-color: var(--luxury-primary); - color: var(--luxury-bg); -} - -.dark-luxury .profile-nav .nav-link.active i, -.dark-luxury .profile-nav .nav-link:hover i { - color: var(--luxury-bg); -} - -.dark-luxury .tab-pane h3 { - font-weight: 700; - margin-bottom: 25px; - color: var(--luxury-text); - border-bottom: 1px solid var(--luxury-border); - padding-bottom: 1rem; -} - -.dark-luxury .order-accordion .accordion-item { - border: 1px solid var(--luxury-border); - border-radius: 15px !important; - margin-bottom: 20px; - background-color: var(--luxury-surface); - overflow: hidden; -} - -.dark-luxury .order-accordion .accordion-button { - border-radius: 0 !important; - background-color: var(--luxury-surface); - box-shadow: none; - padding: 20px; - color: var(--luxury-text); -} - -.dark-luxury .order-accordion .accordion-button:not(.collapsed) { - border-bottom: 1px solid var(--luxury-border); - background-color: var(--luxury-bg); -} - -.dark-luxury .order-accordion .accordion-button::after { - filter: brightness(0) invert(1); -} - -.dark-luxury .order-header { - display: flex; - justify-content: space-between; - width: 100%; - align-items: center; -} - -.dark-luxury .order-header-item { - flex: 1; - text-align: right; -} - -.dark-luxury .order-header-item:first-child { text-align: right; } - -.dark-luxury .order-header-item span { - display: block; - font-size: 0.8rem; - color: var(--luxury-text-muted); -} - -.dark-luxury .order-header-item strong { - font-weight: 600; - color: var(--luxury-text); - font-size: 1rem; -} - -.dark-luxury .order-status { - padding: 5px 12px; - border-radius: 20px; - font-weight: 500; - color: #fff; - font-size: 0.8rem; - text-shadow: 1px 1px 3px rgba(0,0,0,0.2); -} - -.dark-luxury .order-status.status-pending { background-color: #ffc107; color: #000; } -.dark-luxury .order-status.status-processing { background-color: #0dcaf0; color: #000; } -.dark-luxury .order-status.status-shipped { background-color: #0d6efd; } -.dark-luxury .order-status.status-completed { background-color: #198754; } -.dark-luxury .order-status.status-cancelled { background-color: #dc3545; } - - -.dark-luxury .order-details-table { - margin-top: 15px; -} - -.dark-luxury .order-details-table img { - width: 60px; - height: 60px; - object-fit: cover; - border-radius: 10px; -} - -.dark-luxury .order-details-table td { - vertical-align: middle; - border-color: var(--luxury-border); - color: var(--luxury-text-muted); -} -.dark-luxury .order-details-table tr:last-child td { - border-bottom: none; -} - -.dark-luxury .order-details-table .product-name-column { - - font-weight: 600; - - color: var(--luxury-text); - -} - -/* - * New Dashboard Styles - */ - -.dark-luxury .dashboard-title { - font-weight: 700; - margin-bottom: 0.5rem; -} - -.dark-luxury .dashboard-welcome { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - padding: 2rem; - margin-bottom: 2rem; -} - -.dark-luxury .dashboard-welcome p { - color: var(--luxury-text-muted); - margin-bottom: 0; - font-size: 1.1rem; -} - -.dark-luxury .summary-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - padding: 1.5rem; - display: flex; - align-items: center; - gap: 1.5rem; - transition: all 0.3s ease; -} - -.dark-luxury .summary-card:hover { - transform: translateY(-5px); - box-shadow: 0 8px 20px rgba(0,0,0,0.2); - border-color: var(--luxury-primary); -} - -.dark-luxury .summary-card i { - font-size: 2.5rem; - color: var(--luxury-primary); -} - -.dark-luxury .summary-card-info span { - display: block; - color: var(--luxury-text-muted); - font-size: 0.9rem; - margin-bottom: 0.25rem; -} - -.dark-luxury .summary-card-info strong { - font-size: 1.5rem; - font-weight: 700; - color: var(--luxury-text); -} - -.dark-luxury .dashboard-card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 15px; - overflow: hidden; -} - -.dark-luxury .dashboard-card-header { - padding: 1.5rem; - border-bottom: 1px solid var(--luxury-border); - font-size: 1.25rem; - font-weight: 600; - margin: 0; -} - -.dark-luxury .dashboard-card-body { - padding: 1.5rem; -} - -.dark-luxury .modern-table { - width: 100%; - border-collapse: collapse; -} - -.dark-luxury .modern-table th { - text-align: right; - padding: 1rem 1.5rem; - font-weight: 600; - color: var(--luxury-text-muted); - border-bottom: 2px solid var(--luxury-border); - font-size: 0.9rem; - text-transform: uppercase; -} - -.dark-luxury .modern-table td { - text-align: right; - padding: 1rem 1.5rem; - vertical-align: middle; - border-bottom: 1px solid var(--luxury-border); - color: var(--luxury-text); -} - -.dark-luxury .modern-table tbody tr:last-child td { - border-bottom: none; -} - -.dark-luxury .modern-table tbody tr:hover { - background-color: var(--luxury-bg); -} - -.dark-luxury .btn-outline-primary { - border-color: var(--luxury-primary); - color: var(--luxury-primary); -} - -.dark-luxury .btn-outline-primary:hover { - background-color: var(--luxury-primary); - color: var(--luxury-bg); -} - - -/* - - - - * Index Page - Hero Section - - - - */ - - - -.dark-luxury .hero-section { - - - - position: relative; - - - - overflow: hidden; - - - -} - - - - - - - -.dark-luxury .video-background-wrapper { - - - - position: absolute; - - - - top: 0; - - - - left: 0; - - - - width: 100%; - - - - height: 100%; - - - - z-index: 0; - - - -} - - - - - - - -.dark-luxury .video-overlay { - - - - position: absolute; - - - - top: 0; - - - - left: 0; - - - - width: 100%; - - - - height: 100%; - - - - background: rgba(0, 0, 0, 0.5); - - - - z-index: 1; - - - -} - - - - - - - -.dark-luxury .video-background-wrapper video { - - - - min-width: 100%; - - - - min-height: 100%; - - - - width: auto; - - - - height: auto; - - - - position: absolute; - - - - top: 50%; - - - - left: 50%; - - - - transform: translate(-50%, -50%); - - - - object-fit: cover; - - - - opacity: 0.5; - - - -} - - - - - - - -.dark-luxury .hero-title { - - - - font-weight: 700; - - - - color: #fff; - - - - text-shadow: 2px 2px 8px rgba(0,0,0,0.6); - - - -} - - - - - - - -.dark-luxury .hero-subtitle { - - - - color: rgba(255,255,255,0.85); - - - - text-shadow: 1px 1px 4px rgba(0,0,0,0.5); - - - -} - - - - - - - -#about-us { - - - - background-color: var(--luxury-bg); - - - -} - - - - - - - -#about-us h1 { - - - - color: var(--luxury-text); - - - -} - - - - - - - -#about-us p { - - - - color: var(--luxury-text-muted) !important; - - - -} - - - - - - - -.dark-luxury #about-us .about-us-image { - - - - border-radius: 15px; - - - - object-fit: cover; - - - - box-shadow: 0 10px 30px rgba(0,0,0,0.2); - - - -} - -/* - - * Track Order Page Styles - - */ - -.dark-luxury .track-container { - - max-width: 600px; - - margin: 5rem auto; - - background-color: var(--luxury-surface); - - padding: 3rem; - - border-radius: 15px; - - border: 1px solid var(--luxury-border); - - text-align: center; - -} - - - -.dark-luxury .track-container h1 { - - margin-bottom: 1rem; - -} - - - -.dark-luxury .track-container p { - - color: var(--luxury-text-muted); - - margin-bottom: 2rem; - -} - - - -.dark-luxury #track-order-form .form-control { - - text-align: center; - - margin-bottom: 1rem; - -} - - - -/* Track Order Modal */ - -.dark-luxury .order-modal { - - display: none; /* Hidden by default */ - - position: fixed; /* Stay in place */ - - z-index: 1060; /* Sit on top */ - - left: 0; - - top: 0; - - width: 100%; /* Full width */ - - height: 100%; /* Full height */ - - overflow: auto; /* Enable scroll if needed */ - - background-color: rgba(0,0,0,0.7); /* Black w/ opacity */ - - backdrop-filter: blur(5px); - -} - - - -.dark-luxury .order-modal-content { - - background-color: var(--luxury-surface); - - margin: 10% auto; /* 10% from the top and centered */ - - padding: 30px; - - border: 1px solid var(--luxury-border); - - border-radius: 20px; - - width: 80%; /* Could be more or less, depending on screen size */ - - max-width: 800px; - - position: relative; - - animation: fadeIn 0.3s; - -} - - - -@keyframes fadeIn { - - from {opacity: 0; transform: scale(0.95);} - - to {opacity: 1; transform: scale(1);} - -} - - - -.dark-luxury .order-modal-close-btn { - - color: var(--luxury-text-muted); - - position: absolute; - - top: 15px; - - left: 25px; - - font-size: 28px; - - font-weight: bold; - - transition: color 0.3s ease; - -} - - - -.dark-luxury .order-modal-close-btn:hover, - -.dark-luxury .order-modal-close-btn:focus { - - color: var(--luxury-text); - - text-decoration: none; - - cursor: pointer; - -} - - - -.dark-luxury .order-modal-header { - - text-align: center; - - border-bottom: 1px solid var(--luxury-border); - - padding-bottom: 1rem; - - margin-bottom: 1.5rem; - -} - - - -.dark-luxury .order-modal-header h2 { - - font-size: 1.8rem; - - color: var(--luxury-primary); - -} - - - -.dark-luxury .order-details-grid { - - display: grid; - - grid-template-columns: 1fr 1fr; - - gap: 1.5rem; - - margin-bottom: 1.5rem; - -} - - - -.dark-luxury .detail-box h3 { - - font-size: 1.2rem; - - font-weight: 600; - - color: var(--luxury-text); - - border-bottom: 1px solid var(--luxury-border); - - padding-bottom: 0.5rem; - margin-bottom: 1rem; - -} - - - -.dark-luxury .detail-box p { - - margin-bottom: 0.5rem; - - font-size: 0.95rem; - -} - - - -.dark-luxury .products-table { - - width: 100%; - - border-collapse: collapse; - -} - - - -.dark-luxury .products-table th, .dark-luxury .products-table td { - - padding: 0.75rem; - - text-align: right; - - border-bottom: 1px solid var(--luxury-border); - -} - - - -.dark-luxury .products-table th { - - font-weight: 600; - - font-size: 0.9rem; - - color: var(--luxury-text-muted); - -} - - - -.dark-luxury .products-table img { - - width: 45px; - - height: 45px; - - border-radius: 8px; - - margin-left: 10px; - - vertical-align: middle; - -} - -/* -Auth Pages - Dark Luxury Theme -*/ - -.auth-wrapper { - display: flex; - min-height: 100vh; - width: 100%; -} - -.auth-bg { - flex: 1; - background: url('https://images.pexels.com/photos/244133/pexels-photo-244133.jpeg?auto=compress&cs=tinysrgb&w=1260&h=750&dpr=2') no-repeat center center; - background-size: cover; - position: relative; - display: none; /* Hidden on small screens */ -} - -@media (min-width: 992px) { - .auth-bg { - display: flex; - align-items: center; - justify-content: center; - } -} - -.auth-bg::before { - content: ''; - position: absolute; - top: 0; - left: 0; - right: 0; - bottom: 0; - background: rgba(17, 18, 20, 0.7); - z-index: 1; -} - -.auth-bg-content { - position: relative; - z-index: 2; - text-align: center; - padding: 40px; - max-width: 450px; - color: var(--luxury-text); -} - -.auth-bg-content h1 { - font-size: 3rem; - font-weight: 700; - margin-bottom: 1rem; - text-shadow: 1px 1px 15px rgba(0,0,0,0.5); -} - -.auth-bg-content p { - font-size: 1.1rem; - line-height: 1.7; - color: var(--luxury-text-muted); -} - -.auth-form-wrapper { - flex-grow: 1; /* Take up all space on mobile */ - display: flex; - align-items: center; - justify-content: center; - padding: 30px; - background-color: var(--luxury-surface); -} - -@media (min-width: 992px) { - .auth-form-wrapper { - flex: 0 0 500px; /* Fixed width on larger screens */ - flex-grow: 0; - } -} - -.auth-form-container { - max-width: 400px; - width: 100%; -} - -.auth-form-container .form-header .logo { - font-size: 2rem; - font-weight: 700; - color: var(--luxury-primary); - margin-bottom: 1rem; - text-align: center; -} - -.auth-form-container .form-header h2 { - font-size: 1.8rem; - font-weight: 600; - color: var(--luxury-text); - margin-bottom: 0.5rem; - text-align: center; -} - -.auth-form-container .form-header p { - color: var(--luxury-text-muted); - margin-bottom: 2.5rem; - text-align: center; -} - -.auth-wrapper .form-group { - position: relative; - margin-bottom: 1.5rem; -} - -.auth-form-wrapper .form-control { - height: 52px; - padding: 0 20px; - font-size: 0.95rem; -} - - -.auth-form-wrapper .btn-primary { - height: 50px; - font-size: 1rem; -} - -.auth-footer { - text-align: center; - margin-top: 2rem; - font-size: 0.9rem; -} - -.auth-footer a { - color: var(--luxury-primary); - font-weight: 600; -} - -.auth-footer a:hover { - text-decoration: underline; -} - -.dark-luxury .alert-danger { - background-color: rgba(220, 53, 69, 0.1); - border-color: rgba(220, 53, 69, 0.3); - color: #f8d7da; -} - -.dark-luxury .alert-success { - background-color: rgba(25, 135, 84, 0.1); - border-color: rgba(25, 135, 84, 0.3); - color: #d1e7dd; -} - -.dark-luxury .alert-secondary { - background-color: rgba(144, 164, 174, 0.1); - border-color: rgba(144, 164, 174, 0.3); - color: #cfd8dc; -} - - - -.dark-luxury .otp-input { - - font-size: 1.5rem; - - letter-spacing: 0.5rem; - - text-align: center; - - font-weight: 700; - -} - - - - -/* General Responsive Styles */ - - - - - - - -/* On extra small screens, make the body text a bit smaller */ - - - - -@media (max-width: 575.98px) { - - - - - body { - - - - - font-size: 0.95rem; - - - - - } - - - - - .display-3 { - - - - - font-size: 2.8rem; - - - - - } - - - - - .display-4 { - - - - - font-size: 2.3rem; - - - - - } - - - - -} - - - - - - - - - - - - - - - -/* --- Header --- */ - - - - -@media (max-width: 991.98px) { - .dark-luxury .profile-container { - flex-direction: column; - } - - .dark-luxury .profile-sidebar { - position: static; - width: 100%; - margin-bottom: 2rem; - } - - - - - .dark-luxury .navbar-collapse { - - - - - background-color: var(--luxury-surface); - - - - - padding: 1.5rem; - - - - - border-radius: 15px; - - - - - margin-top: 1rem; - - - - - border: 1px solid var(--luxury-border); - - - - - box-shadow: 0 10px 25px rgba(0,0,0,0.3); - - - - - } - - - - - - - - .dark-luxury .navbar-nav .nav-item:not(:last-child) { - - - - - margin-bottom: 0.5rem; - - - - - } - - - - - - - - .dark-luxury .navbar-nav .nav-link { - - - - - padding: 0.5rem 0; - - - - - } - - - - - - - - .dark-luxury .navbar-collapse .d-flex { - - - - - margin-top: 1.5rem; - - - - - padding-top: 1.5rem; - - - - - border-top: 1px solid var(--luxury-border); - - - - - justify-content: center !important; /* Center the icons/buttons */ - - - - - } - - - - - - - - - - .dark-luxury .site-header { - - - - - background-color: rgba(17, 18, 20, 0.85); - - - - - backdrop-filter: blur(10px); - - - - - } - - - - -} - - - - - - - - - - - - - - - -/* --- Footer --- */ - - - - -@media (max-width: 767.98px) { - - - - - .dark-luxury .site-footer .row > div { - - - - - text-align: center; - - - - - margin-bottom: 2.5rem; /* Add more space between stacked columns */ - - - - - } - - - - - - - - .dark-luxury .site-footer .list-unstyled { - - - - - padding-right: 0; /* Remove default padding for RTL */ - - - - - text-align: center; - - - - - } - - - - - - - - - - .dark-luxury .site-footer .social-icons { - - - - - justify-content: center !important; - - - - - } - - - - - - - - - - .dark-luxury .site-footer .d-flex.align-items-center { - - - - - justify-content: center; - - - - - } - - - - -} - - - - - - - - - - - - - - - -/* --- Homepage Specific --- */ - - - - - - - -@media (max-width: 767.98px) { - - - - - - - - - - - - - - .dark-luxury .hero-section { - - - - - - - - - - - - - - min-height: 60vh; /* Reduce height on mobile */ - - - - - - - - - - - - - - height: auto; - - - - - - - - - - - - - - } - - - - - - - - - - - - - - .dark-luxury .hero-title { - - - - - - - - - - - - - - font-size: 2.5rem; - - - - - - - - - - - - - - } - - - - - - - - - - - - - - .dark-luxury .hero-subtitle { - - - - - - - - - - - - - - font-size: 1.1rem; - - - - - - - - - - - - - - } - - - - -} -.dark-luxury #about-us .text-md-end { - - - - - - - - text-align: center !important; - - - - - - - - } - -/* --- Profile Page Responsive --- */ - -@media (max-width: 991.98px) { - .dark-luxury .profile-container { - flex-direction: column; - } - - .dark-luxury .profile-sidebar { - flex: 0 0 auto; - width: 100%; - position: static; - margin-bottom: 30px; - } -} - -@media (max-width: 767.98px) { - .dark-luxury .order-header { - flex-direction: column; - align-items: flex-start; - gap: 15px; - } - - .dark-luxury .order-header-item { - text-align: right !important; - width: 100%; - } - - .dark-luxury .order-accordion .accordion-button { - padding: 15px; - } - - .dark-luxury .order-details-table .product-name-column { - max-width: 150px; - white-space: normal; - } -} - -@media (max-width: 575.98px) { - .dark-luxury .user-card { - padding: 15px 5px; - } - .dark-luxury .profile-nav .nav-link { - padding: 10px; - gap: 10px; - font-size: 0.9rem; - } - .dark-luxury .order-header-item strong { - font-size: 0.9rem; - } - .dark-luxury .order-header-item span { - font-size: 0.75rem; - } -} - - - - - -} - -/* - * FAQ Page - Accordion Styles - */ -.dark-luxury .accordion-item { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - border-radius: 10px !important; /* Use important to override bootstrap defaults */ - margin-bottom: 1rem; - overflow: hidden; /* Ensures the child elements adhere to the border radius */ -} - -.dark-luxury .accordion-header { - border-bottom: none; -} - -.dark-luxury .accordion-button { - background-color: var(--luxury-surface); - color: var(--luxury-text); - font-weight: 600; - padding: 1.5rem; - border-radius: 0; - box-shadow: none; /* Remove default focus shadow */ - transition: background-color 0.3s ease; -} - -.dark-luxury .accordion-button:not(.collapsed) { - background-color: var(--luxury-bg); - color: var(--luxury-primary); - border-bottom: 1px solid var(--luxury-border); -} - -.dark-luxury .accordion-button:focus { - box-shadow: 0 0 0 0.2rem rgba(192, 159, 128, 0.25); /* Custom focus ring */ -} - -/* Style the accordion icon (chevron) */ -.dark-luxury .accordion-button::after { - background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2390a4ae'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e"); - transition: transform 0.3s ease; -} - -.dark-luxury .accordion-button:not(.collapsed)::after { - background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23c09f80'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e"); -} - -.dark-luxury .accordion-body { - padding: 1.5rem; - color: var(--luxury-text-muted); - line-height: 1.8; -} - -/* Generic Card Style for static pages (e.g., Terms) */ -.dark-luxury main .card { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); - color: var(--luxury-text-muted); /* Fixing text color */ -} - -.dark-luxury main .card .card-body, -.dark-luxury main .card .card-text { - color: var(--luxury-text-muted); /* Ensuring all text within the card is readable */ -} - -.dark-luxury main .card .card-title, -.dark-luxury main .card h1, -.dark-luxury main .card h2, -.dark-luxury main .card h3, -.dark-luxury main .card h4, -.dark-luxury main .card h5, -.dark-luxury main .card h6 { - color: var(--luxury-text); /* Making titles more prominent */ -} - -/* Restore accordion styles to prevent conflicts */ -.dark-luxury .accordion-item { - background-color: var(--luxury-surface); - border: 1px solid var(--luxury-border); -} -.dark-luxury .accordion-button { - background-color: var(--luxury-surface); - color: var(--luxury-text); -} -.dark-luxury .accordion-button:not(.collapsed) { - background-color: var(--luxury-bg); - color: var(--luxury-primary); -} -.dark-luxury .accordion-body { - color: var(--luxury-text-muted); -} diff --git a/assets/css/theme.css b/assets/css/theme.css new file mode 100644 index 00000000..09681a2b --- /dev/null +++ b/assets/css/theme.css @@ -0,0 +1,325 @@ +/* + * Dark & Luxury Theme + * Palette: Black, Gray, Custom Blue + * Font: Vazirmatn + */ + +@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css'); + +:root { + /* Color Palette */ + --color-dark-bg: #111111; /* پس‌زمینه اصلی (مشکی) */ + --color-surface: #1f2326; /* پس‌زمینه بخش‌ها (خاکستری تیره‌تر) */ + --color-card-bg: #2a2f34; /* پس‌زمینه کارت‌ها */ + --color-border: #333333; /* رنگ جداکننده‌ها و حاشیه‌ها */ + --color-gold: #e5b56e; /* رنگ شاخص (طلایی سفارشی) */ + --color-gold-hover: #e9bc7e; /* رنگ هاور طلایی سفارشی */ + + /* Text Colors */ + --color-text-primary: #F5F5F5; /* متن اصلی (سفید دودی) */ + --color-text-secondary: #E0E0E0; /* متن ثانویه (خاکستری روشن) */ + + /* Bootstrap Overrides */ + --bs-body-bg: var(--color-dark-bg); + --bs-body-color: var(--color-text-primary); + --bs-border-color: var(--color-border); + --bs-primary: var(--color-gold); + --bs-primary-rgb: 229, 181, 110; + + /* Spacing */ + --section-padding-lg: 6rem; + --section-padding-md: 4rem; +} + +/* --- Base & Typography --- */ +body { + font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; + background-color: var(--bs-body-bg); + color: var(--bs-body-color); + direction: rtl; + text-align: right; + line-height: 1.8; + font-weight: 400; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +html { + scroll-behavior: smooth; +} + +h1, h2, h3, h4, h5, h6 { + font-weight: 700; /* فونت ضخیم‌تر برای عناوین */ + color: var(--color-text-primary); +} + +a { + color: var(--color-gold); + text-decoration: none; + transition: color 0.3s ease; +} + +a:hover { + color: var(--color-gold-hover); +} + +/* --- Layout & Spacing --- */ + +.section-padding { + padding-top: var(--section-padding-md); + padding-bottom: var(--section-padding-md); +} + +@media (min-width: 992px) { + .section-padding { + padding-top: var(--section-padding-lg); + padding-bottom: var(--section-padding-lg); + } +} + +.section-title { + position: relative; + padding-bottom: 15px; +} + +.section-title::after { + content: ''; + position: absolute; + display: block; + width: 60px; + height: 3px; + background: var(--color-gold); + bottom: 0; + left: 50%; + transform: translateX(-50%); +} + +/* For right-aligned titles */ +.text-md-end .section-title::after, +.text-end .section-title::after { + left: auto; + right: 0; + transform: none; +} + + +/* --- Page Specific --- */ + +/* Hero Section */ +.hero-section .hero-title { + font-weight: 800; + text-shadow: 0 2px 20px rgba(0,0,0,0.6); +} + +.hero-section .hero-subtitle { + text-shadow: 0 2px 15px rgba(0,0,0,0.5); + font-weight: 300; + letter-spacing: 0.5px; +} + +/* About Us Section */ +.about-us-image { + border-radius: 12px; + box-shadow: 0 15px 40px rgba(0,0,0,0.4); + transition: transform 0.4s ease; +} +.about-us-image:hover { + transform: scale(1.03); +} + + +/* --- General Components --- */ + +.card { + background-color: var(--color-card-bg); + border: 1px solid rgba(255, 255, 255, 0.05); + border-radius: 15px; /* کمی گردتر */ + box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4); + transition: all 0.4s ease; + overflow: hidden; +} + +.card:hover { + transform: translateY(-8px); + box-shadow: 0 12px 45px rgba(0, 0, 0, 0.5); + border-color: rgba(var(--bs-primary-rgb), 0.5); +} + +.card.card-static:hover { + transform: none; + box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4); /* Keep original shadow */ + border-color: rgba(255, 255, 255, 0.05); /* Keep original border */ +} + + + +.card-header, .card-footer { + background-color: rgba(0,0,0,0.1); + border-bottom: 1px solid var(--color-border); +} + +.btn-primary { + background-color: var(--color-gold); + border-color: var(--color-gold); + color: #111; /* رنگ متن تیره برای کنتراست روی دکمه طلایی */ + font-weight: 600; + padding: 10px 25px; + border-radius: 8px; + transition: all 0.3s ease; +} + +.btn-primary:hover, .btn-primary:focus { + background-color: var(--color-gold-hover); + border-color: var(--color-gold-hover); + color: #000; + transform: translateY(-2px); + box-shadow: 0 4px 15px rgba(218, 165, 32, 0.2); +} + +.form-control { + background-color: var(--color-surface); + border-color: var(--color-border); + color: var(--color-text-primary); + border-radius: 8px; +} + +.form-control:focus { + background-color: var(--color-surface); + border-color: var(--color-gold); + color: var(--color-text-primary); + box-shadow: 0 0 0 0.25rem rgba(var(--bs-primary-rgb), 0.25); +} + +.form-control::placeholder { + color: var(--color-text-secondary); + opacity: 0.7; +} + +/* --- Utilities --- */ +.text-gold { + color: var(--color-gold) !important; +} + +.text-muted { + color: #bbbbbb !important; +} + +.bg-surface { + background-color: var(--color-surface) !important; +} + +/* --- Header --- */ +.site-header { + background-color: rgba(17, 17, 17, 0.85); + backdrop-filter: blur(10px); + -webkit-backdrop-filter: blur(10px); + border-bottom: 1px solid transparent; + transition: border-color 0.3s ease; +} + +.site-header.header-scrolled { + border-color: var(--color-border); +} + +.site-header .navbar-brand { + color: var(--color-gold); +} + +.site-header .nav-link { + color: var(--color-text-secondary); + transition: color 0.3s ease; +} + +.site-header .nav-link:hover, .site-header .nav-link.active { + color: var(--color-gold); +} + +.navbar-toggler { + border-color: rgba(var(--bs-primary-rgb), 0.5) !important; +} + +.navbar-toggler-icon { + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(229, 181, 110, 1)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important; +} + + +/* --- Product Card --- */ +.product-card { + /* This class is a specific implementation of the .card component. */ + /* It inherits border, background, shadow, etc. from .card */ + padding: 0; /* Remove card-body padding if any is added globally */ +} + +/* The hover effect for product-card is slightly different, so we override the transform */ +.product-card:hover { + transform: translateY(-8px); /* Keep the slightly larger lift */ +} + +.product-card .product-image { + aspect-ratio: 3 / 4; + overflow: hidden; +} + +.product-card .product-image img { + width: 100%; + height: 100%; + object-fit: cover; /* پوشش کامل کادر بدون تغییر نسبت */ + transition: transform 0.5s ease; +} + +.product-card:hover .product-image img { + transform: scale(1.08); /* افکت زوم روی هاور */ +} + +.product-card .product-info { + padding: 1.5rem 0.5rem; +} + +.product-card .product-title a { + font-size: 1.1rem; + font-weight: 600; + color: var(--color-text-primary); + text-decoration: none; +} + +.product-card .product-price { + color: var(--color-gold); + font-size: 1.2rem; + font-weight: 700; + margin-top: 0.5rem; +} + +/* --- Footer --- */ +.site-footer { + background-color: var(--color-surface); + border-top: 1px solid var(--color-border); +} + +.site-footer h5 { + color: var(--color-gold); +} + +.site-footer p, +.site-footer .text-white-50 { + color: var(--color-text-secondary) !important; +} + +.site-footer a, +.site-footer a.text-white-50 { + color: var(--color-text-secondary) !important; + transition: color 0.3s ease; +} + +.site-footer a:hover { + color: var(--color-gold) !important; +} + +.site-footer .social-icon { + font-size: 1.5rem; + color: var(--color-text-secondary); + transition: color 0.3s ease; +} + +.site-footer .social-icon:hover { + color: var(--color-gold); +} diff --git a/assets/js/main.js b/assets/js/main.js index fa0b40e5..4c105e38 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -1,11 +1,30 @@ -// Custom JavaScript will go here - document.addEventListener('DOMContentLoaded', () => { - // --- AOS Initialization --- + // Initialize AOS (Animate on Scroll) AOS.init({ - duration: 800, - once: true, + duration: 800, // Animation duration in ms + offset: 100, // Offset (in px) from the original trigger point + once: true, // Whether animation should happen only once - while scrolling down }); -}); + // Add a class to the header when the page is scrolled + const header = document.querySelector('.site-header'); + if (header) { + const scrollThreshold = 50; // Pixels to scroll before adding the class + + const handleScroll = () => { + if (window.scrollY > scrollThreshold) { + header.classList.add('header-scrolled'); + } else { + header.classList.remove('header-scrolled'); + } + }; + + // Listen for the scroll event + window.addEventListener('scroll', handleScroll); + + // Initial check in case the page is already scrolled on load + handleScroll(); + } + +}); \ No newline at end of file diff --git a/assets/pasted-20251207-145857-9f50f97d.png b/assets/pasted-20251207-145857-9f50f97d.png new file mode 100644 index 00000000..efb5b39e Binary files /dev/null and b/assets/pasted-20251207-145857-9f50f97d.png differ diff --git a/assets/pasted-20251207-191805-ff2e9ada.png b/assets/pasted-20251207-191805-ff2e9ada.png new file mode 100644 index 00000000..92dfeec0 Binary files /dev/null and b/assets/pasted-20251207-191805-ff2e9ada.png differ diff --git a/cart.php b/cart.php index dd5c8867..e8122973 100644 --- a/cart.php +++ b/cart.php @@ -7,98 +7,105 @@ $cart_items = $_SESSION['cart'] ?? []; $total_price = 0; ?> -
    -
    +
    +
    +
    - -
    - -

    سبد خرید شما خالی است

    -

    به نظر می‌رسد هنوز محصولی به سبد خرید خود اضافه نکرده‌اید. همین حالا گشتی در فروشگاه بزنید.

    - - - رفتن به فروشگاه - -
    - -
    -

    سبد خرید شما

    -

    جزئیات سفارش خود را بررسی و نهایی کنید.

    -
    -
    -
    - $item): - $item_total = $item['price'] * $item['quantity']; - $total_price += $item_total; - ?> -
    -
    -
    - - - - -
    -
    -
    -
    - - <?php echo htmlspecialchars($item['name']); ?> - -
    -
    -
    - -
    - رنگ: - -
    - -
    -
    -
    + +
    +
    + +
    +

    سبد خرید شما خالی است

    +

    به نظر می‌رسد هنوز محصولی به سبد خرید خود اضافه نکرده‌اید. همین حالا گشتی در فروشگاه بزنید.

    + +
    + +
    +

    سبد خرید شما

    +

    جزئیات سفارش خود را بررسی و نهایی کنید.

    +
    + +
    +
    + $item): + $item_total = $item['price'] * $item['quantity']; + $total_price += $item_total; + ?> +
    +
    + - - - - - + +
    -
    - تومان +
    +
    + + <?php echo htmlspecialchars($item['name']); ?> + +
    +
    +
    + +
    + رنگ: + +
    + +
    +
    +
    + + + + + + + +
    +
    +
    + تومان +
    -
    - -
    + +
    -
    -
    -

    خلاصه سفارش

    -
    - جمع کل - تومان -
    -
    - هزینه ارسال - رایگان -
    -
    -
    - مبلغ نهایی +
    +
    +

    خلاصه سفارش

    +
    + جمع کل تومان
    -
    -
    - ادامه و پرداخت +
    + هزینه ارسال + رایگان +
    +
    +
    + مبلغ نهایی + تومان +
    +
    +
    -
    - -
    -
    + +
    +
    +
    \ No newline at end of file diff --git a/checkout.php b/checkout.php index fb9780d0..b21bafbf 100644 --- a/checkout.php +++ b/checkout.php @@ -72,114 +72,123 @@ $grand_total = $total_price + $shipping_cost; ?> -
    -
    - -
    -

    جزئیات صورتحساب

    +
    +
    +
    +
    +

    تکمیل سفارش و پرداخت

    +

    اطلاعات خود را برای ارسال سفارش وارد کنید.

    +
    -
      '; - foreach ($_SESSION['checkout_errors'] as $error) { - echo '
    • ' . htmlspecialchars($error) . '
    • '; - } - echo '
    '; - // Unset the session variable so it doesn't show again on refresh - unset($_SESSION['checkout_errors']); - } - ?> - -
    +
    + +
    +

    جزئیات صورتحساب

    -
    -
    اطلاعات تماس
    -
    -
    -
    - - -
    -
    - - -
    -
    - - -
    -
    - - +
      '; + foreach ($_SESSION['checkout_errors'] as $error) { + echo '
    • ' . htmlspecialchars($error) . '
    • '; + } + echo '
    '; + // Unset the session variable so it doesn't show again on refresh + unset($_SESSION['checkout_errors']); + } + ?> + + + +
    +
    اطلاعات تماس
    +
    +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    -
    -
    -
    -
    آدرس جهت ارسال
    -
    -
    - - -
    -
    -
    - - -
    -
    - - -
    -
    - - +
    +
    آدرس جهت ارسال
    +
    +
    + + +
    +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    -
    + +
    - -
    + +
    +
    +

    خلاصه سفارش شما

    +
      + +
    • + (x) + T +
    • + +
    - -
    -
    -

    خلاصه سفارش شما

    -
      - -
    • - (x) - T -
    • - -
    +
    +
    + جمع کل + T +
    +
    + هزینه ارسال + T +
    +
    + مبلغ قابل پرداخت + T +
    +
    -
    -
    - جمع کل - T +
    + +
    -
    - هزینه ارسال - T -
    -
    - مبلغ قابل پرداخت - T -
    -
    - -
    -
    -
    +
    diff --git a/db/migrations/016_add_phone_to_users.sql b/db/migrations/016_add_phone_to_users.sql new file mode 100644 index 00000000..b1ba3161 --- /dev/null +++ b/db/migrations/016_add_phone_to_users.sql @@ -0,0 +1 @@ +ALTER TABLE `users` ADD COLUMN `phone` VARCHAR(255) NULL AFTER `email`; \ No newline at end of file diff --git a/includes/header.php b/includes/header.php index fb446bf9..7c484e07 100644 --- a/includes/header.php +++ b/includes/header.php @@ -34,32 +34,8 @@ $page_title = $page_title ?? 'فروشگاه آتیمه'; // Default title <?php echo htmlspecialchars($page_title); ?> - - - - - - - + + @@ -70,10 +46,11 @@ $page_title = $page_title ?? 'فروشگاه آتیمه'; // Default title + + + - - - - + + + \ No newline at end of file