/**
 * Hoysala Seva Trust - Main Styles
 * Colour scheme from HST logo: dark blue + cyan/teal
 */

:root {
    /* Logo colours: dark blue (primary), cyan (accent) */
    --primary: #1a4a82;
    --primary-dark: #0f3460;
    --accent: #35b5d1;
    --accent-light: #3cc0e7;
    --secondary: #1a4a82;
    --secondary-light: #2563a8;
    --light-bg: #f0f7fa;
    --nav-bg: #fff;
    --dark-text: #1e293b;
    --muted: #64748b;
    /* Program circles – logo palette */
    --program-blue: #1a4a82;
    --program-cyan: #35b5d1;
    --program-teal: #0d9488;
    --program-lightblue: #0ea5e9;
}

body {
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    color: var(--dark-text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ========== YFS-style Navbar ========== */
.yfs-nav {
    background: var(--nav-bg) !important;
    padding: 0.5rem 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.brand-block {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    color: var(--dark-text) !important;
}
.brand-logo-img {
    height: 52px;
    width: auto;
    max-width: 120px;
    object-fit: contain;
    flex-shrink: 0;
}
.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}
.brand-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dark-text);
}
.brand-tagline {
    font-size: 0.75rem;
    color: var(--muted);
    font-weight: 400;
}
.brand-block:hover .brand-name { color: var(--primary) !important; }
.brand-block:hover .brand-tagline { color: var(--muted) !important; }

.yfs-nav .nav-link {
    font-weight: 500;
    color: var(--dark-text) !important;
    padding: 0.5rem 0.75rem !important;
}
/* Dropdown toggle as button – look like nav link, no button chrome */
.yfs-nav .dropdown-toggle.nav-link {
    background: none;
    border: none;
    cursor: pointer;
    font-size: inherit;
}
.yfs-nav .dropdown-toggle.nav-link:focus {
    outline: none;
    box-shadow: none;
}
.yfs-nav .nav-link:hover,
.yfs-nav .nav-link.active {
    color: var(--accent) !important;
}
.yfs-nav .dropdown-menu {
    border: none;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 0.35rem 0;
    min-width: 220px;
    display: none;
}
/* Show when Bootstrap adds .show to menu or parent (click to open) */
.yfs-nav .dropdown.show .dropdown-menu,
.yfs-nav .dropdown-menu.show {
    display: block !important;
}
.yfs-nav .dropdown-menu li {
    display: block;
}
.yfs-nav .dropdown-item {
    display: block;
    width: 100%;
    color: var(--dark-text);
    padding: 0.5rem 1rem;
    white-space: nowrap;
}
.yfs-nav .dropdown-item:hover {
    background: var(--light-bg);
    color: var(--accent);
}

/* Donate = filled dark blue, Volunteer = outlined cyan */
.btn-donate {
    background: var(--primary) !important;
    border: 2px solid var(--primary);
    color: #fff !important;
    font-weight: 600;
    padding: 0.5rem 1.25rem;
    border-radius: 6px;
    margin-right: 0.5rem;
}
.btn-donate:hover {
    background: var(--primary-dark) !important;
    border-color: var(--primary-dark);
    color: #fff !important;
}
.btn-volunteer-outline {
    background: transparent !important;
    border: 2px solid var(--accent);
    color: var(--accent) !important;
    font-weight: 600;
    padding: 0.5rem 1.25rem;
    border-radius: 6px;
}
.btn-volunteer-outline:hover {
    background: var(--accent) !important;
    color: #fff !important;
}
.navbar-cta {
    margin-left: 0.5rem;
}

/* Legacy volunteer button (other pages) */
.btn-volunteer {
    background: var(--primary) !important;
    border-color: var(--primary);
    color: #fff !important;
    font-weight: 600;
    padding: 0.5rem 1.25rem;
    border-radius: 6px;
}
.btn-volunteer:hover {
    background: var(--primary-dark) !important;
    border-color: var(--primary-dark);
    color: #fff !important;
}

