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

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

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

/* Hero Section */
.hero {
    height: 400px;
    background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('../assets/pages hero/metallic division hero.png');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.hero h1 {
    color: white;
    font-size: clamp(2rem, 5vw, 3.5rem);
    text-align: center;
    font-weight: bold;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    opacity: 0;
}

/* Split Content Section */
.split-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 4rem 0;
}

.image-carousel {
    position: relative;
    height: 400px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    opacity: 0;
}

.image-carousel img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
    z-index: 2;
}

.carousel-btn:hover {
    background: rgba(0,0,0,0.8);
}

.prev { left: 20px; }
.next { right: 20px; }

.content-text {
    padding: 0rem;
    opacity: 0;
}

.content-text p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    color: #444;
    text-align: justify;
}

/* Expertise Section */
.expertise-section {
    background-color: #f5f5f5;
    padding: 4rem 0;
}

.expertise-section h2 {
    text-align: left;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #333;
    position: relative;
    padding-bottom: 0.5rem;
}

.expertise-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100px;
    height: 3px;
    background-color: #ff6b00;
}

@media (max-width: 1212px) {
    .expertise-section h2 {
        padding-left: 2rem;
    }
    
    .expertise-section h2::after {
        left: 2rem;
    }
    
    .services-container {
        padding: 0 2rem;
    }
}

@media (min-width: 1213px) {
    .expertise-section h2 {
        max-width: 1200px;
        margin-left: auto;
        margin-right: auto;
        padding-left: 0;
    }
}

.services-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    gap: 5rem;
}

.services-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.service-item {
    width: 100%;
    opacity: 0;
}

