/* Etchant Information Page Styles */

/* Page Container */
.first-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    overflow-x: hidden;
    box-sizing: border-box;
}

/* Back Button Styles */
.back-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    background: none;
    border: none;
    cursor: pointer;
    color: #007AFF;
    transition: all 0.2s ease;
    margin-bottom: 1rem;
    border-radius: 50%;
}

.back-button:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.back-button svg {
    width: 24px;
    height: 24px;
}

@media (max-width: 768px) {
    .back-button {
        padding: 6px;
    }
    .back-button svg {
        width: 20px;
        height: 20px;
    }
}

/* Etchant Information Section */
.etchant-information {
    padding: 2rem 0;
    max-width: 1200px;
    margin: 0 auto;
}

/* Intro Section */
.intro-section {
    border-radius: 20px;
    padding: 2.5rem;
    margin: 1.5rem auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    max-width: 1200px;
}

.intro-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #007bff, #00bcd4);
}

.intro-text h2 {
    color: #1a365d;
    font-size: 2.25rem;
    margin-bottom: 1.25rem;
    font-weight: 700;
    line-height: 1.2;
    position: relative;
    padding-bottom: 0.75rem;
}

.intro-text h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: #007bff;
    border-radius: 2px;
}

.intro-text h3 {
    color: #2d3748;
    font-size: 1.5rem;
    margin: 1.5rem 0 1rem;
    font-weight: 600;
    line-height: 1.3;
}

.intro-text p {
    color: #4a5568;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    max-width: 1200px;
}

.intro-text ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.intro-text li {
    margin-bottom: 0;
    padding: 1rem;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    padding-left: 1.75rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

.intro-text li:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.intro-text li:before {
    content: "•";
    color: #007bff;
    position: absolute;
    left: 0.75rem;
    font-size: 1.25rem;
    font-weight: bold;
    line-height: 1.4;
}

.intro-text strong {
    color: #2d3748;
    font-weight: 600;
    display: block;
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.inline-link {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.25rem 0;
    border-bottom: 2px solid transparent;
}

.inline-link:hover {
    color: #0056b3;
    border-bottom-color: #0056b3;
}

/* Etchant Grid Layout */
.etchant-row {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2.5rem;
    justify-content: center;
}

.etchant-column {
    flex: 1;
    min-width: 300px;
    max-width: 400px;
}

/* Table Container */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    min-width: 0;
    max-width: 100%;
}

/* Table Styles */
.etchant-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    font-size: 0.9rem;
    margin: 0.75rem 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.etchant-table th {
    background: #f8f9fa;
    color: #333;
    font-weight: 600;
    text-align: left;
    padding: 0.75rem;
    border-bottom: 2px solid #dee2e6;
    font-size: 0.95rem;
}

.etchant-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #dee2e6;
    vertical-align: top;
}

.etchant-table tr:last-child td {
    border-bottom: none;
}

.etchant-table strong {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    color: #2c3e50;
}

.etchant-table .concentration-list,
.etchant-table .condition-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.etchant-table .concentration-list li,
.etchant-table .condition-list li {
    margin: 0;
    padding: 0.15rem 0;
    line-height: 1.3;
    min-height: 1.3em;
}

.etchant-table .concentration-list li strong {
    display: inline;
    margin: 0;
    font-size: 0.9rem;
    color: #2c3e50;
}

.etchant-table .concentration-list li:first-child,
.etchant-table .condition-list li:first-child {
    margin-top: 0.25rem;
}

/* Dropdown Styles */
.etchant-dropdown {
    position: relative;
    background: #f8f9fa;
    padding: 1.25rem;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.3s ease;
}

.etchant-dropdown:hover {
    background: #e9ecef;
}

.etchant-dropbtn {
    background: none;
    border: none;
    color: #2c3e50;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0.5rem 1rem;
    width: 100%;
    text-align: left;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
}

.etchant-dropbtn:hover {
    color: #1a73e8;
    background: rgba(26, 115, 232, 0.05);
}

