:root {
    --primary-green: #2E7D32;
    --primary-blue: #1565C0;
    --white: #ffffff;
    --light-green: #4CAF50;
    --light-blue: #42A5F5;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background: linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
}

@keyframes gradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Header Styles */
header {
    background: linear-gradient(135deg, var(--primary-green), var(--primary-blue));
    padding: 1.5rem;
    color: var(--white);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.header-content {
    display: flex;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    gap: 2rem;
}

/* Logo Styles */
#logo {
    width: 120px;
    height: 120px;
    flex-shrink: 0;
    padding: 10px;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
}

#logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Banner Styles */
.banner {
    flex: 1;
    text-align: left;
    padding-left: 2rem;
}

.banner h1 {
    font-size: 2.8rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.banner h2 {
    font-size: 1.2rem;
    font-weight: normal;
    color: rgba(255,255,255,0.9);
}

/* Navigation Styles */
nav {
    margin-top: 1rem;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
    gap: 2rem;
}

nav ul li a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    font-weight: bold;
    transition: all 0.3s ease;
}

nav ul li a:hover {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

/* Main Content Styles */
main {
    padding: 2rem;
    text-align: center;
    display: flex;
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* Gallery Styles */
.gallery-container {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    margin: 20px 0;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    background: #f0f0f0;
}

.gallery-wrapper {
    position: relative;
    width: 100%;
    max-width: 800px;
    height: 100%;
    margin: 0 auto;
    overflow: hidden;
}

.gallery-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.gallery-slide.active {
    opacity: 1;
}

.gallery-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}

.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 1rem;
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 10;
}

.gallery-arrow.left {
    left: 10px;
}

.gallery-arrow.right {
    right: 10px;
}

.loading-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

/* Welcome Section Styles */
#gallery {
    flex: 1;
    max-width: 50%;
}

#welcome {
    flex: 1;
    text-align: left;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

#welcome h1 {
    color: var(--primary-blue);
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    font-family: 'Georgia', serif;
    border-bottom: 2px solid var(--primary-green);
    padding-bottom: 0.5rem;
}

#welcome p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: #333;
}

