@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700;800&subset=cyrillic,cyrillic-ext,latin&display=swap');

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg:           #FFFFFF;
  --surface:      #FFFFFF;
  --surface-2:    #F5F5F0;
  --border:       #EAEAEA;
  --border-dark:  #D5D5D0;
  
  --text:         #111111;
  --text-2:       #666660;
  --text-muted:   #9C9C94;
  
  --accent-gold:  #FAB835;
  --accent-gold-dark: #E2A325;
  
  --bar-bg:       #FFFFFF;
  --bar-text:     #111111;
  --bar-muted:    #777777;
  
  --empty:        #EDEDE6;
  --radius-lg:    22px;
  --radius-md:    14px;
  --radius-sm:    10px;
  --font:         'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  
  --shadow-sm:    0 2px 8px rgba(0, 0, 0, 0.03);
  --shadow-md:    0 6px 24px rgba(0, 0, 0, 0.05);
}

html, body {
  font-family: var(--font);
  background: #FFFFFF;
  color: var(--text);
  font-size: 16px;
  line-height: 1.4;
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

/* ── TOP ERROR / ALERT BANNER ── */
.top-error-banner {
  position: fixed;
  top: 14px;
  left: 16px;
  right: 16px;
  max-width: 480px;
  margin: 0 auto;
  background: #1C1C1E;
  border: 1px solid rgba(255, 69, 58, 0.4);
  border-radius: 14px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 100000;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  transform: translateY(-120%);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.top-error-banner.show {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.top-error-banner.type-warning {
  border-color: rgba(255, 159, 10, 0.4);
}

.top-error-banner.type-success {
  border-color: rgba(48, 209, 88, 0.4);
}

.top-error-icon {
  width: 20px;
  height: 20px;
  color: #FF453A;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.top-error-banner.type-warning .top-error-icon {
  color: #FF9F0A;
}

.top-error-banner.type-success .top-error-icon {
  color: #30D158;
}

.top-error-text {
  flex: 1;
  font-size: 13.5px;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.35;
  word-break: break-word;
}

.top-error-close {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font-size: 14px;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease;
}

.top-error-close:active {
  color: #FFFFFF;
}

.loading-screen {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100dvh;
  background-color: #FFFFFF;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.35s;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.tf-loading-container {
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}

.tf-shimmer-logo {
  width: 52px;
  height: 52px;
  display: block;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.06));
  animation: logoPulse 2s ease-in-out infinite;
}

@keyframes logoPulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.92;
  }
  50% {
    transform: scale(1.05);
    opacity: 1;
  }
}

@keyframes textShimmer {
  0% { 
    background-position: -100% center;
  }
  100% { 
    background-position: 100% center;
  }
}

.app {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  width: 100%;
  margin: 0;
  background: var(--bar-bg);
  position: relative;
  overflow: hidden;
  transition: opacity 0.3s ease;
}

/* ══════════════════════════════════════════════════════
   СВЕТЛАЯ КАРТОЧКА КОНТЕНТА (100% ширина без отступов по бокам)
   ══════════════════════════════════════════════════════ */
.content-sheet {
  flex: 1;
  width: 100%;
  margin: 0;
  background: var(--bg);
  border-radius: 0;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 10;
  box-shadow: none;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
}

/* ── TAB CONTENT ── */
.tab-content {
  flex: 1;
  width: 100%;
  display: none;
  flex-direction: column;
  padding: 12px 16px 86px;
  gap: 14px;
}
.tab-content.active { display: flex; }

/* ── PAGE HEADER ── */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px;
  height: 48px;
  background: #0D0D0F;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  flex-shrink: 0;
  margin-bottom: 16px;
  box-sizing: border-box;
}

.page-title {
  font-size: 15px;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: -0.01em;
  margin: 0;
}

.header-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: none;
  transition: transform 0.1s ease, color 0.15s ease, background-color 0.15s ease;
}
.header-btn:active {
  transform: scale(0.95);
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
}
.header-btn svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

/* ── APP GREETING HEADER (КАК В РЕФЕРЕНСЕ) ── */
.app-greeting-header {
  padding: 10px 4px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.greeting-title {
  font-size: 26px;
  font-weight: 800;
  color: #111111;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.greeting-sub {
  color: #9C9C94;
  font-weight: 400;
}

.greeting-subtitle {
  font-size: 13.5px;
  font-weight: 600;
  color: #8E8E93;
  margin-top: 2px;
}

/* ── REFERENCE HERO DARK CARD (КАК В РЕФЕРЕНСЕ) ── */
.ref-hero-card {
  background: #1C1C1E; /* Глубокий матовый темный тон Apple */
  border-radius: 14px !important;
  padding: 16px 18px 14px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.12);
  position: sticky;
  top: 8px;
  z-index: 50;
  overflow: hidden;
  box-sizing: border-box;
}

