/* ============================================
   BioBank - Modern Homepage Styles
   ============================================ */

/* Root Variables */
:root {
    --primary-color: #0066CC;
    --secondary-color: #00A86B;
    --dark-color: #1a1a2e;
    --light-color: #f8f9fa;
    --text-dark: #333333;
    --text-light: #666666;
    --gradient-primary: linear-gradient(135deg, #0066CC 0%, #00A86B 100%);
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

/* Navigation Styles */
.navbar {
    background-color: #fff;
    padding: 1rem 0;
    transition: var(--transition);
    z-index: 1000;
    box-shadow: var(--shadow-md);
}

.navbar-brand {
    display: flex;
    align-items: center;
    padding: 0;
}

.navbar-brand img {
    /* Remove filter to show original logo */
    transition: opacity 0.3s ease;
    max-height: 70px;
    width: auto;
}

.navbar-scrolled .navbar-brand img {
    /* Logo remains the same when scrolled */
    opacity: 1;
}

.nav-link {
    color: var(--text-dark) !important;
    font-weight: 500;
    padding: 0.5rem 1.25rem !important;
    transition: var(--transition);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--secondary-color);
    transform: translateX(-50%);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 80%;
}

.nav-link.active {
    color: var(--primary-color) !important;
    font-weight: 600;
}

.nav-link.active::after {
    width: 80%;
    background: var(--primary-color);
}

.navbar-toggler {
    border: 1px solid rgba(0, 0, 0, 0.2) !important;
    background: rgba(255, 255, 255, 0.9) !important;
    padding: 0.25rem 0.5rem !important;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 102, 204, 0.25);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2833, 33, 33, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    width: 24px;
    height: 24px;
    display: block;
}

/* Ensure toggler is visible */
@media (max-width: 991px) {
    .navbar-toggler {
        display: block !important;
        opacity: 1 !important;
        visibility: visible !important;
    }
}

.btn-login {
    background: var(--gradient-primary);
    border: none;
    border-radius: 50px;
    padding: 0.6rem 2rem !important;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.3);
    color: #fff !important;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.4);
}

/* Hero Section */
.hero-section,
.hero-banner {
    position: relative;
    min-height: calc(100vh - 76px);
    color: #fff;
    overflow: hidden;
    margin-top: 76px;
}

/* Carousel Styles */
#heroCarousel {
    height: calc(100vh - 76px);
}

.carousel-inner,
.carousel-item {
    height:  calc(100vh - 76px); 

}

.carousel-item img {
    width: 100%;
    height: calc(100vh - 76px);
    object-fit: cover;
    filter: brightness(0.7);
}

.carousel-caption {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 2;
    width: 90%;
    max-width: 900px;
}

.carousel-indicators {
    bottom: 50px;
}

.carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin: 0 5px;
    background-color: rgba(255, 255, 255, 0.5);
    border: 2px solid #fff;
}

.carousel-indicators button.active {
    background-color: #fff;
}