.service-btn {
    width: 100%;
    padding: 1.2rem 1.5rem;
    background: white;
    border: none;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.service-btn span {
    font-size: 1.1rem;
    font-weight: 500;
    color: #333;
    text-align: left;
}

.service-btn i {
    font-size: 0.9rem;
    color: #666;
    transition: transform 0.3s ease;
}

.service-btn:hover {
    background-color: #f8f8f8;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.service-btn.active {
    background-color: #A79079;
    color: white;
    transform: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.service-btn.active span {
    color: white;
}

.service-btn.active i {
    color: white;
    transform: rotate(180deg);
}

.service-content {
    display: none;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 0.5rem;
}

.service-item.active .service-content {
    display: block;
}

.service-details {
    padding: 1.5rem;
}

.service-details h4 {
    color: #000000;
    margin: 0 0 0.8rem 0;
    font-size: 1.1rem;
}

.service-details h4:not(:first-child) {
    margin-top: 1.5rem;
}

.service-details ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.service-details li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
    line-height: 1.4;
    color: #444;
}

.service-details li:last-child {
    margin-bottom: 0;
}

.service-details li::before {
    content: "•";
    color: #004d40;
    position: absolute;
    left: 0;
}

.details-box {
    display: none;
    background: #A79079;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    height: fit-content;
    opacity: 0;
}

.details-content {
    padding: 2rem;
    color: #ffffff;
}

.details-content > div {
    margin-bottom: 2rem;
}

.details-content > div:last-child {
    margin-bottom: 0;
}

.details-content h4 {
    color: #ffffff;
    font-size: 1.2rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.details-content ul {
    list-style-type: none;
    padding-left: 1.5rem;
}

.details-content ul ul {
    margin-top: 0.5rem;
    margin-left: 1rem;
}

.details-content li {
    margin-bottom: 0.5rem;
    position: relative;
    color: #ffffff;
}

.details-content li:before {
    content: "•";
    color: #ffffff;
    position: absolute;
    left: -1.5rem;
}

.details-content ul ul li:before {
    content: "◦";
}

.overview-section,
.capabilities-section,
.industries-section,
.certifications-section,
.facilities-section {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.overview-section:hover,
.capabilities-section:hover,
.industries-section:hover,
.certifications-section:hover,
.facilities-section:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.1);
}

/* Mobile Styles */
@media (max-width: 767px) {
    .expertise-section {
        padding: 3rem 1rem;
    }

    .details-box {
        display: none !important;
    }

    .service-content {
        display: none;
    }

    .service-content.active {
        display: block;
    }

    .service-btn.active {
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
        margin-bottom: 0;
    }
}

/* Desktop Styles */
@media (min-width: 768px) {
    .services-container {
        grid-template-columns: minmax(400px, 1fr) minmax(700px, 2fr);
        padding: 5 2rem;
    }

    .service-content {
        display: none !important;
    }

    .details-box {
        display: block;
        position: sticky;
        top: 2rem;
        max-height: calc(100vh - 4rem);
        overflow-y: auto;
    }

    .service-btn.active {
        border-radius: 8px;
    }
}

/* Responsive Styles */
@media (min-width: 1213px) {
    .services-container {
        grid-template-columns: minmax(400px, 1fr) minmax(700px, 2fr);
    }
    
    .service-content {
        display: none !important;
    }
}

@media (max-width: 1212px) {
    .services-container {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 2rem;
    }

    .details-box {
        display: none !important;
    }

    .service-content {
        margin-top: 0.5rem;
        padding: 1.5rem;
        background: #f8f8f8;
        border-radius: 0 0 8px 8px;
    }

    .service-item.active .service-content {
        display: block !important;
    }

    .service-btn {
        border-radius: 8px;
    }

    .service-item.active .service-btn {
        border-radius: 8px 8px 0 0;
        background-color: #A79079;
    }

    .service-item.active .service-btn span,
    .service-item.active .service-btn i {
        color: white;
    }

    .service-item.active .service-btn i {
        transform: rotate(180deg);
    }

    .content-text {
        padding: 0 2rem;
    }
}

@media (max-width: 768px) {
    .split-content {
        gap: 1rem;
        padding: 2rem 0;
    }

    .image-carousel {
        height: 300px;
    }

    .content-text {
        padding: 0 1.5rem;
    }

    .expertise-section {
        padding: 2rem 0;
    }

    .services-container {
        padding: 0 1.5rem;
    }

    .service-btn {
        padding: 1rem;
    }

    .service-btn span {
        font-size: 1rem;
    }

    .service-details h4 {
        font-size: 1rem;
    }

    .service-details ul li {
        font-size: 0.95rem;
    }
}

/* Projects Section */
.projects-section {
    padding: 4rem 0;
}

.view-more-container {
    text-align: right;
    margin-bottom: 2rem;
}

.view-more-btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: #fd7a55;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 500;
    transition: background-color 0.3s ease;
    border: none;
    cursor: pointer;
}

.view-more-btn:hover {
    background-color: #ff3700;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.project-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: inherit;
    display: block;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.project-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.project-card h3 {
    margin: 1rem;
    font-size: 1.2rem;
    color: #333;
}

.project-card p {
    margin: 0 1rem 1rem;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .project-grid {
        grid-template-columns: 1fr;
        padding: 0 2rem;
    }
}

/* Responsive Design */
@media (min-width: 768px) {
    .split-content {
        grid-template-columns: 1fr 1fr;
    }

    .project-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .project-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

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

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideFromLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideFromRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

.service-content, .project-card {
    animation: fadeIn 0.3s ease-in-out;
}

.animate-fade-in {
    opacity: 0;
    animation: fadeInScale 0.8s ease forwards;
}

.animate-from-left {
    opacity: 0;
    animation: slideFromLeft 0.8s ease forwards;
}

.animate-from-right {
    opacity: 0;
    animation: slideFromRight 0.8s ease forwards;
}

.animate-from-bottom {
    opacity: 0;
    animation: slideFromBottom 0.8s ease forwards;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }
.delay-4 { animation-delay: 0.8s; }

/* Accessibility */
.carousel-btn:focus,
.service-btn:focus,
.view-more-btn:focus {
    outline: 2px solid #004d40;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .hero {
        height: auto;
        padding: 2rem;
    }
    
    .carousel-btn,
    .view-more-btn {
        display: none;
    }
}