/* ========== Hero - YFS style: hands image + dark overlay + cursive text ========== */
.hero-banner {
    position: relative;
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Hero slideshow (carousel) */
.hero-slideshow {
    position: relative;
    min-height: 75vh;
    overflow: hidden;
}
.hero-slideshow .carousel,
.hero-slideshow .carousel-inner,
.hero-slideshow .carousel-item {
    height: 75vh;
    min-height: 400px;
}
.hero-slideshow .carousel-item {
    position: relative;
}
.hero-slideshow .slide-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.hero-slideshow .carousel-caption {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    padding: 2rem 1rem;
    z-index: 2;
}
.hero-slideshow .hero-title {
    font-family: 'Dancing Script', cursive;
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 700;
    color: #facc15;
    text-shadow: 0 2px 8px rgba(0,0,0,0.6), 0 0 20px rgba(0,0,0,0.4);
    margin-bottom: 0.25em;
    line-height: 1.2;
}
.hero-slideshow .hero-sub {
    font-family: 'Dancing Script', cursive;
    font-size: clamp(1.5rem, 3.5vw, 2.5rem);
    color: #fff;
    margin-bottom: 1rem;
    text-shadow: 0 2px 6px rgba(0,0,0,0.6);
}
.hero-slideshow .lead {
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    color: rgba(255,255,255,0.95);
    margin-bottom: 1.5rem;
    text-shadow: 0 1px 4px rgba(0,0,0,0.5);
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}
.hero-slideshow .hero-buttons .btn {
    padding: 0.75rem 1.75rem;
    font-weight: 600;
    border-radius: 6px;
    margin: 0 0.35rem 0.5rem;
}
.hero-slideshow .carousel-indicators {
    z-index: 3;
}
.hero-slideshow .carousel-control-prev,
.hero-slideshow .carousel-control-next {
    z-index: 3;
}
.hero-banner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url('https://images.unsplash.com/photo-1559027615-cd4628902d4a?w=1920') center/cover no-repeat;
    z-index: 0;
}
.hero-banner::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, rgba(26, 74, 130, 0.78) 0%, rgba(15, 52, 96, 0.65) 100%);
    z-index: 1;
}
.hero-banner .container {
    position: relative;
    z-index: 2;
    text-align: center;
}
.hero-banner .hero-title {
    font-family: 'Dancing Script', cursive;
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 700;
    color: #facc15;
    text-shadow: 0 2px 20px rgba(0,0,0,0.4);
    margin-bottom: 0.25em;
    line-height: 1.2;
}
.hero-banner .hero-title .heart {
    color: var(--accent-light);
    display: inline-block;
}
.hero-banner .hero-sub {
    font-family: 'Dancing Script', cursive;
    font-size: clamp(1.5rem, 3.5vw, 2.5rem);
    color: #bae6fd;
    margin-bottom: 1.5rem;
}
.hero-banner .lead {
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 1.5rem;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}
.hero-banner .btn {
    padding: 0.75rem 1.75rem;
    font-weight: 600;
    border-radius: 6px;
    margin: 0 0.35rem 0.5rem;
}
.hero-banner .btn-primary {
    background: var(--primary);
    border-color: var(--primary);
}
.hero-banner .btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}
.hero-banner .btn-outline-light {
    border-width: 2px;
}
.hero-banner .btn-outline-light:hover {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

/* Program circles - overlap bottom of hero (YFS style) */
.hero-with-circles {
    padding-bottom: 6rem;
}
.program-circles-wrap {
    position: relative;
    z-index: 3;
    margin-top: -5rem;
}
.program-circle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}
.program-circle:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
    color: #fff;
}
.program-circle .circle-icon {
    font-size: 2.25rem;
    margin-bottom: 0.35rem;
}
.program-circle .circle-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-align: center;
    line-height: 1.2;
}
.program-circle.education { background: var(--program-blue); }
.program-circle.health { background: var(--program-cyan); }
.program-circle.environment { background: var(--program-teal); }
.program-circle.livelihood { background: var(--program-lightblue); }
@media (max-width: 768px) {
    .program-circle { width: 110px; height: 110px; font-size: 0.65rem; }
    .program-circle .circle-icon { font-size: 1.75rem; }
}

