
/* === ROOT VARIABLES === */
:root {
--primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
--secondary-gradient: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
--success-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%);
--warning-gradient: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
--success-gradient-2: linear-gradient(190deg, #10b981 0%, #059669 100%);

--primary-color: #6366f1;
--secondary-color: #8b5cf6;
--accent-color: #10b981;
--text-dark: #1f2937;
--text-light: #6b7280;
--text-muted: #9ca3af;
--white: #ffffff;
--background-light: #f9fafb;
--background-dark: #1f2937;
--shadow-light: rgba(99, 102, 241, 0.1);
--shadow-medium: rgba(99, 102, 241, 0.2);
--shadow-heavy: rgba(99, 102, 241, 0.3);

--border-radius: 16px;
--border-radius-large: 24px;
--spacing-xs: 4px;
--spacing-sm: 8px;
--spacing-md: 16px;
--spacing-lg: 24px;
--spacing-xl: 32px;
--spacing-xxl: 48px;

--transition-fast: 0.2s ease;
--transition-medium: 0.3s ease;
--transition-slow: 0.5s ease;
--animation-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

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

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

html {
height: 100%;
overflow-x: hidden;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
scroll-behavior: smooth;
}

body {
font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
height: 100vh;
background: var(--primary-gradient);
overflow-x: hidden;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
touch-action: manipulation;
line-height: 1.6;
color: var(--text-dark);
}

/* === КОНТЕЙНЕР === */
.container {
width: 100%;
max-width: 800px;
margin: 0 auto;
height: 100vh;
display: flex;
flex-direction: column;
background: rgba(255, 255, 255, 0.98);
backdrop-filter: blur(20px);
box-shadow: 0 0 60px var(--shadow-heavy);
position: relative;
overflow: hidden;
}

.container::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
height: 3px;
background: var(--success-gradient);
z-index: 1000;
}

ul {
    margin-left: 20px;
}

/* === ЗАСТАВКА === */
.splash-screen {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100vh;
background: var(--primary-gradient);
display: flex;
align-items: center;
justify-content: center;
z-index: 10000;
transition: all 1s ease-out;
}

.splash-screen.hidden {
opacity: 0;
pointer-events: none;
transform: scale(1.1);
}

.splash-content {
text-align: center;
color: white;
animation: splashAnimation 1.2s var(--animation-bounce);
max-width: 90%;
margin: 0 auto;
}

.splash-title {
background: rgba(255, 255, 255, 0.15);
backdrop-filter: blur(15px);
border: 1px solid rgba(255, 255, 255, 0.3);
border-radius: var(--border-radius) var(--border-radius) 0 0;
padding: var(--spacing-md) var(--spacing-lg);
font-size: 14px;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 2px;
margin-bottom: 0;
position: relative;
overflow: hidden;
white-space: nowrap;
}

.splash-title::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
);
animation: shimmer 2s infinite;
}

.splash-name {
background: rgba(255, 255, 255, 0.2);
backdrop-filter: blur(15px);
border: 1px solid rgba(255, 255, 255, 0.3);
border-top: none;
border-radius: 0 0 var(--border-radius) var(--border-radius);
padding: var(--spacing-xl) var(--spacing-lg);
font-family: "Poppins", sans-serif;
font-size: 28px;
font-weight: 800;
line-height: 1.2;
text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
word-break: keep-all;
}

/* === HEADER === */
.header {
background: rgba(255, 255, 255, 0.95);
backdrop-filter: blur(20px);
border-bottom: 1px solid var(--shadow-light);
padding: var(--spacing-md) var(--spacing-lg);
flex-shrink: 0;
position: sticky;
top: 0;
z-index: 100;
transition: all var(--transition-medium);
}

.header.scrolled {
box-shadow: 0 4px 20px var(--shadow-light);
background: rgba(255, 255, 255, 0.98);
}

.header-content {
display: flex;
align-items: center;
justify-content: space-between;
gap: var(--spacing-md);
}

.doctor-info {
display: flex;
align-items: center;
gap: var(--spacing-md);
flex: 1;
}

.doctor-avatar {
width: 56px;
height: 56px;
border-radius: 50%;
overflow: hidden;
border: 3px solid transparent;
background: var(--secondary-gradient);
padding: 2px;
box-shadow: 0 8px 32px var(--shadow-medium);
animation: avatarPulse 3s infinite ease-in-out;
flex-shrink: 0;
position: relative;
}

.doctor-avatar::before {
content: "";
position: absolute;
inset: -3px;
border-radius: 50%;
background: var(--success-gradient);
z-index: -1;
animation: avatarGlow 2s infinite alternate;
}

.doctor-avatar img {
width: 100%;
height: 100%;
object-fit: cover;
display: block;
border-radius: 50%;
}

.doctor-details {
flex: 1;
min-width: 0;
}

.doctor-details h3 {
font-family: "Poppins", sans-serif;
font-size: 18px;
font-weight: 700;
color: var(--text-dark);
margin: 0;
}

.doctor-details__years {
    color: #1F2937;
    font-size: 12px;
    font-weight: 400;
    line-height: 133%;
    margin-top: 2px;
}

