:root {
    --primary: #222;
    --accent: #ff4757;
    --bg: #f1f2f6;
    --card-bg: #ffffff;
    --text: #2f3542;
    --text-muted: #747d8c;
    --border: #e4e7eb;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Шапка сайта */
.main-header {
    background: var(--primary);
    padding: 15px 0;
}
.main-header nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    gap: 20px;
}
.main-header nav a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 4px;
}
.main-header nav a.active, .main-header nav a:hover {
    background: var(--accent);
}

/* Сетка товаров */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.product-card {
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--border);
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.2s;
}
.product-card:hover {
    transform: translateY(-5px);
}

.badge-sale {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--accent);
    color: white;
    padding: 4px 8px;
    font-size: 12px;
    font-weight: bold;
    border-radius: 4px;
    z-index: 2;
}

.product-img-wrap {
    height: 250px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}
.product-img-wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.product-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.product-vendor {
    font-size: 12px;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: bold;
}
.product-title {
    font-size: 16px;
    margin: 8px 0;
    height: 48px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}
.product-desc {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 15px;
    flex-grow: 1;
}

.product-price-block {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}
.current-price {
    font-size: 20px;
    font-weight: bold;
    color: var(--primary);
}
.old-price {
    font-size: 14px;
    text-decoration: line-through;
    color: var(--text-muted);
}

.btn-buy {
    background: var(--primary);
    color: white;
    text-align: center;
    text-decoration: none;
    padding: 10px;
    border-radius: 6px;
    font-weight: 500;
}
.btn-buy:hover {
    background: #000;
}

/* Сетка Блога */
.blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}
.blog-card {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid var(--border);
}
.post-date {
    font-size: 13px;
    color: var(--text-muted);
}
.read-more {
    color: var(--accent);
    text-decoration: none;
    font-weight: bold;
}

/* Красивое оформление цитаты с линией слева */
.wysiwyg-editor blockquote, 
blockquote {
    border-left: 4px solid #ccc; /* Вертикальная черта */
    padding-left: 15px;          /* Отступ текста от линии */
    margin-left: 0;
    margin-right: 0;
    font-style: italic;          /* Курсив для текста цитаты */
    color: #555;
}

/* Live-Панель */
#live-panel {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 30px;
    color: white;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}
.live-panel-hidden { transform: translateX(200%); }
.live-panel-visible { transform: translateX(0); }

.status-ok { background: #2ed573; }
.status-alert { background: #ffa502; }
.status-error { background: #ff4757; }

.live-icon {
    animation: blink 1.5s infinite;
}
@keyframes blink {
    0% { opacity: 0.2; }
    50% { opacity: 1; }
    100% { opacity: 0.2; }
}

/* Делаем все картинки внутри контента визуально кликабельными */
.wysiwyg-editor img, 
.post-content img, 
article img {
    cursor: zoom-in;
    transition: opacity 0.2s ease;
}
.wysiwyg-editor img:hover, 
.post-content img:hover, 
article img:hover {
    opacity: 0.9; /* Легкое затемение при наведении */
}
