/* Переменные для Светлой темы (по умолчанию) */
html[data-theme="light"] {
	--bg-input: #ffffff;
	--color-input: #000000;
	--color-diller: green;
	--border-input: #333333;
	--text-color: #2d3748;
	--text-muted: #718096;
	--card-border: rgba(0, 0, 0, 0.08);
	--accent-color: #3182ce;
	--accent-hover: #2b6cb0;
	--header-bg: #ffffff;
	--shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
	--bg-sidebar: #f4f5f7;
	--bg-item-hover: #e2e8f0;
	--bg-item-active: #3b82f6;
	--text-active: #ffffff;
	--divider-color: #e2e8f0;
	--transition-speed: 0.3s;
}

/* Переменные для Темной темы */
html[data-theme="dark"] {
	--bg-input: #1c2637;
	--color-diller: lime;
	--color-input: #ffffff;
	--border-input: #ffffff;
	--text-color: #f7fafc;
	--text-muted: #a0aec0;
	--card-border: rgba(255, 255, 255, 0.08);
	--accent-color: #63b3ed;
	--accent-hover: #4299e1;
	--header-bg: #2d3748;
	--shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
	--bg-sidebar: #1e293b;
	--bg-item-hover: #334155;
	--bg-item-active: #3b82f6;
	--text-color: #f1f5f9;
	--text-active: #ffffff;
	--divider-color: #334155;
}

.card-data {
	background: var(--card-bg);
	color: var(--text-color);
	max-width: 600px;
	margin: 20px auto;
	padding: 20px;
	min-height: calc(100vh - 400px);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;

}

.card-data-sum {
	background: var(--card-bg);
	color: var(--text-color);
	width: 90%;
	max-width: 1400px;
	margin: 20px auto;
	padding: 20px;
	min-height: calc(100vh - 400px);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;

}


.category-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 2rem;
}

/* Карточка категории */
.category-card {
	background-color: var(--card-bg);
	border: 1px solid var(--card-border);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: var(--shadow);
	display: flex;
	flex-direction: column;
}

.block-text {
	width: 100%;
	text-align: center;
	color: var(--text-muted);
	padding: 0px 0 30px 0;
}

.block-button {
	width: 100%;
	text-align: center;
}


.category-image img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    display: block;
}

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

.category-title {
	font-size: 1.25rem;
	margin-bottom: 0.5rem;
	font-weight: 600;
}

.category-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

/* Нижняя часть карточки */
.category-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--card-border);
    padding-top: 1rem;
    font-size: 0.9rem;
}

.category-count {
    color: var(--text-muted);
}

.category-count strong {
    color: var(--text-color);
}

.category-link {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
}

.category-link:hover {
	color: var(--accent-hover);
	text-decoration: underline;
}

.shop-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 24px;
	font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
	color: #2d3436;
	padding: 20px;
	box-sizing: border-box;
}

.product-card {
	background-color: var(--card-bg);
	border: 1px solid var(--card-border);
	border-radius: 12px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	padding-top: 10px;
}

