pmi-site/static/css/custom.css

207 lines
4.9 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/* background*/
body {
margin: 0;
padding: 0;
background: linear-gradient(135deg, #f5f7fa 0%, #e8eef5 100%);
position: relative;
min-height: 100vh;
}
body::before {
content: '';
position: fixed;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
z-index: -1;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='50' height='50' viewBox='0 0 50 50'%3E%3Cpath d='M0 0 L50 50 M50 0 L0 50' stroke='%23003366' stroke-width='0.5' opacity='0.08'/%3E%3Ccircle cx='25' cy='25' r='1.5' fill='%23003366' opacity='0.12'/%3E%3C/svg%3E");
background-size: 50px 50px;
transform: rotate(20deg);
}
/* ------------------------------------------------------------------ */
/* Плавные анимации и переходы */
/* Плавное появление элементов */
header, main, footer {
animation: fadeIn 0.6s ease-out;
}
@keyframes fadeIn {
from { opacity: 0; transform: translateY(20px); }
to { opacity: 1; transform: translateY(0); }
}
/* Плавные переходы для ссылок и кнопок */
a, .pdf-link, nav a {
transition: all 0.3s ease;
}
/* Эффект при наведении на карточки сотрудников */
.person {
transition: transform 0.2s, box-shadow 0.2s;
}
.person:hover {
transform: translateY(-3px);
box-shadow: 0 4px 12px rgba(0, 51, 102, 0.15);
}
/* ------------------------------------------------------------------ */
/* Улучшенная навигация с "хлебными крошками" */
.breadcrumbs {
padding: 10px 0;
margin-bottom: 20px;
font-size: 0.9em;
color: #666;
}
.breadcrumbs a {
color: #003366;
text-decoration: none;
}
.breadcrumbs a:hover {
text-decoration: underline;
}
.breadcrumbs span {
color: #888;
}
/* ------------------------------------------------------------------ */
/* Ограничение максимального размера всех изображений */
main img {
max-width: 100%;
height: auto;
display: block;
margin: 20px auto;
border-radius: 4px;
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
/* Специальные классы для управления размером */
.img-left {
float: left;
max-width: 300px;
margin: 0 20px 20px 0;
}
.img-right {
float: right;
max-width: 300px;
margin: 0 0 20px 20px;
}
.img-center {
max-width: 500px;
margin: 20px auto;
}
.img-thumbnail {
max-width: 150px;
border: 2px solid #ddd;
}
/* ------------------------------------------------------------------ */
/* Красивые карточки для новостей */
.news-card {
background: white;
border-radius: 8px;
padding: 20px;
margin: 15px 0;
box-shadow: 0 2px 8px rgba(0, 51, 102, 0.08);
border-left: 4px solid #003366;
transition: transform 0.2s, box-shadow 0.2s;
}
.news-card:hover {
transform: translateX(5px);
box-shadow: 0 4px 16px rgba(0, 51, 102, 0.15);
}
.news-date {
color: #666;
font-size: 0.85em;
margin-bottom: 10px;
}
.news-title {
color: #003366;
margin: 0 0 10px 0;
font-size: 1.3em;
}
/* ------------------------------------------------------------------ */
/* Мобильная адаптация */
@media (max-width: 768px) {
body {
padding: 10px;
}
nav {
display: flex;
flex-direction: column;
gap: 10px;
}
nav a {
margin-right: 0;
padding: 10px;
background: rgba(0, 51, 102, 0.05);
border-radius: 5px;
}
main {
padding: 15px;
}
h1 {
font-size: 1.5em;
}
h2 {
font-size: 1.3em;
}
}
/* Тёмная тема (переключатель) */
/* Тёмная тема */
body.dark-mode {
background: linear-gradient(135deg, #1a1f2e 0%, #2d3748 100%);
color: #e2e8f0;
}
body.dark-mode::before {
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='50' height='50' viewBox='0 0 50 50'%3E%3Cpath d='M0 0 L50 50 M50 0 L0 50' stroke='%234a5568' stroke-width='0.5' opacity='0.15'/%3E%3Ccircle cx='25' cy='25' r='1.5' fill='%234a5568' opacity='0.2'/%3E%3C/svg%3E");
}
body.dark-mode header,
body.dark-mode main {
background: rgba(45, 55, 72, 0.95);
color: #e2e8f0;
}
body.dark-mode h1,
body.dark-mode h2,
body.dark-mode h3 {
color: #63b3ed;
}
body.dark-mode a {
color: #90cdf4;
}
/* Кнопка переключения темы */
.theme-toggle {
position: fixed;
bottom: 20px;
right: 20px;
width: 50px;
height: 50px;
border-radius: 50%;
background: #003366;
color: white;
border: none;
cursor: pointer;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
font-size: 24px;
transition: transform 0.3s;
}
.theme-toggle:hover {
transform: scale(1.1);
}