/*
Theme Name: RT Beacon
Theme URI: https://example.com/rt-beacon
Author: Your Name
Author URI: https://example.com
Description: A custom theme for 1zibobeacon.com
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rt-beacon
Tags: custom-background, custom-colors, custom-header, custom-menu, featured-images, responsive-layout

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned with others.
*/

/* Import existing styles */
@import url('rt-dome/css/R.css');


/* 古腾堡块前台样式 */
.entry-content,.wp-block-separator:not(.is-style-wide):not(.is-style-dots)
{width: 100% !important;}

.entry-content > * {margin-bottom: 1.5em;}

.entry-content .wp-block {max-width: 100%;}

/* 重要:恢复古腾堡块的列表样式,被 R.css 的全局样式覆盖了 */
.entry-content ul,
.entry-content ol {
    list-style: inherit !important;
    padding: inherit !important;
    margin: inherit !important;
}

.entry-content .wp-block-list ul {
    list-style-type: disc !important;
    padding-left: 1.5em !important;
    margin-bottom: 1.5em !important;
}

.entry-content .wp-block-list ol {
    list-style-type: decimal !important;
    padding-left: 1.5em !important;
    margin-bottom: 1.5em !important;
}

.entry-content .wp-block-list li {
    list-style: disc !important;
    margin-bottom: 0.5em !important;
}

/* 确保所有古腾堡块样式正确应用 */
.entry-content .wp-block-paragraph,
.entry-content .wp-block-heading,
.entry-content .wp-block-list,
.entry-content .wp-block-image,
.entry-content .wp-block-quote,
.entry-content .wp-block-gallery,
.entry-content .wp-block-columns,
.entry-content .wp-block-column,
.entry-content .wp-block-group,
.entry-content .wp-block-media-text,
.entry-content .wp-block-button,
.entry-content .wp-block-separator,
.entry-content .wp-block-table,
.entry-content .wp-block-code,
.entry-content .wp-block-cover,
.entry-content .wp-block-archives,
.entry-content .wp-block-latest-posts,
.entry-content .wp-block-categories,
.entry-content .wp-block-tag-cloud,
.entry-content .wp-block-search,
.entry-content .wp-block-shortcode,
.entry-content .wp-block-audio,
.entry-content .wp-block-video {
    margin-bottom: 1.5em;
}

/* 列表样式 */
.entry-content .wp-block-list ul,
.about-nr .wp-block-list ul {
    list-style-type: disc !important;
    padding-left: 1.5em !important;
}

.entry-content .wp-block-list ol,
.about-nr .wp-block-list ol {
    list-style-type: decimal !important;
    padding-left: 1.5em !important;
}

.entry-content .wp-block-list li,
.about-nr .wp-block-list li {
    list-style: disc;
}

