﻿
:root {
    --amwaj-primary: #00BFB3;
    --amwaj-secondary: #00A69A;
    --amwaj-accent: #FF8C40;
    --amwaj-green: #4CAF50;
    --amwaj-bg-light: #F5FBFB;
    --amwaj-text-dark: #333333;
    --amwaj-white: #FFFFFF;
    --shadow-card: 0 4px 15px rgba(0, 0, 0, 0.05);
}

* {
    box-sizing: border-box;
}

html {
    overflow-y: scroll;
    scroll-behavior: smooth;
}

body {
    font-family: 'Cairo', sans-serif;
    background-color: var(--amwaj-bg-light);
    color: var(--amwaj-text-dark);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    width: 100%;
}

  
h1, h2, h3, h4 {
    font-weight: 900;
    margin-bottom: 15px;
    color: var(--amwaj-text-dark);
}

h2 {
    font-size: 1.8em;
    border-bottom: 2px solid var(--amwaj-primary);
    display: inline-block;
    padding-bottom: 10px;
    margin-bottom: 30px;
}


header {
    background-color: var(--amwaj-white);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    height: 160px;
}

.top-header-bar {
    padding: 10px 0;
    height: 70px;
    display: flex;
    align-items: center;
    border-bottom: 3px solid #00BFB3;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 40px;
    width: auto;
}

.logo-text-wrapper {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.main-logo-title {
    font-size: 1.1em;
    font-weight: 900;
    color: var(--amwaj-text-dark);
}

.secondary-tagline {
    font-size: 0.75em;
    color: var(--amwaj-secondary);
    font-weight: 600;
}

.header-actions-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.lang-btn {
    background-color: transparent;
    color: var(--amwaj-text-dark);
    padding: 6px 15px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 0.9em;
    border: 2px solid var(--amwaj-bg-light);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-family: 'Cairo', sans-serif;
    text-decoration: none;
}

    .lang-btn:hover {
        background-color: var(--amwaj-bg-light);
        color: var(--amwaj-primary);
        border-color: var(--amwaj-primary);
        transform: translateY(-2px);
    }

    .lang-btn i {
        color: var(--amwaj-secondary);
        font-size: 1.1em;
    }

.cart-btn {
    background: white;
    border: 1px solid #eee;
    color: var(--amwaj-text-dark);
    font-size: 1.2em;
    position: relative;
    cursor: pointer;
    padding: 8px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

    .cart-btn:hover {
        background-color: var(--amwaj-primary);
        color: white;
        border-color: var(--amwaj-primary);
    }

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--amwaj-accent);
    color: white;
    font-size: 0.7em;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    border: 2px solid white;
}

.search-bar-container {
    background-color: #fff;
    padding: 0;
    border-top: 1px solid #f0f0f0;
    height: 60px;
    display: flex;
    align-items: center;
    margin-top: 5px;
    margin-bottom: 5px;
}

.search-input {
    width: 100%;
    padding: 5px 20px;
    border: 1px solid var(--amwaj-secondary);
    border-radius: 25px;
    outline: none;
    font-family: inherit;
    transition: box-shadow 0.3s;
}

    .search-input:focus {
        box-shadow: 0 0 0 3px rgba(0, 191, 179, 0.1);
    }

.live-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #eee;
    border-radius: 0 0 15px 15px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    z-index: 1001;
    max-height: 300px;
    overflow-y: auto;
    display: none;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 10px 15px;
    border-bottom: 1px solid #f9f9f9;
    cursor: pointer;
    transition: 0.2s;
}

    .search-result-item:hover {
        background-color: #f0fdfb;
    }

    .search-result-item img {
        width: 40px;
        height: 40px;
        object-fit: contain;
        border-radius: 5px;
        margin-left: 10px;
        border: 1px solid #eee;
        background: #f9f9f9;
        padding: 2px;
    }

    .search-result-item .info {
        flex-grow: 1;
        text-align: start; 
        padding: 0 10px;
    }

    .search-result-item .name {
        font-weight: bold;
        font-size: 0.95em;
        color: var(--amwaj-text-dark);
    }

    .search-result-item .price {
        font-size: 0.85em;
        color: var(--amwaj-primary);
        font-weight: bold;
    }

