/* ===================================
   SO&G HOME IMPROVEMENT - PROFESSIONAL STYLES
   Advanced CSS with SEO & UX Optimization
   =================================== */

/* CSS Variables for Easy Customization */
:root {
    --primary-red: #C41E3A;
    --dark-red: #8B1424;
    --black: #1a1a1a;
    --dark-gray: #2c2c2c;
    --white: #ffffff;
    --light-gray: #f5f5f5;
    --text-dark: #333333;
    --text-gray: #666666;
    --border-color: #dddddd;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
    --shadow-xl: 0 20px 40px rgba(0,0,0,0.2);
    
    /* Transitions */
    --transition: all 0.3s ease;
    --transition-fast: all 0.15s ease;
    --transition-slow: all 0.5s ease;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    overflow-x: hidden;
    background: var(--white);
}

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

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(37,211,102,0.4);
    z-index: 9999;
    transition: var(--transition);
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37,211,102,0.6);
}

.whatsapp-float svg {
    width: 35px;
    height: 35px;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Top Bar */
.top-bar {
    background: var(--black);
    color: var(--white);
    padding: 10px 0;
    font-size: 14px;
}

.top-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-phone {
    color: var(--primary-red);
    font-weight: 600;
    padding: 5px 15px;
    border: 1px solid var(--primary-red);
    border-radius: 20px;
    transition: var(--transition);
}

.top-phone:hover {
    background: var(--primary-red);
    color: var(--white);
}

/* Navigation */
.navbar {
    background: var(--white);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-md);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: 60px;
    width: auto;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-red);
    transition: var(--transition);
}

.nav-menu a:hover::after {
    width: 100%;
}

.nav-menu a:hover {
    color: var(--primary-red);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    transition: var(--transition);
}

/* Hero Section */
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--black) 0%, var(--dark-gray) 100%);
    position: relative;
    overflow: hidden;
    margin-top: -10px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(196,30,58,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.3), rgba(0,0,0,0.5));
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    animation: fadeInUp 0.8s ease;
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    animation: fadeInUp 0.8s ease 0.2s backwards;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 0.8s ease 0.4s backwards;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 35px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 5px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    text-align: center;
}

.btn-primary {
    background: var(--primary-red);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(196,30,58,0.3);
}

.btn-primary:hover {
    background: var(--dark-red);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(196,30,58,0.4);
}

.btn-whatsapp {
    background: #25D366;
    color: var(--white);
    box-shadow: 0 4px 15px rgba(37,211,102,0.3);
}

.btn-whatsapp:hover {
    background: #1da851;
    transform: translateY(-2px);
}

/* Section Styles */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: var(--text-dark);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary-red);
    margin: 20px auto 0;
}

/* Services Section */
.services {
    background: var(--light-gray);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.service-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.service-card h3 {
    font-size: 1.5rem;
    margin: 20px 0 15px;
    color: var(--text-dark);
}

.service-card p {
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 20px;
}

.service-btn {
    display: inline-block;
    padding: 10px 25px;
    background: var(--primary-red);
    color: var(--white);
    border-radius: 5px;
    font-weight: 600;
    transition: var(--transition);
}

.service-btn:hover {
    background: var(--dark-red);
    transform: scale(1.05);
}

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.gallery-item {
    aspect-ratio: 4/3;
    background: linear-gradient(135deg, #f5f5f5 0%, #e0e0e0 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-gray);
    transition: var(--transition);
    overflow: hidden;
}

.gallery-item:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Testimonials */
.testimonials {
    background: var(--light-gray);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.testimonial-card {
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stars {
    color: #FFD700;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.testimonial-card p {
    font-style: italic;
    margin-bottom: 15px;
    color: var(--text-gray);
}

.testimonial-card strong {
    color: var(--text-dark);
}

/* Quote Form */
.quote-section {
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--dark-red) 100%);
    color: var(--white);
}

.quote-section h2 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2.5rem;
}

.quote-form {
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: 40px;
    border-radius: 10px;
    box-shadow: var(--shadow-xl);
}

.quote-form input,
.quote-form select,
.quote-form textarea {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.quote-form input:focus,
.quote-form select:focus,
.quote-form textarea:focus {
    outline: none;
    border-color: var(--primary-red);
    box-shadow: 0 0 0 3px rgba(196,30,58,0.1);
}

.quote-form button {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
}

/* Contact */
.contact {
    background: var(--light-gray);
}

.contact-info {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.contact-info p {
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.contact-info a {
    color: var(--primary-red);
    font-weight: 600;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* Footer */
.footer {
    background: var(--black);
    color: var(--white);
    padding: 40px 0 20px;
    text-align: center;
}

.footer-logo {
    height: 80px;
    width: auto;
    margin: 0 auto 20px;
}

.footer p {
    margin-bottom: 10px;
    opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 90px;
        flex-direction: column;
        background: var(--white);
        width: 100%;
        text-align: center;
        transition: var(--transition);
        box-shadow: var(--shadow-lg);
        padding: 30px 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-content p {
        font-size: 1.2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .whatsapp-float {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }
    
    .whatsapp-float svg {
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }
    
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .logo {
        height: 50px;
    }
}

/* Loading Animation */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

body {
    animation: fadeIn 0.5s ease;
}

/* Utility Classes */
.text-center { text-align: center; }
.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }
