/* Pizoni Painting Company Styles */
:root {
    --primary-color: #2E8B57; /* Sea Green - painting theme */
    --secondary-color: #ffffff;
    --text-color: #333333;
    --button-color: #FF6B35; /* Orange accent */
    --light-gray: #f8f9fa;
    --dark-gray: #343a40;
    --success-green: #28a745;
    --warning-orange: #fd7e14;
    --info-blue: #17a2b8;
    --white: #ffffff;
}

/* Reset and Base Styles */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    margin: 0;
    padding: 0;
    background-color: var(--secondary-color);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-color);
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    line-height: 1.7;
}

/* Header Styles */
header {
    background-color: var(--secondary-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary-color) !important;
}

.navbar-nav .nav-link {
    font-weight: 500;
    color: var(--text-color) !important;
    margin: 0 0.5rem;
    padding: 0.5rem 1rem !important;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.navbar-nav .nav-link:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color) !important;
    transform: translateY(-2px);
}

/* Breadcrumbs */
.breadcrumb {
    background-color: transparent;
    padding: 0.5rem 0;
    margin-bottom: 0;
    font-size: 0.9rem;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    color: var(--primary-color);
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb-item a:hover {
    text-decoration: underline;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, #228B22 100%);
    color: var(--secondary-color);
    padding: 4rem 0;
    min-height: 500px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('/images/painting-pattern.png') repeat;
    opacity: 0.1;
    z-index: 1;
}

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

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    color: var(--white) !important;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    color: var(--white) !important;
}