.online-status {
display: flex;
align-items: center;
gap: var(--spacing-sm);
margin-top: 2px;
}

.online-indicator {
width: 10px;
height: 10px;
background: var(--accent-color);
border-radius: 50%;
animation: onlinePulse 2s infinite;
box-shadow: 0 0 10px var(--accent-color);
}

.online-text {
font-size: 13px;
color: var(--accent-color);
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.5px;
}

.consultation-badge {
border: none;
cursor: pointer;
outline: none;
background: var(--success-gradient);
color: white;
padding: var(--spacing-sm) var(--spacing-md);
border-radius: var(--border-radius-large);
font-size: 10px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 1px;
box-shadow: 0 8px 32px rgba(6, 255, 165, 0.4);
white-space: nowrap;
position: relative;
overflow: hidden;
animation: badgeFloat 3s ease-in-out infinite;
display: flex;
align-items: center;
justify-content: center;
width: 54px;
transition: all 0.3s ease;
}

.consultation-badge:hover {
    background: var(--success-gradient-2);
}

.consultation-badge svg {
    /* margin-bottom: -5px; */
}

.consultation-badge::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
);
animation: shimmer 3s infinite;
}

/* === ЧАТ === */
.chat-container {
flex: 1;
overflow-y: auto;
padding: var(--spacing-lg);
scroll-behavior: smooth;
position: relative;
}

.chat-container::-webkit-scrollbar {
width: 6px;
}

.chat-container::-webkit-scrollbar-track {
background: transparent;
}

.chat-container::-webkit-scrollbar-thumb {
background: var(--secondary-gradient);
border-radius: 10px;
}

.chat-container::-webkit-scrollbar-thumb:hover {
background: var(--primary-gradient);
}

.timestamp {
text-align: center;
margin: var(--spacing-md) 0 var(--spacing-xl) 0;
}

.timestamp span {
background: var(--secondary-gradient);
color: white;
padding: var(--spacing-sm) var(--spacing-md);
border-radius: var(--border-radius);
font-size: 12px;
font-weight: 600;
box-shadow: 0 4px 20px var(--shadow-light);
position: relative;
overflow: hidden;
}

/* === СООБЩЕНИЯ === */
.message {
margin-bottom: var(--spacing-lg);
animation: messageSlideIn 0.6s var(--animation-bounce);
opacity: 0;
animation-fill-mode: forwards;
}

.message.doctor {
display: flex;
align-items: flex-start;
gap: var(--spacing-md);
}

.message.user {
display: flex;
justify-content: flex-end;
}

.message-avatar {
width: 44px;
height: 44px;
border-radius: 50%;
border: 2px solid var(--primary-color);
overflow: hidden;
flex-shrink: 0;
box-shadow: 0 4px 16px var(--shadow-light);
}

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

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

.doctor-name {
font-size: 12px;
color: var(--primary-color);
font-weight: 700;
margin-bottom: var(--spacing-xs);
text-transform: uppercase;
letter-spacing: 0.5px;
}

.message-bubble {
padding: var(--spacing-md) var(--spacing-lg);
border-radius: var(--border-radius);
font-size: 15px;
line-height: 1.7;
word-wrap: break-word;
position: relative;
transform: translateY(20px);
animation: bubbleAppear 0.5s var(--transition-medium) forwards;
}

.message-bubble.doctor {
background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
border: 1px solid var(--shadow-light);
border-radius: 0 var(--border-radius) var(--border-radius)
    var(--border-radius);
box-shadow: 0 8px 32px var(--shadow-light);
max-width: 85%;
color: var(--text-dark);
position: relative;
}

.message-bubble.doctor::before {
content: "";
position: absolute;
top: 0;
left: 0;
width: 4px;
height: 100%;
background: var(--primary-gradient);
border-radius: 2px 0 0 2px;
}

.message-bubble.user {
background: var(--primary-gradient);
color: white;
border-radius: var(--border-radius) 0 var(--border-radius)
    var(--border-radius);
max-width: 80%;
box-shadow: 0 8px 32px var(--shadow-medium);
margin-left: auto;
}

.message-time {
font-size: 11px;
color: var(--text-light);
margin-top: var(--spacing-sm);
font-weight: 500;
}

.message.user .message-time {
text-align: right;
}

/* === TYPING INDICATOR === */
.typing-indicator {
display: flex;
align-items: center;
gap: var(--spacing-sm);
padding: var(--spacing-md);
margin: var(--spacing-md) 0;
opacity: 0;
animation: fadeInUp 0.3s ease forwards;
}

.typing-dots {
display: flex;
gap: 4px;
}

.typing-dot {
width: 8px;
height: 8px;
background: var(--secondary-color);
border-radius: 50%;
animation: typingBounce 1.4s infinite ease-in-out;
}

.typing-dot:nth-child(1) {
animation-delay: -0.32s;
}
.typing-dot:nth-child(2) {
animation-delay: -0.16s;
}

/* === ИЗОБРАЖЕНИЯ === */
.before-after-image,
.product-image {
width: 100%;
max-width: 280px;
height: auto;
border-radius: var(--border-radius);
margin: var(--spacing-sm) 0;
box-shadow: 0 12px 40px var(--shadow-light);
object-fit: cover;
display: block;
transition: all var(--transition-medium);
cursor: pointer;
}

