:root {
    /* Telegram цвета */
    --tg-theme-bg-color: #ffffff;
    --tg-theme-text-color: #000000;
    --tg-theme-hint-color: #999999;
    --tg-theme-link-color: #2481cc;
    --tg-theme-button-color: #2481cc;
    --tg-theme-button-text-color: #ffffff;
    --tg-theme-secondary-bg-color: #f4f4f5;
    
    /* RGB версии цветов для rgba() */
    --tg-theme-button-color-rgb: 62, 144, 234;
    --tg-theme-hint-color-rgb: 153, 153, 153;
    
    /* Радиусы скругления */
    --radius-xs: 6px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 50%;
    
    /* Отступы */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 12px;
    --spacing-lg: 16px;
    --spacing-xl: 20px;
    --spacing-2xl: 24px;
    --spacing-3xl: 28px;
    --spacing-4xl: 32px;
    
    /* Тени */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 6px 20px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 12px 24px rgba(0, 0, 0, 0.25);
    
    /* Переходы */
    --transition-fast: 0.1s;
    --transition-normal: 0.2s;
    --transition-slow: 0.3s;
    --transition-ease: cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Шрифты */
    --font-size-xs: 12px;
    --font-size-sm: 14px;
    --font-size-base: 15px;
    --font-size-md: 16px;
    --font-size-lg: 17px;
    --font-size-xl: 20px;
    --font-size-2xl: 24px;
    --font-size-3xl: 34px;
    
    --font-weight-normal: 400;
    --font-weight-medium: 590;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    /* Высота строки */
    --line-height-tight: 1.15;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.6;
    
    /* Z-index слои */
    --z-base: 1;
    --z-dropdown: 100;
    --z-sticky: 500;
    --z-modal: 1000;
    --z-tooltip: 1500;
}

/* Темная тема */
body.dark-theme {
    --tg-theme-bg-color: #18222d;
    --tg-theme-text-color: #ffffff;
    --tg-theme-hint-color: #a8a8a8;
    --tg-theme-link-color: #5ac8fa;
    --tg-theme-button-color: #5ac8fa;
    --tg-theme-button-text-color: #ffffff;
    --tg-theme-secondary-bg-color: #232e3c;
}

/* Автоматическое определение темы через Telegram */
body[data-telegram-theme="dark"] {
    --tg-theme-bg-color: #18222d;
    --tg-theme-text-color: #ffffff;
    --tg-theme-hint-color: #a8a8a8;
    --tg-theme-link-color: #5ac8fa;
    --tg-theme-button-color: #5ac8fa;
    --tg-theme-button-text-color: #ffffff;
    --tg-theme-secondary-bg-color: #232e3c;
}

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

/* Убираем подчёркивание у всех ссылок */
a {
    text-decoration: none !important;
}

a * {
    text-decoration: none !important;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: -0.015em;
    padding: 0;
    margin: 0;
    overflow-x: hidden;
}

.container {
    max-width: 100%;
    padding: var(--spacing-lg);
    padding-bottom: var(--spacing-4xl);
}

/* ========== УТИЛИТАРНЫЕ КЛАССЫ ========== */

/* Карточки */
.card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: var(--radius-md);
    padding: var(--spacing-lg);
}

.card-lg {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-xl);
}

/* Flex контейнеры */
.flex {
    display: flex;
}

.flex-col {
    display: flex;
    flex-direction: column;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

/* Gap утилиты */
.gap-xs { gap: var(--spacing-xs); }
.gap-sm { gap: var(--spacing-sm); }
.gap-md { gap: var(--spacing-md); }
.gap-lg { gap: var(--spacing-lg); }
.gap-xl { gap: var(--spacing-xl); }

/* Transitions */
.transition {
    transition: all var(--transition-normal) var(--transition-ease);
}

.transition-fast {
    transition: all var(--transition-fast) ease;
}

/* Тени */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }

/* Анимации появления */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

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

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

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Утилиты для текста */
.text-hint {
    color: var(--tg-theme-hint-color);
}

.text-center {
    text-align: center;
}

.font-semibold {
    font-weight: var(--font-weight-semibold);
}

.font-bold {
    font-weight: var(--font-weight-bold);
}

/* Header - Улучшенный */
header {
    margin-bottom: var(--spacing-3xl);
}

header h1 {
    font-size: var(--font-size-3xl);
    font-weight: var(--font-weight-bold);
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.02em;
    line-height: var(--line-height-tight);
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.subtitle {
    color: var(--tg-theme-hint-color);
    font-size: var(--font-size-base);
    line-height: 1.47;
    letter-spacing: -0.01em;
    font-weight: var(--font-weight-normal);
}

.back-button {
    background: none;
    border: none;
    color: var(--tg-theme-link-color);
    font-size: var(--font-size-md);
    padding: var(--spacing-sm) 0;
    margin-bottom: var(--spacing-md);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    text-decoration: none;
}

/* Profile Card */
.profile-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: var(--radius-md);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-xl);
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.profile-avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-size-2xl);
    box-shadow: var(--shadow-md);
    flex-shrink: 0;
    overflow: hidden;
    position: relative;
}

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

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
    flex: 1;
}

.profile-name {
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-md);
}

.profile-details {
    color: var(--tg-theme-hint-color);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-normal);
    letter-spacing: -0.01em;
    line-height: 1.47;
}

/* Navigation */
.main-nav {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
}

.nav-button {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: 18px 20px;
    background: var(--tg-theme-secondary-bg-color);
    border-radius: var(--radius-md);
    text-decoration: none !important;
    color: var(--tg-theme-text-color);
    transition: all 0.2s ease;
    position: relative;
    box-shadow: none;
}

.nav-button:active {
    opacity: 0.7;
    transform: scale(0.98);
}

.nav-button .nav-icon {
    font-size: 22px;
    line-height: 1;
}

.nav-button .nav-text {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.3;
}

/* Бейджи с количеством на кнопках навигации */
.nav-button .badge-count {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%) scale(0.8);
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
    z-index: 10;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

/* Бейджи на кнопках внутри карточек */
.btn .badge-count {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 18px;
    height: 18px;
    background: #FFD700;
    color: #000;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.nav-button .badge-count.visible {
    opacity: 1;
    transform: translateY(-50%) scale(1);
    animation: badgePulse 2s ease-in-out infinite;
}

@keyframes badgePulse {
    0%, 100% {
        transform: translateY(-50%) scale(1);
    }
    50% {
        transform: translateY(-50%) scale(1.1);
    }
}


.nav-button.primary .badge-count {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.4);
}

.nav-button.highlight .badge-count {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
}

.nav-button.special .badge-count {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    box-shadow: 0 2px 6px rgba(139, 92, 246, 0.4);
}

/* Базовые стили для анимированных кнопок */
.nav-button.primary,
.nav-button.special,
.nav-button.highlight {
    position: relative;
    overflow: hidden;
    z-index: 1;
    animation: pulseGlow 3s ease-in-out infinite;
}

.nav-button.primary:active,
.nav-button.special:active,
.nav-button.highlight:active {
    transform: scale(0.98);
    opacity: 0.9;
}

/* Общий shimmer эффект для всех анимированных кнопок */
.nav-button.primary::before,
.nav-button.special::before,
.nav-button.highlight::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    animation: shimmer 3s infinite;
}

/* Индивидуальные цвета для каждой кнопки */
.nav-button.primary {
    --glow-color-1: rgba(59, 130, 246, 0.3);
    --glow-color-2: rgba(96, 165, 250, 0.35);
    --glow-color-1-strong: rgba(59, 130, 246, 0.5);
    --glow-color-2-strong: rgba(96, 165, 250, 0.3);
    --glow-color-hover: rgba(59, 130, 246, 0.4);
    --glow-color-2-hover: rgba(96, 165, 250, 0.25);
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border: none;
    box-shadow: 0 2px 8px var(--glow-color-1);
}

.nav-button.special {
    --glow-color-1: rgba(16, 185, 129, 0.3);
    --glow-color-2: rgba(52, 211, 153, 0.35);
    --glow-color-1-strong: rgba(16, 185, 129, 0.5);
    --glow-color-2-strong: rgba(52, 211, 153, 0.3);
    --glow-color-hover: rgba(16, 185, 129, 0.4);
    --glow-color-2-hover: rgba(52, 211, 153, 0.25);
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    box-shadow: 0 2px 8px var(--glow-color-1);
}

.nav-button.special::before {
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
}

.nav-button.highlight {
    --glow-color-1: rgba(255, 165, 0, 0.3);
    --glow-color-2: rgba(255, 215, 0, 0.35);
    --glow-color-1-strong: rgba(255, 165, 0, 0.5);
    --glow-color-2-strong: rgba(255, 215, 0, 0.3);
    --glow-color-hover: rgba(255, 215, 0, 0.4);
    --glow-color-2-hover: rgba(255, 215, 0, 0.3);
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #000000;
    border: none;
    box-shadow: 0 2px 8px var(--glow-color-1);
}

/* Общая анимация свечения с использованием переменных */
@keyframes pulseGlow {
    0%, 100% {
        box-shadow: 0 2px 8px var(--glow-color-1);
    }
    50% {
        box-shadow: 0 4px 16px var(--glow-color-1-strong), 0 0 12px 3px var(--glow-color-2-strong);
    }
}

/* Общая анимация shimmer */
@keyframes shimmer {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
    }
}

/* Общий hover эффект */
.nav-button.primary:hover,
.nav-button.special:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 18px var(--glow-color-hover), 0 0 16px 4px var(--glow-color-2-hover);
}

.nav-button.highlight:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 18px var(--glow-color-hover);
}

body.dark-theme .nav-button.highlight {
    background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
    color: #ffffff;
    border: 2px solid rgba(245, 158, 11, 0.4);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

body.dark-theme .nav-button.highlight:hover {
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.6);
}

.nav-button .icon {
    font-size: 24px;
}

.nav-button .text {
    font-size: 17px;
    font-weight: 510;
    letter-spacing: -0.022em;
    line-height: 1.35;
    text-decoration: none !important;
}

/* Info Card */
.info-card {
    background: linear-gradient(135deg, rgba(66, 153, 225, 0.1) 0%, rgba(66, 153, 225, 0.05) 100%);
    border-left: 4px solid var(--tg-theme-button-color);
    border-radius: 12px;
    padding: 16px 18px;
    margin-top: 20px;
    font-size: 15px;
    font-weight: 400;
    letter-spacing: -0.015em;
    line-height: 1.53;
}

.info-card p {
    margin: 0;
}

.info-card h3 {
    font-size: 16px;
    margin-bottom: 12px;
}

.info-card ol {
    margin-left: 20px;
    color: var(--tg-theme-hint-color);
}

.info-card li {
    margin-bottom: 8px;
    font-size: 14px;
}

/* Form Sections */
.form-section {
    margin-bottom: 24px;
}

.form-section h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
}

/* Секция шаблонов */
.templates-section {
    margin-bottom: 32px;
}

.templates-section h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--tg-theme-text-color);
}

.section-hint {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    margin-bottom: 16px;
    line-height: 1.4;
}

.info-hint {
    border-radius: 12px;
    padding: 14px;
    display: block;
    font-size: 14px;
    line-height: 1.6;
    color: var(--tg-theme-hint-color);
    animation: fadeInDown 0.4s ease;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    max-width: 100%;
}

.info-hint strong {
    display: inline;
    font-weight: 600;
}

.info-hint p {
    margin: 0;
    line-height: 1.5;
}

.templates-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-lg);
    max-width: 600px;
}

.template-card {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid rgba(59, 130, 246, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-slow) var(--transition-ease);
    position: relative;
    overflow: hidden;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    text-decoration: none;
    color: inherit;
    display: block;
}

.template-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, rgba(147, 51, 234, 0.1) 100%);
    opacity: 0;
    transition: opacity var(--transition-slow) ease;
}

.template-card:hover {
    transform: translateY(-4px);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: var(--shadow-xl);
}

.template-card:hover::before {
    opacity: 1;
}

.template-card:active {
    transform: translateY(-2px) scale(0.98);
    border-color: rgba(59, 130, 246, 0.8);
    box-shadow: 0 8px 16px rgba(59, 130, 246, 0.3);
}

.template-card.active {
    border-color: #10b981;
    border-width: 3px;
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    box-shadow: 0 8px 16px rgba(16, 185, 129, 0.3);
}