/* 标题样式 */
.entry-content .wp-block-heading h1 {
    font-size: 2.5em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content .wp-block-heading h2 {
    font-size: 2em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content .wp-block-heading h3 {
    font-size: 1.75em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content .wp-block-heading h4 {
    font-size: 1.5em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content .wp-block-heading h5 {
    font-size: 1.25em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content .wp-block-heading h6 {
    font-size: 1em;
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

/* 段落样式 */
.entry-content .wp-block-paragraph {
    margin-bottom: 1.5em;
    font-size: 16px;
    line-height: 1.5;
}

/* 引用样式 */
.entry-content .wp-block-quote {
    border-left: 4px solid #000;
    padding-left: 1em;
    font-style: italic;
    margin-bottom: 1.5em;
    font-size: 1.25em;
}

/* 列布局 */
.entry-content .wp-block-columns {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 1.5em;
}

.entry-content .wp-block-column {
    flex: 1;
    min-width: 0;
    padding: 0 1em;
}

/* 组块样式 */
.entry-content .wp-block-group {
    margin-bottom: 1.5em;
}

/* 媒体与文本块 */
.entry-content .wp-block-media-text {
    display: flex;
    align-items: center;
    margin-bottom: 1.5em;
}

.entry-content .wp-block-media-text__media {
    flex: 1;
}

.entry-content .wp-block-media-text__content {
    flex: 1;
    padding: 0 1em;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .entry-content .wp-block-columns {
        flex-direction: column;
    }
    
    .entry-content .wp-block-column {
        flex-basis: 100%;
        margin-bottom: 1em;
    }
    
    .entry-content .wp-block-media-text {
        flex-direction: column;
    }
    
    .entry-content .wp-block-media-text__content {
        padding: 1em 0 0 0;
    }
    
    .entry-content .wp-block-gallery .blocks-gallery-grid {
        flex-direction: column;
    }
    
    .entry-content .wp-block-gallery .blocks-gallery-item {
        flex-basis: 100%;
    }
}

/* 图片对齐样式 */
.entry-content .alignleft {
    float: left;
    margin-right: 1.5em;
    margin-bottom: 1em;
}

.entry-content .alignright {
    float: right;
    margin-left: 1.5em;
    margin-bottom: 1em;
}

.entry-content .aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1em;
}

/* 宽版和全宽对齐 */
.entry-content .alignwide {
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
}

.entry-content .alignfull {
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
}

/* 按钮样式 */
.entry-content .wp-block-button .wp-block-button__link {
    display: inline-block;
    padding: 0.75em 1.5em;
    background-color: #000;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
}

/* 分隔线样式 */
.entry-content .wp-block-separator {
    border: none;
    border-top: 1px solid #ccc;
    margin: 2em 0;
}

/* 表格样式 */
.entry-content .wp-block-table {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-table table {
    width: 100%;
    border-collapse: collapse;
}

.entry-content .wp-block-table th,
.entry-content .wp-block-table td {
    padding: 0.5em;
    border: 1px solid #ccc;
    text-align: left;
}

.entry-content .wp-block-table th {
    background-color: #f5f5f5;
    font-weight: bold;
}

/* 代码块样式 */
.entry-content .wp-block-code {
    margin-bottom: 1.5em;
    padding: 1em;
    background-color: #f5f5f5;
    border-radius: 4px;
    font-family: monospace;
    white-space: pre-wrap;
}

/* 封面样式 */
.entry-content .wp-block-cover {
    margin-bottom: 1.5em;
    position: relative;
    overflow: hidden;
}

.entry-content .wp-block-cover .wp-block-cover__inner-container {
    position: relative;
    z-index: 1;
    color: #fff;
    text-align: center;
    padding: 2em;
}

/* 归档块样式 */
.entry-content .wp-block-archives {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-archives li {
    margin-bottom: 0.5em;
}

/* 最新帖子块样式 */
.entry-content .wp-block-latest-posts {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-latest-posts li {
    margin-bottom: 0.5em;
}

/* 分类块样式 */
.entry-content .wp-block-categories {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-categories li {
    margin-bottom: 0.5em;
}

/* 标签云块样式 */
.entry-content .wp-block-tag-cloud {
    margin-bottom: 1.5em;
}

/* 搜索块样式 */
.entry-content .wp-block-search {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-search .wp-block-search__input {
    padding: 0.5em;
    border: 1px solid #ccc;
    border-radius: 4px 0 0 4px;
    width: 70%;
}

.entry-content .wp-block-search .wp-block-search__button {
    padding: 0.5em 1em;
    background-color: #000;
    color: #fff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

/* 短代码块样式 */
.entry-content .wp-block-shortcode {
    margin-bottom: 1.5em;
}

/* 音频块样式 */
.entry-content .wp-block-audio {
    margin-bottom: 1.5em;
}

/* 视频块样式 */
.entry-content .wp-block-video {
    margin-bottom: 1.5em;
}

/* 图库样式 */
.entry-content .wp-block-gallery {
    margin-bottom: 1.5em;
}

.entry-content .wp-block-gallery .blocks-gallery-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -0.5em;
}

.entry-content .wp-block-gallery .blocks-gallery-item {
    flex: 1 1 300px;
    margin: 0.5em;
}

.entry-content .wp-block-gallery .blocks-gallery-item img {
    max-width: 100%;
    height: auto;
}

/* 确保与主题样式的兼容性 */
.about-nr .wp-block {
    margin-bottom: 1.5em;
}

/* 调整列布局 */
.about-nr .wp-block-columns {
    margin-left: 0;
    margin-right: 0;
}

/* 调整图片对齐 */
.about-nr .alignleft {
    float: left;
    margin-right: 1.5em;
    margin-bottom: 1em;
}

.about-nr .alignright {
    float: right;
    margin-left: 1.5em;
    margin-bottom: 1em;
}

.about-nr .aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1em;
}

/* 调整分隔线样式 */
.about-nr hr.wp-block-separator {
    border: none;
    border-top: 1px solid #ccc;
    margin: 2em 0;
}

/* 重要:恢复其他被全局样式覆盖的古腾堡块样式 */
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6 {
    margin-top: 0;
    margin-bottom: 0.5em;
    font-weight: bold;
}

.entry-content p {
    padding: inherit;
    margin-bottom: 1.5em;
}

.entry-content a {
    color: #0000ee;
    text-decoration: underline;
    transition: all 0.2s;
}

.entry-content a:hover {
    color: #0000cc;
}

/* 确保图片不被全局样式影响 */
.entry-content img {
    height: auto;
    max-width: 100%;
}

/* 恢复表格样式 */
.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5em;
}

/* 恢复引用样式 */
.entry-content blockquote {
    border-left: 4px solid #000;
    padding-left: 1em;
    font-style: italic;
    margin-bottom: 1.5em;
    color: #555;
}