/* ============================================
   COMPONENTS CSS - Composants réutilisables
   ============================================ */

/* ===== Boutons ===== */
.btn {
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--border-radius-sm);
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: var(--primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 2px solid var(--accent);
}

.btn-secondary:hover {
    background: var(--accent);
    color: var(--primary);
}

/* ===== Code Block Visual ===== */
.hero-code {
    background: var(--bg-card);
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: var(--border-radius);
    padding: 2rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    position: relative;
    overflow: hidden;
    animation: fadeInRight 0.8s ease-out 0.3s both;
}

.hero-code::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 35px;
    background: var(--bg-elevated);
    border-bottom: 1px solid rgba(0, 217, 255, 0.2);
}

.hero-code::after {
    content: '';
    position: absolute;
    top: 12px;
    left: 15px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--secondary);
    box-shadow: 20px 0 0 var(--accent), 40px 0 0 #4CAF50;
}

.code-content {
    margin-top: 25px;
    line-height: 1.8;
}

.code-line {
    display: block;
    animation: typing 0.5s steps(30) forwards;
    opacity: 0;
}

.code-line:nth-child(1) { animation-delay: 1s; }
.code-line:nth-child(2) { animation-delay: 1.3s; }
.code-line:nth-child(3) { animation-delay: 1.6s; }
.code-line:nth-child(4) { animation-delay: 1.9s; }
.code-line:nth-child(5) { animation-delay: 2.2s; }
.code-line:nth-child(6) { animation-delay: 2.5s; }

@keyframes typing {
    to { opacity: 1; }
}

.code-keyword { color: #FF79C6; }
.code-function { color: var(--accent); }
.code-string { color: #50FA7B; }
.code-comment { color: var(--text-dim); }

/* ===== Service Cards ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--bg-card);
    padding: 2.5rem;
    border-radius: var(--border-radius);
    border: 1px solid rgba(0, 217, 255, 0.1);
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
}

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

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

.service-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
    box-shadow: 0 10px 40px rgba(0, 217, 255, 0.2);
}

.service-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent);
}

.service-card ul {
    margin: 1rem 0;
}

.service-card li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-dim);
}

.service-card li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: var(--accent);
}

/* ===== Stack ===== */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.stack-category {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--accent);
}

.stack-category h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--accent);
    font-family: var(--font-mono);
}

.stack-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.tag {
    padding: 0.5rem 1rem;
    background: rgba(0, 217, 255, 0.1);
    border: 1px solid rgba(0, 217, 255, 0.3);
    border-radius: 6px;
    font-size: 0.9rem;
    font-family: var(--font-mono);
    transition: all var(--transition-fast);
}

.tag:hover {
    background: var(--accent);
    color: var(--primary);
    transform: translateY(-2px);
}

/* ===== Pricing ===== */
.pricing-card {
    background: var(--bg-card);
    padding: 3rem;
    border-radius: var(--border-radius);
    border: 2px solid var(--accent);
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.pricing-card::before {
    content: 'TARIF';
    position: absolute;
    top: 20px;
    right: -30px;
    background: var(--secondary);
    color: white;
    padding: 0.3rem 3rem;
    transform: rotate(45deg);
    font-size: 0.8rem;
    font-weight: 700;
}

.pricing-header {
    text-align: center;
    margin-bottom: 2rem;
}

.pricing-header h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.price {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--accent);
    font-family: var(--font-mono);
}

.price-suffix {
    font-size: 1.2rem;
    color: var(--text-dim);
}

.pricing-features {
    margin: 2rem 0;
}

.pricing-features li {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.pricing-features li::before {
    content: '✓';
    color: var(--accent);
    font-weight: 700;
    font-size: 1.3rem;
}

/* ===== Process Timeline ===== */
.process-timeline {
    position: relative;
    padding-left: 2rem;
}

.process-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--accent), var(--secondary));
}

.process-step {
    position: relative;
    margin-bottom: 3rem;
    padding-left: 2rem;
}

.process-step::before {
    content: '';
    position: absolute;
    left: -2.5rem;
    top: 0;
    width: 20px;
    height: 20px;
    background: var(--accent);
    border: 4px solid var(--bg);
    border-radius: 50%;
}

.process-step h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--accent);
}

.process-step .step-number {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
}

/* ===== Contact ===== */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.contact-item {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: var(--border-radius);
    border: 1px solid rgba(0, 217, 255, 0.1);
    transition: all var(--transition-fast);
    text-align: center;
    min-width: 250px;
    max-width: 280px;
    width: 100%;
    margin: 0 auto;
}

.contact-item:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.2);
}

.contact-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

.contact-item h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--accent);
}

.contact-item a {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    word-break: break-all;
}

.contact-item a:hover {
    color: var(--accent);
}

.social-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* ===== Formulaires ===== */
input, textarea, select {
    width: 100%;
    padding: 1rem;
    background: var(--bg-elevated);
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: var(--border-radius-sm);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 1rem;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--accent);
}

textarea {
    resize: vertical;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text);
    font-weight: 500;
}

/* ============================================
   FAQ SECTION - Accordéons
   ============================================ */

.faq-container {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 1rem;
    background: var(--bg-card);
    border-radius: var(--border-radius);
    border: 1px solid rgba(0, 217, 255, 0.1);
    overflow: hidden;
    transition: all var(--transition-fast);
}

.faq-item:hover {
    border-color: rgba(0, 217, 255, 0.3);
}

.faq-question {
    width: 100%;
    padding: 1.5rem;
    background: transparent;
    border: none;
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 1.1rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all var(--transition-fast);
}

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

.faq-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.faq-question-text {
    flex: 1;
}

.faq-toggle {
    font-size: 1.8rem;
    color: var(--accent);
    font-weight: 300;
    flex-shrink: 0;
    transition: transform var(--transition-fast);
}

/* État ouvert */
.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-item.active {
    border-color: var(--accent);
    box-shadow: 0 5px 20px rgba(0, 217, 255, 0.1);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out, padding 0.4s ease-out;
    padding: 0 1.5rem;
}

.faq-item.active .faq-answer {
    max-height: 1500px;
    padding: 0 1.5rem 1.5rem;
    transition: max-height 0.5s ease-in, padding 0.4s ease-in;
}

.faq-answer p {
    color: var(--text-dim);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-answer strong {
    color: var(--text);
    font-weight: 600;
}

.faq-answer ul,
.faq-answer ol {
    margin: 1rem 0 1rem 1.5rem;
    color: var(--text-dim);
    line-height: 1.8;
}

.faq-answer li {
    margin-bottom: 0.5rem;
}

.faq-answer li strong {
    color: var(--accent);
}

/* CTA après FAQ */
.faq-cta {
    text-align: center;
    margin-top: 3rem;
    padding: 2rem;
    background: rgba(0, 217, 255, 0.05);
    border-radius: var(--border-radius);
    border: 1px solid rgba(0, 217, 255, 0.2);
}

.faq-cta p {
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 1rem;
}