/* ========================================
   BASE STYLES
   ======================================== */
* {
    padding: 0;
    margin: 0;
}
body {
    background-color: oklch(92.3% 0.003 48.717);
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
  }
  .no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
  }


body:has(#taskModal.flex),
body:has(#variablesModal.flex) {
    overflow: hidden;
    height: 100dvh !important
}
/* ========================================
   LAYOUT COMPONENTS
   ======================================== */

.card {
    border: 1px solid #fff;
}



.card-disabled  {
    filter: saturate(0);

}

/* Hide card content for special tags */



[data-tag="important"] {
    background: #ee6e6c !important;
    color: #fcf3f2 !important;
    order: -99999
}

.card:has([data-tag="hide"]) .task-url,
.card:has([data-tag="hide"]) .task-footer {
    display: none;
}

.task-footer span.task-footer-button {
    filter: brightness(0.8)
}

/* ========================================
   KANBAN BOARD STYLES
   ======================================== */
.kanban-board {
    scroll-behavior: smooth;
}

.kanban-column {
    flex: 1;
    min-width: 300px;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    overflow: auto
}

.kanban-task {
    cursor: grab;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kanban-task:active {
    cursor: grabbing;
}

.kanban-task.dragging {
    opacity: 0.5;
    cursor: grabbing;
    z-index: 1000;
}

.kanban-task.task-highlight {
    animation: task-highlight-fade 2s ease-in-out;
}

@keyframes task-highlight-fade {
    0% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.2);
    }
    100% {
        filter: brightness(1);
    }
}

