/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    overflow-x: hidden;
    width: 100%;
}

a {
    color: #0055ff;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

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

/* Header */
.header {
    background: linear-gradient(135deg, #0055ff, #00aaff);
    color: #fff;
    padding: 40px 0;
    text-align: center;
}

.main-title {
    font-size: 2.5em;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.promo-counter {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 12px;
    border-radius: 20px;
    font-size: 0.6em;
    vertical-align: middle;
    margin-left: 10px;
}

.header-subtitle {
    font-size: 1.2em;
    margin-bottom: 30px;
    opacity: 0.9;
}

.header-instruction {
    margin-top: 20px;
    font-size: 1.1em;
    opacity: 0.9;
}

/* Promocodes Grid */
.promocodes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 30px 0;
    counter-reset: card-counter;
    position: relative;
}

.promocode-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 10px;
    padding: 25px;
    color: #333;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    animation: fadeInUp 0.5s ease-out forwards;
    opacity: 0;
}

.promocode-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.promocode-card::before {
    content: counter(card-counter);
    counter-increment: card-counter;
    position: absolute;
    top: -10px;
    left: -10px;
    background: #ff5500;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

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

.promocode-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.service-name {
    font-weight: 700;
    font-size: 1.3em;
    color: #0055ff;
    flex: 1;
}

.discount-badge {
    background: #ff5500;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 600;
    flex-shrink: 0;
}

.promocode-description-short {
    margin: 15px 0;
    color: #666;
    font-size: 0.95em;
    line-height: 1.5;
    min-height: 60px;
}

.open-btn {
    background: #ff5500;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    justify-content: center;
    font-size: 1.1em;
}

.open-btn:hover {
    background: #ff4400;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255, 85, 0, 0.3);
}

.open-icon {
    font-size: 1.2em;
}

.update-time {
    font-size: 0.85em;
    color: #888;
    font-style: italic;
    margin-top: 10px;
    text-align: right;
}

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

.section-title {
    font-size: 2em;
    margin-bottom: 25px;
    color: #0055ff;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.service-card {
    background: #f5f9ff;
    padding: 25px;
    border-radius: 10px;
    text-align: center;
    transition: all 0.3s;
}

.service-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 85, 255, 0.1);
}

.service-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.service-card h3 {
    margin: 10px 0;
    color: #0055ff;
}

.service-link-wrapper {
    text-decoration: none;
    color: inherit;
    display: block;
    cursor: pointer;
}

.service-link-wrapper:hover .service-icon {
    transform: scale(1.1);
}

.service-link-wrapper:hover h3 {
    color: #ff5500;
}

.service-card {
    transition: all 0.3s ease;
    cursor: pointer;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 85, 255, 0.2);
}

/* How-to section */
.steps-list {
    list-style-type: decimal;
    margin-left: 20px;
    margin-bottom: 20px;
    font-size: 1.1em;
}

.steps-list li {
    margin-bottom: 10px;
    padding-left: 10px;
}

/* FAQ Section */
.faq-section {
    margin-top: 50px;
}

.faq-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
}

.faq-item {
    background: #f5f9ff;
    border-radius: 8px;
    padding: 20px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
}

.faq-item:hover {
    background: #e8f0ff;
}

.faq-checkbox {
    display: none;
}

.faq-question {
    font-size: 1.1em;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    margin: 0;
    display: flex;
    align-items: center;
    user-select: none;
}

.accordion-icon {
    margin-right: 10px;
    transition: transform 0.3s;
    flex-shrink: 0;
    color: #0055ff;
    font-size: 1.2em;
}

.faq-answer {
    font-size: 1em;
    color: #666;
    line-height: 1.5;
    margin: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, margin 0.3s ease;
}

.faq-item.active .accordion-icon {
    transform: rotate(90deg);
}

.faq-item.active .faq-answer {
    max-height: 200px;
    margin-top: 15px;
}