.carousel-control-prev,
.carousel-control-next {
    width: 5%;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 1;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 50px;
    height: 50px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.9) 0%, rgba(0, 102, 204, 0.8) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.text-gradient {
    background: linear-gradient(135deg, #00A86B, #00D68F);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    font-weight: 400;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons .btn {
    margin: 0.5rem;
    padding: 0.75rem 2rem;
    font-weight: 600;
    border-radius: 50px;
    transition: var(--transition);
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
    box-shadow: 0 4px 15px rgba(0, 102, 204, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.4);
}

.btn-outline-light {
    border: 2px solid #fff;
    background: transparent;
}

.btn-outline-light:hover {
    background: #fff;
    color: var(--primary-color) !important;
}

/* Hero Stats */
.hero-stats {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-item {
    text-align: center;
    color: #fff;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
    margin: 0;
}

/* Services Section */
.services-section {
    background: var(--light-color);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.service-card {
    background: #fff;
    border-radius: 16px;
    padding: 2.5rem;
    text-align: center;
    transition: var(--transition);
    height: 100%;
    box-shadow: var(--shadow-sm);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: #fff;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.service-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.service-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.service-link:hover {
    color: var(--secondary-color);
}

.service-link:hover i {
    transform: translateX(5px);
}

/* Research Section */
.research-section {
    background: #fff;
}

.research-section .lead {
    font-size: 1.125rem;
    color: var(--text-light);
}

.feature-item {
    display: flex;
    align-items: center;
    font-size: 1.05rem;
}

.feature-item i {
    font-size: 1.25rem;
}

.research-image-wrapper {
    position: relative;
}

.research-image-wrapper img {
    width: 100%;
    height: auto;
}

.research-badge {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    background: var(--gradient-primary);
    color: #fff;
    padding: 1rem 2rem;
    border-radius: 50px;
    display: flex;
    align-items: center;
    box-shadow: var(--shadow-md);
}

.research-badge i {
    font-size: 1.5rem;
    margin-right: 0.75rem;
}

/* CTA Section */
.cta-section {
    background: var(--gradient-primary);
    padding: 3rem 0;
    color: #fff;
}

.cta-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.cta-subtitle {
    font-size: 1.125rem;
    opacity: 0.95;
    margin-bottom: 2rem;
}

.cta-section .btn-light {
    background: #fff;
    color: var(--primary-color);
    border: none;
}

.cta-section .btn-light:hover {
    background: var(--light-color);
    transform: translateY(-2px);
}

.cta-section .btn-outline-light {
    border-color: #fff;
    color: #fff;
}

.cta-section .btn-outline-light:hover {
    background: #fff;
    color: var(--primary-color);
}

/* Footer */
.footer {
    background: var(--dark-color);
    color: #fff;
    padding: 3rem 0 2rem;
}

.footer-content {
    padding-bottom: 0;
}

.footer-logo-wrapper {
    margin-bottom: 1.5rem;
}

.footer-logo-wrapper img {
    /* Remove filter to show original logo colors */
    max-height: 80px;
    width: auto;
}

.footer-brand p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
}

.footer-title {
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
    color: #fff;
    font-weight: 600;
}

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

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    font-size: 0.95rem;
}

.footer-links a i {
    margin-right: 0.5rem;
    font-size: 0.75rem;
}

.footer-links a:hover {
    color: #fff;
    transform: translateX(5px);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--gradient-primary);
    transform: translateY(-3px);
}

.contact-item {
    display: flex;
    align-items: start;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

.contact-item i {
    margin-right: 1rem;
    color: var(--secondary-color);
    font-size: 1.1rem;
    margin-top: 0.2rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 3rem;
    padding-top: 2rem;
}

.footer-bottom p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition);
}

.footer-link:hover {
    color: #fff;
}

/* Responsive Design */
@media (max-width: 992px) {
    /* Navigation */
    .navbar {
        padding: 0.75rem 0;
    }
    
    .navbar-brand img {
        max-height: 60px;
    }
    
    /* Navbar Collapse */
    .navbar-collapse {
        background: #fff;
        margin-top: 1rem;
        padding: 1rem 0;
        border-top: 1px solid #eee;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        position: relative;
        z-index: 999;
    }
    
    .navbar-nav {
        align-items: flex-start !important;
    }
    
    .nav-item {
        width: 100%;
    }
    
    .nav-link {
        padding: 0.75rem 1rem !important;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .nav-link:hover {
        background: #f8f9fa;
    }
    
    .nav-item:last-of-type .nav-link {
        border-bottom: none;
    }
    
    /* Hero Section */
    .hero-banner {
        min-height: calc(100vh - 70px);
        margin-top: 70px;
    }
    
    #heroCarousel,
    .carousel-inner,
    .carousel-item {
        height: calc(100vh - 70px);
    }
    
    .carousel-item img {
        height: calc(100vh - 70px);
    }
}

@media (max-width: 768px) {
    /* Navigation */
    .navbar-brand img {
        max-height: 50px;
    }
    
    .nav-link {
        padding: 0.5rem 1rem !important;
        text-align: center;
    }
    
    .btn-login {
        margin-top: 1rem;
        width: 100%;
    }
    
    /* Hero Section */
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        padding: 0 1rem;
    }
    
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        padding: 0 2rem;
    }
    
    .hero-buttons .btn {
        width: 100%;
        margin: 0 !important;
    }
    
    /* Carousel */
    .carousel-caption {
        width: 95%;
        padding: 0 1rem;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        width: 10%;
    }
    
    .carousel-indicators {
        bottom: 30px;
    }
    
    /* Sections */
    .stat-number {
        font-size: 1.75rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .service-card {
        padding: 2rem;
        margin-bottom: 1.5rem;
    }
    
    /* Content Sections */
    .content-section {
        padding: 3rem 0 !important;
    }
    
    .stats-inline {
        gap: 1rem;
    }
    
    .image-wrapper {
        margin-top: 2rem;
    }
    
    /* Footer */
    .footer {
        padding: 2rem 0 1.5rem;
    }
    
    .footer-logo-wrapper img {
        max-height: 60px;
    }
    
    .footer-map {
        height: 200px;
        margin-top: 1rem;
    }
    
    .footer-bottom {
        margin-top: 2rem;
        padding-top: 1.5rem;
    }
    
    /* Page Headers */
    .page-header {
        padding: 30px 0 !important;
        margin-top: 70px;
    }
    
    .page-title {
        font-size: 2rem !important;
    }
    
    .page-subtitle {
        font-size: 1rem !important;
    }
}