.kanban-tasks-container {
    transition: all 0.2s ease;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.task-block {
    background: #ffffff0a;
	border: unset;
	backdrop-filter: brightness(1.15) saturate(0.65);
	border-radius: 8px;
	color: #fff;
	padding: 4px 12px 4px 4px;
	gap: 4px
}

.task-block-url {
    line-height: 1.1;
    font-size: 11px;

}

/* Placeholder для показа места вставки */
.drag-placeholder {
    background: #a8a29e70;
    outline: 2px dashed #a8a29e;
    outline-offset: 2px;
    border-radius: 8px;
    margin: 3px 0;
    transition: all 0.2s ease;
    min-height: 120px; /* Примерная высота task карточки */
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a8a29e;
    font-size: 14px;
    opacity: 0.7;
}

.drag-over-column {
    background-color: rgba(59, 130, 246, 0.05);
}



/* ========================================
   MODAL STYLES
   ======================================== */

.modal {
    background-color: oklch(0.95 0 0);
    border: 1px solid #fff;
}

.modal-header,
.modal-footer {
    position: sticky;
    background-color: oklch(0.95 0 0);
}

.modal-header {
    top: 0;
    padding-top: 10px;
    padding-bottom: 10px;
}

.modal-footer {
    bottom: 0;
    padding-top: 10px;
    padding-bottom: 10px;
    z-index: 3;
	margin-inline: -6px;
}

/* ========================================
   FORM ELEMENTS
   ======================================== */

.input {
    background-color: #fff;
    border: 1px solid oklch(0.88 0.02 68.61);
    color: oklch(37.3% 0.034 259.733);
}

.input::placeholder {
    color: oklch(0.74 0.02 83.58);
}

.input:focus {
    border-color: #9c7762;
    outline: none;
    box-shadow: 0 0 0 3px rgb(246 147 59 / 10%);
}

/* Custom Checkbox */
.checkbox {
    appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #3b82f6;
    border-radius: 3px;
    background: transparent;
    cursor: pointer;
    position: relative;
}

.checkbox:checked {
    background: #9c7762;
    border-color: #9c7762;
}

.checkbox:checked::after {
    content: "✓";
    position: absolute;
    top: -3px;
    left: 2px;
    color: white;
    font-size: 12px;
}

/* ========================================
   BUTTON STYLES
   ======================================== */

.weekday-btn {
    background-color: #f8fafc;
    color: #64748b;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}

.weekday-btn:hover {
    background-color: #f1f5f9;
    border-color: #cbd5e1;
}

.weekday-btn.active {
    background-color: #10b981;
    color: white;
    border-color: #10b981;
}

/* ========================================
   TAB SYSTEM
   ======================================== */

.tab-btns {
    border-bottom: 1px solid oklch(70.9% 0.01 56.259);
    padding-left: 10px;
    font-size: 14px;
}

.tab-content {
    padding-inline: 10px;
}

.tab-button {
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.2s;
    cursor: pointer;
    font-size: 13px;
}

.tab-button.active {
    background-color: #9c7662;
    color: white;
}

.tab-button:not(.active) {
    background-color: #e2dfde;
    color: #807a77;
}

.tab-button:not(.active):hover {
    background-color: #d5cfc6;
}

.tab-btn.active {
    border: 1px solid oklch(70.9% 0.01 56.259);
    border-bottom: unset;
    border-radius: 5px 5px 0 0;
    background: oklch(0.95 0 0);
    transform: translateY(1px);
}

/* ========================================
   FILTER BUTTONS (for logs modal)
   ======================================== */

.filter-btn {
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.2s;
    cursor: pointer;
    font-size: 13px;
    border: 1px solid transparent;
    background-color: #e2dfde;
    color: #807a77;
}

.filter-btn:hover {
    background-color: #d5cfc6;
}

.filter-btn.active {
    background-color: #9c7662;
    color: white;
    border-color: #8a6654;
}

/* ========================================
   TAG SYSTEM
   ======================================== */

.tag {
    display: inline-block;
    padding: 3px 13px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.tag.filter-active {
    ring: 2px solid #000;
}

.tag.filter-inactive {
    opacity: 0.3;
}

.tag-input {
    border: 1px dashed #ccc;
    background: transparent;
    border-radius: 12px;
    padding: 2px 8px;
    font-size: 11px;
    min-width: 60px;
}

.tag-input:focus {
    border-color: #3b82f6;
    outline: none;
}

/* Tag dropdown */
#tagDropdown {
    max-height: 300px;
    overflow-y: auto;
}

.dropdown-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
}

/* ========================================
   ICON SELECTOR
   ======================================== */

.icon-selector {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 3px;
}

.icon-option {
    padding: 4px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
}

.icon-option i {
    color: #9ca3af !important;
}

.icon-option:hover {
    transform: scale(1.1);
}

.icon-option.selected {
    outline: 2px solid #000;
    outline-offset: 0px;
    transform: scale(1.1);
    z-index: 2
}



/* ========================================
   COLOR SELECTOR
   ======================================== */

.color-selector {

}

.color-option {
    width: 35px;
    height: 35px;
    border-radius: 8px;
    border: 2px solid #fff;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.color-option:hover {

    transform: scale(1.05);
}

.color-option.selected {
    outline: 2px solid #000;
    outline-offset: 0px;
    transform: scale(1.1);
    z-index: 2
}

.color-option.selected::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    font-weight: bold;
    font-size: 12px;

}

/* ========================================
   URL TEMPLATES
   ======================================== */

.url-template-item {
    transition: all 0.2s;
}

.url-template-item:hover {
    background-color: #f8fafc;
    border-color: #12b981;
}

/* ========================================
   TASK COMPONENTS
   ======================================== */

.task-icon {
    transition: color 0.2s;
    scale: 1.2;
    transform-origin: top left
}

/* Schedule display optimizations */
.tasks-schedule:has(span:nth-of-type(5)) > span {
    padding-inline: 4px !important;
    padding-block: 1px !important;
    font-size: 11px !important;
}

