
:root {
    /* Цветовая палитра (Dark Mode Theme) */
    --bg-body: #0f172a;
    --bg-surface: #1e293b;
    --bg-surface-hover: #334155;
    
    --primary-color: #3b82f6;
    --primary-hover: #2563eb;
    --primary-glow: rgba(59, 130, 246, 0.5);
    
    --secondary-color: #10b981;
    --accent-color: #f59e0b;
    
    --text-main: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --border-color: #334155;
    
    /* Размеры и отступы */
    --container-width: 1200px;
    --header-height: 80px;
    --radius-sm: 0.5rem;
    --radius-md: 1rem;
    --radius-lg: 1.5rem;
    
    /* Типографика */
    --font-main: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    
    /* Эффекты */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.15);
    --shadow-glow: 0 0 20px var(--primary-glow);
    
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Скроллбар */
::-webkit-scrollbar {
    width: 0.75rem;
}
::-webkit-scrollbar-track {
    background: var(--bg-body);
}
::-webkit-scrollbar-thumb {
    background: var(--bg-surface-hover);
    border-radius: 10px;
    border: 3px solid var(--bg-body);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--text-secondary);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

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

/* --- Layout --- */
.grid-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

/* --- Header --- */
.site-header {
    background-color: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
    box-shadow: var(--shadow-md);
}

.inside-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.site-logo img {
    height: 40px; /* Адаптация лого */
    width: auto;
    transition: transform var(--transition-fast);
}

.site-logo:hover img {
    transform: scale(1.05);
}

/* Navigation */
.main-navigation ul {
    display: flex;
    gap: 1.5rem;
}

.main-navigation a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-secondary);
    position: relative;
    padding: 0.5rem 0;
}

.main-navigation a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width var(--transition-smooth);
    border-radius: 2px;
}

.main-navigation a:hover {
    color: var(--text-main);
}

.main-navigation a:hover::after {
    width: 100%;
}

/* --- Mobile Menu Toggle --- */
.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    font-size: 1.5rem;
}

.gp-icon svg {
    fill: currentColor;
}

/* --- Main Content Area --- */
.site-content {
    padding-top: 3rem;
    padding-bottom: 4rem;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.content-area {
    flex: 1;
    min-width: 0; /* Fix flex overflow */
}

/* Article Styling */
.inside-article {
    background-color: var(--bg-surface);
    border-radius: var(--radius-md);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

/* Typography Headings */
h1.entry-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    text-align: center;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, #fff 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

h2.wp-block-heading {
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    margin-top: 3rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    position: relative;
    padding-left: 1rem;
    border-left: 4px solid var(--primary-color);
}

p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.8;
}

/* Lists */
.wp-block-list {
    margin-bottom: 2rem;
    padding-left: 1.5rem;
}

.wp-block-list li {
    position: relative;
    margin-bottom: 0.75rem;
    padding-left: 1.5rem;
    color: var(--text-secondary);
}

.wp-block-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-color);
    font-weight: bold;
}

/* Images */
.wp-block-image figure {
    margin: 2rem 0;
}

.wp-block-image img {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-smooth), box-shadow var(--transition-smooth);
}

.wp-block-image img:hover {
    transform: scale(1.01);
    box-shadow: var(--shadow-glow);
}

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

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

/* --- Buttons (Winlink) --- */
.button-container {
    display: flex;
    justify-content: center;
    margin: 2.5rem 0;
}

.winlink {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: white;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    border-radius: 50px;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
    transition: all var(--transition-smooth);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.winlink::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--secondary-color), #059669);
    opacity: 0;
    z-index: -1;
    transition: opacity var(--transition-smooth);
}

.winlink:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.6);
}

.winlink:hover::before {
    opacity: 1;
}

.winlink:active {
    transform: translateY(-1px);
}

/* --- Sidebar --- */
.sidebar {
    width: 300px;
    flex-shrink: 0;
}

.widget {
    background-color: var(--bg-surface);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
}

/* --- Footer --- */
.site-footer {
    background-color: #0b1120;
    border-top: 1px solid var(--border-color);
    padding: 3rem 0;
    margin-top: auto;
}

.footer-widgets-container {
    margin-bottom: 2rem;
}

.footer-widget-1 ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
}

.footer-widget-1 a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: color var(--transition-fast);
}

.footer-widget-1 a:hover {
    color: var(--primary-color);
}

.site-info {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.875rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* --- Mobile Menu (Slideout) --- */
.slideout-navigation {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    background-color: var(--bg-surface);
    z-index: 1001;
    transform: translateX(100%);
    transition: transform var(--transition-smooth);
    box-shadow: -5px 0 20px rgba(0,0,0,0.5);
    padding-top: 4rem;
}

.slideout-navigation.is-open {
    transform: translateX(0);
}

.slideout-menu li {
    border-bottom: 1px solid var(--border-color);
}

.slideout-menu a {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--text-main);
    font-size: 1.1rem;
}

.slideout-exit {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
}

/* --- Forms (Generic Styles) --- */
input[type="text"], 
input[type="email"], 
input[type="password"], 
textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background-color: var(--bg-body);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-main);
    font-family: inherit;
    transition: all var(--transition-fast);
}

input:focus, 
textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

/* --- Responsive Design --- */

/* Tablet & Mobile */
@media (max-width: 1024px) {
    .inside-header {
        justify-content: space-between;
    }
    
    .main-navigation:not(.slideout-navigation) {
        display: none; /* Скрываем десктопное меню */
    }
    
    .menu-toggle {
        display: block; /* Показываем кнопку бургера */
    }

    .site-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        margin-top: 2rem;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 60px;
    }

    .grid-container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .inside-article {
        padding: 1.5rem;
    }

    .wp-block-columns {
        flex-direction: column;
        gap: 1.5rem;
    }

    .winlink {
        width: 100%;
        padding: 0.9rem 1rem;
    }

    h1.entry-title {
        margin-bottom: 1.5rem;
    }
    
    h2.wp-block-heading {
        margin-top: 2rem;
        font-size: 1.5rem;
    }
}

/* --- Utility Animations --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.inside-article {
    animation: fadeIn 0.6s ease-out;
}
