/* ============================================================================
   COMPONENTS CSS
   Component-specific styles separated from main style.css for better organization
   ============================================================================ */

/* Feature Cards */
.feature-card {
    background: #fff;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 160px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
}

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

.feature-card h4 {
    margin-bottom: 0.5rem;
    color: #2c3e50;
    font-size: 1.3rem;
}

.feature-card p {
    margin: 0;
    color: #7f8c8d;
    font-size: 1rem;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Image Carousel Section */
.image-carousel-container {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 3rem auto 0;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    background: #ecf0f1;
}

.image-carousel {
    position: relative;
    width: 100%;
    height: 600px;
    overflow: hidden;
}

.carousel-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
    object-fit: cover;
    object-position: center;
    background: #ecf0f1;
}

.carousel-image.active {
    opacity: 1;
    z-index: 1;
}

.carousel-image[src] {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.carousel-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #7f8c8d;
    font-size: 1.2rem;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(44, 62, 80, 0.8);
    color: #fff;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 2rem;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    user-select: none;
}

.carousel-btn:hover {
    background: rgba(44, 62, 80, 1);
    transform: translateY(-50%) scale(1.1);
}

.carousel-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.carousel-btn-prev {
    left: 20px;
}

.carousel-btn-next {
    right: 20px;
}

.carousel-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.service-card {
    background: #fff;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border-top: 4px solid transparent;
}

.service-card:nth-child(1) {
    border-top-color: #e74c3c;
}

.service-card:nth-child(2) {
    border-top-color: #f39c12;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #2c3e50;
}

.service-list {
    list-style: none;
    margin-top: 1rem;
}

.service-list li {
    padding: 0.3rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.service-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #27ae60;
    font-weight: bold;
}

/* Form Styles */
.form-container {
    background: #fff;
    padding: 2.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    max-width: 800px;
    margin: 0 auto;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group.full-width {
    grid-column: span 2;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #2c3e50;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #e74c3c;
}

.form-group textarea {
    height: 120px;
    resize: vertical;
}

.submit-btn {
    background: linear-gradient(45deg, #e74c3c, #f39c12);
    color: #fff;
    padding: 1rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.3);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-loader {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

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

.contact-item {
    text-align: center;
    padding: 1.5rem;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.contact-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #e74c3c;
}

/* Phone Number */
.phone-number {
    color: #2c3e50;
    text-decoration: none;
    transition: all 0.3s ease;
}

.phone-number:hover {
    color: #e74c3c;
    transform: translateY(-2px);
}

/* Footer */
footer {
    background: #2c3e50;
    color: #fff;
    padding: 2rem 0;
    text-align: center;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

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

.footer-links li {
    margin: 0.5rem 0;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

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

/* Success Message */
.success-message {
    background: #27ae60;
    color: #fff;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    display: none;
}

/* Error Message */
.error-message {
    background: #e74c3c;
    color: #fff;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    display: none;
}

/* Responsive Design for Components */
@media (max-width: 1024px) {
    .image-carousel {
        height: 500px;
    }
}

@media (max-width: 768px) {
    .image-carousel {
        height: 350px;
    }

    .carousel-btn {
        width: 40px;
        height: 40px;
        font-size: 1.5rem;
    }

    .carousel-btn-prev {
        left: 10px;
    }

    .carousel-btn-next {
        right: 10px;
    }

    .feature-card {
        min-height: 120px;
        padding: 1.5rem;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-group.full-width {
        grid-column: span 1;
    }

    .service-card img {
        height: 150px !important;
    }
}

