/*
Theme Name: ViaHomeopatica
Theme URI: https://viahomeopatica.ru
Author: Shkola Olga
Description: Закрытый образовательный портал Академии Гомеопатии Виа Гомеопатика
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 8.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: viahomeopatica
*/

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

a {
    color: #2c5f2d;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Layout */
.site {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-content {
    flex: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
    width: 100%;
}

/* Header */
.site-header {
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.site-logo {
    flex-shrink: 0;
}

.site-logo img {
    height: 50px;
    width: auto;
}

.site-logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    text-decoration: none;
}

.site-logo-text .logo-via {
    color: #2c3e50;
}

.site-logo-text .logo-accent {
    color: #6b8e7e;
}

.site-logo-text .logo-patica {
    color: #734c75;
}

/* Navigation - базовая структура */
.main-navigation {
    flex: 1;
}

/* Auth Block */
.header-auth {
    flex-shrink: 0;
    text-align: right;
}

.auth-guest {
    color: #888;
    font-size: 0.9rem;
    font-style: italic;
}

.auth-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-name {
    font-weight: 500;
    color: #333;
}

.logout-btn {
    background: #e74c3c;
    color: #fff;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.2s;
}

.logout-btn:hover {
    background: #c0392b;
    text-decoration: none;
}

/* Footer */
.site-footer {
    background: #2c3e50;
    color: #ecf0f1;
    margin-top: auto;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    text-align: center;
}

.footer-copyright {
    opacity: 0.9;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem 0;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: #bdc3c7;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: #fff;
}

.footer-contact {
    font-size: 0.9rem;
    opacity: 0.8;
}

.footer-contact a {
    color: #bdc3c7;
}

/* Content Types */
.entry-header {
    margin-bottom: 1.5rem;
}

.entry-title {
    font-size: 2rem;
    margin: 0 0 0.5rem 0;
    color: #2c3e50;
}

.entry-meta {
    color: #7f8c8d;
    font-size: 0.9rem;
}

/* Access Denied */
.access-denied {
    background: #fff;
    padding: 3rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.access-denied h1 {
    color: #e74c3c;
}

/* 404 Page */
.error-404 {
    background: #fff;
    padding: 4rem 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    max-width: 600px;
    margin: 4rem auto;
}

.error-404-code {
    font-size: 8rem;
    font-weight: 700;
    line-height: 1;
    color: #734c75;
    margin: 0 0 1rem 0;
    opacity: 0.9;
    letter-spacing: -4px;
}

.error-404-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    display: block;
}

.error-404 h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin: 0 0 1rem 0;
    font-weight: 600;
}

.error-404 p {
    color: #666;
    font-size: 1.1rem;
    margin: 0 0 2rem 0;
    line-height: 1.6;
}

.error-404 .button {
    display: inline-block;
    padding: 14px 32px;
    background: #734c75;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(115, 76, 117, 0.3);
}

.error-404 .button:hover {
    background: #5a3d5c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(115, 76, 117, 0.4);
    text-decoration: none;
}

@media (max-width: 660px) {
    .error-404 {
        margin: 2rem 1rem;
        padding: 3rem 1.5rem;
    }
    
    .error-404-code {
        font-size: 6rem;
    }
    
    .error-404 h2 {
        font-size: 1.5rem;
    }
}

/* Utility */
.screen-reader-text {
    position: absolute !important;
    clip: rect(1px, 1px, 1px, 1px);
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* Responsive - мобильная версия */
@media (max-width: 660px) {
    .header-inner {
        flex-direction: column;
        gap: 1rem;
    }

    .site-content {
        padding: 1rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.5rem;
    }
}


/* Better Messages - минимальные стили для работы */
.bp-messages-wrap {
    min-height: 400px;
}

.bp-messages-chat-content {
    min-height: 300px;
}

/* Скрыть стандартную кнопку Better Messages */
.bp-messages-button,
.bp-better-messages-mini-chat-button,
#bp-better-messages-mini-mobile-open {
    display: none !important;
}

.legal-page {
    max-width: 800px;
    margin: 2rem auto;
    padding: 3rem 2rem;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.legal-page h1 {
    font-size: 2rem;
    color: #2c3e50;
    margin: 0 0 2rem 0;
    text-align: center;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #0F6B7D;
}

.legal-page h2 {
    font-size: 1.5rem;
    color: #0F6B7D;
    margin: 2rem 0 1rem 0;
    font-weight: 600;
}

.legal-page h3 {
    font-size: 1.2rem;
    color: #0F6B7D;
    margin: 1.5rem 0 0.75rem 0;
    font-weight: 600;
}

.legal-content {
    line-height: 1.8;
    color: #333;
    text-align: left;
}

.legal-content p {
    margin: 0 0 1rem 0;
}

.legal-content ul {
    margin: 0 0 1.5rem 0;
    padding-left: 2rem;
    list-style: disc;
}

.legal-content ul li {
    margin-bottom: 0.5rem;
}

.last-updated {
    margin-top: 3rem;
    padding-top: 1rem;
    border-top: 1px solid #ccc;
    color: #666;
    font-size: 0.9rem;
    text-align: right;
}

/* ===== SINGLE PAGES (Reference & Acute Case) ===== */
.reference-single-body h2,
.acute-single-body h2 {
    font-size: 1.5rem;
    color: #0A5260;
    margin: 2rem 0 1rem 0;
}

.reference-single-body h3,
.acute-single-body h3 {
    font-size: 1.2rem;
    color: #0A5260;
    margin: 1.5rem 0 0.75rem 0;
}

.reference-single-body,
.acute-single-body {
    font-size: 1rem;
    color: #333;
    line-height: 1.8;
}

/* Mobile */
@media (max-width: 768px) {
    .legal-page {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }
    
    .legal-page h1 {
        font-size: 1.5rem;
    }
    
    .legal-page h2 {
        font-size: 1.2rem;
    }
    
    .reference-single-body h2,
    .acute-single-body h2 {
        font-size: 1.2rem;
    }
}

