/* Core Variables */
:root {
    --primary: #333;
    --accent: #000;
    --bg-profile: #fffaf0;
    /* --transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); */
    --bg-color: #ffffff;
    --text-main: #1a1a1a;
    --text-muted: #666;
    --accent-bg: #fffaf0;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
      /* Color variables for the web pages */
    --light-bg: #f9f9f9;
    --text-main: #333333;
    --text-muted: #666666;
    --fnl-green: #009C99; /* Matches your eco-friendly branding */
    --border-color: #e0e0e0;
    --bg-color: #1a1a1a;
    --text-color: #d1d1d1;
    --accent-color: #007bff38; /* Change this to match fnlhub's brand color */
    --primary: #3D52A0;
    --secondary: #7091E6;
    --grey: #8697C4;
    --light-grey: #ADBBDA;
    --off-white: #EDE8F5;
    /* Sizes variables for all elements */
    --company-logo-width: 100px;
    /* font sizes for  */
    --font-size-extra-sm: 0.6rem;
    --font-size-sm: 1rem;
    --font-size-m: 2rem;
    --font-size-l: 2.24rem;
    --font-size-el: clamp(1rem, 0.4rem + 3vw, 4rem);
    /* Font weights */
    --font-weight-extra-light: 100;
    --font-weight-light: 300;
    --font-weight-medium: 400;
    --font-weight-bold: 600;
    --font-weight-exbold: 800;
    /* line heights */
    --line-height-small: 1.2rem;
    --line-height-medium: 1.6rem;
    --line-height-big: 2rem;
    --glass: rgba(255, 255, 255, 0.1);
    --blur: blur(10px);
    --dark:#111;
    --muted:#777;
    --bg:#fafafa;
}

html {   
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

html, body {
  overflow-x: hidden;
}

body {
    margin: 0;
    padding: 0;
}

 /* Main Scroll Button Container */
#scrollToTopBtn {
  position: fixed;
  bottom: -60px;
  right: 30px;
  width: 40px;
  height: 40px;
  background-color: #009C99;
  border-radius: 50%;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  z-index: 100;
  opacity: 0;
  transition: bottom 0.5s ease, opacity 0.5s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  overflow: visible;
}

#scrollToTopBtn.show {
  bottom: 30px;
  opacity: 1;
}

/* Pulsing Ring (Kirupa style) */
#scrollToTopBtn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  background-color: rgba(77, 255, 246, 0.5);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(1);
  animation: pulse-ring 1.5s infinite;
  z-index: -1;
}

@keyframes pulse-ring {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.6;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.8);
    opacity: 0;
  }
}

#scrollToTopBtn:hover {
  background-color: #009C99;
}

/* Styling the Navigational Bar of the main page*/
nav {
    background-color: rgb(255, 255, 255);
}

nav ul{
    width: 100%;
    list-style: none;
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

nav li {
    height: 70px;
}

nav a {
    height: 100%;
    padding: 0 20px;
    text-decoration: none;
    display: flex;
    align-items: center;
    color: black;
    font-size: 1rem;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: 0.3s ease;
}

nav a.active {
  color: #009C99;
  font-weight: 700;
  border-radius: 5px;
}

nav a:hover {
    background-color: #f0f0f0;
    color: #009C99;
}

nav li:first-child {
    margin-right: auto;
}

/* Update this to match your existing 'nav a' styles precisely */
.nav-label {
    height: 100%;
    padding: 0 20px;
    display: flex;
    align-items: center;
    color: black;
    font-size: 1rem;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    cursor: pointer;
    transition: 0.3s ease;
}

/* Ensure the hover background matches the other links */
.dropdown:hover .nav-label {
    color: #009C99;
}

/* Fix for the icon alignment */
.dropdown-icon {
    display: inline-block;
    margin-left: 8px;
    transition: transform 0.4s ease;
    /* This ensures it doesn't change the line-height of the text */
    line-height: 0; 
}

.comp-logo {
    inline-size: 130px;
}

.home-btn {
    color: #009C99;
}

/* Styling the Sidebar of the main page*/
.sidebar {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 250px;
    z-index: 999;
    background-color: rgba(255, 255, 255, 0.395);
    backdrop-filter: blur(10px);
    box-shadow: -10px 0 10px rgba(0, 0, 0, 0.1);
    display: none;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
}

/* Ensure the sidebar container allows for natural height expansion */
.sidebar li {
    height: auto; /* Changed from 70px to allow content to grow */
    width: 100%;
}

.sidebar li a {
    height: 50px; /* Reduced from 70px for tighter spacing */
    padding: 0 20px;
}

/* Mobile Dropdown specific behavior */
.mobile-dropdown {
    display: flex;
    flex-direction: column; /* Stack header and sub-menu vertically */
    width: 100%;
}

.mobile-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    cursor: pointer;
}

