/* ==========================================================================
   GS Machine Automation - Product & Service Detail Page Styles
   ========================================================================== */

:root {
    --primary-color: #17627d;
    --primary-hover: #0d3f52;
    --bg-dark: #ffffff;
    --bg-card: #f7f9fa;
    --border-color: #e4e9ec;
    --text-white: #171b1f;
    --text-body: #4a5568;
}

/* Base resets inside the main wrapper */
.detail-main {
    background-color: var(--bg-dark);
    color: var(--text-body);
    font-family: 'Inter', system-ui, sans-serif;
}

/* Info section headings with primary indicator */
.info-section-title {
    font-family: 'Kanit', sans-serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-white);
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 8px;
}

.info-section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 35px;
    height: 2px;
    background-color: var(--primary-color);
}

.detail-description {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-body);
}

/* List Stylings */
.advantages-list, .features-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.advantages-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1rem;
    color: var(--text-white);
    font-weight: 500;
}

.advantages-list li i {
    color: var(--primary-color);
    background-color: rgba(23, 98, 125, 0.1);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    flex-shrink: 0;
}

.features-list li {
    position: relative;
    padding-left: 20px;
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--text-body);
}

.features-list li::before {
    content: '';
    position: absolute;
    left: 4px;
    top: 8px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: var(--primary-color);
}

/* Technical Specifications Table Section */
.detail-specs-section {
    width: 100%;
}

.specs-table-wrapper {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background-color: var(--bg-dark);
    margin-top: 20px;
}

.specs-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}

.specs-table th {
    background-color: #f7f9fa;
    color: var(--text-white);
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    padding: 14px 18px;
    border-bottom: 2px solid var(--border-color);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

.specs-table td {
    padding: 12px 18px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-body);
}

.specs-table tr:last-child td {
    border-bottom: none;
}

.specs-table tr:hover {
    background-color: rgba(23, 98, 125, 0.03);
}

.specs-table td:first-child {
    font-weight: 600;
    color: var(--text-white);
    background-color: #fafbfc;
    width: 25%;
}

/* Error states overlay */
.detail-error {
    text-align: center;
    padding: 100px 20px;
    background-color: var(--bg-dark);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
}

.detail-error a {
    margin-top: 15px;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 12px 25px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
}

/* Dynamic Interactive Tab Controls */
.elementor-tabs-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 25px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 15px;
    width: 100%;
}

.elementor-tab-title {
    background-color: #f7f9fa;
    border: 1px solid var(--border-color);
    color: var(--text-white) !important;
    padding: 12px 24px;
    border-radius: 6px;
    font-family: 'Kanit', sans-serif;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.elementor-tab-title:hover {
    border-color: var(--primary-color);
    background-color: rgba(23, 98, 125, 0.05);
}

.elementor-tab-title.elementor-active {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(23, 98, 125, 0.2);
    font-weight: 600;
}

.elementor-tab-content {
    display: none;
    width: 100%;
}

.elementor-tab-content.elementor-active {
    display: block;
    animation: tabFadeIn 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) forwards;
}

@keyframes tabFadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Detail Page Responsive Adjustments */
@media(max-width: 768px) {
    .detail-banner-inner {
        flex-direction: column !important;
        text-align: center !important;
    }
    .detail-banner-inner p {
        margin: 0 auto !important;
    }
    .detail-banner-inner .banner-hero-card {
        max-width: 100% !important;
        width: 100% !important;
    }
    .banner-hero-card img {
        height: 220px !important;
    }
}

@media(max-width: 600px) {
    .elementor-tabs-wrapper {
        flex-direction: column;
        gap: 8px;
    }
    .elementor-tab-title {
        width: 100%;
        text-align: center;
        padding: 10px 16px;
    }
    .specs-table td:first-child {
        width: 38%;
    }
}

/* Hero Banner Image Card */
.banner-hero-card {
    background: #ffffff;
    padding: 10px;
    border-radius: 14px;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.09);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.banner-hero-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.banner-hero-card img {
    width: 100%;
    height: 270px;
    object-fit: cover;
    border-radius: 10px;
    display: block;
}

/* Spotlight Main Image & Gallery Thumbnails */
.spotlight-img-wrap {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--border-color);
    background: #ffffff;
    padding: 8px;
}

.spotlight-main-img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: 8px;
    display: block;
    transition: opacity 0.25s ease-in-out;
}

.gallery-thumbs-row {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: thin;
}

.gallery-thumb-btn {
    border: 2px solid var(--border-color);
    background: #ffffff;
    padding: 4px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
    flex-shrink: 0;
    outline: none;
}

.gallery-thumb-btn:hover,
.gallery-thumb-btn.active {
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(23, 98, 125, 0.25);
    transform: scale(1.04);
}

.gallery-thumb-btn img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 5px;
    display: block;
}

