/* ===== Reset & Base Styles ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ===== Theme 2026: Emerald Green Edition ===== */
:root {
  /* Основная палитра */
  --space-dark: #002d1f;       /* Глубокий темный фон */
  --space-medium: #004d35;     /* Средний тон */
  --space-light: #00704E;      /* ВАШ ОСНОВНОЙ ЦВЕТ */
  
  --neon-blue: #00ffb3;        /* Акцентный мятный (вместо голубого) */
  --neon-purple: #2ecc71;      /* Зеленый изумруд */
  
  /* Градиенты 2026 */
  --gradient-dark: linear-gradient(135deg, var(--space-dark), var(--space-medium));
  --gradient-neon: linear-gradient(135deg, var(--space-light), var(--neon-blue));
  
  /* Тени с зеленым оттенком */
  --shadow-blue: 0 4px 20px rgba(0, 112, 78, 0.3);
}

/* Обновление анимации логотипа под новый цвет */
.wm-first, .wm-rest {
  --g1: #00704E;
  --g2: #00ffb3;
  --g3: #00a372;
  background: linear-gradient(100deg, var(--g1), var(--g2), var(--g3), var(--g1));
  background-size: 220% 100%;
  animation: logoGradient 5s ease-in-out infinite alternate;
}

body {
  font-family: 'Segoe UI', system-ui, sans-serif;
  line-height: 1.6;
  /*color: #fff;*/
  background: var(--gradient-dark);
  min-height: 100vh;
}

.site-main {
  min-height: 100vh;
}

/* ===== Layout & Containers ===== */
.container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 20px;
}

.absence-container {
  background: rgba(16, 18, 27, 0.6);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: 30px;
  margin: 2rem auto;
  box-shadow: var(--shadow-purple);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.5s ease;
  max-width: 98%;
}

/* ===== Header & Navigation ===== */


body {
    /*overflow: hidden;*/
    width: 100%;
}
/*
*:not(path):not(g) {
  color: hsla(210, 100%, 100%, 0.9) !important;
  background: hsla(210, 100%, 50%, 0.2) !important;
  outline: solid 1px hsla(0, 100%, 50%, 0.5) !important;
  box-shadow: none !important;
  filter: none !important;
}

div, section, article, header, footer, main, aside, nav, figure, figcaption {
  background: hsla(120, 100%, 25%, 0.1) !important;
  outline: solid 1px hsla(120, 100%, 25%, 0.4) !important;
  position: relative;
}

div::before, section::before, article::before, header::before, footer::before, main::before, aside::before, nav::before, figure::before, figcaption::before {
  content: attr(class);
  position: absolute;
  top: 0;
  left: 0;
  padding: 2px 4px;
  font-size: 10px;
  background: rgba(0,0,0,0.7);
  color: white;
  z-index: 9999;
}

*/





/* ===== Calendar Controls ===== */
.controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
  align-items: center;
  background: #2c3e50;
  padding: 15px;
  border-radius: var(--radius-md);
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}
h1 {
  margin-bottom: 2rem;
  font-size: 3rem;
}
.btn {
  padding: 12px 20px;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.btn-add {
  background: linear-gradient(135deg, #00b09b, #96c93d);
  color: white;
  border:0;
    border-radius: var(--radius-sm);
  padding: 12px;

}

.btn-add:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

#filter-form {
  display: flex;
  gap: 10px;
}

#department, #type {
  padding: 10px 15px;
  border: 2px solid #34495e;
  border-radius: var(--radius-md);
  background: #34495e;
  color: white;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 180px;
}

#department:hover, #type:hover {
  border-color: var(--neon-blue);
  box-shadow: 0 0 0 3px rgba(52,152,219,0.2);
}

.navigation {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-weight: 500;
}

.navigation a {
  color: #bdc3c7;
  text-decoration: none;
  font-size: 18px;
  transition: color 0.3s ease;
  padding: 5px;
}

.navigation a:hover {
  color: var(--neon-blue);
}

.view-controls {
  display: flex;
  gap: 5px;
  background: #34495e;
  padding: 5px;
  border-radius: var(--radius-md);
}

.view-controls a {
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: #ecf0f1;
  font-weight: 500;
  transition: all 0.3s ease;
}

.view-controls a.active {
  background: var(--neon-blue);
  color: white;
}


/* Типы отсутствий */
.absence {
  font-weight: bold;
  position: relative;
}

.absence:after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: currentColor;
  opacity: 0.1;
  z-index: 0;
}

.absence.отпуск {
  color: #4CAF50;
}

.absence.больничный {
  color: #FFC107;
}

.absence.командировка {
  color: #2196F3;
}

.absence.удаленная-работа {
  color: #9E9E9E;
}

/* Выходные дни */
.weekend {
  background: var(--gradient-dark) !important;
  color: #ff5858 !important;
}

/* Ховер-эффекты */
.absence-table td:not(.absence):hover {
  background: #1b2b32 !important;
  cursor: pointer;
  transform: scale(1.02);
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  color: var(--comet-red);
}

/* ===== Modal Window ===== */
#absence-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  backdrop-filter: blur(5px);
}

.modal-content {
  background: var(--gradient-dark);
  padding: 2rem;
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 500px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.2);
  animation: modalFadeIn 0.4s ease-out;
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Формы в модалке */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

.form-control {
  width: 100%;
  padding: 12px 15px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--neon-blue);
  box-shadow: var(--shadow-blue);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 2rem;
}

/* ===== Footer ===== */
.site-footer {
  background: rgba(16, 18, 27, 0.8);
  padding: 30px 0;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== Theme Switcher ===== */
.theme-switcher {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1000;
  display: flex;
  gap: 10px;
  background: rgba(255, 255, 255, 0.9);
  padding: 10px;
  border-radius: 50px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.theme-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: transparent;
}

.theme-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 0 15px currentColor;
}

/* ===== Light Theme ===== */
.theme-light {
  background: var(--gradient-light);
  color: #2c3e50;
}

.theme-light .absence-container {
  background: rgba(255, 255, 255, 0.8);
  color: #2c3e50;
  box-shadow: 0 8px 32px rgba(100, 100, 255, 0.2);
}

.theme-light .absence-table {
  background: rgba(255, 255, 255, 0.9);
}

.theme-light .absence-table th {
  background: linear-gradient(135deg, #667eea, #764ba2);
}

.theme-light .weekend {
  background: rgba(241, 241, 241, 0.9);
  color: #7f8c8d;
}

/* ===== Responsive Styles ===== */
@media (max-width: 992px) {
  .controls {
    grid-template-columns: 1fr;
  }
  
  #filter-form {
    flex-direction: column;
  }
}

@media (max-width: 768px) {
  .header-container {
    flex-direction: column;
    padding: 15px 0;
    height: auto;
  }
  
  .main-navigation ul {
    margin-top: 15px;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .absence-container {
    padding: 20px 15px;
  }
  
  .absence-table {
    font-size: 0.9rem;
  }
  
  .btn-add {
    width: 100%;
  }
}

/* ===== Animations ===== */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.floating {
  animation: float 3s ease-in-out infinite;
}

.header-content  {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.site-title a {
  color: #fff;
}

/* Grid Layout */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

/* Post Card */
.post-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

/* Thumbnail */
.post-thumbnail {
    height: 220px;
    overflow: hidden;
}

.post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

/* Content */
.post-content {
    /* padding: 25px; */
}

.post-title {
    margin: 0 0 15px;
    font-size: 1.5rem;
    line-height: 1.3;
}

.post-title a {
    color: #333;
    text-decoration: none;
}

.post-title a:hover {
    color: #0066cc;
}

.post-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.9rem;
    color: #666;
}

.entry-content {
    margin-bottom: 20px;
    color: #444;
    line-height: 1.6;
}

.read-more {
    display: inline-block;
    color: #0066cc;
    font-weight: 500;
    text-decoration: none;
}

.read-more:hover {
    text-decoration: underline;
}

/* Pagination */
.pagination {
    margin: 50px 0;
    text-align: center;
}

.page-numbers {
    display: inline-block;
    padding: 8px 15px;
    margin: 0 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #333;
}

.page-numbers.current {
    background: #0066cc;
    color: white;
    border-color: #0066cc;
}

.page-numbers:hover:not(.current) {
    background: #f5f5f5;
}

/* No Posts */
.no-posts {
    text-align: center;
    padding: 50px;
    font-size: 1.2rem;
    color: #666;
}

/* Single Post Container */
.single-post .site-main .container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Post Header */
.post-header {
    /* margin-bottom: 40px; */
    text-align: center;
}

.post-featured-image {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.post-featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

.post-title {
    font-size: 2.2rem;
    line-height: 1.3;
    margin: 0 0 20px;
    color: #222;
}

.post-meta {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 20px;
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 1rem;
    font-size: 0.8rem;
}

.post-meta i {
    margin-right: 5px;
    color: #0066cc;
}

/* Post Content */
.post-content {
    line-height: 1.8;
    font-size: 1.1rem;
    color: #444;
    margin-bottom: 40px;
}

.post-content p {
    margin-bottom: 1.5em;
}

.post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 0 0 30px;
}

.post-content h2,
.post-content h3,
.post-content h4 {
    margin: 0 0 0.8em;
    color: #222;
}

.post-content h2 {
    font-size: 1.8rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.post-content h3 {
    font-size: 1.5rem;
}

.post-content blockquote {
    border-left: 4px solid #0066cc;
    padding: 15px 25px;
    margin: 0 0 30px;
    background: #f9f9f9;
    font-style: italic;
    color: #555;
}

/* Post Footer */
.post-footer {
    margin: 0 0 50px;
    padding: 30px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.post-tags {
    flex: 1;
    min-width: 200px;
}

.tags-label {
    font-weight: 500;
    color: #666;
}

.post-tags a {
    display: inline-block;
    margin: 0 5px 5px 0;
    padding: 3px 10px;
    background: #f0f0f0;
    border-radius: 3px;
    color: #555;
    text-decoration: none;
    font-size: 0.9rem;
}

.post-tags a:hover {
    background: #0066cc;
    color: white;
}

.post-share {
    display: flex;
    align-items: center;
    gap: 10px;
}

.share-label {
    font-weight: 500;
    color: #666;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.share-btn:hover {
    transform: translateY(-3px);
}

.twitter { background: #1DA1F2; }
.facebook { background: #3b5998; }
.linkedin { background: #0077b5; }

/* Post Navigation */
.post-navigation {
    display: flex;
    justify-content: space-between;
    margin: 0 0 50px;
    font-size: 1.1rem;
}

.nav-previous, 
.nav-next {
    flex: 1;
}

.nav-next {
    text-align: right;
}

.post-navigation a {
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.post-navigation a:hover {
    text-decoration: underline;
}

.post-featured-image img {
  max-height: 300px;
  width: auto; 
  margin: 0 auto;   
}

.site-logo a img {
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.site-logo a:hover img {
    transform: translateY(-5px) scale(1.05);
}

/* Responsive */
@media (max-width: 768px) {
    .post-title {
        font-size: 1.8rem;
    }
    
    .post-meta {
        gap: 10px;
        font-size: 0.85rem;
    }
    
    .post-footer {
        flex-direction: column;
    }
    
    .post-share {
        margin-top: 20px;
    }
}

.site-main.single-post article {
  background: #fff; 
  padding: 1rem;  
}

.space-10 {
  height: 10rem;
}

/* index */
/*.gradient-style {
      background: linear-gradient(to bottom, #4caf50 0%, #2575fc 100%);
    padding: 2px 4px;
    border-radius: 4px;
}*/

.gradient-text {
            font-size: 48px;
            font-weight: bold;
            position: relative;
            display: inline-block;
        }
        
        .gradient-text::before {
            content: attr(data-text);
            position: absolute;
            background: linear-gradient(90deg, #4caf50, #2575fc, #4caf50);
            background-size: 200% auto;
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
            
            animation: gradientAnimation 3s linear infinite;
        }
        
        .gradient-text::after {
            content: attr(data-text);
            color: transparent;
            text-shadow: 0 0 10px rgba(0,0,0,0.3);
        }
        
        @keyframes gradientAnimation {
            0% {
                background-position: 0% center;
            }
            100% {
                background-position: 200% center;
            }
        }

.organization-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
            gap: 25px;
            padding: 0;
        }

        .organization-card {
            display: block;
            background: #2d2d2d;
            border-radius: 12px;
            padding: 25px;
            text-decoration: none;
            color: #e0e0e0;
            transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
            border: 1px solid rgba(255, 255, 255, 0.05);
            box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
            position: relative;
            overflow: hidden;
        }

        .organization-card:before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 4px;
            height: 100%;
            background: linear-gradient(to bottom, #4caf50 0%, #2575fc 100%);
            transition: width 0.3s ease;
        }

        .organization-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 12px 25px rgba(0, 0, 0, 0.25);
            border-color: rgba(255, 255, 255, 0.1);
        }

        .organization-card:hover:before {
            width: 8px;
        }

        .card-title {
            margin: 0 0 15px 0;
            color: #ffffff;
            font-size: 1.4rem;
            font-weight: 600;
        }

        .card-excerpt {
            margin: 0 0 20px 0;
            color: #b0b0b0;
            line-height: 1.6;
            font-size: 1rem;
        }

        .card-link {
            display: inline-flex;
            align-items: center;
            color: #4caf50;
            font-weight: 500;
            transition: color 0.3s ease;
            font-size: 0.95rem;
        }

        .card-link svg {
            margin-left: 8px;
            transition: transform 0.3s ease;
        }

        .organization-card:hover .card-link {
            color: #2575fc;
        }

        .organization-card:hover .card-link svg {
            transform: translateX(4px);
        }

        .page-title {
            margin-bottom: 40px;
            position: relative;
            padding-bottom: 15px;
            font-size: 2.2rem;
            font-weight: 400;
        }

        .page-title:after {
            content: '';
            position: absolute;
            left: 0;
            bottom: 0;
            width: 60px;
            height: 3px;
            background: linear-gradient(to right, #4caf50, #2575fc);
            border-radius: 3px;
        }

        @media (max-width: 768px) {
            body {
                /*padding: 20px;*/
            }
            
            .organization-grid {
                grid-template-columns: 1fr;
            }
            
            .page-title {
                font-size: 1.8rem;
                margin-bottom: 30px;
            }
        }





/*дни рождения*/


.birthday-calendar {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    max-width: 100%;
    margin: 0 auto;
}

.birthday-filters {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.birthday-search-input, 
.birthday-department-filter {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    min-width: 200px;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
    gap: 20px;
}

.calendar-month {
    background: #e6f2ff;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}


.month-title {
    color: #333;
    font-size: 20px;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 8px;
}

.month-days {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
}

.calendar-day {
    border: 1px solid #eee;
    border-radius: 5px;
    padding: 8px;
    transition: all 0.3s;
    min-height: 60px;    background: #ffffffbd;
}

.calendar-day:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.calendar-day.today {
    border-color: #ffc107;
    background-color: #fff8e1;
}

.calendar-day.past {
    opacity: 0.8;
}

.calendar-day.future {
    border-left: 3px solid #4caf50;
}

.day-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    padding-bottom: 5px;
    border-bottom: 1px dashed #eee;
    font-size: 14px;
}

.day-number {
    font-weight: bold;
    color: #333;
}

.day-week {
    color: #888;
    font-size: 0.8em;
}

.day-employees {
    display: grid;
    gap: 8px;
    margin-top: 5px;
}

.employee-card {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding: 5px;
    border-radius: 3px;
    background: #f9f9f9;
    font-size: 13px;
    line-height: 1.3;
    color: #000;
    word-break: break-word;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.employee-card:hover {
    background: #f0f0f0;
}

.employee-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.list-item .employee-avatar {
    width: 70px;
    height: 70px;
}

.employee-info {
    flex: 1;
    min-width: 0;
    position: relative;
    width: 100%;
}

.employee-name {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.employee-age {
    color: #666;
    font-size: 0.9em;
}

.next-age {
    color: #4caf50;
    font-size: 0.85em;
}

.employee-department {
    color: #888;
    font-size: 0.85em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.no-results {
    text-align: center;
    padding: 40px;
    color: #666;
    grid-column: 1 / -1;
}

/* Стили для тултипа */
.tooltip {
    position: absolute;
    z-index: 1000;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-left: 100px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    max-width: 300px;
    display: none;
    color: #000;
}

.tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 20px;
    border-width: 8px;
    border-style: solid;
    border-color: #4caf50 transparent transparent transparent;
}

.employee-tooltip .tooltip-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.employee-tooltip .tooltip-header img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.employee-tooltip .tooltip-header h3 {
    margin: 0;
    font-size: 18px;
    color: #333;
}

.employee-tooltip .tooltip-body {
    font-size: 14px;
    line-height: 1.5;
}

.employee-tooltip .tooltip-body p {
    margin: 8px 0;
}

.employee-tooltip .tooltip-body span {
    font-weight: 500;
    color: #555;
    display: inline-block;
    min-width: 100px;
}

@media (max-width: 768px) {
    .birthday-filters {
        flex-direction: column;
    }
    
    .calendar-grid {
        grid-template-columns: 1fr;
    }
    
    .month-days {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    .tooltip {
        max-width: 250px;
        left: 50% !important;
        transform: translateX(-50%);
    }
    
    .tooltip::after {
        left: 50%;
        transform: translateX(-50%);
    }
}
 /* Стили для печати */
    @media print {
        body * {
            visibility: hidden;
        }
        #print-birthdays-container, #print-birthdays-container * {
            visibility: visible;
        }
        #print-birthdays-container {
            position: absolute;
            left: 0;
            top: 0;
            width: 100%;
            padding: 20px;
            box-sizing: border-box;
        }
        .print-header {
            margin-bottom: 20px;
            display: flex;            
            justify-content: space-between;
            align-items: center;
        }
        .print-header h1 {
            color: #43b02a;
            margin-left: 0;
            margin-right: auto;
        }
        .logo-container {
            margin-left: auto;
            margin-right: 0;
            display: block;
            text-align: right;
            
        }
        .print-content {
            display: flex;
            width: 100%;
            justify-content: space-between;
        }
        .birthdays-list {
            margin-right: auto;
            margin-left: 0;
            color: #000;
            width: 600px;
            display: flex;
            justify-content: space-between;

        }
        .print-image {
            width: 800px;
        }
        .month-section {
            margin-bottom: 30px;
            page-break-inside: avoid;
        }
        .month-title {
            font-size: 24px;
            margin-bottom: 15px;
            padding-bottom: 5px;
            color: #43b02a;
            border-bottom: 1px solid #ccc;
        }
        .birthday-item {
            display: flex;
            align-items: center;
            margin-bottom: 15px;
            page-break-inside: avoid;
            width: 49%;
        }
        .birthday-avatar {
            margin-right: 15px;
        }
        .birthday-avatar img {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            object-fit: cover;
        }
        .birthday-info {
            flex: 1;
        }
        .birthday-name {
            font-weight: bold;
            font-size: 18px;
            color: #43b02a;
            white-space: nowrap;
        }
        .birthday-date {
            color: #555;
        }
    }
/*дни рождения end*/



.absence-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 2px;
}

.absence-item {
    padding: 4px;
    border-radius: 3px;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: ;
    font-weight: bold;
}

.employee-name a {
    color: var(--star-yellow);
}

.employee-name a:hover {
    text-decoration: underline;
}

/* Улучшаем отображение для мобильных устройств */
@media (max-width: 768px) {
    .absence-item {
        font-size: 10px;
        padding: 2px;
    }
    
    .table-wrapper {
        overflow-x: auto;
    }
}


.main-content-wrapper {
    display: flex;
    gap: 20px;
}

.filter-panel {
    width: 260px;
    flex-shrink: 0;
    background: #1b2b32;
    padding: 15px;
    border-radius: 5px;
}

.content-area {
    flex-grow: 1;
    min-width: 0;
}

.employee-cell {
    min-width: 180px;
}

.employee-info {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.employee-name {
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.department-label {
    font-size: 0.85em;
    color: #666;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.absence-item {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 0.85em;
}

.checkbox-filters {
    margin-top: 20px;
}

.checkbox-filter-group {
    margin-bottom: 20px;
}

.checkbox-list {
    max-height: 500px;
    overflow-y: auto;
    padding: 5px;
}

.checkbox-item {
    margin: 5px 0;
}

.show-only-checkbox {
    padding: 10px;
    border-radius: 4px;
}

.view-switcher {
    display: flex;
    width: 100%;
}

.view-switcher button {
    flex: 1;
    padding: 5px;
    border: 1px solid #ddd;
    background: white;
    cursor: pointer;
}

.view-switcher button.active {
    background: #0073aa;
    color: white;
    border-color: #0073aa;
}

.view-switcher button:first-child {
    border-radius: 4px 0 0 4px;
}

.view-switcher button:last-child {
    border-radius: 0 4px 4px 0;
}

.presence-filter-group {
  margin-bottom: 1.5rem;
  font-family: 'Segoe UI', system-ui, sans-serif;
}

.presence-filter-group h4 {
  color: var(--neon-blue);
  margin-bottom: 0.75rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-shadow: 0 0 8px rgba(0, 210, 255, 0.2);
}

.presence-filter {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  color: white;
  background: var(--space-medium);
  border: 1px solid var(--neon-purple);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-blue);
  appearance: none;
  background-image: 
    linear-gradient(45deg, transparent 50%, var(--neon-blue) 50%),
    linear-gradient(135deg, var(--neon-blue) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) 50%,
    calc(100% - 15px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  transition: all 0.3s ease;
  cursor: pointer;
}

.presence-filter:hover {
  border-color: var(--neon-blue);
  box-shadow: var(--shadow-purple);
}

.presence-filter:focus {
  outline: none;
  border-color: var(--neon-blue);
  box-shadow: 0 0 0 2px rgba(0, 210, 255, 0.3);
}

.presence-filter option {
  background: var(--space-dark);
  color: white;
}

.presence-filter option:checked {
  background: var(--neon-purple);
  color: white;
  font-weight: bold;
}

/* Кастомный стрелочный индикатор (для лучшей поддержки) */
.presence-filter::-ms-expand {
  display: none;
}


/* Основные стили для дерева */
.tree {
  color: #fff;
  font-family: Arial, sans-serif;
  background-color: #222;
  padding: 20px;
  border-radius: 5px;
  overflow: auto;
}

/* Стили для скролла */

.tree::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
.tree::-webkit-scrollbar-track {
  background: #333;
}
.tree::-webkit-scrollbar-thumb {
  background: #4CAF50;
  border-radius: 5px;
}
.tree::-webkit-scrollbar-thumb:hover {
  background: #45a049;
}

.tree ul {
  padding-left: 20px;
  list-style: none;
  position: relative;
}

.tree ul:before {
  content: "";
  position: absolute;
  top: 15px; /* Начинаем ниже верхней границы первого элемента */
  left: 10px;
  height: calc(100% - 30px); /* Учитываем padding элементов */
  width: 2px;
  background: #4CAF50;
  display: none;
}

.tree li {
  position: relative;
  padding-left: 30px;
  padding-top: 5px; /* Добавляем отступ сверху вместо margin */
  padding-bottom: 5px; /* Добавляем отступ снизу вместо margin */
}

.tree li:before {
  content: "";
  position: absolute;
  left: 0;
  top: 20px; /* Сдвигаем вниз с учетом padding */
  width: 20px;
  height: 2px;
  background: #4CAF50;
}

.tree li:after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%; /* Занимаем всю высоту li */
  width: 2px;
  background: #4CAF50;
}

.tree li:last-child:after {
  height: 20px; /* Корректируем высоту для последнего элемента */
}

.tree .node {
  display: inline-flex;
  align-items: center;
  padding: 8px 15px;
  background-color: #333;
  border-radius: 4px;
  border-left: 3px solid #4CAF50;
  transition: all 0.3s;
  cursor: pointer;
  text-decoration: none;
  color: #fff;
  position: relative; /* Добавляем для позиционирования тултипа */
}

.tree .node:hover {
  background-color: #444;
  transform: translateX(5px);
}

/* Стили для верхнего уровня */
.top-level {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.top-level > li {
  padding-left: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.top-level > li:before,
.top-level > li:after {
  display: none;
}

.top-level > li > ul {
  padding-left: 0;
}

.top-level > li > ul:before {
  display: none;
}

/* Класс для элементов без детей */
.no-children:after {
  display: none !important;
}

/* Стили для аватара */
.employee-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 10px;
  object-fit: cover;
}


/* Стили для статусов */
.presence-indicator {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-left: 8px;
  vertical-align: middle;
}

.presence-present {
  background-color: #4CAF50;
}

.presence-absent {
  background-color: #f44336;
}

.absence-icon {
  margin-left: 8px;
  vertical-align: middle;
  font-size: 16px;
}

/* Дополнительные стили для разных статусов */
.absence-vacation {
  color: #FFC107;
}
.absence-vacation_plan {
  color: #FF9800;
}
.absence-sick_leave {
  color: #9C27B0;
}
.absence-business_trip {
  color: #2196F3;
}
.absence-remote {
  color: #00BCD4;
}
.absence-day_off {
  color: #8BC34A;
}


/* Упрощенные стили для тултипа */
.node .tooltip h3 {
    color: #fff !important;
}
.node .tooltip .position {
    margin-bottom: 4px;
}
.node .tooltip {
  visibility: hidden;
  width: 250px;
  background-color: #333;
  color: #fff;
  text-align: left;
  border-radius: 6px;
  padding: 10px;
  position: absolute;
  z-index: 1000;
  bottom: 100%; /* Показываем прямо над элементом */
  left: 0;
  opacity: 0;
  transition: opacity 0.2s;
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  border: 1px solid #4CAF50;
  pointer-events: none;
  margin-bottom: 5px; /* Небольшой отступ от элемента */
}

.node:hover {
    z-index: 999;
}
.node:hover .tooltip {
  visibility: visible;
  opacity: 1;
  display: block;
  text-align: center !important;
  z-index: 999;
  color: #fff !important;
}










    /* Улучшаем стили для скролла перетаскиванием */
.org-chart-wrapper {
    cursor: grab;
    overflow: auto;
    height: 56vh;
    padding: 20px 0;
}

.org-chart-wrapper:active {
    cursor: grabbing;
}

.org-chart {
    display: inline-block;
    min-width: 100%;
    padding-bottom: 20px;
    padding-top: 50px;
    padding-left: 100px;
    user-select: none; /* Предотвращаем выделение текста при перетаскивании */
}

/* Улучшаем видимость скролла */
.org-chart-wrapper::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

.org-chart-wrapper::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

.org-chart-wrapper::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    border: 3px solid transparent;
    background-clip: content-box;
}

.org-chart-wrapper::-webkit-scrollbar-thumb:hover {
    background-color: rgba(255, 255, 255, 0.5);
}
    /* Добавьте эти стили в ваш CSS */

/* Стиль для пунктирных линий */
.connectors line[stroke-dasharray] {
    stroke-linecap: round;
}

/* Улучшаем позиционирование кнопки раскрытия */
.toggle-children {
    position: absolute;
    top: calc(100% + 5px);
    right: 50%;
    transform: translateX(50%);
    width: 20px;
    height: 20px;
    background-color: #4CAF50;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    cursor: pointer;
    z-index: 3;
    border: 2px solid #222;
    font-size: 14px;
}

.org-chart-wrapper {
    user-select: none;
}

























.org-chart-container {
    background-color: #222;
    padding: 20px;
    border-radius: 5px;
    max-width: 100%;
    overflow: auto;
    color: #fff;
    padding-top: 120px;
}
.org-chart-wrapper {
    width: 100%;
    overflow: auto;
    height: 56vh;
    padding: 20px 0;
}
.org-chart {
    position: relative;
    display: inline-block;
    min-width: 100%;
    padding-bottom: 20px;
    padding-top: 50px;
    padding-left: 100px;
}
.connectors {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}
.level {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
    position: relative;
}
.level-0 {
    margin-top: 0;
}
.level-1 {
    /*margin-top: 80px;*/
}
.level-2 {
    margin-top: 80px;
}
.node {
    background-color: #333;
    border-radius: 6px;
    padding: 10px;
    text-align: center;
    width: 150px;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: all 0.3s;
    border-left: 3px solid #4CAF50;
    cursor: pointer;
    z-index: 2;
}
.node:hover {
    background-color: #444;
    transform: translateY(-5px);
}
.level-0-node {
    background-color: #2c3e50;
    border-left: 3px solid #e74c3c;
}
.level-1-node {
    background-color: #34495e;
    border-left: 3px solid #3498db;
}
.level-2-node {
    background-color: #3d566e;
    border-left: 3px solid #9b59b6;
}
.node-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}
.children-container {
    width: 100%;
    display: flex;
    justify-content: center;
}
.employee-avatar {
    width: 66px;
    height: 66px;
    border-radius: 50%;
    object-fit: cover;
    /* margin-bottom: 8px; */
}
.employee-name {
    font-size: 14px;
    margin-bottom: 5px;
    word-break: break-word;
}
.presence-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-top: 5px;
}
.presence-present {
    background-color: #4CAF50;
}
.presence-absent {
    background-color: #f44336;
}
.absence-icon {
    font-size: 16px;
    margin-top: 5px;
}
.absence-vacation {
    color: #FFC107;
}
.absence-vacation_plan {
    color: #FF9800;
}
.absence-sick_leave {
    color: #9C27B0;
}
.absence-business_trip {
    color: #2196F3;
}
.absence-remote {
    color: #00BCD4;
}
.absence-day_off {
    color: #8BC34A;
}
.tooltip {
    visibility: hidden;
    width: 250px;
    background-color: #333;
    color: #fff;
    text-align: left;
    border-radius: 6px;
    padding: 10px;
    position: absolute;
    z-index: 1000;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.2s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    border: 1px solid #4CAF50;
    pointer-events: none;
    margin-bottom: 10px;
}
.node:hover .tooltip {
    visibility: visible;
    opacity: 1;
}
.tooltip h3 {
    color: #fff;
    margin-top: 0;
    margin-bottom: 10px;
}
.tooltip .position {
    margin-bottom: 5px;
    font-size: 14px;
}
.tooltip .status {
    margin-bottom: 0;
    font-size: 14px;
}
.toggle-children {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 20px;
    height: 20px;
    background-color: #4CAF50;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    cursor: pointer;
    z-index: 3;
    border: 2px solid #222;
}
.org-chart-wrapper::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
.org-chart-wrapper::-webkit-scrollbar-track {
    background: #333;
}
.org-chart-wrapper::-webkit-scrollbar-thumb {
    background: #4CAF50;
    border-radius: 5px;
}
.org-chart-wrapper::-webkit-scrollbar-thumb:hover {
    background: #45a049;
}
.employee-link {
    color: inherit;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 100%;
}


.presence-indicator {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-left: 5px;
    vertical-align: middle;
    transform: translate(0px, -4px);
}
.absence-icon  {
    transform: translate(0px, -4px);    
}

.presence-present {
    background-color: #4CAF50; /* Зеленый */
}

.presence-absent {
    background-color: #F44336; /* Красный */
}

.employee-presence-filter {
    margin-left: 10px;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ddd;
}
.absence-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-left: 5px;
    vertical-align: middle;
    font-size: 16px;
    text-align: center;
}

/* Цвета для разных типов отсутствий */
.absence-vacation { color: #00d2ff; } /* Отпуск */
.absence-vacation_plan { color: #64b5f6; } /* Планируемый отпуск */
.absence-sick_leave { color: #ff5252; } /* Больничный */
.absence-business_trip { color: #3a7bd5; } /* Командировка */
.absence-remote { color: #ff9800; } /* Удалёнка */
.absence-day_off { color: #9c27b0; } /* Отгул */

/* Для отображения нескольких статусов */
.status-container {
    display: inline-block;
    margin-left: 5px;
}
.status-container .presence-indicator,
.status-container .absence-icon {
    margin-left: 3px;
}

.employee-no-results {
    display: none;
    text-align: center;
    padding: 20px;
    color: #666;
}


/* твой стиль оставляю как есть — ничего не ломаю */
:root{--space-dark:#0f2027;--space-medium:#203a43;--space-light:#2c5364;--neon-blue:#00d2ff;--neon-purple:#3a7bd5;--star-yellow:#FFC107;--comet-red:#FF5252;--gradient-dark:linear-gradient(135deg,var(--space-dark),var(--space-medium),var(--space-light));--gradient-neon:linear-gradient(135deg,var(--neon-blue),var(--neon-purple));--shadow-blue:0 4px 20px rgba(0,210,255,.3);--shadow-purple:0 4px 20px rgba(58,123,213,.3);--radius-sm:8px;--radius-lg:16px}
.cosmic-calendar{background:var(--space-dark);color:#e0e0e0;border-radius:var(--radius-lg);padding:20px;box-shadow:var(--shadow-blue);font-family:Arial,Helvetica,sans-serif;max-width:1000px;margin:0 auto;border:1px solid var(--space-medium)}
.calendar-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px;padding-bottom:15px;border-bottom:1px solid var(--space-medium)}
.calendar-title{font-size:24px;color:var(--neon-blue);text-transform:uppercase;letter-spacing:1px;margin:0;text-shadow:0 0 10px rgba(0,210,255,.5)}
.calendar-nav{display:flex;gap:10px}
.calendar-nav button{background:var(--space-medium);color:#e0e0e0;border:1px solid var(--neon-purple);padding:8px 15px;border-radius:var(--radius-sm);cursor:pointer;transition:.3s;font-weight:700}
.calendar-nav button:hover{background:var(--neon-purple);box-shadow:var(--shadow-purple)}
.calendar-weekdays{display:grid;grid-template-columns:repeat(7,1fr);text-align:center;font-weight:700;margin-bottom:10px;color:var(--neon-blue);text-transform:uppercase;font-size:14px}
.calendar-days{display:grid;grid-template-columns:repeat(7,1fr);gap:8px}
.calendar-day{min-height:120px;padding:8px;border:1px solid var(--space-medium);border-radius:var(--radius-sm);background:var(--space-dark);position:relative;overflow:hidden;display:flex;flex-direction:column}
.day-number{font-weight:700;margin-bottom:5px;color:#e0e0e0;align-self:flex-end}
.other-month{opacity:.4;background:rgba(15,32,39,.5)}
.has-events{background:rgba(32,58,67,.5);box-shadow:inset 0 0 10px rgba(0,210,255,.2)}
.event-dot{display:inline-block;width:8px;height:8px;background:var(--neon-blue);border-radius:50%;margin-right:5px;box-shadow:0 0 5px var(--neon-blue)}
.event-item{font-size:12px;margin:3px 0;padding:5px;border-radius:var(--radius-sm);cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:rgba(0,210,255,.1);border-left:2px solid var(--neon-blue);transition:.2s}
.event-item:hover{background:rgba(0,210,255,.3);box-shadow:0 0 8px rgba(0,210,255,.3)}
.current-day{background:rgba(0,210,255,.1);box-shadow:inset 0 0 10px rgba(0,210,255,.3);border-color:var(--neon-blue)}
.current-day .day-number{color:var(--neon-blue);font-size:16px}
.day-events{flex-grow:1;overflow-y:auto;scrollbar-width:thin;scrollbar-color:var(--neon-blue) var(--space-medium)}
.day-events::-webkit-scrollbar{width:4px}
.day-events::-webkit-scrollbar-track{background:var(--space-medium)}
.day-events::-webkit-scrollbar-thumb{background-color:var(--neon-blue);border-radius:2px}
.event-modal{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(15,32,39,.9);z-index:1000;justify-content:center;align-items:center}
.modal-content{background:var(--gradient-dark);border-radius:16px;padding:30px;width:90%;max-width:600px;max-height:90vh;overflow-y:auto;box-shadow:var(--shadow-blue),0 0 40px rgba(0,210,255,.5);border:1px solid var(--neon-blue);position:relative}
.modal-close{position:absolute;top:15px;right:15px;background:var(--comet-red);color:#fff;border:none;width:30px;height:30px;border-radius:50%;font-size:18px;cursor:pointer}
.modal-title{color:var(--neon-blue);font-size:24px;margin-bottom:15px;text-shadow:0 0 10px rgba(0,210,255,.5)}
.modal-date{display:inline-block;background:rgba(0,210,255,.1);padding:5px 10px;border-radius:8px;margin-bottom:20px;color:var(--star-yellow);font-size:14px;border:1px solid var(--neon-blue)}
.modal-image{margin-bottom:20px;text-align:center}
.modal-image img{max-width:100%;max-height:200px;height:auto;border-radius:4px}
@media (max-width:768px){.calendar-day{min-height:80px;padding:5px}.event-item{font-size:10px;padding:3px}.day-number{font-size:12px}.current-day .day-number{font-size:14px}}




:root{
  --bg:#0b1418;
  --panel:#102229;
  --panel-soft:#0f2026;
  --txt:#e9f1f3;
  --muted:rgba(233,241,243,.72);
  --accent:#00d2ff;
  --ok:#69ff00;
  --bad:#ff5252;
  --gap:10px;
}

/* БАЗОВЫЙ КОНТЕЙНЕР (вся страница укладывается в 100vh) */
.absence-today-container{
  /*height:100vh;*/
  max-width:100%;
  margin:0 auto;
  padding:12px 12px 0;
  background:var(--bg);
  color:var(--txt);
  display:grid;
  grid-template-rows:auto auto 1fr auto; /* h1 / toolbar / lists-scroll / legend */
  gap:8px;
  font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Arial,sans-serif;
}

/* Заголовок */
.absence-today-container h1{
  margin:0;
  font-weight:600;
  font-size:20px;
  line-height:1.25;
}

/* Поисковая панель */
.toolbar {
    display: grid;
    grid-template-columns: 1fr 36px;
    gap: 6px;
    align-items: center;
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
    z-index: 99;
    background: #0b1418;
    padding: .5rem 1rem;
}
#employee-search{
  width:100%; height:36px;
  padding:0 12px;
  font-size:18px;
  color:var(--txt);
  background:var(--panel);
  border:1px solid rgba(0,0,0,.35);
  border-radius:8px;
  outline:none;
}
#employee-search::placeholder{ color:rgba(233,241,243,.55); }
#clear-search{
  height:36px;
  border:1px solid rgba(0,0,0,.35);
  background:var(--panel);
  color:var(--muted);
  border-radius:8px;
  cursor:pointer;
}

/* Прокручиваемая область со списками */
.lists-scroll{
  min-height:0; /* важно для гридов */
  /*overflow:auto;*/
  /*padding-right:2px;*/
}

/* Секции */
.absence-section,.presence-section{
  background:var(--panel-soft);
  border:1px solid rgba(255,255,255,.05);
  border-radius:10px;
  padding:10px;
  margin:0 0 var(--gap);
}
.section-title{
  margin:-2px 0 8px;
  font-size:15px; font-weight:600;
  display:flex; align-items:center; gap:8px;
  color:var(--muted);
}
.section-title .dot{ width:8px; height:8px; border-radius:50%; background:var(--ok); }
.absence-section .section-title .dot{ background:var(--bad); }
.section-title .count{ color:var(--txt); font-weight:700; margin-left:2px; }

/* Сетка сотрудников */
.employee-list{
  list-style:none; margin:0; padding:0;
  display:grid; gap:6px;
  grid-template-columns:repeat(3, minmax(220px,1fr));
}
@media (max-width:560px){
  .employee-list{ grid-template-columns:1fr; }
}

/* Карточка */
.employee-item{
  display:grid;
  grid-template-columns:40px 1fr;
  gap:8px;
  align-items:center;
  background:#11262d;
  border:1px solid rgba(255,255,255,.06);
  border-radius:8px;
  padding:8px;
  content-visibility:auto;
  contain-intrinsic-size:60px;
}
.employee-item:focus-within{ outline:2px solid rgba(0,210,255,.4); outline-offset:2px; }

/* Аватар */
.employee-avatar{
  width:40px; height:40px; border-radius:50%;
  object-fit:cover;
  border:1px solid rgba(255,255,255,.1);
}

/* Инфо */
.employee-info{ min-width:0; }
.employee-name{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size: 12px;
  font-weight:700;
  color: #000000;
  text-decoration:none;
  margin:0 0 2px 0;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.employee-name:hover{ text-decoration:underline; }
.department-label,.position-label{
  display:block; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
  line-height:1.2;
}
.department-label{ font-size:12px; color:var(--muted); }
.position-label{ font-size:12px; color:var(--accent); }

/* Индикаторы */
.presence-indicator{ width:10px; height:10px; border-radius:50%; }
.present{ background:var(--ok); }
.absent{ background:var(--bad); }

/* Причины */
.absence-reasons{ display:flex; flex-wrap:wrap; gap:6px; margin-top:6px; }
.absence-reason{
  display:inline-flex; align-items:center; gap:6px;
  padding:3px 6px; border-radius:8px;
  font-size:11px; line-height:1.2; color:var(--txt);
  border:1px solid rgba(255,255,255,.08);
}
.absence-comment,.absence-kontragent{ font-size:11px; opacity:.85; }

/* Легенда (низ) */
.legend-container{
  display:flex; align-items:center; gap:12px;
  overflow-x:auto; white-space:nowrap;
  padding:8px 0 10px;
  border-top:1px solid rgba(255,255,255,.06);
  background:linear-gradient(180deg,rgba(0,0,0,.9),rgba(0,0,0,.88));

  justify-content: center;
  position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 108;
}
.legend-item{ display:inline-flex; align-items:center; gap:6px; font-size:12px; color:var(--muted); }
.legend-color{ width:12px; height:12px; border-radius:4px; border:1px solid rgba(255,255,255,.08); }

.site-footer {
  padding-bottom: 60px;
}
/* Портретная оптимизация */
@media (orientation:portrait) and (min-width:900px){
  .employee-list{ grid-template-columns:repeat(3, minmax(220px, 1fr)); }
}
@media (orientation:portrait) and (min-width:1200px){
  .employee-list{ grid-template-columns:repeat(4, minmax(220px, 1fr)); }
}

/* Режим экономии для слабых ПК */
.low-end .employee-item{ background:#12252b; }
.low-end *{ transition:none !important; animation:none !important; }

/* Пустые состояния */
.no-absences,.no-presence{ text-align:center; padding:12px; color:var(--muted); font-style:italic; }


.employee-item[hidden]{ display:none !important; }



  :root{
  --g1:#00704E; --g2:#00ffb3; --g3:#00a372;
  --logo-speed:2.4s; /* быстрее анимация */
}


/* компактно, без глобального uppercase */
.wordmark{
  display:inline-flex; align-items:baseline; gap:0;
  font-family:"Manrope", system-ui, -apple-system, Segoe UI, Roboto, "Noto Sans", sans-serif;
  font-weight:900; letter-spacing:.01em; line-height:1;
  font-size:clamp(22px,4.6vw,28px);
  -webkit-font-smoothing:antialiased; text-rendering:optimizeLegibility;
}

/* общий градиент и анимация */
.wm-first, .wm-rest, .wm-ver span{
  background:linear-gradient(100deg, var(--g1), var(--g2), var(--g3), var(--g1));
  background-size:220% 100%;
  -webkit-background-clip:text; background-clip:text;
  -webkit-text-fill-color:transparent;
  animation:logoGradient var(--logo-speed) ease-in-out infinite alternate;
  will-change:background-position;
}

@keyframes logoGradient{
  0%{background-position:0% 50%} 100%{background-position:100% 50%}
}

/* 1-я буква: зеркалим, убираем лишний отступ, подсветка */
.wm-first{
  display:inline-block;
  /*transform:scaleX(-1);            /* ЗЕРКАЛО */
  transform-origin:center;
  margin-right:.04ch;              /* плотный кернинг справа */
  letter-spacing:0;
  -webkit-text-stroke:.8px rgba(255,255,255,.16);
  text-shadow:
    0 0 6px rgba(47,255,200,.35),
    0 2px 10px rgba(0,0,0,.35);
}

/* остальное слово */
.wm-rest{ letter-spacing:.02em; }

/* версия как sup */
.wm-ver{ position:relative; margin-left:.18ch; line-height:1; }
.wm-ver span{
  position:relative; top:-2em;   /* поднимаем как верхний индекс */
  font-size:.3em; font-weight:800;
  font-variant-numeric:tabular-nums;
  letter-spacing:.02em;
}

@media (prefers-reduced-motion:reduce){
  .wm-first, .wm-rest, .wm-ver span{ animation:none; }
}


html[data-theme="dark"] .page-title {
  color: #fff;
}
