/* CSS styles for Wushu Federation website */

.title {
	font-family: Verdana;
	font-size: 65%;
	color: #000000;
	background-color: #DDDDEE;
	text-align : center;
	font-weight : bolder;
}

.head {
	font-family: Verdana;
	font-size: 65%;
	color: #000000;
	background-color: #DBE9FC;
	text-align : center;
	font-weight : bolder;
}

.zag1 {
	font-size:8.0pt;
	font-weight:700;
	text-align:left;
	vertical-align:middle;
	white-space:normal;
	padding-left:22px;
}

.pr15b15 { padding: 0 15px 15px 0 }

.zag2 {
	font-size:15.0pt;
	font-weight:700;
	vertical-align:middle;
	border-bottom:.5pt solid silver;
	white-space:normal;
	padding-left:17px;
}

.sdelka {
	font-family:"Courier New", serif;
	font-size:20.0pt;
	font-weight:700;
	vertical-align:top;
	border-top:.10pt solid white;
	border-bottom:.5pt solid silver;
	white-space:normal;
	padding-left:22px;
}

.sdelka2 {
	font-family:"Courier New", serif;
	font-size:20.0pt;
	font-weight:700;
	vertical-align:top;
	border-top:.10pt solid white;
	border-bottom:.5pt solid silver;
	white-space:normal;
}

.poisk {
	font-size:12.0pt;
	font-weight : bolder;
	vertical-align:middle;
	border-top:.5pt solid silver;
	border-bottom:.5pt solid silver;
}

.tablepoisk {
	font-family: Verdana;
	font-size: 165%;
	vertical-align:middle;
	text-align : center;
	font-weight : bolder;
}

.fon {
	font-family: Verdana;
	font-size: 165%;
	color: #DBE9FC;
	background-color: #DBE9FC;
}

table.fon td {
	font-family: Verdana;
	font-size: 65%;
	color: #000000;
	background-color: #FFFFC0;
}

tr.head td{
	font-family: Verdana;
	font-size: 65%;
	color: #000000;
	background-color: #FFFFC0;
	text-align : center;
	font-weight : bolder;
}

tr.grid td, td.c {
	background-color: #FFFFC0;
	white-space : nowrap;
	font-family: Verdana;
	font-size: 65%;
	color: #000000;
	text-align : center;
}

.r {
	text-align : right;
}

input[type=submit], .btn-login, .btn-logout {
	font-size: 14px;
	background-color : #FFFFCC;
	border : 1px solid Black;
	font-weight : bold;
	color : Navy;
	text-align: center;
	padding: 5px 10px;
	cursor: pointer;
	text-decoration: none;
	display: inline-block;
}

input[type=submit]:hover, .btn-login:hover, .btn-logout:hover {
	background-color: #ffeeaa;
}

select, textarea, input[type=text], input[type=password] {
	font-family: Verdana;
	font-size: 90%;
	border : 1px solid Black;
	background-color : #FFFFFF;
	padding: 4px;
}

input[type=text], input[type=password] {
	width: 100%;
	max-width: 250px;
	box-sizing: border-box;
}

textarea {
	width: 100%;
	height : 100px;
	box-sizing: border-box;
}

span.green {
	color : Green;
}
span.rb {
	color : Red;
	font-weight : bold;
}
span.red {
	color : Red;
}
span.blue {
	color : Blue;
}

A:HOVER {
	color : #FF0000;
}

A {
	color : #000000;
	text-decoration : none;
}

/* Базовые стили разметки */
body {
	font-family: Verdana;
	color: #000000;
	margin: 0;
	padding: 0;
	text-align: center;
	font-size: 14px;
	background: #2fb5ea url(img_ags/doc_bg_r.gif) repeat-x;
}

/* Адаптивный контейнер-таблица */
.main-table {
	max-width: 1024px;
	width: 1024px;
	margin: 0 auto;
	background-color: #e9e9df;
	text-align: left;
	box-shadow: 0 0 10px rgba(0,0,0,0.15);
	border-collapse: collapse;
}

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

.footer-content-wrapper img, .page-content-wrapper img {
	max-width: 100%;
	height: auto;
}

/* Ячейки табличной сетки (для больших экранов по умолчанию) */
.sidebar-left-cell {
	width: 184px;
	padding: 20px 0;
	box-sizing: border-box;
	text-align: center;
	display: table-cell;
}

.content-main-cell {
	background-color: #ffffff;
	text-align: left;
}

.sidebar-right-cell {
	text-align: left;
}

/* Стили меню (для больших экранов) */
.menu-table {
	width: auto;
	margin: 0 auto;
	border-collapse: collapse;
}

.menu-row {
	height: 33px;
}