.ref-hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.ref-hero-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.ref-hero-title {
  font-size: 19px;
  font-weight: 800;
  color: #FFFFFF;
  letter-spacing: -0.02em;
  cursor: pointer;
  line-height: 1.2;
}

.ref-hero-time-sub {
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
}

/* ── НОВАЯ ТИПОГРАФИКА ДЛЯ ШАПКИ РАЗОВОГО (ДАТА + ВРЕМЯ И ДЕВАЙС) ── */
.single-hero-datetime-line {
  display: flex;
  align-items: center;
  gap: 8px;
}

.single-text-date-wrapper,
.single-text-time-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.single-text-trigger {
  font-size: 20px;
  font-weight: 800;
  color: #FFFFFF;
  letter-spacing: -0.02em;
  cursor: pointer;
  line-height: 1.2;
  transition: opacity 0.15s ease;
}

.single-text-trigger:active {
  opacity: 0.75;
}

.single-datetime-dot {
  font-size: 14px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.35);
  user-select: none;
}

.single-hero-device-line {
  display: flex;
  align-items: center;
  margin-top: 5px;
}

.single-device-text-trigger {
  font-size: 13.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: color 0.15s ease;
  user-select: none;
}

.single-device-text-trigger:active {
  color: rgba(255, 255, 255, 0.9);
}

.ref-hero-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ref-action-icon-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: #FFFFFF;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ref-action-icon-btn:active {
  background: rgba(255, 255, 255, 0.18);
  transform: scale(0.92);
}

.ref-action-icon-btn svg {
  width: 15px;
  height: 15px;
  stroke: #FFFFFF;
}

.ref-dots-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  transition: background 0.12s ease;
}

.ref-dots-btn:active {
  background: rgba(255, 255, 255, 0.08);
}

.ref-dots-btn svg {
  width: 16px;
  height: 16px;
}

/* ── WEEK STRIP (ЛЕНТА ДНЕЙ КАК В РЕФЕРЕНСЕ) ── */
.ref-week-strip {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  padding: 0;
  margin-top: 24px; /* Большой красивый "воздушный" отступ */
  border-top: none;
  border-bottom: none;
}

.ref-week-day-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.ref-day-label {
  font-size: 10.5px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.3);
  text-transform: lowercase;
}

.ref-day-bubble {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.7);
  transition: all 0.15s ease;
}

.ref-week-day-col:active .ref-day-bubble {
  transform: scale(0.92);
}

.ref-week-day-col.active .ref-day-bubble {
  background: #E85D04; /* Оранжевый акцентный градиент как в референсе */
  background: linear-gradient(135deg, #FF6B00 0%, #D84A00 100%);
  color: #FFFFFF;
  box-shadow: 0 4px 12px rgba(232, 93, 4, 0.4);
}

.ref-pills-row {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.ref-tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12.5px;
  font-weight: 700;
  color: #FFFFFF;
  cursor: pointer;
  transition: background 0.12s ease;
}

.ref-tag-pill:active {
  background: rgba(255, 255, 255, 0.14);
}

.ref-tag-pill svg {
  width: 13px;
  height: 13px;
  stroke: rgba(255, 255, 255, 0.6);
}

.upload-zone-hint {
  font-size: 12px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.4);
  margin-left: 8px;
}

/* ── SECTION HEADLINE (КАК В РЕФЕРЕНСЕ) ── */
.ref-section-headline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 4px 4px;
}

.ref-section-headline span:first-child {
  font-size: 18px;
  font-weight: 800;
  color: #111111;
  letter-spacing: -0.02em;
}

.ref-section-badge {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-2);
  background: #F0F0EA;
  padding: 4px 10px;
  border-radius: 999px;
}

.device-select-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  max-width: 100%;
}

.big-select-trigger {
  font-size: 15px !important;
  font-weight: 700 !important;
  color: rgba(255, 255, 255, 0.7) !important; /* Название модели слегка тусклее */
  padding: 0 16px 0 0 !important; /* Резервируем место под стрелочку */
  cursor: pointer;
  max-width: 100%;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  user-select: none;
  transition: color 0.15s ease;
}

.big-select-trigger:active {
  color: #FFFFFF !important;
}

.custom-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 6px;
  background: #18181B !important; /* Плотный сплошной глубокий цвет без прозрачности */
  border: none !important;
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.85) !important;
  padding: 6px;
  min-width: 190px;
  z-index: 10000 !important;
  box-sizing: border-box;
  overflow: hidden;
}

.custom-dropdown-menu.open {
  display: block;
  animation: fadeInDropdown 0.12s cubic-bezier(0.25, 1, 0.5, 1);
}

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

.custom-dropdown-item {
  padding: 8px 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45); /* Тусклый белый по умолчанию */
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 8px; /* Капсульный вид внутри меню */
  transition: background-color 0.12s ease, color 0.12s ease;
  white-space: nowrap;
}