.etchant-dropbtn:after {
    content: "▼";
    font-size: 0.8rem;
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.etchant-dropdown:hover .etchant-dropbtn:after {
    transform: rotate(180deg);
}

.etchant-dropdown-content {
    display: none;
    position: absolute;
    background: #ffffff;
    min-width: 220px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border-radius: 12px;
    z-index: 100;
    padding: 0.75rem 0;
    margin-top: 0.5rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.etchant-dropdown:hover .etchant-dropdown-content {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.etchant-dropdown-content:before {
    content: '';
    position: absolute;
    top: -6px;
    left: 20px;
    width: 12px;
    height: 12px;
    background: #ffffff;
    transform: rotate(45deg);
    box-shadow: -2px -2px 5px rgba(0, 0, 0, 0.04);
}

.etchant-dropdown-content a {
    color: #4a5568;
    padding: 0.75rem 1.25rem;
    text-decoration: none;
    display: block;
    transition: all 0.2s ease;
    font-weight: 500;
    font-size: 0.95rem;
}

.etchant-dropdown-content a:first-child {
    border-radius: 12px 12px 0 0;
}

.etchant-dropdown-content a:last-child {
    border-radius: 0 0 12px 12px;
}

.etchant-dropdown-content a:hover {
    background: #f8f9fa;
    color: #1a73e8;
    padding-left: 1.5rem;
}

.etchant-dropdown-content a:active {
    background: #e9ecef;
}

/* Image Styles */
.etchant-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.etchant-table:hover .etchant-image {
    transform: scale(1.05);
}

/* Etchant Hero Section */
.etchant-hero {
    margin-bottom: 0;
    min-height: 60vh;
}

@media (min-width: 1024px) {
    .etchant-hero {
        min-height: 70vh;
    }
}

.etchant-hero .welcome-content-wrapper {
    max-width: 1440px;
}

.etchant-hero .welcome-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #0f172a;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
    .etchant-hero .welcome-title {
        font-size: 2rem;
    }
}

.etchant-hero .welcome-content {
    grid-template-columns: 1fr;
    max-width: 1200px;
    margin: 0 auto;
    gap: 0;
}

.etchant-hero .welcome-description {
    max-width: 100%;
    margin: 0;
}

.etchant-hero .welcome-description .section-text {
    color: #1e293b;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.25rem;
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.3);
}

.etchant-hero .welcome-description h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.4);
}

.etching-matters-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}

@media (max-width: 1024px) {
    .etching-matters-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .etching-matters-cards {
        grid-template-columns: 1fr;
    }
}

.etching-matters-card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.etching-matters-card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
    border-color: #93c5fd;
}

.etching-matters-card {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(229, 231, 235, 0.9);
    border-radius: 0.5rem;
    padding: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.etching-matters-card:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
    border-color: #93c5fd;
}

.etching-matters-card h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #000000;
    margin: 0 0 0.5rem 0;
    line-height: 1.3;
}

.etching-matters-card p {
    font-size: 0.875rem;
    line-height: 1.5;
    color: #1f2937;
    margin: 0;
}

/* Ensure content is visible even if animations don't load */
.etchant-hero .welcome-text {
    color: #111827;
}

/* Fallback for when animations.js hasn't loaded */
.etchant-hero .welcome-text[data-animate] {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.etchant-information {
    padding-top: 0;
}

/* Class Cards with Images */
.class-card-with-image {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.class-card-with-image:hover {
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    transform: translateY(-4px);
    border-color: #93c5fd;
}

.class-card-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f9fafb;
    position: relative;
}

.class-card-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.1), transparent);
    pointer-events: none;
}

.class-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.class-card-with-image:hover .class-card-image img {
    transform: scale(1.08);
}

.class-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.class-card-title {
    margin: 0 0 0.75rem 0;
    font-size: 1.125rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.4;
}