/* Section spacing - match YFS rhythm */
section {
    padding: 4rem 0;
}
.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}
.section-subtitle {
    color: var(--muted);
    margin-bottom: 2.5rem;
}

/* Impact numbers - stat cards */
.impact-section {
    background: var(--secondary);
    color: #fff;
    padding: 4rem 0;
}
.impact-section .stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-light);
    line-height: 1.2;
}
.impact-section .stat-label {
    font-size: 1rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Program cards - image on top, content below */
.program-card {
    border: none;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    height: 100%;
}
.program-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}
.program-card .card-img-top {
    height: 200px;
    object-fit: cover;
    background: var(--light-bg);
}
.program-card .card-title {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.15rem;
}
.program-card .card-text {
    color: var(--muted);
    font-size: 0.95rem;
}
.program-card .btn {
    font-weight: 600;
    color: var(--accent);
    padding: 0;
}
.program-card .btn:hover {
    color: var(--primary);
}

/* Initiatives section */
.initiative-card {
    border-left: 4px solid var(--primary);
    padding-left: 1rem;
    margin-bottom: 1.5rem;
}
.initiative-card h6 {
    font-weight: 700;
    color: var(--secondary);
}

/* Testimonials - carousel/cards */
.testimonial-card {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    height: 100%;
    border: 1px solid #eee;
}
.testimonial-card .quote {
    color: var(--muted);
    font-style: italic;
    margin-bottom: 1rem;
}
.testimonial-card .name {
    font-weight: 700;
    color: var(--secondary);
}
.testimonial-card .meta {
    font-size: 0.85rem;
    color: var(--muted);
}

/* Events list */
.event-card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    overflow: hidden;
    transition: box-shadow 0.25s ease;
}
.event-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}
.event-card .event-date {
    background: var(--primary);
    color: #fff;
    text-align: center;
    padding: 0.75rem;
    font-weight: 700;
    font-size: 0.9rem;
}
.event-card .card-body {
    padding: 1.25rem;
}

/* Partners / sponsors */
.partners-section {
    background: var(--light-bg);
    padding: 4rem 0;
}
.partner-logo {
    height: 60px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
}
.partner-logo:hover {
    filter: grayscale(0);
    opacity: 1;
}

/* Footer */
.footer {
    background: var(--secondary);
    color: #fff;
    margin-top: auto;
}
.footer a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
}
.footer a:hover {
    color: #fff;
    text-decoration: underline;
}
.footer-brand {
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

/* Buttons global – logo colours */
.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
}
.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}
.btn-outline-primary {
    border-color: var(--accent);
    color: var(--accent);
}
.btn-outline-primary:hover {
    background: var(--accent);
    color: #fff;
}

/* Page headers (inner pages) */
.page-header {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
    color: #fff;
    padding: 3rem 0;
    margin-bottom: 2rem;
}
.page-header h1 {
    font-size: 2.25rem;
    font-weight: 700;
}

/* Forms */
.form-control:focus, .form-select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 0.2rem rgba(53, 181, 209, 0.25);
}

/* About - timeline */
.timeline-item {
    position: relative;
    padding-left: 2rem;
    padding-bottom: 2rem;
}
.timeline-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.25rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent);
}
.timeline-item::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 1.25rem;
    bottom: 0;
    width: 2px;
    background: #dee2e6;
}
.timeline-item:last-child::after {
    display: none;
}

/* Detail page image */
.detail-hero-img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 8px;
}

/* Override Bootstrap primary to logo dark blue */
.text-primary { color: var(--primary) !important; }
.bg-primary { background-color: var(--primary) !important; }

/* Utilities */
.text-white-50 { color: rgba(255, 255, 255, 0.75) !important; }

/* Alerts */
.alert-success { border-left: 4px solid #198754; }
.alert-danger { border-left: 4px solid #dc3545; }
