/* Common CSS for common elements, header and footer */
@charset "utf-8";

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Raleway', sans-serif;
    font-size: 16px;
}

body { 
    font-size: 125%;
    line-height: 1.6;
    color: #3B3F3E; /* Dark Grey */
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow-x: hidden; /* Prevent horizontal scroll */
}

a {
    text-decoration: none;
    color: inherit;
}

main {
    flex: 1;
}

/* Header styles */
header {
    background-color: #fff;
    height: 80px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    width: 100%;
    position: relative; /* For proper positioning of hamburger */
}

.header-container {
    height: 80px;
    display: flex;
    width: 100%;
    justify-content: space-between;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height:80px;
    max-width: 334px;
    flex-shrink: 0;
    margin: 0 0 0 12px;
    /* cursor: pointer; */
}

.logo-img {
    display: flex;
    align-items: center;
    padding: 0 24px;
}

.logo-img img {
    max-width: 334px;
    max-height: 48px;
    object-fit: contain;
}

.main-nav {
    display: flex;
    flex-wrap: nowrap;
    background-color: white;
    padding: 0 30px;
    border-radius: 30px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    width: 400px;
    height: 40px;
    flex-shrink: 0;
    white-space: nowrap;
    justify-content: space-between;
    align-items: center;
    margin-right: 24px;
    align-self: center;
}

.main-nav a {
    color: #B45C50; /* Cheek Pink */
    font-size: 100%;
    font-weight: 500;
    transition: color 0.3s;
}

.main-nav a:hover {
    color: #EDAFA5;
}
/* Header End*/

/* Footer Styles */
footer {
    flex-shrink: 0;
    background-color: #655E5D; /* footer color */
    color: white;
    height: 240px;
    width: 100%;
    margin-top: 0px;
    margin-right: 0px;
    margin-left: 0px;
    margin-bottom: 0px;
}

.footer-container {
    display: grid;
    grid-auto-flow: column;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-areas: "left center right";
    height: 100%;
    width: 100%;
    margin: 0 auto;
    padding: 46px 24px 24px 24px;
}

.footer-left {
    grid-area: left;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-start;
}

.footer-logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height:60px;
    max-width: 304px;
    flex-shrink: 0;
    margin: 0;
} 

.footer-logo-img {
    display: flex;
    align-items: center;
    padding: 0 24px;
}

.footer-logo-img img {
    max-width: 334px;
    max-height: 48px;
    object-fit: contain;
}

.footer-center {
    grid-area: center;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.footer-right {
    grid-area: right;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-end;
}

/* Footer navigation */
.footer-nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

.footer-nav ul li a {
    text-decoration: none;
    color: white;
    font-size: 100%;
    font-weight: 500;
    transition: color 0.3s;
    white-space: nowrap;
}

.footer-nav ul li a:hover {
    color: #EDAFA5;
}

.copyright {
    font-size: 90%;
}

/* Hamburger menu icon */
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 24px;
    cursor: pointer;
    margin-right: 24px;
    z-index: 101;
    position: relative;
}

.hamburger-menu span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: #B45C50;
    border-radius: 3px;
    transition: all 0.3s ease;
    position: absolute;
    left: 0;
}

.hamburger-menu span:nth-child(1) {
    top: 0;
    transform-origin: center;
}

.hamburger-menu span:nth-child(2) {
    top: 10.5px;
    transform-origin: center;
}

.hamburger-menu span:nth-child(3) {
    top: 21px;
    transform-origin: center;
}

/* Hamburger active state */
.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg);
    top: 10.5px;
}

.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg);
    top: 10.5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Header mobile styles */
    header {
        height: 80px;
        padding: 0;
    }
    
    .header-container {
        height: 80px;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0 16px;
        position: relative;
    }
    
    .logo-container {
        max-width: 70%;
        margin: 0;
        padding: 0;
    }
    
    .logo-img {
        padding: 0 16px;
    }
    
    .logo-img img {
        max-width: 220px;
        max-height: 42px;
    }
    
    /* Hamburger menu */
    .hamburger-menu {
        display: flex;
        position: absolute;
        right: 16px;
        top: 28px;
    }
    
    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background-color: white;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 60px 30px;
        transition: right 0.3s ease;
        box-shadow: -5px 0 10px rgba(0, 0, 0, 0.1);
        margin: 0;
        border-radius: 0;
        gap: 30px;
        z-index: 100;
    }
    
    .main-nav.active {
        right: 0;
    }
    
    .main-nav a {
        font-size: 200%;
    }
    
    /* Overlay when menu is open */
    .menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 99;
    }
    
    .menu-overlay.active {
        display: block;
    }
    
    /* Footer mobile styles */
    footer {
        height: auto;
        padding: 16px 20px;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        grid-template-areas: 
            "left"
            "center"
            "right";
        gap: 20px;
    }

    .footer-left {
        justify-content: center;
        align-items: center;
    }
    
    .footer-logo-container {
        width: 100%;
        justify-content: center;
        margin: 0 auto;
    }
      
    .footer-logo-img {
        display: flex;
        justify-content: center;
    }
    
    .footer-logo-img img {
        max-width: 200px;
    }

    .footer-center, .footer-right {
        justify-content: center;
        align-items: center;
    }
    
    .footer-center {
        padding-top: 8px;
    }
    
    .footer-nav ul {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
}

/* Extra small devices (460px and below) */
@media (max-width: 460px) {
    body {
        overflow-x: hidden;
    }
    
    /* Header small screen styles */
    header {
        width: 100%;
        overflow-x: visible;
    }
    
    .header-container {
        width: 100%;
        padding: 0 10px;
    }
    
    .logo-container {
        max-width: 65%;
        margin: 0;
    }
    
    .logo-img {
        padding: 0 12px;
    }
    
    .logo-img img {
        max-width: 180px;
        max-height: 36px;
    }

    
    /* Ensure hamburger menu is always visible */
    .hamburger-menu {
        display: flex;
        position: absolute;
        right: 10px;
        top: 50%; /* Center vertically */
        transform: translateY(-50%); /* Perfect vertical centering */
        z-index: 1001;
    }
    
    /* Reinforce the menu positioning */
    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        z-index: 1000;
    }
    
    .main-nav.active {
        right: 0;
    }
   
    .main-nav a {
        font-size: 100%;
    }
    
    /* Footer small screen styles */
    footer {
        padding: 16px 10px;
    }
    
    .footer-container {
        padding: 30px 10px 20px 10px;
    }
    
    .footer-logo-text {
        font-size: 120%;
    }
    
    .footer-nav ul {
        gap: 10px;
    }
    
    .footer-nav ul li a {
        font-size: 90%;
    }
    
    .copyright {
        font-size: 80%;
        text-align: center;
        margin-top: 10px;
    }
}