/* =============================================
   GLOBAL
   ============================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, sans-serif;
}

body {
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

/* =============================================
   NAVBAR — DESKTOP
   ============================================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 6%;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    z-index: 1000;
    gap: 16px;
}

.logo {
    font-size: 24px;
    font-weight: 800;
    color: #084787;
    letter-spacing: -1px;
    flex-shrink: 0;
}

/* Search bar — capped width so nav-links always stay visible on right */
.search-bar {
    flex: 0 1 400px;
    min-width: 0;
}

.search-bar form {
    display: flex;
    background: #f1f3f4;
    padding: 4px;
    border-radius: 50px;
    border: 1px solid #ddd;
    width: 100%;
}
.search-bar form:hover{
    border-color: #3498db;
}

.search-bar input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 15px;
    outline: none;
    font-size: 14px;
    min-width: 0;
}

.search-bar button {
    background: #084787;
    color: #fff;
    border: none;
    padding: 8px 20px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Nav links — always on the right, never shrink or wrap on desktop */
.nav-links {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.nav-links a {
    text-decoration: none;
    color: #444;
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
}

/* Green "List Your Shop" */
.list-shop {
    background: #2ecc71;
    color: #fff !important;
    padding: 8px 16px;
    border-radius: 8px;
}

/* Blue "Login" */
.login-link {
    background: #084787;
    color: #fff !important;
    padding: 8px 16px;
    border-radius: 8px;
}

/* Category select */
.nav-links #category {
    appearance: none;
    background-color: #f1f3f4;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 8px 35px 8px 14px;
    font-size: 14px;
    font-weight: 600;
    color: #444;
    cursor: pointer;
    outline: none;
    white-space: nowrap;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23444' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    transition: border-color 0.2s ease;
}

.nav-links #category:focus {
    border-color: #084787;
}

/* Hamburger button — hidden on desktop */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: #f1f3f4;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.2s ease;
}

.hamburger:hover { background: #e2e6ea; }

.hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: #084787;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

/* =============================================
   HERO
   ============================================= */
.hero-section {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
    background: #000;
}

.hero-slider {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    opacity: 0;
    pointer-events: none;
}

.hero-slide img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    opacity: 0;
}

.hero-text {
    position: absolute;
    right: 80px;
    top: 50%;
    transform: translateY(-50%);
    text-align: right;
    color: #fff;
    padding: 25px 40px;
    border-radius: 15px;
    z-index: 2;
}

.hero-text h2 {
    font-size: 90px;
    font-weight: 800;
    line-height: 1;
    opacity: 0;
    text-shadow: 2px 4px 12px rgba(0, 0, 0, 0.8);
}

.hero-text p {
    font-size: 36px;
    font-weight: 600;
    margin-top: 8px;
    opacity: 0;
    text-shadow: 1px 3px 8px rgba(0, 0, 0, 0.8);
}