.template-card.active::after {
    content: '✓';
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background: #10b981;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
}

.template-icon {
    font-size: var(--font-size-3xl);
    margin-bottom: var(--spacing-sm);
    position: relative;
    z-index: var(--z-base);
}

.template-name {
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-semibold);
    color: var(--tg-theme-text-color);
    margin-bottom: var(--spacing-xs);
    position: relative;
    z-index: var(--z-base);
}

.template-description {
    font-size: var(--font-size-xs);
    color: var(--tg-theme-hint-color);
    line-height: 1.3;
    position: relative;
    z-index: var(--z-base);
}

/* Warning Card */
.warning-card {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    display: flex;
    gap: var(--spacing-md);
    animation: fadeInDown 0.4s var(--transition-ease);
}

.warning-icon {
    font-size: 28px;
    flex-shrink: 0;
    line-height: 1;
}

.warning-content {
    flex: 1;
}

.warning-title {
    font-size: var(--font-size-md);
    font-weight: var(--font-weight-bold);
    color: #92400e;
    margin-bottom: var(--spacing-sm);
}

.warning-text {
    font-size: var(--font-size-sm);
    color: #78350f;
    line-height: var(--line-height-relaxed);
}

.warning-text strong {
    font-weight: var(--font-weight-bold);
    color: #92400e;
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Dark theme для шаблонов и предупреждений */
body.dark-theme .template-card {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    border-color: rgba(59, 130, 246, 0.3);
}

body.dark-theme .template-card:hover {
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 0 12px 24px rgba(59, 130, 246, 0.4);
}

body.dark-theme .template-card::before {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(147, 51, 234, 0.2) 100%);
}

body.dark-theme .warning-card {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(217, 119, 6, 0.15) 100%);
    border-color: rgba(245, 158, 11, 0.5);
}

body.dark-theme .warning-title {
    color: #fbbf24;
}

body.dark-theme .warning-text {
    color: #fde68a;
}

body.dark-theme .warning-text strong {
    color: #fcd34d;
}

/* Template Preview Page */
.template-preview-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
}

.template-preview-header {
    text-align: center;
    margin-bottom: 24px;
}

.template-preview-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.template-preview-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--tg-theme-text-color);
}

.template-preview-description {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 16px;
    padding: 16px;
    margin-bottom: 24px;
}

.template-preview-description p {
    color: #1e3a8a;
    line-height: 1.8;
    margin: 0;
}

.template-times {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 24px 0;
}

.time-block {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.give-block {
    border: 2px solid #f59e0b;
}

.take-block {
    border: 2px solid #10b981;
}

.time-block-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.time-block-icon {
    font-size: 24px;
}

.time-block-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--tg-theme-text-color);
}

.time-block-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--tg-theme-text-color);
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.time-block-hint {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    line-height: 1.4;
}

.time-arrow {
    font-size: 32px;
    text-align: center;
    color: #3b82f6;
    font-weight: bold;
}

.instruction-card {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 2px solid #10b981;
    border-radius: 16px;
    padding: 20px;
}

.instruction-card h3 {
    color: #065f46;
    margin-bottom: 12px;
    font-size: 18px;
}

.instruction-card ol {
    color: #064e3b;
}

/* Dark theme для preview */
body.dark-theme .template-preview-description {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.1) 100%);
    border-color: rgba(59, 130, 246, 0.3);
}

body.dark-theme .template-preview-description p {
    color: var(--tg-theme-text-color);
}

body.dark-theme .time-block {
    background: var(--tg-theme-secondary-bg-color);
}

body.dark-theme .instruction-card {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(5, 150, 105, 0.1) 100%);
    border-color: rgba(16, 185, 129, 0.4);
}

body.dark-theme .instruction-card h3 {
    color: #6ee7b7;
}

body.dark-theme .instruction-card ol {
    color: var(--tg-theme-text-color);
}

/* Адаптивность для шаблонов */
@media (max-width: 480px) {
    .templates-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .template-card {
        padding: 12px;
    }
    
    .template-icon {
        font-size: 28px;
    }
    
    .template-name {
        font-size: 14px;
    }
    
    .template-description {
        font-size: 11px;
    }
    
    .warning-card {
        flex-direction: column;
        gap: 8px;
    }
    
    .warning-icon {
        font-size: 24px;
    }
    
    .warning-title {
        font-size: 15px;
    }
    
    .warning-text {
        font-size: 13px;
    }
}

/* Dates Container */
.dates-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
    transform: translateZ(0);
    will-change: contents;
}

/* Selected Date Chip - Compact Style */
.selected-date-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, 
        rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.08) 0%, 
        rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.04) 100%);
    border: 1px solid rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.2);
    border-radius: 12px;
    padding: 10px 12px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInSlide 0.3s ease-out backwards;
}

.selected-date-chip:hover {
    background: linear-gradient(135deg, 
        rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.12) 0%, 
        rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.08) 100%);
    border-color: rgba(var(--tg-theme-button-color-rgb, 59, 130, 246), 0.3);
    transform: translateY(-1px);
}

.selected-date-icon {
    font-size: 18px;
    flex-shrink: 0;
    line-height: 1;
}

.selected-date-text {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    color: var(--tg-theme-text-color);
    line-height: 1.4;
}

.remove-date-chip {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #ef4444;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    line-height: 1;
}

.remove-date-chip:hover {
    background: #ef4444;
    color: white;
    border-color: #ef4444;
    transform: scale(1.1) rotate(90deg);
}

.remove-date-chip:active {
    transform: scale(0.95) rotate(90deg);
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.date-item {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 95%, var(--tg-theme-button-color) 5%) 100%);
    border-radius: 16px;
    padding: 18px;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.03);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInScale 0.4s ease-out backwards;
    will-change: transform, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
    box-shadow: 
        0 2px 8px -2px rgba(0, 0, 0, 0.08),
        0 1px 2px -1px rgba(0, 0, 0, 0.05);
}

.date-item:hover {
    border-color: rgba(255, 59, 48, 0.15);
    transform: translateY(-2px) translateZ(0);
    box-shadow: 
        0 8px 16px -4px rgba(0, 0, 0, 0.12),
        0 4px 8px -2px rgba(0, 0, 0, 0.08);
}

.date-item:active {
    transform: translateY(0) translateZ(0);
    transition-duration: 0.1s;
}

.date-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    gap: 12px;
}

.date-value {
    font-weight: 600;
    font-size: 17px;
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
}

.date-value::before {
    content: '📅';
    font-size: 18px;
}

.remove-date {
    background: linear-gradient(135deg, #ff3b30 0%, #ff1744 100%);
    border: none;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 
        0 2px 8px rgba(255, 59, 48, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

.remove-date::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s;
}

.remove-date:hover::before {
    opacity: 1;
}

.remove-date:hover {
    transform: scale(1.15) rotate(90deg) translateZ(0);
    box-shadow: 
        0 6px 16px rgba(255, 59, 48, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.remove-date:active {
    transform: scale(0.9) rotate(90deg) translateZ(0);
    transition-duration: 0.1s;
}

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

/* Анимация удаления даты */
.date-item.removing {
    animation: fadeOutRight 0.4s ease-out forwards;
    pointer-events: none;
    will-change: transform, opacity, height;
}

@keyframes fadeOutRight {
    0% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
        max-height: 200px;
    }
    50% {
        opacity: 0;
        transform: translate3d(100%, 0, 0) scale(0.8);
        max-height: 200px;
    }
    100% {
        opacity: 0;
        transform: translate3d(100%, 0, 0) scale(0.8);
        max-height: 0;
        padding-top: 0;
        padding-bottom: 0;
        margin-top: 0;
        margin-bottom: 0;
    }
}

/* Редактируемое время */
.editable-time {
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
    background: rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.1);
    display: inline-block;
}

.editable-time:hover {
    background: rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.2);
    transform: scale(1.05);
}

.editable-time::after {
    content: ' ✏️';
    opacity: 0;
    transition: opacity 0.2s ease;
    font-size: 0.85em;
}

.editable-time:hover::after {
    opacity: 1;
}

/* Блокировка секции */
.section-disabled {
    opacity: 0.5;
    pointer-events: none;
    position: relative;
}

.section-disabled::before {
    content: '🔒 Сначала добавьте даты для отдачи';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--tg-theme-bg-color);
    padding: 12px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    font-weight: 600;
    color: var(--tg-theme-hint-color);
    z-index: 10;
    white-space: nowrap;
}

.time-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.time-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.time-label {
    color: var(--tg-theme-hint-color);
    font-size: 14px;
}

.time-value {
    font-size: 16px;
    color: var(--tg-theme-link-color);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(36, 129, 204, 0.1);
}

.time-value:active {
    opacity: 0.7;
}

/* Checkbox */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    cursor: pointer;
    padding: 12px;
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 8px;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    min-width: 20px;
    min-height: 20px;
    cursor: pointer;
    flex-shrink: 0;
}

/* Buttons */
.btn-primary, .btn-secondary, .btn-cancel {
    width: 100%;
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-medium);
    letter-spacing: -0.022em;
    border: none;
    cursor: pointer;
    transition: all 0.25s var(--transition-ease);
    position: relative;
    will-change: transform;
    transform: translateZ(0);
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.btn-primary {
    background: linear-gradient(135deg, var(--tg-theme-button-color) 0%, #2563eb 100%);
    color: var(--tg-theme-button-text-color);
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: -0.01em;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    position: relative;
    overflow: hidden;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: 100%;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
    z-index: 1;
}

.btn-primary > * {
    position: relative;
    z-index: 2;
}

.btn-primary:hover {
    transform: translateY(-2px) translateZ(0);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-secondary {
    background: var(--tg-theme-secondary-bg-color);
    color: var(--tg-theme-link-color);
    box-shadow: 
        var(--shadow-sm),
        inset 0 0 0 1px rgba(0, 0, 0, 0.05);
}

.btn-secondary:hover {
    background: color-mix(in srgb, var(--tg-theme-secondary-bg-color) 90%, var(--tg-theme-button-color) 10%);
    transform: translateY(-1px) translateZ(0);
    box-shadow: var(--shadow-md);
}

.btn-cancel {
    background: transparent;
    color: #ff3b30;
    box-shadow: inset 0 0 0 2px rgba(255, 59, 48, 0.2);
}

.btn-cancel:hover {
    background: rgba(255, 59, 48, 0.08);
    box-shadow: inset 0 0 0 2px rgba(255, 59, 48, 0.3);
}

.btn-primary:active, .btn-secondary:active, .btn-cancel:active {
    transform: translateY(0) scale(0.98) translateZ(0);
    transition-duration: 0.1s;
}

.actions {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    margin-top: var(--spacing-2xl);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 100px;
    background: rgba(0, 0, 0, 0.5);
    z-index: var(--z-modal);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--transition-normal) ease-in-out, visibility var(--transition-normal) ease-in-out;
    will-change: opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 20px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.modal.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.modal-content {
    background: var(--tg-theme-bg-color);
    border-radius: var(--radius-lg);
    padding: 0;
    max-width: 90%;
    width: 500px;
    max-width: 500px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    animation: slideUp var(--transition-slow) ease-out;
    will-change: transform, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    z-index: 10001;
    pointer-events: auto;
}

@media (max-width: 768px) {
    .modal-content {
        width: 100%;
        max-width: 100%;
        max-height: 95vh;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    }
    
    .modal-body {
        max-height: calc(95vh - 180px);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-xl) var(--spacing-xl) var(--spacing-md) var(--spacing-xl);
    border-bottom: 1px solid var(--tg-theme-secondary-bg-color);
}

.modal-header h3 {
    font-size: var(--font-size-xl);
    font-weight: var(--font-weight-semibold);
    margin: 0;
}

.modal-body {
    padding: var(--spacing-xl);
    overflow-y: auto;
    max-height: calc(100vh - 200px);
}

.modal-body h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--tg-theme-text-color);
}

.modal-footer {
    display: flex;
    gap: 12px;
    padding: var(--spacing-md) var(--spacing-xl) var(--spacing-xl) var(--spacing-xl);
    border-top: 1px solid var(--tg-theme-secondary-bg-color);
    justify-content: flex-end;
    flex-wrap: wrap;
}

.modal-footer button {
    min-width: 120px;
    flex: 1;
}