.custom-dropdown-item + .custom-dropdown-item {
  border-top: none !important; /* Убираем линии-разделители полностью */
}

.custom-dropdown-item:active {
  background: rgba(255, 255, 255, 0.06);
}

.custom-dropdown-item.active {
  color: #FFFFFF; /* Выбранный горит ярко-белым */
  background: rgba(255, 255, 255, 0.12); /* Серый кружок подсветки как в нижней пилюле */
}

.custom-dropdown-item .check-icon {
  width: 12px;
  height: 12px;
  color: #FFFFFF;
  flex-shrink: 0;
}

.select-chevron {
  position: absolute;
  right: 0; /* Стрелочка прямо у правого края текста */
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  color: rgba(255, 255, 255, 0.5); /* Тусклый шеврон */
  pointer-events: none;
}

.datetime-row {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #FFFFFF;
  flex-wrap: wrap;
  font-size: 15px !important;
  font-weight: 700;
}

.time-select-wrapper,
.date-select-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.big-select-trigger.time-trigger,
.big-select-trigger.date-trigger {
  padding-right: 0 !important;
  color: #FFFFFF !important; /* Дата и время горят ярко-белым */
}

/* ── CUSTOM CALENDAR DROPDOWN ── */
.calendar-dropdown-menu {
  min-width: 200px !important;
  padding: 8px !important;
  z-index: 9999 !important;
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 4px;
  margin-bottom: 6px;
}

.calendar-header span {
  font-size: 13px;
  font-weight: 700;
  color: #FFFFFF;
}

.calendar-nav-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  padding: 4px 6px;
  font-size: 20px;
  font-weight: 300;
  line-height: 1;
  transition: color 0.1s;
}

.calendar-nav-btn:active {
  color: #FFFFFF;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
}

.calendar-grid-header {
  font-size: 10px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.35);
  padding: 2px 0;
  text-transform: uppercase;
}

.calendar-day {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.65);
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.1s;
}

.calendar-day:active {
  background: rgba(255, 255, 255, 0.08);
}

.calendar-day.active {
  color: #FFFFFF !important;
  background: rgba(255, 255, 255, 0.12) !important;
  font-weight: 700;
}

.calendar-day.other-month {
  color: rgba(255, 255, 255, 0.2);
}

/* ── CUSTOM TIME PICKER DROPDOWN ── */
.time-dropdown-menu {
  min-width: 120px !important;
  padding: 6px !important;
  display: none;
  gap: 8px;
  z-index: 9999 !important;
  border: none !important;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8) !important;
}

.time-dropdown-menu.open {
  display: flex !important; /* Для колонок часов и минут */
}

.unified-time-menu {
  min-width: 190px !important;
  padding: 8px !important;
  left: 0 !important;
  right: auto !important;
  border: none !important;
  background: #18181B !important;
}

#single-time-menu {
  left: auto !important;
  right: -20px !important;
  border: none !important;
}

.time-picker-divider {
  width: 1px;
  height: 140px;
  background: rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
  margin: 0 4px;
}

.time-picker-column {
  display: flex;
  flex-direction: column;
  height: 140px;
  overflow-y: auto;
  scrollbar-width: none;
  flex: 1;
}

.time-picker-column::-webkit-scrollbar {
  display: none;
}

.time-picker-item {
  padding: 6px 0;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  border-radius: 6px;
  text-align: center;
  transition: all 0.1s;
}

.time-picker-item:active {
  background: rgba(255, 255, 255, 0.05);
}

.time-picker-item.active {
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.12);
  border: none !important;
  box-shadow: none !important;
}

.bullet-separator {
  margin: 0 4px;
  color: rgba(255, 255, 255, 0.4);
  font-weight: 700;
  font-size: 15px !important;
}

.dash-separator {
  color: rgba(255, 255, 255, 0.4);
  font-weight: 700;
  font-size: 15px !important;
}

/* ── DRUM TIME BOXES (single tab) ── */
.drum-time-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.drum-trigger {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.drum-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 6px 0;
  width: 68px;
  font-size: 22px;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: 0.02em;
  transition: background 0.15s;
}

.drum-trigger:active .drum-box {
  background: rgba(255, 255, 255, 0.14);
}

.drum-colon {
  font-size: 20px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.5);
  padding: 0 2px;
}

/* ── UPLOAD ZONE ── */
.upload-zone {
  border: 1.5px dashed var(--border-dark);
  border-radius: var(--radius-lg);
  padding: 22px 16px;
  text-align: center;
  cursor: pointer;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.upload-zone:hover {
  border-color: rgba(255, 255, 255, 0.15) !important;
}
.upload-icon {
  width: 18px;
  height: 18px;
  fill: rgba(255, 255, 255, 0.25); /* Слегка тусклее, чтобы не выделялась */
  transition: fill 0.15s ease;
}
.upload-zone:active .upload-icon {
  fill: rgba(255, 255, 255, 0.7);
}
.upload-zone input[type="file"] { display: none; }

/* ── SCHEDULE LIST ── */
.schedule-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ── ПРОМЕЖУТОК МЕЖДУ КАРТОЧКАМИ (полоски + минуты) ── */
.schedule-gap-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 2px 14px;
  user-select: none;
}

