/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: sans-serif;
}

:root {
    --primary-color: #388e3c; /* A nice green for peace and nature */
    --secondary-color: #fdd835; /* Gold/Yellow for light/spirituality */
    --text-color: #333;
    --light-bg: #f4f4f4;
    --dark-bg: #2e7d32;
}

body {
    line-height: 1.6;
    color: var(--text-color);
    background-color: white;
    scroll-behavior: smooth;
}

/* Navbar Styling */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    background-color: var(--dark-bg);
    color: white;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.logo {
    display: flex;
    align-items: center;
}
.logo img {
    /* scaled up by ~2.1x as requested */
    height: 50px;
    width: auto;
    display: block;
}

.nav-links {
    list-style: none;
    display: flex;
}

.nav-links li a {
    color: white;
    text-decoration: none;
    padding: 0 15px;
    transition: color 0.3s;
}

.nav-links li a:hover {
    color: var(--secondary-color);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 101;
}

@media (max-width: 768px) {
    .navbar {
        padding: 12px 3%;
        flex-wrap: wrap;
    }

    .logo img {
        height: 40px;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 60px;
        left: 0;
        background-color: var(--dark-bg);
        padding: 15px 0;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links li a {
        display: block;
        padding: 12px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .menu-toggle {
        display: block;
    }

    .login-btn {
        width: 100%;
        margin-top: 10px;
    }
}

.login-btn, .logout-btn {
    padding: 8px 15px;
    border: 2px solid white;
    background-color: transparent;
    color: white;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.login-btn:hover, .logout-btn:hover {
    background-color: white;
    color: var(--dark-bg);
}

/* General Section Styling */
.section-padding {
    padding: 60px 5%;
    text-align: center;
}

h1, h2, h3 {
    margin-bottom: 20px;
    color: var(--primary-color);
}
.carousel-container {
    position: relative;
    width: 100%;
    height: 60vh; /* Adjust as needed */
    overflow: hidden;
}

.carousel-slide {
    display: flex;
    width: 100%;
    height: 100%;
    /* In a real app, this would use JS for translation/animation */
}

.carousel-item {
    min-width: 100%;
    height: 100%;
    background: none;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    color: white;
}

/* Hero-specific styles: large image of Radha-Madhava with subtle darkening overlay and center logo */
.hero {
    position: relative;
    width: 100%;
    height: 75vh;
    min-height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.hero-carousel {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}
.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    /* show full image without cropping */
    object-fit: contain;
    object-position: center center;
    background-color: #000; /* letterbox color when aspect ratios differ */
    filter: contrast(1.03) saturate(1.02);
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
}
.hero-image.fade-in {
    opacity: 1;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.0);
    transition: background 1.2s ease-in-out 0.4s;
}
.hero.show-overlay .hero-overlay {
    background: rgba(0,0,0,0.35);
}
.hero-logo {
    position: relative;
    z-index: 3;
    max-width: 60%;
    width: 420px;
    opacity: 0;
    transform: translateY(12px) scale(0.96);
    transition: opacity 1s ease 0.8s, transform 1s ease 0.8s;
    pointer-events: none;
    filter: drop-shadow(0 6px 18px rgba(0,0,0,0.35));
}
.hero.show-overlay .hero-logo {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Responsive tweaks for hero logo */
@media (max-width: 800px) {
    .hero-logo { width: 260px; max-width: 80%; }
    .hero { height: 55vh; }
}

@media (max-width: 600px) {
    .hero {
        height: 50vh;
        min-height: 300px;
    }
    
    .hero-logo {
        width: 180px;
        max-width: 70%;
    }
    
    .hero-image {
        object-fit: cover;
    }
}

.carousel-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.4); /* Dark overlay */
}

.carousel-caption {
    position: relative;
    z-index: 2;
    padding: 20px;
    max-width: 800px;
}

/* Services Section */
.services-intro {
    color: #666;
    font-size: 1.05rem;
    margin-bottom: 40px;
}

.carousel-3d-container {
    perspective: 1000px;
    width: 100%;
    height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 40px 0;
}

.carousel-3d {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
}

.carousel-3d-item {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: rotateY(calc(var(--index) * 60deg)) translateZ(400px);
    transition: all 1.2s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    pointer-events: none;
}

.carousel-3d-item.active {
    opacity: 1;
    pointer-events: auto;
}

.carousel-3d-item.prev {
    opacity: 0.3;
    transform: rotateY(calc(var(--index) * 60deg - 60deg)) translateZ(400px) scale(0.85);
}

.carousel-3d-item.next {
    opacity: 0.3;
    transform: rotateY(calc(var(--index) * 60deg + 60deg)) translateZ(400px) scale(0.85);
}

.service-card-3d {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    text-align: center;
    width: 100%;
    max-width: 380px;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-left: 5px solid var(--primary-color);
    transition: all 0.4s ease;
}

.service-card-3d:hover {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
    transform: translateY(-8px);
}

.service-icon {
    font-size: 3.5rem;
    margin-bottom: 16px;
    display: block;
}

.service-card-3d h3 {
    color: var(--primary-color);
    margin: 12px 0;
    font-size: 1.3rem;
}

.service-card-3d p {
    color: #555;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* Carousel Navigation Dots */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 30px;
    position: relative;
    z-index: 1000;
    pointer-events: auto;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    background-color: transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1001;
    pointer-events: auto;
}

.dot.active {
    background-color: var(--primary-color);
    transform: scale(1.3);
}

.dot:hover {
    background-color: var(--primary-color);
}

/* Responsive 3D Carousel */
@media (max-width: 768px) {
    .carousel-3d-container {
        perspective: none;
        height: auto;
        padding: 20px 0;
    }
    
    .carousel-3d {
        display: flex;
        overflow-x: auto;
        gap: 16px;
        padding: 0 16px 16px;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }
    
    .carousel-3d-item {
        position: static;
        width: 100%;
        min-width: 280px;
        height: auto;
        opacity: 1 !important;
        transform: none !important;
        pointer-events: auto !important;
        transition: none;
        flex-shrink: 0;
    }
    
    .carousel-3d-item.active,
    .carousel-3d-item.prev,
    .carousel-3d-item.next {
        opacity: 1 !important;
        transform: none !important;
    }
    
    .service-card-3d {
        max-width: 100%;
        padding: 24px 16px;
        height: auto;
    }
    
    .service-icon {
        font-size: 2.8rem;
    }
    
    .service-card-3d h3 {
        font-size: 1.1rem;
    }
    
    .service-card-3d p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .carousel-3d {
        gap: 12px;
        padding: 0 12px 12px;
    }
    
    .carousel-3d-item {
        min-width: 260px;
    }
    
    .service-card-3d {
        padding: 20px 12px;
    }
    
    .service-icon {
        font-size: 2.4rem;
    }
    
    .service-card-3d h3 {
        font-size: 1rem;
    }
    
    .service-card-3d p {
        font-size: 0.85rem;
        line-height: 1.5;
    }
    
    .carousel-dots {
        display: none;
    }
}

.service-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}

