/* ==========================================================================
   deft NDT GmbH - Master Stylesheet (100% lokal, DSGVO- & TDDDG-konform)
   Null externe Requests, keine US-Cloud, B2B High-End Industrial Dark/Light
   ========================================================================== */

/* 1. PREFLIGHT / BROWSER-RESET */
*, ::before, ::after {
    box-sizing: border-box;
    border-width: 0;
    border-style: solid;
    border-color: #E5E7EB;
    margin: 0;
    padding: 0;
}

html {
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
    tab-size: 4;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    line-height: inherit;
    background-color: #F3F4F6;
    color: #111827;
    -webkit-font-smoothing: antialiased;
    border-top: 4px solid #808080;
}

a {
    color: inherit;
    text-decoration: none;
    cursor: pointer;
}

button {
    background-color: transparent;
    background-image: none;
    color: inherit;
    font-family: inherit;
    font-size: 100%;
    line-height: inherit;
    border: none;
    padding: 0;
    margin: 0;
    cursor: pointer;
}

img, svg {
    display: block;
    max-width: 100%;
}

/* 2. TYPOGRAFIE & SCHRIFTEN */
.font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }
.font-sans { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
.tabular-nums { font-variant-numeric: tabular-nums; }

.text-\[9px\] { font-size: 9px; line-height: 12px; }
.text-\[10px\] { font-size: 10px; line-height: 14px; }
.text-\[11px\] { font-size: 11px; line-height: 15px; }
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }

.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-black, .font-extrabold { font-weight: 900; }

.uppercase { text-transform: uppercase; }
.tracking-tight { letter-spacing: -0.025em; }
.tracking-wide { letter-spacing: 0.025em; }
.tracking-wider { letter-spacing: 0.05em; }
.tracking-widest { letter-spacing: 0.1em; }
.leading-none { line-height: 1; }
.leading-tight { line-height: 1.25; }
.leading-relaxed { line-height: 1.625; }

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.underline { text-decoration: underline !important; }
.select-none { user-select: none; }

