:root {
    --primary-color: #6b8e23;      /* Olive Green */
    --secondary-color: #7cb5ec;     /* Sky Blue */
    --accent-color: #ff4000;        /* Tomato Red */
    --background-color: #f9f9f9;
    --text-color: #333;
    --warm-gray: #e6e9ed;
    --light-accent: #ffa500;     /* Lighter orange for hover states */
    --dark-primary: #b22222;     /* Darker orange/red for depth */
    --soft-white: #ffffff;
    --soft-shadow: 0 2px 10px rgba(74, 94, 140, 0.1);
    --card-shadow: 0 4px 6px rgba(74, 94, 140, 0.06);
    --hover-shadow: 0 10px 20px rgba(74, 94, 140, 0.15);
    --contact-bar-color: #3498db; /* Nice blue for the contact bar */
}

.department-card-content button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease, outline 0.3s ease;
    outline: 2px solid rgba(255, 255, 255, 0.3);
}
.department-card-content button:hover {
    background-color: var(--dark-primary);
    outline: 2px solid white;
}

.modal-content input[type="text"] {
    width: 100%;
    padding: 12px 20px;
    margin: 8px 0;
    box-sizing: border-box;
    border: 2px solid #ccc;
    border-radius: 4px;
}

.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}
.pagination button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    margin: 2px;
    transition: background-color 0.3s ease, outline 0.3s ease;
    cursor: pointer;
    outline: 2px solid rgba(255, 255, 255, 0.3);
}
.pagination button:hover {
    background-color: var(--dark-primary);
    outline: 2px solid white;
}
.pagination button.active {
    background-color: var(--dark-primary);
    outline: 2px solid white;
}

.price {
    font-size: 1.2em;
    font-weight: bold;
    margin: 10px 0;
}
.sale-price {
    color: var(--primary-color);
}
.original-price {
    text-decoration: line-through;
    color: #6c757d;
    font-size: 0.9em;
    margin-left: 5px;
}
.unit {
    font-size: 0.8em;
    color: #6c757d;
    margin-left: 2px;
}

.modal-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}
.modal-item {
    position: relative;
    flex: 1 1 240px;
    margin: 10px;
    max-width: 300px;
    min-width: 240px;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.modal-item:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}
.modal-item img {
    width: 100%;
    height: 150px;
    object-fit: contain;
}
.modal-item h3 {
    font-size: 1.2em;
    margin: 10px 0;
}
.modal-item p {
    margin: 5px 0;
}

.ribbon {
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    overflow: hidden;
    z-index: 1;
}
.ribbon span {
    position: absolute;
    display: block;
    width: 140px;
    padding: 5px 0;
    background-color: var(--primary-color);
    color: #fff;
    font: bold 12px sans-serif;
    text-align: center;
    transform: rotate(45deg);
    top: 25px;
    right: -35px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.featured-deals {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
}
@media (max-width: 600px) {
    .modal-item {
        flex: 1 1 calc(100% - 20px);
        margin: 10px;
    }
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

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

header {
    background: white;
    color: var(--text-color);
    padding: 15px 0;
    box-shadow: var(--soft-shadow);
}

.top-bar {
    background-color: var(--contact-bar-color);
    padding: 8px 0;
    text-align: center;
    font-size: 0.95em;
    color: var(--soft-white);
    letter-spacing: 0.3px;
}

.logo {
    max-width: 200px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.logo:hover {
    transform: scale(1.02);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
}
nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
}
nav ul li a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 4px;
    letter-spacing: 0.3px;
}
nav ul li a:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.hero {
    background-image: url('img/banner.jpg');
    background-size: cover;
    background-position: center;
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--soft-white);
    margin-bottom: 60px;
    position: relative;
}
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(51, 51, 51, 0.7), rgba(51, 51, 51, 0.8));
}
.hero-content {
    position: relative;
    z-index: 1;
    max-width: 750px;
    padding: 40px;
    background: rgba(51, 51, 51, 0.85);
    border-radius: 8px;
    backdrop-filter: blur(10px);
}
.hero h1 {
    font-size: 3.5em;
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.2;
}
.hero p {
    font-size: 1.25em;
    margin-bottom: 30px;
    font-weight: 400;
    opacity: 0.95;
}

