/* Reset & Base Styles */
:root {
    /* Colors */
    --primary: #009849;   /* Green accent */
    --primary-light: #00b359; /* Lighter green */
    --primary-dark: #007a3d;  /* Darker green */
    --secondary: #ff7a22; /* Orange */
    --secondary-light: #ff8f3d; /* Lighter orange */
    --secondary-dark: #e65a1a;  /* Darker orange */
    --dark: #0d3b66;      /* Dark blue */
    --text: #1a1a1a;      /* Main text color */
    --text-light: #666666; /* Secondary text color */
    --light: #ffffff;     /* White */
    --gray: #f8f9fa;      /* Light gray background */
    --gray-light: #e9ecef; /* Lighter gray */
    --border: #dee2e6;    /* Border color */
    --shadow: rgba(0, 0, 0, 0.1); /* Shadow color */
    
    /* Spacing */
    --container-padding: 0 20px;
    --section-padding: 50px 0;
    
    /* Border radius */
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --border-radius-lg: 20px;
    --border-radius-xl: 30px;
    
    /* Transitions */
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Shadows */
    --shadow-sm: 0 2px 8px var(--shadow);
    --shadow-md: 0 4px 16px var(--shadow);
    --shadow-lg: 0 8px 32px var(--shadow);
    --shadow-xl: 0 16px 48px var(--shadow);
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    --gradient-secondary: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-light) 100%);
    --gradient-dark: linear-gradient(135deg, var(--dark) 0%, #1a4a7a 100%);
}

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

html {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    scroll-behavior: smooth;
}

body {
    background-color: var(--light);
    color: var(--text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    font-size: 16px;
    padding-top: 120px; /* Space for fixed header */
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--container-padding);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: var(--border-radius);
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-size: 15px;
    text-decoration: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn::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: var(--transition);
}

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