.menu-text-cell {
	padding: 0 15px;
	height: 33px;
	vertical-align: middle;
	white-space: nowrap;
}

.menu-link {
	font-weight: bold;
	font-size: 13px;
	color: Blue;
	text-decoration: none;
	line-height: 1.2;
	display: inline-block;
}

.menu-link.active {
	color: Red;
}

.menu-admin-actions {
	display: inline-flex;
	align-items: center;
	gap: 3px;
	padding-left: 5px;
}

.auth-logout-link {
	margin-top: 30px;
	text-align: center;
}

/* Кнопка закрытия и гамбургер скрыты на десктопе по умолчанию */
.menu-close-btn {
	display: none !important;
}
.hamburger-btn {
	display: none !important;
}
.menu-overlay {
	display: none !important;
}

/* Стили новостей */
.news-header {
	font-weight: bold;
	text-align: center;
	margin-bottom: 15px;
	border-bottom: 2px solid #ea3f39;
	padding-bottom: 5px;
}

.news-item {
	border-bottom: 1px dashed #ccc;
	padding-bottom: 10px;
	margin-bottom: 10px;
	font-size: 13px;
}

.news-more-link {
	color: Blue;
	font-size: 12px;
	display: inline-block;
	margin-top: 5px;
}

.news-admin-actions {
	margin-top: 5px;
	text-align: center;
}

/* Стили для кнопок редактирования и интерфейса редактора */
.edit-page-btn-container {
	display: flex;
	justify-content: flex-end;
	margin-bottom: 15px;
	border-bottom: 1px solid #eee;
	padding-bottom: 10px;
}

.btn-edit-page {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background-color: #ffe01a;
	color: #333300 !important;
	font-weight: bold;
	padding: 8px 16px;
	border-radius: 20px;
	box-shadow: 0 3px 6px rgba(0,0,0,0.1);
	border: 1px solid #e0c200;
	font-size: 13px;
	transition: all 0.2s ease;
}

.btn-edit-page:hover {
	background-color: #ffd400;
	transform: translateY(-2px);
	box-shadow: 0 5px 12px rgba(0,0,0,0.15);
	color: #000000 !important;
}

.editor-container {
	padding: 10px;
}

.editor-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	border-bottom: 2px solid #fee41e;
	padding-bottom: 10px;
	margin-bottom: 20px;
}

.editor-title {
	margin: 0;
	font-size: 18px;
	color: #333;
}

.btn-back-link {
	font-size: 13px;
	font-weight: bold;
	color: Blue !important;
	text-decoration: none;
	padding: 5px 10px;
	border: 1px solid #ccc;
	background-color: #f9f9f9;
	border-radius: 4px;
	transition: all 0.2s ease;
}

.btn-back-link:hover {
	background-color: #eee;
	color: Red !important;
}

