/* 
   IronPeak Construction
   Professional CSS Theme
   ---------------------
   Fonts: 'Montserrat', sans-serif (Headers) | 'Roboto', sans-serif (Body)
   Colors: Iron Slate (#1a252f), Peak Orange (#e67e22), Concrete (#ecf0f1)
*/

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700;900&family=Roboto:wght@300;400;500&display=swap');

:root {
    --primary-color: #e67e22; /* Peak Orange */
    --secondary-color: #1a252f; /* Iron Slate */
    --dark-bg: #12181e;
    --light-bg: #f4f6f7;
    --text-color: #34495e;
    --text-light: #ecf0f1;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --shadow: 0 10px 30px rgba(0,0,0,0.1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #fff;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    color: var(--secondary-color);
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

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

ul {
    list-style: none;
}

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

/* ====================
   Navigation
   ==================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition);
    background: transparent;
    padding: 1.5rem 0;
}

.header.scrolled {
    background: rgba(26, 37, 47, 0.95);
    padding: 1rem 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    backdrop-filter: blur(10px);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    font-size: 1.8rem;
    font-weight: 900;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo span {
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: #fff;
    font-weight: 500;
    font-size: 0.9rem;
    position: relative;
}

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

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.nav-link.active {
    color: var(--primary-color);
}

.mobile-toggle {
    display: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ====================
   Hero Section
   ==================== */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: -2;
    transform: scale(1.1);
    transition: transform 10s ease;
}

.hero.active .hero-bg {
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.7));
    z-index: -1;
}

.hero-content {
    max-width: 800px;
    padding: 0 20px;
    z-index: 1;
}

.hero-title {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s forwards 0.5s;
}

.hero-tagline {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 2.5rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s forwards 0.8s;
}

.btn {
    display: inline-block;
    padding: 15px 40px;
    background: var(--primary-color);
    color: #fff;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 2px solid var(--primary-color);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #fff;
    z-index: -1;
    transition: var(--transition);
}

.btn:hover::before {
    left: 0;
}

.btn:hover {
    color: var(--primary-color);
}

.btn-outline {
    background: transparent;
    border: 2px solid #fff;
    margin-left: 15px;
}

.btn-outline:hover {
    background: #fff;
    color: var(--secondary-color);
    border-color: #fff;
}

/* ====================
   Sections & Layout
   ==================== */
.section {
    padding: 100px 0;
}

.bg-light {
    background: var(--light-bg);
}

.bg-dark {
    background: var(--secondary-color);
    color: #fff;
}

.bg-dark h2 {
    color: #fff;
}

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

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 2.5rem;
    display: inline-block;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--primary-color);
}

.section-subtitle {
    display: block;
    font-family: 'Roboto', sans-serif;
    font-size: 1.1rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
    font-weight: 700;
}

/* ====================
   Stats Counter
   ==================== */
.stats-section {
    background: var(--primary-color);
    padding: 60px 0;
    color: #fff;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    text-align: center;
}

.stat-item h3 {
    font-size: 3.5rem;
    color: #fff;
    margin-bottom: 0.5rem;
}

.stat-item p {
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

/* ====================
   Services Grid
   ==================== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background: #fff;
    padding: 40px 30px;
    border-bottom: 4px solid transparent;
    transition: var(--transition);
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-10px);
    border-bottom-color: var(--primary-color);
}

.service-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

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

.read-more {
    margin-top: 20px;
    display: inline-block;
    color: var(--primary-color);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
}

/* ====================
   Projects Carousel
   ==================== */
.project-wrapper {
    position: relative;
    overflow: hidden;
    padding: 20px 0;
}

.project-track {
    display: flex;
    gap: 30px;
    transition: transform 0.5s ease;
}

.project-card {
    min-width: 100%;
    height: 500px;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
}

@media (min-width: 768px) {
    .project-card {
        min-width: calc(50% - 15px);
    }
}

@media (min-width: 1024px) {
    .project-card {
        min-width: calc(33.333% - 20px);
    }
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.project-card:hover .project-img {
    transform: scale(1.1);
}

.project-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    padding: 30px;
    color: #fff;
    transform: translateY(20px);
    opacity: 0.9;
    transition: var(--transition);
}

.project-card:hover .project-info {
    transform: translateY(0);
    opacity: 1;
}

.project-cat {
    color: var(--primary-color);
    text-transform: uppercase;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 5px;
    display: block;
}

.project-controls {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
}

.control-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--secondary-color);
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.control-btn:hover {
    background: var(--secondary-color);
    color: #fff;
}

