/* General Styles */
:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary-color: #6b7280;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --light-bg: #f9fafb;
    --dark-bg: #1f2937;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-success: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    --gradient-warning: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

body {
    font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
}

/* Header Styles */
.header {
    background: var(--gradient-primary);
    color: white;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="%23ffffff" opacity="0.1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

.site-title {
    font-size: 2rem;
    font-weight: bold;
    margin: 0;
}

.site-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin: 0;
}

/* Main Section */
.main-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    position: relative;
    overflow: hidden;
}

.main-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 20%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 70% 80%, rgba(168, 85, 247, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.min-vh-70 {
    min-height: 60vh;
}

/* Equal height columns */
.row.align-items-start {
    align-items: stretch !important;
}

.col-lg-5, .col-lg-7 {
    display: flex;
    flex-direction: column;
}

.col-lg-5 {
    justify-content: center;
}

.col-lg-7 {
    justify-content: flex-start;
    padding-left: 3rem;
}

.content-container {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.main-title {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.main-description {
    font-size: 0.9rem;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    line-height: 1.6;
    font-weight: 400;
}

.badge-container {
    margin-bottom: 1.5rem;
}

.badge {
    font-size: 0.875rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 50px;
}

.content-container {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.price-card {
    border: none;
    box-shadow: var(--shadow-lg);
    border-radius: 15px;
    overflow: hidden;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
    transition: all 0.3s ease;
    max-width: 400px;
}

.price-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.price-display {
    background: var(--gradient-primary);
    color: white;
    padding: 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 15px;
}

.price-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255,255,255,0.1) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.price-card:hover .price-display::before {
    transform: translateX(100%);
}

.price-label {
    font-size: 1rem;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.price-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.price-info {
    margin-top: 0.5rem;
}

.nomination-selector label {
    color: var(--secondary-color);
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
}

.nomination-selector select {
    font-size: 1.1rem;
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    background: white;
    transition: all 0.3s ease;
    font-weight: 500;
}

.nomination-selector select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.pulse-button {
    animation: pulse 2s infinite;
    position: relative;
    overflow: hidden;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(99, 102, 241, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0);
    }
}

.delivery-info {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 12px;
    padding: 1.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
    font-weight: 500;
}

.info-item:last-child {
    margin-bottom: 0;
}

.card-image-container {
    position: relative;
    border-radius: 25px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 0;
    max-width: 500px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 450px;
}

.card-image-container:hover {
    transform: translateY(-10px) rotate(1deg);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.25);
}

.main-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: all 0.3s ease;
    border-radius: 25px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    max-width: 100%;
}

/* Description Toggle */
.description-container {
    max-width: 100%;
}

.main-description-short {
    font-size: 0.9rem;
    color: var(--secondary-color);
    line-height: 1.6;
    font-weight: 400;
    margin-bottom: 0.5rem;
}

.description-toggle {
    color: var(--primary-color) !important;
    text-decoration: none !important;
    font-weight: 500;
    border: none !important;
    background: none !important;
    box-shadow: none !important;
    transition: all 0.3s ease;
}

.description-toggle:hover {
    color: var(--primary-dark) !important;
    transform: translateX(5px);
}

.description-toggle i {
    transition: transform 0.3s ease;
}

.description-full {
    animation: fadeIn 0.3s ease-in-out;
}

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

/* Select Arrow Animation */
.select-wrapper {
    position: relative;
}

.select-arrow {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--secondary-color);
    pointer-events: none;
    transition: transform 0.3s ease;
    z-index: 1;
}

.nomination-selector select:focus + .select-arrow,
.nomination-selector select:active + .select-arrow {
    transform: translateY(-50%) rotate(180deg);
}

.nomination-selector select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: none;
    padding-right: 3rem;
}

/* Sections */
.how-to-section, .reviews-section {
    background-color: var(--light-bg);
    padding: 5rem 0;
}

.how-to-section {
    margin-top: 4rem;
}

.reviews-section {
    margin-top: 4rem;
}

.section-title {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 4rem;
}

/* FAQ Styles */
.accordion-button {
    font-weight: 600;
    background-color: white;
    border: none;
}

.accordion-button:not(.collapsed) {
    background-color: var(--primary-color);
    color: white;
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(111, 66, 193, 0.25);
}

/* Reviews Styles */
.overall-rating {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.rating-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary-color);
}

.rating-stars {
    font-size: 1.5rem;
    margin: 0.5rem 0;
}

.rating-count {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.rating-breakdown {
    padding-left: 1rem;
}

.rating-bar-container {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.rating-label {
    min-width: 50px;
    font-size: 0.9rem;
}

.rating-bar {
    flex: 1;
    height: 8px;
    background-color: #e9ecef;
    border-radius: 4px;
    margin: 0 1rem;
    overflow: hidden;
}

.rating-fill {
    height: 100%;
    background-color: var(--warning-color);
    transition: width 0.3s ease;
}

.review-item {
    background: white;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.reviewer-name {
    font-weight: bold;
    color: var(--primary-color);
}

.review-rating {
    color: var(--warning-color);
}

.review-date {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.review-text {
    color: #333;
    line-height: 1.6;
}

.review-stats-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: var(--shadow-xl);
    height: fit-content;
    border: 1px solid rgba(99, 102, 241, 0.1);
    transition: all 0.3s ease;
}

.review-stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

.stats-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.stat-item:hover {
    transform: scale(1.05);
}

.stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--secondary-color);
    font-weight: 500;
}

.trust-badges {
    background: rgba(16, 185, 129, 0.05);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(16, 185, 129, 0.1);
}

.trust-item {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--secondary-color);
}