/* Page Header Styles - БЕЛЫЕ ЗАГОЛОВКИ НА ВСЕХ СТРАНИЦАХ */
.page-header {
    background: linear-gradient(135deg, var(--primary-color), #228B22);
    color: var(--secondary-color);
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    color: var(--white) !important;
}

/* Buttons */
.cta-button, .btn-primary {
    background: linear-gradient(45deg, var(--button-color), #ff8c42);
    color: var(--secondary-color);
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    display: inline-block;
    margin-top: 20px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cta-button:hover, .btn-primary:hover {
    background: linear-gradient(45deg, #ff8c42, var(--button-color));
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
    color: var(--secondary-color);
    text-decoration: none;
}

.secondary-button {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
    padding: 10px 25px;
    border-radius: 50px;
    text-decoration: none;
    display: inline-block;
    margin-top: 20px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.secondary-button:hover {
    background-color: var(--white);
    color: var(--primary-color);
    text-decoration: none;
    transform: translateY(-2px);
}

/* Services Section */
.services {
    padding: 5rem 0;
    background-color: var(--light-gray);
}

.service-item {
    background-color: var(--secondary-color);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 25px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    height: 100%;
    border: 1px solid #e9ecef;
}

.service-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(46, 139, 87, 0.15);
    border-color: var(--primary-color);
}

.service-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 1.5rem;
}

.service-item h3 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.service-item p {
    color: #666;
    line-height: 1.6;
}

/* Pricing */
.pricing {
    background: linear-gradient(135deg, var(--primary-color), #228B22);
    color: var(--secondary-color);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: 600;
    display: inline-block;
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

.old-price {
    text-decoration: line-through;
    color: #999;
    margin-right: 10px;
}

/* Testimonials */
.testimonials {
    background-color: var(--light-gray);
    padding: 5rem 0;
}

.testimonial-item {
    background-color: var(--secondary-color);
    padding: 2rem;
    border-radius: 15px;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    border-left: 5px solid var(--primary-color);
    position: relative;
}

.testimonial-item::before {
    content: '"';
    font-size: 4rem;
    color: var(--primary-color);
    position: absolute;
    top: -10px;
    left: 20px;
    font-family: Georgia, serif;
    opacity: 0.3;
}

.testimonial-item p {
    font-style: italic;
    margin-bottom: 1rem;
    padding-left: 2rem;
    line-height: 1.7;
}

.testimonial-item strong {
    color: var(--primary-color);
    font-weight: 600;
}

/* Contact Form */
.contact-section {
    padding: 5rem 0;
    background-color: var(--secondary-color);
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background-color: var(--light-gray);
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

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

.form-control {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 15px;
    font-size: 16px;
    transition: all 0.3s ease;
    background-color: var(--secondary-color);
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(46, 139, 87, 0.25);
    background-color: var(--secondary-color);
}

.form-control::placeholder {
    color: #999;
}

/* Articles Section */
.articles {
    padding: 5rem 0;
    background-color: var(--secondary-color);
}

.card {
    border: none;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    height: 100%;
}

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

.card-img-top {
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.card:hover .card-img-top {
    transform: scale(1.05);
}

.card-body {
    padding: 1.5rem;
    background-color: var(--secondary-color);
}

.card-title {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

.card-title a {
    color: var(--primary-color);
    text-decoration: none;
}

.card-title a:hover {
    color: var(--button-color);
    text-decoration: none;
}

.card-text {
    color: #666;
    line-height: 1.6;
}

.text-muted {
    color: #999 !important;
    font-size: 0.9rem;
}

/* Pagination */
.pagination {
    margin-top: 3rem;
}

.page-link {
    color: var(--primary-color);
    border-color: var(--primary-color);
    padding: 10px 15px;
    margin: 0 2px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.page-link:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border-color: var(--primary-color);
}

.page-item.active .page-link {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Services Page specific styles */
.services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.service-cta-btn {
    background-color: var(--button-color);
    color: var(--white);
    padding: 12px 24px;
    text-decoration: none;
    display: inline-block;
    border-radius: 5px;
    margin-top: 1rem;
    font-weight: bold;
    font-size: 1rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.service-cta-btn:hover {
    background-color: #ff8c42;
    color: var(--white);
    text-decoration: none;
    transform: translateY(-2px);
}

/* Portfolio Page Styles */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.portfolio-item {
    background-color: var(--white);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(46, 139, 87, 0.15);
}

.portfolio-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-item:hover img {
    transform: scale(1.05);
}

.portfolio-content {
    padding: 1.5rem;
}

.portfolio-category {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1rem;
}

/* Footer */
footer {
    background-color: var(--dark-gray);
    color: var(--secondary-color);
    padding: 3rem 0 1rem;
}

footer h3, footer h4 {
    color: var(--secondary-color);
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

footer ul {
    list-style: none;
    padding: 0;
}

footer ul li {
    margin-bottom: 0.5rem;
}

footer ul li a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer ul li a:hover {
    color: var(--secondary-color);
    text-decoration: none;
}

footer p {
    color: #ccc;
    margin-bottom: 0.5rem;
}

footer a {
    color: var(--secondary-color);
    text-decoration: none;
}

footer a:hover {
    color: var(--button-color);
    text-decoration: none;
}

/* WhatsApp Button */
.whatsapp-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #25D366;
    color: white;
    padding: 15px 20px;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.whatsapp-button:hover {
    background-color: #128C7E;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
    color: white;
    text-decoration: none;
}

.whatsapp-button img {
    width: 24px;
    height: 24px;
}

/* Scroll to Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 80px;
    right: 20px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(46, 139, 87, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 1.2rem;
}

.scroll-top-btn:hover {
    background-color: #228B22;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(46, 139, 87, 0.4);
}

/* Alerts */
.alert {
    border-radius: 10px;
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    border: none;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

/* Loading States */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Text color helpers */
.text-white {
    color: var(--white) !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .service-item {
        margin-bottom: 2rem;
    }
    
    .contact-form {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }
    
    .whatsapp-button {
        bottom: 15px;
        right: 15px;
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .whatsapp-button span {
        display: none;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .hero {
        padding: 3rem 0;
        min-height: 400px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .services, .testimonials, .contact-section, .articles {
        padding: 3rem 0;
    }
    
    .cta-button, .btn-primary {
        padding: 10px 20px;
        font-size: 16px;
    }
}

/* Performance Optimizations */
.img-fluid {
    height: auto;
    max-width: 100%;
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus States */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .hero {
        background: var(--primary-color);
    }
    
    .service-item {
        border: 2px solid var(--text-color);
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Scroll to Top Button - точно как в 3-й работе */
.scroll-top-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(46, 139, 87, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scroll-top-btn:hover {
    background-color: #228B22;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(46, 139, 87, 0.4);
}