@media (max-width: 480px) {
    .modal-footer {
        flex-direction: column-reverse;
    }
    
    .modal-footer button {
        width: 100%;
        min-width: auto;
    }
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    line-height: 1;
    color: var(--tg-theme-hint-color);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.1);
    color: var(--tg-theme-text-color);
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 100px;
    background: transparent;
    z-index: 10000;
    cursor: pointer;
}

.info-section {
    margin-bottom: 20px;
    padding: 16px;
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    border-left: 4px solid rgba(59, 130, 246, 0.5);
}

.info-section.important {
    border-left-color: rgba(245, 158, 11, 0.5);
    background: rgba(245, 158, 11, 0.05);
}

.info-section h4 {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 12px 0;
    color: var(--tg-theme-text-color);
    text-align: center !important;
    display: block;
    width: 100%;
}

.info-section p {
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 8px 0;
    color: var(--tg-theme-text-color);
}

.info-section ul {
    margin: 8px 0;
    padding-left: 20px;
}

.info-section li {
    font-size: 14px;
    line-height: 1.8;
    margin-bottom: 6px;
    color: var(--tg-theme-text-color);
}

.info-section .hint-text {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    margin-top: 12px;
    margin-bottom: 0;
    padding: 8px 12px;
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.1);
    border-radius: 8px;
}

.close-modal {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--tg-theme-hint-color);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dates-container {
    min-height: 60px;
    padding: 12px;
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 8px;
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dates-container:empty::before {
    content: 'Нажмите "Добавить дату" для выбора';
    color: var(--tg-theme-hint-color);
    font-size: 14px;
    text-align: center;
    display: block;
    padding: 12px;
}

.dates-selection {
    padding: 12px;
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    margin-bottom: 8px;
}

.date-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.date-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    background: var(--tg-theme-bg-color);
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.2s;
}

.date-checkbox:hover {
    background: var(--tg-theme-secondary-bg-color);
}

.date-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--tg-theme-button-color);
}

.date-checkbox span {
    flex: 1;
    font-size: 15px;
    color: var(--tg-theme-text-color);
}

.info-message {
    text-align: center;
    padding: 16px;
}

.info-message p {
    margin-bottom: 8px;
}

/* Дубликат удалён - стили date-item находятся выше */

.date-item span {
    font-size: 15px;
    font-weight: 500;
}

/* Calendar */
.calendar {
    width: 100%;
}

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

.calendar-nav {
    background: var(--tg-theme-secondary-bg-color);
    border: none;
    font-size: 20px;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
}

.calendar-month {
    font-weight: 600;
    font-size: 16px;
}

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

.calendar-day-header {
    text-align: center;
    font-size: 12px;
    color: var(--tg-theme-hint-color);
    padding: 8px;
    font-weight: 600;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.calendar-day:hover {
    background: var(--tg-theme-secondary-bg-color);
}

.calendar-day.selected {
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
}

.calendar-day.disabled {
    color: var(--tg-theme-hint-color);
    cursor: not-allowed;
}

.calendar-day.disabled:hover {
    background: transparent;
}

/* Time Picker */
.time-picker {
    padding: 8px 0;
}

.time-input-group {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.time-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 18px;
    text-align: center;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
}

.time-range {
    display: flex;
    align-items: center;
    gap: 12px;
}

.time-range input {
    flex: 1;
    padding: 14px 16px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 18px;
    text-align: center;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
}

.time-range span {
    font-size: 20px;
    color: var(--tg-theme-hint-color);
}

/* Loading */
.loading {
    text-align: center;
    padding: 40px;
    color: var(--tg-theme-hint-color);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 40px 20px;
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.empty-state-text {
    color: var(--tg-theme-hint-color);
    font-size: 16px;
}

.empty-state p {
    margin-bottom: 12px;
}

.empty-state .hint {
    color: var(--tg-theme-hint-color);
    font-size: 14px;
    margin-bottom: 20px;
}

/* Error state */
.error-state {
    text-align: center;
    padding: 40px 20px;
}

.error-state p {
    margin-bottom: 12px;
}

/* Request Card */
.requests-container {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.request-card {
    background: var(--tg-theme-bg-color);
    border-radius: 14px;
    padding: 16px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(var(--tg-theme-hint-color-rgb, 153, 153, 153), 0.1);
    animation: fadeInUp 0.4s ease-out backwards;
    margin-bottom: 12px;
}

.request-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: linear-gradient(180deg, #3b82f6 0%, rgba(59, 130, 246, 0.3) 100%);
    opacity: 1;
}

.request-card:hover::before {
    background: linear-gradient(180deg, #3b82f6 0%, #2563eb 100%);
}

/* Задержка появления для каждой карточки */
.request-card:nth-child(1) { animation-delay: 0.05s; }
.request-card:nth-child(2) { animation-delay: 0.1s; }
.request-card:nth-child(3) { animation-delay: 0.15s; }
.request-card:nth-child(4) { animation-delay: 0.2s; }
.request-card:nth-child(5) { animation-delay: 0.25s; }

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

body.dark-theme .request-card {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

body.dark-theme .request-card::before {
    background: linear-gradient(180deg, #60a5fa 0%, rgba(96, 165, 250, 0.3) 100%);
}

body.dark-theme .request-card:hover::before {
    background: linear-gradient(180deg, #60a5fa 0%, #3b82f6 100%);
}

.request-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    border-color: rgba(var(--tg-theme-button-color-rgb, 62, 144, 234), 0.3);
}

.request-card:active {
    transform: translateY(0);
    transition-duration: 0.1s;
}

/* Акцент для своих запросов */
.request-card.my-request {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        rgba(36, 129, 204, 0.03) 100%);
    border-left: 4px solid var(--tg-theme-button-color);
}

/* Звезда удалена - была непонятной для пользователей v1760983474522 */

.request-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-sm);
    flex-wrap: wrap;
    gap: var(--spacing-xs);
}

.request-author {
    font-weight: 600;
    font-size: 16px;
    letter-spacing: -0.015em;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    color: var(--tg-theme-text-color);
    margin-bottom: 2px;
}

.request-id {
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-sm);
    letter-spacing: -0.01em;
    line-height: 1.4;
    color: var(--tg-theme-hint-color);
}

.request-date {
    color: var(--tg-theme-hint-color);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-normal);
    letter-spacing: -0.01em;
    line-height: 1.4;
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.request-date::before {
    content: '🕐';
    font-size: 11px;
}

.request-body {
    margin-bottom: var(--spacing-sm);
}

.request-section {
    margin-bottom: var(--spacing-xs);
}

.request-section strong {
    display: block;
    margin-bottom: 8px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.6px;
    color: #666;
    text-transform: uppercase;
    opacity: 1;
}

body.dark-theme .request-section strong {
    color: #999;
}

.request-section p {
    font-size: 15px;
    line-height: 1.55;
    margin: 0;
    color: var(--tg-theme-text-color);
    font-weight: 450;
    letter-spacing: -0.01em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Красивые иконки для дат */
.request-section.give-dates strong::before {
    content: '📤 ';
}

.request-section.take-dates strong::before {
    content: '📥 ';
}

.request-section.any-date strong::before {
    content: '🗓️ ';
}

.request-footer {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
    flex-wrap: wrap;
    width: 100%;
}

.request-city, .request-schedule {
    flex: 1;
    padding: 6px 10px;
    background: rgba(59, 130, 246, 0.08);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    color: var(--tg-theme-text-color);
    letter-spacing: -0.005em;
    border: 1px solid rgba(59, 130, 246, 0.12);
    transition: all 0.2s ease;
}

.request-city:hover, .request-schedule:hover {
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.2);
}

body.dark-theme .request-city,
body.dark-theme .request-schedule {
    background: rgba(96, 165, 250, 0.15);
    border-color: rgba(96, 165, 250, 0.25);
}

body.dark-theme .request-city:hover,
body.dark-theme .request-schedule:hover {
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.35);
}

.request-responses {
    margin-bottom: var(--spacing-sm);
    font-size: var(--font-size-sm);
}

.request-actions {
    display: flex;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-sm);
    flex-wrap: wrap;
}

.request-actions .btn {
    flex: 1;
    min-width: 120px;
    white-space: nowrap;
    font-size: var(--font-size-xs);
}

.request-actions .btn-sm {
    padding: var(--spacing-sm) var(--spacing-md);
}

/* Для узких экранов - кнопки на всю ширину */
@media (max-width: 400px) {
    .request-actions {
        flex-direction: column;
    }
    
    .request-actions .btn {
        width: 100%;
    }
}

/* Для страницы "Мои запросы" - кнопки всегда вертикально и на всю ширину */
.swap-my .request-actions,
.request-card.my-request .request-actions {
    flex-direction: column;
    gap: var(--spacing-sm);
}

.swap-my .request-actions .btn,
.request-card.my-request .request-actions .btn {
    width: 100%;
    flex: none;
    min-width: auto;
}