.tasks-schedule:has(span:nth-of-type(5)) > span i {
    display: none;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 800px) {
    .container {
        padding: 0 20px;
    }

    #tagFilter .tag {
        padding: 9px 20px;
    }

    .add-task-title-area {
        display: flex !important;
        flex-direction: column !important;
    }

    .modal {
        padding-inline: 10px !important;
        max-height: 90vh;
        overflow-y: auto;
    }

    .rule-weekday-btn {
        padding: 0.35rem 0.5rem !important;
        font-size: 0.7rem !important;
    }

    /* Уменьшаем gap между кнопками дней недели */
    .schedule-rule .flex.flex-wrap,
    .calendar-event .flex.flex-wrap {
        gap: 4px !important;
    }

    .schedule-wrap {
        display: flex !important;
        flex-direction: column !important;
        align-items: unset !important;
    }

    .tab-button i {
        display: none;
    }

    .tab-button {
        padding: 10px;
        line-height: 1.2;
    }

    /* Адаптивность канбана для мобильных */
    body, html {
        height: auto !important;
        overflow-y: auto !important;
    }

    body > div {
        height: auto !important;
        overflow: visible !important;
    }

    .kanban-board {
        scroll-snap-type: x mandatory;
        align-items: flex-start;
        height: auto !important;
    }

    .kanban-column {
        flex: 0 0 100%;
        min-width: 100%;
        max-width: 100%;
        scroll-snap-align: center;
        scroll-snap-stop: always;
        height: auto !important;
        min-height: 60vh;
    }

    .kanban-tasks-container {
        overflow-y: visible;
        flex: 1;
        padding-bottom: 2rem;
    }

    /* Адаптивность фильтров */
    #tagDropdown {
        position: fixed !important;
        top: auto !important;
        right: 0.5rem !important;
        left: 0.5rem !important;
        bottom: 0.5rem !important;
        min-width: 0 !important;
        max-width: none !important;
        max-height: 50vh;
        overflow-y: auto;
    }

    /* Адаптивность header */
    body > div > div:first-child {
        padding: 0.5rem;
    }

    /* Уменьшаем кнопки в header */
    body > div > div:first-child button {
        padding: 0.2rem 0.5rem;
        font-size: 0.875rem;
    }

    body > div > div:first-child button i {
        margin-right: 0;
    }

    body > div > div:first-child button span {
        display: none;
    }

    /* Адаптивность модальных окон */
    .modal-content {
        max-width: 95vw !important;
        margin: 0.5rem;
    }

    /* Адаптивность для настроек */
    #variablesModal .modal-content,
    #logsModal .modal-content {
        width: 95vw !important;
        max-width: 95vw !important;
    }

    /* Адаптивность табов в модалах */
    .tab-btns {
        overflow-x: auto;
        white-space: nowrap;
        padding-bottom: 0.5rem;
    }

    /* Уменьшаем размер селекторов */
    .icon-selector {
        grid-template-columns: repeat(8, 1fr);
        gap: 2px;
    }

    .icon-option {
        padding: 6px !important;
        border-width: 1px !important;
    }

    .icon-option i {
        font-size: 0.9rem !important;
    }

    .color-selector {
        grid-template-columns: repeat(8, 1fr);
        gap: 4px;
    }



    .tab-content {
        word-break: break-all;
    }

    /* Адаптация модала настроек */


    /* Компактные ссылки и текст */
    #variablesModal .text-sm {
        font-size: 0.75rem !important;
    }

    #variablesModal .text-xs {
        font-size: 0.65rem !important;
    }

    /* Компактные padding для секций */
    #variablesModal .border.rounded {
        padding: 0.5rem !important;
    }

    #variablesModal .space-y-4 > * {
        margin-top: 0.5rem !important;
    }

    #variablesModal .space-y-2 > * {
        margin-top: 0.25rem !important;
    }

    /* Переменные в одну колонку на мобиле */
    #variablesModal .grid-cols-2 {
        grid-template-columns: 1fr !important;
    }

    /* Компактные кнопки и инпуты */
    #variablesModal button {
        padding: 5px 7px !important;
        font-size: 12px !important;
    }

    #variablesModal input[type="text"],
    #variablesModal input[type="password"] {
        padding: 0.4rem 0.5rem !important;
        font-size: 0.75rem !important;
    }

    /* URL Templates адаптация */
    #urlTemplatesTab .flex.items-center.gap-3 {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 0.5rem !important;
    }

    /* Категории адаптация */
    #categoriesTab .flex.items-center {
        flex-wrap: wrap !important;
    }

    /* Компактные иконки */
    #variablesModal i {
        font-size: 0.75rem;
    }

    /* Компактные code блоки */
    #variablesModal code {
        font-size: 0.65rem !important;
        padding: 0.25rem 0.4rem !important;
    }
}



/* ========================================
   CALENDAR STYLES
   ======================================== */

