/* Import Google Fonts for typography */
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

/* Reset default browser styles and set box-sizing */
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

/* Body layout and font */
body {
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Poppins', sans-serif;
    height: 97vh;
    background: #f5f5f5;
}

/* Main navbar section container */
.navbar-section {
    position: relative;
    width: 100%;
    height: 70vh;
    margin: 0 6rem;
    border: 1px solid #000;
    overflow: hidden;
    background: rgb(218, 218, 235);
}

/* Navbar styles */
.navbar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    width: 100%;
    background: purple;
    color: #fff;
    box-shadow: rgba(0, 0, 0, 0.11) 0 4px 10px;
}

/* Logo styles */
.logo {
    margin: auto 2rem;
}

/* Navbar menu container */
.navbar .navbar-menu {
    display: flex;
    justify-content: end;
    margin: 0 1rem;
}

/* Navbar menu items */
.navbar-item {
    list-style: none;
    margin: 0 .1rem;
}

/* Navbar links */
.navbar-item a {
    display: inline-block;
    text-decoration: none;
    color: #fff;
    padding: 1rem 1.3rem;
    font-size: .8rem;
    letter-spacing: 1px;
    transition: color .3s;
}

/* Hover effect for navbar links */
.navbar .navbar-menu a:hover {
    background: rgb(156, 1, 156);
    border-radius: 7px;
}

/* Toggle icon (hamburger/cross) for mobile menu */
.toggle-icon {
    position: absolute;
    right: 0;
    display: none;
    background: #fff;
    align-items: center;
    width: 60px;
    cursor: pointer;
    margin: .6rem 1rem;
    border-radius: 4px;
}

/* Icon styles for hamburger and cross */
.bar-icon,
.cross-icon {
    color: #000;
    font-size: 2rem;
    margin: 0 auto;
}

/* Website Content section */
.content {
    padding: 2rem;
}

/* Heading in content */
.content h2 {
    text-align: center;
    margin: 1rem 0;
    font-size: .1.3rem;
    letter-spacing: 1px;
}

/* Paragraph in content: clamp lines and ellipsis */
.content p {
    display: -webkit-box;
    -webkit-line-clamp: 8;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Responsive styles for mobile screens */
@media screen and (max-width: 968px) {

    /* Hide menu by default on mobile */
    .navbar-menu {
        display: none !important;
    }

    .logo {
        margin: .6rem 1.5rem;
    }

    /* Show toggle icon on mobile */
    .toggle-icon {
        display: flex;
    }

    /* Mobile menu styles */
    .menu {
        display: flex !important;
        position: absolute;
        width: 50%;
        top: 55px;
        left: -17px;
        transform: scaleY(0);
        transform-origin: top;
        transition: transform 0.3s;
        flex-direction: column;
        background: rgba(151, 30, 151, 0.776);
        z-index: 1000;
        opacity: 0;
    }

    /* Show menu when mobile-menu class is active */
    .mobile-menu {
        transform: scaleY(1);
        opacity: 1;
    }

    /* Larger padding for mobile menu links */
    .mobile-menu .navbar-item a {
        padding: 1rem 2rem;
    }

    /* Border and pointer for mobile menu items */
    .mobile-menu .navbar-item {
        border-bottom: 1px solid #000;
        cursor: pointer;
    }

    /* Hide cross icon by default */
    .cross-icon {
        display: none;
    }

    /* Hover effect for mobile menu items */
    .mobile-menu .navbar-item:hover {
        background: rgba(128, 0, 128, 0.833);
    }
}