/* Badges - Улучшенные */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    letter-spacing: -0.01em;
    white-space: nowrap;
    height: 22px;
    line-height: 1;
    min-width: fit-content;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    transition: all var(--transition-normal) ease;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.badge-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.badge-secondary {
    background: var(--tg-theme-hint-color);
    color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Status badges */
.badge-pending {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(245, 158, 11, 0.3);
}

.badge-accepted {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.badge-rejected {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.badge-new {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    margin-left: var(--spacing-sm);
    height: 18px;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

.new-responses-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    margin-top: 8px;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

/* Floating Action Button (FAB) для обновления */
.fab-refresh {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 56px;
    height: 56px;
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
    border: none;
    border-radius: 50%;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    z-index: 999;
    transition: all 0.3s ease;
}

.fab-refresh:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.fab-refresh:active {
    transform: scale(0.95);
}

.fab-refresh.spinning {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Status filter */
.status-filter {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    overflow-x: auto;
    padding: 4px 0;
}

.status-filter-btn {
    padding: 8px 16px;
    background: var(--tg-theme-secondary-bg-color);
    border: 2px solid transparent;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    color: var(--tg-theme-text-color);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.status-filter-btn:hover {
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
}

.status-filter-btn.active {
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
    border-color: var(--tg-theme-button-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Developer Card */
.developer-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 16px;
    padding: 20px;
    margin: 24px 0;
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.developer-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(10%, 10%); }
}

.developer-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(102, 126, 234, 0.4);
}

.developer-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
    border: 3px solid rgba(255, 255, 255, 0.3);
    z-index: 1;
}

.developer-info {
    flex: 1;
    z-index: 1;
}

.developer-label {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 4px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.developer-name {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.developer-role {
    font-size: 13px;
    opacity: 0.85;
}

.developer-contact {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 10px 16px;
    border-radius: 12px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
    z-index: 1;
    white-space: nowrap;
}

.developer-contact:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.developer-contact:active {
    transform: scale(0.98);
}

/* Form Card */
.form-card {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 97%, var(--tg-theme-button-color) 3%) 100%);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.08),
        0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.03);
    animation: slideIn 0.5s ease-out;
    transform: translateZ(0);
    will-change: transform;
}

.form-card h3 {
    margin-bottom: 20px;
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.5px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    font-size: 15px;
    color: var(--tg-theme-text-color);
}

.form-hint {
    margin-top: 8px;
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    opacity: 0.8;
    line-height: 1.4;
}

.form-control {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid transparent;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 500;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    color: #1f2937;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%233b82f6' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 20px 20px;
    padding-right: 56px;
    cursor: pointer;
    box-shadow: 
        0 4px 12px rgba(59, 130, 246, 0.08),
        inset 0 0 0 1px rgba(59, 130, 246, 0.1),
        inset 0 2px 4px rgba(255, 255, 255, 0.5);
    position: relative;
    will-change: transform;
    transform: translateZ(0);
}

.form-control:hover:not(.custom-select-display) {
    box-shadow: 
        0 8px 24px rgba(59, 130, 246, 0.15),
        inset 0 0 0 1px rgba(59, 130, 246, 0.2),
        inset 0 2px 4px rgba(255, 255, 255, 0.7);
    transform: translateY(-2px) translateZ(0);
    border-color: rgba(59, 130, 246, 0.3);
}

/* Специальные стили для обычных select элементов */
select.form-control:hover {
    background-image: url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%233b82f6' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 20px 20px;
}

.form-control:focus {
    outline: none;
    border-color: #3b82f6;
    background: linear-gradient(135deg, #f8fafc 0%, #f0f8ff 100%);
    box-shadow: 
        0 12px 32px rgba(59, 130, 246, 0.25),
        0 0 0 4px rgba(59, 130, 246, 0.1),
        inset 0 0 0 1px rgba(59, 130, 246, 0.3),
        inset 0 2px 4px rgba(59, 130, 246, 0.05);
    transform: translateY(-2px) translateZ(0);
}

.form-control:active {
    transform: scale(0.985) translateZ(0);
    transition-duration: 0.1s;
}

/* Темная тема для select */
.dark-theme .form-control {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    color: #f3f4f6;
    border-color: rgba(59, 130, 246, 0.2);
    box-shadow: 
        0 4px 12px rgba(0, 0, 0, 0.4),
        inset 0 0 0 1px rgba(59, 130, 246, 0.15),
        inset 0 2px 4px rgba(0, 0, 0, 0.2);
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%236366f1' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 20px center;
}

.dark-theme .form-control:hover:not(.custom-select-display) {
    background: linear-gradient(135deg, #374151 0%, #1f2937 100%);
    box-shadow: 
        0 8px 24px rgba(59, 130, 246, 0.25),
        inset 0 0 0 1px rgba(59, 130, 246, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.05);
    border-color: rgba(59, 130, 246, 0.4);
}

/* Специальные стили для обычных select элементов в темной теме */
.dark-theme select.form-control:hover {
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%236366f1' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 20px center;
    background-size: 20px 20px;
}

.dark-theme .form-control:focus {
    background: linear-gradient(135deg, #374151 0%, #1f2937 100%);
    box-shadow: 
        0 12px 32px rgba(59, 130, 246, 0.35),
        0 0 0 4px rgba(59, 130, 246, 0.2),
        inset 0 0 0 1px rgba(59, 130, 246, 0.4),
        inset 0 2px 4px rgba(99, 102, 241, 0.1);
    border-color: #6366f1;
}

/* Улучшенный вид option */
.form-control option {
    padding: 10px 14px;
    background: #ffffff;
    color: #1f2937;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.4;
    transition: all 0.2s;
}

.form-control option:hover {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
}

.form-control option:checked {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: #ffffff;
    font-weight: 600;
}

/* Стили для optgroup */
.form-control optgroup {
    font-weight: 600;
    font-size: 12px;
    color: #6b7280;
    font-style: normal;
    padding: 8px 14px;
    background: #f9fafb;
    margin-top: 4px;
}

.dark-theme .form-control option {
    background: #1f2937;
    color: #f3f4f6;
}

.dark-theme .form-control option:hover {
    background: #374151;
}

.dark-theme .form-control option:checked {
    background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%);
    color: #ffffff;
}

.dark-theme .form-control optgroup {
    background: #111827;
    color: #9ca3af;
}

/* Стили для form-group */
.form-group {
    margin-bottom: 24px;
    animation: slideIn 0.4s ease-out;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.form-group:focus-within label {
    color: #3b82f6;
}

.form-hint {
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

.form-group:focus-within .form-hint {
    opacity: 1;
}

/* Анимация появления */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Button sizes */
.btn-sm {
    padding: 8px 16px;
    font-size: 14px;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    border: none;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 16px;
    cursor: pointer;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.btn-danger:active {
    transform: translateY(0);
    opacity: 0.9;
}

/* Request Details Page */
.request-author-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
}

.request-author-card h3 {
    font-size: 16px;
    margin-bottom: 12px;
}

.author-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.author-name {
    font-weight: 600;
    font-size: 16px;
}

.author-details {
    display: flex;
    gap: 16px;
    color: var(--tg-theme-hint-color);
    font-size: 14px;
}

.request-detail-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
}

.request-detail-card h3 {
    font-size: 16px;
    margin-bottom: 16px;
}

.detail-section {
    margin-bottom: 20px;
}

.detail-section h4 {
    font-size: 15px;
    margin-bottom: 8px;
    font-weight: 600;
}

.dates-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.date-list-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px 14px;
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.04);
    border-radius: 10px;
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    border: 1px solid rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.08);
    transition: all 0.2s ease;
}

.date-list-item:hover {
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.06);
}

body.dark-theme .date-list-item {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
}

body.dark-theme .date-list-item:hover {
    background: rgba(255, 255, 255, 0.06);
}

.date-icon {
    font-size: 20px;
    line-height: 1;
    margin-top: 1px;
}

.date-text {
    font-weight: 500;
    color: var(--tg-theme-text-color);
    font-size: 15px;
    letter-spacing: -0.01em;
    line-height: 1.4;
}

.time-text {
    color: var(--tg-theme-hint-color);
    font-size: 13px;
    font-weight: 450;
    display: block;
    line-height: 1.4;
    letter-spacing: -0.005em;
}

.any-date-badge {
    display: inline-block;
    padding: 8px 16px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 20px;
    font-weight: 500;
    font-size: 14px;
}

.request-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding-top: 12px;
    border-top: 1px solid rgba(128, 128, 128, 0.2);
}

.meta-item {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
}

.respond-section {
    margin: 20px 0;
}

.hint-text {
    text-align: center;
    color: var(--tg-theme-hint-color);
    font-size: 13px;
    margin-top: 8px;
}

/* Response Cards */
.response-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    border-left: 4px solid var(--tg-theme-button-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.response-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.response-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(128, 128, 128, 0.15);
}

.response-author {
    font-weight: 600;
    font-size: 15px;
}

.response-date {
    color: var(--tg-theme-hint-color);
    font-size: 13px;
}

.response-body {
    margin-bottom: 12px;
}

.response-details {
    margin-bottom: 12px;
    padding: 10px;
    background: var(--tg-theme-bg-color);
    border-radius: 8px;
}

.response-details p {
    margin: 6px 0;
    font-size: 14px;
}

.response-section {
    margin-top: 12px;
}

.response-section strong {
    display: block;
    margin-bottom: 4px;
    font-size: 14px;
}

.response-section p {
    margin: 4px 0;
    font-size: 14px;
    color: var(--tg-theme-text-color);
}

.response-message {
    margin-top: 12px;
    padding: 10px;
    background: var(--tg-theme-bg-color);
    border-radius: 8px;
}

.response-message strong {
    display: block;
    margin-bottom: 4px;
}

.response-message p {
    margin: 0;
    font-size: 14px;
    font-style: italic;
}

.response-dates {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 16px 0;
    padding: 16px;
    background: var(--tg-theme-bg-color);
    border-radius: 12px;
    border: 1px solid rgba(128, 128, 128, 0.1);
}

.response-dates > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.response-dates strong {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.response-dates p {
    margin: 0;
    font-size: 15px;
    color: var(--tg-theme-text-color);
    font-weight: 500;
    line-height: 1.5;
}

.response-header strong {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    display: block;
}

.response-header p {
    margin: 0;
    font-size: 13px;
    color: var(--tg-theme-hint-color);
}

.response-message {
    padding: 12px 16px;
    background: var(--tg-theme-bg-color);
    border-radius: 10px;
    margin: 12px 0;
    border-left: 3px solid var(--tg-theme-button-color);
    font-size: 14px;
    line-height: 1.6;
}

.response-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid rgba(128, 128, 128, 0.1);
}

.response-actions .btn {
    flex: 1;
    font-weight: 600;
    font-size: 15px;
    padding: 14px 20px;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.response-actions .btn-success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.3);
}

.response-actions .btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    box-shadow: 0 6px 16px rgba(34, 197, 94, 0.4);
    transform: translateY(-2px);
}

.response-actions .btn-success:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(34, 197, 94, 0.3);
}

.response-actions .btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.response-actions .btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
    transform: translateY(-2px);
}

.response-actions .btn-danger:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.response-actions .btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

@media (max-width: 400px) {
    .response-actions {
        flex-direction: column;
    }
    
    .response-actions .btn {
        width: 100%;
    }
}

/* Form Textarea */
.form-textarea {
    width: 100%;
    min-height: 80px;
    padding: 12px;
    border: 2px solid rgba(128, 128, 128, 0.2);
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.5;
    font-family: inherit;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    resize: vertical;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--tg-theme-button-color);
}

.form-textarea::placeholder {
    color: var(--tg-theme-hint-color);
}

/* Available Take Dates */
#availableTakeDates {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

/* Rules Page */
.rules-section {
    margin-bottom: 24px;
}

.rules-section h2 {
    font-size: 18px;
    margin-bottom: 16px;
    color: var(--tg-theme-text-color);
}

.rule-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    display: flex;
    gap: 16px;
    border-left: 4px solid var(--tg-theme-button-color);
    transition: transform 0.2s ease;
}

.rule-card:hover {
    transform: translateY(-2px);
}

.rule-card.important {
    border-left-color: #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05) 0%, var(--tg-theme-secondary-bg-color) 100%);
}

.rule-icon {
    font-size: 32px;
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--tg-theme-bg-color);
    border-radius: 12px;
}

.rule-content {
    flex: 1;
}

.rule-content h3 {
    font-size: 16px;
    margin-bottom: 8px;
    color: var(--tg-theme-text-color);
}

.rule-content p {
    font-size: 14px;
    line-height: 1.6;
    color: var(--tg-theme-text-color);
    margin-bottom: 12px;
}

.rule-content ul {
    margin-left: 20px;
    font-size: 14px;
}

.rule-content ul li {
    margin-bottom: 8px;
}

.rule-example {
    background: var(--tg-theme-bg-color);
    border-radius: 8px;
    padding: 12px;
    margin-top: 12px;
    border-left: 3px solid #10b981;
}

.rule-example.error {
    border-left-color: #ef4444;
}

.example-label {
    display: block;
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 6px;
}

.example-note {
    display: block;
    font-size: 12px;
    color: var(--tg-theme-hint-color);
    margin-top: 4px;
    font-style: italic;
}

.timezone-list {
    list-style: none;
    margin: 12px 0;
    padding: 0;
}

.timezone-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--tg-theme-bg-color);
    border-radius: 8px;
    margin-bottom: 8px;
}

.city-name {
    font-weight: 500;
    font-size: 14px;
}

.timezone-badge {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.timezone-badge.highlight {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.timezone-note {
    background: rgba(245, 158, 11, 0.1);
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 13px;
    margin-top: 12px;
    border-left: 3px solid #f59e0b;
}

.forge-steps {
    margin-left: 20px;
    font-size: 14px;
}

.forge-steps li {
    margin-bottom: 6px;
}

.schedule-card {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    border-left: 4px solid var(--tg-theme-button-color);
}

.schedule-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.schedule-name {
    font-weight: 600;
    font-size: 15px;
}

.schedule-hours {
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.schedule-card p {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    margin: 0;
}

.info-card.warning {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(239, 68, 68, 0.05) 100%);
    border-left-color: #ef4444;
}

/* ============================================
   🎨 UI/UX IMPROVEMENTS - БАЗОВЫЕ УЛУЧШЕНИЯ
   ============================================ */

/* 1. TOAST NOTIFICATIONS - Floating Style */
.toast-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
    width: calc(100% - 32px);
    max-width: 420px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    padding: 14px 18px;
    border-radius: 16px;
    box-shadow: 
        0 8px 24px rgba(0, 0, 0, 0.12),
        0 4px 8px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(0, 0, 0, 0.04);
    pointer-events: auto;
    cursor: pointer;
    min-height: 64px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    will-change: transform, opacity;
}

.toast:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 12px 32px rgba(0, 0, 0, 0.16),
        0 6px 12px rgba(0, 0, 0, 0.1),
        0 0 0 1px rgba(0, 0, 0, 0.04);
}

.toast:active {
    transform: scale(0.98);
}

.toast-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.toast:hover .toast-icon {
    transform: scale(1.1) rotate(5deg);
}

.toast-message {
    flex: 1;
    font-size: 15px;
    line-height: 1.5;
    font-weight: 500;
}