/* 3. FARBEN (BRANDING deft NDT) */
.text-brandTextDark { color: #111827 !important; }
.text-brandGrayText { color: #4B5563 !important; }
.text-brandSteel { color: #808080 !important; }
.text-black { color: #000000 !important; }
.text-white { color: #ffffff !important; }
.text-neutral-400 { color: #9CA3AF !important; }
.text-emerald-800 { color: #065F46 !important; }
.text-rose-800 { color: #9F1239 !important; }
.text-waGreen { color: #25D366 !important; }

.bg-white { background-color: #ffffff; }
.bg-black { background-color: #000000; }
.bg-brandBg { background-color: #F3F4F6; }
.bg-brandLightGray { background-color: #F9FAFB; }
.bg-brandSteel { background-color: #808080; }
.bg-neutral-100 { background-color: #F3F4F6; }
.bg-neutral-950 { background-color: #0a0a0a; }
.bg-emerald-50 { background-color: #ECFDF5; }
.bg-rose-50 { background-color: #FFF1F2; }
.bg-white\/95 { background-color: rgba(255, 255, 255, 0.95); }
.bg-black\/60 { background-color: rgba(0, 0, 0, 0.6); }
.bg-black\/80 { background-color: rgba(0, 0, 0, 0.8); }

.border { border-width: 1px; }
.border-t { border-top-width: 1px; }
.border-b { border-bottom-width: 1px; }
.border-r { border-right-width: 1px; }
.border-t-4 { border-top-width: 4px; }

.border-brandBorder { border-color: #E5E7EB; }
.border-brandBorder\/60 { border-color: rgba(229, 231, 235, 0.6); }
.border-brandSteel { border-color: #808080; }
.border-emerald-200 { border-color: #A7F3D0; }
.border-rose-200 { border-color: #FECDD3; }
.border-white\/10 { border-color: rgba(255, 255, 255, 0.1); }

/* 4. BASIS-LAYOUT, FLEXBOX & GRID */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.shrink-0 { flex-shrink: 0 !important; }

.header-nav {
    display: flex;
    align-items: center;
    gap: 1.75rem;
}
@media (min-width: 1280px) {
    .header-nav { gap: 2.25rem; }
}

.footer-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.grid { display: grid; }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-12 { gap: 3rem; }

.space-x-1\.5 > :not([hidden]) ~ :not([hidden]) { margin-left: 0.375rem; }
.space-x-2 > :not([hidden]) ~ :not([hidden]) { margin-left: 0.5rem; }
.space-x-2\.5 > :not([hidden]) ~ :not([hidden]) { margin-left: 0.625rem; }
.space-x-3 > :not([hidden]) ~ :not([hidden]) { margin-left: 0.75rem; }
.space-x-4 > :not([hidden]) ~ :not([hidden]) { margin-left: 1rem; }

.space-y-1\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.375rem; }
.space-y-2 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.5rem; }
.space-y-2\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.625rem; }
.space-y-3 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.75rem; }
.space-y-4 > :not([hidden]) ~ :not([hidden]) { margin-top: 1rem; }

/* 5. ABSTÄNDE & SIZING */
.p-2 { padding: 0.5rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-2\.5 { padding-left: 0.625rem; padding-right: 0.625rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-3\.5 { padding-left: 0.875rem; padding-right: 0.875rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-3\.5 { padding-top: 0.875rem; padding-bottom: 0.875rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }

.pt-0 { padding-top: 0; }
.pt-2 { padding-top: 0.5rem; }
.pt-3 { padding-top: 0.75rem; }
.pt-4 { padding-top: 1rem; }
.pt-8 { padding-top: 2rem; }
.pt-12 { padding-top: 3rem; }
.pt-16 { padding-top: 4rem; }
.pt-20 { padding-top: 5rem; }

.pb-1 { padding-bottom: 0.25rem; }
.pb-2 { padding-bottom: 0.5rem; }
.pb-3 { padding-bottom: 0.75rem; }
.pb-4 { padding-bottom: 1rem; }
.pb-6 { padding-bottom: 1.5rem; }
.pb-16 { padding-bottom: 4rem; }
.pr-3\.5 { padding-right: 0.875rem; }
.pr-4 { padding-right: 1rem; }
.pl-6 { padding-left: 1.5rem; }
.pl-8 { padding-left: 2rem; }

.mt-0\.5 { margin-top: 0.125rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-1\.5 { margin-top: 0.375rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }
.mt-20 { margin-top: 5rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-1\.5 { margin-bottom: 0.375rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-14 { margin-bottom: 3.5rem; }
.mb-16 { margin-bottom: 4rem; }
.mb-20 { margin-bottom: 5rem; }

.w-auto { width: auto; }
.w-full { width: 100%; }
.w-2 { width: 0.5rem; }
.h-2 { height: 0.5rem; }
.w-3\.5 { width: 0.875rem; }
.h-3\.5 { height: 0.875rem; }
.w-4 { width: 1rem; }
.h-4 { height: 1rem; }
.h-7 { height: 1.75rem; }
.h-8 { height: 2rem; }
.h-14 { height: 3.5rem; }
.h-20 { height: 5rem; }
.h-44 { height: 11rem; }
.h-72 { height: 18rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-7xl { max-width: 80rem; margin-left: auto; margin-right: auto; }
.min-h-\[320px\] { min-height: 320px; }
.max-h-80 { max-height: 20rem; }
.max-h-\[85vh\] { max-height: 85vh; }

/* 6. POSITIONIERUNG & SICHTBARKEIT */
.relative { position: relative; }
.absolute { position: absolute; }
.sticky { position: sticky; }
.fixed { position: fixed; }
.top-0 { top: 0; }
.top-2\.5 { top: 0.625rem; }
.right-2\.5 { right: 0.625rem; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }
.hidden { display: none; }
.block { display: block; }
.inline-block { display: inline-block; }

/* 7. FORMULARE, RAHMEN & INTERAKTIONEN */
.rounded { border-radius: 0.25rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-full { border-radius: 9999px; }
.shadow-sm { box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }

.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }
.whitespace-nowrap { white-space: nowrap; }
.object-contain { object-fit: contain; }
.object-cover { object-fit: cover; }
.cursor-pointer { cursor: pointer; }

.backdrop-blur-md { backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.backdrop-blur-sm { backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }

.transition { transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1); }
.transition-all { transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1); }
.duration-200 { transition-duration: 200ms; }
.duration-300 { transition-duration: 300ms; }

/* Hover States */
.hover\:bg-neutral-800:hover { background-color: #262626 !important; }
.hover\:bg-neutral-100:hover { background-color: #f5f5f5 !important; }
.hover\:text-black:hover { color: #000000 !important; }
.hover\:border-black:hover { border-color: #000000 !important; }
.hover\:border-brandSteel:hover { border-color: #808080 !important; }
.hover\:underline:hover { text-decoration: underline !important; }

.group:hover .group-hover\:scale-105 { transform: scale(1.05); }
.group:hover .group-hover\:text-black { color: #000000 !important; }

/* 8. RESPONSIVE DESIGN BREAKPOINTS */
@media (min-width: 640px) {
    .sm\:flex { display: flex !important; }
    .sm\:inline { display: inline !important; }
    .sm\:inline-block { display: inline-block !important; }
    .sm\:inline-flex { display: inline-flex !important; }
    .sm\:flex-row { flex-direction: row; }
    .sm\:items-center { align-items: center; }
    .sm\:h-8 { height: 2rem; }
    .sm\:h-9 { height: 2.25rem; }
    .sm\:h-48 { height: 12rem; }
    .sm\:h-96 { height: 24rem; }
    .sm\:text-base { font-size: 1rem; line-height: 1.5rem; }
    .sm\:text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
    .sm\:text-6xl { font-size: 3.75rem; line-height: 1; }
    .sm\:p-8 { padding: 2rem; }
    .sm\:px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
    .sm\:px-3\.5 { padding-left: 0.875rem; padding-right: 0.875rem; }
    .sm\:py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
    .sm\:gap-2 { gap: 0.5rem; }
    .sm\:mt-16 { margin-top: 4rem; }
}

@media (min-width: 768px) {
    .md\:flex { display: flex !important; }
    .md\:inline-flex { display: inline-flex !important; }
    .md\:flex-row { flex-direction: row; }
    .md\:items-center { align-items: center; }
    .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .md\:border-t-0 { border-top-width: 0 !important; }
    .md\:border-l { border-left-width: 1px !important; }
    .md\:pt-0 { padding-top: 0 !important; }
    .md\:pl-6 { padding-left: 1.5rem !important; }
}

@media (min-width: 1024px) {
    .lg\:flex { display: flex !important; }
    .lg\:flex-row { flex-direction: row !important; }
    .lg\:items-center { align-items: center !important; }
    .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .lg\:grid-cols-12 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
    .lg\:col-span-5 { grid-column: span 5 / span 5; }
    .lg\:col-span-6 { grid-column: span 6 / span 6; }
    .lg\:col-span-7 { grid-column: span 7 / span 7; }
    .lg\:p-8 { padding: 2rem; }
    .lg\:border-t-0 { border-top-width: 0 !important; }
    .lg\:border-l { border-left-width: 1px !important; }
    .lg\:pt-0 { padding-top: 0 !important; }
    .lg\:pl-8 { padding-left: 2rem !important; }
}

@media (min-width: 1280px) {
    .xl\:flex { display: flex !important; }
}

/* 9. PRÄZISE CSS-DOT-MATRIX */
.dot-container {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.dot {
    width: 8px;
    height: 8px;
    border-radius: 9999px;
    display: inline-block;
    flex-shrink: 0;
}
.dot-active {
    background-color: #111827;
}
.dot-inactive {
    background-color: #E5E7EB;
    box-shadow: inset 0 0 0 1px #D1D5DB;
}

.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

.sys-tab-btn.active {
    background-color: #111827 !important;
    color: #FFFFFF !important;
    border-color: #111827 !important;
}
.sys-tab-btn.active:hover {
    color: #FFFFFF !important;
    background-color: #1F2937 !important;
}
.sys-tab-btn:not(.active):hover {
    background-color: #E5E7EB !important;
    color: #111827 !important;
}

th.sortable:hover {
    background-color: #E5E7EB;
    cursor: pointer;
}

table {
    width: 100%;
    border-collapse: collapse;
}
.divide-y > tr:not(:first-child) {
    border-top-width: 1px;
    border-top-color: #E5E7EB;
}

@keyframes pulse {
    50% { opacity: .5; }
}
.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* 10. MOBILE FIX (< 640px) */
@media (max-width: 640px) {
    h1 {
        font-size: 2.1rem !important;
        line-height: 1.15 !important;
        letter-spacing: -0.02em !important;
        word-break: normal !important;
        overflow-wrap: break-word !important;
        hyphens: auto !important;
    }

    .grid-cols-2, .grid-cols-3, .lg\:grid-cols-2, .lg\:grid-cols-3 {
        display: flex !important;
        flex-direction: column !important;
        gap: 0.75rem !important;
        width: 100% !important;
    }

    #showcaseAnchor .space-y-1\.5 > div,
    #lab .space-y-2\.5 > div {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        background-color: #F9FAFB !important;
        padding: 0.75rem !important;
        border-radius: 0.375rem !important;
        border: 1px solid #E5E7EB !important;
        margin-bottom: 0.5rem !important;
        width: 100% !important;
    }

    #showcaseAnchor .space-y-1\.5 > div span:first-child,
    #lab .space-y-2\.5 > div span:first-child {
        font-size: 11px !important;
        color: #4B5563 !important;
        margin-bottom: 0.125rem !important;
    }

    #showcaseAnchor .space-y-1\.5 > div span:last-child,
    #lab .space-y-2\.5 > div span:last-child {
        text-align: left !important;
        font-weight: 700 !important;
        color: #111827 !important;
    }

    .p-8 { padding: 1rem !important; }
    .max-w-7xl { padding-left: 0.75rem !important; padding-right: 0.75rem !important; }
}
/* 11. ERGÄNZUNGEN (Hero-Zeichnung, Ablauf, Ansprechpartner, WhatsApp-Button, Systeme-Teaser) */
.h-5 { height: 1.25rem; }
.h-6 { height: 1.5rem; }
@media (min-width: 640px) {
    .sm\:h-6 { height: 1.5rem; }
}
.max-h-full { max-height: 100%; }
.sys-teaser { cursor: pointer; display: block; width: 100%; border-style: solid !important; }
#systemsOpenBtn { border-style: solid !important; }

/* Hero: dekorative Linienzeichnung, nur ab Tablet-Querformat */
.hero-art {
    display: none;
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 46%;
    overflow: hidden;
    pointer-events: none;
    opacity: 0.08;
}
.hero-art svg {
    position: absolute;
    top: 50%;
    right: -6%;
    width: 560px;
    max-width: none;
    transform: translateY(-50%);
}
.hero-content { position: relative; z-index: 1; }
@media (min-width: 1024px) {
    .hero-art { display: block; }
}

/* Ansprechpartner mit Porträts */
.contact-people {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 0.75rem;
}
.contact-person {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    line-height: 1.4;
}
.portrait {
    width: 56px;
    height: 56px;
    border-radius: 9999px;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid #E5E7EB;
}

/* WhatsApp-Button nur auf dem Handy */
.wa-float {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 45;
    width: 52px;
    height: 52px;
    border-radius: 9999px;
    background-color: #ffffff;
    border: 1px solid #E5E7EB;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}
.wa-float img { width: 24px; height: 24px; }
@media (min-width: 640px) {
    .wa-float { display: none; }
}
