/* ==========================================================================
   STATIC PAGES, OVERLAYS & BLOGS STYLESHEET (Decoupled from style.css)
   ========================================================================== */

.static-page-panel {
    position: absolute !important; 
    inset: 18px !important; 
    width: auto; 
    height: auto;
    opacity: 0; 
    pointer-events: none; 
    transition: opacity 0.3s ease; 
    z-index: 100;
    overflow-y: auto; 
    scrollbar-gutter: stable;
}

.static-page-panel.visible { 
    opacity: 1; 
    pointer-events: auto; 
}

.static-content-panel {
    position: relative; 
}

.static-page-panel .back-button, 
.standalone-static-panel .back-link,
.static-content-panel .back-link {
    position: absolute; 
    top: 20px; left: 20px; 
    font-size: 0.9em; 
    background: none; 
    border: none;
    color: var(--highlight-primary); 
    cursor: pointer; 
    padding: 5px 10px; 
    text-decoration: none; 
    z-index: 10;
    font-weight: bold;
}

.static-page-panel .back-button:hover, 
.standalone-static-panel .back-link:hover, 
.static-content-panel .back-link:hover { 
    text-decoration: underline; 
}

.panel-scroll-wrapper h1 {
    margin-top: 50px; 
}

.title-icon { 
    height: 1.2em; 
    width: auto; 
    margin-left: 15px; 
    display: block; 
}

.about-content-box, 
.game-mode-description-box {
    background-color: var(--bg-secondary); 
    padding: 15px 20px;
    border-radius: 8px; 
    margin-top: 20px;
}

.game-mode-description-box { 
    display: flex; 
    gap: 20px; 
    align-items: center; 
}

.game-mode-description-text-content { 
    flex: 1; 
}

.game-mode-screenshot {
    flex-shrink: 0; 
    width: 320px; 
    height: 180px; 
    object-fit: cover;
    border-radius: 8px; 
    border: 2px solid var(--highlight-primary); 
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

body.standalone-page { 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    min-height: 100vh; 
    padding: 20px; 
    box-sizing: border-box; 
    overflow: hidden; 
}

.standalone-static-panel { 
    max-width: 1000px; 
    width: 100%; 
    max-height: 90vh; 
    overflow-y: auto; 
}

.standalone-static-panel .imprint-section { 
    margin-top: 40px; 
    padding-top: 20px; 
    border-top: 2px solid var(--muted-line); 
    font-size: 0.9em; 
    color: var(--text-secondary); 
}


/* --- Unified Typography for Static/Content Panels --- */
:is(.static-content-panel, .static-page-panel, .standalone-static-panel) h1 {
    color: #fff; 
    font-size: 2.2em; 
    text-align: center;
    margin-bottom: 30px; margin-top: 0;
    display: flex; 
    align-items: center; 
    justify-content: center;
}

:is(.static-content-panel, .static-page-panel, .standalone-static-panel) h2 {
    font-size: 1.8em;
    padding-bottom: 10px; 
    color: var(--highlight-secondary);
    margin-top: 25px; 
    margin-bottom: 15px;
}

:is(.static-content-panel, .static-page-panel, .standalone-static-panel) h3 {
    font-size: 1.4em; 
    color: var(--highlight-primary);
    margin-top: 25px; 
    margin-bottom: 15px;
}

:is(.static-content-panel, .static-page-panel, .standalone-static-panel) ul {
    padding-left: 20px; 
    line-height: 1.6;
}

:is(.static-content-panel, .static-page-panel, .standalone-static-panel) li {
    margin-bottom: 10px; 
    color: var(--text-primary);
}

:is(.static-content-panel, .static-page-panel, .standalone-static-panel) p {
    line-height: 1.6; 
    margin-bottom: 15px;
}

:is(.static-page-panel, .standalone-static-panel) a {
    color: var(--highlight-primary); 
    text-decoration: none;
}

:is(.static-page-panel, .standalone-static-panel) a:hover { 
    text-decoration: underline; 
}


/* --- Blog Specific Styles --- */
.blog-entry {
    background-color: var(--bg-secondary);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    border: 1px solid var(--border-color);
}

.blog-entry-content {
    display: flex;
    flex-direction: row;
    gap: 20px;
    align-items: flex-start;
    max-width: 100%; 
}

a.blog-entry {
    display: block; 
    text-decoration: none;
    transition: transform 0.2s ease, border-color 0.2s ease; 
    cursor: pointer;
}

a.blog-entry:hover { 
    transform: translateY(-3px); 
    border-color: var(--highlight-secondary); 
}

/* Home Preview adjustments */
.home-blog-list { 
    display: flex; 
    flex-direction: column; 
    gap: 12px; 
    margin-top: 15px; 
}

.home-blog-item { 
    padding: 15px; 
    margin-bottom: 0; 
}

.home-blog-item h4 { 
    margin: 0 0 6px 0; 
    color: var(--highlight-primary); 
    font-size: 1.1rem; 
}

.home-blog-item p { 
    margin: 0; 
    color: var(--text-secondary); 
    font-size: 0.9rem; 
    line-height: 1.5; 
}

.blog-list-image {
    width: 280px;
    max-width: 35%; 
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    order: 2; 
    flex-shrink: 0;
}

.blog-title {
    color: #fff !important;
    font-weight: bold;
    font-size: 1.8em;
    margin-bottom: 5px !important;
    margin-top: 0px !important;
    text-align: left; 
}

.blog-meta {
    color: var(--highlight-secondary);
    font-size: 0.85em;
    margin-bottom: 15px;
    padding-bottom: 10px;
    padding-top: 10px;
    border-bottom: 2px solid var(--muted-line);
    border-top: 2px solid var(--muted-line);
}

.blog-divider {
    border: 0;
    height: 2px;
    background: var(--muted-line);
    margin: 30px 0;
}

.blog-body {
    line-height: 1.6;
    position: relative;
}

.blog-preview-text {
    max-height: 5.4em; 
    overflow: hidden;
    position: relative;
    margin-bottom: 10px;
    color: var(--text-primary);
    -webkit-mask-image: linear-gradient(to bottom, black 40%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 40%, transparent 100%);
}

.read-further-link {
    color: var(--highlight-primary);
    text-decoration: none;
    font-size: 0.95em;
    font-weight: 500;
}

.read-further-link:hover {
    text-decoration: underline;
}

/* Hide elements in article view */
.is-article-view .back-link,
.is-article-view .blog-main-title {
    display: none;
}

/* Elegant Blog Layout */
.blog-post-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 0;
}

.blog-breadcrumb {
    font-size: 0.9em;
    color: var(--text-secondary);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.blog-breadcrumb a {
    color: var(--highlight-primary);
    text-decoration: none;
}

.blog-post-title {
    font-size: 2.8em !important;
    text-align: left !important;
    justify-self: start !important;
    line-height: 1.1;
}

.blog-post-meta {
    font-size: 0.95em;
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-style: italic;
}

/* Rich Text Refinement */
.blog-rich-text {
    line-height: 1.8;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

.blog-rich-text h2 {
    font-size: 1.8em;
    color: var(--highlight-secondary);
    margin-top: 1.5em;
    border: none; 
}

.blog-rich-text p {
    margin-bottom: 1.5em;
}

.blog-rich-text img {
    border: 1px solid rgba(255,255,255,0.1);
    padding: 5px;
    background: rgba(0,0,0,0.2);
}

#home-blog-preview-panel {
    flex: 1 1 100%;
    max-width: 918px; 
    width: 100%;
    box-sizing: border-box;
    margin: 0 auto; 
}
