/* Brand Colors of the SCSD */
:root {
    --scsd-teal: #2cb2a0;
    --scsd-blue: #0071b9;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Navbar Styling */
.navbar {
    transition: background 0.3s ease;
    padding-top: 20px;
}

.nav-link {
    font-size: 0.9rem;
    margin: 0 10px;
}

/* Custom Button */
.btn-primary-scsd {
    background-color: var(--scsd-blue);
    border-color: var(--scsd-blue);
    color: white;
}

/* Hero Section with Image Background */
.hero-section {
    position: relative;
    height: 100vh; /* Full screen height */
    background: url('https://images.unsplash.com/photo-1551076805-e1869033e561?q=80&w=2000') no-repeat center center/cover;
    display: flex;
    align-items: center;
}

/* Dark overlay to make white text pop */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4); 
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.display-2 {
    line-height: 1.1;
}

/* Footer Specific Styling */
.footer-section {
    background-color: #1a1d21; /* Very dark grey, almost black */
    color: #ffffff;
}

.text-teal {
    color: var(--scsd-teal);
}

.text-light-muted {
    color: #b0b3b8; /* Soft grey text for readability */
    font-size: 0.95rem;
}

.footer-link {
    color: #ffffff;
    text-decoration: none;
    display: block;
    margin-bottom: 10px;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--scsd-teal);
}

.social-icon {
    color: white;
    font-size: 1.2rem;
    transition: transform 0.3s ease;
    display: inline-block;
}

.social-icon:hover {
    color: var(--scsd-teal);
    transform: translateY(-3px);
}

.btn-teal {
    background-color: var(--scsd-teal);
    color: white;
    border: none;
}

.btn-teal:hover {
    background-color: var(--scsd-blue);
    color: white;
}

html {
    scroll-behavior: smooth;
}

/* Also adding a small fix for the primary-scsd outline button */
.btn-outline-primary-scsd {
    border: 2px solid var(--scsd-blue);
    color: var(--scsd-blue);
    font-weight: bold;
}

.btn-outline-primary-scsd:hover {
    background-color: var(--scsd-blue);
    color: white;
}

/* 1. The 'Glass' effect for the mobile menu */
@media (max-width: 991px) {
    .navbar-collapse {
        background: rgba(0, 0, 0, 0.85); /* Dark transparent background */
        padding: 20px;
        border-radius: 10px;
        margin-top: 15px;
        backdrop-filter: blur(10px); /* Blurs the image behind the menu */
    }
}

/* 2. Style for when the user scrolls down */
.navbar.scrolled {
    background: rgba(26, 29, 33, 0.95) !important; /* Dark solid brand color */
    padding-top: 10px;
    padding-bottom: 10px;
    box-shadow: 0 4px 12px rgba(0, 255, 225, 0.1);
}

/* Teal Brand Overlay */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* This creates a gradient from Teal to the Deep Blue at a 45-degree angle */
    background: linear-gradient(
        45deg, 
        rgba(44, 178, 160, 0.85), /* Your Teal @ 85% opacity */
        rgba(0, 113, 185, 0.7)    /* Your Blue @ 70% opacity */
    ); 
    z-index: 1;
}

/* Ensure the text stays crisp on top of the teal */
.hero-content h1 {
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2); /* Subtle shadow for depth */
}

/* Timeline Container */
.main-timeline {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
}

/* The vertical line */
.main-timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--scsd-blue);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.horizontal-timeline-wrapper {
    overflow-x: auto; /* Allows swiping on mobile */
    padding: 40px 0;
    -webkit-overflow-scrolling: touch;
}

/* Hide scrollbar but keep functionality */
.horizontal-timeline-wrapper::-webkit-scrollbar {
    display: none;
}

.horizontal-timeline {
    display: flex;
    position: relative;
    min-width: 1000px; /* Ensures it stays wide enough to be a timeline */
    justify-content: space-between;
    padding: 0 50px;
}

.timeline-line {
    position: absolute;
    top: 30px;
    left: 50px;
    right: 50px;
    height: 4px;
    background: var(--scsd-blue);
    z-index: 1;
}

.timeline-stop {
    position: relative;
    width: 220px;
    z-index: 2;
    text-align: center;
}

.stop-dot {
    width: 20px;
    height: 20px;
    background: white;
    border: 4px solid var(--scsd-teal);
    border-radius: 50%;
    margin: 22px auto 20px; /* Centers dot on the line */
    transition: all 0.3s ease;
}

.timeline-stop:hover .stop-dot {
    background: var(--scsd-teal);
    transform: scale(1.3);
}

.stop-content {
    background: white;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.stop-date {
    font-weight: 800;
    color: var(--scsd-teal);
    display: block;
    margin-bottom: 5px;
}

.stop-content h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--scsd-blue);
}

.stop-content p {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0;
}