.scrolling-banner {
    background-color: var(--amwaj-secondary);
    color: white;
    height: 30px;
    line-height: 30px;
    overflow: hidden;
    white-space: nowrap;
    font-size: 0.9em;
    font-weight: bold;
    position: absolute;
    bottom: 0;
    width: 100%;
}

    .scrolling-banner span {
        display: inline-block;
        padding-left: 100%;
        animation: scroll-rtl 20s linear infinite;
    }

@keyframes scroll-rtl {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(100%);
    }
}


main {
    padding-top: 180px !important;
    padding-bottom: 50px;
    flex-grow: 1;
}

.page-section {
    margin-bottom: 40px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); 
    gap: 25px;
}

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


.product-card {
    background: white;
    border-radius: 15px;
    padding: 15px;
    box-shadow: var(--shadow-card);
    border: 1px solid #eee;
    text-align: center;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

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

.product-image-wrapper {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    background-color: #fff;
    border-radius: 10px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid #f0f0f0;
}

.product-card img {
    max-width: 80%;
    max-height: 80%;
    object-fit: contain;
    transition: transform 0.3s;
}

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

.product-card h4 {
    font-size: 1.1em;
    margin: 10px 0;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-card p {
    font-size: 0.9em;
    color: #777;
    margin-bottom: 10px;
}

.price-section {
    margin-top: auto;
    margin-bottom: 10px;
}

.original-price {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9em;
}

.current-price {
    color: var(--amwaj-primary);
    font-size: 1.3em;
    font-weight: bold;
}

.quantity-control {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--amwaj-primary);
    background: white;
    color: var(--amwaj-primary);
    font-size: 1.2em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.2s;
}

    .qty-btn:hover {
        background: var(--amwaj-primary);
        color: white;
    }

.qty-display {
    font-weight: bold;
    font-size: 1.2em;
    min-width: 20px;
}

.add-to-cart-btn {
    width: 100%;
    padding: 12px;
    background-color: var(--amwaj-green);
    color: white;
    border: none;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

    .add-to-cart-btn:hover {
        background-color: #3d8b40;
        transform: scale(1.02);
    }

.category-card {
    background: white;
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    border: 1px solid #eee;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%; 
}

    .category-card:hover {
        border-color: var(--amwaj-primary);
        transform: translateY(-3px);
    }

    .category-card img {
        width: 100px;
        height: 100px;
        border-radius: 10px;
        object-fit: contain;
        margin-bottom: 10px;
        background-color: #f9f9f9;
        padding: 10px;
    }


.admin-form-card {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}

.admin-form-header {
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.form-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    background-color: #fcfcfc;
}

    .form-input:focus {
        border-color: var(--amwaj-primary);
        background-color: white;
        outline: none;
    }

.full-width {
    grid-column: span 2;
}

.toggle-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.toggle-input {
    width: 20px;
    height: 20px;
}

.form-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
}

.btn-save {
    flex: 2;
    background: var(--amwaj-primary);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
}

.btn-cancel {
    flex: 1;
    background: #fff;
    color: #dc3545;
    border: 1px solid #dc3545;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
}

.table-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    overflow-x: auto;
    padding: 5px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table thead {
    background-color: var(--amwaj-primary) !important;
    color: white !important;
}

    .admin-table thead th {
        padding: 15px;
        text-align: right;
        font-weight: bold;
        border: none;
        font-size: 1em;
    }

        .admin-table thead th:first-child {
            border-top-right-radius: 10px;
            border-bottom-right-radius: 10px;
        }

        .admin-table thead th:last-child {
            border-top-left-radius: 10px;
            border-bottom-left-radius: 10px;
        }

.admin-table tbody tr {
    border-bottom: 1px solid #f1f1f1;
    transition: background-color 0.2s;
}

    .admin-table tbody tr:hover {
        background-color: #fcfcfc;
    }

.admin-table td {
    padding: 12px 15px;
    vertical-align: middle;
}

.orders-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 10px;
    min-width: 900px;
}

    .orders-table thead th {
        background: transparent;
        color: #636e72;
        font-weight: 600;
        padding: 15px;
        border: none;
        text-transform: uppercase;
        font-size: 0.85em;
    }

    .orders-table tbody tr {
        background: white;
        box-shadow: 0 2px 5px rgba(0,0,0,0.02);
        transition: 0.2s;
    }

        .orders-table tbody tr:hover {
            transform: scale(1.005);
            box-shadow: 0 5px 15px rgba(0,0,0,0.05);
        }

    .orders-table td {
        padding: 15px;
        vertical-align: middle;
        border-top: 1px solid #f1f2f6;
        border-bottom: 1px solid #f1f2f6;
    }

        .orders-table td:first-child {
            border-right: 1px solid #f1f2f6;
            border-radius: 0 10px 10px 0;
        }

        .orders-table td:last-child {
            border-left: 1px solid #f1f2f6;
            border-radius: 10px 0 0 10px;
        }

