/* =====================================================
   SISEENG - Sistem Informasi Manajemen Gereja
   Main Stylesheet
   ===================================================== */

/* =====================================================
   CSS Variables / Custom Properties
   ===================================================== */
:root {
    --primary-color: #1e40af;
    --primary-dark: #1e3a8a;
    --primary-light: #3b82f6;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #06b6d4;
    
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    
    --bg-light: #f8fafc;
    --bg-white: #ffffff;
    
    --border-color: #e5e7eb;
    --border-radius: 0.5rem;
    --border-radius-lg: 1rem;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    --font-family-base: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-family-heading: 'Merriweather', Georgia, serif;
    
    --transition-base: all 0.3s ease;
}

/* =====================================================
   Base Styles
   ===================================================== */
html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family-base);
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-white);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-heading);
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 1rem;
}

/* Large font for elderly readability */
.fs-lg {
    font-size: 1.2rem !important;
}

.fs-xl {
    font-size: 1.4rem !important;
}

p {
    margin-bottom: 1.25rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition-base);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

/* =====================================================
   Bootstrap Overrides
   ===================================================== */

/* Primary Color Override */
.bg-primary {
    background-color: var(--primary-color) !important;
}

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

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

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

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

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

/* Larger buttons for accessibility */
.btn {
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    border-radius: var(--border-radius);
    transition: var(--transition-base);
}

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

/* Card Styling */
.card {
    border-radius: var(--border-radius-lg);
    overflow: hidden;
}

.card-header {
    background-color: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.5rem;
}

.card-body {
    padding: 1.5rem;
}

/* Form Controls - Larger for accessibility */
.form-control,
.form-select {
    padding: 0.75rem 1rem;
    font-size: 1.1rem;
    border-radius: var(--border-radius);
    border: 2px solid var(--border-color);
    transition: var(--transition-base);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(30, 64, 175, 0.15);
}

.form-control-lg {
    padding: 1rem 1.25rem;
    font-size: 1.2rem;
}

.form-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 1.05rem;
}

/* =====================================================
   Navigation
   ===================================================== */
.navbar {
    padding: 1rem 0;
    transition: var(--transition-base);
}

.navbar-brand {
    font-family: var(--font-family-heading);
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-link {
    font-size: 1.1rem;
    font-weight: 500;
    padding: 0.75rem 1.25rem !important;
    transition: var(--transition-base);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--primary-color) !important;
}

/* Sticky/Fixed Navbar styles */
.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.98) !important;
    box-shadow: var(--shadow);
}

/* =====================================================
   Hero Section
   ===================================================== */
.hero-section {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/pattern.svg') repeat;
    opacity: 0.1;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 300;
    opacity: 0.9;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
}

/* =====================================================
   Section Styling
   ===================================================== */
section {
    padding: 5rem 0;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.section-title.text-center::after {
    left: 50%;
    transform: translateX(-50%);
}

/* =====================================================
   Schedule Card
   ===================================================== */
.schedule-card {
    background: var(--bg-white);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-left: 4px solid var(--primary-color);
    box-shadow: var(--shadow);
    transition: var(--transition-base);
}

.schedule-card:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow-lg);
}

.schedule-time {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
}

.schedule-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin: 0.5rem 0;
}

.schedule-location {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* =====================================================
   Event Card
   ===================================================== */
.event-card {
    transition: var(--transition-base);
}

.event-card:hover {
    transform: translateY(-5px);
}

.event-date-badge {
    min-width: 70px;
    text-align: center;
    padding: 0.75rem;
    background: var(--primary-color);
    color: white;
    border-radius: var(--border-radius);
}

.event-date-badge .day {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1;
}

.event-date-badge .month {
    font-size: 0.875rem;
    text-transform: uppercase;
}

/* =====================================================
   Article Card
   ===================================================== */
.article-card {
    transition: var(--transition-base);
}

.article-card:hover {
    transform: translateY(-5px);
}

.article-card .card-img-top {
    height: 200px;
    object-fit: cover;
}

/* =====================================================
   Footer
   ===================================================== */
footer {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    color: #f3f4f6;
    padding: 4rem 0 0;
}

footer h5 {
    font-family: var(--font-family-heading);
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    color: white;
}

footer a {
    color: #d1d5db;
    transition: var(--transition-base);
}

footer a:hover {
    color: white;
    padding-left: 5px;
}

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

footer ul li {
    margin-bottom: 0.75rem;
}

.footer-bottom {
    background: rgba(0, 0, 0, 0.2);
    padding: 1.5rem 0;
    margin-top: 3rem;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1.25rem;
    margin-right: 0.75rem;
    transition: var(--transition-base);
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

/* =====================================================
   Utility Classes
   ===================================================== */
.hover-lift {
    transition: var(--transition-base);
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
}

.divider {
    width: 60px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 2px;
    margin: 1.5rem auto;
}

/* =====================================================
   Animations
   ===================================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.animate-pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* =====================================================
   Responsive Adjustments
   ===================================================== */
@media (max-width: 991.98px) {
    section {
        padding: 3rem 0;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 767.98px) {
    body {
        font-size: 1rem;
    }
    
    .btn {
        padding: 0.625rem 1.25rem;
    }
    
    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 1.05rem;
    }
    
    .hero-section {
        min-height: 70vh;
    }
}

/* =====================================================
   Print Styles
   ===================================================== */
@media print {
    .navbar,
    footer,
    .btn,
    .no-print {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    a {
        text-decoration: none;
        color: inherit;
    }
}

/* =====================================================
   Accessibility Enhancements
   ===================================================== */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    z-index: 9999;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

/* Focus visible for keyboard navigation */
*:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

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

/* High contrast mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #0000ff;
        --text-primary: #000000;
        --border-color: #000000;
    }
    
    .btn {
        border-width: 2px;
    }
}