/* Toast types */
.toast-success {
    background: linear-gradient(135deg, 
        color-mix(in srgb, var(--tg-theme-bg-color) 85%, #10b981 15%),
        var(--tg-theme-bg-color));
    border-left: 4px solid #10b981;
}

.toast-success .toast-icon {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.toast-error {
    background: linear-gradient(135deg, 
        color-mix(in srgb, var(--tg-theme-bg-color) 85%, #ef4444 15%),
        var(--tg-theme-bg-color));
    border-left: 4px solid #ef4444;
}

.toast-error .toast-icon {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.toast-warning {
    background: linear-gradient(135deg, 
        color-mix(in srgb, var(--tg-theme-bg-color) 85%, #f59e0b 15%),
        var(--tg-theme-bg-color));
    border-left: 4px solid #f59e0b;
}

.toast-warning .toast-icon {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
}

.toast-info {
    background: linear-gradient(135deg, 
        color-mix(in srgb, var(--tg-theme-bg-color) 85%, var(--tg-theme-button-color) 15%),
        var(--tg-theme-bg-color));
    border-left: 4px solid var(--tg-theme-button-color);
}

.toast-info .toast-icon {
    background: linear-gradient(135deg, var(--tg-theme-button-color), #1d72b8);
    color: white;
    box-shadow: 0 4px 12px rgba(36, 129, 204, 0.4);
}

/* Toast animations */
.toast-enter {
    opacity: 0;
    transform: translateY(-30px) scale(0.9);
}

.toast-show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.toast-exit {
    opacity: 0;
    transform: translateY(-30px) scale(0.9);
}

/* Dark theme adjustments */
@media (prefers-color-scheme: dark) {
    .toast {
        background: color-mix(in srgb, var(--tg-theme-bg-color) 90%, #fff 10%);
        box-shadow: 
            0 8px 24px rgba(0, 0, 0, 0.4),
            0 4px 8px rgba(0, 0, 0, 0.3),
            0 0 0 1px rgba(255, 255, 255, 0.1);
    }
    
    .toast:hover {
        box-shadow: 
            0 12px 32px rgba(0, 0, 0, 0.5),
            0 6px 12px rgba(0, 0, 0, 0.4),
            0 0 0 1px rgba(255, 255, 255, 0.1);
    }
}

/* 2. SKELETON LOADERS - PREMIUM SHIMMER */
.skeleton {
    background: linear-gradient(
        110deg,
        var(--tg-theme-secondary-bg-color) 8%,
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 70%, #fff 30%) 18%,
        var(--tg-theme-secondary-bg-color) 33%
    );
    background-size: 200% 100%;
    animation: shimmer 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    will-change: background-position;
    transform: translateZ(0);
}

.skeleton::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 100%
    );
    transform: translateX(-100%);
    animation: shimmer-highlight 2s ease-in-out infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

@keyframes shimmer-highlight {
    0% {
        transform: translateX(-100%);
    }
    50%, 100% {
        transform: translateX(200%);
    }
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.skeleton-title {
    height: 24px;
    width: 60%;
    margin-bottom: 12px;
    border-radius: 6px;
}

.skeleton-card {
    height: 120px;
    margin-bottom: 12px;
    border-radius: 12px;
}

.skeleton-button {
    height: 48px;
    border-radius: 12px;
}

.skeleton-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

/* Skeleton для карточки запроса */
.skeleton-request-card {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 97%, #fff 3%) 100%);
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 12px;
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.05),
        0 1px 2px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.02);
    animation: fadeInScale 0.4s ease-out backwards;
}

.skeleton-request-card .skeleton-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.skeleton-request-card .skeleton-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* 3. SMOOTH ANIMATIONS */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

/* Анимации для элементов */
.animate-fade-in {
    animation: fadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-slide-up {
    animation: slideUp 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-scale-in {
    animation: scaleIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Staggered animation для списков */
.stagger-item {
    opacity: 0;
    animation: fadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.stagger-item:nth-child(1) { animation-delay: 0.05s; }
.stagger-item:nth-child(2) { animation-delay: 0.1s; }
.stagger-item:nth-child(3) { animation-delay: 0.15s; }
.stagger-item:nth-child(4) { animation-delay: 0.2s; }
.stagger-item:nth-child(5) { animation-delay: 0.25s; }
.stagger-item:nth-child(6) { animation-delay: 0.3s; }
.stagger-item:nth-child(n+7) { animation-delay: 0.35s; }

/* Smooth transitions */
.smooth-transition {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 4. RIPPLE EFFECT */
.ripple-container {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8) 0%, rgba(255, 255, 255, 0.4) 50%, rgba(255, 255, 255, 0) 100%);
    transform: scale(0) translateZ(0);
    animation: ripple-animation 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    will-change: transform, opacity;
    backface-visibility: hidden;
}

.ripple-primary {
    background: radial-gradient(circle, rgba(59, 130, 246, 0.6) 0%, rgba(59, 130, 246, 0.3) 50%, rgba(59, 130, 246, 0) 100%);
}

.ripple-danger {
    background: radial-gradient(circle, rgba(239, 68, 68, 0.6) 0%, rgba(239, 68, 68, 0.3) 50%, rgba(239, 68, 68, 0) 100%);
}

@keyframes ripple-animation {
    0% {
        transform: scale(0) translateZ(0);
        opacity: 1;
    }
    100% {
        transform: scale(4) translateZ(0);
        opacity: 0;
    }
}

/* Применяем ripple к интерактивным элементам */
.btn, .btn-primary, .btn-secondary, .btn-cancel, .btn-danger, 
.nav-button, .request-card, .form-control,
.back-button, .developer-contact, .bottom-sheet-item,
.custom-select-display {
    position: relative;
}

/* Overflow только для элементов с ripple */
.btn[data-ripple-added="true"],
.btn-primary[data-ripple-added="true"],
.btn-secondary[data-ripple-added="true"],
.btn-cancel[data-ripple-added="true"],
.request-card[data-ripple-added="true"],
.bottom-sheet-item[data-ripple-added="true"] {
    overflow: hidden;
}

/* date-item нужен overflow для remove-date::before */
.date-item {
    overflow: visible;
}

/* ========== BOTTOM SHEET ========== */

.bottom-sheet-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.bottom-sheet-backdrop.show {
    opacity: 1;
    visibility: visible;
}

.bottom-sheet {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--tg-theme-bg-color);
    border-radius: 24px 24px 0 0;
    max-height: 80vh;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 
        0 -10px 40px rgba(0, 0, 0, 0.2),
        0 -2px 8px rgba(0, 0, 0, 0.1);
    will-change: transform;
}

.bottom-sheet.show {
    transform: translateY(0);
}

.bottom-sheet-handle {
    padding: 12px 0 8px;
    display: flex;
    justify-content: center;
    cursor: grab;
    touch-action: none;
}

.bottom-sheet-handle:active {
    cursor: grabbing;
}

.bottom-sheet-handle-bar {
    width: 40px;
    height: 5px;
    background: var(--tg-theme-hint-color);
    border-radius: 3px;
    opacity: 0.3;
    transition: all 0.2s ease;
}

.bottom-sheet-handle:hover .bottom-sheet-handle-bar {
    opacity: 0.5;
    width: 50px;
}

.bottom-sheet-header {
    padding: 8px 24px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bottom-sheet-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.5px;
}

.bottom-sheet-icon {
    font-size: 24px;
}

.bottom-sheet-close {
    position: absolute;
    top: 16px;
    right: 24px;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 20px;
    color: var(--tg-theme-hint-color);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bottom-sheet-close:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: rotate(90deg);
}

.bottom-sheet-search {
    margin-top: 8px;
}

.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 16px;
    font-size: 18px;
    opacity: 0.5;
}

.search-input {
    width: 100%;
    padding: 12px 16px 12px 48px;
    border: 2px solid rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    font-size: 16px;
    background: var(--tg-theme-secondary-bg-color);
    color: var(--tg-theme-text-color);
    transition: all 0.2s ease;
}

.search-input:focus {
    outline: none;
    border-color: var(--tg-theme-button-color);
    background: var(--tg-theme-bg-color);
    box-shadow: 0 0 0 3px rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.1);
}

.bottom-sheet-content {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
    overscroll-behavior: contain;
}

.bottom-sheet-item {
    padding: 16px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    animation: slideInLeft 0.3s ease-out backwards;
    will-change: transform;
    transform: translateZ(0);
}

.bottom-sheet-item:hover {
    background: rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.05);
}

.bottom-sheet-item:active {
    background: rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.1);
    transform: scale(0.98);
}

.bottom-sheet-item.selected {
    background: linear-gradient(90deg, 
        rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.12) 0%,
        rgba(var(--tg-theme-button-color-rgb, 36, 129, 204), 0.05) 100%);
    border-left: 4px solid var(--tg-theme-button-color);
}

.item-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.item-text {
    flex: 1;
    font-size: 16px;
    font-weight: 500;
}

.item-check {
    font-size: 20px;
    color: var(--tg-theme-button-color);
    font-weight: 700;
}

.bottom-sheet-empty {
    padding: 48px 24px;
    text-align: center;
    color: var(--tg-theme-hint-color);
    font-size: 16px;
}

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

/* Custom Select Display (замена нативного select) */
.custom-select-display {
    width: 100%;
    padding: 18px 24px;
    border: 2px solid transparent;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 500;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    color: #1f2937;
    cursor: pointer;
    box-shadow: 
        0 4px 12px rgba(59, 130, 246, 0.08),
        inset 0 0 0 1px rgba(59, 130, 246, 0.1),
        inset 0 2px 4px rgba(255, 255, 255, 0.5);
    position: relative;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    will-change: transform;
    transform: translateZ(0);
}

.custom-select-display::after {
    content: '';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%233b82f6' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.3s ease, opacity 0.3s ease;
    opacity: 1;
    z-index: 1;
}

.custom-select-display:hover {
    transform: translateY(-2px) translateZ(0);
    box-shadow: 
        0 8px 24px rgba(59, 130, 246, 0.15),
        inset 0 0 0 1px rgba(59, 130, 246, 0.2),
        inset 0 2px 4px rgba(255, 255, 255, 0.7);
    border-color: rgba(59, 130, 246, 0.3);
}

.dark-theme .custom-select-display:hover {
    transform: translateY(-2px) translateZ(0);
    box-shadow: 
        0 8px 24px rgba(59, 130, 246, 0.25),
        inset 0 0 0 1px rgba(59, 130, 246, 0.3),
        inset 0 2px 4px rgba(255, 255, 255, 0.05);
    border-color: rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, #374151 0%, #1f2937 100%);
}

.custom-select-display:hover::after {
    transform: translateY(-50%) scale(1.1);
    opacity: 1;
}

.dark-theme .custom-select-display:hover::after {
    transform: translateY(-50%) scale(1.1);
    opacity: 1;
}

.custom-select-display:active::after {
    transform: translateY(-50%) scale(0.9);
}

/* ========== УВЕЛИЧЕННЫЕ TOUCH TARGETS ========== */

/* Минимум 44x44px для всех кликабельных элементов (Apple HIG) */
.btn, .btn-primary, .btn-secondary, .btn-cancel,
.remove-date, .close-modal, .back-button,
.bottom-sheet-close {
    min-width: 44px;
    min-height: 44px;
}

/* Псевдо-элемент для расширения области клика */
.remove-date::after,
.close-modal::after,
.bottom-sheet-close::after {
    content: '';
    position: absolute;
    top: -8px;
    left: -8px;
    right: -8px;
    bottom: -8px;
    border-radius: inherit;
    z-index: -1;
    pointer-events: auto;
}

/* Увеличенные отступы для мобильных */
@media (pointer: coarse) {
    .date-item {
        padding: 20px;
    }
    
    .btn-primary, .btn-secondary, .btn-cancel {
        padding: 18px;
        font-size: 17px;
    }
    
    .form-control, .custom-select-display {
        padding: 15px 18px;
        font-size: 15px;
    }
    
    .bottom-sheet-item {
        padding: 18px 24px;
        min-height: 60px;
    }
    
    .time-value {
        padding: 8px 14px;
        font-size: 16px;
    }
}

/* ========== SWIPE GESTURES ========== */

.swiped-left {
    animation: swipeLeftFeedback 0.3s ease-out;
}

.swiped-right {
    animation: swipeRightFeedback 0.3s ease-out;
}

@keyframes swipeLeftFeedback {
    0% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(-10px);
        box-shadow: 0 4px 20px rgba(239, 68, 68, 0.3);
    }
    100% {
        transform: translateX(0);
    }
}

@keyframes swipeRightFeedback {
    0% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(10px);
        box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
    }
    100% {
        transform: translateX(0);
    }
}

/* ========== PARTICLE EFFECTS ========== */