.schedule-gap-divider .gap-line {
  flex: 1;
  height: 1px;
  background: var(--border-dark);
  opacity: 0.5;
}

.schedule-gap-divider .gap-text {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: lowercase;
  flex-shrink: 0;
}

.schedule-item {
  background: transparent;
}

.schedule-item:hover {
  background: transparent;
}

.schedule-item-main {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
}

.time-label {
  font-size: 17px;
  font-weight: 800;
  color: var(--text);
  min-width: 56px;
  flex-shrink: 0;
  letter-spacing: -0.02em;
  transition: all 0.25s ease;
}

.pair-photos {
  display: flex;
  gap: 10px;
  flex: 1;
  max-width: 200px;
  opacity: 1;
  transform: scale(1);
  transform-origin: left center;
  transition: max-width 0.3s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.25s ease, transform 0.25s ease, margin 0.3s ease;
}

.photo-slot {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.05);
  border: none;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
  position: relative;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.photo-slot:active {
  transform: scale(0.95);
}

.photo-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-slot.empty::after {
  content: '?';
  color: var(--text-muted);
  font-size: 16px;
  font-weight: 700;
}

.photo-slot.has-photo::after {
  content: none;
}

/* Детальная секция карточки расписания (всегда открыта по умолчанию) */
.schedule-item-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-height: 300px;
  opacity: 1;
  transform: scaleY(1);
  transform-origin: top center;
  transition: max-height 0.3s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.25s ease, margin 0.25s ease, transform 0.25s ease;
}

.schedule-item-details.schedule-item-details--hidden {
  max-height: 0;
  opacity: 0;
  transform: scaleY(0.85);
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden;
  pointer-events: none;
}

.details-photos-grid {
  display: flex;
  gap: 10px;
  width: 100%;
}

.details-photos-grid .story-photo-card {
  flex: 1 1 50%;
  aspect-ratio: 9 / 7.5;
  min-height: 95px;
  max-height: 125px;
  background: #F4F4EE;
  border-radius: 14px;
}

.details-photos-grid .story-badge-top {
  top: 8px;
  right: 8px;
  font-size: 10.5px;
  padding: 3px 8px;
}

.details-photos-grid .story-badge-bottom {
  bottom: 8px;
  left: 8px;
  font-size: 11px;
  padding: 3px 9px;
}

.details-photos-grid .story-placeholder .story-plus-icon {
  width: 34px;
  height: 34px;
}

.details-photos-grid .story-placeholder .story-plus-icon svg {
  width: 16px;
  height: 16px;
}

.detail-photo-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #F5F5F0;
  border-radius: 14px;
  padding: 10px;
  min-height: 110px;
  position: relative;
  overflow: hidden;
  border: 1.5px dashed rgba(0, 0, 0, 0.08);
  cursor: pointer;
}

.detail-photo-card.has-image {
  border-style: solid;
  border-color: rgba(0, 0, 0, 0.04);
  padding: 0;
}

.detail-photo-card img {
  width: 100%;
  height: 110px;
  object-fit: cover;
  border-radius: 12px;
}

.detail-photo-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-2);
  margin-top: 4px;
}

.detail-photo-delete-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.65);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: transform 0.12s ease;
}

.detail-photo-delete-badge:active {
  transform: scale(0.9);
}

.detail-photo-delete-badge svg {
  width: 13px;
  height: 13px;
}

