/**
 * Block Styles for Frontend
 *
 * This file contains styles for WordPress block editor blocks
 * that need additional styling beyond the main stylesheet.
 */

/* Block Container */
.entry-content > *,
.entry-summary > *,
.page-content > * {
    margin-bottom: 1.5rem;
    max-width: 100%;
}

/* Paragraphs */
.has-drop-cap:not(:focus)::first-letter {
    font-size: 5em;
    line-height: 1;
    font-weight: bold;
    float: left;
    margin: 0.1em 0.1em 0 0;
}

/* Headings */
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
    color: #0f172a;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.entry-content h1 { font-size: 2.5rem; }
.entry-content h2 { font-size: 2rem; }
.entry-content h3 { font-size: 1.75rem; }
.entry-content h4 { font-size: 1.5rem; }
.entry-content h5 { font-size: 1.25rem; }
.entry-content h6 { font-size: 1rem; }

/* Links */
.entry-content a {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.3s ease;
}

.entry-content a:hover {
    color: #2563eb;
    text-decoration: underline;
}

/* Blockquote */
.wp-block-quote {
    border-left: 4px solid #3b82f6;
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #64748b;
}

.wp-block-quote cite {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    font-style: normal;
}

.wp-block-quote.is-large,
.wp-block-quote.is-style-large {
    border-left: 4px solid #3b82f6;
    padding-left: 2rem;
}

/* Pullquote */
.wp-block-pullquote {
    border-top: 4px solid #3b82f6;
    border-bottom: 4px solid #3b82f6;
    padding: 2rem 0;
    margin: 2rem 0;
    text-align: center;
}

.wp-block-pullquote blockquote {
    margin: 0;
    border: none;
    padding: 0;
}

.wp-block-pullquote cite {
    display: block;
    margin-top: 1rem;
    color: #64748b;
    font-style: normal;
}