@media (max-width: 576px) {
    /* Hero Section */
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
    }
    
    /* Buttons */
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
    
    /* Service Cards */
    .service-card {
        padding: 1.5rem;
    }
    
    .service-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    /* Stats */
    .stats-inline .stat-item {
        flex: 1 1 100%;
    }
    
    /* Footer */
    .contact-item {
        font-size: 0.9rem;
    }
    
    .footer-links {
        font-size: 0.9rem;
    }
}

/* Breadcrumb Styles */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
}

.breadcrumb-item {
    font-size: 1rem;
}

.breadcrumb-item a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: #fff;
}

.breadcrumb-item.active {
    color: #fff;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.6);
    content: "/";
    padding: 0 0.75rem;
}

/* Page Header Common Styles */
.page-header {
    padding: 50px 0 50px !important;
}

.page-title {
    font-size: 3rem !important;
    margin-bottom: 0.75rem !important;
}

.page-subtitle {
    font-size: 1.125rem !important;
    margin-bottom: 1.5rem !important;
}

/* Footer Map */
.footer-map {
    margin-top: 0.5rem;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    height: 250px;
}

.footer-map iframe {
    filter: brightness(0.8) contrast(1.1);
    transition: filter 0.3s ease;
    height: 100%;
}

.footer-map:hover iframe {
    filter: brightness(0.9) contrast(1.1);
}

/* Content Sections */
.content-section {
    position: relative;
    background: #fff;
}

.content-section.bg-light {
    background: var(--light-color);
}

.content-wrapper h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 1.5rem;
}

.content-wrapper .lead {
    font-size: 1.125rem;
    font-weight: 400;
    color: var(--text-light);
    line-height: 1.8;
}

.content-wrapper p {
    color: var(--text-dark);
    line-height: 1.8;
}

/* Stats Inline */
.stats-inline {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.stats-inline .stat-item {
    text-align: left;
}

.stats-inline .stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stats-inline .stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
    margin: 0;
}

/* Service List */
.service-list {
    margin-top: 2rem;
}

.service-item {
    display: flex;
    align-items: start;
    padding: 1rem;
    background: #fff;
    border-radius: 12px;
    transition: var(--transition);
}

.bg-light .service-item {
    background: rgba(255, 255, 255, 0.8);
}

.service-item:hover {
    transform: translateX(10px);
    box-shadow: var(--shadow-md);
}

.service-item i {
    font-size: 1.5rem;
    width: 40px;
    flex-shrink: 0;
}

.service-item h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.25rem;
}

/* Research Areas */
.research-areas {
    margin-top: 2rem;
}

.research-item {
    padding: 1.25rem;
    background: var(--light-color);
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
}

.research-item:hover {
    transform: translateX(10px);
    box-shadow: var(--shadow-md);
    background: #fff;
}

.research-item h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.research-item p {
    margin: 0;
    font-size: 0.95rem;
}

/* Image Wrapper */
.image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
}

.image-wrapper img {
    width: 100%;
    height: auto;
    transition: transform 0.5s ease;
}

.image-wrapper:hover img {
    transform: scale(1.05);
}

.rounded-custom {
    border-radius: 16px !important;
}

/* Responsive Design Updates */
@media (max-width: 768px) {
    .content-wrapper h2 {
        font-size: 2rem;
    }
    
    .stats-inline {
        justify-content: center;
        text-align: center;
    }
    
    .stats-inline .stat-item {
        text-align: center;
        flex: 1 1 calc(33.333% - 1rem);
        min-width: 100px;
    }
    
    .service-item {
        flex-direction: column;
        text-align: center;
    }
    
    .service-item i {
        margin-bottom: 1rem;
    }
    
    .research-item {
        text-align: center;
        border-left: none;
        border-top: 4px solid var(--primary-color);
    }
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    color: #fff;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 102, 204, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* Mobile adjustments for back to top */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
}

/* Utility Classes */
.py-5 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
}

@media (min-width: 768px) {
    .py-5 {
        padding-top: 5rem !important;
        padding-bottom: 5rem !important;
    }
}