/* ── ШИРОКАЯ КНОПКА ДЕЙСТВИЯ ПОД ФОТО И МОРФ-АНИМАЦИЯ ── */
.schedule-item {
  background: transparent;
  border: none;
  border-radius: 14px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: none;
  user-select: none;
  overflow: visible;
  transition: gap 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.schedule-item--skipped {
  gap: 0px !important;
}

.schedule-item-details {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-height: 160px;
  opacity: 1;
  transform: scaleY(1);
  transform-origin: top center;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              margin 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.schedule-item-details.schedule-item-details--hidden {
  max-height: 0px !important;
  opacity: 0 !important;
  transform: scaleY(0.6) scaleX(0.96) !important;
  margin: 0 !important;
  pointer-events: none !important;
}

.schedule-wide-action-btn {
  width: 100%;
  border: none;
  border-radius: 14px;
  padding: 11px 16px;
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  height: 42px;
  box-sizing: border-box;
  background-color: #F4F4EE;
  color: var(--text-2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: background-color 0.32s cubic-bezier(0.16, 1, 0.3, 1),
              color 0.25s ease,
              box-shadow 0.32s ease,
              transform 0.15s ease;
}

.schedule-wide-action-btn:active {
  transform: scale(0.985);
}

.schedule-wide-action-btn.skip-state {
  background-color: #F4F4EE;
  color: var(--text-2);
}

.schedule-wide-action-btn.skip-state:hover {
  background-color: #EBEBE5;
  color: var(--text);
}

.schedule-wide-action-btn.restore-state {
  background-color: #FF5A00 !important;
  color: #FFFFFF !important;
  box-shadow: 0 6px 20px rgba(255, 90, 0, 0.28) !important;
}

.schedule-wide-action-btn .btn-text-skip,
.schedule-wide-action-btn .btn-text-restore {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.28s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.schedule-wide-action-btn.skip-state .btn-text-skip {
  opacity: 1;
  transform: translateY(0);
}

.schedule-wide-action-btn.skip-state .btn-text-restore {
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
}

.schedule-wide-action-btn.restore-state .btn-text-skip {
  opacity: 0;
  transform: translateY(-12px);
  pointer-events: none;
}

.schedule-wide-action-btn.restore-state .btn-text-restore {
  opacity: 1;
  transform: translateY(0);
}

/* ── 1-WEEK CALENDAR STRIP WITH WEEKDAYS (ПН, ВТ, СР...) ── */
.ref-calendar-matrix {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  padding: 0;
  margin-top: 32px;
  max-height: 80px;
  opacity: 1;
  overflow: hidden;
  box-sizing: border-box;
}

.ref-week-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.ref-week-day-name {
  font-size: 11px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  user-select: none;
}

.ref-matrix-cell {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12.5px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.7);
  margin: 0 auto;
  transition: all 0.15s ease;
}

.ref-week-item:active .ref-matrix-cell {
  transform: scale(0.92);
}

.ref-week-item.active .ref-week-day-name {
  color: #FFFFFF;
}

.ref-week-item.active .ref-matrix-cell {
  background: #FF5A00;
  color: #FFFFFF;
  box-shadow: none;
}

#tab-single {
  gap: 10px;
}

/* ── СЕГМЕНТНЫЙ ПЕРЕКЛЮЧАТЕЛЬ ОДИНОЧНАЯ / ПАРА ── */
.single-mode-wrapper {
  display: flex;
  width: 100%;
  margin: 0;
  padding: 0;
  position: relative;
  z-index: 10;
}

.single-mode-switch {
  display: flex;
  position: relative;
  width: 100%;
  background: #F4F4EE;
  padding: 3px;
  border-radius: 14px;
  box-sizing: border-box;
  user-select: none;
  -webkit-user-select: none;
}

.single-mode-glider {
  position: absolute;
  top: 3px;
  left: 3px;
  width: calc(50% - 3px);
  height: calc(100% - 6px);
  background: #FFFFFF;
  border-radius: 11px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: transform 0.25s cubic-bezier(0.32, 0.72, 0, 1);
  pointer-events: none;
  z-index: 1;
}

.single-mode-switch.mode-2-active .single-mode-glider {
  transform: translateX(100%);
}

.single-mode-switch.mode-1-active .single-mode-glider {
  transform: translateX(0);
}

.single-mode-btn {
  flex: 1;
  background: transparent !important;
  border: none;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  color: #7E7E76;
  padding: 9px 0;
  border-radius: 11px;
  cursor: pointer;
  text-align: center;
  position: relative;
  z-index: 5;
  transition: color 0.2s ease;
  box-shadow: none !important;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.single-mode-btn.active {
  color: #111111;
}

/* ── ПЛАШКА ЗАГРУЗКИ ДЛЯ РАСПИСАНИЯ (ЕДИНЫЙ СТИЛЬ БЕЗ ВЛОЖЕННОСТИ) ── */
.interval-upload-switch {
  cursor: pointer;
  padding: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.interval-upload-switch:active {
  transform: scale(0.98);
  opacity: 0.85;
}

.interval-upload-btn {
  background: transparent !important;
  color: #111111 !important;
  box-shadow: none !important;
  padding: 12px 0 !important;
  font-size: 13.5px !important;
}

/* ── СЕТКА КАРТОЧЕК ДЛЯ ФОТО (STORIES STYLE) ── */
.single-stories-grid {
  display: flex;
  gap: 12px;
  width: 100%;
  position: relative;
  align-items: stretch;
  overflow: hidden;
  padding-bottom: 0;
  margin: 0;
}

.story-photo-card {
  position: relative;
  border-radius: 14px;
  background: #F4F4EE;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Карточка 1 (До) */
#single-card-0 {
  flex: 1 1 50%;
  aspect-ratio: 9 / 14;
  transition: flex 0.4s cubic-bezier(0.32, 0.72, 0, 1), 
              aspect-ratio 0.4s cubic-bezier(0.32, 0.72, 0, 1),
              transform 0.2s ease, box-shadow 0.2s ease;
}

/* Карточка 2 (После) */
#single-card-1 {
  flex: 1 1 50%;
  aspect-ratio: 9 / 14;
  opacity: 1;
  transform: translateX(0) scale(1);
  transform-origin: right center;
  transition: flex 0.4s cubic-bezier(0.32, 0.72, 0, 1), 
              opacity 0.3s cubic-bezier(0.32, 0.72, 0, 1), 
              transform 0.4s cubic-bezier(0.32, 0.72, 0, 1),
              aspect-ratio 0.4s cubic-bezier(0.32, 0.72, 0, 1);
}

/* Режим 1 фото: Карточка 0 выталкивает Карточку 1 на 100% ширины */
.single-stories-grid.mode-1 {
  gap: 0;
}

.single-stories-grid.mode-1 #single-card-0 {
  flex: 1 0 100%;
  aspect-ratio: 16 / 15;
}

.single-stories-grid.mode-1 #single-card-1 {
  flex: 0 0 0%;
  opacity: 0;
  transform: translateX(50px) scale(0.9);
  pointer-events: none;
  border-width: 0;
}

.story-photo-card:active {
  transform: scale(0.98);
}

.story-badge-top {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #FFFFFF;
  font-size: 11.5px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: -0.01em;
  pointer-events: none;
}

.story-badge-bottom {
  position: absolute;
  bottom: 12px;
  left: 12px;
  z-index: 5;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 800;
  padding: 5px 11px;
  border-radius: 999px;
  letter-spacing: -0.01em;
  pointer-events: none;
}

.story-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.story-plus-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(0, 0, 0, 0.35);
  transition: all 0.15s ease;
}

