/* Custom CSS for WiseWriters */

:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    scroll-behavior: smooth;
}

/* Navigation */
.navbar {
    transition: all 0.3s ease;
    z-index: 1000;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

.whatsapp-nav {
    background: var(--success-color);
    color: white !important;
    border-radius: 20px;
    padding: 8px 15px !important;
    transition: all 0.3s ease;
}

.whatsapp-nav:hover {
    background: #218838;
    transform: translateY(-2px);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-buttons .btn {
    margin: 5px;
    padding: 12px 30px;
    font-weight: 600;
    border-radius: 30px;
    transition: all 0.3s ease;
}

.hero-buttons .btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.hero-stats {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
}

.stat-item {
    display: flex;
    align-items: center;
    font-weight: 500;
}

.hero-image svg {
    width: 100%;
    height: auto;
    max-width: 500px;
}

/* Service Cards */
.service-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
    font-size: 2rem;
}

.service-card h4 {
    color: var(--dark-color);
    margin-bottom: 15px;
    font-weight: 600;
}

.service-card p {
    color: var(--secondary-color);
    line-height: 1.6;
}

/* Order Form */
.order-form-container {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
}

.form-control, .form-select {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.pricing-info {
    background: var(--light-color);
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
}

.pricing-info ul {
    margin-bottom: 15px;
}

.total-price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
    padding: 10px;
    background: white;
    border-radius: 8px;
    border: 2px solid var(--primary-color);
}

/* Testimonials */
.testimonial-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 100%;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.rating {
    margin-bottom: 15px;
}

.client-info {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

/* FAQ */
.accordion-button {
    font-weight: 600;
    background: var(--light-color);
}

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

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(0, 123, 255, 0.25);
}

/* Blog Cards */
.blog-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 100%;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.blog-image {
    overflow: hidden;
}

.blog-content {
    padding: 25px;
}

.blog-content h4 {
    color: var(--dark-color);
    margin-bottom: 15px;
    font-weight: 600;
}

.blog-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.blog-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    bottom: 100px;
    left: 20px;
    z-index: 1000;
}

.whatsapp-btn {
    width: 60px;
    height: 60px;
    background: var(--success-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
}

.whatsapp-btn:hover {
    background: #218838;
    transform: scale(1.1);
    color: white;
}

.whatsapp-tooltip {
    position: absolute;
    bottom: 70px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--dark-color);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

/* Chat Widget */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 350px;
    height: 400px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: none;
    flex-direction: column;
    z-index: 1001;
}

.chat-header {
    background: var(--primary-color);
    color: white;
    padding: 15px;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: between;
    align-items: center;
}

.chat-header h6 {
    margin: 0;
    flex-grow: 1;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.chat-messages {
    flex-grow: 1;
    padding: 15px;
    overflow-y: auto;
    max-height: 280px;
}

.bot-message, .user-message {
    margin-bottom: 15px;
    padding: 12px;
    border-radius: 10px;
    max-width: 80%;
}

.bot-message {
    background: var(--light-color);
    color: var(--dark-color);
    align-self: flex-start;
}

.user-message {
    background: var(--primary-color);
    color: white;
    align-self: flex-end;
    margin-left: auto;
}

.chat-input {
    padding: 15px;
    display: flex;
    gap: 10px;
    border-top: 1px solid #e9ecef;
}

.chat-input input {
    flex-grow: 1;
    border: 1px solid #e9ecef;
    border-radius: 20px;
    padding: 8px 15px;
    outline: none;
}

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

.chat-input button:hover {
    background: #0056b3;
}

.chat-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.4);
    transition: all 0.3s ease;
    z-index: 1000;
}

.chat-toggle:hover {
    background: #0056b3;
    transform: scale(1.1);
}

/* Footer */
footer {
    background: var(--dark-color) !important;
}

footer a {
    transition: all 0.3s ease;
}

footer a:hover {
    color: var(--primary-color) !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        padding: 60px 0;
    }
    
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .service-card {
        margin-bottom: 30px;
    }
    
    .order-form-container {
        padding: 25px;
    }
    
    .chat-widget {
        width: 300px;
        height: 350px;
        right: 10px;
        bottom: 10px;
    }
    
    .whatsapp-float {
        bottom: 80px;
        left: 15px;
    }
    
    .hero-stats {
        margin-top: 30px;
    }
    
    .stat-item {
        justify-content: center;
        margin-bottom: 10px;
    }
}

@media (max-width: 576px) {
    .hero-buttons .btn {
        display: block;
        margin: 10px 0;
        width: 100%;
    }
    
    .service-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .testimonial-card, .blog-card {
        margin-bottom: 20px;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.service-card, .testimonial-card, .blog-card {
    animation: fadeInUp 0.6s ease forwards;
}

/* Loading States */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Form Validation Styles */
.was-validated .form-control:valid,
.was-validated .form-select:valid {
    border-color: var(--success-color);
}

.was-validated .form-control:invalid,
.was-validated .form-select:invalid {
    border-color: var(--danger-color);
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.border-radius-custom {
    border-radius: 15px;
}