.btn-primary {
    background: var(--gradient-primary);
    color: var(--light);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background: var(--gradient-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--gradient-secondary);
    color: var(--light);
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
    background: var(--gradient-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Top Bar */
.top-bar {
    background: var(--gradient-primary);
    color: var(--light);
    padding: 10px 0;
    font-size: 14px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1001;
    box-shadow: var(--shadow-sm);
}

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

.top-bar a {
    color: var(--light);
    font-weight: 500;
}

.top-bar a:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

/* Header */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-md);
    position: fixed;
    width: 100%;
    top: 40px; /* Below top bar */
    left: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo-text {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.main-nav ul {
    display: flex;
    gap: 35px;
}

.main-nav a {
    font-weight: 500;
    color: var(--text);
    padding: 10px 0;
    position: relative;
    transition: var(--transition);
    border-radius: var(--border-radius-sm);
}

.main-nav a:hover {
    color: var(--primary);
    background: rgba(0, 152, 73, 0.1);
    padding: 10px 15px;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: var(--gradient-primary);
    transition: var(--transition);
    transform: translateX(-50%);
    border-radius: 2px;
}

.main-nav a:hover::after {
    width: 80%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 25px;
}

.search-icon,
.phone-icon {
    color: var(--text);
    font-size: 18px;
    transition: var(--transition);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.search-icon:hover,
.phone-icon:hover {
    color: var(--primary);
    background: rgba(0, 152, 73, 0.1);
    transform: scale(1.1);
}

/* Main Content */
.main-content {
    padding: 50px 0;
}

/* Article Header */
.article-header {
    margin-bottom: 50px;
    text-align: center;
}

.article-header h1 {
    font-size: 42px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 20px;
    background: var(--gradient-dark);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.breadcrumbs {
    color: var(--text-light);
    font-size: 14px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.breadcrumbs a {
    color: var(--primary);
    font-weight: 500;
    padding: 5px 10px;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
}

.breadcrumbs a:hover {
    background: rgba(0, 152, 73, 0.1);
    transform: translateY(-1px);
}

/* Table of Contents */
.table-of-contents {
    background: var(--gray);
    padding: 35px;
    border-radius: var(--border-radius-lg);
    margin-bottom: 50px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.table-of-contents h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 20px;
    text-align: center;
}

.table-of-contents ul {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 12px;
}

.table-of-contents a {
    color: var(--text);
    font-size: 15px;
    line-height: 1.5;
    padding: 12px 16px;
    border-radius: var(--border-radius);
    transition: var(--transition);
    display: block;
    border: 1px solid transparent;
}

.table-of-contents a:hover {
    color: var(--primary);
    background: var(--light);
    border-color: var(--primary);
    transform: translateX(5px);
    box-shadow: var(--shadow-sm);
}

/* Article Content */
.article-content {
    max-width: 900px;
    margin: 0 auto;
}

.intro {
    margin-bottom: 50px;
    text-align: center;
    padding: 40px;
    background: var(--gray);
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border);
}

.intro p {
    font-size: 20px;
    color: var(--text);
    margin-bottom: 30px;
    line-height: 1.7;
}

/* Content Sections */
.content-section {
    margin-bottom: 60px;
    padding: 40px;
    background: var(--light);
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.content-section:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.content-section h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary);
    position: relative;
}

.content-section h2::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 50px;
    height: 3px;
    background: var(--gradient-secondary);
    border-radius: 2px;
}

.section-content {
    margin-bottom: 30px;
}

.text-content p {
    margin-bottom: 20px;
    line-height: 1.7;
    font-size: 16px;
}

.text-content ul {
    margin-left: 20px;
}

.text-content li {
    margin-bottom: 12px;
    position: relative;
    padding-left: 25px;
    line-height: 1.6;
}

.text-content li::before {
    content: "✓";
    color: var(--primary);
    font-weight: bold;
    position: absolute;
    left: 0;
    background: rgba(0, 152, 73, 0.1);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

/* Image Placeholders */
.image-placeholder {
    background: var(--gray);
    border: 2px dashed var(--border);
    border-radius: var(--border-radius);
    padding: 40px 20px;
    text-align: center;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.placeholder-text {
    color: var(--text-light);
    font-style: italic;
}

/* Eye Exercises Diagram */
.eye-exercises .image-placeholder {
    background: var(--light);
    border: none;
    padding: 20px;
}

.exercise-diagram {
    position: relative;
    width: 150px;
    height: 150px;
}

.concentric-circles {
    position: relative;
    width: 100%;
    height: 100%;
}

.circle {
    position: absolute;
    border: 3px solid;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.circle.blue {
    width: 120px;
    height: 120px;
    border-color: #3b82f6;
}

.circle.red {
    width: 80px;
    height: 80px;
    border-color: #ef4444;
}

.circle.green {
    width: 40px;
    height: 40px;
    border-color: #10b981;
}

.arrows {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.arrow {
    position: absolute;
    width: 20px;
    height: 2px;
    background: var(--primary);
}

.arrow::after {
    content: '';
    position: absolute;
    right: 0;
    top: -3px;
    width: 0;
    height: 0;
    border-left: 6px solid var(--primary);
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
}

.arrow-1 {
    top: 20px;
    left: 20px;
    transform: rotate(45deg);
}

.arrow-2 {
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
}

.arrow-3 {
    bottom: 20px;
    left: 20px;
    transform: rotate(-45deg);
}

/* Decorative Band */
.decorative-band {
    background: var(--gradient-secondary);
    padding: 20px 0;
    margin: 50px 0;
    overflow: hidden;
    border-radius: var(--border-radius-lg);
}

.eye-pattern {
    display: flex;
    justify-content: center;
    gap: 25px;
    animation: scroll 25s linear infinite;
}

.eye-pattern i {
    color: var(--light);
    font-size: 24px;
    transition: var(--transition);
}

.eye-pattern i:hover {
    transform: scale(1.2) rotate(10deg);
}

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

/* Social Sharing */
.social-sharing {
    margin: 50px 0;
    padding: 35px;
    background: var(--gray);
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border);
    text-align: center;
}

.social-sharing h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 20px;
}

.social-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.social-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    font-size: 18px;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.social-btn.facebook { background: linear-gradient(135deg, #1877f2, #0d6efd); }
.social-btn.twitter { background: linear-gradient(135deg, #1da1f2, #0ea5e9); }
.social-btn.instagram { background: linear-gradient(135deg, #e4405f, #dc2626); }
.social-btn.vk { background: linear-gradient(135deg, #4c75a3, #3b82f6); }
.social-btn.odnoklassniki { background: linear-gradient(135deg, #ed812b, #f59e0b); }

.social-btn:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: var(--shadow-lg);
}

/* Popular Articles */
.popular-articles {
    margin-top: 80px;
}

.popular-articles h3 {
    font-size: 28px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 40px;
    text-align: center;
    background: var(--gradient-dark);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.article-card {
    background: var(--light);
    border: 1px solid var(--border);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.article-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.article-icon {
    height: 120px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    font-size: 36px;
    transition: var(--transition);
}

.article-card:hover .article-icon {
    background: var(--gradient-secondary);
    transform: scale(1.1);
}

.article-info {
    padding: 25px;
}

.article-info h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 12px;
    line-height: 1.4;
}

.article-info p {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.6;
}

/* Footer */
.footer {
    background: var(--gradient-dark);
    color: var(--light);
    padding: 60px 0 25px;
    margin-top: 80px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 50px;
}

.footer-logo .logo-text {
    font-size: 28px;
    font-weight: 700;
    color: var(--light);
    margin-bottom: 25px;
    background: var(--light);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.contact-info p {
    margin-bottom: 15px;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
}

.contact-info p:hover {
    transform: translateX(5px);
}

.contact-info i {
    color: var(--secondary);
    width: 18px;
    font-size: 16px;
}

.footer-links h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--light);
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    font-size: 15px;
    transition: var(--transition);
    padding: 5px 0;
    border-radius: var(--border-radius-sm);
}

.footer-links a:hover {
    color: var(--secondary);
    background: rgba(255, 255, 255, 0.1);
    padding: 5px 10px;
    transform: translateX(5px);
}

/* Footer Map */
.footer-map {
    flex: 2;
    max-width: 600px;
}

.footer-map h4 {
    color: var(--light);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    position: relative;
}

.footer-map h4::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.map-container {
    margin-bottom: 15px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.map-container:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.map-info {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
}

.map-info p {
    color: var(--light);
    margin-bottom: 8px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

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

.map-info i {
    color: var(--primary);
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.footer-social h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--light);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    transition: var(--transition);
    font-size: 18px;
}

.social-links a:hover {
    background: var(--secondary);
    color: var(--light);
    transform: translateY(-3px) scale(1.1);
    box-shadow: var(--shadow-md);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 25px;
}

.footer-legal p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
    font-size: 13px;
}

.payment-methods {
    display: flex;
    align-items: center;
    gap: 20px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
}

.payment-icons {
    display: flex;
    align-items: center;
    gap: 15px;
}

.payment-icons i {
    font-size: 24px;
    color: var(--light);
    transition: var(--transition);
}

.payment-icons i:hover {
    transform: scale(1.2);
}

.mir-card,
.sbp {
    background: var(--light);
    color: var(--dark);
    padding: 4px 8px;
    border-radius: var(--border-radius-sm);
    font-size: 11px;
    font-weight: 600;
    transition: var(--transition);
}

.mir-card:hover,
.sbp:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-sm);
}

/* Chat Widget */
.chat-widget {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    background: var(--gradient-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--light);
    font-size: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    z-index: 1000;
}

.chat-widget:hover {
    transform: scale(1.15) rotate(5deg);
    box-shadow: var(--shadow-xl);
}

/* Responsive Design */
@media (max-width: 992px) {
    .section-content {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
    
    .footer-map {
        max-width: 100%;
    }
    
    .table-of-contents ul {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 100px;
    }
    
    .top-bar {
        display: none;
    }
    
    .header {
        top: 0;
    }
    
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .main-nav ul {
        flex-wrap: wrap;
        gap: 15px;
        justify-content: center;
    }
    
    .header-actions {
        flex-direction: column;
        gap: 15px;
    }
    
    .article-header h1 {
        font-size: 32px;
    }
    
    .content-section h2 {
        font-size: 24px;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .footer-map {
        max-width: 100%;
    }
    
    .map-container iframe {
        height: 300px;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .payment-methods {
        justify-content: center;
    }
    
    .content-section {
        padding: 30px 25px;
    }
    
    .intro {
        padding: 30px 25px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .article-header h1 {
        font-size: 28px;
    }
    
    .content-section h2 {
        font-size: 20px;
    }
    
    .intro p {
        font-size: 18px;
    }
    
    .table-of-contents {
        padding: 25px 20px;
    }
    
    .social-buttons {
        justify-content: center;
    }
    
    .chat-widget {
        width: 50px;
        height: 50px;
        font-size: 20px;
        bottom: 20px;
        left: 20px;
    }
}