.order-item-badge {
    display: inline-block;
    background: #f1f2f6;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.85em;
    margin: 2px;
    color: #555;
}

.status-select {
    padding: 8px 12px;
    border-radius: 30px;
    border: none;
    font-weight: bold;
    font-size: 0.9em;
    cursor: pointer;
    outline: none;
    text-align: center;
    width: 100%;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-paid {
    background: #d4edda;
    color: #155724;
}

.status-cancelled {
    background: #f8d7da;
    color: #721c24;
}

.status-blacklist {
    background: #333;
    color: #fff;
}

.action-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 3px;
    font-size: 1em;
    cursor: pointer;
}

    .action-btn.delete {
        background: #ffebee;
        color: #c62828;
    }

    .action-btn.whatsapp {
        background: #e8f5e9;
        color: #2e7d32;
    }

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.3s;
}

    .stat-card .icon {
        width: 60px;
        height: 60px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.5em;
    }

    .stat-card .info h4 {
        font-size: 1.8em;
        margin: 0;
        color: #2d3436;
    }

    .stat-card .info p {
        margin: 0;
        color: #636e72;
        font-size: 0.9em;
    }


footer {
    background-color: white;
    padding: 30px 0;
    margin-top: auto;
    text-align: center;
    border-top: 1px solid #eee;
}

.footer-social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

    .footer-social-links i {
        width: 45px;
        height: 45px;
        border-radius: 50%;
        color: white;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.3em;
        transition: transform 0.3s;
    }

        .footer-social-links i:hover {
            transform: scale(1.1);
        }

.fab.fa-tiktok {
    background-color: #000000;
}

.fab.fa-snapchat-ghost {
    background-color: #FFFC00;
    color: #000 !important;
}

.fab.fa-instagram {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

.fab.fa-facebook-f {
    background-color: #1877F2;
}

.fab.fa-whatsapp {
    background-color: #25D366;
}


.cart-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
}

.cart-modal-content {
    background: white;
    width: 90%;
    max-width: 500px;
    border-radius: 15px;
    padding: 20px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.cart-body {
    flex-grow: 1;
    overflow-y: auto;
}

.cart-item {
    background: #f9f9f9;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5em;
    cursor: pointer;
    color: #777;
}

.utility-buttons {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1500;
}

.back-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 1.2em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-container {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translate(-50%, 50px);
    background: #333;
    color: white;
    padding: 12px 25px;
    border-radius: 30px;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: 0.4s;
}

    .toast-container.show {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, 0);
    }

#screenshot-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    color: white;
    z-index: 99999;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-size: 1.5em;
}


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

@media (max-width: 992px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .category-grid {
        grid-template-columns: repeat(3, 1fr); 
    }
}

@media (max-width: 600px) {
    .product-grid {
        grid-template-columns: 1fr;
    }

    .category-grid {
        grid-template-columns: repeat(2, 1fr); 
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .full-width {
        grid-column: span 1;
    }

    .header-container {
        padding: 0 5px;
    }

    main {
        padding-top: 165px !important;
    }
}
.watermark-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999; 
    pointer-events: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' version='1.1' height='150px' width='150px'><text transform='translate(20, 100) rotate(-45)' fill='rgba(0,0,0,0.03)' font-size='20'>Amwaj Grocery</text></svg>");
    opacity: 1;
    display: block;
}
#screenshot-overlay {
    backdrop-filter: blur(15px); 
    -webkit-backdrop-filter: blur(15px);
}
@media (max-width: 992px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .category-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }

    .admin-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