@keyframes slideEnter {
    0%   { opacity: 0; }
    100% { opacity: 1; }
}
@keyframes slideExit {
    0%   { opacity: 1; }
    100% { opacity: 0; }
}
@keyframes imgAppear {
    0%   { opacity: 0; transform: scale(1.05); }
    100% { opacity: 1; transform: scale(1); }
}
@keyframes itemAppear {
    0%   { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.hero-slide.active {
    opacity: 1;
    pointer-events: auto;
    animation: slideEnter 1s ease forwards;
}
.hero-slide.active img {
    animation: imgAppear 1.2s ease 0s both;
}
.hero-slide.active .hero-text h2 {
    animation: itemAppear 0.6s ease 0.6s both;
}
.hero-slide.active .hero-text p {
    animation: itemAppear 0.6s ease 1.0s both;
}
.hero-slide.exit {
    animation: slideExit 1s ease forwards;
    pointer-events: none;
}

/* =============================================
   CATEGORIES
   ============================================= */
.categories-section {
    padding: 60px 6% 30px;
}

.categories-section h2 {
    font-size: 26px;
    margin-bottom: 30px;
    color: #084787;
    font-weight: 800;
}

.category-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.category-card {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: #fff;
    height: 160px;
    border-radius: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    cursor: pointer;
    border: 1px solid #edf2f7;
    overflow: hidden;
}

.category-card:hover {
    transform: translateY(-8px);
    border-color: #3498db;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.category-card img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

.category-card p {
    position: relative;
    z-index: 1;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    background: rgba(0, 0, 0, 0.45);
    width: 100%;
    text-align: center;
    padding: 10px;
}

/* =============================================
   FEATURED SHOPS
   ============================================= */
.featured-shops {
    padding: 20px 6% 60px;
}

.featured-shops h2 {
    font-size: 26px;
    margin-bottom: 30px;
    color: #084787;
    font-weight: 800;
}

.shop-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}
@media (max-width: 600px) {
    .shop-container { grid-template-columns: 1fr; }
}

.shop-card {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.shop-image   { width: 100%; height: 180px; object-fit: cover; }
.shop-card h3 { padding: 15px 15px 5px; }
.rating       { color: #f39c12; padding: 0 15px; font-weight: bold; }
.distance     { color: #888; padding: 0 15px; font-size: 13px; }

.product-preview {
    display: flex;
    gap: 10px;
    padding: 15px;
    flex-wrap: wrap;
}

.product-preview img {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
}

.shop-card button {
    width: calc(100% - 30px);
    margin: 10px 15px 20px;
    padding: 12px;
    border: none;
    background: #084787;
    color: #fff;
    font-weight: bold;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    background: #1e293b;
    color: #fff;
    padding: 50px 6% 20px;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.social-icons img {
    width: 24px;
    filter: invert(1);
    margin-right: 15px;
}

.footer-bottom {
    text-align: center;
    margin-top: 40px;
    font-size: 12px;
    opacity: 0.6;
}

.__cf_email__{
    color:white;
    text-decoration: none;
}

/* =============================================
   LARGE DESKTOPS (1440px+)
   ============================================= */
@media (min-width: 1440px) {
    .navbar { padding: 14px 8%; }
    .search-bar { flex: 0 1 500px; }
    .hero-section { height: 420px; }
    .hero-text h2 { font-size: 110px; }
    .hero-text p  { font-size: 44px; }
    .categories-section,
    .featured-shops { padding-left: 8%; padding-right: 8%; }
    .category-container { grid-template-columns: repeat(5, 1fr); }
    .category-card { height: 180px; }
}

/* =============================================
   STANDARD DESKTOPS (1101–1439px)
   ============================================= */
@media (max-width: 1439px) and (min-width: 1101px) {
    .hero-section { height: 340px; }
    .hero-text h2 { font-size: 80px; }
    .hero-text p  { font-size: 32px; }
}

/* =============================================
   SMALL DESKTOPS (max 1100px)
   ============================================= */
@media (max-width: 1100px) {
    .category-container { grid-template-columns: repeat(2, 1fr); }
    .search-bar { flex: 0 1 240px; }
    .hero-text h2 { font-size: 72px; }
    .hero-text p  { font-size: 28px; }
    .hero-text    { right: 40px; padding: 20px 30px; }
}

/* =============================================
   TABLET LANDSCAPE (max 900px)
   ============================================= */
@media (max-width: 900px) {
    .navbar { padding: 12px 4%; gap: 10px; }
    .nav-links { gap: 10px; }
    .search-bar { flex: 0 1 200px; }
    .nav-links a { font-size: 13px; }
    .list-shop  { padding: 7px 12px; }
    .login-link { padding: 7px 12px; }
    .nav-links #category { padding: 7px 28px 7px 10px; font-size: 13px; }
    .hero-section { height: 260px; }
    .hero-text { right: 24px; padding: 16px 22px; }
    .hero-text h2 { font-size: 58px; }
    .hero-text p  { font-size: 24px; }
    .categories-section { padding: 40px 4% 20px; }
    .featured-shops      { padding: 20px 4% 40px; }
    .shop-container { grid-template-columns: repeat(2, 1fr); gap: 20px; }
}

/* =============================================
   MOBILE — Hamburger menu (max 768px)
   ============================================= */
@media (max-width: 768px) {

    /* Navbar wraps into rows */
    .navbar {
        flex-wrap: wrap;
        padding: 12px 5%;
        gap: 0;
        align-items: center;
    }

    /* Row 1 left: Logo */
    .logo {
        flex: 1;
        font-size: 22px;
    }

    /* Row 1 right: Hamburger */
    .hamburger {
        display: flex;
        order: 2;
    }

    /* Row 2: Search bar — always visible */
    .search-bar {
        order: 3;
        flex: 0 0 100%;
        margin-top: 10px;
    }

    .search-bar form { width: 100%; }

    /* Row 3: Nav links — slide down on open */
    .nav-links {
        order: 4;
        flex: 0 0 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
        padding: 0;
    }

    /* Expanded state */
    .navbar.nav-open .nav-links {
        max-height: 500px;
        padding: 8px 0;
    }

    /* Category select — full-width row */
    .nav-links #category {
        display: block;
        width: 100%;
        padding: 14px 36px 14px 14px;
        font-size: 15px;
        font-weight: 600;
        color: #333;
        background-color: #fff;
        border: none;
        border-bottom: 1px solid #efefef;
        border-radius: 0;
        cursor: pointer;
        outline: none;
        appearance: none;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23084787' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-position: right 16px center;
        white-space: normal;
    }

    /* Plain nav link rows */
    .nav-links a {
        display: block;
        padding: 14px;
        font-size: 15px;
        font-weight: 600;
        color: #333;
        border-bottom: 1px solid #efefef;
        border-radius: 0;
        background: none;
        text-align: left;
        white-space: normal;
    }

    /* Green "List Your Shop" */
    .nav-links a.list-shop {
        background: #2ecc71;
        color: #fff !important;
        border-radius: 10px;
        border: none;
        margin: 8px 0 4px;
        text-align: center;
        padding: 13px 14px;
    }

    /* Blue "Login" */
    .nav-links a.login-link {
        background: #084787;
        color: #fff !important;
        border-radius: 10px;
        border: none;
        margin: 4px 0 8px;
        text-align: center;
        padding: 13px 14px;
    }

    /* Hero */
    .hero-section { height: 220px; }
    .hero-text { right: 16px; left: auto; text-align: right; padding: 14px 18px; }
    .hero-text h2 { font-size: 48px; }
    .hero-text p  { font-size: 20px; }

    /* Sections */
    .categories-section { padding: 36px 5% 20px; }
    .featured-shops      { padding: 16px 5% 36px; }
    .categories-section h2,
    .featured-shops h2   { font-size: 22px; margin-bottom: 20px; }

    /* Grids */
    .category-container { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .shop-container      { grid-template-columns: 1fr; gap: 20px; }
    .category-card       { height: 140px; }
    .category-card p     { font-size: 16px; }

    /* Footer */
    .footer { padding: 36px 5% 16px; }
    .footer-container { flex-direction: column; gap: 20px; }
}

/* =============================================
   LARGE PHONES (max 600px)
   ============================================= */
@media (max-width: 600px) {
    .hero-section { height: 200px; }
    .hero-text { right: 14px; }
    .hero-text h2 { font-size: 40px; }
    .hero-text p  { font-size: 17px; }
    .category-container { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .category-card { height: 120px; border-radius: 14px; }
    .category-card p { font-size: 14px; padding: 8px; }
    .shop-image { height: 160px; }
    .product-preview img { width: 52px; height: 52px; }
}

/* =============================================
   SMALL PHONES (max 480px)
   ============================================= */
@media (max-width: 480px) {
    .navbar { padding: 10px 4%; }
    .logo   { font-size: 20px; }
    .search-bar input  { font-size: 13px; padding: 7px 12px; }
    .search-bar button { padding: 7px 14px; font-size: 13px; }

    .hero-section { height: 180px; }
    .hero-text { right: 10px; left: auto; text-align: right; padding: 10px 14px; }
    .hero-text h2 { font-size: 32px; }
    .hero-text p  { font-size: 14px; }

    .categories-section { padding: 28px 4% 16px; }
    .featured-shops      { padding: 12px 4% 28px; }
    .categories-section h2,
    .featured-shops h2   { font-size: 20px; margin-bottom: 16px; }

    .category-container { grid-template-columns: 1fr 1fr; gap: 10px; }
    .category-card { height: 110px; border-radius: 12px; }
    .category-card p { font-size: 13px; padding: 7px; }

    .shop-card h3  { font-size: 15px; padding: 12px 12px 4px; }
    .rating        { font-size: 13px; padding: 0 12px; }
    .distance      { font-size: 12px; padding: 0 12px; }
    .product-preview { padding: 10px 12px; gap: 8px; }
    .product-preview img { width: 46px; height: 46px; }
    .shop-card button {
        width: calc(100% - 24px);
        margin: 8px 12px 16px;
        padding: 11px;
        font-size: 13px;
    }

    .footer { padding: 28px 4% 14px; }
    .footer-container { gap: 16px; }
    .social-icons img { width: 20px; margin-right: 10px; }
    .footer-bottom { font-size: 11px; margin-top: 28px; }
}

/* =============================================
   VERY SMALL PHONES (max 360px)
   ============================================= */
@media (max-width: 360px) {
    .logo { font-size: 18px; }
    .hero-section { height: 155px; }
    .hero-text h2 { font-size: 26px; }
    .hero-text p  { font-size: 12px; }
    .category-container { grid-template-columns: 1fr; }
    .category-card { height: 130px; }
    .search-bar button { padding: 7px 10px; font-size: 12px; }
}