.before-after-image:hover,
.product-image:hover {
transform: translateY(-4px) scale(1.02);
box-shadow: 0 20px 60px var(--shadow-medium);
}

/* === КНОПКИ ВЫБОРА === */
.choice-buttons {
display: flex;
flex-direction: column;
gap: var(--spacing-sm);
align-items: flex-end;
margin: var(--spacing-lg) 0;
animation: fadeInUp 0.6s ease-out;
}

.choice-button {
background: var(--primary-gradient);
color: white;
border: none;
border-radius: var(--border-radius-large);
padding: var(--spacing-md) var(--spacing-lg);
cursor: pointer;
font-size: 14px;
font-weight: 600;
font-family: inherit;
transition: all var(--transition-medium);
box-shadow: 0 8px 32px var(--shadow-medium);
max-width: 85%;
min-height: 48px;
display: flex;
align-items: center;
justify-content: center;
text-align: center;
line-height: 1.4;
word-wrap: break-word;
position: relative;
overflow: hidden;
transform: translateX(20px);
opacity: 0;
animation: slideInRight 0.5s ease forwards;
}

.choice-button:nth-child(1) {
animation-delay: 0.1s;
}
.choice-button:nth-child(2) {
animation-delay: 0.2s;
}
.choice-button:nth-child(3) {
animation-delay: 0.3s;
}
.choice-button:nth-child(4) {
animation-delay: 0.4s;
}
.choice-button:nth-child(5) {
animation-delay: 0.5s;
}

.choice-button::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
);
transition: left 0.6s ease;
}

.choice-button:hover {
transform: translateY(-3px) scale(1.02);
box-shadow: 0 16px 48px var(--shadow-heavy);
}

.choice-button:hover::before {
left: 100%;
}

.choice-button:active {
transform: translateY(-1px) scale(0.98);
}

/* === РУЛЕТКА === */
.wheel-section {
text-align: center;
margin: var(--spacing-xl) 0;
padding: var(--spacing-lg);
position: relative;
}

.wheel-container {
position: relative;
display: inline-block;
margin: var(--spacing-lg) 0;
}

.wheel-image {
width: 300px;
height: 300px;
border-radius: 50%;
box-shadow: 0 20px 80px var(--shadow-medium);
transition: transform 3s cubic-bezier(0.23, 1, 0.32, 1);
background: conic-gradient(
    from 0deg,
    #ff6b6b 0deg 45deg,
    #4ecdc4 45deg 90deg,
    #45b7d1 90deg 135deg,
    #f9ca24 135deg 180deg,
    #f0932b 180deg 225deg,
    #eb4d4b 225deg 270deg,
    #6c5ce7 270deg 315deg,
    #a29bfe 315deg 360deg
);
position: relative;
animation: wheelIdle 4s ease-in-out infinite;
}

.wheel-image::before {
content: "";
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 90%;
height: 90%;
background: white;
border-radius: 50%;
z-index: 1;
box-shadow: inset 0 0 40px var(--shadow-light);
}

.spin-button {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background: white;
color: var(--text-dark);
border: 3px solid var(--secondary-color);
border-radius: 50%;
width: 120px;
height: 120px;
font-weight: 800;
font-size: 16px;
cursor: pointer;
box-shadow: 0 16px 48px var(--shadow-medium);
transition: all var(--transition-medium);
z-index: 10;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-family: "Poppins", sans-serif;
text-transform: uppercase;
letter-spacing: 1px;
}

.spin-button::before {
content: "";
position: absolute;
top: -20px;
left: 50%;
transform: translateX(-50%);
width: 0;
height: 0;
border-left: 15px solid transparent;
border-right: 15px solid transparent;
border-bottom: 20px solid var(--secondary-color);
z-index: 11;
}

.spin-button:hover {
transform: translate(-50%, -50%) scale(1.05);
box-shadow: 0 20px 60px var(--shadow-heavy);
border-color: var(--primary-color);
}

.spin-button:active {
transform: translate(-50%, -50%) scale(0.95);
}

.spin-button:disabled {
opacity: 0.7;
cursor: not-allowed;
transform: translate(-50%, -50%) scale(0.95);
}

/* === ПОПАП РУЛЕТКИ === */
.wheel-popup {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.8);
backdrop-filter: blur(10px);
display: none;
align-items: center;
justify-content: center;
z-index: 2000;
opacity: 0;
transition: all var(--transition-slow);
}

.wheel-popup.show {
display: flex;
opacity: 1;
}

.popup-content {
background: white;
border-radius: var(--border-radius-large);
padding: var(--spacing-xxl);
text-align: center;
max-width: 450px;
width: 90%;
box-shadow: 0 40px 120px rgba(0, 0, 0, 0.4);
animation: popupAppear 0.6s var(--animation-bounce);
position: relative;
overflow: hidden;
}

.popup-content::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
height: 4px;
background: var(--success-gradient);
}

