/* Base Styles */
:root {
    --denim: #147cb4;
    --tango: #f18324;
    --soya-bean: #635747;
    --potters-clay: #94653c;
    --limed-spruce: #374c54;
    --tarawera: #093a5c;
    --pickled-bluewood: #2c4454;
    --cape-cod: #434c4c;
    --blue-dianne: #214354;
    --chathams-blue: #143c74;
    
    --white: #ffffff;
    --light-gray: #f8f9fa;
    --medium-gray: #e9ecef;
    --dark-gray: #495057;
    --black: #212529;
    
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --box-shadow-hover: 0 15px 30px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease-in-out;
    --border-radius: 12px;
    --border-radius-sm: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--dark-gray);
    background-color: var(--white);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    color: var(--tarawera);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.8rem;
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
    font-weight: 700;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 5px;
    background: linear-gradient(to right, var(--denim), var(--tango));
    border-radius: 3px;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--pickled-bluewood);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 500;
    text-transform: capitalize;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
    z-index: -1;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    color: var(--white);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(20, 124, 180, 0.3);
}

.btn-secondary {
    background: linear-gradient(135deg, var(--tango) 0%, var(--potters-clay) 100%);
    color: var(--white);
}

.btn-secondary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(241, 131, 36, 0.3);
}

.btn i {
    margin-left: 8px;
    transition: var(--transition);
}

.btn:hover i {
    transform: translateX(5px);
}

/* Header Styles */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    animation: fadeInDown 0.5s ease;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.header .logo img {
    height: 55px;
    width: auto;
    transition: var(--transition);
}

.header.scrolled .logo img {
    height: 45px;
}

.nav-menu {
    display: flex;
}

.nav-item {
    margin-left: 35px;
    position: relative;
}

.nav-link {
    font-weight: 500;
    color: var(--pickled-bluewood);
    transition: var(--transition);
    position: relative;
    padding: 8px 0;
}

.nav-link:hover {
    color: var(--denim);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, var(--denim), var(--tango));
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.mobile-menu {
    display: none;
    cursor: pointer;
    font-size: 24px;
    color: var(--denim);
    transition: var(--transition);
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
}

.mobile-menu:hover {
    color: var(--tango);
}

/* Hero Section */
.hero {
    padding: 180px 0 120px;
    background: linear-gradient(135deg, rgba(20, 60, 116, 0.05) 0%, rgba(255, 255, 255, 1) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -100px;
    right: -100px;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, rgba(20, 124, 180, 0.1) 0%, rgba(241, 131, 36, 0.1) 100%);
    border-radius: 50%;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -100px;
    left: -100px;
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, rgba(241, 131, 36, 0.1) 0%, rgba(20, 124, 180, 0.1) 100%);
    border-radius: 50%;
    z-index: 0;
}

.hero .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    padding-right: 40px;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: var(--tarawera);
    line-height: 1.2;
    font-weight: 700;
    animation: fadeInUp 1s ease;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--pickled-bluewood);
    margin-bottom: 35px;
    animation: fadeInUp 1s ease 0.2s forwards;
    opacity: 0;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    animation: fadeInUp 1s ease 0.4s forwards;
    opacity: 0;
}

.hero-image {
    flex: 1;
    animation: fadeInRight 1s ease;
    position: relative;
}

.hero-image img {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
    transition: var(--transition);
}

.hero-image:hover img {
    transform: perspective(1000px) rotateY(0) rotateX(0);
    box-shadow: var(--box-shadow-hover);
}

/* Clients Section */
.clients {
    padding: 80px 0;
    background-color: var(--light-gray);
}

.clients h3 {
    text-align: center;
    margin-bottom: 40px;
    color: var(--pickled-bluewood);
    font-weight: 500;
    font-size: 1.3rem;
}

.client-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 40px;
}

.client-logo {
    opacity: 0.7;
    transition: var(--transition);
    filter: grayscale(100%);
    padding: 15px;
    background: var(--white);
    border-radius: var(--border-radius-sm);
    box-shadow: var(--box-shadow);
}