.calendar-header {
    margin-bottom: 1rem;
}

/* На десктопе скрываем встроенную шапку календаря */
@media (min-width: 769px) {
    .calendar-header {
        display: none;
    }

    /* Показываем навигацию в header только когда календарь активен */
    #headerCalendarNav {
        display: none !important;
    }

    #calendarView:not(.hidden) ~ * #headerCalendarNav,
    body:has(#calendarView:not(.hidden)) #headerCalendarNav {
        display: flex !important;
    }
}

.calendar-grid {
    display: flex;
    flex-direction: column;
    margin-inline: 16px;
}

.weekdays-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid #e7e5e4;
    position: sticky;
    top: 0px;
    background: #fff;
    z-index: 10
}



.days-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
}

.calendar-day {
    min-height: 120px;
    max-width: 100%;
    width: 100%;
    min-width: 0;
    border: 1px solid #e7e5e4;
    border-radius: 0.5rem;
    padding: 0.25rem;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.calendar-day:hover {
    background: #fafaf9;
    border-color: #d6d3d1;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.calendar-day.empty {
    background: #f5f5f4;
    cursor: default;
    border-color: transparent;
}

.calendar-day.empty:hover {
    background: #f5f5f4;
    box-shadow: none;
}

.calendar-day.other-month {
    background: #fafaf9;
    opacity: 0.5;
    border-color: #e7e5e4;
}

.calendar-day.other-month:hover {
    opacity: 0.7;
    background: #f5f5f4;
}

.calendar-day.other-month .day-number {
    color: #a8a29e;
}

.calendar-day.past {
    background: #fafaf9;
    border-color: #e7e5e4;
}

.calendar-day.past .day-number {
    color: #a8a29e;
}

.calendar-day.past:hover {
    background: #f5f5f4;
    cursor: not-allowed;
}

.calendar-day.today {
    border-color: transparent;
    outline: 3px solid #a4797994;
    outline-offset: 2px;
    background: #e7e4e49e
}

.calendar-day.today:hover {
    background: #d5cece9e
}

/* Weekend styling (Saturday and Sunday) */
.calendar-day.holiday {
    background: #ffc5e63b;
	border-color: #daa0c13b;
}

.calendar-day.holiday:hover {
    background: #df9fc33b;
}

.calendar-day.holiday .day-number,
.calendar-day.holiday .text-stone-400 {
    color: #974d8e;
}

.day-number {
    font-weight: 600;
    color: #44403c;
    font-size: 0.875rem;

}

.calendar-day.today .day-number {
    color: #906262;
    font-size: 16px;
}

.day-tasks {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    overflow-y: auto;
    min-width: 0;
    overflow-x: hidden;
}

.calendar-task {

    border-radius: 5px 10px 10px 5px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    cursor: pointer;
    transition: all 0.15s;
    min-width: 0;
    max-width: 100%;
}

.calendar-task-border {
    filter: brightness(.75);
    border-radius: 5px 0 0 5px;
}

.calendar-task:hover {
    opacity: 0.8;
}

.calendar-task i {
    flex-shrink: 0;
    font-size: 0.75rem;
}

.calendar-task .task-name {
    flex: 1;
    line-height: 1.1;
	padding-block: 3px;
    font-weight: 500;
    word-break: break-all;
	padding-right: 3px;
}

/* Responsive calendar */
@media (max-width: 1024px) {
    .days-grid {
        gap: 0.375rem;
    }

    .calendar-day {
        min-height: 100px;
        padding: 0.375rem;
    }

    #calendarView {
        padding: 0.5rem;
    }
}