.welcome-highlight {
    background: linear-gradient(45deg, var(--primary-green), var(--primary-blue));
    color: white;
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    font-size: 1.2rem;
    margin: 2rem 0;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Bishop Message Styles */
.bishop-message {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid var(--primary-blue);
}

.bishop-message h3 {
    color: var(--primary-blue);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.message-signature {
    margin-top: 1.5rem;
    text-align: right;
    font-style: italic;
}

.message-timestamp {
    font-size: 0.9rem;
    color: #666;
}

/* Services Section Styles */
.services-section {
    margin: 3rem 0;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.services-section h2 {
    color: var(--primary-blue);
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    font-family: 'Georgia', serif;
}

.service-cards {
    display: flex;
    justify-content: space-around;
    gap: 2rem;
    flex-wrap: wrap;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    text-align: center;
    min-width: 250px;
    transition: transform 0.3s ease;
}

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

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.service-card h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.service-card p {
    color: #555;
    line-height: 1.5;
}

/* About Section Styles */
.about-container {
    display: flex;
    padding: 2rem;
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.about-section {
    flex: 1;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

.left-section {
    animation-delay: 0.2s;
}

.right-section {
    animation-delay: 0.4s;
}

.about-section h1 {
    color: var(--primary-blue);
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    font-family: 'Georgia', serif;
    border-bottom: 2px solid var(--primary-green);
    padding-bottom: 0.5rem;
}

.about-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: #333;
}

.highlight-box {
    background: linear-gradient(45deg, var(--primary-green), var(--primary-blue));
    color: white;
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    font-size: 1.2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Card Styles */
.card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    transition: transform 0.3s ease;
}

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

.card h2 {
    color: var(--primary-blue);
    margin-bottom: 1rem;
    font-size: 1.8rem;
    font-family: 'Georgia', serif;
}

/* Goal Item Styles */
.goal-item {
    margin-bottom: 1.5rem;
}

.goal-item h3 {
    color: var(--primary-green);
    margin-bottom: 0.5rem;
    font-size: 1.3rem;
}

.goal-item p {
    color: #555;
    line-height: 1.6;
}

/* Leadership Styles */
.leadership-container {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.leadership-list {
    flex: 0 0 40%;
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
}

.leadership-list h2 {
    color: var(--primary-blue);
    margin: 1.5rem 0 1rem;
    font-family: 'Georgia', serif;
    border-bottom: 2px solid var(--primary-green);
    padding-bottom: 0.5rem;
}

.leadership-list ul {
    list-style: none;
    padding: 0;
}

.leadership-list li {
    margin: 1rem 0;
    padding: 0.5rem;
    transition: background-color 0.3s ease;
}

.leadership-list a {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: bold;
}

.leadership-list li:hover {
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 5px;
}

.profile-container {
    flex: 0 0 60%;
    position: sticky;
    top: 2rem;
    height: 90vh;
}

.leader-profile {
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.15);
    transition: opacity 0.3s ease;
    height: 100%;
    overflow-y: auto;
}

.profile-image {
    width: 200px;
    height: 200px;
    overflow: hidden;
    border-radius: 10px;
    margin: 0 auto 1.5rem;
}

.profile-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #f5f5f5;
}

.profile-details h2 {
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
    font-family: 'Georgia', serif;
}

.profile-details h3 {
    color: var(--primary-green);
    margin-bottom: 1.5rem;
    font-style: italic;
}

.profile-text {
    line-height: 1.8;
    color: #333;
}

/* Pastors Grid Styles */
.pastors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.pastor-card {
    background: var(--white);
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

.pastor-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto 1rem;
    object-fit: cover;
}

.pastor-name {
    color: var(--primary-blue);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.pastor-title {
    color: var(--primary-green);
    font-style: italic;
    margin-bottom: 1rem;
}

.pastor-bio {
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Sermons Styles */
.sermons-container {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    min-height: 80vh;
}

.sermon-list {
    flex: 0 0 40%;
    overflow-y: auto;
    padding: 1rem;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.sermon-viewer {
    flex: 1;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 1rem;
}

.sermon-item {
    padding: 1rem;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background 0.3s;
}

.sermon-item:hover {
    background: #f5f5f5;
}

.sermon-item h3 {
    margin: 0 0 0.5rem 0;
    color: var(--primary-blue);
}

.sermon-item p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

.sermon-controls {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.sermon-controls button {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    background: var(--primary-blue);
    color: white;
    cursor: pointer;
}

.no-sermon-selected {
    text-align: center;
    color: #666;
    margin-top: 2rem;
}

/* Admin Styles */
.admin-container {
    max-width: 800px;
    margin: 2rem auto;
    padding: 1rem;
}

.logo-upload, .admin-sermon-upload {
    background: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin: 2rem auto;
}

.logo-upload form, .admin-sermon-upload form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.logo-upload button, .admin-sermon-upload button {
    background: var(--primary-blue);
    color: var(--white);
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.admin-sermon-upload {
    max-width: 600px;
}

.admin-sermon-upload input {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
}

#uploadStatus, #loginStatus {
    margin-top: 1rem;
    text-align: center;
    font-weight: bold;
}

#loginStatus {
    color: red;
}

/* Login Form Styles */
.login-form {
    background: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    max-width: 400px;
    margin: 2rem auto;
}

.login-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.login-form input {
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.login-form button {
    background: var(--primary-blue);
    color: var(--white);
    padding: 0.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* Timer Display */
.timer-display {
    font-size: 24px;
    margin-top: 20px;
}

/* Church Info */
.church-info {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1rem;
    text-align: left;
}

.church-info h2 {
    color: var(--primary-green);
    margin: 1.5rem 0 1rem;
}

.church-info ul {
    list-style: none;
    padding: 0;
}

.church-info li {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.church-info li:before {
    content: "•";
    color: var(--primary-blue);
    position: absolute;
    left: 0;
}

/* Footer */
footer {
    background: #333;
    color: white;
    text-align: center;
    padding: 1rem;
    width: 100%;
    margin-top: 2rem;
}

@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    .container {
        width: 100%;
        padding: 10px;
    }
    img {
        max-width: 100%;
        height: auto;
    }
}