.story-photo-card:hover .story-plus-icon {
  background: rgba(0, 0, 0, 0.08);
  color: rgba(0, 0, 0, 0.6);
}

.story-plus-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}

.story-img-container {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.story-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.story-delete-btn {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 6;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px);
  border: none;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.12s ease;
}

.story-delete-btn:active {
  transform: scale(0.9);
}

.story-delete-btn svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
}

/* ── RESET SCHEDULE BUTTON (в самом низу) ── */
.reset-schedule-container {
  display: flex;
  justify-content: center;
  padding: 24px 0 16px;
}

.reset-schedule-btn {
  background: transparent;
  border: 1.5px solid var(--border-dark);
  border-radius: 999px;
  padding: 11px 22px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-2);
  font-family: var(--font);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.15s ease;
}

.reset-schedule-btn:active {
  background: #F2F2EC;
  color: #111111;
  border-color: #111111;
  transform: scale(0.97);
}

.reset-schedule-btn svg {
  width: 16px;
  height: 16px;
}

/* ── CUSTOM MODAL OVERLAYS ── */
.custom-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.custom-modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.custom-modal-card {
  background: #FFFFFF;
  border-radius: 24px;
  width: 100%;
  max-width: 360px;
  padding: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  transform: translateY(20px) scale(0.96);
  transition: transform 0.22s cubic-bezier(0.25, 1, 0.5, 1);
  box-sizing: border-box;
}

.custom-modal-overlay.open .custom-modal-card {
  transform: translateY(0) scale(1);
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}

.modal-header-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.modal-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--text);
}

.modal-subtitle {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.modal-close-btn {
  background: #F0F0EA;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-2);
  transition: background 0.12s ease;
}

.modal-close-btn:active {
  background: #E4E4DC;
}

.modal-close-btn svg {
  width: 16px;
  height: 16px;
}

.modal-photo-preview {
  width: 100%;
  height: 240px;
  border-radius: 16px;
  background: #F7F7F2;
  border: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.modal-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.modal-empty-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
}

.modal-empty-slot svg {
  width: 36px;
  height: 36px;
  stroke: var(--text-muted);
}

.modal-empty-slot span {
  font-size: 13px;
  font-weight: 600;
}

.modal-actions {
  display: flex;
  gap: 8px;
}

.modal-btn {
  flex: 1;
  padding: 13px 16px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.1s ease;
}

.modal-btn:active {
  transform: scale(0.97);
}

.modal-btn svg {
  width: 18px;
  height: 18px;
}

.modal-btn--upload {
  background: #0D0D0F;
  color: #FFFFFF;
}

.modal-btn--delete {
  background: #FEE8E8;
  color: #E53935;
}

/* ── CONFIRM MODAL SPECIFIC ── */
.confirm-modal-card {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 26px 20px;
}

.confirm-icon-box {
  display: none !important;
}

.confirm-title {
  font-size: 18px;
  font-weight: 800;
  color: #111111;
  margin-bottom: 6px;
}

.confirm-desc {
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.45;
  margin-bottom: 20px;
}

.confirm-buttons {
  display: flex;
  gap: 10px;
  width: 100%;
}

.confirm-btn {
  flex: 1;
  padding: 13px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font);
  border: none;
  cursor: pointer;
  transition: transform 0.1s ease;
}