@media (max-width: 600px) {

    header {
        height: auto;
        padding-bottom: 10px;
    }

    .top-header-bar {
        height: auto;
        flex-wrap: wrap;
        padding: 10px 5px;
    }

    .logo img {
        height: 35px;
    }

    .main-logo-title {
        font-size: 1em;
    }

    .header-actions-group {
        gap: 5px;
    }

    .lang-btn {
        padding: 4px 10px;
        font-size: 0.8em;
    }

    .search-bar-container {
        margin-top: 0;
        height: 50px;
    }

    .search-input {
        padding: 8px 15px;
        font-size: 0.9em;
    }

    main {
        padding-top: 160px !important; 
        padding-left: 10px;
        padding-right: 10px;
    }

    h2 {
        font-size: 1.4em;
        margin-bottom: 20px;
    }

    .product-grid {
        grid-template-columns: 1fr; 
        gap: 20px;
    }

    .category-grid {
        grid-template-columns: repeat(2, 1fr); 
        gap: 10px;
    }

    .product-card {
        padding: 10px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.08); 
    }

    .product-image-wrapper {
        margin-bottom: 10px;
        border-radius: 8px;
    }

    .add-to-cart-btn {
        padding: 10px;
        font-size: 0.95em;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .full-width {
        grid-column: span 1;
    }

    .admin-form-card {
        padding: 15px; 
    }

    .cart-modal-content {
        width: 100%;
        height: 85vh; 
        border-radius: 20px 20px 0 0; 
        max-width: none;
        position: absolute;
        bottom: 0;
    }

    .cart-modal-overlay {
        align-items: flex-end; 
    }

    .utility-buttons {
        bottom: 15px;
        right: 15px;
    }

    .back-btn {
        width: 40px;
        height: 40px;
        font-size: 1em;
    }
}


@media only screen and (max-width: 768px) {
    body {
        -webkit-touch-callout: none;
        -webkit-user-select: none; 
        -khtml-user-select: none; 
        -moz-user-select: none; 
        -ms-user-select: none; 
        user-select: none; 
    }

    img {
        pointer-events: none; 
        -webkit-user-drag: none;
    }

    @media print {
        html {
            display: none !important;
        }

        body {
            display: none !important;
        }
    }
}

#screenshot-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    color: white;
    z-index: 2147483647; 
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-size: 1.2em;
    text-align: center;
    padding: 20px;
}

.filter-container {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 15px; 
    margin-bottom: 30px;
    white-space: nowrap; 
    -webkit-overflow-scrolling: touch; 
    scrollbar-width: none; 
    justify-content: center; 
}

    .filter-container::-webkit-scrollbar {
        display: none;
    }

.filter-btn {
    display: inline-block;
    padding: 10px 25px;
    border-radius: 50px;
    background-color: white;
    border: 1px solid #eee;
    color: var(--amwaj-text-dark);
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    font-size: 0.95em;
}

    .filter-btn:hover {
        background-color: #f9f9f9;
        border-color: var(--amwaj-primary);
        transform: translateY(-2px);
    }

    .filter-btn.active {
        background-color: var(--amwaj-primary);
        color: white;
        border-color: var(--amwaj-primary);
        box-shadow: 0 4px 10px rgba(0, 191, 179, 0.3);
    }

@media (max-width: 768px) {
    .filter-container {
        justify-content: flex-start; 
        padding-left: 5px;
        padding-right: 5px;
    }
}

.cart-modal-overlay, .product-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px); 
}