@media (max-width: 768px) {
    /* Вертикальный календарь на мобильных */
    .weekdays-header {
        display: none; /* Скрываем заголовки дней недели */
    }

    .calendar-grid {
        margin: 0
    }

    .days-grid {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }

    .calendar-day {
        width: 100%;
        max-width: 100%;
        min-height: auto;
        padding: 0.75rem;
        display: flex;
        flex-direction: row;
        gap: 0.75rem;
    }

    .day-number {
        font-size: 1rem;
        margin-bottom: 0;
        flex-shrink: 0;
        min-width: 60px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .day-number span {
        display: block;
        font-size: 0.7rem;
        font-weight: 400;
        opacity: 0.7;
        margin-top: 2px;
    }

    .day-tasks {
        flex: 1;
        gap: 0.5rem;
    }

    .calendar-task {
        font-size: 0.75rem;
        padding: 0.5rem;
    }

    .calendar-task i {
        font-size: 0.75rem;
    }

    #calendarView {
        padding: 0.5rem;
    }

    /* Календарный заголовок - компактный */
    .calendar-header {
        padding: 0.5rem !important;
        margin-bottom: 0.5rem !important;
    }

    .calendar-header h2 {
        font-size: 1rem;
    }

    /* Скрываем часы на мобильных */
    #serverClock {
        display: none;
    }

    .calendar-header button {
        padding: 0.5rem 1rem;
    }

    /* Скрываем дни из других месяцев на мобильных */
    .calendar-day.other-month {
        display: none;
    }
}

@media (max-width: 480px) {
    /* Календарь для очень маленьких экранов */
    .calendar-day {
        padding: 0.5rem;
        gap: 0.5rem;
    }

    .day-number {
        font-size: 0.9rem;
        min-width: 30px;
    }

    .calendar-task {
        font-size: 0.7rem;
        padding: 0.4rem;
    }

    #calendarView {
        padding: 0.25rem;
    }

    .calendar-header {
        padding: 0.5rem !important;
    }

    .calendar-header h2 {
        font-size: 0.9rem;
    }

    /* Компактные модалы на очень маленьких экранах */
    .icon-selector {
        grid-template-columns: repeat(4, 1fr);
    }

    .color-selector {
        grid-template-columns: repeat(4, 1fr);
    }

    .modal-content {
        max-width: 100vw !important;
        margin: 0;
        border-radius: 0;
    }

    /* Еще более компактные формы на маленьких экранах */
    #taskForm label {
        font-size: 0.75rem !important;
    }

    #taskForm input,
    #taskForm select {
        font-size: 0.75rem !important;
        padding: 0.3rem 0.4rem !important;
    }

    /* Weekday buttons еще меньше */
    .weekday-btn,
    .rule-weekday-btn {
        padding: 0.25rem 0.3rem !important;
        font-size: 0.6rem !important;
        min-width: unset !important;
        line-height: 1.2 !important;
    }

    /* Уменьшаем gap между кнопками дней недели */
    .schedule-rule .flex.flex-wrap,
    .calendar-event .flex.flex-wrap {
        gap: 2px !important;
    }

    /* Footer еще компактнее */
    #taskModal .modal-footer button {
        padding: 0.35rem 0.6rem !important;
        font-size: 0.7rem !important;
    }

    #taskModal .modal-footer label {
        font-size: 0.7rem !important;
    }

    .color-selector{

    }

    /* Иконки совсем маленькие */
    .icon-option {
        padding: 4px !important;
    }

    .icon-selector {
grid-template-columns: repeat(8, 1fr);
    }

    .icon-option i {
        font-size: 1.2rem !important;
    }


}

/* ========================================
   NOTIFICATIONS & ANIMATIONS
   ======================================== */