/* The Sub-Menu: Using 'static' so it pushes content down */
.mobile-sub-menu {
    display: none; 
    position: static; /* Vital: This pushes other links down */
    list-style: none;
    padding: 0;
    margin: 0;
    background: rgba(0, 0, 0, 0.03); /* Subtle contrast */
    width: 100%;
}

.mobile-sub-menu li a {
    padding-left: 40px; /* Indent sub-links */
    height: 45px; /* Even tighter spacing for sub-links */
    font-size: 0.95rem;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Toggle state */
.mobile-dropdown.open .mobile-sub-menu {
    display: block;
}

.mobile-dropdown.open .mobile-icon {
    transform: rotate(180deg);
}

.menu-button {
    display: none;
}

/* Dropdown Container */
.dropdown {
    position: relative;
}

/* Hide the menu by default */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 70px; /* Match your 'nav li' height */
    left: 0;
    background-color: #fff;
    min-width: 160px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.1);
    z-index: 1000;
    list-style: none;
    padding: 0;
    border-radius: 0 0 8px 8px;
    border-top: 2px solid var(--fnl-green);
}

/* Style the dropdown links */
.dropdown-menu li {
    height: auto; /* Allow items to shrink to text size */
    width: 100%;
}

.dropdown-menu li a {
    padding: 12px 20px;
    font-size: 0.9rem;
    display: block;
}

/* Show the menu on hover */
.dropdown:hover .dropdown-menu {
    display: block;
    background-color: #dae3e794;
}

/* Ensure the sidebar (mobile) doesn't break */
.sidebar .dropdown-menu {
    position: static;
    display: block; /* Always show in sidebar or use a toggle */
    box-shadow: none;
    padding-left: 20px;
    background: transparent;
}

/* Starting position: Tip pointing UP */
.dropdown-icon {
    margin-left: 8px;
    font-size: 0.9rem;
    display: inline-block;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1); /* Smooth, snappy feel */
    color: inherit;
}

/* Hover position: Rotate 180 degrees to point DOWN */
.dropdown:hover .dropdown-icon {
    transform: rotate(180deg);
    color: var(--fnl-green); /* Optional: changes color when active */
}

/* Ensure the dropdown menu appears correctly */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%; /* Sits right at the bottom of the nav bar */
    left: 0;
    background: white;
    min-width: 180px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    list-style: none;
    padding: 10px 0;
    border-radius: 0 0 8px 8px;
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    display: block;
}

/* Force the active color and weight to show up */
/* nav ul li a.active, 
.sidebar li a.active,
a.active {
    color: #009C99 !important;
    font-weight: 800 !important;
} */

/* Also ensure the parent "About" turns green if a sub-link is active */
.active-parent .nav-label {
    color: #009C99 !important;
}

@media (max-width: 800px) {
    .hideOnMobile{
        display: none;
    }
    .menu-button {
        display: block;
    }
}

@media (max-width: 400px) {
    .sidebar {
        width: 100%;
    }
}