@keyframes confetti-fall {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

@keyframes particleBurst {
    0% {
        transform: translate(0, 0) scale(1) translateZ(0);
        opacity: 1;
    }
    100% {
        transform: translate(
            calc(var(--end-x) - var(--start-x, 0px)), 
            calc(var(--end-y) - var(--start-y, 0px))
        ) scale(0) translateZ(0);
        opacity: 0;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* ========== CIRCULAR SWAPS ========== */

/* Карточка инструкции */
.instruction-card {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid rgba(245, 158, 11, 0.3);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
    animation: fadeInScale 0.5s ease-out;
}

.instruction-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.instruction-step {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 16px;
    transition: all 0.3s ease;
    animation: fadeInScale 0.4s ease-out backwards;
}

.instruction-step:nth-child(1) { animation-delay: 0.1s; }
.instruction-step:nth-child(2) { animation-delay: 0.2s; }
.instruction-step:nth-child(3) { animation-delay: 0.3s; }
.instruction-step:nth-child(4) { animation-delay: 0.4s; }

.instruction-step:hover {
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.2);
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.step-content {
    flex: 1;
    min-width: 0;
    overflow: visible;
}

.step-title {
    font-weight: 700;
    font-size: 15px;
    color: #1f2937;
    margin-bottom: 6px;
    line-height: 1.4;
}

.step-description {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.circular-info {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border: 2px solid rgba(59, 130, 246, 0.2);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
    animation: fadeInScale 0.5s ease-out;
}

.example-label {
    font-weight: 600;
    font-size: 14px;
    color: #374151;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.info-icon {
    font-size: 32px;
    animation: pulse 2s ease-in-out infinite;
}

.info-header h3 {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
    color: #1f2937;
}

.circular-info p {
    color: #374151;
    line-height: 1.6;
    margin-bottom: 20px;
}

/* Пример цепочки */
.example-chain-wrapper {
    overflow: hidden;
    border-radius: 16px;
    margin: 20px 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    padding: 20px 0;
}

.example-chain {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 20px;
    width: max-content;
}

/* Автоматическая плавная прокрутка */
@keyframes smoothScroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.example-chain.auto-scroll {
    animation: smoothScroll 20s linear infinite;
}

.example-chain-wrapper:hover .example-chain.auto-scroll {
    animation-play-state: paused;
}

/* Для мобильных */
@media (max-width: 480px) {
    .instruction-step {
        padding: 14px;
        gap: 12px;
    }
    
    .step-number {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    
    .step-title {
        font-size: 14px;
    }
    
    .step-description {
        font-size: 12px;
        line-height: 1.4;
    }
    
    .example-chain-wrapper {
        padding: 16px 0;
    }
    
    .example-chain {
        gap: 6px;
        padding: 0 16px;
    }
    
    .chain-step {
        min-width: 100px;
        gap: 8px;
    }
    
    .chain-avatar {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .chain-name {
        font-size: 13px;
    }
    
    .chain-shift {
        font-size: 11px;
    }
    
    .chain-arrow {
        font-size: 20px;
        min-width: 24px;
    }
    
    .example-chain.auto-scroll {
        animation-duration: 15s;
    }
}

.chain-step {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    min-width: 120px;
    animation: fadeInScale 0.4s ease-out backwards;
    flex-shrink: 0;
}

.chain-step:nth-child(1) { animation-delay: 0.1s; }
.chain-step:nth-child(3) { animation-delay: 0.2s; }
.chain-step:nth-child(5) { animation-delay: 0.3s; }

.chain-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    flex-shrink: 0;
    overflow: hidden;
    position: relative;
}

.chain-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.chain-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.chain-name {
    font-weight: 600;
    font-size: 14px;
    color: #1f2937;
    white-space: nowrap;
}

.chain-shift {
    font-size: 12px;
    color: #6b7280;
    white-space: nowrap;
}

.chain-arrow {
    font-size: 24px;
    color: #3b82f6;
    font-weight: bold;
    animation: slideRight 1s ease-in-out infinite;
    flex-shrink: 0;
    min-width: 32px;
    text-align: center;
}

.chain-arrow-return {
    animation: rotate 2s linear infinite;
}

@keyframes slideRight {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(5px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Правила */
.info-rules {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 16px;
    padding: 16px;
    background: rgba(16, 185, 129, 0.08);
    border-radius: 12px;
    border-left: 4px solid #10b981;
}

.rule-item {
    font-size: 14px;
    color: #065f46;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Секция поиска */
.search-section {
    margin-bottom: 24px;
}

.search-hint {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, rgba(37, 99, 235, 0.05) 100%);
    border-left: 4px solid #3b82f6;
    padding: 16px 20px;
    border-radius: 12px;
    margin-bottom: 16px;
    font-size: 14px;
    color: #374151;
    line-height: 1.6;
    animation: fadeInScale 0.5s ease-out;
}

.search-hint strong {
    color: #1f2937;
    font-weight: 700;
}

/* Кнопка поиска */
.btn-search-circular {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 17px;
    padding: 18px;
    width: 100%;
}

.btn-search-circular span:first-child {
    font-size: 24px;
    animation: pulse 2s ease-in-out infinite;
}

/* Карточка цепочки */
.circular-chain-card {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 97%, #10b981 3%) 100%);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 
        0 4px 20px rgba(0, 0, 0, 0.08),
        0 1px 3px rgba(0, 0, 0, 0.05);
    border: 2px solid rgba(16, 185, 129, 0.2);
    animation: fadeInScale 0.5s ease-out backwards;
    position: relative;
    overflow: hidden;
}

.circular-chain-card::before {
    content: '🔄';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 48px;
    opacity: 0.1;
    animation: rotate 10s linear infinite;
}

.chain-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.chain-badge {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.chain-score {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    font-weight: 600;
}

.chain-participants {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.participant-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px;
    position: relative;
}

.participant-item::before {
    content: attr(data-position);
    position: absolute;
    left: -8px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: white;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.participant-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
    overflow: hidden;
    position: relative;
}

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

.participant-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.participant-info {
    flex: 1;
}

.participant-name {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 4px;
}

.participant-swap {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    display: flex;
    align-items: center;
    gap: 6px;
}

.swap-arrow {
    color: #10b981;
    font-weight: bold;
}

/* Кнопки действий для цепочки */
.chain-actions {
    display: flex;
    gap: 12px;
}

.btn-accept-chain {
    flex: 1;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 14px;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-accept-chain:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
}

.btn-details-chain {
    padding: 14px 20px;
    background: var(--tg-theme-secondary-bg-color);
    color: var(--tg-theme-link-color);
    border: none;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Статус подтверждения */
.confirmation-status {
    margin-top: 16px;
    padding: 12px;
    background: rgba(251, 191, 36, 0.1);
    border-radius: 12px;
    border-left: 4px solid #f59e0b;
}

.confirmation-progress {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #92400e;
    font-weight: 600;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: rgba(251, 191, 36, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #f59e0b 0%, #d97706 100%);
    transition: width 0.5s ease;
    border-radius: 4px;
}

/* Empty state */
.circular-empty {
    text-align: center;
    padding: 60px 24px;
    animation: fadeIn 0.5s ease-out;
}

.circular-empty-icon {
    font-size: 80px;
    margin-bottom: 16px;
    animation: float 3s ease-in-out infinite;
}

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

.circular-empty h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--tg-theme-text-color);
}

.circular-empty p {
    color: var(--tg-theme-hint-color);
    line-height: 1.6;
}

/* Dark theme для круговых обменов */
.dark-theme .info-header h3 {
    color: var(--tg-theme-text-color);
}

.dark-theme .search-hint {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.1) 100%);
    border-left-color: #3b82f6;
    color: var(--tg-theme-text-color);
}

.dark-theme .search-hint strong {
    color: var(--tg-theme-text-color);
}

.dark-theme .instruction-card {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(217, 119, 6, 0.15) 100%);
    border-color: rgba(245, 158, 11, 0.4);
}

.dark-theme .instruction-step {
    background: rgba(255, 255, 255, 0.08);
}

.dark-theme .step-title {
    color: var(--tg-theme-text-color);
}

.dark-theme .step-description {
    color: var(--tg-theme-hint-color);
}

.dark-theme .circular-info {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.1) 100%);
    border-color: rgba(59, 130, 246, 0.3);
}

.dark-theme .circular-info p {
    color: var(--tg-theme-text-color);
}

.dark-theme .example-label {
    color: var(--tg-theme-text-color);
}

.dark-theme .example-chain-wrapper {
    background: rgba(0, 0, 0, 0.3);
}

.dark-theme .chain-name {
    color: var(--tg-theme-text-color);
}

.dark-theme .chain-shift {
    color: var(--tg-theme-hint-color);
}

.dark-theme .info-rules {
    background: rgba(16, 185, 129, 0.15);
    border-left-color: #10b981;
}

.dark-theme .rule-item {
    color: #6ee7b7;
}

.dark-theme .circular-chain-card {
    background: linear-gradient(135deg, 
        var(--tg-theme-secondary-bg-color) 0%, 
        color-mix(in srgb, var(--tg-theme-secondary-bg-color) 95%, #10b981 5%) 100%);
}

.dark-theme .participant-item {
    background: rgba(255, 255, 255, 0.08);
}

.dark-theme .participant-name {
    color: var(--tg-theme-text-color);
}

.dark-theme .participant-swap {
    color: var(--tg-theme-hint-color);
}

.dark-theme .confirmation-status {
    background: rgba(251, 191, 36, 0.15);
    border-left-color: #fbbf24;
}

.dark-theme .confirmation-progress {
    color: #fcd34d;
}

/* 5. IMPROVED EMPTY STATES */
.empty-state {
    text-align: center;
    padding: 48px 24px;
    animation: fadeIn 0.5s ease-out;
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 16px;
    opacity: 0.5;
    animation: float 3s ease-in-out infinite;
}

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

.empty-state-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--tg-theme-text-color);
}

.empty-state-description {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    margin-bottom: 24px;
    line-height: 1.6;
}

.empty-state-action {
    margin-top: 24px;
}

/* Empty state варианты */
.empty-state.no-requests {
    background: linear-gradient(135deg, rgba(36, 129, 204, 0.05) 0%, transparent 100%);
    border-radius: 12px;
}

.empty-state.no-responses {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, transparent 100%);
    border-radius: 12px;
}

.empty-state.error {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05) 0%, transparent 100%);
    border-radius: 12px;
}

/* 6. ENHANCED LOADING STATES */
.loading {
    text-align: center;
    padding: 32px;
    color: var(--tg-theme-hint-color);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    margin: 0 auto 16px;
    border: 3px solid var(--tg-theme-secondary-bg-color);
    border-top-color: var(--tg-theme-button-color);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 7. ENHANCED BUTTONS */
.btn, .btn-primary, .btn-secondary, .btn-danger, .btn-cancel {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateY(0);
}

.btn:active, .btn-primary:active, .btn-secondary:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn:hover:not(:disabled), .btn-primary:hover:not(:disabled) {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Disabled state */
.btn:disabled, .btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* 8. SMOOTH SCROLL */
html {
    scroll-behavior: smooth;
}

/* 9. ENHANCED CARDS */
.request-card, .response-card, .profile-card, .nav-button {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.request-card:active, .nav-button:active {
    transform: scale(0.98);
}

/* 10. MICRO-INTERACTIONS */
.badge:hover {
    transform: translateY(-1px);
}

/* Pulse animation для новых элементов */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* Success animation */
@keyframes success-bounce {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.success-bounce {
    animation: success-bounce 0.5s ease;
}

/* ============================================
   🔄 PULL TO REFRESH
   ============================================ */

.pull-to-refresh-indicator {
    position: absolute;
    top: -80px;
    left: 0;
    right: 0;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 1000;
}

.ptr-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.ptr-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ptr-icon svg {
    fill: var(--tg-theme-button-color);
    transition: transform 0.3s ease;
}

.ptr-text {
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    font-weight: 500;
}

.ptr-spinner {
    width: 32px;
    height: 32px;
}

.ptr-spinner .loading-spinner {
    width: 24px;
    height: 24px;
    border-width: 2px;
}

/* ============================================
   📱 BOTTOM TAB BAR & NAVIGATION
   ============================================ */

/* Bottom Tab Bar */
.bottom-tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--tg-theme-bg-color);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-around;
    padding: 8px max(12px, env(safe-area-inset-left)) max(8px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-right));
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
}

.tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    text-decoration: none;
    color: var(--tg-theme-hint-color);
    transition: all 0.2s ease;
    position: relative;
    padding: 8px 4px;
    border-radius: 12px;
    min-width: 60px;
    max-width: 80px;
}