/* Legacy Highlight */
.legacy-stop .stop-dot {
    border-color: #dc3545; /* Reddish tone for the tragic loss */
}

/* Theory of Change Styling */
.toc-card {
    background: #ffffff;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 5px solid transparent;
}

/* Hover effect to engage the user */
.toc-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-top: 5px solid var(--scsd-teal);
}

.toc-card h5 {
    color: var(--scsd-teal);
    letter-spacing: 0.5px;
}

/* Special styling for the 'arrow' blocks from your image */
.arrow-block {
    background-color: var(--scsd-blue);
    color: #ffffff;
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 0.9rem;
    position: relative;
    clip-path: polygon(0% 0%, 90% 0%, 100% 50%, 90% 100%, 0% 100%); /* Recreates the arrow shape using CSS */
    margin-bottom: 5px;
    font-weight: 500;
}

/* Specific blue column styling helper */
.toc-blue .toc-list li {
    color: #ffffff;
}

/* Icon list styling */
.toc-list {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}

.toc-list li {
    font-size: 0.9rem;
    margin-bottom: 12px;
    color: #555555;
    position: relative;
    padding-left: 20px;
}

.toc-list li::before {
    content: "●"; /* A soft bullet point */
    color: var(--scsd-blue);
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Final Outcome Box */
.toc-outcome {
    background-color: rgba(44, 178, 160, 0.1); /* Light Teal background */
    border-radius: 10px;
    border: 2px solid var(--scsd-teal);
    transition: all 0.3s ease;
}

.toc-outcome:hover {
    background-color: rgba(44, 178, 160, 0.2);
}

/* Custom Dropdown Styling */
.dropdown-menu {
    background: rgba(26, 29, 33, 0.9); /* Dark theme matching your footer */
    backdrop-filter: blur(10px); /* Frosted glass effect */
    padding: 15px;
    border-radius: 12px;
    margin-top: 10px !important; /* Space from the nav bar */
}

.dropdown-item {
    color: rgba(255, 255, 255, 0.8) !important;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 10px 20px;
    transition: all 0.2s ease;
    border-radius: 8px;
}

.dropdown-item:hover {
    background-color: var(--scsd-teal) !important;
    color: white !important;
    transform: translateX(5px); /* Subtle slide-in effect */
}

/* Add a small arrow pointing up to the nav link */
.dropdown-menu::before {
    content: "";
    position: absolute;
    top: -8px;
    left: 20px;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid rgba(26, 29, 33, 0.9);
}

@media (min-width: 992px) {
    .nav-item.dropdown:hover .dropdown-menu {
        display: block;
        animation: fadeIn 0.3s ease;
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Work Page Header */
.work-header {
    height: 40vh;
    background: linear-gradient(rgba(0, 113, 185, 0.9), rgba(44, 178, 160, 0.9)), 
                url('https://images.unsplash.com/photo-1579154235823-6b1bc74c8df3?q=80&w=2000');
    background-size: cover;
    background-position: center;
}

/* Specific Card style for Our Work */
.work-card {
    padding: 30px;
    background: white;
    border-radius: 15px;
    border-left: 4px solid var(--scsd-teal);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.work-card:hover {
    transform: translateX(10px);
}

.project-item {
    border-radius: 15px;
    overflow: hidden;
    background: white;
}

.bg-teal-soft {
    background-color: rgba(44, 178, 160, 0.1);
}

/* Custom Styles for Projects Section */
:root {
    --scsd-blue: #0A71B6;
    --scsd-teal: #2AB1AA;
}

.project-item {
    transition: all 0.3s ease;
    border: 1px solid #f1f3f5;
}

.project-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(10, 113, 182, 0.12) !important;
}

.scsd-blue-text {
    color: var(--scsd-blue) !important;
}

.text-teal {
    color: var(--scsd-teal) !important;
}

/* Overlay & Image Transition */
.project-overlay {
    transition: opacity 0.4s ease;
}

.project-img-wrapper img {
    transition: transform 0.6s ease;
}

.project-item:hover .project-overlay {
    opacity: 0; /* Makes the brand color fade on hover */
}

.project-item:hover .project-img-wrapper img {
    transform: scale(1.08); /* Small zoom effect on the image */
}

/* Required for image aspect ratio stability */
.object-fit-cover {
    object-fit: cover;
}

/* Impact Card Styling */
.impact-card {
    background: #ffffff;
    padding: 2rem 1.5rem;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    border-bottom: 4px solid transparent;
}

.impact-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-bottom: 4px solid var(--scsd-teal);
}

.stat-number {
    font-size: 2.2rem;
    color: var(--scsd-blue);
}

.stat-title {
    color: var(--scsd-teal);
    letter-spacing: 1px;
}

/* Scroll Animation Classes */
.impact-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.impact-animate.show {
    opacity: 1;
    transform: translateY(0);
}