/* Custom CSS for Church Website */

/* Root Variables */
:root {
    --primary-color: #2c5282;
    --secondary-color: #3182ce;
    --accent-color: #d69e2e;
    --light-bg: #f7fafc;
    --dark-bg: #2d3748;
    --text-primary: #2d3748;
    --text-secondary: #4a5568;
    --text-muted: #718096;
    --border-color: #e2e8f0;
    --shadow-light: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-medium: 0 4px 6px rgba(0, 0, 0, 0.07), 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
}

/* Typography */
body {
    font-family: 'Open Sans', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: #ffffff;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Crimson Text', serif;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.display-1, .display-2, .display-3, .display-4 {
    font-family: 'Crimson Text', serif;
}

/* Bootstrap Color Overrides */
.text-primary {
    color: var(--primary-color) !important;
}

.bg-primary {
    background-color: var(--primary-color) !important;
}

.btn-primary {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: white;
    font-weight: 600;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #c28724;
    border-color: #c28724;
    color: white;
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Hero Carousel Styles */
.hero-carousel {
    position: relative;
    height: 85vh;
    min-height: 600px;
    overflow: hidden;
}

.hero-carousel .carousel {
    height: 100%;
}

.hero-carousel .carousel-inner {
    height: 100%;
}

.hero-carousel .carousel-item {
    height: 100%;
}

.hero-carousel .carousel-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-carousel .carousel-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(44, 82, 130, 0.75) 0%,
        rgba(44, 82, 130, 0.65) 50%,
        rgba(214, 158, 46, 0.5) 100%
    );
}

.hero-carousel .hero-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    z-index: 10;
}

/* Navigation */
.navbar {
    padding: 1rem 0;
    box-shadow: var(--shadow-light);
}

.navbar-brand {
    font-family: 'Crimson Text', serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    color: var(--text-primary) !important;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-color) !important;
    background-color: rgba(44, 82, 130, 0.1);
    border-radius: 0.375rem;
}

/* Cards */
.card {
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-heavy);
}

.card-header {
    border-bottom: none;
    font-weight: 600;
}

/* Feature Icons */
.feature-icon {
    width: 60px;
    height: 60px;
    background: rgba(44, 82, 130, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

/* Buttons */
.btn {
    border-radius: 0.5rem;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: all 0.3s ease;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-outline-light {
    border: 2px solid white;
    color: white;
    font-weight: 600;
}

.btn-outline-light:hover {
    background-color: white;
    color: var(--primary-color);
}

/* Shadows */
.shadow-sm {
    box-shadow: var(--shadow-light) !important;
}

.shadow {
    box-shadow: var(--shadow-medium) !important;
}

.shadow-lg {
    box-shadow: var(--shadow-heavy) !important;
}

/* Breadcrumbs */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    font-weight: bold;
}

.text-white-75 {
    color: rgba(255, 255, 255, 0.75) !important;
}

.text-white-50 {
    color: rgba(255, 255, 255, 0.5) !important;
}

/* Footer */
footer {
    background-color: var(--dark-bg) !important;
}

footer h5, footer h6 {
    color: white;
}

/* Service times styling */
.service-time {
    border-left: 4px solid var(--accent-color);
    padding-left: 1rem;
    margin-bottom: 1rem;
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-carousel {
        height: 70vh;
        min-height: 500px;
    }
    
    .display-3 {
        font-size: 2rem;
    }

    .display-4 {
        font-size: 1.8rem;
    }

    .display-5 {
        font-size: 1.5rem;
    }
    
    .btn-lg {
        padding: 0.75rem 1.25rem;
        font-size: 0.95rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 1rem !important;
    }

    .hero-content .lead {
        font-size: 1.1rem !important;
    }

    .hero-content .h5 {
        font-size: 0.95rem !important;
    }

    .card-body.p-5 {
        padding: 1.5rem !important;
    }

    section.py-5 {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
    }

    .feature-icon {
        width: 50px;
        height: 50px;
    }

    .d-flex.gap-3 {
        gap: 0.75rem !important;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for better accessibility */
.btn:focus,
.nav-link:focus,
a:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #000080;
        --secondary-color: #000080;
        --text-primary: #000000;
        --border-color: #000000;
    }
}

/* Custom utility classes */
.text-church-primary {
    color: var(--primary-color) !important;
}

.bg-church-light {
    background-color: var(--light-bg) !important;
}

.border-church {
    border-color: var(--border-color) !important;
}

/* Print styles */
@media print {
    .navbar,
    .btn,
    footer {
        display: none !important;
    }
    
    .card {
        border: 1px solid #000 !important;
        box-shadow: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
    
    h1, h2, h3, h4, h5, h6 {
        color: #000 !important;
    }
}