.class-card-description {
    color: #4b5563;
    font-size: 0.875rem;
    line-height: 1.6;
    margin: 0;
    flex-grow: 1;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .etchant-row {
        gap: 1rem;
    }

    .etchant-column {
        min-width: 100%;
        max-width: none;
    }

    .etchant-dropdown {
        padding: 1rem;
    }

    .etchant-dropbtn {
        font-size: 1rem;
    }

    .etchant-image {
        height: 180px;
    }

    .intro-section {
        padding: 1.75rem;
        margin: 1rem;
    }

    .intro-text h2 {
        font-size: 1.875rem;
        margin-bottom: 1rem;
    }

    .intro-text h3 {
        font-size: 1.35rem;
        margin: 1.25rem 0 0.875rem;
    }

    .intro-text p {
        font-size: 1.1rem;
    }

    .intro-text ul {
        grid-template-columns: 1fr;
    }

    .intro-text li {
        padding: 1rem;
        padding-left: 2rem;
    }

    .etchant-table {
        font-size: 0.85rem;
    }
    .etchant-table th,
    .etchant-table td {
        padding: 0.6rem;
    }
    .etchant-table strong {
        font-size: 0.9rem;
    }
    .etchant-table .concentration-list li strong {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .first-container {
        padding: 1rem;
    }

    .etchant-column {
        min-width: 100%;
    }

    .intro-section {
        padding: 1.25rem;
        margin: 0.75rem;
    }

    .intro-text h2 {
        font-size: 1.625rem;
    }

    .intro-text h3 {
        font-size: 1.25rem;
    }

    .intro-text p {
        font-size: 1rem;
    }

    .etchant-dropbtn {
        font-size: 1rem;
    }

    .etchant-image {
        height: 160px;
    }

    .etchant-table {
        font-size: 0.8rem;
    }
    .etchant-table th,
    .etchant-table td {
        padding: 0.5rem;
    }
    .etchant-table strong {
        font-size: 0.85rem;
    }
    .etchant-table .concentration-list li strong {
        font-size: 0.8rem;
    }
}

@media (max-width: 1200px) {
    .etchant-row {
        gap: 1.5rem;
    }
    
    .etchant-column {
        min-width: 280px;
    }

    .intro-text ul {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

/* Resource Hub Cards */
.resource-hub {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 1.5rem;
}

.resource-hub h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #1f2937;
}

.resource-hub > p {
    text-align: center;
    margin-bottom: 2.5rem;
    color: #6b7280;
    font-size: 1.1rem;
}

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

.resource-card {
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    padding: 2rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.resource-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, transparent, currentColor, transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-color: currentColor;
}

.resource-card:hover::before {
    opacity: 1;
}

.resource-card-icon {
    width: 60px;
    height: 60px;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.resource-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #1f2937;
}

.resource-card p {
    color: #6b7280;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.resource-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
}

.resource-card-link:hover {
    gap: 0.75rem;
}

/* Additional Resources Section */
.additional-resources {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 1.5rem;
}

.additional-resources-container {
    background: #f9fafb;
    border-radius: 0.75rem;
    padding: 2.5rem;
    border: 1px solid #e5e7eb;
}

.additional-resources h2 {
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #1f2937;
    text-align: center;
}

.additional-resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.additional-resources-column h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #374151;
}

.additional-resources-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.additional-resources-column li {
    margin-bottom: 0.5rem;
}

.additional-resources-column a {
    color: #2563eb;
    text-decoration: none;
    transition: color 0.2s;
}

.additional-resources-column a:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .resource-cards-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .resource-hub h2 {
        font-size: 1.75rem;
    }
    
    .additional-resources-grid {
        grid-template-columns: 1fr;
    }
}

/* Print Styles */
@media print {
    .intro-section {
        background: none;
        box-shadow: none;
        border: 1px solid #dee2e6;
    }

    .etchant-table {
        box-shadow: none;
        border: 1px solid #dee2e6;
    }

    .etchant-dropdown {
        background: none;
        border-bottom: 1px solid #dee2e6;
    }

    .etchant-dropbtn {
        color: #000;
    }

    .etchant-dropdown-content {
        display: block;
        position: static;
        box-shadow: none;
        border: 1px solid #dee2e6;
    }

    .etchant-dropdown-content a {
        color: #000;
    }
}

/* ============================================================================
   ETCHANT DETAIL PAGES — Scoped styles for individual etchant material pages
   (e.g., Metallography-Aluminum-etchants.htm)
   ============================================================================ */

/* ---- Breadcrumb ---- */
.etchant-breadcrumb {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    color: var(--color-text-light);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 1.25rem;
    transition: color 0.2s;
    margin-bottom: 1.5rem;
}

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

.etchant-breadcrumb svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* ---- Hero ---- */
.etchant-detail-hero {
    background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 50%, #f8fafc 100%);
    padding: 3rem 0 3rem;
    margin-top: calc(var(--navigation-height, 100px));
}

.etchant-detail-hero-content {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.etchant-detail-hero-text {
    flex: 1;
}

.etchant-detail-hero-text h1 {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--color-text-primary);
    line-height: 1.2;
    margin-bottom: 1rem;
}

.etchant-detail-hero-text > p {
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--color-text-secondary);
    margin-bottom: 1.5rem;
    max-width: 40rem;
}