/* ====================
   Projects Grid & Filter
   ==================== */
.filter-btns {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 50px;
}

.filter-btn {
    padding: 10px 25px;
    background: transparent;
    border: 2px solid #ddd;
    color: var(--text-color);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn.active, .filter-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

/* ====================
   Team Flip Cards
   ==================== */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 40px;
}

.team-card {
    background-color: transparent;
    height: 400px;
    perspective: 1000px;
}

.team-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    box-shadow: var(--shadow);
}

.team-card:hover .team-inner {
    transform: rotateY(180deg);
}

.team-front, .team-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: hidden;
}

.team-front img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}

.team-info-front {
    position: relative;
    background: #fff;
    padding: 20px;
    text-align: center;
}

.team-back {
    background-color: var(--secondary-color);
    color: white;
    transform: rotateY(180deg);
    padding: 40px;
    justify-content: center;
}

.social-links a {
    color: #fff;
    margin: 0 10px;
    font-size: 1.2rem;
}

.social-links a:hover {
    color: var(--primary-color);
}

/* ====================
   Timeline (About)
   ==================== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.timeline-item {
    padding: 10px 40px;
    position: relative;
    width: 50%;
    box-sizing: border-box;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.timeline-item.left {
    left: 0;
}

.timeline-item.right {
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: #fff;
    border: 4px solid var(--secondary-color);
    border-radius: 50%;
    top: 15px;
    z-index: 1;
}

.timeline-item.left::after {
    right: -14px;
}

.timeline-item.right::after {
    left: -14px;
}

.timeline-content {
    padding: 20px 30px;
    background-color: #fff;
    position: relative;
    border-radius: 6px;
    box-shadow: var(--shadow);
}

/* ====================
   Contact Form
   ==================== */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-form input, .contact-form textarea {
    width: 100%;
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    background: #f9f9f9;
    font-family: inherit;
    transition: var(--transition);
}

.contact-form input:focus, .contact-form textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    background: #fff;
}

.input-error {
    border-color: #e74c3c !important;
}

.error-msg {
    color: #e74c3c;
    font-size: 0.8rem;
    margin-top: -15px;
    margin-bottom: 15px;
    display: block;
}

/* ====================
   Accordion (FAQ)
   ==================== */
.accordion-item {
    border-bottom: 1px solid #ddd;
    margin-bottom: 10px;
}

.accordion-header {
    padding: 20px;
    background: #fff;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 700;
    color: var(--secondary-color);
}

.accordion-icon {
    transition: transform 0.3s ease;
}

.accordion-item.active .accordion-icon {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: #f9f9f9;
}

.accordion-content p {
    padding: 20px;
}

/* ====================
   Modal
   ==================== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    background: #fff;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.modal.active .modal-content {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 2rem;
    cursor: pointer;
    color: #333;
    z-index: 10;
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.modal-img img {
    height: 100%;
    object-fit: cover;
}

.modal-text {
    padding: 40px;
}

/* ====================
   Footer
   ==================== */
.footer {
    background: #151515;
    color: #7f8c8d;
    padding: 80px 0 30px;
}

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

.footer h4 {
    color: #fff;
    margin-bottom: 25px;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 30px;
    text-align: center;
    font-size: 0.9rem;
}

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

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ====================
   Mobile Responsive
   ==================== */
@media (max-width: 768px) {
    .header {
        padding: 1rem 0;
    }
    
    .mobile-toggle {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background: #fff;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.5s ease;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-link {
        color: var(--secondary-color);
        font-size: 1.2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .contact-wrapper, .modal-body {
        grid-template-columns: 1fr;
    }

    .timeline::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }

    .timeline-item::after {
        left: 21px;
    }

    .timeline-item.right {
        left: 0;
    }

    .modal-img {
        height: 300px;
    }
}