.client-logo:hover {
    opacity: 1;
    filter: grayscale(0);
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.client-logo img {
    max-height: 45px;
    width: auto;
}

/* Services Section */
.services {
    padding: 100px 0;
    background-color: var(--white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    padding: 35px 30px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border: 1px solid var(--medium-gray);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--denim), var(--tango));
    transform: scaleX(0);
    transform-origin: left;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
    border-color: transparent;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-icon {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, rgba(20, 124, 180, 0.1) 0%, rgba(241, 131, 36, 0.1) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    color: var(--denim);
    font-size: 2rem;
    transition: var(--transition);
    position: relative;
}

.service-card:hover .service-icon {
    background: linear-gradient(135deg, var(--denim) 0%, var(--tango) 100%);
    color: var(--white);
    transform: rotateY(180deg);
}

.service-card h3 {
    font-size: 1.6rem;
    margin-bottom: 15px;
    color: var(--tarawera);
}

.service-card p {
    margin-bottom: 25px;
    color: var(--pickled-bluewood);
    line-height: 1.6;
}

.service-features {
    text-align: left;
    margin-bottom: 30px;
}

.service-features li {
    margin-bottom: 10px;
    position: relative;
    padding-left: 30px;
    color: var(--pickled-bluewood);
}

.service-features li::before {
    content: '\f00c';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--denim);
    background: rgba(20, 124, 180, 0.1);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

.service-link {
    color: var(--denim);
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.service-link:hover {
    color: var(--chathams-blue);
}

.service-link i {
    margin-left: 8px;
    transition: var(--transition);
}

.service-link:hover i {
    transform: translateX(5px);
}

/* About Section */
.about {
    padding: 100px 0;
    background-color: var(--light-gray);
}

.about .container {
    display: flex;
    align-items: center;
    gap: 60px;
}

.about-content {
    flex: 1;
}

.about-image {
    flex: 1;
    position: relative;
}

.about-image img {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.about-image:hover img {
    transform: scale(1.02);
    box-shadow: var(--box-shadow-hover);
}

.experience-badge {
    position: absolute;
    bottom: -25px;
    right: -25px;
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    color: var(--white);
    width: 130px;
    height: 130px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 15px 35px rgba(20, 124, 180, 0.3);
    animation: pulse 2s infinite;
    z-index: 2;
}

.experience-badge span {
    font-size: 2.8rem;
    font-weight: 700;
    line-height: 1;
}

.experience-badge p {
    font-size: 0.9rem;
    text-align: center;
    margin-top: 5px;
    opacity: 0.9;
}

.mission-vision {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin: 35px 0;
}

.mission, .vision {
    background-color: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.mission:hover, .vision:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.mission h4, .vision h4 {
    color: var(--denim);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    font-size: 1.3rem;
}

.mission h4 i, .vision h4 i {
    margin-right: 12px;
    font-size: 1.5rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 25px;
    margin-top: 45px;
}

.stat {
    text-align: center;
    background-color: var(--white);
    padding: 25px 15px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.stat:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--denim);
    display: block;
    line-height: 1;
    margin-bottom: 8px;
}

.label {
    font-size: 0.95rem;
    color: var(--pickled-bluewood);
    font-weight: 500;
}

/* Portfolio Section */
.portfolio {
    padding: 100px 0;
    background-color: var(--white);
}

.portfolio-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 45px;
}

.filter-btn {
    padding: 10px 24px;
    background-color: var(--light-gray);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    color: var(--pickled-bluewood);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    transition: var(--transition);
    z-index: -1;
    border-radius: 50px;
}

.filter-btn.active, .filter-btn:hover {
    color: white;
}

.filter-btn.active::before, .filter-btn:hover::before {
    width: 100%;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 30px;
}

.portfolio-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    height: 280px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.portfolio-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--box-shadow-hover);
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    bottom: -100%;
    left: 0;
    width: 100%;
    padding: 25px;
    background: linear-gradient(to top, rgba(9, 58, 92, 0.95) 0%, transparent 100%);
    color: var(--white);
    transition: var(--transition);
}

.portfolio-item:hover .portfolio-overlay {
    bottom: 0;
}

.portfolio-overlay h3 {
    margin-bottom: 12px;
    color: var(--white);
    font-size: 1.4rem;
}

.portfolio-overlay p {
    margin-bottom: 18px;
    font-size: 0.95rem;
    opacity: 0.9;
}

