/*
  Page-specific stylesheet for Medical & Healthcare Industry Page
  Version: 1.0 - "The Purity of Form, The Precision of Life" 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/bg-industry-medical.jpg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* --- Universal Section Spacing & Subtitles --- */
.compliance-med-section,
.applications-med-section,
.materials-med-section {
    padding: var(--section-padding);
}

.compliance-med-intro .section-subtitle {
    max-width: 700px;
    margin: -2.5rem auto 3rem auto;
}

/* --- Section 1: Compliance & Precision (Light BG, "Clinical Certificate") --- */
.compliance-med-section {
    background-color: var(--color-light);
}

.compliance-med-intro {
    text-align: center;
}

.cert-cards-grid-med {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

.cert-card-med {
    background-color: var(--color-light);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    /* Softer corners */
    padding: 2.5rem;
    text-align: center;
    /* MODIFIED: Synced transition speed with other pages for a consistent, snappy feel. */
    transition: transform 0.2s ease-out, box-shadow 0.2s ease-out;
}

.cert-card-med:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 122, 255, 0.08);
}

.cert-card-med img {
    height: 40px;
    margin: 0 auto 1.5rem auto;
}

.cert-card-med h3 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}

.cert-card-med p {
    color: var(--color-secondary);
    line-height: 1.6;
}

/* --- Section 2: Medical Applications (Dark BG, "Diagnostic Imaging Station") --- */
.applications-med-section {
    background-color: var(--color-dark);
}

.applications-med-section .section-title {
    color: var(--color-light);
    text-align: center;
}

.applications-med-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

@media (min-width: 992px) {
    .applications-med-grid {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(2, 1fr);
        height: 500px;
    }
}

.app-card-med {
    position: relative;
    display: block;
    border-radius: 24px;
    /* Organic, capsule-like shape */
    overflow: hidden;
    color: var(--color-light);
    height: 300px;
    transition: box-shadow 0.4s ease;
}

.app-card-med:hover {
    /* The "Glow" effect */
    box-shadow: 0 0 25px rgba(0, 122, 255, 0.4);
}

@media (min-width: 992px) {
    .app-card-med-hero {
        grid-column: 1 / 3;
        grid-row: 1 / 3;
        height: auto;
    }

    .app-card-med-small {
        grid-column: 3 / 4;
        height: auto;
    }
}

.app-card-med img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.app-card-med:hover img {
    transform: scale(1.05);
}

.app-card-med-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0) 60%);
    z-index: 1;
}

.app-card-med-content {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 2rem;
    z-index: 3;
}

.app-card-med h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.app-card-med p {
    color: rgba(255, 255, 255, 0.8);
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease 0.1s;
    max-height: 0;
    overflow: hidden;
}

.app-card-med:hover p {
    opacity: 1;
    transform: translateY(0);
    max-height: 100px;
}

/* --- Section 3: Biocompatible Materials (Light Grey BG, "Petri Dish") --- */
.materials-med-section {
    background-color: var(--color-light-grey);
}

.materials-med-section .section-title {
    text-align: center;
}

.materials-med-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

/* Add this new media query below the rule */
@media (min-width: 1200px) {
    .materials-med-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.material-card-med {
    text-align: center;
}

.material-card-med-img {
    position: relative;
    height: 200px;
    width: 200px;
    margin: 0 auto 1.5rem auto;
    border-radius: 50%;
    /* The "Petri Dish" effect */
    overflow: hidden;
    background-color: var(--color-light);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.material-card-med:hover .material-card-med-img {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.material-card-med-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.material-card-med-label {
    padding: 0 1rem;
}

.material-card-med-label h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.material-card-med-label p {
    color: var(--color-secondary);
    font-size: 0.9rem;
}