/* ==========================================================================
   Kratos 3D — Clinical Specialties Pages (Rhinoplasty, Jaw, Facial, Aesthetics)
   UI/UX Pro Max: Bento Grid + Clinical Metric Badges + App UI Placeholder Slots
   ========================================================================== */

.spec-page-wrap {
    padding-bottom: 3rem;
}

/* Specialty Sub-Navigation Pills */
.spec-subnav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    max-width: max-content;
    margin: 0 auto 2.5rem;
    box-shadow: 0 10px 30px -10px rgba(14, 165, 233, 0.12);
    scrollbar-width: none;
}

.spec-subnav::-webkit-scrollbar {
    display: none;
}

.spec-subnav-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.15rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    color: #475569;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.spec-subnav-link:hover {
    color: #0284c7;
    background: #f0f9ff;
}

.spec-subnav-link.is-active {
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
    color: #ffffff;
    box-shadow: 0 6px 16px -4px rgba(14, 165, 233, 0.45);
}

/* Hero Banner Card */
.spec-hero-card {
    background: linear-gradient(145deg, #0f172a 0%, #09101d 100%);
    border-radius: 2rem;
    border: 1px solid rgba(56, 189, 248, 0.2);
    overflow: hidden;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25);
    margin-bottom: 3rem;
}

.spec-hero-glow {
    position: absolute;
    width: 480px;
    height: 480px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.22) 0%, transparent 70%);
    top: -160px;
    right: -120px;
    pointer-events: none;
}

.spec-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    background: rgba(14, 165, 233, 0.14);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #38bdf8;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
}

.spec-hero-image-frame {
    position: relative;
    border-radius: 1.5rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.45);
}

.spec-hero-image-frame img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.spec-hero-image-frame:hover img {
    transform: scale(1.03);
}

/* KPI Strip inside Hero */
.spec-kpi-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.85rem;
    margin-top: 1.75rem;
}

.spec-kpi-box {
    background: rgba(30, 41, 59, 0.65);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 1rem;
    padding: 0.9rem 1rem;
}

.spec-kpi-val {
    font-family: 'Outfit', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    color: #38bdf8;
    line-height: 1.15;
}

.spec-kpi-lbl {
    font-size: 0.73rem;
    color: #94a3b8;
    margin-top: 0.25rem;
    line-height: 1.3;
}

/* Bento Feature Modules */
.spec-bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
    margin-bottom: 3.5rem;
}

.spec-bento-col-6 {
    grid-column: span 12;
}

.spec-bento-col-4 {
    grid-column: span 12;
}

.spec-bento-col-8 {
    grid-column: span 12;
}

@media (min-width: 1024px) {
    .spec-bento-col-6 {
        grid-column: span 6;
    }

    .spec-bento-col-4 {
        grid-column: span 4;
    }

    .spec-bento-col-8 {
        grid-column: span 8;
    }
}

.spec-module-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 1.75rem;
    padding: 1.85rem;
    box-shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.06);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.spec-module-card:hover {
    transform: translateY(-3px);
    border-color: #bae6fd;
    box-shadow: 0 20px 36px -14px rgba(14, 165, 233, 0.14);
}

.spec-module-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    color: #0284c7;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.15rem;
}

.spec-metric-pill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 1.15rem;
}

.spec-metric-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.74rem;
    font-weight: 600;
    padding: 0.3rem 0.7rem;
    border-radius: 0.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #334155;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* Symbolic App Screenshot Showcase (Reserved for Real KratosEditor V5 Screenshots) */
.spec-ui-showcase {
    background: linear-gradient(180deg, #0b1120 0%, #0f172a 100%);
    border-radius: 2rem;
    border: 1px solid rgba(56, 189, 248, 0.22);
    padding: 2rem;
    margin-bottom: 3.5rem;
    color: #f8fafc;
    display: none;
}

.spec-ui-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.spec-ui-tab-btn {
    padding: 0.55rem 1rem;
    border-radius: 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.2s ease;
}

.spec-ui-tab-btn:hover {
    border-color: rgba(56, 189, 248, 0.45);
    color: #ffffff;
}

.spec-ui-tab-btn.is-active {
    background: #0284c7;
    border-color: #38bdf8;
    color: #ffffff;
}

.spec-ui-slot-frame {
    position: relative;
    border-radius: 1.25rem;
    overflow: hidden;
    border: 1px dashed rgba(56, 189, 248, 0.45);
    background: #060a12;
    margin-top: 1.25rem;
}

.spec-ui-slider-viewport {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #060a12;
}

.spec-ui-slider-track {
    display: flex;
    width: 100%;
    transition: transform 0.48s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
}

.spec-ui-slide {
    min-width: 100%;
    width: 100%;
    flex-shrink: 0;
    position: relative;
    display: flex;
    flex-direction: column;
}

.spec-ui-slide-media {
    position: relative;
    width: 100%;
    height: 460px;
    background: #050811;
    overflow: hidden;
}

.spec-ui-slide-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.94;
    transition: transform 0.6s ease;
}