.portfolio-link {
    display: inline-flex;
    align-items: center;
    color: var(--white);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

.portfolio-link:hover {
    color: var(--tango);
}

.portfolio-link i {
    margin-left: 8px;
    transition: var(--transition);
}

.portfolio-link:hover i {
    transform: translateX(5px);
}

.portfolio-cta {
    text-align: center;
    margin-top: 60px;
}

.portfolio-cta p {
    font-size: 1.3rem;
    margin-bottom: 25px;
    color: var(--pickled-bluewood);
}

/* Testimonials Section */
.testimonials {
    padding: 100px 0;
    background-color: var(--light-gray);
}

.testimonials-slider {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.testimonial-card {
    background-color: var(--white);
    border-radius: var(--border-radius);
    padding: 35px 30px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 5rem;
    color: rgba(20, 124, 180, 0.1);
    font-family: serif;
    line-height: 1;
}

.testimonial-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.rating {
    color: var(--tango);
    margin-bottom: 25px;
    font-size: 1.1rem;
}

.testimonial-content p {
    font-style: italic;
    margin-bottom: 30px;
    color: var(--pickled-bluewood);
    position: relative;
    line-height: 1.7;
    z-index: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 18px;
    border: 3px solid var(--denim);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.author-info h4 {
    color: var(--tarawera);
    margin-bottom: 5px;
    font-size: 1.2rem;
}

.author-info p {
    font-size: 0.95rem;
    color: var(--pickled-bluewood);
    margin-bottom: 0;
}

.testimonials-cta {
    text-align: center;
    margin-top: 60px;
}

.testimonials-cta p {
    font-size: 1.3rem;
    margin-bottom: 25px;
    color: var(--pickled-bluewood);
}

/* Process Section */
.process {
    padding: 100px 0;
    background-color: var(--white);
}

.process-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 35px;
    counter-reset: step-counter;
}

.process-step {
    position: relative;
    background-color: var(--light-gray);
    padding: 35px 30px 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    counter-increment: step-counter;
}

.process-step:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
    background: linear-gradient(135deg, var(--light-gray) 0%, rgba(20, 124, 180, 0.05) 100%);
}

.step-number {
    position: absolute;
    top: -20px;
    left: -20px;
    width: 65px;
    height: 65px;
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 700;
    box-shadow: 0 8px 20px rgba(20, 124, 180, 0.3);
}

.step-content {
    margin-top: 25px;
}

.step-content h3 {
    color: var(--tarawera);
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.step-content p {
    color: var(--pickled-bluewood);
    line-height: 1.6;
}

/* Team Section */
.team {
    padding: 100px 0;
    background-color: var(--light-gray);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 30px;
}

.team-member {
    background-color: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    text-align: center;
}

.team-member:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.member-image {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.member-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.team-member:hover .member-image img {
    transform: scale(1.1);
}

.member-social {
    position: absolute;
    bottom: -60px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 15px;
    padding: 18px 0;
    background-color: rgba(20, 124, 180, 0.9);
    transition: var(--transition);
}

.team-member:hover .member-social {
    bottom: 0;
}

.member-social a {
    color: var(--white);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.member-social a:hover {
    background-color: var(--white);
    color: var(--denim);
    transform: translateY(-3px);
}

.member-info {
    padding: 25px 20px;
}

.member-info h3 {
    color: var(--tarawera);
    margin-bottom: 8px;
    font-size: 1.3rem;
}

.member-info p {
    color: var(--pickled-bluewood);
    font-size: 0.95rem;
    margin-bottom: 12px;
}

.member-bio {
    font-size: 0.85rem;
    color: var(--cape-cod);
    margin-top: 12px;
    line-height: 1.5;
}

.team-cta {
    text-align: center;
    margin-top: 60px;
}

.team-cta p {
    font-size: 1.3rem;
    margin-bottom: 25px;
    color: var(--pickled-bluewood);
}

/* Contact Section */
.contact {
    padding: 100px 0;
    background-color: var(--white);
}

.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 50px;
}

.contact-info {
    background-color: var(--light-gray);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.contact-info:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.contact-info h3 {
    color: var(--tarawera);
    margin-bottom: 20px;
    font-size: 1.6rem;
}

.contact-info p {
    margin-bottom: 30px;
    color: var(--pickled-bluewood);
    line-height: 1.6;
}

.contact-details {
    margin-bottom: 35px;
}

.contact-item {
    display: flex;
    margin-bottom: 22px;
    align-items: flex-start;
}

.contact-item i {
    font-size: 1.3rem;
    color: var(--denim);
    margin-right: 15px;
    margin-top: 5px;
    min-width: 20px;
}

.contact-item h4 {
    color: var(--tarawera);
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.contact-item p {
    margin-bottom: 0;
    font-size: 0.95rem;
}

.social-links h4 {
    color: var(--tarawera);
    margin-bottom: 18px;
    font-size: 1.2rem;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-icons a:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(20, 124, 180, 0.3);
}

.contact-form {
    background-color: var(--light-gray);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.contact-form:hover {
    transform: translateY(-5px);
    box-shadow: var(--box-shadow-hover);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    margin-bottom: 22px;
    position: relative;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid var(--medium-gray);
    border-radius: var(--border-radius-sm);
    font-family: 'Poppins', sans-serif;
    transition: var(--transition);
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--denim);
    box-shadow: 0 0 0 3px rgba(20, 124, 180, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 130px;
}

.form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23214454' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    background-size: 12px;
}

.contact-form button {
    width: 100%;
    padding: 16px;
    font-size: 1.1rem;
    margin-top: 10px;
}

.contact-form button i {
    margin-left: 10px;
}

/* Newsletter Section */
.newsletter {
    padding: 70px 0;
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.newsletter::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    animation: backgroundMove 20s linear infinite;
    z-index: 0;
}

.newsletter .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    position: relative;
    z-index: 1;
}

.newsletter-content h3 {
    font-size: 2rem;
    margin-bottom: 12px;
}

.newsletter-content p {
    opacity: 0.9;
    font-size: 1.1rem;
    max-width: 500px;
}

.newsletter-form {
    display: flex;
    flex: 1;
    max-width: 500px;
    min-width: 300px;
}

.newsletter-form input {
    flex: 1;
    padding: 16px 22px;
    border: none;
    border-radius: 50px 0 0 50px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
}

.newsletter-form input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.newsletter-form button {
    border-radius: 0 50px 50px 0;
    padding: 16px 32px;
}

/* Footer */
.footer {
    background-color: var(--tarawera);
    color: white;
    padding: 80px 0 20px;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--denim), var(--tango));
}

.footer a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer a:hover {
    color: var(--tango);
    text-decoration: none;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer-logo img {
    height: 100px;
    width: auto;
    margin-bottom: 20px;
}

.footer-logo p {
    opacity: 0.8;
    font-size: 0.95rem;
    margin-bottom: 25px;
    line-height: 1.6;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social a {
    display: inline-flex;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background-color: var(--tango);
    color: white;
    transform: translateY(-3px);
}

.footer-links h4,
.footer-services h4,
.footer-contact h4 {
    font-size: 1.3rem;
    margin-bottom: 22px;
    position: relative;
    padding-bottom: 12px;
}

.footer-links h4::after,
.footer-services h4::after,
.footer-contact h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--tango);
    border-radius: 2px;
}

.footer-links ul li,
.footer-services ul li {
    margin-bottom: 12px;
}

.footer-links ul li a,
.footer-services ul li a {
    opacity: 0.8;
    font-size: 0.95rem;
    transition: var(--transition);
    display: inline-block;
}

.footer-links ul li a:hover,
.footer-services ul li a:hover {
    opacity: 1;
    color: var(--tango);
    padding-left: 8px;
}

.footer-contact ul li {
    display: flex;
    margin-bottom: 18px;
    opacity: 0.8;
    font-size: 0.95rem;
    align-items: flex-start;
}

.footer-contact ul li i {
    margin-right: 12px;
    color: var(--tango);
    font-size: 1.1rem;
    min-width: 20px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 25px 0;
}

.footer-copyright {
    text-align: center;
    margin-bottom: 15px;
    opacity: 0.7;
    font-size: 0.95rem;
}

.footer-legal {
    display: flex;
    justify-content: center;
    gap: 25px;
}

.footer-legal a {
    opacity: 0.7;
    font-size: 0.85rem;
    transition: var(--transition);
}

.footer-legal a:hover {
    opacity: 1;
    color: var(--tango);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 55px;
    height: 55px;
    background: linear-gradient(135deg, var(--tango) 0%, var(--potters-clay) 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 5px 15px rgba(241, 131, 36, 0.3);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: linear-gradient(135deg, var(--denim) 0%, var(--chathams-blue) 100%);
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(20, 124, 180, 0.3);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(20, 124, 180, 0.3);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 15px 40px rgba(20, 124, 180, 0.4);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(20, 124, 180, 0.3);
    }
}

@keyframes backgroundMove {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(-10px, -10px);
    }
}

/* Responsive Styles */
@media (max-width: 1400px) {
    .container {
        max-width: 1140px;
    }
}

@media (max-width: 1200px) {
    .container {
        max-width: 960px;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .portfolio-grid {
        grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    }
}

@media (max-width: 992px) {
    .container {
        max-width: 720px;
    }
    
    .hero .container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-content {
        max-width: 100%;
        padding-right: 0;
        margin-bottom: 50px;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .about .container {
        flex-direction: column;
    }
    
    .about-image {
        margin-top: 50px;
    }
    
    .mission-vision {
        grid-template-columns: 1fr;
    }
    
    .client-logos {
        gap: 25px;
    }
    
    .client-logo img {
        max-height: 40px;
    }
    
    .section-title {
        font-size: 2.4rem;
    }
}

@media (max-width: 768px) {
    .container {
        max-width: 540px;
    }
    
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background-color: var(--white);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 50px;
        transition: var(--transition);
        z-index: 999;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-item {
        margin: 15px 0;
    }
    
    .mobile-menu {
        display: flex;
    }
    
    .hero {
        padding: 150px 0 80px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .section {
        padding: 80px 0;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
    
    .section-header {
        margin-bottom: 40px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .process-steps {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .process-step {
        padding: 40px 30px 30px;
    }
    
    .step-number {
        width: 55px;
        height: 55px;
        font-size: 1.4rem;
    }
    
    .testimonials-slider {
        grid-template-columns: 1fr;
    }
    
    .newsletter .container {
        flex-direction: column;
        text-align: center;
    }
    
    .newsletter-form {
        flex-direction: column;
        max-width: 100%;
    }
    
    .newsletter-form input {
        border-radius: 50px;
        margin-bottom: 15px;
    }
    
    .newsletter-form button {
        border-radius: 50px;
        width: 100%;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 35px;
    }
    
    .footer-links h4::after,
    .footer-services h4::after,
    .footer-contact h4::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-social {
        justify-content: center;
    }
    
    .footer-legal {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        padding: 130px 0 60px;
    }
    
    .hero-title {
        font-size: 2.2rem;
        line-height: 1.3;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-item {
        height: 250px;
    }
    
    .team-grid {
        grid-template-columns: 1fr;
    }
    
    .member-image {
        height: 300px;
    }
    
    .experience-badge {
        width: 100px;
        height: 100px;
    }
    
    .experience-badge span {
        font-size: 2.2rem;
    }
    
    .stats {
        grid-template-columns: 1fr 1fr;
    }
    
    .contact-container {
        grid-template-columns: 1fr;
    }
    
    .contact-info,
    .contact-form {
        padding: 30px 20px;
    }
    
    .back-to-top {
        width: 45px;
        height: 45px;
        font-size: 1rem;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 400px) {
    .hero-title {
        font-size: 1.9rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .portfolio-filter {
        flex-direction: column;
        align-items: center;
    }
    
    .filter-btn {
        margin: 5px 0;
        width: 100%;
        text-align: center;
    }
    
    .stats {
        grid-template-columns: 1fr;
    }
}

/* Small height devices */
@media (max-height: 600px) and (orientation: landscape) {
    .hero {
        padding: 120px 0 60px;
    }
    
    .hero-content {
        margin-bottom: 30px;
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 10px;
    }
    
    .hero-subtitle {
        margin-bottom: 20px;
    }
    
    .section-header {
        margin-bottom: 30px;
    }
    
    .nav-menu {
        top: 70px;
        height: calc(100vh - 70px);
    }
}

/* High-resolution devices */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .section-title::after {
        height: 4px;
    }
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* Print styles */
@media print {
    .header,
    .mobile-menu,
    .footer,
    .back-to-top,
    .btn,
    .hero-buttons,
    .member-social,
    .portfolio-overlay,
    .testimonial-card::before {
        display: none !important;
    }
    
    body {
        padding-top: 0;
        background: none;
        color: #000;
        font-size: 12pt;
    }
    
    .container {
        max-width: 100%;
        padding: 0;
    }
    
    .section {
        padding: 50px 0;
        page-break-inside: avoid;
    }
    
    .section-header {
        page-break-after: avoid;
    }
    
    .section-title::after {
        background: #000;
    }
    
    a::after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
        font-weight: normal;
    }
    
    img {
        max-height: 300px;
    }
}