/* Code */
.wp-block-code {
    background-color: #1e293b;
    color: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.wp-block-code code {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9em;
}

.entry-content code {
    background-color: #f1f5f9;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-size: 0.9em;
}

/* Lists */
.wp-block-list {
    margin-bottom: 1rem;
}

.wp-block-list li {
    margin-bottom: 0.5rem;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.entry-content ul {
    list-style: disc;
}

.entry-content ol {
    list-style: decimal;
}

.entry-content ul ul,
.entry-content ol ol {
    margin-top: 0.5rem;
}

/* Tables */
.wp-block-table {
    margin: 1.5rem 0;
    width: 100%;
    overflow-x: auto;
}

.wp-block-table table {
    border-collapse: collapse;
    width: 100%;
}

.wp-block-table th,
.wp-block-table td {
    border: 1px solid #e2e8f0;
    padding: 0.75rem;
    text-align: left;
}

.wp-block-table th {
    background-color: #f8fafc;
    font-weight: 600;
}

.wp-block-table.is-style-stripes tbody tr:nth-child(odd) {
    background-color: #f8fafc;
}

/* Separator/HR */
.wp-block-separator {
    border: none;
    margin: 2rem 0;
}

.wp-block-separator.is-style-wide {
    border-bottom: 2px solid #e2e8f0;
    max-width: 100%;
}

.wp-block-separator.is-style-dots {
    background: none;
    text-align: center;
    max-width: 100%;
    line-height: 1;
    height: auto;
}

.wp-block-separator.is-style-dots::before {
    content: "···";
    color: #e2e8f0;
    font-size: 1.5rem;
    letter-spacing: 2em;
}

/* Image */
.wp-block-image {
    margin: 1.5rem 0;
}

.wp-block-image img {
    max-width: 100%;
    height: auto;
    display: block;
}

.wp-block-image figcaption {
    text-align: center;
    color: #64748b;
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.wp-block-image.alignleft {
    float: left;
    margin-right: 1.5rem;
    margin-bottom: 1.5rem;
}

.wp-block-image.alignright {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.wp-block-image.aligncenter {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

/* Gallery */
.wp-block-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.blocks-gallery-item img {
    width: 100%;
    height: auto;
}

/* Media & Text */
.wp-block-media-text {
    display: grid;
    grid-template-columns: 50% 50%;
    gap: 2rem;
    margin: 2rem 0;
    align-items: center;
}

.wp-block-media-text .wp-block-media-text__media {
    margin: 0;
}

.wp-block-media-text img {
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .wp-block-media-text {
        grid-template-columns: 1fr;
    }
}

/* Buttons */
.wp-block-button {
    margin-bottom: 1rem;
}

.wp-block-button__link {
    background-color: #3b82f6;
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: all 0.3s ease;
}

.wp-block-button__link:hover {
    background-color: #2563eb;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.wp-block-button.is-style-outline .wp-block-button__link {
    background-color: transparent;
    border: 2px solid #3b82f6;
    color: #3b82f6;
}

.wp-block-button.is-style-outline .wp-block-button__link:hover {
    background-color: #3b82f6;
    color: #ffffff;
}

/* Cover */
.wp-block-cover {
    background-color: #0f172a;
    color: #ffffff;
    padding: 4rem 2rem;
    text-align: center;
    position: relative;
}

.wp-block-cover h2 {
    color: #ffffff;
}

.wp-block-cover p {
    color: #ffffff;
}

.wp-block-cover__inner-container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Group */
.wp-block-group {
    margin-bottom: 1.5rem;
}

.wp-block-group__inner-container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Columns */
.wp-block-columns {
    display: flex;
    gap: 2rem;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.wp-block-column {
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .wp-block-columns {
        flex-direction: column;
    }

    .wp-block-column {
        flex: none;
    }
}

/* Latest Posts */
.wp-block-latest-posts {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.wp-block-latest-posts li {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.wp-block-latest-posts__post-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.wp-block-latest-posts__post-title a {
    color: #0f172a;
    text-decoration: none;
}

.wp-block-latest-posts__post-title a:hover {
    color: #3b82f6;
}

.wp-block-latest-posts__post-excerpt {
    color: #64748b;
}

.wp-block-latest-posts__post-date {
    color: #94a3b8;
    font-size: 0.875rem;
}

/* Search */
.wp-block-search {
    display: flex;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.wp-block-search__input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 1rem;
}

.wp-block-search__input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.wp-block-search__button {
    background-color: #3b82f6;
    color: #ffffff;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wp-block-search__button:hover {
    background-color: #2563eb;
}

/* Categories & Tags */
.wp-block-categories-list,
.wp-block-tag-cloud {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.wp-block-categories-list li {
    margin-bottom: 0.5rem;
}

.wp-block-tag-cloud a {
    display: inline-block;
    background-color: #f8fafc;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    margin: 0.25rem;
    text-decoration: none;
    color: #3b82f6;
    transition: all 0.3s ease;
}

.wp-block-tag-cloud a:hover {
    background-color: #3b82f6;
    color: #ffffff;
}

/* File */
.wp-block-file {
    background-color: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.wp-block-file a {
    text-decoration: none;
}

.wp-block-file__textlink {
    color: #3b82f6;
    font-weight: 600;
}

.wp-block-file__button {
    background-color: #3b82f6;
    color: #ffffff;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.875rem;
    display: inline-block;
    margin-top: 1rem;
}

/* Verse */
.wp-block-verse {
    font-family: monospace;
    background-color: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    color: #64748b;
}

/* Spacer */
.wp-block-spacer {
    clear: both;
}

/* Alignment Utilities */
.entry-content .alignleft {
    float: left;
    margin-right: 1.5rem;
    margin-bottom: 1.5rem;
}

.entry-content .alignright {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.entry-content .aligncenter {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}

.entry-content .alignwide {
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.entry-content .alignfull {
    max-width: none;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
}

/* Responsive */
@media (max-width: 768px) {
    .entry-content h1 { font-size: 2rem; }
    .entry-content h2 { font-size: 1.75rem; }
    .entry-content h3 { font-size: 1.5rem; }

    .wp-block-columns {
        gap: 1rem;
    }

    .wp-block-media-text {
        gap: 1rem;
    }
}