/* Footer */
.footer {
    background-color: #333;
    padding: 30px 0;
    color: #fff;
    text-align: center;
}

.footer-content {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.footer-logo .logo-text {
    font-size: 1.5em;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: #ccc;
}

.footer-links a:hover {
    color: #fff;
}

.footer-copy {
    font-size: 0.9em;
    margin-top: 20px;
    color: #aaa;
}

.footer-disclaimer {
    font-size: 0.8em;
    color: #888;
    margin-top: 10px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Quick tags container */
.quick-tags-container {
    margin: 30px 0 20px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(5px);
}

.tags-title {
    font-size: 1.3em;
    margin-bottom: 15px;
    color: #fff;
    text-align: center;
}

.tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.tag-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 30px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tag-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    background: #fff;
}

.tag-emoji {
    font-size: 1.2em;
}

.tag-name {
    font-size: 0.9em;
}

.tag-discount {
    background: #ff5500;
    color: white;
    padding: 2px 8px;
    border-radius: 15px;
    font-size: 0.8em;
    font-weight: 600;
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: flex;
    opacity: 1;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #fff;
    border-radius: 15px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transform: scale(0.7);
    transition: transform 0.3s ease;
}

.modal.show .modal-content {
    transform: scale(1);
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    margin: 0;
    font-size: 1.3em;
    color: #333;
}

.modal-close {
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: color 0.3s;
}

.modal-close:hover {
    color: #333;
}

.modal-body {
    padding: 25px;
}

.modal-discount {
    display: inline-block;
    background: #ff5500;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: 600;
    margin-bottom: 20px;
}

.modal-code-container {
    background: #f5f9ff;
    border: 2px dashed #0055ff;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.modal-code {
    font-family: 'Courier New', monospace;
    font-size: 1.8em;
    font-weight: 700;
    color: #0055ff;
    flex: 1;
    text-align: center;
    word-break: break-all;
}

.modal-copy-btn {
    background: #0055ff;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.modal-copy-btn:hover {
    background: #0044cc;
}

.modal-copy-btn.copied {
    background: #28a745;
}

.modal-description {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
}

.modal-link-container {
    text-align: center;
}

/* Стиль для кнопки вместо ссылки */
.modal-link-btn {
    display: inline-block;
    background: #0055ff;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
}

.modal-link-btn:hover {
    background: #0044cc;
    transform: translateY(-2px);
}

/* Responsive design */
@media (max-width: 768px) {
    .main-title {
        font-size: 2em;
        flex-direction: column;
        gap: 5px;
    }
    
    .promo-counter {
        font-size: 0.7em;
        margin-left: 0;
    }
    
    .promocodes-grid {
        grid-template-columns: 1fr;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .modal-code-container {
        flex-direction: column;
    }
    
    .modal-code {
        font-size: 1.5em;
    }
    
    .modal-copy-btn {
        width: 100%;
        justify-content: center;
    }
    
    .promocode-card::before {
        width: 25px;
        height: 25px;
        font-size: 12px;
    }
    
    .tags-grid {
        gap: 8px;
    }
    
    .tag-link {
        padding: 8px 12px;
        font-size: 0.9em;
    }
    
    .tag-emoji {
        font-size: 1em;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .promocode-card {
        padding: 20px;
    }
    
    .main-title {
        font-size: 1.7em;
    }
    
    .section-title {
        font-size: 1.5em;
    }
    
    .promocode-card::before {
        width: 22px;
        height: 22px;
        font-size: 11px;
    }
    
    .modal-content {
        width: 95%;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .modal-code {
        font-size: 1.2em;
    }
    
    .tag-link {
        padding: 8px 12px;
    }
    
    .tag-emoji {
        font-size: 1.2em;
    }
    
    .tag-name {
        display: inline-block !important;
        font-size: 0.9em;
    }
    
    .modal-link-btn {
        padding: 10px 20px;
        font-size: 14px;
        width: 100%;
    }
}