.cta-button {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--soft-white);
    padding: 14px 32px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 0.3px;
}
.cta-button:hover {
    background-color: var(--light-accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 90, 95, 0.4);
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    color: var(--primary-color);
    font-size: 2.5em;
    font-weight: 700;
    letter-spacing: -0.5px;
    position: relative;
}
.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), var(--light-accent));
    margin: 20px auto 0;
    border-radius: 2px;
}

.featured-deals {
    display: grid;
    grid-template-columns: repeat(4, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
}

.deal-card {
    background-color: var(--soft-white);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--card-shadow);
}
.deal-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--hover-shadow);
}
.deal-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.deal-card:hover img {
    transform: scale(1.05);
}
.deal-card-content {
    padding: 24px;
}
.deal-card h3 {
    margin-bottom: 12px;
    color: var(--primary-color);
    font-size: 1.4em;
    font-weight: 600;
    letter-spacing: -0.3px;
}
.deal-card p {
    font-weight: 500;
    color: var(--secondary-color);
    font-size: 1.2em;
}

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

.department-card {
    position: relative;
    height: 300px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.department-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--hover-shadow);
}
.department-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.department-card:hover img {
    transform: scale(1.05);
}
.department-card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px;
    background: linear-gradient(to top, rgba(51, 51, 51, 0.9), rgba(51, 51, 51, 0));
    color: var(--soft-white);
    transition: all 0.3s ease;
}
.department-card h3 {
    margin-bottom: 10px;
    font-size: 1.6em;
    font-weight: 600;
    letter-spacing: -0.3px;
}
.department-card a {
    color: var(--soft-white);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}
.department-card a:hover {
    color: var(--primary-color);
}

footer {
    background: linear-gradient(135deg, var(--primary-color), var(--dark-primary));
    color: var(--soft-white);
    text-align: center;
    padding: 60px 0;
    margin-top: 80px;
}
footer p {
    margin-bottom: 20px;
    opacity: 0.9;
}
footer a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}
footer a:hover {
    color: var(--light-accent);
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(51, 51, 51, 0.95);
    backdrop-filter: blur(5px);
}
.modal-content {
    background: var(--soft-white);
    margin: 2% auto;
    padding: 30px;
    width: 90%;
    max-width: 1200px;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}
.close {
    color: var(--primary-color);
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}
.close:hover {
    color: var(--light-accent);
}

.modal-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); 
    gap: 25px;
}
.modal-item {
    background-color: var(--soft-white);
    border-radius: 8px;
    box-shadow: var(--card-shadow);
    padding: 20px;
    text-align: center;
    transition: transform 0.3s ease;
}
.modal-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--hover-shadow);
}
.modal-item img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 15px;
}
.modal-item h3 {
    font-size: 1.2em;
    margin-bottom: 8px;
    color: var(--primary-color);
    font-weight: 600;
}
.modal-item p {
    font-weight: 500;
    color: var(--secondary-color);
}
.modal-item .description {
    font-size: 0.95em;
    color: var(--text-color);
    margin-top: 12px;
    opacity: 0.8;
}

@media (max-width: 1024px) {
    .modal-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .hero h1 {
        font-size: 3em;
    }
}

@media (max-width: 768px) {
    nav {
        flex-direction: column;
    }
    nav ul {
        margin-top: 20px;
        flex-wrap: wrap;
        justify-content: center;
    }
    nav ul li {
        margin: 5px;
    }
    .hero {
        height: 500px;
    }
    .hero h1 {
        font-size: 2.5em;
    }
    .hero p {
        font-size: 1.1em;
    }
    .section-title {
        font-size: 2em;
    }
    .modal-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero {
        height: 400px;
    }
    .hero h1 {
        font-size: 2em;
    }
    .modal-grid {
        grid-template-columns: 1fr;
    }
    .section-title {
        font-size: 1.8em;
    }
}