/**
 * Ünlüoğlu İnşaat - Custom Styles
 * Additional styles for theme customization
 */

/* Menu Toggle Animation */
.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Body Menu Open State */
body.menu-open {
    overflow: hidden;
}

/* Notification Animation */
@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 2rem;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.5);
    color: #fff;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.25rem;
    box-shadow: 0 4px 20px rgba(196, 30, 58, 0.3);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-5px);
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s ease-in-out infinite;
}

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

/* Service Page Content Styling */
.service-content-main h2 {
    color: var(--primary-dark);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.service-content-main h3 {
    color: var(--primary-dark);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.service-content-main ul {
    margin: 1.5rem 0;
    padding-left: 0;
}

.service-content-main ul li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    color: var(--gray-700);
    line-height: 1.7;
}

.service-content-main ul li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--primary-red);
    margin-top: 3px;
    flex-shrink: 0;
}

/* Project Detail Page */
.project-detail-header {
    margin-bottom: 2rem;
}

.project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin: 2rem 0;
    padding: 30px;
    background: var(--gray-50);
    border-radius: var(--radius-lg);
}

.project-meta-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.project-meta-item i {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-red);
    color: #fff;
    border-radius: 50%;
}

.project-meta-item span {
    color: var(--gray-600);
    font-size: 0.875rem;
}

.project-meta-item strong {
    display: block;
    color: var(--primary-dark);
    font-size: 1rem;
}

/* Project Gallery Grid */
.project-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 2rem 0;
}

.project-gallery-grid img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition-normal);
}

.project-gallery-grid img:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-lg);
}

/* Stats Section */
.stats-section {
    background: var(--primary-dark);
    padding: 80px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.stat-item {
    text-align: center;
    color: #fff;
}

.stat-number {
    font-family: var(--font-secondary);
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 10px;
    color: var(--primary-red);
}

.stat-label {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 50px;
}

.pagination .page-numbers {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    color: var(--gray-700);
    font-weight: 500;
    transition: var(--transition-normal);
}

.pagination .page-numbers:hover,
.pagination .page-numbers.current {
    background: var(--primary-red);
    color: #fff;
}

/* Form Validation States */
.form-group input.error,
.form-group textarea.error,
.form-group select.error {
    border-color: #dc3545;
}

.form-group input.success,
.form-group textarea.success,
.form-group select.success {
    border-color: #28a745;
}

.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 5px;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
    }
    
    .back-to-top {
        bottom: 85px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .project-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .project-meta {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .project-gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
}

/* ==========================================
   QUOTE/SLOGAN SECTION
========================================== */
.quote-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.quote-box {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
    padding: 50px 40px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    position: relative;
    border-left: 5px solid #C41E3A;
}

.quote-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    background: linear-gradient(135deg, #C41E3A 0%, #a01830 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quote-icon i {
    font-size: 32px;
    color: #fff;
}

.quote-box blockquote {
    font-family: 'Lexend', sans-serif;
    font-size: 1.5rem;
    font-weight: 500;
    color: #2D2A4A;
    line-height: 1.6;
    margin: 0 0 20px 0;
    font-style: italic;
}

.quote-box cite {
    font-size: 1rem;
    color: #C41E3A;
    font-weight: 600;
    font-style: normal;
}

/* ==========================================
   STATS SECTION
========================================== */
.stats-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #2D2A4A 0%, #1d1a3a 100%);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.stat-item {
    text-align: center;
    padding: 30px 20px;
}

.stat-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    background: rgba(196, 30, 58, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon i {
    font-size: 28px;
    color: #C41E3A;
}

.stat-number {
    font-family: 'Lexend', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: #fff;
    line-height: 1;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1rem;
    color: rgba(255,255,255,0.7);
}

@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .quote-box blockquote {
        font-size: 1.2rem;
    }
    
    .quote-box {
        padding: 40px 25px;
    }
}

/* ==========================================
   MEGA MENU STYLES
========================================== */
.has-mega-menu {
    position: relative;
}

.has-mega-menu > a {
    display: flex;
    align-items: center;
    gap: 6px;
}

.has-mega-menu > a i {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.has-mega-menu:hover > a i {
    transform: rotate(180deg);
}

.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    width: 580px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    padding-top: 20px;
}

.has-mega-menu:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.mega-menu::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid #fff;
}

.mega-menu-inner {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 20px 25px;
}

.mega-menu-column {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.mega-menu-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.mega-menu-item:hover {
    background: linear-gradient(135deg, rgba(196,30,58,0.08) 0%, rgba(45,42,74,0.08) 100%);
}

.mega-menu-item i {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #C41E3A 0%, #a01830 100%);
    color: #fff;
    border-radius: 10px;
    font-size: 18px;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.mega-menu-item:hover i {
    transform: scale(1.1);
}

.mega-menu-item div {
    display: flex;
    flex-direction: column;
}

.mega-title {
    font-weight: 600;
    color: #2D2A4A;
    font-size: 0.95rem;
    margin-bottom: 3px;
}

.mega-desc {
    font-size: 0.8rem;
    color: #6c757d;
}

.mega-menu-footer {
    border-top: 1px solid #eee;
    padding: 15px 25px;
    text-align: center;
    background: #f8f9fa;
    border-radius: 0 0 16px 16px;
}

.mega-menu-footer a {
    color: #C41E3A;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.mega-menu-footer a:hover {
    gap: 12px;
}

.mega-menu-footer a i {
    font-size: 12px;
}

/* ==========================================
   HEADER CTA BUTTONS
========================================== */
.header-cta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.header-btn i {
    font-size: 16px;
}

.btn-call {
    background: linear-gradient(135deg, #C41E3A 0%, #a01830 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(196, 30, 58, 0.3);
}

.btn-call:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(196, 30, 58, 0.4);
    color: #fff;
}

.btn-quote {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.btn-quote:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
    color: #fff;
}

/* Header scrolled button adjustments */
.site-header.scrolled .btn-call,
.site-header.scrolled .btn-quote {
    padding: 10px 16px;
}

/* ==========================================
   RESPONSIVE MEGA MENU & BUTTONS
========================================== */
@media (max-width: 1200px) {
    .mega-menu {
        width: 500px;
    }
    
    .header-btn span {
        display: none;
    }
    
    .header-btn {
        width: 44px;
        height: 44px;
        padding: 0;
        justify-content: center;
    }
    
    .header-btn i {
        margin: 0;
    }
}

@media (max-width: 992px) {
    .mega-menu {
        display: none !important;
    }
    
    .has-mega-menu > a i {
        display: none;
    }
    
    .header-cta {
        display: none;
    }
}

/* Print Styles */
@media print {
    .site-header,
    .cta-section,
    .site-footer,
    .whatsapp-float,
    .back-to-top {
        display: none !important;
    }
    
    .page-header {
        background: none !important;
        height: auto;
        padding: 20px 0;
    }
    
    .page-header::before {
        display: none;
    }
    
    .page-title {
        color: #000 !important;
    }
}

.mega-menu-item .mega-desc {
    text-transform: none !important;
}
