/* ============================================
   components.css - Переиспользуемые компоненты
   ============================================ */

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 100px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
    color: white;
    box-shadow: 0 4px 16px rgba(255,153,0,0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255,153,0,0.4);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text);
    border: 1.5px solid var(--border);
}

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

.btn-white {
    background: white;
    color: var(--primary-dark);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.btn-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

/* Section headers */
.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 56px;
}

.section-label {
    display: inline-block;
    background: rgba(0,191,255,0.1);
    color: var(--primary-dark);
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
}

.section-title {
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 16px;
}

.section-desc {
    color: var(--text-light);
    font-size: 16px;
}

/* Cards */
.service-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: transparent;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-icon {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, rgba(0,191,255,0.1), rgba(255,153,0,0.1));
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    color: var(--primary);
}

.service-icon svg,
.service-icon img {
    width: 28px;
    height: 28px;
}

.service-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.service-card p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
}

/* Case cards */
.case-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.case-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.case-image {
    height: 180px;
    background: linear-gradient(135deg, rgba(0,191,255,0.15), rgba(255,153,0,0.15));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.case-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,0.05) 100%);
}

.case-image svg,
.case-image img {
    width: 48px;
    height: 48px;
    position: relative;
    z-index: 2;
    color: var(--primary);
}

.case-content {
    padding: 28px;
}

.case-tag {
    display: inline-block;
    background: rgba(0,191,255,0.1);
    color: var(--primary-dark);
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}

.case-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.case-card p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 16px;
}

.case-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.case-link:hover {
    gap: 10px;
}

/* Contact cards */
.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center;
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    display: block;
}

.contact-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.contact-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, rgba(0,191,255,0.1), rgba(255,153,0,0.1));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    color: var(--primary);
}

.contact-icon svg,
.contact-icon img {
    width: 28px;
    height: 28px;
}

.contact-card h3 {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 6px;
}

.contact-card p {
    color: var(--text-muted);
    font-size: 14px;
}

/* FAQ */
.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    overflow: hidden;
    transition: var(--transition);
}

.faq-item.active {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.faq-question {
    width: 100%;
    padding: 20px 24px;
    background: none;
    border: none;
    text-align: left;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    color: var(--primary);
}

.faq-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
    margin-left: 12px;
}

.faq-item.active .faq-icon {
    background: var(--primary);
    color: white;
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 300px;
    padding: 0 24px 20px;
}

.faq-answer p {
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.7;
}

/* Grids */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 24px;
}

.contacts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

/* Mobile */
@media (max-width: 768px) {
    .services-grid,
    .cases-grid {
        grid-template-columns: 1fr;
    }
    .contacts-grid {
        grid-template-columns: 1fr;
    }
}