.etchant-detail-hero-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.etchant-detail-hero-image {
    width: 200px;
    height: 200px;
    flex-shrink: 0;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: white;
    padding: 5px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.etchant-detail-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

@media (max-width: 768px) {
    .etchant-detail-hero {
        padding: 1.5rem 0 2rem;
    }

    .etchant-detail-hero-content {
        flex-direction: column-reverse;
        gap: 1.5rem;
        text-align: center;
    }

    .etchant-detail-hero-text h1 {
        font-size: 1.875rem;
    }

    .etchant-detail-hero-text > p {
        max-width: none;
    }

    .etchant-detail-hero-actions {
        justify-content: center;
    }

    .etchant-detail-hero-image {
        width: 140px;
        height: 140px;
    }
}

/* ---- Section Titles ---- */
.etchant-detail-section-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.etchant-detail-section-subtitle {
    font-size: 1rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
    line-height: 1.6;
}

/* ---- Overview Section ---- */
.etchant-detail-overview {
    padding: 3rem 0;
}

.etchant-overview-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.etchant-overview-card {
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.etchant-overview-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-color: #93c5fd;
}

.etchant-overview-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 0.5rem;
}

.etchant-overview-card > p {
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--color-text-tertiary);
    margin-bottom: 0.75rem;
}

.etchant-overview-card details {
    border-top: 1px solid var(--color-border);
    padding-top: 0.75rem;
}

.etchant-overview-card summary {
    cursor: pointer;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-primary);
    padding: 0.25rem 0;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    user-select: none;
}

.etchant-overview-card summary::-webkit-details-marker {
    display: none;
}

.etchant-overview-card summary::after {
    content: '';
    width: 6px;
    height: 6px;
    border-right: 2px solid var(--color-primary);
    border-bottom: 2px solid var(--color-primary);
    transform: rotate(-45deg);
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.etchant-overview-card details[open] summary::after {
    transform: rotate(45deg);
}

.etchant-overview-card details ul {
    list-style: none;
    padding: 0;
    margin: 0.75rem 0 0;
}

.etchant-overview-card details li {
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--color-text-secondary);
    padding: 0.3rem 0 0.3rem 1rem;
    position: relative;
}

.etchant-overview-card details li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.65rem;
    width: 5px;
    height: 5px;
    background: var(--color-primary);
    border-radius: 50%;
}

.etchant-overview-card details li strong {
    color: var(--color-text-primary);
    font-weight: 600;
}

@media (max-width: 768px) {
    .etchant-overview-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .etchant-overview-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .etchant-overview-card:last-child {
        grid-column: 1 / -1;
    }
}

/* ---- Etchant Data Section ---- */
.etchant-detail-data {
    padding: 3rem 0;
    background: var(--color-background);
}

.etchant-detail-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    font-size: 0.875rem;
    margin: 1.5rem 0;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.etchant-detail-table th {
    background: var(--color-gray-100);
    color: var(--color-text-primary);
    font-weight: 600;
    text-align: left;
    padding: 0.875rem 1rem;
    border-bottom: 2px solid var(--color-border);
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.etchant-detail-table td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
    color: var(--color-text-secondary);
}

.etchant-detail-table tr:last-child td {
    border-bottom: none;
}

.etchant-detail-table tr:hover td {
    background: #fafbfc;
}

.etchant-detail-table td strong {
    display: block;
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 0.25rem;
}

.etchant-detail-table .concentration-list,
.etchant-detail-table .condition-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.etchant-detail-table .concentration-list li,
.etchant-detail-table .condition-list li {
    margin: 0;
    padding: 0.2rem 0;
    line-height: 1.4;
    font-size: 0.8125rem;
}

.etchant-detail-table .concentration-list li strong {
    display: inline;
    margin: 0;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text-primary);
}

.etchant-detail-table td ul:not(.concentration-list):not(.condition-list) {
    list-style: none;
    padding: 0;
    margin: 0;
}

.etchant-detail-table td ul:not(.concentration-list):not(.condition-list) li {
    padding: 0.15rem 0 0.15rem 0.875rem;
    position: relative;
    font-size: 0.8125rem;
    line-height: 1.5;
}

.etchant-detail-table td ul:not(.concentration-list):not(.condition-list) li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55rem;
    width: 4px;
    height: 4px;
    background: var(--color-primary);
    border-radius: 50%;
}