/* Rules Snippet Section */
.rules-bg {
    background-color: var(--primary-color);
    color: white;
}

.rules-bg h2 {
    color: var(--secondary-color);
}

.rules-highlight {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 40px auto;
    text-align: left;
}

.rule-item {
    display: flex;
    gap: 16px;
    padding: 20px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    transition: all 0.3s ease;
    border-left: 4px solid var(--secondary-color);
}

.rule-item:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.rule-number {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 50px;
    width: 50px;
    height: 50px;
    background-color: var(--secondary-color);
    color: var(--dark-bg);
    border-radius: 50%;
    font-weight: bold;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.rule-content h4 {
    color: var(--secondary-color);
    margin: 0 0 8px 0;
    font-size: 1.1rem;
}

.rule-content p {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
}

@media (max-width: 768px) {
    .rules-highlight {
        grid-template-columns: 1fr;
    }
    
    .rule-item {
        padding: 16px;
    }
}

.cta-button {
    display: inline-block;
    padding: 10px 20px;
    margin-top: 15px;
    background-color: var(--secondary-color);
    color: var(--dark-bg);
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s;
}

.cta-button:hover {
    background-color: #ffeb3b; /* Lighter yellow */
}

/* About Page Specific */
.about-hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-bg) 100%);
    color: white;
    padding: 80px 5%;
    text-align: center;
}