.tab-item:active {
    transform: scale(0.95);
    background: var(--tg-theme-secondary-bg-color);
}

.tab-icon {
    font-size: 24px;
    margin-bottom: 2px;
    transition: transform 0.2s ease;
}

.tab-label {
    font-size: 11px;
    font-weight: 500;
    margin-top: 2px;
}

.tab-item.active {
    color: var(--tg-theme-button-color);
}

.tab-item.active .tab-icon {
    transform: scale(1.1);
}

/* Badge на tab */
.tab-item .badge {
    position: absolute;
    top: 4px;
    right: 8px;
    min-width: 18px;
    height: 18px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    border-radius: 9px;
    font-size: 11px;
    font-weight: var(--font-weight-semibold);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.tab-item .badge.badge-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

/* Отступ для контента, чтобы не перекрывался tab bar */
body.has-tab-bar .container {
    padding-bottom: 100px;
    min-height: calc(100vh - 60px);
}

/* Секция откликов должна прокручиваться */
#responsesSection {
    margin-top: 24px;
    margin-bottom: 20px;
}

#responsesContainer {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* ============================================
   🔍 ФИЛЬТРЫ
   ============================================ */

/* Search Container */
.search-container {
    margin-bottom: 16px;
    animation: slideUp 0.3s ease;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 16px;
    font-size: 18px;
    pointer-events: none;
    color: var(--tg-theme-hint-color);
}

.search-input {
    width: 100%;
    padding: 14px 48px 14px 48px;
    background: var(--tg-theme-secondary-bg-color);
    border: 2px solid transparent;
    border-radius: 12px;
    font-size: 16px;
    color: var(--tg-theme-text-color);
    outline: none;
    transition: all 0.3s ease;
}

.search-input:focus {
    border-color: var(--tg-theme-button-color);
    background: var(--tg-theme-bg-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.search-input::placeholder {
    color: var(--tg-theme-hint-color);
}

.search-clear-btn {
    position: absolute;
    right: 12px;
    width: 24px;
    height: 24px;
    background: var(--tg-theme-hint-color);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    transition: all 0.2s ease;
}

.search-clear-btn:hover {
    background: var(--tg-theme-text-color);
}

.search-clear-btn:active {
    transform: scale(0.9);
}

.filters-container {
    background: var(--tg-theme-secondary-bg-color);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    animation: slideUp 0.3s ease;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.filters-title {
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-badge {
    background: var(--tg-theme-button-color);
    color: var(--tg-theme-button-text-color);
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
}

.clear-filters-btn {
    background: none;
    border: none;
    color: var(--tg-theme-link-color);
    font-size: 13px;
    padding: 4px 8px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.clear-filters-btn:active {
    background: rgba(0, 0, 0, 0.05);
}

.filters-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 12px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.filter-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--tg-theme-hint-color);
}

.filter-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    font-size: 14px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23999' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 32px;
}

.filter-select:focus {
    outline: none;
    border-color: var(--tg-theme-button-color);
    box-shadow: 0 0 0 3px rgba(36, 129, 204, 0.1);
}

/* Стили для option и optgroup в filter-select */
.filter-select option {
    padding: 8px 12px;
    background: var(--tg-theme-bg-color);
    color: var(--tg-theme-text-color);
    font-size: 13px;
    font-weight: 400;
    line-height: 1.4;
}

.filter-select optgroup {
    font-weight: 600;
    font-size: 11px;
    color: var(--tg-theme-hint-color);
    font-style: normal;
    padding: 6px 12px;
    background: var(--tg-theme-secondary-bg-color);
}

.filter-select:active {
    transform: scale(0.98);
}

/* Адаптивные стили для фильтров */
@media (max-width: 768px) {
    .filters-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .filters-container {
        padding: 12px;
    }
    
    .filters-grid {
        gap: 10px;
    }
    
    .filter-label {
        font-size: 12px;
    }
    
    .filter-select {
        padding: 8px 10px;
        font-size: 13px;
    }
}

/* Результаты фильтрации */
.filter-results {
    text-align: center;
    padding: 12px;
    background: linear-gradient(135deg, rgba(36, 129, 204, 0.1) 0%, rgba(36, 129, 204, 0.05) 100%);
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    color: var(--tg-theme-hint-color);
    animation: fadeIn 0.3s ease;
}

.filter-results strong {
    color: var(--tg-theme-button-color);
    font-weight: 600;
}

/* Match badge для совместимых запросов */
.perfect-match-badge,
.compatibility-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    margin-left: auto;
    white-space: nowrap;
    min-width: fit-content;
    height: 22px;
    line-height: 1;
}

.perfect-match-badge {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

.compatibility-badge {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

/* Информационная кнопка */
.info-button {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--tg-theme-text-color);
}

.info-button:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.3);
    transform: scale(1.05);
}

.info-button:active {
    transform: scale(0.95);
}

body.dark-theme .info-button {
    background: rgba(96, 165, 250, 0.12);
    border-color: rgba(96, 165, 250, 0.25);
}

body.dark-theme .info-button:hover {
    background: rgba(96, 165, 250, 0.18);
    border-color: rgba(96, 165, 250, 0.35);
}

/* Аватары пользователей */
.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.user-avatar.large {
    width: 64px;
    height: 64px;
    font-size: 24px;
}

/* Цвета для аватаров (генерируются по первой букве имени) */
.avatar-color-1 { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.avatar-color-2 { background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%); }
.avatar-color-3 { background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%); }
.avatar-color-4 { background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%); }
.avatar-color-5 { background: linear-gradient(135deg, #fa709a 0%, #fee140 100%); }
.avatar-color-6 { background: linear-gradient(135deg, #30cfd0 0%, #330867 100%); }
.avatar-color-7 { background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%); }
.avatar-color-8 { background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%); }
.avatar-color-9 { background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%); }
.avatar-color-0 { background: linear-gradient(135deg, #ff6e7f 0%, #bfe9ff 100%); }

/* ============================================
   Таймер времени жизни данных
   ============================================ */

.lifetime-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    margin-top: 8px;
    transition: all 0.3s ease;
}

.lifetime-badge.lifetime-active {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.lifetime-badge.lifetime-expiring {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
    animation: pulse 2s ease-in-out infinite;
}

.lifetime-badge.lifetime-expired {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
}

.lifetime-icon {
    font-size: 16px;
    line-height: 1;
}

.lifetime-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.lifetime-label {
    font-size: 10px;
    opacity: 0.9;
    font-weight: 400;
}

.lifetime-timer {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* Прогресс-бар времени жизни */
.lifetime-progress {
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 12px;
}

.dark-theme .lifetime-progress {
    background: rgba(255, 255, 255, 0.1);
}

.lifetime-progress-bar {
    height: 100%;
    transition: width 0.3s ease;
    border-radius: 2px;
}

/* Компактный вариант для карточек */
.lifetime-badge.compact {
    padding: 4px 8px;
    font-size: 11px;
    gap: 4px;
}

.lifetime-badge.compact .lifetime-icon {
    font-size: 14px;
}

.lifetime-badge.compact .lifetime-text {
    flex-direction: row;
    gap: 4px;
    align-items: center;
}

.lifetime-badge.compact .lifetime-label {
    display: none;
}

/* Тултип для детальной информации */
.lifetime-badge[title] {
    cursor: help;
}

/* Анимация пульсации для истекающих данных */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

/* ============================================
   Страница правил обмена
   ============================================ */

.rules-container {
    padding: 16px;
}

.rules-section {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    display: flex;
    gap: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.rules-section.rules-important {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
}

.dark-theme .rules-section.rules-important {
    background: linear-gradient(135deg, #78350f 0%, #92400e 100%);
    border-color: #f59e0b;
}

.rules-section.rules-how-it-works {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
}

.dark-theme .rules-section.rules-how-it-works {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
}

.rules-section.rules-faq {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
}

.dark-theme .rules-section.rules-faq {
    background: linear-gradient(135deg, #581c87 0%, #6b21a8 100%);
}

.rules-icon {
    font-size: 36px;
    line-height: 1;
    flex-shrink: 0;
}

.rules-content {
    flex: 1;
}

.rules-content h2 {
    margin: 0 0 12px 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.rules-content p {
    margin: 0 0 12px 0;
    line-height: 1.6;
    color: var(--text-secondary);
}

.rules-content p:last-child {
    margin-bottom: 0;
}

/* Примеры */
.rules-example {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.example-good,
.example-bad {
    display: flex;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    align-items: flex-start;
}

.example-good {
    background: rgba(16, 185, 129, 0.1);
    border-left: 3px solid #10b981;
}

.example-bad {
    background: rgba(239, 68, 68, 0.1);
    border-left: 3px solid #ef4444;
}

.example-icon {
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1.5;
}

.example-good strong,
.example-bad strong {
    display: block;
    margin-bottom: 4px;
    font-size: 14px;
}

.example-good p,
.example-bad p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
}

/* Пояснения */
.rules-explanation {
    margin-top: 16px;
    padding: 12px;
    background: rgba(59, 130, 246, 0.1);
    border-left: 3px solid #3b82f6;
    border-radius: 8px;
}

.rules-explanation strong {
    display: block;
    margin-bottom: 6px;
    color: #3b82f6;
    font-size: 14px;
}

.rules-explanation p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-secondary);
}

/* Часовые пояса */
.timezone-list {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.timezone-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-primary);
    border-radius: 8px;
    font-size: 14px;
}

.timezone-city {
    font-weight: 500;
}

.timezone-offset {
    color: var(--text-secondary);
    font-size: 13px;
}

/* Рабочий процесс */
.workflow-steps {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.workflow-step {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.step-number {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
}

.step-content strong {
    display: block;
    margin-bottom: 4px;
    font-size: 15px;
    color: var(--text-primary);
}

.step-content p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-secondary);
}

/* FAQ */
.faq-item {
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
}

.faq-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.faq-item strong {
    display: block;
    margin-bottom: 6px;
    font-size: 15px;
    color: var(--text-primary);
}

.faq-item p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Действия */
.rules-actions {
    margin-top: 24px;
    display: flex;
    justify-content: center;
    padding-bottom: 24px;
}

.btn-large {
    padding: 18px 40px;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border: none;
    border-radius: 16px;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-large::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-large:hover::before {
    width: 300px;
    height: 300px;
}

.btn-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.4);
}

.btn-large:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.dark-theme .btn-large {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.5);
}

.dark-theme .btn-large:hover {
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.6);
}

/* ============================================
   Баннер для незарегистрированных пользователей
   ============================================ */

.registration-banner {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    margin: 16px 0;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.2);
    animation: slideDown 0.4s ease-out;
}

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

.banner-icon {
    font-size: 32px;
    line-height: 1;
    flex-shrink: 0;
}

.banner-content {
    flex: 1;
}

.banner-content h3 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 700;
    color: #92400e;
}

.banner-content p {
    margin: 0 0 6px 0;
    font-size: 14px;
    line-height: 1.5;
    color: #78350f;
}

.banner-content p:last-child {
    margin-bottom: 0;
}

.banner-hint {
    font-weight: 600;
}

.banner-hint code {
    background: rgba(255, 255, 255, 0.5);
    padding: 2px 8px;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #92400e;
    font-weight: 700;
}

.banner-steps {
    margin: 12px 0;
    padding-left: 24px;
    list-style-type: decimal;
}

.banner-steps li {
    margin: 6px 0;
    font-size: 14px;
    line-height: 1.5;
    color: #78350f;
}

.banner-steps code {
    background: rgba(255, 255, 255, 0.5);
    padding: 2px 8px;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #92400e;
    font-weight: 700;
}

