:root {
    --primary-color: #8B5CF6;
    --primary-dark: #7C3AED;
    --primary-light: #A78BFA;
    --secondary-color: #1E293B;
    --accent-color: #3B82F6;
    --accent-dark: #2563EB;
    --text-dark: #1F2937;
    --text-light: #6B7280;
    --bg-white: #FFFFFF;
    --bg-gray: #F8FAFC;
    --bg-dark: #0F172A;
    --border-color: #E5E7EB;
    --success-color: #10B981;
    --error-color: #EF4444;
    --warning-color: #F59E0B;
    
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 6px 10px -1px rgba(0, 0, 0, 0.1), 0 4px 6px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    --gradient-dark: linear-gradient(135deg, var(--secondary-color), var(--bg-dark));
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: linear-gradient(135deg, var(--bg-gray) 0%, #ffffff 100%);
    min-height: 100vh;
}

/* Header Styles */
.main-header {
    background: var(--gradient-dark);
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.navbar {
    padding: 1rem 0;
}

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

.nav-logo a {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--bg-white);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: all 0.3s ease;
}

.nav-logo a:hover {
    transform: translateY(-2px);
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--bg-white);
    text-decoration: none;
    font-weight: 500;
    padding: 0.7rem 1.5rem;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 2px solid transparent;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary-light);
    transform: translateY(-2px);
}

.admin-login {
    background: var(--gradient-primary);
    border-color: var(--primary-color);
}

.admin-login:hover {
    background: transparent;
    border-color: var(--bg-white);
    transform: translateY(-2px);
}

/* Hero Section */
.hero {
    background: var(--gradient-dark);
    color: white;
    padding: 5rem 0;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><polygon fill="%238B5CF6" fill-opacity="0.1" points="0,1000 1000,0 1000,1000"/></svg>');
    background-size: cover;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
    line-height: 1.2;
}

.hero-content p {
    font-size: 1.3rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
	padding-top: 25px;
}

/* Blog Posts Grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 2.5rem;
    margin-bottom: 4rem;
}

.post-card {
    background: var(--bg-white);
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    position: relative;
}

.post-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
}

.post-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.post-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-card:hover .post-image {
    transform: scale(1.05);
}

.no-image {
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 3rem;
}

.post-content {
    padding: 2rem;
}

.post-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 1rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.post-date, .post-views {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.post-views {
    color: var(--primary-color);
    font-weight: 600;
}

.post-excerpt {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tag {
    background: var(--primary-light);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 2rem;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tag:hover {
    background: var(--primary-color);
    transform: translateY(-1px);
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    background: var(--gradient-primary);
    color: white;
    padding: 0.9rem 1.8rem;
    border-radius: 0.75rem;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
}

.read-more:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Forms */
.form-container {
    background: var(--bg-white);
    padding: 3rem;
    border-radius: 1.5rem;
    box-shadow: var(--shadow-lg);
    max-width: 900px;
    margin: 2rem auto;
    border: 1px solid var(--border-color);
}

.form-title {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--secondary-color);
    font-size: 2.2rem;
    font-weight: 700;
}

.form-group {
    margin-bottom: 2rem;
}

.form-label {
    display: block;
    margin-bottom: 0.7rem;
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 1rem;
}

.form-input, .form-textarea, .form-select, .form-file {
    width: 100%;
    padding: 1rem 1.2rem;
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--bg-white);
    font-family: inherit;
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
    transform: translateY(-1px);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.5;
}

.form-file {
    padding: 0.8rem 1.2rem;
}

/* Text Editor */
.editor-container {
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    overflow: hidden;
    background: var(--bg-white);
}

.editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    padding: 1rem;
    background: var(--bg-gray);
    border-bottom: 1px solid var(--border-color);
}

.editor-btn {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.6rem 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-dark);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.editor-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.editor-content {
    min-height: 400px;
    padding: 1.5rem;
    background: var(--bg-white);
    line-height: 1.6;
    overflow-y: auto;
}

.editor-content:focus {
    outline: none;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    padding: 1rem 2rem;
    border: none;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--bg-gray);
    color: var(--text-dark);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
    transform: translateY(-2px);
}

.btn-danger {
    background: var(--error-color);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-2px);
}

.btn-sm {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
}

/* Footer */
.main-footer {
    background: var(--gradient-dark);
    color: white;
    padding: 4rem 0 2rem;
    margin-top: 6rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h3, .footer-section h4 {
    margin-bottom: 1.5rem;
    color: var(--primary-light);
}

.footer-section h3 {
    font-size: 1.5rem;
}

.footer-section a {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--primary-light);
}

.footer-section p {
    margin-bottom: 0.8rem;
    opacity: 0.9;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.8rem;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.social-link:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.footer-bottom {
    text-align: center;
    padding-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-light);
}

.footer-bottom p {
    margin-bottom: 0.5rem;
}