.popup-close {
position: absolute;
top: var(--spacing-md);
right: var(--spacing-md);
width: 36px;
height: 36px;
cursor: pointer;
background: var(--background-light);
border-radius: 50%;
border: none;
display: flex;
align-items: center;
justify-content: center;
font-size: 20px;
line-height: 1;
transition: all var(--transition-fast);
color: var(--text-light);
display: none;
}

.popup-close:hover {
background: var(--shadow-light);
transform: scale(1.1);
}

.popup-title {
font-family: "Poppins", sans-serif;
font-size: 32px;
font-weight: 800;
background: var(--success-gradient);
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
margin-bottom: var(--spacing-md);
animation: titleGlow 2s ease-in-out infinite alternate;
}

.popup-text {
font-size: 18px;
color: var(--text-dark);
margin-bottom: var(--spacing-xl);
line-height: 1.8;
font-weight: 500;
}

.popup-button {
background: var(--success-gradient);
color: white;
border: none;
padding: var(--spacing-md) var(--spacing-xl);
border-radius: var(--border-radius);
font-size: 18px;
font-weight: 700;
cursor: pointer;
transition: all var(--transition-medium);
text-transform: uppercase;
letter-spacing: 1px;
font-family: "Poppins", sans-serif;
box-shadow: 0 8px 32px rgba(6, 255, 165, 0.4);
position: relative;
overflow: hidden;
}

.popup-button::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
);
transition: left 0.6s ease;
}

.popup-button:hover {
transform: translateY(-2px);
box-shadow: 0 16px 48px rgba(6, 255, 165, 0.6);
}

.popup-button:hover::before {
left: 100%;
}

/* === ФОРМА ЗАКАЗА === */
.order-form {
background: linear-gradient(135deg, #b8e6b8 0%, #7dd3fc 100%);
border-radius: 0;
padding: 0;
margin: var(--spacing-lg) 0 0 0;
box-shadow: none;
border: none;
position: relative;
width: 100%;
}

.order-form.hidden {
display: none !important;
}

.order-form.show * {
display: block !important;
visibility: visible !important;
opacity: 1 !important;
}

.order-form.show .timer-display {
display: flex !important;
}

.order-form.show .security-badges {
display: flex !important;
}

.order-form.show .form-input-new,
.order-form.show .submit-button-new {
display: block !important;
width: 100%;
max-width: 400px;
margin: 0 auto var(--spacing-md);
}

/* Верхняя панель с таймером */
.timer-header {
background: #1e3a8a;
color: white;
padding: var(--spacing-lg);
text-align: center;
position: relative;
overflow: hidden;
display: block;
width: 100%;
}

.timer-header::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
);
animation: shimmer 3s infinite;
}

.discount-text {
font-family: "Poppins", sans-serif;
font-size: 22px;
font-weight: 800;
margin-bottom: var(--spacing-sm);
text-transform: uppercase;
letter-spacing: 2px;
text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
animation: textPulse 2s ease-in-out infinite;
display: block;
}

.timer-label {
font-size: 16px;
margin-bottom: var(--spacing-md);
color: #fef08a;
font-weight: 600;
letter-spacing: 1px;
display: block;
}