@media (max-width: 600px) {
    .sidebar {
        width: 100%;
    }
}

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

/* Hero Section */
.hero { 
    display: flex; 
    align-items: center; 
    gap: 50px; 
    margin: 60px 0; 
    flex-wrap: wrap; 

}

.hero-text { 
    flex: 1; 
    min-width: 300px; 
}

.hero-text .date { 
    font-size: 14px; 
    color: var(--text-muted); 
    margin-bottom: 15px; 
    display: block; 
}

.hero-text h1 { 
    font-size: 42px; 
    line-height: 1.2; 
    margin-bottom: 20px; 
    transition: var(--transition); 
    cursor: pointer; 
}

.hero-text h1:hover { 
    opacity: 0.7; 
}

.read-btn { 
    padding: 12px 30px; 
    border: 1px solid #000; 
    background: none; 
    border-radius: 8px; 
    cursor: pointer; 
    transition: var(--transition); 
}

.read-btn:hover { 
    background: #000; 
    color: #fff; 
}

.hero-images { 
    flex: 1; 
    position: relative; 
    min-width: 300px; 
    height: 500px; 
}

.hero-images img { 
    border-radius: 15px; 
    object-fit: cover; 
    position: absolute; 
    box-shadow: 0 20px 40px rgba(0,0,0,0.1); 
}

.img-1 { 
    width: 70%; 
    height: 80%; 
    right: 0; 
    top: 0; 
    z-index: 1; 
}

.img-2 { 
    width: 70%; 
    height: 80%; 
    left: 0; 
    bottom: 0; 
    z-index: 2; 
}

/* Trending Slider */
.section-header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-bottom: 30px; 
}

.controls button { 
    background: none; 
    border: none; 
    font-size: 20px; 
    cursor: pointer; 
    margin-left: 15px; 
    opacity: 0.5; 
    transition: 0.3s; 
}

.controls button:hover { 
    opacity: 1; 
}

.trending-slider { 
    overflow: hidden; 
    padding-bottom: 40px; 
}

.slider-track { 
    display: flex; 
    gap: 20px; 
    transition: transform 0.5s ease; 
}

.trend-card { 
    min-width: calc(25% - 15px); 
    position: relative; 
    border-radius: 15px; 
    overflow: hidden; 
    height: 350px; 
    cursor: pointer; 
}

.trend-card img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: var(--transition); 
}

.trend-card:hover img { 
    transform: scale(1.1); 
}

.trend-overlay { 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    right: 0; 
    padding: 20px; 
    background: linear-gradient(transparent, rgba(0,0,0,0.8)); 
    color: #fff; 
}

.trend-overlay span { 
    font-size: 18px; 
    color: #009C99; 
    font-weight: 800; 
}

/* Main Content Grid */
.layout-grid { 
    display: grid; 
    grid-template-columns: 2fr 1fr; 
    gap: 50px; 
    margin-top: 60px; 
}

.layout-grid .content a {
    text-decoration: none;
    color: #007a78; 
}

a.trend-card,
a.blog-post{
    text-decoration: none;
    color: inherit;
    display: block;
}

a.pop-item {
    text-decoration: none;
    color: inherit;
}

/* Blog Post Items */
.blog-post { 
    margin-bottom: 40px; 
    cursor: pointer; 
}

.post-thumb { 
    overflow: hidden; 
    border-radius: 12px; 
    height: 300px; 
    margin-bottom: 15px; 
}

.post-thumb img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: var(--transition); 
}

.blog-post:hover .post-thumb img { 
    transform: scale(1.08); 
}

.blog-post h3 { 
    transition: var(--fnl-green); 
    margin-bottom: 10px; 
}

.blog-post:hover h3 { 
    color: var(--text-muted); 
}

.blog-post p {
    color: #000000;
}