.confirm-btn:active {
  transform: scale(0.97);
}

.confirm-btn--cancel {
  background: #F0F0EA;
  color: var(--text-2);
}

.confirm-btn--secondary {
  background: #E5E5DE;
  color: #111111;
}

.confirm-btn--action {
  background: #0D0D0F;
  color: #FFFFFF;
}

.confirm-btn--danger {
  background: #E53935;
  color: #FFFFFF;
}

.confirm-buttons.confirm-buttons--three {
  flex-direction: column;
  gap: 8px;
}

.confirm-buttons.confirm-buttons--three .confirm-btn {
  width: 100%;
  padding: 12px;
}

/* ── SECTION & CONTROLS ── */
.section { display: flex; flex-direction: column; gap: 8px; }

.section-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-left: 2px;
}

select, input[type="time"], input[type="date"], input[type="text"], input[type="number"] {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  font-family: var(--font);
  background: var(--surface);
  color: var(--text);
  appearance: none;
  -webkit-appearance: none;
  outline: none;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s;
}
select:focus, input:focus { border-color: var(--text); }

.time-range { display: flex; align-items: center; gap: 8px; }
.time-range input { flex: 1; }
.time-range span { color: var(--text-2); font-size: 15px; font-weight: 700; flex-shrink: 0; }

.field-static {
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.divider { border: none; border-top: 1px solid var(--border); margin: 4px 0; }

/* ── REPORT ROWS ── */
#report-rows { display: flex; flex-direction: column; gap: 9px; }

.report-row {
  display: flex;
  align-items: stretch;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.report-row .row-label {
  flex: 1;
  padding: 14px 16px;
  font-size: 15px;
  font-weight: 600;
  border-right: 1px solid var(--border);
  display: flex;
  align-items: center;
  color: var(--text);
}
.report-row .row-value {
  width: 54px;
  padding: 14px 8px;
  text-align: center;
  font-size: 16px;
  font-weight: 800;
  border: none;
  outline: none;
  font-family: var(--font);
  background: var(--surface);
  color: var(--text);
  border-right: 1px solid var(--border);
}
.report-row .counter-btn {
  width: 46px;
  border: none;
  background: var(--surface-2);
  font-size: 20px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  font-family: var(--font);
  transition: background 0.1s;
}
.report-row .counter-btn + .counter-btn { border-left: 1px solid var(--border); }
.report-row .counter-btn:active { background: #DFDFD4; }

/* ══════════════════════════════════════════════════════
   АККУРАТНАЯ ПЛЫВУЩАЯ ПИЛЮЛЯ НАВИГАЦИИ (Floating Glass Pill)
   ══════════════════════════════════════════════════════ */
.bottom-bar-container {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px; /* Отступ, отделяющий оранжевую кнопку действия от пилюли */
  z-index: 100;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  overflow: visible;
}

.bottom-nav-pill {
  width: 210px; /* 4 комфортные кнопки по 52px + 2px рамки */
  height: 56px;
  background: #0D0D0F;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.38);
  overflow: hidden;
  z-index: 2;
}

.floating-circle-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
  padding: 0;
  flex-shrink: 0;
  z-index: 3;
}

#left-action-btn {
  background: #FF5A00 !important;
  color: #FFFFFF !important;
  border: none !important;
  box-shadow: 0 8px 24px rgba(255, 90, 0, 0.3) !important;
  position: relative;
}

#left-action-btn:active {
  transform: scale(0.92);
  background: #E04E00 !important;
}

#left-action-btn svg {
  stroke: none !important;
  fill: #FFFFFF !important;
  width: 20px !important;
  height: 20px !important;
}

#left-action-btn svg path {
  fill: #FFFFFF !important;
}

#right-profile-btn {
  background: #0D0D0F;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.55);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
}

#right-profile-btn:active {
  transform: scale(0.92);
}

#right-profile-btn.active {
  background: #FFFFFF;
  color: #111111;
  border-color: #FFFFFF;
}

#right-profile-btn.active svg {
  stroke: #111111;
}

.floating-circle-btn svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  fill: none;
}

/* Скрываем левое и правое действия для чистой навигации */
.bar-left,
.bar-right {
  display: none !important;
}

.action-label-btn {
  background: none;
  border: none;
  color: var(--bar-text);
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font);
  letter-spacing: -0.01em;
  cursor: pointer;
  padding: 4px 8px;
  transition: opacity 0.15s ease;
}
.action-label-btn:active { opacity: 0.7; }

/* По центру: Круглые иконки вкладок */
.bar-center {
  display: flex;
  align-items: center;
  width: 100%;
  height: 100%;
  gap: 0;
}