.countdown-timer {
background: rgba(255, 255, 255, 0.1);
border: 2px solid #fef08a;
border-radius: var(--border-radius);
padding: var(--spacing-lg);
display: inline-block;
margin: 0 auto;
backdrop-filter: blur(10px);
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.timer-display {
display: flex;
justify-content: center;
align-items: center;
gap: var(--spacing-md);
}

.timer-unit {
text-align: center;
position: relative;
display: block;
}

.timer-number {
font-family: "Poppins", sans-serif;
font-size: 32px;
font-weight: 900;
line-height: 1;
display: block;
color: #fef08a;
text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
animation: numberFlip 1s ease-in-out;
}

.timer-label-small {
font-size: 12px;
text-transform: uppercase;
letter-spacing: 1px;
margin-top: var(--spacing-xs);
color: #fef08a;
font-weight: 600;
display: block;
}

.timer-separator {
font-size: 28px;
font-weight: 900;
color: #fef08a;
animation: separatorBlink 1s infinite;
display: block;
}

/* Основной контент формы */
.form-content {
padding: var(--spacing-xxl) var(--spacing-lg);
text-align: center;
max-width: 500px;
margin: 0 auto;
position: relative;
display: block;
width: 100%;
}

/* Изображение продукта */
.product-showcase {
position: relative;
margin-bottom: var(--spacing-xl);
animation: productFloat 6s ease-in-out infinite;
}

.product-image-new {
width: 300px;
max-width: 90%;
height: auto;
margin: 0 auto var(--spacing-lg);
display: block;
border-radius: var(--border-radius-large);
box-shadow: 0 20px 80px var(--shadow-medium);
transition: all var(--transition-medium);
}

.product-image-new:hover {
transform: scale(1.05) rotate(2deg);
box-shadow: 0 30px 100px var(--shadow-heavy);
}

.discount-badge {
position: absolute;
top: -15px;
right: 10%;
background: var(--warning-gradient);
color: white;
width: 90px;
height: 90px;
border-radius: 50%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-weight: 900;
box-shadow: 0 16px 48px rgba(255, 107, 107, 0.5);
transform: rotate(15deg);
animation: badgeBounce 3s infinite ease-in-out;
z-index: 5;
}

.discount-badge::before {
content: "";
position: absolute;
inset: -4px;
border-radius: 50%;
background: var(--warning-gradient);
z-index: -1;
animation: badgeGlow 2s infinite alternate;
}

.discount-number {
font-family: "Poppins", sans-serif;
font-size: 28px;
line-height: 1;
text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.discount-percent {
font-size: 18px;
margin-top: -2px;
}

.discount-off {
font-size: 12px;
font-weight: 700;
margin-top: 2px;
letter-spacing: 1px;
}

/* Цены */
.price-section-new {
margin-bottom: var(--spacing-xl);
animation: priceHighlight 3s ease-in-out infinite;
}

.old-price-new {
font-size: 28px;
color: var(--text-light);
text-decoration: line-through;
margin-bottom: var(--spacing-sm);
font-weight: 500;
position: relative;
opacity: 0.7;
}

.new-price-new {
font-family: "Poppins", sans-serif;
font-size: 42px;
font-weight: 900;
background: var(--warning-gradient);
background-clip: text;
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
text-shadow: 0 4px 20px rgba(255, 107, 107, 0.3);
animation: priceGlow 2s ease-in-out infinite alternate;
}

/* Поля формы */
.form-fields-new {
margin-bottom: var(--spacing-xl);
}

.form-input-new {
width: 100%;
max-width: 400px;
padding: var(--spacing-lg);
border: 2px solid rgba(255, 255, 255, 0.8);
border-radius: var(--border-radius-large);
font-size: 16px;
font-weight: 500;
font-family: inherit;
background: rgba(255, 255, 255, 0.95);
transition: all var(--transition-medium);
margin-bottom: var(--spacing-md);
box-shadow: 0 8px 32px var(--shadow-light);
backdrop-filter: blur(10px);
}

.form-input-new:focus {
border-color: var(--primary-color);
box-shadow: 0 0 0 4px var(--shadow-light),
    0 16px 48px var(--shadow-medium);
outline: none;
background: white;
transform: translateY(-2px);
}

.form-input-new::placeholder {
color: var(--text-light);
font-weight: 400;
}

.form-input-new:valid {
border-color: var(--accent-color);
}

/* Кнопка заказа */
.submit-button-new {
width: 100%;
max-width: 400px;
background: linear-gradient(135deg, #1e3a8a 0%, #3730a3 100%);
border: none;
border-radius: var(--border-radius-large);
padding: var(--spacing-lg) var(--spacing-xl);
color: white;
font-size: 20px;
font-weight: 800;
font-family: "Poppins", sans-serif;
cursor: pointer;
transition: all var(--transition-medium);
text-transform: uppercase;
letter-spacing: 2px;
box-shadow: 0 16px 48px rgba(30, 58, 138, 0.4);
position: relative;
overflow: hidden;
margin-bottom: var(--spacing-lg);
animation: buttonPulse 3s ease-in-out infinite;
}

.submit-button-new::before {
content: "";
position: absolute;
top: 0;
left: -100%;
width: 100%;
height: 100%;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
);
transition: left 0.6s ease;
}

.submit-button-new::after {
content: "🚀";
position: absolute;
right: var(--spacing-lg);
top: 50%;
transform: translateY(-50%);
font-size: 18px;
opacity: 0;
transition: all var(--transition-medium);
}

.submit-button-new:hover {
transform: translateY(-4px) scale(1.02);
box-shadow: 0 24px 64px var(--shadow-heavy);
}

.submit-button-new:hover::before {
left: 100%;
}

.submit-button-new:hover::after {
opacity: 1;
transform: translateY(-50%) translateX(10px);
}

.submit-button-new:active {
transform: translateY(-2px) scale(0.98);
}

/* Дополнительная информация */
.form-footer {
margin-top: var(--spacing-lg);
padding: var(--spacing-lg);
background: rgba(255, 255, 255, 0.1);
border-radius: var(--border-radius);
backdrop-filter: blur(10px);
}

.security-badges {
display: flex;
justify-content: center;
align-items: center;
gap: var(--spacing-md);
margin-bottom: var(--spacing-md);
flex-wrap: wrap;
}

.security-badge {
display: flex;
align-items: center;
gap: var(--spacing-xs);
color: white;
font-size: 12px;
font-weight: 600;
opacity: 0.9;
}

.guarantee-text {
color: white;
font-size: 14px;
text-align: center;
line-height: 1.6;
opacity: 0.9;
}

/* === КНОПКА СКРОЛЛА === */
.scroll-button {
position: fixed;
right: var(--spacing-lg);
bottom: var(--spacing-lg);
width: 56px;
height: 56px;
background: var(--success-gradient);
border: none;
border-radius: 50%;
display: none;
align-items: center;
justify-content: center;
box-shadow: 0 16px 48px rgba(6, 255, 165, 0.4);
cursor: pointer;
transition: all var(--transition-medium);
z-index: 1000;
animation: scrollButtonFloat 3s ease-in-out infinite;
}

.scroll-button:hover {
transform: translateY(-4px) scale(1.1);
box-shadow: 0 24px 64px rgba(6, 255, 165, 0.6);
}

.scroll-button.show {
display: flex;
animation: fadeInScale 0.5s var(--animation-bounce);
}

.scroll-arrow {
border: solid white;
border-width: 0 3px 3px 0;
display: inline-block;
padding: 8px;
transform: rotate(45deg);
transition: transform var(--transition-fast);
}

.scroll-button:hover .scroll-arrow {
transform: rotate(45deg) translateY(2px);
}

/* === ДОПОЛНИТЕЛЬНЫЕ ЭЛЕМЕНТЫ ИНТЕРФЕЙСА === */

/* Прогресс-бар диагностики */
.progress-container {
position: sticky;
/* top: 80px; */
padding: var(--spacing-md);
border-radius: 0 0 15px 15px;
border-bottom: 1px solid rgba(99, 102, 241, 0.10);
background: rgba(239, 239, 239, 0.98);
box-shadow: 0 4px 20px 0 rgba(99, 102, 241, 0.10);
backdrop-filter: blur(10px);
z-index: 50;
opacity: 0;
transform: translateY(-20px);
transition: all var(--transition-medium);

}

.progress-container.show {
opacity: 1;
transform: translateY(0);
}

.progress-label {
font-size: 12px;
font-weight: 600;
color: var(--text-dark);
margin-bottom: var(--spacing-xs);
text-align: center;
text-transform: uppercase;
letter-spacing: 1px;
}

.progress-bar {
width: 100%;
height: 6px;
background: var(--background-light);
border-radius: 3px;
overflow: hidden;
position: relative;
}

.progress-fill {
height: 100%;
background: var(--success-gradient);
border-radius: 3px;
transition: width 0.8s ease;
position: relative;
}

.progress-fill::after {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.5),
    transparent
);
animation: progressShimmer 2s infinite;
}