/* Admin Styles */
.admin-panel {
    background: var(--bg-white);
    border-radius: 1.5rem;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    margin: 2rem auto;
    max-width: 1400px;
    border: 1px solid var(--border-color);
}

.admin-header {
    background: var(--gradient-dark);
    color: white;
    padding: 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 2rem;
}

.admin-nav {
    background: var(--bg-gray);
    padding: 1.5rem 2.5rem;
    border-bottom: 1px solid var(--border-color);
}

.admin-nav-list {
    display: flex;
    gap: 1.5rem;
    list-style: none;
    flex-wrap: wrap;
}

.admin-nav-link {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 600;
    padding: 0.8rem 1.5rem;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border: 2px solid transparent;
}

.admin-nav-link.active, .admin-nav-link:hover {
    background: var(--gradient-primary);
    color: white;
    transform: translateY(-2px);
}

.admin-content {
    padding: 2.5rem;
}

/* Login Page */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-dark);
    padding: 2rem;
}

.login-box {
    background: var(--bg-white);
    padding: 3.5rem;
    border-radius: 1.5rem;
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 450px;
    border: 1px solid var(--border-color);
}

.login-title {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--secondary-color);
    font-size: 2.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

/* Alerts */
.alert {
    padding: 1.2rem 1.5rem;
    border-radius: 0.75rem;
    margin-bottom: 1.5rem;
    border-left: 4px solid;
    font-weight: 500;
}

.alert-success {
    background: #D1FAE5;
    border-color: var(--success-color);
    color: #065F46;
}

.alert-error {
    background: #FEE2E2;
    border-color: var(--error-color);
    color: #7F1D1D;
}

.alert-warning {
    background: #FEF3C7;
    border-color: var(--warning-color);
    color: #92400E;
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--text-light);
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .admin-nav-list {
        flex-direction: column;
        gap: 1rem;
    }
    
    .form-container {
        padding: 2rem;
        margin: 1rem;
    }
    
    .login-box {
        padding: 2rem;
        margin: 1rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* Loading Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}
/* Анимации для админки */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.admin-content > * {
    animation: slideIn 0.3s ease;
}

/* Адаптивность для таблиц */
@media (max-width: 1024px) {
    .posts-table {
        font-size: 0.9rem;
    }
    
    .posts-table th,
    .posts-table td {
        padding: 0.8rem;
    }
}

@media (max-width: 768px) {
    .posts-table {
        display: block;
        overflow-x: auto;
    }
    
    .form-row {
        flex-direction: column;
    }
    
    .action-buttons {
        flex-direction: column;
    }
}

/* Улучшения для редактора */
.editor-content {
    min-height: 400px;
    max-height: 600px;
    overflow-y: auto;
}

.editor-content:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-color);
}

/* Статусы для постов */
.post-status {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-published {
    background: #D1FAE5;
    color: #065F46;
}

.status-draft {
    background: #FEF3C7;
    color: #92400E;
}

.status-pending {
    background: #DBEAFE;
    color: #1E40AF;
}
/* Advanced Editor Styles */
.editor-container {
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    overflow: hidden;
    background: var(--bg-white);
}

.editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    padding: 1rem;
    background: var(--bg-gray);
    border-bottom: 1px solid var(--border-color);
    align-items: center;
}

.editor-btn {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 0.6rem 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-dark);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.editor-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.editor-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.toolbar-separator {
    width: 1px;
    background: var(--border-color);
    margin: 0 0.3rem;
    height: 24px;
}

.toolbar-group {
    display: flex;
    gap: 0.3rem;
    align-items: center;
}

.editor-content {
    min-height: 400px;
    padding: 1.5rem;
    background: var(--bg-white);
    line-height: 1.6;
    overflow-y: auto;
    font-family: 'Inter', sans-serif;
}

.editor-content:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-color);
}

/* HTML Mode Styles */
.editor-html-container {
    border-top: 1px solid var(--border-color);
}

.editor-html-textarea {
    width: 100%;
    min-height: 400px;
    padding: 1.5rem;
    border: none;
    background: #f8f9fa;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    color: var(--text-dark);
}

.editor-html-textarea:focus {
    outline: none;
    background: #fff;
}

/* Content Styles inside Editor */
.editor-content h1,
.editor-content h2,
.editor-content h3,
.editor-content h4,
.editor-content h5,
.editor-content h6 {
    color: var(--secondary-color);
    margin: 1.5rem 0 1rem 0;
    font-weight: 600;
}

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

.editor-content p {
    margin-bottom: 1rem;
    line-height: 1.6;
}

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

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

.editor-content blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: var(--text-light);
    background: var(--bg-gray);
    padding: 1.5rem;
    border-radius: 0 0.5rem 0.5rem 0;
}

.editor-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1rem 0;
}

.editor-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.editor-content table th,
.editor-content table td {
    border: 1px solid var(--border-color);
    padding: 0.75rem;
    text-align: left;
}

