/* --- Global Reset & Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: #ffffff;
    color: #1a1a1a;
    overflow-x: hidden; /* Prevents awkward side-scrolling on phones */
}

/* --- Base Layout Rules (Desktop First) --- */
.announcement-bar {
    background-color: #0D3E26;
    color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 5%;
    font-size: 12px;
}
.announcement-bar .top-links a {
    color: #ffffff;
    text-decoration: none;
    margin-left: 20px;
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    border-bottom: 1px solid #f0f0f0;
    gap: 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.logo-q {
    font-size: 38px;
    font-weight: 700;
    color: #0D3E26;
}
.logo-text h1 {
    font-size: 20px;
    letter-spacing: 2px;
    font-weight: 700;
}
.logo-text small {
    font-size: 9px;
    letter-spacing: 1px;
    color: #777;
    display: block;
    margin-top: -4px;
}

.search-container {
    display: flex;
    align-items: center;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    width: 45%;
    height: 44px;
}
.search-container input {
    border: none;
    padding: 0 15px;
    flex-grow: 1;
    height: 100%;
    outline: none;
}
.search-select {
    border: none;
    border-left: 1px solid #e0e0e0;
    padding: 0 15px;
    height: 100%;
    background: #fafafa;
    cursor: pointer;
}
.search-btn {
    background-color: #0D3E26;
    border: none;
    color: white;
    width: 50px;
    height: 100%;
    cursor: pointer;
}

.header-actions {
    display: flex;
    gap: 25px;
    font-size: 14px;
    font-weight: 500;
    flex-shrink: 0;
}
.header-actions a {
    text-decoration: none;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sub-nav {
    display: flex;
    align-items: center;
    padding: 10px 5%;
    border-bottom: 1px solid #f0f0f0;
}
.categories-btn {
    background-color: #0D3E26;
    color: white;
    border: none;
    padding: 12px 20px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
}
.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
    margin-left: 40px;
}
.nav-links a {
    text-decoration: none;
    color: #444;
    font-size: 13px;
    font-weight: 600;
}
.nav-links a.active {
    color: #0D3E26;
    border-bottom: 2px solid #0D3E26;
}

.hero-section {
    background-color: #F3F4F3;
    margin: 20px 5%;
    border-radius: 8px;
    display: grid;
    grid-template-columns: 1fr 1fr; /* Changed from 1.2fr 0.8fr to fit the wide image */
    align-items: center;
    padding: 60px 80px;
    gap: 40px; /* Adds breathing room between text and image */
}
.hero-title {
    font-size: 48px;
    font-weight: 700;
    color: #0D3E26;
    margin: 15px 0;
}
.btn-shop-now {
    display: inline-block;
    background-color: #0D3E26;
    color: white;
    text-decoration: none;
    padding: 14px 32px;
    border-radius: 4px;
    font-weight: 600;
}
.hero-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover; /* Prevents image distortion */
    border-radius: 6px; /* Smooths image edges to match hero card */
}

/* ==========================================================================
   📱 AUTOMATIC RESPONSIVE BREAKPOINTS (THE GADGET MAGIC)
   ========================================================================== */

/* --- 1. Tablet View Layout (Screens smaller than 1024px) --- */
@media screen and (max-width: 1024px) {
    .main-header {
        flex-wrap: wrap; /* Allows search bar to drop cleanly underneath */
    }
    .search-container {
        order: 3; /* Moves search bar below logo and actions */
        width: 100%;
    }
    .hero-section {
        padding: 40px;
        grid-template-columns: 1fr 1fr; /* Equal split for tablets */
    }
    .hero-title {
        font-size: 36px;
    }
}

/* --- 2. Mobile Phone View Layout (Screens smaller than 768px) --- */
@media screen and (max-width: 768px) {
    .announcement-bar .top-links {
        display: none; /* Hides links on tiny mobile screens to save space */
    }
    .announcement-bar {
        justify-content: center;
        text-align: center;
    }
    
    /* Hide the text label for icons to avoid overcrowding the screen */
    .action-text {
        display: none;
    }
    .header-actions i {
        font-size: 22px; /* Makes icons bigger and easier to tap with fingers */
    }

    /* Drop the dropdown selection from search to fit phone screens */
    .search-select {
        display: none;
    }

    /* Turn the navigation links into a clean, horizontal swipe-menu */
    .nav-links {
        display: flex;
        overflow-x: auto;
        white-space: nowrap;
        margin-left: 15px;
        padding-bottom: 5px;
        gap: 15px;
    }
    .sub-nav {
        justify-content: flex-start;
    }

    /* Stack Hero layout vertically so the image drops smoothly under the text */
    .hero-section {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 40px 20px;
    }
    .hero-content {
        order: 1;
    }
    .hero-image {
        order: 2;
        margin-top: 30px;
    }
    .hero-title {
        font-size: 28px;
    }
}