@media (max-width: 768px) {
    .etchant-detail-table {
        font-size: 0.8125rem;
    }

    .etchant-detail-table th,
    .etchant-detail-table td {
        padding: 0.625rem 0.5rem;
    }

    .etchant-detail-table th {
        font-size: 0.75rem;
    }
}

/* ---- Tip Aside ---- */
.etchant-detail-tip {
    background: #eff6ff;
    border-left: 4px solid var(--color-primary);
    border-radius: 0 var(--border-radius-md) var(--border-radius-md) 0;
    padding: 1.25rem 1.5rem;
    margin-top: 1.5rem;
}

.etchant-detail-tip > strong {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    color: var(--color-primary);
    margin-bottom: 0.75rem;
}

.etchant-detail-tip > strong::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%232563eb' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 22h4M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0z'/%3E%3C/svg%3E") center/contain no-repeat;
    flex-shrink: 0;
}

.etchant-detail-tip ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.375rem 1.5rem;
}

.etchant-detail-tip li {
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--color-text-secondary);
    padding-left: 1rem;
    position: relative;
}

.etchant-detail-tip li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-primary);
    font-weight: 700;
    font-size: 0.75rem;
}

@media (max-width: 640px) {
    .etchant-detail-tip ul {
        grid-template-columns: 1fr;
    }
}

/* ---- Troubleshooting ---- */
.etchant-detail-troubleshooting {
    padding: 3rem 0;
}

.troubleshooting-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.troubleshooting-card {
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    padding: 1.25rem;
    transition: all 0.3s ease;
}

.troubleshooting-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border-color: #93c5fd;
}

.troubleshooting-card h4 {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.troubleshooting-card h4::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.troubleshooting-card:nth-child(1) h4::before { background: #ef4444; }
.troubleshooting-card:nth-child(2) h4::before { background: #f59e0b; }
.troubleshooting-card:nth-child(3) h4::before { background: #6366f1; }
.troubleshooting-card:nth-child(4) h4::before { background: #8b5cf6; }
.troubleshooting-card:nth-child(5) h4::before { background: #ec4899; }
.troubleshooting-card:nth-child(6) h4::before { background: #14b8a6; }

.troubleshooting-card p {
    font-size: 0.8125rem;
    line-height: 1.6;
    color: var(--color-text-tertiary);
    margin: 0;
}

@media (max-width: 1024px) {
    .troubleshooting-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .troubleshooting-grid {
        grid-template-columns: 1fr;
    }
}

/* ---- Related Resources ---- */
.etchant-detail-resources {
    padding: 3rem 0;
    background: var(--color-background);
}

.etchant-resources-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.etchant-resource-card {
    background: white;
    border: 1px solid var(--color-border);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.etchant-resource-card:hover {
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    border-color: #93c5fd;
    transform: translateY(-3px);
}

.etchant-resource-card .resource-icon-wrapper {
    width: 40px;
    height: 40px;
    border-radius: var(--border-radius-md);
    background: #eff6ff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary);
}

.etchant-resource-card .resource-icon-wrapper svg {
    width: 20px;
    height: 20px;
}

.etchant-resource-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text-primary);
    margin: 0;
    line-height: 1.4;
}

.etchant-resource-card p {
    font-size: 0.8125rem;
    line-height: 1.5;
    color: var(--color-text-light);
    margin: 0;
    flex-grow: 1;
}

.etchant-resource-card .resource-link-text {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-primary);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: gap 0.2s;
}

.etchant-resource-card:hover .resource-link-text {
    gap: 0.5rem;
}

.etchant-resource-card .resource-link-text svg {
    width: 14px;
    height: 14px;
}

@media (max-width: 1024px) {
    .etchant-resources-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .etchant-resources-grid {
        grid-template-columns: 1fr;
    }
}

/* ---- Print overrides for detail pages ---- */
@media print {
    .etchant-detail-hero {
        background: none;
        padding: 1rem 0;
    }

    .etchant-detail-hero-image {
        display: none;
    }

    .etchant-detail-table {
        border: 1px solid #ccc;
        box-shadow: none;
    }

    .etchant-overview-card details {
        display: block;
    }

    .etchant-overview-card details[open] {
        display: block;
    }

    .troubleshooting-card,
    .etchant-resource-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ccc;
    }

    .etchant-detail-resources {
        display: none;
    }
}