.cart-modal-content {
    background: white;
    width: 90%;
    max-width: 500px;
    border-radius: 15px;
    padding: 20px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.product-modal-content {
    background: white;
    width: 90%;
    max-width: 900px; 
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: row; 
    box-shadow: 0 15px 50px rgba(0,0,0,0.3);
    max-height: 90vh;
    position: relative;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.product-modal-image-col {
    width: 50%;
    background-color: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
}

    .product-modal-image-col img {
        max-width: 100%;
        max-height: 400px;
        object-fit: contain;
        filter: drop-shadow(0 10px 20px rgba(0,0,0,0.1));
    }

.product-modal-details-col {
    width: 50%;
    padding: 40px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.product-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0,0,0,0.05);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.2em;
    cursor: pointer;
    z-index: 10;
    transition: 0.2s;
}

html[dir="rtl"] .product-modal-close {
    right: auto;
    left: 20px;
}

.product-modal-close:hover {
    background: #e74c3c;
    color: white;
}

.modal-product-title {
    font-size: 1.8em;
    color: var(--amwaj-text-dark);
    margin-bottom: 10px;
    font-weight: 900;
}

.modal-product-price {
    font-size: 2em;
    color: var(--amwaj-primary);
    font-weight: bold;
    margin: 15px 0;
}

.modal-product-desc {
    color: #666;
    line-height: 1.8;
    font-size: 1em;
    margin-bottom: 20px;
    background: #fff;
}


@media (max-width: 768px) {
    .product-modal-content {
        flex-direction: column; 
        height: 85vh; 
        width: 100%;
        border-radius: 20px 20px 0 0;
        position: absolute;
        bottom: 0;
        max-width: none;
        animation: slideUp 0.3s ease;
    }

    .product-modal-image-col {
        width: 100%;
        height: 250px;
        padding: 20px;
        flex-shrink: 0;
    }

        .product-modal-image-col img {
            max-height: 200px;
        }

    .product-modal-details-col {
        width: 100%;
        padding: 25px;
    }

    .cart-modal-overlay, .product-modal-overlay {
        align-items: flex-end;
    }
}

.product-modal-content {
    background: white;
    width: 90%;
    max-width: 900px;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-height: 90vh;
    position: relative;
    animation: zoomIn 0.3s ease;
}

.product-modal-image-col {
    width: 45%;
    background-color: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
    border-left: 1px solid #f1f5f9; 
}

    .product-modal-image-col img {
        max-width: 100%;
        max-height: 400px;
        object-fit: contain;
        filter: drop-shadow(0 10px 15px rgba(0,0,0,0.1));
    }

.product-modal-details-col {
    width: 55%;
    padding: 40px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    position: relative;
}

.product-modal-close {
    position: absolute;
    top: 15px;
    right: 15px; 
    background: rgba(0,0,0,0.05);
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.1em;
    cursor: pointer;
    z-index: 10;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

html[dir="rtl"] .product-modal-close {
    right: auto;
    left: 15px;
}

.product-modal-close:hover {
    background: #ef4444;
    color: white;
}

.modal-product-title {
    font-size: 1.8em;
    color: var(--amwaj-text-dark);
    margin-bottom: 15px;
    font-weight: 900;
    line-height: 1.3;
}

.modal-product-price {
    font-size: 2em;
    color: var(--amwaj-primary);
    font-weight: 800;
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.summernote-content {
    color: #475569;
    line-height: 1.7;
    font-size: 1rem;
    margin-bottom: 30px;
    background: #fff;
}

    .summernote-content ul, .summernote-content ol {
        padding-right: 20px;
        margin-bottom: 15px;
    }

html[dir="ltr"] .summernote-content ul {
    padding-right: 0;
    padding-left: 20px;
}

.summernote-content p {
    margin-bottom: 10px;
}

.summernote-content h1, .summernote-content h2, .summernote-content h3 {
    color: var(--amwaj-secondary);
    margin-top: 15px;
    margin-bottom: 10px;
}

.modal-actions-wrapper {
    margin-top: auto; 
    display: flex;
    gap: 15px;
    padding-top: 20px;
    border-top: 1px solid #f1f5f9;
}

@media (max-width: 768px) {
    .product-modal-content {
        flex-direction: column;
        height: 85vh;
        width: 100%;
        border-radius: 20px 20px 0 0;
        position: absolute;
        bottom: 0;
        max-width: none;
        animation: slideUp 0.3s ease;
    }

    .product-modal-image-col {
        width: 100%;
        height: 220px;
        padding: 15px;
        border-left: none;
        border-bottom: 1px solid #f1f5f9;
    }

        .product-modal-image-col img {
            max-height: 180px;
        }

    .product-modal-details-col {
        width: 100%;
        padding: 20px;
    }

    .modal-product-title {
        font-size: 1.4em;
    }

    .modal-product-price {
        font-size: 1.6em;
    }
}
