/* ═══════════ Taxonomía · explorador de la clasificación de los faisanes ═══════════ */
.rd-tax{background:#fff;}
.rd-tax .sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;}
.tx-wrap{max-width:1560px;margin:0 auto;padding-inline:clamp(18px,3vw,56px);}
.tx-hero{background:radial-gradient(120% 160% at 12% 0%,var(--forest) 0%,var(--forest-dark) 64%);color:#fff;padding:clamp(40px,6vw,76px) 0 clamp(34px,5vw,60px);position:relative;overflow:hidden;}
.tx-hero::after{content:"";position:absolute;inset:auto -8% -42% auto;width:46vw;max-width:640px;aspect-ratio:1;border-radius:50%;background:radial-gradient(circle,oklch(75% .12 85 / .22),transparent 66%);pointer-events:none;}
.tx-kicker{margin:0 0 14px;font-size:12px;font-weight:800;letter-spacing:.18em;text-transform:uppercase;color:var(--gold);}
.tx-hero h1{margin:0;font-family:'Bebas Neue',Impact,'Arial Narrow Bold',sans-serif;font-weight:400;font-size:clamp(44px,6.4vw,92px);line-height:.95;letter-spacing:.012em;color:#fff;max-width:18ch;text-wrap:balance;}
.tx-deck{margin:18px 0 0;max-width:62ch;font-size:clamp(16px,1.3vw,19px);line-height:1.55;color:oklch(88% .02 150);}
.tx-counters{display:flex;flex-wrap:wrap;gap:clamp(22px,4vw,64px);margin:32px 0 0;padding:0;}
.tx-counters > div{margin:0;}
.tx-counters dd{margin:0;font-family:'Bebas Neue',Impact,sans-serif;font-size:clamp(46px,5vw,72px);line-height:1;color:#fff;font-variant-numeric:tabular-nums;order:-1;}
.tx-counters div{display:flex;flex-direction:column;}
.tx-counters dt{margin-top:6px;font-size:11.5px;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:oklch(80% .03 100);}
.tx-rev{margin:26px 0 0;font-size:13px;color:oklch(82% .02 150);}
.tx-rev a{color:var(--gold);font-weight:700;text-decoration:underline;text-underline-offset:3px;}

/* barra de herramientas */
.tx-bar{position:sticky;top:var(--nav-h,64px);z-index:80;background:oklch(98.6% .006 85 / .94);backdrop-filter:blur(14px) saturate(1.3);-webkit-backdrop-filter:blur(14px) saturate(1.3);border-bottom:1px solid var(--line);}
.tx-barin{display:flex;flex-wrap:wrap;gap:8px 12px;align-items:center;padding-block:10px;}
.tx-search{position:relative;flex:1 1 300px;min-width:min(100%,260px);display:block;color:oklch(45% .03 150);}
.tx-search svg{position:absolute;left:14px;top:50%;translate:0 -50%;pointer-events:none;}
.tx-search input{width:100%;box-sizing:border-box;height:40px;border:1px solid var(--line);border-radius:999px;background:#fff;padding:0 16px 0 40px;font:500 15px 'Public Sans',system-ui,sans-serif;color:var(--ink);outline:0;transition:border-color .2s,box-shadow .2s;}
.tx-search input:focus{border-color:var(--forest);box-shadow:0 0 0 4px oklch(40% .08 155 / .14);}
.tx-filters{display:flex;gap:6px;flex-wrap:wrap;}
.tx-fchip{display:inline-flex;align-items:center;gap:6px;height:34px;padding:0 12px 0 10px;border-radius:999px;border:1px solid var(--line);background:#fff;font:800 11.5px 'Public Sans',sans-serif;letter-spacing:.06em;color:var(--ink);cursor:pointer;transition:background .2s,border-color .2s,transform .2s;}
.tx-fchip i{width:10px;height:10px;border-radius:50%;background:var(--c);box-shadow:0 0 0 3px color-mix(in oklch,var(--c) 22%,transparent);}
.tx-fchip span{font-weight:600;opacity:.55;font-variant-numeric:tabular-nums;}
.tx-fchip:hover{border-color:var(--c);}
.tx-fchip[aria-pressed="true"]{background:var(--c);border-color:var(--c);color:#fff;}
.tx-fchip[aria-pressed="true"] i{background:#fff;box-shadow:none;}
.tx-tog,.tx-btn{display:inline-flex;align-items:center;gap:8px;height:36px;padding:0 14px;border-radius:999px;border:1px solid var(--line);background:#fff;font:700 12.5px 'Public Sans',sans-serif;letter-spacing:.03em;color:var(--ink);cursor:pointer;transition:background .2s,color .2s,border-color .2s;}
.tx-tog:hover,.tx-btn:hover{border-color:var(--forest);}
.tx-tog[aria-pressed="true"]#tx-ren{background:var(--forest);border-color:var(--forest);color:#fff;}
.tx-tog.ghost{border-style:dashed;color:var(--crimson-dark);}
.tx-seg{display:inline-flex;border:1px solid var(--line);border-radius:999px;background:#fff;padding:3px;}
.tx-seg button{height:30px;padding:0 15px;border:0;border-radius:999px;background:transparent;font:700 12.5px 'Public Sans',sans-serif;color:oklch(38% .03 150);cursor:pointer;}
.tx-seg button[aria-pressed="true"]{background:var(--forest);color:#fff;}
.tx-status{margin:0 0 16px;font-size:13.5px;color:oklch(42% .03 150);font-variant-numeric:tabular-nums;}
.tx-status b{color:var(--ink);}
button:focus-visible,a:focus-visible,summary:focus-visible,input:focus-visible{outline:3px solid oklch(62% .14 85);outline-offset:2px;border-radius:8px;}

/* maquetación */
.tx-layout{display:grid;grid-template-columns:230px minmax(0,1fr);gap:clamp(24px,4vw,64px);padding-block:44px 90px;align-items:start;}
.tx-rail{position:sticky;top:calc(var(--nav-h,64px) + 84px);max-height:calc(100vh - var(--nav-h,64px) - 110px);}
.tx-railt{margin:0 0 10px;font-size:11px;font-weight:800;letter-spacing:.18em;text-transform:uppercase;color:var(--crimson-dark);}
.tx-rail ol{list-style:none;margin:0;padding:0;}
.tx-rail ol a{display:flex;justify-content:space-between;gap:10px;padding:6px 10px 6px 12px;border-left:2px solid var(--line);font-size:14px;color:oklch(34% .03 150);text-decoration:none;transition:color .2s,border-color .2s,background .2s;}
.tx-rail ol a b{font-weight:600;font-size:12px;opacity:.5;font-variant-numeric:tabular-nums;}
.tx-rail ol a:hover{background:oklch(97% .01 85);border-left-color:var(--gold);}
.tx-rail ol a.on{border-left-color:var(--crimson);color:var(--ink);font-weight:700;background:oklch(97% .012 85);}
.tx-rail ol a.dim{opacity:.35;}
.tx-railf{display:flex;flex-direction:column;gap:2px;margin:16px 0 0;padding-top:12px;border-top:1px solid var(--line);}
.tx-railf a{font-size:13px;font-weight:600;color:oklch(40% .03 150);text-decoration:none;padding:3px 0 3px 14px;}
.tx-railf a:hover{color:var(--crimson);}
.tx-sec{margin-bottom:64px;scroll-margin-top:calc(var(--nav-h,64px) + 90px);}
.tx-sec > h2{margin:0 0 12px;font-family:'Bebas Neue',Impact,sans-serif;font-weight:400;font-size:clamp(30px,3vw,44px);letter-spacing:.03em;color:var(--forest);display:flex;align-items:center;gap:16px;}
.tx-sec > h2::before{content:"";flex:none;width:38px;height:4px;border-radius:99px;background:linear-gradient(90deg,var(--gold),var(--crimson));}
.tx-lead{margin:0 0 22px;max-width:76ch;font-size:16.5px;line-height:1.65;color:oklch(32% .02 155);}

/* linaje */
.tx-ribbon{list-style:none;margin:0 0 14px;padding:0;display:flex;flex-wrap:wrap;gap:0;}
.tx-ribbon li{position:relative;display:flex;flex-direction:column;gap:2px;padding:12px 26px 12px 18px;background:var(--sand);margin-right:-6px;clip-path:polygon(0 0,calc(100% - 14px) 0,100% 50%,calc(100% - 14px) 100%,0 100%,14px 50%);min-width:130px;}
.tx-ribbon li:first-child{clip-path:polygon(0 0,calc(100% - 14px) 0,100% 50%,calc(100% - 14px) 100%,0 100%);border-radius:12px 0 0 12px;}
.tx-ribbon li:nth-child(even){background:oklch(94.5% .02 85);}
.tx-ribbon li:last-child{background:var(--forest);color:#fff;}
.tx-ribbon .rk{font-size:10px;font-weight:800;letter-spacing:.16em;text-transform:uppercase;opacity:.65;}
.tx-ribbon em{font-family:'Newsreader',Georgia,serif;font-size:18px;font-style:italic;}
.tx-fulltree summary{cursor:pointer;display:inline-flex;align-items:center;gap:8px;font:700 13px 'Public Sans',sans-serif;color:var(--crimson-dark);padding:6px 0;list-style:none;}
.tx-fulltree summary::-webkit-details-marker{display:none;}
.tx-fulltree summary::before{content:"+";display:inline-grid;place-items:center;width:22px;height:22px;border-radius:50%;border:1px solid var(--crimson);font-size:15px;line-height:1;}
.tx-fulltree[open] summary::before{content:"–";}
.tx-ranks{list-style:none;margin:14px 0 0;padding:0 0 0 6px;max-width:640px;border-left:2px solid var(--line);}
.tx-ranks li{position:relative;display:grid;grid-template-columns:130px 1fr;gap:12px;padding:6px 0 6px 20px;font-size:14.5px;border-bottom:1px dotted oklch(90% .01 85);}
.tx-ranks li::before{content:"";position:absolute;left:-6px;top:14px;width:10px;height:10px;border-radius:50%;background:#fff;border:2px solid var(--gold);}
.tx-ranks li.key::before{background:var(--crimson);border-color:var(--crimson);}
.tx-ranks .rk{font-size:11px;font-weight:800;letter-spacing:.13em;text-transform:uppercase;color:oklch(45% .03 150);padding-top:2px;}
.tx-ranks em{font-family:'Newsreader',Georgia,serif;font-size:17px;}
.au{color:oklch(48% .02 150);font-size:.82em;font-style:normal;font-weight:500;}

/* panorama */
.tx-charts{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,320px),1fr));gap:20px;}
.tx-fig{margin:0;padding:22px 24px;border:1px solid var(--line);border-radius:20px;background:var(--paper-raised,#faf8f3);}
.tx-fig figcaption{display:flex;flex-direction:column;gap:2px;margin-bottom:16px;}
.tx-fig figcaption b{font-size:15px;color:var(--ink);}
.tx-fig figcaption span{font-size:12.5px;color:oklch(48% .02 150);}
.tx-stack{display:flex;gap:3px;height:54px;}
.tx-stack .seg{flex:var(--w) 1 0;min-width:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;border:0;border-radius:10px;background:var(--c);color:#fff;font:inherit;cursor:pointer;transition:transform .2s,filter .2s,box-shadow .2s;}
.tx-stack .seg b{font-size:12px;letter-spacing:.06em;}
.tx-stack .seg span{font-size:15px;font-weight:700;font-variant-numeric:tabular-nums;}
.tx-stack .seg:hover{transform:translateY(-3px);filter:saturate(1.15);}
.tx-stack .seg[aria-pressed="true"]{box-shadow:0 0 0 3px #fff,0 0 0 5px var(--c);}
.tx-legend{list-style:none;display:flex;flex-wrap:wrap;gap:6px 18px;margin:14px 0 0;padding:0;font-size:12.5px;color:oklch(36% .02 150);}
.tx-legend i{display:inline-block;width:10px;height:10px;border-radius:50%;background:var(--c);margin-right:6px;}
.tx-legend b{font-variant-numeric:tabular-nums;}
.tx-bars{list-style:none;margin:0;padding:0;display:grid;gap:7px;}
.tx-bars a{display:grid;grid-template-columns:120px 1fr 34px;align-items:center;gap:10px;text-decoration:none;color:var(--ink);font-size:13.5px;}
.tx-bars .bar{display:block;height:12px;border-radius:99px;background:oklch(94% .012 85);overflow:hidden;}
.tx-bars .bar i{display:block;height:100%;width:var(--w);border-radius:99px;background:linear-gradient(90deg,var(--forest),oklch(55% .12 150));transition:width .8s cubic-bezier(.2,.8,.2,1);}
.tx-bars b{text-align:right;font-variant-numeric:tabular-nums;}
.tx-bars a:hover em{color:var(--crimson);}

/* géneros */
#tx-tree{display:grid;gap:18px;}
.tx-genus{border:1px solid var(--line);border-radius:22px;background:#fff;scroll-margin-top:calc(var(--nav-h,64px) + 96px);}
.tx-genus > summary{display:grid;grid-template-columns:46px minmax(0,1.3fr) auto minmax(80px,200px) 22px;align-items:center;gap:16px;padding:16px 22px;cursor:pointer;list-style:none;border-radius:22px;background:linear-gradient(180deg,oklch(98.4% .008 85),#fff);}
.tx-genus > summary::-webkit-details-marker{display:none;}
.tx-gimg{width:46px;height:46px;border-radius:50%;object-fit:cover;background:var(--sand);box-shadow:0 0 0 3px #fff,0 0 0 4px var(--line);}
.tx-gname{display:flex;flex-direction:column;min-width:0;}
.tx-gname em{font-family:'Newsreader',Georgia,serif;font-size:26px;line-height:1.1;color:var(--forest);}
.tx-gname small{font-size:13px;}
.tx-gcount{font-size:13px;color:oklch(40% .02 150);white-space:nowrap;font-variant-numeric:tabular-nums;}
.tx-gcount b{color:var(--ink);}
.tx-gbar{display:flex;gap:2px;height:8px;}
.tx-gbar i{flex:var(--w) 1 0;border-radius:99px;background:var(--c);}
.tx-caret{width:12px;height:12px;border-right:2px solid var(--crimson);border-bottom:2px solid var(--crimson);rotate:45deg;transition:rotate .25s;justify-self:end;margin-top:-4px;}
.tx-genus[open] .tx-caret{rotate:225deg;margin-top:4px;}
.tx-genus[open] > summary{border-bottom:1px solid var(--line);border-radius:22px 22px 0 0;}
.tx-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,300px),1fr));gap:14px;padding:20px;}

/* especie */
.tx-sp{display:flex;flex-direction:column;gap:8px;padding:16px 16px 14px;border:1px solid var(--line);border-radius:16px;background:#fff;transition:box-shadow .25s,transform .25s,border-color .25s;content-visibility:auto;contain-intrinsic-size:auto 220px;}
.tx-sp:hover{box-shadow:0 22px 36px -28px oklch(20% .06 155 / .55);transform:translateY(-2px);border-color:var(--gold-soft,var(--gold));}
.tx-sp:target{box-shadow:0 0 0 3px var(--gold);}
.tx-sp-top{display:grid;grid-template-columns:52px minmax(0,1fr) auto;gap:12px;align-items:center;}
.tx-ico{width:52px;height:52px;border-radius:50%;object-fit:cover;background:var(--sand);}
.tx-sp h4{margin:0;font-weight:400;font-size:17px;line-height:1.2;}
.tx-sp h4 .sci{font-family:'Newsreader',Georgia,serif;font-size:19px;color:var(--ink);}
.tx-sp .au{margin:2px 0 0;}
.tx-chip{display:inline-flex;align-items:center;gap:6px;height:26px;padding:0 10px 0 8px;border-radius:999px;background:oklch(97% .01 85);border:1px solid var(--line);font:800 11px 'Public Sans',sans-serif;letter-spacing:.08em;}
.tx-chip i{width:9px;height:9px;border-radius:50%;background:var(--c);box-shadow:0 0 8px var(--c);}
.tx-common{margin:0;font-weight:600;font-size:15px;color:var(--forest);}
.tx-sp-meta{display:flex;flex-wrap:wrap;gap:6px;align-items:center;font-size:12.5px;color:oklch(46% .02 150);}
.tx-new{display:inline-flex;align-items:center;font-size:9.5px;font-weight:800;letter-spacing:.1em;text-transform:uppercase;line-height:1;color:oklch(22% .05 150);background:linear-gradient(135deg,oklch(86% .14 85),oklch(78% .15 70));border-radius:999px;padding:5px 8px;}
.tx-new.inl{vertical-align:1px;}
.tx-tag{font-size:9.5px;font-weight:800;letter-spacing:.1em;text-transform:uppercase;border:1px dashed var(--crimson);color:var(--crimson-dark);border-radius:999px;padding:4px 8px;}
.tx-extra{margin:0;font-size:13px;}
.tx-extra a{color:var(--crimson-dark);font-weight:700;}
.tx-fn{text-decoration:none;color:var(--crimson);margin-left:2px;font-weight:700;}
.tx-sp-act{display:flex;justify-content:space-between;align-items:center;margin-top:auto;padding-top:8px;border-top:1px dotted var(--line);}
.tx-go{font-size:13px;font-weight:800;color:var(--crimson);text-decoration:none;}
.tx-go:hover{text-decoration:underline;text-underline-offset:3px;}
.tx-copy{border:0;background:transparent;font:700 11.5px 'Public Sans',sans-serif;letter-spacing:.06em;text-transform:uppercase;color:oklch(48% .02 150);cursor:pointer;padding:4px 6px;border-radius:6px;}
.tx-copy:hover{color:var(--forest);background:oklch(96% .01 85);}
.tx-copy.ok{color:oklch(42% .12 150);}
.tx-subs summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:6px;font-size:13px;font-weight:700;color:oklch(32% .03 150);padding:6px 10px;border-radius:10px;background:oklch(97% .01 85);}
.tx-subs summary::-webkit-details-marker{display:none;}
.tx-subs summary .n{display:inline-grid;place-items:center;min-width:24px;height:22px;padding:0 6px;border-radius:99px;background:var(--forest);color:#fff;font-size:12px;font-variant-numeric:tabular-nums;}
.tx-subs summary .hint{margin-left:auto;font-weight:500;opacity:.55;}
.tx-subs[open] summary .hint{font-size:0;}
.tx-subs[open] summary .hint::after{content:"· ocultar";font-size:13px;}
.tx-subtable{margin-top:8px;max-height:320px;overflow:auto;border:1px solid var(--line);border-radius:12px;}
.tx-subtable table{width:100%;border-collapse:collapse;font-size:13px;}
.tx-subtable th[scope=col]{position:sticky;top:0;background:oklch(96.5% .016 78);font-size:10px;letter-spacing:.12em;text-transform:uppercase;text-align:left;padding:8px 10px;color:var(--crimson-dark);}
.tx-subtable td,.tx-subtable th[scope=row]{padding:7px 10px;border-top:1px solid oklch(93% .012 80);text-align:left;vertical-align:top;font-weight:400;}
.tx-subtable th[scope=row] em{font-family:'Newsreader',Georgia,serif;font-size:14.5px;}
.tx-subtable tr[hidden]{display:none;}
.tx-sp mark{background:oklch(90% .12 90);color:inherit;border-radius:3px;padding:0 1px;}
.tx-sp[hidden],.tx-genus[hidden]{display:none;}
.tx-empty{padding:40px 20px;text-align:center;color:oklch(42% .03 150);font-size:16px;}
.tx-link{border:0;background:none;color:var(--crimson);font:700 inherit;text-decoration:underline;cursor:pointer;}

/* vista de tabla */
#tx-tablewrap{border:1px solid var(--line);border-radius:18px;overflow:auto;max-height:80vh;}
.tx-tbl{width:100%;border-collapse:collapse;font-size:14px;}
.tx-tbl th{position:sticky;top:0;z-index:2;background:oklch(96.5% .016 78);text-align:left;font-size:10.5px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:var(--crimson-dark);padding:12px 14px;cursor:pointer;white-space:nowrap;user-select:none;}
.tx-tbl th[aria-sort]::after{content:" ▲";font-size:9px;}
.tx-tbl th[aria-sort=descending]::after{content:" ▼";}
.tx-tbl td{padding:9px 14px;border-top:1px solid oklch(93% .012 80);vertical-align:top;}
.tx-tbl td em{font-family:'Newsreader',Georgia,serif;font-size:16px;}
.tx-tbl tr.sub td:first-child{padding-left:30px;}
.tx-tbl tr:hover td{background:oklch(98.5% .01 85);}
.tx-tbl-opt{display:flex;gap:16px;align-items:center;padding:12px 14px;border-bottom:1px solid var(--line);font-size:13px;position:sticky;left:0;}
.tx-tbl-opt label{display:inline-flex;gap:8px;align-items:center;cursor:pointer;}

/* notas, datos */
.tx-notes{list-style:none;margin:0;padding:0;display:grid;gap:10px;max-width:90ch;}
.tx-notes li{display:grid;grid-template-columns:34px 1fr;gap:12px;align-items:start;padding:12px 16px;border:1px solid var(--line);border-radius:14px;background:#fff;scroll-margin-top:calc(var(--nav-h,64px) + 96px);}
.tx-notes li:target{box-shadow:0 0 0 3px var(--gold);}
.tx-notes .num{display:grid;place-items:center;width:30px;height:30px;border-radius:50%;background:var(--forest);color:#fff;font-weight:800;font-size:13px;}
.tx-notes p{margin:3px 0 0;font-size:14.5px;line-height:1.55;color:oklch(30% .02 155);}
.tx-two{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:18px;}
.tx-box{padding:22px 24px;border:1px solid var(--line);border-radius:20px;background:var(--paper-raised,#faf8f3);}
.tx-box h3{margin:0 0 8px;font-size:12px;font-weight:800;letter-spacing:.16em;text-transform:uppercase;color:var(--crimson-dark);}
.tx-box p{margin:0 0 14px;font-size:14.5px;line-height:1.6;}
.tx-dl{display:flex;flex-wrap:wrap;gap:10px;}
.tx-btn{height:44px;padding:0 18px;text-decoration:none;}
.tx-btn small{font-weight:500;opacity:.6;font-size:11.5px;}
.tx-cite{font-family:'Newsreader',Georgia,serif;font-size:16px !important;padding:14px 16px;border-left:3px solid var(--gold);background:#fff;border-radius:0 12px 12px 0;}
.tx-fine{max-width:90ch;font-size:13.5px;line-height:1.6;color:oklch(42% .02 150);margin-top:18px;}

@media (max-width:1100px){
  .tx-layout{grid-template-columns:1fr;padding-top:28px;}
  .tx-rail{display:none;}
  .tx-genus > summary{grid-template-columns:46px minmax(0,1fr) 22px;}
  .tx-gcount,.tx-gbar{grid-column:2;}
  .tx-gbar{grid-row:3;max-width:200px;}
  .tx-caret{grid-row:1;grid-column:3;}
}
@media (max-width:720px){
  .tx-ribbon li{min-width:0;padding-right:22px;}
  .tx-ranks li{grid-template-columns:96px 1fr;}
  .tx-bars a{grid-template-columns:96px 1fr 30px;}
  .tx-barin{gap:8px;}
  .tx-filters{order:3;}
}
@media (prefers-reduced-motion:reduce){*{transition:none !important;animation:none !important;}}
@media print{
  .rd-util,.rd-header,.rd-navbar,.tx-bar,.tx-rail,.tx-copy,.tx-sp-act,.tx-dl,#tx-cite-btn,.rd-footer{display:none !important;}
  .tx-hero{background:none;color:#000;padding:0;} .tx-hero h1,.tx-counters dd,.tx-deck,.tx-kicker,.tx-counters dt,.tx-rev{color:#000 !important;}
  .tx-genus{break-inside:avoid-page;} details{display:block;} details > *{display:block;} .tx-grid{grid-template-columns:repeat(2,1fr);}
}
[hidden]{display:none !important;}

/* ═══════════ Contraste reforzado ═══════════ */
.rd-tax{--tx-edge:oklch(74% .025 85);--tx-edge-soft:oklch(84% .02 85);--tx-ink:oklch(20% .03 155);--tx-mute:oklch(34% .03 155);--tx-tint:oklch(95.5% .012 85);background:var(--tx-tint);}
.tx-layout{background:transparent;}
.tx-bar{background:oklch(99% .004 85 / .96);border-bottom:2px solid var(--tx-edge);box-shadow:0 14px 24px -22px oklch(18% .05 155 / .6);}
.tx-search input{border:2px solid var(--tx-edge);color:var(--tx-ink);font-weight:600;}
.tx-search input::placeholder{color:oklch(42% .03 155);opacity:1;font-weight:500;}
.tx-fchip,.tx-tog,.tx-seg{border:1.5px solid var(--tx-edge);color:var(--tx-ink);}
.tx-fchip span{opacity:.75;}
.tx-fchip[aria-pressed="true"],.tx-seg button[aria-pressed="true"],.tx-tog[aria-pressed="true"]#tx-ren{color:#fff;}
.tx-lead,.tx-notes p,.tx-box p,.tx-fine{color:var(--tx-ink);}
.tx-fine{color:var(--tx-mute);}
.tx-sec > h2{color:var(--forest-dark,oklch(24% .06 155));}
.au{color:var(--tx-mute);font-weight:600;}
.tx-rail ol a{color:var(--tx-ink);border-left:3px solid var(--tx-edge-soft);font-weight:500;}
.tx-rail ol a b{opacity:.8;}
.tx-rail ol a.on{border-left-color:var(--crimson);background:#fff;box-shadow:0 8px 18px -14px oklch(18% .05 155 / .6);}
.tx-railf a{color:var(--tx-mute);}
.tx-ribbon li{background:oklch(88% .035 85);color:var(--tx-ink);}
.tx-ribbon li:nth-child(even){background:oklch(92% .03 85);}
.tx-ribbon li:last-child{background:var(--forest-dark,oklch(24% .06 155));color:#fff;}
.tx-ribbon .rk{opacity:.8;}
.tx-ranks{border-left:3px solid var(--tx-edge);}
.tx-ranks li{border-bottom:1px solid var(--tx-edge-soft);}
.tx-ranks .rk{color:var(--tx-mute);}
.tx-fig,.tx-box,.tx-notes li{background:#fff;border:1.5px solid var(--tx-edge);box-shadow:0 18px 30px -26px oklch(18% .05 155 / .55);}
.tx-fig figcaption span{color:var(--tx-mute);}
.tx-legend{color:var(--tx-ink);}
.tx-bars .bar{background:oklch(88% .02 85);}
.tx-bars a{color:var(--tx-ink);font-weight:600;}
.tx-bars .bar i{background:linear-gradient(90deg,var(--forest-dark,oklch(24% .06 155)),oklch(42% .12 150));}
/* géneros: cabecera oscura, cuerpo claro */
.tx-genus{border:2px solid var(--forest-dark,oklch(24% .06 155));background:#fff;box-shadow:0 26px 40px -34px oklch(15% .06 155 / .7);overflow:clip;}
.tx-genus > summary{background:linear-gradient(100deg,var(--forest-dark,oklch(24% .06 155)),var(--forest,oklch(32% .08 155)));color:#fff;border-radius:0;}
.tx-gname em{color:#fff;}
.tx-gname small{color:oklch(86% .04 100);font-weight:600;}
.tx-gimg{box-shadow:0 0 0 3px oklch(78% .13 85);}
.tx-gcount{color:oklch(88% .03 100);}
.tx-gcount b{color:var(--gold,oklch(80% .14 85));font-size:1.15em;}
.tx-caret{border-color:var(--gold,oklch(80% .14 85));}
.tx-genus[open] > summary{border-bottom:0;border-radius:0;}
.tx-gbar i{box-shadow:0 0 0 1px oklch(100% 0 0 / .35);}
.tx-grid{background:var(--tx-tint);}
/* especies */
.tx-sp{border:1.5px solid var(--tx-edge);box-shadow:0 14px 24px -22px oklch(18% .05 155 / .55);background:#fff;}
.tx-sp:hover{border-color:var(--forest);box-shadow:0 22px 34px -24px oklch(18% .05 155 / .7);}
.tx-sp h4 .sci{color:var(--tx-ink);font-weight:600;}
.tx-common{color:var(--forest-dark,oklch(24% .06 155));font-weight:700;font-size:15.5px;}
.tx-sp-meta{color:var(--tx-mute);font-weight:600;}
.tx-chip{background:var(--c);color:#fff;border:0;padding:0 11px;text-shadow:0 1px 1px oklch(15% .05 155 / .35);}
.tx-chip i{background:#fff;box-shadow:none;}
.tx-chip[style*="iucn-vu"],.tx-chip[style*="iucn-nt"]{color:oklch(20% .04 100);text-shadow:none;}
.tx-chip[style*="iucn-vu"] i,.tx-chip[style*="iucn-nt"] i{background:oklch(20% .04 100);}
.tx-new{box-shadow:0 0 0 1.5px oklch(45% .1 70);}
.tx-sp-act{border-top:1.5px solid var(--tx-edge-soft);}
.tx-go{display:inline-flex;align-items:center;gap:6px;height:32px;padding:0 14px;border-radius:999px;background:var(--crimson);color:#fff;text-decoration:none;font-weight:800;font-size:12.5px;transition:background .2s,transform .2s;}
.tx-go:hover{background:var(--crimson-dark);text-decoration:none;transform:translateX(2px);}
.tx-copy{color:var(--tx-mute);border:1.5px solid var(--tx-edge-soft);border-radius:999px;padding:5px 11px;}
.tx-subs summary{background:oklch(90% .03 85);color:var(--tx-ink);border:1.5px solid var(--tx-edge-soft);}
.tx-subs[open] summary{background:oklch(86% .04 85);}
.tx-subs summary .hint{opacity:.8;}
.tx-subtable{border:1.5px solid var(--tx-edge);}
.tx-subtable th[scope=col]{background:oklch(88% .035 85);color:oklch(32% .08 25);}
.tx-subtable td,.tx-subtable th[scope=row]{border-top:1px solid var(--tx-edge-soft);color:var(--tx-ink);}
.tx-subtable tbody tr:nth-child(even) > *{background:oklch(97% .008 85);}
.tx-subtable th[scope=row] em{font-weight:600;}
.tx-fn{color:var(--crimson-dark);}
#tx-tablewrap{border:2px solid var(--tx-edge);background:#fff;}
.tx-tbl th{background:oklch(88% .035 85);color:oklch(30% .08 25);}
.tx-tbl td{border-top:1px solid var(--tx-edge-soft);color:var(--tx-ink);}
.tx-tbl tbody tr:nth-child(even) td{background:oklch(97.5% .008 85);}
.tx-tbl tr.sub td{color:var(--tx-mute);}
.tx-tbl .tx-chip{height:24px;}
.tx-sp mark{background:oklch(88% .16 90);color:var(--tx-ink);}

/* ═══════════ Subespecies sin scroll: la tarjeta se ensancha y las lista en columnas ═══════════ */
.tx-sp:has(.tx-subs[open]){grid-column:1 / -1;}
.tx-subtable{display:none;}
.tx-sublist{list-style:none;margin:10px 0 0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,280px),1fr));gap:8px;}
.tx-sublist li{display:flex;flex-direction:column;gap:2px;padding:9px 12px;border:1.5px solid var(--tx-edge-soft);border-radius:12px;background:oklch(98% .008 85);}
.tx-sublist li[hidden]{display:none;}
.tx-sublist em{font-family:'Newsreader',Georgia,serif;font-size:16px;font-weight:600;color:var(--tx-ink);line-height:1.25;}
.tx-sublist .au{font-size:12.5px;}
.tx-sublist .cm{font-size:13.5px;font-weight:700;color:var(--forest-dark,oklch(24% .06 155));}
.tx-subs[open] > summary{margin-bottom:0;}
/* vista de tabla: sin altura máxima, la página es la que se desplaza */
#tx-tablewrap{max-height:none;overflow:visible;}
.tx-tbl th{top:calc(var(--nav-h,64px) + 62px);}
.tx-tbl-opt{position:static;}
@media (max-width:900px){
  #tx-tablewrap{overflow-x:auto;}
  .tx-tbl th{position:static;}
}

/* ═══════════ Subespecies en cuadro de diálogo: la tarjeta de la especie no se mueve ═══════════ */
.tx-sp:has(.tx-subs[open]){grid-column:auto;}
.tx-subs summary{cursor:pointer;}
.tx-subs summary .hint{font-size:0;}
.tx-subs summary .hint::after{content:"· ver todas";font-size:13px;font-weight:600;}
.tx-subs.hit summary{box-shadow:0 0 0 3px oklch(85% .14 88);}
.tx-subs .tx-sublist{display:none;}
.tx-dlg{padding:0;border:2px solid var(--forest-dark,oklch(24% .06 155));border-radius:22px;width:min(1120px,94vw);max-height:90vh;color:var(--tx-ink,#1a2a22);background:oklch(98.6% .006 85);box-shadow:0 50px 100px -30px oklch(10% .05 155 / .75);overflow:hidden;}
.tx-dlg[open]{display:flex;flex-direction:column;}
.tx-dlg::backdrop{background:oklch(14% .04 155 / .62);backdrop-filter:blur(5px);}
.tx-dlg-h{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;padding:20px 26px;background:linear-gradient(100deg,var(--forest-dark,oklch(24% .06 155)),var(--forest,oklch(32% .08 155)));color:#fff;flex:none;}
.tx-dlg-h .k{margin:0 0 4px;font-size:11px;font-weight:800;letter-spacing:.18em;text-transform:uppercase;color:var(--gold,oklch(80% .14 85));}
.tx-dlg-h h3{margin:0;font-weight:400;}
.tx-dlg-h h3 em{font-family:'Newsreader',Georgia,serif;font-size:clamp(24px,3vw,34px);}
.tx-dlg-h .s{margin:6px 0 0;font-size:14px;color:oklch(88% .03 100);}
.tx-dlg-h .x{flex:none;width:42px;height:42px;border-radius:50%;border:2px solid oklch(100% 0 0 / .5);background:transparent;color:#fff;font-size:26px;line-height:1;cursor:pointer;transition:background .2s,border-color .2s;}
.tx-dlg-h .x:hover{background:#fff;color:var(--forest-dark,oklch(24% .06 155));border-color:#fff;}
.tx-dlg .tx-sublist{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr));gap:8px;margin:0;padding:20px 26px;list-style:none;overflow:auto;flex:1 1 auto;}
.tx-dlg .tx-sublist li{padding:8px 12px;border:1.5px solid var(--tx-edge-soft,#ddd);border-radius:12px;background:#fff;gap:1px;}
.tx-dlg .tx-sublist em{font-size:15.5px;}
.tx-dlg .tx-sublist .au{font-size:12px;}
.tx-dlg .tx-sublist .cm{font-size:13px;}
.tx-dlg-f{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:14px 26px;border-top:2px solid var(--tx-edge-soft,#ddd);background:oklch(96% .012 85);flex:none;}
.tx-dlg-f .tip{font-size:12.5px;color:var(--tx-mute,#445);}
@media (prefers-reduced-motion:no-preference){
  .tx-dlg[open]{animation:tx-pop .22s cubic-bezier(.2,.8,.2,1);}
  @keyframes tx-pop{from{opacity:0;transform:translateY(14px) scale(.98);}to{opacity:1;transform:none;}}
}
@media (max-width:600px){.tx-dlg{width:100vw;max-width:100vw;max-height:100dvh;height:100dvh;border-radius:0;border-width:0;} .tx-dlg-f .tip{display:none;}}
@media print{.tx-dlg{display:none !important;}}
/* diálogo más compacto: caben las 30 subespecies sin desplazarse */
.tx-dlg{width:min(1240px,96vw);}
.tx-dlg-h{padding:14px 22px;align-items:center;}
.tx-dlg-h .k{margin-bottom:2px;}
.tx-dlg-h h3 em{font-size:clamp(22px,2.4vw,30px);}
.tx-dlg-h .s{margin-top:3px;font-size:13px;}
.tx-dlg-h .x{width:38px;height:38px;font-size:24px;}
.tx-dlg .tx-sublist{grid-template-columns:repeat(auto-fill,minmax(min(100%,182px),1fr));gap:7px;padding:14px 22px;}
.tx-dlg .tx-sublist li{padding:6px 10px;border-radius:10px;}
.tx-dlg .tx-sublist em{font-size:14.5px;line-height:1.2;}
.tx-dlg .tx-sublist .au{font-size:11.5px;}
.tx-dlg .tx-sublist .cm{font-size:12.5px;line-height:1.25;}
.tx-dlg-f{padding:10px 22px;}
.tx-dlg-f .tx-go{height:30px;}
