/* Animated Gradient Background for Ghost Source Theme */
@keyframes gradientAnimation {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

:root {
    /* Override the background color with our animated gradient */
    --background-color: transparent !important;
}

body {
    /* Create a gradient that animates from blue to purple */
    background: linear-gradient(-45deg, #1a2980, #3498db, #6a3093, #8e44ad);
    background-size: 400% 400%;
    animation: gradientAnimation 15s ease infinite;
}

/* Ensure content is readable on the gradient background */
.gh-viewport {
    color: #000;
}

/* Add semi-transparent backgrounds to content areas for better readability */
.gh-article, .gh-card, .gh-content {
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
    color: #333;
}

/* Add stronger contrast to post titles */
.gh-card-title, .gh-article-title {
    color: #000;
    font-weight: bold;
}

/* Make post excerpts and content more readable */
.gh-card-excerpt, .gh-content p {
    color: #222;
    font-weight: normal;
}

/* Style the navigation for better visibility on gradient */
.gh-navigation {
    background-color: rgba(20, 30, 48, 0.85); /* Dark navy blue with transparency */
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.gh-navigation a:not(.gh-button) {
    color: #ffffff; /* White text for better contrast */
    font-weight: 500;
}

.gh-navigation a:not(.gh-button):hover {
    color: #3498db; /* Light blue on hover */
}

/* Adjust footer for better visibility */
.gh-footer {
    background-color: rgba(20, 30, 48, 0.85); /* Dark navy blue with transparency - matching header */
    backdrop-filter: blur(10px);
    color: #ffffff;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.gh-footer a:not(.gh-button) {
    color: #3498db !important; /* Light blue links */
}

.gh-footer a:not(.gh-button):hover {
    color: #5dade2 !important; /* Lighter blue on hover */
    text-decoration: none;
}

/* Make buttons stand out on the gradient */
.gh-button {
    background-color: #3498db;
    color: #fff;
    border: none;
    transition: all 0.3s ease;
}

.gh-button:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Fix any padding issues that might occur */
.gh-article-header, .gh-card-wrapper {
    padding: 0;
}

/* Site title in header */
.gh-head-logo {
    color: #ffffff !important;
}

/* Search icon and other icons in header/footer */
.gh-icon {
    fill: #ffffff;
}

/* AI Character Directory Styling */
.ai-character-directory {
    padding: 3rem 0;
    background-color: rgba(103, 58, 183, 0.8); /* Purple background */
    color: white;
    text-align: center;
}

.ai-directory-heading {
    text-align: center;
    margin-bottom: 0.5rem;
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
}

.ai-directory-description {
    text-align: center;
    margin-bottom: 2.5rem;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
}

.character-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    margin: 0 auto;
    max-width: 1000px; /* Ensures grid stays centered with fewer items */
}

.character-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

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

.character-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem;
    text-align: center;
}

/* New background-image approach for author images */
.author-image {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    margin-bottom: 1.5rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.author-initial {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    font-weight: bold;
    background: linear-gradient(135deg, #1e88e5, #9c27b0);
    color: white;
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.character-name {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0 0 1.5rem;
    color: #333;
}

.view-stories-btn {
    background: linear-gradient(90deg, #1e88e5, #9c27b0);
    color: white;
    padding: 0.8rem 2rem;
    border-radius: 30px;
    font-weight: 500;
    font-size: 0.95rem;
    text-align: center;
    transition: box-shadow 0.2s ease;
}

.character-card:hover .view-stories-btn {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.no-characters-message {
    padding: 2rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    grid-column: 1 / -1;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .character-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 1.5rem;
    }
    
    .author-image, .author-initial {
        width: 130px;
        height: 130px;
    }
    
    .character-name {
        font-size: 1.4rem;
    }
    
    .character-card-link {
        padding: 1.5rem;
    }
    
    .view-stories-btn {
        padding: 0.7rem 1.5rem;
    }
}

/* Fix for main layout issues */
.gh-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 4vw;
}

/* Latest posts section styling */
.latest-posts-section {
    padding: 3rem 0;
}

.latest-posts-heading {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2.5rem;
    font-weight: 700;
}

/* CTA/Subscribe section styling */
.gh-cta {
    margin: 3rem auto; /* Add proper spacing */
    padding: 0 4vw;
    max-width: 1200px;
    position: relative;
    z-index: 2; /* Ensure it appears above footer */
}

/* Footer styling */
.gh-foot {
    margin-top: 3rem;
    position: relative;
    z-index: 1;
} 