/* Notification animations */
@keyframes slide-in {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slide-out {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

@keyframes scale-in {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.animate-slide-in {
    animation: slide-in 0.3s ease-out;
}

.animate-slide-out {
    animation: slide-out 0.3s ease-out;
}

.animate-scale-in {
    animation: scale-in 0.2s ease-out;
}

/* Notification styles */
.notification {
    min-width: 300px;
    max-width: 400px;
    transition: all 0.3s ease;
}

.notification:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
}

/* ========================================
   LOGS MODAL STYLES
   ======================================== */

/* Timeline styles */
.timeline-day {
    margin-bottom: 1.5rem;
}

.timeline-date {
    z-index: 5;
}

.timeline-logs {
    position: relative;
}

/* ========================================
   CRON TEMPLATE BUTTONS
   ======================================== */
.cron-template-btn {
    padding: 2px 6px;
    font-size: 10px;
    line-height: 1.2;
    color: #6b7280;
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s ease;
    white-space: nowrap;
    font-weight: 500;
}

.cron-template-btn:hover {
    background-color: #f3f4f6;
    border-color: #d1d5db;
    color: #374151;
    transform: translateY(-1px);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.cron-template-btn:active {
    transform: translateY(0);
    background-color: #e5e7eb;
}

/* ========================================
   URL TEXTAREA STYLES
   ======================================== */
.url-input {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.4;
    resize: none;
    height: 38px;
    min-height: 38px;
    max-height: 200px;
    word-break: break-all;
    overflow-wrap: anywhere;
    overflow-y: hidden;
    transition: height 0.15s ease;
}

.url-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Mobile styles for logs */
@media (max-width: 768px) {
    /* Фикс sticky header и footer для всех модалов */
    .modal-header {
        position: sticky !important;
        top: 0 !important;
        z-index: 30 !important;
        background: oklch(0.95 0 0) !important;
        padding: 0.25rem 1rem !important
    }

    .modal {
        height: 100dvh !important;
        max-height: unset !important;
        width: 100vw !important;
        max-width: unset !important;
        margin: 0 !important;
        border-radius: 0 !important;
        padding: 0 !important;
        padding-inline: 0 !important;
        padding-block: 0 !important;
        &.px-6 {
            padding: 0 !important;
            padding-inline: 0 !important;
            padding-block: 0 !important;
        }
       &.mx-4{
        margin: 0 !important;
        }
    }

    .modal-footer {
        position: sticky !important;
        bottom: 0 !important;
        z-index: 30 !important;
        background: oklch(0.95 0 0) !important;
        gap: 5px !important;
        max-width: 100%;
        padding: 5px !important;
        left: 0;
    }



    /* Специфичные стили для модала таска */
    #taskModal .modal {
        padding-inline: 0 !important;
        padding-block: 0 !important;
    }

    #taskModal .modal-header {
        margin-bottom: 0 !important;
        border-bottom: 1px solid #e7e5e4;
    }

    #taskModal .modal-footer {
        justify-content: space-between;
        border-top: 1px solid #e7e5e4 !important;
        margin-top: 0 !important;
        flex-wrap: wrap;


    }

    /* Компактные элементы footer */
    #taskModal .modal-footer label {
        font-size: 0.75rem !important;
        margin: 0 !important;
    }

    #taskModal .modal-footer .checkbox {
        width: 14px !important;
        height: 14px !important;
        margin-right: 0.25rem !important;
    }

    #taskModal .modal-footer button {
        padding: 0.4rem 0.75rem !important;
        font-size: 0.75rem !important;
    }

    /* Располагаем чекбоксы и кнопки в две линии на узких экранах */
    #taskModal .modal-footer {
        justify-content: space-between !important;
    }

    #taskModal .modal-footer label:first-of-type {
        order: 1;
    }

    #taskModal .modal-footer label:last-of-type {
        order: 2;
    }

    #taskModal .modal-footer button:first-of-type {
        order: 3;
    }

    #taskModal .modal-footer button:last-of-type {
        order: 4;
    }

    /* Добавляем padding к содержимому формы */
    #taskModal #taskForm > div:not(.modal-footer) {
        padding-inline: 1rem;
    }

    #taskModal #taskForm > div:first-child {
        padding-top: 0.75rem;
    }

    #taskModal #taskForm > div:last-of-type:not(.modal-footer) {
        padding-bottom: 0.75rem;
    }

    /* Компактные шапки всех модальных окон кроме taskModal */


    .modal-header h2,
    .modal-header h3 {
        font-size: 1rem !important;
    }

    .modal-header i {
        font-size: 0.9rem;
    }

    /* Компактные табы */
    .tab-btns {
        margin-top: 0.5rem !important;
        margin-bottom: 1rem !important;
        gap: 0.25rem !important;
    }

    .tab-btn {
        padding: 0.5rem 0.75rem !important;
        font-size: 0.8rem !important;
    }

    .tab-btn i {
        font-size: 0.75rem;
        margin-right: 0.25rem !important;
    }

    /* Компактное модальное окно */
    .modal {
        padding-block: 0.5rem !important;
        margin: 0.5rem !important;
    }

    /* Компактные формы */
    #taskForm .space-y-5 {
        gap: 0.75rem !important;
    }

    #taskForm .space-y-4 {
        gap: 0.5rem !important;
    }

    #taskForm label {
        font-size: 0.85rem !important;
        margin-bottom: 0.25rem !important;
    }

    /* Компактные инпуты */
    #taskForm input,
    #taskForm select,
    #taskForm textarea {
        font-size: 0.85rem !important;
        padding: 0.4rem 0.6rem !important;
    }

    /* Компактные кнопки в форме */
    #taskForm button:not(.modal-footer button) {
        padding: 0.4rem 0.75rem !important;
        font-size: 0.75rem !important;
    }

    /* Компактный preview */
    #colorPreview {
        padding: 0.5rem !important;
        min-height: 40px !important;
    }

    #colorPreview i {
        font-size: 1rem !important;
    }

    #colorPreview .preview-title {
        font-size: 0.85rem !important;
    }

    /* Компактные Schedule табы */
    .schedule-tab-btn {
        padding: 0.4rem 0.75rem !important;
        font-size: 0.75rem !important;
    }

    /* Компактные weekday кнопки */
    .weekday-btn,
    .rule-weekday-btn {
        padding: 0.3rem 0.4rem !important;
        font-size: 0.65rem !important;
        min-width: 32px !important;
        line-height: 1.2 !important;
    }

    /* Уменьшаем gap между кнопками дней недели */
    .schedule-rule .flex.flex-wrap,
    .calendar-event .flex.flex-wrap {
        gap: 3px !important;
    }

    /* Компактные URL inputs */
    .url-input {
        font-size: 0.8rem !important;
        line-height: 1.3 !important;
        font-family: 'Courier New', Consolas, monospace !important;
    }

    /* Уменьшаем gap между элементами */
    #taskForm .gap-4 {
        gap: 0.5rem !important;
    }

    #taskForm .gap-2 {
        gap: 0.25rem !important;

    }

    .color-selector {
        grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    }

    /* Компактные теги */
    #taskForm .tag,
    #tagsContainer .tag {
        font-size: 0.65rem !important;
        padding: 0.2rem 0.5rem !important;
        display: flex;
		align-items: center;
		gap: 10px;
    }

    .tag-input {
        font-size: 0.7rem !important;
        padding: 0.15rem 0.4rem !important;
    }

    /* Компактный таймаут и чекбоксы */
    #taskTimeout {
        max-width: 100px;
    }

    /* Компактные label для чекбоксов в форме */
    #taskForm label:has(input[type="checkbox"]) {
        font-size: 0.75rem !important;
    }

    /* Компактный селектор категорий */
    #taskCategory {
        font-size: 0.8rem !important;
    }

    /* Компактные Calendar Events */
    .calendar-event-item input[type="date"],
    .calendar-event-item input[type="time"] {
        font-size: 0.75rem !important;
        padding: 0.3rem 0.4rem !important;
    }

    /* Компактный cron expression */
    #cronExpression {
        font-size: 0.75rem !important;
    }

    /* Уменьшаем иконки в labels */
    #taskForm label i {
        font-size: 0.75rem !important;
    }

    /* Компактные Schedule Rules */
    .schedule-rule {
        padding: 0.5rem !important;
    }

    .schedule-rule input[type="time"] {
        font-size: 0.75rem !important;
        padding: 0.3rem 0.4rem !important;
    }

    /* Компактные фильтры */
    .filter-btn {
        padding: 4px 8px !important;
        font-size: 11px !important;
    }

    .filter-btn i {
        font-size: 10px;
        margin-right: 4px !important;
    }

    /* Компактное содержимое логов */
    .timeline-date {
        font-size: 0.8rem;
        padding: 0.5rem !important;
    }

    .timeline-logs {
        margin-left: 0.5rem !important;
        padding-left: 0.5rem !important;
    }

    .log-item {
        padding: 0.5rem !important;
    }

    .log-item .font-medium {
        font-size: 0.75rem !important;
    }

    .log-item .text-xs {
        font-size: 0.65rem !important;
    }

    /* Модальное окно на весь экран */


    /* Убираем отступы по бокам */

}