/* Уведомления */
.notification {
position: fixed;
top: var(--spacing-lg);
right: var(--spacing-lg);
background: white;
border-radius: var(--border-radius);
padding: var(--spacing-md) var(--spacing-lg);
box-shadow: 0 16px 48px var(--shadow-medium);
z-index: 2000;
transform: translateX(400px);
transition: all var(--transition-medium);
border-left: 4px solid var(--accent-color);
max-width: 300px;
}

.notification.show {
transform: translateX(0);
}

.notification-content {
display: flex;
align-items: center;
gap: var(--spacing-sm);
}

.notification-icon {
width: 24px;
height: 24px;
border-radius: 50%;
background: var(--accent-color);
display: flex;
align-items: center;
justify-content: center;
color: white;
font-size: 12px;
font-weight: bold;
}

.notification-text {
font-size: 14px;
color: var(--text-dark);
font-weight: 500;
}

/* Эффект печатания для текста */
.typewriter {
overflow: hidden;
border-right: 2px solid var(--primary-color);
white-space: nowrap;
animation: typing 1.5s steps(40, end),
    blink-caret 0.75s step-end infinite;
}

/* === АНИМАЦИИ === */
@keyframes splashAnimation {
0% {
    opacity: 0;
    transform: scale(0.8) rotateY(180deg);
}
50% {
    transform: scale(1.1) rotateY(90deg);
}
100% {
    opacity: 1;
    transform: scale(1) rotateY(0deg);
}
}

@keyframes shimmer {
0% {
    left: -100%;
}
100% {
    left: 100%;
}
}

@keyframes avatarPulse {
0%,
100% {
    box-shadow: 0 8px 32px var(--shadow-medium);
}
50% {
    box-shadow: 0 12px 48px var(--shadow-heavy);
}
}

@keyframes avatarGlow {
0% {
    opacity: 0.8;
}
100% {
    opacity: 1;
}
}

@keyframes onlinePulse {
0%,
100% {
    opacity: 1;
    transform: scale(1);
}
50% {
    opacity: 0.3;
    transform: scale(1.2);
}
}

@keyframes badgeFloat {
0%,
100% {
    transform: translateY(0) scale(1);
}
50% {
    transform: translateY(-5px) scale(1.02);
}
}

@keyframes messageSlideIn {
0% {
    opacity: 0;
    transform: translateY(30px) rotateX(90deg);
}
100% {
    opacity: 1;
    transform: translateY(0) rotateX(0deg);
}
}

@keyframes bubbleAppear {
0% {
    opacity: 0;
    transform: translateY(20px) scale(0.8);
}
100% {
    opacity: 1;
    transform: translateY(0) scale(1);
}
}

@keyframes slideInRight {
0% {
    opacity: 0;
    transform: translateX(30px);
}
100% {
    opacity: 1;
    transform: translateX(0);
}
}

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

@keyframes fadeInScale {
0% {
    opacity: 0;
    transform: scale(0.5);
}
100% {
    opacity: 1;
    transform: scale(1);
}
}

@keyframes typingBounce {
0%,
80%,
100% {
    transform: scale(0);
}
40% {
    transform: scale(1);
}
}

@keyframes wheelIdle {
0%,
100% {
    transform: rotate(0deg) scale(1);
}
50% {
    transform: rotate(5deg) scale(1.02);
}
}

@keyframes badgeBounce {
0%,
100% {
    transform: rotate(15deg) scale(1);
}
50% {
    transform: rotate(15deg) scale(1.1);
}
}