.nav-bubble {
  width: 52px; /* 4 кнопки * 52px = 208px */
  height: 56px;
  border-radius: 50%;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex-shrink: 0;
  position: relative;
  transition: background-color 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.nav-bubble svg {
  width: 20px;
  height: 20px;
  color: rgba(255, 255, 255, 0.4) !important;
  fill: currentColor !important;
  position: relative;
  z-index: 2;
  transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
}

.nav-bubble svg path,
.nav-bubble svg circle,
.nav-bubble svg ellipse {
  fill: currentColor !important;
}

.nav-bubble:hover svg {
  color: rgba(255, 255, 255, 0.65) !important;
}

.nav-bubble.active {
  background: transparent !important;
}

.nav-bubble.active::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  z-index: 1;
}

.nav-bubble.active svg {
  color: #FFFFFF !important;
  transform: scale(1.06);
}

.nav-bubble.active svg path,
.nav-bubble.active svg circle,
.nav-bubble.active svg ellipse {
  fill: #FFFFFF !important;
}

/* Справа: Жёлтая акцентная круглая кнопка со счётчиком */
.bar-right {
  display: flex;
  align-items: center;
}

.action-circle-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent-gold);
  border: none;
  color: #111111;
  font-size: 13px;
  font-weight: 800;
  font-family: var(--font);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(250, 184, 53, 0.3);
  transition: transform 0.12s ease, background 0.15s ease;
}
.action-circle-btn:active {
  transform: scale(0.92);
  background: var(--accent-gold-dark);
}

/* ── CONFIG SHEET (Bottom Sheet Modal) ── */
.sheet-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(2px);
  z-index: 200;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.sheet-overlay.open { opacity: 1; }

.config-sheet {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  transform: translateY(100%);
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: 28px 28px 0 0;
  z-index: 201;
  box-shadow: 0 -8px 36px rgba(0, 0, 0, 0.15);
  transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
}
.config-sheet.open { transform: translateY(0); }

.sheet-handle {
  width: 40px;
  height: 4px;
  background: var(--border-dark);
  border-radius: 2px;
  margin: 12px auto 0;
}

.sheet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 22px 10px;
}
.sheet-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.sheet-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s;
}
.sheet-close:active { background: #DCDCD0; }
.sheet-close svg { width: 16px; height: 16px; }

.sheet-body {
  padding: 10px 22px 30px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sheet-apply-btn {
  width: 100%;
  padding: 15px;
  border: none;
  border-radius: 999px;
  background: #111111;
  color: #FFFFFF;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  margin-top: 6px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  transition: background 0.15s ease, transform 0.1s ease;
}
.sheet-apply-btn:active {
  background: #333333;
  transform: scale(0.98);
}

/* ── PROFILE PAGE STYLES ── */
.profile-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--surface);
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  margin-bottom: 8px;
}

.profile-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-2);
}

.profile-avatar svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
}

.profile-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.profile-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
}

.profile-username {
  font-size: 13px;
  color: var(--text-muted);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 8px;
}

.stat-box {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 14px 8px;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.stat-num {
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
}

.stat-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.primary-action-btn {
  width: 100%;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--text);
  color: var(--surface);
  border: none;
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.primary-action-btn:active {
  opacity: 0.85;
}

/* ── UNIFIED DARK BLOCK ── */
.unified-dark-block {
  background: #0D0D0F;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 4px;
  position: sticky;
  top: 8px;
  z-index: 50;
  overflow: visible; /* Чтобы выпадающие списки (календарь, время, девайсы) не обрезались */
}

.datetime-row {
  overflow: visible;
  will-change: max-height, opacity;
}

.unified-dark-block .upload-zone {
  background: rgba(255, 255, 255, 0.01);
  border: 1px dashed rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 16px;
  margin-top: 36px;
  overflow: hidden;
  will-change: max-height, opacity, margin-top, padding;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.unified-dark-block .upload-zone:active {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.1);
}

.unified-dark-block .upload-zone p {
  color: #FFFFFF;
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 4px 0;
}

.unified-dark-block .upload-zone .upload-hint {
  color: rgba(255, 255, 255, 0.45) !important;
  font-size: 11px;
}

/* Скрываем календарную иконку на мобильных, оставляя инпут чистым */
.config-date-input::-webkit-calendar-picker-indicator {
  display: none !important;
  -webkit-appearance: none;
}

/* ── WIP / ЗАГЛУШКА СТРАНИЦА ── */
.wip-page {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 40px 24px 100px;
  text-align: center;
}

.wip-img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  border-radius: 20px;
  opacity: 0.92;
  filter: saturate(0.9);
}

.wip-text {
  font-size: 18px;
  font-weight: 700;
  color: #111111;
  line-height: 1.55;
  letter-spacing: -0.01em;
}

.wip-sub {
  font-size: 13px;
  font-weight: 400;
  color: #E3E3E3;
  margin-top: 4px;
}