.about-hero h1 {
    color: var(--secondary-color);
    font-size: 2.8rem;
    margin-bottom: 12px;
}

.about-hero p {
    font-size: 1.3rem;
    opacity: 0.95;
}

.about-section {
    background-color: #f4f4f4;
}

.about-section h2 {
    color: var(--primary-color);
}

.about-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.about-card {
    background-color: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary-color);
}

.about-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.about-icon {
    font-size: 3rem;
    margin-bottom: 16px;
    display: block;
}

.about-card h3 {
    color: var(--primary-color);
    margin: 12px 0;
    font-size: 1.4rem;
}

.about-card p {
    color: #555;
    line-height: 1.7;
    margin: 12px 0;
    text-align: left;
}

.about-card ul {
    list-style: none;
    padding: 0;
    text-align: left;
}

.about-card li {
    margin: 12px 0;
    color: #555;
    line-height: 1.6;
}

.about-card strong {
    color: var(--primary-color);
}

@media (max-width: 768px) {
    .about-hero h1 {
        font-size: 2rem;
    }
    
    .about-hero p {
        font-size: 1.1rem;
    }
    
    .about-cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .about-card {
        padding: 20px;
    }
}

.about-card {
    background-color: white;
    padding: 20px;
    border-left: 5px solid var(--primary-color);
}

.rules-list {
    text-align: left;
    max-width: 800px;
    margin: 40px auto;
}

.rules-list ul {
    list-style: disc inside;
    padding-left: 20px;
}

/* Footer Styling */
.footer-bg {
    background-color: var(--text-color);
    color: white;
    padding: 60px 5%;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.footer-section h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 20px;
}

.contact-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.contact-detail {
    flex: 1;
}

.contact-label {
    font-weight: 600;
    margin: 0 0 4px 0;
    color: var(--secondary-color);
}

.contact-detail p {
    margin: 0;
    font-size: 0.95rem;
}

.contact-detail a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
}

.contact-detail a:hover {
    color: var(--secondary-color);
}

.social-links-grid {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px solid var(--secondary-color);
    border-radius: 50%;
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.4rem;
    transition: background-color 0.3s, transform 0.3s;
}

.social-link:hover {
    background-color: var(--secondary-color);
    color: var(--text-color);
    transform: scale(1.1);
}

.social-link i {
    display: block;
}

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

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

.footer-bg p {
    margin-bottom: 10px;
}

.social-links a {
    color: var(--secondary-color);
    text-decoration: none;
    margin: 0 10px;
}

.social-links a:hover {
    text-decoration: underline;
}

/* Mobile Responsive Footer */
@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .footer-section h3 {
        font-size: 1.1rem;
    }
    
    .contact-item {
        flex-direction: column;
        gap: 8px;
    }
    
    .contact-icon {
        font-size: 1.5rem;
    }
    
    .social-links-grid {
        justify-content: center;
    }
    
    .social-link {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }
    
    .footer-links {
        text-align: center;
    }
    
    .footer-links li {
        margin-bottom: 10px;
    }
}

@media (max-width: 480px) {
    .footer-bg {
        padding: 40px 3%;
    }
    
    .footer-section h3 {
        font-size: 1rem;
        margin-bottom: 15px;
    }
    
    .contact-label {
        font-size: 0.9rem;
    }
    
    .contact-detail p {
        font-size: 0.85rem;
    }
    
    .social-link {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}