.spec-ui-slide:hover .spec-ui-slide-media img {
    transform: scale(1.015);
}

.spec-ui-slot-overlay-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 15;
    background: rgba(9, 13, 22, 0.88);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(56, 189, 248, 0.4);
    color: #7dd3fc;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.spec-ui-slide-step-pill {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 15;
    background: rgba(2, 132, 199, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(125, 211, 252, 0.45);
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.8rem;
    border-radius: 999px;
    letter-spacing: 0.03em;
}

/* Slider Arrow Buttons */
.spec-ui-slider-arrow {
    position: absolute;
    top: 230px;
    transform: translateY(-50%);
    z-index: 20;
    width: 46px;
    height: 46px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.82);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(56, 189, 248, 0.4);
    color: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.45);
}

.spec-ui-slider-arrow:hover {
    background: #0284c7;
    border-color: #7dd3fc;
    transform: translateY(-50%) scale(1.07);
}

.spec-ui-slider-arrow.is-prev {
    left: 1rem;
}

.spec-ui-slider-arrow.is-next {
    right: 1rem;
}

.spec-ui-slot-caption-bar {
    background: rgba(15, 23, 42, 0.96);
    border-top: 1px solid rgba(148, 163, 184, 0.16);
    padding: 1rem 1.25rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

/* Slider Footer: Thumbnails + Dots + Counter */
.spec-ui-slider-footer {
    background: #090e1a;
    border-top: 1px solid rgba(148, 163, 184, 0.14);
    padding: 0.9rem 1.25rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.spec-ui-thumbs {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    overflow-x: auto;
    padding-bottom: 2px;
}

.spec-ui-thumb {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.35rem 0.65rem 0.35rem 0.35rem;
    border-radius: 0.75rem;
    background: rgba(30, 41, 59, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #94a3b8;
    font-size: 0.74rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.spec-ui-thumb img {
    width: 44px;
    height: 30px;
    border-radius: 0.45rem;
    object-fit: cover;
    display: block;
    opacity: 0.75;
}

.spec-ui-thumb:hover {
    border-color: rgba(56, 189, 248, 0.45);
    color: #e2e8f0;
}

.spec-ui-thumb.is-active {
    background: rgba(2, 132, 199, 0.22);
    border-color: #38bdf8;
    color: #ffffff;
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.3);
}

.spec-ui-thumb.is-active img {
    opacity: 1;
}

.spec-ui-dots-wrap {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin-left: auto;
}

.spec-ui-dots {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.spec-ui-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.35);
    border: none;
    padding: 0;
    cursor: pointer;
    transition: all 0.25s ease;
}

.spec-ui-dot.is-active {
    width: 26px;
    background: #38bdf8;
}

.spec-ui-counter {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.75rem;
    font-weight: 700;
    color: #7dd3fc;
    background: rgba(14, 165, 233, 0.14);
    border: 1px solid rgba(56, 189, 248, 0.3);
    padding: 0.25rem 0.6rem;
    border-radius: 0.5rem;
}

/* FAQ Accordion Styling */
.spec-faq-section details>summary {
    list-style: none;
}

.spec-faq-section details>summary::-webkit-details-marker {
    display: none;
}

.spec-faq-section details .chevron {
    transition: transform 0.25s ease-in-out;
}

.spec-faq-section details[open] .chevron {
    transform: rotate(180deg);
}

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

    .spec-ui-showcase {
        padding: 1.25rem;
    }

    .spec-module-card {
        padding: 1.35rem;
    }

    .spec-ui-slide-media {
        height: 270px;
    }

    .spec-ui-slider-arrow {
        top: 135px;
        width: 38px;
        height: 38px;
    }
}