/* Темная тема */
.dark-theme .registration-banner {
    background: linear-gradient(135deg, #78350f 0%, #92400e 100%);
    border-color: #f59e0b;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.dark-theme .banner-content h3 {
    color: #fbbf24;
}

.dark-theme .banner-content p {
    color: #fde68a;
}

.dark-theme .banner-hint code {
    background: rgba(0, 0, 0, 0.3);
    color: #fbbf24;
}

.dark-theme .banner-steps li {
    color: #fde68a;
}

.dark-theme .banner-steps code {
    background: rgba(0, 0, 0, 0.3);
    color: #fbbf24;
}

/* ==================== RESPONSE CARDS IMPROVEMENTS ==================== */

/* Улучшенный header откликов */
.response-card .request-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.response-card .request-header-left {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    flex: 1;
    flex-wrap: wrap;
}

.response-card .request-id {
    font-size: 14px;
    font-weight: 600;
    color: var(--tg-theme-text-color);
    opacity: 0.8;
}

/* Кнопка удаления отклика */
.btn-delete-response {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    border: none;
    border-radius: 10px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
    flex-shrink: 0;
}

.btn-delete-response:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-delete-response:active {
    transform: translateY(0);
}

.btn-delete-response .delete-icon {
    font-size: 18px;
    display: block;
}

.btn-delete-response:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Кнопка отзыва отклика (для pending) */
.btn-withdraw {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.2);
    gap: 6px;
}

.btn-withdraw:hover {
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.btn-withdraw .delete-text {
    font-size: 13px;
    font-weight: 500;
    color: white;
    display: block;
}

.btn-withdraw .delete-icon {
    font-size: 16px;
}

/* Контактная информация */
.contact-info-box {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(37, 99, 235, 0.05) 100%);
    border: 2px solid rgba(59, 130, 246, 0.15);
    border-radius: 12px;
    padding: 16px;
    margin-top: 16px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 5;
}

.contact-info-box:hover {
    border-color: rgba(59, 130, 246, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
}

.contact-info-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.contact-info-header .contact-icon {
    font-size: 18px;
}

.contact-info-header strong {
    font-size: 14px;
    font-weight: 600;
    color: var(--tg-theme-text-color);
}

.contact-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background: var(--tg-theme-bg-color);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 10;
    cursor: pointer;
    pointer-events: auto;
}

.contact-link:hover {
    background: rgba(59, 130, 246, 0.05);
    border-color: rgba(59, 130, 246, 0.2);
}

.contact-name-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.contact-name {
    font-size: 15px;
    font-weight: 500;
    color: var(--tg-theme-link-color);
}

.contact-login {
    font-size: 12px;
    font-weight: 400;
    color: var(--tg-theme-hint-color);
    font-family: 'Courier New', monospace;
}

.contact-action {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    display: flex;
    flex-shrink: 0;
    align-items: center;
    gap: 4px;
}

.contact-hint {
    margin-top: 10px;
    font-size: 12px;
    color: var(--tg-theme-hint-color);
    padding: 8px;
    background: rgba(59, 130, 246, 0.05);
    border-radius: 6px;
    text-align: center;
}

/* Улучшенная типографика в откликах */
.response-card .request-section {
    margin-bottom: 14px;
}

.response-card .request-section strong {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--tg-theme-text-color);
    margin-bottom: 6px;
    opacity: 0.9;
}

.response-card .request-section p {
    font-size: 14px;
    line-height: 1.5;
    color: var(--tg-theme-text-color);
    margin: 0;
}

/* Бейджи статусов */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 3px 10px;
    border-radius: var(--radius-sm);
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    white-space: nowrap;
    height: 22px;
    line-height: 1;
    min-width: fit-content;
}

.badge-warning {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #78350f;
    box-shadow: 0 2px 4px rgba(251, 191, 36, 0.3);
}

.badge-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.3);
}

.badge-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.3);
}

.badge-secondary {
    background: rgba(0, 0, 0, 0.1);
    color: var(--tg-theme-hint-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Dark theme для откликов */
.dark-theme .contact-info-box {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12) 0%, rgba(37, 99, 235, 0.08) 100%);
    border-color: rgba(59, 130, 246, 0.2);
}

.dark-theme .contact-link {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.dark-theme .contact-link:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
}

.dark-theme .contact-hint {
    background: rgba(59, 130, 246, 0.08);
}

/* Адаптивность */
@media (max-width: 480px) {
    .btn-delete-response {
        padding: 6px 10px;
    }
    
    .btn-delete-response .delete-icon {
        font-size: 16px;
    }
    
    .contact-info-box {
        padding: 12px;
    }
    
    .contact-link {
        padding: 10px;
    }
    
    .contact-name {
        font-size: 14px;
    }
    
    .contact-action {
        font-size: 12px;
    }
}

/* ========== PRIVACY WARNING CARD ========== */
.privacy-warning-card {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.1) 0%, rgba(245, 158, 11, 0.05) 100%);
    border: 2px solid rgba(251, 191, 36, 0.3);
    border-radius: 16px;
    padding: 20px;
    margin: 20px 0;
    display: flex;
    gap: 16px;
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.1);
    animation: fadeInUp 0.5s ease-out;
}

.privacy-warning-icon {
    font-size: 48px;
    flex-shrink: 0;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.privacy-warning-content {
    flex: 1;
}

.privacy-warning-title {
    font-size: 18px;
    font-weight: 700;
    color: #d97706;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.privacy-warning-text {
    font-size: 14px;
    color: var(--tg-theme-text-color);
    margin-bottom: 16px;
    line-height: 1.5;
}

.privacy-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.privacy-step {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.step-number {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.step-content {
    flex: 1;
}

.step-content strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--tg-theme-text-color);
    margin-bottom: 4px;
}

.step-content p {
    font-size: 13px;
    color: var(--tg-theme-hint-color);
    margin: 0;
    line-height: 1.4;
}

.step-content code {
    background: rgba(0, 0, 0, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-family: 'Courier New', monospace;
    color: #d97706;
    font-weight: 600;
}

.privacy-warning-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: rgba(251, 191, 36, 0.08);
    border-radius: 8px;
    font-size: 13px;
    color: var(--tg-theme-text-color);
}

.privacy-icon-check {
    font-size: 16px;
}

/* Dark theme для privacy warning */
.dark-theme .privacy-warning-card {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.15) 0%, rgba(245, 158, 11, 0.08) 100%);
    border-color: rgba(251, 191, 36, 0.4);
}

.dark-theme .privacy-warning-footer {
    background: rgba(251, 191, 36, 0.12);
}

.dark-theme .step-content code {
    background: rgba(255, 255, 255, 0.1);
    color: #fbbf24;
}

/* Адаптивность */
@media (max-width: 768px) {
    .privacy-warning-card {
        flex-direction: column;
        padding: 16px;
    }
    
    .privacy-warning-icon {
        font-size: 36px;
        text-align: center;
    }
    
    .privacy-warning-title {
        font-size: 16px;
    }
    
    .step-content strong {
        font-size: 13px;
    }
    
    .step-content p {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .privacy-warning-card {
        padding: 12px;
        margin: 12px 0;
    }
    
    .privacy-warning-title {
        font-size: 15px;
    }
    
    .privacy-steps {
        gap: 10px;
    }
    
    .step-number {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }
}

/* ========================================
   REQUEST CARDS - Компактный профессиональный дизайн
   ======================================== */

.request-card {
    background: var(--tg-theme-bg-color);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(var(--tg-theme-hint-color-rgb, 153, 153, 153), 0.1);
    position: relative;
    overflow: hidden;
}

.request-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    transition: width 0.3s ease;
}

.request-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.request-card:hover::before {
    width: 4px;
}

.request-card:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.dark-theme .request-card {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

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

.request-author {
    font-weight: 600;
    font-size: 16px;
    letter-spacing: -0.015em;
    line-height: 1.3;
    color: var(--tg-theme-text-color);
    margin-bottom: 2px;
}

.request-date {
    font-size: 12px;
    color: var(--tg-theme-hint-color);
    opacity: 0.8;
}

.request-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 12px;
}

.request-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.request-section strong {
    display: block;
    margin-bottom: 8px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    opacity: 1;
    color: #666;
}

.dark-theme .request-section strong {
    color: #999;
}

.request-section p {
    font-size: 15px;
    line-height: 1.55;
    font-weight: 450;
    letter-spacing: -0.01em;
    color: var(--tg-theme-text-color);
    margin: 0;
}

.date-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.date-list-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 14px;
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.04);
    border-radius: 10px;
    gap: 6px;
    border: 1px solid rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.08);
    transition: all 0.2s ease;
    line-height: 1.5;
}

.date-list-item:hover {
    background: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.06);
    border-color: rgba(var(--tg-theme-hint-color-rgb, 128, 128, 128), 0.12);
}

.date-text {
    font-weight: 500;
    font-size: 15px;
    letter-spacing: -0.01em;
    line-height: 1.4;
    color: var(--tg-theme-text-color);
}

.time-text {
    font-size: 13px;
    font-weight: 450;
    line-height: 1.4;
    letter-spacing: -0.005em;
    color: var(--tg-theme-hint-color);
}

.request-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    width: 100%;
}

.request-city,
.request-schedule {
    flex: 1;
    padding: 6px 10px;
    background: rgba(59, 130, 246, 0.08);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    color: var(--tg-theme-text-color);
    letter-spacing: -0.005em;
    border: 1px solid rgba(59, 130, 246, 0.12);
    transition: all 0.2s ease;
}

.dark-theme .request-city,
.dark-theme .request-schedule {
    background: rgba(96, 165, 250, 0.15);
    border-color: rgba(96, 165, 250, 0.25);
}

.request-city:hover,
.request-schedule:hover {
    background: rgba(59, 130, 246, 0.12);
    border-color: rgba(59, 130, 246, 0.2);
}

/* Бейджи совместимости */
.perfect-match-badge,
.compatibility-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    height: 22px;
    line-height: 1;
    margin-left: auto;
}

.perfect-match-badge {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.compatibility-badge {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

/* Новые бейджи совместимости для подходящих запросов */
.badge-perfect {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
    height: 22px;
}

.badge-good-for-you {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25);
    height: 22px;
}

.badge-good-for-them {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.25);
    height: 22px;
}

/* Другие бейджи */
.badge-success,
.badge-warning,
.badge-danger,
.badge-pending,
.badge-accepted,
.badge-rejected,
.badge-new {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    height: 22px;
    line-height: 1;
    margin-left: auto;
}

.badge-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.badge-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.25);
}

.badge-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.25);
}

.badge-pending {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    box-shadow: 0 2px 6px rgba(59, 130, 246, 0.25);
}

.badge-accepted {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.badge-rejected {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.25);
}

.badge-new {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
    box-shadow: 0 2px 6px rgba(139, 92, 246, 0.25);
}

/* Улучшенная типографика */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Адаптивность для карточек */
@media (max-width: 768px) {
    .request-card {
        padding: 14px;
        margin-bottom: 10px;
    }
    
    .request-author {
        font-size: 15px;
    }
    
    .request-section p {
        font-size: 14px;
    }
    
    .date-list-item {
        padding: 10px 12px;
    }
}

/* ========================================
   Toggle Switch (для настроек уведомлений)
   ======================================== */

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 28px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--tg-theme-button-color, #3b82f6);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(22px);
}

.toggle-switch input:disabled + .toggle-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===== Apple-style Header ===== */
.apple-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    position: sticky;
    top: 0;
    background: var(--tg-theme-bg-color);
    z-index: 1000;
    border-bottom: 1px solid rgba(128, 128, 128, 0.1);
    margin: -16px -16px 16px -16px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.apple-header .back-link {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--tg-theme-link-color, #007AFF);
    text-decoration: none;
    font-size: 17px;
    font-weight: 400;
    padding: 8px 12px;
    margin: -8px -12px;
    transition: opacity 0.2s;
    min-width: 80px;
    position: relative;
    z-index: 10;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.apple-header .back-link:active {
    opacity: 0.6;
}

.apple-header .back-link svg {
    flex-shrink: 0;
    pointer-events: none;
}

.apple-header h1 {
    font-size: 17px;
    font-weight: 600;
    margin: 0;
    text-align: center;
    flex: 1;
    pointer-events: none;
}

.apple-header .header-action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    color: var(--tg-theme-link-color, #007AFF);
    cursor: pointer;
    border-radius: 50%;
    transition: background 0.2s;
    min-width: 44px;
    position: relative;
    z-index: 10;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.apple-header .header-action-btn svg {
    pointer-events: none;
}

.apple-header .header-action-btn:active {
    background: rgba(128, 128, 128, 0.15);
}

.apple-header .header-spacer {
    width: 44px;
    flex-shrink: 0;
}


