/* ============================================================
   Artikel-Uebersicht und KI-Lexikon
   Praefix ar- (Artikel) und lx- (Lexikon)
   ============================================================ */

.ar-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.ar-chips a {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase;
  color: rgba(230, 238, 242, 0.85); text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.05);
  padding: 8px 14px; border-radius: 999px;
  transition: border-color 0.25s, background 0.25s, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.ar-chips a:hover { border-color: var(--orange-soft); background: rgba(237, 152, 42, 0.14); transform: translateY(-2px); }
.ar-chips b { color: var(--orange-soft); font-weight: 600; }

.ar-section { padding: 72px 0 40px; }
.ar-section .sec-head { margin-bottom: 36px; }

/* ---------- Empfohlener Artikel ---------- */
.ar-feat {
  position: relative; overflow: hidden; margin-bottom: 44px;
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: 36px; align-items: center;
  padding: 48px 48px 44px; border-radius: 24px; color: #E6EEF2;
  background: radial-gradient(700px 420px at 100% 0%, rgba(237, 152, 42, 0.2), transparent 60%), linear-gradient(160deg, #16354A, var(--night) 78%);
  box-shadow: var(--shadow-lift);
}
.ar-feat .mono-label, .ar-feat .mono-label::before { color: var(--orange-soft); }
.ar-feat h3 { font-size: clamp(30px, 4vw, 46px); line-height: 1.06; letter-spacing: -0.03em; color: #fff; margin: 16px 0 14px; }
.ar-feat p.lead { color: rgba(230, 238, 242, 0.78); font-size: 18px; line-height: 1.6; margin: 0 0 22px; max-width: 520px; }
.ar-crit { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 10px; }
.ar-crit li {
  display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: center;
  font-size: 15.5px; color: rgba(230, 238, 242, 0.9); line-height: 1.4;
  opacity: 0; transform: translateX(-14px);
  transition: opacity 0.6s ease-out, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--t, 0s);
}
.ar-feat.in .ar-crit li { opacity: 1; transform: none; }
.ar-crit li i { font-style: normal; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; font-family: var(--font-mono); font-size: 12px; color: var(--orange-soft); border: 1px solid rgba(245, 194, 107, 0.45); background: rgba(237, 152, 42, 0.1); }
.ar-feat .btn { margin-top: 2px; }

.ar-bal { width: 100%; height: auto; max-height: 340px; display: block; }
.ar-bal .bl { fill: none; stroke: rgba(230, 238, 242, 0.85); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ar-bal .bl-or { stroke: var(--orange); }
.ar-bal .bl-dim { stroke: rgba(230, 238, 242, 0.35); stroke-width: 2; }
.ar-bal .pan-fill { fill: rgba(255, 255, 255, 0.06); stroke: rgba(230, 238, 242, 0.85); stroke-width: 3; }
.ar-bal .blk { fill: rgba(237, 152, 42, 0.85); }
.ar-bal .blk2 { fill: rgba(111, 167, 199, 0.85); }
.ar-bal text { font: 600 13px var(--font-mono); letter-spacing: 0.1em; fill: rgba(230, 238, 242, 0.8); text-anchor: middle; }
.ar-bal .beam, .ar-bal .pan { transform-origin: 210px 66px; }
.ar-bal .pan.l { transform-origin: 62px 66px; }
.ar-bal .pan.r { transform-origin: 358px 66px; }
.ar-bal .beam { transform: rotate(-16deg); }
.ar-bal .pan.l, .ar-bal .pan.r { transform: rotate(16deg); }
.ar-feat.in .ar-bal .beam { animation: ar-swing 3.6s both; }
.ar-feat.in .ar-bal .pan { animation: ar-swing-c 3.6s both; }
@keyframes ar-swing {
  0% { transform: rotate(-16deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  26% { transform: rotate(9deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  50% { transform: rotate(-5deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  72% { transform: rotate(2.4deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  100% { transform: rotate(0deg); }
}
@keyframes ar-swing-c {
  0% { transform: rotate(16deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  26% { transform: rotate(-9deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  50% { transform: rotate(5deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  72% { transform: rotate(-2.4deg); animation-timing-function: cubic-bezier(0.45, 0, 0.55, 1); }
  100% { transform: rotate(0deg); }
}

/* ---------- Filter ---------- */
.ar-filter { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 34px; }
.ar-filter button {
  font: 600 14px var(--font-head); color: var(--ink); cursor: pointer;
  padding: 10px 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--card);
  transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.ar-filter button:hover { border-color: var(--orange-soft); transform: translateY(-2px); }
.ar-filter button[aria-pressed="true"] { background: var(--petrol); border-color: var(--petrol); color: #fff; }
.ar-filter button .n { font-family: var(--font-mono); font-size: 12px; opacity: 0.6; margin-left: 6px; }

/* ---------- Gruppen ---------- */
.ar-group { margin-bottom: 56px; }
.ar-group.is-off, .ar-feat.is-off { display: none; }
.ar-ghead { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 22px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.ar-ghead h3 { font-size: clamp(24px, 3vw, 32px); letter-spacing: -0.025em; margin: 0; }
.ar-ghead p { margin: 0; color: var(--gray); font-size: 15.5px; max-width: 460px; }

/* ---------- Karten ---------- */
.ar-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.ar-vis {
  position: relative; height: 128px; display: grid; place-items: center; overflow: hidden;
  background: linear-gradient(135deg, var(--vb1, #E7EFF3), var(--vb2, #F3F1E4));
}
.ar-vis::before {
  content: ""; position: absolute; inset: 0; opacity: 0.55;
  background-image: linear-gradient(rgba(29, 64, 82, 0.07) 1px, transparent 1px), linear-gradient(90deg, rgba(29, 64, 82, 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(circle at 50% 50%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 20%, transparent 78%);
}
.g-recht { --vb1: #E3EDF2; --vb2: #F3F1E4; }
.g-praxis { --vb1: #FBEED6; --vb2: #F6F2E2; }
.g-hint { --vb1: #E8EEE6; --vb2: #F3F1E4; }
.ar-ic { position: relative; width: 120px; height: 90px; overflow: visible; }
.ar-ic * { fill: none; stroke: var(--petrol); stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.ar-ic .ac { stroke: var(--orange-deep); }
.ar-ic .fl { fill: var(--orange); stroke: var(--orange-deep); }
.ar-ic .dr { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.5s cubic-bezier(0.65, 0, 0.35, 1); transition-delay: var(--d, 0s); }
.ar-card.in .ar-ic .dr { stroke-dashoffset: 0; }
.ar-ic .pop { opacity: 0; transform: scale(0.4); transform-box: fill-box; transform-origin: center; transition: opacity 0.4s ease-out, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1); transition-delay: calc(var(--d, 0s) + 0.9s); }
.ar-card.in .ar-ic .pop { opacity: 1; transform: none; }
.ar-ic .hv { transform-box: fill-box; transform-origin: center; transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.ar-card:hover .ar-ic .hv { transform: translateY(-4px) rotate(-4deg); }
.ar-tag { position: absolute; left: 14px; top: 12px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.12em; color: var(--petrol); text-transform: uppercase; z-index: 1; }
.ar-body { padding: 22px 26px 26px; display: flex; flex-direction: column; flex: 1; }
.ar-body .card-num { margin-bottom: 12px; }
.ar-body .card-link { margin-top: auto; padding-top: 20px; }

/* ---------- Lexikon ---------- */
.lx-wrap { display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 56px; align-items: start; }
.lx-side { position: sticky; top: 108px; }
.lx-card { padding: 28px 26px; border-radius: 20px; color: #E6EEF2; background: radial-gradient(500px 300px at 100% 0%, rgba(237, 152, 42, 0.2), transparent 60%), linear-gradient(160deg, #16354A, var(--night) 78%); box-shadow: var(--shadow-lift); }
.lx-card .mono-label, .lx-card .mono-label::before { color: var(--orange-soft); }
.lx-card p { color: rgba(230, 238, 242, 0.75); font-size: 15px; margin: 12px 0 18px; line-height: 1.55; }
.lx-chipset { display: flex; flex-wrap: wrap; gap: 8px; }
.lx-chip {
  font: 600 13px var(--font-head); color: #fff; cursor: pointer;
  padding: 8px 13px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.24); background: rgba(255, 255, 255, 0.06);
  opacity: 0; transform: translateY(10px) scale(0.94);
  transition: opacity 0.5s ease-out, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1), background 0.25s, border-color 0.25s;
  transition-delay: var(--t, 0s);
}
.lx-card.in .lx-chip { opacity: 1; transform: none; }
.lx-card.in .lx-chip:hover { background: rgba(237, 152, 42, 0.22); border-color: var(--orange-soft); transform: translateY(-2px); transition-delay: 0s; }
.lx-card.in .lx-chip.on { background: var(--orange); border-color: var(--orange); color: var(--petrol-deep); }
.lx-t { display: inline-flex; align-items: center; gap: 14px; }
.lx-ic { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; background: var(--bg-alt); transition: background 0.3s, transform 0.5s cubic-bezier(0.16, 1, 0.3, 1); }
.lx-ic svg { width: 21px; height: 21px; fill: none; stroke: var(--petrol); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.acc-item summary:hover .lx-ic, .acc-item[open] .lx-ic { background: rgba(237, 152, 42, 0.2); }
.acc-item[open] .lx-ic svg { stroke: var(--orange-deep); }
.acc-item summary { padding: 18px 4px; }
.acc-item .acc-body { padding-left: 56px; line-height: 1.7; }
.acc-item.flash { animation: lx-flash 1.6s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes lx-flash { 0% { background: rgba(237, 152, 42, 0.22); } 100% { background: transparent; } }

@media (max-width: 1024px) {
  .ar-feat { grid-template-columns: 1fr; padding: 36px 30px; }
  .ar-bal { max-height: 260px; }
  .lx-wrap { grid-template-columns: 1fr; gap: 30px; }
  .lx-side { position: static; }
}
@media (max-width: 720px) {
  .ar-section { padding: 52px 0 24px; }
  .ar-feat { padding: 28px 20px; border-radius: 18px; }
  .ar-group { margin-bottom: 44px; }
  .acc-item .acc-body { padding-left: 4px; }
  .lx-ic { width: 34px; height: 34px; }
}

@media (prefers-reduced-motion: reduce) {
  .ar-crit li, .lx-chip, .ar-ic .dr, .ar-ic .pop { transition: none !important; opacity: 1; transform: none; stroke-dashoffset: 0; }
  .ar-bal .beam, .ar-bal .pan { animation: none !important; transform: none !important; }
  .acc-item.flash { animation: none; }
}

/* Gruppen mit 2 oder 4 Karten: zwei Spalten, keine Luecken */
.grid-3.ar-g2, .grid-3.ar-g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 720px) { .grid-3.ar-g2, .grid-3.ar-g4 { grid-template-columns: 1fr; } }

/* ============================================================
   Bilder, Kontrast, Bewegung (Runde 2)
   ============================================================ */

/* ---------- Hero mit Foto rechts ---------- */
.ar-hero-pic {
  position: absolute; top: 0; right: 0; bottom: 0; width: 44%; z-index: 1; overflow: hidden; pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 45%);
  mask-image: linear-gradient(90deg, transparent 0, #000 45%);
}
.ar-hero-pic::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 26, 34, 0.4), transparent 35%, rgba(10, 26, 34, 0.6)); }
.ar-hero-pic picture, .ar-hero-pic img { display: block; width: 100%; height: 100%; }
.ar-hero-pic img { object-fit: cover; filter: saturate(0.9) brightness(0.88); transform: scale(1.1); animation: ar-pic-in 2.2s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both; }
@keyframes ar-pic-in {
  0% { opacity: 0; transform: translate3d(40px, 0, 0) scale(1.3); }
  35% { opacity: 0.9; }
  100% { opacity: 1; transform: scale(1.1); }
}
.ar-hero h1, .ar-hero .sub { max-width: min(100%, 640px); }
@media (max-width: 960px) {
  .ar-hero-pic { left: 0; width: auto; opacity: 0.28; -webkit-mask-image: linear-gradient(180deg, #000 30%, transparent 100%); mask-image: linear-gradient(180deg, #000 30%, transparent 100%); }
  .ar-hero h1, .ar-hero .sub { max-width: 100%; }
}

/* ---------- Empfohlener Artikel: Foto als Hintergrund ---------- */
.ar-feat > div { position: relative; z-index: 1; }
.ar-feat-bg { display: block; position: absolute; inset: 0; z-index: 0; opacity: 0.3; -webkit-mask-image: linear-gradient(100deg, transparent 20%, #000 100%); mask-image: linear-gradient(100deg, transparent 20%, #000 100%); }
.ar-feat-bg img { display: block; width: 100%; height: 100%; object-fit: cover; transform: scale(1.12); transition: transform 2.4s cubic-bezier(0.16, 1, 0.3, 1); }
.ar-feat.in .ar-feat-bg img { transform: scale(1); }

/* ---------- Karten: Foto mit dunklem Band, Zeichnung darueber ---------- */
.ar-vis.has-ph { height: 188px; background: var(--night); }
.ar-vis.has-ph::before { display: none; }
.ar-ph { display: block; position: absolute; inset: 0; }
.ar-ph img { display: block; width: 100%; height: 100%; object-fit: cover; filter: grayscale(0.55) contrast(1.05) brightness(0.8); transform: scale(1.12); transition: transform 1.4s cubic-bezier(0.16, 1, 0.3, 1), filter 0.7s ease-out; }
.ar-card.in .ar-ph img { transform: scale(1); }
.ar-card:hover .ar-ph img { filter: grayscale(0) contrast(1.05) brightness(0.95); transform: scale(1.06); }
.ar-vis.has-ph::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 26, 34, 0.62), rgba(10, 26, 34, 0.12) 45%, rgba(10, 26, 34, 0.78)); pointer-events: none; }
.ar-vis.has-ph .ar-tag { color: #fff; z-index: 2; background: rgba(10, 26, 34, 0.5); padding: 5px 10px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.22); left: 14px; top: 14px; }
.ar-vis.has-ph .ar-ic { position: absolute; right: 14px; bottom: 10px; width: 84px; height: 63px; z-index: 2; }
.ar-vis.has-ph .ar-ic * { stroke: rgba(255, 255, 255, 0.92); }
.ar-vis.has-ph .ar-ic .ac { stroke: var(--orange-soft); }
.ar-vis.has-ph .ar-ic .fl { fill: var(--orange); stroke: var(--orange-soft); }

/* ---------- Lexikon im dunklen Band ---------- */
.night .acc { border-top-color: rgba(255, 255, 255, 0.16); }
.night .acc-item { border-bottom-color: rgba(255, 255, 255, 0.12); }
.night .acc-item summary { color: #fff; }
.night .acc-item summary:hover { color: var(--orange-soft); }
.night .acc-item .acc-body { color: rgba(230, 238, 242, 0.78); }
.night .acc-item .acc-body a { color: var(--orange-soft); }
.night .lx-ic { background: rgba(255, 255, 255, 0.08); }
.night .lx-ic svg { stroke: var(--steel-light); }
.night .acc-item summary:hover .lx-ic, .night .acc-item[open] .lx-ic { background: rgba(237, 152, 42, 0.22); }
.night .acc-item[open] .lx-ic svg { stroke: var(--orange-soft); }
.night .lx-card { background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.14); box-shadow: none; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.lx-side .spec { aspect-ratio: 16 / 10; margin-top: 18px; }
@media (max-width: 1024px) { .lx-side .spec { aspect-ratio: 16 / 9; } }
@media (prefers-reduced-motion: reduce) {
  .ar-hero-pic img { animation: none; transform: none; }
  .ar-feat-bg img, .ar-ph img { transform: none; transition: none; }
}