.trust-item:last-child {
    margin-bottom: 0;
}

.trust-item i {
    width: 20px;
    margin-right: 0.75rem;
}

.review-note {
    background: linear-gradient(135deg, #fff3cd 0%, #fef3c7 100%) !important;
    border: 1px solid rgba(245, 158, 11, 0.2) !important;
    border-radius: 12px !important;
}

.rating-stars-large i {
    font-size: 1.5rem;
    color: #ddd;
    cursor: pointer;
    margin-right: 0.25rem;
    transition: color 0.2s ease;
}

.rating-stars-large i:hover,
.rating-stars-large i.active {
    color: var(--warning-color);
}

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

/* Chat Widget Styles */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
}

.chat-toggle:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-xl);
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 15px;
    box-shadow: var(--shadow-xl);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.chat-header {
    background: var(--gradient-primary);
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-body {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    background-color: #f8f9fa;
}

.chat-messages {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.chat-message {
    max-width: 80%;
    padding: 0.75rem 1rem;
    border-radius: 15px;
    word-wrap: break-word;
    position: relative;
}

.chat-message.user {
    background-color: var(--primary-color);
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 5px;
}

.chat-message.admin {
    background-color: #6366f1;
    color: white;
    align-self: flex-start;
    border-bottom-left-radius: 5px;
}

.chat-message.system {
    background-color: #e5e7eb;
    color: #6b7280;
    align-self: center;
    font-size: 0.875rem;
    text-align: center;
    max-width: 90%;
}

.chat-footer {
    padding: 1rem;
    background: white;
    border-top: 1px solid #e5e7eb;
}

.chat-input-group {
    display: flex;
    gap: 0.5rem;
}

.chat-input-group input {
    flex: 1;
    border: 1px solid #d1d5db;
    border-radius: 20px;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.chat-input-group button {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-input-group button:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

/* Chat Name Request Styles */
.chat-name-request {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
}

.chat-name-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-name-modal {
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: var(--shadow-xl);
    text-align: center;
    max-width: 280px;
    width: 90%;
}

.chat-name-modal h6 {
    margin-bottom: 1rem;
    color: var(--primary-color);
    font-weight: 600;
}

.chat-name-modal input {
    margin-bottom: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    padding: 0.75rem;
    font-size: 0.9rem;
    transition: border-color 0.3s ease;
}

.chat-name-modal input:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.chat-name-modal button {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1.5rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-name-modal button:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* Buttons */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border: none;
    border-radius: 8px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(111, 66, 193, 0.3);
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 8px;
    padding: 0.75rem 2rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border-radius: 15px 15px 0 0;
}

/* Rating Input */
.rating-input {
    display: flex;
    flex-direction: row-reverse;
    justify-content: center;
}

.rating-input input {
    display: none;
}

.rating-input label {
    font-size: 1.5rem;
    color: #ddd;
    cursor: pointer;
    margin: 0 0.25rem;
    transition: color 0.2s ease;
}

.rating-input label:hover,
.rating-input label:hover ~ label,
.rating-input input:checked ~ label {
    color: var(--warning-color);
}

/* Footer */
.footer {
    background: #2c3e50 !important;
    margin-top: 4rem;
}

.footer h5 {
    color: white;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer p {
    color: #bdc3c7;
    margin-bottom: 0.5rem;
}

.footer hr {
    border-color: #34495e;
}

/* Responsive Design */
@media (max-width: 768px) {
    .main-title {
        font-size: 1.8rem;
    }
    
    .price-value {
        font-size: 1.8rem;
    }
    
    .chat-window {
        width: 300px;
    }
    
    .review-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .review-header > div {
        margin-bottom: 0.5rem;
    }
    
    .rating-breakdown {
        padding-left: 0;
        margin-top: 1rem;
    }
    
    .overall-rating .row {
        text-align: center;
    }
    
    /* Мобильная адаптация главной секции */
    .col-lg-5, .col-lg-7 {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Принудительно меняем порядок на мобильных */
    .order-1 {
        order: 1 !important;
    }
    
    .order-2 {
        order: 3 !important;
    }
    
    .card-image-container {
        order: 2 !important;
        margin-bottom: 2rem !important;
        margin-top: 2rem !important;
        min-height: 250px;
        max-width: 90%;
        margin-left: auto;
        margin-right: auto;
    }
    
    .content-container {
        padding: 0 1rem;
        margin-top: 0 !important;
    }
    
    .price-card {
        max-width: 100%;
        margin: 0 1rem;
    }
    
    .main-section {
        padding: 2rem 0;
    }
    
    .main-description {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }
    
    .price-display {
        padding: 1rem;
    }
    
    .price-label {
        font-size: 0.9rem;
    }
    
    .nomination-selector select {
        font-size: 1rem;
        padding: 0.75rem;
    }
    
    .delivery-info {
        padding: 1rem;
        margin: 0 1rem;
    }
    
    .info-item {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }
    
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .how-to-section, .reviews-section {
        padding: 3rem 0;
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Success/Error Messages */
.alert-custom {
    border: none;
    border-radius: 10px;
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
}

.alert-success-custom {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
}

.alert-danger-custom {
    background: linear-gradient(135deg, #dc3545, #e74c3c);
    color: white;
}