.editor-content table th {
    background: var(--bg-gray);
    font-weight: 600;
}

.editor-content code {
    background: #f4f4f4;
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #e83e8c;
}

.editor-content pre {
    background: #2d2d2d;
    color: #f8f8f2;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin: 1rem 0;
}

.editor-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.editor-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.editor-content a:hover {
    text-decoration: underline;
}

/* Placeholder */
[data-placeholder]:empty:before {
    content: attr(data-placeholder);
    color: var(--text-light);
    font-style: italic;
}

/* Responsive Editor */
@media (max-width: 768px) {
    .editor-toolbar {
        gap: 0.2rem;
        padding: 0.75rem;
    }
    
    .editor-btn {
        padding: 0.5rem 0.7rem;
        font-size: 0.8rem;
    }
    
    .editor-content {
        padding: 1rem;
        min-height: 300px;
    }
    
    .editor-html-textarea {
        padding: 1rem;
        min-height: 300px;
    }
}

.current-image {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-gray);
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
}

.image-preview {
    max-width: 300px;
    max-height: 200px;
    border-radius: 0.5rem;
    margin: 0.5rem 0;
    display: block;
    border: 2px solid var(--primary-color);
}

.image-info {
    margin-top: 0.5rem;
    padding: 0.5rem;
    background: var(--bg-white);
    border-radius: 0.25rem;
    font-size: 0.8rem;
    color: var(--text-light);
}

.image-error {
    padding: 1rem;
    background: #fee2e2;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    color: #dc2626;
    margin: 0.5rem 0;
}

.image-error i {
    margin-right: 0.5rem;
}

.remove-image-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    cursor: pointer;
    margin-top: 1rem;
    padding: 0.5rem;
    background: var(--bg-white);
    border-radius: 0.25rem;
}

.post-image-full {
    margin-bottom: 2rem;
    border-radius: 0.75rem;
    overflow: hidden;
    box-shadow: var(--shadow);
    text-align: center; /* Центрируем изображение */
}

.post-image-full img {
    max-width: 100%;
    height: auto;
    max-height: 500px; /* Ограничиваем максимальную высоту */
    width: auto;
    border-radius: 0.75rem;
    transition: transform 0.3s ease;
    object-fit: contain; /* Сохраняем пропорции */
}

.post-image-full:hover img {
    transform: scale(1.01);
}

/* Стили для похожих статей - изображения */
.similar-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 0.5rem 0.5rem 0 0;
    transition: transform 0.3s ease;
}

.similar-card:hover .similar-image {
    transform: scale(1.05);
}

.similar-image.no-image {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
}

/* Контейнер для похожих статей */
.similar-posts {
    margin: 4rem 0;
    padding: 2rem 0;
    border-top: 2px solid var(--border-color);
}

.similar-posts h2 {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--secondary-color);
    font-size: 2.2rem;
    font-weight: 700;
}

.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.similar-card {
    background: var(--bg-white);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.similar-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.similar-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.similar-content h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 0;
}

.similar-content p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex-grow: 1;
}

.similar-content .read-more {
    align-self: flex-start;
    margin-top: auto;
}

/* Адаптация для планшетов */
@media (max-width: 1024px) {
    .similar-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 1.5rem;
    }
    
    .similar-image {
        height: 160px;
    }
    
    .similar-content {
        padding: 1.25rem;
    }
    
    .similar-content h3 {
        font-size: 1.1rem;
    }
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    .similar-posts {
        margin: 3rem 0;
        padding: 1.5rem 0;
    }
    
    .similar-posts h2 {
        font-size: 1.8rem;
        margin-bottom: 2rem;
    }
    
    .similar-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .similar-image {
        height: 200px;
    }
    
    .similar-card {
        border-radius: 0.75rem;
    }
    
    .similar-content {
        padding: 1.5rem;
    }
    
    .similar-content h3 {
        font-size: 1.3rem;
    }
}

/* Адаптация для маленьких мобильных */
@media (max-width: 480px) {
    .similar-posts {
        margin: 2rem 0;
    }
    
    .similar-posts h2 {
        font-size: 1.6rem;
        margin-bottom: 1.5rem;
    }
    
    .similar-grid {
        gap: 1rem;
    }
    
    .similar-image {
        height: 180px;
    }
    
    .similar-content {
        padding: 1.25rem;
    }
    
    .similar-content h3 {
        font-size: 1.2rem;
        margin-bottom: 0.75rem;
    }
    
    .similar-content p {
        margin-bottom: 1rem;
        -webkit-line-clamp: 2;
    }
}

/* Дополнительные стили для консистентности */
.similar-card .read-more {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
}

.similar-card .read-more i {
    font-size: 0.8rem;
}

/* Анимация появления */
.similar-card {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

.similar-card:nth-child(1) { animation-delay: 0.1s; }
.similar-card:nth-child(2) { animation-delay: 0.2s; }
.similar-card:nth-child(3) { animation-delay: 0.3s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}