@keyframes badgeGlow {
0% {
    box-shadow: 0 0 20px rgba(255, 107, 107, 0.5);
}
100% {
    box-shadow: 0 0 40px rgba(255, 107, 107, 0.8);
}
}

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

@keyframes priceHighlight {
0%,
100% {
    transform: scale(1);
}
50% {
    transform: scale(1.02);
}
}

@keyframes priceGlow {
0% {
    filter: drop-shadow(0 0 10px rgba(255, 107, 107, 0.5));
}
100% {
    filter: drop-shadow(0 0 20px rgba(255, 107, 107, 0.8));
}
}

@keyframes buttonPulse {
0%,
100% {
    box-shadow: 0 16px 48px var(--shadow-heavy);
}
50% {
    box-shadow: 0 20px 64px var(--shadow-heavy);
}
}

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

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

@keyframes numberFlip {
0% {
    transform: rotateY(0deg);
}
50% {
    transform: rotateY(90deg);
}
100% {
    transform: rotateY(0deg);
}
}

@keyframes separatorBlink {
0%,
50% {
    opacity: 1;
}
51%,
100% {
    opacity: 0.3;
}
}

@keyframes titleGlow {
0% {
    filter: drop-shadow(0 0 10px rgba(6, 255, 165, 0.5));
}
100% {
    filter: drop-shadow(0 0 20px rgba(6, 255, 165, 0.8));
}
}

@keyframes popupAppear {
0% {
    opacity: 0;
    transform: scale(0.5) rotateY(180deg);
}
100% {
    opacity: 1;
    transform: scale(1) rotateY(0deg);
}
}

@keyframes progressShimmer {
0% {
    transform: translateX(-100%);
}
100% {
    transform: translateX(100%);
}
}

@keyframes typing {
from {
    width: 0;
}
to {
    width: 100%;
}
}

@keyframes blink-caret {
from,
to {
    border-color: transparent;
}
50% {
    border-color: var(--primary-color);
}
}

/* === УЛУЧШЕННАЯ АДАПТИВНОСТЬ === */
@media (max-width: 768px) {
:root {
    --spacing-xs: 2px;
    --spacing-sm: 6px;
    --spacing-md: 12px;
    --spacing-lg: 18px;
    --spacing-xl: 24px;
    --spacing-xxl: 36px;
}

.container {
    border-radius: 0;
    box-shadow: none;
}

.header {
    padding: var(--spacing-md);
}

.doctor-avatar {
    width: 48px;
    height: 48px;
}

.doctor-details h3 {
    font-size: 16px;
}

/* .consultation-badge {
    font-size: 10px;
    padding: var(--spacing-xs) var(--spacing-sm);
} */

.chat-container {
    padding: var(--spacing-md);
}

.message-bubble.doctor {
    max-width: 90%;
    padding: var(--spacing-sm) var(--spacing-md);
}

.message-bubble.user {
    max-width: 85%;
    padding: var(--spacing-sm) var(--spacing-md);
}

.choice-button {
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 13px;
    min-height: 44px;
    max-width: 90%;
}

.before-after-image,
.product-image {
    max-width: 240px;
}

.wheel-image {
    width: 250px;
    height: 250px;
}

.spin-button {
    width: 100px;
    height: 100px;
    font-size: 14px;
}

.form-content {
    padding: var(--spacing-xl) var(--spacing-md);
}

.product-image-new {
    width: 240px;
}

.discount-badge {
    width: 75px;
    height: 75px;
    right: 8%;
}

.discount-number {
    font-size: 22px;
}

.discount-percent {
    font-size: 16px;
}

.timer-number {
    font-size: 26px;
}

.old-price-new {
    font-size: 22px;
}

.new-price-new {
    font-size: 34px;
}

.popup-content {
    padding: var(--spacing-xl) var(--spacing-md);
    margin: var(--spacing-md);
}

.submit-button-new {
    font-size: 16px;
    padding: var(--spacing-md) var(--spacing-lg);
}

.form-input-new {
    padding: var(--spacing-md);
    font-size: 15px;
}

.scroll-button {
    right: var(--spacing-md);
    bottom: var(--spacing-md);
    width: 48px;
    height: 48px;
}

.discount-text {
    font-size: 18px;
}

.timer-label {
    font-size: 14px;
}

.notification {
    right: var(--spacing-md);
    top: var(--spacing-md);
    max-width: calc(100vw - 32px);
}
}

@media (max-width: 480px) {
.splash-name {
    font-size: 24px;
    padding: var(--spacing-lg) var(--spacing-md);
}

.splash-title {
    font-size: 12px;
    padding: var(--spacing-sm) var(--spacing-md);
    letter-spacing: 1px;
}

.doctor-details h3 {
    font-size: 14px;
}

/* .consultation-badge {
    font-size: 9px;
    padding: 4px 8px;
} */

.before-after-image,
.product-image {
    max-width: 200px;
}

.wheel-image {
    width: 200px;
    height: 200px;
}

.spin-button {
    width: 80px;
    height: 80px;
    font-size: 12px;
}

.product-image-new {
    width: 200px;
}

.discount-badge {
    width: 65px;
    height: 65px;
    right: 10%;
}

.discount-number {
    font-size: 18px;
}

.discount-percent {
    font-size: 14px;
}

.discount-off {
    font-size: 10px;
}

.timer-number {
    font-size: 22px;
}

.old-price-new {
    font-size: 20px;
}

.new-price-new {
    font-size: 30px;
}

.discount-text {
    font-size: 16px;
}

.timer-label {
    font-size: 12px;
}
}