/* Sidebar Profile */
.profile-widget { 
    background: #009c9913; 
    padding: 40px; 
    border-radius: 20px; 
    text-align: center; 
    margin-bottom: 40px; 
}

.profile-widget img { 
    width: 80px; 
    height: 80px; 
    border-radius: 50%; 
    margin-bottom: 15px; 
}

.profile-widget h3 { 
    margin-bottom: 10px; 
}

.profile-widget p { 
    font-size: 14px; 
    color: var(--text-muted); 
    margin-bottom: 20px; 
}

.search-widget {
    margin-bottom: 30px;
}

.search-box {
    display: flex;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition);
}

.search-box:focus-within {
    border-color: var(--fnl-green);
    box-shadow: 0 0 8px rgba(0, 156, 153, 0.2);
}

.search-box input {
    border: none;
    padding: 12px 15px;
    outline: none;
    width: 100%;
    font-size: 0.95rem;
}

.search-box button {
    background: var(--fnl-green);
    color: white;
    border: none;
    padding: 0 20px;
    cursor: pointer;
    transition: 0.3s;
}

.search-box button:hover {
    background: #007a78;
}

/* Popular Posts & Categories */
.widget h4 { 
    border-bottom: 1px solid #eee; 
    padding-bottom: 10px; 
    margin-bottom: 20px; 
}

.pop-item { 
    display: flex; 
    gap: 15px; 
    margin-bottom: 20px; 
    cursor: pointer; 
}

.pop-item img { 
    width: 60px; 
    height: 60px; 
    border-radius: 8px; 
    object-fit: cover; 
}

.pop-item h5 { 
    font-size: 14px; 
    line-height: 1.3; 
    transition: 0.3s; 
}

.pop-item:hover h5 { 
    color: var(--text-muted); 
}

.cat-item { 
    display: flex; 
    justify-content: space-between; 
    padding: 12px 15px; 
    background: #009c999d; 
    border-radius: 8px; 
    margin-bottom: 8px; 
    transition: var(--transition); 
    cursor: pointer; 
}

.cat-item:hover { 
    background: #dcf0ed; 
    padding-left: 20px; 
}

@media (max-width: 900px) {
    .layout-grid { grid-template-columns: 1fr; }
    .hero-images { display: none; }
    .trend-card { min-width: calc(50% - 10px); }
}


/* Styling the footer */
.footer {
  background-color: var(--bg-color);
  color: var(--text-color);
  /* background-color: var(--light-bg);
  color: var(--text-main); */
  padding: 60px 0 20px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding: 0 20px;
}

.footer-logo {
    color: #fff;
    margin-bottom: 20px;
}

.footer-logo span {
    color: var(--accent-color);
}

.footer-section h3 {
    color: #009C99;
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: var(--text-color);
    text-decoration: none;
    transition: 0.3s;
}

.footer-section a:hover {
    color: var(--accent-color);
    padding-left: 5px;
}

/* Social Icons */
footer .social-icons {
    margin-top: 20px;
}

footer .social-icons a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: #333;
    color: #ffffff;
    text-align: center;
    line-height: 40px;
    border-radius: 50%;
    margin-right: 10px;
    transition: 0.3s;
}

.social-icons a.facebook {
    background-color: #1778F2;
}

.social-icons a.instagram {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

footer .social-icons a.twitter {
    background-color: #000000;
}

.social-icons a.whatsapp {
    background-color: #25D366;
}

.social-icons a.linkedin {
    background-color: #17a9ec;
}

.social-icons a.youtube {
    background-color: #FF0000;
}

.social-icons a:hover {
    background: var(--accent-color);
    transform: translateY(-5px);
}

.social-icons a.whatsapp:hover {
    background-color: #009C99;
    border-color: #009C99;
    color: #fff;
}

/* Bottom Bar */
.footer-bottom {
    text-align: center;
    margin-top: 50px;
    padding-top: 20px;
    border-top: 1px solid #333;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
}