.editor-textarea-wrapper {
	margin-bottom: 20px;
	box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.editor-actions {
	display: flex;
	align-items: center;
	gap: 15px;
	justify-content: center;
	margin-top: 20px;
}

.btn-save-changes {
	background-color: #2ea44f !important;
	color: white !important;
	border: 1px solid rgba(27,31,35,0.15) !important;
	font-weight: bold;
	padding: 10px 24px !important;
	font-size: 14px !important;
	border-radius: 6px;
	cursor: pointer;
	box-shadow: 0 3px 6px rgba(0,0,0,0.08);
	transition: all 0.2s ease;
}

.btn-save-changes:hover {
	background-color: #2c974b !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.btn-discard-changes {
	background-color: #fafbfc !important;
	color: #24292e !important;
	border: 1px solid rgba(27,31,35,0.15) !important;
	font-weight: bold;
	padding: 10px 24px;
	font-size: 14px;
	border-radius: 6px;
	text-decoration: none;
	display: inline-block;
	box-shadow: 0 3px 6px rgba(0,0,0,0.04);
	transition: all 0.2s ease;
}

.btn-discard-changes:hover {
	background-color: #f3f4f6 !important;
	color: #000 !important;
}

.access-denied-box {
	text-align: center;
	padding: 40px 20px;
	border: 1px dashed #ea3f39;
	background-color: #fff9f9;
	border-radius: 8px;
	margin-top: 20px;
}

.lock-icon {
	font-size: 48px;
	display: block;
	margin-bottom: 15px;
}

.btn-login-redirect {
	background-color: #0066FF;
	color: white !important;
	padding: 10px 20px;
	font-weight: bold;
	border-radius: 4px;
	text-decoration: none;
	display: inline-block;
}

.btn-login-redirect:hover {
	background-color: #0052cc;
}

/* АДАПТИВНОСТЬ ДЛЯ МОБИЛЬНЫХ УСТРОЙСТВ И УЗКИХ ЭКРАНОВ */
@media (max-width: 1024px) {
	/* Показываем кнопку гамбургера */
	.hamburger-btn {
		display: flex !important;
		flex-direction: column;
		justify-content: space-between;
		width: 32px;
		height: 24px;
		background: #ffffff;
		border: 1px solid #1c7293;
		border-radius: 4px;
		padding: 5px;
		cursor: pointer;
		position: fixed;
		top: 15px;
		right: 15px;
		z-index: 1000;
		box-shadow: 0 2px 5px rgba(0,0,0,0.2);
	}

	.hamburger-line {
		display: block;
		width: 100%;
		height: 3px;
		background-color: #1c7293;
		border-radius: 2px;
		transition: all 0.3s ease;
	}

	/* Эффект крестика при активации гамбургера */
	.hamburger-btn.active .hamburger-line:nth-child(1) {
		transform: translateY(7px) rotate(45deg);
	}
	.hamburger-btn.active .hamburger-line:nth-child(2) {
		opacity: 0;
	}
	.hamburger-btn.active .hamburger-line:nth-child(3) {
		transform: translateY(-7px) rotate(-45deg);
	}

	/* Подложка при открытом меню */
	.menu-overlay {
		display: block !important;
		position: fixed;
		top: 0;
		left: 0;
		width: 100vw;
		height: 100vh;
		background-color: rgba(0,0,0,0.6);
		z-index: 998;
		opacity: 0;
		pointer-events: none;
		transition: opacity 0.3s ease;
	}

	.menu-overlay.active {
		opacity: 1;
		pointer-events: auto;
	}

	/* Превращаем таблицы в блочные элементы */
	.main-table, .main-table tbody, .main-table tr, .main-table td {
		display: block !important;
		width: 100% !important;
		max-width: 100% !important;
		box-sizing: border-box;
	}

	.main-table {
		box-shadow: none;
	}

	/* Превращаем левую панель в выдвижную (off-canvas drawer) */
	.sidebar-left-cell {
		position: fixed !important;
		top: 0 !important;
		left: 0 !important;
		height: 100vh !important;
		width: 260px !important;
		z-index: 999 !important;
		background-color: #d8d8ce !important;
		background-image: none !important; /* убираем фоновую картинку left.jpg */
		box-shadow: 4px 0 15px rgba(0,0,0,0.3) !important;
		transform: translateX(-100%);
		transition: transform 0.3s ease !important;
		padding: 60px 15px 20px 15px !important;
		text-align: center;
		overflow-y: auto;
		display: block !important;
	}

	.sidebar-left-cell.open {
		transform: translateX(0) !important;
	}

	/* Кнопка закрытия внутри выдвижной панели */
	.menu-close-btn {
		display: block !important;
		position: absolute;
		top: 15px;
		right: 15px;
		font-size: 32px;
		font-weight: bold;
		background: transparent;
		border: none;
		color: #555;
		cursor: pointer;
		line-height: 1;
		padding: 0;
	}

	/* Меню выстраивается вертикально внутри выдвижной панели */
	.menu-table, .menu-table tbody {
		display: table !important;
		width: auto !important;
		margin: 0 auto !important;
	}

	.menu-row {
		display: table-row !important;
		height: auto !important;
	}

	.knopka-edge {
		display: table-cell !important;
	}

	.menu-text-cell {
		display: table-cell !important;
		background-image: url(/images/knopka_m.jpg) !important;
		background-repeat: repeat-x !important;
		padding: 0 15px !important;
		height: 33px !important;
		white-space: nowrap !important;
	}

	/* Рамки и отступы основного контента и новостей на мобильных */
	.content-main-cell {
		border-left: none !important;
		border-right: none !important;
		border-top: double 4px #fee41e !important;
		border-bottom: double 4px #fee41e !important;
		padding: 20px 15px !important;
	}

	.sidebar-right-cell {
		border-left: none !important;
		border-right: none !important;
		border-bottom: double 4px #ea3f39 !important;
		padding: 20px 15px !important;
	}

	.editor-header {
		flex-direction: column;
		gap: 10px;
		text-align: center;
	}
}

/* Стили кнопки редактирования подвала */
.edit-footer-btn-container {
	text-align: center;
	margin-bottom: 8px;
	margin-top: 5px;
}

.btn-edit-footer {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-size: 11px;
	background-color: rgba(255, 224, 26, 0.9);
	color: #333300 !important;
	font-weight: bold;
	padding: 4px 12px;
	border-radius: 12px;
	border: 1px solid #e0c200;
	transition: all 0.2s ease;
	text-decoration: none;
	box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-edit-footer:hover {
	background-color: #ffd400;
	transform: scale(1.05);
	box-shadow: 0 4px 8px rgba(0,0,0,0.15);
	color: #000000 !important;
}