@media (max-width: 360px) {
.header {
    padding: var(--spacing-sm);
}

.doctor-avatar {
    width: 40px;
    height: 40px;
}

.chat-container {
    padding: var(--spacing-sm);
}

.choice-button {
    padding: var(--spacing-xs) var(--spacing-sm);
    min-height: 40px;
    font-size: 11px;
}

.before-after-image,
.product-image {
    max-width: 180px;
}

.wheel-image {
    width: 180px;
    height: 180px;
}

.spin-button {
    width: 70px;
    height: 70px;
    font-size: 11px;
}

.product-image-new {
    width: 180px;
}

.discount-badge {
    width: 55px;
    height: 55px;
}

.discount-number {
    font-size: 16px;
}

.form-content {
    padding: var(--spacing-lg) var(--spacing-sm);
}

.timer-number {
    font-size: 18px;
}

.countdown-timer {
    padding: var(--spacing-sm) var(--spacing-md);
}

.timer-display {
    gap: var(--spacing-sm);
}
}

/* === УЛУЧШЕНИЯ ПРОИЗВОДИТЕЛЬНОСТИ === */
.message,
.choice-button,
.wheel-image,
.product-image-new {
will-change: transform;
}

/* Оптимизация анимаций для слабых устройств */
@media (prefers-reduced-motion: reduce) {
*,
*::before,
*::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
}
}

/* === УТИЛИТЫ === */
.hidden {
display: none !important;
}

.show {
display: block !important;
}

.fade-in {
animation: fadeInUp 0.5s ease forwards;
}

.slide-in-right {
animation: slideInRight 0.5s ease forwards;
}

.no-scroll {
overflow: hidden;
}

/* Плавная прокрутка для всех элементов */
* {
scroll-behavior: smooth;
}

/* Улучшенная типографика */
h1,
h2,
h3,
h4,
h5,
h6 {
font-family: "Poppins", sans-serif;
font-weight: 700;
line-height: 1.2;
margin-bottom: var(--spacing-sm);
}

p {
margin-bottom: var(--spacing-md);
line-height: 1.7;
}

/* Улучшенная доступность */
:focus {
outline: 2px solid var(--accent-color);
outline-offset: 2px;
}

button:focus,
input:focus {
outline: 2px solid var(--primary-color);
outline-offset: 2px;
}

/* Улучшенные переходы */
a,
button,
input,
select,
textarea {
transition: all var(--transition-medium);
}

/* ================== MODAL START ================== */

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 15px;
    border: 2px dashed #DDD;
    background: #FFF;
    padding: 20px 10px;
    max-width: 325px;
    max-height: max-content;  
    z-index: 3;
    display: none;
  }
  
  .modal__overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(5px); 
    background-color: rgba(0,0,0,0.3);
    top: 0;
    left: 0;
    z-index: 1;
    display: none;
  }
  
  .modal__wrapper {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    gap: 15px;
  }
  
  .modal__close {
    display: flex;
    justify-content: flex-end;
    width: 100%;
    font-size: 24px;
    cursor: pointer;
  }
  
  .modal__heading {
    display: flex;
    flex-direction: column;
    gap: 5px;
  }
  
  .modal__heading-title {
    color: #10B981;
    text-align: center;
    font-family: "Inter", sans-serif;
    font-size: 20px;
    font-weight: 700;
  line-height: 85%;
  }
  
  .modal__heading-text {
    color: #222;
    text-align: center;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 121.429%;
  }
  
  .modal__form {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 5px;
  }
  
  .modal__form label {
    color: #000;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 142.857%;
  }
  
  .modal__form input {
    border-radius: 35px;
    border: 2px solid #DDD;
    background: #F2F2F2;
    padding: 12.5px;
    font-size: 14px;
    font-weight: 400;
    line-height: 142.857%;
    outline: none;
    width: 100%;
    color: #000;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 142.857%;
    line-height: 100%;
  }
  
  .modal__form input::placeholder {
    color: #757575;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 142.857%;
  }
  
  .modal__form button {
    border-radius: 35px;
    background: #388E3C;
    color: #FFF;
    text-align: center;
    font-family: "Inter", sans-serif;
    font-size: 18px;
    font-weight: 700;
    line-height: 150%;
    padding: 12.5px;
    margin-top: 15px;
    border: none;
    outline: none;
    cursor: pointer;
    transition: all 0.3s ease;
    max-width: 294px;
    width: 100%;
  }
  
  .modal__form button:hover {
    background: #2f7532;
  }
  
  @keyframes modalFade {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
  }
  
  .modal__policy {
    color: #888;
    text-align: center;
    font-family: "Inter", sans-serif;
    font-size: 8px;
    font-weight: 400;
    line-height: 187.5%;
  }