.product-card:hover {
	transform: translateY(-4px);
	border: 1px solid #888;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* Изображение */
.product-image {
	width: 100%;
	height: 210px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
}

.product-image img {
	width: 100%;
	height: 100%;
	margin: 0 auto;
	object-fit: contain;
	transition: transform 0.3s ease;
}

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

/* Инфо-блок */
.product-content {
	padding: 16px;
	display: flex;
	flex-direction: column;
	flex-grow: 1;
}

.product-title {
	color: var(--text-color);
	font-size: 1.05rem;
	text-align: center;
	font-weight: 600;
	line-height: 1.2;
	margin: 0 0 8px 0;
}

.product-price {
	font-size: 1.25rem;
	font-weight: 700;
	color: #0984e3;
	text-align: right;
}

.product-price-block {
	width: 100%;
	display: flex;
	flex-direction: column;
	margin: 12px 0;
}



/* Список характеристик */
.product-specs {
    list-style: none;
    padding: 0;
    margin: 0 0 16px 0;
    border-top: 1px solid #f1f2f6;
    border-bottom: 1px solid #f1f2f6;
    padding: 10px 0;
    font-size: 0.85rem;
}

.product-specs li {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
}

.product-specs li:last-child {
    margin-bottom: 0;
}

.spec-name {
    color: #b2bec3;
}

.spec-value {
    font-weight: 500;
    color: #636e72;
    text-align: right;
}

/* Форма и элементы управления */
.product-actions-form {
	margin-top: auto;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.quantity-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.9rem;
    color: #636e72;
}

.qty-input {
	width: 80px;
	background: var(--bg-input);
	color: var(--color-input);
	padding: 6px 8px;
	border: 1.5px: solid var(--border-input);;
	border-radius: 6px;
	text-align: center;
	font-size: 0.95rem;
	outline: none;
	transition: border-color 0.2s;
}

.qty-input:focus {
	border-color: #0984e3;
}

/* Кнопки */
.buttons-row {
	display: flex;
	gap: 8px;
	justify-content: center;
}

.btn-shop {
	align-items: center;
	justify-content: center;
	padding: 5px 10px;
	border-radius: 8px;
	font-size: 0.9rem;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s, transform 0.1s;
	border: none;
	text-align: center;
}


.btn-buy {
	background-color: #0984e3;
	color: #ffffff;
}

.btn-buy:hover {
	background-color: #74b9ff;
}

.btn-details {
    background-color: #f1f2f6;
    color: #2d3436;
}

.btn-details:hover {
    background-color: #dfe6e9;
}

.btn:active {
    transform: scale(0.98);
}


.page-wrapper {
	display: grid;
	grid-template-columns: 290px 1fr; /* Левая колонка 250px, правая - всё остальное */
	min-height: calc(100vh - 120px); /* Высота за вычетом шапки и подвала */
}

.sidebar {
	background-color: var(--bg-card);
	padding: 20px;
	border-right: 1px solid #bdc3c7;
}

.main-content {
	padding: 20px;
}

.sCat {
	padding: 5px 0;
	color: var(--text-color);
	font-size: 0.9rem;
}
.sCat:hover {
	background: var(--accent-hover:);
}

/* Левая панель со списком категорий */

.category-list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.category-item {
	position: relative;
	border-radius: 8px;
	overflow: hidden;
	transition: background-color var(--transition-speed) ease;
}

.category-item a {
	display: flex;
	align-items: center;
	padding: 12px 16px;
	color: var(--text-color);
	text-decoration: none;
	font-size: 16px;
	font-weight: 500;
	position: relative;
	z-index: 2;
	transition: color var(--transition-speed) ease, transform 0.2s ease;
}

.category-item:hover a {
	transform: translateX(4px);
	text-decoration: none;
}

.category-item::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	width: 0; /* Изначально скрыт */
	height: 100%;
	background-color: var(--bg-item-hover);
	z-index: 1;
	transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1); /* Красивое ускорение сглаживания */
}

.category-item:hover::before {
	width: 100%;
}

.category-item.active {
	background-color: var(--bg-item-active);
}

.category-item.active a {
	color: var(--text-active);
}

.category-item.active::before {
	display: none;
}

.category-item .icon {
	margin-right: 12px;
	font-size: 18px;
	transition: transform 0.3s ease;
}

.category-item:hover .icon {
	transform: scale(1.15) rotate(-5deg);
}

.diller {
	color: var(--color-diller);
}
.form-actions {
	width: 100%;
	text-align: center;
}
.modal-global-window {
	max-width: 460px;
}

.shopnotice {
	width: 100%;
	padding: 0 0 30px 0;
	text-align: center;
}


@media (max-width: 767px) {
	.page-wrapper {	grid-template-columns: 1fr; }
	.sidebar { display: none; }
}

