/*
  Page-specific stylesheet for Finishing Services Page
  Version: 7.0 - "The Art of Display" Soul Injected
*/

/* --- Shell Module Consistency --- */
.page-hero,
.final-cta-section {
    background-image: linear-gradient(rgba(0, 0, 0, .5), rgba(0, 0, 0, .5)), url(../images/backgrounds/hero-bg-finishing.jpg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* --- Section 1: "'Spectrum' Gallery (Final Polished Version)" --- */
.spectrum-gallery-section {
    padding: var(--section-padding);
}

.spectrum-grid {
    display: grid;
    /* Two equal columns */
    grid-template-columns: 1fr 1fr;
    /* Increased gap for a more spacious, premium feel */
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.spectrum-card-new {
    display: flex;
    /* Aligns image and text content vertically */
    align-items: center;
    gap: 2rem;
    background-color: var(--color-light);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    /* Slightly larger radius for a softer look */
    padding: 2rem;
}

.spectrum-image-wrapper-new {
    /* The image container will take up half the space */
    flex: 1;
    border-radius: 10px;
    overflow: hidden;
    /* The key to the "long rectangle" shape */
    aspect-ratio: 16 / 9;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.spectrum-image-wrapper-new img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.spectrum-card-new:hover .spectrum-image-wrapper-new img {
    transform: scale(1.05);
}

.spectrum-content-new {
    /* The text container will also take up half the space */
    flex: 1;
}

.spectrum-content-new h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.spectrum-content-new p {
    color: var(--color-secondary);
    line-height: 1.6;
}

/* Logic for alternating layout */
/* The 2nd and 3rd items will have their image on the right */
.spectrum-card-new:nth-child(2) .spectrum-image-wrapper-new,
.spectrum-card-new:nth-child(3) .spectrum-image-wrapper-new {
    order: 1;
    /* This moves the image to the end of the flex container */
}

/* Responsive adjustments for smaller screens */
@media (max-width: 1024px) {
    .spectrum-grid {
        /* Stack them into a single column on tablets and below */
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .spectrum-card-new {
        /* On mobile, stack image on top of text */
        flex-direction: column;
        align-items: flex-start;
        padding: 1.5rem;
    }

    .spectrum-image-wrapper-new {
        width: 100%;
    }

    /* Reset the order for mobile to ensure consistency */
    .spectrum-card-new:nth-child(2) .spectrum-image-wrapper-new,
    .spectrum-card-new:nth-child(3) .spectrum-image-wrapper-new {
        order: 0;
    }
}

/* --- Section 2: "'Symphony of Finishes'" --- */
.symphony-section {
    padding: var(--section-padding);
    background-color: var(--color-light-grey);
}

.symphony-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: minmax(150px, auto);
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

.symphony-item {
    border-radius: 12px;
    overflow: hidden;
}

.symphony-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.symphony-item.item-text {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.symphony-item.item-text h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.symphony-item.item-text p {
    color: var(--color-secondary);
    line-height: 1.6;
}

/* Asymmetrical Layout */
.symphony-item:nth-child(1) {
    grid-column: 1 / 8;
    grid-row: span 2;
}

.symphony-item:nth-child(2) {
    grid-column: 8 / 13;
    grid-row: span 1;
}

.symphony-item:nth-child(3) {
    grid-column: 8 / 13;
    grid-row: span 1;
}

.symphony-item:nth-child(4) {
    grid-column: 1 / 5;
    grid-row: span 1;
}

.symphony-item:nth-child(5) {
    grid-column: 5 / 9;
    grid-row: span 1;
}

.symphony-item:nth-child(6) {
    grid-column: 9 / 13;
    grid-row: span 2;
}

.symphony-item:nth-child(7) {
    grid-column: 1 / 9;
    grid-row: span 1;
    display: none;
}

/* Adjust as needed */

/* --- Section 3: "'Material' Matrix" --- */
.material-matrix-section {
    padding: var(--section-padding);
}

.matrix-table-wrapper {
    overflow-x: auto;
    max-width: 900px;
    margin: 0 auto;
    border: 1px solid var(--color-border);
    border-radius: 12px;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: center;
}

th,
td {
    padding: 1.25rem 1rem;
    line-height: 1.5;
}

th {
    background-color: var(--color-light-grey);
    font-weight: 700;
}

td {
    color: var(--color-secondary);
}

tbody tr:not(:last-child) {
    border-bottom: 1px solid var(--color-border);
}

thead th:first-child,
tbody tr td:first-child {
    text-align: left;
    font-weight: 700;
    color: var(--color-dark);
}

td.is-compatible {
    font-size: 1.5rem;
    color: var(--color-primary);
}

/* --- Section 4: "'Cornerstones of Quality'" --- */
.quality-cornerstone-section {
    padding: var(--section-padding);
    background-color: var(--color-light-grey);
}

.cornerstone-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

@media(min-width: 992px) {
    .cornerstone-grid {
        grid-template-columns: 2fr 1fr;
    }
}

.cornerstone-main {
    background-color: var(--color-light);
    border-radius: 12px;
    padding: 2.5rem;
}

.cornerstone-main img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.cornerstone-main h3,
.cornerstone-secondary h3 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.cornerstone-main p,
.cornerstone-secondary p {
    color: var(--color-secondary);
    line-height: 1.6;
}

.cornerstone-secondary-stack {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.cornerstone-secondary {
    background-color: var(--color-light);
    border-radius: 12px;
    padding: 2.5rem;
}