@roxyapi/ui 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +3 -1
- package/README.md +6 -0
- package/THEMING.md +30 -23
- package/components-catalog.json +1 -1
- package/dist/cdn/components/almanac-day.js +5 -3
- package/dist/cdn/components/angel-number-card.js +3 -3
- package/dist/cdn/components/angel-number-lookup.js +3 -3
- package/dist/cdn/components/arudha-padas.js +3 -3
- package/dist/cdn/components/ashtakavarga-grid.js +3 -3
- package/dist/cdn/components/aspects-table.js +3 -3
- package/dist/cdn/components/astrocartography-map.js +9 -9
- package/dist/cdn/components/bazi-chart.js +2 -2
- package/dist/cdn/components/bhav-chalit-table.js +3 -3
- package/dist/cdn/components/bhava-bala-table.js +2 -2
- package/dist/cdn/components/biorhythm-chart.js +3 -3
- package/dist/cdn/components/bodygraph.js +11 -11
- package/dist/cdn/components/chara-karakas.js +3 -3
- package/dist/cdn/components/choghadiya-grid.js +3 -3
- package/dist/cdn/components/compatibility-card.js +3 -3
- package/dist/cdn/components/compound-number.js +3 -3
- package/dist/cdn/components/crystal-card.js +2 -2
- package/dist/cdn/components/crystal-grid.js +2 -2
- package/dist/cdn/components/dasha-timeline.js +2 -2
- package/dist/cdn/components/data.js +2 -2
- package/dist/cdn/components/divisional-chart.js +54 -54
- package/dist/cdn/components/dosha-card.js +3 -3
- package/dist/cdn/components/dosha-constitution.js +2 -2
- package/dist/cdn/components/dream-card.js +2 -2
- package/dist/cdn/components/dream-search.js +3 -3
- package/dist/cdn/components/endpoint-form.js +3 -3
- package/dist/cdn/components/ephemeris-table.js +3 -3
- package/dist/cdn/components/fixed-stars.js +3 -3
- package/dist/cdn/components/flying-star-chart.js +3 -3
- package/dist/cdn/components/forecast-digest.js +3 -3
- package/dist/cdn/components/forecast-timeline.js +5 -3
- package/dist/cdn/components/gematria.js +3 -3
- package/dist/cdn/components/gochara-table.js +3 -3
- package/dist/cdn/components/guna-milan.js +2 -2
- package/dist/cdn/components/hd-connection.js +10 -10
- package/dist/cdn/components/hd-penta.js +18 -18
- package/dist/cdn/components/hd-type-card.js +3 -3
- package/dist/cdn/components/hd-variables.js +2 -2
- package/dist/cdn/components/heliacal-table.js +3 -3
- package/dist/cdn/components/hexagram.js +3 -3
- package/dist/cdn/components/hora-table.js +3 -3
- package/dist/cdn/components/horoscope-card.js +3 -3
- package/dist/cdn/components/kp-chart.js +3 -3
- package/dist/cdn/components/kp-finance-card.js +3 -3
- package/dist/cdn/components/kp-planets-table.js +3 -3
- package/dist/cdn/components/kp-ruling-planets.js +3 -3
- package/dist/cdn/components/kua-card.js +3 -3
- package/dist/cdn/components/local-space-compass.js +8 -8
- package/dist/cdn/components/location-search.js +3 -3
- package/dist/cdn/components/luck-pillars.js +2 -2
- package/dist/cdn/components/mayan-day-sign.js +3 -3
- package/dist/cdn/components/moon-phase.js +5 -3
- package/dist/cdn/components/nakshatra-card.js +2 -2
- package/dist/cdn/components/natal-chart.js +17 -17
- package/dist/cdn/components/numerology-card.js +3 -3
- package/dist/cdn/components/panchang-table.js +5 -3
- package/dist/cdn/components/positions-table.js +3 -3
- package/dist/cdn/components/profection-card.js +3 -3
- package/dist/cdn/components/reference-card.js +3 -3
- package/dist/cdn/components/relocation-wheel.js +18 -18
- package/dist/cdn/components/report.js +3 -3
- package/dist/cdn/components/shadbala-table.js +3 -3
- package/dist/cdn/components/synastry-chart.js +17 -17
- package/dist/cdn/components/tarot-card.js +2 -2
- package/dist/cdn/components/tarot-catalog.js +3 -3
- package/dist/cdn/components/tarot-spread.js +3 -3
- package/dist/cdn/components/transit-wheel.js +10 -10
- package/dist/cdn/components/transits-table.js +3 -3
- package/dist/cdn/components/upagraha-table.js +3 -3
- package/dist/cdn/components/vastu-mandala.js +8 -8
- package/dist/cdn/components/vedic-aspects.js +3 -3
- package/dist/cdn/components/vedic-daily.js +3 -3
- package/dist/cdn/components/vedic-kundli.js +55 -55
- package/dist/cdn/components/vedic-planets-table.js +3 -3
- package/dist/cdn/components/western-planets-table.js +3 -3
- package/dist/cdn/components/yoga-list.js +2 -2
- package/dist/cdn/components/zodiac-card.js +3 -3
- package/dist/cdn/locales/de.js +1 -1
- package/dist/cdn/locales/es.js +1 -1
- package/dist/cdn/locales/fr.js +1 -1
- package/dist/cdn/locales/hi.js +1 -1
- package/dist/cdn/locales/pt.js +1 -1
- package/dist/cdn/locales/ru.js +1 -1
- package/dist/cdn/locales/tr.js +1 -1
- package/dist/cdn/roxy-ui.js +115 -115
- package/dist/cdn/widgets.js +1 -1
- package/dist/charts.cjs +69 -69
- package/dist/charts.d.ts +3 -2
- package/dist/charts.js +69 -69
- package/dist/components/almanac-day.js +1 -1
- package/dist/components/angel-number-card.js +1 -1
- package/dist/components/angel-number-lookup.js +1 -1
- package/dist/components/arudha-padas.js +1 -1
- package/dist/components/ashtakavarga-grid.js +1 -1
- package/dist/components/aspects-table.js +1 -1
- package/dist/components/astrocartography-map.d.ts +2 -1
- package/dist/components/astrocartography-map.js +7 -7
- package/dist/components/bazi-chart.js +1 -1
- package/dist/components/bhav-chalit-table.js +1 -1
- package/dist/components/bhava-bala-table.js +1 -1
- package/dist/components/biorhythm-chart.js +1 -1
- package/dist/components/bodygraph.js +8 -8
- package/dist/components/chara-karakas.js +1 -1
- package/dist/components/choghadiya-grid.js +1 -1
- package/dist/components/compatibility-card.js +1 -1
- package/dist/components/compound-number.js +1 -1
- package/dist/components/crystal-card.js +1 -1
- package/dist/components/crystal-grid.js +1 -1
- package/dist/components/dasha-timeline.js +1 -1
- package/dist/components/data.js +1 -1
- package/dist/components/divisional-chart.js +44 -44
- package/dist/components/dosha-card.js +1 -1
- package/dist/components/dosha-constitution.js +1 -1
- package/dist/components/dream-card.js +1 -1
- package/dist/components/dream-search.js +1 -1
- package/dist/components/endpoint-form.js +1 -1
- package/dist/components/ephemeris-table.js +1 -1
- package/dist/components/fixed-stars.js +1 -1
- package/dist/components/flying-star-chart.js +1 -1
- package/dist/components/forecast-digest.js +1 -1
- package/dist/components/forecast-timeline.d.ts +2 -0
- package/dist/components/forecast-timeline.js +1 -1
- package/dist/components/gematria.js +1 -1
- package/dist/components/gochara-table.js +1 -1
- package/dist/components/guna-milan.js +1 -1
- package/dist/components/hd-connection.js +9 -9
- package/dist/components/hd-penta.js +13 -13
- package/dist/components/hd-type-card.js +1 -1
- package/dist/components/hd-variables.js +1 -1
- package/dist/components/heliacal-table.js +1 -1
- package/dist/components/hexagram.js +1 -1
- package/dist/components/hora-table.js +1 -1
- package/dist/components/horoscope-card.js +1 -1
- package/dist/components/kp-chart.js +1 -1
- package/dist/components/kp-finance-card.js +1 -1
- package/dist/components/kp-planets-table.js +1 -1
- package/dist/components/kp-ruling-planets.js +1 -1
- package/dist/components/kua-card.js +1 -1
- package/dist/components/local-space-compass.js +5 -5
- package/dist/components/location-search.js +1 -1
- package/dist/components/luck-pillars.js +1 -1
- package/dist/components/mayan-day-sign.js +1 -1
- package/dist/components/moon-phase.d.ts +1 -1
- package/dist/components/moon-phase.js +1 -1
- package/dist/components/nakshatra-card.js +1 -1
- package/dist/components/natal-chart.js +16 -16
- package/dist/components/numerology-card.js +1 -1
- package/dist/components/panchang-table.js +1 -1
- package/dist/components/positions-table.js +1 -1
- package/dist/components/profection-card.js +1 -1
- package/dist/components/reference-card.js +1 -1
- package/dist/components/relocation-wheel.js +15 -15
- package/dist/components/report.js +1 -1
- package/dist/components/shadbala-table.js +1 -1
- package/dist/components/synastry-chart.js +15 -15
- package/dist/components/tarot-card.js +1 -1
- package/dist/components/tarot-catalog.js +1 -1
- package/dist/components/tarot-spread.js +1 -1
- package/dist/components/transit-wheel.js +7 -7
- package/dist/components/transits-table.js +1 -1
- package/dist/components/upagraha-table.js +1 -1
- package/dist/components/vastu-mandala.js +4 -4
- package/dist/components/vedic-aspects.js +1 -1
- package/dist/components/vedic-daily.js +1 -1
- package/dist/components/vedic-kundli.js +42 -42
- package/dist/components/vedic-planets-table.js +1 -1
- package/dist/components/western-planets-table.js +1 -1
- package/dist/components/yoga-list.js +1 -1
- package/dist/components/zodiac-card.js +1 -1
- package/dist/generated/symbol-font.d.ts +14 -0
- package/dist/i18n/chrome-strings.d.ts +1 -1
- package/dist/i18n/localized-element.d.ts +3 -1
- package/dist/index.cjs +121 -121
- package/dist/index.js +107 -107
- package/dist/locales/de.js +1 -1
- package/dist/locales/es.js +1 -1
- package/dist/locales/fr.js +1 -1
- package/dist/locales/hi.js +1 -1
- package/dist/locales/pt.js +1 -1
- package/dist/locales/ru.js +1 -1
- package/dist/locales/tr.js +1 -1
- package/dist/styles/charts/moon.css +1 -0
- package/dist/styles/charts/natal-wheel.css +1 -1
- package/dist/styles/charts/synastry-wheel.css +1 -1
- package/dist/styles/fonts/symbols/OFL.txt +94 -0
- package/dist/styles/fonts/symbols/noto-sans-math.woff2 +0 -0
- package/dist/styles/fonts/symbols/noto-sans-symbols-2.woff2 +0 -0
- package/dist/styles/fonts/symbols/noto-sans-symbols.woff2 +0 -0
- package/dist/styles/fonts/symbols/noto-sans.woff2 +0 -0
- package/dist/styles/fonts/symbols.css +1 -0
- package/dist/styles/fonts.d.ts +11 -2
- package/dist/styles/tokens-css.d.ts +1 -1
- package/dist/styles/tokens.css +1 -1
- package/dist/tokens/index.d.ts +10 -7
- package/dist/utils/base-element.d.ts +3 -0
- package/dist/utils/base-styles.d.ts +1 -1
- package/dist/utils/brand.d.ts +3 -1
- package/dist/utils/chart-styles.d.ts +2 -0
- package/dist/utils/glyph.d.ts +5 -0
- package/dist/utils/interp-accordion.d.ts +2 -0
- package/dist/utils/moon-mark.d.ts +7 -0
- package/dist/utils/moon.d.ts +37 -0
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
"use strict";var en=Object.defineProperty;var Vo=Object.getOwnPropertyDescriptor;var Uh=Object.getOwnPropertyNames;var qh=Object.prototype.hasOwnProperty;var Yh=(n,a)=>{for(var e in a)en(n,e,{get:a[e],enumerable:true})},Wh=(n,a,e,t)=>{if(a&&typeof a=="object"||typeof a=="function")for(let r of Uh(a))!qh.call(n,r)&&r!==e&&en(n,r,{get:()=>a[r],enumerable:!(t=Vo(a,r))||t.enumerable});return n};var Zh=n=>Wh(en({},"__esModule",{value:true}),n),m=(n,a,e,t)=>{for(var r=t>1?void 0:t?Vo(a,e):a,s=n.length-1,i;s>=0;s--)(i=n[s])&&(r=(t?i(a,e,r):i(r))||r);return t&&r&&en(a,e,r),r};var mf={};Yh(mf,{ROXY_COMPONENTS:()=>wi,ROXY_UI_COMPONENTS:()=>hf,ROXY_UI_VERSION:()=>fs,RoxyAlmanacDay:()=>xa,RoxyAngelNumberCard:()=>Qa,RoxyAngelNumberLookup:()=>er,RoxyArudhaPadas:()=>ar,RoxyAshtakavargaGrid:()=>va,RoxyAspectsTable:()=>rr,RoxyAstrocartographyMap:()=>sr,RoxyBaziChart:()=>nr,RoxyBhavChalitTable:()=>ir,RoxyBhavaBalaTable:()=>or,RoxyBiorhythmChart:()=>ka,RoxyBodygraph:()=>Ra,RoxyCharaKarakas:()=>mr,RoxyChoghadiyaGrid:()=>gr,RoxyCompatibilityCard:()=>Ca,RoxyCompoundNumber:()=>yr,RoxyCrystalCard:()=>ur,RoxyCrystalGrid:()=>Ta,RoxyDashaTimeline:()=>da,RoxyData:()=>fr,RoxyDivisionalChart:()=>Ea,RoxyDoshaCard:()=>Da,RoxyDoshaConstitution:()=>br,RoxyDreamCard:()=>vr,RoxyDreamSearch:()=>Lr,RoxyEndpointForm:()=>De,RoxyEphemerisTable:()=>Pa,RoxyFixedStars:()=>wr,RoxyFlyingStarChart:()=>Ma,RoxyForecastDigest:()=>kr,RoxyForecastTimeline:()=>Sr,RoxyGematria:()=>Rr,RoxyGocharaTable:()=>Cr,RoxyGunaMilan:()=>Tr,RoxyHdConnection:()=>Er,RoxyHdPenta:()=>Ar,RoxyHdTypeCard:()=>Pr,RoxyHdVariables:()=>Mr,RoxyHeliacalTable:()=>_r,RoxyHexagram:()=>Nr,RoxyHoraTable:()=>zr,RoxyHoroscopeCard:()=>ma,RoxyKpChart:()=>_a,RoxyKpFinanceCard:()=>Or,RoxyKpPlanetsTable:()=>Ir,RoxyKpRulingPlanets:()=>Gr,RoxyKuaCard:()=>Na,RoxyLocalSpaceCompass:()=>Fr,RoxyLocationSearch:()=>Ye,RoxyLuckPillars:()=>Br,RoxyMayanDaySign:()=>Ia,RoxyMoonPhase:()=>Ga,RoxyNakshatraCard:()=>Hr,RoxyNatalChart:()=>ya,RoxyNumerologyCard:()=>Fa,RoxyPanchangTable:()=>Ba,RoxyPositionsTable:()=>Ha,RoxyProfectionCard:()=>Vr,RoxyReferenceCard:()=>Ur,RoxyRelocationWheel:()=>qr,RoxyReport:()=>Mt,RoxyShadbalaTable:()=>Yr,RoxySynastryChart:()=>Zr,RoxyTarotCard:()=>ja,RoxyTarotCatalog:()=>Ka,RoxyTarotSpread:()=>Va,RoxyTransitWheel:()=>ta,RoxyTransitsTable:()=>Ua,RoxyUpagrahaTable:()=>Xr,RoxyVastuMandala:()=>qa,RoxyVedicAspects:()=>Jr,RoxyVedicDaily:()=>Qr,RoxyVedicKundli:()=>ra,RoxyVedicPlanetsTable:()=>es,RoxyWesternPlanetsTable:()=>jr,RoxyYogaList:()=>Ya,RoxyZodiacCard:()=>Wa,componentForTool:()=>jo,expandCompact:()=>Ns,roxyDataScript:()=>Fc,serializeRoxyData:()=>_i});module.exports=Zh(mf);var G=require("lit"),Zc=require("lit/decorators.js");var Uo=[{endpoint:"chinese-astrology/calendar/day/{date}",method:"GET",attrs:{mode:"day"}},{endpoint:"chinese-astrology/calendar/monthly",method:"GET",attrs:{mode:"month"}},{endpoint:"chinese-astrology/calendar/auspicious-days",method:"POST",attrs:{mode:"auspicious"}}],qo=[{endpoint:"angel-numbers/numbers/{number}",method:"GET"},{endpoint:"angel-numbers/daily",method:"POST"}],Yo=[{endpoint:"angel-numbers/lookup",method:"GET"}],Wo=[{endpoint:"vedic-astrology/arudha",method:"POST"}],Zo=[{endpoint:"vedic-astrology/ashtakavarga",method:"POST"}],Xo=[{endpoint:"astrology/aspects",method:"POST"},{endpoint:"astrology/transit-aspects",method:"POST"},{endpoint:"astrology/aspect-patterns",method:"POST"}],Jo=[{endpoint:"astrology/astrocartography",method:"POST"}],Qo=[{endpoint:"chinese-astrology/bazi/chart",method:"POST"}],el=[{endpoint:"vedic-astrology/bhav-chalit",method:"POST"}],tl=[{endpoint:"vedic-astrology/bhava-bala",method:"POST"}],al=[{endpoint:"biorhythm/daily",method:"POST",attrs:{mode:"daily"}},{endpoint:"biorhythm/forecast",method:"POST",attrs:{mode:"forecast"}},{endpoint:"biorhythm/critical-days",method:"POST",attrs:{mode:"critical-days"}}],rl=[{endpoint:"human-design/bodygraph",method:"POST"}],sl=[{endpoint:"vedic-astrology/chara-karakas",method:"POST"}],nl=[{endpoint:"vedic-astrology/panchang/choghadiya",method:"POST"}],il=[{endpoint:"astrology/compatibility-score",method:"POST",attrs:{mode:"astrology"}},{endpoint:"numerology/compatibility",method:"POST",attrs:{mode:"numerology"}},{endpoint:"biorhythm/compatibility",method:"POST",attrs:{mode:"biorhythm"}}],ol=[{endpoint:"numerology/compound-number/{number}",method:"GET"}],ll=[{endpoint:"crystals/{id}",method:"GET"}],cl=[{endpoint:"crystals",method:"GET"},{endpoint:"crystals/chakra/{chakra}",method:"GET"},{endpoint:"crystals/element/{element}",method:"GET"},{endpoint:"crystals/zodiac/{sign}",method:"GET"},{endpoint:"crystals/birthstone/{month}",method:"GET"},{endpoint:"crystals/search",method:"GET"}],dl=[{endpoint:"vedic-astrology/dasha/major",method:"POST",attrs:{period:"major"}},{endpoint:"vedic-astrology/dasha/current",method:"POST",attrs:{period:"current"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}",method:"POST",attrs:{period:"sub"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}",method:"POST",attrs:{period:"antara"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}/{pratyantardasha}",method:"POST",attrs:{period:"sookshma"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}/{pratyantardasha}/{sookshma}",method:"POST",attrs:{period:"prana"}}],pl=[{endpoint:"vedic-astrology/divisional-chart",method:"POST"},{endpoint:"vedic-astrology/navamsa",method:"POST"}],hl=[{endpoint:"vedic-astrology/dosha/manglik",method:"POST",attrs:{type:"manglik"}},{endpoint:"vedic-astrology/dosha/kalsarpa",method:"POST",attrs:{type:"kalsarpa"}},{endpoint:"vedic-astrology/dosha/sadhesati",method:"POST",attrs:{type:"sadhesati"}}],ml=[{endpoint:"ayurveda/constitution",method:"POST"}],gl=[{endpoint:"dreams/symbols/{id}",method:"GET"}],yl=[{endpoint:"dreams/symbols",method:"GET"}],ul=[{endpoint:"astrology/planets/monthly",method:"POST"},{endpoint:"vedic-astrology/planetary-positions/monthly",method:"POST"}],fl=[{endpoint:"astrology/fixed-stars",method:"POST"}],xl=[{endpoint:"feng-shui/flying-stars/natal",method:"POST",attrs:{mode:"natal"}},{endpoint:"feng-shui/flying-stars/annual/{year}",method:"GET",attrs:{mode:"annual"}}],bl=[{endpoint:"forecast/digest",method:"POST"}],vl=[{endpoint:"forecast/timeline",method:"POST"},{endpoint:"forecast/significant-dates",method:"POST"},{endpoint:"forecast/transits",method:"POST"}],Ll=[{endpoint:"kabbalah/gematria",method:"POST"}],$l=[{endpoint:"vedic-astrology/transit",method:"POST"}],wl=[{endpoint:"vedic-astrology/compatibility",method:"POST"}],kl=[{endpoint:"human-design/connection",method:"POST"}],Sl=[{endpoint:"human-design/penta",method:"POST"}],Rl=[{endpoint:"human-design/type",method:"POST"},{endpoint:"human-design/profile",method:"POST"}],Cl=[{endpoint:"human-design/variables",method:"POST"}],Tl=[{endpoint:"vedic-astrology/heliacal",method:"POST"}],El=[{endpoint:"iching/hexagrams/random",method:"GET"},{endpoint:"iching/hexagrams/{number}",method:"GET"},{endpoint:"iching/hexagrams/lookup",method:"GET"},{endpoint:"iching/cast",method:"GET"},{endpoint:"iching/daily",method:"POST"},{endpoint:"iching/daily/cast",method:"POST"}],Dl=[{endpoint:"vedic-astrology/panchang/hora",method:"POST"}],Al=[{endpoint:"astrology/horoscope/{sign}/daily",method:"GET",attrs:{period:"daily"}},{endpoint:"astrology/horoscope/{sign}/weekly",method:"GET",attrs:{period:"weekly"}},{endpoint:"astrology/horoscope/{sign}/monthly",method:"GET",attrs:{period:"monthly"}},{endpoint:"astrology/horoscope/{sign}/yearly",method:"GET",attrs:{period:"yearly"}}],Pl=[{endpoint:"vedic-astrology/kp/chart",method:"POST"}],Ml=[{endpoint:"vedic-astrology/kp/daily-finance",method:"POST"}],_l=[{endpoint:"vedic-astrology/kp/planets",method:"POST"}],Nl=[{endpoint:"vedic-astrology/kp/ruling-planets",method:"POST"}],zl=[{endpoint:"feng-shui/kua",method:"POST",attrs:{mode:"kua"}},{endpoint:"feng-shui/eight-mansions",method:"POST",attrs:{mode:"mansions"}}],Ol=[{endpoint:"astrology/local-space",method:"POST"}],Il=[{endpoint:"chinese-astrology/bazi/luck-pillars",method:"POST"}],Gl=[{endpoint:"mesoamerican-astrology/mayan/tzolkin",method:"POST",attrs:{mode:"day"}},{endpoint:"mesoamerican-astrology/mayan/chart",method:"POST",attrs:{mode:"chart"}}],Fl=[{endpoint:"astrology/moon-phase/current",method:"GET",attrs:{mode:"current"}},{endpoint:"astrology/moon-phase/upcoming",method:"GET",attrs:{mode:"upcoming"}},{endpoint:"astrology/moon-phase/calendar/{year}/{month}",method:"GET",attrs:{mode:"calendar"}}],Bl=[{endpoint:"vedic-astrology/nakshatras/{id}",method:"GET"}],Hl=[{endpoint:"astrology/natal-chart",method:"POST"}],jl=[{endpoint:"numerology/life-path",method:"POST",attrs:{type:"life-path"}},{endpoint:"numerology/expression",method:"POST",attrs:{type:"expression"}},{endpoint:"numerology/soul-urge",method:"POST",attrs:{type:"soul-urge"}},{endpoint:"numerology/personality",method:"POST",attrs:{type:"personality"}},{endpoint:"numerology/birth-day",method:"POST",attrs:{type:"birth-day"}},{endpoint:"numerology/maturity",method:"POST",attrs:{type:"maturity"}},{endpoint:"numerology/daily",method:"POST",attrs:{type:"daily"}},{endpoint:"numerology/personal-day",method:"POST",attrs:{type:"personal-day"}},{endpoint:"numerology/personal-month",method:"POST",attrs:{type:"personal-month"}},{endpoint:"numerology/personal-year",method:"POST",attrs:{type:"personal-year"}},{endpoint:"numerology/chart",method:"POST",attrs:{type:"chart"}}],Kl=[{endpoint:"vedic-astrology/panchang/detailed",method:"POST",attrs:{detail:"detailed"}},{endpoint:"vedic-astrology/panchang/basic",method:"POST",attrs:{detail:"basic"}}],Vl=[{endpoint:"astrology/asteroids",method:"POST"},{endpoint:"astrology/lilith",method:"POST"},{endpoint:"astrology/progressions",method:"POST"},{endpoint:"astrology/solar-arc",method:"POST"},{endpoint:"astrology/arabic-lots",method:"POST"}],Ul=[{endpoint:"astrology/profections",method:"POST"}],ql=[{endpoint:"astrology/signs/{id}",method:"GET"},{endpoint:"astrology/planet-meanings/{id}",method:"GET"},{endpoint:"vedic-astrology/rashis/{id}",method:"GET"},{endpoint:"iching/trigrams/{id}",method:"GET"},{endpoint:"human-design/gates/{number}",method:"GET"},{endpoint:"human-design/centers/{id}",method:"GET"},{endpoint:"numerology/meanings/{number}",method:"GET"},{endpoint:"vedic-astrology/avasthas/{id}",method:"GET"}],Yl=[{endpoint:"astrology/relocation-chart",method:"POST"}],Wl=[{endpoint:"reports/natal",method:"POST",attrs:{report:"natal"}},{endpoint:"reports/synastry",method:"POST",attrs:{report:"synastry"}},{endpoint:"reports/kundli",method:"POST",attrs:{report:"kundli"}},{endpoint:"reports/matchmaking",method:"POST",attrs:{report:"matchmaking"}},{endpoint:"reports/yearly-forecast",method:"POST",attrs:{report:"yearly-forecast"}},{endpoint:"reports/human-design",method:"POST",attrs:{report:"human-design"}},{endpoint:"reports/bazi",method:"POST",attrs:{report:"bazi"}},{endpoint:"reports/numerology",method:"POST",attrs:{report:"numerology"}},{endpoint:"reports/tarot",method:"POST",attrs:{report:"tarot"}}],Zl=[{endpoint:"vedic-astrology/shadbala",method:"POST"}],Xl=[{endpoint:"astrology/synastry",method:"POST"}],Jl=[{endpoint:"tarot/daily",method:"POST"},{endpoint:"tarot/cards/{id}",method:"GET"}],Ql=[{endpoint:"tarot/cards",method:"GET"}],ec=[{endpoint:"tarot/spreads/three-card",method:"POST",attrs:{spread:"three-card"}},{endpoint:"tarot/spreads/celtic-cross",method:"POST",attrs:{spread:"celtic-cross"}},{endpoint:"tarot/spreads/love",method:"POST",attrs:{spread:"love"}},{endpoint:"tarot/spreads/career",method:"POST",attrs:{spread:"career"}},{endpoint:"tarot/spreads/custom",method:"POST",attrs:{spread:"custom"}},{endpoint:"tarot/yes-no",method:"POST",attrs:{spread:"yes-no"}},{endpoint:"tarot/draw",method:"POST",attrs:{spread:"draw"}}],tc=[{endpoint:"astrology/transit-aspects",method:"POST"}],ac=[{endpoint:"astrology/transits",method:"POST"}],rc=[{endpoint:"vedic-astrology/upagraha",method:"POST"}],sc=[{endpoint:"vastu/mandala",method:"POST",attrs:{mode:"mandala"}},{endpoint:"vastu/entrance",method:"POST",attrs:{mode:"entrance"}}],nc=[{endpoint:"vedic-astrology/aspects",method:"POST"}],ic=[{endpoint:"vedic-astrology/daily",method:"POST"}],oc=[{endpoint:"vedic-astrology/birth-chart",method:"POST"}],lc=[{endpoint:"vedic-astrology/birth-chart",method:"POST"}],cc=[{endpoint:"astrology/natal-chart",method:"POST"}],dc=[{endpoint:"vedic-astrology/yoga",method:"GET"},{endpoint:"vedic-astrology/yoga/detect",method:"POST"},{endpoint:"vedic-astrology/yoga/{id}",method:"GET"}],pc=[{endpoint:"chinese-astrology/zodiac/sign",method:"POST",attrs:{mode:"sign"}},{endpoint:"chinese-astrology/zodiac/animals/{id}",method:"GET",attrs:{mode:"animal"}},{endpoint:"chinese-astrology/zodiac/{id}/daily",method:"GET",attrs:{mode:"daily"}},{endpoint:"chinese-astrology/zodiac/compatibility/{sign1}/{sign2}",method:"GET",attrs:{mode:"compatibility"}}];var Me=require("lit"),we=require("lit/decorators.js"),rs=require("lit/directives/if-defined.js");var hc=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function Si(n){if(n.lang)return n.lang;if(typeof document>"u")return;let a=n.closest?.("[lang]")?.getAttribute("lang");return a||document.documentElement.lang||void 0}function mc(n){return!n||n.toLowerCase().split("-")[0]==="en"}var Xh={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function ki(n,a){let e=n.toLowerCase();return a.find(t=>t.toLowerCase()===e)}function tn(n,a=hc){let e=Si(n);if(!e)return;let t=ki(e,a);if(t)return t;let r=e.toLowerCase().split("-"),s=r[0];if(s==="zh"){let i=r.find(o=>o==="hans"||o==="hant")??Xh[r[1]??""];return i?ki(`zh-${i}`,a):void 0}return ki(s,a)}var bs=require("lit");var Jh={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},Ri='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',gc='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',yc='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',an={"fraunces-jost":{name:"Fraunces with Jost",sans:Ri,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:Ri,display:Ri},geist:{name:"Geist",sans:gc,display:gc},system:{name:"System",sans:yc,display:yc}};function uc(n){let{sans:a,display:e}=an[n];return Object.keys(Jh).filter(t=>`${a} ${e}`.includes(`"${t}"`))}var fc=["practitioner","eucalyptus","kiln","moonlit","celeste"];var fs="1.3.0";var Qh=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,em=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function rn(n,a){if(!a)return;let e=new URL(a);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let t=(Qh.exec(e.pathname)??em.exec(e.pathname))?.[1];if(t!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${n}/dist`:`${e.origin}${t}`}var nm={},tm="color-mix(in oklab, var(--roxy-accent) 70%, black)",am="var(--roxy-accent)",rm="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",Ci=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function Ti(n){if(!n||!Ci.test(n))return;let a=n.slice(1).toLowerCase();return`#${a.length===3?a.replace(/./g,"$&$&"):a}`}function sn(n){return n!==void 0&&Object.hasOwn(an,n)}function xc(n){return fc.includes(n)}function bc(n){let a=[];return n.brandColor&&Ci.test(n.brandColor)&&a.push(`--roxy-primary:${n.brandColor}`),n.brandAccent&&Ci.test(n.brandAccent)&&a.push(`--roxy-accent:${n.brandAccent}`,`--roxy-accent-ink:light-dark(${tm},${am})`,`--roxy-ring:${rm}`),a.join(";")}function vc(n,a){if(sn(a))return a;let e=n.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let r=n.shadowRoot?.firstElementChild,s=r?.localName==="style"?r:null;s?.sheet&&(s.sheet.disabled=true);let i,o,l;try{let c=globalThis.getComputedStyle(n),d=p=>c.getPropertyValue(p).trim();i=d("--roxy-font-sans"),o=d("--roxy-font-display"),l=d("--roxy-font")}finally{s?.sheet&&(s.sheet.disabled=false)}if(!(i||o))return sn(l)?l:void 0}function Lc(n){let{sans:a,display:e}=an[n];return`--roxy-font:${n};--roxy-font-sans:${a};--roxy-font-display:${e}`}var sm=rn(fs,globalThis.document?.currentScript?.src||nm.url);function $c(n,a=sm){if(typeof document>"u"||a===void 0)return;let e=`roxy-ui-font-${n}`;if(uc(n).length===0||document.getElementById(e))return;let t=document.createElement("link");t.id=e,t.rel="stylesheet",t.href=`${a}/styles/fonts/${n}.css`,document.head.append(t)}var wc='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black)}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white)}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var kc="roxy-ui-tokens";function Sc(){if(typeof document>"u")return null;let n=document.getElementById(kc);if(n)return n;let a=document.createElement("style");return a.id=kc,a.textContent=wc,document.head.prepend(a),a}function Rt(n){return n.toLowerCase().replace(/[\s_-]+/g," ").trim()}function V(n){return n?n.charAt(0).toUpperCase()+n.slice(1).toLowerCase():""}function D(n){return n.replace(/[_-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([a-z])([0-9])/g,"$1 $2").replace(/^\w/,a=>a.toUpperCase())}function nn(n){return typeof n=="string"&&/^https?:\/\//.test(n)}var Rc="__ROXY_UI_I18N__";function Ei(){let n=globalThis,a=n[Rc];if(a)return a;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return n[Rc]=e,e}function Di(n,a){return a?n.replace(/\{\{(\w+)\}\}/g,(e,t)=>t in a?String(a[t]??""):e):n}function on(n,a,e){return Di(Ai(n,a)??a,e)}function Ai(n,a){if(!n)return;let{catalogs:e}=Ei(),t=n.toLowerCase();return(e[t]??e[t.split("-")[0]])?.[Rt(a)]}function Cc(n){if(!n)return;let{fieldLabels:a}=Ei(),e=n.toLowerCase();return a[e]??a[e.split("-")[0]]}function xs(n,a){return Cc(n)?.fields[a]}function Tc(n,a,e){return Cc(n)?.enums[`${a}.${e}`]}function Ec(n){let{listeners:a}=Ei();return a.add(n),()=>{a.delete(n)}}var ln=class{constructor(a){this.host=a,a.addController(this)}hostConnected(){this.unsubscribe=Ec(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var Za=class extends bs.LitElement{constructor(){super();this.translator=(e,t)=>this.t(e,t);new ln(this)}connectedCallback(){super.connectedCallback(),Sc()}fontDeclarations(e){let t=vc(this,e);return t?($c(t),Lc(t)):""}renderFontStyle(){let e=this.fontDeclarations();return e?bs.html`<style>:host{${e}}</style>`:bs.nothing}t(e,t){return on(this.effectiveLang(),e,t)}effectiveLang(){return Si(this)}};var Pc=require("lit");var Dc=require("lit"),Ac=Dc.css`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var im=Pc.css`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}:host([bare]){--roxy-surface:transparent;--roxy-shadow-sm:none;--roxy-shadow-md:none}*,:before,:after{box-sizing:border-box}h1,h2,h3,h4{font-family:var(--roxy-font-display)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);background-size:200% 100%;animation:1.4s ease-in-out infinite roxy-shimmer}@keyframes roxy-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@media (prefers-reduced-motion:reduce){.roxy-skeleton{animation:none}}.roxy-sr-only{clip-path:inset(50%);white-space:nowrap;border:0;width:1px;height:1px;margin:0;padding:0;position:absolute;overflow:hidden}.roxy-empty{padding:var(--roxy-space-lg);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,u=[im,Ac];var om="__cols",lm="__rows";function cm(n){return typeof n=="object"&&n!==null&&!Array.isArray(n)}function cn(n){if(Array.isArray(n)){let s=false,i=n.map(o=>{let l=cn(o);return l!==o&&(s=true),l});return s?i:n}if(!cm(n))return n;let a=n[om],e=n[lm];if(Array.isArray(a)&&Array.isArray(e)&&Object.keys(n).length===2)return e.map(s=>{let i={};return a.forEach((o,l)=>{i[o]=cn(s[l])}),i});let t=false,r={};for(let[s,i]of Object.entries(n)){let o=cn(i);o!==i&&(t=true),r[s]=o}return t?r:n}function Ns(n){return cn(n)}function Mc(n,a){return n.find(e=>e.attrs&&Object.entries(e.attrs).every(([t,r])=>a[t]===r))??n[0]}var dm="pk_live_YOUR_KEY",_c={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function ts(n){if(n)return n===dm?_c.sample:n.startsWith("pk_")?void 0:_c.secret}function vs(n,a,e={}){e.warn&&console.warn(a.message),n.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:a.reason,message:a.message},bubbles:true,composed:true}))}var $s="https://roxyapi.com/api/v2";async function Nc(n){return(await zc(n)).message}async function zc(n){try{let a=await n.json();if(a?.error){let e=a.code==="validation_error"&&Array.isArray(a.issues)?a.issues.filter(t=>typeof t.path=="string"&&typeof t.message=="string").map(t=>({path:t.path,message:t.message})):null;return{message:a.error,issues:e?.length?e:null,worded:true,...a.code?{code:a.code}:{}}}}catch{}return{message:`Request failed (${n.status})`,issues:null,worded:false}}var pn={fromAttribute:n=>{if(n!=null){try{let a=JSON.parse(n);if(a&&typeof a=="object"&&!Array.isArray(a))return a}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},Ls=class extends Error{constructor(e,t=null,r=true,s,i){super(e);this.issues=t;this.worded=r;this.status=s;this.code=i}};function Pi(n){return n.submitUrl?void 0:ts(n.publishableKey)}function Mi(n){return!!(n.submitUrl||n.publishableKey&&!Pi(n))}async function Xa(n,a,e){let t=Pi(n);if(t)throw new Ls(t.message);let r=n.submitUrl?await fetch(n.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:pm(a,n.submitContext),signal:e}):await hm(n,a,e);if(!r.ok){let s=await zc(r);throw new Ls(s.message,s.issues,s.worded,r.status,s.code)}return await r.json()}function pm(n,a){return JSON.stringify(a?{...n,context:a}:n)}function hm(n,a,e){let t=new URL(`${n.baseUrl??$s}${a.path}`,document.baseURI);for(let[s,i]of Object.entries(a.query??{}))i!=null&&t.searchParams.set(s,String(i));let r={Accept:"application/json"};return n.publishableKey&&(r["X-API-Key"]=n.publishableKey),a.body!=null&&(r["Content-Type"]="application/json"),fetch(t,{method:a.method??"GET",headers:r,body:a.body!=null?JSON.stringify(a.body):void 0,signal:e})}var dn=class{constructor(a){this.baseUrl=$s;this.worded=true;this.failure={};this.host=a,a.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(a){this.worded=true,this.failure={};let e=Pi(this);if(e){this.host.error=e.message,vs(this.host,e);return}this.abort?.abort();let t=new AbortController;this.abort=t,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let r=await Xa(this,a,t.signal);if(t.signal.aborted)return;this.host.data=r}catch(r){if(t.signal.aborted||r?.name==="AbortError")return;r instanceof Ls&&(this.host.issues=r.issues,this.failure={status:r.status,code:r.code}),this.worded=r instanceof Ls&&r.worded,this.host.error=r instanceof Error?r.message:String(r)}finally{this.abort===t&&(this.abort=void 0),t.signal.aborted||(this.host.loading=false)}}};function Oc(n,a,e,t=[]){let r={...e},s=`/${n.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(c,d)=>{let p=r[d];return delete r[d],encodeURIComponent(String(p??""))}),i=new Set(t),o={},l={};for(let[c,d]of Object.entries(r))d===void 0||d===""||(a==="GET"||i.has(c)?o[c]=d:l[c]=d);return{path:s,method:a,query:o,body:a==="POST"?l:void 0}}var st=require("lit");var hn=require("lit");function he(){return hn.html`<svg class="roxy-chevron" viewBox="0 0 16 16" width="14" height="14" aria-hidden="true"><path d="M4 6l4 4 4-4" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>`}var W=hn.css`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var me=st.css`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@container (width<=26rem){.interp-card summary{flex-wrap:wrap}.roxy-chevron{order:2}.interp-aside{flex-basis:100%;order:3;justify-content:flex-end}}.interp-body{margin-top:var(--roxy-space-sm);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function as(n){return n?.length?st.html`<div class="interp-keywords roxy-chips">${n.map(a=>st.html`<span class="roxy-chip">${a}</span>`)}</div>`:st.nothing}function zs(n,a){if(!n)return st.nothing;let e=(t,r)=>r?st.html`<p><strong>${a(t)}</strong> ${r}</p>`:st.nothing;return st.html`${n.summary?st.html`<p>${n.summary}</p>`:st.nothing} ${e("Impact:",n.impact)}${e("Timing:",n.timing)}${e("Guidance:",n.guidance)} ${as(n.keywords)}`}function Ic(n,a,e){let t=n.filter(r=>!!r.body);return t.length===0?st.nothing:st.html`<section class="block" part="section readings"><h3>${e}</h3>${t.map((r,s)=>st.html`<details class="interp-card" part="reading" name="${a}" ?open="${s===0}"><summary><span class="interp-lead">${r.label}</span> ${he()} ${r.aside?st.html`<span class="interp-aside"><small>${r.aside}</small></span>`:st.nothing}</summary><div class="interp-body"><p>${r.body}</p>${r.extra??st.nothing}</div></details>`)}</section>`}var Gc="roxy-data";function _i(n){return JSON.stringify(n).replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}function Fc(n){return`<script type="application/json" class="${Gc}">${_i(n)}<\/script>`}function mm(n){return n.nodeName==="SCRIPT"&&n.getAttribute("type")==="application/json"}var mn=class{constructor(a){this.host=a,a.addController(this)}hostConnected(){if(this.host.data!=null)return;let a=this.read();a!==void 0&&(this.host.data=a,this.host.requestUpdate())}read(){let a=this.findInlineScript();return a?this.parse(a.textContent):void 0}findInlineScript(){for(let a of Array.from(this.host.children))if(mm(a)&&a.classList.contains(Gc))return a;return null}parse(a){if(a?.trim())try{return JSON.parse(a)}catch{return}}};var g=class extends Za{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,t=this.listKey,r=this.listRows();if(!(!e||!t||!r)){this.moreLoading=true,this.moreError=null;try{let s=await Xa(this.fetcher,{...e,query:{...e.query,offset:r.length}});if(this.lastRequest!==e)return;let i=s[t];this.data={...this.data,...s,[t]:[...r,...Array.isArray(i)?i:[]]}}catch(s){this.lastRequest===e&&(this.moreError=s instanceof Error?s.message:String(s))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let t=this.selfFetch();if(!t)return;let r=e.detail;this.lastValues=r.values,this.sticky=!!r.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(r.values),this.fetchFresh(Oc(t.endpoint,t.method,{...r.values,...this.ownRequest()},r.queryKeys??[]))};new mn(this),this.fetcher=new dn(this)}static{this.styles=[u]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let t=Ns(this.data);t!==this.data&&(this.data=t)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:Mc(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return Me.html`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(t){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,t),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:t},bubbles:true,composed:true})),customElements.get("roxy-data")?Me.html`<roxy-data .data="${e}" lang="${(0,rs.ifDefined)(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(s=>s.trim().toLowerCase()).filter(s=>/^[a-z][a-z0-9-]*$/.test(s)),t=[bc(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!t)return Me.nothing;let r=(t?`:host{${t}}`:"")+e.map(s=>`[part~="${s}"],roxy-endpoint-form::part(${s}){display:none!important}`).join("");return Me.html`<style>${r}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):this.loading?this.renderLoading():this.error!=null?this.renderError(this.error):this.data!=null?this.selfFetched?this.editing?this.renderForm():this.renderResult(this.data):this.showAttribution()?Me.html`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,t,r){return this.hideReadings?Me.nothing:Ic(e,t,this.t(r??"Reading"))}renderResult(e){let t=Me.html`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?Me.html`${t}${this.renderAttribution()}`:t}renderWithForm(e){return Me.html`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?Me.nothing:this.renderErrorBanner(this.error):this.data==null?Me.nothing:this.showAttribution()?Me.html`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),t=this.data?.total;return!this.lastRequest||!e||typeof t!="number"?Me.nothing:e.length>=t?Me.nothing:Me.html`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?Me.html`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:Me.nothing}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let t=this.openedRow??document.createElement(this.rowDetail.tag);t.publishableKey=this.publishableKey,t.baseUrl=this.baseUrl,t.submitUrl=this.submitUrl,t.submitContext=this.submitContext,t.hideReadings=this.hideReadings,t.hideSections=this.hideSections;let r=this.effectiveLang();r&&t.setAttribute("lang",r),this.openedRow=t,this.openedRowId=e,t.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:tn(this)}}).then(()=>t.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return Me.html`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(Me.nothing):this.renderEmpty()}renderForm(){let e=this.selfFetch();return Me.html`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${(0,rs.ifDefined)(this.specUrl)}" publishable-key="${(0,rs.ifDefined)(this.publishableKey)}" location-url="${(0,rs.ifDefined)(this.locationUrl)}" submit-label="${(0,rs.ifDefined)(this.submitLabel)}" lang="${(0,rs.ifDefined)(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return Me.html`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return Me.html`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let t=!!this.selfFetch();if(t&&this.issues)return this.renderForm();let r=this.renderErrorBanner(e);return t?Me.html`${r}${this.renderForm()}`:r}renderErrorBanner(e){return Me.html`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};m([(0,we.property)({attribute:false})],g.prototype,"data",2),m([(0,we.property)({type:String,attribute:"data-endpoint"})],g.prototype,"endpoint",2),m([(0,we.property)({type:String})],g.prototype,"method",2),m([(0,we.property)({type:String,attribute:"publishable-key"})],g.prototype,"publishableKey",2),m([(0,we.property)({type:String,attribute:"base-url"})],g.prototype,"baseUrl",2),m([(0,we.property)({type:String,attribute:"spec-url"})],g.prototype,"specUrl",2),m([(0,we.property)({type:String,attribute:"submit-url"})],g.prototype,"submitUrl",2),m([(0,we.property)({attribute:"submit-context",converter:pn})],g.prototype,"submitContext",2),m([(0,we.property)({type:String,attribute:"location-url"})],g.prototype,"locationUrl",2),m([(0,we.property)({type:Boolean})],g.prototype,"remember",2),m([(0,we.property)({type:Boolean,attribute:"hide-readings",reflect:true})],g.prototype,"hideReadings",2),m([(0,we.property)({type:String,attribute:"hide-sections",reflect:true})],g.prototype,"hideSections",2),m([(0,we.property)({type:String,attribute:"brand-color"})],g.prototype,"brandColor",2),m([(0,we.property)({type:String,attribute:"brand-accent"})],g.prototype,"brandAccent",2),m([(0,we.property)({type:String})],g.prototype,"font",2),m([(0,we.property)({type:String,attribute:"submit-label"})],g.prototype,"submitLabel",2),m([(0,we.property)({type:String,attribute:"error-message"})],g.prototype,"errorMessage",2),m([(0,we.property)({type:String})],g.prototype,"attribution",2),m([(0,we.state)()],g.prototype,"loading",2),m([(0,we.state)()],g.prototype,"error",2),m([(0,we.state)()],g.prototype,"issues",2),m([(0,we.state)()],g.prototype,"selfFetched",2),m([(0,we.state)()],g.prototype,"editing",2),m([(0,we.state)()],g.prototype,"sticky",2),m([(0,we.state)()],g.prototype,"openedRow",2),m([(0,we.state)()],g.prototype,"openedRowId",2),m([(0,we.state)()],g.prototype,"moreLoading",2),m([(0,we.state)()],g.prototype,"moreError",2);var f=n=>a=>{customElements.get(n)||customElements.define(n,a)};var gn=/^\d{4}-\d{2}-\d{2}$/,gm=/^\d{4}-\d{2}$/,jc=/^\d{2}:\d{2}(:\d{2})?$/,ym=/^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/,Bc=new Map;function vt(n){if(!n)return["en"];let a=Bc.get(n);if(a)return[a,"en"];let e="en";try{e=Intl.getCanonicalLocales(n)[0]??"en"}catch{e="en"}return Bc.set(n,e),[e,"en"]}var Hc=new Map;function yn(n){let a=n??"",e=Hc.get(a);if(e)return e;let r={hour:new Intl.DateTimeFormat(vt(n),{timeStyle:"short",timeZone:"UTC"}).formatToParts(new Date(Date.UTC(2e3,0,1,1))).find(s=>s.type==="hour")?.value?.length===2?"2-digit":"numeric",minute:"2-digit"};return Hc.set(a,r),r}function Os(n,a){return n&&a?`${n} - ${a}`:n||a}function ns(n){let a=jc.test(n)?`1970-01-01T${n}`:gn.test(n)?`${n}T00:00:00`:gm.test(n)?`${n}-01T00:00:00`:ym.test(n)?n.replace(" ","T"):null;return a?{d:new Date(`${a}Z`),timeZone:"UTC"}:{d:new Date(n)}}function Nt(n,a){if(typeof a!="string"||a.length===0||gn.test(a))return"";let{d:e,timeZone:t}=ns(a);return Number.isNaN(e.getTime())?a:e.toLocaleTimeString(vt(n),{...yn(n),timeZone:t})}function M(n,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ns(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(vt(n),{month:"short",day:"numeric",year:"numeric",timeZone:t})}function na(n,a){return a?Os(Nt(n,a.start),Nt(n,a.end)):""}function Ct(n,a,e){return Os(M(n,a),M(n,e))}function Ja(n,a,e){if(typeof a!="string"||a.length===0)return"";if(e==="year")return a.match(/^(\d{4})/)?.[1]??a;let{d:t,timeZone:r}=ns(a);return Number.isNaN(t.getTime())?a:t.toLocaleString(vt(n),{day:e==="month"?void 0:"numeric",month:"short",year:"numeric",...e==="time"?yn(n):{},timeZone:r})}function Kc(n,a,e,t){return Os(Ja(n,a,t),Ja(n,e,t))}function ss(n,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ns(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(vt(n),{month:"short",day:"numeric",timeZone:t})}function Vc(n,a,e){let t=ss(n,a),r=ss(n,e);return t===r?t:Os(t,r)}function Uc(n,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ns(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(vt(n),{weekday:"short",day:"numeric",timeZone:t})}function ws(n,a,e){return typeof a!="number"||!Number.isFinite(a)||typeof e!="number"||!Number.isInteger(e)||e<1||e>12?"":new Date(Date.UTC(a,e-1,1,12)).toLocaleDateString(vt(n),{month:"long",year:"numeric",timeZone:"UTC"})}function un(n,a){return typeof a!="number"||!Number.isInteger(a)||a<1||a>12?"":new Date(Date.UTC(2e3,a-1,1,12)).toLocaleDateString(vt(n),{month:"long",timeZone:"UTC"})}function U(n,a){return typeof a!="number"||!Number.isFinite(a)?"":a.toLocaleString(vt(n),{maximumFractionDigits:0})}function nt(n,a){let e=a.filter(Boolean);return e.length<2?e[0]??"":new Intl.ListFormat(vt(n),{style:"long",type:"conjunction"}).format(e)}function b(n,a,e=1){return typeof a!="number"||!Number.isFinite(a)?"":a.toLocaleString(vt(n),{maximumFractionDigits:e})}function Oe(n,a,e=1){return typeof a!="number"||!Number.isFinite(a)?"":(a/100).toLocaleString(vt(n),{style:"percent",maximumFractionDigits:e})}function Tt(n){return(n.type??"").toLowerCase().trim().replace(/[\s_]+/g,"-")}function He(n){return V(Tt(n))}var um={"kp-newcomb":"KP Newcomb","kp-old":"KP Old",lahiri:"Lahiri",raman:"B.V. Raman",custom:"Custom"};function is(n,a,e){let t=typeof a=="string"?um[a]??D(a):"",r=typeof e=="number"?`${b(n,e,2)}\xB0`:"";return t&&r?`${t} (${r})`:t||r}function ue(n,a,e,t=false){let r=typeof a=="string"&&gn.test(a)&&typeof e=="string"&&jc.test(e)?`${a}T${e}`:a;if(typeof r!="string"||r.length===0)return"";if(gn.test(r))return M(n,r);let{d:s,timeZone:i}=ns(r);return Number.isNaN(s.getTime())?r:s.toLocaleString(vt(n),{month:"short",day:"numeric",year:"numeric",...yn(n),...t?{second:"2-digit"}:{},timeZone:i})}function ks(n,a,e){return Os(ue(n,a),ue(n,e))}function qc(n,a){if(typeof a!="string"||a.length===0)return"";let{d:e}=ns(a);return Number.isNaN(e.getTime())?a:e.toLocaleString(vt(n),{month:"short",day:"numeric",year:"numeric",...yn(n),timeZone:"UTC",timeZoneName:"short"})}function Yc(){try{return new Intl.DateTimeFormat(vt(void 0)).resolvedOptions().timeZone}catch{return}}function Ni(n,a){if(!(typeof a!="string"||!a))return a===n?void 0:a}function Is(n,a){let e=typeof n=="string"?n:"",t=Ni(e,a);return e?t?`${e} (${t})`:e:t??""}function ke(n,a,e){return xs(n,a)??e??D(a)}function ie(n,a,e,t){return Tc(n,a,e)??t??D(e)}var fn="Localized";function y(n,a,e){let t=n,r=t?.[`${a}${fn}`];if(typeof r=="string"&&r!=="")return r;if(e!==void 0)return e;let s=t?.[a];return typeof s=="string"?s:""}function xn(n,a){let e=n,t=e?.[a];if(!Array.isArray(t))return[];let r=e?.[`${a}${fn}`],s=Array.isArray(r)?r:[];return t.map((i,o)=>{let l=s[o];return{value:String(i),label:typeof l=="string"&&l!==""?l:String(i)}})}function Ss(n){let a;for(let e of Object.keys(n)){if(!e.endsWith(fn))continue;let t=e.slice(0,-fn.length);if(t===""||!(t in n))continue;a??={...n};let r=n[e];r!=null&&r!==""&&(a[t]=r),delete a[e]}return a??n}function Wc(n){return!("days"in n)}var xa=class extends g{constructor(){super(...arguments);this.mode="day"}renderData(e){let t=this.effectiveLang();return this.mode==="day"&&Wc(e)?G.html`<article class="card" part="card" aria-labelledby="almanac-title">${this.renderDayCard(e,t)}</article>`:Wc(e)?G.nothing:G.html`<article class="card" part="card" aria-labelledby="almanac-title"><header class="head" part="header"><h2 class="title" id="almanac-title">${"activityLabel"in e&&e.activityLabel?e.activityLabel:this.t("Almanac")}</h2>${"startDate"in e&&e.startDate?G.html`<span class="lunar">${Ct(t,e.startDate,e.endDate)}</span>`:G.nothing} ${"year"in e&&typeof e.year=="number"?G.html`<span class="lunar">${ws(t,e.year,e.month)||e.year}</span>`:G.nothing} ${typeof e.total=="number"?G.html`<span class="lunar">${this.t("{{count}} days",{count:U(t,e.total)})}</span>`:G.nothing}</header>${"avoidAnimal"in e&&e.avoidAnimal?G.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Avoiding")}</span><b>${D(y(e,"avoidAnimal"))}</b></span></div>`:G.nothing} ${this.renderSolarTerms(e,t)}<section part="section days"><ul class="days">${(e.days??[]).map(r=>this.renderDayRow(r,t))}</ul></section></article>`}renderDayCard(e,t){let r=e.dayOfficer;return G.html`<header class="head" part="header"><h2 class="title" id="almanac-title">${M(t,e.date)}</h2>${e.lunar?G.html`<span class="lunar">${e.lunar.isLeapMonth?this.t("Lunar {{month}}/{{day}} (leap)",{month:String(e.lunar.month??""),day:String(e.lunar.day??"")}):this.t("Lunar {{month}}/{{day}}",{month:String(e.lunar.month??""),day:String(e.lunar.day??"")})}</span>`:G.nothing} ${r?.name?G.html`<span class="roxy-chip tag tag-${r.quality??"neutral"}">${y(r,"name")} <span lang="zh">${r.chinese??""}</span></span>`:G.nothing}</header>${this.renderPillars(e)} ${this.renderLists(e,t)} ${r?.meaning&&!this.hideReadings?G.html`<p class="meaning" part="reading">${r.meaning}</p>`:G.nothing} ${this.renderMansion(e)}`}renderPillars(e){let r=[["Year",e.yearPillar],["Month",e.monthPillar],["Day",e.dayPillar]].filter(([,s])=>s?.chinese||s?.stem);return r.length===0&&!e.clashAnimal?G.nothing:G.html`<div class="facts" part="details">${r.map(([s,i])=>G.html`<span><span class="roxy-label">${this.t(s)}</span> <b lang="zh">${i?.chinese??""}</b> ${i?.naYin??""}</span>`)} ${e.clashAnimal?G.html`<span><span class="roxy-label">${this.t("Clash")}</span><b>${y(e,"clashAnimal")}</b></span>`:G.nothing}</div>`}renderLists(e,t){let r=e.favours??[],s=e.avoids??[];return r.length===0&&s.length===0?G.nothing:G.html`<div class="lists" part="section activities">${r.length?G.html`<div class="list"><h3>${this.t("Favours")}</h3><div class="roxy-chips chips-favour">${r.map(i=>G.html`<span class="roxy-chip">${ie(t,"activity",i)}</span>`)}</div></div>`:G.nothing} ${s.length?G.html`<div class="list"><h3>${this.t("Avoids")}</h3><div class="roxy-chips chips-avoid">${s.map(i=>G.html`<span class="roxy-chip">${ie(t,"activity",i)}</span>`)}</div></div>`:G.nothing}</div>`}renderMansion(e){let t=e.mansion;return t?.name?G.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Mansion")}</span><b>${y(t,"name")}</b> <span lang="zh">${t.chinese??""}</span></span> ${t.palace?G.html`<span>${D(t.palace)}</span>`:G.nothing} ${t.planet?G.html`<span>${t.planet}</span>`:G.nothing} ${t.animal?G.html`<span>${y(t,"animal")}</span>`:G.nothing}</div>`:G.nothing}renderSolarTerms(e,t){let r="solarTerms"in e?e.solarTerms??[]:[];return r.length===0?G.nothing:G.html`<div class="terms" part="details">${r.map(s=>G.html`<span>${ss(t,s.date)} ${s.name??""}</span>`)}</div>`}renderDayRow(e,t){let r=e.dayOfficer,s=e.favours??[];return G.html`<li class="day" part="label-track"><span class="day-date">${ss(t,e.date)}</span><div class="day-body"><span lang="zh">${e.dayPillar?.chinese??""}</span> ${r?.name?G.html`<span class="roxy-chip tag tag-${r.quality??"neutral"}">${y(r,"name")}</span>`:G.nothing} ${s.length?G.html`<span class="roxy-chips chips-favour">${s.map(i=>G.html`<span class="roxy-chip">${ie(t,"activity",i)}</span>`)}</span>`:G.nothing} ${e.clashAnimal?G.html`<span class="roxy-label">${this.t("Clash")} ${y(e,"clashAnimal")}</span>`:G.nothing}</div></li>`}};xa.endpoints=Uo,xa.styles=[u,G.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.list h3{margin:0}.list h3{margin-block-end:var(--roxy-space-xs)}.lunar{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}:is(.tag-auspicious,.chips-favour>*){color:var(--roxy-success-fg)}:is(.tag-inauspicious,.chips-avoid>*){color:var(--roxy-danger-fg)}.tag-neutral{color:var(--roxy-info-fg)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.meaning{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin:0;padding-block-start:var(--roxy-space-md)}.days{margin:0;padding:0;list-style:none;display:grid}.day{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);display:grid}.day:first-child{border-block-start:0;padding-block-start:0}.day-date{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.day-body{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.terms{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}`],m([(0,Zc.property)({type:String,reflect:true})],xa.prototype,"mode",2),xa=m([f("roxy-almanac-day")],xa);var _e=require("lit");var fm=[{key:"spiritual",source:"Spiritual"},{key:"love",source:"Love"},{key:"career",source:"Career"},{key:"money",source:"Money"},{key:"twinFlame",source:"Twin flame"}];function bn(n,a,e,t){let r=[];if(a)for(let s of fm){let i=a[s.key];i&&r.push({label:n(s.source),body:i})}return e&&r.push({label:n("Biblical"),body:e}),t&&r.push({label:n("Shadow"),body:t}),r}var xm={positive:"success",cautionary:"danger",neutral:"info"},Qa=class extends g{renderData(a){let e=(a.energy??"").toLowerCase(),t=a.keywords??[],r=a.actionSteps??[];return _e.html`<article class="card" part="card" aria-label="${`${this.t("Angel number")} ${a.number??""}`}"><div class="hero" part="header">${a.number?_e.html`<div class="numeral">${a.number}</div>`:_e.nothing}<div><p class="roxy-label">${this.t("Angel number")}</p>${a.title?_e.html`<h2>${a.title}</h2>`:_e.nothing}</div></div>${a.coreMessage&&!this.hideReadings?_e.html`<p>${a.coreMessage}</p>`:_e.nothing}<ul class="badges roxy-chips" part="details">${a.type?_e.html`<li>${a.type}</li>`:_e.nothing} ${typeof a.digitRoot=="number"?_e.html`<li>${this.t("Digit root")} ${a.digitRoot}</li>`:_e.nothing} ${a.energy?_e.html`<li class="roxy-chip" data-tone="${xm[e]??_e.nothing}">${a.energy}</li>`:_e.nothing}</ul>${t.length>0&&!this.hideReadings?_e.html`<ul class="roxy-chips">${t.map(s=>_e.html`<li>${s}</li>`)}</ul>`:_e.nothing} ${this.renderSections(a)} ${a.affirmation&&!this.hideReadings?_e.html`<p class="affirmation">${a.affirmation}</p>`:_e.nothing} ${r.length>0&&!this.hideReadings?_e.html`<div class="steps" part="section action-steps"><h3>${this.t("Action steps")}</h3><ul>${r.map(s=>_e.html`<li>${s}</li>`)}</ul></div>`:_e.nothing}</article>`}renderSections(a){return this.renderInterpretation(bn(this.translator,a.meaning,a.biblical,a.shadow),"angel-meaning","Reading")}};Qa.endpoints=qo,Qa.styles=[u,me,_e.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.numeral){min-width:0}@container (width<=24rem){.hero{justify-items:start;gap:var(--roxy-space-sm);grid-template-columns:minmax(0,1fr);display:grid}}.badges>li{text-transform:capitalize}.affirmation{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);font-style:italic}.steps h3{margin-block-end:var(--roxy-space-xs)}.steps ul{gap:calc(var(--roxy-space-unit) / 2);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}`],Qa=m([f("roxy-angel-number-card")],Qa);var j=require("lit");var bm={positive:"Positive energy",neutral:"Neutral energy",cautionary:"Cautionary energy"},vm={positive:"success",cautionary:"warning"},er=class extends g{renderData(a){let e=a.knownMeaning,t=a.digitRootMeaning,r=e?.title??this.t("Number analysis"),s=e?.actionSteps??[];return j.html`<article class="card" part="card" aria-label="${this.t("Angel number {{number}}",{number:a.number??""})}"><div class="hero" part="header">${a.number?j.html`<div class="numeral">${a.number}</div>`:j.nothing}<div>${e?.title?j.html`<p class="roxy-label">${this.t("Number analysis")}</p>`:j.nothing}<h2>${r}</h2></div></div><ul class="badges roxy-chips" part="details">${a.type?j.html`<li>${a.type}</li>`:j.nothing} ${typeof a.digits=="number"?j.html`<li>${this.t("{{count}} digits",{count:a.digits})}</li>`:j.nothing} ${typeof a.uniqueDigits=="number"?j.html`<li>${this.t("{{count}} unique",{count:a.uniqueDigits})}</li>`:j.nothing} ${typeof a.digitRoot=="number"?j.html`<li>${this.t("Digit root {{n}}",{n:a.digitRoot})}</li>`:j.nothing} ${a.isPalindrome?j.html`<li class="roxy-chip" data-tone="info">${this.t("Palindrome")}</li>`:j.nothing} ${a.isRepeating?j.html`<li class="roxy-chip" data-tone="info">${this.t("Repeating")}</li>`:j.nothing} ${e?.energy?j.html`<li class="roxy-chip" data-tone="${vm[e.energy]??j.nothing}">${this.t(bm[e.energy]??"Neutral energy")}</li>`:j.nothing}</ul>${a.contextNote?j.html`<div class="context" part="section context"><p class="roxy-label">${this.t("Where you saw it")}</p><p>${a.contextNote}</p></div>`:j.nothing} ${e&&!this.hideReadings?j.html`<div class="section" part="section known-meaning"><p class="roxy-label">${this.t("Known angel number")}</p>${e.coreMessage?j.html`<p>${e.coreMessage}</p>`:j.nothing} ${e.keywords&&e.keywords.length>0?j.html`<ul class="roxy-chips">${e.keywords.map(i=>j.html`<li>${i}</li>`)}</ul>`:j.nothing} ${this.renderMeaning(e.meaning,"lookup-known",e.biblical,e.shadow)} ${e.affirmation?j.html`<p><em>${e.affirmation}</em></p>`:j.nothing} ${s.length>0?j.html`<p class="roxy-label">${this.t("What to do next")}</p><ol class="steps">${s.map(i=>j.html`<li>${i}</li>`)}</ol>`:j.nothing}</div>`:j.nothing} ${t&&!this.hideReadings?j.html`<div class="section" part="section digit-root"><p class="roxy-label">${t.number?this.t("Foundational digit root ({{n}})",{n:t.number}):this.t("Foundational digit root")}</p>${t.title?j.html`<h3>${t.title}</h3>`:j.nothing} ${t.coreMessage?j.html`<p>${t.coreMessage}</p>`:j.nothing} ${e?j.nothing:this.renderRootMeaning(t)}</div>`:j.nothing}</article>`}renderMeaning(a,e,t,r){return this.renderInterpretation(bn(this.translator,a,t,r),e,"Reading")}renderRootMeaning(a){return j.html`${a.keywords&&a.keywords.length>0?j.html`<ul class="roxy-chips">${a.keywords.map(e=>j.html`<li>${e}</li>`)}</ul>`:j.nothing}${this.renderMeaning(a.meaning,"lookup-root")}${a.affirmation?j.html`<p><em>${a.affirmation}</em></p>`:j.nothing}`}};er.endpoints=Yo,er.styles=[u,W,me,j.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.numeral){min-width:0}@container (width<=24rem){.hero{justify-items:start;gap:var(--roxy-space-sm);grid-template-columns:minmax(0,1fr);display:grid}}.badges>li{text-transform:capitalize}.context{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);display:grid}.steps{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.section{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.section p{font-size:var(--roxy-text-sm)}`],er=m([f("roxy-angel-number-lookup")],er);var pt=require("lit");var Rs=(n,a)=>a?n[Rt(a)]:void 0,Lm={sun:"\u2609",moon:"\u263D",mercury:"\u263F",venus:"\u2640",earth:"\u2641",mars:"\u2642",jupiter:"\u2643",saturn:"\u2644",uranus:"\u2645",neptune:"\u2646",pluto:"\u2647",rahu:"\u260A",ketu:"\u260B",ascendant:"Asc",midheaven:"MC","part of fortune":"\u2297",vertex:"Vx",lagna:"La","north node":"\u260A","south node":"\u260B",chiron:"\u26B7",lilith:"\u26B8","black moon lilith":"\u26B8"},S=n=>Rs(Lm,n),$m={sun:"Su",moon:"Mo",mercury:"Me",venus:"Ve",mars:"Ma",jupiter:"Ju",saturn:"Sa",uranus:"Ur",neptune:"Ne",pluto:"Pl",rahu:"Ra",ketu:"Ke",ascendant:"Asc",lagna:"La"},Jc=n=>Rs($m,n),wm={aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"},Z=n=>Rs(wm,n),km={aries:"Ar",taurus:"Ta",gemini:"Ge",cancer:"Cn",leo:"Le",virgo:"Vi",libra:"Li",scorpio:"Sc",sagittarius:"Sg",capricorn:"Cp",aquarius:"Aq",pisces:"Pi"},vn=n=>Rs(km,n),Ie=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"],Sm={conjunction:"\u260C",semisextile:"\u26BA","semi sextile":"\u26BA",semisquare:"\u2220","semi square":"\u2220",sextile:"\u26B9",square:"\u25A1",trine:"\u25B3",sesquiquadrate:"\u26BC",quincunx:"\u26BB",opposition:"\u260D"},Cs=n=>Rs(Sm,n),Rm={heaven:"\u2630",lake:"\u2631",fire:"\u2632",thunder:"\u2633",wind:"\u2634",water:"\u2635",mountain:"\u2636",earth:"\u2637"},zi=n=>Rs(Rm,n),Xc={"new moon":"\u{1F311}","waxing crescent":"\u{1F312}","first quarter":"\u{1F313}","waxing gibbous":"\u{1F314}","full moon":"\u{1F315}","waning gibbous":"\u{1F316}","last quarter":"\u{1F317}","waning crescent":"\u{1F318}"},Qc=n=>{if(!n)return;let a=Rt(n),e=a.replace(/ moon$/,""),t=e==="third quarter"?"last quarter":e;return Xc[a]??Xc[t]};var ed=require("lit"),Se=ed.css`.roxy-facts{gap:var(--roxy-space-sm) var(--roxy-space-lg);margin:var(--roxy-space-sm) 0 0;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;flex-wrap:wrap;display:flex}.roxy-facts>div{min-width:0}.roxy-facts dd{overflow-wrap:anywhere;margin:0}`;var zt=require("lit");var ae=zt.css`.roxy-frame{color:var(--roxy-muted);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-normal);margin:0}.roxy-frame .roxy-frame-deg{font-variant-numeric:tabular-nums}`;function ve(n,a,e){if(!a?.ayanamsa)return zt.nothing;let t=is(n,a.ayanamsa);if(!t)return zt.nothing;let r=typeof a.ayanamsaDegrees=="number"?b(n,a.ayanamsaDegrees,4):void 0;return zt.html`<p class="roxy-frame">${r===void 0?e("Sidereal frame: {{frame}}",{frame:t}):e("Sidereal frame: {{frame}}, {{degrees}}\xB0 subtracted",{frame:t,degrees:r})}</p>`}function tr(n,a,e){let t=[];return n?.yearBoundary&&t.push(["Year boundary","yearBoundary",n.yearBoundary]),n?.dayBoundary&&t.push(["Day boundary","dayBoundary",n.dayBoundary]),n?.hourClock&&t.push(["Hour clock","hourClock",n.hourClock]),t.length===0?zt.nothing:zt.html`<p class="roxy-frame">${t.map(([r,s,i],o)=>zt.html`${o>0?" \xB7 ":""}${a(r)}: <span class="roxy-frame-deg" title="${i}">${ie(e,s,i)}</span>`)}</p>`}function td(n,a,e){let t=Object.values(a??{}).filter(r=>!!r?.ayanamsa);return t.length===0?zt.nothing:zt.html`<div class="roxy-frame">${t.map(r=>{let s=is(n,r.ayanamsa),i=typeof r.ayanamsaDegrees=="number"?b(n,r.ayanamsaDegrees,4):void 0,o=r.governs?.length?r.governs.join(", "):"";return zt.html`<p class="roxy-frame">${i===void 0?e("Sidereal frame: {{frame}}",{frame:s}):e("Sidereal frame: {{frame}}, {{degrees}}\xB0 subtracted",{frame:s,degrees:i})}${o?e(", governs {{sections}}",{sections:o}):""}</p>`})}</div>`}var rd=require("lit");var ad=require("lit"),ia=ad.css`@container (width<=30rem){table.stacked,table.stacked caption,table.stacked tbody,table.stacked tr,table.stacked td{width:100%;min-width:0;display:block}table.stacked thead{display:none}table.stacked tr{border-bottom:1px solid var(--roxy-border);padding-block:var(--roxy-space-sm)}table.stacked tr:last-child{border-bottom:0}table.stacked td{padding:calc(var(--roxy-space-unit) / 2) 0;white-space:normal;border:0}table.stacked td:empty{display:none}table.stacked td[data-inline]{width:auto;margin-inline-end:var(--roxy-space-md);display:inline-block}table.stacked td[data-label]:before{content:attr(data-label) " ";color:var(--roxy-muted)}}`;var Ln=[ia,rd.css`.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr.lead-row td:first-child{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}td.name{font-weight:var(--roxy-weight-bold)}.abbr{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);margin-inline-start:var(--roxy-space-xs)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}tbody tr.lead-row :is(.abbr,.glyph){color:var(--roxy-accent-ink)}.meaning{min-width:24ch}.meaning strong{display:block}.meaning p{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}@container (width<=30rem){table.stacked tr{padding-inline:var(--roxy-space-md)}table.stacked tbody tr.lead-row{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}table.stacked tbody tr.lead-row td:first-child{box-shadow:none}}`];var Cm=new Set(["a1","a12"]),ar=class extends g{renderData(a){let e=a.padas??[];if(!e.length)return this.renderEmpty();let t=e.filter(r=>r.exceptionApplied).length;return pt.html`<div class="wrap" part="card" aria-label="${this.t("Arudha padas")}"><header class="head" part="header"><h2>${this.t("Arudha padas")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header><dl class="roxy-facts" part="details"><div><dt>${this.t("Lagna")}</dt><dd>${a.lagnaRashi??""}</dd></div><div><dt>${this.t("Arudha Lagna")}</dt><dd>${a.arudhaLagna??""}</dd></div><div><dt>${this.t("Upapada")}</dt><dd>${a.upapada??""}</dd></div></dl><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Arudha padas")}"><table class="stacked" role="table"><caption class="roxy-sr-only">${this.t("The twelve Arudha padas: each pada with its bhava, the bhava sign and its lord, the sign the lord occupies, the sign the pada falls in, which house from the Lagna that is, whether the classical exception was applied, and what the pada is read for.")}</caption><thead><tr><th scope="col">${this.t("Pada")}</th><th scope="col">${this.t("Bhava")}</th><th scope="col">${this.t("Bhava rashi")}</th><th scope="col">${this.t("Lord")}</th><th scope="col">${this.t("Lord rashi")}</th><th scope="col">${this.t("Pada rashi")}</th><th scope="col">${this.t("From Lagna")}</th><th scope="col">${this.t("Read for")}</th></tr></thead><tbody>${e.map(r=>this.renderRow(r))}</tbody></table></div>${t>0?pt.html`<p class="note" part="legend"><span class="exception">${this.t("Moved")}</span> ${this.t("marks a pada that fell in its own bhava or the seventh from it and was moved to the tenth from there, as the classical rule requires. {{count}} of {{total}} padas here.",{count:t,total:e.length})}</p>`:pt.nothing}</div>`}renderRow(a){let e=r=>Z(r)??"",t=r=>{let s=e(r);return pt.html`${s?pt.html`<span class="glyph">${s}</span>`:pt.nothing}${r??""}`};return pt.html`<tr class="${Cm.has(a.id)?"lead-row":""}"><td class="name">${a.name??""}${a.abbreviation?pt.html`<span class="abbr">${a.abbreviation}</span>`:pt.nothing}</td><td data-inline data-label="${this.t("Bhava")}">${a.house??""}</td><td data-inline data-label="${this.t("Bhava rashi")}">${t(a.bhavaRashi)}</td><td data-inline data-label="${this.t("Lord")}">${a.lord??""}</td><td data-inline data-label="${this.t("Lord rashi")}">${t(a.lordRashi)}</td><td data-inline data-label="${this.t("Pada rashi")}">${t(a.rashi)} ${a.exceptionApplied?pt.html`<span class="exception">${this.t("Moved")}</span>`:pt.nothing}</td><td data-inline data-label="${this.t("From Lagna")}">${a.houseFromLagna??""}</td><td class="meaning"><strong>${a.meaning??""}</strong> ${a.significations?pt.html`<p>${a.significations}</p>`:pt.nothing}</td></tr>`}};ar.endpoints=Wo,ar.styles=[u,ae,Se,...Ln,pt.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,p{margin:0}.roxy-facts{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);margin:0}.roxy-facts dd{font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold)}.exception{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.note{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],ar=m([f("roxy-arudha-padas")],ar);var Pe=require("lit"),sd=require("lit/decorators.js");var ba=require("lit"),ot=ba.css`.roxy-tablist{gap:var(--roxy-space-xs);box-shadow:inset 0 calc(var(--roxy-line-thick) * -1) 0 var(--roxy-border);scrollbar-width:thin;min-width:0;display:flex;overflow-x:auto}.roxy-tab{padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);border:none;border-bottom:var(--roxy-line-thick) solid transparent;cursor:pointer;color:var(--roxy-muted);transition:color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;flex-shrink:0}.roxy-tab[aria-selected=true]{color:var(--roxy-accent-ink);border-bottom-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.roxy-tab:hover:not([aria-selected=true]){color:var(--roxy-fg)}.roxy-tab:focus-visible{outline-offset:calc(var(--roxy-line-thick) * -1);border-radius:var(--roxy-radius-sm)}`;function gt(n){let{items:a,active:e,onSelect:t,label:r,idPrefix:s,controls:i=false}=n;return ba.html`<div class="roxy-tablist" part="tablist" role="tablist" aria-label="${r}" @keydown="${l=>{if(l.key!=="ArrowRight"&&l.key!=="ArrowLeft")return;l.preventDefault();let c=a.findIndex(x=>x.id===e);if(c===-1)return;let d=l.key==="ArrowRight"?1:-1,p=a[(c+d+a.length)%a.length];if(!p)return;t(p.id);let h=l.currentTarget.getRootNode();requestAnimationFrame(()=>{h.querySelector(`#${s}-tab-${p.id}`)?.focus()})}}">${a.map(l=>ba.html`<button type="button" class="roxy-tab" part="tab" role="tab" id="${s}-tab-${l.id}" aria-selected="${e===l.id?"true":"false"}" aria-controls="${i?`${s}-panel-${l.id}`:ba.nothing}" tabindex="${e===l.id?"0":"-1"}" @click="${()=>t(l.id)}">${l.label}</button>`)}</div>${i?a.filter(l=>l.id!==e).map(l=>ba.html`<div role="tabpanel" id="${s}-panel-${l.id}" aria-labelledby="${s}-tab-${l.id}" hidden></div>`):ba.nothing}`}var Tm=[{id:"sarva",source:"Sarvashtakavarga"},{id:"bhinna",source:"Bhinnashtakavarga"},{id:"reduced",source:"Reduced"},{id:"pinda",source:"Shodhya Pinda"}],va=class extends g{constructor(){super(...arguments);this.activeTab="sarva"}renderData(e){let t=e.signs??[];return Pe.html`<div class="wrap" part="card" aria-label="${this.t("Ashtakavarga grid")}"><div class="head" part="header"><h2 class="title">${this.t("Ashtakavarga")}</h2>${t.length?Pe.html`<p class="subtitle">${this.t("{{count}} signs",{count:t.length})}</p>`:Pe.nothing} ${ve(this.effectiveLang(),e.frame,this.translator)}</div>${gt({items:Tm.map(({id:r,source:s})=>({id:r,label:this.t(s)})),active:this.activeTab,onSelect:r=>{this.activeTab=r},label:this.t("Ashtakavarga views"),idPrefix:"ashtakavarga",controls:true})}<div id="ashtakavarga-panel-${this.activeTab}" part="panel" role="tabpanel" aria-labelledby="ashtakavarga-tab-${this.activeTab}">${this.activeTab==="sarva"?this.renderSarva(t):this.activeTab==="bhinna"?this.renderBhinna(t):this.activeTab==="reduced"?this.renderReduced(t):this.renderPinda()}</div></div>`}bhinnaTier(e){return e<=1?"tier-1":e<=2?"tier-2":e<=3?"tier-3":e<=4?"tier-4":e<=5?"tier-5":e<=6?"tier-6":"tier-7"}sarvaTier(e){return e<=20?"tier-1":e<=24?"tier-2":e<=27?"tier-3":e<=29?"tier-4":e<=32?"tier-5":e<=36?"tier-6":"tier-7"}renderLegend(e){return Pe.html`<div class="legend" part="legend"><span>${this.t("Fewer bindus")}</span> <span class="legend-scale" aria-hidden="true">${[1,2,3,4,5,6,7].map(t=>Pe.html`<span class="legend-swatch tier-${t}"></span>`)} </span><span>${this.t("More bindus")}</span> <span class="legend-note">${e}</span></div>`}renderSarva(e){let t=this.data?.sarvashtakavarga;return t?Pe.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Sarvashtakavarga")}"><table><caption class="roxy-sr-only">${this.t("Sarvashtakavarga: each of the twelve signs and the bindus all planets contribute to it, with a grand total.")}</caption><thead><tr><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Bindus")}</th></tr></thead><tbody>${e.map((r,s)=>{let i=t.bindus[s]??0;return Pe.html`<tr><td><div class="planet-cell"><span class="glyph" aria-hidden="true">${Z(r)??""}</span> ${r}</div></td><td class="${`bindu-cell ${this.sarvaTier(i)}`}">${i}</td></tr>`})}</tbody><tfoot><tr class="total-row"><td>${this.t("Total")}</td><td>${t.total}</td></tr></tfoot></table></div>${this.renderLegend("Under 25 is a weak sign, 25 to 29 average, 30 and above strong. The 12 signs always total 337.")}`:Pe.html`<p class="roxy-empty">${this.t("No sarvashtakavarga data")}</p>`}renderBhinna(e){let t=this.data?.bhinnashtakavarga;return t?.length?Pe.html`${this.renderBinduGrid(e,t,"Bhinnashtakavarga: the bindus each planet scores in every one of the twelve signs, with a row total.","Bhinnashtakavarga")} ${this.renderLegend("Each planet scores 0 to 8 bindus per sign. 4 is the mid, 5 and above is strong support for that planet in that sign.")}`:Pe.html`<p class="roxy-empty">${this.t("No bhinnashtakavarga data")}</p>`}renderReduced(e){let t=this.data?.reducedBhinnashtakavarga,r=this.data?.reducedSarvashtakavarga;return!t?.length&&!r?Pe.html`<p class="roxy-empty">${this.t("No reduced ashtakavarga data")}</p>`:Pe.html`${this.renderBinduGrid(e,t??[],"Reduced Bhinnashtakavarga after Shodhana: the bindus each planet keeps in every one of the twelve signs, with a row total and a Reduced Sarvashtakavarga totals row.","Reduced",r)} ${this.renderLegend("Bindus left after Trikona and Ekadipati Shodhana, the input to Shodhya Pinda. The Reduced SAV row totals the seven planets only, so it does not include the Lagna row above it.")}`}renderBinduGrid(e,t,r,s,i){return t.length?Pe.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t(s)}"><table class="bhinna-table"><caption class="roxy-sr-only">${r}</caption><thead><tr><th scope="col">${this.t("Planet")}</th>${e.map(o=>Pe.html`<th scope="col" title="${o}">${Z(o)??o}</th>`)}<th scope="col">${this.t("Total")}</th></tr></thead><tbody>${t.map(o=>Pe.html`<tr><td>${o.planet}</td>${o.bindus.map(l=>Pe.html`<td class="${`bindu-cell ${this.bhinnaTier(l)}`}">${l}</td>`)}<td>${o.total}</td></tr>`)}</tbody>${i?Pe.html`<tfoot><tr class="total-row"><td>${this.t("Reduced SAV")}</td>${e.map((o,l)=>Pe.html`<td>${i.bindus[l]??0}</td>`)}<td>${i.total}</td></tr></tfoot>`:Pe.nothing}</table></div>`:Pe.html`<p class="roxy-empty">${this.t("No bindu data")}</p>`}renderPinda(){let e=this.data?.shodhyaPinda;return e?.length?Pe.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Shodhya Pinda")}"><table><caption class="roxy-sr-only">${this.t("Shodhya Pinda: each planet with its Rashi Pinda, Graha Pinda and Shodhya Pinda strength scores.")}</caption><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Rashi Pinda")}</th><th scope="col">${this.t("Graha Pinda")}</th><th scope="col">${this.t("Shodhya Pinda")}</th></tr></thead><tbody>${e.map(t=>Pe.html`<tr><td>${t.planet}</td><td>${t.rashiPinda}</td><td>${t.grahaPinda}</td><td>${t.shodhyaPinda}</td></tr>`)}</tbody></table></div>`:Pe.html`<p class="roxy-empty">${this.t("No shodhya pinda data")}</p>`}};va.endpoints=Zo,va.styles=[u,ae,ot,Pe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.subtitle{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}[role=tabpanel]:not([hidden]){gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.overflow-scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){text-align:center}:is(th,td):first-child{text-align:start}.glyph{font-size:var(--roxy-text-base);line-height:1}.planet-cell{align-items:center;gap:var(--roxy-space-xs);white-space:nowrap;display:flex}.total-row td{font-weight:var(--roxy-weight-bold);border-block-start:var(--roxy-line-thick) solid var(--roxy-border);border-block-end:0}.bindu-cell{min-width:3ch;font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;color:var(--roxy-fg)}.tier-1{background:color-mix(in srgb, var(--roxy-heat) 30%, transparent)}.tier-2{background:color-mix(in srgb, var(--roxy-heat) 17%, transparent)}.tier-3{background:color-mix(in srgb, var(--roxy-heat) 7%, transparent)}.tier-4{background:color-mix(in srgb, var(--roxy-border) 45%, transparent)}.tier-5{background:color-mix(in srgb, var(--roxy-success) 16%, transparent)}.tier-6{background:color-mix(in srgb, var(--roxy-success) 32%, transparent)}.tier-7{background:color-mix(in srgb, var(--roxy-success) 50%, transparent)}.legend{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend-scale{gap:1px;display:flex}.legend-swatch{block-size:.75lh;inline-size:2ch}.legend-note{flex:24ch}.bhinna-table :is(th,td):first-child{min-width:8ch}@container (width<=480px){.bhinna-table :is(th,td){padding:var(--roxy-space-xs);font-size:var(--roxy-text-xs)}.bhinna-table :is(th,td):first-child{min-width:6ch}.bindu-cell{min-width:2ch}}`],m([(0,sd.state)()],va.prototype,"activeTab",2),va=m([f("roxy-ashtakavarga-grid")],va);var B=require("lit");var Em=new Set(["conjunction","sextile","square","trine","opposition"]);function La(n){return Em.has(Tt(n))}function Ze(n){return`aspect-${Tt(n)}`}var nd=.3,Dm=.9,id=.5,Am=1.8;function Ts(n){let{strength:a}=n;if(typeof a!="number"||!Number.isFinite(a))return;let e=Math.min(1,Math.max(0,a/100)),t=nd+e*(Dm-nd),r=id+e*(Am-id);return`opacity:${t.toFixed(3)};stroke-width:${r.toFixed(3)}`}var Oi=require("lit"),$a=Oi.css`.aspect-trine,.aspect-sextile{--_aspect:var(--roxy-info);--_aspect-ink:var(--roxy-info-fg)}.aspect-square,.aspect-opposition{--_aspect:var(--roxy-danger);--_aspect-ink:var(--roxy-danger-fg)}.aspect-quincunx,.aspect-semi-sextile{--_aspect:var(--roxy-success);--_aspect-ink:var(--roxy-success-fg)}.aspect-conjunction{--_aspect:var(--roxy-accent-ink);--_aspect-ink:var(--roxy-accent-ink)}:is(.aspect-trine,.aspect-sextile,.aspect-square,.aspect-opposition,.aspect-quincunx,.aspect-semi-sextile,.aspect-conjunction){color:var(--_aspect-ink);stroke-opacity:1}.aspect-swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_aspect);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}`,Es=[Oi.css`.aspect{stroke:var(--_aspect,var(--roxy-muted));stroke-width:.8px;fill:none;opacity:.55;stroke-opacity:.7}`,$a];function Pm(n,a,e){if(n.include?.length){let t={bodies:nt(a,n.include)};return n.strictOrbs?e("Detected with strict orbs, including {{bodies}}.",t):e("Detected with industry-standard orbs, including {{bodies}}.",t)}return n.strictOrbs?e("Detected with strict orbs, classical bodies only."):e("Detected with industry-standard orbs, classical bodies only.")}var od={GRAND_CROSS:0,GRAND_TRINE:1,KITE:2,T_SQUARE:3,YOD:4,MYSTIC_RECTANGLE:5,STELLIUM:6},rr=class extends g{renderData(a){let e="aspects"in a?a.aspects??[]:[],t="patterns"in a?a.patterns??[]:[],r="summary"in a?a.summary:void 0;if(e.length===0&&t.length===0)return this.renderEmpty();let s=ue(this.effectiveLang(),"transitDate"in a?a.transitDate:"date"in a?a.date:"","time"in a?a.time:void 0,true),i="timezone"in a?a.timezone:void 0,o="options"in a?a.options:void 0;return B.html`<div class="wrap" part="card" aria-label="${this.t("Aspects")}"><div class="head" part="header"><h2>${e.length===0?this.t("Chart patterns"):this.t("Aspects")}</h2>${e.length>0||s?B.html`<p class="subtitle roxy-label">${[e.length===1?this.t("1 aspect"):e.length>1?this.t("{{count}} aspects",{count:e.length}):"",s].filter(Boolean).join(" \xB7 ")}</p>`:B.nothing} ${typeof i=="number"&&Number.isFinite(i)?B.html`<dl class="roxy-facts" part="details"><div><dt>${ke(this.effectiveLang(),"timezone")}</dt><dd>${b(this.effectiveLang(),i,5)}</dd></div></dl>`:B.nothing}</div>${r?this.renderSummary(r):B.nothing} ${r&&"strongest"in r&&r.strongest?this.renderStrongest(r.strongest):B.nothing} ${e.length>0?B.html`<div role="list" part="section aspects" aria-label="${this.t("Aspect list")}">${e.map((l,c)=>B.html`<div role="listitem">${this.renderAspect(l,c)}</div>`)}</div>`:B.nothing} ${t.length>0?B.html`<section class="patterns" part="section patterns"><h3>${this.t("Chart patterns")}</h3>${[...t].sort((l,c)=>(od[l.kind]??9)-(od[c.kind]??9)||(c.tightness??0)-(l.tightness??0)).map(l=>this.renderPattern(l))}</section>`:B.nothing} ${o?B.html`<p class="provenance">${Pm(o,this.effectiveLang(),this.translator)}</p>`:B.nothing}</div>`}renderSummary(a){let e="totalAspects"in a?a.totalAspects:a.total,t=Object.entries(a.byType??{}).sort((r,s)=>s[1]-r[1]);return B.html`<p class="counts" part="details" role="region" aria-label="${this.t("Aspect summary")}">${typeof e=="number"?B.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e})}</span>`:B.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:a.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:a.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:a.neutral})}</span> ${t.map(([r,s])=>B.html`<span>${this.t("{{label}}: {{value}}",{label:He({type:r}),value:s})}</span>`)}</p>`}renderStrongest(a){let e=S(a.planet1)??"",t=S(a.planet2)??"";return B.html`<div class="strongest" part="details strongest"><span class="roxy-label">${this.t("Strongest")}</span> <span aria-hidden="true" class="glyph">${e}</span>${y(a,"planet1")} <span class="asp-name ${Ze(a)}">${y(a,"type",He(a))}</span> <span aria-hidden="true" class="glyph">${t}</span>${y(a,"planet2")} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:a.isApplying?this.t("Applying"):this.t("Separating"),orb:b(this.effectiveLang(),a.orb,2),strength:b(this.effectiveLang(),a.strength,0)})}</span></div>`}renderAspect(a,e){let t=S(a.planet1)??"",r=S(a.planet2)??"",s=He(a),i=a.isApplying?this.t("Applying"):this.t("Separating"),o="meaning"in a?a.meaning:void 0,l="transitInterpretation"in a?a.transitInterpretation:void 0,c="aspectInterpretation"in a?a.aspectInterpretation:void 0,d=!!(o||l||c),p=B.html`<span aria-hidden="true" class="glyph">${t}</span>${y(a,"planet1")} <span class="asp-name ${Ze(a)}">${y(a,"type",s)}</span> <span aria-hidden="true" class="glyph">${r}</span>${y(a,"planet2")} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:i,orb:b(this.effectiveLang(),a.orb,2),strength:b(this.effectiveLang(),a.strength,0)})}</span>`;return!d||this.hideReadings?B.html`<div class="interp-card" part="reading"><div class="static-head">${p}</div></div>`:B.html`<details class="interp-card" part="reading" name="aspects" ?open="${e===0}"><summary>${p}${he()}</summary><div class="interp-body" part="readings">${o?this.renderMeaning(o):B.nothing} ${l?this.renderTransit(l):B.nothing} ${c?zs(c,this.translator):B.nothing}</div></details>`}renderMeaning(a){return B.html`${a.description?.short?B.html`<p>${a.description.short}</p>`:B.nothing} ${a.description?.long&&a.description.long!==a.description.short?B.html`<p>${a.description.long}</p>`:B.nothing} ${as(a.keywords)}`}renderTransit(a){return zs(a,this.translator)}renderPattern(a){let e=a.planets??[],t=a.apex?[...e].sort((r,s)=>+(s===a.apex)-+(r===a.apex)):e;return B.html`<div class="pattern" part="pattern"><div class="pattern-head"><span class="pattern-name">${a.name??a.kind??this.t("Pattern")}</span> ${a.element?B.html`<span class="roxy-chip">${a.element}</span>`:B.nothing} ${a.modality?B.html`<span class="roxy-chip">${a.modality}</span>`:B.nothing} ${a.dissociate?B.html`<span class="roxy-chip" title="${this.t("Out of sign: one or more planets sit outside the pattern element or modality, so the theme holds but runs weaker.")}">${this.t("Dissociate")}</span>`:B.nothing} ${typeof a.tightness=="number"?B.html`<span class="pattern-tight roxy-label">${this.t("{{percent}} tight",{percent:Oe(this.effectiveLang(),a.tightness,0)})}</span>`:B.nothing}</div>${t.length?B.html`<ul class="roxy-chips">${t.map(r=>{let s=S(r),i=!!a.apex&&r===a.apex;return B.html`<li class="${i?"roxy-chip apex":"roxy-chip"}">${s?B.html`<span aria-hidden="true">${s}</span>`:B.nothing}${r}${i?B.html`<span>${this.t("apex")}</span>`:B.nothing}</li>`})}</ul>`:B.nothing} ${a.interpretation&&!this.hideReadings?B.html`<p class="pattern-interp">${a.interpretation}</p>`:B.nothing}</div>`}};rr.endpoints=Xo,rr.styles=[u,Se,W,me,$a,B.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.interp-card summary,.static-head{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.static-head{font-size:var(--roxy-text-sm)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-normal);font-variant-numeric:tabular-nums;margin-inline-start:auto}.glyph{line-height:1}.asp-name{font-weight:var(--roxy-weight-bold)}.strongest,.pattern{padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.strongest{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.pattern{gap:var(--roxy-space-xs);display:grid}.pattern-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.pattern-name{font-weight:var(--roxy-weight-bold)}.pattern-tight{font-variant-numeric:tabular-nums;margin-inline-start:auto}.roxy-chip.apex{color:var(--roxy-fg);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.pattern-interp{font-size:var(--roxy-text-sm)}.provenance{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],rr=m([f("roxy-aspects-table")],rr);var fe=require("lit");var os=require("lit"),je=class{constructor(a){this.host=a;this.state="closed";this.zoom=1;this.pressedBy="";this.press=a2=>{this.pressedBy=a2.pointerType};this.openOnMouse=a2=>{let e=this.pressedBy==="mouse";this.pressedBy="",e&&(a2.target?.closest?.("a, button, summary, input, select, textarea")||getSelection()?.toString()||this.open())};a.addController(this)}hostUpdated(){let a=this.host.renderRoot.querySelector(".roxy-chart-dialog");if(!a)this.reset();else if(a.isConnected&&this.state!=="closed"){this.state==="opening"&&(this.state="open",a.open||a.showModal());let e=a.querySelector(".roxy-chart-scroll");a.open&&e&&this.position&&(e.scrollLeft=e.scrollWidth*this.position.x-e.clientWidth/2,e.scrollTop=e.scrollHeight*this.position.y-e.clientHeight/2,this.position=void 0)}}hostDisconnected(){this.reset(),this.host.renderRoot.querySelector(".roxy-chart-dialog")?.close()}open(){this.state="opening",this.position={x:.5,y:0},this.host.requestUpdate()}reset(){this.state="closed",this.zoom=1,this.position=void 0}resize(a){let e=this.host.renderRoot.querySelector(".roxy-chart-scroll");this.position=a===0?{x:.5,y:0}:e?{x:(e.scrollLeft+e.clientWidth/2)/e.scrollWidth,y:(e.scrollTop+e.clientHeight/2)/e.scrollHeight}:void 0,this.zoom=a===0?1:Math.min(3,Math.max(1,this.zoom+a)),this.host.requestUpdate()}renderChartViewport(a,e,t){return os.html`<div class="roxy-chart-view"><div class="roxy-chart-hit" @pointerdown="${this.press}" @click="${this.openOnMouse}">${a}</div><div class="roxy-chart-tools" part="chart-controls"><button type="button" @click="${()=>this.open()}">${t("Enlarge chart")}</button></div><dialog class="roxy-chart-dialog" part="chart-dialog" aria-label="${e}" @close="${()=>{this.reset(),this.host.requestUpdate()}}">${this.state!=="closed"?os.html`<div class="roxy-chart-bar"><strong>${e}</strong><div class="roxy-chart-tools"><button type="button" aria-label="${t("Zoom out")}" ?disabled="${this.zoom===1}" @click="${()=>this.resize(-.5)}">−</button> <button type="button" @click="${()=>this.resize(0)}">${t("Reset zoom")}</button> <button type="button" aria-label="${t("Zoom in")}" ?disabled="${this.zoom===3}" @click="${()=>this.resize(.5)}">+</button> <button type="button" @click="${()=>this.host.renderRoot.querySelector(".roxy-chart-dialog")?.close()}">${t("Close")}</button></div></div><div class="roxy-chart-scroll" role="region" tabindex="0" aria-label="${e}"><div class="roxy-chart-expanded" style="${`--chart-zoom:${this.zoom}`}">${a}</div></div>`:os.nothing}</dialog></div>`}},Xe=os.css`.roxy-chart-view{min-width:0}@media (hover:hover) and (pointer:fine){.roxy-chart-hit{cursor:zoom-in}}.roxy-chart-tools{gap:var(--roxy-space-sm);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex}.roxy-chart-tools button{font-size:var(--roxy-text-sm);color:var(--roxy-secondary);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);min-width:2lh;min-height:2lh;padding:var(--roxy-space-xs) var(--roxy-space-sm);cursor:pointer;background:0 0}.roxy-chart-tools button:hover:not(:disabled){border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-chart-tools button:disabled{color:var(--roxy-muted);cursor:default}.roxy-chart-dialog{--roxy-surface:var(--roxy-bg);width:calc(100% - 2 * var(--roxy-space-md));max-width:calc(var(--roxy-chart-expanded-width,60rem) * 1.2);max-height:calc(100% - 2 * var(--roxy-space-md));padding:var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);color:var(--roxy-fg);background:var(--roxy-bg);box-shadow:var(--roxy-shadow-lg);margin:auto}.roxy-chart-dialog[open]{flex-direction:column;display:flex;overflow:hidden}.roxy-chart-dialog::backdrop{background:color-mix(in oklab, var(--roxy-bg) 85%, transparent)}.roxy-chart-bar{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);margin-bottom:var(--roxy-space-md);flex-wrap:wrap;flex-shrink:0;display:flex}.roxy-chart-bar>strong{overflow-wrap:anywhere;min-width:0}.roxy-chart-scroll{overscroll-behavior:contain;flex:auto;min-height:0;overflow:auto}.roxy-chart-expanded{width:max(100%, calc(var(--roxy-chart-expanded-width,60rem) * var(--chart-zoom)));padding:var(--roxy-space-sm)}.roxy-chart-expanded>svg{width:100%;max-width:none;height:auto;margin:0}`;function Ot(n){let a=n%360;return a<0?a+360:a}function Kt(n){let a=Ot(n),e=Math.floor(a/30)%12,t=a%30,r=Math.floor(t),s=(t-r)*60,i=Math.floor(s),o=Math.round((s-i)*60);return{sign:Ie[e]??"Aries",signIndex:e,degree:r,minute:i,second:o}}function lt(n,a){let{sign:e,degree:t,minute:r}=Kt(n);return`${t}\xB0 ${a||e} ${String(r).padStart(2,"0")}'`}function Vt(n){return Jt(Ot(n)%30)}function Ii(n){let a=Math.floor(n);return{degree:a,minute:Math.floor((n-a)*60)}}function Jt(n){let{degree:a,minute:e}=Ii(n);return`${a}\xB0${String(e).padStart(2,"0")}'`}function Gs(n){return Ot(n+180)}function $n(n,a){let e=Ot(n),t=Ot(a)-e;return t<0&&(t+=360),Ot(e+t/2)}function Ut(n,a,e){let t=n.filter(c=>Number.isFinite(a(c))).map(c=>{let d=Ot(a(c));return{item:c,longitude:d,displayLongitude:d}}).sort((c,d)=>c.longitude-d.longitude),r=t.length;if(r<2)return t;let s=0,i=-1;for(let c=0;c<r;c++){let d=t[(c+r-1)%r],h=(t[c].longitude-d.longitude+360)%360;h>i&&(i=h,s=c)}let o=t[s],l=o.longitude;for(let c=1;c<r;c++){let d=t[(s+c)%r],p=typeof e=="function"?e(o.item,d.item):e,h=d.longitude+(s+c>=r?360:0);l=Math.max(h,l+p),d.displayLongitude=Ot(l),o=d}return t}var oa=2;function ld(n,a){let e=n*Math.PI/180;return a.width/2*Math.abs(Math.cos(e))+a.height/2*Math.abs(Math.sin(e))}function wa(n,a,e,t){let r=n*Math.PI/180,s=(i,o)=>o>1e-9?(i+t)/o:Number.POSITIVE_INFINITY;return Math.min(s((a.width+e.width)/2,Math.abs(Math.cos(r))),s((a.height+e.height)/2,Math.abs(Math.sin(r))))}var Mm=(n,a)=>Math.abs(n.x-a.x)<(n.width+a.width)/2&&Math.abs(n.y-a.y)<(n.height+a.height)/2;function cd(n,a){let e=[],t=r=>e.reduce((s,i)=>Mm(r,i)?Math.max(s,Math.min((r.width+i.width)/2-Math.abs(r.x-i.x),(r.height+i.height)/2-Math.abs(r.y-i.y))):s,0);return[...n].map((r,s)=>({point:r,index:s})).sort((r,s)=>r.point.displayLongitude-s.point.displayLongitude).reduce((r,{point:s,index:i})=>{let o=a(s,0),l=a(s,1),c=t(o)===0||t(o)<=t(l)?0:1;return e.push(c===0?o:l),r[i]=c,r},[])}var It={minute:3.4,whole:1.85,retrograde:1.25,ink:.9};function Gt(n,a){return a>0?n/a*(180/Math.PI):0}function H(n,a,e,t){let r=t*Math.PI/180;return{x:n+e*Math.cos(r),y:a+e*Math.sin(r)}}var _m={Sun:"var(--roxy-accent)",Moon:"var(--roxy-secondary)",Mercury:"var(--roxy-info)",Venus:"var(--roxy-success)",Mars:"var(--roxy-danger)",Jupiter:"var(--roxy-warning)",Saturn:"var(--roxy-muted)",Uranus:"var(--roxy-info-fg)",Neptune:"var(--roxy-success-fg)",Pluto:"var(--roxy-danger-fg)"},dd=["var(--roxy-accent)","var(--roxy-info)","var(--roxy-success)","var(--roxy-danger)","var(--roxy-warning)","var(--roxy-secondary)","var(--roxy-info-fg)","var(--roxy-success-fg)","var(--roxy-danger-fg)","var(--roxy-accent-ink)","var(--roxy-warning-fg)","var(--roxy-primary)"];function ls(n,a=0){return _m[V(n)]??dd[a%dd.length]??"var(--roxy-accent)"}var pd="M120 170L120 171L118 171L116 171L114 171L114 170L116 170L118 170L119 170L120 170ZM21 169L19 170L18 169L17 169L16 169L17 168L19 168L20 169L21 169ZM135 168L136 168L137 169L137 170L135 170L133 171L132 171L130 171L127 171L126 171L126 170L128 170L129 170L130 169L131 168L132 168L133 168L135 168ZM59 164L60 164L61 163L61 164L60 164L58 164L57 164L58 163L59 164ZM54 163L56 164L55 164L54 164L53 163L54 163ZM81 162L82 162L83 162L84 163L83 162L82 162L81 162L79 163L78 162L80 162L81 162ZM112 161L111 162L110 162L109 163L108 162L107 162L106 162L105 162L106 161L107 161L108 161L108 160L109 159L110 159L111 160L111 161L112 161ZM121 154L120 154L119 154L119 155L118 155L117 155L117 156L118 156L117 156L116 157L115 157L114 158L115 158L115 159L116 159L117 159L117 160L118 160L118 161L119 162L119 163L119 164L118 164L117 165L116 165L114 166L113 166L112 166L110 166L109 167L108 167L106 167L104 167L103 167L105 167L106 168L105 168L104 168L102 168L102 169L103 170L105 170L107 170L109 171L110 171L112 171L114 171L117 172L118 172L120 172L121 173L122 173L123 173L125 173L126 172L128 172L130 172L133 172L135 172L137 172L138 172L139 171L142 171L144 171L146 171L148 171L150 171L151 170L150 170L150 169L148 169L146 169L144 169L144 168L145 168L146 168L148 168L149 167L150 167L151 167L152 166L154 166L155 166L156 166L158 166L159 166L160 166L161 165L162 165L163 165L164 164L165 164L164 164L164 163L165 163L166 163L167 163L168 162L169 162L170 161L171 161L171 162L173 162L173 161L174 161L176 161L177 161L178 161L179 161L180 162L181 161L182 161L183 161L184 161L185 161L186 160L187 160L188 160L190 160L191 161L192 161L192 160L193 160L195 160L196 160L197 160L198 160L199 160L200 160L201 160L202 160L203 161L204 161L205 160L206 160L207 160L208 160L209 160L210 160L211 160L212 160L213 159L214 159L215 159L216 159L217 159L218 160L219 160L220 160L220 159L221 159L222 159L223 158L224 158L225 158L226 158L227 158L228 157L229 157L230 157L231 157L232 156L233 156L234 156L235 156L236 156L237 156L237 157L238 157L239 157L240 157L241 158L242 158L243 158L244 157L245 158L246 158L247 158L248 158L249 158L250 159L250 160L249 160L248 160L248 161L249 161L248 161L248 162L249 162L250 162L251 162L252 162L252 161L253 161L253 160L254 160L256 160L257 160L258 159L259 158L260 158L261 158L262 157L263 157L264 157L265 157L266 157L267 157L268 156L269 157L270 157L271 157L272 157L273 157L274 157L275 157L276 157L277 157L278 157L279 157L280 157L281 157L282 156L283 156L284 156L285 156L286 157L287 157L288 157L289 157L290 157L291 156L292 156L293 156L294 156L295 156L296 157L297 157L299 157L300 157L301 157L302 157L303 156L304 157L305 157L306 157L307 157L308 157L309 157L310 157L311 156L312 156L313 156L314 156L315 156L315 155L316 156L317 157L319 157L320 157L321 157L322 157L323 157L324 157L325 157L326 157L326 158L327 158L328 158L329 158L330 159L331 159L333 159L334 159L335 159L336 159L337 159L338 159L339 160L340 160L341 160L342 161L343 161L344 161L345 161L346 161L347 161L348 161L349 161L351 161L351 162L350 163L349 164L348 164L347 164L346 164L346 165L345 165L344 165L344 166L343 167L344 167L344 168L345 168L347 168L347 169L345 169L344 169L342 169L341 170L340 171L341 171L342 172L344 172L345 173L347 173L349 173L349 174L352 174L353 174L356 174L358 174L360 175L360 180L0 180L0 175L1 174L3 174L4 174L6 175L7 174L10 174L11 174L13 175L16 175L18 175L22 175L25 175L29 175L31 176L34 175L37 175L33 175L30 174L29 174L26 174L27 173L27 172L25 172L25 171L23 171L26 171L28 171L29 171L31 171L33 171L34 170L33 170L32 170L30 169L28 169L27 169L25 169L24 169L23 168L22 168L22 167L23 167L25 167L26 167L27 167L29 167L30 167L31 167L32 167L34 166L34 165L35 165L36 166L37 165L38 165L40 165L41 165L42 165L44 165L45 164L46 164L48 164L49 164L50 164L52 164L53 164L55 165L56 164L57 164L59 165L60 164L61 164L63 164L64 164L65 164L66 164L67 164L68 165L69 164L70 165L71 165L72 165L74 165L75 165L77 165L78 165L79 165L80 165L79 165L79 164L77 164L77 163L76 163L77 163L78 163L80 163L81 163L82 163L82 164L84 164L85 163L86 163L88 163L89 163L90 163L91 163L92 163L93 163L94 163L95 163L96 164L97 164L99 164L99 163L100 163L101 164L102 163L103 164L104 164L105 164L106 164L107 163L108 163L110 163L111 163L112 163L113 162L112 161L112 160L111 160L112 159L113 158L112 158L112 157L113 157L114 156L115 156L116 155L117 155L118 155L119 154L120 154L121 154L121 153L122 153L123 154L122 154L121 154ZM112 144L114 144L115 145L114 145L113 145L112 146L111 145L110 145L109 145L108 144L107 144L105 143L106 143L108 144L109 144L110 143L111 143L112 143L112 144ZM121 141L122 142L121 142L120 142L119 142L120 141L121 142L121 141ZM250 140L249 140L249 139L250 139L251 139L250 140ZM325 131L326 131L327 131L328 131L328 132L328 133L327 134L326 134L325 133L325 132L325 131ZM353 131L354 131L354 132L353 133L353 134L352 134L351 134L351 135L351 136L350 136L349 137L348 137L348 136L347 136L347 135L348 134L349 134L350 134L351 133L352 132L352 131L353 130L353 131ZM355 126L355 127L356 127L356 128L357 128L358 128L359 128L358 129L357 129L357 130L357 131L356 131L355 132L355 131L355 130L354 130L354 129L355 129L355 128L355 127L354 127L354 126L353 125L353 124L354 125L355 126ZM347 112L346 112L345 112L345 111L344 110L345 110L345 111L346 111L347 112ZM358 107L359 108L358 108L357 108L358 107L358 108L358 107ZM359 107L359 106L360 106L360 107L359 107ZM230 104L230 105L230 106L230 105L230 106L230 107L229 107L229 108L229 109L229 110L228 112L228 114L227 115L226 115L225 116L225 115L224 115L224 114L223 113L223 112L223 111L224 111L224 110L224 109L224 108L224 107L224 106L225 106L226 106L227 105L228 105L228 104L229 103L229 102L230 102L230 103L230 104ZM324 104L324 105L325 104L325 105L325 106L326 107L326 108L326 109L327 109L328 110L329 110L329 111L330 112L330 113L331 112L331 113L332 114L333 115L333 116L333 117L334 118L334 119L333 119L333 120L333 121L333 122L332 123L331 124L331 125L330 126L330 127L329 128L328 128L327 128L327 129L326 129L325 129L325 128L324 128L324 129L323 129L322 128L321 128L320 127L320 126L319 126L318 126L318 125L318 124L318 125L317 125L318 124L318 123L317 124L316 124L316 125L315 124L315 123L314 123L313 122L312 122L311 121L310 122L308 122L307 122L306 122L305 123L304 123L304 124L303 124L302 124L301 124L300 124L299 125L299 124L299 125L298 125L297 125L296 124L295 124L296 123L296 122L295 121L295 120L295 119L294 118L294 117L293 117L293 116L294 117L293 116L294 116L294 115L293 114L294 114L294 113L294 112L294 113L295 112L295 111L296 111L297 111L298 110L299 110L300 110L301 110L301 109L302 109L302 108L302 107L303 106L303 107L304 107L304 106L305 105L306 105L306 104L307 104L308 104L308 105L309 105L310 105L309 104L310 104L310 103L311 103L311 102L312 102L313 102L312 101L313 101L314 102L315 102L316 102L317 102L317 103L316 103L316 104L315 105L316 105L316 106L317 106L318 106L318 107L319 107L320 108L321 107L321 106L322 105L322 104L322 103L322 102L322 101L323 101L323 102L324 103L324 104ZM301 100L300 100L299 100L300 99L300 100L301 100ZM341 100L340 100L340 99L341 100ZM342 100L341 99L341 98L341 99L342 100ZM304 100L303 100L304 100L304 99L305 99L306 98L307 98L307 99L306 99L305 99L304 100ZM298 98L299 98L299 99L298 99L297 99L297 98L298 98ZM303 98L303 99L301 99L300 99L300 98L301 98L301 99L302 98L303 98ZM340 98L340 99L339 98L338 97L339 98L340 98ZM289 97L291 97L291 96L293 97L293 98L294 98L296 98L295 99L293 98L292 98L291 98L289 98L288 98L286 97L285 97L286 96L287 96L288 96L289 97ZM315 96L314 97L314 96L314 95L315 96ZM336 97L335 97L335 96L335 95L335 96L336 96L336 97ZM332 95L331 96L330 96L329 96L328 96L328 95L329 96L330 96L330 95L330 96L331 95L332 95L332 94L332 95ZM307 93L307 94L306 94L306 93L307 93ZM310 93L311 94L310 93L309 93L308 93L309 93L310 93ZM333 94L333 95L333 94L332 94L332 93L331 93L332 93L333 94ZM314 91L314 93L315 93L316 92L317 92L318 92L319 92L320 92L321 93L323 93L325 94L326 95L328 96L328 97L327 97L328 98L329 99L329 100L330 100L331 100L331 101L330 101L330 100L329 100L328 100L327 99L326 98L325 98L324 98L323 98L323 99L322 99L321 99L320 98L319 98L318 98L319 97L318 96L318 95L316 95L315 94L314 94L313 94L313 93L312 93L313 92L314 92L312 92L311 91L312 91L312 90L314 91ZM305 89L304 90L303 90L301 90L300 90L300 91L301 91L303 91L302 92L302 93L302 94L303 95L303 96L302 95L303 94L302 95L301 95L302 94L301 94L301 93L300 93L300 94L300 96L299 95L300 94L299 93L299 92L299 91L300 90L300 89L301 89L302 89L303 89L304 89L305 88L305 89ZM309 89L309 90L308 90L308 91L308 90L307 89L308 88L309 88L309 89ZM286 96L285 96L284 95L283 94L282 94L281 93L281 92L280 91L279 90L279 89L279 88L278 88L277 87L276 86L275 85L276 85L277 85L278 86L279 86L280 87L281 88L282 88L282 89L283 89L284 90L283 91L284 91L285 92L286 92L286 93L286 94L286 96ZM298 88L299 89L298 89L297 90L298 91L297 91L297 92L296 94L295 94L294 93L293 93L292 93L291 93L290 93L290 92L290 91L289 90L289 89L290 88L291 88L291 87L292 87L293 87L294 86L294 85L295 85L296 84L297 83L298 84L299 85L298 85L299 86L298 86L297 87L298 88ZM306 82L307 83L306 84L306 83L305 83L306 84L305 84L304 84L304 83L304 82L303 83L302 83L302 82L303 82L303 81L304 82L305 81L305 80L306 81L306 82ZM261 84L260 84L260 83L260 82L260 80L261 81L262 82L262 84L261 84ZM304 80L303 81L302 80L303 80L303 79L303 80L304 79L304 80ZM299 81L297 82L298 81L298 80L299 80L300 79L299 80L299 81ZM302 78L303 78L303 79L302 80L302 79L302 78ZM306 78L306 79L305 79L305 80L305 79L304 79L305 79L305 78L304 77L305 77L306 78ZM302 77L301 78L301 77L300 77L301 77L302 77ZM301 71L302 72L303 73L302 74L302 75L302 76L303 76L304 76L304 77L303 77L303 76L303 77L302 76L301 76L301 75L301 76L300 75L300 74L300 72L301 71ZM114 72L113 72L113 71L114 71L114 72ZM103 72L102 72L102 71L102 72L103 72L104 72L103 72ZM107 70L108 70L109 70L110 70L110 71L111 71L112 71L111 72L110 72L109 72L108 72L107 72L106 72L106 71L107 71L107 72L108 71L107 71L107 70ZM290 71L289 72L289 71L289 70L290 70L291 70L291 71L290 71ZM24 71L24 70L25 70L25 71L24 71ZM100 67L101 68L102 67L102 68L103 68L103 69L104 69L105 69L106 70L105 70L104 70L102 70L103 70L103 69L102 69L101 68L100 68L99 68L98 68L98 67L97 67L97 68L96 68L95 68L96 68L96 67L97 67L98 67L99 67L100 67ZM102 66L102 65L102 66ZM301 67L301 68L300 67L300 66L301 65L302 65L302 66L301 67ZM315 56L314 57L314 56L313 57L312 57L313 56L314 56L315 56ZM215 54L214 55L213 55L212 55L213 55L214 55L215 54ZM204 54L204 55L205 55L206 55L205 55L204 55L204 54ZM196 52L195 53L194 53L192 52L193 52L194 52L195 52L196 52ZM189 49L190 49L190 51L189 51L188 51L188 50L188 49L189 49ZM321 53L321 54L320 55L319 55L317 55L316 57L315 56L315 55L313 56L312 56L311 56L312 57L311 59L310 59L310 58L310 57L309 57L310 56L311 56L312 55L313 55L315 54L316 54L317 53L319 52L320 51L320 49L321 49L322 50L322 51L321 52L321 53ZM190 48L189 49L189 48L189 47L190 48ZM324 46L325 46L326 47L324 47L323 48L322 47L321 48L320 48L320 47L321 47L322 45L322 44L323 45L324 46ZM116 43L117 44L118 44L117 44L116 44L116 43ZM118 41L116 41L115 40L116 40L117 40L118 41ZM56 41L56 42L54 41L53 40L52 40L52 39L53 39L53 40L54 40L55 40L55 41L56 41ZM124 39L123 40L124 40L125 40L124 40L125 41L126 40L127 41L126 41L127 41L127 42L127 43L126 43L126 42L125 43L124 43L125 43L124 42L123 42L121 42L121 41L122 41L123 39L124 38L125 38L124 39ZM47 36L48 36L48 37L49 38L48 38L48 37L47 37L47 36ZM324 39L325 41L323 41L323 42L324 43L324 44L323 43L322 44L322 43L322 42L322 41L322 40L322 39L322 38L322 37L323 36L322 36L323 36L323 37L323 38L324 39ZM173 38L171 38L170 38L171 37L170 36L172 35L173 35L174 35L174 36L174 37L173 38ZM193 34L192 35L191 35L191 34L192 34L193 34ZM27 33L26 33L25 33L26 32L27 32L28 32L27 33ZM177 31L176 32L177 32L178 32L178 33L177 34L178 34L179 35L180 36L180 37L182 37L182 38L181 38L181 39L179 39L178 39L177 39L176 40L175 40L174 40L176 39L177 39L175 38L176 38L175 37L177 37L177 36L176 35L175 35L175 34L174 35L174 34L174 33L174 32L175 31L176 31L177 31ZM14 30L13 30L14 30ZM98 27L97 28L96 28L97 27L98 27ZM8 26L9 26L10 26L10 27L11 27L10 27L9 27L8 27L8 26ZM95 24L95 25L96 25L97 25L98 26L99 26L100 26L99 27L97 26L96 26L94 27L94 26L93 26L94 26L94 25L94 24L95 24ZM165 24L166 25L165 26L162 26L161 27L160 26L157 26L158 26L156 25L158 25L156 24L158 24L159 24L161 24L162 24L164 23L165 24ZM104 23L103 23L103 22L104 22L105 22L105 23L104 23ZM5 23L6 24L5 23L8 23L10 24L9 24L7 25L7 26L6 26L5 25L4 25L3 24L2 25L1 24L0 24L1 25L0 25L0 21L2 22L5 23ZM84 21L82 21L80 21L81 20L82 20L83 20L84 21ZM360 19L359 19L360 18L360 19ZM1 19L0 19L0 18L1 18L2 19L1 19ZM89 21L89 22L91 21L92 21L92 22L93 23L94 22L94 21L94 20L96 20L97 20L99 21L98 22L99 22L99 23L97 24L95 24L94 23L94 24L93 25L92 26L90 26L89 26L89 27L88 27L87 28L86 29L85 30L85 31L87 31L87 32L88 33L89 33L91 33L92 34L93 34L94 34L95 35L97 35L98 35L98 36L98 37L99 38L100 39L101 38L101 37L101 36L100 35L102 35L103 34L103 33L103 32L101 31L103 30L102 29L102 28L103 27L104 28L105 28L106 28L107 28L108 28L109 29L110 29L110 30L111 31L112 31L112 32L114 31L115 30L116 31L117 32L119 33L118 34L120 34L120 35L122 35L123 35L123 36L124 36L124 37L124 38L123 39L121 39L120 40L118 40L116 40L115 40L114 40L113 40L111 41L110 42L109 43L110 43L111 42L113 41L115 41L116 41L115 42L115 43L116 44L117 44L118 44L119 43L120 44L119 45L117 45L116 46L115 46L114 46L116 45L114 45L113 45L112 46L111 46L110 46L109 47L109 48L110 48L109 49L108 49L107 49L106 49L108 49L107 49L106 49L106 50L105 51L104 51L105 51L105 52L104 53L104 52L104 51L103 51L104 52L103 52L104 52L104 53L104 54L104 55L103 55L102 56L101 56L101 57L100 57L99 58L99 59L99 60L99 61L99 62L100 63L100 64L100 65L99 65L99 64L98 64L98 63L97 63L97 62L97 61L96 60L95 60L94 60L92 60L91 60L90 60L91 60L91 61L90 61L89 61L88 60L87 60L86 60L85 61L84 61L83 62L83 63L83 64L82 65L82 66L82 67L82 68L83 69L83 70L84 71L85 71L86 72L87 71L88 71L89 71L89 70L90 69L91 69L92 69L93 68L93 69L93 70L92 70L93 71L92 71L92 72L92 71L92 72L92 73L91 74L92 74L93 74L94 74L95 74L96 74L96 75L97 75L97 76L96 76L96 77L97 77L97 78L96 78L96 79L97 80L98 81L99 81L100 81L100 80L101 80L101 81L102 81L103 81L104 81L104 80L105 79L106 79L107 79L107 78L108 78L109 78L108 79L108 80L108 81L109 81L109 80L109 79L110 79L110 78L110 79L111 79L112 79L113 79L114 79L114 80L115 80L116 80L116 79L117 79L118 79L117 80L118 80L119 81L120 81L120 82L121 82L122 83L122 84L123 84L124 84L125 84L126 84L127 85L128 85L128 86L129 86L129 88L130 88L130 89L129 90L130 90L131 90L131 91L132 91L133 91L135 92L136 92L135 93L137 92L139 93L140 93L141 94L143 95L144 95L145 95L145 97L145 99L144 100L143 101L142 102L142 103L141 103L141 104L141 106L141 107L141 108L140 108L140 110L139 111L139 112L138 112L138 113L137 113L135 113L135 114L134 114L132 115L132 116L131 117L132 117L131 118L131 119L130 119L129 121L128 122L127 123L127 124L126 124L125 125L124 125L123 124L122 124L123 125L123 126L123 127L122 128L121 129L119 129L118 129L118 130L118 131L117 131L116 131L115 131L115 132L116 132L117 133L116 133L115 133L115 135L114 135L113 135L113 136L112 136L113 137L114 137L114 138L113 139L112 140L111 140L111 141L111 142L112 142L111 142L110 143L109 143L109 144L107 144L106 143L105 142L105 141L105 140L104 139L105 138L106 137L104 137L105 136L106 134L107 134L107 132L106 133L106 132L106 130L107 129L106 128L106 127L107 127L107 126L108 124L109 122L108 121L109 120L109 119L109 118L109 116L110 114L110 111L110 110L110 108L109 108L109 107L107 106L105 105L104 105L104 104L103 102L102 100L101 98L100 97L99 97L99 96L99 95L99 94L100 93L100 92L100 93L99 92L99 91L100 90L100 89L101 89L101 88L102 87L103 86L103 85L102 84L103 84L103 83L102 83L102 82L101 81L100 81L100 82L100 83L99 83L99 82L98 82L97 82L96 82L96 81L95 80L94 80L94 79L93 78L92 77L93 77L92 77L91 77L90 76L89 76L88 76L88 75L87 74L86 74L85 74L84 74L83 74L82 74L81 73L80 73L79 73L78 72L76 72L76 71L75 71L75 70L74 70L75 69L74 69L75 69L74 68L74 67L73 66L72 65L71 64L70 63L69 62L68 62L68 61L67 60L67 59L66 58L65 58L65 59L65 60L66 60L66 61L67 61L67 62L68 62L68 63L69 64L69 65L69 66L70 66L71 67L70 67L69 66L68 66L68 65L68 64L67 64L67 63L66 63L65 62L66 62L66 61L65 61L64 60L64 59L63 58L63 57L62 56L61 56L60 56L59 55L58 54L57 52L56 51L56 50L56 49L56 48L55 47L56 46L56 44L56 43L56 42L55 42L57 42L57 43L58 43L58 42L57 41L55 40L54 40L53 39L52 38L51 37L51 36L49 36L49 35L48 35L48 34L46 33L46 32L45 32L43 32L42 31L40 30L39 30L37 30L36 30L34 30L33 29L32 29L32 30L31 30L30 30L29 31L28 31L28 30L29 29L30 29L29 29L28 29L27 30L26 31L27 31L26 32L25 32L24 33L23 33L22 34L20 34L19 35L18 35L17 35L15 36L15 35L16 35L17 35L18 34L19 34L20 34L21 33L22 33L22 32L23 31L22 31L21 31L21 32L20 31L19 31L18 31L18 30L17 30L16 30L15 30L15 29L14 28L15 27L16 27L17 27L18 26L18 27L19 26L18 26L19 25L18 25L17 26L16 25L15 26L14 25L13 25L12 24L13 24L16 23L16 24L18 24L18 23L16 23L16 22L15 22L13 22L14 21L16 21L17 21L17 20L18 20L19 20L21 19L22 19L23 19L25 19L26 19L28 19L29 20L30 19L32 20L34 20L35 20L36 20L38 20L39 20L41 21L42 21L43 21L44 21L46 20L47 20L49 20L50 20L51 20L52 20L53 20L54 21L56 20L56 21L57 20L59 20L60 21L62 21L64 21L65 21L66 22L65 22L67 22L69 22L70 22L71 23L72 22L71 22L72 21L73 21L74 21L75 21L76 22L77 22L79 22L80 22L82 22L81 22L82 21L84 22L84 23L85 22L86 21L85 20L84 20L84 19L85 18L86 18L87 19L88 20L89 21ZM66 17L65 17L68 17L69 18L70 17L71 17L72 18L72 17L73 17L75 17L75 18L76 19L77 20L79 20L77 20L78 21L76 21L74 21L73 21L71 21L68 21L67 21L66 21L65 21L64 21L63 20L65 20L66 20L68 20L66 19L64 19L62 19L64 19L62 19L61 18L62 17L65 17L66 17ZM76 17L75 17L73 17L73 16L75 16L76 17ZM104 17L103 17L102 17L101 17L100 17L99 17L99 16L100 16L102 16L104 17ZM93 17L94 17L95 17L98 16L99 17L99 18L101 18L102 17L104 18L106 18L106 19L108 18L109 19L111 19L112 20L113 21L111 21L114 22L115 22L117 23L118 23L118 24L116 25L115 25L113 24L112 24L113 25L114 25L115 26L115 27L114 27L111 26L113 27L114 28L111 28L109 27L108 27L108 26L107 26L105 25L105 26L102 26L101 25L102 25L104 25L106 25L106 24L107 23L107 22L105 21L103 21L104 21L103 20L102 20L101 20L99 20L95 20L93 20L91 20L90 19L92 19L90 19L90 18L91 17L92 16L94 16L93 17ZM80 16L81 16L83 16L83 17L82 17L83 17L83 18L82 19L81 19L80 18L78 17L80 17L78 17L80 16ZM324 17L322 17L320 17L321 16L322 16L323 17L324 17ZM87 17L86 18L85 18L84 17L85 16L88 16L89 16L88 17L87 17ZM60 19L57 19L56 19L54 18L55 17L56 16L55 16L58 16L60 16L62 16L63 16L64 17L63 17L61 17L60 18L60 19ZM331 15L330 15L328 15L326 15L328 15L331 15ZM86 15L84 15L83 15L84 15L85 14L86 15ZM325 14L324 15L321 15L319 15L317 15L318 14L319 14L321 14L325 14ZM82 13L82 14L82 15L80 15L79 15L79 14L77 14L79 14L80 13L81 13L82 13ZM72 14L73 14L74 14L74 15L70 15L68 16L66 16L66 15L68 15L64 15L62 15L64 14L65 14L67 14L69 14L71 15L70 14L70 13L71 13L72 14ZM238 19L237 19L234 19L233 19L232 19L231 18L232 18L232 17L234 16L236 15L238 14L241 14L244 14L246 13L248 13L249 13L248 14L245 14L242 15L238 16L237 17L235 18L236 18L238 19ZM85 13L86 13L88 13L89 14L90 14L91 14L92 14L94 15L95 14L97 14L99 14L100 15L98 16L97 15L94 16L92 16L90 15L88 15L87 15L87 14L86 14L84 14L83 13L85 13ZM64 12L64 13L63 13L62 14L60 14L59 14L57 14L59 13L61 12L62 13L64 12ZM287 13L287 14L288 13L291 13L293 14L294 14L294 15L293 15L290 16L289 16L291 16L292 16L293 16L294 17L294 16L296 16L299 16L299 17L303 17L303 16L305 16L307 16L309 17L309 18L308 18L310 19L311 19L312 18L314 19L316 18L317 19L318 18L320 19L319 18L320 17L330 18L333 19L337 19L339 19L340 20L341 21L342 20L344 20L346 21L348 20L350 21L351 21L350 20L354 20L356 20L359 21L360 21L360 25L359 25L357 25L358 26L359 27L359 28L357 27L355 28L354 28L352 29L351 30L350 30L349 29L346 30L345 30L344 30L343 31L342 32L343 32L343 34L342 34L342 35L340 36L340 37L339 37L338 38L337 39L336 38L336 37L335 35L336 33L337 33L337 32L338 32L340 31L342 30L344 29L344 27L343 28L340 29L339 28L337 29L334 30L335 31L333 31L331 31L331 30L330 30L329 31L325 31L322 31L319 33L315 35L317 35L317 36L318 36L319 36L320 36L321 37L321 38L321 39L321 40L320 42L319 43L318 44L317 45L316 46L315 47L314 47L313 47L312 47L311 47L311 48L310 48L310 49L309 49L309 50L308 50L308 51L307 51L308 51L309 53L309 54L309 55L308 55L307 56L306 56L306 55L307 54L306 53L307 53L306 52L305 52L305 51L305 50L304 50L303 50L302 51L301 51L302 51L301 50L302 50L302 49L301 49L300 50L299 51L298 51L298 52L299 52L299 53L300 53L301 52L302 53L303 53L301 53L301 54L300 54L299 55L300 56L301 57L301 58L302 58L302 59L301 59L302 60L302 61L302 62L301 62L300 63L300 64L299 65L297 66L296 67L295 67L294 68L294 67L293 68L292 68L291 69L290 70L290 69L289 68L288 68L287 69L286 70L286 71L286 72L287 73L288 74L289 75L289 77L289 78L288 79L287 80L286 80L285 81L285 80L284 80L283 79L283 78L282 77L281 77L280 77L280 78L279 79L279 80L279 81L280 81L280 82L280 83L281 83L282 83L282 84L283 84L283 85L283 86L283 87L284 87L284 88L284 89L283 88L281 87L281 86L281 85L280 85L280 84L280 83L279 82L278 82L278 81L279 80L278 79L279 79L278 78L279 77L278 76L278 75L278 74L277 73L277 74L275 74L274 74L275 73L274 72L274 71L274 70L273 70L272 69L272 68L271 67L270 67L271 68L270 68L269 68L268 68L267 69L266 70L265 71L264 72L263 72L262 73L262 74L261 74L260 74L260 75L260 76L260 77L260 78L260 80L259 80L259 81L258 81L258 82L257 81L256 80L256 79L255 78L255 77L255 76L254 75L254 74L253 72L253 71L253 70L253 69L251 69L250 69L249 68L250 68L249 67L248 66L247 66L247 65L246 65L245 65L243 65L241 65L240 65L239 64L237 64L237 63L236 63L235 64L233 63L232 62L231 61L230 60L229 60L228 60L228 61L229 62L229 63L230 63L230 64L231 65L231 64L232 64L232 65L231 65L232 66L233 66L234 66L235 65L236 64L236 65L237 66L238 66L239 66L239 67L240 67L240 68L239 68L239 69L238 70L238 71L237 71L237 72L236 72L235 72L235 73L234 73L233 73L232 74L231 75L230 75L229 76L228 76L227 76L227 77L226 77L225 77L224 77L223 77L223 76L223 75L223 74L223 73L222 73L222 72L221 71L220 70L219 69L219 68L219 67L218 66L217 66L217 65L217 64L216 63L215 62L215 61L215 60L215 61L214 62L213 62L212 60L213 61L213 62L214 64L215 65L216 66L215 66L216 67L217 68L217 69L217 70L217 71L218 72L219 73L219 74L220 75L221 76L222 76L222 77L223 77L223 78L223 79L224 79L224 80L225 80L226 79L227 79L228 79L229 79L230 78L231 78L231 79L231 80L231 81L230 82L229 83L229 85L228 86L227 87L226 88L224 89L223 90L222 91L222 92L221 92L220 93L220 94L219 95L219 96L219 97L219 98L220 99L220 100L220 101L220 102L221 103L221 104L221 105L220 105L220 106L219 107L217 108L216 109L215 110L215 111L215 112L216 112L216 113L215 114L216 114L215 114L214 115L213 115L213 116L213 117L212 118L212 119L211 119L211 120L210 121L209 122L208 123L207 123L206 124L205 124L204 124L203 124L202 124L201 124L200 125L199 124L198 124L198 123L198 122L198 121L197 120L196 119L196 118L195 117L195 116L195 115L194 114L194 113L194 112L193 111L193 110L193 109L192 108L192 107L192 106L192 105L192 104L193 104L193 103L193 102L194 102L194 101L193 100L193 99L193 98L193 97L192 96L192 95L191 94L190 93L189 92L189 91L189 90L189 89L190 88L190 87L189 86L188 86L189 85L187 86L186 86L185 85L185 84L184 84L183 84L182 84L181 84L179 85L178 85L177 85L176 85L175 85L174 85L173 85L172 86L171 85L170 84L169 84L169 83L168 83L167 82L167 81L166 81L166 80L165 80L165 79L164 79L164 78L163 78L163 77L163 76L162 75L163 75L163 74L164 74L163 73L164 73L164 72L164 71L164 70L163 69L163 68L164 67L164 66L165 66L165 65L165 64L166 64L166 63L167 62L168 62L169 61L170 61L170 60L170 59L171 58L171 57L172 56L173 56L174 55L174 54L175 54L175 55L176 55L177 55L178 55L179 54L180 54L181 54L181 53L183 53L185 53L186 53L187 53L188 53L190 53L191 53L191 54L191 55L190 56L191 56L191 57L193 57L194 57L195 58L196 59L197 59L198 59L199 60L200 59L200 58L201 57L202 57L203 57L203 58L204 58L205 58L206 58L207 59L208 59L209 59L210 59L211 58L212 59L213 59L214 59L215 58L214 58L215 58L215 57L215 56L216 55L216 54L216 53L215 53L214 54L213 54L212 53L211 53L210 54L209 53L208 53L207 52L206 52L207 51L206 51L207 50L209 50L209 49L211 49L212 48L214 48L215 48L217 49L218 49L220 49L222 48L221 47L220 47L219 46L218 45L217 45L218 44L218 43L219 43L218 43L217 43L216 43L215 44L216 45L217 45L216 45L215 45L214 46L213 45L214 45L212 45L213 44L214 44L213 44L212 44L212 43L211 43L210 44L210 45L209 45L209 46L208 47L208 48L209 49L208 49L207 49L206 50L206 49L205 49L204 49L204 50L203 50L203 51L204 51L204 52L203 52L203 53L203 54L202 54L202 53L201 52L201 51L200 51L200 50L199 50L199 49L200 48L199 48L198 48L198 47L197 47L196 46L195 46L195 45L194 45L194 44L193 44L192 45L193 46L194 46L194 47L195 48L196 48L197 49L198 49L198 50L197 50L196 50L197 51L196 52L196 51L196 50L195 50L195 49L194 49L193 49L192 48L191 48L191 47L190 46L189 46L188 46L187 46L187 47L185 47L183 47L183 48L182 49L181 49L180 50L180 51L180 52L179 52L179 53L178 53L177 53L176 53L175 54L174 54L173 53L172 53L171 53L171 52L170 51L171 51L171 50L171 49L171 48L171 47L172 46L173 46L175 46L176 47L178 47L179 46L179 44L178 43L177 42L176 42L175 41L177 41L178 41L178 40L179 41L181 40L182 39L183 39L184 38L185 37L186 36L187 37L187 36L188 36L189 36L189 35L188 34L188 33L189 33L190 33L191 32L191 33L190 33L191 34L190 34L190 35L191 36L192 36L193 36L194 36L195 36L196 35L198 35L199 35L199 36L200 36L200 35L201 35L201 34L201 33L202 33L203 32L203 33L204 33L204 32L203 31L205 31L206 30L207 31L208 31L209 30L208 29L206 30L204 30L203 30L202 30L201 29L202 28L201 27L202 27L202 26L205 25L205 24L204 24L202 24L201 25L201 26L200 26L198 27L197 29L198 29L199 30L198 31L197 31L196 33L196 34L195 34L194 35L193 35L193 34L192 33L191 31L190 31L188 32L187 32L186 31L185 30L185 28L186 27L189 27L191 26L192 24L195 22L196 21L199 20L201 20L203 20L205 19L206 19L208 19L211 20L210 20L211 20L212 20L214 21L217 21L220 22L221 23L220 24L218 24L214 23L213 23L215 24L215 26L216 26L217 26L217 25L220 25L222 24L223 24L224 24L225 23L224 23L224 22L223 21L226 22L227 22L226 22L226 23L228 23L228 22L230 22L234 21L233 22L235 22L237 22L239 21L240 22L241 21L240 20L241 20L244 20L245 21L249 22L249 21L248 21L247 21L247 20L247 19L249 18L249 17L250 17L253 17L253 18L252 19L253 20L253 21L254 22L253 22L251 24L252 24L253 23L254 23L255 22L254 22L255 21L254 21L254 20L254 19L253 19L255 18L255 17L256 18L255 19L256 19L256 18L258 18L260 18L262 18L261 17L261 16L262 16L265 16L267 16L266 16L267 15L268 15L270 14L273 14L276 14L277 14L279 14L281 14L281 13L282 13L284 12L286 13L285 13L287 13ZM229 49L230 49L230 50L229 51L229 52L230 53L231 53L232 53L234 53L234 52L234 51L233 51L233 50L233 49L234 49L235 49L234 48L233 48L233 49L233 48L232 48L233 48L233 47L231 47L231 46L230 46L230 45L231 45L232 45L233 45L233 44L233 43L232 43L231 43L230 43L229 44L228 44L227 45L228 46L227 47L229 48L229 49ZM86 12L86 13L84 12L86 12ZM70 12L68 13L66 12L67 12L69 12L70 12ZM205 12L202 13L201 12L203 12L205 12ZM70 11L69 12L67 12L67 11L68 11L69 11L70 11ZM84 12L83 12L82 12L81 12L81 11L83 11L84 12ZM80 12L79 12L77 12L75 12L76 11L75 11L76 11L79 11L80 12ZM285 12L279 12L281 11L282 11L283 11L285 11L285 12ZM198 10L202 11L199 11L198 12L197 13L196 13L194 13L195 12L193 12L191 11L190 10L193 10L194 10L195 10L196 10L197 10L198 10ZM205 10L207 10L206 10L203 11L200 10L198 10L197 10L200 9L202 10L203 9L205 10ZM231 9L230 10L229 10L228 10L227 10L227 9L225 9L227 9L228 9L229 9L230 9L232 9L231 9ZM280 11L278 11L275 11L273 11L273 10L271 10L274 9L276 9L278 9L280 10L280 11ZM93 10L94 11L93 11L91 12L89 12L87 12L86 11L87 11L85 11L84 10L83 10L84 9L85 9L86 9L85 9L88 9L89 9L91 9L92 10L93 10ZM112 7L114 7L116 7L118 7L118 8L116 8L113 8L112 8L115 8L112 9L111 9L109 10L107 10L106 11L103 11L104 11L105 11L104 12L102 12L100 13L102 13L99 14L97 14L94 14L92 14L91 14L90 13L92 13L92 12L95 12L94 12L92 12L93 11L95 11L93 10L96 10L97 10L98 10L96 9L92 9L91 9L90 9L89 8L88 8L90 8L91 8L93 8L95 7L96 7L97 8L98 7L99 7L101 7L104 7L107 7L109 7L112 7ZM153 6L159 7L157 8L153 8L148 8L149 8L152 8L155 8L157 8L158 8L157 9L159 8L164 8L167 8L168 9L164 9L163 10L160 10L162 10L161 11L160 11L160 12L162 13L160 13L158 13L160 14L160 15L159 15L161 16L158 16L160 16L159 17L158 17L156 17L158 17L158 18L156 17L155 18L157 18L158 19L156 20L156 19L154 19L155 19L154 20L156 20L158 20L155 21L152 22L149 22L148 22L147 22L146 23L144 24L143 24L142 24L140 25L139 25L139 26L139 27L137 27L138 28L137 29L137 30L135 30L134 29L132 29L131 29L130 28L128 26L128 25L126 24L127 23L126 23L127 22L129 21L129 20L128 20L127 21L125 20L126 19L127 19L129 19L127 19L126 18L125 19L124 18L125 17L124 16L123 15L121 15L121 14L119 14L117 14L114 14L111 14L110 14L109 13L111 13L113 13L109 12L107 12L111 11L114 11L115 10L112 10L113 9L116 9L118 9L117 8L120 8L123 8L126 8L127 8L130 8L132 8L133 8L135 8L133 8L133 7L137 7L140 7L141 6L145 6L153 6Z";var wn=360,Ds=180,As=n=>n+180,Ps=n=>90-n,Nm=9,hd=23.44,md=66.56,gd=n=>n===0?"0":`${Math.abs(n)}\xB0${n>0?"E":"W"}`,yd=n=>n===0?"0":`${Math.abs(n)}\xB0${n>0?"N":"S"}`;function zm(n){let a=[],e=[],t=null;for(let r of n)t!==null&&Math.abs(r.longitude-t)>180&&(e.length&&a.push(e),e=[]),e.push(`${As(r.longitude)},${Ps(r.latitude)}`),t=r.longitude;return e.length&&a.push(e),a.filter(r=>r.length>1).map(r=>r.join(" "))}var ud={mc:"MC",ic:"IC",ascendant:"ASC",descendant:"DSC"},sr=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this)}updated(){for(let e of this.renderRoot.querySelectorAll('svg[part="chart"]')){if(typeof e.getBBox!="function")continue;let{x:t,y:r,width:s,height:i}=e.getBBox();e.setAttribute("viewBox",[t-1,r-1,s+2,i+2].join(" "))}}renderData(e){let t=e.lines??[],r=e.birthDetails;return fe.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Astrocartography")}</h2>${r?fe.html`<p class="roxy-label">${ue(this.effectiveLang(),r.date,r.time)} · ${yd(Math.round(r.latitude))} ${gd(Math.round(r.longitude))}</p>`:fe.nothing}</header>${this.chartViewport.renderChartViewport(this.renderMap(t,r),this.t("Astrocartography"),this.translator)} ${this.renderLegend(t)} ${e.summary&&!this.hideReadings?fe.html`<p class="summary">${e.summary}</p>`:fe.nothing} ${this.renderInterpretations(t)}</div>`}renderMap(e,t){return fe.html`<svg viewBox="0 0 ${wn} ${Ds}" part="chart" role="img" aria-label="${this.t("World map of planetary astrocartography lines")}"><title>${this.t("Astrocartography world map")}</title><desc>${this.t("Equirectangular world map. Each body has a Midheaven and Imum Coeli meridian and a curved Ascendant and Descendant line, colored per body.")}</desc><rect class="map-frame" x="0" y="0" width="${wn}" height="${Ds}"/><path class="land" d="${pd}" fill-rule="evenodd"/>${this.renderGraticule()} ${this.renderBodyLines(e)} ${t?fe.svg`<text class="birthplace" x=${As(t.longitude)} y=${Ps(t.latitude)} text-anchor="middle" dominant-baseline="central"><title>${this.t("Birth location")}</title>★</text>`:fe.nothing}</svg>`}renderGraticule(){let e=[];for(let s=-150;s<=150;s+=30){let i=As(s),o=s===0;e.push(fe.svg`<line class=${o?"grat-axis":"grat"} x1=${i} y1="0" x2=${i} y2=${Ds} />`),e.push(fe.svg`<text class="axis-label" x=${i} y=${Ds-2} text-anchor="middle">${gd(s)}</text>`)}let t=[];for(let s=-60;s<=60;s+=30){let i=Ps(s),o=s===0;t.push(fe.svg`<line class=${o?"grat-axis":"grat"} x1="0" y1=${i} x2=${wn} y2=${i} />`),t.push(fe.svg`<text class="axis-label" x="2" y=${i-1}>${yd(s)}</text>`)}let r=[hd,-hd,md,-md].map(s=>fe.svg`<line class="grat-ref" x1="0" y1=${Ps(s)} x2=${wn} y2=${Ps(s)} />`);return fe.svg`${e}${t}${r}`}renderBodyLines(e){let t=e.map((d,p)=>{let h=y(d,"planet");return{line:d,name:h,color:ls(d.planet,p),glyph:d.symbol||S(d.planet)||h}}),r=d=>d.reduce((p,h)=>Math.abs(h.latitude)<Math.abs(p.latitude)?h:p,d[0]??{latitude:0,longitude:0}),s=d=>new Map(Ut(t,p=>d(p)+180,Nm).map(({item:p,displayLongitude:h})=>[p,h-180])),i=s(d=>d.line.mc.longitude),o=s(d=>d.line.ic.longitude),l=s(d=>r(d.line.ascendant.points??[]).longitude),c=s(d=>r(d.line.descendant.points??[]).longitude);return t.map(d=>{let{line:p,name:h,color:x,glyph:$}=d,L=C=>C.get(d)??0;return fe.svg`${[this.renderMeridian(p.mc.longitude,L(i),x,$,h,"mc",false),this.renderMeridian(p.ic.longitude,L(o),x,$,h,"ic",true),this.renderCurve(p.ascendant.points,{longitude:L(l),latitude:r(p.ascendant.points??[]).latitude},x,$,h,"ascendant",false),this.renderCurve(p.descendant.points,{longitude:L(c),latitude:r(p.descendant.points??[]).latitude},x,$,h,"descendant",true)]}`})}renderMeridian(e,t,r,s,i,o,l){let c=As(e),d=o==="ic"?Ds-16:9;return fe.svg`<g>
|
|
2
|
-
<line class=${`acg-line${l?" dashed":""}`} stroke=${r} x1=${c} y1="0" x2=${c} y2=${
|
|
3
|
-
<text class="acg-glyph" fill=${r} x=${
|
|
4
|
-
</g>`}renderCurve(e,t,r,
|
|
5
|
-
${c.map(d=>
|
|
6
|
-
<text class="acg-glyph" fill=${r} x=${
|
|
7
|
-
</g>`}renderLegend(e){return e.length===0?fe.nothing:fe.html`<div class="legend" part="legend">${e.map((t,r)=>{let s=ls(t.planet,r);return fe.html`<span class="legend-item"><span class="legend-swatch" style="${`border-block-start-color: ${s}`}"></span> ${t.symbol?fe.html`<span aria-hidden="true">${t.symbol}</span>`:fe.nothing}${y(t,"planet")}</span>`})} <span class="legend-note">${this.t("Solid lines are the Ascendant and Midheaven, dashed are the Descendant and IC.")}</span></div>`}renderInterpretations(e){return e.length===0||this.hideReadings?fe.nothing:fe.html`<section class="block" part="section readings"><h3>${this.t("Planetary lines")}</h3>${e.map((t,r)=>{let s=ls(t.planet,r),i=[["MC",t.mc.interpretation],["IC",t.ic.interpretation],["AC",t.ascendant.interpretation],["DC",t.descendant.interpretation]];return fe.html`<details class="interp-card" part="reading" name="acg-lines" ?open="${r===0}"><summary><span class="interp-lead"><span class="interp-dot" style="${`background: ${s}`}"></span> ${t.symbol?fe.html`<span aria-hidden="true">${t.symbol}</span>`:fe.nothing}${y(t,"planet")} </span>${he()}</summary><div class="interp-body">${i.filter(([,o])=>o).map(([o,l])=>fe.html`<p class="interp-line"><span class="code">${o}</span>${l}</p>`)}</div></details>`})}</section>`}};sr.endpoints=Jo,sr.styles=[u,Xe,W,me,fe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}svg{border-radius:var(--roxy-radius-sm);width:100%;height:auto;display:block}.map-frame{fill:color-mix(in srgb, var(--roxy-border) 12%, transparent);stroke:var(--roxy-border);stroke-width:.8px}.land{fill:var(--roxy-secondary);opacity:.13}.grat{stroke:var(--roxy-border);stroke-width:.4px;fill:none}.grat-axis{stroke:var(--roxy-muted);stroke-width:.6px;opacity:.6}.grat-ref{stroke:var(--roxy-secondary);stroke-width:.4px;stroke-dasharray:2 2;opacity:.5;fill:none}.axis-label{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .3125)}.acg-line{fill:none;stroke-width:1px;opacity:.95}.acg-line.dashed{stroke-dasharray:4 2.5}.acg-glyph{font-size:calc(var(--roxy-text-base) * .5);font-weight:var(--roxy-weight-bold)}.birthplace{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .5625)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.legend-item{align-items:center;gap:var(--roxy-space-xs);display:inline-flex}.legend-swatch{inline-size:var(--roxy-space-md);border-block-start:var(--roxy-line-thick) solid;block-size:0}.legend-note{width:100%}.summary,.interp-line{font-size:var(--roxy-text-sm)}.interp-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);flex-shrink:0;align-self:center}.interp-line .code{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);margin-inline-end:var(--roxy-space-xs)}`],sr=m([f("roxy-astrocartography-map")],sr);var ce=require("lit");var fd=require("lit");var Om=new Set(["wood","fire","earth","metal","water"]);function Et(n){let a=Rt(n??"");return Om.has(a)?`element-${a}`:""}var la=fd.css`.element-wood{--_element:var(--roxy-success);--_element-ink:var(--roxy-success-fg)}.element-fire{--_element:var(--roxy-danger);--_element-ink:var(--roxy-danger-fg)}.element-earth{--_element:var(--roxy-warning);--_element-ink:var(--roxy-warning-fg)}.element-metal{--_element:var(--roxy-secondary);--_element-ink:var(--roxy-secondary)}.element-water{--_element:var(--roxy-info);--_element-ink:var(--roxy-info-fg)}.element-word{color:var(--_element-ink)}`;var Im={year:"Year",month:"Month",day:"Day",hour:"Hour"},xd={harmonious:"Harmonious",challenging:"Challenging"},bd={"stem-combination":"Stem combination","six-combination":"Six combination",trine:"Trine",clash:"Clash",harm:"Harm",punishment:"Punishment","stem-clash":"Stem clash"},vd={deficient:"Deficient",balanced:"Balanced",excess:"Excess"},nr=class extends g{renderData(a){let e=this.effectiveLang(),t=ue(e,a.birthData?.date,a.birthData?.time);return ce.html`<article class="card" part="card" aria-labelledby="bazi-title"><header class="head" part="header"><h2 class="title" id="bazi-title">${this.t("Four pillars")}</h2>${t?ce.html`<span class="born">${t}</span>`:ce.nothing} ${a.zodiacAnimal?ce.html`<span class="roxy-chip animal">${y(a,"zodiacAnimal")}</span>`:ce.nothing}</header><div class="pillars-wrap" part="chart" role="region" tabindex="0" aria-label="${this.t("Four pillars")}"><div class="pillars">${(a.pillars??[]).map(r=>this.renderPillar(r))}</div></div>${this.renderDayMaster(a)} ${this.renderElements(a)} ${this.renderInteractions(a)} ${a.summary&&!this.hideReadings?ce.html`<p class="summary" part="section summary">${a.summary}</p>`:ce.nothing} ${tr(a.conventions,this.translator,this.effectiveLang())}</article>`}renderPillar(a){let e=Im[a.position],t=a.position==="day";return ce.html`<div class="pillar ${t?"pillar-self":""}" part="pillar"><span class="pos roxy-label">${e?this.t(e):D(a.position)}</span> <span class="god">${y(a.tenGod,"name")}</span> <span class="hanzi" lang="zh">${a.stem?.chinese??""}</span> <span class="romanised">${a.stem?.pinyin??""} <span class="element-word ${Et(a.stem?.element)}">${y(a.stem,"element")}</span></span> <span class="hanzi hanzi-branch" lang="zh">${a.branch?.chinese??""}</span> <span class="romanised">${a.branch?.pinyin??""} ${y(a.branch,"animal")}</span> ${a.hiddenStems?.length?ce.html`<hr class="rule"><ul class="hidden" aria-label="${this.t("Hidden stems")}">${a.hiddenStems.map(r=>ce.html`<li><span lang="zh">${r.stem?.chinese??""}</span> <span class="role">${r.role}</span> ${y(r.tenGod,"name")}</li>`)}</ul>`:ce.nothing} ${a.naYin?ce.html`<hr class="rule"><span class="nayin" title="${this.t("Na Yin")}">${a.naYin}</span>`:ce.nothing}</div>`}renderDayMaster(a){let e=a.dayMaster;return e?ce.html`<section part="section day-master"><h3 class="block-title">${this.t("Day Master")}</h3><div class="master"><span class="hanzi" lang="zh">${e.chinese??""}</span> <span><b class="element-word ${Et(e.element)}">${y(e,"element")}</b> ${e.polarity??""} ${e.pinyin??""}</span> ${e.nature&&!this.hideReadings?ce.html`<p part="reading">${e.nature}</p>`:ce.nothing}</div></section>`:ce.nothing}renderElements(a){let e=a.fiveElements??[];if(e.length===0)return ce.nothing;let t=this.effectiveLang(),r=e.reduce((s,i)=>s+(i.count??0),0)||1;return ce.html`<section part="section elements"><h3 class="block-title">${this.t("Elements")}</h3><div class="elements">${e.map(s=>ce.html`<div class="element ${Et(s.element)}" part="label-track"><span class="element-word">${y(s,"element")}</span> <span class="element-track"><span class="element-fill" style="width:${(s.count??0)/r*100}%"></span></span> <span class="element-count">${U(t,s.count??0)} ${s.level&&vd[s.level]?this.t(vd[s.level]):s.level??""}</span> ${s.reading&&!this.hideReadings?ce.html`<p class="element-reading" part="reading">${s.reading}</p>`:ce.nothing}</div>`)}</div></section>`}renderInteractions(a){let e=a.interactions??[];return e.length===0?ce.nothing:ce.html`<section part="section interactions"><h3 class="block-title">${this.t("Interactions")}</h3><ul class="interactions">${e.map(t=>ce.html`<li class="interaction"><div class="interaction-line"><span lang="zh">${t.chinese??""}</span> <b>${t.type&&bd[t.type]?this.t(bd[t.type]):D(t.type??"")}</b> ${t.quality?ce.html`<span class="roxy-chip tag tag-${t.quality}">${t.quality&&xd[t.quality]?this.t(xd[t.quality]):t.quality}</span>`:ce.nothing} <span>${(t.positions??[]).join(" ")}</span> ${t.transformsTo?ce.html`<span>${t.transformsTo}</span>`:ce.nothing} ${t.variety?ce.html`<span>${t.variety}</span>`:ce.nothing} ${t.type==="punishment"&&typeof t.complete=="boolean"?ce.html`<span class="completeness">${t.complete?this.t("Complete"):this.t("Partial")}</span>`:ce.nothing}</div>${t.meaning&&!this.hideReadings?ce.html`<p class="interaction-meaning" part="reading">${t.meaning}</p>`:ce.nothing}</li>`)}</ul></section>`}};nr.endpoints=Qo,nr.styles=[u,ae,la,ce.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-sm) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.born{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.animal{margin-inline-start:auto}.pillars-wrap{min-width:0;overflow-x:auto}.pillars{grid-template-columns:repeat(4,minmax(12ch,1fr));display:grid}.pillar{gap:var(--roxy-space-xs);padding:var(--roxy-space-sm);border-block-start:var(--roxy-line-thick) solid transparent;text-align:center;align-content:start;display:grid}.pillar+.pillar{border-inline-start:1px solid var(--roxy-border)}.pillar-self{border-block-start-color:var(--roxy-accent)}.pillar-self .pos{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.god{min-block-size:1lh;color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.hanzi{font-size:calc(var(--roxy-text-base) * 2);line-height:var(--roxy-leading-tight)}.hanzi-branch{color:var(--roxy-accent-ink)}.romanised,.nayin,.hidden .role{color:var(--roxy-muted)}.romanised,.nayin{font-size:var(--roxy-text-xs)}.rule{inline-size:100%;margin:calc(var(--roxy-space-unit) / 2) 0;border:0;border-block-start:1px solid var(--roxy-border)}.hidden{gap:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);text-align:start;margin:0;padding:0;list-style:none;display:grid}.nayin{text-align:start}.master{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.master .hanzi{font-size:calc(var(--roxy-text-base) * 1.5)}.master p{color:var(--roxy-secondary);flex-basis:100%;margin:0}.elements{gap:var(--roxy-space-xs);display:grid}.element{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr) max-content;align-items:center;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:grid}.element-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.25lh;overflow:hidden}:where(.element){--_element:var(--roxy-accent)}.element-fill{background:var(--_element);height:100%;display:block}.element-count{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.element-reading,.interaction-meaning{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);margin:0}.element-reading{grid-column:1/-1}:is(.master p,.element-reading,.interaction-meaning){border-block-start:0}.interactions{margin:0;padding:0;list-style:none;display:grid}.interaction{gap:calc(var(--roxy-space-unit) / 2);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.interaction:first-child{border-block-start:0;padding-block-start:0}.interaction-line{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.tag-harmonious{color:var(--roxy-success-fg)}.tag-challenging{color:var(--roxy-danger-fg)}.summary{margin:0}`],nr=m([f("roxy-bazi-chart")],nr);var Lt=require("lit");function ca(n,a){return!a||!n?.length?"":n.map(e=>a[String(e)]?.[0]).filter(Boolean).join(", ")}function Gi(n,a){return!a||typeof n!="number"?"":(a[String(n)]??[]).join(", ")}var ir=class extends g{renderData(a){let e=a.grahas??[],t=a.bhavas??[];if(!e.length&&!t.length)return this.renderEmpty();let r=e.filter(i=>i.moved),s=a.movedCount??r.length;return Lt.html`<div class="wrap" part="card" aria-label="${this.t("Bhav Chalit")}"><header class="head" part="header"><h2 class="title">${this.t("Bhav Chalit")}</h2><p class="lede">${s===0?this.t("No graha changes house. The Rashi chart and the Chalit chart agree, which is a normal result rather than a missing reading."):this.t("{{count}} of {{total}} grahas change house between the Rashi chart and the unequal Sripati cusps.",{count:s,total:e.length})}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header>${r.length?Lt.html`<div class="moved-list" part="table moved">${r.map(i=>this.renderMoved(i,a.houseThemes))}</div>`:Lt.nothing} ${t.length?Lt.html`<details part="details"><summary>${this.t("Bhava cusps and occupants")}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Bhava cusps and occupants")}"><table part="table"><thead><tr><th>${this.t("Bhava")}</th><th>${this.t("Rashi")}</th><th>${this.t("Start")}</th><th>${this.t("Madhya")}</th><th>${this.t("End")}</th><th>${this.t("Span")}</th><th>${this.t("Grahas")}</th></tr></thead><tbody>${t.map(i=>this.renderBhavaRow(i))}</tbody></table></div></details>`:Lt.nothing}</div>`}renderMoved(a,e){let t=S(a.graha)??"",r=typeof a.bhava=="number"?ca([a.bhava],e):"";return Lt.html`<div class="moved-row"><span class="graha">${t?Lt.html`<span class="glyph">${t}</span>`:Lt.nothing}${a.graha} </span><span class="shift">${this.t("house {{from}} in the Rashi chart, house {{to}} here",{from:a.rashiHouse??"",to:a.bhava??""})} </span>${r?Lt.html`<span class="themes">${r}</span>`:Lt.nothing}</div>`}renderBhavaRow(a){let e=(a.grahas??[]).join(", ");return Lt.html`<tr><td class="num">${a.house}</td><td>${a.rashi}</td><td class="num">${b(this.effectiveLang(),a.start,2)}°</td><td class="num">${b(this.effectiveLang(),a.madhya,2)}°</td><td class="num">${b(this.effectiveLang(),a.end,2)}°</td><td class="num">${b(this.effectiveLang(),a.span,2)}°</td><td class="occupants">${e}</td></tr>`}};ir.endpoints=el,ir.styles=[u,ae,Lt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.lede{margin:0}.lede{font-size:var(--roxy-text-sm)}.moved-row{align-items:baseline;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.shift{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td.occupants{white-space:normal;color:var(--roxy-secondary)}summary{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}`],ir=m([f("roxy-bhav-chalit-table")],ir);var $t=require("lit");var Ld=[{key:"bhavadhipatiBala",source:"Bhavadhipati",color:"var(--roxy-accent)"},{key:"digBala",source:"Dig",color:"var(--roxy-info)"},{key:"drishtiBala",source:"Drishti",color:"var(--roxy-success)"}],or=class extends g{renderData(a){let e=a.bhavas??[];if(!e.length)return this.renderEmpty();let t=Math.max(...e.map(r=>r.totalVirupas??0),1);return $t.html`<div class="wrap" part="card" aria-label="${this.t("Bhava Bala")}"><header class="head" part="header"><h2 class="title">${this.t("Bhava Bala")}</h2><p class="subtitle">${a.houseSystem?this.t("Twelve houses ranked by strength on the {{system}} frame",{system:a.houseSystem}):this.t("Twelve houses ranked by strength")}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header><div class="rows" part="table" role="list">${e.map(r=>this.renderBhava(r,t,a.houseThemes))}</div><div class="legend" part="legend" aria-label="${this.t("Component legend")}">${Ld.map(r=>$t.html`<div class="legend-row"><span class="swatch" style="background:${r.color}" aria-hidden="true"></span> ${this.t("{{component}} Bala",{component:this.t(r.source)})}</div>`)}</div></div>`}renderBhava(a,e,t){let r=typeof a.house=="number"?ca([a.house],t):"";return $t.html`<article class="row" role="listitem"><div class="row-top"><span class="house">${this.t("House {{n}}",{n:a.house})}</span> <span class="rashi">${a.rashi}</span> ${a.lord?$t.html`<span class="lord">${this.t("lord {{graha}}",{graha:a.lord})}</span>`:$t.nothing} <span class="total">${this.t("{{value}} rupas",{value:b(this.effectiveLang(),a.totalRupas,2)})} ${typeof a.rank=="number"?$t.html`<span class="rank">#${a.rank}</span>`:$t.nothing}</span></div><div class="bar" role="img" aria-label="${this.t("Bhava Bala {{value}} virupas",{value:b(this.effectiveLang(),a.totalVirupas,1)})}">${Ld.map(s=>{let i=Math.max(0,a[s.key]??0);return i>0?$t.html`<span class="seg" style="width:${i/e*100}%;background:${s.color}" title="${this.t("{{component}} {{value}} virupas",{component:this.t(s.source),value:b(this.effectiveLang(),i,1)})}"></span>`:$t.nothing})}</div>${r?$t.html`<p class="themes">${r}</p>`:$t.nothing}</article>`}};or.endpoints=tl,or.styles=[u,ae,$t.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.subtitle,.themes{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.row{gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row:last-child{border-block-end:0}.row-top{align-items:baseline;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.house{min-width:9ch;font-weight:var(--roxy-weight-bold)}.rashi{color:var(--roxy-secondary)}.lord{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.total{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);margin-inline-start:auto}.rank{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:var(--roxy-space-xs)}.bar{border-radius:var(--roxy-radius-full);background:color-mix(in srgb, var(--roxy-border) 55%, transparent);block-size:.5lh;display:flex;overflow:hidden}.seg{height:100%}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend-row{align-items:center;gap:var(--roxy-space-xs);display:flex}.swatch{border-radius:var(--roxy-radius-sm);block-size:.6lh;inline-size:1.5ch}`],or=m([f("roxy-bhava-bala-table")],or);var Q=require("lit"),$d=require("lit/decorators.js");var Fs=["physical","emotional","intellectual","intuitive"],kn={physical:"Physical",emotional:"Emotional",intellectual:"Intellectual",intuitive:"Intuitive"};function lr(n,a){let e=kn[n];return e?a(e):D(n)}var Sn={physical:"var(--roxy-danger)",emotional:"var(--roxy-info)",intellectual:"var(--roxy-success)",intuitive:"color-mix(in oklab, var(--roxy-info) 50%, var(--roxy-danger))",aesthetic:"var(--roxy-warning)",awareness:"color-mix(in oklab, var(--roxy-danger) 70%, var(--roxy-info))",spiritual:"color-mix(in oklab, var(--roxy-success) 50%, var(--roxy-info))",passion:"color-mix(in oklab, var(--roxy-danger) 50%, var(--roxy-warning))",mastery:"var(--roxy-accent)",wisdom:"var(--roxy-muted)"},Gm={ascending:"ascending through zero",descending:"descending through zero"},Fm={double:"Double day",triple:"Triple day"},ka=class extends g{constructor(){super(...arguments);this.mode="daily"}renderData(e){return this.mode==="critical-days"&&"criticalDays"in e?this.renderCritical(e):this.mode==="forecast"&&"days"in e?this.renderForecast(e):this.renderDaily(e)}renderDaily(e){let t=e.quickRead??{},r=Object.entries(t).map(([i,o])=>{let l=typeof o=="number"?o:0,c=Math.abs(l)>1?l/100:l;return[i,c]}),s=e.spotlight;return Q.html`<section class="wrap" part="card" aria-label="${this.t("Daily biorhythm")}"><header class="head" part="header"><h2>${this.t("Biorhythm")}</h2><div class="head-meta">${e.overallPhase?Q.html`<span class="roxy-chip">${D(e.overallPhase)}</span>`:Q.nothing} ${typeof e.energyRating=="number"?Q.html`<span class="energy">${this.t("Energy {{value}}/10",{value:e.energyRating})}</span>`:Q.nothing}</div></header>${s?Q.html`<div class="spotlight" part="details spotlight" style="${`border-inline-start-color: ${Sn[s.cycle]??"var(--roxy-accent)"}`}"><p class="roxy-label">${this.t("Spotlight cycle")}</p><div class="lead"><strong>${lr(s.cycle,i=>this.t(i))}</strong> ${typeof s.value=="number"?Q.html`<span class="energy">${Oe(this.effectiveLang(),s.value,0)}</span>`:Q.nothing} ${s.phase?Q.html`<span class="roxy-chip">${D(s.phase)}</span>`:Q.nothing}</div>${s.message&&!this.hideReadings?Q.html`<p>${s.message}</p>`:Q.nothing}</div>`:Q.nothing}<div class="bars" part="chart bars" role="list">${r.map(([i,o])=>{let l=Math.abs(o)*50,c=Sn[i]??"var(--roxy-accent)";return Q.html`<div class="bar" role="listitem"><span>${lr(i,d=>this.t(d))}</span> <span class="track"><span class="fill ${o<0?"low":"high"}" style="width:${l}%;background:${c}"></span> </span><span class="value">${Oe(this.effectiveLang(),o*100,0)}</span></div>`})}</div>${this.hideReadings?Q.nothing:Q.html`${e.dailyMessage?Q.html`<p>${e.dailyMessage}</p>`:Q.nothing} ${e.advice?Q.html`<p>${e.advice}</p>`:Q.nothing}`}</section>`}renderForecast(e){let t=e.days??[];if(t.length===0)return Q.html`<div class="roxy-empty" role="status">${this.t("No forecast")}</div>`;let r=600,s=160,i=r/Math.max(t.length-1,1),o=e.summary;return Q.html`<section class="wrap" part="card" aria-label="${this.t("Biorhythm forecast")}"><header class="head" part="header"><h2>${this.t("Forecast")}</h2><span class="energy">${Ct(this.effectiveLang(),e.startDate,e.endDate)}</span></header><svg viewBox="0 0 ${r} ${s}" part="chart" role="img" aria-label="${this.t("Biorhythm cycle lines across the forecast window")}"><title>${this.t("Biorhythm forecast")}</title><line x1="0" y1="${s/2}" x2="${r}" y2="${s/2}" stroke="var(--roxy-border)" stroke-width="1"/>${Fs.map(l=>{let c=t.map((p,h)=>{let x=p[l]??0,$=h*i,L=s/2-x/100*(s/2-8);return`${$.toFixed(2)},${L.toFixed(2)}`}).join(" "),d=Sn[l]??"var(--roxy-secondary)";return Q.svg`<polyline points=${c} fill="none" stroke=${d} stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />`})} ${t.map((l,c)=>l.isCritical?Q.svg`<circle cx=${(c*i).toFixed(2)} cy=${s/2} r="3" fill="var(--roxy-danger)"><title>${[M(this.effectiveLang(),l.date),nt(this.effectiveLang(),(l.criticalCycles??[]).map(d=>lr(d,p=>this.t(p)))),this.t("critical day"),typeof l.energyRating=="number"?this.t("Energy {{value}}/10",{value:l.energyRating}):""].filter(Boolean).join(" \xB7 ")}</title></circle>`:Q.nothing)}</svg><div class="forecast-axis" part="legend"><span>${M(this.effectiveLang(),t[0]?.date)}</span><span>${M(this.effectiveLang(),t.at(-1)?.date)}</span></div><div class="legend" part="legend">${Fs.map(l=>Q.html`<span class="key"><span class="dot" style="${`background: ${Sn[l]}`}"></span>${this.t(kn[l])}</span>`)} <span class="key"><span class="dot critical"></span>${this.t("critical day")}</span></div>${o?Q.html`<dl class="roxy-facts" part="details">${this.stat(this.t("Best day"),M(this.effectiveLang(),o.bestDay))} ${this.stat(this.t("Worst day"),M(this.effectiveLang(),o.worstDay))} ${this.stat(this.t("Average energy"),typeof o.averageEnergy=="number"?`${o.averageEnergy}/10`:"")} ${this.stat(this.t("Critical days"),typeof o.criticalDayCount=="number"?`${o.criticalDayCount}`:"")}</dl>`:Q.nothing} ${this.renderForecastData(e)} ${o?.periodAdvice&&!this.hideReadings?Q.html`<p>${o.periodAdvice}</p>`:Q.nothing}</section>`}renderForecastData(e){let t=this.effectiveLang();return Q.html`<details class="forecast-data" part="section days"><summary>${this.t("Daily values")}${he()}</summary><div class="forecast-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Biorhythm forecast")}"><table class="forecast-table"><caption class="roxy-sr-only">${this.t("Biorhythm forecast")}</caption><thead><tr><th scope="col">${this.t("Date")}</th>${Fs.map(r=>Q.html`<th scope="col">${this.t(kn[r])}</th>`)}<th scope="col">${this.t("Energy rating")}</th><th scope="col">${this.t("Days since birth")}</th><th scope="col">${this.t("Critical days")}</th></tr></thead><tbody>${e.days.map(r=>Q.html`<tr><th scope="row"><time datetime="${r.date}">${M(t,r.date)}</time></th>${Fs.map(s=>Q.html`<td>${Oe(t,r[s],2)}</td>`)}<td>${this.t("Energy {{value}}/10",{value:r.energyRating})}</td><td>${b(t,r.daysSinceBirth,0)}</td><td>${r.isCritical?nt(t,r.criticalCycles.map(s=>lr(s,i=>this.t(i))))||this.t("critical day"):this.t("None")}</td></tr>`)}</tbody></table></div></details>`}renderCritical(e){let t=e.criticalDays??[],r=e.doubleCriticalDays??[],s=t.map(i=>({label:M(this.effectiveLang(),i.date)||i.date,aside:[i.cycle?lr(i.cycle,o=>this.t(o)):"",this.severityName(i.severity)].filter(Boolean).join(" \xB7 "),body:i.advisory??"",extra:Q.html`<p class="crit-meta">${[i.direction?this.t(Gm[i.direction]):"",typeof i.period=="number"?this.t("{{period}}-day cycle",{period:i.period}):""].filter(Boolean).join(" \xB7 ")}</p>`}));return Q.html`<section class="wrap" part="card" aria-label="${this.t("Critical days")}"><header class="head" part="header"><h2>${this.t("Critical days")}</h2><span class="energy">${Ct(this.effectiveLang(),e.startDate,e.endDate)}</span></header><dl class="roxy-facts" part="details">${this.stat(this.t("Events"),typeof e.totalCriticalDays=="number"?`${e.totalCriticalDays}`:"")} ${this.stat(this.t("Double days"),r.length?`${r.length}`:"0")} ${this.stat(this.t("Triple day"),e.tripleCriticalDay?M(this.effectiveLang(),e.tripleCriticalDay):this.t("None"))}</dl>${r.length>0?Q.html`<p class="crit-note">${this.t("Two or more cycles cross zero on {{dates}}. Take extra care on these dates.",{dates:nt(this.effectiveLang(),r.map(i=>M(this.effectiveLang(),i)||i))})}</p>`:Q.nothing} ${this.renderInterpretation(s,"biorhythm-critical","Advisories")}</section>`}severityName(e){let t=Fm[e];return t?this.t(t):""}stat(e,t){return t?Q.html`<div><dt>${e}</dt><dd>${t}</dd></div>`:Q.nothing}};ka.endpoints=al,ka.styles=[u,W,Se,me,Q.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.head-meta{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.energy{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.spotlight{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);display:grid}.spotlight .lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.spotlight strong{text-transform:capitalize}.spotlight p{font-size:var(--roxy-text-sm)}.bars{gap:var(--roxy-space-xs);display:grid}.bar{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:minmax(0,16ch) minmax(0,1fr) 7ch;display:grid}.track{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.7lh;position:relative;overflow:hidden}.track:after{content:"";background:var(--roxy-surface);width:1px;position:absolute;top:0;bottom:0;left:50%}.fill{height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);position:absolute;top:0}.fill.high{left:50%}.fill.low{right:50%}.value{color:var(--roxy-muted);text-align:end;font-variant-numeric:tabular-nums}svg{width:100%;max-width:var(--roxy-chart-max-width,37.5rem);height:auto;display:block}.legend{gap:var(--roxy-space-md);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.key{align-items:center;gap:var(--roxy-space-xs);text-transform:capitalize;display:inline-flex}.dot{border-radius:var(--roxy-radius-full);block-size:.6lh;inline-size:.6lh}.dot.critical{background:var(--roxy-danger)}.roxy-facts{margin:0}.roxy-facts dd{font-weight:var(--roxy-weight-bold)}.forecast-data>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}.forecast-scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}.forecast-table{width:100%}.forecast-table th,.forecast-table td{text-align:end;white-space:nowrap}.forecast-table th:first-child,.forecast-table td:first-child{text-align:start}.forecast-axis{justify-content:space-between;gap:var(--roxy-space-sm);width:100%;max-width:var(--roxy-chart-max-width,37.5rem);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);display:flex}.crit-note{border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md)}.crit-meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],m([(0,$d.property)({type:String,reflect:true})],ka.prototype,"mode",2),ka=m([f("roxy-biorhythm-chart")],ka);var E=require("lit"),Od=require("lit/decorators.js"),Id=require("lit/directives/unsafe-html.js");var cr="http://www.w3.org/2000/svg",Rn=class{constructor(a){this.markup=a}};function Bm(n){return String(n).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}function Fi(n){return n==null?"":n instanceof Rn?n.markup:typeof n=="string"||typeof n=="number"?Bm(n):n.map(Fi).join("")}function T(n,...a){let e=n[0]??"";return a.forEach((t,r)=>{e+=e.endsWith("=")?`"${Fi(t)}"`:Fi(t),e+=n[r+1]??""}),new Rn(e)}function dr(n){return(a,e)=>on(n,a,e)}var Ed=14,Hm=86,Dd=0,jm=102,pr=6,Ad=(Hm-Ed)*pr,Km=(jm-Dd)*pr;function ds(n,a){return{x:(n-Ed)*pr,y:(a-Dd)*pr}}var K=50,En=n=>2*K-n,Bs=1.02*pr,Vm=1.15*pr,Je=2.87,Dt=4.4,wd=5.65,Bi={head:{64:[K-Je,11.2],61:[K,11.2],63:[K+Je,11.2]},ajna:{47:[K-Je,18],24:[K,18],4:[K+Je,18],17:[K-Je,20.6],11:[K+Je,20.6],43:[K,25.3]},throat:{62:[K-Je,32.4],23:[K,32.4],56:[K+Je,32.4],16:[K-Dt,34.7],35:[K+Dt,34.7],20:[K-Dt,37.3],12:[K+Dt,37.3],45:[K+Dt,39.6],31:[K-Je,41.9],8:[K,41.9],33:[K+Je,41.9]},g:{1:[K,47.7],7:[K-Je,50.3],13:[K+Je,50.3],10:[K-wd,53.4],25:[K+wd,53.4],15:[K-Je,56.8],46:[K+Je,56.8],2:[K,59.2]},heart:{21:[63.9,59.5],51:[62.1,61.3],26:[60.1,63.3],40:[66.6,63.3]},spleen:{48:[20,70.8],57:[22.5,72.4],44:[25,73.8],50:[27.7,75.3],32:[25,76.6],28:[22.5,78],18:[20,79.5]},sacral:{5:[K-Je,72.7],14:[K,72.7],29:[K+Je,72.7],34:[K-Dt,75.4],27:[K-Dt,79],59:[K+Dt,79],42:[K-Je,81.7],3:[K,81.7],9:[K+Je,81.7]},"solar-plexus":{},root:{53:[K-Je,90.2],60:[K,90.2],52:[K+Je,90.2],54:[K-Dt,92.6],19:[K+Dt,92.6],38:[K-Dt,95.3],39:[K+Dt,95.3],58:[K-Dt,98.1],41:[K+Dt,98.1]}},Um={48:36,57:22,44:37,50:6,32:49,28:55,18:30};function qm(){let n={},a={};for(let[e,[t,r]]of Object.entries(Bi.spleen))Bi["solar-plexus"][Um[Number(e)]]=[En(t),r];for(let[e,t]of Object.entries(Bi))for(let[r,[s,i]]of Object.entries(t))n[Number(r)]=ds(s,i),a[Number(r)]=e;return{points:n,centerOf:a}}var{points:Vi,centerOf:Hs}=qm(),t1=Ad/2;function cs(n){return n.map(([a,e])=>ds(a,e))}function Hi(n,a,e){return cs([[K-n,a],[K+n,a],[K+n,e],[K-n,e]])}var ji=5.9,kd=[[18.3,68.3],[18.3,82],[30.3,75.15]],Ki=[20,84.4],Sd=12*pr,Ym=[63.2,67.9],Wm=13.1*pr,Ui=[{id:"head",label:"Head",color:"gold",points:cs([[43.55,12.5],[56.45,12.5],[50,1.7]])},{id:"ajna",label:"Ajna",color:"green",points:cs([[43.55,16.5],[56.45,16.5],[50,27.7]])},{id:"throat",label:"Throat",color:"brown",points:Hi(ji,31,43.3)},{id:"g",label:"G",color:"gold",points:cs([[50,45.8],[57.7,53.6],[50,61.4],[42.3,53.6]])},{id:"heart",label:"Heart",color:"red",points:cs([[56.65,65.23],[64.2,56.74],[69.75,65.23]]),caption:{at:ds(...Ym),room:Wm}},{id:"spleen",label:"Spleen",color:"brown",points:cs(kd),caption:{at:ds(...Ki),room:Sd}},{id:"sacral",label:"Sacral",color:"red",points:Hi(ji,71.3,83.1)},{id:"solar-plexus",label:"Solar Plexus",color:"brown",points:cs(kd.map(([n,a])=>[En(n),a])),caption:{at:ds(En(Ki[0]),Ki[1]),room:Sd}},{id:"root",label:"Root",color:"brown",points:Hi(ji,88.5,99.8)}],Zm=[[64,47],[61,24],[63,4],[17,62],[11,56],[43,23],[16,48],[20,34],[20,10],[7,31],[1,8],[13,33],[21,45],[12,22],[35,36],[57,20],[15,5],[2,14],[46,29],[34,10],[10,57],[25,51],[27,50],[57,34],[26,44],[18,58],[28,38],[32,54],[3,60],[9,52],[42,53],[59,6],[19,49],[39,55],[41,30],[37,40]],Xm=Jm();function Jm(){let n=En,a=[[50,3],[58,3],[60,10],[57,17.5],[56.5,20.5],[53.5,23.5],[51.5,27],[54,28],[64,30],[79,35],[83,42],[84,58],[83,74],[83,86],[76,93],[68,97],[64,99],[62,100.5],[60,100.5]],e=[`M ${Cn(a[0])}`];for(let t=1;t+2<a.length;t+=3)e.push(`C ${Cn(a[t])} ${Cn(a[t+1])} ${Cn(a[t+2])}`);e.push(`L ${Tn(a[a.length-1],n)}`);for(let t=a.length-3;t>=1;t-=3)e.push(`C ${Tn(a[t+1],n)} ${Tn(a[t],n)} ${Tn(a[t-1],n)}`);return e.push("Z"),e.join(" ")}function Cn([n,a]){let e=ds(n,a);return`${e.x} ${e.y}`}function Tn([n,a],e){let t=ds(e(n),a);return`${t.x} ${t.y}`}function Qm(n){return n.map(a=>`${a.x},${a.y}`).join(" ")}function Pd(n){return n.left&&n.right?"both":n.left?"src-left":"src-right"}function eg(){return T`<path class="bg-body" d=${Xm} />`}function tg(n){let a=[];for(let[e,t]of Zm){let r=Vi[e],s=Vi[t];if(!r||!s)continue;a.push(T`<line class="bg-channel" x1=${r.x} y1=${r.y} x2=${s.x} y2=${s.y} />`);let i={x:(r.x+s.x)/2,y:(r.y+s.y)/2};for(let[o,l]of[[e,r],[t,s]]){let c=n.get(o);if(!c)continue;let d=Pd(c);a.push(T`<line class="bg-half ${d==="both"?"src-left":d}" x1=${l.x} y1=${l.y} x2=${i.x} y2=${i.y} />`),d==="both"&&a.push(T`<line class="bg-half src-right stripe" x1=${l.x} y1=${l.y} x2=${i.x} y2=${i.y} />`)}}return a}function ag(n,a,e){return Ui.flatMap(t=>{let r=n.has(t.id),s=`bg-center bg-${t.color}${r?" defined":""}`,i=a?.get(t.id)||t.label;return[T`<polygon class=${s} points=${Qm(t.points)}><title>${i}: ${r?e.defined:e.open}</title></polygon>`,t.caption?Rd(i,t.caption.at,"bg-caption",t.caption.room):Rd(i,Cd(t.points),r?`defined bg-${t.color}`:"",sg(t.points,Cd(t.points).y)*.86)]})}function Rd(n,a,e,t){let r=n.split(/\s+/).filter(Boolean),s=r.reduce((c,d)=>Math.max(c,d.length),0),i=Math.min(Vm,t/Math.max(1,s*rg)),o=i*1.05,l=a.y-o*(r.length-1)/2;return T`<text class="bg-center-name ${e}" style=${`font-size:${i}px`} x=${a.x} y=${a.y} text-anchor="middle" dominant-baseline="central" aria-hidden="true">${r.map((c,d)=>T`<tspan x=${a.x} y=${l+d*o}>${c}</tspan>`)}</text>`}var rg=.66;function sg(n,a){let e=[];for(let t=0;t<n.length;t++){let r=n[t],s=n[(t+1)%n.length];if(r.y===s.y)continue;let i=Math.min(r.y,s.y),o=Math.max(r.y,s.y);a<i||a>o||e.push(r.x+(a-r.y)/(s.y-r.y)*(s.x-r.x))}return e.length<2?0:Math.max(...e)-Math.min(...e)}function Cd(n){let a=n.length||1;return{x:n.reduce((e,t)=>e+t.x,0)/a,y:n.reduce((e,t)=>e+t.y,0)/a}}function Td(n,a){return`M ${n.x} ${n.y-Bs} A ${Bs} ${Bs} 0 0 ${a} ${n.x} ${n.y+Bs} Z`}function ng(n,a){let e=[];for(let[t,r]of Object.entries(Vi)){let s=Number(t),i=n.get(s),o=i?Pd(i):"",l=a.get(s);e.push(T`<g class="bg-gate-node">
|
|
8
|
-
${o==="both"?[
|
|
9
|
-
<text class="bg-gate ${i?"on":""}" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${
|
|
10
|
-
${l?
|
|
11
|
-
</g>`)}return e}var
|
|
12
|
-
${
|
|
13
|
-
${
|
|
14
|
-
${
|
|
15
|
-
${
|
|
16
|
-
`}function Wi(n,a){return n==="design"?a("Design"):n==="personality"?a("Personality"):n??""}function ig(n){let a=new Map;for(let e of n){if(e.gate==null)continue;let t=a.get(e.gate);t?t.push(e):a.set(e.gate,[e])}return a}function Zi(n){return n.planet?S(n.planet)??y(n,"planet"):""}function og(n,a){let e=new Map;for(let[t,r]of n){let s=r.map(i=>[Zi(i),`${t}${i.line!=null?`.${i.line}`:""}`,Wi(i.side,a)].filter(Boolean).join(" "));e.set(t,[a("Gate {{gate}}",{gate:t}),y(r[0],"gateName"),...s].filter(Boolean).join(" \xB7 "))}return e}function Xi(n){return new Map(n.map(a=>[a.id,y(a,"name")]))}function Md(n,a={}){let e=dr(a.lang),t=n.centers??[],r=ig(n.gates??[]);return T`<svg class="chart bodygraph" xmlns=${cr} part="chart" viewBox=${qi} preserveAspectRatio="xMidYMid meet" role="img" aria-label=${e("Human Design bodygraph with nine centers, channels, and activated gates overlaid on a human silhouette")}><title>${e("Human Design bodygraph")}</title><desc>${e("Nine energy centers in their canonical positions over a human silhouette, each filled with its traditional color when defined and outlined when open, wired by channels between activated gates.")}</desc>${Yi({definedCenters:new Set(t.filter(s=>s.defined).map(s=>s.id)),gateSources:new Map([...r].map(([s,i])=>[s,{left:i.some(o=>o.side==="design"),right:i.some(o=>o.side==="personality")}])),gateTitles:og(r,e),centerNames:Xi(t),stateWords:{defined:e("Defined"),open:e("Open")}})}</svg>`.markup}var _d=require("lit"),Dn=_d.css`.chart{width:100%;max-width:var(--roxy-chart-max-width,30rem);height:auto;margin:0 auto;display:block}@container (width<=26rem){.chart{width:calc(100% + 2 * var(--roxy-space-lg));margin-inline:calc(-1 * var(--roxy-space-lg))}}.legend{gap:var(--roxy-space-sm) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend .swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border:1px solid var(--roxy-secondary);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.legend .swatch.source{border-radius:var(--roxy-radius-full);border-color:#0000}`;var js=require("lit"),Nd=js.css`:where(.natal-wheel) .wheel-line,:where(.natal-wheel) .tick{fill:none;stroke:var(--roxy-border)}:where(.natal-wheel) .tick-major{stroke:var(--roxy-secondary)}:where(.natal-wheel) .sign-glyph{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}:where(.natal-wheel) .planet-glyph{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .875);font-weight:var(--roxy-weight-bold)}:where(.natal-wheel) .planet-deg{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .4375)}:where(.natal-wheel) .planet-deg .retro{fill:var(--roxy-danger-fg)}:where(.natal-wheel) .planet-leader{stroke:var(--roxy-accent);stroke-width:.5px;opacity:.55}:where(.natal-wheel) .house-num{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .5625)}:where(.natal-wheel) .cusp-deg{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .375)}:where(.natal-wheel) .angle-marker{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold)}:where(.natal-wheel) .angle-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}@container (width<=480px){:where(.natal-wheel) .sign-glyph,:where(.natal-wheel) .planet-glyph{font-size:calc(var(--roxy-text-base) * 1.5)}:where(.natal-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .8125)}:where(.natal-wheel) .house-num{font-size:calc(var(--roxy-text-base) * .75)}}`,zd=js.css`:where(.synastry-wheel) .wheel-line{fill:none;stroke:var(--roxy-border)}:where(.synastry-wheel) .p1{--_person:var(--roxy-accent-ink)}:where(.synastry-wheel) .p2{--_person:var(--roxy-fg)}:where(.synastry-wheel) .sign{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}:where(.synastry-wheel) text.p1,:where(.synastry-wheel) text.p2{fill:var(--_person);font-size:calc(var(--roxy-text-base) * 1.125);font-weight:var(--roxy-weight-bold)}:where(.synastry-wheel) .person-tag,:where(.synastry-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .625)}:where(.synastry-wheel) .planet-deg{fill:var(--roxy-muted)}:where(.synastry-wheel) .planet-deg .retro{fill:var(--roxy-danger-fg)}:where(.synastry-wheel) .leader{stroke:var(--_person);stroke-width:.5px;opacity:.7}@container (width<=480px){:where(.synastry-wheel) .sign,:where(.synastry-wheel) text.p1,:where(.synastry-wheel) text.p2{font-size:calc(var(--roxy-text-base) * 1.75)}:where(.synastry-wheel) .person-tag,:where(.synastry-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .9375)}}:where(.synastry-wheel) .asc-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}:where(.synastry-wheel) .asc-label{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold)}`,An=js.css`:where(.kundli) .line{fill:#0000;stroke:var(--roxy-border)}:where(.kundli) .sign-text{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-normal);font-family:var(--roxy-font-sans);text-transform:uppercase}:where(.kundli) .rashi-num{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .75);font-weight:var(--roxy-weight-normal);font-family:var(--roxy-font-sans)}:where(.kundli) .house-num{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .planet-text{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .centre-label{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .875);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .lagna-marker{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans);text-transform:uppercase}:where(.kundli) .lagna-bg{fill:color-mix(in srgb, var(--roxy-accent) 14%, transparent)}:where(.kundli) .lagna-slash{stroke:var(--roxy-accent);stroke-linecap:round;opacity:.7}`,Pn=js.css`:where(.bodygraph) .bg-body{fill:color-mix(in srgb, var(--roxy-secondary) 8%, transparent);stroke:var(--roxy-border);stroke-width:1px}:where(.bodygraph) .bg-channel{stroke:var(--roxy-border);stroke-width:5px;stroke-linecap:round}:where(.bodygraph) .bg-half{stroke-width:5px;stroke-linecap:round}:where(.bodygraph) .bg-half.stripe{stroke-linecap:butt;stroke-dasharray:7 7}:where(.bodygraph) .bg-center{fill:var(--_mask,var(--roxy-bg));stroke:var(--roxy-secondary);stroke-width:1.8px}:where(.bodygraph) .bg-center.defined{stroke:color-mix(in srgb, var(--roxy-fg) 45%, transparent)}:where(.bodygraph){--_gold:color-mix(in oklch, var(--roxy-warning) 60%, var(--roxy-success));--_gold-ink:color-mix(in oklch, var(--roxy-warning-fg) 60%, var(--roxy-success-fg));--_center-gold:light-dark(color-mix(in oklab, var(--_gold) 40%, var(--roxy-bg)),color-mix(in oklab, var(--_gold) 50%, var(--_gold-ink)));--_center-green:light-dark(color-mix(in oklab, var(--roxy-success) 40%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-success) 50%, var(--roxy-success-fg)));--_center-red:light-dark(color-mix(in oklab, var(--roxy-danger) 40%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-danger) 50%, var(--roxy-danger-fg)));--_center-brown:light-dark(color-mix(in oklab, color-mix(in oklab, var(--roxy-warning-fg) 75%, var(--roxy-fg)) 45%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-warning-fg) 50%, var(--roxy-secondary)))}:where(.bodygraph) .bg-center.bg-gold.defined,:where(.bodygraph) .legend .swatch.bg-gold{fill:var(--_center-gold);background:var(--_center-gold)}:where(.bodygraph) .bg-center.bg-green.defined,:where(.bodygraph) .legend .swatch.bg-green{fill:var(--_center-green);background:var(--_center-green)}:where(.bodygraph) .bg-center.bg-red.defined,:where(.bodygraph) .legend .swatch.bg-red{fill:var(--_center-red);background:var(--_center-red)}:where(.bodygraph) .bg-center.bg-brown.defined,:where(.bodygraph) .legend .swatch.bg-brown{fill:var(--_center-brown);background:var(--_center-brown)}:where(.bodygraph) .bg-gate-dot{fill:var(--_mask,var(--roxy-bg));stroke:var(--roxy-border);stroke-width:1px}:where(.bodygraph) .bg-gate-dot.on{stroke:var(--_mask,var(--roxy-bg))}:where(.bodygraph) .bg-center-name{color:var(--roxy-muted);fill:currentColor;font-weight:var(--roxy-weight-bold);text-transform:uppercase;pointer-events:none}:where(.bodygraph) .bg-center-name.defined{color:light-dark(var(--roxy-fg),var(--roxy-bg))}:where(.bodygraph) .bg-gate{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .50625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.bodygraph) .bg-gate.on{fill:var(--src-ink,var(--_mask,var(--roxy-bg)))}:where(.bodygraph) .bg-half.src-left{stroke:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .bg-half.src-right{stroke:var(--src-right,var(--roxy-fg))}:where(.bodygraph) .bg-gate-dot.on.src-left{fill:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .bg-gate-dot.on.src-right{fill:var(--src-right,var(--roxy-fg))}:where(.bodygraph) .legend .swatch.src-left{background:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .legend .swatch.src-right{background:var(--src-right,var(--roxy-fg))}`;var it=require("lit");var hr=[Se,it.css`.roxy-facts{margin:0}.lead{font-size:var(--roxy-text-sm);margin:0}.keynotes{gap:var(--roxy-space-xs);margin:0;display:grid}.keynotes dd{margin:0}`];function Sa(n){let a=n.filter(e=>!!e.value);return a.length===0?it.nothing:it.html`<dl class="roxy-facts" part="facts">${a.map(e=>it.html`<div part="fact"><dt>${e.label}</dt><dd>${e.value}</dd></div>`)}</dl>`}function Mn(n,a,e){return!n&&!a?it.nothing:it.html`<div class="themes roxy-chips" part="themes">${n?it.html`<span class="roxy-chip" data-tone="success">${e("Signature: {{value}}",{value:n})}</span>`:it.nothing} ${a?it.html`<span class="roxy-chip" data-tone="danger">${e("Not-self: {{value}}",{value:a})}</span>`:it.nothing}</div>`}function _n(n,a){return!n?.personality&&!n?.design?it.nothing:it.html`<dl class="keynotes" part="keynotes">${n.personality?it.html`<dt>${a("Line {{line}} \xB7 Personality",{line:n.personalityLine??""})}</dt><dd>${n.personality}</dd>`:it.nothing} ${n.design?it.html`<dt>${a("Line {{line}} \xB7 Design",{line:n.designLine??""})}</dt><dd>${n.design}</dd>`:it.nothing}</dl>`}var lg=["gold","green","brown","red"],Ra=class extends g{constructor(){super(...arguments);this.viewport=new je(this);this.side="personality"}renderData(e){let t=e.centers??[],r=Xi(t);return E.html`<div class="wrap bodygraph" part="card"><header class="head" part="header"><div><h2>${this.t("Bodygraph")}</h2>${e.designInstantUtc?E.html`<div class="meta">${this.t("Design")} <time datetime="${e.designInstantUtc}">${qc(this.effectiveLang(),e.designInstantUtc)}</time></div>`:E.nothing}</div>${e.type||e.profile?E.html`<div class="type-line">${[y(e,"type"),e.profile?this.t("Profile {{profile}}",{profile:e.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:E.nothing}</header><div class="layout" part="layout">${this.viewport.renderChartViewport((0,Id.unsafeHTML)(Md(e,{lang:this.effectiveLang()})),this.t("Human Design bodygraph"),this.translator)} ${this.renderSummary(e,r)}</div>${this.renderReading(e)} ${this.renderChannels(e.channels??[],r)} ${this.renderCenters(t)} ${this.renderActivations(e)}</div>`}renderSummary(e,t){let r=e.incarnationCross;return E.html`<div class="summary" part="details">${Sa([{label:this.t("Type"),value:y(e,"type")},{label:this.t("Strategy"),value:y(e,"strategy")},{label:this.t("Authority"),value:y(e,"authority")},{label:this.t("Profile"),value:e.profile},{label:this.t("Definition"),value:y(e,"definition")}])} ${e.typeDescription&&!this.hideReadings?E.html`<p class="lead">${e.typeDescription}</p>`:E.nothing} ${r?.name?E.html`<p class="cross">${r.name} ${r.gates?.length?E.html`<span class="gates">(${r.gates.join(", ")})</span>`:E.nothing}</p>`:E.nothing} ${Mn(e.signature?y(e,"signature"):void 0,e.notSelf?y(e,"notSelf"):void 0,this.translator)} ${this.renderLegend(t)}</div>`}renderLegend(e){let t=lg.map(r=>[r,Ui.filter(s=>s.color===r).map(s=>e.get(s.id)||s.label).join(", ")]);return E.html`<div class="legend" part="legend"><span class="legend-row"><span class="swatch source src-left"></span>${this.t("Design")} <span class="swatch source src-right"></span>${this.t("Personality")} </span><span class="legend-row">${this.t("Center colors when defined. Open centers are outlined.")}</span> ${t.map(([r,s])=>E.html`<span><span class="swatch bg-${r} defined"></span>${s}</span>`)} <span><span class="swatch"></span>${this.t("Open center")}</span></div>`}renderReading(e){let t=e.incarnationCross,r=[{label:this.t("Strategy"),aside:y(e,"strategy"),body:e.strategyDescription},{label:this.t("Authority"),aside:y(e,"authority"),body:e.authorityDescription},{label:this.t("Profile"),aside:e.profile,body:e.profileDescription,extra:_n(e.profileKeynotes,this.translator)},{label:this.t("Definition"),aside:y(e,"definition"),body:e.definitionDescription},{label:this.t("Aura"),body:e.aura},{label:this.t("Incarnation cross"),aside:t?y(t,"angle"):void 0,body:t?.description??""}];return this.renderInterpretation(r,"hd-reading")}renderChannels(e,t){if(e.length===0||this.hideReadings)return E.nothing;let r=new Map;for(let i of e){let o=i.circuit??"",l=r.get(o);l?l.push(i):r.set(o,[i])}let s=0;return E.html`<section class="block" part="section channels"><h3>${this.t("Defined channels ({{count}})",{count:e.length})}</h3>${[...r].map(([i,o])=>E.html`<div class="group">${i?E.html`<p class="group-head">${this.t("{{circuit}} circuit",{circuit:y(o[0],"circuit")})}</p>`:E.nothing} ${o[0]?.circuitDescription?E.html`<p class="group-note">${o[0].circuitDescription}</p>`:E.nothing} ${o.map(l=>E.html`<details class="interp-card" part="reading" name="hd-channel" ?open="${s++===0}"><summary><span class="interp-lead"><span class="chan-gates">${l.gateA}-${l.gateB}</span> <span>${y(l,"name")}</span> </span>${he()} <span class="interp-aside"><span class="roxy-chips">${(l.centers??[]).map(c=>E.html`<span class="roxy-chip">${t.get(c)||c}</span>`)}</span></span></summary><div class="interp-body">${l.description?E.html`<p>${l.description}</p>`:E.nothing}</div></details>`)}</div>`)}</section>`}renderCenters(e){if(e.length===0||this.hideReadings)return E.nothing;let t=e.filter(r=>r.defined).length;return E.html`<section class="block" part="section centers"><h3>${this.t("Centers ({{defined}} defined, {{open}} open)",{defined:t,open:e.length-t})}</h3>${e.map((r,s)=>E.html`<details class="interp-card" part="reading" name="hd-center" ?open="${s===0}"><summary><span class="interp-lead">${y(r,"name")}</span> ${he()} <span class="interp-aside"><span class="roxy-chips"><span class="roxy-chip ${r.defined?"on":""}">${r.defined?this.t("Defined"):this.t("Open")}</span> ${r.motor?E.html`<span class="roxy-chip">${this.t("Motor")}</span>`:E.nothing} ${r.awareness?E.html`<span class="roxy-chip">${this.t("Awareness")}</span>`:E.nothing}</span></span></summary><div class="interp-body">${r.theme?E.html`<p>${r.theme}</p>`:E.nothing} ${!r.defined&&r.notSelfQuestion?E.html`<dl class="keynotes"><dt>${this.t("Not-self question")}</dt><dd>${r.notSelfQuestion}</dd></dl>`:E.nothing} ${r.biology?E.html`<p class="footnote">${this.t("Biology")}. ${r.biology}</p>`:E.nothing} ${r.gates?.length?E.html`<p class="footnote">${this.t("Gates {{gates}}",{gates:r.gates.join(", ")})}</p>`:E.nothing}</div></details>`)}</section>`}renderActivations(e){let t=e.gates??[];if(t.length===0||this.hideReadings)return E.nothing;let r=t.filter(d=>d.side==="personality"),s=t.filter(d=>d.side==="design"),i=r.length>0&&s.length>0,o=this.side,l=i?o==="design"?s:r:t,c=i?e.sides?.[o]:void 0;return E.html`<section class="block" part="section activations"><h3>${this.t("Activations ({{count}})",{count:t.length})}</h3>${i?gt({items:[{id:"personality",label:`${this.t("Personality")} (${r.length})`},{id:"design",label:`${this.t("Design")} (${s.length})`}],active:o,onSelect:d=>{this.side=d},label:this.t("Chart sides"),idPrefix:"hd",controls:true}):E.nothing}<div id="${i?`hd-panel-${o}`:E.nothing}" part="panel" role="${i?"tabpanel":E.nothing}" aria-labelledby="${i?`hd-tab-${o}`:E.nothing}">${c?E.html`<p class="side-note">${c}</p>`:E.nothing} ${l.map((d,p)=>this.renderGate(d,p===0))}</div></section>`}renderGate(e,t){let r=Zi(e),s=y(e,"planet"),i=e.ichingHexagram;return E.html`<details class="interp-card" part="reading" name="hd-gate" ?open="${t}"><summary><span class="interp-lead">${r?E.html`<span class="glyph" aria-hidden="true">${r}</span>`:E.nothing} <span class="gate-id">${e.gate}${e.line!=null?`.${e.line}`:""}</span> <span>${y(e,"gateName")}</span> </span>${he()} ${s?E.html`<span class="interp-aside"><small>${s}</small></span>`:E.nothing}</summary><div class="interp-body">${e.gateDescription?E.html`<p>${e.gateDescription}</p>`:E.nothing} ${e.lineMeaning?E.html`<dl class="keynotes"><dt>${this.t("Line {{line}}",{line:e.line??""})}</dt><dd>${e.lineMeaning}</dd></dl>`:E.nothing} ${e.planetDescription?E.html`<p class="footnote">${s}. ${e.planetDescription}</p>`:E.nothing} ${i?.number?E.html`<p class="footnote">${this.t("I Ching hexagram {{number}}",{number:i.number})}${i.english?`, ${i.english}`:""}</p>`:E.nothing}</div></details>`}};Ra.endpoints=rl,Ra.styles=[u,Xe,ot,W,me,hr,Pn,Dn,E.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.type-line,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.layout{align-items:start;gap:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.summary{gap:var(--roxy-space-md);display:grid}.cross{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm)}.cross .gates{color:var(--roxy-muted);font-variant-numeric:tabular-nums}.legend-row{flex-basis:100%}.legend-row .swatch:not(:first-child){margin-inline-start:var(--roxy-space-md)}.legend .swatch.defined{border-color:color-mix(in srgb, var(--roxy-fg) 45%, transparent)}.group+.group{margin-block-start:var(--roxy-space-md)}.group-head{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-note,.side-note,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.group-note,.side-note{margin-block-end:var(--roxy-space-sm)}.side-note{padding-block-start:var(--roxy-space-sm)}.roxy-chip.on{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.gate-id,.chan-gates{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.glyph{color:var(--roxy-accent-ink)}`],m([(0,Od.state)()],Ra.prototype,"side",2),Ra=m([f("roxy-bodygraph")],Ra);var yt=require("lit");var cg={eight:"Eight karaka scheme, Rahu included and ranked from the end of its sign.",seven:"Seven karaka scheme, Rahu excluded and the Pitrikaraka office not assigned."},mr=class extends g{renderData(a){let e=a.karakas??[];return e.length?yt.html`<div class="wrap" part="card" aria-label="${this.t("Chara karakas")}"><header class="head" part="header"><h2>${this.t("Chara karakas")}</h2><p class="scheme"><span class="scheme-chip roxy-chip">${a.scheme??""}</span> ${a.scheme?cg[a.scheme]??"":""}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header><dl class="roxy-facts" part="details"><div><dt>${this.t("Atmakaraka")}</dt><dd>${a.atmakaraka??""}</dd></div><div><dt>${this.t("Darakaraka")}</dt><dd>${a.darakaraka??""}</dd></div></dl><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Chara karakas")}"><table class="stacked" role="table"><caption class="roxy-sr-only">${this.t("Chara karakas in descending rank: each office, the graha holding it, its rashi, the degree it holds, the degree that earned the office, and what the office is read for.")}</caption><thead><tr><th scope="col">${this.t("Office")}</th><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Ranked on")}</th><th scope="col">${this.t("Read for")}</th></tr></thead><tbody>${e.map((t,r)=>this.renderRow(t,r===0))}</tbody></table></div></div>`:this.renderEmpty()}renderRow(a,e){let t=S(a.graha)??"",r=Z(a.rashi)??"";return yt.html`<tr class="${e?"lead-row":""}"><td class="name">${a.name??""}${a.abbreviation?yt.html`<span class="abbr">${a.abbreviation}</span>`:yt.nothing}</td><td data-inline data-label="${this.t("Graha")}">${t?yt.html`<span class="glyph">${t}</span>`:yt.nothing}${a.graha??""}</td><td data-inline data-label="${this.t("Rashi")}">${r?yt.html`<span class="glyph">${r}</span>`:yt.nothing}${a.rashi??""}</td><td data-inline data-label="${this.t("Degree")}">${b(this.effectiveLang(),a.degreeInRashi,2)}</td><td data-inline data-label="${this.t("Ranked on")}">${b(this.effectiveLang(),a.rankingDegree,2)} ${a.isReversed?yt.html`<span class="reversed">${this.t("measured from the end of the sign")}</span>`:yt.nothing}</td><td class="meaning"><strong>${a.meaning??""}</strong> ${a.significations?yt.html`<p>${a.significations}</p>`:yt.nothing}</td></tr>`}};mr.endpoints=sl,mr.styles=[u,ae,Se,...Ln,yt.css`.wrap{overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);display:grid}h2,p{margin:0}.scheme{align-items:baseline;gap:var(--roxy-space-sm);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.scheme-chip{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.roxy-facts{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);margin:0}.roxy-facts dd{font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold)}.reversed{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}`],mr=m([f("roxy-chara-karakas")],mr);var ut=require("lit");var gr=class extends g{isCurrent(a){let e=Date.now(),t=Date.parse(a.start),r=Date.parse(a.end);return Number.isNaN(t)||Number.isNaN(r)?false:e>=t&&e<r}renderTile(a){let e=a.effect==="Good"?"good":a.effect==="Bad"?"bad":"neutral",t=this.isCurrent(a),r=S(a.lord)??"",s=na(this.effectiveLang(),a),i=e==="good"?this.t("Favourable"):e==="bad"?this.t("Unfavourable"):"";return ut.html`<div class="cho-tile ${e}${t?" now":""}" role="listitem" aria-current="${t?"time":"false"}"><span class="tile-name">${a.name}${t?ut.html`<span class="now-badge">${this.t("Now")}</span>`:ut.nothing} </span><span class="tile-time" aria-label="${this.t("Time range")}">${s}</span> <span class="tile-lord">${r?ut.html`<span aria-hidden="true">${r}</span>`:ut.nothing} ${a.lord} ${i?ut.html`<span aria-hidden="true">·</span><span class="tile-effect">${i}</span>`:ut.nothing}</span></div>`}renderData(a){let{date:e,dayChoghadiya:t,nightChoghadiya:r}=a;return ut.html`<div class="wrap" part="card"><div class="header" part="header"><h2>${this.t("Choghadiya")}</h2>${e?ut.html`<p class="roxy-label">${M(this.effectiveLang(),e)}</p>`:ut.nothing}</div><div class="cho-grid" part="table"><section class="period-col" aria-label="${this.t("Day muhurta periods")}"><h3 class="period-heading">${this.t("Daytime")}</h3><div role="list" aria-label="${this.t("Daytime choghadiya")}">${t&&t.length>0?t.map(s=>this.renderTile(s)):ut.html`<p class="roxy-empty" role="status">${this.t("No daytime periods")}</p>`}</div></section><section class="period-col" aria-label="${this.t("Night muhurta periods")}"><h3 class="period-heading">${this.t("Night")}</h3><div role="list" aria-label="${this.t("Nighttime choghadiya")}">${r&&r.length>0?r.map(s=>this.renderTile(s)):ut.html`<p class="roxy-empty" role="status">${this.t("No nighttime periods")}</p>`}</div></section></div></div>`}};gr.endpoints=nl,gr.styles=[u,ut.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.header{gap:var(--roxy-space-xs);display:grid}h2,h3,p{margin:0}.cho-grid{gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}@container (width>=40rem){.cho-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}.period-heading{margin-block-end:var(--roxy-space-xs)}.cho-tile{align-items:center;gap:0 var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr) auto;display:grid}.cho-tile:last-child{border-block-end:0}.cho-tile.now{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-sm)}.now-badge{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-sm)}.tile-name{min-width:0;font-weight:var(--roxy-weight-bold);overflow-wrap:anywhere;grid-column:1}.good :is(.tile-name,.tile-effect){color:var(--roxy-success-fg)}.bad :is(.tile-name,.tile-effect){color:var(--roxy-danger-fg)}.tile-time{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;text-align:end;white-space:nowrap;grid-area:1/2/3;align-self:center}.tile-lord{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;grid-column:1;display:flex}`],gr=m([f("roxy-choghadiya-grid")],gr);var te=require("lit"),Bd=require("lit/decorators.js");var dg=["sun","moon","venus","mars"],Gd=["fire","earth","air","water"],Fd={astrology:"Astrology compatibility",numerology:"Numerology compatibility",biorhythm:"Biorhythm compatibility"},pg={in_sync:"In sync",complementary:"Complementary",neutral:"Neutral",opposing:"Opposing"},Ca=class extends g{constructor(){super(...arguments);this.mode="astrology"}getBreakdown(){let e=this.data;if(!e)return{};if("categories"in e&&e.categories){let t={};for(let[r,s]of Object.entries(e.categories))typeof s=="number"&&Number.isFinite(s)&&(t[r]=s);return t}return{}}renderData(e){let t=e.overallScore,r=this.getBreakdown(),s="rating"in e?e.rating:void 0,i="archetype"in e?e.archetype:void 0,o="advice"in e?e.advice:void 0,l="summary"in e?e.summary:void 0,c="interpretation"in e?e.interpretation:void 0,d="strengths"in e?e.strengths:void 0,p="challenges"in e?e.challenges:void 0,h="keyAspects"in e?e.keyAspects:void 0,x=!this.hideReadings,$=this.t(Fd[this.mode]??Fd.astrology);return te.html`<article class="card" part="card" aria-label="${$}"><div class="head" part="header"><h2>${$}</h2><div>${typeof t=="number"?te.html`<div class="score">${Math.round(t)}</div>`:te.nothing} ${s?te.html`<div class="rating">${s}</div>`:te.nothing}</div></div>${Object.keys(r).length>0?te.html`<div role="list" part="details breakdown">${Object.entries(r).map(([L,C])=>te.html`<div class="bar-row" role="listitem"><span style="text-transform:capitalize">${L}</span> <span class="bar"><span style="width:${Math.max(0,Math.min(100,C))}%"></span></span> <span>${Math.round(C)}</span></div>`)}</div>`:te.nothing} ${i?te.html`<p><span class="archetype">${i.label}</span> ${i.description&&x?te.html`· ${i.description}`:te.nothing}</p>`:te.nothing} ${l&&x?te.html`<p>${l}</p>`:te.nothing} ${c&&x?te.html`<p class="body">${c}</p>`:te.nothing} ${o&&x?te.html`<p class="body">${o}</p>`:te.nothing} ${this.renderAspectBreakdown()} ${this.renderSignCompatibility()} ${this.renderElementBalance()} ${this.renderSubScores()} ${x&&((d?.length??0)>0||(p?.length??0)>0)?te.html`<div class="lists" part="section strengths-challenges">${d?.length?te.html`<div><h3>${this.t("Strengths")}</h3><ul>${d.map(L=>te.html`<li>${L}</li>`)}</ul></div>`:te.nothing} ${p?.length?te.html`<div><h3>${this.t("Challenges")}</h3><ul>${p.map(L=>te.html`<li>${L}</li>`)}</ul></div>`:te.nothing}</div>`:te.nothing} ${h?.length?te.html`<div class="lists" part="section key-aspects"><div><h3>${this.t("Key aspects")}</h3><ul>${h.slice(0,6).map(L=>te.html`<li>${hg(this.effectiveLang(),L,x)}</li>`)}</ul></div></div>`:te.nothing}</article>`}renderAspectBreakdown(){let e=this.astro()?.aspectBreakdown;return e?te.html`<p class="counts" part="details aspect-breakdown" role="region" aria-label="${this.t("Aspect breakdown")}">${typeof e.total=="number"?te.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:te.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span></p>`:te.nothing}renderSignCompatibility(){let e=this.astro(),t=e?.signCompatibility;if(!t)return te.nothing;let r=e?.persons,s=dg.map(i=>{let o=t[i];if(!o)return null;let l=c=>{let d=V((c==="person1"?o.person1Sign:o.person2Sign)??""),p=r?.[c]?.[i]?.degree,h=Z(d)??"",x=typeof p=="number"?` ${Math.round(p)}\xB0`:"";return`${h} ${d}${x}`.trim()};return{label:`${S(i)??""} ${V(i)}`.trim(),aside:nt(this.effectiveLang(),[l("person1"),l("person2")]),body:o.description??""}}).filter(i=>i!==null);return this.renderInterpretation(s,"compat-signs","Sign compatibility")}renderElementBalance(){let e=this.astro()?.elementBalance;if(!e)return te.nothing;let t=e.person1,r=e.person2,s=Math.max(1,...Gd.map(o=>Math.max(t?.[o]??0,r?.[o]??0))),i=e.sharedElement?.toLowerCase();return te.html`<section class="block" part="section element-balance"><h3>${this.t("Element balance")}</h3><div class="elements"><div class="el-row el-head"><span></span> <span class="roxy-label">${this.t("Person 1")}</span> <span class="roxy-label">${this.t("Person 2")}</span></div>${Gd.map(o=>{let l=t?.[o]??0,c=r?.[o]??0;return te.html`<div class="${o===i?"el-row shared":"el-row"}"><span class="el-name">${o}</span> <span class="el-bar p1"><span>${l}</span> <span class="track"><span style="width:${l/s*100}%"></span></span> </span><span class="el-bar p2"><span class="track"><span style="width:${c/s*100}%"></span></span> <span>${c}</span></span></div>`})}</div>${e.description&&!this.hideReadings?te.html`<p class="shared-note">${e.description}</p>`:te.nothing}</section>`}renderSubScores(){let e=this.data;if(!e)return te.nothing;let t=[];if("lifePath"in e){let r=[["Life Path",e.lifePath],["Expression",e.expression],["Soul Urge",e.soulUrge]];for(let[s,i]of r)i&&t.push({label:this.t(s),aside:[nt(this.effectiveLang(),[String(i.person1),String(i.person2)]),Oe(this.effectiveLang(),i.compatibility,0)].filter(Boolean).join(" \xB7 "),body:i.description??""})}if("cycles"in e&&e.cycles)for(let[r,s]of Object.entries(e.cycles))s&&t.push({label:lr(r,i=>this.t(i)),aside:[typeof s.alignment=="number"?this.t("{{percent}} in step",{percent:Oe(this.effectiveLang(),s.alignment,0)}):"",s.phase?this.t(pg[s.phase]):""].filter(Boolean).join(" \xB7 "),body:s.description??""});return this.renderInterpretation(t,"compat-sub-scores","Breakdown")}astro(){let e=this.data;return e&&"signCompatibility"in e?e:void 0}};Ca.endpoints=il,Ca.styles=[u,W,me,te.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr) auto;display:grid}.head h2{text-transform:capitalize}.score{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.rating{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.bar-row{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:14ch minmax(0,1fr) 4ch;display:grid}.bar,.el-bar .track{block-size:var(--roxy-space-sm);background:var(--roxy-border);border-radius:var(--roxy-radius-full);overflow:hidden}.bar>span{background:var(--roxy-accent);height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.bar-row>span:last-child{color:var(--roxy-muted);text-align:end;font-variant-numeric:tabular-nums}.archetype{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.lists h3{margin-block-end:var(--roxy-space-xs)}.lists ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}p.body{font-size:var(--roxy-text-sm)}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.block>h3{margin-block-end:var(--roxy-space-sm)}.elements{gap:var(--roxy-space-sm);display:grid}.el-row{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:8ch minmax(0,1fr) minmax(0,1fr);display:grid}.el-row .el-name{text-transform:capitalize}.el-row.shared .el-name{font-weight:var(--roxy-weight-bold)}.el-head span:nth-child(2){text-align:end}.el-bar{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;display:flex}.el-bar.p1{flex-direction:row-reverse}.el-bar .track{flex:auto;display:flex}.el-bar.p1 .track{justify-content:flex-end}.el-bar .track>span{background:var(--roxy-accent);height:100%;display:block}.el-bar.p2 .track>span{background:var(--roxy-secondary)}.shared-note{font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-sm)}`],m([(0,Bd.property)({type:String,reflect:true})],Ca.prototype,"mode",2),Ca=m([f("roxy-compatibility-card")],Ca);function hg(n,a,e){let t=Tt(a),r=typeof a.orb=="number"?` (orb ${b(n,a.orb,1)}\xB0)`:"",s=[a.planet1,t,a.planet2].filter(Boolean).join(" ");return a.description&&e?`${s}${r} \xB7 ${a.description}`:`${s}${r}`}var qt=require("lit");var Hd={fortunate:"Fortunate",unfortunate:"Unfortunate",mixed:"Mixed fortune"},mg={fortunate:"success",unfortunate:"danger",mixed:"warning"},yr=class extends g{renderData(a){let e=U(this.effectiveLang(),a.number);return qt.html`<article class="card" part="card" aria-label="${`${this.t("Compound number")} ${e}`}"><header class="hero" part="header"><div class="numeral">${e}</div><div><p class="roxy-label">${this.t("Compound number")}</p>${a.name?qt.html`<h2>${a.name}</h2>`:qt.nothing}</div></header><ul class="badges roxy-chips" part="details"><li>${this.t("Root number {{n}}",{n:U(this.effectiveLang(),a.root)})}</li><li class="roxy-chip" data-tone="${mg[a.nature]??qt.nothing}">${Hd[a.nature]?this.t(Hd[a.nature]):D(a.nature)}</li>${typeof a.sameAs=="number"?qt.html`<li>${this.t("Same meaning as {{n}}",{n:U(this.effectiveLang(),a.sameAs)})}</li>`:qt.nothing}</ul>${a.meaning&&!this.hideReadings?qt.html`<p part="section readings">${a.meaning}</p>`:qt.nothing}</article>`}};yr.endpoints=ol,yr.styles=[u,qt.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.hero>div{min-width:0}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.badges>li{font-variant-numeric:tabular-nums}`],yr=m([f("roxy-compound-number")],yr);var Te=require("lit");var gg={apple:"#8db600",azure:"#007fff",blackish:"black",bluish:"blue",bottle:"#006a4e",brass:"#b5a642",brick:"#b22222",brownish:"brown",browns:"brown",burgundy:"#800020",clear:"#eef2f6",colorless:"#eef2f6",colourless:"#eef2f6",cream:"#fffdd0",creamy:"#fffdd0",emerald:"#50c878",golden:"gold",greenish:"green",lilac:"#c8a2c8",mauve:"#e0b0ff",peach:"peachpuff",pinkish:"pink",reddish:"red",rose:"#f4a6b7",royal:"royalblue",silvery:"silver",sky:"skyblue",yellowish:"yellow"},yg=new Set(["beige","black","blue","brown","crimson","cyan","gold","gray","green","grey","indigo","lavender","magenta","maroon","navy","olive","orange","pink","purple","red","salmon","silver","tan","teal","turquoise","violet","white","yellow"]),ug={bright:["white",85],dark:["black",60],deep:["black",70],faintly:["white",30],light:["white",55],pale:["white",45],rich:["black",80]};function Nn(n){let a=[],e=[];for(let i of n.toLowerCase().split(/[\s-]+/)){let o=ug[i];if(o){e.push(o);continue}let l=gg[i]??(yg.has(i)?i:"");l&&a.push(l)}let[t,r]=a;if(!t)return"var(--roxy-border, #e4e4e7)";let s=r?`color-mix(in srgb, ${t}, ${r})`:t;for(let[i,o]of e)s=`color-mix(in srgb, ${s} ${o}%, ${i})`;return s}var ur=class extends g{renderData(a){let e=a.colors??[],t=a.keywords??[],r=a.pairsWith??[],s=un(this.effectiveLang(),a.birthMonth)||void 0,i=a.name??this.t("Crystal");return Te.html`<article class="wrap" part="card" aria-label="${i}"><div class="hero" part="header">${a.imageUrl?Te.html`<img class="photo" part="chart" src="${a.imageUrl}" alt="${i}" loading="lazy">`:Te.nothing}<div><h2>${a.name}</h2>${a.description&&!this.hideReadings?Te.html`<p class="desc">${a.description}</p>`:Te.nothing}</div></div><dl class="roxy-facts" part="details">${this.attr(this.t("Planet"),a.planet)} ${this.attr(this.t("Hardness"),typeof a.hardness=="number"?this.t("{{value}} Mohs",{value:b(this.effectiveLang(),a.hardness)}):void 0)} ${this.attr(this.t("Vibration"),a.numericalVibration)} ${this.attr(this.t("Birthstone"),s)} ${this.list(this.t("Chakras"),a.chakras)} ${this.list(this.t("Zodiac"),a.zodiacSigns)} ${this.list(this.t("Elements"),a.elements)} ${e.length?Te.html`<div><dt>${this.t("Colors")}</dt><dd><div class="colors">${e.map(o=>Te.html`<span class="color"><span class="dot" style="${`background:${Nn(o)}`}"></span>${o}</span>`)}</div></dd></div>`:Te.nothing}</dl>${this.renderMeaning(a.meaning)} ${t.length&&!this.hideReadings?Te.html`<section part="section keywords"><h3>${this.t("Keywords")}</h3><ul class="chips roxy-chips">${t.map(o=>Te.html`<li>${o}</li>`)}</ul></section>`:Te.nothing} ${a.affirmation&&!this.hideReadings?Te.html`<p class="affirmation">${a.affirmation}</p>`:Te.nothing} ${r.length?Te.html`<section part="section pairs-with"><h3>${this.t("Pairs with")}</h3><ul class="chips roxy-chips">${r.map(o=>Te.html`<li>${String(o).replace(/-/g," ")}</li>`)}</ul></section>`:Te.nothing}</article>`}attr(a,e){return e==null||e===""?Te.nothing:Te.html`<div><dt>${a}</dt><dd>${e}</dd></div>`}list(a,e){return e?.length?Te.html`<div><dt>${a}</dt><dd>${e.join(", ")}</dd></div>`:Te.nothing}renderMeaning(a){if(!a||this.hideReadings)return Te.nothing;let t=[[this.t("Spiritual"),a.spiritual],[this.t("Emotional"),a.emotional],[this.t("Physical"),a.physical]].filter(([,r])=>!!r);return t.length===0?Te.nothing:Te.html`<div class="meaning" part="section meaning">${t.map(([r,s])=>Te.html`<h3>${r}</h3><p>${s}</p>`)}</div>`}};ur.endpoints=ll,ur.styles=[u,Se,Te.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:flex-start;gap:var(--roxy-space-md);display:flex}.photo{border-radius:var(--roxy-radius-md);object-fit:cover;background:var(--roxy-border);flex:none;block-size:4lh;inline-size:4lh}.hero h2{margin-block-end:var(--roxy-space-xs)}.desc,.meaning p{font-size:var(--roxy-text-sm)}.colors{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.color{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-xs);text-transform:capitalize;display:inline-flex}.dot{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.6lh;inline-size:.6lh}.meaning h3,section>h3{margin-block-end:var(--roxy-space-xs)}.meaning p{margin-block-end:var(--roxy-space-sm)}.chips>li{text-transform:capitalize}.affirmation{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md);font-style:italic}`],ur=m([f("roxy-crystal-card")],ur);var Ft=require("lit"),jd=require("lit/decorators.js");var Ta=class extends g{constructor(){super(...arguments);this.heading="";this.rowDetail={tag:"roxy-crystal-card",path:"crystals/{id}"};this.listKey="crystals"}renderData(e){let t=e.crystals??[];if(t.length===0)return this.renderEmpty();let r=this.heading||this.deriveHeading(e),s="total"in e&&typeof e.total=="number"?e.total:t.length;return Ft.html`<section class="wrap" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="count">${s===1?this.t("1 crystal"):this.t("{{count}} crystals",{count:s})}</span></header><ul class="grid" part="section crystals">${t.map(i=>Ft.html`<li><button type="button" class="tile" aria-pressed="${this.openedRowId===i.id?"true":"false"}" @click="${()=>this.pickRow({id:i.id,name:i.name})}">${i.imageUrl?Ft.html`<img class="photo" src="${i.imageUrl}" alt="${i.name??this.t("Crystal")}" loading="lazy">`:Ft.html`<div class="photo" aria-hidden="true"></div>`}<p class="name">${i.name}</p>${i.colors&&i.colors.length>0?Ft.html`<div class="colors" aria-label="${this.t("Colors: {{list}}",{list:nt(this.effectiveLang(),i.colors)})}">${i.colors.map(o=>Ft.html`<span class="swatch" style="${`background:${Nn(o)}`}" title="${o}"></span>`)}</div>`:Ft.nothing}</button></li>`)}</ul>${this.renderMore()} ${this.openedRow?Ft.html`<div class="detail" part="detail">${this.openedRow}</div>`:Ft.nothing}</section>`}deriveHeading(e){return"chakra"in e&&e.chakra?this.t("{{chakra}} chakra crystals",{chakra:e.chakra}):"element"in e&&e.element?this.t("{{element}} element crystals",{element:e.element}):"sign"in e&&e.sign?this.t("Crystals for {{sign}}",{sign:e.sign}):"month"in e&&typeof e.month=="number"?this.t("{{month}} birthstones",{month:un(this.effectiveLang(),e.month)}):this.t("Crystals")}};Ta.endpoints=cl,Ta.styles=[u,Ft.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,16ch),1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs);width:100%;padding:var(--roxy-space-xs);color:inherit;border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;border:1px solid #0000;display:grid}.tile[aria-pressed=true],.tile:hover{border-color:var(--roxy-accent)}.detail{margin-block-start:var(--roxy-space-md)}.photo{aspect-ratio:1;border-radius:var(--roxy-radius-sm);object-fit:cover;background:var(--roxy-border);width:100%}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.colors{gap:var(--roxy-space-xs);flex-wrap:wrap;display:flex}.swatch{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.4lh;inline-size:.4lh}`],m([(0,jd.property)({type:String,reflect:true})],Ta.prototype,"heading",2),Ta=m([f("roxy-crystal-grid")],Ta);var ge=require("lit"),On=require("lit/decorators.js");function Kd(n){return"pranaDashas"in n?"Prana":"sookshmaDashas"in n?"Sookshma":"pratyantardashas"in n?"Pratyantardasha":"antardashas"in n?"Antardasha":"Mahadasha"}function Ji(n){if("sookshmaPeriod"in n&&n.sookshmaPeriod)return{source:"Sookshma",period:n.sookshmaPeriod};if("pratyantardashaPeriod"in n&&n.pratyantardashaPeriod)return{source:"Pratyantardasha",period:n.pratyantardashaPeriod};if("antardashaPeriod"in n&&n.antardashaPeriod)return{source:"Antardasha",period:n.antardashaPeriod};if("mahadashaPeriod"in n&&n.mahadashaPeriod)return{source:"Mahadasha",period:n.mahadashaPeriod}}function Qi(n){if(!n)return"";let a=[];return n.years&&a.push(`${n.years}y`),n.months&&a.push(`${n.months}m`),n.days&&a.push(`${n.days}d`),a.length?a.join(" "):"0d"}function Vd(n,a){return ca(n?.strongHouses?.length?n.strongHouses:n?.signifiedHouses,a)}function zn(n,a){let e=M(n,a.startDate);return e&&e===M(n,a.endDate)?ks(n,a.startDate,a.endDate):Ct(n,a.startDate,a.endDate)}var da=class extends g{constructor(){super(...arguments);this.period="current";this.view="timeline"}renderData(e){let t=this.collectPeriods(e),r=t.length?Math.max(...t.map(d=>d.durationYears)):0,s=xg(t.length?Math.min(...t.map(d=>d.durationYears)):0),i=this.hideReadings?[]:this.readings(e,t),o=this.frameRows(e),l=[{id:"timeline",label:this.t("Timeline")},...i.length?[{id:"readings",label:this.t("Readings ({{count}})",{count:i.length})}]:[],...o.length?[{id:"frame",label:this.t("Chart details")}]:[]],c=l.some(d=>d.id===this.view)?this.view:"timeline";return ge.html`<div class="wrap" part="card" aria-label="${this.t("Dasha timeline")}"><header class="head" part="header"><h2 class="title">${this.heading(e)}</h2>${this.renderLordChain(e)}</header>${this.renderParentMahadasha(e)} ${l.length>1?gt({items:l,active:c,onSelect:d=>{this.view=d},label:this.t("Dasha views"),idPrefix:"roxy-dasha",controls:true}):ge.nothing}<div id="roxy-dasha-panel-${c}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="${l.length>1?`roxy-dasha-tab-${c}`:ge.nothing}">${c==="timeline"?ge.html`${this.period==="current"?this.renderCurrent(e):ge.nothing} ${t.length>0?ge.html`<div class="timeline" part="chart timeline" role="list">${t.map(d=>this.renderBar(d,r,s,e.houseThemes))}</div>`:ge.nothing}`:ge.nothing} ${c==="readings"?this.renderReadings(i):ge.nothing} ${c==="frame"?this.renderFrame(o):ge.nothing}</div></div>`}renderLordChain(e){let t=["mahadashaLord"in e?e.mahadashaLord:void 0,"antardashaLord"in e?e.antardashaLord:void 0,"pratyantardashaLord"in e?e.pratyantardashaLord:void 0,"sookshmaLord"in e?e.sookshmaLord:void 0].filter(Boolean);return t.length>1?ge.html`<div class="nakshatra">${t.join(" \u203A ")}</div>`:"nakshatraName"in e&&e.nakshatraName?ge.html`<div class="nakshatra">${"nakshatraLord"in e&&e.nakshatraLord?this.t("Moon nakshatra: {{name}} (lord {{lord}})",{name:e.nakshatraName,lord:e.nakshatraLord}):this.t("Moon nakshatra: {{name}}",{name:e.nakshatraName})}</div>`:ge.nothing}frameRows(e){let t=[];if("nakshatraName"in e&&e.nakshatraName){let r="moonNakshatra"in e&&e.moonNakshatra?` (${e.moonNakshatra} of 27)`:"";t.push(["Moon nakshatra",`${e.nakshatraName}${r}`])}if("nakshatraLord"in e&&e.nakshatraLord&&t.push(["Nakshatra lord",e.nakshatraLord]),"moonLongitude"in e&&typeof e.moonLongitude=="number"&&t.push(["Moon longitude",`${b(this.effectiveLang(),e.moonLongitude,3)}\xB0 sidereal`]),"ayanamsaType"in e&&e.ayanamsaType&&t.push(["Ayanamsa",is(this.effectiveLang(),e.ayanamsaType,"ayanamsa"in e?e.ayanamsa:void 0)]),"birthDashaBalance"in e&&e.birthDashaBalance){let r="nakshatraLord"in e&&e.nakshatraLord?`${e.nakshatraLord} `:"";t.push(["Balance at birth",`${Qi(e.birthDashaBalance)} of the opening ${r}mahadasha`])}return"totalYears"in e&&typeof e.totalYears=="number"&&t.push(["Cycle length",`${e.totalYears} years`]),t}renderFrame(e){return ge.html`<dl class="roxy-facts" part="details frame">${e.map(([t,r])=>ge.html`<div><dt>${t}</dt><dd>${r}</dd></div>`)}</dl>`}renderReadings(e){return this.renderInterpretation(e,"roxy-dasha",e.length===1?"Reading":"Readings")}heading(e){let t=Ji(e);return t?this.t("{{level}} periods in {{planet}} {{parent}}",{level:this.t(Kd(e)),planet:t.period.planet,parent:this.t(t.source)}):"mahadashas"in e?this.t("Vimshottari Mahadasha"):"mahadasha"in e?this.t("Active dashas"):this.period==="major"?this.t("Vimshottari Mahadasha"):this.t("Active dashas")}renderParentMahadasha(e){let t=Ji(e);if(!t)return ge.nothing;let r=t.period,s=zn(this.effectiveLang(),r),i=r.nominalStartDate?M(this.effectiveLang(),r.nominalStartDate):"";return ge.html`<p class="parent">${this.t("Inside the {{planet}} {{level}}{{span}}{{duration}}.",{planet:r.planet,level:this.t(t.source),span:s?`, ${s}`:"",duration:typeof r.durationYears=="number"?` (${fg(this.effectiveLang(),r.durationYears)})`:""})} ${i?ge.html`<br>${this.t("It began {{date}}, before birth, so only the sub-periods running after the birth date are listed.",{date:i})}`:ge.nothing}</p>`}readings(e,t){let r=[],s=Ji(e);if(s?.period.interpretation&&r.push({label:this.t("{{planet}} {{level}}",{planet:s.period.planet,level:this.t(s.source)}),aside:zn(this.effectiveLang(),s.period),body:s.period.interpretation}),"mahadasha"in e){let o=[["Mahadasha",e.mahadasha,e.remainingInMahadasha],["Antardasha",e.antardasha,e.remainingInAntardasha],["Pratyantardasha",e.pratyantardasha,e.remainingInPratyantardasha],["Sookshma",e.sookshmaDasha,e.remainingInSookshma],["Prana",e.pranaDasha,e.remainingInPrana]];for(let[l,c,d]of o){if(!c?.interpretation)continue;let p=Qi(d);r.push({label:this.t("{{planet}} {{level}}",{planet:c.planet,level:this.t(l)}),aside:p?this.t("{{balance}} left",{balance:p}):zn(this.effectiveLang(),c),body:c.interpretation})}}let i=t.find(o=>this.isCurrent(o));return i?.interpretation&&r.push({label:`${i.planet} ${Kd(e)}`,aside:zn(this.effectiveLang(),i),body:i.interpretation}),r}renderCurrent(e){if(!("mahadasha"in e))return ge.nothing;let t=[["Mahadasha",e.mahadasha,e.remainingInMahadasha],["Antardasha",e.antardasha,e.remainingInAntardasha],["Pratyantardasha",e.pratyantardasha,e.remainingInPratyantardasha],["Sookshma",e.sookshmaDasha,e.remainingInSookshma],["Prana",e.pranaDasha,e.remainingInPrana]];return ge.html`<div class="current" part="details current">${t.map(([r,s,i])=>{if(!s)return ge.nothing;let o=Qi(i),l=Vd(s.significators,e.houseThemes);return ge.html`<div><span class="roxy-label">${this.t(r)}</span> <strong>${s.planet}</strong> ${o?ge.html`<small>${this.t("{{balance}} left",{balance:o})}</small>`:ge.nothing} ${l?ge.html`<small class="houses">${this.t("Signifies {{houses}}",{houses:l})}</small>`:ge.nothing}</div>`})}</div>`}collectPeriods(e){return"mahadashas"in e&&e.mahadashas?.length?e.mahadashas:"antardashas"in e&&e.antardashas?.length?e.antardashas:"pratyantardashas"in e&&e.pratyantardashas?.length?e.pratyantardashas:"sookshmaDashas"in e&&e.sookshmaDashas?.length?e.sookshmaDashas:"pranaDashas"in e&&e.pranaDashas?.length?e.pranaDashas:[]}isCurrent(e){if(!e.startDate||!e.endDate)return false;let t=Date.now(),r=Date.parse(e.startDate),s=Date.parse(e.endDate);return Number.isNaN(r)||Number.isNaN(s)?false:t>=r&&t<s}progressIn(e){if(!e.startDate||!e.endDate)return-1;let t=Date.parse(e.startDate),r=Date.parse(e.endDate),s=Date.now();return Number.isNaN(t)||Number.isNaN(r)||s<t||s>=r||r<=t?-1:(s-t)/(r-t)}renderBar(e,t,r,s){let i=e.durationYears,o=t>0?i/t*100:0,l=this.isCurrent(e),c=l?this.progressIn(e):-1,d=l?"bar-track bar-now":"bar-track",p=Vd(e.significators,s),h=["bar",l?"now":"",r==="time"?"fine":""].filter(Boolean).join(" ");return ge.html`<div class="${h}" part="label-track" role="listitem" aria-current="${l?"time":"false"}"><span><strong>${e.planet}</strong>${l?ge.html`<span class="now-badge">${this.t("Now")}</span>`:ge.nothing} </span><span class="${d}"><span class="bar-fill" style="width:${o}%"></span> ${c>=0?ge.html`<span class="bar-progress" style="left:${c*o}%" aria-hidden="true"></span>`:ge.nothing} </span><span class="dates">${Kc(this.effectiveLang(),e.startDate,e.endDate,r)} </span>${p?ge.html`<span class="houses">${this.t("Signifies {{houses}}",{houses:p})}</span>`:ge.nothing}</div>`}};da.endpoints=dl,da.styles=[u,W,Se,me,ot,ge.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}.nakshatra{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.current{gap:var(--roxy-space-md) var(--roxy-space-lg);border-block-end:1px solid var(--roxy-border);flex-wrap:wrap;margin-block-end:var(--roxy-space-md);padding-block-end:var(--roxy-space-md);display:flex}.current>div{align-content:start;min-width:0;display:grid}.current small{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.parent{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);font-size:var(--roxy-text-sm);color:var(--roxy-muted);margin:0;padding-inline-start:var(--roxy-space-sm)}.timeline{gap:var(--roxy-space-xs);display:grid}.bar{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr) 16ch;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);align-items:center;row-gap:0;display:grid}.bar.now strong,.now-badge{color:var(--roxy-accent-ink)}.now-badge{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.bar-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.6lh;position:relative;overflow:hidden}.bar-fill{background:var(--roxy-accent);opacity:.45;height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.bar-now .bar-fill{opacity:1}.bar-progress{inline-size:var(--roxy-line-thick);background:var(--roxy-accent-ink);position:absolute;inset-block:0}.dates{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;text-align:end}.bar.fine{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr)}.bar.fine .dates{text-align:start;grid-column:1/-1;min-width:0}.bar .houses{min-width:0;color:var(--roxy-muted);font-size:var(--roxy-text-xs);grid-column:1/-1}[role=tabpanel]{padding-top:var(--roxy-space-md)}`],m([(0,On.property)({type:String,reflect:true})],da.prototype,"period",2),m([(0,On.state)()],da.prototype,"view",2),da=m([f("roxy-dasha-timeline")],da);var eo=365.25;function fg(n,a){if(a>=1)return`${b(n,a,1)} years`;let e=a*eo;if(e>=1)return`${b(n,e,e>=10?0:1)} days`;let t=e*24;return t>=1?`${b(n,t,1)} hours`:`${b(n,t*60,0)} minutes`}function xg(n){return n>=2?"year":n>=60/eo?"month":n>=1/eo?"day":"time"}var Y=require("lit"),Wd=require("lit/decorators.js"),ao=require("lit/directives/if-defined.js");var Ud=["title","name","label","heading","overview","summary"],bg=80,vg=80,Lg=3,$g=["imageUrl","image","icon","symbol"],wg=["imageUrl","image"],kg=["affirmation","mantra","motto","quote"],Sg=new Set(["seed"]),Rg=new Set(["id","slug","key"]),Cg=new Set(["calculation","calculations","type","position","count","totalcount","total","limit","offset","page","pagesize","perpage"]),Tg=8,qd=1,Eg=12,Dg=n=>n.toLowerCase().replace(/[_-]/g,""),Yd=n=>/^(has|is)([A-Z_]|$)/.test(n),Ag=/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}(:\d{2}(\.\d+)?)?(Z|[+-]\d{2}:\d{2})?)?$/,Pg=/^[A-Z0-9]+(_[A-Z0-9]+)+$/,Mg=6;function _g(n,a){if(!Number.isInteger(a))return false;let e=n.replace(/([a-z])([A-Z])/g,"$1 $2").split(/[\s_-]+/);return e[e.length-1].toLowerCase()==="year"}function ps(n){return n===null||["string","number","boolean"].includes(typeof n)}function to(n){return n!==null&&typeof n=="object"&&!(Array.isArray(n)&&n.every(ps))}function Zd(n){if(n==null)return true;if(Array.isArray(n))return n.length===0;if(typeof n!="object")return false;let a=Object.values(n);return a.length===0||a.every(Zd)}var fr=class extends g{constructor(){super(...arguments);this.depth=0}renderData(e){return this.depth>=Mg?Y.html`<div class="roxy-empty" role="status">${this.t("Nested data omitted")}</div>`:Y.html`<div class="roxy-card" part="card" aria-label="${this.t("Generic data display")}">${this.renderValue(e)}</div>`}renderValue(e){return e==null?Y.nothing:ps(e)?Y.html`<p>${this.scalarTemplate(e)}</p>`:Array.isArray(e)?this.renderArray(e):this.renderObject(e)}renderArray(e){return e.length===0?Y.html`<div class="roxy-empty" role="status">${this.t("Empty list")}</div>`:e.every(ps)?this.renderChips(e):e.every(r=>r!==null&&typeof r=="object"&&!Array.isArray(r))?this.renderObjectArray(e):Y.html`<ol>${e.map(r=>Y.html`<li>${this.renderValue(r)}</li>`)}</ol>`}renderChips(e){return Y.html`<ul class="roxy-chips">${e.filter(t=>t!==null).map(t=>Y.html`<li>${this.formatScalar(t)}</li>`)}</ul>`}renderObjectArray(e){let t=e.map(h=>this.suppress(h)),r=this.collectKeys(t),s=new Set(r.filter(h=>t.some(x=>typeof x[h]=="string"&&Array.from(x[h]).length>vg))),i=new Set(r.filter(h=>s.has(h)||t.some(x=>to(x[h]??null)))),o=s.size>0||i.size>0&&i.size<r.length,l=h=>o?i.has(h)?"col-wide":"col-tight":"",c=i.size>0&&r.length>Lg,d=t.length>Eg;return Y.html`<div class="${c?"roxy-collection":d&&!c?"roxy-collection compact long":"roxy-collection compact"}" part="table" role="${c?"list":"group"}" aria-label="${c?this.t("{{count}} rows",{count:t.length}):this.t("Data table")}" tabindex="${c?Y.nothing:"0"}">${c?Y.html`${d?Y.html`<p>${this.t("{{count}} rows",{count:t.length})}</p>`:Y.nothing} ${t.map(h=>Y.html`<div class="roxy-record" role="listitem">${this.renderField(h)}</div>`)}`:Y.html`<table class="${s.size?"roxy-table stacked prose":i.size?"roxy-table stacked":"roxy-table"}" role="table">${d?Y.html`<caption>${this.t("{{count}} rows",{count:t.length})}</caption>`:Y.nothing}<thead><tr>${r.map(h=>Y.html`<th class="${l(h)}">${ke(this.effectiveLang(),h)}</th>`)}</tr></thead><tbody>${t.map(h=>Y.html`<tr>${r.map(x=>Y.html`<td class="${l(x)}" data-label="${ke(this.effectiveLang(),x)}">${this.renderCell(h[x],x)}</td>`)}</tr>`)}</tbody></table>`}</div>`}suppress(e){let t=Ss(e),r=Ud.some(s=>typeof t[s]=="string");return Object.fromEntries(Object.entries(t).filter(([s])=>{let i=Dg(s);return Sg.has(i)||r&&Rg.has(i)?false:!Cg.has(i)}))}renderObject(e){let t=this.suppress(e),r=Ud.find(p=>typeof t[p]=="string"&&t[p].length<=bg),s=$g.find(p=>typeof t[p]=="string"&&t[p].startsWith("http")),i=r!=="summary"&&typeof t.summary=="string"?"summary":null,o=kg.find(p=>typeof t[p]=="string"),l=Object.entries(t).filter(([p,h])=>p!==r&&p!==i&&p!==o&&!wg.includes(p)&&!Zd(h)),c=l.filter(([,p])=>!to(p)),d=l.filter(([,p])=>to(p));return Y.html`${s?Y.html`<img class="roxy-image" src="${String(t[s])}" alt="${r?String(t[r]):this.t("illustration")}" loading="lazy">`:Y.nothing} ${r?this.depth===0?Y.html`<h2 class="roxy-title" part="header">${t[r]}</h2>`:Y.html`<h3 class="roxy-title" part="header">${t[r]}</h3>`:Y.nothing} ${i?Y.html`<p class="roxy-summary">${t[i]}</p>`:Y.nothing} ${o?Y.html`<blockquote class="roxy-quote">${t[o]}</blockquote>`:Y.nothing} ${c.length>0?Y.html`<dl class="roxy-rows" part="details label-track">${c.map(([p,h])=>Y.html`<dt>${ke(this.effectiveLang(),p)}</dt><dd>${this.renderField(h,p)}</dd>`)}</dl>`:Y.nothing} ${d.map(([p,h])=>this.renderSection(p,h))}`}renderSection(e,t){let r=t!==null&&typeof t=="object"?Array.isArray(t)?t.length:Object.keys(t).length:0,s=this.renderField(t,e),i=ke(this.effectiveLang(),e);return r>Tg||this.depth>=qd?Y.html`<details class="roxy-section" ?open="${this.depth<qd}"><summary>${i}</summary>${s}</details>`:Y.html`<div class="roxy-section">${this.depth===0?Y.html`<h3>${i}</h3>`:Y.html`<h4>${i}</h4>`} ${s}</div>`}renderField(e,t){return e==null?"":e===true&&t!==void 0&&Yd(t)?Y.html`<span class="roxy-chip">${this.t("Yes")}</span>`:ps(e)?Y.html`${this.scalarTemplate(e,t)}`:Array.isArray(e)&&e.every(ps)?this.renderChips(e):Y.html`<roxy-data bare lang="${(0,ao.ifDefined)(this.effectiveLang())}" .data="${e}" .depth="${this.depth+1}"></roxy-data>`}renderCell(e,t){return e==null?"":e===true&&t!==void 0&&Yd(t)?Y.html`<span class="roxy-chip">${this.t("Yes")}</span>`:ps(e)?this.scalarTemplate(e,t):Array.isArray(e)&&e.every(ps)?e.filter(r=>r!==null).map(r=>this.formatScalar(r)).join(", "):Y.html`<roxy-data bare lang="${(0,ao.ifDefined)(this.effectiveLang())}" .data="${e}" .depth="${this.depth+1}"></roxy-data>`}scalarTemplate(e,t){return nn(e)?Y.html`<a href="${e}" target="_blank" rel="noopener noreferrer">${e}</a>`:this.formatScalar(e,t)}formatScalar(e,t){return typeof e=="number"?t!==void 0&&_g(t,e)?String(e):b(this.effectiveLang(),e,2)||String(e):typeof e=="boolean"?e?this.t("Yes"):this.t("No"):Ag.test(e)?ue(this.effectiveLang(),e):Pg.test(e)?D(e.toLowerCase()):e}collectKeys(e){let t=new Set;for(let r of e)for(let s of Object.keys(r))t.add(s);return Array.from(t)}};fr.styles=[u,Y.css`.roxy-card{padding:var(--roxy-space-md)}.roxy-card a{color:var(--roxy-accent-ink)}:is(h2,h3,h4,p,dl){margin:0}:is(h2,h3).roxy-title{margin-block-end:var(--roxy-space-sm)}.roxy-summary{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-md)}dl.roxy-rows{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:fit-content(25%) minmax(0,1fr);display:grid}dl.roxy-rows dd{word-break:break-word;margin:0}.roxy-collection{min-width:0}.roxy-collection.compact{overflow-x:auto}.roxy-collection.long{max-block-size:20lh}.roxy-record+.roxy-record{margin-block-start:var(--roxy-space-sm)}table.roxy-table{width:100%}table.roxy-table caption{text-align:start}table.roxy-table th{white-space:nowrap}:where(table.roxy-table) :is(th,td).col-tight{white-space:nowrap;width:1%}:where(table.roxy-table.prose) :is(th,td).col-wide{min-width:40ch}.roxy-image{max-width:100%;height:auto;border-radius:var(--roxy-radius-md);margin-block-end:var(--roxy-space-md)}.roxy-section{margin-block-start:var(--roxy-space-md)}.roxy-section>:is(h3,h4,summary){font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);margin-block-end:var(--roxy-space-xs)}blockquote.roxy-quote{margin:var(--roxy-space-md) 0;border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md);font-style:italic}`,ia],m([(0,Wd.property)({attribute:false})],fr.prototype,"depth",2),fr=m([f("roxy-data")],fr);var Yt=require("lit"),np=require("lit/decorators.js"),ip=require("lit/directives/unsafe-html.js");var pa=require("lit");var Bt=400,Ee=20,ft=Bt-2*Ee,qe=Bt/2,Xd=Object.fromEntries(Ie.map(n=>[n.toLowerCase(),n])),so="\u02B3",no="\u1D9C",io="\u02B7";function ro(n){return Ie.indexOf(n)}function Ng(n){let a=Jc(n.graha)??n.graha,e=`${n.isRetrograde?so:""}${n.combust?no:""}${n.war?io:""}`;if(typeof n.longitude!="number"||!Number.isFinite(n.longitude)||n.natalReference)return`${a}${e}`;let{degree:t}=Kt(n.longitude);return`${a} ${t}\xB0${e}`}function zg(n,a,e){let t=[V(n.graha)],r=n.natalReference===true;if(r&&t.push(e("in {{sign}}",{sign:a})),typeof n.longitude=="number"&&Number.isFinite(n.longitude)){let s=Kt(n.longitude),i=String(s.minute).padStart(2,"0");t.push(r?`D1: ${s.degree}\xB0${i}' ${s.sign}`:`${s.degree}\xB0${i}' ${s.sign}`)}if(n.nakshatra?.name){let s=n.nakshatra.pada?` ${e("pada {{n}}",{n:n.nakshatra.pada})}`:"";t.push(`${r?"D1: ":""}${n.nakshatra.name}${s}`)}return n.nakshatra?.lord&&t.push(e("nakshatra lord {{graha}}",{graha:n.nakshatra.lord})),n.awastha&&t.push(n.awastha),n.deeptadi&&t.push(n.deeptadi),n.combust&&t.push(e("combust")),n.war&&t.push(n.war.winner?e("planetary war with {{graha}}, won by {{winner}}",{graha:n.war.opponent,winner:n.war.winner}):e("planetary war with {{graha}}",{graha:n.war.opponent})),n.isRetrograde&&t.push(e("retrograde")),t.join(" \xB7 ")}function oo(n,a,e,t,r,s){let i=t-(n.length-1)*r/2;return n.map((o,l)=>{let c=i+l*r;return T`<text class="planet-text" x=${e} y=${c} text-anchor="middle" dominant-baseline="central">${Ng(o)}<title>${zg(o,a,s)}</title></text>`})}function Gn(n,a={}){let{divisionLabel:e,lagnaOverride:t,states:r,natalReference:s}=a,i=new Set((r?.combustion??[]).map(p=>(p.planet??"").toLowerCase())),o=new Map;for(let p of r?.planetaryWar??[])!p.planet1||!p.planet2||(o.set(p.planet1.toLowerCase(),{opponent:p.planet2,winner:p.winner}),o.set(p.planet2.toLowerCase(),{opponent:p.planet1,winner:p.winner}));let l={};for(let p of Ie)l[p.toLowerCase()]=[];let c=t?Xd[t.toLowerCase()]??"":"",d=c;for(let[p,h]of Object.entries(n??{})){let x=(h?.rashi??"").toLowerCase();if(p==="Lagna"||h?.graha==="Lagna"){c||(d=Xd[x]??"");continue}if(!x||!(x in l))continue;let $=h.graha??p,L=$.toLowerCase();l[x]?.push({graha:$,natalReference:s,longitude:h.longitude,nakshatra:h.nakshatra,isRetrograde:h.isRetrograde,awastha:h.awastha,deeptadi:h.deeptadi,combust:i.has(L)||void 0,war:o.get(L)})}return{lagnaSign:d,placements:l,divisionLabel:e}}var hs=ft/4,Og={Pisces:{col:0,row:0},Aries:{col:1,row:0},Taurus:{col:2,row:0},Gemini:{col:3,row:0},Cancer:{col:3,row:1},Leo:{col:3,row:2},Virgo:{col:3,row:3},Libra:{col:2,row:3},Scorpio:{col:1,row:3},Sagittarius:{col:0,row:3},Capricorn:{col:0,row:2},Aquarius:{col:0,row:1}};function Ig(n){let a=Og[n]??{col:0,row:0};return{x:Ee+a.col*hs,y:Ee+a.row*hs,w:hs,h:hs}}function Gg(n){let a=Ee,e=Ee+hs,t=Ee+2*hs,r=Ee+3*hs,s=Bt-Ee;return T`
|
|
17
|
-
<rect class="line" x=${a} y=${a} width=${
|
|
18
|
-
<line class="line" x1=${a} y1=${e} x2=${
|
|
19
|
-
<line class="line" x1=${a} y1=${r} x2=${
|
|
20
|
-
<line class="line" x1=${e} y1=${a} x2=${e} y2=${
|
|
21
|
-
<line class="line" x1=${r} y1=${a} x2=${r} y2=${
|
|
1
|
+
"use strict";var dn=Object.defineProperty;var rl=Object.getOwnPropertyDescriptor;var vm=Object.getOwnPropertyNames;var Lm=Object.prototype.hasOwnProperty;var $m=(s,a)=>{for(var e in a)dn(s,e,{get:a[e],enumerable:true})},wm=(s,a,e,t)=>{if(a&&typeof a=="object"||typeof a=="function")for(let r of vm(a))!Lm.call(s,r)&&r!==e&&dn(s,r,{get:()=>a[r],enumerable:!(t=rl(a,r))||t.enumerable});return s};var km=s=>wm(dn({},"__esModule",{value:true}),s),m=(s,a,e,t)=>{for(var r=t>1?void 0:t?rl(a,e):a,n=s.length-1,i;n>=0;n--)(i=s[n])&&(r=(t?i(a,e,r):i(r))||r);return t&&r&&dn(a,e,r),r};var nx={};$m(nx,{ROXY_COMPONENTS:()=>_i,ROXY_UI_COMPONENTS:()=>sx,ROXY_UI_VERSION:()=>$s,RoxyAlmanacDay:()=>wa,RoxyAngelNumberCard:()=>nr,RoxyAngelNumberLookup:()=>ir,RoxyArudhaPadas:()=>cr,RoxyAshtakavargaGrid:()=>Sa,RoxyAspectsTable:()=>dr,RoxyAstrocartographyMap:()=>pr,RoxyBaziChart:()=>hr,RoxyBhavChalitTable:()=>mr,RoxyBhavaBalaTable:()=>gr,RoxyBiorhythmChart:()=>Ea,RoxyBodygraph:()=>Aa,RoxyCharaKarakas:()=>xr,RoxyChoghadiyaGrid:()=>br,RoxyCompatibilityCard:()=>Pa,RoxyCompoundNumber:()=>vr,RoxyCrystalCard:()=>Lr,RoxyCrystalGrid:()=>Ma,RoxyDashaTimeline:()=>ya,RoxyData:()=>$r,RoxyDivisionalChart:()=>_a,RoxyDoshaCard:()=>Na,RoxyDoshaConstitution:()=>kr,RoxyDreamCard:()=>Sr,RoxyDreamSearch:()=>Rr,RoxyEndpointForm:()=>De,RoxyEphemerisTable:()=>Oa,RoxyFixedStars:()=>Tr,RoxyFlyingStarChart:()=>Ga,RoxyForecastDigest:()=>Er,RoxyForecastTimeline:()=>Dr,RoxyGematria:()=>Ar,RoxyGocharaTable:()=>Pr,RoxyGunaMilan:()=>Mr,RoxyHdConnection:()=>_r,RoxyHdPenta:()=>zr,RoxyHdTypeCard:()=>Or,RoxyHdVariables:()=>Gr,RoxyHeliacalTable:()=>Ir,RoxyHexagram:()=>Fr,RoxyHoraTable:()=>Br,RoxyHoroscopeCard:()=>xa,RoxyKpChart:()=>Ia,RoxyKpFinanceCard:()=>Hr,RoxyKpPlanetsTable:()=>jr,RoxyKpRulingPlanets:()=>Kr,RoxyKuaCard:()=>Fa,RoxyLocalSpaceCompass:()=>Vr,RoxyLocationSearch:()=>We,RoxyLuckPillars:()=>Ur,RoxyMayanDaySign:()=>ja,RoxyMoonPhase:()=>Ka,RoxyNakshatraCard:()=>qr,RoxyNatalChart:()=>va,RoxyNumerologyCard:()=>Va,RoxyPanchangTable:()=>Ua,RoxyPositionsTable:()=>qa,RoxyProfectionCard:()=>Zr,RoxyReferenceCard:()=>Xr,RoxyRelocationWheel:()=>Jr,RoxyReport:()=>Nt,RoxyShadbalaTable:()=>Qr,RoxySynastryChart:()=>ts,RoxyTarotCard:()=>Ya,RoxyTarotCatalog:()=>Wa,RoxyTarotSpread:()=>Za,RoxyTransitWheel:()=>sa,RoxyTransitsTable:()=>Xa,RoxyUpagrahaTable:()=>as,RoxyVastuMandala:()=>Ja,RoxyVedicAspects:()=>rs,RoxyVedicDaily:()=>ss,RoxyVedicKundli:()=>ia,RoxyVedicPlanetsTable:()=>ns,RoxyWesternPlanetsTable:()=>Yr,RoxyYogaList:()=>Qa,RoxyZodiacCard:()=>er,componentForTool:()=>tl,expandCompact:()=>Ks,roxyDataScript:()=>rd,serializeRoxyData:()=>Ki});module.exports=km(nx);var z=require("lit"),Sd=require("lit/decorators.js");var sl=[{endpoint:"chinese-astrology/calendar/day/{date}",method:"GET",attrs:{mode:"day"}},{endpoint:"chinese-astrology/calendar/monthly",method:"GET",attrs:{mode:"month"}},{endpoint:"chinese-astrology/calendar/auspicious-days",method:"POST",attrs:{mode:"auspicious"}}],nl=[{endpoint:"angel-numbers/numbers/{number}",method:"GET"},{endpoint:"angel-numbers/daily",method:"POST"}],il=[{endpoint:"angel-numbers/lookup",method:"GET"}],ol=[{endpoint:"vedic-astrology/arudha",method:"POST"}],ll=[{endpoint:"vedic-astrology/ashtakavarga",method:"POST"}],cl=[{endpoint:"astrology/aspects",method:"POST"},{endpoint:"astrology/transit-aspects",method:"POST"},{endpoint:"astrology/aspect-patterns",method:"POST"}],dl=[{endpoint:"astrology/astrocartography",method:"POST"}],pl=[{endpoint:"chinese-astrology/bazi/chart",method:"POST"}],hl=[{endpoint:"vedic-astrology/bhav-chalit",method:"POST"}],ml=[{endpoint:"vedic-astrology/bhava-bala",method:"POST"}],gl=[{endpoint:"biorhythm/daily",method:"POST",attrs:{mode:"daily"}},{endpoint:"biorhythm/forecast",method:"POST",attrs:{mode:"forecast"}},{endpoint:"biorhythm/critical-days",method:"POST",attrs:{mode:"critical-days"}}],yl=[{endpoint:"human-design/bodygraph",method:"POST"}],ul=[{endpoint:"vedic-astrology/chara-karakas",method:"POST"}],fl=[{endpoint:"vedic-astrology/panchang/choghadiya",method:"POST"}],xl=[{endpoint:"astrology/compatibility-score",method:"POST",attrs:{mode:"astrology"}},{endpoint:"numerology/compatibility",method:"POST",attrs:{mode:"numerology"}},{endpoint:"biorhythm/compatibility",method:"POST",attrs:{mode:"biorhythm"}}],bl=[{endpoint:"numerology/compound-number/{number}",method:"GET"}],vl=[{endpoint:"crystals/{id}",method:"GET"}],Ll=[{endpoint:"crystals",method:"GET"},{endpoint:"crystals/chakra/{chakra}",method:"GET"},{endpoint:"crystals/element/{element}",method:"GET"},{endpoint:"crystals/zodiac/{sign}",method:"GET"},{endpoint:"crystals/birthstone/{month}",method:"GET"},{endpoint:"crystals/search",method:"GET"}],$l=[{endpoint:"vedic-astrology/dasha/major",method:"POST",attrs:{period:"major"}},{endpoint:"vedic-astrology/dasha/current",method:"POST",attrs:{period:"current"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}",method:"POST",attrs:{period:"sub"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}",method:"POST",attrs:{period:"antara"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}/{pratyantardasha}",method:"POST",attrs:{period:"sookshma"}},{endpoint:"vedic-astrology/dasha/sub/{mahadasha}/{antardasha}/{pratyantardasha}/{sookshma}",method:"POST",attrs:{period:"prana"}}],wl=[{endpoint:"vedic-astrology/divisional-chart",method:"POST"},{endpoint:"vedic-astrology/navamsa",method:"POST"}],kl=[{endpoint:"vedic-astrology/dosha/manglik",method:"POST",attrs:{type:"manglik"}},{endpoint:"vedic-astrology/dosha/kalsarpa",method:"POST",attrs:{type:"kalsarpa"}},{endpoint:"vedic-astrology/dosha/sadhesati",method:"POST",attrs:{type:"sadhesati"}}],Sl=[{endpoint:"ayurveda/constitution",method:"POST"}],Rl=[{endpoint:"dreams/symbols/{id}",method:"GET"}],Cl=[{endpoint:"dreams/symbols",method:"GET"}],Tl=[{endpoint:"astrology/planets/monthly",method:"POST"},{endpoint:"vedic-astrology/planetary-positions/monthly",method:"POST"}],El=[{endpoint:"astrology/fixed-stars",method:"POST"}],Dl=[{endpoint:"feng-shui/flying-stars/natal",method:"POST",attrs:{mode:"natal"}},{endpoint:"feng-shui/flying-stars/annual/{year}",method:"GET",attrs:{mode:"annual"}}],Al=[{endpoint:"forecast/digest",method:"POST"}],Pl=[{endpoint:"forecast/timeline",method:"POST"},{endpoint:"forecast/significant-dates",method:"POST"},{endpoint:"forecast/transits",method:"POST"}],Ml=[{endpoint:"kabbalah/gematria",method:"POST"}],_l=[{endpoint:"vedic-astrology/transit",method:"POST"}],Nl=[{endpoint:"vedic-astrology/compatibility",method:"POST"}],zl=[{endpoint:"human-design/connection",method:"POST"}],Ol=[{endpoint:"human-design/penta",method:"POST"}],Gl=[{endpoint:"human-design/type",method:"POST"},{endpoint:"human-design/profile",method:"POST"}],Il=[{endpoint:"human-design/variables",method:"POST"}],Fl=[{endpoint:"vedic-astrology/heliacal",method:"POST"}],Bl=[{endpoint:"iching/hexagrams/random",method:"GET"},{endpoint:"iching/hexagrams/{number}",method:"GET"},{endpoint:"iching/hexagrams/lookup",method:"GET"},{endpoint:"iching/cast",method:"GET"},{endpoint:"iching/daily",method:"POST"},{endpoint:"iching/daily/cast",method:"POST"}],Hl=[{endpoint:"vedic-astrology/panchang/hora",method:"POST"}],jl=[{endpoint:"astrology/horoscope/{sign}/daily",method:"GET",attrs:{period:"daily"}},{endpoint:"astrology/horoscope/{sign}/weekly",method:"GET",attrs:{period:"weekly"}},{endpoint:"astrology/horoscope/{sign}/monthly",method:"GET",attrs:{period:"monthly"}},{endpoint:"astrology/horoscope/{sign}/yearly",method:"GET",attrs:{period:"yearly"}}],Kl=[{endpoint:"vedic-astrology/kp/chart",method:"POST"}],Vl=[{endpoint:"vedic-astrology/kp/daily-finance",method:"POST"}],Ul=[{endpoint:"vedic-astrology/kp/planets",method:"POST"}],ql=[{endpoint:"vedic-astrology/kp/ruling-planets",method:"POST"}],Yl=[{endpoint:"feng-shui/kua",method:"POST",attrs:{mode:"kua"}},{endpoint:"feng-shui/eight-mansions",method:"POST",attrs:{mode:"mansions"}}],Wl=[{endpoint:"astrology/local-space",method:"POST"}],Zl=[{endpoint:"chinese-astrology/bazi/luck-pillars",method:"POST"}],Xl=[{endpoint:"mesoamerican-astrology/mayan/tzolkin",method:"POST",attrs:{mode:"day"}},{endpoint:"mesoamerican-astrology/mayan/chart",method:"POST",attrs:{mode:"chart"}}],Jl=[{endpoint:"astrology/moon-phase/current",method:"GET",attrs:{mode:"current"}},{endpoint:"astrology/moon-phase/upcoming",method:"GET",attrs:{mode:"upcoming"}},{endpoint:"astrology/moon-phase/calendar/{year}/{month}",method:"GET",attrs:{mode:"calendar"}}],Ql=[{endpoint:"vedic-astrology/nakshatras/{id}",method:"GET"}],ec=[{endpoint:"astrology/natal-chart",method:"POST"}],tc=[{endpoint:"numerology/life-path",method:"POST",attrs:{type:"life-path"}},{endpoint:"numerology/expression",method:"POST",attrs:{type:"expression"}},{endpoint:"numerology/soul-urge",method:"POST",attrs:{type:"soul-urge"}},{endpoint:"numerology/personality",method:"POST",attrs:{type:"personality"}},{endpoint:"numerology/birth-day",method:"POST",attrs:{type:"birth-day"}},{endpoint:"numerology/maturity",method:"POST",attrs:{type:"maturity"}},{endpoint:"numerology/daily",method:"POST",attrs:{type:"daily"}},{endpoint:"numerology/personal-day",method:"POST",attrs:{type:"personal-day"}},{endpoint:"numerology/personal-month",method:"POST",attrs:{type:"personal-month"}},{endpoint:"numerology/personal-year",method:"POST",attrs:{type:"personal-year"}},{endpoint:"numerology/chart",method:"POST",attrs:{type:"chart"}}],ac=[{endpoint:"vedic-astrology/panchang/detailed",method:"POST",attrs:{detail:"detailed"}},{endpoint:"vedic-astrology/panchang/basic",method:"POST",attrs:{detail:"basic"}}],rc=[{endpoint:"astrology/asteroids",method:"POST"},{endpoint:"astrology/lilith",method:"POST"},{endpoint:"astrology/progressions",method:"POST"},{endpoint:"astrology/solar-arc",method:"POST"},{endpoint:"astrology/arabic-lots",method:"POST"}],sc=[{endpoint:"astrology/profections",method:"POST"}],nc=[{endpoint:"astrology/signs/{id}",method:"GET"},{endpoint:"astrology/planet-meanings/{id}",method:"GET"},{endpoint:"vedic-astrology/rashis/{id}",method:"GET"},{endpoint:"iching/trigrams/{id}",method:"GET"},{endpoint:"human-design/gates/{number}",method:"GET"},{endpoint:"human-design/centers/{id}",method:"GET"},{endpoint:"numerology/meanings/{number}",method:"GET"},{endpoint:"vedic-astrology/avasthas/{id}",method:"GET"}],ic=[{endpoint:"astrology/relocation-chart",method:"POST"}],oc=[{endpoint:"reports/natal",method:"POST",attrs:{report:"natal"}},{endpoint:"reports/synastry",method:"POST",attrs:{report:"synastry"}},{endpoint:"reports/kundli",method:"POST",attrs:{report:"kundli"}},{endpoint:"reports/matchmaking",method:"POST",attrs:{report:"matchmaking"}},{endpoint:"reports/yearly-forecast",method:"POST",attrs:{report:"yearly-forecast"}},{endpoint:"reports/human-design",method:"POST",attrs:{report:"human-design"}},{endpoint:"reports/bazi",method:"POST",attrs:{report:"bazi"}},{endpoint:"reports/numerology",method:"POST",attrs:{report:"numerology"}},{endpoint:"reports/tarot",method:"POST",attrs:{report:"tarot"}}],lc=[{endpoint:"vedic-astrology/shadbala",method:"POST"}],cc=[{endpoint:"astrology/synastry",method:"POST"}],dc=[{endpoint:"tarot/daily",method:"POST"},{endpoint:"tarot/cards/{id}",method:"GET"}],pc=[{endpoint:"tarot/cards",method:"GET"}],hc=[{endpoint:"tarot/spreads/three-card",method:"POST",attrs:{spread:"three-card"}},{endpoint:"tarot/spreads/celtic-cross",method:"POST",attrs:{spread:"celtic-cross"}},{endpoint:"tarot/spreads/love",method:"POST",attrs:{spread:"love"}},{endpoint:"tarot/spreads/career",method:"POST",attrs:{spread:"career"}},{endpoint:"tarot/spreads/custom",method:"POST",attrs:{spread:"custom"}},{endpoint:"tarot/yes-no",method:"POST",attrs:{spread:"yes-no"}},{endpoint:"tarot/draw",method:"POST",attrs:{spread:"draw"}}],mc=[{endpoint:"astrology/transit-aspects",method:"POST"}],gc=[{endpoint:"astrology/transits",method:"POST"}],yc=[{endpoint:"vedic-astrology/upagraha",method:"POST"}],uc=[{endpoint:"vastu/mandala",method:"POST",attrs:{mode:"mandala"}},{endpoint:"vastu/entrance",method:"POST",attrs:{mode:"entrance"}}],fc=[{endpoint:"vedic-astrology/aspects",method:"POST"}],xc=[{endpoint:"vedic-astrology/daily",method:"POST"}],bc=[{endpoint:"vedic-astrology/birth-chart",method:"POST"}],vc=[{endpoint:"vedic-astrology/birth-chart",method:"POST"}],Lc=[{endpoint:"astrology/natal-chart",method:"POST"}],$c=[{endpoint:"vedic-astrology/yoga",method:"GET"},{endpoint:"vedic-astrology/yoga/detect",method:"POST"},{endpoint:"vedic-astrology/yoga/{id}",method:"GET"}],wc=[{endpoint:"chinese-astrology/zodiac/sign",method:"POST",attrs:{mode:"sign"}},{endpoint:"chinese-astrology/zodiac/animals/{id}",method:"GET",attrs:{mode:"animal"}},{endpoint:"chinese-astrology/zodiac/{id}/daily",method:"GET",attrs:{mode:"daily"}},{endpoint:"chinese-astrology/zodiac/compatibility/{sign1}/{sign2}",method:"GET",attrs:{mode:"compatibility"}}];var Pe=require("lit"),we=require("lit/decorators.js"),ls=require("lit/directives/if-defined.js");var kc=["de","en","es","fr","hi","pt","ru","tr","zh-Hans","zh-Hant"];function js(s){if(s.lang)return s.lang;if(typeof document>"u")return;let a=s.closest?.("[lang]")?.getAttribute("lang");return a||document.documentElement.lang||void 0}function Sc(s){return!s||s.toLowerCase().split("-")[0]==="en"}var Sm={tw:"hant",hk:"hant",mo:"hant",cn:"hans",sg:"hans",my:"hans"};function Ni(s,a){let e=s.toLowerCase();return a.find(t=>t.toLowerCase()===e)}function pn(s,a=kc){let e=js(s);if(!e)return;let t=Ni(e,a);if(t)return t;let r=e.toLowerCase().split("-"),n=r[0];if(n==="zh"){let i=r.find(o=>o==="hans"||o==="hant")??Sm[r[1]??""];return i?Ni(`zh-${i}`,a):void 0}return Ni(n,a)}var ks=require("lit");var Tc="symbols";var Rm={Fraunces:["latin","latin-ext"],Jost:["latin","latin-ext","cyrillic"],Geist:["latin","latin-ext","cyrillic"]},zi='"Jost", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Rc='"Geist", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',Cc='system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',hn={"fraunces-jost":{name:"Fraunces with Jost",sans:zi,display:'"Fraunces", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif'},jost:{name:"Jost",sans:zi,display:zi},geist:{name:"Geist",sans:Rc,display:Rc},system:{name:"System",sans:Cc,display:Cc}};function Ec(s){let{sans:a,display:e}=hn[s];return Object.keys(Rm).filter(t=>`${a} ${e}`.includes(`"${t}"`))}var Dc=["practitioner","eucalyptus","kiln","moonlit","celeste"];var $s="1.4.0";var Cm=/^(.*)\/cdn\/(?:roxy-ui|components\/[\w-]+)\.js$/,Tm=/^(.*\/dist)\/(?:index|components\/[\w-]+)\.js$/;function mn(s,a){if(!a)return;let e=new URL(a);if(e.protocol!=="https:"&&e.protocol!=="http:")return;let t=(Cm.exec(e.pathname)??Tm.exec(e.pathname))?.[1];if(t!==void 0)return e.hostname==="cdn.jsdelivr.net"?`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${s}/dist`:`${e.origin}${t}`}var Pm={},Em="color-mix(in oklab, var(--roxy-accent) 70%, black)",Dm="var(--roxy-accent)",Am="color-mix(in srgb, var(--roxy-accent) 40%, transparent)",Oi=/^#(?:[\da-f]{3}|[\da-f]{6})$/i;function Gi(s){if(!s||!Oi.test(s))return;let a=s.slice(1).toLowerCase();return`#${a.length===3?a.replace(/./g,"$&$&"):a}`}function gn(s){return s!==void 0&&Object.hasOwn(hn,s)}function Ac(s){return Dc.includes(s)}function Pc(s){let a=[];return s.brandColor&&Oi.test(s.brandColor)&&a.push(`--roxy-primary:${s.brandColor}`),s.brandAccent&&Oi.test(s.brandAccent)&&a.push(`--roxy-accent:${s.brandAccent}`,`--roxy-accent-ink:light-dark(${Em},${Dm})`,`--roxy-ring:${Am}`),a.join(";")}function Mc(s,a){if(gn(a))return a;let e=s.getRootNode();if(("host"in e?e.host:null)?.localName.startsWith("roxy-")||!globalThis.getComputedStyle)return;let r=s.shadowRoot?.firstElementChild,n=r?.localName==="style"?r:null;n?.sheet&&(n.sheet.disabled=true);let i,o,l;try{let c=globalThis.getComputedStyle(s),d=h=>c.getPropertyValue(h).trim();i=d("--roxy-font-sans"),o=d("--roxy-font-display"),l=d("--roxy-font")}finally{n?.sheet&&(n.sheet.disabled=false)}if(!(i||o))return gn(l)?l:void 0}function _c(s){let{sans:a,display:e}=hn[s];return`--roxy-font:${s};--roxy-font-sans:${a};--roxy-font-display:${e}`}var Nc=mn($s,globalThis.document?.currentScript?.src||Pm.url);function zc(s,a){if(typeof document>"u"||a===void 0)return;let e=`roxy-ui-font-${s}`;if(document.getElementById(e))return;let t=document.createElement("link");t.id=e,t.rel="stylesheet",t.href=`${a}/styles/fonts/${s}.css`,document.head.append(t)}function Oc(s,a=Nc){Ec(s).length>0&&zc(s,a)}function Gc(s=Nc){zc(Tc,s)}var Ic='@layer roxy.tokens,roxy.theme;@layer roxy.tokens{:where(:root,:host){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-font: initial;--roxy-font-sans: initial;--roxy-font-mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, "Liberation Mono", monospace;--roxy-font-symbol: "Roxy Symbols", ui-sans-serif, system-ui, sans-serif;--roxy-text-base: 1rem;--roxy-text-scale: 1.15;--roxy-weight-normal: 400;--roxy-weight-bold: 600;--roxy-leading-tight: 1.25;--roxy-leading-normal: 1.5;--roxy-tracking-tight: -0.01em;--roxy-tracking-normal: 0em;--roxy-space-unit: 0.25rem;--roxy-radius: 6px;--roxy-motion-duration: 200ms;--roxy-motion-easing: cubic-bezier(0.4, 0, 0.2, 1)}:where(:root,:host,[data-theme],.light,.dark){--roxy-surface: var(--roxy-bg);--roxy-primary: var(--roxy-fg);--roxy-secondary: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg));--roxy-muted: color-mix(in oklab, var(--roxy-fg) 60%, var(--roxy-bg));--roxy-border: color-mix(in oklab, var(--roxy-fg) 14%, var(--roxy-bg));--roxy-ring: color-mix(in srgb, var(--roxy-accent) 40%, transparent);--roxy-heat: var(--roxy-danger);--roxy-moon-lit: color-mix(in oklab, var(--roxy-accent) 6%, #f6eedf);--roxy-moon-mare: color-mix( in oklab, var(--roxy-moon-lit) 62%, var(--roxy-moon-shade) );--roxy-moon-rim: color-mix( in oklab, var(--roxy-moon-shade) 70%, var(--roxy-fg) );--roxy-moon-eclipse: color-mix( in oklab, color-mix(in oklab, var(--roxy-danger) 55%, var(--roxy-warning)) 72%, var(--roxy-moon-shade) );--roxy-moon-corona: color-mix( in oklab, var(--roxy-warning) 60%, var(--roxy-moon-lit) );--roxy-font-display: var(--roxy-font-sans);--roxy-text-sm: calc(var(--roxy-text-base) / var(--roxy-text-scale));--roxy-text-xs: calc(var(--roxy-text-sm) / var(--roxy-text-scale));--roxy-text-lg: calc(var(--roxy-text-base) * var(--roxy-text-scale));--roxy-text-xl: calc( var(--roxy-text-lg) * var(--roxy-text-scale) * var(--roxy-text-scale) );--roxy-space-xs: var(--roxy-space-unit);--roxy-space-sm: calc(var(--roxy-space-unit) * 2);--roxy-space-md: calc(var(--roxy-space-unit) * 4);--roxy-space-lg: calc(var(--roxy-space-unit) * 6);--roxy-space-xl: calc(var(--roxy-space-unit) * 10);--roxy-line-thick: calc(var(--roxy-space-unit) / 2);--roxy-touch: calc(var(--roxy-space-unit) * 11);--roxy-radius-sm: calc(var(--roxy-radius) / 2);--roxy-radius-md: var(--roxy-radius);--roxy-radius-lg: calc(var(--roxy-radius) * 5 / 3);--roxy-radius-full: 9999px;--roxy-shadow-sm: none;--roxy-shadow-md: 0 4px 12px color-mix(in srgb, black 10%, transparent);--roxy-shadow-lg: 0 12px 32px color-mix(in srgb, black 18%, transparent)}@media(prefers-color-scheme:dark){:where(:root,:host){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white);--roxy-moon-shade: color-mix( in oklab, var(--roxy-fg) 10%, var(--roxy-bg) )}}:where(:root[data-theme=light],[data-theme=light],:root.light,.light,:host([data-theme="light"])){color-scheme:light;--roxy-bg: #ffffff;--roxy-fg: #0a0a0a;--roxy-accent: #4a6297;--roxy-success: #16a34a;--roxy-warning: #ea580c;--roxy-danger: #dc2626;--roxy-info: #0284c7;--roxy-accent-ink: color-mix(in oklab, var(--roxy-accent) 70%, black);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, black);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, black);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, black);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, black);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 78%, var(--roxy-bg))}:where(:root[data-theme=dark],[data-theme=dark],:root.dark,.dark,:host([data-theme="dark"])){color-scheme:dark;--roxy-bg: #0a0a0a;--roxy-fg: #fafafa;--roxy-accent: #92aade;--roxy-success: #22c55e;--roxy-warning: #fb923c;--roxy-danger: #ef4444;--roxy-info: #38bdf8;--roxy-accent-ink: var(--roxy-accent);--roxy-success-fg: color-mix(in oklab, var(--roxy-success) 70%, white);--roxy-warning-fg: color-mix(in oklab, var(--roxy-warning) 70%, white);--roxy-danger-fg: color-mix(in oklab, var(--roxy-danger) 70%, white);--roxy-info-fg: color-mix(in oklab, var(--roxy-info) 70%, white);--roxy-moon-shade: color-mix(in oklab, var(--roxy-fg) 10%, var(--roxy-bg))}@media(prefers-reduced-motion:reduce){:where(:root,:host){--roxy-motion-duration: 0ms}}}';var Fc="roxy-ui-tokens";function Bc(){if(typeof document>"u")return null;let s=document.getElementById(Fc);if(s)return s;let a=document.createElement("style");return a.id=Fc,a.textContent=Ic,document.head.prepend(a),a}function $t(s){return s.toLowerCase().replace(/[\s_-]+/g," ").trim()}function U(s){return s?s.charAt(0).toUpperCase()+s.slice(1).toLowerCase():""}function D(s){return s.replace(/[_-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([a-z])([0-9])/g,"$1 $2").replace(/^\w/,a=>a.toUpperCase())}function yn(s){return typeof s=="string"&&/^https?:\/\//.test(s)}var Hc="__ROXY_UI_I18N__";function Ii(){let s=globalThis,a=s[Hc];if(a)return a;let e={catalogs:{},fieldLabels:{},requested:new Set,listeners:new Set};return s[Hc]=e,e}function Fi(s,a){return a?s.replace(/\{\{(\w+)\}\}/g,(e,t)=>t in a?String(a[t]??""):e):s}function un(s,a,e){return Fi(Bi(s,a)??a,e)}function Bi(s,a){if(!s)return;let{catalogs:e}=Ii(),t=s.toLowerCase();return(e[t]??e[t.split("-")[0]])?.[$t(a)]}function jc(s){if(!s)return;let{fieldLabels:a}=Ii(),e=s.toLowerCase();return a[e]??a[e.split("-")[0]]}function ws(s,a){return jc(s)?.fields[a]}function Kc(s,a,e){return jc(s)?.enums[`${a}.${e}`]}function Vc(s){let{listeners:a}=Ii();return a.add(s),()=>{a.delete(s)}}var fn=class{constructor(a){this.host=a,a.addController(this)}hostConnected(){this.unsubscribe=Vc(()=>this.host.requestUpdate())}hostDisconnected(){this.unsubscribe?.(),this.unsubscribe=void 0}};var tr=class extends ks.LitElement{constructor(){super();this.translator=(e,t)=>this.t(e,t);new fn(this)}connectedCallback(){super.connectedCallback(),Bc()}updated(e){super.updated(e),this.renderRoot.querySelector(".roxy-glyph")&&Gc()}fontDeclarations(e){let t=Mc(this,e);return t?(Oc(t),_c(t)):""}renderFontStyle(){let e=this.fontDeclarations();return e?ks.html`<style>:host{${e}}</style>`:ks.nothing}t(e,t){return un(this.effectiveLang(),e,t)}effectiveLang(){return js(this)}};var Wc=require("lit");var Ss=require("lit"),Uc=Ss.css`:where(.roxy-glyph){font-family:var(--roxy-font-symbol)}`;function Je(s){return s?Ss.html`<span class="roxy-glyph" aria-hidden="true">${s}</span>`:Ss.nothing}var qc=require("lit"),Yc=qc.css`:where([part~=card]){background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);box-shadow:var(--roxy-shadow-sm)}:where([part~=card] [part~=card],[part~=card] [part~=reading],[part~=card] .roxy-card){border:0;border-block-start:1px solid var(--roxy-border);box-shadow:none;background:0 0;border-radius:0;padding-inline:0}:host([bare]) [part~=card]{box-shadow:none;background:0 0;border:0;border-radius:0;padding:0}:where(h1,h2){color:var(--roxy-fg);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-tight);text-wrap:balance}:where(h3,h4,h5,h6){color:var(--roxy-fg);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-label,th,dt){color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);letter-spacing:var(--roxy-tracking-normal);text-transform:none}:where(.roxy-chips){gap:var(--roxy-space-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}:where(.roxy-chip,.roxy-chips>li){align-items:center;gap:var(--roxy-space-xs);padding:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-tight);overflow-wrap:anywhere;background:0 0;max-inline-size:100%;display:inline-flex}:where(.roxy-chip[data-tone=success],.roxy-chips>li[data-tone=success]){color:var(--roxy-success-fg)}:where(.roxy-chip[data-tone=warning],.roxy-chips>li[data-tone=warning]){color:var(--roxy-warning-fg)}:where(.roxy-chip[data-tone=danger],.roxy-chips>li[data-tone=danger]){color:var(--roxy-danger-fg)}:where(.roxy-chip[data-tone=info],.roxy-chips>li[data-tone=info]){color:var(--roxy-info-fg)}:where(table){border-collapse:collapse;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:where(th,td){padding:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;vertical-align:top}:where(summary){cursor:pointer}:where(a,button,summary,input,select,textarea,[tabindex]):focus-visible{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}:where(summary:focus-visible){border-radius:var(--roxy-radius-sm)}:where(input,select,textarea,button){font:inherit}:where(input:not([type=checkbox],[type=radio],[type=range]),select,textarea){padding:var(--roxy-space-xs) var(--roxy-space-sm);background:var(--roxy-bg);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md)}`;var Mm=Wc.css`:host{--roxy-label-col:minmax(0, 25%);--_mask:var(--roxy-surface);font-family:var(--roxy-font-sans);color:var(--roxy-fg);font-size:var(--roxy-text-base);line-height:var(--roxy-leading-normal);animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing) both;background:0 0;display:block;container-type:inline-size}:host([bare]){--_mask:var(--roxy-bg)}:host([hidden]){display:none}:host([bare]){--roxy-surface:transparent;--roxy-shadow-sm:none;--roxy-shadow-md:none}*,:before,:after{box-sizing:border-box}h1,h2,h3,h4{font-family:var(--roxy-font-display)}@keyframes roxy-fade-in{0%{transform:translateY(calc(var(--roxy-space-unit) / 2))}to{transform:translateY(0)}}@media (prefers-reduced-motion:reduce){:host{animation:none}}.roxy-skeleton{background:linear-gradient(90deg, var(--roxy-border) 0%, color-mix(in srgb, var(--roxy-border) 60%, transparent) 50%, var(--roxy-border) 100%);border-radius:var(--roxy-radius-md);background-size:200% 100%;animation:1.4s ease-in-out infinite roxy-shimmer}@keyframes roxy-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}@media (prefers-reduced-motion:reduce){.roxy-skeleton{animation:none}}.roxy-sr-only{clip-path:inset(50%);white-space:nowrap;border:0;width:1px;height:1px;margin:0;padding:0;position:absolute;overflow:hidden}.roxy-empty{padding:var(--roxy-space-lg);color:var(--roxy-muted);text-align:center;font-size:var(--roxy-text-sm)}.roxy-error{gap:var(--roxy-space-sm);padding:var(--roxy-space-lg);background:var(--roxy-surface);border:1px solid var(--roxy-danger);border-radius:var(--roxy-radius-md);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);justify-items:start;display:grid}:host(:focus-within) .roxy-card{outline:var(--roxy-line-thick) solid var(--roxy-ring);outline-offset:var(--roxy-line-thick)}.roxy-attribution{margin-top:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);text-align:right}.roxy-attribution a{color:inherit;text-decoration:none}.roxy-attribution a:hover{color:var(--roxy-accent-ink);text-decoration:underline}.roxy-edit-bar{margin-bottom:var(--roxy-space-sm);justify-content:flex-end;display:flex}.roxy-edit{padding:var(--roxy-space-xs) var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-family:inherit;font-size:var(--roxy-text-sm);cursor:pointer;background:0 0}.roxy-edit:hover{border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-edit:disabled{cursor:progress;color:var(--roxy-muted)}roxy-endpoint-form+*{margin-top:var(--roxy-space-md)}.roxy-more{justify-items:center;gap:var(--roxy-space-sm);margin-top:var(--roxy-space-md);display:grid}.roxy-more .roxy-edit{min-height:var(--roxy-touch)}:host{font-variant-emoji:text}`,u=[Mm,Yc,Uc];var _m="__cols",Nm="__rows";function zm(s){return typeof s=="object"&&s!==null&&!Array.isArray(s)}function xn(s){if(Array.isArray(s)){let n=false,i=s.map(o=>{let l=xn(o);return l!==o&&(n=true),l});return n?i:s}if(!zm(s))return s;let a=s[_m],e=s[Nm];if(Array.isArray(a)&&Array.isArray(e)&&Object.keys(s).length===2)return e.map(n=>{let i={};return a.forEach((o,l)=>{i[o]=xn(n[l])}),i});let t=false,r={};for(let[n,i]of Object.entries(s)){let o=xn(i);o!==i&&(t=true),r[n]=o}return t?r:s}function Ks(s){return xn(s)}function Zc(s,a){return s.find(e=>e.attrs&&Object.entries(e.attrs).every(([t,r])=>a[t]===r))??s[0]}var Om="pk_live_YOUR_KEY",Xc={secret:{reason:"possible-secret-key",message:"Client-side components accept a pk_ publishable key only. Use a publishable key with an origin allowlist, or render server-side."},sample:{reason:"sample-key",message:"Replace the sample key with your own publishable key from your RoxyAPI account."}};function is(s){if(s)return s===Om?Xc.sample:s.startsWith("pk_")?void 0:Xc.secret}function Rs(s,a,e={}){e.warn&&console.warn(a.message),s.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{reason:a.reason,message:a.message},bubbles:true,composed:true}))}var Ts="https://roxyapi.com/api/v2";async function Jc(s){return(await Qc(s)).message}async function Qc(s){try{let a=await s.json();if(a?.error){let e=a.code==="validation_error"&&Array.isArray(a.issues)?a.issues.filter(t=>typeof t.path=="string"&&typeof t.message=="string").map(t=>({path:t.path,message:t.message})):null;return{message:a.error,issues:e?.length?e:null,worded:true,...a.code?{code:a.code}:{}}}}catch{}return{message:`Request failed (${s.status})`,issues:null,worded:false}}var vn={fromAttribute:s=>{if(s!=null){try{let a=JSON.parse(s);if(a&&typeof a=="object"&&!Array.isArray(a))return a}catch{}console.warn("[roxy-ui] submit-context must be a JSON object; sending the request without it.")}}},Cs=class extends Error{constructor(e,t=null,r=true,n,i){super(e);this.issues=t;this.worded=r;this.status=n;this.code=i}};function Hi(s){return s.submitUrl?void 0:is(s.publishableKey)}function ji(s){return!!(s.submitUrl||s.publishableKey&&!Hi(s))}async function ar(s,a,e){let t=Hi(s);if(t)throw new Cs(t.message);let r=s.submitUrl?await fetch(s.submitUrl,{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:Gm(a,s.submitContext),signal:e}):await Im(s,a,e);if(!r.ok){let n=await Qc(r);throw new Cs(n.message,n.issues,n.worded,r.status,n.code)}return await r.json()}function Gm(s,a){return JSON.stringify(a?{...s,context:a}:s)}function Im(s,a,e){let t=new URL(`${s.baseUrl??Ts}${a.path}`,document.baseURI);for(let[n,i]of Object.entries(a.query??{}))i!=null&&t.searchParams.set(n,String(i));let r={Accept:"application/json"};return s.publishableKey&&(r["X-API-Key"]=s.publishableKey),a.body!=null&&(r["Content-Type"]="application/json"),fetch(t,{method:a.method??"GET",headers:r,body:a.body!=null?JSON.stringify(a.body):void 0,signal:e})}var bn=class{constructor(a){this.baseUrl=Ts;this.worded=true;this.failure={};this.host=a,a.addController(this)}hostDisconnected(){this.abort?.abort(),this.abort=void 0}async run(a){this.worded=true,this.failure={};let e=Hi(this);if(e){this.host.error=e.message,Rs(this.host,e);return}this.abort?.abort();let t=new AbortController;this.abort=t,this.host.loading=true,this.host.error=null,this.host.issues=null;try{let r=await ar(this,a,t.signal);if(t.signal.aborted)return;this.host.data=r}catch(r){if(t.signal.aborted||r?.name==="AbortError")return;r instanceof Cs&&(this.host.issues=r.issues,this.failure={status:r.status,code:r.code}),this.worded=r instanceof Cs&&r.worded,this.host.error=r instanceof Error?r.message:String(r)}finally{this.abort===t&&(this.abort=void 0),t.signal.aborted||(this.host.loading=false)}}};function ed(s,a,e,t=[]){let r={...e},n=`/${s.replace(/^\//,"")}`.replace(/\{([^}]+)\}/g,(c,d)=>{let h=r[d];return delete r[d],encodeURIComponent(String(h??""))}),i=new Set(t),o={},l={};for(let[c,d]of Object.entries(r))d===void 0||d===""||(a==="GET"||i.has(c)?o[c]=d:l[c]=d);return{path:n,method:a,query:o,body:a==="POST"?l:void 0}}var it=require("lit");var Ln=require("lit");function he(){return Ln.html`<svg class="roxy-chevron" viewBox="0 0 16 16" width="14" height="14" aria-hidden="true"><path d="M4 6l4 4 4-4" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>`}var X=Ln.css`summary{list-style:none}summary::-webkit-details-marker{display:none}.roxy-chevron{aspect-ratio:auto;width:.7lh;height:.7lh;color:var(--roxy-muted);transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0}details[open]>summary .roxy-chevron{transform:rotate(180deg)}@media (prefers-reduced-motion:reduce){.roxy-chevron{transition:none}}`;var me=it.css`.block{border-top:1px solid var(--roxy-border);padding-top:var(--roxy-space-md)}.block h3{margin:0 0 var(--roxy-space-sm)}.interp-card{padding-block:var(--roxy-space-sm)}.interp-card summary{font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:flex}.interp-lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;flex:auto;order:1;min-width:0;display:inline-flex}.interp-aside{align-items:center;gap:var(--roxy-space-sm);flex-shrink:0;order:2;display:inline-flex}.roxy-chevron{order:3}.interp-aside small{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);white-space:nowrap}@container (width<=26rem){.interp-card summary{flex-wrap:wrap}.roxy-chevron{order:2}.interp-aside{flex-basis:100%;order:3;justify-content:flex-end}}.interp-body{margin-top:var(--roxy-space-sm);gap:var(--roxy-space-sm);color:var(--roxy-fg);font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-normal);overflow-wrap:anywhere;display:grid}.interp-body p{margin:0}`;function os(s){return s?.length?it.html`<div class="interp-keywords roxy-chips">${s.map(a=>it.html`<span class="roxy-chip">${a}</span>`)}</div>`:it.nothing}function Vs(s,a){if(!s)return it.nothing;let e=(t,r)=>r?it.html`<p><strong>${a(t)}</strong> ${r}</p>`:it.nothing;return it.html`${s.summary?it.html`<p>${s.summary}</p>`:it.nothing} ${e("Impact:",s.impact)}${e("Timing:",s.timing)}${e("Guidance:",s.guidance)} ${os(s.keywords)}`}function td(s,a,e){let t=s.filter(r=>!!r.body);return t.length===0?it.nothing:it.html`<section class="block" part="section readings"><h3>${e}</h3>${t.map((r,n)=>it.html`<details class="interp-card" part="reading" name="${a}" ?open="${n===0}"><summary><span class="interp-lead">${Je(r.glyph)} ${r.label}</span> ${he()} ${r.aside?it.html`<span class="interp-aside"><small>${r.aside}</small></span>`:it.nothing}</summary><div class="interp-body"><p>${r.body}</p>${r.extra??it.nothing}</div></details>`)}</section>`}var ad="roxy-data";function Ki(s){return JSON.stringify(s).replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}function rd(s){return`<script type="application/json" class="${ad}">${Ki(s)}<\/script>`}function Fm(s){return s.nodeName==="SCRIPT"&&s.getAttribute("type")==="application/json"}var $n=class{constructor(a){this.host=a,a.addController(this)}hostConnected(){if(this.host.data!=null)return;let a=this.read();a!==void 0&&(this.host.data=a,this.host.requestUpdate())}read(){let a=this.findInlineScript();return a?this.parse(a.textContent):void 0}findInlineScript(){for(let a of Array.from(this.host.children))if(Fm(a)&&a.classList.contains(ad))return a;return null}parse(a){if(a?.trim())try{return JSON.parse(a)}catch{return}}};var g=class extends tr{constructor(){super();this.data=null;this.endpoint="";this.remember=false;this.hideReadings=false;this.hideSections="";this.loading=false;this.error=null;this.issues=null;this.selfFetched=false;this.editing=false;this.sticky=false;this.hostLoaded=false;this.moreLoading=false;this.moreError=null;this.onMore=async()=>{let e=this.lastRequest,t=this.listKey,r=this.listRows();if(!(!e||!t||!r)){this.moreLoading=true,this.moreError=null;try{let n=await ar(this.fetcher,{...e,query:{...e.query,offset:r.length}});if(this.lastRequest!==e)return;let i=n[t];this.data={...this.data,...n,[t]:[...r,...Array.isArray(i)?i:[]]}}catch(n){this.lastRequest===e&&(this.moreError=n instanceof Error?n.message:String(n))}finally{this.moreLoading=false}}};this.onEdit=()=>{this.editing=true};this.onFormSubmit=e=>{let t=this.selfFetch();if(!t)return;let r=e.detail;this.lastValues=r.values,this.sticky=!!r.sticky,this.selfFetched=true,this.editing=false,this.remember&&this.writeRemembered(r.values),this.fetchFresh(ed(t.endpoint,t.method,{...r.values,...this.ownRequest()},r.queryKeys??[]))};new $n(this),this.fetcher=new bn(this)}static{this.styles=[u]}static{this.endpoints=[]}willUpdate(e){if(e.has("data")&&this.data!=null){let t=Ks(this.data);t!==this.data&&(this.data=t)}(e.has("publishableKey")||e.has("baseUrl")||e.has("submitUrl")||e.has("submitContext"))&&this.syncFetcher()}syncFetcher(){this.fetcher.publishableKey=this.publishableKey,this.baseUrl&&(this.fetcher.baseUrl=this.baseUrl),this.fetcher.submitUrl=this.submitUrl,this.fetcher.submitContext=this.submitContext}selfFetch(){let e=this.endpoint?{endpoint:this.endpoint,method:"POST"}:this.hostLoaded||!(this.publishableKey||this.submitUrl)?void 0:Zc(this.constructor.endpoints,this);return e&&{endpoint:e.endpoint,method:this.method??e.method}}render(){return Pe.html`${this.hostStyle()}${this.renderState()}`}drawn(e){try{return this.renderData(e)}catch(t){return console.warn(`[roxy-ui] ${this.localName} could not draw its response`,t),this.dispatchEvent(new CustomEvent("roxy-render-error",{detail:{error:t},bubbles:true,composed:true})),customElements.get("roxy-data")?Pe.html`<roxy-data .data="${e}" lang="${(0,ls.ifDefined)(this.effectiveLang())}"></roxy-data>`:this.renderEmpty()}}hostStyle(){let e=this.hideSections.split(",").map(n=>n.trim().toLowerCase()).filter(n=>/^[a-z][a-z0-9-]*$/.test(n)),t=[Pc(this),this.fontDeclarations(this.font)].filter(Boolean).join(";");if(e.length===0&&!t)return Pe.nothing;let r=(t?`:host{${t}}`:"")+e.map(n=>`[part~="${n}"],roxy-endpoint-form::part(${n}){display:none!important}`).join("");return Pe.html`<style>${r}</style>`}ownRequest(){return{}}get failure(){return this.fetcher.failure}renderState(){return this.selfFetch()&&this.sticky&&this.selfFetched&&!this.editing?this.renderWithForm(this.stickyBody()):this.loading?this.renderLoading():this.error!=null?this.renderError(this.error):this.data!=null?this.selfFetched?this.editing?this.renderForm():this.renderResult(this.data):this.showAttribution()?Pe.html`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data):this.renderNoData()}renderInterpretation(e,t,r){return this.hideReadings?Pe.nothing:td(e,t,this.t(r??"Reading"))}renderResult(e){let t=Pe.html`<div class="roxy-edit-bar" part="edit-bar"><button type="button" class="roxy-edit" @click="${this.onEdit}">${this.t("Edit query")}</button></div>${this.drawn(e)}`;return this.showAttribution()?Pe.html`${t}${this.renderAttribution()}`:t}renderWithForm(e){return Pe.html`${this.renderForm()}${e}`}stickyBody(){return this.loading?this.renderLoading():this.error!=null?this.issues?Pe.nothing:this.renderErrorBanner(this.error):this.data==null?Pe.nothing:this.showAttribution()?Pe.html`${this.drawn(this.data)}${this.renderAttribution()}`:this.drawn(this.data)}renderMore(){let e=this.listRows(),t=this.data?.total;return!this.lastRequest||!e||typeof t!="number"?Pe.nothing:e.length>=t?Pe.nothing:Pe.html`<div class="roxy-more" part="more"><button type="button" class="roxy-edit" ?disabled="${this.moreLoading}" aria-busy="${this.moreLoading?"true":"false"}" @click="${this.onMore}">${this.t("Show more")}</button> ${this.moreError?Pe.html`<p class="roxy-error" role="alert">${this.t(this.moreError)}</p>`:Pe.nothing}</div>`}listRows(){let e=this.listKey?this.data?.[this.listKey]:void 0;return Array.isArray(e)?e:void 0}fetchFresh(e){return this.lastRequest=e,this.openedRow=void 0,this.openedRowId=void 0,this.moreError=null,this.fetcher.run(e)}load(e){return this.hostLoaded=true,this.syncFetcher(),this.fetchFresh(e)}pickRow(e){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:e,bubbles:true,composed:true})),this.openRow(e.id)}openRow(e){if(!this.rowDetail||!(this.publishableKey||this.submitUrl))return;let t=this.openedRow??document.createElement(this.rowDetail.tag);t.publishableKey=this.publishableKey,t.baseUrl=this.baseUrl,t.submitUrl=this.submitUrl,t.submitContext=this.submitContext,t.hideReadings=this.hideReadings,t.hideSections=this.hideSections;let r=this.effectiveLang();r&&t.setAttribute("lang",r),this.openedRow=t,this.openedRowId=e,t.load({path:`/${this.rowDetail.path.replace("{id}",encodeURIComponent(e))}`,method:"GET",query:{lang:pn(this)}}).then(()=>t.scrollIntoView?.({block:"nearest"}))}showAttribution(){return this.attribution!=null&&this.attribution!=="off"&&this.attribution!=="false"}renderAttribution(){return Pe.html`<div class="roxy-attribution" part="attribution"><a href="https://roxyapi.com/?utm_source=widget&utm_medium=embed" target="_blank" rel="noopener">${this.t("Spiritual data by RoxyAPI")}</a></div>`}renderNoData(){return this.selfFetch()?this.renderWithForm(Pe.nothing):this.renderEmpty()}renderForm(){let e=this.selfFetch();return Pe.html`<roxy-endpoint-form part="form" exportparts="hint" data-endpoint="${e?.endpoint??""}" method="${e?.method??"POST"}" spec-url="${(0,ls.ifDefined)(this.specUrl)}" publishable-key="${(0,ls.ifDefined)(this.publishableKey)}" location-url="${(0,ls.ifDefined)(this.locationUrl)}" submit-label="${(0,ls.ifDefined)(this.submitLabel)}" lang="${(0,ls.ifDefined)(this.effectiveLang())}" .initialValues="${this.formInitialValues()}" .serverIssues="${this.issues}" .apiRoute="${this.fetcher}" .autoload="${!this.selfFetched}" .fullPages="${!!this.listKey}" @roxy-submit="${this.onFormSubmit}"></roxy-endpoint-form>`}formInitialValues(){return this.lastValues??(this.remember?this.readRemembered():void 0)}rememberKey(){return`roxy-ui:form:${this.selfFetch()?.endpoint??""}`}readRemembered(){try{let e=sessionStorage.getItem(this.rememberKey());return e?JSON.parse(e):void 0}catch{return}}writeRemembered(e){try{sessionStorage.setItem(this.rememberKey(),JSON.stringify(e))}catch{}}renderEmpty(){return Pe.html`<div class="roxy-empty" role="status" part="empty">${this.t("No data")}</div>`}renderLoading(){return Pe.html`<div class="roxy-skeleton" style="height:5lh" role="status" aria-label="${this.t("Loading")}" part="loading"></div>`}renderError(e){let t=!!this.selfFetch();if(t&&this.issues)return this.renderForm();let r=this.renderErrorBanner(e);return t?Pe.html`${r}${this.renderForm()}`:r}renderErrorBanner(e){return Pe.html`<div class="roxy-error" role="alert" part="error">${!this.fetcher.worded&&this.errorMessage||this.t(e)}</div>`}};m([(0,we.property)({attribute:false})],g.prototype,"data",2),m([(0,we.property)({type:String,attribute:"data-endpoint"})],g.prototype,"endpoint",2),m([(0,we.property)({type:String})],g.prototype,"method",2),m([(0,we.property)({type:String,attribute:"publishable-key"})],g.prototype,"publishableKey",2),m([(0,we.property)({type:String,attribute:"base-url"})],g.prototype,"baseUrl",2),m([(0,we.property)({type:String,attribute:"spec-url"})],g.prototype,"specUrl",2),m([(0,we.property)({type:String,attribute:"submit-url"})],g.prototype,"submitUrl",2),m([(0,we.property)({attribute:"submit-context",converter:vn})],g.prototype,"submitContext",2),m([(0,we.property)({type:String,attribute:"location-url"})],g.prototype,"locationUrl",2),m([(0,we.property)({type:Boolean})],g.prototype,"remember",2),m([(0,we.property)({type:Boolean,attribute:"hide-readings",reflect:true})],g.prototype,"hideReadings",2),m([(0,we.property)({type:String,attribute:"hide-sections",reflect:true})],g.prototype,"hideSections",2),m([(0,we.property)({type:String,attribute:"brand-color"})],g.prototype,"brandColor",2),m([(0,we.property)({type:String,attribute:"brand-accent"})],g.prototype,"brandAccent",2),m([(0,we.property)({type:String})],g.prototype,"font",2),m([(0,we.property)({type:String})],g.prototype,"hemisphere",2),m([(0,we.property)({type:String,attribute:"submit-label"})],g.prototype,"submitLabel",2),m([(0,we.property)({type:String,attribute:"error-message"})],g.prototype,"errorMessage",2),m([(0,we.property)({type:String})],g.prototype,"attribution",2),m([(0,we.state)()],g.prototype,"loading",2),m([(0,we.state)()],g.prototype,"error",2),m([(0,we.state)()],g.prototype,"issues",2),m([(0,we.state)()],g.prototype,"selfFetched",2),m([(0,we.state)()],g.prototype,"editing",2),m([(0,we.state)()],g.prototype,"sticky",2),m([(0,we.state)()],g.prototype,"openedRow",2),m([(0,we.state)()],g.prototype,"openedRowId",2),m([(0,we.state)()],g.prototype,"moreLoading",2),m([(0,we.state)()],g.prototype,"moreError",2);var x=s=>a=>{customElements.get(s)||customElements.define(s,a)};var wn=/^\d{4}-\d{2}-\d{2}$/,Bm=/^\d{4}-\d{2}$/,id=/^\d{2}:\d{2}(:\d{2})?$/,Hm=/^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/,sd=new Map;function wt(s){if(!s)return["en"];let a=sd.get(s);if(a)return[a,"en"];let e="en";try{e=Intl.getCanonicalLocales(s)[0]??"en"}catch{e="en"}return sd.set(s,e),[e,"en"]}var nd=new Map;function kn(s){let a=s??"",e=nd.get(a);if(e)return e;let r={hour:new Intl.DateTimeFormat(wt(s),{timeStyle:"short",timeZone:"UTC"}).formatToParts(new Date(Date.UTC(2e3,0,1,1))).find(n=>n.type==="hour")?.value?.length===2?"2-digit":"numeric",minute:"2-digit"};return nd.set(a,r),r}function Us(s,a){return s&&a?`${s} - ${a}`:s||a}function ds(s){let a=id.test(s)?`1970-01-01T${s}`:wn.test(s)?`${s}T00:00:00`:Bm.test(s)?`${s}-01T00:00:00`:Hm.test(s)?s.replace(" ","T"):null;return a?{d:new Date(`${a}Z`),timeZone:"UTC"}:{d:new Date(s)}}function Ot(s,a){if(typeof a!="string"||a.length===0||wn.test(a))return"";let{d:e,timeZone:t}=ds(a);return Number.isNaN(e.getTime())?a:e.toLocaleTimeString(wt(s),{...kn(s),timeZone:t})}function M(s,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ds(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(wt(s),{month:"short",day:"numeric",year:"numeric",timeZone:t})}function la(s,a){return a?Us(Ot(s,a.start),Ot(s,a.end)):""}function Et(s,a,e){return Us(M(s,a),M(s,e))}function rr(s,a,e){if(typeof a!="string"||a.length===0)return"";if(e==="year")return a.match(/^(\d{4})/)?.[1]??a;let{d:t,timeZone:r}=ds(a);return Number.isNaN(t.getTime())?a:t.toLocaleString(wt(s),{day:e==="month"?void 0:"numeric",month:"short",year:"numeric",...e==="time"?kn(s):{},timeZone:r})}function od(s,a,e,t){return Us(rr(s,a,t),rr(s,e,t))}function cs(s,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ds(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(wt(s),{month:"short",day:"numeric",timeZone:t})}function ld(s,a,e){let t=cs(s,a),r=cs(s,e);return t===r?t:Us(t,r)}function cd(s,a){if(typeof a!="string"||a.length===0)return"";let{d:e,timeZone:t}=ds(a);return Number.isNaN(e.getTime())?a:e.toLocaleDateString(wt(s),{weekday:"short",day:"numeric",timeZone:t})}function Es(s,a,e){return typeof a!="number"||!Number.isFinite(a)||typeof e!="number"||!Number.isInteger(e)||e<1||e>12?"":new Date(Date.UTC(a,e-1,1,12)).toLocaleDateString(wt(s),{month:"long",year:"numeric",timeZone:"UTC"})}function Sn(s,a){return typeof a!="number"||!Number.isInteger(a)||a<1||a>12?"":new Date(Date.UTC(2e3,a-1,1,12)).toLocaleDateString(wt(s),{month:"long",timeZone:"UTC"})}function q(s,a){return typeof a!="number"||!Number.isFinite(a)?"":a.toLocaleString(wt(s),{maximumFractionDigits:0})}function ot(s,a){let e=a.filter(Boolean);return e.length<2?e[0]??"":new Intl.ListFormat(wt(s),{style:"long",type:"conjunction"}).format(e)}function b(s,a,e=1){return typeof a!="number"||!Number.isFinite(a)?"":a.toLocaleString(wt(s),{maximumFractionDigits:e})}function Ne(s,a,e=1){return typeof a!="number"||!Number.isFinite(a)?"":(a/100).toLocaleString(wt(s),{style:"percent",maximumFractionDigits:e})}function Dt(s){return(s.type??"").toLowerCase().trim().replace(/[\s_]+/g,"-")}function je(s){return U(Dt(s))}var jm={"kp-newcomb":"KP Newcomb","kp-old":"KP Old",lahiri:"Lahiri",raman:"B.V. Raman",custom:"Custom"};function ps(s,a,e){let t=typeof a=="string"?jm[a]??D(a):"",r=typeof e=="number"?`${b(s,e,2)}\xB0`:"";return t&&r?`${t} (${r})`:t||r}function fe(s,a,e,t=false){let r=typeof a=="string"&&wn.test(a)&&typeof e=="string"&&id.test(e)?`${a}T${e}`:a;if(typeof r!="string"||r.length===0)return"";if(wn.test(r))return M(s,r);let{d:n,timeZone:i}=ds(r);return Number.isNaN(n.getTime())?r:n.toLocaleString(wt(s),{month:"short",day:"numeric",year:"numeric",...kn(s),...t?{second:"2-digit"}:{},timeZone:i})}function Ds(s,a,e){return Us(fe(s,a),fe(s,e))}function dd(s,a){if(typeof a!="string"||a.length===0)return"";let{d:e}=ds(a);return Number.isNaN(e.getTime())?a:e.toLocaleString(wt(s),{month:"short",day:"numeric",year:"numeric",...kn(s),timeZone:"UTC",timeZoneName:"short"})}function pd(){try{return new Intl.DateTimeFormat(wt(void 0)).resolvedOptions().timeZone}catch{return}}function Vi(s,a){if(!(typeof a!="string"||!a))return a===s?void 0:a}function qs(s,a){let e=typeof s=="string"?s:"",t=Vi(e,a);return e?t?`${e} (${t})`:e:t??""}function Se(s,a,e){return ws(s,a)??e??D(a)}function ie(s,a,e,t){return Kc(s,a,e)??t??D(e)}var Rn="Localized";function y(s,a,e){let t=s,r=t?.[`${a}${Rn}`];if(typeof r=="string"&&r!=="")return r;if(e!==void 0)return e;let n=t?.[a];return typeof n=="string"?n:""}function Cn(s,a){let e=s,t=e?.[a];if(!Array.isArray(t))return[];let r=e?.[`${a}${Rn}`],n=Array.isArray(r)?r:[];return t.map((i,o)=>{let l=n[o];return{value:String(i),label:typeof l=="string"&&l!==""?l:String(i)}})}function As(s){let a;for(let e of Object.keys(s)){if(!e.endsWith(Rn))continue;let t=e.slice(0,-Rn.length);if(t===""||!(t in s))continue;a??={...s};let r=s[e];r!=null&&r!==""&&(a[t]=r),delete a[e]}return a??s}var ca="http://www.w3.org/2000/svg",Tn=class{constructor(a){this.markup=a}};function Km(s){return String(s).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")}function Ui(s){return s==null?"":s instanceof Tn?s.markup:typeof s=="string"||typeof s=="number"?Km(s):s.map(Ui).join("")}function R(s,...a){let e=s[0]??"";return a.forEach((t,r)=>{e+=e.endsWith("=")?`"${Ui(t)}"`:Ui(t),e+=s[r+1]??""}),new Tn(e)}function da(s){return(a,e)=>un(s,a,e)}var Vm=24,Ps=29.530588853,Um=Date.UTC(2e3,0,6,18,14),qm=864e5,Ym=s=>(1-Math.cos(s*Math.PI/180))/2*100,md=s=>({illumination:Ym(s),waxing:s<180});function Ys(s){if(!(typeof s!="number"||!Number.isInteger(s)||s<1||s>30))return md(12*(s-.5))}function gd(s){let a=Date.parse(`${s}T12:00:00Z`);return!s||Number.isNaN(a)?void 0:((a-Um)/qm%Ps+Ps)%Ps/Ps*360}function Wi(s){let a=gd(s);return a===void 0?void 0:a<180}function yd(s){let a=gd(s);return a===void 0?void 0:md(Math.round(a/90)%4*90)}function Wm(s){let a=s;return()=>(a=(a*9301+49297)%233280,a/233280)}function ud(s,a,e,t,r,n){let o=Wm(n),l=Math.cos(r),c=Math.sin(r),d=Array.from({length:14},(L,$)=>{let k=$/14*Math.PI*2,j=.9+o()*.16,ue=Math.cos(k)*e*j,Xe=Math.sin(k)*t*j;return[s+ue*l-Xe*c,a+ue*c+Xe*l]}),h=L=>d[(L+14)%14],p=L=>L.toFixed(3),f=`M${p(h(0)[0])} ${p(h(0)[1])}`;for(let L=0;L<14;L++){let[$,k,j,ue]=[h(L-1),h(L),h(L+1),h(L+2)];f+=`C${p(k[0]+(j[0]-$[0])/6)} ${p(k[1]+(j[1]-$[1])/6)} ${p(j[0]-(ue[0]-k[0])/6)} ${p(j[1]-(ue[1]-k[1])/6)} ${p(j[0])} ${p(j[1])}`}return`${f}Z`}var fd=[[-.36,-.42,.27,.21,.3,11],[-.6,-.02,.2,.42,.15,23],[.04,-.44,.16,.15,0,37],[.26,-.14,.2,.16,-.4,41],[.66,-.34,.1,.08,.2,53],[.52,.12,.11,.17,.1,67],[-.24,.36,.18,.12,-.2,71],[-.52,.34,.08,.08,0,83],[.33,.26,.07,.07,0,97],[-.08,-.12,.12,.08,.5,101]],qi=fd.map(([s,a,e,t,r,n])=>ud(s,a,e,t,r,n)).join(""),xd=R`<circle class="moon-limb moon-limb-1" r="0.95"></circle><circle class="moon-limb moon-limb-2" r="0.985"></circle>`,Zm=fd.map(([s,a,e,t,r,n])=>ud(s,a,e*1.22,t*1.22,r,n+3)).join("");function Yi(s,a){let e=Math.abs(1-2*s).toFixed(4),t=s<.5;return a?`M0 -1A1 1 0 0 1 0 1A${e} 1 0 0 ${t?0:1} 0 -1Z`:`M0 -1A1 1 0 0 0 0 1A${e} 1 0 0 ${t?1:0} 0 -1Z`}var hd=.004;function Xm(s,a,e,t){let r=a>hd,n=t&&r&&a<1-hd?[.012,.006].map((i,o)=>R`<path class="moon-soft moon-soft-${o+1}" d=${Yi(Math.min(1,a+i),e)}></path>`):[];return R`<circle class="moon-shade" r="1"></circle>${t?R`<path class="moon-earthshine" d=${qi} clip-path=${`url(#${s}-disc)`}></path>`:""}${n}${r?R`<path class="moon-lit" d=${Yi(a,e)}></path>`:""}${t&&r?R`<g clip-path=${`url(#${s}-lit)`}><path class="moon-halo" d=${Zm}></path><path class="moon-mare" d=${qi}></path><circle class="moon-crater" cx="-0.16" cy="0.72" r="0.035"></circle>${xd}</g>`:""}`}function Jm(s,a,e){return a==="solar"?R`<circle class="moon-corona" r="1.1"></circle><circle class="moon-corona moon-corona-outer" r="1.18"></circle><circle class="moon-shade" r="1"></circle>`:R`<circle class="moon-copper" r="1"></circle>${e?R`<path class="moon-copper-mare" d=${qi} clip-path=${`url(#${s}-disc)`}></path><g class="moon-copper-limb">${xd}</g>`:""}`}function Qm(s,a){let e=da(s.lang);if(s.eclipse==="lunar")return e("Lunar eclipse");if(s.eclipse==="solar")return e("Solar eclipse");let t=s.lang,r=Ne(t,a,0);return s.waxing?e("{{percent}} illuminated, waxing",{percent:r}):e("{{percent}} illuminated, waning",{percent:r})}function bd(s){let a=Math.min(1,Math.max(0,s.illumination/100)),e=s.size>=Vm,t=`roxy-moon-${Math.round(a*1e4)}${s.waxing?"x":"n"}${s.eclipse??""}${e?"d":""}`,r=[e?R`<clipPath id=${`${t}-disc`}><circle r="1"></circle></clipPath>`:"",e&&!s.eclipse?R`<clipPath id=${`${t}-lit`}><path d=${Yi(a,s.waxing)}></path></clipPath>`:""],n=s.eclipse?Jm(t,s.eclipse,e):Xm(t,a,s.waxing,e);return R`<svg xmlns=${ca} class="roxy-moon" viewBox="-1.2 -1.2 2.4 2.4" width=${s.size} height=${s.size} role="img" aria-label=${Qm(s,a*100)}><defs>${r}</defs>${s.hemisphere==="south"?R`<g transform="rotate(180)">`:R`<g>`}${n}<circle class=${e?"moon-rim":"moon-rim moon-rim-small"} r="1"></circle></g></svg>`.markup}var An=require("lit"),wd=require("lit/directives/unsafe-html.js");var Ms=require("lit"),vd=Ms.css`:where(.natal-wheel) .wheel-line,:where(.natal-wheel) .tick{fill:none;stroke:var(--roxy-border)}:where(.natal-wheel) .tick-major{stroke:var(--roxy-secondary)}:where(.natal-wheel) .sign-glyph{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}:where(.natal-wheel) .planet-glyph{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .875);font-weight:var(--roxy-weight-bold)}:where(.natal-wheel) .planet-deg{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .4375)}:where(.natal-wheel) .planet-deg .retro{fill:var(--roxy-danger-fg)}:where(.natal-wheel) .planet-leader{stroke:var(--roxy-accent);stroke-width:.5px;opacity:.55}:where(.natal-wheel) .house-num{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .5625)}:where(.natal-wheel) .cusp-deg{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .375)}:where(.natal-wheel) .angle-marker{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold)}:where(.natal-wheel) .angle-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}@container (width<=480px){:where(.natal-wheel) .sign-glyph,:where(.natal-wheel) .planet-glyph{font-size:calc(var(--roxy-text-base) * 1.5)}:where(.natal-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .8125)}:where(.natal-wheel) .house-num{font-size:calc(var(--roxy-text-base) * .75)}}`,Ld=Ms.css`:where(.synastry-wheel) .wheel-line{fill:none;stroke:var(--roxy-border)}:where(.synastry-wheel) .p1{--_person:var(--roxy-accent-ink)}:where(.synastry-wheel) .p2{--_person:var(--roxy-fg)}:where(.synastry-wheel) .sign{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}:where(.synastry-wheel) text.p1,:where(.synastry-wheel) text.p2{fill:var(--_person);font-size:calc(var(--roxy-text-base) * 1.125);font-weight:var(--roxy-weight-bold)}:where(.synastry-wheel) .person-tag,:where(.synastry-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .625)}:where(.synastry-wheel) .planet-deg{fill:var(--roxy-muted)}:where(.synastry-wheel) .planet-deg .retro{fill:var(--roxy-danger-fg)}:where(.synastry-wheel) .leader{stroke:var(--_person);stroke-width:.5px;opacity:.7}@container (width<=480px){:where(.synastry-wheel) .sign,:where(.synastry-wheel) text.p1,:where(.synastry-wheel) text.p2{font-size:calc(var(--roxy-text-base) * 1.75)}:where(.synastry-wheel) .person-tag,:where(.synastry-wheel) .planet-deg{font-size:calc(var(--roxy-text-base) * .9375)}}:where(.synastry-wheel) .asc-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}:where(.synastry-wheel) .asc-label{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold)}`,En=Ms.css`:where(.kundli) .line{fill:#0000;stroke:var(--roxy-border)}:where(.kundli) .sign-text{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-normal);font-family:var(--roxy-font-sans);text-transform:uppercase}:where(.kundli) .rashi-num{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .75);font-weight:var(--roxy-weight-normal);font-family:var(--roxy-font-sans)}:where(.kundli) .house-num{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .planet-text{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .centre-label{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .875);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.kundli) .lagna-marker{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans);text-transform:uppercase}:where(.kundli) .lagna-bg{fill:color-mix(in srgb, var(--roxy-accent) 14%, transparent)}:where(.kundli) .lagna-slash{stroke:var(--roxy-accent);stroke-linecap:round;opacity:.7}`,Dn=Ms.css`:where(.bodygraph) .bg-body{fill:color-mix(in srgb, var(--roxy-secondary) 8%, transparent);stroke:var(--roxy-border);stroke-width:1px}:where(.bodygraph) .bg-channel{stroke:var(--roxy-border);stroke-width:5px;stroke-linecap:round}:where(.bodygraph) .bg-half{stroke-width:5px;stroke-linecap:round}:where(.bodygraph) .bg-half.stripe{stroke-linecap:butt;stroke-dasharray:7 7}:where(.bodygraph) .bg-center{fill:var(--_mask,var(--roxy-bg));stroke:var(--roxy-secondary);stroke-width:1.8px}:where(.bodygraph) .bg-center.defined{stroke:color-mix(in srgb, var(--roxy-fg) 45%, transparent)}:where(.bodygraph){--_gold:color-mix(in oklch, var(--roxy-warning) 60%, var(--roxy-success));--_gold-ink:color-mix(in oklch, var(--roxy-warning-fg) 60%, var(--roxy-success-fg));--_center-gold:light-dark(color-mix(in oklab, var(--_gold) 40%, var(--roxy-bg)),color-mix(in oklab, var(--_gold) 50%, var(--_gold-ink)));--_center-green:light-dark(color-mix(in oklab, var(--roxy-success) 40%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-success) 50%, var(--roxy-success-fg)));--_center-red:light-dark(color-mix(in oklab, var(--roxy-danger) 40%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-danger) 50%, var(--roxy-danger-fg)));--_center-brown:light-dark(color-mix(in oklab, color-mix(in oklab, var(--roxy-warning-fg) 75%, var(--roxy-fg)) 45%, var(--roxy-bg)),color-mix(in oklab, var(--roxy-warning-fg) 50%, var(--roxy-secondary)))}:where(.bodygraph) .bg-center.bg-gold.defined,:where(.bodygraph) .legend .swatch.bg-gold{fill:var(--_center-gold);background:var(--_center-gold)}:where(.bodygraph) .bg-center.bg-green.defined,:where(.bodygraph) .legend .swatch.bg-green{fill:var(--_center-green);background:var(--_center-green)}:where(.bodygraph) .bg-center.bg-red.defined,:where(.bodygraph) .legend .swatch.bg-red{fill:var(--_center-red);background:var(--_center-red)}:where(.bodygraph) .bg-center.bg-brown.defined,:where(.bodygraph) .legend .swatch.bg-brown{fill:var(--_center-brown);background:var(--_center-brown)}:where(.bodygraph) .bg-gate-dot{fill:var(--_mask,var(--roxy-bg));stroke:var(--roxy-border);stroke-width:1px}:where(.bodygraph) .bg-gate-dot.on{stroke:var(--_mask,var(--roxy-bg))}:where(.bodygraph) .bg-center-name{color:var(--roxy-muted);fill:currentColor;font-weight:var(--roxy-weight-bold);text-transform:uppercase;pointer-events:none}:where(.bodygraph) .bg-center-name.defined{color:light-dark(var(--roxy-fg),var(--roxy-bg))}:where(.bodygraph) .bg-gate{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .50625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}:where(.bodygraph) .bg-gate.on{fill:var(--src-ink,var(--_mask,var(--roxy-bg)))}:where(.bodygraph) .bg-half.src-left{stroke:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .bg-half.src-right{stroke:var(--src-right,var(--roxy-fg))}:where(.bodygraph) .bg-gate-dot.on.src-left{fill:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .bg-gate-dot.on.src-right{fill:var(--src-right,var(--roxy-fg))}:where(.bodygraph) .legend .swatch.src-left{background:var(--src-left,var(--roxy-danger))}:where(.bodygraph) .legend .swatch.src-right{background:var(--src-right,var(--roxy-fg))}`,$d=Ms.css`:where(.roxy-moon) .moon-shade{fill:var(--roxy-moon-shade)}:where(.roxy-moon) .moon-earthshine{fill:var(--roxy-moon-lit);opacity:.05}:where(.roxy-moon) .moon-soft{fill:var(--roxy-moon-lit)}:where(.roxy-moon) .moon-soft-1{opacity:.18}:where(.roxy-moon) .moon-soft-2{opacity:.34}:where(.roxy-moon) .moon-lit{fill:var(--roxy-moon-lit)}:where(.roxy-moon) .moon-limb{fill:none;stroke:var(--roxy-moon-mare)}:where(.roxy-moon) .moon-limb-1{stroke-width:.1px;opacity:.18}:where(.roxy-moon) .moon-limb-2{stroke-width:.03px;opacity:.3}:where(.roxy-moon) .moon-halo{fill:var(--roxy-moon-mare);opacity:.22}:where(.roxy-moon) .moon-mare{fill:var(--roxy-moon-mare);opacity:.38}:where(.roxy-moon) .moon-crater{fill:none;stroke:var(--roxy-moon-mare);stroke-width:.012px}:where(.roxy-moon) .moon-copper{fill:var(--roxy-moon-eclipse)}:where(.roxy-moon) .moon-copper-limb .moon-limb{stroke:var(--roxy-moon-shade)}:where(.roxy-moon) .moon-copper-mare{fill:var(--roxy-moon-shade);opacity:.3}:where(.roxy-moon) .moon-corona{fill:none;stroke:var(--roxy-moon-corona);stroke-width:.05px}:where(.roxy-moon) .moon-corona-outer{stroke-width:.02px;opacity:.45}:where(.roxy-moon) .moon-rim{fill:none;stroke:var(--roxy-moon-rim);stroke-width:.012px}:where(.roxy-moon) .moon-rim-small{stroke-width:.04px}`;var sr=[$d,An.css`.moon-mark{vertical-align:middle;flex-shrink:0;display:inline-flex}`];function ea(s,a,e,t){return An.html`<span class="moon-mark">${(0,wd.unsafeHTML)(bd({...a,size:e,eclipse:t,hemisphere:s.hemisphere,lang:js(s)}))}</span>`}var eg=28,tg=20;function kd(s){return!("days"in s)}var wa=class extends g{constructor(){super(...arguments);this.mode="day"}renderData(e){let t=this.effectiveLang();return this.mode==="day"&&kd(e)?z.html`<article class="card" part="card" aria-labelledby="almanac-title">${this.renderDayCard(e,t)}</article>`:kd(e)?z.nothing:z.html`<article class="card" part="card" aria-labelledby="almanac-title"><header class="head" part="header"><h2 class="title" id="almanac-title">${"activityLabel"in e&&e.activityLabel?e.activityLabel:this.t("Almanac")}</h2>${"startDate"in e&&e.startDate?z.html`<span class="lunar">${Et(t,e.startDate,e.endDate)}</span>`:z.nothing} ${"year"in e&&typeof e.year=="number"?z.html`<span class="lunar">${Es(t,e.year,e.month)||e.year}</span>`:z.nothing} ${typeof e.total=="number"?z.html`<span class="lunar">${this.t("{{count}} days",{count:q(t,e.total)})}</span>`:z.nothing}</header>${"avoidAnimal"in e&&e.avoidAnimal?z.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Avoiding")}</span><b>${D(y(e,"avoidAnimal"))}</b></span></div>`:z.nothing} ${this.renderSolarTerms(e,t)}<section part="section days"><ul class="days">${(e.days??[]).map(r=>this.renderDayRow(r,t))}</ul></section></article>`}renderDayCard(e,t){let r=e.dayOfficer,n=Ys(e.lunar?.day);return z.html`<header class="head" part="header"><h2 class="title" id="almanac-title">${M(t,e.date)}</h2>${e.lunar?z.html`<span class="lunar">${n?ea(this,n,eg):z.nothing}${e.lunar.isLeapMonth?this.t("Lunar {{month}}/{{day}} (leap)",{month:String(e.lunar.month??""),day:String(e.lunar.day??"")}):this.t("Lunar {{month}}/{{day}}",{month:String(e.lunar.month??""),day:String(e.lunar.day??"")})}</span>`:z.nothing} ${r?.name?z.html`<span class="roxy-chip tag tag-${r.quality??"neutral"}">${y(r,"name")} <span lang="zh">${r.chinese??""}</span></span>`:z.nothing}</header>${this.renderPillars(e)} ${this.renderLists(e,t)} ${r?.meaning&&!this.hideReadings?z.html`<p class="meaning" part="reading">${r.meaning}</p>`:z.nothing} ${this.renderMansion(e)}`}renderPillars(e){let r=[["Year",e.yearPillar],["Month",e.monthPillar],["Day",e.dayPillar]].filter(([,n])=>n?.chinese||n?.stem);return r.length===0&&!e.clashAnimal?z.nothing:z.html`<div class="facts" part="details">${r.map(([n,i])=>z.html`<span><span class="roxy-label">${this.t(n)}</span> <b lang="zh">${i?.chinese??""}</b> ${i?.naYin??""}</span>`)} ${e.clashAnimal?z.html`<span><span class="roxy-label">${this.t("Clash")}</span><b>${y(e,"clashAnimal")}</b></span>`:z.nothing}</div>`}renderLists(e,t){let r=e.favours??[],n=e.avoids??[];return r.length===0&&n.length===0?z.nothing:z.html`<div class="lists" part="section activities">${r.length?z.html`<div class="list"><h3>${this.t("Favours")}</h3><div class="roxy-chips chips-favour">${r.map(i=>z.html`<span class="roxy-chip">${ie(t,"activity",i)}</span>`)}</div></div>`:z.nothing} ${n.length?z.html`<div class="list"><h3>${this.t("Avoids")}</h3><div class="roxy-chips chips-avoid">${n.map(i=>z.html`<span class="roxy-chip">${ie(t,"activity",i)}</span>`)}</div></div>`:z.nothing}</div>`}renderMansion(e){let t=e.mansion;return t?.name?z.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Mansion")}</span><b>${y(t,"name")}</b> <span lang="zh">${t.chinese??""}</span></span> ${t.palace?z.html`<span>${D(t.palace)}</span>`:z.nothing} ${t.planet?z.html`<span>${t.planet}</span>`:z.nothing} ${t.animal?z.html`<span>${y(t,"animal")}</span>`:z.nothing}</div>`:z.nothing}renderSolarTerms(e,t){let r="solarTerms"in e?e.solarTerms??[]:[];return r.length===0?z.nothing:z.html`<div class="terms" part="details">${r.map(n=>z.html`<span>${cs(t,n.date)} ${n.name??""}</span>`)}</div>`}renderDayRow(e,t){let r=e.dayOfficer,n=e.favours??[],i=Ys(e.lunar?.day);return z.html`<li class="day" part="label-track"><span class="day-date">${cs(t,e.date)}</span><div class="day-body">${i?ea(this,i,tg):z.nothing} <span lang="zh">${e.dayPillar?.chinese??""}</span> ${r?.name?z.html`<span class="roxy-chip tag tag-${r.quality??"neutral"}">${y(r,"name")}</span>`:z.nothing} ${n.length?z.html`<span class="roxy-chips chips-favour">${n.map(o=>z.html`<span class="roxy-chip">${ie(t,"activity",o)}</span>`)}</span>`:z.nothing} ${e.clashAnimal?z.html`<span class="roxy-label">${this.t("Clash")} ${y(e,"clashAnimal")}</span>`:z.nothing}</div></li>`}};wa.endpoints=sl,wa.styles=[u,sr,z.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.list h3{margin:0}.list h3{margin-block-end:var(--roxy-space-xs)}.lunar{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.lunar .moon-mark{margin-inline-end:var(--roxy-space-xs)}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}:is(.tag-auspicious,.chips-favour>*){color:var(--roxy-success-fg)}:is(.tag-inauspicious,.chips-avoid>*){color:var(--roxy-danger-fg)}.tag-neutral{color:var(--roxy-info-fg)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.meaning{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin:0;padding-block-start:var(--roxy-space-md)}.days{margin:0;padding:0;list-style:none;display:grid}.day{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);display:grid}.day:first-child{border-block-start:0;padding-block-start:0}.day-date{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.day-body{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.terms{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}`],m([(0,Sd.property)({type:String,reflect:true})],wa.prototype,"mode",2),wa=m([x("roxy-almanac-day")],wa);var Me=require("lit");var ag=[{key:"spiritual",source:"Spiritual"},{key:"love",source:"Love"},{key:"career",source:"Career"},{key:"money",source:"Money"},{key:"twinFlame",source:"Twin flame"}];function Pn(s,a,e,t){let r=[];if(a)for(let n of ag){let i=a[n.key];i&&r.push({label:s(n.source),body:i})}return e&&r.push({label:s("Biblical"),body:e}),t&&r.push({label:s("Shadow"),body:t}),r}var rg={positive:"success",cautionary:"danger",neutral:"info"},nr=class extends g{renderData(a){let e=(a.energy??"").toLowerCase(),t=a.keywords??[],r=a.actionSteps??[];return Me.html`<article class="card" part="card" aria-label="${`${this.t("Angel number")} ${a.number??""}`}"><div class="hero" part="header">${a.number?Me.html`<div class="numeral">${a.number}</div>`:Me.nothing}<div><p class="roxy-label">${this.t("Angel number")}</p>${a.title?Me.html`<h2>${a.title}</h2>`:Me.nothing}</div></div>${a.coreMessage&&!this.hideReadings?Me.html`<p>${a.coreMessage}</p>`:Me.nothing}<ul class="badges roxy-chips" part="details">${a.type?Me.html`<li>${a.type}</li>`:Me.nothing} ${typeof a.digitRoot=="number"?Me.html`<li>${this.t("Digit root")} ${a.digitRoot}</li>`:Me.nothing} ${a.energy?Me.html`<li class="roxy-chip" data-tone="${rg[e]??Me.nothing}">${a.energy}</li>`:Me.nothing}</ul>${t.length>0&&!this.hideReadings?Me.html`<ul class="roxy-chips">${t.map(n=>Me.html`<li>${n}</li>`)}</ul>`:Me.nothing} ${this.renderSections(a)} ${a.affirmation&&!this.hideReadings?Me.html`<p class="affirmation">${a.affirmation}</p>`:Me.nothing} ${r.length>0&&!this.hideReadings?Me.html`<div class="steps" part="section action-steps"><h3>${this.t("Action steps")}</h3><ul>${r.map(n=>Me.html`<li>${n}</li>`)}</ul></div>`:Me.nothing}</article>`}renderSections(a){return this.renderInterpretation(Pn(this.translator,a.meaning,a.biblical,a.shadow),"angel-meaning","Reading")}};nr.endpoints=nl,nr.styles=[u,me,Me.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.numeral){min-width:0}@container (width<=24rem){.hero{justify-items:start;gap:var(--roxy-space-sm);grid-template-columns:minmax(0,1fr);display:grid}}.badges>li{text-transform:capitalize}.affirmation{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);font-style:italic}.steps h3{margin-block-end:var(--roxy-space-xs)}.steps ul{gap:calc(var(--roxy-space-unit) / 2);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}`],nr=m([x("roxy-angel-number-card")],nr);var K=require("lit");var sg={positive:"Positive energy",neutral:"Neutral energy",cautionary:"Cautionary energy"},ng={positive:"success",cautionary:"warning"},ir=class extends g{renderData(a){let e=a.knownMeaning,t=a.digitRootMeaning,r=e?.title??this.t("Number analysis"),n=e?.actionSteps??[];return K.html`<article class="card" part="card" aria-label="${this.t("Angel number {{number}}",{number:a.number??""})}"><div class="hero" part="header">${a.number?K.html`<div class="numeral">${a.number}</div>`:K.nothing}<div>${e?.title?K.html`<p class="roxy-label">${this.t("Number analysis")}</p>`:K.nothing}<h2>${r}</h2></div></div><ul class="badges roxy-chips" part="details">${a.type?K.html`<li>${a.type}</li>`:K.nothing} ${typeof a.digits=="number"?K.html`<li>${this.t("{{count}} digits",{count:a.digits})}</li>`:K.nothing} ${typeof a.uniqueDigits=="number"?K.html`<li>${this.t("{{count}} unique",{count:a.uniqueDigits})}</li>`:K.nothing} ${typeof a.digitRoot=="number"?K.html`<li>${this.t("Digit root {{n}}",{n:a.digitRoot})}</li>`:K.nothing} ${a.isPalindrome?K.html`<li class="roxy-chip" data-tone="info">${this.t("Palindrome")}</li>`:K.nothing} ${a.isRepeating?K.html`<li class="roxy-chip" data-tone="info">${this.t("Repeating")}</li>`:K.nothing} ${e?.energy?K.html`<li class="roxy-chip" data-tone="${ng[e.energy]??K.nothing}">${this.t(sg[e.energy]??"Neutral energy")}</li>`:K.nothing}</ul>${a.contextNote?K.html`<div class="context" part="section context"><p class="roxy-label">${this.t("Where you saw it")}</p><p>${a.contextNote}</p></div>`:K.nothing} ${e&&!this.hideReadings?K.html`<div class="section" part="section known-meaning"><p class="roxy-label">${this.t("Known angel number")}</p>${e.coreMessage?K.html`<p>${e.coreMessage}</p>`:K.nothing} ${e.keywords&&e.keywords.length>0?K.html`<ul class="roxy-chips">${e.keywords.map(i=>K.html`<li>${i}</li>`)}</ul>`:K.nothing} ${this.renderMeaning(e.meaning,"lookup-known",e.biblical,e.shadow)} ${e.affirmation?K.html`<p><em>${e.affirmation}</em></p>`:K.nothing} ${n.length>0?K.html`<p class="roxy-label">${this.t("What to do next")}</p><ol class="steps">${n.map(i=>K.html`<li>${i}</li>`)}</ol>`:K.nothing}</div>`:K.nothing} ${t&&!this.hideReadings?K.html`<div class="section" part="section digit-root"><p class="roxy-label">${t.number?this.t("Foundational digit root ({{n}})",{n:t.number}):this.t("Foundational digit root")}</p>${t.title?K.html`<h3>${t.title}</h3>`:K.nothing} ${t.coreMessage?K.html`<p>${t.coreMessage}</p>`:K.nothing} ${e?K.nothing:this.renderRootMeaning(t)}</div>`:K.nothing}</article>`}renderMeaning(a,e,t,r){return this.renderInterpretation(Pn(this.translator,a,t,r),e,"Reading")}renderRootMeaning(a){return K.html`${a.keywords&&a.keywords.length>0?K.html`<ul class="roxy-chips">${a.keywords.map(e=>K.html`<li>${e}</li>`)}</ul>`:K.nothing}${this.renderMeaning(a.meaning,"lookup-root")}${a.affirmation?K.html`<p><em>${a.affirmation}</em></p>`:K.nothing}`}};ir.endpoints=il,ir.styles=[u,X,me,K.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.numeral){min-width:0}@container (width<=24rem){.hero{justify-items:start;gap:var(--roxy-space-sm);grid-template-columns:minmax(0,1fr);display:grid}}.badges>li{text-transform:capitalize}.context{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);display:grid}.steps{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.section{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.section p{font-size:var(--roxy-text-sm)}`],ir=m([x("roxy-angel-number-lookup")],ir);var mt=require("lit");var ig=/(?![\d#*])\p{Emoji}/gu,og=s=>s.replace(ig,"$&\uFE0E"),Mn=s=>Object.fromEntries(Object.entries(s).map(([a,e])=>[a,og(e)])),_s=(s,a)=>a?s[$t(a)]:void 0,lg=Mn({sun:"\u2609",moon:"\u263D",mercury:"\u263F",venus:"\u2640",earth:"\u2641",mars:"\u2642",jupiter:"\u2643",saturn:"\u2644",uranus:"\u2645",neptune:"\u2646",pluto:"\u2647",rahu:"\u260A",ketu:"\u260B",ascendant:"Asc",midheaven:"MC","part of fortune":"\u2297",vertex:"Vx",lagna:"La","north node":"\u260A","south node":"\u260B",chiron:"\u26B7",lilith:"\u26B8","black moon lilith":"\u26B8"}),S=s=>_s(lg,s),cg={sun:"Su",moon:"Mo",mercury:"Me",venus:"Ve",mars:"Ma",jupiter:"Ju",saturn:"Sa",uranus:"Ur",neptune:"Ne",pluto:"Pl",rahu:"Ra",ketu:"Ke",ascendant:"Asc",lagna:"La"},Rd=s=>_s(cg,s),dg=Mn({aries:"\u2648",taurus:"\u2649",gemini:"\u264A",cancer:"\u264B",leo:"\u264C",virgo:"\u264D",libra:"\u264E",scorpio:"\u264F",sagittarius:"\u2650",capricorn:"\u2651",aquarius:"\u2652",pisces:"\u2653"}),J=s=>_s(dg,s),pg={aries:"Ar",taurus:"Ta",gemini:"Ge",cancer:"Cn",leo:"Le",virgo:"Vi",libra:"Li",scorpio:"Sc",sagittarius:"Sg",capricorn:"Cp",aquarius:"Aq",pisces:"Pi"},_n=s=>_s(pg,s),Ie=["Aries","Taurus","Gemini","Cancer","Leo","Virgo","Libra","Scorpio","Sagittarius","Capricorn","Aquarius","Pisces"],hg=Mn({conjunction:"\u260C",semisextile:"\u26BA","semi sextile":"\u26BA",semisquare:"\u2220","semi square":"\u2220",sextile:"\u26B9",square:"\u25A1",trine:"\u25B3",sesquiquadrate:"\u26BC",quincunx:"\u26BB",opposition:"\u260D"}),Ns=s=>_s(hg,s),mg=Mn({heaven:"\u2630",lake:"\u2631",fire:"\u2632",thunder:"\u2633",wind:"\u2634",water:"\u2635",mountain:"\u2636",earth:"\u2637"}),or=s=>_s(mg,s),gg=19904,yg=64,Cd=s=>typeof s=="number"&&Number.isInteger(s)&&s>=1&&s<=yg?String.fromCodePoint(gg+s-1):void 0,Ke="\u211E",Td="\u27F7",Ed="\u2605";var Dd=require("lit"),Re=Dd.css`.roxy-facts{gap:var(--roxy-space-sm) var(--roxy-space-lg);margin:var(--roxy-space-sm) 0 0;font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;flex-wrap:wrap;display:flex}.roxy-facts>div{min-width:0}.roxy-facts dd{overflow-wrap:anywhere;margin:0}`;var Gt=require("lit");var re=Gt.css`.roxy-frame{color:var(--roxy-muted);font-size:var(--roxy-text-xs);line-height:var(--roxy-leading-normal);margin:0}.roxy-frame .roxy-frame-deg{font-variant-numeric:tabular-nums}`;function ve(s,a,e){if(!a?.ayanamsa)return Gt.nothing;let t=ps(s,a.ayanamsa);if(!t)return Gt.nothing;let r=typeof a.ayanamsaDegrees=="number"?b(s,a.ayanamsaDegrees,4):void 0;return Gt.html`<p class="roxy-frame">${r===void 0?e("Sidereal frame: {{frame}}",{frame:t}):e("Sidereal frame: {{frame}}, {{degrees}}\xB0 subtracted",{frame:t,degrees:r})}</p>`}function lr(s,a,e){let t=[];return s?.yearBoundary&&t.push(["Year boundary","yearBoundary",s.yearBoundary]),s?.dayBoundary&&t.push(["Day boundary","dayBoundary",s.dayBoundary]),s?.hourClock&&t.push(["Hour clock","hourClock",s.hourClock]),t.length===0?Gt.nothing:Gt.html`<p class="roxy-frame">${t.map(([r,n,i],o)=>Gt.html`${o>0?" \xB7 ":""}${a(r)}: <span class="roxy-frame-deg" title="${i}">${ie(e,n,i)}</span>`)}</p>`}function Ad(s,a,e){let t=Object.values(a??{}).filter(r=>!!r?.ayanamsa);return t.length===0?Gt.nothing:Gt.html`<div class="roxy-frame">${t.map(r=>{let n=ps(s,r.ayanamsa),i=typeof r.ayanamsaDegrees=="number"?b(s,r.ayanamsaDegrees,4):void 0,o=r.governs?.length?r.governs.join(", "):"";return Gt.html`<p class="roxy-frame">${i===void 0?e("Sidereal frame: {{frame}}",{frame:n}):e("Sidereal frame: {{frame}}, {{degrees}}\xB0 subtracted",{frame:n,degrees:i})}${o?e(", governs {{sections}}",{sections:o}):""}</p>`})}</div>`}var Md=require("lit");var Pd=require("lit"),pa=Pd.css`@container (width<=30rem){table.stacked,table.stacked caption,table.stacked tbody,table.stacked tr,table.stacked td{width:100%;min-width:0;display:block}table.stacked thead{display:none}table.stacked tr{border-bottom:1px solid var(--roxy-border);padding-block:var(--roxy-space-sm)}table.stacked tr:last-child{border-bottom:0}table.stacked td{padding:calc(var(--roxy-space-unit) / 2) 0;white-space:normal;border:0}table.stacked td:empty{display:none}table.stacked td[data-inline]{width:auto;margin-inline-end:var(--roxy-space-md);display:inline-block}table.stacked td[data-label]:before{content:attr(data-label) " ";color:var(--roxy-muted)}}`;var Nn=[pa,Md.css`.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr.lead-row td:first-child{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}td.name{font-weight:var(--roxy-weight-bold)}.abbr{color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);margin-inline-start:var(--roxy-space-xs)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}tbody tr.lead-row :is(.abbr,.glyph){color:var(--roxy-accent-ink)}.meaning{min-width:24ch}.meaning strong{display:block}.meaning p{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}@container (width<=30rem){table.stacked tr{padding-inline:var(--roxy-space-md)}table.stacked tbody tr.lead-row{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}table.stacked tbody tr.lead-row td:first-child{box-shadow:none}}`];var ug=new Set(["a1","a12"]),cr=class extends g{renderData(a){let e=a.padas??[];if(!e.length)return this.renderEmpty();let t=e.filter(r=>r.exceptionApplied).length;return mt.html`<div class="wrap" part="card" aria-label="${this.t("Arudha padas")}"><header class="head" part="header"><h2>${this.t("Arudha padas")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header><dl class="roxy-facts" part="details"><div><dt>${this.t("Lagna")}</dt><dd>${a.lagnaRashi??""}</dd></div><div><dt>${this.t("Arudha Lagna")}</dt><dd>${a.arudhaLagna??""}</dd></div><div><dt>${this.t("Upapada")}</dt><dd>${a.upapada??""}</dd></div></dl><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Arudha padas")}"><table class="stacked" role="table"><caption class="roxy-sr-only">${this.t("The twelve Arudha padas: each pada with its bhava, the bhava sign and its lord, the sign the lord occupies, the sign the pada falls in, which house from the Lagna that is, whether the classical exception was applied, and what the pada is read for.")}</caption><thead><tr><th scope="col">${this.t("Pada")}</th><th scope="col">${this.t("Bhava")}</th><th scope="col">${this.t("Bhava rashi")}</th><th scope="col">${this.t("Lord")}</th><th scope="col">${this.t("Lord rashi")}</th><th scope="col">${this.t("Pada rashi")}</th><th scope="col">${this.t("From Lagna")}</th><th scope="col">${this.t("Read for")}</th></tr></thead><tbody>${e.map(r=>this.renderRow(r))}</tbody></table></div>${t>0?mt.html`<p class="note" part="legend"><span class="exception">${this.t("Moved")}</span> ${this.t("marks a pada that fell in its own bhava or the seventh from it and was moved to the tenth from there, as the classical rule requires. {{count}} of {{total}} padas here.",{count:t,total:e.length})}</p>`:mt.nothing}</div>`}renderRow(a){let e=r=>J(r)??"",t=r=>{let n=e(r);return mt.html`${n?mt.html`<span class="glyph roxy-glyph">${n}</span>`:mt.nothing}${r??""}`};return mt.html`<tr class="${ug.has(a.id)?"lead-row":""}"><td class="name">${a.name??""}${a.abbreviation?mt.html`<span class="abbr">${a.abbreviation}</span>`:mt.nothing}</td><td data-inline data-label="${this.t("Bhava")}">${a.house??""}</td><td data-inline data-label="${this.t("Bhava rashi")}">${t(a.bhavaRashi)}</td><td data-inline data-label="${this.t("Lord")}">${a.lord??""}</td><td data-inline data-label="${this.t("Lord rashi")}">${t(a.lordRashi)}</td><td data-inline data-label="${this.t("Pada rashi")}">${t(a.rashi)} ${a.exceptionApplied?mt.html`<span class="exception">${this.t("Moved")}</span>`:mt.nothing}</td><td data-inline data-label="${this.t("From Lagna")}">${a.houseFromLagna??""}</td><td class="meaning"><strong>${a.meaning??""}</strong> ${a.significations?mt.html`<p>${a.significations}</p>`:mt.nothing}</td></tr>`}};cr.endpoints=ol,cr.styles=[u,re,Re,...Nn,mt.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,p{margin:0}.roxy-facts{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);margin:0}.roxy-facts dd{font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold)}.exception{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.note{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],cr=m([x("roxy-arudha-padas")],cr);var Ae=require("lit"),_d=require("lit/decorators.js");var ka=require("lit"),dt=ka.css`.roxy-tablist{gap:var(--roxy-space-xs);box-shadow:inset 0 calc(var(--roxy-line-thick) * -1) 0 var(--roxy-border);scrollbar-width:thin;min-width:0;display:flex;overflow-x:auto}.roxy-tab{padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);border:none;border-bottom:var(--roxy-line-thick) solid transparent;cursor:pointer;color:var(--roxy-muted);transition:color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;flex-shrink:0}.roxy-tab[aria-selected=true]{color:var(--roxy-accent-ink);border-bottom-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.roxy-tab:hover:not([aria-selected=true]){color:var(--roxy-fg)}.roxy-tab:focus-visible{outline-offset:calc(var(--roxy-line-thick) * -1);border-radius:var(--roxy-radius-sm)}`;function ut(s){let{items:a,active:e,onSelect:t,label:r,idPrefix:n,controls:i=false}=s;return ka.html`<div class="roxy-tablist" part="tablist" role="tablist" aria-label="${r}" @keydown="${l=>{if(l.key!=="ArrowRight"&&l.key!=="ArrowLeft")return;l.preventDefault();let c=a.findIndex(f=>f.id===e);if(c===-1)return;let d=l.key==="ArrowRight"?1:-1,h=a[(c+d+a.length)%a.length];if(!h)return;t(h.id);let p=l.currentTarget.getRootNode();requestAnimationFrame(()=>{p.querySelector(`#${n}-tab-${h.id}`)?.focus()})}}">${a.map(l=>ka.html`<button type="button" class="roxy-tab" part="tab" role="tab" id="${n}-tab-${l.id}" aria-selected="${e===l.id?"true":"false"}" aria-controls="${i?`${n}-panel-${l.id}`:ka.nothing}" tabindex="${e===l.id?"0":"-1"}" @click="${()=>t(l.id)}">${l.label}</button>`)}</div>${i?a.filter(l=>l.id!==e).map(l=>ka.html`<div role="tabpanel" id="${n}-panel-${l.id}" aria-labelledby="${n}-tab-${l.id}" hidden></div>`):ka.nothing}`}var fg=[{id:"sarva",source:"Sarvashtakavarga"},{id:"bhinna",source:"Bhinnashtakavarga"},{id:"reduced",source:"Reduced"},{id:"pinda",source:"Shodhya Pinda"}],Sa=class extends g{constructor(){super(...arguments);this.activeTab="sarva"}renderData(e){let t=e.signs??[];return Ae.html`<div class="wrap" part="card" aria-label="${this.t("Ashtakavarga grid")}"><div class="head" part="header"><h2 class="title">${this.t("Ashtakavarga")}</h2>${t.length?Ae.html`<p class="subtitle">${this.t("{{count}} signs",{count:t.length})}</p>`:Ae.nothing} ${ve(this.effectiveLang(),e.frame,this.translator)}</div>${ut({items:fg.map(({id:r,source:n})=>({id:r,label:this.t(n)})),active:this.activeTab,onSelect:r=>{this.activeTab=r},label:this.t("Ashtakavarga views"),idPrefix:"ashtakavarga",controls:true})}<div id="ashtakavarga-panel-${this.activeTab}" part="panel" role="tabpanel" aria-labelledby="ashtakavarga-tab-${this.activeTab}">${this.activeTab==="sarva"?this.renderSarva(t):this.activeTab==="bhinna"?this.renderBhinna(t):this.activeTab==="reduced"?this.renderReduced(t):this.renderPinda()}</div></div>`}bhinnaTier(e){return e<=1?"tier-1":e<=2?"tier-2":e<=3?"tier-3":e<=4?"tier-4":e<=5?"tier-5":e<=6?"tier-6":"tier-7"}sarvaTier(e){return e<=20?"tier-1":e<=24?"tier-2":e<=27?"tier-3":e<=29?"tier-4":e<=32?"tier-5":e<=36?"tier-6":"tier-7"}renderLegend(e){return Ae.html`<div class="legend" part="legend"><span>${this.t("Fewer bindus")}</span> <span class="legend-scale" aria-hidden="true">${[1,2,3,4,5,6,7].map(t=>Ae.html`<span class="legend-swatch tier-${t}"></span>`)} </span><span>${this.t("More bindus")}</span> <span class="legend-note">${e}</span></div>`}renderSarva(e){let t=this.data?.sarvashtakavarga;return t?Ae.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Sarvashtakavarga")}"><table><caption class="roxy-sr-only">${this.t("Sarvashtakavarga: each of the twelve signs and the bindus all planets contribute to it, with a grand total.")}</caption><thead><tr><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Bindus")}</th></tr></thead><tbody>${e.map((r,n)=>{let i=t.bindus[n]??0;return Ae.html`<tr><td><div class="planet-cell"><span class="glyph roxy-glyph" aria-hidden="true">${J(r)??""}</span> ${r}</div></td><td class="${`bindu-cell ${this.sarvaTier(i)}`}">${i}</td></tr>`})}</tbody><tfoot><tr class="total-row"><td>${this.t("Total")}</td><td>${t.total}</td></tr></tfoot></table></div>${this.renderLegend("Under 25 is a weak sign, 25 to 29 average, 30 and above strong. The 12 signs always total 337.")}`:Ae.html`<p class="roxy-empty">${this.t("No sarvashtakavarga data")}</p>`}renderBhinna(e){let t=this.data?.bhinnashtakavarga;return t?.length?Ae.html`${this.renderBinduGrid(e,t,"Bhinnashtakavarga: the bindus each planet scores in every one of the twelve signs, with a row total.","Bhinnashtakavarga")} ${this.renderLegend("Each planet scores 0 to 8 bindus per sign. 4 is the mid, 5 and above is strong support for that planet in that sign.")}`:Ae.html`<p class="roxy-empty">${this.t("No bhinnashtakavarga data")}</p>`}renderReduced(e){let t=this.data?.reducedBhinnashtakavarga,r=this.data?.reducedSarvashtakavarga;return!t?.length&&!r?Ae.html`<p class="roxy-empty">${this.t("No reduced ashtakavarga data")}</p>`:Ae.html`${this.renderBinduGrid(e,t??[],"Reduced Bhinnashtakavarga after Shodhana: the bindus each planet keeps in every one of the twelve signs, with a row total and a Reduced Sarvashtakavarga totals row.","Reduced",r)} ${this.renderLegend("Bindus left after Trikona and Ekadipati Shodhana, the input to Shodhya Pinda. The Reduced SAV row totals the seven planets only, so it does not include the Lagna row above it.")}`}renderBinduGrid(e,t,r,n,i){return t.length?Ae.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t(n)}"><table class="bhinna-table"><caption class="roxy-sr-only">${r}</caption><thead><tr><th scope="col">${this.t("Planet")}</th>${e.map(o=>Ae.html`<th scope="col" class="roxy-glyph" title="${o}">${J(o)??o}</th>`)}<th scope="col">${this.t("Total")}</th></tr></thead><tbody>${t.map(o=>Ae.html`<tr><td>${o.planet}</td>${o.bindus.map(l=>Ae.html`<td class="${`bindu-cell ${this.bhinnaTier(l)}`}">${l}</td>`)}<td>${o.total}</td></tr>`)}</tbody>${i?Ae.html`<tfoot><tr class="total-row"><td>${this.t("Reduced SAV")}</td>${e.map((o,l)=>Ae.html`<td>${i.bindus[l]??0}</td>`)}<td>${i.total}</td></tr></tfoot>`:Ae.nothing}</table></div>`:Ae.html`<p class="roxy-empty">${this.t("No bindu data")}</p>`}renderPinda(){let e=this.data?.shodhyaPinda;return e?.length?Ae.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Shodhya Pinda")}"><table><caption class="roxy-sr-only">${this.t("Shodhya Pinda: each planet with its Rashi Pinda, Graha Pinda and Shodhya Pinda strength scores.")}</caption><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Rashi Pinda")}</th><th scope="col">${this.t("Graha Pinda")}</th><th scope="col">${this.t("Shodhya Pinda")}</th></tr></thead><tbody>${e.map(t=>Ae.html`<tr><td>${t.planet}</td><td>${t.rashiPinda}</td><td>${t.grahaPinda}</td><td>${t.shodhyaPinda}</td></tr>`)}</tbody></table></div>`:Ae.html`<p class="roxy-empty">${this.t("No shodhya pinda data")}</p>`}};Sa.endpoints=ll,Sa.styles=[u,re,dt,Ae.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.subtitle{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}[role=tabpanel]:not([hidden]){gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.overflow-scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){text-align:center}:is(th,td):first-child{text-align:start}.glyph{font-size:var(--roxy-text-base);line-height:1}.planet-cell{align-items:center;gap:var(--roxy-space-xs);white-space:nowrap;display:flex}.total-row td{font-weight:var(--roxy-weight-bold);border-block-start:var(--roxy-line-thick) solid var(--roxy-border);border-block-end:0}.bindu-cell{min-width:3ch;font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;color:var(--roxy-fg)}.tier-1{background:color-mix(in srgb, var(--roxy-heat) 30%, transparent)}.tier-2{background:color-mix(in srgb, var(--roxy-heat) 17%, transparent)}.tier-3{background:color-mix(in srgb, var(--roxy-heat) 7%, transparent)}.tier-4{background:color-mix(in srgb, var(--roxy-border) 45%, transparent)}.tier-5{background:color-mix(in srgb, var(--roxy-success) 16%, transparent)}.tier-6{background:color-mix(in srgb, var(--roxy-success) 32%, transparent)}.tier-7{background:color-mix(in srgb, var(--roxy-success) 50%, transparent)}.legend{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend-scale{gap:1px;display:flex}.legend-swatch{block-size:.75lh;inline-size:2ch}.legend-note{flex:24ch}.bhinna-table :is(th,td):first-child{min-width:8ch}@container (width<=480px){.bhinna-table :is(th,td){padding:var(--roxy-space-xs);font-size:var(--roxy-text-xs)}.bhinna-table :is(th,td):first-child{min-width:6ch}.bindu-cell{min-width:2ch}}`],m([(0,_d.state)()],Sa.prototype,"activeTab",2),Sa=m([x("roxy-ashtakavarga-grid")],Sa);var B=require("lit");var xg=new Set(["conjunction","sextile","square","trine","opposition"]);function Ra(s){return xg.has(Dt(s))}function Qe(s){return`aspect-${Dt(s)}`}var Nd=.3,bg=.9,zd=.5,vg=1.8;function zs(s){let{strength:a}=s;if(typeof a!="number"||!Number.isFinite(a))return;let e=Math.min(1,Math.max(0,a/100)),t=Nd+e*(bg-Nd),r=zd+e*(vg-zd);return`opacity:${t.toFixed(3)};stroke-width:${r.toFixed(3)}`}var Zi=require("lit"),Ca=Zi.css`.aspect-trine,.aspect-sextile{--_aspect:var(--roxy-info);--_aspect-ink:var(--roxy-info-fg)}.aspect-square,.aspect-opposition{--_aspect:var(--roxy-danger);--_aspect-ink:var(--roxy-danger-fg)}.aspect-quincunx,.aspect-semi-sextile{--_aspect:var(--roxy-success);--_aspect-ink:var(--roxy-success-fg)}.aspect-conjunction{--_aspect:var(--roxy-accent-ink);--_aspect-ink:var(--roxy-accent-ink)}:is(.aspect-trine,.aspect-sextile,.aspect-square,.aspect-opposition,.aspect-quincunx,.aspect-semi-sextile,.aspect-conjunction){color:var(--_aspect-ink);stroke-opacity:1}.aspect-swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_aspect);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}`,Os=[Zi.css`.aspect{stroke:var(--_aspect,var(--roxy-muted));stroke-width:.8px;fill:none;opacity:.55;stroke-opacity:.7}`,Ca];function Lg(s,a,e){if(s.include?.length){let t={bodies:ot(a,s.include)};return s.strictOrbs?e("Detected with strict orbs, including {{bodies}}.",t):e("Detected with industry-standard orbs, including {{bodies}}.",t)}return s.strictOrbs?e("Detected with strict orbs, classical bodies only."):e("Detected with industry-standard orbs, classical bodies only.")}var Od={GRAND_CROSS:0,GRAND_TRINE:1,KITE:2,T_SQUARE:3,YOD:4,MYSTIC_RECTANGLE:5,STELLIUM:6},dr=class extends g{renderData(a){let e="aspects"in a?a.aspects??[]:[],t="patterns"in a?a.patterns??[]:[],r="summary"in a?a.summary:void 0;if(e.length===0&&t.length===0)return this.renderEmpty();let n=fe(this.effectiveLang(),"transitDate"in a?a.transitDate:"date"in a?a.date:"","time"in a?a.time:void 0,true),i="timezone"in a?a.timezone:void 0,o="options"in a?a.options:void 0;return B.html`<div class="wrap" part="card" aria-label="${this.t("Aspects")}"><div class="head" part="header"><h2>${e.length===0?this.t("Chart patterns"):this.t("Aspects")}</h2>${e.length>0||n?B.html`<p class="subtitle roxy-label">${[e.length===1?this.t("1 aspect"):e.length>1?this.t("{{count}} aspects",{count:e.length}):"",n].filter(Boolean).join(" \xB7 ")}</p>`:B.nothing} ${typeof i=="number"&&Number.isFinite(i)?B.html`<dl class="roxy-facts" part="details"><div><dt>${Se(this.effectiveLang(),"timezone")}</dt><dd>${b(this.effectiveLang(),i,5)}</dd></div></dl>`:B.nothing}</div>${r?this.renderSummary(r):B.nothing} ${r&&"strongest"in r&&r.strongest?this.renderStrongest(r.strongest):B.nothing} ${e.length>0?B.html`<div role="list" part="section aspects" aria-label="${this.t("Aspect list")}">${e.map((l,c)=>B.html`<div role="listitem">${this.renderAspect(l,c)}</div>`)}</div>`:B.nothing} ${t.length>0?B.html`<section class="patterns" part="section patterns"><h3>${this.t("Chart patterns")}</h3>${[...t].sort((l,c)=>(Od[l.kind]??9)-(Od[c.kind]??9)||(c.tightness??0)-(l.tightness??0)).map(l=>this.renderPattern(l))}</section>`:B.nothing} ${o?B.html`<p class="provenance">${Lg(o,this.effectiveLang(),this.translator)}</p>`:B.nothing}</div>`}renderSummary(a){let e="totalAspects"in a?a.totalAspects:a.total,t=Object.entries(a.byType??{}).sort((r,n)=>n[1]-r[1]);return B.html`<p class="counts" part="details" role="region" aria-label="${this.t("Aspect summary")}">${typeof e=="number"?B.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e})}</span>`:B.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:a.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:a.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:a.neutral})}</span> ${t.map(([r,n])=>B.html`<span>${this.t("{{label}}: {{value}}",{label:je({type:r}),value:n})}</span>`)}</p>`}renderStrongest(a){let e=S(a.planet1)??"",t=S(a.planet2)??"";return B.html`<div class="strongest" part="details strongest"><span class="roxy-label">${this.t("Strongest")}</span> <span aria-hidden="true" class="glyph roxy-glyph">${e}</span>${y(a,"planet1")} <span class="asp-name ${Qe(a)}">${y(a,"type",je(a))}</span> <span aria-hidden="true" class="glyph roxy-glyph">${t}</span>${y(a,"planet2")} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:a.isApplying?this.t("Applying"):this.t("Separating"),orb:b(this.effectiveLang(),a.orb,2),strength:b(this.effectiveLang(),a.strength,0)})}</span></div>`}renderAspect(a,e){let t=S(a.planet1)??"",r=S(a.planet2)??"",n=je(a),i=a.isApplying?this.t("Applying"):this.t("Separating"),o="meaning"in a?a.meaning:void 0,l="transitInterpretation"in a?a.transitInterpretation:void 0,c="aspectInterpretation"in a?a.aspectInterpretation:void 0,d=!!(o||l||c),h=B.html`<span aria-hidden="true" class="glyph roxy-glyph">${t}</span>${y(a,"planet1")} <span class="asp-name ${Qe(a)}">${y(a,"type",n)}</span> <span aria-hidden="true" class="glyph roxy-glyph">${r}</span>${y(a,"planet2")} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:i,orb:b(this.effectiveLang(),a.orb,2),strength:b(this.effectiveLang(),a.strength,0)})}</span>`;return!d||this.hideReadings?B.html`<div class="interp-card" part="reading"><div class="static-head">${h}</div></div>`:B.html`<details class="interp-card" part="reading" name="aspects" ?open="${e===0}"><summary>${h}${he()}</summary><div class="interp-body" part="readings">${o?this.renderMeaning(o):B.nothing} ${l?this.renderTransit(l):B.nothing} ${c?Vs(c,this.translator):B.nothing}</div></details>`}renderMeaning(a){return B.html`${a.description?.short?B.html`<p>${a.description.short}</p>`:B.nothing} ${a.description?.long&&a.description.long!==a.description.short?B.html`<p>${a.description.long}</p>`:B.nothing} ${os(a.keywords)}`}renderTransit(a){return Vs(a,this.translator)}renderPattern(a){let e=a.planets??[],t=a.apex?[...e].sort((r,n)=>+(n===a.apex)-+(r===a.apex)):e;return B.html`<div class="pattern" part="pattern"><div class="pattern-head"><span class="pattern-name">${a.name??a.kind??this.t("Pattern")}</span> ${a.element?B.html`<span class="roxy-chip">${a.element}</span>`:B.nothing} ${a.modality?B.html`<span class="roxy-chip">${a.modality}</span>`:B.nothing} ${a.dissociate?B.html`<span class="roxy-chip" title="${this.t("Out of sign: one or more planets sit outside the pattern element or modality, so the theme holds but runs weaker.")}">${this.t("Dissociate")}</span>`:B.nothing} ${typeof a.tightness=="number"?B.html`<span class="pattern-tight roxy-label">${this.t("{{percent}} tight",{percent:Ne(this.effectiveLang(),a.tightness,0)})}</span>`:B.nothing}</div>${t.length?B.html`<ul class="roxy-chips">${t.map(r=>{let n=S(r),i=!!a.apex&&r===a.apex;return B.html`<li class="${i?"roxy-chip apex":"roxy-chip"}">${n?B.html`<span class="roxy-glyph" aria-hidden="true">${n}</span>`:B.nothing}${r}${i?B.html`<span>${this.t("apex")}</span>`:B.nothing}</li>`})}</ul>`:B.nothing} ${a.interpretation&&!this.hideReadings?B.html`<p class="pattern-interp">${a.interpretation}</p>`:B.nothing}</div>`}};dr.endpoints=cl,dr.styles=[u,Re,X,me,Ca,B.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.interp-card summary,.static-head{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.static-head{font-size:var(--roxy-text-sm)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-normal);font-variant-numeric:tabular-nums;margin-inline-start:auto}.glyph{line-height:1}.asp-name{font-weight:var(--roxy-weight-bold)}.strongest,.pattern{padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.strongest{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.pattern{gap:var(--roxy-space-xs);display:grid}.pattern-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.pattern-name{font-weight:var(--roxy-weight-bold)}.pattern-tight{font-variant-numeric:tabular-nums;margin-inline-start:auto}.roxy-chip.apex{color:var(--roxy-fg);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.pattern-interp{font-size:var(--roxy-text-sm)}.provenance{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],dr=m([x("roxy-aspects-table")],dr);var ke=require("lit");var hs=require("lit"),Ve=class{constructor(a){this.host=a;this.state="closed";this.zoom=1;this.pressedBy="";this.press=a2=>{this.pressedBy=a2.pointerType};this.openOnMouse=a2=>{let e=this.pressedBy==="mouse";this.pressedBy="",e&&(a2.target?.closest?.("a, button, summary, input, select, textarea")||getSelection()?.toString()||this.open())};a.addController(this)}hostUpdated(){let a=this.host.renderRoot.querySelector(".roxy-chart-dialog");if(!a)this.reset();else if(a.isConnected&&this.state!=="closed"){this.state==="opening"&&(this.state="open",a.open||a.showModal());let e=a.querySelector(".roxy-chart-scroll");a.open&&e&&this.position&&(e.scrollLeft=e.scrollWidth*this.position.x-e.clientWidth/2,e.scrollTop=e.scrollHeight*this.position.y-e.clientHeight/2,this.position=void 0)}}hostDisconnected(){this.reset(),this.host.renderRoot.querySelector(".roxy-chart-dialog")?.close()}open(){this.state="opening",this.position={x:.5,y:0},this.host.requestUpdate()}reset(){this.state="closed",this.zoom=1,this.position=void 0}resize(a){let e=this.host.renderRoot.querySelector(".roxy-chart-scroll");this.position=a===0?{x:.5,y:0}:e?{x:(e.scrollLeft+e.clientWidth/2)/e.scrollWidth,y:(e.scrollTop+e.clientHeight/2)/e.scrollHeight}:void 0,this.zoom=a===0?1:Math.min(3,Math.max(1,this.zoom+a)),this.host.requestUpdate()}renderChartViewport(a,e,t){return hs.html`<div class="roxy-chart-view"><div class="roxy-chart-hit" @pointerdown="${this.press}" @click="${this.openOnMouse}">${a}</div><div class="roxy-chart-tools" part="chart-controls"><button type="button" @click="${()=>this.open()}">${t("Enlarge chart")}</button></div><dialog class="roxy-chart-dialog" part="chart-dialog" aria-label="${e}" @close="${()=>{this.reset(),this.host.requestUpdate()}}">${this.state!=="closed"?hs.html`<div class="roxy-chart-bar"><strong>${e}</strong><div class="roxy-chart-tools"><button type="button" aria-label="${t("Zoom out")}" ?disabled="${this.zoom===1}" @click="${()=>this.resize(-.5)}">−</button> <button type="button" @click="${()=>this.resize(0)}">${t("Reset zoom")}</button> <button type="button" aria-label="${t("Zoom in")}" ?disabled="${this.zoom===3}" @click="${()=>this.resize(.5)}">+</button> <button type="button" @click="${()=>this.host.renderRoot.querySelector(".roxy-chart-dialog")?.close()}">${t("Close")}</button></div></div><div class="roxy-chart-scroll" role="region" tabindex="0" aria-label="${e}"><div class="roxy-chart-expanded" style="${`--chart-zoom:${this.zoom}`}">${a}</div></div>`:hs.nothing}</dialog></div>`}},et=hs.css`.roxy-chart-view{min-width:0}@media (hover:hover) and (pointer:fine){.roxy-chart-hit{cursor:zoom-in}}.roxy-chart-tools{gap:var(--roxy-space-sm);flex-wrap:wrap;justify-content:flex-end;align-items:center;display:flex}.roxy-chart-tools button{font-size:var(--roxy-text-sm);color:var(--roxy-secondary);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);min-width:2lh;min-height:2lh;padding:var(--roxy-space-xs) var(--roxy-space-sm);cursor:pointer;background:0 0}.roxy-chart-tools button:hover:not(:disabled){border-color:var(--roxy-accent);color:var(--roxy-accent-ink)}.roxy-chart-tools button:disabled{color:var(--roxy-muted);cursor:default}.roxy-chart-dialog{--roxy-surface:var(--roxy-bg);width:calc(100% - 2 * var(--roxy-space-md));max-width:calc(var(--roxy-chart-expanded-width,60rem) * 1.2);max-height:calc(100% - 2 * var(--roxy-space-md));padding:var(--roxy-space-md);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);color:var(--roxy-fg);background:var(--roxy-bg);box-shadow:var(--roxy-shadow-lg);margin:auto}.roxy-chart-dialog[open]{flex-direction:column;display:flex;overflow:hidden}.roxy-chart-dialog::backdrop{background:color-mix(in oklab, var(--roxy-bg) 85%, transparent)}.roxy-chart-bar{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);margin-bottom:var(--roxy-space-md);flex-wrap:wrap;flex-shrink:0;display:flex}.roxy-chart-bar>strong{overflow-wrap:anywhere;min-width:0}.roxy-chart-scroll{overscroll-behavior:contain;flex:auto;min-height:0;overflow:auto}.roxy-chart-expanded{width:max(100%, calc(var(--roxy-chart-expanded-width,60rem) * var(--chart-zoom)));padding:var(--roxy-space-sm)}.roxy-chart-expanded>svg{width:100%;max-width:none;height:auto;margin:0}`;function It(s){let a=s%360;return a<0?a+360:a}function Ut(s){let a=It(s),e=Math.floor(a/30)%12,t=a%30,r=Math.floor(t),n=(t-r)*60,i=Math.floor(n),o=Math.round((n-i)*60);return{sign:Ie[e]??"Aries",signIndex:e,degree:r,minute:i,second:o}}function pt(s,a){let{sign:e,degree:t,minute:r}=Ut(s);return`${t}\xB0 ${a||e} ${String(r).padStart(2,"0")}'`}function qt(s){return ta(It(s)%30)}function Xi(s){let a=Math.floor(s);return{degree:a,minute:Math.floor((s-a)*60)}}function ta(s){let{degree:a,minute:e}=Xi(s);return`${a}\xB0${String(e).padStart(2,"0")}'`}function Ws(s){return It(s+180)}function zn(s,a){let e=It(s),t=It(a)-e;return t<0&&(t+=360),It(e+t/2)}function Yt(s,a,e){let t=s.filter(c=>Number.isFinite(a(c))).map(c=>{let d=It(a(c));return{item:c,longitude:d,displayLongitude:d}}).sort((c,d)=>c.longitude-d.longitude),r=t.length;if(r<2)return t;let n=0,i=-1;for(let c=0;c<r;c++){let d=t[(c+r-1)%r],p=(t[c].longitude-d.longitude+360)%360;p>i&&(i=p,n=c)}let o=t[n],l=o.longitude;for(let c=1;c<r;c++){let d=t[(n+c)%r],h=typeof e=="function"?e(o.item,d.item):e,p=d.longitude+(n+c>=r?360:0);l=Math.max(p,l+h),d.displayLongitude=It(l),o=d}return t}var ha=2;function Gd(s,a){let e=s*Math.PI/180;return a.width/2*Math.abs(Math.cos(e))+a.height/2*Math.abs(Math.sin(e))}function Ta(s,a,e,t){let r=s*Math.PI/180,n=(i,o)=>o>1e-9?(i+t)/o:Number.POSITIVE_INFINITY;return Math.min(n((a.width+e.width)/2,Math.abs(Math.cos(r))),n((a.height+e.height)/2,Math.abs(Math.sin(r))))}var $g=(s,a)=>Math.abs(s.x-a.x)<(s.width+a.width)/2&&Math.abs(s.y-a.y)<(s.height+a.height)/2;function Id(s,a){let e=[],t=r=>e.reduce((n,i)=>$g(r,i)?Math.max(n,Math.min((r.width+i.width)/2-Math.abs(r.x-i.x),(r.height+i.height)/2-Math.abs(r.y-i.y))):n,0);return[...s].map((r,n)=>({point:r,index:n})).sort((r,n)=>r.point.displayLongitude-n.point.displayLongitude).reduce((r,{point:n,index:i})=>{let o=a(n,0),l=a(n,1),c=t(o)===0||t(o)<=t(l)?0:1;return e.push(c===0?o:l),r[i]=c,r},[])}var Ft={minute:3.4,whole:1.85,retrograde:1.25,ink:.9};function Bt(s,a){return a>0?s/a*(180/Math.PI):0}function H(s,a,e,t){let r=t*Math.PI/180;return{x:s+e*Math.cos(r),y:a+e*Math.sin(r)}}var wg={Sun:"var(--roxy-accent)",Moon:"var(--roxy-secondary)",Mercury:"var(--roxy-info)",Venus:"var(--roxy-success)",Mars:"var(--roxy-danger)",Jupiter:"var(--roxy-warning)",Saturn:"var(--roxy-muted)",Uranus:"var(--roxy-info-fg)",Neptune:"var(--roxy-success-fg)",Pluto:"var(--roxy-danger-fg)"},Fd=["var(--roxy-accent)","var(--roxy-info)","var(--roxy-success)","var(--roxy-danger)","var(--roxy-warning)","var(--roxy-secondary)","var(--roxy-info-fg)","var(--roxy-success-fg)","var(--roxy-danger-fg)","var(--roxy-accent-ink)","var(--roxy-warning-fg)","var(--roxy-primary)"];function ms(s,a=0){return wg[U(s)]??Fd[a%Fd.length]??"var(--roxy-accent)"}var Bd="M120 170L120 171L118 171L116 171L114 171L114 170L116 170L118 170L119 170L120 170ZM21 169L19 170L18 169L17 169L16 169L17 168L19 168L20 169L21 169ZM135 168L136 168L137 169L137 170L135 170L133 171L132 171L130 171L127 171L126 171L126 170L128 170L129 170L130 169L131 168L132 168L133 168L135 168ZM59 164L60 164L61 163L61 164L60 164L58 164L57 164L58 163L59 164ZM54 163L56 164L55 164L54 164L53 163L54 163ZM81 162L82 162L83 162L84 163L83 162L82 162L81 162L79 163L78 162L80 162L81 162ZM112 161L111 162L110 162L109 163L108 162L107 162L106 162L105 162L106 161L107 161L108 161L108 160L109 159L110 159L111 160L111 161L112 161ZM121 154L120 154L119 154L119 155L118 155L117 155L117 156L118 156L117 156L116 157L115 157L114 158L115 158L115 159L116 159L117 159L117 160L118 160L118 161L119 162L119 163L119 164L118 164L117 165L116 165L114 166L113 166L112 166L110 166L109 167L108 167L106 167L104 167L103 167L105 167L106 168L105 168L104 168L102 168L102 169L103 170L105 170L107 170L109 171L110 171L112 171L114 171L117 172L118 172L120 172L121 173L122 173L123 173L125 173L126 172L128 172L130 172L133 172L135 172L137 172L138 172L139 171L142 171L144 171L146 171L148 171L150 171L151 170L150 170L150 169L148 169L146 169L144 169L144 168L145 168L146 168L148 168L149 167L150 167L151 167L152 166L154 166L155 166L156 166L158 166L159 166L160 166L161 165L162 165L163 165L164 164L165 164L164 164L164 163L165 163L166 163L167 163L168 162L169 162L170 161L171 161L171 162L173 162L173 161L174 161L176 161L177 161L178 161L179 161L180 162L181 161L182 161L183 161L184 161L185 161L186 160L187 160L188 160L190 160L191 161L192 161L192 160L193 160L195 160L196 160L197 160L198 160L199 160L200 160L201 160L202 160L203 161L204 161L205 160L206 160L207 160L208 160L209 160L210 160L211 160L212 160L213 159L214 159L215 159L216 159L217 159L218 160L219 160L220 160L220 159L221 159L222 159L223 158L224 158L225 158L226 158L227 158L228 157L229 157L230 157L231 157L232 156L233 156L234 156L235 156L236 156L237 156L237 157L238 157L239 157L240 157L241 158L242 158L243 158L244 157L245 158L246 158L247 158L248 158L249 158L250 159L250 160L249 160L248 160L248 161L249 161L248 161L248 162L249 162L250 162L251 162L252 162L252 161L253 161L253 160L254 160L256 160L257 160L258 159L259 158L260 158L261 158L262 157L263 157L264 157L265 157L266 157L267 157L268 156L269 157L270 157L271 157L272 157L273 157L274 157L275 157L276 157L277 157L278 157L279 157L280 157L281 157L282 156L283 156L284 156L285 156L286 157L287 157L288 157L289 157L290 157L291 156L292 156L293 156L294 156L295 156L296 157L297 157L299 157L300 157L301 157L302 157L303 156L304 157L305 157L306 157L307 157L308 157L309 157L310 157L311 156L312 156L313 156L314 156L315 156L315 155L316 156L317 157L319 157L320 157L321 157L322 157L323 157L324 157L325 157L326 157L326 158L327 158L328 158L329 158L330 159L331 159L333 159L334 159L335 159L336 159L337 159L338 159L339 160L340 160L341 160L342 161L343 161L344 161L345 161L346 161L347 161L348 161L349 161L351 161L351 162L350 163L349 164L348 164L347 164L346 164L346 165L345 165L344 165L344 166L343 167L344 167L344 168L345 168L347 168L347 169L345 169L344 169L342 169L341 170L340 171L341 171L342 172L344 172L345 173L347 173L349 173L349 174L352 174L353 174L356 174L358 174L360 175L360 180L0 180L0 175L1 174L3 174L4 174L6 175L7 174L10 174L11 174L13 175L16 175L18 175L22 175L25 175L29 175L31 176L34 175L37 175L33 175L30 174L29 174L26 174L27 173L27 172L25 172L25 171L23 171L26 171L28 171L29 171L31 171L33 171L34 170L33 170L32 170L30 169L28 169L27 169L25 169L24 169L23 168L22 168L22 167L23 167L25 167L26 167L27 167L29 167L30 167L31 167L32 167L34 166L34 165L35 165L36 166L37 165L38 165L40 165L41 165L42 165L44 165L45 164L46 164L48 164L49 164L50 164L52 164L53 164L55 165L56 164L57 164L59 165L60 164L61 164L63 164L64 164L65 164L66 164L67 164L68 165L69 164L70 165L71 165L72 165L74 165L75 165L77 165L78 165L79 165L80 165L79 165L79 164L77 164L77 163L76 163L77 163L78 163L80 163L81 163L82 163L82 164L84 164L85 163L86 163L88 163L89 163L90 163L91 163L92 163L93 163L94 163L95 163L96 164L97 164L99 164L99 163L100 163L101 164L102 163L103 164L104 164L105 164L106 164L107 163L108 163L110 163L111 163L112 163L113 162L112 161L112 160L111 160L112 159L113 158L112 158L112 157L113 157L114 156L115 156L116 155L117 155L118 155L119 154L120 154L121 154L121 153L122 153L123 154L122 154L121 154ZM112 144L114 144L115 145L114 145L113 145L112 146L111 145L110 145L109 145L108 144L107 144L105 143L106 143L108 144L109 144L110 143L111 143L112 143L112 144ZM121 141L122 142L121 142L120 142L119 142L120 141L121 142L121 141ZM250 140L249 140L249 139L250 139L251 139L250 140ZM325 131L326 131L327 131L328 131L328 132L328 133L327 134L326 134L325 133L325 132L325 131ZM353 131L354 131L354 132L353 133L353 134L352 134L351 134L351 135L351 136L350 136L349 137L348 137L348 136L347 136L347 135L348 134L349 134L350 134L351 133L352 132L352 131L353 130L353 131ZM355 126L355 127L356 127L356 128L357 128L358 128L359 128L358 129L357 129L357 130L357 131L356 131L355 132L355 131L355 130L354 130L354 129L355 129L355 128L355 127L354 127L354 126L353 125L353 124L354 125L355 126ZM347 112L346 112L345 112L345 111L344 110L345 110L345 111L346 111L347 112ZM358 107L359 108L358 108L357 108L358 107L358 108L358 107ZM359 107L359 106L360 106L360 107L359 107ZM230 104L230 105L230 106L230 105L230 106L230 107L229 107L229 108L229 109L229 110L228 112L228 114L227 115L226 115L225 116L225 115L224 115L224 114L223 113L223 112L223 111L224 111L224 110L224 109L224 108L224 107L224 106L225 106L226 106L227 105L228 105L228 104L229 103L229 102L230 102L230 103L230 104ZM324 104L324 105L325 104L325 105L325 106L326 107L326 108L326 109L327 109L328 110L329 110L329 111L330 112L330 113L331 112L331 113L332 114L333 115L333 116L333 117L334 118L334 119L333 119L333 120L333 121L333 122L332 123L331 124L331 125L330 126L330 127L329 128L328 128L327 128L327 129L326 129L325 129L325 128L324 128L324 129L323 129L322 128L321 128L320 127L320 126L319 126L318 126L318 125L318 124L318 125L317 125L318 124L318 123L317 124L316 124L316 125L315 124L315 123L314 123L313 122L312 122L311 121L310 122L308 122L307 122L306 122L305 123L304 123L304 124L303 124L302 124L301 124L300 124L299 125L299 124L299 125L298 125L297 125L296 124L295 124L296 123L296 122L295 121L295 120L295 119L294 118L294 117L293 117L293 116L294 117L293 116L294 116L294 115L293 114L294 114L294 113L294 112L294 113L295 112L295 111L296 111L297 111L298 110L299 110L300 110L301 110L301 109L302 109L302 108L302 107L303 106L303 107L304 107L304 106L305 105L306 105L306 104L307 104L308 104L308 105L309 105L310 105L309 104L310 104L310 103L311 103L311 102L312 102L313 102L312 101L313 101L314 102L315 102L316 102L317 102L317 103L316 103L316 104L315 105L316 105L316 106L317 106L318 106L318 107L319 107L320 108L321 107L321 106L322 105L322 104L322 103L322 102L322 101L323 101L323 102L324 103L324 104ZM301 100L300 100L299 100L300 99L300 100L301 100ZM341 100L340 100L340 99L341 100ZM342 100L341 99L341 98L341 99L342 100ZM304 100L303 100L304 100L304 99L305 99L306 98L307 98L307 99L306 99L305 99L304 100ZM298 98L299 98L299 99L298 99L297 99L297 98L298 98ZM303 98L303 99L301 99L300 99L300 98L301 98L301 99L302 98L303 98ZM340 98L340 99L339 98L338 97L339 98L340 98ZM289 97L291 97L291 96L293 97L293 98L294 98L296 98L295 99L293 98L292 98L291 98L289 98L288 98L286 97L285 97L286 96L287 96L288 96L289 97ZM315 96L314 97L314 96L314 95L315 96ZM336 97L335 97L335 96L335 95L335 96L336 96L336 97ZM332 95L331 96L330 96L329 96L328 96L328 95L329 96L330 96L330 95L330 96L331 95L332 95L332 94L332 95ZM307 93L307 94L306 94L306 93L307 93ZM310 93L311 94L310 93L309 93L308 93L309 93L310 93ZM333 94L333 95L333 94L332 94L332 93L331 93L332 93L333 94ZM314 91L314 93L315 93L316 92L317 92L318 92L319 92L320 92L321 93L323 93L325 94L326 95L328 96L328 97L327 97L328 98L329 99L329 100L330 100L331 100L331 101L330 101L330 100L329 100L328 100L327 99L326 98L325 98L324 98L323 98L323 99L322 99L321 99L320 98L319 98L318 98L319 97L318 96L318 95L316 95L315 94L314 94L313 94L313 93L312 93L313 92L314 92L312 92L311 91L312 91L312 90L314 91ZM305 89L304 90L303 90L301 90L300 90L300 91L301 91L303 91L302 92L302 93L302 94L303 95L303 96L302 95L303 94L302 95L301 95L302 94L301 94L301 93L300 93L300 94L300 96L299 95L300 94L299 93L299 92L299 91L300 90L300 89L301 89L302 89L303 89L304 89L305 88L305 89ZM309 89L309 90L308 90L308 91L308 90L307 89L308 88L309 88L309 89ZM286 96L285 96L284 95L283 94L282 94L281 93L281 92L280 91L279 90L279 89L279 88L278 88L277 87L276 86L275 85L276 85L277 85L278 86L279 86L280 87L281 88L282 88L282 89L283 89L284 90L283 91L284 91L285 92L286 92L286 93L286 94L286 96ZM298 88L299 89L298 89L297 90L298 91L297 91L297 92L296 94L295 94L294 93L293 93L292 93L291 93L290 93L290 92L290 91L289 90L289 89L290 88L291 88L291 87L292 87L293 87L294 86L294 85L295 85L296 84L297 83L298 84L299 85L298 85L299 86L298 86L297 87L298 88ZM306 82L307 83L306 84L306 83L305 83L306 84L305 84L304 84L304 83L304 82L303 83L302 83L302 82L303 82L303 81L304 82L305 81L305 80L306 81L306 82ZM261 84L260 84L260 83L260 82L260 80L261 81L262 82L262 84L261 84ZM304 80L303 81L302 80L303 80L303 79L303 80L304 79L304 80ZM299 81L297 82L298 81L298 80L299 80L300 79L299 80L299 81ZM302 78L303 78L303 79L302 80L302 79L302 78ZM306 78L306 79L305 79L305 80L305 79L304 79L305 79L305 78L304 77L305 77L306 78ZM302 77L301 78L301 77L300 77L301 77L302 77ZM301 71L302 72L303 73L302 74L302 75L302 76L303 76L304 76L304 77L303 77L303 76L303 77L302 76L301 76L301 75L301 76L300 75L300 74L300 72L301 71ZM114 72L113 72L113 71L114 71L114 72ZM103 72L102 72L102 71L102 72L103 72L104 72L103 72ZM107 70L108 70L109 70L110 70L110 71L111 71L112 71L111 72L110 72L109 72L108 72L107 72L106 72L106 71L107 71L107 72L108 71L107 71L107 70ZM290 71L289 72L289 71L289 70L290 70L291 70L291 71L290 71ZM24 71L24 70L25 70L25 71L24 71ZM100 67L101 68L102 67L102 68L103 68L103 69L104 69L105 69L106 70L105 70L104 70L102 70L103 70L103 69L102 69L101 68L100 68L99 68L98 68L98 67L97 67L97 68L96 68L95 68L96 68L96 67L97 67L98 67L99 67L100 67ZM102 66L102 65L102 66ZM301 67L301 68L300 67L300 66L301 65L302 65L302 66L301 67ZM315 56L314 57L314 56L313 57L312 57L313 56L314 56L315 56ZM215 54L214 55L213 55L212 55L213 55L214 55L215 54ZM204 54L204 55L205 55L206 55L205 55L204 55L204 54ZM196 52L195 53L194 53L192 52L193 52L194 52L195 52L196 52ZM189 49L190 49L190 51L189 51L188 51L188 50L188 49L189 49ZM321 53L321 54L320 55L319 55L317 55L316 57L315 56L315 55L313 56L312 56L311 56L312 57L311 59L310 59L310 58L310 57L309 57L310 56L311 56L312 55L313 55L315 54L316 54L317 53L319 52L320 51L320 49L321 49L322 50L322 51L321 52L321 53ZM190 48L189 49L189 48L189 47L190 48ZM324 46L325 46L326 47L324 47L323 48L322 47L321 48L320 48L320 47L321 47L322 45L322 44L323 45L324 46ZM116 43L117 44L118 44L117 44L116 44L116 43ZM118 41L116 41L115 40L116 40L117 40L118 41ZM56 41L56 42L54 41L53 40L52 40L52 39L53 39L53 40L54 40L55 40L55 41L56 41ZM124 39L123 40L124 40L125 40L124 40L125 41L126 40L127 41L126 41L127 41L127 42L127 43L126 43L126 42L125 43L124 43L125 43L124 42L123 42L121 42L121 41L122 41L123 39L124 38L125 38L124 39ZM47 36L48 36L48 37L49 38L48 38L48 37L47 37L47 36ZM324 39L325 41L323 41L323 42L324 43L324 44L323 43L322 44L322 43L322 42L322 41L322 40L322 39L322 38L322 37L323 36L322 36L323 36L323 37L323 38L324 39ZM173 38L171 38L170 38L171 37L170 36L172 35L173 35L174 35L174 36L174 37L173 38ZM193 34L192 35L191 35L191 34L192 34L193 34ZM27 33L26 33L25 33L26 32L27 32L28 32L27 33ZM177 31L176 32L177 32L178 32L178 33L177 34L178 34L179 35L180 36L180 37L182 37L182 38L181 38L181 39L179 39L178 39L177 39L176 40L175 40L174 40L176 39L177 39L175 38L176 38L175 37L177 37L177 36L176 35L175 35L175 34L174 35L174 34L174 33L174 32L175 31L176 31L177 31ZM14 30L13 30L14 30ZM98 27L97 28L96 28L97 27L98 27ZM8 26L9 26L10 26L10 27L11 27L10 27L9 27L8 27L8 26ZM95 24L95 25L96 25L97 25L98 26L99 26L100 26L99 27L97 26L96 26L94 27L94 26L93 26L94 26L94 25L94 24L95 24ZM165 24L166 25L165 26L162 26L161 27L160 26L157 26L158 26L156 25L158 25L156 24L158 24L159 24L161 24L162 24L164 23L165 24ZM104 23L103 23L103 22L104 22L105 22L105 23L104 23ZM5 23L6 24L5 23L8 23L10 24L9 24L7 25L7 26L6 26L5 25L4 25L3 24L2 25L1 24L0 24L1 25L0 25L0 21L2 22L5 23ZM84 21L82 21L80 21L81 20L82 20L83 20L84 21ZM360 19L359 19L360 18L360 19ZM1 19L0 19L0 18L1 18L2 19L1 19ZM89 21L89 22L91 21L92 21L92 22L93 23L94 22L94 21L94 20L96 20L97 20L99 21L98 22L99 22L99 23L97 24L95 24L94 23L94 24L93 25L92 26L90 26L89 26L89 27L88 27L87 28L86 29L85 30L85 31L87 31L87 32L88 33L89 33L91 33L92 34L93 34L94 34L95 35L97 35L98 35L98 36L98 37L99 38L100 39L101 38L101 37L101 36L100 35L102 35L103 34L103 33L103 32L101 31L103 30L102 29L102 28L103 27L104 28L105 28L106 28L107 28L108 28L109 29L110 29L110 30L111 31L112 31L112 32L114 31L115 30L116 31L117 32L119 33L118 34L120 34L120 35L122 35L123 35L123 36L124 36L124 37L124 38L123 39L121 39L120 40L118 40L116 40L115 40L114 40L113 40L111 41L110 42L109 43L110 43L111 42L113 41L115 41L116 41L115 42L115 43L116 44L117 44L118 44L119 43L120 44L119 45L117 45L116 46L115 46L114 46L116 45L114 45L113 45L112 46L111 46L110 46L109 47L109 48L110 48L109 49L108 49L107 49L106 49L108 49L107 49L106 49L106 50L105 51L104 51L105 51L105 52L104 53L104 52L104 51L103 51L104 52L103 52L104 52L104 53L104 54L104 55L103 55L102 56L101 56L101 57L100 57L99 58L99 59L99 60L99 61L99 62L100 63L100 64L100 65L99 65L99 64L98 64L98 63L97 63L97 62L97 61L96 60L95 60L94 60L92 60L91 60L90 60L91 60L91 61L90 61L89 61L88 60L87 60L86 60L85 61L84 61L83 62L83 63L83 64L82 65L82 66L82 67L82 68L83 69L83 70L84 71L85 71L86 72L87 71L88 71L89 71L89 70L90 69L91 69L92 69L93 68L93 69L93 70L92 70L93 71L92 71L92 72L92 71L92 72L92 73L91 74L92 74L93 74L94 74L95 74L96 74L96 75L97 75L97 76L96 76L96 77L97 77L97 78L96 78L96 79L97 80L98 81L99 81L100 81L100 80L101 80L101 81L102 81L103 81L104 81L104 80L105 79L106 79L107 79L107 78L108 78L109 78L108 79L108 80L108 81L109 81L109 80L109 79L110 79L110 78L110 79L111 79L112 79L113 79L114 79L114 80L115 80L116 80L116 79L117 79L118 79L117 80L118 80L119 81L120 81L120 82L121 82L122 83L122 84L123 84L124 84L125 84L126 84L127 85L128 85L128 86L129 86L129 88L130 88L130 89L129 90L130 90L131 90L131 91L132 91L133 91L135 92L136 92L135 93L137 92L139 93L140 93L141 94L143 95L144 95L145 95L145 97L145 99L144 100L143 101L142 102L142 103L141 103L141 104L141 106L141 107L141 108L140 108L140 110L139 111L139 112L138 112L138 113L137 113L135 113L135 114L134 114L132 115L132 116L131 117L132 117L131 118L131 119L130 119L129 121L128 122L127 123L127 124L126 124L125 125L124 125L123 124L122 124L123 125L123 126L123 127L122 128L121 129L119 129L118 129L118 130L118 131L117 131L116 131L115 131L115 132L116 132L117 133L116 133L115 133L115 135L114 135L113 135L113 136L112 136L113 137L114 137L114 138L113 139L112 140L111 140L111 141L111 142L112 142L111 142L110 143L109 143L109 144L107 144L106 143L105 142L105 141L105 140L104 139L105 138L106 137L104 137L105 136L106 134L107 134L107 132L106 133L106 132L106 130L107 129L106 128L106 127L107 127L107 126L108 124L109 122L108 121L109 120L109 119L109 118L109 116L110 114L110 111L110 110L110 108L109 108L109 107L107 106L105 105L104 105L104 104L103 102L102 100L101 98L100 97L99 97L99 96L99 95L99 94L100 93L100 92L100 93L99 92L99 91L100 90L100 89L101 89L101 88L102 87L103 86L103 85L102 84L103 84L103 83L102 83L102 82L101 81L100 81L100 82L100 83L99 83L99 82L98 82L97 82L96 82L96 81L95 80L94 80L94 79L93 78L92 77L93 77L92 77L91 77L90 76L89 76L88 76L88 75L87 74L86 74L85 74L84 74L83 74L82 74L81 73L80 73L79 73L78 72L76 72L76 71L75 71L75 70L74 70L75 69L74 69L75 69L74 68L74 67L73 66L72 65L71 64L70 63L69 62L68 62L68 61L67 60L67 59L66 58L65 58L65 59L65 60L66 60L66 61L67 61L67 62L68 62L68 63L69 64L69 65L69 66L70 66L71 67L70 67L69 66L68 66L68 65L68 64L67 64L67 63L66 63L65 62L66 62L66 61L65 61L64 60L64 59L63 58L63 57L62 56L61 56L60 56L59 55L58 54L57 52L56 51L56 50L56 49L56 48L55 47L56 46L56 44L56 43L56 42L55 42L57 42L57 43L58 43L58 42L57 41L55 40L54 40L53 39L52 38L51 37L51 36L49 36L49 35L48 35L48 34L46 33L46 32L45 32L43 32L42 31L40 30L39 30L37 30L36 30L34 30L33 29L32 29L32 30L31 30L30 30L29 31L28 31L28 30L29 29L30 29L29 29L28 29L27 30L26 31L27 31L26 32L25 32L24 33L23 33L22 34L20 34L19 35L18 35L17 35L15 36L15 35L16 35L17 35L18 34L19 34L20 34L21 33L22 33L22 32L23 31L22 31L21 31L21 32L20 31L19 31L18 31L18 30L17 30L16 30L15 30L15 29L14 28L15 27L16 27L17 27L18 26L18 27L19 26L18 26L19 25L18 25L17 26L16 25L15 26L14 25L13 25L12 24L13 24L16 23L16 24L18 24L18 23L16 23L16 22L15 22L13 22L14 21L16 21L17 21L17 20L18 20L19 20L21 19L22 19L23 19L25 19L26 19L28 19L29 20L30 19L32 20L34 20L35 20L36 20L38 20L39 20L41 21L42 21L43 21L44 21L46 20L47 20L49 20L50 20L51 20L52 20L53 20L54 21L56 20L56 21L57 20L59 20L60 21L62 21L64 21L65 21L66 22L65 22L67 22L69 22L70 22L71 23L72 22L71 22L72 21L73 21L74 21L75 21L76 22L77 22L79 22L80 22L82 22L81 22L82 21L84 22L84 23L85 22L86 21L85 20L84 20L84 19L85 18L86 18L87 19L88 20L89 21ZM66 17L65 17L68 17L69 18L70 17L71 17L72 18L72 17L73 17L75 17L75 18L76 19L77 20L79 20L77 20L78 21L76 21L74 21L73 21L71 21L68 21L67 21L66 21L65 21L64 21L63 20L65 20L66 20L68 20L66 19L64 19L62 19L64 19L62 19L61 18L62 17L65 17L66 17ZM76 17L75 17L73 17L73 16L75 16L76 17ZM104 17L103 17L102 17L101 17L100 17L99 17L99 16L100 16L102 16L104 17ZM93 17L94 17L95 17L98 16L99 17L99 18L101 18L102 17L104 18L106 18L106 19L108 18L109 19L111 19L112 20L113 21L111 21L114 22L115 22L117 23L118 23L118 24L116 25L115 25L113 24L112 24L113 25L114 25L115 26L115 27L114 27L111 26L113 27L114 28L111 28L109 27L108 27L108 26L107 26L105 25L105 26L102 26L101 25L102 25L104 25L106 25L106 24L107 23L107 22L105 21L103 21L104 21L103 20L102 20L101 20L99 20L95 20L93 20L91 20L90 19L92 19L90 19L90 18L91 17L92 16L94 16L93 17ZM80 16L81 16L83 16L83 17L82 17L83 17L83 18L82 19L81 19L80 18L78 17L80 17L78 17L80 16ZM324 17L322 17L320 17L321 16L322 16L323 17L324 17ZM87 17L86 18L85 18L84 17L85 16L88 16L89 16L88 17L87 17ZM60 19L57 19L56 19L54 18L55 17L56 16L55 16L58 16L60 16L62 16L63 16L64 17L63 17L61 17L60 18L60 19ZM331 15L330 15L328 15L326 15L328 15L331 15ZM86 15L84 15L83 15L84 15L85 14L86 15ZM325 14L324 15L321 15L319 15L317 15L318 14L319 14L321 14L325 14ZM82 13L82 14L82 15L80 15L79 15L79 14L77 14L79 14L80 13L81 13L82 13ZM72 14L73 14L74 14L74 15L70 15L68 16L66 16L66 15L68 15L64 15L62 15L64 14L65 14L67 14L69 14L71 15L70 14L70 13L71 13L72 14ZM238 19L237 19L234 19L233 19L232 19L231 18L232 18L232 17L234 16L236 15L238 14L241 14L244 14L246 13L248 13L249 13L248 14L245 14L242 15L238 16L237 17L235 18L236 18L238 19ZM85 13L86 13L88 13L89 14L90 14L91 14L92 14L94 15L95 14L97 14L99 14L100 15L98 16L97 15L94 16L92 16L90 15L88 15L87 15L87 14L86 14L84 14L83 13L85 13ZM64 12L64 13L63 13L62 14L60 14L59 14L57 14L59 13L61 12L62 13L64 12ZM287 13L287 14L288 13L291 13L293 14L294 14L294 15L293 15L290 16L289 16L291 16L292 16L293 16L294 17L294 16L296 16L299 16L299 17L303 17L303 16L305 16L307 16L309 17L309 18L308 18L310 19L311 19L312 18L314 19L316 18L317 19L318 18L320 19L319 18L320 17L330 18L333 19L337 19L339 19L340 20L341 21L342 20L344 20L346 21L348 20L350 21L351 21L350 20L354 20L356 20L359 21L360 21L360 25L359 25L357 25L358 26L359 27L359 28L357 27L355 28L354 28L352 29L351 30L350 30L349 29L346 30L345 30L344 30L343 31L342 32L343 32L343 34L342 34L342 35L340 36L340 37L339 37L338 38L337 39L336 38L336 37L335 35L336 33L337 33L337 32L338 32L340 31L342 30L344 29L344 27L343 28L340 29L339 28L337 29L334 30L335 31L333 31L331 31L331 30L330 30L329 31L325 31L322 31L319 33L315 35L317 35L317 36L318 36L319 36L320 36L321 37L321 38L321 39L321 40L320 42L319 43L318 44L317 45L316 46L315 47L314 47L313 47L312 47L311 47L311 48L310 48L310 49L309 49L309 50L308 50L308 51L307 51L308 51L309 53L309 54L309 55L308 55L307 56L306 56L306 55L307 54L306 53L307 53L306 52L305 52L305 51L305 50L304 50L303 50L302 51L301 51L302 51L301 50L302 50L302 49L301 49L300 50L299 51L298 51L298 52L299 52L299 53L300 53L301 52L302 53L303 53L301 53L301 54L300 54L299 55L300 56L301 57L301 58L302 58L302 59L301 59L302 60L302 61L302 62L301 62L300 63L300 64L299 65L297 66L296 67L295 67L294 68L294 67L293 68L292 68L291 69L290 70L290 69L289 68L288 68L287 69L286 70L286 71L286 72L287 73L288 74L289 75L289 77L289 78L288 79L287 80L286 80L285 81L285 80L284 80L283 79L283 78L282 77L281 77L280 77L280 78L279 79L279 80L279 81L280 81L280 82L280 83L281 83L282 83L282 84L283 84L283 85L283 86L283 87L284 87L284 88L284 89L283 88L281 87L281 86L281 85L280 85L280 84L280 83L279 82L278 82L278 81L279 80L278 79L279 79L278 78L279 77L278 76L278 75L278 74L277 73L277 74L275 74L274 74L275 73L274 72L274 71L274 70L273 70L272 69L272 68L271 67L270 67L271 68L270 68L269 68L268 68L267 69L266 70L265 71L264 72L263 72L262 73L262 74L261 74L260 74L260 75L260 76L260 77L260 78L260 80L259 80L259 81L258 81L258 82L257 81L256 80L256 79L255 78L255 77L255 76L254 75L254 74L253 72L253 71L253 70L253 69L251 69L250 69L249 68L250 68L249 67L248 66L247 66L247 65L246 65L245 65L243 65L241 65L240 65L239 64L237 64L237 63L236 63L235 64L233 63L232 62L231 61L230 60L229 60L228 60L228 61L229 62L229 63L230 63L230 64L231 65L231 64L232 64L232 65L231 65L232 66L233 66L234 66L235 65L236 64L236 65L237 66L238 66L239 66L239 67L240 67L240 68L239 68L239 69L238 70L238 71L237 71L237 72L236 72L235 72L235 73L234 73L233 73L232 74L231 75L230 75L229 76L228 76L227 76L227 77L226 77L225 77L224 77L223 77L223 76L223 75L223 74L223 73L222 73L222 72L221 71L220 70L219 69L219 68L219 67L218 66L217 66L217 65L217 64L216 63L215 62L215 61L215 60L215 61L214 62L213 62L212 60L213 61L213 62L214 64L215 65L216 66L215 66L216 67L217 68L217 69L217 70L217 71L218 72L219 73L219 74L220 75L221 76L222 76L222 77L223 77L223 78L223 79L224 79L224 80L225 80L226 79L227 79L228 79L229 79L230 78L231 78L231 79L231 80L231 81L230 82L229 83L229 85L228 86L227 87L226 88L224 89L223 90L222 91L222 92L221 92L220 93L220 94L219 95L219 96L219 97L219 98L220 99L220 100L220 101L220 102L221 103L221 104L221 105L220 105L220 106L219 107L217 108L216 109L215 110L215 111L215 112L216 112L216 113L215 114L216 114L215 114L214 115L213 115L213 116L213 117L212 118L212 119L211 119L211 120L210 121L209 122L208 123L207 123L206 124L205 124L204 124L203 124L202 124L201 124L200 125L199 124L198 124L198 123L198 122L198 121L197 120L196 119L196 118L195 117L195 116L195 115L194 114L194 113L194 112L193 111L193 110L193 109L192 108L192 107L192 106L192 105L192 104L193 104L193 103L193 102L194 102L194 101L193 100L193 99L193 98L193 97L192 96L192 95L191 94L190 93L189 92L189 91L189 90L189 89L190 88L190 87L189 86L188 86L189 85L187 86L186 86L185 85L185 84L184 84L183 84L182 84L181 84L179 85L178 85L177 85L176 85L175 85L174 85L173 85L172 86L171 85L170 84L169 84L169 83L168 83L167 82L167 81L166 81L166 80L165 80L165 79L164 79L164 78L163 78L163 77L163 76L162 75L163 75L163 74L164 74L163 73L164 73L164 72L164 71L164 70L163 69L163 68L164 67L164 66L165 66L165 65L165 64L166 64L166 63L167 62L168 62L169 61L170 61L170 60L170 59L171 58L171 57L172 56L173 56L174 55L174 54L175 54L175 55L176 55L177 55L178 55L179 54L180 54L181 54L181 53L183 53L185 53L186 53L187 53L188 53L190 53L191 53L191 54L191 55L190 56L191 56L191 57L193 57L194 57L195 58L196 59L197 59L198 59L199 60L200 59L200 58L201 57L202 57L203 57L203 58L204 58L205 58L206 58L207 59L208 59L209 59L210 59L211 58L212 59L213 59L214 59L215 58L214 58L215 58L215 57L215 56L216 55L216 54L216 53L215 53L214 54L213 54L212 53L211 53L210 54L209 53L208 53L207 52L206 52L207 51L206 51L207 50L209 50L209 49L211 49L212 48L214 48L215 48L217 49L218 49L220 49L222 48L221 47L220 47L219 46L218 45L217 45L218 44L218 43L219 43L218 43L217 43L216 43L215 44L216 45L217 45L216 45L215 45L214 46L213 45L214 45L212 45L213 44L214 44L213 44L212 44L212 43L211 43L210 44L210 45L209 45L209 46L208 47L208 48L209 49L208 49L207 49L206 50L206 49L205 49L204 49L204 50L203 50L203 51L204 51L204 52L203 52L203 53L203 54L202 54L202 53L201 52L201 51L200 51L200 50L199 50L199 49L200 48L199 48L198 48L198 47L197 47L196 46L195 46L195 45L194 45L194 44L193 44L192 45L193 46L194 46L194 47L195 48L196 48L197 49L198 49L198 50L197 50L196 50L197 51L196 52L196 51L196 50L195 50L195 49L194 49L193 49L192 48L191 48L191 47L190 46L189 46L188 46L187 46L187 47L185 47L183 47L183 48L182 49L181 49L180 50L180 51L180 52L179 52L179 53L178 53L177 53L176 53L175 54L174 54L173 53L172 53L171 53L171 52L170 51L171 51L171 50L171 49L171 48L171 47L172 46L173 46L175 46L176 47L178 47L179 46L179 44L178 43L177 42L176 42L175 41L177 41L178 41L178 40L179 41L181 40L182 39L183 39L184 38L185 37L186 36L187 37L187 36L188 36L189 36L189 35L188 34L188 33L189 33L190 33L191 32L191 33L190 33L191 34L190 34L190 35L191 36L192 36L193 36L194 36L195 36L196 35L198 35L199 35L199 36L200 36L200 35L201 35L201 34L201 33L202 33L203 32L203 33L204 33L204 32L203 31L205 31L206 30L207 31L208 31L209 30L208 29L206 30L204 30L203 30L202 30L201 29L202 28L201 27L202 27L202 26L205 25L205 24L204 24L202 24L201 25L201 26L200 26L198 27L197 29L198 29L199 30L198 31L197 31L196 33L196 34L195 34L194 35L193 35L193 34L192 33L191 31L190 31L188 32L187 32L186 31L185 30L185 28L186 27L189 27L191 26L192 24L195 22L196 21L199 20L201 20L203 20L205 19L206 19L208 19L211 20L210 20L211 20L212 20L214 21L217 21L220 22L221 23L220 24L218 24L214 23L213 23L215 24L215 26L216 26L217 26L217 25L220 25L222 24L223 24L224 24L225 23L224 23L224 22L223 21L226 22L227 22L226 22L226 23L228 23L228 22L230 22L234 21L233 22L235 22L237 22L239 21L240 22L241 21L240 20L241 20L244 20L245 21L249 22L249 21L248 21L247 21L247 20L247 19L249 18L249 17L250 17L253 17L253 18L252 19L253 20L253 21L254 22L253 22L251 24L252 24L253 23L254 23L255 22L254 22L255 21L254 21L254 20L254 19L253 19L255 18L255 17L256 18L255 19L256 19L256 18L258 18L260 18L262 18L261 17L261 16L262 16L265 16L267 16L266 16L267 15L268 15L270 14L273 14L276 14L277 14L279 14L281 14L281 13L282 13L284 12L286 13L285 13L287 13ZM229 49L230 49L230 50L229 51L229 52L230 53L231 53L232 53L234 53L234 52L234 51L233 51L233 50L233 49L234 49L235 49L234 48L233 48L233 49L233 48L232 48L233 48L233 47L231 47L231 46L230 46L230 45L231 45L232 45L233 45L233 44L233 43L232 43L231 43L230 43L229 44L228 44L227 45L228 46L227 47L229 48L229 49ZM86 12L86 13L84 12L86 12ZM70 12L68 13L66 12L67 12L69 12L70 12ZM205 12L202 13L201 12L203 12L205 12ZM70 11L69 12L67 12L67 11L68 11L69 11L70 11ZM84 12L83 12L82 12L81 12L81 11L83 11L84 12ZM80 12L79 12L77 12L75 12L76 11L75 11L76 11L79 11L80 12ZM285 12L279 12L281 11L282 11L283 11L285 11L285 12ZM198 10L202 11L199 11L198 12L197 13L196 13L194 13L195 12L193 12L191 11L190 10L193 10L194 10L195 10L196 10L197 10L198 10ZM205 10L207 10L206 10L203 11L200 10L198 10L197 10L200 9L202 10L203 9L205 10ZM231 9L230 10L229 10L228 10L227 10L227 9L225 9L227 9L228 9L229 9L230 9L232 9L231 9ZM280 11L278 11L275 11L273 11L273 10L271 10L274 9L276 9L278 9L280 10L280 11ZM93 10L94 11L93 11L91 12L89 12L87 12L86 11L87 11L85 11L84 10L83 10L84 9L85 9L86 9L85 9L88 9L89 9L91 9L92 10L93 10ZM112 7L114 7L116 7L118 7L118 8L116 8L113 8L112 8L115 8L112 9L111 9L109 10L107 10L106 11L103 11L104 11L105 11L104 12L102 12L100 13L102 13L99 14L97 14L94 14L92 14L91 14L90 13L92 13L92 12L95 12L94 12L92 12L93 11L95 11L93 10L96 10L97 10L98 10L96 9L92 9L91 9L90 9L89 8L88 8L90 8L91 8L93 8L95 7L96 7L97 8L98 7L99 7L101 7L104 7L107 7L109 7L112 7ZM153 6L159 7L157 8L153 8L148 8L149 8L152 8L155 8L157 8L158 8L157 9L159 8L164 8L167 8L168 9L164 9L163 10L160 10L162 10L161 11L160 11L160 12L162 13L160 13L158 13L160 14L160 15L159 15L161 16L158 16L160 16L159 17L158 17L156 17L158 17L158 18L156 17L155 18L157 18L158 19L156 20L156 19L154 19L155 19L154 20L156 20L158 20L155 21L152 22L149 22L148 22L147 22L146 23L144 24L143 24L142 24L140 25L139 25L139 26L139 27L137 27L138 28L137 29L137 30L135 30L134 29L132 29L131 29L130 28L128 26L128 25L126 24L127 23L126 23L127 22L129 21L129 20L128 20L127 21L125 20L126 19L127 19L129 19L127 19L126 18L125 19L124 18L125 17L124 16L123 15L121 15L121 14L119 14L117 14L114 14L111 14L110 14L109 13L111 13L113 13L109 12L107 12L111 11L114 11L115 10L112 10L113 9L116 9L118 9L117 8L120 8L123 8L126 8L127 8L130 8L132 8L133 8L135 8L133 8L133 7L137 7L140 7L141 6L145 6L153 6Z";var On=360,Gs=180,Is=s=>s+180,Fs=s=>90-s,kg=9,Hd=23.44,jd=66.56,Kd=s=>s===0?"0":`${Math.abs(s)}\xB0${s>0?"E":"W"}`,Vd=s=>s===0?"0":`${Math.abs(s)}\xB0${s>0?"N":"S"}`;function Sg(s){let a=[],e=[],t=null;for(let r of s)t!==null&&Math.abs(r.longitude-t)>180&&(e.length&&a.push(e),e=[]),e.push(`${Is(r.longitude)},${Fs(r.latitude)}`),t=r.longitude;return e.length&&a.push(e),a.filter(r=>r.length>1).map(r=>r.join(" "))}var Ud={mc:"MC",ic:"IC",ascendant:"ASC",descendant:"DSC"},pr=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this)}updated(e){super.updated(e);for(let t of this.renderRoot.querySelectorAll('svg[part="chart"]')){if(typeof t.getBBox!="function")continue;let{x:r,y:n,width:i,height:o}=t.getBBox();t.setAttribute("viewBox",[r-1,n-1,i+2,o+2].join(" "))}}renderData(e){let t=e.lines??[],r=e.birthDetails;return ke.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Astrocartography")}</h2>${r?ke.html`<p class="roxy-label">${fe(this.effectiveLang(),r.date,r.time)} · ${Vd(Math.round(r.latitude))} ${Kd(Math.round(r.longitude))}</p>`:ke.nothing}</header>${this.chartViewport.renderChartViewport(this.renderMap(t,r),this.t("Astrocartography"),this.translator)} ${this.renderLegend(t)} ${e.summary&&!this.hideReadings?ke.html`<p class="summary">${e.summary}</p>`:ke.nothing} ${this.renderInterpretations(t)}</div>`}renderMap(e,t){return ke.html`<svg viewBox="0 0 ${On} ${Gs}" part="chart" role="img" aria-label="${this.t("World map of planetary astrocartography lines")}"><title>${this.t("Astrocartography world map")}</title><desc>${this.t("Equirectangular world map. Each body has a Midheaven and Imum Coeli meridian and a curved Ascendant and Descendant line, colored per body.")}</desc><rect class="map-frame" x="0" y="0" width="${On}" height="${Gs}"/><path class="land" d="${Bd}" fill-rule="evenodd"/>${this.renderGraticule()} ${this.renderBodyLines(e)} ${t?ke.svg`<text class="birthplace roxy-glyph" x=${Is(t.longitude)} y=${Fs(t.latitude)} text-anchor="middle" dominant-baseline="central"><title>${this.t("Birth location")}</title>${Ed}</text>`:ke.nothing}</svg>`}renderGraticule(){let e=[];for(let n=-150;n<=150;n+=30){let i=Is(n),o=n===0;e.push(ke.svg`<line class=${o?"grat-axis":"grat"} x1=${i} y1="0" x2=${i} y2=${Gs} />`),e.push(ke.svg`<text class="axis-label" x=${i} y=${Gs-2} text-anchor="middle">${Kd(n)}</text>`)}let t=[];for(let n=-60;n<=60;n+=30){let i=Fs(n),o=n===0;t.push(ke.svg`<line class=${o?"grat-axis":"grat"} x1="0" y1=${i} x2=${On} y2=${i} />`),t.push(ke.svg`<text class="axis-label" x="2" y=${i-1}>${Vd(n)}</text>`)}let r=[Hd,-Hd,jd,-jd].map(n=>ke.svg`<line class="grat-ref" x1="0" y1=${Fs(n)} x2=${On} y2=${Fs(n)} />`);return ke.svg`${e}${t}${r}`}renderBodyLines(e){let t=e.map((d,h)=>{let p=y(d,"planet");return{line:d,name:p,color:ms(d.planet,h),glyph:S(d.planet)??p}}),r=d=>d.reduce((h,p)=>Math.abs(p.latitude)<Math.abs(h.latitude)?p:h,d[0]??{latitude:0,longitude:0}),n=d=>new Map(Yt(t,h=>d(h)+180,kg).map(({item:h,displayLongitude:p})=>[h,p-180])),i=n(d=>d.line.mc.longitude),o=n(d=>d.line.ic.longitude),l=n(d=>r(d.line.ascendant.points??[]).longitude),c=n(d=>r(d.line.descendant.points??[]).longitude);return t.map(d=>{let{line:h,name:p,color:f,glyph:L}=d,$=k=>k.get(d)??0;return ke.svg`${[this.renderMeridian(h.mc.longitude,$(i),f,L,p,"mc",false),this.renderMeridian(h.ic.longitude,$(o),f,L,p,"ic",true),this.renderCurve(h.ascendant.points,{longitude:$(l),latitude:r(h.ascendant.points??[]).latitude},f,L,p,"ascendant",false),this.renderCurve(h.descendant.points,{longitude:$(c),latitude:r(h.descendant.points??[]).latitude},f,L,p,"descendant",true)]}`})}renderMeridian(e,t,r,n,i,o,l){let c=Is(e),d=o==="ic"?Gs-16:9;return ke.svg`<g>
|
|
2
|
+
<line class=${`acg-line${l?" dashed":""}`} stroke=${r} x1=${c} y1="0" x2=${c} y2=${Gs}><title>${this.t("{{planet}} {{angle}} line",{planet:i,angle:this.t(Ud[o]??"MC")})}</title></line>
|
|
3
|
+
<text class="acg-glyph roxy-glyph" fill=${r} x=${Is(t)} y=${d} text-anchor="middle" dominant-baseline="central">${n}</text>
|
|
4
|
+
</g>`}renderCurve(e,t,r,n,i,o,l){let c=Sg(e??[]);return c.length===0?ke.nothing:ke.svg`<g>
|
|
5
|
+
${c.map(d=>ke.svg`<polyline class=${`acg-line${l?" dashed":""}`} stroke=${r} points=${d}><title>${this.t("{{planet}} {{angle}} line",{planet:i,angle:this.t(Ud[o]??"MC")})}</title></polyline>`)}
|
|
6
|
+
<text class="acg-glyph roxy-glyph" fill=${r} x=${Is(t.longitude)} y=${Fs(t.latitude)} text-anchor="middle" dominant-baseline="central">${n}</text>
|
|
7
|
+
</g>`}renderLegend(e){return e.length===0?ke.nothing:ke.html`<div class="legend" part="legend">${e.map((t,r)=>{let n=ms(t.planet,r);return ke.html`<span class="legend-item"><span class="legend-swatch" style="${`border-block-start-color: ${n}`}"></span> ${Je(S(t.planet))}${y(t,"planet")}</span>`})} <span class="legend-note">${this.t("Solid lines are the Ascendant and Midheaven, dashed are the Descendant and IC.")}</span></div>`}renderInterpretations(e){return e.length===0||this.hideReadings?ke.nothing:ke.html`<section class="block" part="section readings"><h3>${this.t("Planetary lines")}</h3>${e.map((t,r)=>{let n=ms(t.planet,r),i=[["MC",t.mc.interpretation],["IC",t.ic.interpretation],["AC",t.ascendant.interpretation],["DC",t.descendant.interpretation]];return ke.html`<details class="interp-card" part="reading" name="acg-lines" ?open="${r===0}"><summary><span class="interp-lead"><span class="interp-dot" style="${`background: ${n}`}"></span> ${Je(S(t.planet))}${y(t,"planet")} </span>${he()}</summary><div class="interp-body">${i.filter(([,o])=>o).map(([o,l])=>ke.html`<p class="interp-line"><span class="code">${o}</span>${l}</p>`)}</div></details>`})}</section>`}};pr.endpoints=dl,pr.styles=[u,et,X,me,ke.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}svg{border-radius:var(--roxy-radius-sm);width:100%;height:auto;display:block}.map-frame{fill:color-mix(in srgb, var(--roxy-border) 12%, transparent);stroke:var(--roxy-border);stroke-width:.8px}.land{fill:var(--roxy-secondary);opacity:.13}.grat{stroke:var(--roxy-border);stroke-width:.4px;fill:none}.grat-axis{stroke:var(--roxy-muted);stroke-width:.6px;opacity:.6}.grat-ref{stroke:var(--roxy-secondary);stroke-width:.4px;stroke-dasharray:2 2;opacity:.5;fill:none}.axis-label{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .3125)}.acg-line{fill:none;stroke-width:1px;opacity:.95}.acg-line.dashed{stroke-dasharray:4 2.5}.acg-glyph{font-size:calc(var(--roxy-text-base) * .5);font-weight:var(--roxy-weight-bold)}.birthplace{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .5625)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.legend-item{align-items:center;gap:var(--roxy-space-xs);display:inline-flex}.legend-swatch{inline-size:var(--roxy-space-md);border-block-start:var(--roxy-line-thick) solid;block-size:0}.legend-note{width:100%}.summary,.interp-line{font-size:var(--roxy-text-sm)}.interp-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);flex-shrink:0;align-self:center}.interp-line .code{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);margin-inline-end:var(--roxy-space-xs)}`],pr=m([x("roxy-astrocartography-map")],pr);var ce=require("lit");var qd=require("lit");var Rg=new Set(["wood","fire","earth","metal","water"]);function At(s){let a=$t(s??"");return Rg.has(a)?`element-${a}`:""}var ma=qd.css`.element-wood{--_element:var(--roxy-success);--_element-ink:var(--roxy-success-fg)}.element-fire{--_element:var(--roxy-danger);--_element-ink:var(--roxy-danger-fg)}.element-earth{--_element:var(--roxy-warning);--_element-ink:var(--roxy-warning-fg)}.element-metal{--_element:var(--roxy-secondary);--_element-ink:var(--roxy-secondary)}.element-water{--_element:var(--roxy-info);--_element-ink:var(--roxy-info-fg)}.element-word{color:var(--_element-ink)}`;var Cg={year:"Year",month:"Month",day:"Day",hour:"Hour"},Yd={harmonious:"Harmonious",challenging:"Challenging"},Wd={"stem-combination":"Stem combination","six-combination":"Six combination",trine:"Trine",clash:"Clash",harm:"Harm",punishment:"Punishment","stem-clash":"Stem clash"},Zd={deficient:"Deficient",balanced:"Balanced",excess:"Excess"},hr=class extends g{renderData(a){let e=this.effectiveLang(),t=fe(e,a.birthData?.date,a.birthData?.time);return ce.html`<article class="card" part="card" aria-labelledby="bazi-title"><header class="head" part="header"><h2 class="title" id="bazi-title">${this.t("Four pillars")}</h2>${t?ce.html`<span class="born">${t}</span>`:ce.nothing} ${a.zodiacAnimal?ce.html`<span class="roxy-chip animal">${y(a,"zodiacAnimal")}</span>`:ce.nothing}</header><div class="pillars-wrap" part="chart" role="region" tabindex="0" aria-label="${this.t("Four pillars")}"><div class="pillars">${(a.pillars??[]).map(r=>this.renderPillar(r))}</div></div>${this.renderDayMaster(a)} ${this.renderElements(a)} ${this.renderInteractions(a)} ${a.summary&&!this.hideReadings?ce.html`<p class="summary" part="section summary">${a.summary}</p>`:ce.nothing} ${lr(a.conventions,this.translator,this.effectiveLang())}</article>`}renderPillar(a){let e=Cg[a.position],t=a.position==="day";return ce.html`<div class="pillar ${t?"pillar-self":""}" part="pillar"><span class="pos roxy-label">${e?this.t(e):D(a.position)}</span> <span class="god">${y(a.tenGod,"name")}</span> <span class="hanzi" lang="zh">${a.stem?.chinese??""}</span> <span class="romanised">${a.stem?.pinyin??""} <span class="element-word ${At(a.stem?.element)}">${y(a.stem,"element")}</span></span> <span class="hanzi hanzi-branch" lang="zh">${a.branch?.chinese??""}</span> <span class="romanised">${a.branch?.pinyin??""} ${y(a.branch,"animal")}</span> ${a.hiddenStems?.length?ce.html`<hr class="rule"><ul class="hidden" aria-label="${this.t("Hidden stems")}">${a.hiddenStems.map(r=>ce.html`<li><span lang="zh">${r.stem?.chinese??""}</span> <span class="role">${r.role}</span> ${y(r.tenGod,"name")}</li>`)}</ul>`:ce.nothing} ${a.naYin?ce.html`<hr class="rule"><span class="nayin" title="${this.t("Na Yin")}">${a.naYin}</span>`:ce.nothing}</div>`}renderDayMaster(a){let e=a.dayMaster;return e?ce.html`<section part="section day-master"><h3 class="block-title">${this.t("Day Master")}</h3><div class="master"><span class="hanzi" lang="zh">${e.chinese??""}</span> <span><b class="element-word ${At(e.element)}">${y(e,"element")}</b> ${e.polarity??""} ${e.pinyin??""}</span> ${e.nature&&!this.hideReadings?ce.html`<p part="reading">${e.nature}</p>`:ce.nothing}</div></section>`:ce.nothing}renderElements(a){let e=a.fiveElements??[];if(e.length===0)return ce.nothing;let t=this.effectiveLang(),r=e.reduce((n,i)=>n+(i.count??0),0)||1;return ce.html`<section part="section elements"><h3 class="block-title">${this.t("Elements")}</h3><div class="elements">${e.map(n=>ce.html`<div class="element ${At(n.element)}" part="label-track"><span class="element-word">${y(n,"element")}</span> <span class="element-track"><span class="element-fill" style="width:${(n.count??0)/r*100}%"></span></span> <span class="element-count">${q(t,n.count??0)} ${n.level&&Zd[n.level]?this.t(Zd[n.level]):n.level??""}</span> ${n.reading&&!this.hideReadings?ce.html`<p class="element-reading" part="reading">${n.reading}</p>`:ce.nothing}</div>`)}</div></section>`}renderInteractions(a){let e=a.interactions??[];return e.length===0?ce.nothing:ce.html`<section part="section interactions"><h3 class="block-title">${this.t("Interactions")}</h3><ul class="interactions">${e.map(t=>ce.html`<li class="interaction"><div class="interaction-line"><span lang="zh">${t.chinese??""}</span> <b>${t.type&&Wd[t.type]?this.t(Wd[t.type]):D(t.type??"")}</b> ${t.quality?ce.html`<span class="roxy-chip tag tag-${t.quality}">${t.quality&&Yd[t.quality]?this.t(Yd[t.quality]):t.quality}</span>`:ce.nothing} <span>${(t.positions??[]).join(" ")}</span> ${t.transformsTo?ce.html`<span>${t.transformsTo}</span>`:ce.nothing} ${t.variety?ce.html`<span>${t.variety}</span>`:ce.nothing} ${t.type==="punishment"&&typeof t.complete=="boolean"?ce.html`<span class="completeness">${t.complete?this.t("Complete"):this.t("Partial")}</span>`:ce.nothing}</div>${t.meaning&&!this.hideReadings?ce.html`<p class="interaction-meaning" part="reading">${t.meaning}</p>`:ce.nothing}</li>`)}</ul></section>`}};hr.endpoints=pl,hr.styles=[u,re,ma,ce.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-sm) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.born{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.animal{margin-inline-start:auto}.pillars-wrap{min-width:0;overflow-x:auto}.pillars{grid-template-columns:repeat(4,minmax(12ch,1fr));display:grid}.pillar{gap:var(--roxy-space-xs);padding:var(--roxy-space-sm);border-block-start:var(--roxy-line-thick) solid transparent;text-align:center;align-content:start;display:grid}.pillar+.pillar{border-inline-start:1px solid var(--roxy-border)}.pillar-self{border-block-start-color:var(--roxy-accent)}.pillar-self .pos{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.god{min-block-size:1lh;color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.hanzi{font-size:calc(var(--roxy-text-base) * 2);line-height:var(--roxy-leading-tight)}.hanzi-branch{color:var(--roxy-accent-ink)}.romanised,.nayin,.hidden .role{color:var(--roxy-muted)}.romanised,.nayin{font-size:var(--roxy-text-xs)}.rule{inline-size:100%;margin:calc(var(--roxy-space-unit) / 2) 0;border:0;border-block-start:1px solid var(--roxy-border)}.hidden{gap:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);text-align:start;margin:0;padding:0;list-style:none;display:grid}.nayin{text-align:start}.master{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.master .hanzi{font-size:calc(var(--roxy-text-base) * 1.5)}.master p{color:var(--roxy-secondary);flex-basis:100%;margin:0}.elements{gap:var(--roxy-space-xs);display:grid}.element{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr) max-content;align-items:center;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);font-size:var(--roxy-text-sm);display:grid}.element-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.25lh;overflow:hidden}:where(.element){--_element:var(--roxy-accent)}.element-fill{background:var(--_element);height:100%;display:block}.element-count{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.element-reading,.interaction-meaning{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);margin:0}.element-reading{grid-column:1/-1}:is(.master p,.element-reading,.interaction-meaning){border-block-start:0}.interactions{margin:0;padding:0;list-style:none;display:grid}.interaction{gap:calc(var(--roxy-space-unit) / 2);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.interaction:first-child{border-block-start:0;padding-block-start:0}.interaction-line{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.tag-harmonious{color:var(--roxy-success-fg)}.tag-challenging{color:var(--roxy-danger-fg)}.summary{margin:0}`],hr=m([x("roxy-bazi-chart")],hr);var kt=require("lit");function ga(s,a){return!a||!s?.length?"":s.map(e=>a[String(e)]?.[0]).filter(Boolean).join(", ")}function Ji(s,a){return!a||typeof s!="number"?"":(a[String(s)]??[]).join(", ")}var mr=class extends g{renderData(a){let e=a.grahas??[],t=a.bhavas??[];if(!e.length&&!t.length)return this.renderEmpty();let r=e.filter(i=>i.moved),n=a.movedCount??r.length;return kt.html`<div class="wrap" part="card" aria-label="${this.t("Bhav Chalit")}"><header class="head" part="header"><h2 class="title">${this.t("Bhav Chalit")}</h2><p class="lede">${n===0?this.t("No graha changes house. The Rashi chart and the Chalit chart agree, which is a normal result rather than a missing reading."):this.t("{{count}} of {{total}} grahas change house between the Rashi chart and the unequal Sripati cusps.",{count:n,total:e.length})}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header>${r.length?kt.html`<div class="moved-list" part="table moved">${r.map(i=>this.renderMoved(i,a.houseThemes))}</div>`:kt.nothing} ${t.length?kt.html`<details part="details"><summary>${this.t("Bhava cusps and occupants")}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Bhava cusps and occupants")}"><table part="table"><thead><tr><th>${this.t("Bhava")}</th><th>${this.t("Rashi")}</th><th>${this.t("Start")}</th><th>${this.t("Madhya")}</th><th>${this.t("End")}</th><th>${this.t("Span")}</th><th>${this.t("Grahas")}</th></tr></thead><tbody>${t.map(i=>this.renderBhavaRow(i))}</tbody></table></div></details>`:kt.nothing}</div>`}renderMoved(a,e){let t=S(a.graha)??"",r=typeof a.bhava=="number"?ga([a.bhava],e):"";return kt.html`<div class="moved-row"><span class="graha">${t?kt.html`<span class="glyph roxy-glyph">${t}</span>`:kt.nothing}${a.graha} </span><span class="shift">${this.t("house {{from}} in the Rashi chart, house {{to}} here",{from:a.rashiHouse??"",to:a.bhava??""})} </span>${r?kt.html`<span class="themes">${r}</span>`:kt.nothing}</div>`}renderBhavaRow(a){let e=(a.grahas??[]).join(", ");return kt.html`<tr><td class="num">${a.house}</td><td>${a.rashi}</td><td class="num">${b(this.effectiveLang(),a.start,2)}°</td><td class="num">${b(this.effectiveLang(),a.madhya,2)}°</td><td class="num">${b(this.effectiveLang(),a.end,2)}°</td><td class="num">${b(this.effectiveLang(),a.span,2)}°</td><td class="occupants">${e}</td></tr>`}};mr.endpoints=hl,mr.styles=[u,re,kt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.lede{margin:0}.lede{font-size:var(--roxy-text-sm)}.moved-row{align-items:baseline;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.shift{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td.occupants{white-space:normal;color:var(--roxy-secondary)}summary{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}`],mr=m([x("roxy-bhav-chalit-table")],mr);var St=require("lit");var Xd=[{key:"bhavadhipatiBala",source:"Bhavadhipati",color:"var(--roxy-accent)"},{key:"digBala",source:"Dig",color:"var(--roxy-info)"},{key:"drishtiBala",source:"Drishti",color:"var(--roxy-success)"}],gr=class extends g{renderData(a){let e=a.bhavas??[];if(!e.length)return this.renderEmpty();let t=Math.max(...e.map(r=>r.totalVirupas??0),1);return St.html`<div class="wrap" part="card" aria-label="${this.t("Bhava Bala")}"><header class="head" part="header"><h2 class="title">${this.t("Bhava Bala")}</h2><p class="subtitle">${a.houseSystem?this.t("Twelve houses ranked by strength on the {{system}} frame",{system:a.houseSystem}):this.t("Twelve houses ranked by strength")}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header><div class="rows" part="table" role="list">${e.map(r=>this.renderBhava(r,t,a.houseThemes))}</div><div class="legend" part="legend" aria-label="${this.t("Component legend")}">${Xd.map(r=>St.html`<div class="legend-row"><span class="swatch" style="background:${r.color}" aria-hidden="true"></span> ${this.t("{{component}} Bala",{component:this.t(r.source)})}</div>`)}</div></div>`}renderBhava(a,e,t){let r=typeof a.house=="number"?ga([a.house],t):"";return St.html`<article class="row" role="listitem"><div class="row-top"><span class="house">${this.t("House {{n}}",{n:a.house})}</span> <span class="rashi">${a.rashi}</span> ${a.lord?St.html`<span class="lord">${this.t("lord {{graha}}",{graha:a.lord})}</span>`:St.nothing} <span class="total">${this.t("{{value}} rupas",{value:b(this.effectiveLang(),a.totalRupas,2)})} ${typeof a.rank=="number"?St.html`<span class="rank">#${a.rank}</span>`:St.nothing}</span></div><div class="bar" role="img" aria-label="${this.t("Bhava Bala {{value}} virupas",{value:b(this.effectiveLang(),a.totalVirupas,1)})}">${Xd.map(n=>{let i=Math.max(0,a[n.key]??0);return i>0?St.html`<span class="seg" style="width:${i/e*100}%;background:${n.color}" title="${this.t("{{component}} {{value}} virupas",{component:this.t(n.source),value:b(this.effectiveLang(),i,1)})}"></span>`:St.nothing})}</div>${r?St.html`<p class="themes">${r}</p>`:St.nothing}</article>`}};gr.endpoints=ml,gr.styles=[u,re,St.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.subtitle,.themes{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.row{gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row:last-child{border-block-end:0}.row-top{align-items:baseline;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.house{min-width:9ch;font-weight:var(--roxy-weight-bold)}.rashi{color:var(--roxy-secondary)}.lord{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.total{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);margin-inline-start:auto}.rank{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:var(--roxy-space-xs)}.bar{border-radius:var(--roxy-radius-full);background:color-mix(in srgb, var(--roxy-border) 55%, transparent);block-size:.5lh;display:flex;overflow:hidden}.seg{height:100%}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend-row{align-items:center;gap:var(--roxy-space-xs);display:flex}.swatch{border-radius:var(--roxy-radius-sm);block-size:.6lh;inline-size:1.5ch}`],gr=m([x("roxy-bhava-bala-table")],gr);var ee=require("lit"),Jd=require("lit/decorators.js");var Zs=["physical","emotional","intellectual","intuitive"],Gn={physical:"Physical",emotional:"Emotional",intellectual:"Intellectual",intuitive:"Intuitive"};function yr(s,a){let e=Gn[s];return e?a(e):D(s)}var In={physical:"var(--roxy-danger)",emotional:"var(--roxy-info)",intellectual:"var(--roxy-success)",intuitive:"color-mix(in oklab, var(--roxy-info) 50%, var(--roxy-danger))",aesthetic:"var(--roxy-warning)",awareness:"color-mix(in oklab, var(--roxy-danger) 70%, var(--roxy-info))",spiritual:"color-mix(in oklab, var(--roxy-success) 50%, var(--roxy-info))",passion:"color-mix(in oklab, var(--roxy-danger) 50%, var(--roxy-warning))",mastery:"var(--roxy-accent)",wisdom:"var(--roxy-muted)"},Tg={ascending:"ascending through zero",descending:"descending through zero"},Eg={double:"Double day",triple:"Triple day"},Ea=class extends g{constructor(){super(...arguments);this.mode="daily"}renderData(e){return this.mode==="critical-days"&&"criticalDays"in e?this.renderCritical(e):this.mode==="forecast"&&"days"in e?this.renderForecast(e):this.renderDaily(e)}renderDaily(e){let t=e.quickRead??{},r=Object.entries(t).map(([i,o])=>{let l=typeof o=="number"?o:0,c=Math.abs(l)>1?l/100:l;return[i,c]}),n=e.spotlight;return ee.html`<section class="wrap" part="card" aria-label="${this.t("Daily biorhythm")}"><header class="head" part="header"><h2>${this.t("Biorhythm")}</h2><div class="head-meta">${e.overallPhase?ee.html`<span class="roxy-chip">${D(e.overallPhase)}</span>`:ee.nothing} ${typeof e.energyRating=="number"?ee.html`<span class="energy">${this.t("Energy {{value}}/10",{value:e.energyRating})}</span>`:ee.nothing}</div></header>${n?ee.html`<div class="spotlight" part="details spotlight" style="${`border-inline-start-color: ${In[n.cycle]??"var(--roxy-accent)"}`}"><p class="roxy-label">${this.t("Spotlight cycle")}</p><div class="lead"><strong>${yr(n.cycle,i=>this.t(i))}</strong> ${typeof n.value=="number"?ee.html`<span class="energy">${Ne(this.effectiveLang(),n.value,0)}</span>`:ee.nothing} ${n.phase?ee.html`<span class="roxy-chip">${D(n.phase)}</span>`:ee.nothing}</div>${n.message&&!this.hideReadings?ee.html`<p>${n.message}</p>`:ee.nothing}</div>`:ee.nothing}<div class="bars" part="chart bars" role="list">${r.map(([i,o])=>{let l=Math.abs(o)*50,c=In[i]??"var(--roxy-accent)";return ee.html`<div class="bar" role="listitem"><span>${yr(i,d=>this.t(d))}</span> <span class="track"><span class="fill ${o<0?"low":"high"}" style="width:${l}%;background:${c}"></span> </span><span class="value">${Ne(this.effectiveLang(),o*100,0)}</span></div>`})}</div>${this.hideReadings?ee.nothing:ee.html`${e.dailyMessage?ee.html`<p>${e.dailyMessage}</p>`:ee.nothing} ${e.advice?ee.html`<p>${e.advice}</p>`:ee.nothing}`}</section>`}renderForecast(e){let t=e.days??[];if(t.length===0)return ee.html`<div class="roxy-empty" role="status">${this.t("No forecast")}</div>`;let r=600,n=160,i=r/Math.max(t.length-1,1),o=e.summary;return ee.html`<section class="wrap" part="card" aria-label="${this.t("Biorhythm forecast")}"><header class="head" part="header"><h2>${this.t("Forecast")}</h2><span class="energy">${Et(this.effectiveLang(),e.startDate,e.endDate)}</span></header><svg viewBox="0 0 ${r} ${n}" part="chart" role="img" aria-label="${this.t("Biorhythm cycle lines across the forecast window")}"><title>${this.t("Biorhythm forecast")}</title><line x1="0" y1="${n/2}" x2="${r}" y2="${n/2}" stroke="var(--roxy-border)" stroke-width="1"/>${Zs.map(l=>{let c=t.map((h,p)=>{let f=h[l]??0,L=p*i,$=n/2-f/100*(n/2-8);return`${L.toFixed(2)},${$.toFixed(2)}`}).join(" "),d=In[l]??"var(--roxy-secondary)";return ee.svg`<polyline points=${c} fill="none" stroke=${d} stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />`})} ${t.map((l,c)=>l.isCritical?ee.svg`<circle cx=${(c*i).toFixed(2)} cy=${n/2} r="3" fill="var(--roxy-danger)"><title>${[M(this.effectiveLang(),l.date),ot(this.effectiveLang(),(l.criticalCycles??[]).map(d=>yr(d,h=>this.t(h)))),this.t("critical day"),typeof l.energyRating=="number"?this.t("Energy {{value}}/10",{value:l.energyRating}):""].filter(Boolean).join(" \xB7 ")}</title></circle>`:ee.nothing)}</svg><div class="forecast-axis" part="legend"><span>${M(this.effectiveLang(),t[0]?.date)}</span><span>${M(this.effectiveLang(),t.at(-1)?.date)}</span></div><div class="legend" part="legend">${Zs.map(l=>ee.html`<span class="key"><span class="dot" style="${`background: ${In[l]}`}"></span>${this.t(Gn[l])}</span>`)} <span class="key"><span class="dot critical"></span>${this.t("critical day")}</span></div>${o?ee.html`<dl class="roxy-facts" part="details">${this.stat(this.t("Best day"),M(this.effectiveLang(),o.bestDay))} ${this.stat(this.t("Worst day"),M(this.effectiveLang(),o.worstDay))} ${this.stat(this.t("Average energy"),typeof o.averageEnergy=="number"?`${o.averageEnergy}/10`:"")} ${this.stat(this.t("Critical days"),typeof o.criticalDayCount=="number"?`${o.criticalDayCount}`:"")}</dl>`:ee.nothing} ${this.renderForecastData(e)} ${o?.periodAdvice&&!this.hideReadings?ee.html`<p>${o.periodAdvice}</p>`:ee.nothing}</section>`}renderForecastData(e){let t=this.effectiveLang();return ee.html`<details class="forecast-data" part="section days"><summary>${this.t("Daily values")}${he()}</summary><div class="forecast-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Biorhythm forecast")}"><table class="forecast-table"><caption class="roxy-sr-only">${this.t("Biorhythm forecast")}</caption><thead><tr><th scope="col">${this.t("Date")}</th>${Zs.map(r=>ee.html`<th scope="col">${this.t(Gn[r])}</th>`)}<th scope="col">${this.t("Energy rating")}</th><th scope="col">${this.t("Days since birth")}</th><th scope="col">${this.t("Critical days")}</th></tr></thead><tbody>${e.days.map(r=>ee.html`<tr><th scope="row"><time datetime="${r.date}">${M(t,r.date)}</time></th>${Zs.map(n=>ee.html`<td>${Ne(t,r[n],2)}</td>`)}<td>${this.t("Energy {{value}}/10",{value:r.energyRating})}</td><td>${b(t,r.daysSinceBirth,0)}</td><td>${r.isCritical?ot(t,r.criticalCycles.map(n=>yr(n,i=>this.t(i))))||this.t("critical day"):this.t("None")}</td></tr>`)}</tbody></table></div></details>`}renderCritical(e){let t=e.criticalDays??[],r=e.doubleCriticalDays??[],n=t.map(i=>({label:M(this.effectiveLang(),i.date)||i.date,aside:[i.cycle?yr(i.cycle,o=>this.t(o)):"",this.severityName(i.severity)].filter(Boolean).join(" \xB7 "),body:i.advisory??"",extra:ee.html`<p class="crit-meta">${[i.direction?this.t(Tg[i.direction]):"",typeof i.period=="number"?this.t("{{period}}-day cycle",{period:i.period}):""].filter(Boolean).join(" \xB7 ")}</p>`}));return ee.html`<section class="wrap" part="card" aria-label="${this.t("Critical days")}"><header class="head" part="header"><h2>${this.t("Critical days")}</h2><span class="energy">${Et(this.effectiveLang(),e.startDate,e.endDate)}</span></header><dl class="roxy-facts" part="details">${this.stat(this.t("Events"),typeof e.totalCriticalDays=="number"?`${e.totalCriticalDays}`:"")} ${this.stat(this.t("Double days"),r.length?`${r.length}`:"0")} ${this.stat(this.t("Triple day"),e.tripleCriticalDay?M(this.effectiveLang(),e.tripleCriticalDay):this.t("None"))}</dl>${r.length>0?ee.html`<p class="crit-note">${this.t("Two or more cycles cross zero on {{dates}}. Take extra care on these dates.",{dates:ot(this.effectiveLang(),r.map(i=>M(this.effectiveLang(),i)||i))})}</p>`:ee.nothing} ${this.renderInterpretation(n,"biorhythm-critical","Advisories")}</section>`}severityName(e){let t=Eg[e];return t?this.t(t):""}stat(e,t){return t?ee.html`<div><dt>${e}</dt><dd>${t}</dd></div>`:ee.nothing}};Ea.endpoints=gl,Ea.styles=[u,X,Re,me,ee.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.head-meta{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.energy{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.spotlight{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-md);display:grid}.spotlight .lead{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.spotlight strong{text-transform:capitalize}.spotlight p{font-size:var(--roxy-text-sm)}.bars{gap:var(--roxy-space-xs);display:grid}.bar{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:minmax(0,16ch) minmax(0,1fr) 7ch;display:grid}.track{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.7lh;position:relative;overflow:hidden}.track:after{content:"";background:var(--roxy-surface);width:1px;position:absolute;top:0;bottom:0;left:50%}.fill{height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);position:absolute;top:0}.fill.high{left:50%}.fill.low{right:50%}.value{color:var(--roxy-muted);text-align:end;font-variant-numeric:tabular-nums}svg{width:100%;max-width:var(--roxy-chart-max-width,37.5rem);height:auto;display:block}.legend{gap:var(--roxy-space-md);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.key{align-items:center;gap:var(--roxy-space-xs);text-transform:capitalize;display:inline-flex}.dot{border-radius:var(--roxy-radius-full);block-size:.6lh;inline-size:.6lh}.dot.critical{background:var(--roxy-danger)}.roxy-facts{margin:0}.roxy-facts dd{font-weight:var(--roxy-weight-bold)}.forecast-data>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}.forecast-scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}.forecast-table{width:100%}.forecast-table th,.forecast-table td{text-align:end;white-space:nowrap}.forecast-table th:first-child,.forecast-table td:first-child{text-align:start}.forecast-axis{justify-content:space-between;gap:var(--roxy-space-sm);width:100%;max-width:var(--roxy-chart-max-width,37.5rem);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);display:flex}.crit-note{border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md)}.crit-meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],m([(0,Jd.property)({type:String,reflect:true})],Ea.prototype,"mode",2),Ea=m([x("roxy-biorhythm-chart")],Ea);var E=require("lit"),pp=require("lit/decorators.js"),hp=require("lit/directives/unsafe-html.js");var np=14,Dg=86,ip=0,Ag=102,ur=6,op=(Dg-np)*ur,Pg=(Ag-ip)*ur;function ys(s,a){return{x:(s-np)*ur,y:(a-ip)*ur}}var V=50,Hn=s=>2*V-s,Xs=1.02*ur,Mg=1.15*ur,tt=2.87,Pt=4.4,Qd=5.65,Qi={head:{64:[V-tt,11.2],61:[V,11.2],63:[V+tt,11.2]},ajna:{47:[V-tt,18],24:[V,18],4:[V+tt,18],17:[V-tt,20.6],11:[V+tt,20.6],43:[V,25.3]},throat:{62:[V-tt,32.4],23:[V,32.4],56:[V+tt,32.4],16:[V-Pt,34.7],35:[V+Pt,34.7],20:[V-Pt,37.3],12:[V+Pt,37.3],45:[V+Pt,39.6],31:[V-tt,41.9],8:[V,41.9],33:[V+tt,41.9]},g:{1:[V,47.7],7:[V-tt,50.3],13:[V+tt,50.3],10:[V-Qd,53.4],25:[V+Qd,53.4],15:[V-tt,56.8],46:[V+tt,56.8],2:[V,59.2]},heart:{21:[63.9,59.5],51:[62.1,61.3],26:[60.1,63.3],40:[66.6,63.3]},spleen:{48:[20,70.8],57:[22.5,72.4],44:[25,73.8],50:[27.7,75.3],32:[25,76.6],28:[22.5,78],18:[20,79.5]},sacral:{5:[V-tt,72.7],14:[V,72.7],29:[V+tt,72.7],34:[V-Pt,75.4],27:[V-Pt,79],59:[V+Pt,79],42:[V-tt,81.7],3:[V,81.7],9:[V+tt,81.7]},"solar-plexus":{},root:{53:[V-tt,90.2],60:[V,90.2],52:[V+tt,90.2],54:[V-Pt,92.6],19:[V+Pt,92.6],38:[V-Pt,95.3],39:[V+Pt,95.3],58:[V-Pt,98.1],41:[V+Pt,98.1]}},_g={48:36,57:22,44:37,50:6,32:49,28:55,18:30};function Ng(){let s={},a={};for(let[e,[t,r]]of Object.entries(Qi.spleen))Qi["solar-plexus"][_g[Number(e)]]=[Hn(t),r];for(let[e,t]of Object.entries(Qi))for(let[r,[n,i]]of Object.entries(t))s[Number(r)]=ys(n,i),a[Number(r)]=e;return{points:s,centerOf:a}}var{points:ro,centerOf:Js}=Ng(),oL=op/2;function gs(s){return s.map(([a,e])=>ys(a,e))}function eo(s,a,e){return gs([[V-s,a],[V+s,a],[V+s,e],[V-s,e]])}var to=5.9,ep=[[18.3,68.3],[18.3,82],[30.3,75.15]],ao=[20,84.4],tp=12*ur,zg=[63.2,67.9],Og=13.1*ur,so=[{id:"head",label:"Head",color:"gold",points:gs([[43.55,12.5],[56.45,12.5],[50,1.7]])},{id:"ajna",label:"Ajna",color:"green",points:gs([[43.55,16.5],[56.45,16.5],[50,27.7]])},{id:"throat",label:"Throat",color:"brown",points:eo(to,31,43.3)},{id:"g",label:"G",color:"gold",points:gs([[50,45.8],[57.7,53.6],[50,61.4],[42.3,53.6]])},{id:"heart",label:"Heart",color:"red",points:gs([[56.65,65.23],[64.2,56.74],[69.75,65.23]]),caption:{at:ys(...zg),room:Og}},{id:"spleen",label:"Spleen",color:"brown",points:gs(ep),caption:{at:ys(...ao),room:tp}},{id:"sacral",label:"Sacral",color:"red",points:eo(to,71.3,83.1)},{id:"solar-plexus",label:"Solar Plexus",color:"brown",points:gs(ep.map(([s,a])=>[Hn(s),a])),caption:{at:ys(Hn(ao[0]),ao[1]),room:tp}},{id:"root",label:"Root",color:"brown",points:eo(to,88.5,99.8)}],Gg=[[64,47],[61,24],[63,4],[17,62],[11,56],[43,23],[16,48],[20,34],[20,10],[7,31],[1,8],[13,33],[21,45],[12,22],[35,36],[57,20],[15,5],[2,14],[46,29],[34,10],[10,57],[25,51],[27,50],[57,34],[26,44],[18,58],[28,38],[32,54],[3,60],[9,52],[42,53],[59,6],[19,49],[39,55],[41,30],[37,40]],Ig=Fg();function Fg(){let s=Hn,a=[[50,3],[58,3],[60,10],[57,17.5],[56.5,20.5],[53.5,23.5],[51.5,27],[54,28],[64,30],[79,35],[83,42],[84,58],[83,74],[83,86],[76,93],[68,97],[64,99],[62,100.5],[60,100.5]],e=[`M ${Fn(a[0])}`];for(let t=1;t+2<a.length;t+=3)e.push(`C ${Fn(a[t])} ${Fn(a[t+1])} ${Fn(a[t+2])}`);e.push(`L ${Bn(a[a.length-1],s)}`);for(let t=a.length-3;t>=1;t-=3)e.push(`C ${Bn(a[t+1],s)} ${Bn(a[t],s)} ${Bn(a[t-1],s)}`);return e.push("Z"),e.join(" ")}function Fn([s,a]){let e=ys(s,a);return`${e.x} ${e.y}`}function Bn([s,a],e){let t=ys(e(s),a);return`${t.x} ${t.y}`}function Bg(s){return s.map(a=>`${a.x},${a.y}`).join(" ")}function lp(s){return s.left&&s.right?"both":s.left?"src-left":"src-right"}function Hg(){return R`<path class="bg-body" d=${Ig} />`}function jg(s){let a=[];for(let[e,t]of Gg){let r=ro[e],n=ro[t];if(!r||!n)continue;a.push(R`<line class="bg-channel" x1=${r.x} y1=${r.y} x2=${n.x} y2=${n.y} />`);let i={x:(r.x+n.x)/2,y:(r.y+n.y)/2};for(let[o,l]of[[e,r],[t,n]]){let c=s.get(o);if(!c)continue;let d=lp(c);a.push(R`<line class="bg-half ${d==="both"?"src-left":d}" x1=${l.x} y1=${l.y} x2=${i.x} y2=${i.y} />`),d==="both"&&a.push(R`<line class="bg-half src-right stripe" x1=${l.x} y1=${l.y} x2=${i.x} y2=${i.y} />`)}}return a}function Kg(s,a,e){return so.flatMap(t=>{let r=s.has(t.id),n=`bg-center bg-${t.color}${r?" defined":""}`,i=a?.get(t.id)||t.label;return[R`<polygon class=${n} points=${Bg(t.points)}><title>${i}: ${r?e.defined:e.open}</title></polygon>`,t.caption?ap(i,t.caption.at,"bg-caption",t.caption.room):ap(i,rp(t.points),r?`defined bg-${t.color}`:"",Ug(t.points,rp(t.points).y)*.86)]})}function ap(s,a,e,t){let r=s.split(/\s+/).filter(Boolean),n=r.reduce((c,d)=>Math.max(c,d.length),0),i=Math.min(Mg,t/Math.max(1,n*Vg)),o=i*1.05,l=a.y-o*(r.length-1)/2;return R`<text class="bg-center-name ${e}" style=${`font-size:${i}px`} x=${a.x} y=${a.y} text-anchor="middle" dominant-baseline="central" aria-hidden="true">${r.map((c,d)=>R`<tspan x=${a.x} y=${l+d*o}>${c}</tspan>`)}</text>`}var Vg=.66;function Ug(s,a){let e=[];for(let t=0;t<s.length;t++){let r=s[t],n=s[(t+1)%s.length];if(r.y===n.y)continue;let i=Math.min(r.y,n.y),o=Math.max(r.y,n.y);a<i||a>o||e.push(r.x+(a-r.y)/(n.y-r.y)*(n.x-r.x))}return e.length<2?0:Math.max(...e)-Math.min(...e)}function rp(s){let a=s.length||1;return{x:s.reduce((e,t)=>e+t.x,0)/a,y:s.reduce((e,t)=>e+t.y,0)/a}}function sp(s,a){return`M ${s.x} ${s.y-Xs} A ${Xs} ${Xs} 0 0 ${a} ${s.x} ${s.y+Xs} Z`}function qg(s,a){let e=[];for(let[t,r]of Object.entries(ro)){let n=Number(t),i=s.get(n),o=i?lp(i):"",l=a.get(n);e.push(R`<g class="bg-gate-node">
|
|
8
|
+
${o==="both"?[R`<path class="bg-gate-dot on src-left" d=${sp(r,0)} />`,R`<path class="bg-gate-dot on src-right" d=${sp(r,1)} />`]:R`<circle class="bg-gate-dot ${o&&`on ${o}`}" cx=${r.x} cy=${r.y} r=${Xs} />`}
|
|
9
|
+
<text class="bg-gate ${i?"on":""}" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${n}</text>
|
|
10
|
+
${l?R`<title>${l}</title>`:""}
|
|
11
|
+
</g>`)}return e}var no=`0 0 ${op} ${Pg}`;function io(s){return R`
|
|
12
|
+
${Hg()}
|
|
13
|
+
${jg(s.gateSources)}
|
|
14
|
+
${Kg(s.definedCenters,s.centerNames,s.stateWords??{defined:"defined",open:"open"})}
|
|
15
|
+
${qg(s.gateSources,s.gateTitles)}
|
|
16
|
+
`}function oo(s,a){return s==="design"?a("Design"):s==="personality"?a("Personality"):s??""}function Yg(s){let a=new Map;for(let e of s){if(e.gate==null)continue;let t=a.get(e.gate);t?t.push(e):a.set(e.gate,[e])}return a}function lo(s){return s.planet?S(s.planet)??y(s,"planet"):""}function Wg(s,a){let e=new Map;for(let[t,r]of s){let n=r.map(i=>[lo(i),`${t}${i.line!=null?`.${i.line}`:""}`,oo(i.side,a)].filter(Boolean).join(" "));e.set(t,[a("Gate {{gate}}",{gate:t}),y(r[0],"gateName"),...n].filter(Boolean).join(" \xB7 "))}return e}function co(s){return new Map(s.map(a=>[a.id,y(a,"name")]))}function cp(s,a={}){let e=da(a.lang),t=s.centers??[],r=Yg(s.gates??[]);return R`<svg class="chart bodygraph" xmlns=${ca} part="chart" viewBox=${no} preserveAspectRatio="xMidYMid meet" role="img" aria-label=${e("Human Design bodygraph with nine centers, channels, and activated gates overlaid on a human silhouette")}><title>${e("Human Design bodygraph")}</title><desc>${e("Nine energy centers in their canonical positions over a human silhouette, each filled with its traditional color when defined and outlined when open, wired by channels between activated gates.")}</desc>${io({definedCenters:new Set(t.filter(n=>n.defined).map(n=>n.id)),gateSources:new Map([...r].map(([n,i])=>[n,{left:i.some(o=>o.side==="design"),right:i.some(o=>o.side==="personality")}])),gateTitles:Wg(r,e),centerNames:co(t),stateWords:{defined:e("Defined"),open:e("Open")}})}</svg>`.markup}var dp=require("lit"),jn=dp.css`.chart{width:100%;max-width:var(--roxy-chart-max-width,30rem);height:auto;margin:0 auto;display:block}@container (width<=26rem){.chart{width:calc(100% + 2 * var(--roxy-space-lg));margin-inline:calc(-1 * var(--roxy-space-lg))}}.legend{gap:var(--roxy-space-sm) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.legend .swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border:1px solid var(--roxy-secondary);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.legend .swatch.source{border-radius:var(--roxy-radius-full);border-color:#0000}`;var lt=require("lit");var fr=[Re,lt.css`.roxy-facts{margin:0}.lead{font-size:var(--roxy-text-sm);margin:0}.keynotes{gap:var(--roxy-space-xs);margin:0;display:grid}.keynotes dd{margin:0}`];function Da(s){let a=s.filter(e=>!!e.value);return a.length===0?lt.nothing:lt.html`<dl class="roxy-facts" part="facts">${a.map(e=>lt.html`<div part="fact"><dt>${e.label}</dt><dd>${e.value}</dd></div>`)}</dl>`}function Kn(s,a,e){return!s&&!a?lt.nothing:lt.html`<div class="themes roxy-chips" part="themes">${s?lt.html`<span class="roxy-chip" data-tone="success">${e("Signature: {{value}}",{value:s})}</span>`:lt.nothing} ${a?lt.html`<span class="roxy-chip" data-tone="danger">${e("Not-self: {{value}}",{value:a})}</span>`:lt.nothing}</div>`}function Vn(s,a){return!s?.personality&&!s?.design?lt.nothing:lt.html`<dl class="keynotes" part="keynotes">${s.personality?lt.html`<dt>${a("Line {{line}} \xB7 Personality",{line:s.personalityLine??""})}</dt><dd>${s.personality}</dd>`:lt.nothing} ${s.design?lt.html`<dt>${a("Line {{line}} \xB7 Design",{line:s.designLine??""})}</dt><dd>${s.design}</dd>`:lt.nothing}</dl>`}var Zg=["gold","green","brown","red"],Aa=class extends g{constructor(){super(...arguments);this.viewport=new Ve(this);this.side="personality"}renderData(e){let t=e.centers??[],r=co(t);return E.html`<div class="wrap bodygraph" part="card"><header class="head" part="header"><div><h2>${this.t("Bodygraph")}</h2>${e.designInstantUtc?E.html`<div class="meta">${this.t("Design")} <time datetime="${e.designInstantUtc}">${dd(this.effectiveLang(),e.designInstantUtc)}</time></div>`:E.nothing}</div>${e.type||e.profile?E.html`<div class="type-line">${[y(e,"type"),e.profile?this.t("Profile {{profile}}",{profile:e.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:E.nothing}</header><div class="layout" part="layout">${this.viewport.renderChartViewport((0,hp.unsafeHTML)(cp(e,{lang:this.effectiveLang()})),this.t("Human Design bodygraph"),this.translator)} ${this.renderSummary(e,r)}</div>${this.renderReading(e)} ${this.renderChannels(e.channels??[],r)} ${this.renderCenters(t)} ${this.renderActivations(e)}</div>`}renderSummary(e,t){let r=e.incarnationCross;return E.html`<div class="summary" part="details">${Da([{label:this.t("Type"),value:y(e,"type")},{label:this.t("Strategy"),value:y(e,"strategy")},{label:this.t("Authority"),value:y(e,"authority")},{label:this.t("Profile"),value:e.profile},{label:this.t("Definition"),value:y(e,"definition")}])} ${e.typeDescription&&!this.hideReadings?E.html`<p class="lead">${e.typeDescription}</p>`:E.nothing} ${r?.name?E.html`<p class="cross">${r.name} ${r.gates?.length?E.html`<span class="gates">(${r.gates.join(", ")})</span>`:E.nothing}</p>`:E.nothing} ${Kn(e.signature?y(e,"signature"):void 0,e.notSelf?y(e,"notSelf"):void 0,this.translator)} ${this.renderLegend(t)}</div>`}renderLegend(e){let t=Zg.map(r=>[r,so.filter(n=>n.color===r).map(n=>e.get(n.id)||n.label).join(", ")]);return E.html`<div class="legend" part="legend"><span class="legend-row"><span class="swatch source src-left"></span>${this.t("Design")} <span class="swatch source src-right"></span>${this.t("Personality")} </span><span class="legend-row">${this.t("Center colors when defined. Open centers are outlined.")}</span> ${t.map(([r,n])=>E.html`<span><span class="swatch bg-${r} defined"></span>${n}</span>`)} <span><span class="swatch"></span>${this.t("Open center")}</span></div>`}renderReading(e){let t=e.incarnationCross,r=[{label:this.t("Strategy"),aside:y(e,"strategy"),body:e.strategyDescription},{label:this.t("Authority"),aside:y(e,"authority"),body:e.authorityDescription},{label:this.t("Profile"),aside:e.profile,body:e.profileDescription,extra:Vn(e.profileKeynotes,this.translator)},{label:this.t("Definition"),aside:y(e,"definition"),body:e.definitionDescription},{label:this.t("Aura"),body:e.aura},{label:this.t("Incarnation cross"),aside:t?y(t,"angle"):void 0,body:t?.description??""}];return this.renderInterpretation(r,"hd-reading")}renderChannels(e,t){if(e.length===0||this.hideReadings)return E.nothing;let r=new Map;for(let i of e){let o=i.circuit??"",l=r.get(o);l?l.push(i):r.set(o,[i])}let n=0;return E.html`<section class="block" part="section channels"><h3>${this.t("Defined channels ({{count}})",{count:e.length})}</h3>${[...r].map(([i,o])=>E.html`<div class="group">${i?E.html`<p class="group-head">${this.t("{{circuit}} circuit",{circuit:y(o[0],"circuit")})}</p>`:E.nothing} ${o[0]?.circuitDescription?E.html`<p class="group-note">${o[0].circuitDescription}</p>`:E.nothing} ${o.map(l=>E.html`<details class="interp-card" part="reading" name="hd-channel" ?open="${n++===0}"><summary><span class="interp-lead"><span class="chan-gates">${l.gateA}-${l.gateB}</span> <span>${y(l,"name")}</span> </span>${he()} <span class="interp-aside"><span class="roxy-chips">${(l.centers??[]).map(c=>E.html`<span class="roxy-chip">${t.get(c)||c}</span>`)}</span></span></summary><div class="interp-body">${l.description?E.html`<p>${l.description}</p>`:E.nothing}</div></details>`)}</div>`)}</section>`}renderCenters(e){if(e.length===0||this.hideReadings)return E.nothing;let t=e.filter(r=>r.defined).length;return E.html`<section class="block" part="section centers"><h3>${this.t("Centers ({{defined}} defined, {{open}} open)",{defined:t,open:e.length-t})}</h3>${e.map((r,n)=>E.html`<details class="interp-card" part="reading" name="hd-center" ?open="${n===0}"><summary><span class="interp-lead">${y(r,"name")}</span> ${he()} <span class="interp-aside"><span class="roxy-chips"><span class="roxy-chip ${r.defined?"on":""}">${r.defined?this.t("Defined"):this.t("Open")}</span> ${r.motor?E.html`<span class="roxy-chip">${this.t("Motor")}</span>`:E.nothing} ${r.awareness?E.html`<span class="roxy-chip">${this.t("Awareness")}</span>`:E.nothing}</span></span></summary><div class="interp-body">${r.theme?E.html`<p>${r.theme}</p>`:E.nothing} ${!r.defined&&r.notSelfQuestion?E.html`<dl class="keynotes"><dt>${this.t("Not-self question")}</dt><dd>${r.notSelfQuestion}</dd></dl>`:E.nothing} ${r.biology?E.html`<p class="footnote">${this.t("Biology")}. ${r.biology}</p>`:E.nothing} ${r.gates?.length?E.html`<p class="footnote">${this.t("Gates {{gates}}",{gates:r.gates.join(", ")})}</p>`:E.nothing}</div></details>`)}</section>`}renderActivations(e){let t=e.gates??[];if(t.length===0||this.hideReadings)return E.nothing;let r=t.filter(d=>d.side==="personality"),n=t.filter(d=>d.side==="design"),i=r.length>0&&n.length>0,o=this.side,l=i?o==="design"?n:r:t,c=i?e.sides?.[o]:void 0;return E.html`<section class="block" part="section activations"><h3>${this.t("Activations ({{count}})",{count:t.length})}</h3>${i?ut({items:[{id:"personality",label:`${this.t("Personality")} (${r.length})`},{id:"design",label:`${this.t("Design")} (${n.length})`}],active:o,onSelect:d=>{this.side=d},label:this.t("Chart sides"),idPrefix:"hd",controls:true}):E.nothing}<div id="${i?`hd-panel-${o}`:E.nothing}" part="panel" role="${i?"tabpanel":E.nothing}" aria-labelledby="${i?`hd-tab-${o}`:E.nothing}">${c?E.html`<p class="side-note">${c}</p>`:E.nothing} ${l.map((d,h)=>this.renderGate(d,h===0))}</div></section>`}renderGate(e,t){let r=lo(e),n=y(e,"planet"),i=e.ichingHexagram;return E.html`<details class="interp-card" part="reading" name="hd-gate" ?open="${t}"><summary><span class="interp-lead">${r?E.html`<span class="glyph roxy-glyph" aria-hidden="true">${r}</span>`:E.nothing} <span class="gate-id">${e.gate}${e.line!=null?`.${e.line}`:""}</span> <span>${y(e,"gateName")}</span> </span>${he()} ${n?E.html`<span class="interp-aside"><small>${n}</small></span>`:E.nothing}</summary><div class="interp-body">${e.gateDescription?E.html`<p>${e.gateDescription}</p>`:E.nothing} ${e.lineMeaning?E.html`<dl class="keynotes"><dt>${this.t("Line {{line}}",{line:e.line??""})}</dt><dd>${e.lineMeaning}</dd></dl>`:E.nothing} ${e.planetDescription?E.html`<p class="footnote">${n}. ${e.planetDescription}</p>`:E.nothing} ${i?.number?E.html`<p class="footnote">${this.t("I Ching hexagram {{number}}",{number:i.number})}${i.english?`, ${i.english}`:""}</p>`:E.nothing}</div></details>`}};Aa.endpoints=yl,Aa.styles=[u,et,dt,X,me,fr,Dn,jn,E.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.type-line,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.layout{align-items:start;gap:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.summary{gap:var(--roxy-space-md);display:grid}.cross{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm)}.cross .gates{color:var(--roxy-muted);font-variant-numeric:tabular-nums}.legend-row{flex-basis:100%}.legend-row .swatch:not(:first-child){margin-inline-start:var(--roxy-space-md)}.legend .swatch.defined{border-color:color-mix(in srgb, var(--roxy-fg) 45%, transparent)}.group+.group{margin-block-start:var(--roxy-space-md)}.group-head{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-note,.side-note,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.group-note,.side-note{margin-block-end:var(--roxy-space-sm)}.side-note{padding-block-start:var(--roxy-space-sm)}.roxy-chip.on{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.gate-id,.chan-gates{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.glyph{color:var(--roxy-accent-ink)}`],m([(0,pp.state)()],Aa.prototype,"side",2),Aa=m([x("roxy-bodygraph")],Aa);var ft=require("lit");var Xg={eight:"Eight karaka scheme, Rahu included and ranked from the end of its sign.",seven:"Seven karaka scheme, Rahu excluded and the Pitrikaraka office not assigned."},xr=class extends g{renderData(a){let e=a.karakas??[];return e.length?ft.html`<div class="wrap" part="card" aria-label="${this.t("Chara karakas")}"><header class="head" part="header"><h2>${this.t("Chara karakas")}</h2><p class="scheme"><span class="scheme-chip roxy-chip">${a.scheme??""}</span> ${a.scheme?Xg[a.scheme]??"":""}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</header><dl class="roxy-facts" part="details"><div><dt>${this.t("Atmakaraka")}</dt><dd>${a.atmakaraka??""}</dd></div><div><dt>${this.t("Darakaraka")}</dt><dd>${a.darakaraka??""}</dd></div></dl><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Chara karakas")}"><table class="stacked" role="table"><caption class="roxy-sr-only">${this.t("Chara karakas in descending rank: each office, the graha holding it, its rashi, the degree it holds, the degree that earned the office, and what the office is read for.")}</caption><thead><tr><th scope="col">${this.t("Office")}</th><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Ranked on")}</th><th scope="col">${this.t("Read for")}</th></tr></thead><tbody>${e.map((t,r)=>this.renderRow(t,r===0))}</tbody></table></div></div>`:this.renderEmpty()}renderRow(a,e){let t=S(a.graha)??"",r=J(a.rashi)??"";return ft.html`<tr class="${e?"lead-row":""}"><td class="name">${a.name??""}${a.abbreviation?ft.html`<span class="abbr">${a.abbreviation}</span>`:ft.nothing}</td><td data-inline data-label="${this.t("Graha")}">${t?ft.html`<span class="glyph roxy-glyph">${t}</span>`:ft.nothing}${a.graha??""}</td><td data-inline data-label="${this.t("Rashi")}">${r?ft.html`<span class="glyph roxy-glyph">${r}</span>`:ft.nothing}${a.rashi??""}</td><td data-inline data-label="${this.t("Degree")}">${b(this.effectiveLang(),a.degreeInRashi,2)}</td><td data-inline data-label="${this.t("Ranked on")}">${b(this.effectiveLang(),a.rankingDegree,2)} ${a.isReversed?ft.html`<span class="reversed">${this.t("measured from the end of the sign")}</span>`:ft.nothing}</td><td class="meaning"><strong>${a.meaning??""}</strong> ${a.significations?ft.html`<p>${a.significations}</p>`:ft.nothing}</td></tr>`}};xr.endpoints=ul,xr.styles=[u,re,Re,...Nn,ft.css`.wrap{overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);display:grid}h2,p{margin:0}.scheme{align-items:baseline;gap:var(--roxy-space-sm);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.scheme-chip{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.roxy-facts{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);margin:0}.roxy-facts dd{font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold)}.reversed{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}`],xr=m([x("roxy-chara-karakas")],xr);var xt=require("lit");var br=class extends g{isCurrent(a){let e=Date.now(),t=Date.parse(a.start),r=Date.parse(a.end);return Number.isNaN(t)||Number.isNaN(r)?false:e>=t&&e<r}renderTile(a){let e=a.effect==="Good"?"good":a.effect==="Bad"?"bad":"neutral",t=this.isCurrent(a),r=S(a.lord)??"",n=la(this.effectiveLang(),a),i=e==="good"?this.t("Favourable"):e==="bad"?this.t("Unfavourable"):"";return xt.html`<div class="cho-tile ${e}${t?" now":""}" role="listitem" aria-current="${t?"time":"false"}"><span class="tile-name">${a.name}${t?xt.html`<span class="now-badge">${this.t("Now")}</span>`:xt.nothing} </span><span class="tile-time" aria-label="${this.t("Time range")}">${n}</span> <span class="tile-lord">${r?xt.html`<span class="roxy-glyph" aria-hidden="true">${r}</span>`:xt.nothing} ${a.lord} ${i?xt.html`<span aria-hidden="true">·</span><span class="tile-effect">${i}</span>`:xt.nothing}</span></div>`}renderData(a){let{date:e,dayChoghadiya:t,nightChoghadiya:r}=a;return xt.html`<div class="wrap" part="card"><div class="header" part="header"><h2>${this.t("Choghadiya")}</h2>${e?xt.html`<p class="roxy-label">${M(this.effectiveLang(),e)}</p>`:xt.nothing}</div><div class="cho-grid" part="table"><section class="period-col" aria-label="${this.t("Day muhurta periods")}"><h3 class="period-heading">${this.t("Daytime")}</h3><div role="list" aria-label="${this.t("Daytime choghadiya")}">${t&&t.length>0?t.map(n=>this.renderTile(n)):xt.html`<p class="roxy-empty" role="status">${this.t("No daytime periods")}</p>`}</div></section><section class="period-col" aria-label="${this.t("Night muhurta periods")}"><h3 class="period-heading">${this.t("Night")}</h3><div role="list" aria-label="${this.t("Nighttime choghadiya")}">${r&&r.length>0?r.map(n=>this.renderTile(n)):xt.html`<p class="roxy-empty" role="status">${this.t("No nighttime periods")}</p>`}</div></section></div></div>`}};br.endpoints=fl,br.styles=[u,xt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.header{gap:var(--roxy-space-xs);display:grid}h2,h3,p{margin:0}.cho-grid{gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}@container (width>=40rem){.cho-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}.period-heading{margin-block-end:var(--roxy-space-xs)}.cho-tile{align-items:center;gap:0 var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr) auto;display:grid}.cho-tile:last-child{border-block-end:0}.cho-tile.now{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);padding-inline-start:var(--roxy-space-sm)}.now-badge{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-sm)}.tile-name{min-width:0;font-weight:var(--roxy-weight-bold);overflow-wrap:anywhere;grid-column:1}.good :is(.tile-name,.tile-effect){color:var(--roxy-success-fg)}.bad :is(.tile-name,.tile-effect){color:var(--roxy-danger-fg)}.tile-time{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;text-align:end;white-space:nowrap;grid-area:1/2/3;align-self:center}.tile-lord{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;grid-column:1;display:flex}`],br=m([x("roxy-choghadiya-grid")],br);var ae=require("lit"),yp=require("lit/decorators.js");var Jg=["sun","moon","venus","mars"],mp=["fire","earth","air","water"],gp={astrology:"Astrology compatibility",numerology:"Numerology compatibility",biorhythm:"Biorhythm compatibility"},Qg={in_sync:"In sync",complementary:"Complementary",neutral:"Neutral",opposing:"Opposing"},Pa=class extends g{constructor(){super(...arguments);this.mode="astrology"}getBreakdown(){let e=this.data;if(!e)return{};if("categories"in e&&e.categories){let t={};for(let[r,n]of Object.entries(e.categories))typeof n=="number"&&Number.isFinite(n)&&(t[r]=n);return t}return{}}renderData(e){let t=e.overallScore,r=this.getBreakdown(),n="rating"in e?e.rating:void 0,i="archetype"in e?e.archetype:void 0,o="advice"in e?e.advice:void 0,l="summary"in e?e.summary:void 0,c="interpretation"in e?e.interpretation:void 0,d="strengths"in e?e.strengths:void 0,h="challenges"in e?e.challenges:void 0,p="keyAspects"in e?e.keyAspects:void 0,f=!this.hideReadings,L=this.t(gp[this.mode]??gp.astrology);return ae.html`<article class="card" part="card" aria-label="${L}"><div class="head" part="header"><h2>${L}</h2><div>${typeof t=="number"?ae.html`<div class="score">${Math.round(t)}</div>`:ae.nothing} ${n?ae.html`<div class="rating">${n}</div>`:ae.nothing}</div></div>${Object.keys(r).length>0?ae.html`<div role="list" part="details breakdown">${Object.entries(r).map(([$,k])=>ae.html`<div class="bar-row" role="listitem"><span style="text-transform:capitalize">${$}</span> <span class="bar"><span style="width:${Math.max(0,Math.min(100,k))}%"></span></span> <span>${Math.round(k)}</span></div>`)}</div>`:ae.nothing} ${i?ae.html`<p><span class="archetype">${i.label}</span> ${i.description&&f?ae.html`· ${i.description}`:ae.nothing}</p>`:ae.nothing} ${l&&f?ae.html`<p>${l}</p>`:ae.nothing} ${c&&f?ae.html`<p class="body">${c}</p>`:ae.nothing} ${o&&f?ae.html`<p class="body">${o}</p>`:ae.nothing} ${this.renderAspectBreakdown()} ${this.renderSignCompatibility()} ${this.renderElementBalance()} ${this.renderSubScores()} ${f&&((d?.length??0)>0||(h?.length??0)>0)?ae.html`<div class="lists" part="section strengths-challenges">${d?.length?ae.html`<div><h3>${this.t("Strengths")}</h3><ul>${d.map($=>ae.html`<li>${$}</li>`)}</ul></div>`:ae.nothing} ${h?.length?ae.html`<div><h3>${this.t("Challenges")}</h3><ul>${h.map($=>ae.html`<li>${$}</li>`)}</ul></div>`:ae.nothing}</div>`:ae.nothing} ${p?.length?ae.html`<div class="lists" part="section key-aspects"><div><h3>${this.t("Key aspects")}</h3><ul>${p.slice(0,6).map($=>ae.html`<li>${ey(this.effectiveLang(),$,f)}</li>`)}</ul></div></div>`:ae.nothing}</article>`}renderAspectBreakdown(){let e=this.astro()?.aspectBreakdown;return e?ae.html`<p class="counts" part="details aspect-breakdown" role="region" aria-label="${this.t("Aspect breakdown")}">${typeof e.total=="number"?ae.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:ae.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span></p>`:ae.nothing}renderSignCompatibility(){let e=this.astro(),t=e?.signCompatibility;if(!t)return ae.nothing;let r=e?.persons,n=Jg.map(i=>{let o=t[i];if(!o)return null;let l=c=>{let d=U((c==="person1"?o.person1Sign:o.person2Sign)??""),h=r?.[c]?.[i]?.degree,p=typeof h=="number"?` ${Math.round(h)}\xB0`:"";return`${d}${p}`};return{glyph:S(i),label:U(i),aside:ot(this.effectiveLang(),[l("person1"),l("person2")]),body:o.description??""}}).filter(i=>i!==null);return this.renderInterpretation(n,"compat-signs","Sign compatibility")}renderElementBalance(){let e=this.astro()?.elementBalance;if(!e)return ae.nothing;let t=e.person1,r=e.person2,n=Math.max(1,...mp.map(o=>Math.max(t?.[o]??0,r?.[o]??0))),i=e.sharedElement?.toLowerCase();return ae.html`<section class="block" part="section element-balance"><h3>${this.t("Element balance")}</h3><div class="elements"><div class="el-row el-head"><span></span> <span class="roxy-label">${this.t("Person 1")}</span> <span class="roxy-label">${this.t("Person 2")}</span></div>${mp.map(o=>{let l=t?.[o]??0,c=r?.[o]??0;return ae.html`<div class="${o===i?"el-row shared":"el-row"}"><span class="el-name">${o}</span> <span class="el-bar p1"><span>${l}</span> <span class="track"><span style="width:${l/n*100}%"></span></span> </span><span class="el-bar p2"><span class="track"><span style="width:${c/n*100}%"></span></span> <span>${c}</span></span></div>`})}</div>${e.description&&!this.hideReadings?ae.html`<p class="shared-note">${e.description}</p>`:ae.nothing}</section>`}renderSubScores(){let e=this.data;if(!e)return ae.nothing;let t=[];if("lifePath"in e){let r=[["Life Path",e.lifePath],["Expression",e.expression],["Soul Urge",e.soulUrge]];for(let[n,i]of r)i&&t.push({label:this.t(n),aside:[ot(this.effectiveLang(),[String(i.person1),String(i.person2)]),Ne(this.effectiveLang(),i.compatibility,0)].filter(Boolean).join(" \xB7 "),body:i.description??""})}if("cycles"in e&&e.cycles)for(let[r,n]of Object.entries(e.cycles))n&&t.push({label:yr(r,i=>this.t(i)),aside:[typeof n.alignment=="number"?this.t("{{percent}} in step",{percent:Ne(this.effectiveLang(),n.alignment,0)}):"",n.phase?this.t(Qg[n.phase]):""].filter(Boolean).join(" \xB7 "),body:n.description??""});return this.renderInterpretation(t,"compat-sub-scores","Breakdown")}astro(){let e=this.data;return e&&"signCompatibility"in e?e:void 0}};Pa.endpoints=xl,Pa.styles=[u,X,me,ae.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr) auto;display:grid}.head h2{text-transform:capitalize}.score{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.rating{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.bar-row{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:14ch minmax(0,1fr) 4ch;display:grid}.bar,.el-bar .track{block-size:var(--roxy-space-sm);background:var(--roxy-border);border-radius:var(--roxy-radius-full);overflow:hidden}.bar>span{background:var(--roxy-accent);height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.bar-row>span:last-child{color:var(--roxy-muted);text-align:end;font-variant-numeric:tabular-nums}.archetype{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.lists h3{margin-block-end:var(--roxy-space-xs)}.lists ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}p.body{font-size:var(--roxy-text-sm)}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.block>h3{margin-block-end:var(--roxy-space-sm)}.elements{gap:var(--roxy-space-sm);display:grid}.el-row{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);grid-template-columns:8ch minmax(0,1fr) minmax(0,1fr);display:grid}.el-row .el-name{text-transform:capitalize}.el-row.shared .el-name{font-weight:var(--roxy-weight-bold)}.el-head span:nth-child(2){text-align:end}.el-bar{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;display:flex}.el-bar.p1{flex-direction:row-reverse}.el-bar .track{flex:auto;display:flex}.el-bar.p1 .track{justify-content:flex-end}.el-bar .track>span{background:var(--roxy-accent);height:100%;display:block}.el-bar.p2 .track>span{background:var(--roxy-secondary)}.shared-note{font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-sm)}`],m([(0,yp.property)({type:String,reflect:true})],Pa.prototype,"mode",2),Pa=m([x("roxy-compatibility-card")],Pa);function ey(s,a,e){let t=Dt(a),r=typeof a.orb=="number"?` (orb ${b(s,a.orb,1)}\xB0)`:"",n=[a.planet1,t,a.planet2].filter(Boolean).join(" ");return a.description&&e?`${n}${r} \xB7 ${a.description}`:`${n}${r}`}var Wt=require("lit");var up={fortunate:"Fortunate",unfortunate:"Unfortunate",mixed:"Mixed fortune"},ty={fortunate:"success",unfortunate:"danger",mixed:"warning"},vr=class extends g{renderData(a){let e=q(this.effectiveLang(),a.number);return Wt.html`<article class="card" part="card" aria-label="${`${this.t("Compound number")} ${e}`}"><header class="hero" part="header"><div class="numeral">${e}</div><div><p class="roxy-label">${this.t("Compound number")}</p>${a.name?Wt.html`<h2>${a.name}</h2>`:Wt.nothing}</div></header><ul class="badges roxy-chips" part="details"><li>${this.t("Root number {{n}}",{n:q(this.effectiveLang(),a.root)})}</li><li class="roxy-chip" data-tone="${ty[a.nature]??Wt.nothing}">${up[a.nature]?this.t(up[a.nature]):D(a.nature)}</li>${typeof a.sameAs=="number"?Wt.html`<li>${this.t("Same meaning as {{n}}",{n:q(this.effectiveLang(),a.sameAs)})}</li>`:Wt.nothing}</ul>${a.meaning&&!this.hideReadings?Wt.html`<p part="section readings">${a.meaning}</p>`:Wt.nothing}</article>`}};vr.endpoints=bl,vr.styles=[u,Wt.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.hero>div{min-width:0}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.badges>li{font-variant-numeric:tabular-nums}`],vr=m([x("roxy-compound-number")],vr);var Te=require("lit");var ay={apple:"#8db600",azure:"#007fff",blackish:"black",bluish:"blue",bottle:"#006a4e",brass:"#b5a642",brick:"#b22222",brownish:"brown",browns:"brown",burgundy:"#800020",clear:"#eef2f6",colorless:"#eef2f6",colourless:"#eef2f6",cream:"#fffdd0",creamy:"#fffdd0",emerald:"#50c878",golden:"gold",greenish:"green",lilac:"#c8a2c8",mauve:"#e0b0ff",peach:"peachpuff",pinkish:"pink",reddish:"red",rose:"#f4a6b7",royal:"royalblue",silvery:"silver",sky:"skyblue",yellowish:"yellow"},ry=new Set(["beige","black","blue","brown","crimson","cyan","gold","gray","green","grey","indigo","lavender","magenta","maroon","navy","olive","orange","pink","purple","red","salmon","silver","tan","teal","turquoise","violet","white","yellow"]),sy={bright:["white",85],dark:["black",60],deep:["black",70],faintly:["white",30],light:["white",55],pale:["white",45],rich:["black",80]};function Un(s){let a=[],e=[];for(let i of s.toLowerCase().split(/[\s-]+/)){let o=sy[i];if(o){e.push(o);continue}let l=ay[i]??(ry.has(i)?i:"");l&&a.push(l)}let[t,r]=a;if(!t)return"var(--roxy-border, #e4e4e7)";let n=r?`color-mix(in srgb, ${t}, ${r})`:t;for(let[i,o]of e)n=`color-mix(in srgb, ${n} ${o}%, ${i})`;return n}var Lr=class extends g{renderData(a){let e=a.colors??[],t=a.keywords??[],r=a.pairsWith??[],n=Sn(this.effectiveLang(),a.birthMonth)||void 0,i=a.name??this.t("Crystal");return Te.html`<article class="wrap" part="card" aria-label="${i}"><div class="hero" part="header">${a.imageUrl?Te.html`<img class="photo" part="chart" src="${a.imageUrl}" alt="${i}" loading="lazy">`:Te.nothing}<div><h2>${a.name}</h2>${a.description&&!this.hideReadings?Te.html`<p class="desc">${a.description}</p>`:Te.nothing}</div></div><dl class="roxy-facts" part="details">${this.attr(this.t("Planet"),a.planet)} ${this.attr(this.t("Hardness"),typeof a.hardness=="number"?this.t("{{value}} Mohs",{value:b(this.effectiveLang(),a.hardness)}):void 0)} ${this.attr(this.t("Vibration"),a.numericalVibration)} ${this.attr(this.t("Birthstone"),n)} ${this.list(this.t("Chakras"),a.chakras)} ${this.list(this.t("Zodiac"),a.zodiacSigns)} ${this.list(this.t("Elements"),a.elements)} ${e.length?Te.html`<div><dt>${this.t("Colors")}</dt><dd><div class="colors">${e.map(o=>Te.html`<span class="color"><span class="dot" style="${`background:${Un(o)}`}"></span>${o}</span>`)}</div></dd></div>`:Te.nothing}</dl>${this.renderMeaning(a.meaning)} ${t.length&&!this.hideReadings?Te.html`<section part="section keywords"><h3>${this.t("Keywords")}</h3><ul class="chips roxy-chips">${t.map(o=>Te.html`<li>${o}</li>`)}</ul></section>`:Te.nothing} ${a.affirmation&&!this.hideReadings?Te.html`<p class="affirmation">${a.affirmation}</p>`:Te.nothing} ${r.length?Te.html`<section part="section pairs-with"><h3>${this.t("Pairs with")}</h3><ul class="chips roxy-chips">${r.map(o=>Te.html`<li>${String(o).replace(/-/g," ")}</li>`)}</ul></section>`:Te.nothing}</article>`}attr(a,e){return e==null||e===""?Te.nothing:Te.html`<div><dt>${a}</dt><dd>${e}</dd></div>`}list(a,e){return e?.length?Te.html`<div><dt>${a}</dt><dd>${e.join(", ")}</dd></div>`:Te.nothing}renderMeaning(a){if(!a||this.hideReadings)return Te.nothing;let t=[[this.t("Spiritual"),a.spiritual],[this.t("Emotional"),a.emotional],[this.t("Physical"),a.physical]].filter(([,r])=>!!r);return t.length===0?Te.nothing:Te.html`<div class="meaning" part="section meaning">${t.map(([r,n])=>Te.html`<h3>${r}</h3><p>${n}</p>`)}</div>`}};Lr.endpoints=vl,Lr.styles=[u,Re,Te.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.hero{align-items:flex-start;gap:var(--roxy-space-md);display:flex}.photo{border-radius:var(--roxy-radius-md);object-fit:cover;background:var(--roxy-border);flex:none;block-size:4lh;inline-size:4lh}.hero h2{margin-block-end:var(--roxy-space-xs)}.desc,.meaning p{font-size:var(--roxy-text-sm)}.colors{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.color{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-xs);text-transform:capitalize;display:inline-flex}.dot{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.6lh;inline-size:.6lh}.meaning h3,section>h3{margin-block-end:var(--roxy-space-xs)}.meaning p{margin-block-end:var(--roxy-space-sm)}.chips>li{text-transform:capitalize}.affirmation{border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md);font-style:italic}`],Lr=m([x("roxy-crystal-card")],Lr);var Ht=require("lit"),fp=require("lit/decorators.js");var Ma=class extends g{constructor(){super(...arguments);this.heading="";this.rowDetail={tag:"roxy-crystal-card",path:"crystals/{id}"};this.listKey="crystals"}renderData(e){let t=e.crystals??[];if(t.length===0)return this.renderEmpty();let r=this.heading||this.deriveHeading(e),n="total"in e&&typeof e.total=="number"?e.total:t.length;return Ht.html`<section class="wrap" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="count">${n===1?this.t("1 crystal"):this.t("{{count}} crystals",{count:n})}</span></header><ul class="grid" part="section crystals">${t.map(i=>Ht.html`<li><button type="button" class="tile" aria-pressed="${this.openedRowId===i.id?"true":"false"}" @click="${()=>this.pickRow({id:i.id,name:i.name})}">${i.imageUrl?Ht.html`<img class="photo" src="${i.imageUrl}" alt="${i.name??this.t("Crystal")}" loading="lazy">`:Ht.html`<div class="photo" aria-hidden="true"></div>`}<p class="name">${i.name}</p>${i.colors&&i.colors.length>0?Ht.html`<div class="colors" aria-label="${this.t("Colors: {{list}}",{list:ot(this.effectiveLang(),i.colors)})}">${i.colors.map(o=>Ht.html`<span class="swatch" style="${`background:${Un(o)}`}" title="${o}"></span>`)}</div>`:Ht.nothing}</button></li>`)}</ul>${this.renderMore()} ${this.openedRow?Ht.html`<div class="detail" part="detail">${this.openedRow}</div>`:Ht.nothing}</section>`}deriveHeading(e){return"chakra"in e&&e.chakra?this.t("{{chakra}} chakra crystals",{chakra:e.chakra}):"element"in e&&e.element?this.t("{{element}} element crystals",{element:e.element}):"sign"in e&&e.sign?this.t("Crystals for {{sign}}",{sign:e.sign}):"month"in e&&typeof e.month=="number"?this.t("{{month}} birthstones",{month:Sn(this.effectiveLang(),e.month)}):this.t("Crystals")}};Ma.endpoints=Ll,Ma.styles=[u,Ht.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,16ch),1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs);width:100%;padding:var(--roxy-space-xs);color:inherit;border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;border:1px solid #0000;display:grid}.tile[aria-pressed=true],.tile:hover{border-color:var(--roxy-accent)}.detail{margin-block-start:var(--roxy-space-md)}.photo{aspect-ratio:1;border-radius:var(--roxy-radius-sm);object-fit:cover;background:var(--roxy-border);width:100%}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.colors{gap:var(--roxy-space-xs);flex-wrap:wrap;display:flex}.swatch{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.4lh;inline-size:.4lh}`],m([(0,fp.property)({type:String,reflect:true})],Ma.prototype,"heading",2),Ma=m([x("roxy-crystal-grid")],Ma);var ge=require("lit"),Yn=require("lit/decorators.js");function xp(s){return"pranaDashas"in s?"Prana":"sookshmaDashas"in s?"Sookshma":"pratyantardashas"in s?"Pratyantardasha":"antardashas"in s?"Antardasha":"Mahadasha"}function po(s){if("sookshmaPeriod"in s&&s.sookshmaPeriod)return{source:"Sookshma",period:s.sookshmaPeriod};if("pratyantardashaPeriod"in s&&s.pratyantardashaPeriod)return{source:"Pratyantardasha",period:s.pratyantardashaPeriod};if("antardashaPeriod"in s&&s.antardashaPeriod)return{source:"Antardasha",period:s.antardashaPeriod};if("mahadashaPeriod"in s&&s.mahadashaPeriod)return{source:"Mahadasha",period:s.mahadashaPeriod}}function ho(s){if(!s)return"";let a=[];return s.years&&a.push(`${s.years}y`),s.months&&a.push(`${s.months}m`),s.days&&a.push(`${s.days}d`),a.length?a.join(" "):"0d"}function bp(s,a){return ga(s?.strongHouses?.length?s.strongHouses:s?.signifiedHouses,a)}function qn(s,a){let e=M(s,a.startDate);return e&&e===M(s,a.endDate)?Ds(s,a.startDate,a.endDate):Et(s,a.startDate,a.endDate)}var ya=class extends g{constructor(){super(...arguments);this.period="current";this.view="timeline"}renderData(e){let t=this.collectPeriods(e),r=t.length?Math.max(...t.map(d=>d.durationYears)):0,n=iy(t.length?Math.min(...t.map(d=>d.durationYears)):0),i=this.hideReadings?[]:this.readings(e,t),o=this.frameRows(e),l=[{id:"timeline",label:this.t("Timeline")},...i.length?[{id:"readings",label:this.t("Readings ({{count}})",{count:i.length})}]:[],...o.length?[{id:"frame",label:this.t("Chart details")}]:[]],c=l.some(d=>d.id===this.view)?this.view:"timeline";return ge.html`<div class="wrap" part="card" aria-label="${this.t("Dasha timeline")}"><header class="head" part="header"><h2 class="title">${this.heading(e)}</h2>${this.renderLordChain(e)}</header>${this.renderParentMahadasha(e)} ${l.length>1?ut({items:l,active:c,onSelect:d=>{this.view=d},label:this.t("Dasha views"),idPrefix:"roxy-dasha",controls:true}):ge.nothing}<div id="roxy-dasha-panel-${c}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="${l.length>1?`roxy-dasha-tab-${c}`:ge.nothing}">${c==="timeline"?ge.html`${this.period==="current"?this.renderCurrent(e):ge.nothing} ${t.length>0?ge.html`<div class="timeline" part="chart timeline" role="list">${t.map(d=>this.renderBar(d,r,n,e.houseThemes))}</div>`:ge.nothing}`:ge.nothing} ${c==="readings"?this.renderReadings(i):ge.nothing} ${c==="frame"?this.renderFrame(o):ge.nothing}</div></div>`}renderLordChain(e){let t=["mahadashaLord"in e?e.mahadashaLord:void 0,"antardashaLord"in e?e.antardashaLord:void 0,"pratyantardashaLord"in e?e.pratyantardashaLord:void 0,"sookshmaLord"in e?e.sookshmaLord:void 0].filter(Boolean);return t.length>1?ge.html`<div class="nakshatra">${t.join(" \u203A ")}</div>`:"nakshatraName"in e&&e.nakshatraName?ge.html`<div class="nakshatra">${"nakshatraLord"in e&&e.nakshatraLord?this.t("Moon nakshatra: {{name}} (lord {{lord}})",{name:e.nakshatraName,lord:e.nakshatraLord}):this.t("Moon nakshatra: {{name}}",{name:e.nakshatraName})}</div>`:ge.nothing}frameRows(e){let t=[];if("nakshatraName"in e&&e.nakshatraName){let r="moonNakshatra"in e&&e.moonNakshatra?` (${e.moonNakshatra} of 27)`:"";t.push(["Moon nakshatra",`${e.nakshatraName}${r}`])}if("nakshatraLord"in e&&e.nakshatraLord&&t.push(["Nakshatra lord",e.nakshatraLord]),"moonLongitude"in e&&typeof e.moonLongitude=="number"&&t.push(["Moon longitude",`${b(this.effectiveLang(),e.moonLongitude,3)}\xB0 sidereal`]),"ayanamsaType"in e&&e.ayanamsaType&&t.push(["Ayanamsa",ps(this.effectiveLang(),e.ayanamsaType,"ayanamsa"in e?e.ayanamsa:void 0)]),"birthDashaBalance"in e&&e.birthDashaBalance){let r="nakshatraLord"in e&&e.nakshatraLord?`${e.nakshatraLord} `:"";t.push(["Balance at birth",`${ho(e.birthDashaBalance)} of the opening ${r}mahadasha`])}return"totalYears"in e&&typeof e.totalYears=="number"&&t.push(["Cycle length",`${e.totalYears} years`]),t}renderFrame(e){return ge.html`<dl class="roxy-facts" part="details frame">${e.map(([t,r])=>ge.html`<div><dt>${t}</dt><dd>${r}</dd></div>`)}</dl>`}renderReadings(e){return this.renderInterpretation(e,"roxy-dasha",e.length===1?"Reading":"Readings")}heading(e){let t=po(e);return t?this.t("{{level}} periods in {{planet}} {{parent}}",{level:this.t(xp(e)),planet:t.period.planet,parent:this.t(t.source)}):"mahadashas"in e?this.t("Vimshottari Mahadasha"):"mahadasha"in e?this.t("Active dashas"):this.period==="major"?this.t("Vimshottari Mahadasha"):this.t("Active dashas")}renderParentMahadasha(e){let t=po(e);if(!t)return ge.nothing;let r=t.period,n=qn(this.effectiveLang(),r),i=r.nominalStartDate?M(this.effectiveLang(),r.nominalStartDate):"";return ge.html`<p class="parent">${this.t("Inside the {{planet}} {{level}}{{span}}{{duration}}.",{planet:r.planet,level:this.t(t.source),span:n?`, ${n}`:"",duration:typeof r.durationYears=="number"?` (${ny(this.effectiveLang(),r.durationYears)})`:""})} ${i?ge.html`<br>${this.t("It began {{date}}, before birth, so only the sub-periods running after the birth date are listed.",{date:i})}`:ge.nothing}</p>`}readings(e,t){let r=[],n=po(e);if(n?.period.interpretation&&r.push({label:this.t("{{planet}} {{level}}",{planet:n.period.planet,level:this.t(n.source)}),aside:qn(this.effectiveLang(),n.period),body:n.period.interpretation}),"mahadasha"in e){let o=[["Mahadasha",e.mahadasha,e.remainingInMahadasha],["Antardasha",e.antardasha,e.remainingInAntardasha],["Pratyantardasha",e.pratyantardasha,e.remainingInPratyantardasha],["Sookshma",e.sookshmaDasha,e.remainingInSookshma],["Prana",e.pranaDasha,e.remainingInPrana]];for(let[l,c,d]of o){if(!c?.interpretation)continue;let h=ho(d);r.push({label:this.t("{{planet}} {{level}}",{planet:c.planet,level:this.t(l)}),aside:h?this.t("{{balance}} left",{balance:h}):qn(this.effectiveLang(),c),body:c.interpretation})}}let i=t.find(o=>this.isCurrent(o));return i?.interpretation&&r.push({label:`${i.planet} ${xp(e)}`,aside:qn(this.effectiveLang(),i),body:i.interpretation}),r}renderCurrent(e){if(!("mahadasha"in e))return ge.nothing;let t=[["Mahadasha",e.mahadasha,e.remainingInMahadasha],["Antardasha",e.antardasha,e.remainingInAntardasha],["Pratyantardasha",e.pratyantardasha,e.remainingInPratyantardasha],["Sookshma",e.sookshmaDasha,e.remainingInSookshma],["Prana",e.pranaDasha,e.remainingInPrana]];return ge.html`<div class="current" part="details current">${t.map(([r,n,i])=>{if(!n)return ge.nothing;let o=ho(i),l=bp(n.significators,e.houseThemes);return ge.html`<div><span class="roxy-label">${this.t(r)}</span> <strong>${n.planet}</strong> ${o?ge.html`<small>${this.t("{{balance}} left",{balance:o})}</small>`:ge.nothing} ${l?ge.html`<small class="houses">${this.t("Signifies {{houses}}",{houses:l})}</small>`:ge.nothing}</div>`})}</div>`}collectPeriods(e){return"mahadashas"in e&&e.mahadashas?.length?e.mahadashas:"antardashas"in e&&e.antardashas?.length?e.antardashas:"pratyantardashas"in e&&e.pratyantardashas?.length?e.pratyantardashas:"sookshmaDashas"in e&&e.sookshmaDashas?.length?e.sookshmaDashas:"pranaDashas"in e&&e.pranaDashas?.length?e.pranaDashas:[]}isCurrent(e){if(!e.startDate||!e.endDate)return false;let t=Date.now(),r=Date.parse(e.startDate),n=Date.parse(e.endDate);return Number.isNaN(r)||Number.isNaN(n)?false:t>=r&&t<n}progressIn(e){if(!e.startDate||!e.endDate)return-1;let t=Date.parse(e.startDate),r=Date.parse(e.endDate),n=Date.now();return Number.isNaN(t)||Number.isNaN(r)||n<t||n>=r||r<=t?-1:(n-t)/(r-t)}renderBar(e,t,r,n){let i=e.durationYears,o=t>0?i/t*100:0,l=this.isCurrent(e),c=l?this.progressIn(e):-1,d=l?"bar-track bar-now":"bar-track",h=bp(e.significators,n),p=["bar",l?"now":"",r==="time"?"fine":""].filter(Boolean).join(" ");return ge.html`<div class="${p}" part="label-track" role="listitem" aria-current="${l?"time":"false"}"><span><strong>${e.planet}</strong>${l?ge.html`<span class="now-badge">${this.t("Now")}</span>`:ge.nothing} </span><span class="${d}"><span class="bar-fill" style="width:${o}%"></span> ${c>=0?ge.html`<span class="bar-progress" style="left:${c*o}%" aria-hidden="true"></span>`:ge.nothing} </span><span class="dates">${od(this.effectiveLang(),e.startDate,e.endDate,r)} </span>${h?ge.html`<span class="houses">${this.t("Signifies {{houses}}",{houses:h})}</span>`:ge.nothing}</div>`}};ya.endpoints=$l,ya.styles=[u,X,Re,me,dt,ge.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}.nakshatra{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.current{gap:var(--roxy-space-md) var(--roxy-space-lg);border-block-end:1px solid var(--roxy-border);flex-wrap:wrap;margin-block-end:var(--roxy-space-md);padding-block-end:var(--roxy-space-md);display:flex}.current>div{align-content:start;min-width:0;display:grid}.current small{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.parent{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);font-size:var(--roxy-text-sm);color:var(--roxy-muted);margin:0;padding-inline-start:var(--roxy-space-sm)}.timeline{gap:var(--roxy-space-xs);display:grid}.bar{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr) 16ch;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);align-items:center;row-gap:0;display:grid}.bar.now strong,.now-badge{color:var(--roxy-accent-ink)}.now-badge{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.bar-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:.6lh;position:relative;overflow:hidden}.bar-fill{background:var(--roxy-accent);opacity:.45;height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.bar-now .bar-fill{opacity:1}.bar-progress{inline-size:var(--roxy-line-thick);background:var(--roxy-accent-ink);position:absolute;inset-block:0}.dates{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;text-align:end}.bar.fine{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr)}.bar.fine .dates{text-align:start;grid-column:1/-1;min-width:0}.bar .houses{min-width:0;color:var(--roxy-muted);font-size:var(--roxy-text-xs);grid-column:1/-1}[role=tabpanel]{padding-top:var(--roxy-space-md)}`],m([(0,Yn.property)({type:String,reflect:true})],ya.prototype,"period",2),m([(0,Yn.state)()],ya.prototype,"view",2),ya=m([x("roxy-dasha-timeline")],ya);var mo=365.25;function ny(s,a){if(a>=1)return`${b(s,a,1)} years`;let e=a*mo;if(e>=1)return`${b(s,e,e>=10?0:1)} days`;let t=e*24;return t>=1?`${b(s,t,1)} hours`:`${b(s,t*60,0)} minutes`}function iy(s){return s>=2?"year":s>=60/mo?"month":s>=1/mo?"day":"time"}var W=require("lit"),wp=require("lit/decorators.js"),yo=require("lit/directives/if-defined.js");var vp=["title","name","label","heading","overview","summary"],oy=80,ly=80,cy=3,dy=["imageUrl","image","icon","symbol"],py=["imageUrl","image"],hy=["affirmation","mantra","motto","quote"],my=new Set(["seed"]),gy=new Set(["id","slug","key"]),yy=new Set(["calculation","calculations","type","position","count","totalcount","total","limit","offset","page","pagesize","perpage"]),uy=8,Lp=1,fy=12,xy=s=>s.toLowerCase().replace(/[_-]/g,""),$p=s=>/^(has|is)([A-Z_]|$)/.test(s),by=/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}(:\d{2}(\.\d+)?)?(Z|[+-]\d{2}:\d{2})?)?$/,vy=/^[A-Z0-9]+(_[A-Z0-9]+)+$/,Ly=6;function $y(s,a){if(!Number.isInteger(a))return false;let e=s.replace(/([a-z])([A-Z])/g,"$1 $2").split(/[\s_-]+/);return e[e.length-1].toLowerCase()==="year"}function us(s){return s===null||["string","number","boolean"].includes(typeof s)}function go(s){return s!==null&&typeof s=="object"&&!(Array.isArray(s)&&s.every(us))}function kp(s){if(s==null)return true;if(Array.isArray(s))return s.length===0;if(typeof s!="object")return false;let a=Object.values(s);return a.length===0||a.every(kp)}var $r=class extends g{constructor(){super(...arguments);this.depth=0}renderData(e){return this.depth>=Ly?W.html`<div class="roxy-empty" role="status">${this.t("Nested data omitted")}</div>`:W.html`<div class="roxy-card" part="card" aria-label="${this.t("Generic data display")}">${this.renderValue(e)}</div>`}renderValue(e){return e==null?W.nothing:us(e)?W.html`<p>${this.scalarTemplate(e)}</p>`:Array.isArray(e)?this.renderArray(e):this.renderObject(e)}renderArray(e){return e.length===0?W.html`<div class="roxy-empty" role="status">${this.t("Empty list")}</div>`:e.every(us)?this.renderChips(e):e.every(r=>r!==null&&typeof r=="object"&&!Array.isArray(r))?this.renderObjectArray(e):W.html`<ol>${e.map(r=>W.html`<li>${this.renderValue(r)}</li>`)}</ol>`}renderChips(e){return W.html`<ul class="roxy-chips">${e.filter(t=>t!==null).map(t=>W.html`<li>${this.formatScalar(t)}</li>`)}</ul>`}renderObjectArray(e){let t=e.map(p=>this.suppress(p)),r=this.collectKeys(t),n=new Set(r.filter(p=>t.some(f=>typeof f[p]=="string"&&Array.from(f[p]).length>ly))),i=new Set(r.filter(p=>n.has(p)||t.some(f=>go(f[p]??null)))),o=n.size>0||i.size>0&&i.size<r.length,l=p=>o?i.has(p)?"col-wide":"col-tight":"",c=i.size>0&&r.length>cy,d=t.length>fy;return W.html`<div class="${c?"roxy-collection":d&&!c?"roxy-collection compact long":"roxy-collection compact"}" part="table" role="${c?"list":"group"}" aria-label="${c?this.t("{{count}} rows",{count:t.length}):this.t("Data table")}" tabindex="${c?W.nothing:"0"}">${c?W.html`${d?W.html`<p>${this.t("{{count}} rows",{count:t.length})}</p>`:W.nothing} ${t.map(p=>W.html`<div class="roxy-record" role="listitem">${this.renderField(p)}</div>`)}`:W.html`<table class="${n.size?"roxy-table stacked prose":i.size?"roxy-table stacked":"roxy-table"}" role="table">${d?W.html`<caption>${this.t("{{count}} rows",{count:t.length})}</caption>`:W.nothing}<thead><tr>${r.map(p=>W.html`<th class="${l(p)}">${Se(this.effectiveLang(),p)}</th>`)}</tr></thead><tbody>${t.map(p=>W.html`<tr>${r.map(f=>W.html`<td class="${l(f)}" data-label="${Se(this.effectiveLang(),f)}">${this.renderCell(p[f],f)}</td>`)}</tr>`)}</tbody></table>`}</div>`}suppress(e){let t=As(e),r=vp.some(n=>typeof t[n]=="string");return Object.fromEntries(Object.entries(t).filter(([n])=>{let i=xy(n);return my.has(i)||r&&gy.has(i)?false:!yy.has(i)}))}renderObject(e){let t=this.suppress(e),r=vp.find(h=>typeof t[h]=="string"&&t[h].length<=oy),n=dy.find(h=>typeof t[h]=="string"&&t[h].startsWith("http")),i=r!=="summary"&&typeof t.summary=="string"?"summary":null,o=hy.find(h=>typeof t[h]=="string"),l=Object.entries(t).filter(([h,p])=>h!==r&&h!==i&&h!==o&&!py.includes(h)&&!kp(p)),c=l.filter(([,h])=>!go(h)),d=l.filter(([,h])=>go(h));return W.html`${n?W.html`<img class="roxy-image" src="${String(t[n])}" alt="${r?String(t[r]):this.t("illustration")}" loading="lazy">`:W.nothing} ${r?this.depth===0?W.html`<h2 class="roxy-title" part="header">${t[r]}</h2>`:W.html`<h3 class="roxy-title" part="header">${t[r]}</h3>`:W.nothing} ${i?W.html`<p class="roxy-summary">${t[i]}</p>`:W.nothing} ${o?W.html`<blockquote class="roxy-quote">${t[o]}</blockquote>`:W.nothing} ${c.length>0?W.html`<dl class="roxy-rows" part="details label-track">${c.map(([h,p])=>W.html`<dt>${Se(this.effectiveLang(),h)}</dt><dd>${this.renderField(p,h)}</dd>`)}</dl>`:W.nothing} ${d.map(([h,p])=>this.renderSection(h,p))}`}renderSection(e,t){let r=t!==null&&typeof t=="object"?Array.isArray(t)?t.length:Object.keys(t).length:0,n=this.renderField(t,e),i=Se(this.effectiveLang(),e);return r>uy||this.depth>=Lp?W.html`<details class="roxy-section" ?open="${this.depth<Lp}"><summary>${i}</summary>${n}</details>`:W.html`<div class="roxy-section">${this.depth===0?W.html`<h3>${i}</h3>`:W.html`<h4>${i}</h4>`} ${n}</div>`}renderField(e,t){return e==null?"":e===true&&t!==void 0&&$p(t)?W.html`<span class="roxy-chip">${this.t("Yes")}</span>`:us(e)?W.html`${this.scalarTemplate(e,t)}`:Array.isArray(e)&&e.every(us)?this.renderChips(e):W.html`<roxy-data bare lang="${(0,yo.ifDefined)(this.effectiveLang())}" .data="${e}" .depth="${this.depth+1}"></roxy-data>`}renderCell(e,t){return e==null?"":e===true&&t!==void 0&&$p(t)?W.html`<span class="roxy-chip">${this.t("Yes")}</span>`:us(e)?this.scalarTemplate(e,t):Array.isArray(e)&&e.every(us)?e.filter(r=>r!==null).map(r=>this.formatScalar(r)).join(", "):W.html`<roxy-data bare lang="${(0,yo.ifDefined)(this.effectiveLang())}" .data="${e}" .depth="${this.depth+1}"></roxy-data>`}scalarTemplate(e,t){return yn(e)?W.html`<a href="${e}" target="_blank" rel="noopener noreferrer">${e}</a>`:this.formatScalar(e,t)}formatScalar(e,t){return typeof e=="number"?t!==void 0&&$y(t,e)?String(e):b(this.effectiveLang(),e,2)||String(e):typeof e=="boolean"?e?this.t("Yes"):this.t("No"):by.test(e)?fe(this.effectiveLang(),e):vy.test(e)?D(e.toLowerCase()):e}collectKeys(e){let t=new Set;for(let r of e)for(let n of Object.keys(r))t.add(n);return Array.from(t)}};$r.styles=[u,W.css`.roxy-card{padding:var(--roxy-space-md)}.roxy-card a{color:var(--roxy-accent-ink)}:is(h2,h3,h4,p,dl){margin:0}:is(h2,h3).roxy-title{margin-block-end:var(--roxy-space-sm)}.roxy-summary{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-md)}dl.roxy-rows{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:fit-content(25%) minmax(0,1fr);display:grid}dl.roxy-rows dd{word-break:break-word;margin:0}.roxy-collection{min-width:0}.roxy-collection.compact{overflow-x:auto}.roxy-collection.long{max-block-size:20lh}.roxy-record+.roxy-record{margin-block-start:var(--roxy-space-sm)}table.roxy-table{width:100%}table.roxy-table caption{text-align:start}table.roxy-table th{white-space:nowrap}:where(table.roxy-table) :is(th,td).col-tight{white-space:nowrap;width:1%}:where(table.roxy-table.prose) :is(th,td).col-wide{min-width:40ch}.roxy-image{max-width:100%;height:auto;border-radius:var(--roxy-radius-md);margin-block-end:var(--roxy-space-md)}.roxy-section{margin-block-start:var(--roxy-space-md)}.roxy-section>:is(h3,h4,summary){font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);margin-block-end:var(--roxy-space-xs)}blockquote.roxy-quote{margin:var(--roxy-space-md) 0;border-inline-start:var(--roxy-line-thick) solid var(--roxy-accent);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md);font-style:italic}`,pa],m([(0,wp.property)({attribute:false})],$r.prototype,"depth",2),$r=m([x("roxy-data")],$r);var Zt=require("lit"),Mp=require("lit/decorators.js"),_p=require("lit/directives/unsafe-html.js");var ua=require("lit");var jt=400,Ee=20,bt=jt-2*Ee,Ye=jt/2,Sp=Object.fromEntries(Ie.map(s=>[s.toLowerCase(),s])),fo="\u02B3",xo="\u1D9C",bo="\u02B7";function uo(s){return Ie.indexOf(s)}function wy(s){let a=Rd(s.graha)??s.graha,e=`${s.isRetrograde?fo:""}${s.combust?xo:""}${s.war?bo:""}`;if(typeof s.longitude!="number"||!Number.isFinite(s.longitude)||s.natalReference)return`${a}${e}`;let{degree:t}=Ut(s.longitude);return`${a} ${t}\xB0${e}`}function ky(s,a,e){let t=[U(s.graha)],r=s.natalReference===true;if(r&&t.push(e("in {{sign}}",{sign:a})),typeof s.longitude=="number"&&Number.isFinite(s.longitude)){let n=Ut(s.longitude),i=String(n.minute).padStart(2,"0");t.push(r?`D1: ${n.degree}\xB0${i}' ${n.sign}`:`${n.degree}\xB0${i}' ${n.sign}`)}if(s.nakshatra?.name){let n=s.nakshatra.pada?` ${e("pada {{n}}",{n:s.nakshatra.pada})}`:"";t.push(`${r?"D1: ":""}${s.nakshatra.name}${n}`)}return s.nakshatra?.lord&&t.push(e("nakshatra lord {{graha}}",{graha:s.nakshatra.lord})),s.awastha&&t.push(s.awastha),s.deeptadi&&t.push(s.deeptadi),s.combust&&t.push(e("combust")),s.war&&t.push(s.war.winner?e("planetary war with {{graha}}, won by {{winner}}",{graha:s.war.opponent,winner:s.war.winner}):e("planetary war with {{graha}}",{graha:s.war.opponent})),s.isRetrograde&&t.push(e("retrograde")),t.join(" \xB7 ")}function vo(s,a,e,t,r,n){let i=t-(s.length-1)*r/2;return s.map((o,l)=>{let c=i+l*r;return R`<text class="planet-text" x=${e} y=${c} text-anchor="middle" dominant-baseline="central">${wy(o)}<title>${ky(o,a,n)}</title></text>`})}function Zn(s,a={}){let{divisionLabel:e,lagnaOverride:t,states:r,natalReference:n}=a,i=new Set((r?.combustion??[]).map(h=>(h.planet??"").toLowerCase())),o=new Map;for(let h of r?.planetaryWar??[])!h.planet1||!h.planet2||(o.set(h.planet1.toLowerCase(),{opponent:h.planet2,winner:h.winner}),o.set(h.planet2.toLowerCase(),{opponent:h.planet1,winner:h.winner}));let l={};for(let h of Ie)l[h.toLowerCase()]=[];let c=t?Sp[t.toLowerCase()]??"":"",d=c;for(let[h,p]of Object.entries(s??{})){let f=(p?.rashi??"").toLowerCase();if(h==="Lagna"||p?.graha==="Lagna"){c||(d=Sp[f]??"");continue}if(!f||!(f in l))continue;let L=p.graha??h,$=L.toLowerCase();l[f]?.push({graha:L,natalReference:n,longitude:p.longitude,nakshatra:p.nakshatra,isRetrograde:p.isRetrograde,awastha:p.awastha,deeptadi:p.deeptadi,combust:i.has($)||void 0,war:o.get($)})}return{lagnaSign:d,placements:l,divisionLabel:e}}var fs=bt/4,Sy={Pisces:{col:0,row:0},Aries:{col:1,row:0},Taurus:{col:2,row:0},Gemini:{col:3,row:0},Cancer:{col:3,row:1},Leo:{col:3,row:2},Virgo:{col:3,row:3},Libra:{col:2,row:3},Scorpio:{col:1,row:3},Sagittarius:{col:0,row:3},Capricorn:{col:0,row:2},Aquarius:{col:0,row:1}};function Ry(s){let a=Sy[s]??{col:0,row:0};return{x:Ee+a.col*fs,y:Ee+a.row*fs,w:fs,h:fs}}function Cy(s){let a=Ee,e=Ee+fs,t=Ee+2*fs,r=Ee+3*fs,n=jt-Ee;return R`
|
|
17
|
+
<rect class="line" x=${a} y=${a} width=${bt} height=${bt} stroke-width="1.5" fill="none" />
|
|
18
|
+
<line class="line" x1=${a} y1=${e} x2=${n} y2=${e} stroke-width="1" />
|
|
19
|
+
<line class="line" x1=${a} y1=${r} x2=${n} y2=${r} stroke-width="1" />
|
|
20
|
+
<line class="line" x1=${e} y1=${a} x2=${e} y2=${n} stroke-width="1" />
|
|
21
|
+
<line class="line" x1=${r} y1=${a} x2=${r} y2=${n} stroke-width="1" />
|
|
22
22
|
<line class="line" x1=${a} y1=${t} x2=${e} y2=${t} stroke-width="1" />
|
|
23
|
-
<line class="line" x1=${r} y1=${t} x2=${
|
|
23
|
+
<line class="line" x1=${r} y1=${t} x2=${n} y2=${t} stroke-width="1" />
|
|
24
24
|
<line class="line" x1=${t} y1=${a} x2=${t} y2=${e} stroke-width="1" />
|
|
25
|
-
<line class="line" x1=${t} y1=${r} x2=${t} y2=${
|
|
26
|
-
${
|
|
27
|
-
`}function
|
|
25
|
+
<line class="line" x1=${t} y1=${r} x2=${t} y2=${n} stroke-width="1" />
|
|
26
|
+
${s?R`<text class="centre-label" x=${Ye} y=${Ye} text-anchor="middle" dominant-baseline="central">${s}</text>`:""}
|
|
27
|
+
`}function Lo(s,a){let e=uo(a),t=uo(s);return e===-1||t===-1?0:(t-e+12)%12+1}function Ty(s,a,e,t,r){let n=Ry(s),i=n.x+n.w/2,o=n.y+n.h/2,l=_n(s)??s,c=14;return R`
|
|
28
28
|
<g class=${e?"cell lagna":"cell"}>
|
|
29
|
-
${e?
|
|
30
|
-
<rect class="lagna-bg" x=${
|
|
31
|
-
<line class="lagna-slash" x1=${
|
|
29
|
+
${e?R`
|
|
30
|
+
<rect class="lagna-bg" x=${n.x} y=${n.y} width=${n.w} height=${n.h} />
|
|
31
|
+
<line class="lagna-slash" x1=${n.x+n.w-c} y1=${n.y+c} x2=${n.x+c} y2=${n.y+n.h-c} stroke-width="1.2" />
|
|
32
32
|
`:""}
|
|
33
|
-
<text class="sign-text" x=${
|
|
34
|
-
${t>0?
|
|
35
|
-
${e?
|
|
36
|
-
${a.length?
|
|
33
|
+
<text class="sign-text" x=${n.x+6} y=${n.y+12} text-anchor="start" dominant-baseline="central">${l}</text>
|
|
34
|
+
${t>0?R`<text class="house-num" x=${n.x+n.w-6} y=${n.y+12} text-anchor="end" dominant-baseline="central">${t}</text>`:""}
|
|
35
|
+
${e?R`<text class="lagna-marker" x=${i} y=${n.y+26} text-anchor="middle" dominant-baseline="central">${r("ASC")}</text>`:""}
|
|
36
|
+
${a.length?vo(a,s,i,o+4,14,r):""}
|
|
37
37
|
</g>
|
|
38
|
-
`}function
|
|
39
|
-
${
|
|
40
|
-
${Ie.map(t=>
|
|
41
|
-
`}var
|
|
42
|
-
<rect class="line" x=${a.x} y=${a.y} width=${
|
|
43
|
-
<polygon class="line" points="${
|
|
38
|
+
`}function Rp(s,a){let e=s.lagnaSign.toLowerCase();return R`
|
|
39
|
+
${Cy(s.divisionLabel)}
|
|
40
|
+
${Ie.map(t=>Ty(t,s.placements[t.toLowerCase()]??[],t.toLowerCase()===e,Lo(t,s.lagnaSign),a))}
|
|
41
|
+
`}var Tp={tl:{x:Ee,y:Ee},tr:{x:jt-Ee,y:Ee},br:{x:jt-Ee,y:jt-Ee},bl:{x:Ee,y:jt-Ee},top:{x:Ye,y:Ee},right:{x:jt-Ee,y:Ye},bottom:{x:Ye,y:jt-Ee},left:{x:Ee,y:Ye},tlMid:{x:Ye-bt/4,y:Ye-bt/4},trMid:{x:Ye+bt/4,y:Ye-bt/4},brMid:{x:Ye+bt/4,y:Ye+bt/4},blMid:{x:Ye-bt/4,y:Ye+bt/4}};function Ep(s){let a=s.reduce((t,r)=>t+r.x,0)/s.length,e=s.reduce((t,r)=>t+r.y,0)/s.length;return{x:a,y:e}}var Ey=Object.fromEntries(Object.entries({1:["top","trMid","centre","tlMid"],2:["tl","top","tlMid"],3:["tl","left","tlMid"],4:["left","tlMid","centre","blMid"],5:["bl","left","blMid"],6:["bl","bottom","blMid"],7:["bottom","blMid","centre","brMid"],8:["br","bottom","brMid"],9:["br","right","brMid"],10:["right","brMid","centre","trMid"],11:["tr","right","trMid"],12:["tr","top","trMid"]}).map(([s,a])=>{let e=a.map(t=>t==="centre"?{x:Ye,y:Ye}:Tp[t]);return[s,{centre:Ep(e),floor:Math.max(...e.map(t=>t.y))}]})),Cp=12,Dy=16,Ay=8;function Py(s){let{tl:a,tr:e,br:t,bl:r,top:n,right:i,bottom:o,left:l}=Tp;return R`
|
|
42
|
+
<rect class="line" x=${a.x} y=${a.y} width=${bt} height=${bt} stroke-width="1.5" fill="none" />
|
|
43
|
+
<polygon class="line" points="${n.x},${n.y} ${i.x},${i.y} ${o.x},${o.y} ${l.x},${l.y}" stroke-width="1" fill="none" />
|
|
44
44
|
<line class="line" x1=${a.x} y1=${a.y} x2=${t.x} y2=${t.y} stroke-width="1" />
|
|
45
45
|
<line class="line" x1=${e.x} y1=${e.y} x2=${r.x} y2=${r.y} stroke-width="1" />
|
|
46
|
-
${
|
|
47
|
-
`}function
|
|
46
|
+
${s?R`<text class="centre-label" x=${Ye} y=${Ye} text-anchor="middle" dominant-baseline="central">${s}</text>`:""}
|
|
47
|
+
`}function My(s,a,e,t,r,n){let i=Ey[s];if(!i)return R``;let o=i.centre,l=Math.min(14,Math.abs(o.y-Ye)*.45+6),c=(t.length-1)*Cp,d=Math.max(o.y+8-c/2,o.y-l+Dy),h=Math.max(0,d+c-(i.floor-Ay)),p=o.y-l-h,f=d-h+c/2,L=r?`${a} \xB7 ${_n(e)??e}`:`${a}`;return R`
|
|
48
48
|
<g class=${r?"cell lagna":"cell"}>
|
|
49
|
-
<text class="rashi-num" x=${o.x} y=${
|
|
50
|
-
${r?
|
|
51
|
-
${t.length?
|
|
49
|
+
<text class="rashi-num" x=${o.x} y=${p} text-anchor="middle" dominant-baseline="central">${L}</text>
|
|
50
|
+
${r?R`<text class="lagna-marker" x=${o.x} y=${p-12} text-anchor="middle" dominant-baseline="central">${n("ASC")}</text>`:""}
|
|
51
|
+
${t.length?vo(t,e,o.x,f,Cp,n):""}
|
|
52
52
|
</g>
|
|
53
|
-
`}function
|
|
54
|
-
${
|
|
55
|
-
${Ie.map((e,t)=>{let r=
|
|
56
|
-
`}var
|
|
57
|
-
<rect class="line" x=${a} y=${a} width=${
|
|
53
|
+
`}function _y(s,a){return R`
|
|
54
|
+
${Py(s.divisionLabel)}
|
|
55
|
+
${Ie.map((e,t)=>{let r=Lo(e,s.lagnaSign);return My(r,t+1,e,s.placements[e.toLowerCase()]??[],r===1,a)})}
|
|
56
|
+
`}var Wn=bt/3;function Ny(){let s=Ee,a=Ee+Wn,e=Ee+2*Wn,t=jt-Ee,k={Aries:[{x:a,y:s},{x:e,y:s},{x:e,y:a},{x:a,y:a}],Taurus:[{x:s,y:s},{x:a,y:s},{x:a,y:a}],Gemini:[{x:s,y:s},{x:a,y:a},{x:s,y:a}],Cancer:[{x:s,y:a},{x:a,y:a},{x:a,y:e},{x:s,y:e}],Leo:[{x:s,y:e},{x:a,y:e},{x:s,y:t}],Virgo:[{x:a,y:e},{x:a,y:t},{x:s,y:t}],Libra:[{x:a,y:e},{x:e,y:e},{x:e,y:t},{x:a,y:t}],Scorpio:[{x:e,y:e},{x:e,y:t},{x:t,y:t}],Sagittarius:[{x:e,y:e},{x:t,y:t},{x:t,y:e}],Capricorn:[{x:e,y:a},{x:t,y:a},{x:t,y:e},{x:e,y:e}],Aquarius:[{x:t,y:s},{x:t,y:a},{x:e,y:a}],Pisces:[{x:e,y:s},{x:t,y:s},{x:e,y:a}]},j={};for(let[ue,Xe]of Object.entries(k))j[ue]={points:[...Xe],centroid:Ep(Xe)};return j}var zy=Ny();function Oy(s){let a=Ee,e=Ee+Wn,t=Ee+2*Wn,r=jt-Ee;return R`
|
|
57
|
+
<rect class="line" x=${a} y=${a} width=${bt} height=${bt} stroke-width="1.5" fill="none" />
|
|
58
58
|
<line class="line" x1=${a} y1=${e} x2=${e} y2=${e} stroke-width="1" />
|
|
59
59
|
<line class="line" x1=${t} y1=${e} x2=${r} y2=${e} stroke-width="1" />
|
|
60
60
|
<line class="line" x1=${a} y1=${t} x2=${e} y2=${t} stroke-width="1" />
|
|
@@ -67,96 +67,96 @@
|
|
|
67
67
|
<line class="line" x1=${r} y1=${a} x2=${t} y2=${e} stroke-width="1" />
|
|
68
68
|
<line class="line" x1=${r} y1=${r} x2=${t} y2=${t} stroke-width="1" />
|
|
69
69
|
<line class="line" x1=${a} y1=${r} x2=${e} y2=${t} stroke-width="1" />
|
|
70
|
-
${
|
|
71
|
-
`}function
|
|
70
|
+
${s?R`<text class="centre-label" x=${Ye} y=${Ye} text-anchor="middle" dominant-baseline="central">${s}</text>`:""}
|
|
71
|
+
`}function Gy(s,a,e,t,r){let n=zy[s];if(!n)return R``;let{centroid:i,points:o}=n,l=_n(s)??s,c=o.map(d=>`${d.x},${d.y}`).join(" ");return R`
|
|
72
72
|
<g class=${e?"cell lagna":"cell"}>
|
|
73
|
-
${e?
|
|
73
|
+
${e?R`<polygon class="lagna-bg" points=${c} />`:""}
|
|
74
74
|
<text class="sign-text" x=${i.x} y=${i.y-16} text-anchor="middle" dominant-baseline="central">${l}</text>
|
|
75
|
-
${t>0?
|
|
76
|
-
${e?
|
|
77
|
-
${a.length?
|
|
75
|
+
${t>0?R`<text class="house-num" x=${i.x+18} y=${i.y-16} text-anchor="start" dominant-baseline="central">${t}</text>`:""}
|
|
76
|
+
${e?R`<text class="lagna-marker" x=${i.x} y=${i.y-30} text-anchor="middle" dominant-baseline="central">${r("ASC")}</text>`:""}
|
|
77
|
+
${a.length?vo(a,s,i.x,i.y+4,12,r):""}
|
|
78
78
|
</g>
|
|
79
|
-
`}function
|
|
80
|
-
${
|
|
81
|
-
${Ie.map(t=>
|
|
82
|
-
`}function co(n){return ro(n.lagnaSign)!==-1}function Jg(n,a,e){if(a==="north"&&!co(n))return Jd(n,e);switch(a){case"north":return Ug(n,e);case"east":return Xg(n,e);default:return Jd(n,e)}}function Fn(n,a={}){let e=dr(a.lang);return T`<svg class="kundli" xmlns=${cr} viewBox=${`0 0 ${Bt} ${Bt}`} preserveAspectRatio="xMidYMid meet" part="chart" role="img" aria-label=${a.label??e("Vedic birth chart with twelve sign houses")}><title>${a.title??e("Vedic kundli")}</title>${Jg(n,a.style??"north",e)}</svg>`.markup}var Qg=[{id:"north",source:"North"},{id:"south",source:"South"},{id:"east",source:"East"}];function ey(n,a){let e=Object.values(n.placements).flat(),t=[];return e.some(r=>r.isRetrograde)&&t.push(`${so} ${a("retrograde")}`),e.some(r=>r.combust)&&t.push(`${no} ${a("combust")}`),e.some(r=>r.war)&&t.push(`${io} ${a("planetary war")}`),t.length===0?pa.nothing:pa.html`<p class="roxy-frame">${t.join(" \xB7 ")}</p>`}function ty(n){return pa.html`<p class="roxy-frame">${n("No ascendant in this chart, so the houses are not numbered.")}</p>`}function Bn(n,a){let e=[];co(n)||e.push(ty(a));let t=ey(n,a);return t!==pa.nothing&&e.push(t),e}function Hn(n,a,e){return gt({items:Qg.map(({id:t,source:r})=>({id:t,label:e(r)})),active:n,onSelect:a,label:e("Kundli style"),idPrefix:"kundli",controls:true})}function ap(n,a,e,t){return pa.html`<details class="kundli-reference" part="section positions"><summary>${t("Planetary positions")}${he()}</summary><div class="kundli-reference-scroll" part="table" tabindex="0" role="region" aria-label="${t("Planetary positions")}"><table class="kundli-reference-table"><caption class="roxy-sr-only">${t("Planetary positions")}</caption><thead><tr><th scope="col">${t("Body")}</th><th scope="col">D${a} ${t("Sign")}</th><th scope="col">D${a} ${t("House")}</th><th scope="col">D1 ${t("Position")}</th><th scope="col">D1 ${t("Nakshatra")}</th><th scope="col">${t("Pada")}</th><th scope="col">${t("Star lord")}</th><th scope="col">${t("Motion")}</th></tr></thead><tbody>${Object.entries(n).map(([r,s])=>pa.html`<tr><th scope="row">${s.graha??r}</th><td>${s.rashi??""}</td><td>${typeof s.house=="number"?s.house:""}</td><td>${typeof s.longitude=="number"?pa.html`<span>${lt(s.longitude)}</span><small>${b(e,s.longitude,12)}°</small>`:pa.nothing}</td><td>${s.nakshatra?.name??""}</td><td>${s.nakshatra?.pada??""}</td><td>${s.nakshatra?.lord??""}</td><td>${s.isRetrograde?t("retrograde"):""}</td></tr>`)}</tbody></table></div></details>`}var rp=require("lit"),jn=rp.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.kundli-reference{min-width:0}.kundli-reference>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}.kundli-reference-scroll{min-width:0;margin-top:var(--roxy-space-sm);overflow-x:auto}.kundli-reference-table{width:100%}.kundli-reference-table :is(th,td){white-space:nowrap}.kundli-reference-table small{color:var(--roxy-secondary);display:block}.header{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,35rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}`;var ay={number:9,name:"Navamsa"},sp=n=>"division"in n&&n.division?n.division:ay,Ea=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this);this.chartStyle="north";this.setStyle=e=>{this.chartStyle=e}}viewModel(){if(!this.data?.chart?.meta)return null;let e=sp(this.data),t=`D${e.number} ${e.name}`;return Gn(this.data.chart.meta,{divisionLabel:t,natalReference:true})}renderData(e){let t=this.viewModel();if(!t)return this.renderEmpty();let r=sp(e),{vargottama:s}=e;return Yt.html`<div class="wrap" part="card"><div class="header" part="header"><div><h2 class="title">D${r.number} ${r.name} ${Ni(r.name,r.sanskritName)?Yt.html`<span class="division-meta">· ${r.sanskritName}</span>`:Yt.nothing}</h2>${r.significance?Yt.html`<p class="significance">${r.significance}</p>`:Yt.nothing} ${ve(this.effectiveLang(),e.frame,this.translator)} ${Bn(t,this.translator)}</div>${Hn(this.chartStyle,this.setStyle,this.translator)}</div><div id="kundli-panel-${this.chartStyle}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}">${this.chartViewport.renderChartViewport((0,ip.unsafeHTML)(Fn(t,{style:this.chartStyle,lang:this.effectiveLang(),label:this.t("{{chart}} divisional chart with twelve sign houses",{chart:`D${r.number} ${r.name}`}),title:`D${r.number} ${r.name}`})),`D${r.number} ${r.name}`,this.translator)}</div>${ap(e.chart.meta,r.number,this.effectiveLang(),this.translator)} ${s&&s.length>0?Yt.html`<div class="vargottama-row" part="details"><span class="roxy-label">${this.t("Vargottama")}:</span><ul class="roxy-chips" aria-label="${this.t("Vargottama planets")}">${s.map(i=>Yt.html`<li>${S(i)??""} ${i}</li>`)}</ul></div>`:Yt.nothing}</div>`}};Ea.endpoints=pl,Ea.styles=[u,Xe,ae,An,jn,W,ot,Yt.css`.division-meta{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);color:var(--roxy-muted)}.significance{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);font-size:var(--roxy-text-sm);color:var(--roxy-muted);margin:0;padding-inline-start:var(--roxy-space-sm)}.vargottama-row{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}`],m([(0,np.property)({type:String,reflect:true,attribute:"chart-style"})],Ea.prototype,"chartStyle",2),Ea=m([f("roxy-divisional-chart")],Ea);var Ke=require("lit"),op=require("lit/decorators.js");var ry={manglik:"Mangal Dosha",kalsarpa:"Kaal Sarp Dosha",sadhesati:"Sade Sati"},Da=class extends g{constructor(){super(...arguments);this.type="manglik"}renderData(e){let t=!!e.present,r=ry[this.type]??this.type,s=(e.severity??"").toLowerCase(),i=s==="severe"?3:s==="moderate"?2:s==="mild"?1:0,o=i*33;return Ke.html`<article class="card" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="${`badge roxy-chip ${t?"present":"absent"}`}" data-tone="${t?"danger":"success"}">${t?this.t("Present"):this.t("Absent")} </span>${ve(this.effectiveLang(),e.frame,this.translator)}</header>${"type"in e&&e.type?Ke.html`<p class="subtype"><span class="subtype-label roxy-label">${this.type==="sadhesati"?this.t("Current phase"):this.t("Type")}</span>${e.type}</p>`:Ke.nothing} ${e.severity?Ke.html`<div class="severity-bar" part="details" role="meter" aria-valuemin="0" aria-valuemax="3" aria-valuenow="${i}" aria-label="${this.t("Severity")} ${e.severity}"><span class="severity-fill" data-tier="${i}" style="width:${o}%"></span></div>`:Ke.nothing} ${e.description&&!this.hideReadings?Ke.html`<p class="description">${e.description}</p>`:Ke.nothing} ${this.renderEffects(e)} ${e.remedies&&e.remedies.length>0&&!this.hideReadings?Ke.html`<div part="section remedies"><h3>${this.t("Remedies")}</h3><ul>${e.remedies.map(l=>Ke.html`<li>${l}</li>`)}</ul></div>`:Ke.nothing} ${"exceptions"in e&&e.exceptions&&e.exceptions.length>0&&!this.hideReadings?Ke.html`<div part="section exceptions"><h3>${this.t("Exceptions")}</h3><ul>${e.exceptions.map(l=>Ke.html`<li>${l}</li>`)}</ul></div>`:Ke.nothing}</article>`}renderEffects(e){if(!e.effects||this.hideReadings)return Ke.nothing;let t=[];for(let[r,s]of Object.entries(e.effects))if(typeof s=="string"&&s.length>0)t.push(Ke.html`<div><h3>${r}</h3><p>${s}</p></div>`);else if(s&&typeof s=="object")for(let[i,o]of Object.entries(s))typeof o=="string"&&o.length>0&&t.push(Ke.html`<div><h3>${i}</h3><p>${o}</p></div>`);return t.length===0?Ke.nothing:Ke.html`<div class="effects" part="section effects">${t}</div>`}};Da.endpoints=hl,Da.styles=[u,ae,Ke.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}h2{text-transform:capitalize}.subtype{font-size:var(--roxy-text-sm)}.subtype-label{margin-inline-end:var(--roxy-space-sm)}.badge{font-weight:var(--roxy-weight-bold)}.severity-bar{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.35lh;inline-size:100%;overflow:hidden}.severity-fill{background:var(--roxy-warning);block-size:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.severity-fill[data-tier="3"]{background:var(--roxy-danger)}@media (prefers-reduced-motion:reduce){.severity-fill{transition:none}}h3{margin-block-end:var(--roxy-space-xs)}ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}.effects{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.effects p{font-size:var(--roxy-text-sm)}`],m([(0,op.property)({type:String,reflect:true})],Da.prototype,"type",2),Da=m([f("roxy-dosha-card")],Da);var re=require("lit");var sy=/^\d+(?:[.,]\d+)*(?:\s*-\s*\d+(?:[.,]\d+)*)?$/;function Ks(n){if(!n.text)return"";let a=n.chapter==null?"":String(n.chapter),e=n.verse??"",t=a;e&&(t=a?sy.test(e.trim())?`${a}.${e}`:`${a}, ${e}`:e);let r=n.translation?[n.translation,n.year].filter(Boolean).join(" "):"";return[[D(n.text),t].filter(Boolean).join(" "),r,n.basis].filter(Boolean).join(" \xB7 ")}var lp=require("lit"),xr=lp.css`.row{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);display:grid}@container (width<=30rem){.row{grid-template-columns:minmax(0,1fr)}}`;var ny=["vata","pitta","kapha"],iy={"lagna-sign":"Lagna","moon-sign":"Moon sign","strongest-planet":"Strongest graha"};function oy(n){return n.split("-").map(V).join("-")}function ly(n,a){return nt(n,(a??"").split(" ").filter(Boolean).map(V))}var br=class extends g{renderData(a){let e=this.effectiveLang(),t=a.composite;return re.html`<article class="card" part="card" aria-labelledby="dosha-title"><header class="head" part="header"><h2 id="dosha-title">${this.t("Ayurvedic constitution")}</h2>${t?.type?re.html`<span class="type">${oy(t.type)}</span>`:re.nothing}</header>${this.renderBar(e,a)}<div class="facts" part="details">${t?.dominant?re.html`<span><span class="roxy-label">${this.t("Dominant")}</span><b>${V(t.dominant)}</b></span>`:re.nothing} ${t?.secondary?re.html`<span><span class="roxy-label">${this.t("Secondary")}</span><b>${V(t.secondary)}</b></span>`:re.nothing} ${a.lagnaSign?re.html`<span><span class="roxy-label">${this.t("Lagna")}</span><b>${V(a.lagnaSign)}</b></span>`:re.nothing} ${a.moonSign?re.html`<span><span class="roxy-label">${this.t("Moon sign")}</span><b>${V(a.moonSign)}</b></span>`:re.nothing}</div>${this.renderFactors(e,a.factors)} ${this.renderRanking(e,a.strengthRanking)} ${this.renderPlanetDoshas(a.planetDoshas)} ${a.summary&&!this.hideReadings?re.html`<p class="summary" part="section readings">${a.summary}</p>`:re.nothing} ${ve(e,a.frame,this.translator)} ${a.meta?.disclaimer?re.html`<p class="disclaimer" part="disclaimer">${a.meta.disclaimer}</p>`:re.nothing}</article>`}renderBar(a,e){let t=e.composite,r=ny.map(i=>({humour:i,value:t?.[i]??0}));return r.reduce((i,o)=>i+o.value,0)<=0?re.nothing:re.html`<div part="chart"><div class="bar" role="img" aria-label="${r.map(i=>`${V(i.humour)} ${Oe(a,i.value,0)}`).join(", ")}">${r.filter(i=>i.value>0).map(i=>re.html`<div class="${`seg seg-${i.humour}`}" style="${`flex: ${i.value} 0 0`}"></div>`)}</div><p class="shares">${r.map(i=>re.html`<span><span class="${`swatch seg-${i.humour}`}"></span>${V(i.humour)} <b>${Oe(a,i.value,0)}</b></span>`)}</p></div>`}renderFactors(a,e){let t=e??[];return t.length===0?re.nothing:re.html`<section part="section factors"><h3>${this.t("Factors")}</h3><ul class="rows">${t.map(r=>re.html`<li class="row" part="label-track"><span class="roxy-label">${this.factorLabel(r.id)}</span><div><span>${ly(a,r.input)}</span> ${r.doshas?.length?re.html`· ${r.doshas.map(s=>V(s)).join(", ")}`:re.nothing} ${typeof r.weight=="number"?re.html`· <span class="roxy-label">${this.t("Weight")}</span>${b(a,r.weight,2)}`:re.nothing} ${this.renderCitation(r.source)}</div></li>`)}</ul></section>`}factorLabel(a){let e=iy[a??""];return e?this.t(e):D(a??"")}renderCitation(a){let e=Ks(a??{});return e?re.html`<div class="cite"><p><span class="roxy-label">${this.t("Source")}</span>${e}</p>${a?.note?re.html`<details class="note"><summary>${this.t("Note on the source")}${he()}</summary><p>${a.note}</p></details>`:re.nothing}</div>`:re.nothing}renderRanking(a,e){let t=e??[];return t.length===0?re.nothing:re.html`<section part="section ranking"><h3>${this.t("Shadbala")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Shadbala")}"><table><thead><tr><th>${this.t("Rank")}</th><th>${this.t("Graha")}</th><th>${this.t("Strength")}</th><th>${this.t("Strong")}</th></tr></thead><tbody>${t.map(r=>re.html`<tr class="${r.strong?"is-strong":""}"><td>${U(a,r.rank)}</td><td>${r.graha??""}</td><td>${this.t("{{value}} virupas",{value:b(a,r.totalVirupas,2)})}</td><td>${r.strong?this.t("Yes"):this.t("No")}</td></tr>`)}</tbody></table></div></section>`}renderPlanetDoshas(a){let e=a??[];return e.length===0?re.nothing:re.html`<section part="section planet-humours"><h3>${this.t("Planetary humours")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Planetary humours")}"><table><thead><tr><th>${this.t("Graha")}</th><th>${this.t("Humours")}</th><th>${this.t("Dhatu")}</th></tr></thead><tbody>${e.map(t=>re.html`<tr><td>${t.graha??""}</td><td>${(t.doshas??[]).map(r=>V(r)).join(", ")}</td><td>${[t.dhatu,t.dhatuSanskrit].filter(Boolean).join(" \xB7 ")}</td></tr>`)}</tbody></table></div>${this.renderTableSources(e)}</section>`}renderTableSources(a){let e=new Set;for(let t of a)for(let r of[t.doshaSource,t.dhatuSource]){let s=Ks(r??{});s&&e.add(s)}return e.size===0?re.nothing:re.html`<p class="cite"><span class="roxy-label">${this.t("Source")}</span>${[...e].join(" \xB7 ")}</p>`}};br.endpoints=ml,br.styles=[u,ae,W,xr,re.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.type{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold)}.bar{width:100%;min-width:0;border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);block-size:1lh;display:flex;overflow:hidden}.seg{min-width:0}.seg-vata{background:color-mix(in srgb, var(--roxy-info) 45%, var(--roxy-surface))}.seg-pitta{background:color-mix(in srgb, var(--roxy-danger) 45%, var(--roxy-surface))}.seg-kapha{background:color-mix(in srgb, var(--roxy-success) 45%, var(--roxy-surface))}.shares,.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.swatch{block-size:.5lh;inline-size:.5lh;border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.shares b,.facts b{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.facts .roxy-label,.row>div .roxy-label,.cite .roxy-label{margin-inline-end:var(--roxy-space-xs)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.cite{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2)}.cite .roxy-label{font-size:inherit}.cite .note summary{align-items:center;gap:var(--roxy-space-xs);width:fit-content;color:var(--roxy-secondary);display:flex}.cite .note p{margin-block-start:calc(var(--roxy-space-unit) / 2)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}tr.is-strong td{font-weight:var(--roxy-weight-bold)}.summary{font-size:var(--roxy-text-sm)}.disclaimer{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);padding-inline-start:var(--roxy-space-md)}`],br=m([f("roxy-dosha-constitution")],br);var Qt=require("lit");var vr=class extends g{renderData(a){return Qt.html`<article class="card" part="card" aria-label="${a.name??this.t("Dream symbol")}"><header class="head" part="header">${a.letter?Qt.html`<span class="letter" aria-hidden="true">${a.letter}</span>`:Qt.nothing}<div><p class="roxy-label">${this.t("Dream symbol")}</p>${a.name?Qt.html`<h2>${a.name}</h2>`:Qt.nothing}</div></header>${a.meaning?Qt.html`<p>${a.meaning}</p>`:Qt.nothing}</article>`}};vr.endpoints=gl,vr.styles=[u,Qt.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);display:flex}.letter{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:2lh;inline-size:2lh;color:var(--roxy-accent-ink);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);text-transform:uppercase;flex:none;justify-content:center;align-items:center;display:inline-flex}`],vr=m([f("roxy-dream-card")],vr);var ha=require("lit");var Lr=class extends g{constructor(){super(...arguments);this.rowDetail={tag:"roxy-dream-card",path:"dreams/symbols/{id}"};this.listKey="symbols"}renderData(e){let t=e.symbols??[];if(t.length===0)return this.renderEmpty();let r=typeof e.total=="number"?e.total:t.length;return ha.html`<section class="wrap" part="card" aria-label="${this.t("Dream symbols")}"><header class="head" part="header"><h2>${this.t("Dream symbols")}</h2><span class="count">${r===1?this.t("1 symbol"):this.t("{{count}} symbols",{count:r})}</span></header><ul class="grid" part="section symbols">${t.map(s=>ha.html`<li><button type="button" class="result" aria-pressed="${this.openedRowId===s.id?"true":"false"}" @click="${()=>this.pickRow({id:s.id,name:s.name,letter:s.letter})}">${s.letter?ha.html`<span class="letter" aria-hidden="true">${s.letter}</span>`:ha.nothing} <span class="name">${s.name}</span></button></li>`)}</ul>${this.renderMore()} ${this.openedRow?ha.html`<div class="detail" part="detail">${this.openedRow}</div>`:ha.nothing}</section>`}};Lr.endpoints=yl,Lr.styles=[u,ha.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fill,minmax(min(100%,16ch),1fr));margin:0;padding:0;list-style:none;display:grid}.result{align-items:center;gap:var(--roxy-space-sm);width:100%;padding:var(--roxy-space-sm) var(--roxy-space-md);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;display:flex}.result[aria-pressed=true],.result:hover{border-color:var(--roxy-accent)}.result[aria-pressed=true] .name{color:var(--roxy-accent-ink)}.detail{margin-block-start:var(--roxy-space-md)}.letter{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);text-transform:uppercase;flex:none}.name{font-size:var(--roxy-text-sm)}`],Lr=m([f("roxy-dream-search")],Lr);var z=require("lit"),Ge=require("lit/decorators.js"),ea=require("lit/directives/if-defined.js"),Ap=require("lit/directives/live.js");var Aa={accent:"Accent color",afterSunset:"Born after sunset",allowDuplicates:"Allow duplicate cards",allowReversals:"Allow reversed cards",angelDating:"How the name of the day is dated",annualFromYear:"Annual pillars from year",annualYears:"Years of annual pillars",approximateDate:"Approximate date",aspectTypes:"Aspect types",atbashOutput:"AtBash and Albam output",avasthaInfo:"Include avastha details",avoidAnimal:"Avoid clashes with",ayadiText:"Ayadi text family",ayanamsaValue:"Custom ayanamsa value",birthData:"Birth details",birthDate:"Birth date",birthLatitude:"Birth latitude",birthLongitude:"Birth longitude",birthTime:"Birth time",ciphers:"Ciphers to return",colors:"Brand colors",context:"Where you saw it",coordinateSystem:"Coordinate system",correlation:"Correlation constant",count:"How many",currentYear:"Current year",cuts:"Cut corners",dasha:"Dasha lords",datetime:"Date and time",dayBoundary:"Day boundary",depth:"Depth, north to south",directionScheme:"Direction reading",division:"Divisional chart",domainWeights:"Domain weights",door:"Door coordinates",doorPosition:"Door position along the side",doshaClock:"How the dosha periods are cut",endDate:"End date",endDatetime:"End date and time",expression:"Expression number",extensions:"Extended corners",facing:"Facing direction",facingDegrees:"Facing degrees",family:"Yoga family",firstName:"First name",firstNameHebrew:"First name in Hebrew",font:"Typeface",footer:"Footer line",fullName:"Full name",gainHouses:"Gain houses",grid:"Mandala grid",hastaInches:"Length of one hasta in inches",horaryNumber:"Horary number",hourClock:"Hour clock",houseSystem:"House system",id:"ID",include:"Additional bodies",includeMatches:"Include equal value matches",interpretation:"Position meaning",intervalMinutes:"Interval in minutes",isLeapMonth:"Leap month",iso2:"Country code",kua:"Kua number",lang:"Language",latinCiphers:"Also score the Latin ciphers",leapDayPolicy:"Where 29 February falls",letter:"Starting letter",letterAttribution:"Letter attribution reading",lifePath:"Life Path number",limit:"Results per page",lines:"Line pattern",logo:"Logo URL",lossHouses:"Loss houses",lunarDay:"Lunar day",lunarMonth:"Lunar month",lunarYear:"Lunar year",members:"Group members",minSignificance:"Minimum significance",minStrength:"Minimum strength",misparGadol:"Mispar gadol method",modernPlanets:"Include modern planets",moonWindows:"Moon windows",muhurtaText:"Muhurta text",nameHebrew:"Name in Hebrew",natalChart:"Natal chart",nodeType:"Lunar node type",offset:"Results to skip",polygon:"Outline",positions:"Spread positions",primary:"Primary color",q:"Search",question:"Your question",readings:"Include readings",relocationLatitude:"Relocation latitude",relocationLongitude:"Relocation longitude",returnDate:"Return date",returnYear:"Return year",ritucharyaScheme:"Season division",rituZodiac:"Zodiac the season boundaries are measured in",road:"Road side",rulingPlanets:"Ruling planets",scheme:"Karaka scheme",secondName:"Second name",secondNameHebrew:"Second name in Hebrew",sephirotSystem:"Sephirot reading",sign:"Zodiac sign",sign1:"First animal sign",sign2:"Second animal sign",signDoshaScheme:"Sign humour table",significators:"Include KP significators",size:"Paper size",slopeLowDirection:"Direction the ground falls toward",slopeSchool:"Ground level school",soulUrge:"Soul Urge number",spreadName:"Spread name",startDate:"Start date",startDatetime:"Start date and time",strictOrbs:"Use tighter orbs",system:"Avastha system",targetDate:"Target date",targetMonth:"Target month",text:"Word or name",textHebrew:"Hebrew word or name",top:"Top events per window",transitDate:"Transit date",transitTime:"Transit time",transliteration:"Transliteration scheme",treeVariant:"Tree arrangement",type:"Pattern type",vyayaFormula:"Vyaya formula",water:"Standing water direction",weights:"Layer weights",width:"Width, east to west",x:"Distance east",y:"Distance north",yearBearerSystem:"Year Bearer school",yearBoundary:"Year boundary",yearStart:"Wheel year start",zodiac:"Zodiac sign"};var cp={"GET /angel-numbers/numbers/{number}":{number:{path:"/angel-numbers/numbers",limit:50,lang:true}},"GET /astrology/planet-meanings/{id}":{id:{path:"/astrology/planet-meanings",lang:true}},"GET /astrology/signs/{id}":{id:{path:"/astrology/signs",lang:true}},"GET /crystals":{color:{path:"/crystals/colors",lang:true},planet:{path:"/crystals/planets",lang:true}},"GET /crystals/{id}":{id:{path:"/crystals",limit:100,lang:true}},"GET /dreams/symbols":{letter:{path:"/dreams/symbols/letters"}},"GET /dreams/symbols/{id}":{id:{path:"/dreams/symbols",search:"q",limit:50}},"GET /iching/trigrams/{id}":{id:{path:"/iching/trigrams",lang:true}},"GET /tarot/cards/{id}":{id:{path:"/tarot/cards",limit:100,lang:true}}},dp={"GET /tarot/cards":{suit:{field:"arcana",value:"major"}}};var Wt=(n,a)=>`${n}.${a}`;function Vn(n){let a=/^(.+)\.(\d+)$/.exec(n);return a?{key:a[1],index:Number(a[2])}:null}function Un(n,a=Di,e=t=>Aa[t]??D(t)){let t=Vn(n);return t?a("{{group}} {{n}}",{group:e(t.key),n:t.index+1}):a(D(n))}function hp(n,a){let e=a.key??a.name;if(gp(e))return xs(n,e);if(!a.label)return xs(n,a.name);let t=Object.keys(Aa).find(r=>Aa[r]===a.label);return Ai(n,a.label)??(t?xs(n,t):void 0)}function mp(n,a,e){let t=Wt(a,0);return n.filter(r=>r.group===t).map(r=>({...r,key:`${Wt(a,e)}.${r.name}`,group:Wt(a,e)}))}function mo(n){return n.length<=(qn(n)?30:12)?"tiles":"select"}function qn(n){return n.every(a=>a.length<=2)}var cy=["format","branding","readings"],dy=["latitude","longitude","timezone"],pp=["latitude","longitude"];function gp(n){let a=n.match(/^(.+?)(Latitude|Longitude)$/);return a?{group:a[1],leaf:a[2].toLowerCase()}:null}var py=Ie.map(n=>n.toLowerCase());function $r(n,a){if(n){if("$ref"in n&&n.$ref){let e=n.$ref.split("/").pop();return e?a[e]:void 0}return n}}function yp(n){let a=n.anyOf??n.oneOf;return!a||a.length===0?n:a.find(e=>Array.isArray(e.enum))??a.find(e=>ho(e)&&ho(e)!=="null")??a[0]??n}function ho(n){if(typeof n.type=="string")return n.type;if(!Array.isArray(n.type))return;let a=n.type.filter(e=>e!=="null");return a.length===1?a[0]:void 0}function hy(n){let a=yp(n),e=ho(a);return Array.isArray(a.enum)?mo(a.enum):e==="boolean"?"toggle":a.format==="date"?"date":a.format==="time"?"time":a.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function up(n){if(n.length!==12)return false;let a=new Set(n.map(e=>e.toLowerCase()));return py.every(e=>a.has(e))}function Kn(n,a,e){let t=yp(a);return{key:e.key,name:n,group:e.group,inQuery:e.inQuery,kind:hy(a)??"text",required:e.required,description:t.description??a.description,enum:t.enum,min:t.minimum??t.exclusiveMinimum,max:t.maximum??t.exclusiveMaximum,default:a.default??t.default,example:a.example??t.example}}function po(n){return new Set([...n.required??[],...n["x-required-any-of"]?.[0]??[]])}function fp(n,a,e,t=n.requestBody?"POST":"GET"){let r=[],s=[],i=false,o,l=n.requestBody?.content?.["application/json"]?.schema,c=$r(l,a),d=c?.["x-required-any-of"],p=(n["x-request-cost"]??1)>1;if(c?.properties){let h=po(c);for(let[x,$]of Object.entries(c.properties)){if(p&&cy.includes(x))continue;let L=$r($,a)??{},C=L.type==="array"?$r(L.items,a):void 0;if(C?.type==="object"&&C.properties){let ne=Math.max(1,L.minItems??1),Ce=po(C);s.push({key:x,min:ne,max:L.maxItems??ne});for(let dt=0;dt<ne;dt++)for(let[St,sa]of Object.entries(C.properties)){let fa=$r(sa,a)??{};r.push(Kn(St,fa,{key:`${Wt(x,dt)}.${St}`,group:Wt(x,dt),required:h.has(x)&&Ce.has(St)}))}}else if(L.type==="object"&&L.properties){let ne=po(L);for(let[Ce,dt]of Object.entries(L.properties)){let St=$r(dt,a)??{};St.type==="array"&&$r(St.items,a)?.type==="object"||r.push(Kn(Ce,St,{key:`${x}.${Ce}`,group:x,required:h.has(x)&&ne.has(Ce)}))}}else{let ne=gp(x),Ce=Kn(ne?.leaf??x,L,{key:x,group:ne?.group,required:h.has(x)});ne&&(Ce.label=`${D(ne.group)} ${ne.leaf}`),r.push(Ce)}}}for(let h of n.parameters??[]){if(h.in!=="path"&&h.in!=="query")continue;if(h.name==="lang"&&h.in==="query"){i=true,o=$r(h.schema,a)?.enum?.filter(L=>typeof L=="string");continue}let x=$r(h.schema,a)??{},$=Kn(h.name,x,{key:h.name,required:!!h.required,inQuery:h.in==="query"});if(h.in==="path"&&$.enum&&/^(id|identifier|slug)$/i.test(Aa[$.name]??D($.name))){let L=/^([A-Za-z][A-Za-z -]*?)\s+(?:id|identifier|slug)\b/i.exec(h.description??$.description??"")?.[1]?.trim();L&&($.label=L)}r.push($)}for(let h of r)!h.group&&!h.label&&r.some(x=>x.group&&x.name===h.name)&&(h.label=my(h));return go({title:gy(n.summary,e),fields:r,hasLang:i,...o?.length?{langs:o}:{},...s.length>0?{repeats:s}:{},...d?{requiredAnyOf:d}:{}},t,e)}function my(n){let e=(Aa[n.name]??D(n.name)).toLowerCase().replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),t=new RegExp(`^(\\p{L}+) ${e}\\b`,"iu").exec(n.description??"")?.[1];return t?Aa[t.toLowerCase()+n.name.replace(/^./,r=>r.toUpperCase())]:void 0}function go(n,a,e){let t=`${a.toUpperCase()} /${e.replace(/^\//,"")}`,r=cp[t]??{},s=dp[t]??{},i=n.fields.map(h=>{let x={...h};return delete x.role,delete x.city,delete x.viewerZone,delete x.moment,delete x.fold,{...x,...r[h.key]&&{source:r[h.key]},...s[h.key]&&{disabledWhen:s[h.key]}}}),o=[...new Set(i.map(h=>h.group))].map(h=>h===void 0?{}:{key:h,label:Un(h)}),l=o.filter(h=>pp.every(x=>i.some($=>$.group===h.key&&$.name===x)));for(let[h,x]of l.entries()){let $=i.filter(C=>C.group===x.key),L=$.find(C=>C.name==="timezone")??(h===0?i.find(C=>!C.group&&C.name==="timezone"):void 0);x.location={fields:[...$.filter(C=>pp.includes(C.name)).map(C=>C.key),...L?[L.key]:[]],required:$.some(C=>dy.includes(C.name)&&C.required)}}for(let h of i)h.name==="seed"?h.role="seed":(h.name==="limit"||h.name==="offset")&&!h.required?h.role="hidden-default":l.some(x=>x.location?.fields.includes(h.key))?h.role="location":h.name==="timezone"&&(h.city=true,!h.group&&!h.required&&(h.viewerZone=true));let c=o.filter(h=>h.key!==void 0&&(h.location||i.some(x=>x.group===h.key&&x.required))),d=i.some(h=>!h.group&&!h.role&&h.required)||c.length>0||l.some(h=>h.key===void 0);for(let h of o)h.key!==void 0&&d&&!c.includes(h)&&(h.fold=true);let p=h=>c.length>0&&h.default===void 0&&(h.kind==="date"||h.kind==="time"||h.kind==="datetime");for(let h of i)h.group?o.find(x=>x.key===h.group)?.fold&&(h.fold=true):!h.role&&d&&!h.required?p(h)?h.moment=true:h.fold=true:!h.role&&!d&&h.default!==void 0&&(h.fold=true);return{...n,fields:i,groups:o,opensOnLoad:yy(n,a)}}function xp(n,a){let e=n.filter(t=>t.moment);return e.some(t=>t.kind==="time"||t.kind==="datetime")&&e.every(t=>a[t.key]===void 0||a[t.key]==="")}function gy(n,a){let e=n?.split(" - ")[0]?.trim();return e||D(a.split("/").pop()??"")}function yy(n,a){return a.toUpperCase()==="GET"&&!n.fields.some(e=>e.required)}function bp(n,a=[]){if(a.some(t=>t.name==="limit"||t.name==="offset"))return"Search";let e=n.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(e)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(e)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(e)?"Get reading":"Generate"}function vp(n,a){let e=rn(n,a);return e&&`${e}/schemas`}function Lp(n,a){let e=a.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${n.toLowerCase()}--${e}.json`}function uy(n){if(Array.isArray(n))return n;if(!n||typeof n!="object")return null;let a=Object.values(n),e=a.find(Array.isArray);return e||(a.find(r=>!!r&&typeof r=="object"&&Object.values(r).every(s=>typeof s=="number"))??null)}function yo(n,a="id"){let e=uy(n);if(!e)return[];if(!Array.isArray(e)){let r=Object.keys(e),s=r.length>0&&r.every(o=>/^[a-z]$/.test(o));return(s?[..."abcdefghijklmnopqrstuvwxyz"]:r).map(o=>({value:o,label:s?o.toUpperCase():o,disabled:!e[o]}))}let t=[];for(let r of e){if(typeof r=="string"){t.push({value:r,label:r});continue}if(!r||typeof r!="object")continue;let s=r,i=s.id??s[a]??s.number;if(i==null)continue;let o=String(i),l=s.name??s.english;t.push({value:o,label:typeof l=="string"?l:o})}return t}function $p(n){let a=n?.total;return typeof a=="number"?a:void 0}var Ht=require("lit"),Zn=require("lit/directives/if-defined.js");var wp=require("lit"),Yn=wp.css`.spinner{inset-inline-end:calc(var(--roxy-space-unit) * 3);border:var(--roxy-line-thick) solid var(--roxy-muted);border-radius:var(--roxy-radius-full);border-top-color:#0000;block-size:.6lh;inline-size:.6lh;animation:.7s linear infinite roxy-spin;position:absolute;top:50%;transform:translateY(-50%)}@keyframes roxy-spin{to{transform:translateY(-50%)rotate(360deg)}}@media (prefers-reduced-motion:reduce){.spinner{animation:none}}.results{z-index:50;top:calc(100% + var(--roxy-space-xs));padding:var(--roxy-space-xs);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);box-shadow:var(--roxy-shadow-md);max-block-size:15lh;animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing);margin:0;list-style:none;position:absolute;left:0;right:0;overflow-y:auto}.option{align-items:center;gap:var(--roxy-space-sm);inline-size:100%;min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-md);border-radius:var(--roxy-radius-sm);text-align:start;font-size:var(--roxy-text-sm);color:var(--roxy-fg);cursor:pointer;transition:background-color var(--roxy-motion-duration);background:0 0;border:0;display:flex}.option:hover,.option[aria-selected=true]{background:color-mix(in srgb, var(--roxy-accent) 10%, transparent)}.empty{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`;function Wn(n,a){let e,t=((...r)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=void 0,n(...r)},a)});return t.cancel=()=>{e&&(clearTimeout(e),e=void 0)},t}var fy=10,xy=10,uo=new Map;function kp(n,a,e={}){return{...n.limit?{limit:n.limit}:{},...n.lang&&a?{lang:a}:{},...e}}function xo(n,a,e,t){let r=JSON.stringify([n.submitUrl??n.baseUrl,a.path,e,t]),s=uo.get(r);return s||(s=by(n,a,e,t).catch(i=>{throw uo.delete(r),i}),uo.set(r,s)),s}async function by(n,a,e,t){let r=[];for(let s=0;s<xy;s++){let i=await Xa(n,{path:a.path,method:"GET",query:kp(a,t,r.length?{offset:r.length}:{})}),o=yo(i,e);r.push(...o);let l=$p(i);if(!a.limit||l===void 0||r.length>=l||!o.length)break}return r}var fo=n=>n.normalize("NFD").replace(/\p{M}/gu,"").toLowerCase(),Xn=class{constructor(a,e,t,r,s){this.host=a;this.source=e;this.field=t;this.context=r;this.onPick=s;this.query="";this.options=[];this.open=false;this.highlight=-1;this.loading=false;this.error=null;this.search=Wn(a2=>{this.searchServer(a2)},250);a.addController(this)}hostDisconnected(){this.search.cancel(),this.abort?.abort()}input(a){this.query=a,this.error=null,this.source.search?a.trim().length<2?this.close():this.search(a):this.filter(a),this.host.requestUpdate()}focus(){!this.source.search&&!this.open&&this.filter(this.query)}close(){this.open=false,this.highlight=-1,this.host.requestUpdate()}pick(a){this.query=a.label,this.close(),this.onPick(a)}keydown(a){let e=this.options.length;if(a.key==="Escape"){this.close();return}if(a.key==="ArrowDown"&&!this.open){a.preventDefault(),this.input(this.query);return}if(!(!this.open||e===0)){if(a.key==="ArrowDown")this.highlight=(this.highlight+1)%e;else if(a.key==="ArrowUp")this.highlight=(this.highlight-1+e)%e;else if(a.key==="Home")this.highlight=0;else if(a.key==="End")this.highlight=e-1;else if(a.key==="Enter"){let t=this.options[this.highlight]??this.options[0];t&&this.pick(t)}else return;a.preventDefault(),this.host.requestUpdate()}}async filter(a){let{route:e,lang:t}=this.context();this.loading=true,this.host.requestUpdate();try{let r=await xo(e,this.source,this.field,t);if(a!==this.query)return;let s=fo(a.trim());this.show(r.filter(i=>fo(i.label).includes(s)||fo(i.value).includes(s)))}catch(r){this.fail(r)}finally{this.loading=false,this.host.requestUpdate()}}async searchServer(a){let{route:e,lang:t}=this.context(),r=this.source.search;this.abort?.abort();let s=new AbortController;this.abort=s,this.loading=true,this.host.requestUpdate();try{let i=await Xa(e,{path:this.source.path,method:"GET",query:kp({...this.source,limit:fy},t,{[r]:a})},s.signal);if(s.signal.aborted)return;this.show(yo(i,this.field))}catch(i){if(s.signal.aborted)return;this.fail(i)}finally{this.abort===s&&(this.abort=void 0),s.signal.aborted||(this.loading=false,this.host.requestUpdate())}}show(a){this.options=a,this.open=true,this.highlight=a.length?0:-1}fail(a){this.options=[],this.open=false,this.error=a instanceof Error?a.message:String(a)}};function Sp(n,a,e,t={}){let r=`${a}-listbox`;return Ht.html`<div class="picker"><input id="${a}" type="text" role="combobox" aria-expanded="${n.open?"true":"false"}" aria-controls="${r}" aria-autocomplete="list" aria-labelledby="${(0,Zn.ifDefined)(t.labelledby)}" aria-describedby="${(0,Zn.ifDefined)(t.describedby)}" aria-invalid="${(0,Zn.ifDefined)(t.invalid?"true":void 0)}" aria-activedescendant="${n.open&&n.highlight>=0?`${a}-opt-${n.highlight}`:""}" autocomplete="off" placeholder="${e.placeholder}" .value="${n.query}" @input="${s=>n.input(s.target.value)}" @keydown="${s=>n.keydown(s)}" @focus="${()=>n.focus()}" @blur="${()=>n.close()}"> ${n.loading?Ht.html`<span class="spinner" role="status" aria-label="${e.loading}"></span>`:Ht.nothing} ${n.open?Ht.html`<ul id="${r}" class="results" role="listbox">${n.options.length===0?Ht.html`<li class="empty" role="status">${e.empty}</li>`:n.options.map((s,i)=>Ht.html`<li id="${`${a}-opt-${i}`}" class="option" role="option" aria-selected="${n.highlight===i?"true":"false"}" @mousedown="${o=>o.preventDefault()}" @click="${()=>n.pick(s)}">${s.label}</li>`)}</ul>`:Ht.nothing}</div>${n.error?Ht.html`<small class="field-error" role="alert">${n.error}</small>`:Ht.nothing}`}var Rp=[Yn,Ht.css`.picker{position:relative}`];var wy={};var Cp=`${$s}/openapi.json`,Tp=vp(fs,globalThis.document?.currentScript?.src||wy.url),bo=new Map,Jn=class extends Error{constructor(e){super(`HTTP ${e}`);this.status=e}},Qn=class extends Error{constructor(e,t){super(`Endpoint ${e} ${t} not found in OpenAPI spec`);this.method=e;this.path=t}};async function vy(n){let a=bo.get(n);return a||(a=fetch(n).then(async e=>{if(!e.ok)throw new Jn(e.status);return await e.json()}).catch(e=>{throw bo.delete(n),e}),bo.set(n,a)),a}function Ly(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}var Ep=n=>/\bbirth/i.test(n?.description??""),Dp=n=>n.key===`${n.group}.${n.name}`;function $y(n){let a=n.trim();if(!a)return[];try{let e=JSON.parse(a);if(Array.isArray(e))return e}catch{}return a.split(",").map(e=>e.trim()).filter(Boolean)}var De=class extends Za{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.serverIssues=null;this.autoload=false;this.fullPages=false;this.choices={};this.pickers=new Map;this.clearedIssues=new Set;this.fields=[];this.groups=[];this.modelOpensOnLoad=false;this.repeats=[];this.formTitle="";this.hasLang=false;this.values={};this.loaded=false;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=false,this.specError=null,this.loadSchema()};this.onSubmit=e=>{e.preventDefault(),this.submit()}}connectedCallback(){super.connectedCallback(),this.loadSchema()}async loadSchema(){this.specError=null;try{this.applyModel(await this.resolveModel())}catch(e){this.specError=this.specErrorMessage(e),this.loaded=true,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||Cp,message:e instanceof Error?e.message:String(e)},bubbles:true,composed:true}))}}specErrorMessage(e){return e instanceof Jn?this.t("HTTP error {{status}}",{status:e.status}):e instanceof Qn?this.t("Endpoint {{method}} {{path}} not found in OpenAPI spec",{method:e.method,path:e.path}):e instanceof Error?e.message:String(e)}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(Cp)}async modelFromSpec(e){let t=await vy(e),r=`/${this.endpoint.replace(/^\//,"")}`,s=t.paths?.[r]?.[this.method.toLowerCase()];if(!s)throw new Qn(this.method,r);return fp(s,t.components?.schemas??{},this.endpoint,this.method)}async tryLoadSlice(){if(!Tp)return null;try{let e=await fetch(`${Tp}/${Lp(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){(!e.groups||e.opensOnLoad===void 0)&&(e=go(e,this.method,this.endpoint)),this.fields=e.fields,this.groups=e.groups??[],this.modelOpensOnLoad=e.opensOnLoad??false,this.repeats=e.repeats??[],this.formTitle=e.title,this.hasLang=e.hasLang,this.langs=e.langs;let t={};for(let r of e.fields){let s=r.viewerZone?void 0:this.fullPages&&r.name==="limit"&&this.roleOf(r)==="hidden-default"?r.max??r.default:r.default;s!==void 0&&(t[r.key]=s);let i=r.group&&Dp(r)?this.initialValues?.[r.group]?.[r.name]:this.initialValues?.[r.key];i!==void 0&&(t[r.key]=i)}this.values=this.withoutDisabled(t),this.loaded=true,this.loadChoices(),this.autoload&&this.opensOnLoad&&Mi(this.route)&&this.updateComplete.then(()=>this.submit())}get route(){return this.apiRoute??{publishableKey:this.publishableKey}}loadChoices(){for(let t of this.pickers.values())this.removeController(t);if(this.pickers.clear(),!Mi(this.route))return;let e=()=>({route:this.route,lang:this.requestLang()});for(let t of this.fields)if(t.source){if(t.required){let r=new Xn(this,t.source,t.name,e,s=>this.pickChoice(t,s.value));r.query=String(this.values[t.key]??""),this.pickers.set(t.key,r);continue}this.choices={...this.choices,[t.key]:"loading"},xo(this.route,t.source,t.name,this.requestLang()).then(r=>{this.choices={...this.choices,[t.key]:r}},()=>{let{[t.key]:r,...s}=this.choices;this.choices=s})}}setValue(e,t){this.setValues({[e]:t})}setValues(e){this.values=this.withoutDisabled({...this.values,...e});let t=Object.keys(e).filter(r=>this.serverIssues?.some(s=>s.path===r));t.length&&(this.clearedIssues=new Set([...this.clearedIssues,...t]))}isDisabled(e,t=this.values){let r=e.disabledWhen;return!!r&&t[r.field]===r.value}withoutDisabled(e){for(let t of this.fields)this.isDisabled(t,e)&&(e[t.key]=void 0);return e}willUpdate(e){e.has("serverIssues")&&(this.clearedIssues=new Set);let t=e.has("publishableKey")?ts(this.publishableKey):void 0;t&&vs(this,t,{warn:true})}liveIssues(){return(this.serverIssues??[]).filter(e=>!this.clearedIssues.has(e.path))}issueFor(e){return this.liveIssues().find(t=>t.path===e.key)}cityIssues(e){return this.liveIssues().filter(t=>{let r=this.fields.find(s=>s.key===t.path);return!!r&&this.roleOf(r)==="location"&&this.cityGroup(r)===e})}issuesForGroup(e){return this.liveIssues().filter(t=>t.path===e)}fieldLabel(e){return this.roleOf(e)==="location"||e.city?this.locationLabel(this.cityGroup(e)):e.group?`${this.groupName(e.group)} ${this.fieldText(e)}`:this.fieldText(e)}issueLines(e){return e.map(t=>z.html`<small part="field-error" class="field-error" role="alert">${t.message}</small>`)}fieldIssue(e){let t=this.issueFor(e);return t?z.html`<small part="field-error" class="field-error" id="${`roxy-form-${e.key}-error`}" role="alert">${t.message}</small>`:z.nothing}renderIssueSummary(){let e=this.liveIssues();if(e.length===0)return z.nothing;let t=r=>{let s=this.fields.find(o=>o.key===r);if(s)return this.fieldLabel(s);let i=this.groupKeys().find(o=>o===r);return i?this.groupName(i):this.fieldText({name:r.split(".")[0]??r})};return z.html`<div part="validation-error" class="validation-error" role="alert">${e.map(r=>z.html`<div><strong>${t(r.path)}</strong> ${r.message}</div>`)}</div>`}roleOf(e){return e.role??"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){return this.groups.map(e=>e.key)}groupHasLocation(e){return!!this.groups.find(t=>t.key===e)?.location}cityGroup(e){return this.groups.find(t=>t.location?.fields.includes(e.key))?.key??e.group}placeField(e){let t=this.fields.filter(r=>r.group===e);return t.find(r=>r.name==="latitude")??t.find(r=>r.name==="timezone")}locationRequired(e){return this.groups.find(t=>t.key===e)?.location?.required??false}get soleChoice(){if(this.groupKeys().some(r=>this.groupHasLocation(r))||this.groupKeys().some(r=>r!==void 0))return null;let e=this.fields.filter(r=>r.required&&this.isRendered(r)),t=e[0];return e.length!==1||!t?null:t.kind==="tiles"||t.kind==="select"||this.pickers.has(t.key)?t:null}get opensOnLoad(){return this.modelOpensOnLoad}isFilter(e){return this.opensOnLoad&&!e.required&&!!(e.enum||e.source)}get selfSubmits(){if(this.soleChoice)return true;if(!this.opensOnLoad)return false;let e=this.fields.filter(t=>this.isRendered(t));return e.length>0&&e.every(t=>this.isFilter(t))}choiceKind(e){let t=this.choicesOf(e).map(r=>r.value);return this.isFilter(e)&&!qn(t)?"select":this.choices[e.key]?mo(t):e.kind}choicesOf(e){let t=this.choices[e.key];return Array.isArray(t)?t:(e.enum??[]).map(r=>({value:r,label:this.optionText(e.name,r)}))}effectiveSubmitLabel(){return this.submitLabel?this.submitLabel:xp(this.fields,this.values)?this.t("Show right now"):this.t(bp(this.endpoint,this.fields))}requestLang(e){return tn(this,e)}fieldText(e){let t=this.requestLang();return e.label?hp(t,e)??e.label:ke(t,e.name,Aa[e.name])}optionText(e,t){return ie(this.requestLang(),e,t)}onLocationFor(e){return t=>{let r=this.groups.find(i=>i.key===e)?.location?.fields??[],s={};for(let i of r){let o=this.fields.find(l=>l.key===i)?.name;o&&(s[i]=t[o])}this.setValues(s)}}chooseOption(e,t){if(this.isFilter(e)){this.setFilter(e,this.values[e.key]===t?"":t),this.submit();return}this.pickChoice(e,t)}pickChoice(e,t){this.setValue(e.key,t),this.resend()}resend(){let e=this.soleChoice;e&&this.values[e.key]&&this.submit()}setFilter(e,t){let r={[e.key]:t};for(let s of this.fields)s!==e&&(this.isFilter(s)||this.opensOnLoad&&s.kind==="text"&&this.isRendered(s))&&(r[s.key]=void 0);this.setValues(r)}onTilesKeyDown(e){return t=>{let r=this.choicesOf(e).filter(d=>!d.disabled).map(d=>d.value);if(r.length===0)return;let s=r.indexOf(this.values[e.key]),i;if(t.key==="Home")i=0;else if(t.key==="End")i=r.length-1;else if(t.key==="ArrowRight"||t.key==="ArrowDown")i=s===-1?0:(s+1)%r.length;else if(t.key==="ArrowLeft"||t.key==="ArrowUp")i=s===-1?r.length-1:(s-1+r.length)%r.length;else return;t.preventDefault();let o=r[i];if(o===void 0)return;this.chooseOption(e,o);let l=t.currentTarget,c=this.choicesOf(e).findIndex(d=>d.value===o);requestAnimationFrame(()=>l.querySelector(`[data-tile='${c}']`)?.focus())}}submit(){let e=this.collectMissing();if(e.keys.length>0){this.validationErrors=e.labels,this.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{missing:e.keys},bubbles:true,composed:true}));return}this.validationErrors=[],this.clearedIssues=new Set((this.serverIssues??[]).map(i=>i.path));let t={};for(let i of this.fields){let o=this.values[i.key];if(i.name==="seed"&&(o===void 0||o==="")&&(o=Ly()),i.viewerZone&&(o===void 0||o==="")&&(o=Yc()??i.default),o===void 0||o==="")continue;i.kind==="array"&&typeof o=="string"&&(o=$y(o));let l=i.group?Vn(i.group):null;if(l){let c=t[l.key]??[],d=c[l.index]??{};d[i.name]=o,c[l.index]=d,t[l.key]=c}else if(i.group&&Dp(i)){let c=t[i.group]??{};c[i.name]=o,t[i.group]=c}else t[i.key]=o}let r=this.fields.filter(i=>i.inQuery).map(i=>i.name),s=this.requestLang(this.langs);this.hasLang&&s&&(t.lang=s,r.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:t,queryKeys:r,sticky:this.soleChoice!=null||this.opensOnLoad},bubbles:true,composed:true}))}collectMissing(){let e=[],t=[],r=new Set;for(let s of this.fields){if(!s.required)continue;let i=this.roleOf(s)==="location";if(!this.isRendered(s)&&!i)continue;let o=this.values[s.key];if(!(o!==void 0&&o!=="")){if(e.push(s.key),i){r.add(this.cityGroup(s));continue}t.push(this.fieldLabel(s))}}for(let s of r)t.push(this.locationLabel(s));return{keys:e,labels:t}}get readsEnglish(){return mc(this.effectiveLang())}renderTitle(){return this.readsEnglish?z.html`<h2 part="title" class="title" id="roxy-form-title">${this.formTitle}</h2>`:z.nothing}reqMark(e){return e.required?z.html`<span class="req" aria-hidden="true">*</span>`:z.nothing}description(e){if(!e.description||!this.readsEnglish)return z.nothing;if(e.description.length<=120)return z.html`<small part="hint" class="help">${e.description}</small>`;let t=e.description.split(". ")[0]??e.description;return z.html`<details part="hint" class="help-details"><summary><span class="help-lead">${t}</span>${he()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let t=`roxy-form-${e.key}-label`,r=!!e.enum&&up(e.enum),s=this.choicesOf(e),i=qn(s.map(c=>c.value)),o=s.findIndex(c=>c.value===this.values[e.key]),l=o===-1?s.findIndex(c=>!c.disabled):o;return z.html`<div class="field tiles-field"><span class="label" id="${t}">${this.fieldText(e)}${this.reqMark(e)}</span><div class="${i?"tiles narrow":"tiles"}" role="radiogroup" aria-labelledby="${t}" @keydown="${this.onTilesKeyDown(e)}">${s.map((c,d)=>{let p=this.values[e.key]===c.value,h=r?Z(c.value):void 0;return z.html`<button type="button" class="tile" role="radio" data-tile="${d}" aria-checked="${p?"true":"false"}" tabindex="${d===l?"0":"-1"}" ?disabled="${!!c.disabled||this.isDisabled(e)}" @click="${()=>this.chooseOption(e,c.value)}">${h?z.html`<span class="tile-glyph" aria-hidden="true">${h}</span>`:z.nothing} <span class="tile-label">${c.label}</span></button>`})}</div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderSelect(e){let t=`roxy-form-${e.key}`;return z.html`<div part="field" class="field"><label for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label> <select id="${t}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${(0,ea.ifDefined)(this.issueFor(e)?"true":void 0)}" aria-describedby="${(0,ea.ifDefined)(this.issueFor(e)?`${t}-error`:void 0)}" .value="${(0,Ap.live)(this.values[e.key]??"")}" @change="${r=>this.chooseOption(e,r.target.value)}"><option value="">${this.t("Choose")}</option>${this.choicesOf(e).map(r=>z.html`<option value="${r.value}" ?selected="${this.values[e.key]===r.value}" ?disabled="${!!r.disabled}">${r.label}</option>`)}</select> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderPickerField(e,t){let r=`roxy-form-${e.key}`,s=this.soleChoice?.key===e.key&&this.readsEnglish,i=this.issueFor(e);return z.html`<div part="field" class="field">${s?z.nothing:z.html`<label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label>`} ${Sp(t,r,{placeholder:this.t("Type to search"),empty:this.t("{{count}} matches",{count:0}),loading:this.t("Loading")},{labelledby:s?"roxy-form-title":void 0,describedby:i?`${r}-error`:void 0,invalid:!!i})} ${this.fieldIssue(e)}</div>`}renderToggle(e){let t=`roxy-form-${e.key}`,r=this.values[e.key]===true;return z.html`<div part="field" class="field"><div class="toggle-row"><button type="button" id="${t}" class="toggle" role="switch" aria-checked="${r?"true":"false"}" @click="${()=>this.pickChoice(e,!r)}"><span class="knob"></span></button> <label class="toggle-label" for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label></div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderInput(e){let t=`roxy-form-${e.key}`,r=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,s=e.example!=null?String(e.example):"",i=e.kind==="array"?this.t("Comma separated"):this.readsEnglish||!/\p{L}/u.test(s)?s:"";return z.html`<div part="field" class="field"><label for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label> <input id="${t}" type="${e.kind==="array"?"text":r}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${(0,ea.ifDefined)(this.issueFor(e)?"true":void 0)}" aria-describedby="${(0,ea.ifDefined)(this.issueFor(e)?`${t}-error`:void 0)}" min="${(0,ea.ifDefined)(e.min)}" max="${(0,ea.ifDefined)(e.max)}" step="${e.kind==="number"?"any":z.nothing}" placeholder="${i||z.nothing}" .value="${this.values[e.key]??""}" @input="${o=>{let l=this.coerce(e.kind,o.target.value);this.opensOnLoad&&e.kind==="text"?this.setFilter(e,l):this.setValue(e.key,l)}}" @change="${()=>this.resend()}"> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderField(e){if(e.city)return this.renderTimezoneCity(e);let t=this.pickers.get(e.key);if(t)return this.renderPickerField(e,t);let r=this.choices[e.key];return r==="loading"?z.html`<div class="field"><div class="roxy-skeleton field-skeleton" aria-label="${this.t("Loading")}" role="status"></div></div>`:r||e.kind==="tiles"||e.kind==="select"?this.choiceKind(e)==="tiles"?this.renderTiles(e):this.renderSelect(e):e.kind==="toggle"?this.renderToggle(e):this.renderInput(e)}groupName(e){return Un(e,(t,r)=>this.t(t,r),t=>this.fieldText({name:t}))}repeatCount(e){return new Set(this.fields.map(t=>t.group&&Vn(t.group)).filter(t=>t&&t.key===e).map(t=>t.index)).size}addRecord(e){let t=this.repeatCount(e),r=mp(this.fields,e,t),s=this.groups.find(o=>o.key===Wt(e,0));if(s){let o=l=>l.replace(`${Wt(e,0)}.`,`${Wt(e,t)}.`);this.groups=[...this.groups,{...s,key:Wt(e,t),label:Un(Wt(e,t)),...s.location&&{location:{...s.location,fields:s.location.fields.map(o)}}}]}let i={...this.values};for(let o of r)o.default!==void 0&&(i[o.key]=o.default);this.values=i,this.fields=[...this.fields,...r]}removeRecord(e){let t=Wt(e,this.repeatCount(e)-1);this.fields=this.fields.filter(s=>s.group!==t),this.groups=this.groups.filter(s=>s.key!==t);let r={...this.values};for(let s of Object.keys(r))s.startsWith(`${t}.`)&&delete r[s];this.values=r}repeatControls(e){let t=this.repeatCount(e.key);return e.max<=e.min?z.nothing:z.html`<div class="repeat-controls">${t<e.max?z.html`<button type="button" class="repeat-btn" @click="${()=>this.addRecord(e.key)}"><span aria-hidden="true">+</span> ${this.t("Add")}</button>`:z.nothing} ${t>e.min?z.html`<button type="button" class="repeat-btn" @click="${()=>this.removeRecord(e.key)}"><span aria-hidden="true">−</span> ${this.t("Remove")}</button>`:z.nothing}</div>`}locationLabel(e){return e?this.t("{{group}} location",{group:this.groupName(e)}):Ep(this.placeField(e))?this.t("Birth location"):this.t("Location")}locationBlock(e){return z.html`<div class="location-block"><label>${this.locationLabel(e)}${this.locationRequired(e)?z.html`<span class="req" aria-hidden="true">*</span>`:z.nothing}</label> ${this.citySearch(e,this.onLocationFor(e))} ${this.issueLines(this.cityIssues(e))}</div>`}renderTimezoneCity(e){return z.html`<div part="field" class="field location-block"><label>${this.locationLabel(e.group)}${this.reqMark(e)}</label> ${this.citySearch(e.group,t=>this.pickChoice(e,t.timezone))} ${this.fieldIssue(e)}</div>`}citySearch(e,t){let r=e?this.t("{{group}} city",{group:this.groupName(e)}):Ep(this.placeField(e))?this.t("City of birth"):void 0;return z.html`<roxy-location-search endpoint="${(0,ea.ifDefined)(this.locationUrl||void 0)}" publishable-key="${(0,ea.ifDefined)(this.publishableKey)}" .submitUrl="${this.route.submitUrl}" .submitContext="${this.route.submitContext}" lang="${(0,ea.ifDefined)(this.effectiveLang())}" placeholder="${(0,ea.ifDefined)(r)}" @roxy-location-select="${s=>t(s.detail)}"></roxy-location-search><small class="help">${this.t("Type a city, then pick it from the list.")}</small>`}groupCard(e){let t=this.fields.filter(r=>r.group===e&&this.isRendered(r));return z.html`<fieldset part="group" class="person-group"><legend>${this.groupName(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):z.nothing}<div class="fields">${t.map(r=>this.renderField(r))}</div>${this.issueLines(this.issuesForGroup(e))}</fieldset>`}render(){return z.html`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){if(!this.loaded)return z.html`<form><div class="roxy-skeleton form-skeleton"></div></form>`;if(this.specError)return z.html`<div class="roxy-error" role="alert">${this.t("Schema load failed: {{message}}",{message:this.specError})} <button type="button" class="submit" @click="${this.retryLoadSchema}">${this.t("Retry")}</button></div>`;let e=ts(this.publishableKey);if(e)return z.html`<form>${this.renderTitle()}<div part="validation-error" class="validation-error" role="alert">${this.t(e.message)}</div></form>`;let t=this.fields.filter(d=>!d.group&&this.isRendered(d)),r=this.groupKeys().filter(d=>d!==void 0),s=t.filter(d=>!d.fold),i=t.filter(d=>d.fold),o=r.filter(d=>!this.groups.find(p=>p.key===d)?.fold),l=r.filter(d=>this.groups.find(p=>p.key===d)?.fold),c=i.length>0||l.length>0;return z.html`<form @submit="${this.onSubmit}">${this.renderTitle()} ${this.validationErrors.length>0?z.html`<div part="validation-error" class="validation-error" role="alert"><strong>${this.t("Please complete:")}</strong> ${this.validationErrors.join(", ")}</div>`:z.nothing} ${this.renderIssueSummary()}<div class="fields">${s.map(d=>this.renderField(d))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):z.nothing} ${o.map(d=>this.groupCard(d))} ${this.repeats.map(d=>this.repeatControls(d))} ${c?z.html`<details part="advanced" class="advanced" ?open="${this.liveIssues().some(d=>[...i.map(p=>p.key),...l].some(p=>d.path===p||d.path.startsWith(`${p}.`)))}"><summary>${this.t("Advanced")}${he()}</summary><div class="fields">${i.map(d=>this.renderField(d))}</div>${l.map(d=>this.groupCard(d))}</details>`:z.nothing} ${this.selfSubmits?z.nothing:z.html`<button part="submit" class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,t){if(t!==""){if(e==="number"){let r=Number(t);return Number.isFinite(r)?r:void 0}return t}}};De.styles=[u,W,Rp,z.css`form{gap:var(--roxy-space-md);background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);padding:var(--roxy-space-lg);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{margin:0}.fields{align-items:start;gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(22ch,1fr));display:grid}.fields:empty{display:none}.person-group{gap:var(--roxy-space-md);min-inline-size:0;padding:var(--roxy-space-md) 0 0;border:0;border-block-start:1px solid var(--roxy-border);margin:0;display:grid}.person-group legend{float:inline-start;color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);padding:0}.field{gap:var(--roxy-space-xs);flex-direction:column;min-inline-size:0;display:flex}.fields>*{min-inline-size:0}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm);color:var(--roxy-secondary)}.req{color:var(--roxy-danger-fg);margin-inline-start:var(--roxy-space-xs)}input,select{inline-size:100%;min-inline-size:0;min-block-size:var(--roxy-touch)}.help{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.field-error{color:var(--roxy-danger-fg);font-size:var(--roxy-text-xs)}input[aria-invalid=true],select[aria-invalid=true]{border-color:var(--roxy-danger)}input:disabled,select:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.help-details>summary{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-block-start:var(--roxy-space-xs);display:block}.location-block{gap:var(--roxy-space-xs);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(10ch,1fr));display:grid}.tiles.narrow{gap:var(--roxy-space-xs);grid-template-columns:repeat(auto-fill,minmax(4ch,1fr))}.tile{justify-content:center;align-items:center;gap:calc(var(--roxy-space-unit) / 2);min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-size:var(--roxy-text-sm);cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing), background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-direction:column;display:flex}.tile:hover:not(:disabled){border-color:var(--roxy-accent)}.tile:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.tile[aria-checked=true]{border-color:var(--roxy-accent);background:color-mix(in srgb, var(--roxy-accent) 12%, transparent);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.tile-glyph{font-size:var(--roxy-text-lg);line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm);display:flex}.toggle{box-sizing:content-box;block-size:.8lh;inline-size:1.6lh;padding:calc(var(--roxy-space-unit) / 2);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);background:var(--roxy-border);cursor:pointer;transition:background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0;display:inline-flex}.toggle[aria-checked=true]{background:var(--roxy-accent);border-color:var(--roxy-accent)}.toggle .knob{border-radius:var(--roxy-radius-full);background:var(--roxy-bg);block-size:.8lh;inline-size:.8lh;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.toggle[aria-checked=true] .knob{transform:translate(100%)}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.advanced>summary{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);display:flex}.advanced[open]>summary{margin-block-end:var(--roxy-space-md)}.repeat-controls{gap:var(--roxy-space-sm);display:flex}.repeat-btn{color:var(--roxy-accent-ink);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);cursor:pointer;background:0 0}.repeat-btn:hover{border-color:var(--roxy-accent-ink)}.advanced .fields,.advanced .person-group{margin-block-start:var(--roxy-space-md)}.validation-error{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm);display:grid}button.submit{min-block-size:var(--roxy-touch);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-sm) var(--roxy-space-lg);font-weight:var(--roxy-weight-bold);cursor:pointer;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.field-skeleton{block-size:var(--roxy-touch)}.form-skeleton{block-size:5lh}`],m([(0,Ge.property)({type:String,attribute:"data-endpoint"})],De.prototype,"endpoint",2),m([(0,Ge.property)({type:String})],De.prototype,"method",2),m([(0,Ge.property)({type:String,attribute:"spec-url"})],De.prototype,"specUrl",2),m([(0,Ge.property)({type:String,attribute:"submit-label"})],De.prototype,"submitLabel",2),m([(0,Ge.property)({type:String,attribute:"publishable-key"})],De.prototype,"publishableKey",2),m([(0,Ge.property)({type:String,attribute:"location-url"})],De.prototype,"locationUrl",2),m([(0,Ge.property)({attribute:false})],De.prototype,"initialValues",2),m([(0,Ge.property)({attribute:false})],De.prototype,"serverIssues",2),m([(0,Ge.property)({attribute:false})],De.prototype,"apiRoute",2),m([(0,Ge.property)({attribute:false})],De.prototype,"autoload",2),m([(0,Ge.property)({attribute:false})],De.prototype,"fullPages",2),m([(0,Ge.state)()],De.prototype,"choices",2),m([(0,Ge.state)()],De.prototype,"clearedIssues",2),m([(0,Ge.state)()],De.prototype,"fields",2),m([(0,Ge.state)()],De.prototype,"repeats",2),m([(0,Ge.state)()],De.prototype,"formTitle",2),m([(0,Ge.state)()],De.prototype,"hasLang",2),m([(0,Ge.state)()],De.prototype,"values",2),m([(0,Ge.state)()],De.prototype,"loaded",2),m([(0,Ge.state)()],De.prototype,"specError",2),m([(0,Ge.state)()],De.prototype,"validationErrors",2),De=m([f("roxy-endpoint-form")],De);var Ae=require("lit"),Pp=require("lit/decorators.js");var ky="12:00 UTC",Pa=class extends g{constructor(){super(...arguments);this.heading="Ephemeris"}renderData(e){if(!e.days?.length)return this.renderEmpty();let t=this.toViewModel(e),r=this.effectiveLang();return Ae.html`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2><p class="month roxy-label"><span>${ws(r,t.year,t.month)}</span><span>${ky}</span></p></header>${this.renderSignKey(t.signs)}<section part="section changes"><h3>${this.t("Sign changes and retrograde periods")}</h3><div role="list">${t.bodies.map(s=>this.renderTrack(s))}</div></section><section part="section daily"><h3>${this.t("Daily positions")}</h3><div class="scroll" part="table" tabindex="0" aria-label="${this.t("Daily positions")}">${this.renderGrid(t)}</div></section></div>`}renderSignKey(e){return e.length===0?Ae.nothing:Ae.html`<section part="section legend"><h3>${this.t("Signs in this month")}</h3><ul class="signkey" role="list">${e.map(t=>Ae.html`<li class="signkey-item"><span class="signkey-glyph" aria-hidden="true">${t.glyph}</span>${t.label}</li>`)}</ul></section>`}renderTrack(e){let t=S(e.name);return Ae.html`<div class="track" role="listitem"><span class="body-name">${t?Ae.html`<span class="glyph" aria-hidden="true">${t}</span>`:Ae.nothing}${e.label} </span><span class="span">${this.renderPosition(e.first)}<span class="arrow" aria-hidden="true">→</span>${this.renderPosition(e.last)} </span>${e.ingresses.length||e.retrogrades.length?Ae.html`<span class="chips roxy-chips">${e.ingresses.map(r=>this.renderIngressChip(r))} ${e.retrogrades.map(r=>this.renderRetrogradeChip(r))}</span>`:Ae.nothing}</div>`}renderPosition(e){let{degree:t,minute:r}=Ii(e.degreeInSign),s=Z(e.sign),i=y(e,"sign");return Ae.html`<span class="pos" title="${i}">${t}${s?Ae.html`<span class="sg" aria-hidden="true">${s}</span>`:Ae.html`<span class="sg">${i}</span>`}${String(r).padStart(2,"0")}</span>`}renderIngressChip(e){let t=Z(e.sign),r=ss(this.effectiveLang(),e.date);return Ae.html`<span class="roxy-chip chip--ingress" aria-label="${this.t("Enters {{sign}} on {{date}}",{sign:e.signLabel,date:r})}"><span aria-hidden="true">→</span>${t?Ae.html`<span aria-hidden="true">${t}</span>`:Ae.nothing}${e.signLabel} <span class="chip-date">${r}</span></span>`}renderRetrogradeChip(e){let t=Vc(this.effectiveLang(),e.start,e.end);return Ae.html`<span class="roxy-chip chip--retro" data-tone="danger"><span aria-hidden="true">℞</span>${this.t("Retrograde {{range}}",{range:t})}</span>`}renderGrid(e){let t=this.effectiveLang();return Ae.html`<table><caption class="roxy-sr-only">${this.t("Every body with its position on each day of the month, as a zodiac sign and a degree.")}</caption><thead><tr><th scope="col" class="day">${this.t("Date")}</th>${e.bodies.map(r=>{let s=S(r.name);return Ae.html`<th scope="col" title="${r.label}">${s?Ae.html`<span class="glyph" aria-hidden="true">${s}</span><span class="roxy-sr-only">${r.label}</span>`:r.label}</th>`})}</tr></thead><tbody>${e.rows.map(r=>Ae.html`<tr><th scope="row" class="day">${Uc(t,r.date)}</th>${r.cells.map((s,i)=>this.renderCell(s,e.bodies[i],r.date))}</tr>`)}</tbody></table>`}renderCell(e,t,r){if(!e)return Ae.html`<td>—</td>`;let s=[e.isRetrograde?"retro":"",t?.ingressDates.has(r)?"ingress":"",t?.stationDates.has(r)?"station":""].filter(Boolean).join(" ");return Ae.html`<td class="${s}">${this.renderPosition(e)}${e.isRetrograde?Ae.html`<span class="retro-mark" aria-label="${this.t("retrograde")}">℞</span>`:Ae.nothing}</td>`}toViewModel(e){let t=[],r=new Map;for(let o of e.days)for(let l of o.positions){let c=r.get(l.planet);c||(c=[],r.set(l.planet,c),t.push(l.planet)),c.push({date:o.date,p:l})}let s=[];for(let o of t){let l=r.get(o),c=l?.[0],d=l?.[l.length-1];if(!l||!c||!d)continue;let p=[],h=[],x=new Set,$=new Set;for(let L=0;L<l.length;L++){let C=l[L],ne=l[L-1];if(!C||(ne&&C.p.sign!==ne.p.sign&&(p.push({date:C.date,sign:C.p.sign,signLabel:y(C.p,"sign")}),x.add(C.date)),ne&&C.p.isRetrograde!==ne.p.isRetrograde&&$.add(C.date),!C.p.isRetrograde))continue;let Ce=h[h.length-1];Ce&&ne?.p.isRetrograde?Ce.end=C.date:h.push({start:C.date,end:C.date})}s.push({name:o,label:y(d.p,"planet"),first:c.p,last:d.p,ingresses:p,retrogrades:h,ingressDates:x,stationDates:$})}let i=e.days.map(o=>{let l=new Map(o.positions.map(c=>[c.planet,c]));return{date:o.date,cells:s.map(c=>l.get(c.name))}});return{year:e.year,month:e.month,bodies:s,rows:i,signs:this.toSignKey(e)}}toSignKey(e){let t=new Map;for(let s of e.days)for(let i of s.positions){let o=String(i.sign??"").toLowerCase();o&&!t.has(o)&&t.set(o,y(i,"sign"))}let r=[];for(let s of Ie){let i=t.get(s.toLowerCase()),o=Z(s);i&&o&&r.push({sign:s,label:i,glyph:o})}return r}};Pa.endpoints=ul,Pa.styles=[u,Ae.css`:host{overflow-x:clip}.wrap{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,h3,p{margin:0}header,section{gap:var(--roxy-space-sm);display:grid}.month{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.signkey{gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.signkey-item{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);white-space:nowrap;display:inline-flex}.signkey-glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.track{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.body-name{align-items:baseline;gap:var(--roxy-space-xs);min-inline-size:16ch;font-weight:var(--roxy-weight-bold);display:inline-flex}.body-name .glyph{color:var(--roxy-accent-ink)}.span{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-variant-numeric:tabular-nums;white-space:nowrap;display:inline-flex}.arrow{color:var(--roxy-muted)}.chips{margin-inline-start:auto}.chip-date{color:var(--roxy-muted)}.scroll{min-width:0;overflow-x:auto}table{font-size:var(--roxy-text-xs)}:is(th,td){white-space:nowrap}thead th .glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}th.day{z-index:1;background:var(--roxy-bg);color:var(--roxy-fg);border-inline-end:1px solid var(--roxy-border);position:sticky;left:0}thead th.day{z-index:2}.sg{margin-inline:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-variant-numeric:normal}.retro-mark{font-weight:var(--roxy-weight-bold);margin-inline-start:calc(var(--roxy-space-unit) / 2)}td.retro,td.retro .sg{color:var(--roxy-danger-fg)}td.ingress{box-shadow:inset var(--roxy-line-thick) 0 var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}td.station{border-block-start:var(--roxy-line-thick) solid var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}`],m([(0,Pp.property)({type:String})],Pa.prototype,"heading",2),Pa=m([f("roxy-ephemeris-table")],Pa);var Qe=require("lit");var wr=class extends g{renderData(a){let e=a.conjunctions??[],t=a.stars??[];return Qe.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Fixed stars")}</h2>${typeof a.orb=="number"?Qe.html`<p class="roxy-label">${this.t("Orb")} ${b(this.effectiveLang(),a.orb,1)}°</p>`:Qe.nothing}</header>${a.summary&&!this.hideReadings?Qe.html`<p class="summary">${a.summary}</p>`:Qe.nothing} ${e.length?Qe.html`<section part="section conjunctions"><h3>${this.t("Conjunctions to the chart")}</h3>${e.map((r,s)=>Qe.html`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${s===0}"><summary><span class="interp-lead">${this.t("{{point}} conjunct {{star}}",{point:y(r,"point"),star:r.star})}</span> ${he()} <span class="interp-aside"><small>${this.t("orb {{value}}\xB0",{value:b(this.effectiveLang(),r.orb,2)})}</small></span></summary>${r.interpretation&&!this.hideReadings?Qe.html`<div class="interp-body"><p>${r.interpretation}</p></div>`:Qe.nothing}</details>`)}</section>`:Qe.html`<p class="empty-note">${this.t("No star sits within the orb of a natal point.")}</p>`} ${t.length?this.renderCatalog(t):Qe.nothing}</div>`}renderCatalog(a){return Qe.html`<details class="catalog"><summary>${he()} ${this.t("Star catalog ({{count}})",{count:a.length})}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Precessed positions for the chart date")}"><table><caption class="roxy-label">${this.t("Precessed positions for the chart date")}</caption><thead><tr><th scope="col">${this.t("Star")}</th><th scope="col">${this.t("Position")}</th><th scope="col" class="num">${this.t("Mag")}</th><th scope="col">${this.t("Nature")}</th><th scope="col">${this.t("Keywords")}</th></tr></thead><tbody>${a.map(e=>{let t=Z(e.sign);return Qe.html`<tr><td>${e.name}</td><td>${t?Qe.html`<span class="sg">${t}</span>`:Qe.nothing}${Jt(e.degree)} ${e.sign}</td><td class="num">${b(this.effectiveLang(),e.magnitude,1)}</td><td>${e.nature}</td><td><ul class="kw roxy-chips">${(e.keywords??[]).map(r=>Qe.html`<li>${r}</li>`)}</ul></td></tr>`})}</tbody></table></div></details>`}};wr.endpoints=fl,wr.styles=[u,W,me,Qe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.summary{font-size:var(--roxy-text-sm)}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}section>h3{margin-block-end:var(--roxy-space-sm)}.interp-lead .point{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);display:flex}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.sg{color:var(--roxy-secondary);margin-inline-end:var(--roxy-space-xs)}.kw{max-inline-size:32ch}`],wr=m([f("roxy-fixed-stars")],wr);var P=require("lit"),_p=require("lit/decorators.js");var ei=["Southeast","South","Southwest","East","Center","West","Northeast","North","Northwest"];var Mp=require("lit"),ti=Mp.css`.plate-heading{font-size:var(--roxy-text-xs);color:var(--roxy-muted);font-weight:var(--roxy-weight-bold);hyphens:manual}@container (width<=30rem){.plate-heading{font-size:calc(var(--roxy-text-xs) / var(--roxy-text-scale) / var(--roxy-text-scale))}}`;var ai={forward:"Forward",reverse:"Backward"};function ms(n){return"mountainCenterStar"in n}var Ma=class extends g{constructor(){super(...arguments);this.mode="natal"}renderData(e){let t=this.effectiveLang(),r=this.mode!=="annual"&&ms(e);return P.html`<article class="card" part="card" aria-labelledby="flying-star-title"><header class="head" part="header"><h2 class="title" id="flying-star-title">${this.t("Flying star chart")}</h2>${ms(e)?r?P.html`<span class="period">${this.t("Period {{n}}",{n:U(t,e.period??0)})}</span>`:P.nothing:P.html`<span class="period">${e.year??""}</span>`}</header>${ms(e)?r?this.renderNatalFacts(e,t):P.nothing:this.renderAnnualFacts(e,t)}<div class="plate" part="chart plate" role="group" aria-label="${this.t("Flying star chart")}">${ei.map(s=>this.renderPalace(e,s))}</div>${r?P.html`<div class="legend" part="legend"><span><span class="swatch swatch-mountain"></span>${this.t("Mountain star")}</span> <span><span class="swatch swatch-water"></span>${this.t("Water star")}</span> <span>${this.t("Period star")}</span></div>`:P.nothing} ${r&&ms(e)?this.renderStructure(e):P.nothing} ${this.renderPalaceRows(e)}</article>`}renderNatalFacts(e,t){return P.html`<div class="facts" part="details">${e.facing?P.html`<span><span class="roxy-label">${this.t("Facing")}</span> <b>${ie(t,"facing",e.facing.label??"")}</b></span>`:P.nothing} ${e.sitting?P.html`<span><span class="roxy-label">${this.t("Sitting")}</span> <b>${ie(t,"facing",e.sitting.label??"")}</b></span>`:P.nothing} ${typeof e.facingDegrees=="number"?P.html`<span>${U(t,e.facingDegrees)}°</span>`:P.nothing} ${e.mountainFlight?P.html`<span><span class="roxy-label">${this.t("Mountain star")}</span> ${ai[e.mountainFlight]?this.t(ai[e.mountainFlight]):e.mountainFlight}</span>`:P.nothing} ${e.waterFlight?P.html`<span><span class="roxy-label">${this.t("Water star")}</span> ${ai[e.waterFlight]?this.t(ai[e.waterFlight]):e.waterFlight}</span>`:P.nothing} ${e.straddling?P.html`<span><b>${this.t("Straddling")}</b></span>`:P.nothing}</div>`}renderAnnualFacts(e,t){return!e.changeoverDate&&typeof e.centerStar!="number"?P.nothing:P.html`<div class="facts" part="details">${typeof e.centerStar=="number"?P.html`<span><span class="roxy-label">${this.t("Center")}</span> <b>${U(t,e.centerStar)}</b></span>`:P.nothing} ${e.changeoverDate?P.html`<span>${M(t,e.changeoverDate)}</span>`:P.nothing}</div>`}paletteHeading(e,t){return t==="Center"?this.t("Center"):ie(e,"facing",t)}renderPalace(e,t){let r=this.effectiveLang(),s=this.paletteHeading(r,t),i=(e.palaces??[]).find(d=>d.palace===t),o=this.mode!=="annual"&&ms(e);if(!i)return P.html`<div class="palace"><span class="palace-name plate-heading">${s}</span></div>`;let l=t==="Center";if(o&&ms(e)){let d=i;return P.html`<div class="palace ${l?"palace-center":""}"><span class="mountain" title="${this.t("Mountain star")}">${d.mountain??""}</span> <span class="water" title="${this.t("Water star")}">${d.water??""}</span> <span class="star" title="${this.t("Period star")}">${d.period??""}</span> <span class="palace-name plate-heading">${s}</span> ${d.combination?P.html`<span class="combo">${y(d.combination,"name")}</span>`:P.nothing}</div>`}let c=i;return P.html`<div class="palace ${l?"palace-center":""}"><span class="star">${c.star??""}</span> <span class="palace-name plate-heading">${s}</span> <span class="combo">${y(c,"name")}</span></div>`}renderStructure(e){let t=e.structure;return t?.name?P.html`<section part="section structure"><h3 class="block-title">${t.name}</h3>${t.meaning&&!this.hideReadings?P.html`<p class="structure" part="reading">${t.meaning}</p>`:P.nothing}</section>`:P.nothing}renderPalaceRows(e){let t=e.palaces??[];if(t.length===0)return P.nothing;let r=this.effectiveLang(),s=this.mode!=="annual"&&ms(e),i=t.map(o=>{let l=this.paletteHeading(r,o.palace??"");if(s){let d=o;return!d.reading&&!d.combination?P.nothing:P.html`<li class="row" part="label-track"><span class="roxy-label">${l}</span><div class="row-body">${d.combination?P.html`<span>${y(d.combination,"name")}</span>`:P.nothing} ${d.reading&&!this.hideReadings?P.html`<p part="reading">${d.reading}</p>`:P.nothing}</div></li>`}let c=o;return P.html`<li class="row" part="label-track"><span class="roxy-label">${l}</span><div class="row-body"><span>${y(c,"name")}</span> ${c.element?P.html`<span class="element-word ${Et(c.element)}">${y(c,"element")}</span>`:P.nothing}<dl class="star-facts">${c.nature?P.html`<div><dt>${this.t("Nature")}</dt><dd>${c.nature==="auspicious"?this.t("Favourable"):c.nature==="inauspicious"?this.t("Unfavourable"):c.nature}</dd></div>`:P.nothing} ${c.enhancer?P.html`<div><dt>${this.t("Enhancer")}</dt><dd>${c.enhancer}</dd></div>`:P.nothing} ${c.remedy?P.html`<div><dt>${this.t("Remedy")}</dt><dd>${c.remedy}</dd></div>`:P.nothing}</dl>${c.meaning&&!this.hideReadings?P.html`<p part="reading">${c.meaning}</p>`:P.nothing}</div></li>`});return i.every(o=>o===P.nothing)?P.nothing:P.html`<section part="section palaces"><ul class="rows">${i}</ul></section>`}};Ma.endpoints=xl,Ma.styles=[u,la,ti,xr,P.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.period{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.plate{background:var(--roxy-border);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;display:grid;overflow:hidden}.palace{align-content:start;gap:calc(var(--roxy-space-unit) / 2);min-block-size:3.5lh;padding:var(--roxy-space-sm);background:var(--roxy-surface);grid-template-columns:1fr 1fr;display:grid}.palace-center{background:color-mix(in srgb, var(--roxy-accent) 8%, var(--roxy-surface))}.mountain,.water{font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.mountain{color:var(--roxy-info-fg);text-align:start}.water{color:var(--roxy-accent-ink);text-align:end}.star,.palace-name,.combo{text-align:center;grid-column:1/-1}.star{font-size:calc(var(--roxy-text-base) * 1.75);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.combo{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-mountain{background:var(--roxy-info)}.swatch-water{background:var(--roxy-accent)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.row-body p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}.star-facts{gap:var(--roxy-space-xs) var(--roxy-space-md);margin:var(--roxy-space-xs) 0 0;font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.star-facts div{gap:var(--roxy-space-xs);display:flex}.star-facts dt{color:var(--roxy-secondary);font-size:inherit}.star-facts dd{margin:0}.structure{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);border-block-start:0;margin:0}`],m([(0,_p.property)({type:String,reflect:true})],Ma.prototype,"mode",2),Ma=m([f("roxy-flying-star-chart")],Ma);var At=require("lit");var kr=class extends g{renderData(a){let e=a.windows??[];if(e.length===0)return this.renderEmpty();let t=Ct(this.effectiveLang(),a.startDate,a.endDate);return At.html`<div class="wrap" part="card" aria-label="${this.t("Forecast digest")}"><div class="head" part="header"><h2>${this.t("Forecast digest")}</h2>${t?At.html`<p class="subtitle">${t}</p>`:At.nothing}</div>${e.map(r=>this.renderWindow(r))}</div>`}windowLabel(a){return a===1?this.t("Next 24 hours"):typeof a=="number"?this.t("Next {{count}} days",{count:a}):this.t("Window")}renderWindow(a){let e=[...a.top??[]].sort((s,i)=>(i.significance??0)-(s.significance??0)),t=a.byDomain??{},r=Object.entries(t);return At.html`<section class="window" part="section window"><div class="window-head" part="details"><h3>${this.windowLabel(a.days)}</h3><span class="window-count">${this.t("{{count}} events",{count:a.count??0})}</span></div>${r.length>0?At.html`<div class="domains" part="legend">${r.map(([s,i])=>At.html`<span class="domain-chip"><span class="swatch sw-${s}"></span>${D(s)} ${i}</span>`)}</div>`:At.nothing} ${e.length>0?At.html`<div role="list">${e.map(s=>this.renderEvent(s))}</div>`:At.html`<p class="quiet">${this.t("No notable events.")}</p>`}</section>`}renderEvent(a){let e=typeof a.significance=="number"?a.significance:0,t=this.hideReadings||a.description==null?D(a.type??""):a.description;return At.html`<div class="event" part="label-track" role="listitem"><span class="event-date">${M(this.effectiveLang(),a.date)}</span> <span class="event-desc">${t}</span> <span class="sig" role="img" aria-label="${this.t("significance {{value}} of 100",{value:b(this.effectiveLang(),e,0)})}"><span class="sig-fill ${a.domain}" style="width:${Math.max(0,Math.min(100,e))}%"></span></span></div>`}};kr.endpoints=bl,kr.styles=[u,At.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.window{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.window:first-of-type{border-block-start:0;padding-block-start:0}.window-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.window-count{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.domains{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.domain-chip{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:inline-flex}.swatch{border-radius:var(--roxy-radius-sm);block-size:.6lh;inline-size:.6lh;display:inline-block}.sw-western,.sig-fill.western{background:var(--roxy-accent)}.sw-vedic,.sig-fill.vedic{background:var(--roxy-info)}.sw-biorhythm,.sig-fill.biorhythm{background:var(--roxy-success)}.event{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);display:grid}.event-date{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.event-desc{font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-tight)}.sig{block-size:calc(var(--roxy-line-thick) * 2);border-radius:var(--roxy-radius-full);background:var(--roxy-border);grid-column:2;overflow:hidden}.sig-fill{height:100%;display:block}.quiet{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-style:italic}`],kr=m([f("roxy-forecast-digest")],kr);var Ve=require("lit");var Sy={western:"Western",vedic:"Vedic",biorhythm:"Biorhythm"},Ry=["western","vedic","biorhythm"],Sr=class extends g{renderData(a){let e=a.events??[],t=this.groupByDate(e),r=Ry.filter(s=>e.some(i=>i.domain===s));return Ve.html`<div class="wrap" part="card" aria-label="${this.t("Forecast timeline")}"><header class="head" part="header"><h2>${this.t("Forecast timeline")}</h2>${a.startDate&&a.endDate?Ve.html`<div class="range">${Ct(this.effectiveLang(),a.startDate,a.endDate)} · ${this.t("{{count}} events",{count:a.count??e.length})}</div>`:Ve.nothing}</header>${r.length?Ve.html`<div class="legend" part="legend">${r.map(s=>Ve.html`<span><span class="swatch swatch-${s}"></span>${Sy[s]}</span>`)}</div>`:Ve.nothing} ${t.length?Ve.html`<div class="days" part="section events" role="list">${t.map(([s,i])=>this.renderDay(s,i))}</div>`:Ve.html`<p class="roxy-empty" role="status">${this.t("No events in this window")}</p>`}</div>`}groupByDate(a){let e=new Map;for(let t of a){let r=t.date??"",s=e.get(r)??[];s.push(t),e.set(r,s)}return[...e.entries()]}renderDay(a,e){return Ve.html`<div class="day" role="listitem"><div class="day-date">${M(this.effectiveLang(),a)}</div><div class="events">${e.map(t=>this.renderEvent(t))}</div></div>`}renderEvent(a){let e=typeof a.significance=="number"?a.significance:0,t=Math.max(0,Math.min(100,e));return Ve.html`<div class="event"><span class="dot dot-${a.domain}" aria-hidden="true"></span><div class="event-body"><div class="event-line">${this.renderHeadline(a)}</div>${a.description&&!this.hideReadings?Ve.html`<p class="event-desc">${a.description}</p>`:Ve.nothing}<div class="sig" title="${this.t("significance {{value}} of 100",{value:t})}"><span class="sig-track"><span class="sig-fill sig-fill-${a.domain}" style="width:${t}%"></span> </span><span class="sig-val">${t}</span></div></div></div>`}renderHeadline(a){let e=a.body?D(a.body):"",t=a.target?D(a.target):"",r=Tt({type:a.aspect}),s=r?Cs(a.aspect)??He({type:a.aspect}):"",i=typeof a.orb=="number"?b(this.effectiveLang(),a.orb,1):"",o=this.typeQualifier(a);return r&&t?Ve.html`<strong>${e}</strong> <span class="${Ze({type:a.aspect})}">${s}</span> <strong>${t}</strong>${i?Ve.html`<span class="kind">${this.t("orb {{value}}\xB0",{value:i})}</span>`:Ve.nothing}`:Ve.html`<strong>${e||D(a.type??"")}</strong>${o?Ve.html`<span class="kind">${o}</span>`:Ve.nothing}`}typeQualifier(a){return a.type==="sign-ingress"&&a.target?`enters ${D(a.target)}`:a.type==="retrograde-station"&&a.station?a.station:a.type==="eclipse"?[a.kind,"eclipse"].filter(Boolean).join(" "):a.type==="critical-day"?"critical day":a.type==="dasha-change"&&a.target?`dasha ${D(a.target)}`:D(a.type??"")}};Sr.endpoints=vl,Sr.styles=[u,$a,Ve.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.range{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.legend{gap:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.legend .swatch{block-size:.6lh;inline-size:.6lh;border-radius:var(--roxy-radius-full);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-western,.dot-western,.sig-fill-western{background:var(--roxy-accent)}.swatch-vedic,.dot-vedic,.sig-fill-vedic{background:var(--roxy-info)}.swatch-biorhythm,.dot-biorhythm,.sig-fill-biorhythm{background:var(--roxy-success)}.day{gap:var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);grid-template-columns:9ch minmax(0,1fr);display:grid}.day:first-of-type{border-block-start:0}@container (width<=30rem){.day{grid-template-columns:minmax(0,1fr)}}.day-date{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;padding-block-start:calc(var(--roxy-space-unit) / 2)}.events{gap:var(--roxy-space-sm);display:grid}.event{align-items:start;gap:var(--roxy-space-sm);grid-template-columns:.4lh minmax(0,1fr);display:grid}.dot{block-size:.4lh;inline-size:.4lh;border-radius:var(--roxy-radius-full);margin-block-start:var(--roxy-space-xs)}.event-body{min-width:0}.event-line{font-size:var(--roxy-text-sm)}.event-line .kind{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}.event-desc{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2)}.sig{align-items:center;gap:var(--roxy-space-xs);margin-block-start:var(--roxy-space-xs);display:flex}.sig-track{max-inline-size:16ch;block-size:calc(var(--roxy-line-thick) * 2);border-radius:var(--roxy-radius-full);background:var(--roxy-border);flex:1;overflow:hidden}.sig-fill{height:100%;display:block}.sig-val{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],Sr=m([f("roxy-forecast-timeline")],Sr);var N=require("lit"),Np=require("lit/directives/if-defined.js");var Rr=class extends g{renderData(a){let e=this.effectiveLang(),t=a.chosen,r=a.input?.text??a.input?.textHebrew??"";return N.html`<article class="card" part="card" aria-labelledby="gematria-title"><header class="head" part="header"><h2 id="gematria-title">${r?`${this.t("Gematria")} \xB7 ${r}`:this.t("Gematria")}</h2>${t?.hebrew?N.html`<span class="hebrew" lang="he" dir="rtl">${t.hebrew}</span>`:N.nothing} ${this.chosenForm(a)?.romanization?N.html`<span class="roman">${this.chosenForm(a)?.romanization}</span>`:N.nothing} ${t?.rule?N.html`<p class="rule">${t.rule}</p>`:N.nothing}</header>${this.renderLetters(e,this.chosenForm(a)?.letters)} ${this.renderValues(e,a.values,this.t("Cipher values"))} ${this.renderForms(e,a)} ${this.renderTransformations(e,a.transformations)} ${this.renderLatin(e,a.latinValues)} ${this.renderMatches(e,a.matches)} ${this.renderConventions(a.conventions)}</article>`}chosenForm(a){let e=a.hebrewForms??[];return e.find(t=>t.hebrew===a.chosen?.hebrew)??e[0]}renderLetters(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section letters"><h3>${this.t("Letters")}</h3><div class="letters" part="chart" dir="rtl">${t.map(r=>N.html`<div class="${`letter${r.isFinal?" is-final":""}`}" dir="ltr" title="${(0,Np.ifDefined)(r.isFinal?this.t("Final form"):void 0)}"><span class="glyph" lang="he">${r.glyph??""}</span> <span class="name">${r.name??""}</span> <span class="num">${U(a,r.value)}</span></div>`)}</div>${t.some(r=>r.isFinal)?N.html`<p class="legend" part="legend"><span class="swatch"></span>${this.t("Final form")}</p>`:N.nothing}</section>`}renderValues(a,e,t){let r=(e??[]).filter(i=>typeof i.value=="number");if(r.length===0)return N.nothing;let s=r.some(i=>(i.alternateValues??[]).length>0);return N.html`<section part="section values"><h3>${t}</h3><div class="scroll" tabindex="0" role="region" aria-label="${t}"><table><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Value")}</th>${s?N.html`<th>${this.t("Also published")}</th>`:N.nothing}</tr></thead><tbody>${r.map(i=>N.html`<tr><td>${D(i.id??"")}</td><td class="num">${U(a,i.value)}</td>${s?N.html`<td class="num">${(i.alternateValues??[]).map(o=>U(a,o)).join(", ")}</td>`:N.nothing}</tr>`)}</tbody></table></div>${this.renderProvenance(r)}</section>`}renderProvenance(a){let e=new Map;for(let t of a)t.tradition&&!e.has(t.tradition)&&e.set(t.tradition,t.source);return e.size===0?N.nothing:N.html`<p class="provenance"><span class="roxy-label">${this.t("Tradition")}</span> ${[...e].map(([t,r],s)=>N.html`${s>0?" \xB7 ":""}${D(t)}${nn(r)?N.html`<a class="src" href="${r}" target="_blank" rel="noopener noreferrer">${this.t("Source")}</a>`:N.nothing}`)}</p>`}renderForms(a,e){let t=e.hebrewForms??[];return t.length<2?N.nothing:N.html`<section part="section spellings"><h3>${this.t("Spellings")}</h3><ul class="forms">${t.map(r=>N.html`<li class="form"><div><span class="hebrew" lang="he" dir="rtl">${r.hebrew??""}</span> ${r.hebrew===e.chosen?.hebrew?N.html`<span class="chosen roxy-chip" data-tone="success">${this.t("Chosen")}</span>`:N.nothing}</div><span class="roman">${r.romanization??""}</span> ${r.rule?N.html`<p class="rule">${r.rule}</p>`:N.nothing} ${this.renderFormTotals(a,r)}</li>`)}</ul></section>`}renderFormTotals(a,e){let t=(e.values??[]).find(r=>typeof r.value=="number");return t?N.html`<p class="rule"><span class="roxy-label">${D(t.id??"")}</span> ${U(a,t.value)}</p>`:N.nothing}renderTransformations(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section substitutions"><h3>${this.t("Substitutions")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Substitutions")}"><table><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Output")}</th><th>${this.t("Value")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td>${D(r.id??"")}</td><td>${r.output?N.html`<span lang="he" dir="rtl">${r.output}</span>`:N.nothing} ${r.outputRomanization?N.html`<span class="roman">${r.outputRomanization}</span>`:N.nothing}</td><td class="num">${U(a,r.value)}</td></tr>`)}</tbody></table></div></section>`}renderLatin(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section latin-ciphers"><h3>${this.t("Latin ciphers")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Latin ciphers")}"><table class="stacked"><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Value")}</th><th>${this.t("Tradition")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td data-label="${this.t("Cipher")}">${D(r.id??"")} ${r.lineage?N.html`<p class="lineage">${r.lineage}</p>`:N.nothing}</td><td class="num" data-label="${this.t("Value")}">${U(a,r.value)}</td><td data-label="${this.t("Tradition")}">${D(r.tradition??"")}</td></tr>`)}</tbody></table></div></section>`}renderMatches(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section matches"><h3>${this.t("Equal values")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Equal values")}"><table class="stacked"><thead><tr><th>${this.t("Word")}</th><th>${this.t("Meaning")}</th><th>${this.t("Value")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td data-label="${this.t("Word")}"><span lang="he" dir="rtl">${r.hebrew??""}</span> <span class="roman">${r.romanization??""}</span></td><td data-label="${this.t("Meaning")}">${r.meaning??""} ${r.note&&!this.hideReadings?N.html`<p class="match-note" part="reading">${r.note}</p>`:N.nothing}</td><td class="num" data-label="${this.t("Value")}">${U(a,r.value)}</td></tr>`)}</tbody></table></div></section>`}renderConventions(a){let e=this.effectiveLang(),t=[];for(let r of["transliteration","misparGadol"]){let s=a?.[r];s&&t.push([ke(e,r),ie(e,r,s)])}return t.length===0?N.nothing:N.html`<p class="provenance">${t.map(([r,s],i)=>N.html`${i>0?" \xB7 ":""}<span class="roxy-label">${r}</span>${s}`)}</p>`}};Rr.endpoints=Ll,Rr.styles=[u,ia,N.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{justify-items:start;gap:calc(var(--roxy-space-unit) / 2);min-width:0;display:grid}.hebrew{font-size:calc(var(--roxy-text-xl) * 1.3);font-weight:var(--roxy-weight-bold);line-height:1.4}.roman{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.rule{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.provenance .roxy-label,.rule .roxy-label{font-size:inherit;margin-inline-end:var(--roxy-space-xs)}.src{margin-inline-start:var(--roxy-space-xs)}.letters{gap:var(--roxy-space-xs);flex-wrap:wrap;display:flex}.letter{justify-items:center;gap:calc(var(--roxy-space-unit) / 2);min-inline-size:5ch;padding:var(--roxy-space-xs) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);display:grid}.letter .glyph{font-size:var(--roxy-text-lg);line-height:1.3}.letter .name{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.letter .num{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.letter.is-final{border-color:var(--roxy-accent)}.legend{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:var(--roxy-space-sm)}.legend .swatch{block-size:.6lh;inline-size:.6lh;border:1px solid var(--roxy-accent);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td.num{white-space:nowrap}.provenance{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:var(--roxy-space-sm)}.lineage,.match-note{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);white-space:normal;margin-block-start:calc(var(--roxy-space-unit) / 2)}a{color:var(--roxy-accent-ink)}.forms{gap:var(--roxy-space-md);margin:0;padding:0;list-style:none;display:grid}.form{gap:var(--roxy-space-xs);min-width:0;border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.form:first-child{border-block-start:0;padding-block-start:0}`],Rr=m([f("roxy-gematria")],Rr);var Ue=require("lit");var zp=8,Cr=class extends g{renderData(a){let e=a.transitingPlanets??[];if(!e.length)return this.renderEmpty();let t=a.keyTransits??[],r=a.natalPlanets?.find(s=>s.name==="Moon")?.sign;return Ue.html`<div class="wrap" part="card" aria-label="${this.t("Gochara transits")}"><header class="head" part="header"><h2>${this.t("Gochara")}</h2><p class="sub">${this.t("Where each graha transits at {{when}}, read against the natal chart of {{birth}}.",{when:ue(this.effectiveLang(),a.transitDatetime),birth:ue(this.effectiveLang(),a.birthDatetime)})}</p>${r?Ue.html`<p class="sub">${this.t("Gochara houses are counted from the natal Moon in {{sign}}.",{sign:r})}</p>`:Ue.nothing} ${ve(this.effectiveLang(),a.frame,this.translator)}</header><div part="table">${e.map(s=>this.renderPlanet(s))}</div>${t.length&&!this.hideReadings?Ue.html`<section class="key" part="section key-transits"><h3>${this.t("Key transits")}</h3>${t.map(s=>Ue.html`<p class="key-item">${s.description}</p>`)}</section>`:Ue.nothing}</div>`}renderPlanet(a){let e=S(a.name)??"",t=typeof a.longitude=="number"?Vt(a.longitude):void 0;return Ue.html`<article class="row"><div class="row-top"><span class="graha">${e?Ue.html`<span class="glyph">${e}</span>`:Ue.nothing}${a.name} </span><span class="pos">${t?`${a.sign} ${t}`:a.sign} </span>${typeof a.houseFromMoon=="number"?Ue.html`<span class="house moon roxy-chip">${this.t("house {{n}} from the Moon",{n:a.houseFromMoon})}</span>`:Ue.nothing} ${typeof a.natalHouse=="number"?Ue.html`<span class="house lagna roxy-chip">${this.t("house {{n}} from the Lagna",{n:a.natalHouse})}</span>`:Ue.nothing}</div>${this.renderKaksha(a.kaksha)} ${this.renderContacts(this.t("Drishti"),a.drishtiToNatal)} ${this.renderContacts(this.t("Aspects"),a.aspectsToNatal)}</article>`}renderContacts(a,e){return e?.length?Ue.html`<p class="aspects"><span class="contact-label">${a}</span> ${e.map(t=>typeof t.orb=="number"?this.t("{{aspect}} natal {{planet}} ({{orb}}\xB0)",{aspect:He({type:t.aspectType}),planet:t.natalPlanet,orb:b(this.effectiveLang(),t.orb,1)}):this.t("{{aspect}} natal {{planet}}",{aspect:He({type:t.aspectType}),planet:t.natalPlanet})).join(" \xB7 ")}</p>`:Ue.nothing}renderKaksha(a){if(!a||typeof a.number!="number")return Ue.nothing;let e=a.number,t=a.bindu===true?"yes":a.bindu===false?"no":"",r=zp,s=a.lord&&typeof a.startDegree=="number"&&typeof a.endDegree=="number"?this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:e,total:r,graha:a.lord,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)}):a.lord?this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}",{n:e,total:r,graha:a.lord}):typeof a.startDegree=="number"&&typeof a.endDegree=="number"?this.t("Kaksha {{n}} of {{total}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:e,total:r,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)}):this.t("Kaksha {{n}} of {{total}}",{n:e,total:r}),i=a.bindu===null||a.bindu===void 0?"":typeof a.binduCount=="number"?a.bindu?this.t("this kaksha lord gave bindu, {{count}} of {{total}} in this sign",{count:a.binduCount,total:r}):this.t("this kaksha lord gave no bindu, {{count}} of {{total}} in this sign",{count:a.binduCount,total:r}):a.bindu?this.t("this kaksha lord gave bindu"):this.t("this kaksha lord gave no bindu");return Ue.html`<div class="kaksha-bar" part="chart" role="img" aria-label="${this.t("Kaksha {{n}} of {{total}} within the current sign",{n:e,total:r})}">${Array.from({length:zp},(o,l)=>Ue.html`<span class="seg ${l+1===e?`here ${t}`:""}"></span>`)}</div><p class="meta">${i?`${s} \xB7 ${i}`:s}</p>`}};Cr.endpoints=$l,Cr.styles=[u,ae,Ue.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);display:grid}h2,h3,p{margin:0}.sub,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.pos{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.house.moon{border-color:var(--roxy-accent);color:var(--roxy-fg)}.contact-label{font-weight:var(--roxy-weight-bold);margin-inline-end:var(--roxy-space-xs)}.kaksha-bar{block-size:.4lh;margin-block:var(--roxy-space-xs);grid-template-columns:repeat(8,minmax(0,1fr));gap:1px;display:grid}.seg{background:var(--roxy-border);border-radius:var(--roxy-radius-sm)}.seg.here{background:var(--roxy-muted)}.seg.here.yes{background:var(--roxy-success)}.seg.here.no{background:var(--roxy-warning)}.aspects{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.key{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);display:grid}.key-item{font-size:var(--roxy-text-sm)}`],Cr=m([f("roxy-gochara-table")],Cr);var et=require("lit");var Cy={varna:1,vashya:2,tara:3,yoni:4,"graha maitri":5,gana:6,bhakoot:7,nadi:8},Tr=class extends g{renderData(a){let e=(a.breakdown??[]).filter(c=>c?.category!==void 0),t=a.total??0,r=a.maxScore??36,s=t/r*100,i=s>=70?"high":s>=50?"mid":"low",o=s*2.827,l=(100-s)*2.827;return et.html`<article class="card" part="card" aria-label="${this.t("Guna Milan score")}"><div class="score-header" part="header"><div class="score-info"><div class="score-bar" part="details"><div><span class="total">${b(this.effectiveLang(),a.total,1)}</span> <span class="over">/ ${a.maxScore}</span> ${typeof a.percentage=="number"?et.html`<small class="pct">${Oe(this.effectiveLang(),a.percentage,1)}</small>`:et.nothing}</div><div class="verdict-wrap">${typeof a.isCompatible=="boolean"?et.html`<span class="verdict roxy-chip ${a.isCompatible?"yes":"no"}" data-tone="${a.isCompatible?"success":"danger"}">${a.isCompatible?this.t("Compatible"):this.t("Not compatible")}</span>`:et.nothing} ${a.recommendation&&!this.hideReadings?et.html`<span class="recommendation">${a.recommendation}</span>`:et.nothing}</div></div></div><div class="score-ring" part="chart" role="meter" aria-label="${this.t("Guna Milan score")}" aria-valuemin="0" aria-valuemax="${r}" aria-valuenow="${t}"><svg viewBox="0 0 100 100" aria-hidden="true"><circle class="ring-track" cx="50" cy="50" r="45"/><circle class="ring-fill" data-band="${i}" cx="50" cy="50" r="45" stroke-dasharray="${o},${l}" transform="rotate(-90 50 50)"/></svg></div></div>${e.length>0?et.html`<div class="table-scroll" part="table"><table class="stacked"><caption class="roxy-sr-only">${this.t("Guna Milan breakdown: each koota with the classification of person 1 and person 2, and the score it earned out of its maximum.")}</caption><thead><tr><th scope="col">${this.t("Koota")}</th><th scope="col">${this.t("Person 1")}</th><th scope="col">${this.t("Person 2")}</th><th scope="col" class="bar-col">${this.t("Progress")}</th><th scope="col" class="score">${this.t("Points")}</th></tr></thead><tbody>${e.map(c=>{let d=c.score??0,p=c.maxScore??Ty(c.category),h=p?d/p*100:0;return et.html`<tr><td>${c.category} ${c.description?et.html`<small>${c.description}</small>`:et.nothing}</td><td class="classification" data-label="${this.t("Person 1")}">${c.person1??""}</td><td class="classification" data-label="${this.t("Person 2")}">${c.person2??""}</td><td class="bar-cell bar-col"><div class="mini-bar"><span style="width:${h}%"></span></div></td><td class="score" data-label="${this.t("Points")}">${b(this.effectiveLang(),d,1)} / ${p}</td></tr>`})}</tbody></table></div>`:et.nothing} ${(a.doshas?.length??0)>0||(a.doshaCancellations?.length??0)>0?et.html`<ul class="tags roxy-chips" part="details">${a.doshas?.map(c=>et.html`<li class="dosha roxy-chip" data-tone="danger">${c}</li>`)} ${a.doshaCancellations?.map(c=>et.html`<li class="cancel roxy-chip" data-tone="success" title="${c.reason}">${this.t("{{dosha}} cancelled",{dosha:c.dosha})}</li>`)}</ul>`:et.nothing} ${ve(this.effectiveLang(),a.frame,this.translator)}</article>`}};Tr.endpoints=wl,Tr.styles=[u,ae,ia,et.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.card>*{min-width:0}.score-header{align-items:center;gap:var(--roxy-space-md);display:flex}.score-info{flex:1;min-width:0}.table-scroll{min-width:0;overflow-x:auto}.score-bar{align-items:center;gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr) auto;display:grid}.total{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.over,.pct{color:var(--roxy-muted)}.pct{font-size:var(--roxy-text-sm);margin-inline-start:var(--roxy-space-sm)}.verdict-wrap{justify-items:end;gap:var(--roxy-space-xs);text-align:end;display:grid}.verdict{font-weight:var(--roxy-weight-bold)}.recommendation{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.score-ring{flex-shrink:0;block-size:5lh;inline-size:5lh}.score-ring svg{block-size:100%;inline-size:100%;display:block}.ring-track,.ring-fill{fill:none;stroke-width:8px}.ring-track{stroke:var(--roxy-border)}.ring-fill{stroke:var(--roxy-danger);stroke-linecap:round}.ring-fill[data-band=mid]{stroke:var(--roxy-warning)}.ring-fill[data-band=high]{stroke:var(--roxy-success)}table{width:100%}td small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2);display:block}td.classification{color:var(--roxy-secondary);white-space:nowrap}:is(th,td).score{text-align:end}td.score{font-weight:var(--roxy-weight-bold)}td.bar-cell{width:22%}@container (width<=32rem){.bar-col{display:none}}@container (width<=26rem){.score-header{flex-direction:column-reverse;align-items:stretch}.score-ring{align-self:center}.score-bar{gap:var(--roxy-space-xs);grid-template-columns:minmax(0,1fr)}.verdict-wrap{text-align:start;justify-items:start}}.mini-bar{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.35lh;overflow:hidden}.mini-bar>span{background:var(--roxy-accent);block-size:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}`],Tr=m([f("roxy-guna-milan")],Tr);function Ty(n){return n&&Cy[n.toLowerCase()]||1}var ze=require("lit"),Ip=require("lit/directives/unsafe-html.js");var Er=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this)}renderChart(e,t,r){let s=new Set(r?e.personAGates:(e.channels??[]).flatMap(h=>h.personAGates??[])),i=new Set(r?e.personBGates:(e.channels??[]).flatMap(h=>h.personBGates??[])),o=new Map;for(let h of new Set([...s,...i]))o.set(h,{left:s.has(h),right:i.has(h)});let l=new Set((e.centers??[]).filter(h=>h.defined).map(h=>h.id)),c=new Map((e.centers??[]).map(h=>[h.id,h.name])),d=new Map;for(let h of e.channels??[])d.set(h.gateA,h.name),d.set(h.gateB,h.name);let p=new Map;for(let[h,x]of o){let $=[x.left&&"A",x.right&&"B"].filter(Boolean).join(" + ");p.set(h,[`Gate ${h}`,d.get(h),$].filter(Boolean).join(" \xB7 "))}return ze.html`${(0,Ip.unsafeHTML)(T`<svg class="chart bodygraph" part="chart" viewBox=${qi} preserveAspectRatio="xMidYMid meet" role="img" aria-label=${t}><title>${t}</title>${Yi({definedCenters:l,gateSources:o,gateTitles:p,centerNames:c,stateWords:{defined:"Defined",open:"Open"}})}</svg>`.markup)} ${r?ze.nothing:ze.html`<p class="note">${t}</p>`}<div class="legend" part="legend"><span><span class="swatch source src-left"></span>Person A</span> <span><span class="swatch source src-right"></span>Person B</span> <span><span class="swatch"></span>Open center</span></div>`}renderData(e){let t=Array.isArray(e.personAGates)&&Array.isArray(e.personBGates),r=t?this.t("Combined bodygraph"):this.t("Defined channels"),s=e.channels??[],i=e.centers??[],o=i.filter(l=>l.defined).length;return ze.html`<div class="wrap bodygraph" part="card" aria-label="Human Design connection"><header class="head" part="header"><h2>Connection</h2>${typeof e.totalChannels=="number"?ze.html`<span class="count">${e.totalChannels} channels</span>`:ze.nothing}</header>${this.chartViewport.renderChartViewport(this.renderChart(e,r,t),r,this.translator)} ${Sa([{label:"Channels",value:e.totalChannels?.toString()},{label:"Combined definition",value:e.combinedDefinition?D(String(e.combinedDefinition)):void 0},{label:"Centers defined",value:i.length>0?`${o}/${i.length}`:void 0}])} ${this.hideReadings?ze.nothing:ze.html`<p class="lead">A connection chart reads the two charts as one bodygraph. Wherever the two of them together hold both gates of a channel, that channel is defined between them, and the centers it joins are defined in the connection whether or not either person defines them alone.</p>`} ${this.renderDynamics(e.summary)} ${this.renderCenters(i)} ${this.renderChannels(s,i)}</div>`}renderDynamics(e){if(!e)return ze.nothing;let t=[{label:"Electromagnetic",aside:ri(e.electromagnetic),body:"Each person holds one of the two gates, so the channel completes only when they are together. The classic point of attraction."},{label:"Dominance",aside:ri(e.dominance),body:"One person holds both gates and the other holds neither, so the conditioning runs one way, from the person who carries the channel to the person who does not."},{label:"Compromise",aside:ri(e.compromise),body:"One person holds both gates and the other holds a single hanging gate of the same channel, so the channel is complete for one of them and half open for the other."},{label:"Companionship",aside:ri(e.companionship),body:"Both people independently hold both gates, so neither needs the other to complete it. A shared and familiar frequency rather than an attraction."}];return this.renderInterpretation(t,"hd-connection-dynamic","Dynamics")}renderCenters(e){return e.length===0?ze.nothing:ze.html`<section class="block" part="section centers"><h3>Centers</h3>${this.hideReadings?ze.nothing:ze.html`<p class="note">Defined is the state of the combined chart. Beside it is who already defines that center in their own chart. A center defined only together is what the connection itself creates: it is there when the two are together and gone when they are apart. The combined definition counts how the defined centers hang together, so Single is one connected piece and a split is more than one.</p>`} ${e.map(t=>{let r=t.definedBy??[],s=r.includes("A"),i=r.includes("B"),o=!!t.defined&&!s&&!i;return ze.html`<div class="row"><span class="cname">${t.name??D(String(t.id??""))}</span> <span class="roxy-chip ${o?"together":""}" data-tone="${t.defined&&!o?"success":ze.nothing}">${t.defined?o?"Only together":"Defined":"Open"} </span><span class="who">${Ey(!!t.defined,s,i)}</span></div>`})}</section>`}renderChannels(e,t){if(e.length===0)return ze.nothing;let r=new Map(t.map(i=>[String(i.id??""),i.name??""])),s=i=>r.get(i)||D(i);return ze.html`<section class="block" part="section channels"><h3>Channels</h3><div class="scroll" part="table" tabindex="0" role="region" aria-label="Connection channels"><table role="table"><caption class="roxy-sr-only">Connection channels: each channel with its gates, the centers it links, its circuit and dynamic, and the gates person A and person B each hold.</caption><thead><tr><th scope="col">Channel</th><th scope="col">Gates</th><th scope="col">Centers</th><th scope="col">Circuit</th><th scope="col">Dynamic</th><th scope="col">Person A holds</th><th scope="col">Person B holds</th></tr></thead><tbody>${e.map(i=>ze.html`<tr><td>${i.name??""}</td><td class="gates">${i.gateA}-${i.gateB}</td><td>${(i.centers??[]).map(s).join(" to ")}</td><td>${i.circuit??""}</td><td>${i.dynamic?ze.html`<span class="roxy-chip">${i.dynamic}</span>`:ze.nothing}</td><td class="held">${Op(i.personAGates)}</td><td class="held">${Op(i.personBGates)}</td></tr>`)}</tbody></table></div></section>`}};Er.endpoints=kl,Er.styles=[u,W,me,hr,Pn,Dn,Xe,ze.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.note{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-end:var(--roxy-space-sm)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.row:last-child{border-block-end:0}.cname{flex:1;min-width:16ch}.roxy-chip.together{color:var(--roxy-accent-ink);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.who{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}table{width:100%}th,td{white-space:nowrap}tbody tr:last-child td{border-block-end:0}.gates{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.held{font-variant-numeric:tabular-nums}.scroll{min-width:0;overflow-x:auto}.wrap{--src-left:var(--roxy-info-fg);--src-right:var(--roxy-warning-fg);--src-ink:var(--roxy-bg)}`],Er=m([f("roxy-hd-connection")],Er);function ri(n){if(typeof n=="number")return n===0?"None":n===1?"1 channel":`${n} channels`}function Op(n){let a=n??[];return a.length>0?a.join(", "):"Neither"}function Ey(n,a,e){return a&&e?"Defined in both charts":a?"Defined by A":e?"Defined by B":n?"Defined by neither alone, only by the connection":"Open in both charts"}var Le=require("lit");var Dr=require("lit");var Lo=360,Dy=470,$o=8,Bp=Lo-$o*2,ni=48,Vs=15,vo=7,Gp=16,si=[{id:"throat",label:"Throat",y:0},{id:"g",label:"G",y:211},{id:"sacral",label:"Sacral",y:422}],Hp=`0 0 ${Lo} ${Dy}`;function Ay(n,a){return $o+Bp*(n*2+1)/(a*2)}function jp(n){return Hs[n.gateA]==="throat"||Hs[n.gateB]==="throat"}function Py(n){return(jp(n)?Hs[n.gateA]==="throat":Hs[n.gateA]==="g")?n.gateA:n.gateB}function My(){return si.map(n=>Dr.svg`<g>
|
|
83
|
-
<rect class="pn-bar" x=${
|
|
84
|
-
<text class="pn-bar-label" x=${
|
|
85
|
-
</g>`)}function
|
|
86
|
-
<circle class="pn-badge" cx=${
|
|
87
|
-
<text class="pn-badge-text" x=${
|
|
88
|
-
</g>`)}function
|
|
89
|
-
<circle class="pn-gate-dot ${i?"on":""}" cx=${
|
|
90
|
-
<text class="pn-gate ${i?"on":""}" x=${
|
|
91
|
-
${
|
|
92
|
-
</g>`}function
|
|
93
|
-
<line class=${
|
|
94
|
-
<line class=${
|
|
95
|
-
<text class="pn-name ${c.defined?"on":""}" x=${
|
|
96
|
-
${
|
|
97
|
-
${
|
|
98
|
-
</g>`)})}return Dr.svg`${My()}${a.length>0?a:Dr.nothing}`}var Ar=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this)}renderChart(e){let t=(e.channels??[]).filter(s=>s.gateA!=null&&s.gateB!=null).map(s=>({gateA:s.gateA,gateB:s.gateB,name:s.name??"",defined:s.defined===true,isCore:s.isCore===true}));if(t.length===0)return Le.nothing;let r=new Map((e.gates??[]).filter(s=>s.gate!=null).map(s=>[s.gate,s.heldBy??[]]));return Le.html`<svg class="chart" part="chart" viewBox="${Hp}" preserveAspectRatio="xMidYMid meet" role="img" aria-label="Penta ladder: the Throat, G and Sacral with the six penta channels between them, each marked defined or open and lettered with the members holding its gates"><title>Penta</title>${Kp({rungs:t,holders:r,letterFor:Vp})}</svg>`}renderData(e){let t=e.channels??[],r=e.gates??[],s=e.summary,i=s?.gapGates??[],o=t.some(l=>l.isCore);return Le.html`<div class="wrap" part="card" aria-label="Human Design penta"><header class="head" part="header"><h2>Penta</h2>${typeof e.memberCount=="number"?Le.html`<span class="count">${e.memberCount} members</span>`:Le.nothing}</header>${this.chartViewport.renderChartViewport(this.renderChart(e),"Penta",this.translator)} ${Sa([{label:"Members",value:e.memberCount?.toString()},{label:"Defined channels",value:typeof s?.definedChannels=="number"&&t.length>0?`${s.definedChannels} of ${t.length}`:void 0},{label:"Filled gates",value:typeof s?.filledGates=="number"&&r.length>0?`${s.filledGates} of ${r.length}`:void 0},{label:"Core",value:typeof s?.coreDefined=="boolean"?s.coreDefined?"Defined":"Open":void 0},{label:"Gap gates",value:i.length>0?i.join(", "):void 0}])} ${this.hideReadings?Le.nothing:Le.html`<p class="lead">A penta is the field three to five people form when they work as a group. It is read from the twelve penta gates the members bring between them: a channel with both of its gates held somewhere in the group is a defined Strength, and a gate no member holds is a gap the group has to compensate for.</p>`} ${this.renderGroup("Upper (direction)",t.filter(l=>l.position==="upper"),"Upper channels run from the G Center to the Throat. They carry the leadership of the group and how it presents itself.")} ${this.renderGroup("Lower (execution)",t.filter(l=>l.position==="lower"),"Lower channels run from the G Center to the Sacral. They carry the managed, generative, resource work.")} ${this.renderGroup("Channels",t.filter(l=>l.position!=="upper"&&l.position!=="lower"))} ${o&&!this.hideReadings?Le.html`<p class="footnote">Core is the 2/14 Channel of the Beat, the material core of the penta: gate 2 sets the direction for resources, gate 14 is the resources themselves.</p>`:Le.nothing} ${this.renderGates(r)} ${t.length>0||r.length>0?Le.html`<p class="footnote" part="legend">Members are lettered in the order they were sent, so A is the first member of the group.</p>`:Le.nothing}</div>`}renderGroup(e,t,r){return t.length===0?Le.nothing:Le.html`<div class="section" part="section channels"><h3>${e}</h3>${r&&!this.hideReadings?Le.html`<p class="note">${r}</p>`:Le.nothing} ${t.map(s=>Le.html`<div class="row"><span class="gates">${s.gateA}-${s.gateB}</span> <span class="cname">${s.name??""} ${s.circuit?Le.html`<span class="circuit">${s.circuit} circuit</span>`:Le.nothing} </span><span class="roxy-chip" data-tone="${s.defined?"success":Le.nothing}">${s.defined?"Defined":"Open"}</span> ${s.isCore?Le.html`<span class="roxy-chip core">Core</span>`:Le.nothing} <span class="held">Gate ${s.gateA} held by ${wo(s.gateAHeldBy)}. Gate ${s.gateB} held by ${wo(s.gateBHeldBy)}.</span></div>`)}</div>`}renderGates(e){if(e.length===0)return Le.nothing;let t=e.filter(r=>r.filled).length;return Le.html`<div class="section" part="section gates"><h3>Gates (${t} of ${e.length} filled)</h3>${this.hideReadings?Le.nothing:Le.html`<p class="note">The role each gate brings to the group, and who carries it. A gap is a role no member holds, so the group compensates for it.</p>`} ${e.map(r=>Le.html`<div class="row"><span class="gate-id">${r.gate}</span> <span class="cname">${r.gateName??""}</span> ${r.filled?Le.html`<span class="who">Held by ${wo(r.heldBy)}</span>`:Le.html`<span class="roxy-chip" data-tone="danger">Gap</span>`}</div>`)}</div>`}};Ar.endpoints=Sl,Ar.styles=[u,Xe,hr,Le.css`.chart{width:100%;max-width:var(--roxy-chart-max-width,22rem);height:auto;margin:0 auto;display:block}.pn-bar{fill:color-mix(in srgb, var(--roxy-accent) 12%, transparent);stroke:var(--roxy-accent-ink);stroke-width:1.5px}.pn-bar-label{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .9375);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.pn-rung{stroke:var(--roxy-border);stroke-width:6px;stroke-dasharray:6 6}.pn-rung.on{stroke:var(--roxy-accent-ink);stroke-dasharray:none}.pn-rung.on.core{stroke-width:9px}.pn-name{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .75);font-family:var(--roxy-font-sans)}.pn-name.on{fill:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.pn-gate-dot{fill:var(--_mask);stroke:var(--roxy-border);stroke-width:1.5px;stroke-dasharray:4 4}.pn-gate-dot.on{stroke:var(--roxy-accent-ink);stroke-dasharray:none}.pn-gate{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.pn-gate.on{fill:var(--roxy-fg)}.pn-badge{fill:var(--roxy-accent-ink)}.pn-badge-text{fill:var(--roxy-bg);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.section{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.note{margin-block-start:var(--roxy-space-xs)}.note,.held,.who,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.row:last-child{border-block-end:0}.gates,.gate-id{font-variant-numeric:tabular-nums;min-width:5ch;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.cname{flex:1;min-width:16ch}.circuit{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}.held{flex-basis:100%}.roxy-chip.core{color:var(--roxy-accent-ink);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}`],Ar=m([f("roxy-hd-penta")],Ar);var Ny="ABCDE",Vp=n=>Ny[n]??String(n+1);function wo(n){let a=(n??[]).map(Vp);return a.length>0?a.join(", "):"nobody"}var Pt=require("lit");var Pr=class extends g{renderData(a){return zy(a)?this.renderType(a):this.renderProfile(a)}renderType(a){return Pt.html`<div class="wrap" part="card"><header class="head" part="header"><h2>${this.t("Type")}</h2>${a.type||a.profile?Pt.html`<div class="type-line">${[y(a,"type"),a.profile?this.t("Profile {{profile}}",{profile:a.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:Pt.nothing}</header>${Sa([{label:this.t("Type"),value:y(a,"type")},{label:this.t("Strategy"),value:y(a,"strategy")},{label:this.t("Authority"),value:y(a,"authority")},{label:this.t("Profile"),value:a.profile}])} ${a.typeDescription&&!this.hideReadings?Pt.html`<p class="lead">${a.typeDescription}</p>`:Pt.nothing} ${Mn(a.signature?y(a,"signature"):void 0,a.notSelf?y(a,"notSelf"):void 0,this.translator)} ${this.renderInterpretation([{label:this.t("Strategy"),aside:y(a,"strategy"),body:a.strategyDescription},{label:this.t("Authority"),aside:y(a,"authority"),body:a.authorityDescription},{label:this.t("Aura"),body:a.aura}],"hd-type-reading")}</div>`}renderProfile(a){return Pt.html`<div class="wrap" part="card"><header class="head" part="header"><h2>${this.t("Profile")}</h2>${a.profile?Pt.html`<div class="type-line">${a.profile}</div>`:Pt.nothing}</header>${Sa([{label:this.t("Profile"),value:a.profile},{label:this.t("Personality line"),value:a.personalityLine?.toString()},{label:this.t("Design line"),value:a.designLine?.toString()}])} ${this.hideReadings?Pt.nothing:Pt.html`<section class="block" part="section lines"><h3>${this.t("Lines")}</h3>${_n({personality:a.personalityKeynote,personalityLine:a.personalityLine,design:a.designKeynote,designLine:a.designLine},this.translator)}</section>`}</div>`}};Pr.endpoints=Rl,Pr.styles=[u,W,me,hr,Pt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.type-line{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`],Pr=m([f("roxy-hd-type-card")],Pr);function zy(n){return typeof n.type=="string"}var be=require("lit");var Mr=class extends g{renderData(a){let e=[...a.arrows??[]].sort((t,r)=>Up(t.position)-Up(r.position));return be.html`<div class="wrap" part="card" aria-label="${this.t("Human Design variables")}"><h2 part="header">${this.t("Variables")}</h2><div class="grid" part="details arrows">${e.map(t=>this.renderArrow(t))}</div>${a.confident===false?be.html`<p class="note" role="note">${typeof a.confidenceMarginDeg=="number"?this.t("Low confidence: a birth time near a color or tone boundary (within {{margin}}\xB0). Verify the exact birth time.",{margin:a.confidenceMarginDeg}):this.t("Low confidence: a birth time near a color or tone boundary. Verify the exact birth time.")}</p>`:be.nothing} ${this.renderReading(e,a.baseDescription)}</div>`}renderArrow(a){let e=a.direction==="left"?"\u2190":"\u2192",t=y(a,"baseName");return be.html`<div class="arrow"><div class="arrow-head"><span class="glyph ${a.activation?.side??""}" aria-hidden="true">${e}</span> <span class="name">${y(a,"name")}</span></div>${a.layer?be.html`<span class="layer">${y(a,"layer")}</span>`:be.nothing} <span class="labels">${[y(a,"directionLabel"),y(a,"colorLabel")].filter(Boolean).join(" \xB7 ")} </span>${typeof a.color=="number"?be.html`<span class="ctb">${this.t("Color {{color}} \xB7 Tone {{tone}} \xB7 Base {{base}}",{color:a.color,tone:a.tone??"",base:a.base??""})}${t?`, ${t}`:""}</span>`:be.nothing} ${a.activation?.planet?be.html`<span class="ctb">${[y(a.activation,"planet"),Wi(a.activation.side,this.translator)].filter(Boolean).join(" \xB7 ")}</span>`:be.nothing} ${a.confident===false?be.html`<span class="note" role="note">${this.t("Knife-edge: could flip with a more precise birth time.")}</span>`:be.nothing}</div>`}renderReading(a,e){let t=a.filter(i=>i.description||i.colorMeaning);if(t.length===0||this.hideReadings)return be.nothing;let r=new Map;for(let i of t){let o=i.layer??"",l=r.get(o);l?l.push(i):r.set(o,[i])}let s=0;return be.html`<section class="block" part="section readings"><h3>${this.t("Reading")}</h3>${[...r].map(([i,o])=>be.html`<div class="group">${i?be.html`<p class="group-head">${y(o[0],"layer")}</p>`:be.nothing} ${o[0]?.layerDescription?be.html`<p class="group-note">${o[0].layerDescription}</p>`:be.nothing} ${o.map(l=>this.renderArrowReading(l,s++===0))}</div>`)} ${e?be.html`<p class="footnote">${this.t("Base")}. ${e}</p>`:be.nothing}</section>`}renderArrowReading(a,e){let t=a.cognition,r=t?y(t,"label"):"",s=[{label:this.t("Color"),body:a.colorMeaning},{label:this.t("Tone"),body:a.toneMeaning},{label:this.t("Direction"),body:a.directionMeaning},{label:r?`${this.t("Cognition")} \xB7 ${r}`:this.t("Cognition"),body:t?.description}].filter(i=>!!i.body);return be.html`<details class="interp-card" part="reading" name="hd-variable" ?open="${e}"><summary><span class="interp-lead">${y(a,"name")}</span> ${he()} ${a.position?be.html`<span class="interp-aside"><small>${y(a,"position")}</small></span>`:be.nothing}</summary><div class="interp-body">${a.description?be.html`<p>${a.description}</p>`:be.nothing} ${s.length>0?be.html`<dl class="facets">${s.map(i=>be.html`<dt>${i.label}</dt><dd>${i.body}</dd>`)}</dl>`:be.nothing}</div></details>`}};Mr.endpoints=Cl,Mr.styles=[u,W,me,be.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.grid{gap:0 var(--roxy-space-lg);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.arrow{align-content:start;gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.arrow-head{align-items:center;gap:var(--roxy-space-sm);display:flex}.glyph{font-size:var(--roxy-text-xl);color:var(--roxy-accent-ink);line-height:1}.glyph.design{color:var(--roxy-danger-fg)}.glyph.personality{color:var(--roxy-fg)}.name{font-weight:var(--roxy-weight-bold)}.layer,.ctb{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.ctb{font-variant-numeric:tabular-nums}.labels{font-size:var(--roxy-text-sm)}.note{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs)}@container (width<=28rem){.grid{grid-template-columns:minmax(0,1fr)}}.group+.group{margin-block-start:var(--roxy-space-md)}.group-head{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-note,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.group-note{margin-block-end:var(--roxy-space-sm)}.facets{gap:var(--roxy-space-xs);margin:0;display:grid}.facets dd{margin:0}`],Mr=m([f("roxy-hd-variables")],Mr);function Up(n){switch(n){case"Top left":return 0;case"Top right":return 1;case"Bottom left":return 2;case"Bottom right":return 3;default:return 99}}var wt=require("lit");var Oy={udaya:"Rose",asta:"Set"},Iy={udaya:"rises",asta:"sets"},_r=class extends g{renderData(a){let e=a.grahas??[];return e.length?wt.html`<div class="wrap" part="card" aria-label="${this.t("Heliacal visibility")}"><header class="head" part="header"><h2>${this.t("Heliacal rising and setting")}</h2><p class="sub">${this.t("Whether each graha stands far enough from the Sun to be seen, for {{date}}. The Sun and the nodes never appear here: they have no heliacal event.",{date:a.date})}</p></header><div part="table">${e.map(t=>this.renderGraha(t))}</div></div>`:this.renderEmpty()}renderGraha(a){let e=S(a.graha)??"";return wt.html`<article class="row"><div class="row-top"><span class="graha">${e?wt.html`<span class="glyph">${e}</span>`:wt.nothing}${a.graha} </span><span class="state roxy-chip ${a.visible?"visible":"invisible"}" data-tone="${a.visible?wt.nothing:"warning"}">${a.visible?this.t("Visible"):this.t("Invisible")} </span>${a.retrograde?wt.html`<span class="retro" title="${this.t("retrograde")}">R</span>`:wt.nothing}</div><p class="window" part="window">${this.windowLine(a)}</p><p class="meta" part="details">${this.metaLine(a)}</p></article>`}windowLine(a){let e=a.nextEvent,t=a.lastEvent;if(e){let r={event:this.t(Iy[e.type]),where:e.horizon==="east"?this.t("in the east"):this.t("in the west"),when:ue(this.effectiveLang(),e.datetime)};return wt.html`${a.visible?this.t("Visible until it {{event}} {{where}} on {{when}}",r):this.t("Invisible until it {{event}} {{where}} on {{when}}",r)}`}return t?wt.html`${this.t("{{event}} {{where}} on {{when}}, with no further event inside the search window",{event:this.t(Oy[t.type]),where:t.horizon==="east"?this.t("in the east"):this.t("in the west"),when:ue(this.effectiveLang(),t.datetime)})}`:wt.html`${this.t("No rising or setting inside the search window, which is normal for a graha far from the Sun")}`}metaLine(a){let e=a.horizon==="east"?this.t("a morning graha, read before sunrise"):this.t("an evening graha, read after sunset"),t=a.nextEvent??a.lastEvent,r=t&&t.kalamsa!==a.kalamsa,s={degrees:b(this.effectiveLang(),a.timeDegrees,2),limit:b(this.effectiveLang(),a.kalamsa,0),shifted:r?b(this.effectiveLang(),t.kalamsa,0):""};return wt.html`${r?this.t("{{degrees}}\xB0 of time from the Sun against a limit of {{limit}}\xB0, becoming {{shifted}}\xB0 at that event",s):this.t("{{degrees}}\xB0 of time from the Sun against a limit of {{limit}}\xB0",s)} · ${e}`}};_r.endpoints=Tl,_r.styles=[u,wt.css`.wrap{overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);display:grid}h2,p{margin:0}.sub,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.window{font-size:var(--roxy-text-sm)}`],_r=m([f("roxy-heliacal-table")],_r);var oe=require("lit");var Nr=class extends g{resolveHexagram(){let a=this.data;if(!a)return null;if("hexagram"in a&&a.hexagram){if("lines"in a){let s=a,i=s.hexagram;return{hex:i,lines:s.lines,date:s.date,changingLinePositions:s.changingLinePositions,changingLines:s.changingLines??i.changingLines,resultingHexagram:s.resultingHexagram}}let t=a,r=t.hexagram;return{hex:r,changingLines:r.changingLines,dailyMessage:t.dailyMessage,date:t.date}}let e=a;return{hex:e,changingLines:e.changingLines}}renderData(){let a=this.resolveHexagram();if(!a)return this.renderEmpty();let{hex:e,lines:t,changingLinePositions:r,changingLines:s,dailyMessage:i,date:o,resultingHexagram:l}=a;return oe.html`<article class="card" part="card" aria-label="${this.t("I Ching hexagram")}">${this.renderHexagram("hexagram",e,t,r,s,i,o)} ${l?oe.html`<details class="result" part="section resulting-hexagram"><summary>${this.t("Becomes hexagram {{number}} {{name}}.",{number:l.number,name:l.english??l.chinese??""})}${he()}</summary><div class="result-chart">${this.renderHexagram("result",l)}</div></details>`:oe.nothing}</article>`}renderHexagram(a,e,t,r,s,i,o){let l=t??this.derivedLines(e),c=new Set(r??[]),d=!this.hideReadings;return oe.html`<div class="glyphs" part="chart">${e.symbol?oe.html`<div class="symbol">${e.symbol}</div>`:oe.nothing} ${l.length>0?oe.html`<div class="lines" aria-hidden="true">${l.slice().reverse().map((p,h)=>{let x=l.length-1-h+1,$=c.has(x),L=p===6||p===8;return oe.html`<div class="line ${`${L?"broken":"solid"}${$?" changing":""}`}">${L?oe.html`<span class="seg"></span><span class="seg"></span>`:oe.html`<span class="seg"></span>`}</div>`})}</div>`:oe.nothing}</div><div part="header"><h2>${[e.number!=null?`${e.number}.`:"",e.english??e.chinese??this.t("I Ching hexagram")].filter(Boolean).join(" ")}</h2>${o?oe.html`<time class="daily-date" part="details" datetime="${o}">${M(this.effectiveLang(),o)}</time>`:oe.nothing}<p class="subtitle">${e.chinese?oe.html`${e.chinese}`:oe.nothing} ${e.pinyin?oe.html`· ${e.pinyin}`:oe.nothing}</p><div class="trigrams roxy-label" part="details">${e.upperTrigram?oe.html`<div>${this.t("Upper")} <span class="tri-glyph">${zi(e.upperTrigram)??""}</span>${e.upperTrigram}</div>`:oe.nothing} ${e.lowerTrigram?oe.html`<div>${this.t("Lower")} <span class="tri-glyph">${zi(e.lowerTrigram)??""}</span>${e.lowerTrigram}</div>`:oe.nothing}</div>${e.judgment&&d?oe.html`<p class="judgment">${e.judgment}</p>`:oe.nothing} ${e.image&&d?oe.html`<p class="image">${e.image}</p>`:oe.nothing} ${i&&d?oe.html`<p class="message">${i}</p>`:oe.nothing} ${e.interpretation?.general&&d?oe.html`<p>${e.interpretation.general}</p>`:oe.nothing} ${c.size>0?oe.html`<div class="changes" part="section changing-lines">${this.t("Changing lines: {{lines}}.",{lines:Array.from(c).sort((p,h)=>p-h).join(", ")})}</div>`:oe.nothing} ${this.renderTopics(e,a)} ${this.renderLines(s??e.changingLines,c,`${a}-lines`)}</div>`}renderTopics(a,e){let t=a.interpretation;return t?this.renderInterpretation([{label:this.t("Love"),body:t.love??""},{label:this.t("Career"),body:t.career??""},{label:this.t("Decision"),body:t.decision??""},{label:this.t("Advice"),body:t.advice??""}].filter(r=>r.body),`${e}-topics`,"Readings"):oe.nothing}renderLines(a,e,t){let r=a??[];if(r.length===0)return oe.nothing;let s=e.size>0,i=s?r.filter(l=>e.has(l.position)):r;if(i.length===0)return oe.nothing;let o=i.map(l=>({label:`Line ${l.position}`,body:l.text??"",extra:l.meaning?oe.html`<p class="line-meaning">${l.meaning}</p>`:oe.nothing}));return this.renderInterpretation(o,t,s?"Changing lines":"Lines")}derivedLines(a){let e=a.binary??"";return/^[01]{6}$/.test(e)?Array.from(e,t=>t==="1"?7:8):[]}};Nr.endpoints=El,Nr.styles=[u,W,me,oe.css`.card{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,4lh) minmax(0,1fr);display:grid}.result-chart{gap:var(--roxy-space-lg);grid-template-columns:minmax(0,4lh) minmax(0,1fr);padding-block-start:var(--roxy-space-md);display:grid}.result{border-block-start:1px solid var(--roxy-border);grid-column:1/-1;padding-block-start:var(--roxy-space-md)}.result>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}@container (width<=480px){.card,.result-chart{grid-template-columns:minmax(0,1fr)}}h2,p{margin:0}.glyphs{align-content:start;align-self:start;justify-items:center;gap:var(--roxy-space-md);display:grid}.symbol{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);line-height:1}.lines{gap:calc(var(--roxy-space-unit) * 1.5);inline-size:2lh;display:grid}.line{gap:var(--roxy-space-xs);grid-template-columns:1fr 1fr;display:grid}.seg{block-size:calc(var(--roxy-line-thick) * 3);background:var(--roxy-fg);display:block}.line.solid .seg{grid-column:1/-1}.line.changing .seg{background:var(--roxy-accent)}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm)}.daily-date{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm);display:block}.trigrams{gap:var(--roxy-space-md);flex-wrap:wrap;margin-block-end:var(--roxy-space-sm);display:flex}.tri-glyph{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);vertical-align:middle;margin-inline-end:var(--roxy-space-xs)}.judgment,.image,.message{font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm)}.judgment:before{content:"Judgment. ";color:var(--roxy-secondary);font-weight:var(--roxy-weight-bold)}.image:before{content:"Image. ";color:var(--roxy-secondary);font-weight:var(--roxy-weight-bold)}.line-meaning{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);color:var(--roxy-muted);padding-inline-start:var(--roxy-space-sm)}.changes{border-block-start:1px solid var(--roxy-border);color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-md);padding-block-start:var(--roxy-space-md)}`],Nr=m([f("roxy-hexagram")],Nr);var Zt=require("lit");var zr=class extends g{renderData(a){let e=a.dayHoras??[],t=a.nightHoras??[];return e.length===0&&t.length===0?this.renderEmpty():Zt.html`<div class="wrap" part="card" aria-label="${this.t("Hora periods")}"><div class="head" part="header"><h2>${this.t("Hora")}</h2>${a.date?Zt.html`<p class="roxy-label">${M(this.effectiveLang(),a.date)}</p>`:Zt.nothing}</div><div class="cols" part="table">${this.renderColumn(this.t("Daytime"),e)} ${this.renderColumn(this.t("Night"),t)}</div></div>`}renderColumn(a,e){return e.length===0?Zt.nothing:Zt.html`<div class="col"><h3 class="section-label">${a}</h3>${e.map(t=>Zt.html`<div class="row"><span class="glyph" aria-hidden="true">${S(t.planet)??"\xB7"}</span> <span class="planet">${t.planet}</span> <span class="time">${na(this.effectiveLang(),t)}</span> ${typeof t.number=="number"?Zt.html`<span class="num">${t.number}</span>`:Zt.nothing}</div>`)}</div>`}};zr.endpoints=Dl,zr.styles=[u,Zt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.cols{gap:var(--roxy-space-md);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.section-label{margin-block-end:var(--roxy-space-xs)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-xs);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;display:flex}.row:last-child{border-block-end:0}.glyph{inline-size:2ch;color:var(--roxy-accent-ink);font-size:var(--roxy-text-base);text-align:center;line-height:1}.planet{flex:1}.time{color:var(--roxy-muted);white-space:nowrap}.num{inline-size:3ch;color:var(--roxy-muted);font-size:var(--roxy-text-xs);text-align:end}@container (width<=30rem){.cols{grid-template-columns:minmax(0,1fr)}}`],zr=m([f("roxy-hora-table")],zr);var w=require("lit"),ko=require("lit/decorators.js");var Gy={daily:"Daily",weekly:"Weekly",monthly:"Monthly",yearly:"Yearly"},Fy={aspect:"Aspect","sign-ingress":"Sign ingress","retrograde-station":"Retrograde station","lunar-phase":"Lunar phase",eclipse:"Eclipse","solar-season":"Solar season"},By=[["love","Love"],["career","Career"],["health","Health"],["finance","Finance"],["advice","Advice"]],Hy=[["love","Love"],["career","Career"],["health","Health"],["finance","Finance"]],ma=class extends g{constructor(){super(...arguments);this.period="daily";this.layout="auto"}renderData(e){let t=e.sign??"",r=Z(t)??"",s="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,i=this.effectiveLang(),o="date"in e&&e.date&&M(i,e.date)||"week"in e&&e.week&&M(i,e.week)||"month"in e&&e.month&&Ja(i,e.month,"month")||("year"in e&&e.year?String(e.year):"")||"";return w.html`<article class="card" part="card" aria-labelledby="horoscope-title"><header class="head" part="header"><span class="glyph" aria-hidden="true">${r}</span><div><h2 class="title" id="horoscope-title">${t} ${this.t(Gy[this.period])}</h2>${o?w.html`<p class="date roxy-label">${o}</p>`:w.nothing}</div>${s!==null?w.html`<span class="energy" part="details" aria-label="${this.t("Energy {{value}} of 10",{value:s})}">${this.t("Energy {{value}}/10",{value:s})} <span class="energy-bar"><span style="width:${s/10*100}%"></span></span></span>`:w.nothing}</header>${this.renderReading(e)} ${this.renderSky(e)} ${this.renderEvents(e.events)} ${this.renderYear(e)} ${this.renderMonth(e)} ${(()=>{let l="luckyNumber"in e&&e.luckyNumber!==void 0?e.luckyNumber:void 0,c="luckyColor"in e&&e.luckyColor?e.luckyColor:"",d="luckyNumbers"in e&&e.luckyNumbers?e.luckyNumbers:[],p="luckyDays"in e&&e.luckyDays?e.luckyDays:[],h=e.compatibleSigns??[];return l===void 0&&!c&&d.length===0&&p.length===0&&h.length===0?w.nothing:w.html`<div class="lucky" part="details">${l!==void 0?w.html`<span>${this.t("Lucky number")} <strong>${l}</strong></span>`:w.nothing} ${c?w.html`<span>${this.t("Lucky color")} <strong>${c}</strong></span>`:w.nothing} ${d.length?w.html`<span>${this.t("Lucky numbers")} <strong>${d.join(", ")}</strong></span>`:w.nothing} ${p.length?w.html`<span>${this.t("Lucky days")} <strong>${p.join(", ")}</strong></span>`:w.nothing} ${h.length?w.html`<span class="compat-wrap">${this.t("Best with")}<ul class="compat roxy-chips">${h.map(x=>w.html`<li>${x}</li>`)}</ul></span>`:w.nothing}</div>`})()}</article>`}renderReading(e){if(this.hideReadings)return w.nothing;if(this.layout==="column"||this.layout==="auto"&&!!e.column)return e.column?this.renderColumn(e.column):w.nothing;let r=this.paragraphs(e.overview);return w.html`${r.length?w.html`<div class="overview" part="section overview">${r}</div>`:w.nothing}<div class="sections" part="section outlook">${By.map(([s,i])=>{let o=this.paragraphs(e[s]);return o.length?w.html`<div class="section"><h3>${this.t(i)}</h3>${o}</div>`:w.nothing})}</div>`}renderColumn(e){let t=this.paragraphs(e);return t.length===0?w.nothing:w.html`<div class="column" part="section column">${t}</div>`}paragraphs(e){return(e??"").split(/\n\s*\n/).map(t=>t.trim()).filter(Boolean).map(t=>w.html`<p>${t}</p>`)}renderEvents(e){if(!e?.length)return w.nothing;let t=this.effectiveLang();return w.html`<section part="section events"><h3>${this.t("Events")}</h3><ul class="rows" aria-label="${this.t("Events")}">${e.map(r=>this.renderRow(w.html`<time class="row-when" datetime="${r.at}">${Ja(t,r.at,"time")}</time>`,this.renderEventBodies(r),w.html`<span class="kind">${this.t(Fy[r.type])}</span> <span>${this.t("House")} ${r.house}</span> ${r.sign?w.html`<span>${this.glyphName(Z(r.sign),V(r.sign))}</span>`:w.nothing} ${r.through?w.html`<span>${this.t("through {{date}}",{date:M(t,r.through)})}</span>`:w.nothing}`,{when:"element"}))}</ul></section>`}renderEventBodies(e){let t=(e.bodies??[]).map(r=>this.glyphName(S(r),r));return t.length===2&&e.aspect?w.html`${t[0]} <span class="${Ze({type:e.aspect})}">${Cs(e.aspect)??e.aspect}</span> ${t[1]}`:w.html`${t}`}renderYear(e){if(!("themes"in e))return w.nothing;let t=this.effectiveLang();return w.html`${e.themes.length?w.html`<section part="section themes"><h3>${this.t("Themes")}</h3><ul class="rows">${e.themes.map(r=>this.renderRow(Ct(t,r.from,r.to),w.html`${this.glyphName(S(r.body),r.body)} ${this.glyphName(Z(r.sign),V(r.sign))}`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${e.keyPeriods.length?w.html`<section part="section key-periods"><h3>${this.t("Key periods")}</h3><ul class="rows">${e.keyPeriods.map(r=>this.renderRow(Ct(t,r.from,r.to),this.glyphName(S(r.body),r.body),w.html`<span>${this.t("House")} ${r.house}</span><span>${r.focus}</span>`))}</ul></section>`:w.nothing} ${e.eclipses.length?w.html`<section part="section eclipses"><h3>${this.t("Eclipses")}</h3><ul class="rows">${e.eclipses.map(r=>this.renderRow(M(t,r.date),w.html`<span class="name">${r.kind}</span>`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${e.retrogrades.length?w.html`<section part="section retrogrades"><h3>${this.t("Retrogrades")}</h3><ul class="rows">${e.retrogrades.map(r=>this.renderRow(M(t,r.date),w.html`${this.glyphName(S(r.body),r.body)} <span>${r.direction}</span>`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${this.renderBestPeriods(e.bestPeriods)}`}renderBestPeriods(e){if(!e)return w.nothing;let t=this.effectiveLang(),r=Hy.filter(([s])=>e[s]);return r.length===0?w.nothing:w.html`<section part="section best-periods"><h3>${this.t("Best months")}</h3><div class="tiles" part="details">${r.map(([s,i])=>{let o=e[s];return o?w.html`<div class="tile"><span class="roxy-label">${this.t(i)}</span> <span class="tile-value">${Ja(t,o.from,"month")}</span> <span class="tile-note">${this.t("{{count}} harmonious aspects",{count:o.count})}</span></div>`:w.nothing})}</div></section>`}renderRow(e,t,r,s){return w.html`<li class="row" part="label-track">${s?.when==="element"?e:w.html`<span class="row-when">${e}</span>`} <span class="row-what">${t}</span> <span class="row-meta">${r}</span></li>`}glyphName(e,t){return w.html`<span aria-hidden="true">${e??""}</span> <span class="name">${t}</span>`}renderSky(e){let t="moonSign"in e?e.moonSign:"",r="moonPhase"in e?e.moonPhase:"",s=("activeTransits"in e?e.activeTransits:[])??[];if(!t&&!r&&s.length===0)return w.nothing;let i=Z(t)??"";return w.html`<div class="sky" part="section sky">${t||r?w.html`<div class="moon-line">${t?w.html`<span><span class="roxy-label">${this.t("Moon")}</span> <span aria-hidden="true">${i}</span> <b>${t}</b></span>`:w.nothing} ${r?w.html`<span><span class="roxy-label">${this.t("Phase")}</span> <b>${r}</b></span>`:w.nothing}</div>`:w.nothing} ${s.length?w.html`<ul class="transits" aria-label="${this.t("Active transits")}">${s.map(o=>w.html`<li>${o}</li>`)}</ul>`:w.nothing}</div>`}renderMonth(e){let t=("weekByWeek"in e?e.weekByWeek:[])??[],r=("keyDates"in e?e.keyDates:[])??[];return t.length===0&&r.length===0?w.nothing:w.html`${t.length&&!this.hideReadings?w.html`<section part="section week-by-week"><h3>${this.t("Week by week")}</h3><div class="weeks">${t.map(s=>w.html`<div class="week"><span class="roxy-label">${this.t("Week {{n}}",{n:s.week})}</span><div><div class="week-focus">${s.focus}</div>${s.advice?w.html`<p class="week-advice">${s.advice}</p>`:w.nothing}</div></div>`)}</div></section>`:w.nothing} ${r.length?w.html`<section part="section key-dates"><h3>${this.t("Key dates")}</h3><dl class="dates" part="label-track">${r.map(s=>w.html`<div class="date-row"><dt>${M(this.effectiveLang(),s.date)||s.date}</dt><dd>${s.event}</dd></div>`)}</dl></section>`:w.nothing}`}};ma.endpoints=Al,ma.styles=[u,$a,xr,w.css`.card{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.glyph{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);line-height:1}.title{text-transform:capitalize;white-space:nowrap}.energy{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;margin-inline-start:auto}.energy-bar{inline-size:10ch;block-size:var(--roxy-space-sm);background:var(--roxy-border);border-radius:var(--roxy-radius-full);vertical-align:middle;margin-inline-start:var(--roxy-space-xs);display:inline-block;overflow:hidden}.energy-bar>span{background:var(--roxy-accent);height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.column p,.overview p,.section p{line-height:1.7}.overview,.column,.section{align-content:start;gap:var(--roxy-space-sm);display:grid}.column{gap:var(--roxy-space-md)}.sections{gap:var(--roxy-space-lg) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,48ch),1fr));display:grid}.section p{font-size:var(--roxy-text-sm)}.sky,.lucky{border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);padding-block-start:var(--roxy-space-md)}.sky{gap:var(--roxy-space-sm);display:grid}.lucky{gap:var(--roxy-space-sm) var(--roxy-space-md);color:var(--roxy-secondary);flex-wrap:wrap;display:flex}.lucky strong{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.compat-wrap{align-items:center;gap:var(--roxy-space-xs);flex-wrap:wrap;width:100%;display:flex}.compat>li{text-transform:capitalize}.moon-line{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.moon-line b{font-weight:var(--roxy-weight-bold)}.moon-line .roxy-label{margin-inline-end:var(--roxy-space-xs)}.transits{gap:var(--roxy-space-xs);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.transits li::marker{color:var(--roxy-accent)}.weeks{gap:var(--roxy-space-sm);display:grid}.week{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.week:first-child{border-block-start:0;padding-block-start:0}.week-focus{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.week-advice{font-size:var(--roxy-text-sm);margin-block-start:calc(var(--roxy-space-unit) / 2)}.dates{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);margin:0;display:grid}.date-row{display:contents}.date-row dt{color:var(--roxy-accent-ink);font-size:inherit;font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.date-row dd{margin:0}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.row:first-child{border-block-start:0;padding-block-start:0}.row-when{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.row-what{font-size:var(--roxy-text-sm)}.row-what .name,.row-meta .kind{font-weight:var(--roxy-weight-bold)}.row-meta{gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;grid-column:2;display:flex}@container (width<=30rem){.row-meta{grid-column:1}}.tiles{gap:var(--roxy-space-sm) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));display:grid}.tile{gap:calc(var(--roxy-space-unit) / 2);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.tile-value{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.tile-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],m([(0,ko.property)({type:String,reflect:true})],ma.prototype,"period",2),m([(0,ko.property)({type:String,reflect:true})],ma.prototype,"layout",2),ma=m([f("roxy-horoscope-card")],ma);var ee=require("lit"),Yp=require("lit/decorators.js");var jy=[{id:"planets",label:"Planets"},{id:"cusps",label:"Cusps"},{id:"significators",label:"Significators"}],ii=[1,2,3,4];function So(n,a){return n?typeof a=="number"?`${n} ${a}`:n:""}function qp(n){return[...new Set(n.map(String))].join(" > ")}function Ky(n){return[...new Set(n??[])]}var _a=class extends g{constructor(){super(...arguments);this.activeTab="planets"}bodies(){let e=this.data;if(!e)return[];let t=(e.planets??[]).map(s=>({name:s.planet,longitude:s.longitude,house:s.house,nakshatra:s.nakshatra,pada:s.pada,starLord:s.starLord,subLord:s.subLord,subSubLord:s.subSubLord,kpNumber:s.kpNumber,retrograde:s.retrograde})),r=e.nodes;for(let[s,i]of[["Rahu",r?.rahu],["Ketu",r?.ketu]])i&&t.push({name:s,longitude:i.longitude,house:i.house,nakshatra:i.nakshatra,pada:i.pada,starLord:i.starLord,subLord:i.subLord,subSubLord:i.subSubLord,kpNumber:i.kpNumber,retrograde:true});return t}renderData(e){let t=e.ascendant;return ee.html`<div class="wrap" part="card" aria-label="KP chart"><header class="head" part="header"><h2 class="title">KP chart</h2>${t?ee.html`<div class="asc">Ascendant: <strong>${typeof t.longitude=="number"?lt(t.longitude):t.sign??""} </strong>${t.nakshatra?ee.html`· ${So(t.nakshatra,t.pada)}`:ee.nothing} ${t.subLord?ee.html`· sub lord ${t.subLord}`:ee.nothing} ${typeof t.kpNumber=="number"?ee.html`· KP ${t.kpNumber}`:ee.nothing}</div>`:ee.nothing} ${typeof e.meta?.ayanamsa=="number"?ee.html`<div class="ayan">Ayanamsa: ${is(this.effectiveLang(),e.meta.ayanamsaType,e.meta.ayanamsa)} ${e.meta.houseSystem?ee.html`· ${e.meta.houseSystem} houses`:ee.nothing}</div>`:ee.nothing}</header>${gt({items:jy,active:this.activeTab,onSelect:r=>{this.activeTab=r},label:"KP chart views",idPrefix:"kp",controls:true})}<div id="kp-panel-${this.activeTab}" part="panel" role="tabpanel" aria-labelledby="kp-tab-${this.activeTab}">${this.activeTab==="planets"?this.renderPlanets():this.activeTab==="cusps"?this.renderCusps():this.renderSignificators()}</div></div>`}renderPlanets(){let e=this.bodies();return e.length?this.scrollBox(ee.html`<table part="table" role="table"><caption id="kp-planets-caption" class="roxy-sr-only">KP planets and nodes: each body with its position, house, nakshatra and pada, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">Position</th><th scope="col">House</th><th scope="col">Nakshatra, pada</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(t=>ee.html`<tr><td class="body">${t.name}${t.retrograde?ee.html`<span class="retro">R</span>`:ee.nothing}</td><td class="num">${typeof t.longitude=="number"?lt(t.longitude):""}</td><td class="num">${typeof t.house=="number"?t.house:""}</td><td>${So(t.nakshatra,t.pada)}</td><td>${t.starLord??""}</td><td>${t.subLord??""}</td><td>${t.subSubLord??""}</td><td class="num">${typeof t.kpNumber=="number"?t.kpNumber:""}</td></tr>`)}</tbody></table>`,"kp-planets-caption"):ee.html`<p class="roxy-empty" role="status">No planets</p>`}renderCusps(){let e=this.data?.cusps??[],t=this.data?.houseThemes;return e.length?this.scrollBox(ee.html`<table part="table" role="table"><caption id="kp-cusps-caption" class="roxy-sr-only">KP Placidus cusps: each house cusp with what it signifies, its position, sign lord, nakshatra and pada, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">House</th><th scope="col">Position</th><th scope="col">Sign lord</th><th scope="col">Nakshatra, pada</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(r=>ee.html`<tr><td class="body num">${r.house}${this.renderThemes(Gi(r.house,t))}</td><td class="num">${typeof r.longitude=="number"?lt(r.longitude):r.sign??""}</td><td>${r.signLord??""}</td><td>${So(r.nakshatra,r.pada)}</td><td>${r.starLord??""}</td><td>${r.subLord??""}</td><td>${r.subSubLord??""}</td><td class="num">${typeof r.kpNumber=="number"?r.kpNumber:""}</td></tr>`)}</tbody></table>`,"kp-cusps-caption"):ee.html`<p class="roxy-empty" role="status">No cusps</p>`}renderSignificators(){let e=this.data?.significators,t=this.data?.houseThemes,r=e?.houseWise??[],s=e?.planetWise??[];return!r.length&&!s.length?ee.html`<p class="roxy-empty" role="status">No significators</p>`:ee.html`${this.renderLevelLegend(r)} ${r.length?ee.html`<div class="sig-head"><h3 class="sig-title">House-wise significators</h3><p class="sig-note">Planets that signify each house, strongest level first.</p></div>${this.scrollBox(ee.html`<table part="table" role="table"><caption id="kp-house-sig-caption" class="roxy-sr-only">KP house-wise significators: each house, the planets that signify it at levels 1 to 4, and the full strength order.</caption><thead><tr><th scope="col">House</th>${ii.map(i=>ee.html`<th scope="col">L${i}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${r.map(i=>ee.html`<tr><td class="body num">${i.house}${this.renderThemes(Gi(i.house,t))}</td>${ii.map(o=>this.renderCell(this.planetsAtLevel(i,o).join(", ")))}<td class="chain">${qp(i.all??[])}</td></tr>`)}</tbody></table>`,"kp-house-sig-caption")}`:ee.nothing} ${s.length?ee.html`<div class="sig-head"><h3 class="sig-title">Planet-wise significators</h3><p class="sig-note">Houses each planet signifies, strongest level first.</p></div>${this.scrollBox(ee.html`<table part="table" role="table"><caption id="kp-planet-sig-caption" class="roxy-sr-only">KP planet-wise significators: each planet, the houses it signifies at levels 1 to 4, and the full strength order.</caption><thead><tr><th scope="col">Planet</th>${ii.map(i=>ee.html`<th scope="col">L${i}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${s.map(i=>ee.html`<tr><td class="body">${i.planet}</td>${ii.map(o=>this.renderCell(this.housesAtLevel(i,o).join(", ")))}<td class="chain">${qp(i.allHouses??[])}${this.renderThemes(ca(Ky(i.allHouses),t))}</td></tr>`)}</tbody></table>`,"kp-planet-sig-caption")}`:ee.nothing}`}scrollBox(e,t){return ee.html`<div class="scroll" tabindex="0" role="region" aria-labelledby="${t}">${e}</div>`}renderThemes(e){return e?ee.html`<span class="themes">${e}</span>`:ee.nothing}renderCell(e){return e?ee.html`<td>${e}</td>`:ee.html`<td class="empty-cell">none</td>`}planetsAtLevel(e,t){return(e.significators??[]).filter(r=>r.level===t).flatMap(r=>r.planets??[])}housesAtLevel(e,t){return(e.signifies??[]).filter(r=>r.level===t).flatMap(r=>r.houses??[])}renderLevelLegend(e){let t=new Map;for(let r of e)for(let s of r.significators??[])s.description&&!t.has(s.level)&&t.set(s.level,s.description);return t.size===0?ee.nothing:ee.html`<ul class="legend" part="legend" aria-label="Significator levels">${[...t.entries()].sort((r,s)=>r[0]-s[0]).map(([r,s])=>ee.html`<li><b>L${r}</b>${s}</li>`)}</ul>`}};_a.endpoints=Pl,_a.styles=[u,ot,ee.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.sig-title,.sig-note{margin:0}.asc,.ayan{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.asc strong{color:var(--roxy-fg)}[role=tabpanel]:not([hidden]){gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.body{font-weight:var(--roxy-weight-bold)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.num{font-variant-numeric:tabular-nums}.sig-head{gap:var(--roxy-space-xs);display:grid}.sig-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.legend b{color:var(--roxy-accent-ink);margin-inline-end:var(--roxy-space-xs)}.chain,.empty-cell{color:var(--roxy-muted)}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-normal);display:block}`],m([(0,Yp.state)()],_a.prototype,"activeTab",2),_a=m([f("roxy-kp-chart")],_a);var xe=require("lit");var Vy={strong:"Strong",favourable:"Favourable",mixed:"Mixed",caution:"Caution",unfavourable:"Unfavourable"},Uy={favourable:"Favourable",mixed:"Mixed",unfavourable:"Unfavourable",neutral:"Neutral"},Wp={cusps:"Cusps",dasha:"Dasha",rulingPlanets:"Ruling planets",moonWindows:"Moon windows"},qy={gain:"Gain",loss:"Loss"},Yy={mahadasha:"Mahadasha",antardasha:"Antardasha",pratyantardasha:"Pratyantardasha",sookshmaDasha:"Sookshma"},Or=class extends g{renderData(a){return a.layers?xe.html`<div class="wrap" part="card" aria-label="${this.t("KP daily finance")}">${this.renderHead(a)} ${this.renderSignificators(a)}<section class="block" part="section cusps">${this.renderLayer("cusps",a.layers.cusps,this.renderCuspRows(a.layers.cusps.rows))}</section><section class="block" part="section dasha">${this.renderLayer("dasha",a.layers.dasha,this.renderDashaRows(a.layers.dasha.rows))}</section><section class="block" part="section ruling-planets">${this.renderLayer("rulingPlanets",a.layers.rulingPlanets,this.renderRulingRows(a.layers.rulingPlanets.rows))}</section><section class="block" part="section moon-windows">${this.renderLayer("moonWindows",a.layers.moonWindows,this.renderWindowRows(a.layers.moonWindows.rows))}</section>${this.renderWindows(a)}<section class="block" part="section frame">${ve(this.effectiveLang(),{ayanamsa:a.ayanamsa,ayanamsaDegrees:a.ayanamsaDegrees},this.translator)}</section></div>`:this.renderEmpty()}renderHead(a){let e=this.effectiveLang();return xe.html`<header class="head" part="header"><div class="title-row"><h2 class="title">${this.t("KP daily finance")}</h2><span class="when">${ue(e,a.date)}</span></div><div class="verdict-row"><span class="verdict ${a.band}">${this.t(Vy[a.band])}</span> <span class="evidence">${b(e,a.score,1)}</span></div><dl class="roxy-facts" part="details"><div class="fact"><dt>${this.t("Reading moment")}</dt><dd>${ue(e,a.readingAt)}</dd></div><div class="fact"><dt>${this.t("Gain houses")}</dt><dd>${nt(e,a.houses.gain.map(String))}</dd></div><div class="fact"><dt>${this.t("Loss houses")}</dt><dd>${nt(e,a.houses.loss.map(String))}</dd></div></dl></header>`}renderSignificators(a){let e=a.significators,t=this.effectiveLang(),r=s=>xe.html`<div class="roxy-chips">${s.map(i=>xe.html`<span class="chip roxy-chip">${this.glyphName(i)}</span>`)}</div>`;return xe.html`<section class="block" part="section significators"><h3>${this.t("Significators")}</h3><dl class="roxy-facts"><div class="fact"><dt>${this.t("Gain")}</dt><dd>${r(e.gain)}</dd></div><div class="fact"><dt>${this.t("Loss")}</dt><dd>${r(e.loss)}</dd></div></dl>${e.byHouse.length?xe.html`<div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Significators")}"><table><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Significators")}</th></tr></thead><tbody>${e.byHouse.map(s=>xe.html`<tr><td class="num">${s.house} ${this.groupChip(s.group)}</td><td class="names">${nt(t,[...new Set(s.significators)])}</td></tr>`)}</tbody></table></div>`:xe.nothing}</section>`}renderLayer(a,e,t){let r=this.effectiveLang();return xe.html`<div class="block-head"><h3>${this.t(Wp[a])}</h3><span class="evidence">${this.t("Weight")} ${Oe(r,e.weight,0)} · ${this.t("Score")} ${b(r,e.score,1)}</span></div><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t(Wp[a])}">${t}</div>`}renderCuspRows(a){return xe.html`<table><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Sub lord")}</th><th scope="col">${this.t("Star lord")}</th><th scope="col">${this.t("Sign lord")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(e=>xe.html`<tr><td class="num">${e.house} ${this.groupChip(e.inverted?"loss":"gain")}</td><td>${this.glyphName(e.subLord)}</td><td>${this.glyphName(e.starLord)}</td><td>${this.glyphName(e.signLord)}</td><td>${this.verdictChip(e.verdict)}</td><td class="num">${b(this.effectiveLang(),e.score,0)}</td></tr>`)}</tbody></table>`}renderDashaRows(a){let e=this.effectiveLang();return xe.html`<table><thead><tr><th scope="col">${this.t("Level")}</th><th scope="col">${this.t("Lord")}</th><th scope="col">${this.t("Start")}</th><th scope="col">${this.t("End")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th><th scope="col">${this.t("Weight")}</th></tr></thead><tbody>${a.map(t=>xe.html`<tr><td>${this.t(Yy[t.level])}</td><td>${this.glyphName(t.lord,t.retrograde)}</td><td>${ue(e,t.startDate)}</td><td>${ue(e,t.endDate)}</td><td>${this.verdictChip(t.verdict)}</td><td class="num">${b(e,t.score,0)}</td><td class="num">${Oe(e,t.weight,0)}</td></tr>`)}</tbody></table>`}renderRulingRows(a){return xe.html`<table><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(e=>xe.html`<tr><td>${this.glyphName(e.planet,e.retrograde)}</td><td>${this.verdictChip(e.verdict)}</td><td class="num">${b(this.effectiveLang(),e.score,0)}</td></tr>`)}</tbody></table>`}renderWindowRows(a){let e=this.effectiveLang();return xe.html`<table><thead><tr><th scope="col">${this.t("Start")}</th><th scope="col">${this.t("End")}</th><th scope="col">${this.t("Sub lord")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(t=>xe.html`<tr><td>${Nt(e,t.from)}</td><td>${Nt(e,t.to)}</td><td>${this.glyphName(t.subLord)}</td><td>${this.verdictChip(t.verdict)}</td><td class="num">${b(e,t.score,0)}</td></tr>`)}</tbody></table>`}renderWindows(a){let e=this.effectiveLang(),t=a.bestWindow,r=a.worstWindows??[];if(!t&&!r.length)return xe.nothing;let s=(i,o)=>xe.html`<span class="window roxy-chip ${o}" data-tone="${o==="best"?"success":"danger"}"><span>${this.glyphName(i.subLord)}</span> <small>${na(e,{start:i.from,end:i.to})}</small></span>`;return xe.html`<section class="block" part="section windows"><dl class="roxy-facts">${t?xe.html`<div class="fact"><dt>${this.t("Best window")}</dt><dd><div class="roxy-chips">${s(t,"best")}</div></dd></div>`:xe.nothing} ${r.length?xe.html`<div class="fact"><dt>${this.t("Worst windows")}</dt><dd><div class="roxy-chips">${r.map(i=>s(i,"worst"))}</div></dd></div>`:xe.nothing}</dl></section>`}glyphName(a,e=false){let t=S(a);return xe.html`${t?xe.html`<span class="glyph" aria-hidden="true">${t}</span>`:xe.nothing}${a}${e?xe.html`<span class="retro" aria-label="${this.t("retrograde")}">℞</span>`:xe.nothing}`}verdictChip(a){return xe.html`<span class="state ${a}">${this.t(Uy[a])}</span>`}groupChip(a){return xe.html`<span class="chip roxy-chip">${this.t(qy[a])}</span>`}};Or.endpoints=Ml,Or.styles=[u,Se,ae,xe.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head,.block{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);display:grid}.block{border-block-start:1px solid var(--roxy-border)}.title-row,.block-head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title,.block h3{margin:0}.when{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.verdict-row{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict{font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.evidence{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:is(.verdict,.state):is(.strong,.favourable){color:var(--roxy-success-fg)}:is(.verdict,.state):is(.mixed,.caution){color:var(--roxy-warning-fg)}:is(.verdict,.state).unfavourable{color:var(--roxy-danger-fg)}.state.neutral{color:var(--roxy-secondary)}.state{font-weight:var(--roxy-weight-bold)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td.names{white-space:normal}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}.window small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],Or=m([f("roxy-kp-finance-card")],Or);var ga=require("lit");var Ir=class extends g{renderData(a){let e=a.planets??[];return ga.html`<div class="wrap" part="card" aria-label="KP planets table"><header class="head" part="header"><h2 class="title">KP planets</h2>${typeof a.ayanamsa=="number"?ga.html`<span class="ayanamsa">Ayanamsa: ${b(this.effectiveLang(),a.ayanamsa,2)}°</span>`:ga.nothing}</header><div class="scroll" tabindex="0" role="region" aria-labelledby="kp-planets-table-caption"><table part="table" role="table"><caption id="kp-planets-table-caption" class="roxy-sr-only">KP planets: each planet with its sign, sign lord, nakshatra, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">Planet</th><th scope="col">Sign</th><th scope="col">Sign lord</th><th scope="col">Nakshatra</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(t=>ga.html`<tr><td class="planet">${t.planet} ${t.retrograde?ga.html`<span class="retro">R</span>`:ga.nothing}</td><td>${t.sign??""}</td><td>${t.signLord??""}</td><td>${t.nakshatra??""}</td><td>${t.nakshatraLord??""}</td><td>${t.subLord??""}</td><td>${t.subSubLord??""}</td><td>${t.kpNumber??""}</td></tr>`)}</tbody></table></div></div>`}};Ir.endpoints=_l,Ir.styles=[u,ga.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}.ayanamsa{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.planet{font-weight:var(--roxy-weight-bold)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}`],Ir=m([f("roxy-kp-planets-table")],Ir);var kt=require("lit");var Gr=class extends g{renderData(a){let e=a.significators??[];return kt.html`<div class="wrap" part="card" aria-label="KP ruling planets"><header part="header"><h2 class="title">KP ruling planets</h2>${a.dayLord?kt.html`<div class="day-lord">Day lord: <strong>${a.dayLord}</strong></div>`:kt.nothing}</header><div class="groups" part="details"><div class="group"><h3>Moon</h3><dl part="label-track"><dt>Sign lord</dt><dd>${a.moonSignLord??""}</dd><dt>Star lord</dt><dd>${a.moonStarLord??""}</dd><dt>Sub lord</dt><dd>${a.moonSublord??""}</dd><dt>Sub-sub lord</dt><dd>${a.moonSubSublord??""}</dd></dl></div><div class="group"><h3>Lagna</h3><dl part="label-track"><dt>Sign lord</dt><dd>${a.lagnaSignLord??""}</dd><dt>Star lord</dt><dd>${a.lagnaStarLord??""}</dd><dt>Sub lord</dt><dd>${a.lagnaSublord??""}</dd><dt>Sub-sub lord</dt><dd>${a.lagnaSubSublord??""}</dd></dl></div></div>${a.rulingPlanets?.length?kt.html`<div class="rp-list" part="details"><span class="roxy-label">Ruling planets</span><ol class="roxy-chips" aria-label="Ruling planets by strength">${a.rulingPlanets.map((t,r)=>kt.html`<li class="rp"><span class="rank">${r+1}</span> ${t}</li>`)}</ol></div>`:kt.nothing} ${e.length?kt.html`<table part="table"><caption class="roxy-sr-only">House significators: each ruling planet, the houses it signifies, and what those houses stand for.</caption><thead><tr><th scope="col">Planet</th><th scope="col">Signifies houses</th></tr></thead><tbody>${e.map(t=>{let r=ca(t.signifies,a.houseThemes);return kt.html`<tr><td>${t.planet}</td><td><span class="num">${(t.signifies??[]).join(", ")}</span> ${r?kt.html`<span class="themes">${r}</span>`:kt.nothing}</td></tr>`})}</tbody></table>`:kt.nothing}</div>`}};Gr.endpoints=Nl,Gr.styles=[u,kt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.title,.group h3{margin:0}.day-lord{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.day-lord strong{color:var(--roxy-fg)}.groups{gap:var(--roxy-space-md) var(--roxy-space-xl);flex-wrap:wrap;display:flex}.group{gap:var(--roxy-space-xs);flex:1 1 0;min-width:min(100%,22ch);display:grid}.group dl{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-sm);margin:0;display:grid}.group dd{font-weight:var(--roxy-weight-bold);margin:0}.rp-list{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.rp .rank{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.num{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}`],Gr=m([f("roxy-kp-ruling-planets")],Gr);var de=require("lit"),Zp=require("lit/decorators.js");var Na=class extends g{constructor(){super(...arguments);this.mode="kua"}renderData(e){let t=this.effectiveLang(),r=e.trigram;return de.html`<article class="card" part="card" aria-labelledby="kua-title"><header class="head" part="header"><h2 class="title" id="kua-title">${this.t("Kua")} ${e.kua??""}</h2>${e.group?de.html`<span class="group">${this.t("{{direction}} group",{direction:ie(t,"facing",V(e.group))})}</span>`:de.nothing}</header><div class="facts" part="details">${r?de.html`<span><span class="roxy-label">${this.t("Trigram")}</span> <span lang="zh">${r.chinese??""}</span> ${r.symbol??""} <b>${r.english??""}</b> <span class="element-word ${Et(r.element)}">${y(r,"element")}</span></span>`:de.nothing} ${r?.familyMember?de.html`<span><span class="roxy-label">${this.t("Role")}</span>${r.familyMember}</span>`:de.nothing} ${"solarYear"in e&&typeof e.solarYear=="number"?de.html`<span class="solar-year"><span class="roxy-label">${this.t("Year")}</span><b>${Ja(t,String(e.solarYear),"year")}</b></span>`:de.nothing} ${"gender"in e&&e.gender?de.html`<span class="formula-gender"><span class="roxy-label">${ke(t,"gender")}</span>${ie(t,"gender",e.gender)}</span>`:de.nothing} ${"boundaryDate"in e&&e.boundaryDate?de.html`<span>${this.t("Year boundary")} ${M(t,e.boundaryDate)}</span>`:de.nothing} ${"reassigned"in e&&e.reassigned?de.html`<span>${this.t("Reassigned from {{value}}",{value:String("rawKua"in e?e.rawKua??"":"")})}</span>`:de.nothing} ${this.renderBestWorst(e)}</div><div class="plate" part="chart plate" role="group" aria-label="${this.t("Eight mansions")}">${ei.map(s=>this.renderSector(e,s))}</div><div class="legend" part="legend"><span><span class="swatch swatch-good"></span>${this.t("Favourable")}</span> <span><span class="swatch swatch-bad"></span>${this.t("Unfavourable")}</span></div>${this.renderSectorRows(e)} ${"conventions"in e?tr(e.conventions,this.translator,this.effectiveLang()):de.nothing}</article>`}renderBestWorst(e){if(this.mode!=="mansions"||!("bestSector"in e))return de.nothing;let t=this.effectiveLang();return de.html`${e.bestSector?de.html`<span><span class="roxy-label">${this.t("Best")}</span><b>${ie(t,"facing",e.bestSector)}</b></span>`:de.nothing} ${e.worstSector?de.html`<span><span class="roxy-label">${this.t("Worst")}</span><b>${ie(t,"facing",e.worstSector)}</b></span>`:de.nothing}`}sectorHeading(e,t){return t==="Center"?this.t("Center"):ie(e,"facing",t)}renderSector(e,t){let r=this.effectiveLang(),s=this.sectorHeading(r,t);if(t==="Center")return de.html`<div class="sector sector-self centre"><span class="kua-number">${e.kua??""}</span> <span class="trigram-symbol">${e.trigram?.symbol??""}</span> <span class="sector-name plate-heading">${e.trigram?.english??""}</span></div>`;let i=(e.sectors??[]).find(l=>l.direction===t);if(!i)return de.html`<div class="sector"><span class="sector-name plate-heading">${s}</span></div>`;let o=i.nature==="auspicious";return de.html`<div class="sector ${o?"sector-good":"sector-bad"}"><span class="sector-name plate-heading">${s}</span> <span class="star-name">${y(i,"starName")}</span> ${"chinese"in i&&i.chinese?de.html`<span class="star-hanzi" lang="zh">${i.chinese}</span>`:de.nothing} <span class="domain">${i.domain??""}</span> ${typeof i.rank=="number"?de.html`<span class="rank">${o?this.t("Rank"):this.t("Severity")} ${i.rank}</span>`:de.nothing}</div>`}renderSectorRows(e){let t=e.sectors??[];if(t.length===0)return de.nothing;let r=this.effectiveLang(),s=t.map(i=>{let o=this.mode==="mansions"&&"reading"in i?i.reading:void 0;return!o||this.hideReadings?de.nothing:de.html`<li class="row" part="label-track"><span class="roxy-label">${this.sectorHeading(r,i.direction??"")}</span><div class="row-body"><span>${y(i,"starName")}</span><p part="reading">${o}</p></div></li>`});return s.every(i=>i===de.nothing)?de.nothing:de.html`<section part="section sectors"><h3 class="block-title">${this.t("Sectors")}</h3><ul class="rows">${s}</ul></section>`}};Na.endpoints=zl,Na.styles=[u,la,ae,ti,xr,de.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.group{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.plate{background:var(--roxy-border);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;display:grid;overflow:hidden}.sector{align-content:start;gap:calc(var(--roxy-space-unit) / 2);min-block-size:3.5lh;padding:var(--roxy-space-sm);background:var(--roxy-surface);text-align:center;display:grid}.sector-good{background:color-mix(in srgb, var(--roxy-success) 10%, var(--roxy-surface))}.sector-bad{background:color-mix(in srgb, var(--roxy-danger) 10%, var(--roxy-surface))}.sector-self{background:color-mix(in srgb, var(--roxy-accent) 10%, var(--roxy-surface))}:is(.sector-good,.sector-bad,.sector-self) .sector-name,:is(.sector-good,.sector-bad) .rank{color:var(--roxy-secondary)}.star-name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.star-hanzi,.trigram-symbol{color:var(--roxy-accent-ink)}:is(.sector-good,.sector-bad) .star-hanzi{color:var(--roxy-fg)}.domain{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.rank{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.centre{align-content:center}.kua-number{font-size:calc(var(--roxy-text-base) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.trigram-symbol{font-size:calc(var(--roxy-text-base) * 1.5);line-height:var(--roxy-leading-tight)}@container (width<=30rem){.plate{background:var(--roxy-surface);display:block}.sector.centre{display:none}.sector{column-gap:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"name rank""star hanzi""domain domain";min-block-size:auto}.sector:last-child{border-block-end:0}.sector-name{grid-area:name;align-self:center}.rank{text-align:end;white-space:nowrap;grid-area:rank;align-self:center}.star-name{grid-area:star}.star-hanzi{text-align:end;grid-area:hanzi}.domain{grid-area:domain}}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-good{background:var(--roxy-success)}.swatch-bad{background:var(--roxy-danger)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.row-body p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}`],m([(0,Zp.property)({type:String,reflect:true})],Na.prototype,"mode",2),Na=m([f("roxy-kua-card")],Na);var tt=require("lit");var Ro=320,Xt=Ro/2,za=128,Wy=118,Xp=137,Zy=152,Xy=.95,Jy={glyph:11},Qy=Jy.glyph;function Oa(n,a){let e=n*Math.PI/180;return{x:Xt+a*Math.sin(e),y:Xt-a*Math.cos(e)}}var eu=[{az:0,source:"N"},{az:45,source:"NE"},{az:90,source:"E"},{az:135,source:"SE"},{az:180,source:"S"},{az:225,source:"SW"},{az:270,source:"W"},{az:315,source:"NW"}],Fr=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this)}renderData(e){let t=e.bodies??[],r=e.birthDetails;return tt.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Local space")}</h2>${r?tt.html`<p class="roxy-label">${ue(this.effectiveLang(),r.date,r.time)}</p>`:tt.nothing}</header>${this.chartViewport.renderChartViewport(this.renderDial(t),this.t("Local space"),this.translator)} ${e.summary&&!this.hideReadings?tt.html`<p class="summary">${e.summary}</p>`:tt.nothing} ${this.renderList(t)}</div>`}renderDial(e){return tt.html`<svg viewBox="0 0 ${Ro} ${Ro}" part="chart" role="img" aria-label="${this.t("Local space compass of planetary directions from the birthplace")}"><title>${this.t("Local space compass")}</title><desc>${this.t("A compass centered on the birthplace. Each body is a line pointing to its azimuth, clockwise from north. Bodies below the horizon are dimmed.")}</desc><circle class="dial-fill" cx="${Xt}" cy="${Xt}" r="${za}"/><circle class="dial" cx="${Xt}" cy="${Xt}" r="${za*.66}" stroke-width="0.5"/><circle class="dial" cx="${Xt}" cy="${Xt}" r="${za*.33}" stroke-width="0.5"/>${this.renderCompassRing()} ${this.renderSpokes(e)}<circle class="center-dot" cx="${Xt}" cy="${Xt}" r="2.5"/></svg>`}renderCompassRing(){let e=[];for(let l=0;l<360;l+=22.5){let c=Oa(l,za),d=Oa(l,za-(l%45===0?8:4));e.push(tt.svg`<line class="tick" x1=${d.x} y1=${d.y} x2=${c.x} y2=${c.y} />`)}let t=Oa(0,za),r=Oa(180,za),s=Oa(90,za),i=Oa(270,za),o=eu.map(({az:l,source:c})=>{let d=Oa(l,Zy),p=l%90===0;return tt.svg`<text class=${`compass-label${p?" cardinal":""}`} x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${this.t(c)}</text>`});return tt.svg`
|
|
79
|
+
`}function Iy(s,a){let e=s.lagnaSign.toLowerCase();return R`
|
|
80
|
+
${Oy(s.divisionLabel)}
|
|
81
|
+
${Ie.map(t=>Gy(t,s.placements[t.toLowerCase()]??[],t.toLowerCase()===e,Lo(t,s.lagnaSign),a))}
|
|
82
|
+
`}function $o(s){return uo(s.lagnaSign)!==-1}function Fy(s,a,e){if(a==="north"&&!$o(s))return Rp(s,e);switch(a){case"north":return _y(s,e);case"east":return Iy(s,e);default:return Rp(s,e)}}function Xn(s,a={}){let e=da(a.lang);return R`<svg class="kundli" xmlns=${ca} viewBox=${`0 0 ${jt} ${jt}`} preserveAspectRatio="xMidYMid meet" part="chart" role="img" aria-label=${a.label??e("Vedic birth chart with twelve sign houses")}><title>${a.title??e("Vedic kundli")}</title>${Fy(s,a.style??"north",e)}</svg>`.markup}var By=[{id:"north",source:"North"},{id:"south",source:"South"},{id:"east",source:"East"}];function Hy(s,a){let e=Object.values(s.placements).flat(),t=[];return e.some(r=>r.isRetrograde)&&t.push(`${fo} ${a("retrograde")}`),e.some(r=>r.combust)&&t.push(`${xo} ${a("combust")}`),e.some(r=>r.war)&&t.push(`${bo} ${a("planetary war")}`),t.length===0?ua.nothing:ua.html`<p class="roxy-frame">${t.join(" \xB7 ")}</p>`}function jy(s){return ua.html`<p class="roxy-frame">${s("No ascendant in this chart, so the houses are not numbered.")}</p>`}function Jn(s,a){let e=[];$o(s)||e.push(jy(a));let t=Hy(s,a);return t!==ua.nothing&&e.push(t),e}function Qn(s,a,e){return ut({items:By.map(({id:t,source:r})=>({id:t,label:e(r)})),active:s,onSelect:a,label:e("Kundli style"),idPrefix:"kundli",controls:true})}function Dp(s,a,e,t){return ua.html`<details class="kundli-reference" part="section positions"><summary>${t("Planetary positions")}${he()}</summary><div class="kundli-reference-scroll" part="table" tabindex="0" role="region" aria-label="${t("Planetary positions")}"><table class="kundli-reference-table"><caption class="roxy-sr-only">${t("Planetary positions")}</caption><thead><tr><th scope="col">${t("Body")}</th><th scope="col">D${a} ${t("Sign")}</th><th scope="col">D${a} ${t("House")}</th><th scope="col">D1 ${t("Position")}</th><th scope="col">D1 ${t("Nakshatra")}</th><th scope="col">${t("Pada")}</th><th scope="col">${t("Star lord")}</th><th scope="col">${t("Motion")}</th></tr></thead><tbody>${Object.entries(s).map(([r,n])=>ua.html`<tr><th scope="row">${n.graha??r}</th><td>${n.rashi??""}</td><td>${typeof n.house=="number"?n.house:""}</td><td>${typeof n.longitude=="number"?ua.html`<span>${pt(n.longitude)}</span><small>${b(e,n.longitude,12)}°</small>`:ua.nothing}</td><td>${n.nakshatra?.name??""}</td><td>${n.nakshatra?.pada??""}</td><td>${n.nakshatra?.lord??""}</td><td>${n.isRetrograde?t("retrograde"):""}</td></tr>`)}</tbody></table></div></details>`}var Ap=require("lit"),ei=Ap.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.kundli-reference{min-width:0}.kundli-reference>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}.kundli-reference-scroll{min-width:0;margin-top:var(--roxy-space-sm);overflow-x:auto}.kundli-reference-table{width:100%}.kundli-reference-table :is(th,td){white-space:nowrap}.kundli-reference-table small{color:var(--roxy-secondary);display:block}.header{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,35rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}`;var Ky={number:9,name:"Navamsa"},Pp=s=>"division"in s&&s.division?s.division:Ky,_a=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this);this.chartStyle="north";this.setStyle=e=>{this.chartStyle=e}}viewModel(){if(!this.data?.chart?.meta)return null;let e=Pp(this.data),t=`D${e.number} ${e.name}`;return Zn(this.data.chart.meta,{divisionLabel:t,natalReference:true})}renderData(e){let t=this.viewModel();if(!t)return this.renderEmpty();let r=Pp(e),{vargottama:n}=e;return Zt.html`<div class="wrap" part="card"><div class="header" part="header"><div><h2 class="title">D${r.number} ${r.name} ${Vi(r.name,r.sanskritName)?Zt.html`<span class="division-meta">· ${r.sanskritName}</span>`:Zt.nothing}</h2>${r.significance?Zt.html`<p class="significance">${r.significance}</p>`:Zt.nothing} ${ve(this.effectiveLang(),e.frame,this.translator)} ${Jn(t,this.translator)}</div>${Qn(this.chartStyle,this.setStyle,this.translator)}</div><div id="kundli-panel-${this.chartStyle}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}">${this.chartViewport.renderChartViewport((0,_p.unsafeHTML)(Xn(t,{style:this.chartStyle,lang:this.effectiveLang(),label:this.t("{{chart}} divisional chart with twelve sign houses",{chart:`D${r.number} ${r.name}`}),title:`D${r.number} ${r.name}`})),`D${r.number} ${r.name}`,this.translator)}</div>${Dp(e.chart.meta,r.number,this.effectiveLang(),this.translator)} ${n&&n.length>0?Zt.html`<div class="vargottama-row" part="details"><span class="roxy-label">${this.t("Vargottama")}:</span><ul class="roxy-chips" aria-label="${this.t("Vargottama planets")}">${n.map(i=>Zt.html`<li>${Je(S(i))} ${i}</li>`)}</ul></div>`:Zt.nothing}</div>`}};_a.endpoints=wl,_a.styles=[u,et,re,En,ei,X,dt,Zt.css`.division-meta{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-normal);color:var(--roxy-muted)}.significance{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);font-size:var(--roxy-text-sm);color:var(--roxy-muted);margin:0;padding-inline-start:var(--roxy-space-sm)}.vargottama-row{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}`],m([(0,Mp.property)({type:String,reflect:true,attribute:"chart-style"})],_a.prototype,"chartStyle",2),_a=m([x("roxy-divisional-chart")],_a);var Ue=require("lit"),Np=require("lit/decorators.js");var Vy={manglik:"Mangal Dosha",kalsarpa:"Kaal Sarp Dosha",sadhesati:"Sade Sati"},Na=class extends g{constructor(){super(...arguments);this.type="manglik"}renderData(e){let t=!!e.present,r=Vy[this.type]??this.type,n=(e.severity??"").toLowerCase(),i=n==="severe"?3:n==="moderate"?2:n==="mild"?1:0,o=i*33;return Ue.html`<article class="card" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="${`badge roxy-chip ${t?"present":"absent"}`}" data-tone="${t?"danger":"success"}">${t?this.t("Present"):this.t("Absent")} </span>${ve(this.effectiveLang(),e.frame,this.translator)}</header>${"type"in e&&e.type?Ue.html`<p class="subtype"><span class="subtype-label roxy-label">${this.type==="sadhesati"?this.t("Current phase"):this.t("Type")}</span>${e.type}</p>`:Ue.nothing} ${e.severity?Ue.html`<div class="severity-bar" part="details" role="meter" aria-valuemin="0" aria-valuemax="3" aria-valuenow="${i}" aria-label="${this.t("Severity")} ${e.severity}"><span class="severity-fill" data-tier="${i}" style="width:${o}%"></span></div>`:Ue.nothing} ${e.description&&!this.hideReadings?Ue.html`<p class="description">${e.description}</p>`:Ue.nothing} ${this.renderEffects(e)} ${e.remedies&&e.remedies.length>0&&!this.hideReadings?Ue.html`<div part="section remedies"><h3>${this.t("Remedies")}</h3><ul>${e.remedies.map(l=>Ue.html`<li>${l}</li>`)}</ul></div>`:Ue.nothing} ${"exceptions"in e&&e.exceptions&&e.exceptions.length>0&&!this.hideReadings?Ue.html`<div part="section exceptions"><h3>${this.t("Exceptions")}</h3><ul>${e.exceptions.map(l=>Ue.html`<li>${l}</li>`)}</ul></div>`:Ue.nothing}</article>`}renderEffects(e){if(!e.effects||this.hideReadings)return Ue.nothing;let t=[];for(let[r,n]of Object.entries(e.effects))if(typeof n=="string"&&n.length>0)t.push(Ue.html`<div><h3>${r}</h3><p>${n}</p></div>`);else if(n&&typeof n=="object")for(let[i,o]of Object.entries(n))typeof o=="string"&&o.length>0&&t.push(Ue.html`<div><h3>${i}</h3><p>${o}</p></div>`);return t.length===0?Ue.nothing:Ue.html`<div class="effects" part="section effects">${t}</div>`}};Na.endpoints=kl,Na.styles=[u,re,Ue.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}h2{text-transform:capitalize}.subtype{font-size:var(--roxy-text-sm)}.subtype-label{margin-inline-end:var(--roxy-space-sm)}.badge{font-weight:var(--roxy-weight-bold)}.severity-bar{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.35lh;inline-size:100%;overflow:hidden}.severity-fill{background:var(--roxy-warning);block-size:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.severity-fill[data-tier="3"]{background:var(--roxy-danger)}@media (prefers-reduced-motion:reduce){.severity-fill{transition:none}}h3{margin-block-end:var(--roxy-space-xs)}ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}.effects{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.effects p{font-size:var(--roxy-text-sm)}`],m([(0,Np.property)({type:String,reflect:true})],Na.prototype,"type",2),Na=m([x("roxy-dosha-card")],Na);var se=require("lit");var Uy=/^\d+(?:[.,]\d+)*(?:\s*-\s*\d+(?:[.,]\d+)*)?$/;function Qs(s){if(!s.text)return"";let a=s.chapter==null?"":String(s.chapter),e=s.verse??"",t=a;e&&(t=a?Uy.test(e.trim())?`${a}.${e}`:`${a}, ${e}`:e);let r=s.translation?[s.translation,s.year].filter(Boolean).join(" "):"";return[[D(s.text),t].filter(Boolean).join(" "),r,s.basis].filter(Boolean).join(" \xB7 ")}var zp=require("lit"),wr=zp.css`.row{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);display:grid}@container (width<=30rem){.row{grid-template-columns:minmax(0,1fr)}}`;var qy=["vata","pitta","kapha"],Yy={"lagna-sign":"Lagna","moon-sign":"Moon sign","strongest-planet":"Strongest graha"};function Wy(s){return s.split("-").map(U).join("-")}function Zy(s,a){return ot(s,(a??"").split(" ").filter(Boolean).map(U))}var kr=class extends g{renderData(a){let e=this.effectiveLang(),t=a.composite;return se.html`<article class="card" part="card" aria-labelledby="dosha-title"><header class="head" part="header"><h2 id="dosha-title">${this.t("Ayurvedic constitution")}</h2>${t?.type?se.html`<span class="type">${Wy(t.type)}</span>`:se.nothing}</header>${this.renderBar(e,a)}<div class="facts" part="details">${t?.dominant?se.html`<span><span class="roxy-label">${this.t("Dominant")}</span><b>${U(t.dominant)}</b></span>`:se.nothing} ${t?.secondary?se.html`<span><span class="roxy-label">${this.t("Secondary")}</span><b>${U(t.secondary)}</b></span>`:se.nothing} ${a.lagnaSign?se.html`<span><span class="roxy-label">${this.t("Lagna")}</span><b>${U(a.lagnaSign)}</b></span>`:se.nothing} ${a.moonSign?se.html`<span><span class="roxy-label">${this.t("Moon sign")}</span><b>${U(a.moonSign)}</b></span>`:se.nothing}</div>${this.renderFactors(e,a.factors)} ${this.renderRanking(e,a.strengthRanking)} ${this.renderPlanetDoshas(a.planetDoshas)} ${a.summary&&!this.hideReadings?se.html`<p class="summary" part="section readings">${a.summary}</p>`:se.nothing} ${ve(e,a.frame,this.translator)} ${a.meta?.disclaimer?se.html`<p class="disclaimer" part="disclaimer">${a.meta.disclaimer}</p>`:se.nothing}</article>`}renderBar(a,e){let t=e.composite,r=qy.map(i=>({humour:i,value:t?.[i]??0}));return r.reduce((i,o)=>i+o.value,0)<=0?se.nothing:se.html`<div part="chart"><div class="bar" role="img" aria-label="${r.map(i=>`${U(i.humour)} ${Ne(a,i.value,0)}`).join(", ")}">${r.filter(i=>i.value>0).map(i=>se.html`<div class="${`seg seg-${i.humour}`}" style="${`flex: ${i.value} 0 0`}"></div>`)}</div><p class="shares">${r.map(i=>se.html`<span><span class="${`swatch seg-${i.humour}`}"></span>${U(i.humour)} <b>${Ne(a,i.value,0)}</b></span>`)}</p></div>`}renderFactors(a,e){let t=e??[];return t.length===0?se.nothing:se.html`<section part="section factors"><h3>${this.t("Factors")}</h3><ul class="rows">${t.map(r=>se.html`<li class="row" part="label-track"><span class="roxy-label">${this.factorLabel(r.id)}</span><div><span>${Zy(a,r.input)}</span> ${r.doshas?.length?se.html`· ${r.doshas.map(n=>U(n)).join(", ")}`:se.nothing} ${typeof r.weight=="number"?se.html`· <span class="roxy-label">${this.t("Weight")}</span>${b(a,r.weight,2)}`:se.nothing} ${this.renderCitation(r.source)}</div></li>`)}</ul></section>`}factorLabel(a){let e=Yy[a??""];return e?this.t(e):D(a??"")}renderCitation(a){let e=Qs(a??{});return e?se.html`<div class="cite"><p><span class="roxy-label">${this.t("Source")}</span>${e}</p>${a?.note?se.html`<details class="note"><summary>${this.t("Note on the source")}${he()}</summary><p>${a.note}</p></details>`:se.nothing}</div>`:se.nothing}renderRanking(a,e){let t=e??[];return t.length===0?se.nothing:se.html`<section part="section ranking"><h3>${this.t("Shadbala")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Shadbala")}"><table><thead><tr><th>${this.t("Rank")}</th><th>${this.t("Graha")}</th><th>${this.t("Strength")}</th><th>${this.t("Strong")}</th></tr></thead><tbody>${t.map(r=>se.html`<tr class="${r.strong?"is-strong":""}"><td>${q(a,r.rank)}</td><td>${r.graha??""}</td><td>${this.t("{{value}} virupas",{value:b(a,r.totalVirupas,2)})}</td><td>${r.strong?this.t("Yes"):this.t("No")}</td></tr>`)}</tbody></table></div></section>`}renderPlanetDoshas(a){let e=a??[];return e.length===0?se.nothing:se.html`<section part="section planet-humours"><h3>${this.t("Planetary humours")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Planetary humours")}"><table><thead><tr><th>${this.t("Graha")}</th><th>${this.t("Humours")}</th><th>${this.t("Dhatu")}</th></tr></thead><tbody>${e.map(t=>se.html`<tr><td>${t.graha??""}</td><td>${(t.doshas??[]).map(r=>U(r)).join(", ")}</td><td>${[t.dhatu,t.dhatuSanskrit].filter(Boolean).join(" \xB7 ")}</td></tr>`)}</tbody></table></div>${this.renderTableSources(e)}</section>`}renderTableSources(a){let e=new Set;for(let t of a)for(let r of[t.doshaSource,t.dhatuSource]){let n=Qs(r??{});n&&e.add(n)}return e.size===0?se.nothing:se.html`<p class="cite"><span class="roxy-label">${this.t("Source")}</span>${[...e].join(" \xB7 ")}</p>`}};kr.endpoints=Sl,kr.styles=[u,re,X,wr,se.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.type{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold)}.bar{width:100%;min-width:0;border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);block-size:1lh;display:flex;overflow:hidden}.seg{min-width:0}.seg-vata{background:color-mix(in srgb, var(--roxy-info) 45%, var(--roxy-surface))}.seg-pitta{background:color-mix(in srgb, var(--roxy-danger) 45%, var(--roxy-surface))}.seg-kapha{background:color-mix(in srgb, var(--roxy-success) 45%, var(--roxy-surface))}.shares,.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.swatch{block-size:.5lh;inline-size:.5lh;border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.shares b,.facts b{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.facts .roxy-label,.row>div .roxy-label,.cite .roxy-label{margin-inline-end:var(--roxy-space-xs)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.cite{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2)}.cite .roxy-label{font-size:inherit}.cite .note summary{align-items:center;gap:var(--roxy-space-xs);width:fit-content;color:var(--roxy-secondary);display:flex}.cite .note p{margin-block-start:calc(var(--roxy-space-unit) / 2)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}tr.is-strong td{font-weight:var(--roxy-weight-bold)}.summary{font-size:var(--roxy-text-sm)}.disclaimer{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);padding-inline-start:var(--roxy-space-md)}`],kr=m([x("roxy-dosha-constitution")],kr);var aa=require("lit");var Sr=class extends g{renderData(a){return aa.html`<article class="card" part="card" aria-label="${a.name??this.t("Dream symbol")}"><header class="head" part="header">${a.letter?aa.html`<span class="letter" aria-hidden="true">${a.letter}</span>`:aa.nothing}<div><p class="roxy-label">${this.t("Dream symbol")}</p>${a.name?aa.html`<h2>${a.name}</h2>`:aa.nothing}</div></header>${a.meaning?aa.html`<p>${a.meaning}</p>`:aa.nothing}</article>`}};Sr.endpoints=Rl,Sr.styles=[u,aa.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);display:flex}.letter{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);block-size:2lh;inline-size:2lh;color:var(--roxy-accent-ink);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);text-transform:uppercase;flex:none;justify-content:center;align-items:center;display:inline-flex}`],Sr=m([x("roxy-dream-card")],Sr);var fa=require("lit");var Rr=class extends g{constructor(){super(...arguments);this.rowDetail={tag:"roxy-dream-card",path:"dreams/symbols/{id}"};this.listKey="symbols"}renderData(e){let t=e.symbols??[];if(t.length===0)return this.renderEmpty();let r=typeof e.total=="number"?e.total:t.length;return fa.html`<section class="wrap" part="card" aria-label="${this.t("Dream symbols")}"><header class="head" part="header"><h2>${this.t("Dream symbols")}</h2><span class="count">${r===1?this.t("1 symbol"):this.t("{{count}} symbols",{count:r})}</span></header><ul class="grid" part="section symbols">${t.map(n=>fa.html`<li><button type="button" class="result" aria-pressed="${this.openedRowId===n.id?"true":"false"}" @click="${()=>this.pickRow({id:n.id,name:n.name,letter:n.letter})}">${n.letter?fa.html`<span class="letter" aria-hidden="true">${n.letter}</span>`:fa.nothing} <span class="name">${n.name}</span></button></li>`)}</ul>${this.renderMore()} ${this.openedRow?fa.html`<div class="detail" part="detail">${this.openedRow}</div>`:fa.nothing}</section>`}};Rr.endpoints=Cl,Rr.styles=[u,fa.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fill,minmax(min(100%,16ch),1fr));margin:0;padding:0;list-style:none;display:grid}.result{align-items:center;gap:var(--roxy-space-sm);width:100%;padding:var(--roxy-space-sm) var(--roxy-space-md);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;display:flex}.result[aria-pressed=true],.result:hover{border-color:var(--roxy-accent)}.result[aria-pressed=true] .name{color:var(--roxy-accent-ink)}.detail{margin-block-start:var(--roxy-space-md)}.letter{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);text-transform:uppercase;flex:none}.name{font-size:var(--roxy-text-sm)}`],Rr=m([x("roxy-dream-search")],Rr);var O=require("lit"),Fe=require("lit/decorators.js"),ra=require("lit/directives/if-defined.js"),nh=require("lit/directives/live.js");var za={accent:"Accent color",afterSunset:"Born after sunset",allowDuplicates:"Allow duplicate cards",allowReversals:"Allow reversed cards",angelDating:"How the name of the day is dated",annualFromYear:"Annual pillars from year",annualYears:"Years of annual pillars",approximateDate:"Approximate date",aspectTypes:"Aspect types",atbashOutput:"AtBash and Albam output",avasthaInfo:"Include avastha details",avoidAnimal:"Avoid clashes with",ayadiText:"Ayadi text family",ayanamsaValue:"Custom ayanamsa value",birthData:"Birth details",birthDate:"Birth date",birthLatitude:"Birth latitude",birthLongitude:"Birth longitude",birthTime:"Birth time",ciphers:"Ciphers to return",colors:"Brand colors",context:"Where you saw it",coordinateSystem:"Coordinate system",correlation:"Correlation constant",count:"How many",currentYear:"Current year",cuts:"Cut corners",dasha:"Dasha lords",datetime:"Date and time",dayBoundary:"Day boundary",depth:"Depth, north to south",directionScheme:"Direction reading",division:"Divisional chart",domainWeights:"Domain weights",door:"Door coordinates",doorPosition:"Door position along the side",doshaClock:"How the dosha periods are cut",endDate:"End date",endDatetime:"End date and time",expression:"Expression number",extensions:"Extended corners",facing:"Facing direction",facingDegrees:"Facing degrees",family:"Yoga family",firstName:"First name",firstNameHebrew:"First name in Hebrew",font:"Typeface",footer:"Footer line",fullName:"Full name",gainHouses:"Gain houses",grid:"Mandala grid",hastaInches:"Length of one hasta in inches",horaryNumber:"Horary number",hourClock:"Hour clock",houseSystem:"House system",id:"ID",include:"Additional bodies",includeMatches:"Include equal value matches",interpretation:"Position meaning",intervalMinutes:"Interval in minutes",isLeapMonth:"Leap month",iso2:"Country code",kua:"Kua number",lang:"Language",latinCiphers:"Also score the Latin ciphers",leapDayPolicy:"Where 29 February falls",letter:"Starting letter",letterAttribution:"Letter attribution reading",lifePath:"Life Path number",limit:"Results per page",lines:"Line pattern",logo:"Logo URL",lossHouses:"Loss houses",lunarDay:"Lunar day",lunarMonth:"Lunar month",lunarYear:"Lunar year",members:"Group members",minSignificance:"Minimum significance",minStrength:"Minimum strength",misparGadol:"Mispar gadol method",modernPlanets:"Include modern planets",moonWindows:"Moon windows",muhurtaText:"Muhurta text",nameHebrew:"Name in Hebrew",natalChart:"Natal chart",nodeType:"Lunar node type",offset:"Results to skip",polygon:"Outline",positions:"Spread positions",primary:"Primary color",q:"Search",question:"Your question",readings:"Include readings",relocationLatitude:"Relocation latitude",relocationLongitude:"Relocation longitude",returnDate:"Return date",returnYear:"Return year",ritucharyaScheme:"Season division",rituZodiac:"Zodiac the season boundaries are measured in",road:"Road side",rulingPlanets:"Ruling planets",scheme:"Karaka scheme",secondName:"Second name",secondNameHebrew:"Second name in Hebrew",sephirotSystem:"Sephirot reading",sign:"Zodiac sign",sign1:"First animal sign",sign2:"Second animal sign",signDoshaScheme:"Sign humour table",significators:"Include KP significators",size:"Paper size",slopeLowDirection:"Direction the ground falls toward",slopeSchool:"Ground level school",soulUrge:"Soul Urge number",spreadName:"Spread name",startDate:"Start date",startDatetime:"Start date and time",strictOrbs:"Use tighter orbs",system:"Avastha system",targetDate:"Target date",targetMonth:"Target month",text:"Word or name",textHebrew:"Hebrew word or name",top:"Top events per window",transitDate:"Transit date",transitTime:"Transit time",transliteration:"Transliteration scheme",treeVariant:"Tree arrangement",type:"Pattern type",vyayaFormula:"Vyaya formula",water:"Standing water direction",weights:"Layer weights",width:"Width, east to west",x:"Distance east",y:"Distance north",yearBearerSystem:"Year Bearer school",yearBoundary:"Year boundary",yearStart:"Wheel year start",zodiac:"Zodiac sign"};var Op={"GET /angel-numbers/numbers/{number}":{number:{path:"/angel-numbers/numbers",limit:50,lang:true}},"GET /astrology/planet-meanings/{id}":{id:{path:"/astrology/planet-meanings",lang:true}},"GET /astrology/signs/{id}":{id:{path:"/astrology/signs",lang:true}},"GET /crystals":{color:{path:"/crystals/colors",lang:true},planet:{path:"/crystals/planets",lang:true}},"GET /crystals/{id}":{id:{path:"/crystals",limit:100,lang:true}},"GET /dreams/symbols":{letter:{path:"/dreams/symbols/letters"}},"GET /dreams/symbols/{id}":{id:{path:"/dreams/symbols",search:"q",limit:50}},"GET /iching/trigrams/{id}":{id:{path:"/iching/trigrams",lang:true}},"GET /tarot/cards/{id}":{id:{path:"/tarot/cards",limit:100,lang:true}}},Gp={"GET /tarot/cards":{suit:{field:"arcana",value:"major"}}};var Xt=(s,a)=>`${s}.${a}`;function ai(s){let a=/^(.+)\.(\d+)$/.exec(s);return a?{key:a[1],index:Number(a[2])}:null}function ri(s,a=Fi,e=t=>za[t]??D(t)){let t=ai(s);return t?a("{{group}} {{n}}",{group:e(t.key),n:t.index+1}):a(D(s))}function Fp(s,a){let e=a.key??a.name;if(Hp(e))return ws(s,e);if(!a.label)return ws(s,a.name);let t=Object.keys(za).find(r=>za[r]===a.label);return Bi(s,a.label)??(t?ws(s,t):void 0)}function Bp(s,a,e){let t=Xt(a,0);return s.filter(r=>r.group===t).map(r=>({...r,key:`${Xt(a,e)}.${r.name}`,group:Xt(a,e)}))}function So(s){return s.length<=(si(s)?30:12)?"tiles":"select"}function si(s){return s.every(a=>a.length<=2)}var Xy=["format","branding","readings"],Jy=["latitude","longitude","timezone"],Ip=["latitude","longitude"];function Hp(s){let a=s.match(/^(.+?)(Latitude|Longitude)$/);return a?{group:a[1],leaf:a[2].toLowerCase()}:null}var Qy=Ie.map(s=>s.toLowerCase());function Cr(s,a){if(s){if("$ref"in s&&s.$ref){let e=s.$ref.split("/").pop();return e?a[e]:void 0}return s}}function jp(s){let a=s.anyOf??s.oneOf;return!a||a.length===0?s:a.find(e=>Array.isArray(e.enum))??a.find(e=>ko(e)&&ko(e)!=="null")??a[0]??s}function ko(s){if(typeof s.type=="string")return s.type;if(!Array.isArray(s.type))return;let a=s.type.filter(e=>e!=="null");return a.length===1?a[0]:void 0}function eu(s){let a=jp(s),e=ko(a);return Array.isArray(a.enum)?So(a.enum):e==="boolean"?"toggle":a.format==="date"?"date":a.format==="time"?"time":a.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function Kp(s){if(s.length!==12)return false;let a=new Set(s.map(e=>e.toLowerCase()));return Qy.every(e=>a.has(e))}function ti(s,a,e){let t=jp(a);return{key:e.key,name:s,group:e.group,inQuery:e.inQuery,kind:eu(a)??"text",required:e.required,description:t.description??a.description,enum:t.enum,min:t.minimum??t.exclusiveMinimum,max:t.maximum??t.exclusiveMaximum,default:a.default??t.default,example:a.example??t.example}}function wo(s){return new Set([...s.required??[],...s["x-required-any-of"]?.[0]??[]])}function Vp(s,a,e,t=s.requestBody?"POST":"GET"){let r=[],n=[],i=false,o,l=s.requestBody?.content?.["application/json"]?.schema,c=Cr(l,a),d=c?.["x-required-any-of"],h=(s["x-request-cost"]??1)>1;if(c?.properties){let p=wo(c);for(let[f,L]of Object.entries(c.properties)){if(h&&Xy.includes(f))continue;let $=Cr(L,a)??{},k=$.type==="array"?Cr($.items,a):void 0;if(k?.type==="object"&&k.properties){let j=Math.max(1,$.minItems??1),ue=wo(k);n.push({key:f,min:j,max:$.maxItems??j});for(let Xe=0;Xe<j;Xe++)for(let[Tt,oa]of Object.entries(k.properties)){let $a=Cr(oa,a)??{};r.push(ti(Tt,$a,{key:`${Xt(f,Xe)}.${Tt}`,group:Xt(f,Xe),required:p.has(f)&&ue.has(Tt)}))}}else if($.type==="object"&&$.properties){let j=wo($);for(let[ue,Xe]of Object.entries($.properties)){let Tt=Cr(Xe,a)??{};Tt.type==="array"&&Cr(Tt.items,a)?.type==="object"||r.push(ti(ue,Tt,{key:`${f}.${ue}`,group:f,required:p.has(f)&&j.has(ue)}))}}else{let j=Hp(f),ue=ti(j?.leaf??f,$,{key:f,group:j?.group,required:p.has(f)});j&&(ue.label=`${D(j.group)} ${j.leaf}`),r.push(ue)}}}for(let p of s.parameters??[]){if(p.in!=="path"&&p.in!=="query")continue;if(p.name==="lang"&&p.in==="query"){i=true,o=Cr(p.schema,a)?.enum?.filter($=>typeof $=="string");continue}let f=Cr(p.schema,a)??{},L=ti(p.name,f,{key:p.name,required:!!p.required,inQuery:p.in==="query"});if(p.in==="path"&&L.enum&&/^(id|identifier|slug)$/i.test(za[L.name]??D(L.name))){let $=/^([A-Za-z][A-Za-z -]*?)\s+(?:id|identifier|slug)\b/i.exec(p.description??L.description??"")?.[1]?.trim();$&&(L.label=$)}r.push(L)}for(let p of r)!p.group&&!p.label&&r.some(f=>f.group&&f.name===p.name)&&(p.label=tu(p));return Ro({title:au(s.summary,e),fields:r,hasLang:i,...o?.length?{langs:o}:{},...n.length>0?{repeats:n}:{},...d?{requiredAnyOf:d}:{}},t,e)}function tu(s){let e=(za[s.name]??D(s.name)).toLowerCase().replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),t=new RegExp(`^(\\p{L}+) ${e}\\b`,"iu").exec(s.description??"")?.[1];return t?za[t.toLowerCase()+s.name.replace(/^./,r=>r.toUpperCase())]:void 0}function Ro(s,a,e){let t=`${a.toUpperCase()} /${e.replace(/^\//,"")}`,r=Op[t]??{},n=Gp[t]??{},i=s.fields.map(p=>{let f={...p};return delete f.role,delete f.city,delete f.viewerZone,delete f.moment,delete f.fold,{...f,...r[p.key]&&{source:r[p.key]},...n[p.key]&&{disabledWhen:n[p.key]}}}),o=[...new Set(i.map(p=>p.group))].map(p=>p===void 0?{}:{key:p,label:ri(p)}),l=o.filter(p=>Ip.every(f=>i.some(L=>L.group===p.key&&L.name===f)));for(let[p,f]of l.entries()){let L=i.filter(k=>k.group===f.key),$=L.find(k=>k.name==="timezone")??(p===0?i.find(k=>!k.group&&k.name==="timezone"):void 0);f.location={fields:[...L.filter(k=>Ip.includes(k.name)).map(k=>k.key),...$?[$.key]:[]],required:L.some(k=>Jy.includes(k.name)&&k.required)}}for(let p of i)p.name==="seed"?p.role="seed":(p.name==="limit"||p.name==="offset")&&!p.required?p.role="hidden-default":l.some(f=>f.location?.fields.includes(p.key))?p.role="location":p.name==="timezone"&&(p.city=true,!p.group&&!p.required&&(p.viewerZone=true));let c=o.filter(p=>p.key!==void 0&&(p.location||i.some(f=>f.group===p.key&&f.required))),d=i.some(p=>!p.group&&!p.role&&p.required)||c.length>0||l.some(p=>p.key===void 0);for(let p of o)p.key!==void 0&&d&&!c.includes(p)&&(p.fold=true);let h=p=>c.length>0&&p.default===void 0&&(p.kind==="date"||p.kind==="time"||p.kind==="datetime");for(let p of i)p.group?o.find(f=>f.key===p.group)?.fold&&(p.fold=true):!p.role&&d&&!p.required?h(p)?p.moment=true:p.fold=true:!p.role&&!d&&p.default!==void 0&&(p.fold=true);return{...s,fields:i,groups:o,opensOnLoad:ru(s,a)}}function Up(s,a){let e=s.filter(t=>t.moment);return e.some(t=>t.kind==="time"||t.kind==="datetime")&&e.every(t=>a[t.key]===void 0||a[t.key]==="")}function au(s,a){let e=s?.split(" - ")[0]?.trim();return e||D(a.split("/").pop()??"")}function ru(s,a){return a.toUpperCase()==="GET"&&!s.fields.some(e=>e.required)}function qp(s,a=[]){if(a.some(t=>t.name==="limit"||t.name==="offset"))return"Search";let e=s.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(e)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(e)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(e)?"Get reading":"Generate"}function Yp(s,a){let e=mn(s,a);return e&&`${e}/schemas`}function Wp(s,a){let e=a.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${s.toLowerCase()}--${e}.json`}function su(s){if(Array.isArray(s))return s;if(!s||typeof s!="object")return null;let a=Object.values(s),e=a.find(Array.isArray);return e||(a.find(r=>!!r&&typeof r=="object"&&Object.values(r).every(n=>typeof n=="number"))??null)}function Co(s,a="id"){let e=su(s);if(!e)return[];if(!Array.isArray(e)){let r=Object.keys(e),n=r.length>0&&r.every(o=>/^[a-z]$/.test(o));return(n?[..."abcdefghijklmnopqrstuvwxyz"]:r).map(o=>({value:o,label:n?o.toUpperCase():o,disabled:!e[o]}))}let t=[];for(let r of e){if(typeof r=="string"){t.push({value:r,label:r});continue}if(!r||typeof r!="object")continue;let n=r,i=n.id??n[a]??n.number;if(i==null)continue;let o=String(i),l=n.name??n.english;t.push({value:o,label:typeof l=="string"?l:o})}return t}function Zp(s){let a=s?.total;return typeof a=="number"?a:void 0}var Kt=require("lit"),oi=require("lit/directives/if-defined.js");var Xp=require("lit"),ni=Xp.css`.spinner{inset-inline-end:calc(var(--roxy-space-unit) * 3);border:var(--roxy-line-thick) solid var(--roxy-muted);border-radius:var(--roxy-radius-full);border-top-color:#0000;block-size:.6lh;inline-size:.6lh;animation:.7s linear infinite roxy-spin;position:absolute;top:50%;transform:translateY(-50%)}@keyframes roxy-spin{to{transform:translateY(-50%)rotate(360deg)}}@media (prefers-reduced-motion:reduce){.spinner{animation:none}}.results{z-index:50;top:calc(100% + var(--roxy-space-xs));padding:var(--roxy-space-xs);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);box-shadow:var(--roxy-shadow-md);max-block-size:15lh;animation:roxy-fade-in var(--roxy-motion-duration) var(--roxy-motion-easing);margin:0;list-style:none;position:absolute;left:0;right:0;overflow-y:auto}.option{align-items:center;gap:var(--roxy-space-sm);inline-size:100%;min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-md);border-radius:var(--roxy-radius-sm);text-align:start;font-size:var(--roxy-text-sm);color:var(--roxy-fg);cursor:pointer;transition:background-color var(--roxy-motion-duration);background:0 0;border:0;display:flex}.option:hover,.option[aria-selected=true]{background:color-mix(in srgb, var(--roxy-accent) 10%, transparent)}.empty{padding:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`;function ii(s,a){let e,t=((...r)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=void 0,s(...r)},a)});return t.cancel=()=>{e&&(clearTimeout(e),e=void 0)},t}var nu=10,iu=10,To=new Map;function Jp(s,a,e={}){return{...s.limit?{limit:s.limit}:{},...s.lang&&a?{lang:a}:{},...e}}function Do(s,a,e,t){let r=JSON.stringify([s.submitUrl??s.baseUrl,a.path,e,t]),n=To.get(r);return n||(n=ou(s,a,e,t).catch(i=>{throw To.delete(r),i}),To.set(r,n)),n}async function ou(s,a,e,t){let r=[];for(let n=0;n<iu;n++){let i=await ar(s,{path:a.path,method:"GET",query:Jp(a,t,r.length?{offset:r.length}:{})}),o=Co(i,e);r.push(...o);let l=Zp(i);if(!a.limit||l===void 0||r.length>=l||!o.length)break}return r}var Eo=s=>s.normalize("NFD").replace(/\p{M}/gu,"").toLowerCase(),li=class{constructor(a,e,t,r,n){this.host=a;this.source=e;this.field=t;this.context=r;this.onPick=n;this.query="";this.options=[];this.open=false;this.highlight=-1;this.loading=false;this.error=null;this.search=ii(a2=>{this.searchServer(a2)},250);a.addController(this)}hostDisconnected(){this.search.cancel(),this.abort?.abort()}input(a){this.query=a,this.error=null,this.source.search?a.trim().length<2?this.close():this.search(a):this.filter(a),this.host.requestUpdate()}focus(){!this.source.search&&!this.open&&this.filter(this.query)}close(){this.open=false,this.highlight=-1,this.host.requestUpdate()}pick(a){this.query=a.label,this.close(),this.onPick(a)}keydown(a){let e=this.options.length;if(a.key==="Escape"){this.close();return}if(a.key==="ArrowDown"&&!this.open){a.preventDefault(),this.input(this.query);return}if(!(!this.open||e===0)){if(a.key==="ArrowDown")this.highlight=(this.highlight+1)%e;else if(a.key==="ArrowUp")this.highlight=(this.highlight-1+e)%e;else if(a.key==="Home")this.highlight=0;else if(a.key==="End")this.highlight=e-1;else if(a.key==="Enter"){let t=this.options[this.highlight]??this.options[0];t&&this.pick(t)}else return;a.preventDefault(),this.host.requestUpdate()}}async filter(a){let{route:e,lang:t}=this.context();this.loading=true,this.host.requestUpdate();try{let r=await Do(e,this.source,this.field,t);if(a!==this.query)return;let n=Eo(a.trim());this.show(r.filter(i=>Eo(i.label).includes(n)||Eo(i.value).includes(n)))}catch(r){this.fail(r)}finally{this.loading=false,this.host.requestUpdate()}}async searchServer(a){let{route:e,lang:t}=this.context(),r=this.source.search;this.abort?.abort();let n=new AbortController;this.abort=n,this.loading=true,this.host.requestUpdate();try{let i=await ar(e,{path:this.source.path,method:"GET",query:Jp({...this.source,limit:nu},t,{[r]:a})},n.signal);if(n.signal.aborted)return;this.show(Co(i,this.field))}catch(i){if(n.signal.aborted)return;this.fail(i)}finally{this.abort===n&&(this.abort=void 0),n.signal.aborted||(this.loading=false,this.host.requestUpdate())}}show(a){this.options=a,this.open=true,this.highlight=a.length?0:-1}fail(a){this.options=[],this.open=false,this.error=a instanceof Error?a.message:String(a)}};function Qp(s,a,e,t={}){let r=`${a}-listbox`;return Kt.html`<div class="picker"><input id="${a}" type="text" role="combobox" aria-expanded="${s.open?"true":"false"}" aria-controls="${r}" aria-autocomplete="list" aria-labelledby="${(0,oi.ifDefined)(t.labelledby)}" aria-describedby="${(0,oi.ifDefined)(t.describedby)}" aria-invalid="${(0,oi.ifDefined)(t.invalid?"true":void 0)}" aria-activedescendant="${s.open&&s.highlight>=0?`${a}-opt-${s.highlight}`:""}" autocomplete="off" placeholder="${e.placeholder}" .value="${s.query}" @input="${n=>s.input(n.target.value)}" @keydown="${n=>s.keydown(n)}" @focus="${()=>s.focus()}" @blur="${()=>s.close()}"> ${s.loading?Kt.html`<span class="spinner" role="status" aria-label="${e.loading}"></span>`:Kt.nothing} ${s.open?Kt.html`<ul id="${r}" class="results" role="listbox">${s.options.length===0?Kt.html`<li class="empty" role="status">${e.empty}</li>`:s.options.map((n,i)=>Kt.html`<li id="${`${a}-opt-${i}`}" class="option" role="option" aria-selected="${s.highlight===i?"true":"false"}" @mousedown="${o=>o.preventDefault()}" @click="${()=>s.pick(n)}">${n.label}</li>`)}</ul>`:Kt.nothing}</div>${s.error?Kt.html`<small class="field-error" role="alert">${s.error}</small>`:Kt.nothing}`}var eh=[ni,Kt.css`.picker{position:relative}`];var pu={};var th=`${Ts}/openapi.json`,ah=Yp($s,globalThis.document?.currentScript?.src||pu.url),Ao=new Map,ci=class extends Error{constructor(e){super(`HTTP ${e}`);this.status=e}},di=class extends Error{constructor(e,t){super(`Endpoint ${e} ${t} not found in OpenAPI spec`);this.method=e;this.path=t}};async function lu(s){let a=Ao.get(s);return a||(a=fetch(s).then(async e=>{if(!e.ok)throw new ci(e.status);return await e.json()}).catch(e=>{throw Ao.delete(s),e}),Ao.set(s,a)),a}function cu(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}var rh=s=>/\bbirth/i.test(s?.description??""),sh=s=>s.key===`${s.group}.${s.name}`;function du(s){let a=s.trim();if(!a)return[];try{let e=JSON.parse(a);if(Array.isArray(e))return e}catch{}return a.split(",").map(e=>e.trim()).filter(Boolean)}var De=class extends tr{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.serverIssues=null;this.autoload=false;this.fullPages=false;this.choices={};this.pickers=new Map;this.clearedIssues=new Set;this.fields=[];this.groups=[];this.modelOpensOnLoad=false;this.repeats=[];this.formTitle="";this.hasLang=false;this.values={};this.loaded=false;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=false,this.specError=null,this.loadSchema()};this.onSubmit=e=>{e.preventDefault(),this.submit()}}connectedCallback(){super.connectedCallback(),this.loadSchema()}async loadSchema(){this.specError=null;try{this.applyModel(await this.resolveModel())}catch(e){this.specError=this.specErrorMessage(e),this.loaded=true,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||th,message:e instanceof Error?e.message:String(e)},bubbles:true,composed:true}))}}specErrorMessage(e){return e instanceof ci?this.t("HTTP error {{status}}",{status:e.status}):e instanceof di?this.t("Endpoint {{method}} {{path}} not found in OpenAPI spec",{method:e.method,path:e.path}):e instanceof Error?e.message:String(e)}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(th)}async modelFromSpec(e){let t=await lu(e),r=`/${this.endpoint.replace(/^\//,"")}`,n=t.paths?.[r]?.[this.method.toLowerCase()];if(!n)throw new di(this.method,r);return Vp(n,t.components?.schemas??{},this.endpoint,this.method)}async tryLoadSlice(){if(!ah)return null;try{let e=await fetch(`${ah}/${Wp(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){(!e.groups||e.opensOnLoad===void 0)&&(e=Ro(e,this.method,this.endpoint)),this.fields=e.fields,this.groups=e.groups??[],this.modelOpensOnLoad=e.opensOnLoad??false,this.repeats=e.repeats??[],this.formTitle=e.title,this.hasLang=e.hasLang,this.langs=e.langs;let t={};for(let r of e.fields){let n=r.viewerZone?void 0:this.fullPages&&r.name==="limit"&&this.roleOf(r)==="hidden-default"?r.max??r.default:r.default;n!==void 0&&(t[r.key]=n);let i=r.group&&sh(r)?this.initialValues?.[r.group]?.[r.name]:this.initialValues?.[r.key];i!==void 0&&(t[r.key]=i)}this.values=this.withoutDisabled(t),this.loaded=true,this.loadChoices(),this.autoload&&this.opensOnLoad&&ji(this.route)&&this.updateComplete.then(()=>this.submit())}get route(){return this.apiRoute??{publishableKey:this.publishableKey}}loadChoices(){for(let t of this.pickers.values())this.removeController(t);if(this.pickers.clear(),!ji(this.route))return;let e=()=>({route:this.route,lang:this.requestLang()});for(let t of this.fields)if(t.source){if(t.required){let r=new li(this,t.source,t.name,e,n=>this.pickChoice(t,n.value));r.query=String(this.values[t.key]??""),this.pickers.set(t.key,r);continue}this.choices={...this.choices,[t.key]:"loading"},Do(this.route,t.source,t.name,this.requestLang()).then(r=>{this.choices={...this.choices,[t.key]:r}},()=>{let{[t.key]:r,...n}=this.choices;this.choices=n})}}setValue(e,t){this.setValues({[e]:t})}setValues(e){this.values=this.withoutDisabled({...this.values,...e});let t=Object.keys(e).filter(r=>this.serverIssues?.some(n=>n.path===r));t.length&&(this.clearedIssues=new Set([...this.clearedIssues,...t]))}isDisabled(e,t=this.values){let r=e.disabledWhen;return!!r&&t[r.field]===r.value}withoutDisabled(e){for(let t of this.fields)this.isDisabled(t,e)&&(e[t.key]=void 0);return e}willUpdate(e){e.has("serverIssues")&&(this.clearedIssues=new Set);let t=e.has("publishableKey")?is(this.publishableKey):void 0;t&&Rs(this,t,{warn:true})}liveIssues(){return(this.serverIssues??[]).filter(e=>!this.clearedIssues.has(e.path))}issueFor(e){return this.liveIssues().find(t=>t.path===e.key)}cityIssues(e){return this.liveIssues().filter(t=>{let r=this.fields.find(n=>n.key===t.path);return!!r&&this.roleOf(r)==="location"&&this.cityGroup(r)===e})}issuesForGroup(e){return this.liveIssues().filter(t=>t.path===e)}fieldLabel(e){return this.roleOf(e)==="location"||e.city?this.locationLabel(this.cityGroup(e)):e.group?`${this.groupName(e.group)} ${this.fieldText(e)}`:this.fieldText(e)}issueLines(e){return e.map(t=>O.html`<small part="field-error" class="field-error" role="alert">${t.message}</small>`)}fieldIssue(e){let t=this.issueFor(e);return t?O.html`<small part="field-error" class="field-error" id="${`roxy-form-${e.key}-error`}" role="alert">${t.message}</small>`:O.nothing}renderIssueSummary(){let e=this.liveIssues();if(e.length===0)return O.nothing;let t=r=>{let n=this.fields.find(o=>o.key===r);if(n)return this.fieldLabel(n);let i=this.groupKeys().find(o=>o===r);return i?this.groupName(i):this.fieldText({name:r.split(".")[0]??r})};return O.html`<div part="validation-error" class="validation-error" role="alert">${e.map(r=>O.html`<div><strong>${t(r.path)}</strong> ${r.message}</div>`)}</div>`}roleOf(e){return e.role??"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){return this.groups.map(e=>e.key)}groupHasLocation(e){return!!this.groups.find(t=>t.key===e)?.location}cityGroup(e){return this.groups.find(t=>t.location?.fields.includes(e.key))?.key??e.group}placeField(e){let t=this.fields.filter(r=>r.group===e);return t.find(r=>r.name==="latitude")??t.find(r=>r.name==="timezone")}locationRequired(e){return this.groups.find(t=>t.key===e)?.location?.required??false}get soleChoice(){if(this.groupKeys().some(r=>this.groupHasLocation(r))||this.groupKeys().some(r=>r!==void 0))return null;let e=this.fields.filter(r=>r.required&&this.isRendered(r)),t=e[0];return e.length!==1||!t?null:t.kind==="tiles"||t.kind==="select"||this.pickers.has(t.key)?t:null}get opensOnLoad(){return this.modelOpensOnLoad}isFilter(e){return this.opensOnLoad&&!e.required&&!!(e.enum||e.source)}get selfSubmits(){if(this.soleChoice)return true;if(!this.opensOnLoad)return false;let e=this.fields.filter(t=>this.isRendered(t));return e.length>0&&e.every(t=>this.isFilter(t))}choiceKind(e){let t=this.choicesOf(e).map(r=>r.value);return this.isFilter(e)&&!si(t)?"select":this.choices[e.key]?So(t):e.kind}choicesOf(e){let t=this.choices[e.key];return Array.isArray(t)?t:(e.enum??[]).map(r=>({value:r,label:this.optionText(e.name,r)}))}effectiveSubmitLabel(){return this.submitLabel?this.submitLabel:Up(this.fields,this.values)?this.t("Show right now"):this.t(qp(this.endpoint,this.fields))}requestLang(e){return pn(this,e)}fieldText(e){let t=this.requestLang();return e.label?Fp(t,e)??e.label:Se(t,e.name,za[e.name])}optionText(e,t){return ie(this.requestLang(),e,t)}onLocationFor(e){return t=>{let r=this.groups.find(i=>i.key===e)?.location?.fields??[],n={};for(let i of r){let o=this.fields.find(l=>l.key===i)?.name;o&&(n[i]=t[o])}this.setValues(n)}}chooseOption(e,t){if(this.isFilter(e)){this.setFilter(e,this.values[e.key]===t?"":t),this.submit();return}this.pickChoice(e,t)}pickChoice(e,t){this.setValue(e.key,t),this.resend()}resend(){let e=this.soleChoice;e&&this.values[e.key]&&this.submit()}setFilter(e,t){let r={[e.key]:t};for(let n of this.fields)n!==e&&(this.isFilter(n)||this.opensOnLoad&&n.kind==="text"&&this.isRendered(n))&&(r[n.key]=void 0);this.setValues(r)}onTilesKeyDown(e){return t=>{let r=this.choicesOf(e).filter(d=>!d.disabled).map(d=>d.value);if(r.length===0)return;let n=r.indexOf(this.values[e.key]),i;if(t.key==="Home")i=0;else if(t.key==="End")i=r.length-1;else if(t.key==="ArrowRight"||t.key==="ArrowDown")i=n===-1?0:(n+1)%r.length;else if(t.key==="ArrowLeft"||t.key==="ArrowUp")i=n===-1?r.length-1:(n-1+r.length)%r.length;else return;t.preventDefault();let o=r[i];if(o===void 0)return;this.chooseOption(e,o);let l=t.currentTarget,c=this.choicesOf(e).findIndex(d=>d.value===o);requestAnimationFrame(()=>l.querySelector(`[data-tile='${c}']`)?.focus())}}submit(){let e=this.collectMissing();if(e.keys.length>0){this.validationErrors=e.labels,this.dispatchEvent(new CustomEvent("roxy-validation-error",{detail:{missing:e.keys},bubbles:true,composed:true}));return}this.validationErrors=[],this.clearedIssues=new Set((this.serverIssues??[]).map(i=>i.path));let t={};for(let i of this.fields){let o=this.values[i.key];if(i.name==="seed"&&(o===void 0||o==="")&&(o=cu()),i.viewerZone&&(o===void 0||o==="")&&(o=pd()??i.default),o===void 0||o==="")continue;i.kind==="array"&&typeof o=="string"&&(o=du(o));let l=i.group?ai(i.group):null;if(l){let c=t[l.key]??[],d=c[l.index]??{};d[i.name]=o,c[l.index]=d,t[l.key]=c}else if(i.group&&sh(i)){let c=t[i.group]??{};c[i.name]=o,t[i.group]=c}else t[i.key]=o}let r=this.fields.filter(i=>i.inQuery).map(i=>i.name),n=this.requestLang(this.langs);this.hasLang&&n&&(t.lang=n,r.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:t,queryKeys:r,sticky:this.soleChoice!=null||this.opensOnLoad},bubbles:true,composed:true}))}collectMissing(){let e=[],t=[],r=new Set;for(let n of this.fields){if(!n.required)continue;let i=this.roleOf(n)==="location";if(!this.isRendered(n)&&!i)continue;let o=this.values[n.key];if(!(o!==void 0&&o!=="")){if(e.push(n.key),i){r.add(this.cityGroup(n));continue}t.push(this.fieldLabel(n))}}for(let n of r)t.push(this.locationLabel(n));return{keys:e,labels:t}}get readsEnglish(){return Sc(this.effectiveLang())}renderTitle(){return this.readsEnglish?O.html`<h2 part="title" class="title" id="roxy-form-title">${this.formTitle}</h2>`:O.nothing}reqMark(e){return e.required?O.html`<span class="req" aria-hidden="true">*</span>`:O.nothing}description(e){if(!e.description||!this.readsEnglish)return O.nothing;if(e.description.length<=120)return O.html`<small part="hint" class="help">${e.description}</small>`;let t=e.description.split(". ")[0]??e.description;return O.html`<details part="hint" class="help-details"><summary><span class="help-lead">${t}</span>${he()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let t=`roxy-form-${e.key}-label`,r=!!e.enum&&Kp(e.enum),n=this.choicesOf(e),i=si(n.map(c=>c.value)),o=n.findIndex(c=>c.value===this.values[e.key]),l=o===-1?n.findIndex(c=>!c.disabled):o;return O.html`<div class="field tiles-field"><span class="label" id="${t}">${this.fieldText(e)}${this.reqMark(e)}</span><div class="${i?"tiles narrow":"tiles"}" role="radiogroup" aria-labelledby="${t}" @keydown="${this.onTilesKeyDown(e)}">${n.map((c,d)=>{let h=this.values[e.key]===c.value,p=r?J(c.value):void 0;return O.html`<button type="button" class="tile" role="radio" data-tile="${d}" aria-checked="${h?"true":"false"}" tabindex="${d===l?"0":"-1"}" ?disabled="${!!c.disabled||this.isDisabled(e)}" @click="${()=>this.chooseOption(e,c.value)}">${p?O.html`<span class="tile-glyph roxy-glyph" aria-hidden="true">${p}</span>`:O.nothing} <span class="tile-label">${c.label}</span></button>`})}</div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderSelect(e){let t=`roxy-form-${e.key}`;return O.html`<div part="field" class="field"><label for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label> <select id="${t}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${(0,ra.ifDefined)(this.issueFor(e)?"true":void 0)}" aria-describedby="${(0,ra.ifDefined)(this.issueFor(e)?`${t}-error`:void 0)}" .value="${(0,nh.live)(this.values[e.key]??"")}" @change="${r=>this.chooseOption(e,r.target.value)}"><option value="">${this.t("Choose")}</option>${this.choicesOf(e).map(r=>O.html`<option value="${r.value}" ?selected="${this.values[e.key]===r.value}" ?disabled="${!!r.disabled}">${r.label}</option>`)}</select> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderPickerField(e,t){let r=`roxy-form-${e.key}`,n=this.soleChoice?.key===e.key&&this.readsEnglish,i=this.issueFor(e);return O.html`<div part="field" class="field">${n?O.nothing:O.html`<label for="${r}">${this.fieldText(e)}${this.reqMark(e)}</label>`} ${Qp(t,r,{placeholder:this.t("Type to search"),empty:this.t("{{count}} matches",{count:0}),loading:this.t("Loading")},{labelledby:n?"roxy-form-title":void 0,describedby:i?`${r}-error`:void 0,invalid:!!i})} ${this.fieldIssue(e)}</div>`}renderToggle(e){let t=`roxy-form-${e.key}`,r=this.values[e.key]===true;return O.html`<div part="field" class="field"><div class="toggle-row"><button type="button" id="${t}" class="toggle" role="switch" aria-checked="${r?"true":"false"}" @click="${()=>this.pickChoice(e,!r)}"><span class="knob"></span></button> <label class="toggle-label" for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label></div>${this.description(e)} ${this.fieldIssue(e)}</div>`}renderInput(e){let t=`roxy-form-${e.key}`,r=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,n=e.example!=null?String(e.example):"",i=e.kind==="array"?this.t("Comma separated"):this.readsEnglish||!/\p{L}/u.test(n)?n:"";return O.html`<div part="field" class="field"><label for="${t}">${this.fieldText(e)}${this.reqMark(e)}</label> <input id="${t}" type="${e.kind==="array"?"text":r}" ?required="${e.required}" ?disabled="${this.isDisabled(e)}" aria-invalid="${(0,ra.ifDefined)(this.issueFor(e)?"true":void 0)}" aria-describedby="${(0,ra.ifDefined)(this.issueFor(e)?`${t}-error`:void 0)}" min="${(0,ra.ifDefined)(e.min)}" max="${(0,ra.ifDefined)(e.max)}" step="${e.kind==="number"?"any":O.nothing}" placeholder="${i||O.nothing}" .value="${this.values[e.key]??""}" @input="${o=>{let l=this.coerce(e.kind,o.target.value);this.opensOnLoad&&e.kind==="text"?this.setFilter(e,l):this.setValue(e.key,l)}}" @change="${()=>this.resend()}"> ${this.description(e)} ${this.fieldIssue(e)}</div>`}renderField(e){if(e.city)return this.renderTimezoneCity(e);let t=this.pickers.get(e.key);if(t)return this.renderPickerField(e,t);let r=this.choices[e.key];return r==="loading"?O.html`<div class="field"><div class="roxy-skeleton field-skeleton" aria-label="${this.t("Loading")}" role="status"></div></div>`:r||e.kind==="tiles"||e.kind==="select"?this.choiceKind(e)==="tiles"?this.renderTiles(e):this.renderSelect(e):e.kind==="toggle"?this.renderToggle(e):this.renderInput(e)}groupName(e){return ri(e,(t,r)=>this.t(t,r),t=>this.fieldText({name:t}))}repeatCount(e){return new Set(this.fields.map(t=>t.group&&ai(t.group)).filter(t=>t&&t.key===e).map(t=>t.index)).size}addRecord(e){let t=this.repeatCount(e),r=Bp(this.fields,e,t),n=this.groups.find(o=>o.key===Xt(e,0));if(n){let o=l=>l.replace(`${Xt(e,0)}.`,`${Xt(e,t)}.`);this.groups=[...this.groups,{...n,key:Xt(e,t),label:ri(Xt(e,t)),...n.location&&{location:{...n.location,fields:n.location.fields.map(o)}}}]}let i={...this.values};for(let o of r)o.default!==void 0&&(i[o.key]=o.default);this.values=i,this.fields=[...this.fields,...r]}removeRecord(e){let t=Xt(e,this.repeatCount(e)-1);this.fields=this.fields.filter(n=>n.group!==t),this.groups=this.groups.filter(n=>n.key!==t);let r={...this.values};for(let n of Object.keys(r))n.startsWith(`${t}.`)&&delete r[n];this.values=r}repeatControls(e){let t=this.repeatCount(e.key);return e.max<=e.min?O.nothing:O.html`<div class="repeat-controls">${t<e.max?O.html`<button type="button" class="repeat-btn" @click="${()=>this.addRecord(e.key)}"><span aria-hidden="true">+</span> ${this.t("Add")}</button>`:O.nothing} ${t>e.min?O.html`<button type="button" class="repeat-btn" @click="${()=>this.removeRecord(e.key)}"><span aria-hidden="true">−</span> ${this.t("Remove")}</button>`:O.nothing}</div>`}locationLabel(e){return e?this.t("{{group}} location",{group:this.groupName(e)}):rh(this.placeField(e))?this.t("Birth location"):this.t("Location")}locationBlock(e){return O.html`<div class="location-block"><label>${this.locationLabel(e)}${this.locationRequired(e)?O.html`<span class="req" aria-hidden="true">*</span>`:O.nothing}</label> ${this.citySearch(e,this.onLocationFor(e))} ${this.issueLines(this.cityIssues(e))}</div>`}renderTimezoneCity(e){return O.html`<div part="field" class="field location-block"><label>${this.locationLabel(e.group)}${this.reqMark(e)}</label> ${this.citySearch(e.group,t=>this.pickChoice(e,t.timezone))} ${this.fieldIssue(e)}</div>`}citySearch(e,t){let r=e?this.t("{{group}} city",{group:this.groupName(e)}):rh(this.placeField(e))?this.t("City of birth"):void 0;return O.html`<roxy-location-search endpoint="${(0,ra.ifDefined)(this.locationUrl||void 0)}" publishable-key="${(0,ra.ifDefined)(this.publishableKey)}" .submitUrl="${this.route.submitUrl}" .submitContext="${this.route.submitContext}" lang="${(0,ra.ifDefined)(this.effectiveLang())}" placeholder="${(0,ra.ifDefined)(r)}" @roxy-location-select="${n=>t(n.detail)}"></roxy-location-search><small class="help">${this.t("Type a city, then pick it from the list.")}</small>`}groupCard(e){let t=this.fields.filter(r=>r.group===e&&this.isRendered(r));return O.html`<fieldset part="group" class="person-group"><legend>${this.groupName(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):O.nothing}<div class="fields">${t.map(r=>this.renderField(r))}</div>${this.issueLines(this.issuesForGroup(e))}</fieldset>`}render(){return O.html`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){if(!this.loaded)return O.html`<form><div class="roxy-skeleton form-skeleton"></div></form>`;if(this.specError)return O.html`<div class="roxy-error" role="alert">${this.t("Schema load failed: {{message}}",{message:this.specError})} <button type="button" class="submit" @click="${this.retryLoadSchema}">${this.t("Retry")}</button></div>`;let e=is(this.publishableKey);if(e)return O.html`<form>${this.renderTitle()}<div part="validation-error" class="validation-error" role="alert">${this.t(e.message)}</div></form>`;let t=this.fields.filter(d=>!d.group&&this.isRendered(d)),r=this.groupKeys().filter(d=>d!==void 0),n=t.filter(d=>!d.fold),i=t.filter(d=>d.fold),o=r.filter(d=>!this.groups.find(h=>h.key===d)?.fold),l=r.filter(d=>this.groups.find(h=>h.key===d)?.fold),c=i.length>0||l.length>0;return O.html`<form @submit="${this.onSubmit}">${this.renderTitle()} ${this.validationErrors.length>0?O.html`<div part="validation-error" class="validation-error" role="alert"><strong>${this.t("Please complete:")}</strong> ${this.validationErrors.join(", ")}</div>`:O.nothing} ${this.renderIssueSummary()}<div class="fields">${n.map(d=>this.renderField(d))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):O.nothing} ${o.map(d=>this.groupCard(d))} ${this.repeats.map(d=>this.repeatControls(d))} ${c?O.html`<details part="advanced" class="advanced" ?open="${this.liveIssues().some(d=>[...i.map(h=>h.key),...l].some(h=>d.path===h||d.path.startsWith(`${h}.`)))}"><summary>${this.t("Advanced")}${he()}</summary><div class="fields">${i.map(d=>this.renderField(d))}</div>${l.map(d=>this.groupCard(d))}</details>`:O.nothing} ${this.selfSubmits?O.nothing:O.html`<button part="submit" class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,t){if(t!==""){if(e==="number"){let r=Number(t);return Number.isFinite(r)?r:void 0}return t}}};De.styles=[u,X,eh,O.css`form{gap:var(--roxy-space-md);background:var(--roxy-surface);color:var(--roxy-fg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);padding:var(--roxy-space-lg);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{margin:0}.fields{align-items:start;gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(22ch,1fr));display:grid}.fields:empty{display:none}.person-group{gap:var(--roxy-space-md);min-inline-size:0;padding:var(--roxy-space-md) 0 0;border:0;border-block-start:1px solid var(--roxy-border);margin:0;display:grid}.person-group legend{float:inline-start;color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);padding:0}.field{gap:var(--roxy-space-xs);flex-direction:column;min-inline-size:0;display:flex}.fields>*{min-inline-size:0}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm);color:var(--roxy-secondary)}.req{color:var(--roxy-danger-fg);margin-inline-start:var(--roxy-space-xs)}input,select{inline-size:100%;min-inline-size:0;min-block-size:var(--roxy-touch)}.help{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.field-error{color:var(--roxy-danger-fg);font-size:var(--roxy-text-xs)}input[aria-invalid=true],select[aria-invalid=true]{border-color:var(--roxy-danger)}input:disabled,select:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.help-details>summary{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-block-start:var(--roxy-space-xs);display:block}.location-block{gap:var(--roxy-space-xs);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(10ch,1fr));display:grid}.tiles.narrow{gap:var(--roxy-space-xs);grid-template-columns:repeat(auto-fill,minmax(4ch,1fr))}.tile{justify-content:center;align-items:center;gap:calc(var(--roxy-space-unit) / 2);min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm);background:var(--roxy-bg);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);color:var(--roxy-fg);font-size:var(--roxy-text-sm);cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing), background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-direction:column;display:flex}.tile:hover:not(:disabled){border-color:var(--roxy-accent)}.tile:disabled{cursor:default;color:var(--roxy-muted);border-style:dashed}.tile[aria-checked=true]{border-color:var(--roxy-accent);background:color-mix(in srgb, var(--roxy-accent) 12%, transparent);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.tile-glyph{font-size:var(--roxy-text-lg);line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm);display:flex}.toggle{box-sizing:content-box;block-size:.8lh;inline-size:1.6lh;padding:calc(var(--roxy-space-unit) / 2);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-full);background:var(--roxy-border);cursor:pointer;transition:background-color var(--roxy-motion-duration) var(--roxy-motion-easing);flex-shrink:0;display:inline-flex}.toggle[aria-checked=true]{background:var(--roxy-accent);border-color:var(--roxy-accent)}.toggle .knob{border-radius:var(--roxy-radius-full);background:var(--roxy-bg);block-size:.8lh;inline-size:.8lh;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.toggle[aria-checked=true] .knob{transform:translate(100%)}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.advanced>summary{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);color:var(--roxy-fg);display:flex}.advanced[open]>summary{margin-block-end:var(--roxy-space-md)}.repeat-controls{gap:var(--roxy-space-sm);display:flex}.repeat-btn{color:var(--roxy-accent-ink);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);cursor:pointer;background:0 0}.repeat-btn:hover{border-color:var(--roxy-accent-ink)}.advanced .fields,.advanced .person-group{margin-block-start:var(--roxy-space-md)}.validation-error{gap:var(--roxy-space-xs);border-inline-start:var(--roxy-line-thick) solid var(--roxy-danger);color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-sm);display:grid}button.submit{min-block-size:var(--roxy-touch);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);padding:var(--roxy-space-sm) var(--roxy-space-lg);font-weight:var(--roxy-weight-bold);cursor:pointer;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.field-skeleton{block-size:var(--roxy-touch)}.form-skeleton{block-size:5lh}`],m([(0,Fe.property)({type:String,attribute:"data-endpoint"})],De.prototype,"endpoint",2),m([(0,Fe.property)({type:String})],De.prototype,"method",2),m([(0,Fe.property)({type:String,attribute:"spec-url"})],De.prototype,"specUrl",2),m([(0,Fe.property)({type:String,attribute:"submit-label"})],De.prototype,"submitLabel",2),m([(0,Fe.property)({type:String,attribute:"publishable-key"})],De.prototype,"publishableKey",2),m([(0,Fe.property)({type:String,attribute:"location-url"})],De.prototype,"locationUrl",2),m([(0,Fe.property)({attribute:false})],De.prototype,"initialValues",2),m([(0,Fe.property)({attribute:false})],De.prototype,"serverIssues",2),m([(0,Fe.property)({attribute:false})],De.prototype,"apiRoute",2),m([(0,Fe.property)({attribute:false})],De.prototype,"autoload",2),m([(0,Fe.property)({attribute:false})],De.prototype,"fullPages",2),m([(0,Fe.state)()],De.prototype,"choices",2),m([(0,Fe.state)()],De.prototype,"clearedIssues",2),m([(0,Fe.state)()],De.prototype,"fields",2),m([(0,Fe.state)()],De.prototype,"repeats",2),m([(0,Fe.state)()],De.prototype,"formTitle",2),m([(0,Fe.state)()],De.prototype,"hasLang",2),m([(0,Fe.state)()],De.prototype,"values",2),m([(0,Fe.state)()],De.prototype,"loaded",2),m([(0,Fe.state)()],De.prototype,"specError",2),m([(0,Fe.state)()],De.prototype,"validationErrors",2),De=m([x("roxy-endpoint-form")],De);var _e=require("lit"),ih=require("lit/decorators.js");var hu="12:00 UTC",Oa=class extends g{constructor(){super(...arguments);this.heading="Ephemeris"}renderData(e){if(!e.days?.length)return this.renderEmpty();let t=this.toViewModel(e),r=this.effectiveLang();return _e.html`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2><p class="month roxy-label"><span>${Es(r,t.year,t.month)}</span><span>${hu}</span></p></header>${this.renderSignKey(t.signs)}<section part="section changes"><h3>${this.t("Sign changes and retrograde periods")}</h3><div role="list">${t.bodies.map(n=>this.renderTrack(n))}</div></section><section part="section daily"><h3>${this.t("Daily positions")}</h3><div class="scroll" part="table" tabindex="0" aria-label="${this.t("Daily positions")}">${this.renderGrid(t)}</div></section></div>`}renderSignKey(e){return e.length===0?_e.nothing:_e.html`<section part="section legend"><h3>${this.t("Signs in this month")}</h3><ul class="signkey" role="list">${e.map(t=>_e.html`<li class="signkey-item"><span class="signkey-glyph roxy-glyph" aria-hidden="true">${t.glyph}</span>${t.label}</li>`)}</ul></section>`}renderTrack(e){let t=S(e.name);return _e.html`<div class="track" role="listitem"><span class="body-name">${t?_e.html`<span class="glyph roxy-glyph" aria-hidden="true">${t}</span>`:_e.nothing}${e.label} </span><span class="span">${this.renderPosition(e.first)}<span class="arrow" aria-hidden="true">→</span>${this.renderPosition(e.last)} </span>${e.ingresses.length||e.retrogrades.length?_e.html`<span class="chips roxy-chips">${e.ingresses.map(r=>this.renderIngressChip(r))} ${e.retrogrades.map(r=>this.renderRetrogradeChip(r))}</span>`:_e.nothing}</div>`}renderPosition(e){let{degree:t,minute:r}=Xi(e.degreeInSign),n=J(e.sign),i=y(e,"sign");return _e.html`<span class="pos" title="${i}">${t}${n?_e.html`<span class="sg roxy-glyph" aria-hidden="true">${n}</span>`:_e.html`<span class="sg">${i}</span>`}${String(r).padStart(2,"0")}</span>`}renderIngressChip(e){let t=J(e.sign),r=cs(this.effectiveLang(),e.date);return _e.html`<span class="roxy-chip chip--ingress" aria-label="${this.t("Enters {{sign}} on {{date}}",{sign:e.signLabel,date:r})}"><span aria-hidden="true">→</span>${Je(t)}${e.signLabel} <span class="chip-date">${r}</span></span>`}renderRetrogradeChip(e){let t=ld(this.effectiveLang(),e.start,e.end);return _e.html`<span class="roxy-chip chip--retro" data-tone="danger"><span class="roxy-glyph" aria-hidden="true">${Ke}</span>${this.t("Retrograde {{range}}",{range:t})}</span>`}renderGrid(e){let t=this.effectiveLang();return _e.html`<table><caption class="roxy-sr-only">${this.t("Every body with its position on each day of the month, as a zodiac sign and a degree.")}</caption><thead><tr><th scope="col" class="day">${this.t("Date")}</th>${e.bodies.map(r=>{let n=S(r.name);return _e.html`<th scope="col" title="${r.label}">${n?_e.html`<span class="glyph roxy-glyph" aria-hidden="true">${n}</span><span class="roxy-sr-only">${r.label}</span>`:r.label}</th>`})}</tr></thead><tbody>${e.rows.map(r=>_e.html`<tr><th scope="row" class="day">${cd(t,r.date)}</th>${r.cells.map((n,i)=>this.renderCell(n,e.bodies[i],r.date))}</tr>`)}</tbody></table>`}renderCell(e,t,r){if(!e)return _e.html`<td>—</td>`;let n=[e.isRetrograde?"retro":"",t?.ingressDates.has(r)?"ingress":"",t?.stationDates.has(r)?"station":""].filter(Boolean).join(" ");return _e.html`<td class="${n}">${this.renderPosition(e)}${e.isRetrograde?_e.html`<span class="retro-mark roxy-glyph" aria-label="${this.t("retrograde")}">${Ke}</span>`:_e.nothing}</td>`}toViewModel(e){let t=[],r=new Map;for(let o of e.days)for(let l of o.positions){let c=r.get(l.planet);c||(c=[],r.set(l.planet,c),t.push(l.planet)),c.push({date:o.date,p:l})}let n=[];for(let o of t){let l=r.get(o),c=l?.[0],d=l?.[l.length-1];if(!l||!c||!d)continue;let h=[],p=[],f=new Set,L=new Set;for(let $=0;$<l.length;$++){let k=l[$],j=l[$-1];if(!k||(j&&k.p.sign!==j.p.sign&&(h.push({date:k.date,sign:k.p.sign,signLabel:y(k.p,"sign")}),f.add(k.date)),j&&k.p.isRetrograde!==j.p.isRetrograde&&L.add(k.date),!k.p.isRetrograde))continue;let ue=p[p.length-1];ue&&j?.p.isRetrograde?ue.end=k.date:p.push({start:k.date,end:k.date})}n.push({name:o,label:y(d.p,"planet"),first:c.p,last:d.p,ingresses:h,retrogrades:p,ingressDates:f,stationDates:L})}let i=e.days.map(o=>{let l=new Map(o.positions.map(c=>[c.planet,c]));return{date:o.date,cells:n.map(c=>l.get(c.name))}});return{year:e.year,month:e.month,bodies:n,rows:i,signs:this.toSignKey(e)}}toSignKey(e){let t=new Map;for(let n of e.days)for(let i of n.positions){let o=String(i.sign??"").toLowerCase();o&&!t.has(o)&&t.set(o,y(i,"sign"))}let r=[];for(let n of Ie){let i=t.get(n.toLowerCase()),o=J(n);i&&o&&r.push({sign:n,label:i,glyph:o})}return r}};Oa.endpoints=Tl,Oa.styles=[u,_e.css`:host{overflow-x:clip}.wrap{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,h3,p{margin:0}header,section{gap:var(--roxy-space-sm);display:grid}.month{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.signkey{gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.signkey-item{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);white-space:nowrap;display:inline-flex}.signkey-glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.track{align-items:center;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.body-name{align-items:baseline;gap:var(--roxy-space-xs);min-inline-size:16ch;font-weight:var(--roxy-weight-bold);display:inline-flex}.body-name .glyph{color:var(--roxy-accent-ink)}.span{align-items:baseline;gap:var(--roxy-space-xs);color:var(--roxy-secondary);font-variant-numeric:tabular-nums;white-space:nowrap;display:inline-flex}.arrow{color:var(--roxy-muted)}.chips{margin-inline-start:auto}.chip-date{color:var(--roxy-muted)}.scroll{min-width:0;overflow-x:auto}table{font-size:var(--roxy-text-xs)}:is(th,td){white-space:nowrap}thead th .glyph{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}th.day{z-index:1;background:var(--roxy-bg);color:var(--roxy-fg);border-inline-end:1px solid var(--roxy-border);position:sticky;left:0}thead th.day{z-index:2}.sg{margin-inline:calc(var(--roxy-space-unit) / 2);color:var(--roxy-secondary);font-variant-numeric:normal}.retro-mark{font-weight:var(--roxy-weight-bold);margin-inline-start:calc(var(--roxy-space-unit) / 2)}td.retro,td.retro .sg{color:var(--roxy-danger-fg)}td.ingress{box-shadow:inset var(--roxy-line-thick) 0 var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}td.station{border-block-start:var(--roxy-line-thick) solid var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}`],m([(0,ih.property)({type:String})],Oa.prototype,"heading",2),Oa=m([x("roxy-ephemeris-table")],Oa);var at=require("lit");var Tr=class extends g{renderData(a){let e=a.conjunctions??[],t=a.stars??[];return at.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Fixed stars")}</h2>${typeof a.orb=="number"?at.html`<p class="roxy-label">${this.t("Orb")} ${b(this.effectiveLang(),a.orb,1)}°</p>`:at.nothing}</header>${a.summary&&!this.hideReadings?at.html`<p class="summary">${a.summary}</p>`:at.nothing} ${e.length?at.html`<section part="section conjunctions"><h3>${this.t("Conjunctions to the chart")}</h3>${e.map((r,n)=>at.html`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${n===0}"><summary><span class="interp-lead">${this.t("{{point}} conjunct {{star}}",{point:y(r,"point"),star:r.star})}</span> ${he()} <span class="interp-aside"><small>${this.t("orb {{value}}\xB0",{value:b(this.effectiveLang(),r.orb,2)})}</small></span></summary>${r.interpretation&&!this.hideReadings?at.html`<div class="interp-body"><p>${r.interpretation}</p></div>`:at.nothing}</details>`)}</section>`:at.html`<p class="empty-note">${this.t("No star sits within the orb of a natal point.")}</p>`} ${t.length?this.renderCatalog(t):at.nothing}</div>`}renderCatalog(a){return at.html`<details class="catalog"><summary>${he()} ${this.t("Star catalog ({{count}})",{count:a.length})}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Precessed positions for the chart date")}"><table><caption class="roxy-label">${this.t("Precessed positions for the chart date")}</caption><thead><tr><th scope="col">${this.t("Star")}</th><th scope="col">${this.t("Position")}</th><th scope="col" class="num">${this.t("Mag")}</th><th scope="col">${this.t("Nature")}</th><th scope="col">${this.t("Keywords")}</th></tr></thead><tbody>${a.map(e=>{let t=J(e.sign);return at.html`<tr><td>${e.name}</td><td>${t?at.html`<span class="sg roxy-glyph">${t}</span>`:at.nothing}${ta(e.degree)} ${e.sign}</td><td class="num">${b(this.effectiveLang(),e.magnitude,1)}</td><td>${e.nature}</td><td><ul class="kw roxy-chips">${(e.keywords??[]).map(r=>at.html`<li>${r}</li>`)}</ul></td></tr>`})}</tbody></table></div></details>`}};Tr.endpoints=El,Tr.styles=[u,X,me,at.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.summary{font-size:var(--roxy-text-sm)}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}section>h3{margin-block-end:var(--roxy-space-sm)}.interp-lead .point{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);display:flex}.scroll{min-width:0;margin-block-start:var(--roxy-space-sm);overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.sg{color:var(--roxy-secondary);margin-inline-end:var(--roxy-space-xs)}.kw{max-inline-size:32ch}`],Tr=m([x("roxy-fixed-stars")],Tr);var P=require("lit"),lh=require("lit/decorators.js");var pi=["Southeast","South","Southwest","East","Center","West","Northeast","North","Northwest"];var oh=require("lit"),hi=oh.css`.plate-heading{font-size:var(--roxy-text-xs);color:var(--roxy-muted);font-weight:var(--roxy-weight-bold);hyphens:manual}@container (width<=30rem){.plate-heading{font-size:calc(var(--roxy-text-xs) / var(--roxy-text-scale) / var(--roxy-text-scale))}}`;var mi={forward:"Forward",reverse:"Backward"};function xs(s){return"mountainCenterStar"in s}var Ga=class extends g{constructor(){super(...arguments);this.mode="natal"}renderData(e){let t=this.effectiveLang(),r=this.mode!=="annual"&&xs(e);return P.html`<article class="card" part="card" aria-labelledby="flying-star-title"><header class="head" part="header"><h2 class="title" id="flying-star-title">${this.t("Flying star chart")}</h2>${xs(e)?r?P.html`<span class="period">${this.t("Period {{n}}",{n:q(t,e.period??0)})}</span>`:P.nothing:P.html`<span class="period">${e.year??""}</span>`}</header>${xs(e)?r?this.renderNatalFacts(e,t):P.nothing:this.renderAnnualFacts(e,t)}<div class="plate" part="chart plate" role="group" aria-label="${this.t("Flying star chart")}">${pi.map(n=>this.renderPalace(e,n))}</div>${r?P.html`<div class="legend" part="legend"><span><span class="swatch swatch-mountain"></span>${this.t("Mountain star")}</span> <span><span class="swatch swatch-water"></span>${this.t("Water star")}</span> <span>${this.t("Period star")}</span></div>`:P.nothing} ${r&&xs(e)?this.renderStructure(e):P.nothing} ${this.renderPalaceRows(e)}</article>`}renderNatalFacts(e,t){return P.html`<div class="facts" part="details">${e.facing?P.html`<span><span class="roxy-label">${this.t("Facing")}</span> <b>${ie(t,"facing",e.facing.label??"")}</b></span>`:P.nothing} ${e.sitting?P.html`<span><span class="roxy-label">${this.t("Sitting")}</span> <b>${ie(t,"facing",e.sitting.label??"")}</b></span>`:P.nothing} ${typeof e.facingDegrees=="number"?P.html`<span>${q(t,e.facingDegrees)}°</span>`:P.nothing} ${e.mountainFlight?P.html`<span><span class="roxy-label">${this.t("Mountain star")}</span> ${mi[e.mountainFlight]?this.t(mi[e.mountainFlight]):e.mountainFlight}</span>`:P.nothing} ${e.waterFlight?P.html`<span><span class="roxy-label">${this.t("Water star")}</span> ${mi[e.waterFlight]?this.t(mi[e.waterFlight]):e.waterFlight}</span>`:P.nothing} ${e.straddling?P.html`<span><b>${this.t("Straddling")}</b></span>`:P.nothing}</div>`}renderAnnualFacts(e,t){return!e.changeoverDate&&typeof e.centerStar!="number"?P.nothing:P.html`<div class="facts" part="details">${typeof e.centerStar=="number"?P.html`<span><span class="roxy-label">${this.t("Center")}</span> <b>${q(t,e.centerStar)}</b></span>`:P.nothing} ${e.changeoverDate?P.html`<span>${M(t,e.changeoverDate)}</span>`:P.nothing}</div>`}paletteHeading(e,t){return t==="Center"?this.t("Center"):ie(e,"facing",t)}renderPalace(e,t){let r=this.effectiveLang(),n=this.paletteHeading(r,t),i=(e.palaces??[]).find(d=>d.palace===t),o=this.mode!=="annual"&&xs(e);if(!i)return P.html`<div class="palace"><span class="palace-name plate-heading">${n}</span></div>`;let l=t==="Center";if(o&&xs(e)){let d=i;return P.html`<div class="palace ${l?"palace-center":""}"><span class="mountain" title="${this.t("Mountain star")}">${d.mountain??""}</span> <span class="water" title="${this.t("Water star")}">${d.water??""}</span> <span class="star" title="${this.t("Period star")}">${d.period??""}</span> <span class="palace-name plate-heading">${n}</span> ${d.combination?P.html`<span class="combo">${y(d.combination,"name")}</span>`:P.nothing}</div>`}let c=i;return P.html`<div class="palace ${l?"palace-center":""}"><span class="star">${c.star??""}</span> <span class="palace-name plate-heading">${n}</span> <span class="combo">${y(c,"name")}</span></div>`}renderStructure(e){let t=e.structure;return t?.name?P.html`<section part="section structure"><h3 class="block-title">${t.name}</h3>${t.meaning&&!this.hideReadings?P.html`<p class="structure" part="reading">${t.meaning}</p>`:P.nothing}</section>`:P.nothing}renderPalaceRows(e){let t=e.palaces??[];if(t.length===0)return P.nothing;let r=this.effectiveLang(),n=this.mode!=="annual"&&xs(e),i=t.map(o=>{let l=this.paletteHeading(r,o.palace??"");if(n){let d=o;return!d.reading&&!d.combination?P.nothing:P.html`<li class="row" part="label-track"><span class="roxy-label">${l}</span><div class="row-body">${d.combination?P.html`<span>${y(d.combination,"name")}</span>`:P.nothing} ${d.reading&&!this.hideReadings?P.html`<p part="reading">${d.reading}</p>`:P.nothing}</div></li>`}let c=o;return P.html`<li class="row" part="label-track"><span class="roxy-label">${l}</span><div class="row-body"><span>${y(c,"name")}</span> ${c.element?P.html`<span class="element-word ${At(c.element)}">${y(c,"element")}</span>`:P.nothing}<dl class="star-facts">${c.nature?P.html`<div><dt>${this.t("Nature")}</dt><dd>${c.nature==="auspicious"?this.t("Favourable"):c.nature==="inauspicious"?this.t("Unfavourable"):c.nature}</dd></div>`:P.nothing} ${c.enhancer?P.html`<div><dt>${this.t("Enhancer")}</dt><dd>${c.enhancer}</dd></div>`:P.nothing} ${c.remedy?P.html`<div><dt>${this.t("Remedy")}</dt><dd>${c.remedy}</dd></div>`:P.nothing}</dl>${c.meaning&&!this.hideReadings?P.html`<p part="reading">${c.meaning}</p>`:P.nothing}</div></li>`});return i.every(o=>o===P.nothing)?P.nothing:P.html`<section part="section palaces"><ul class="rows">${i}</ul></section>`}};Ga.endpoints=Dl,Ga.styles=[u,ma,hi,wr,P.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.period{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.plate{background:var(--roxy-border);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;display:grid;overflow:hidden}.palace{align-content:start;gap:calc(var(--roxy-space-unit) / 2);min-block-size:3.5lh;padding:var(--roxy-space-sm);background:var(--roxy-surface);grid-template-columns:1fr 1fr;display:grid}.palace-center{background:color-mix(in srgb, var(--roxy-accent) 8%, var(--roxy-surface))}.mountain,.water{font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.mountain{color:var(--roxy-info-fg);text-align:start}.water{color:var(--roxy-accent-ink);text-align:end}.star,.palace-name,.combo{text-align:center;grid-column:1/-1}.star{font-size:calc(var(--roxy-text-base) * 1.75);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.combo{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-mountain{background:var(--roxy-info)}.swatch-water{background:var(--roxy-accent)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.row-body p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}.star-facts{gap:var(--roxy-space-xs) var(--roxy-space-md);margin:var(--roxy-space-xs) 0 0;font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.star-facts div{gap:var(--roxy-space-xs);display:flex}.star-facts dt{color:var(--roxy-secondary);font-size:inherit}.star-facts dd{margin:0}.structure{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);border-block-start:0;margin:0}`],m([(0,lh.property)({type:String,reflect:true})],Ga.prototype,"mode",2),Ga=m([x("roxy-flying-star-chart")],Ga);var Mt=require("lit");var Er=class extends g{renderData(a){let e=a.windows??[];if(e.length===0)return this.renderEmpty();let t=Et(this.effectiveLang(),a.startDate,a.endDate);return Mt.html`<div class="wrap" part="card" aria-label="${this.t("Forecast digest")}"><div class="head" part="header"><h2>${this.t("Forecast digest")}</h2>${t?Mt.html`<p class="subtitle">${t}</p>`:Mt.nothing}</div>${e.map(r=>this.renderWindow(r))}</div>`}windowLabel(a){return a===1?this.t("Next 24 hours"):typeof a=="number"?this.t("Next {{count}} days",{count:a}):this.t("Window")}renderWindow(a){let e=[...a.top??[]].sort((n,i)=>(i.significance??0)-(n.significance??0)),t=a.byDomain??{},r=Object.entries(t);return Mt.html`<section class="window" part="section window"><div class="window-head" part="details"><h3>${this.windowLabel(a.days)}</h3><span class="window-count">${this.t("{{count}} events",{count:a.count??0})}</span></div>${r.length>0?Mt.html`<div class="domains" part="legend">${r.map(([n,i])=>Mt.html`<span class="domain-chip"><span class="swatch sw-${n}"></span>${D(n)} ${i}</span>`)}</div>`:Mt.nothing} ${e.length>0?Mt.html`<div role="list">${e.map(n=>this.renderEvent(n))}</div>`:Mt.html`<p class="quiet">${this.t("No notable events.")}</p>`}</section>`}renderEvent(a){let e=typeof a.significance=="number"?a.significance:0,t=this.hideReadings||a.description==null?D(a.type??""):a.description;return Mt.html`<div class="event" part="label-track" role="listitem"><span class="event-date">${M(this.effectiveLang(),a.date)}</span> <span class="event-desc">${t}</span> <span class="sig" role="img" aria-label="${this.t("significance {{value}} of 100",{value:b(this.effectiveLang(),e,0)})}"><span class="sig-fill ${a.domain}" style="width:${Math.max(0,Math.min(100,e))}%"></span></span></div>`}};Er.endpoints=Al,Er.styles=[u,Mt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.window{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.window:first-of-type{border-block-start:0;padding-block-start:0}.window-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.window-count{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.domains{gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.domain-chip{align-items:center;gap:var(--roxy-space-xs);color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:inline-flex}.swatch{border-radius:var(--roxy-radius-sm);block-size:.6lh;inline-size:.6lh;display:inline-block}.sw-western,.sig-fill.western{background:var(--roxy-accent)}.sw-vedic,.sig-fill.vedic{background:var(--roxy-info)}.sw-biorhythm,.sig-fill.biorhythm{background:var(--roxy-success)}.event{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);display:grid}.event-date{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.event-desc{font-size:var(--roxy-text-sm);line-height:var(--roxy-leading-tight)}.sig{block-size:calc(var(--roxy-line-thick) * 2);border-radius:var(--roxy-radius-full);background:var(--roxy-border);grid-column:2;overflow:hidden}.sig-fill{height:100%;display:block}.quiet{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-style:italic}`],Er=m([x("roxy-forecast-digest")],Er);var Be=require("lit");var mu={western:"Western",vedic:"Vedic",biorhythm:"Biorhythm"},ch=20,gu=["western","vedic","biorhythm"],Dr=class extends g{renderData(a){let e=a.events??[],t=this.groupByDate(e),r=gu.filter(n=>e.some(i=>i.domain===n));return Be.html`<div class="wrap" part="card" aria-label="${this.t("Forecast timeline")}"><header class="head" part="header"><h2>${this.t("Forecast timeline")}</h2>${a.startDate&&a.endDate?Be.html`<div class="range">${Et(this.effectiveLang(),a.startDate,a.endDate)} · ${this.t("{{count}} events",{count:a.count??e.length})}</div>`:Be.nothing}</header>${r.length?Be.html`<div class="legend" part="legend">${r.map(n=>Be.html`<span><span class="swatch swatch-${n}"></span>${mu[n]}</span>`)}</div>`:Be.nothing} ${t.length?Be.html`<div class="days" part="section events" role="list">${t.map(([n,i])=>this.renderDay(n,i))}</div>`:Be.html`<p class="roxy-empty" role="status">${this.t("No events in this window")}</p>`}</div>`}groupByDate(a){let e=new Map;for(let t of a){let r=t.date??"",n=e.get(r)??[];n.push(t),e.set(r,n)}return[...e.entries()]}renderDay(a,e){return Be.html`<div class="day" role="listitem"><div class="day-date">${M(this.effectiveLang(),a)}</div><div class="events">${e.map(t=>this.renderEvent(t))}</div></div>`}renderEvent(a){let e=typeof a.significance=="number"?a.significance:0,t=Math.max(0,Math.min(100,e));return Be.html`<div class="event"><span class="dot dot-${a.domain}" aria-hidden="true"></span><div class="event-body"><div class="event-line">${this.renderMoon(a)}${this.renderHeadline(a)}</div>${a.description&&!this.hideReadings?Be.html`<p class="event-desc">${a.description}</p>`:Be.nothing}<div class="sig" title="${this.t("significance {{value}} of 100",{value:t})}"><span class="sig-track"><span class="sig-fill sig-fill-${a.domain}" style="width:${t}%"></span> </span><span class="sig-val">${t}</span></div></div></div>`}renderHeadline(a){let e=a.body?D(a.body):"",t=a.target?D(a.target):"",r=Dt({type:a.aspect}),n=r?Ns(a.aspect)??je({type:a.aspect}):"",i=typeof a.orb=="number"?b(this.effectiveLang(),a.orb,1):"",o=this.typeQualifier(a);return r&&t?Be.html`<strong>${e}</strong> <span class="${`${Qe({type:a.aspect})} roxy-glyph`}">${n}</span> <strong>${t}</strong>${i?Be.html`<span class="kind">${this.t("orb {{value}}\xB0",{value:i})}</span>`:Be.nothing}`:Be.html`<strong>${e||D(a.type??"")}</strong>${o?Be.html`<span class="kind">${o}</span>`:Be.nothing}`}renderMoon(a){if(a.type==="lunar-phase"&&a.phase)return ea(this,{illumination:a.phase==="full-moon"?100:0,waxing:true},ch);if(a.type!=="eclipse")return Be.nothing;let e=$t(a.body)==="sun";return ea(this,{illumination:e?0:100,waxing:true},ch,e?"solar":"lunar")}typeQualifier(a){return a.type==="sign-ingress"&&a.target?`enters ${D(a.target)}`:a.type==="retrograde-station"&&a.station?a.station:a.type==="eclipse"?[a.kind,"eclipse"].filter(Boolean).join(" "):a.type==="critical-day"?"critical day":a.type==="dasha-change"&&a.target?`dasha ${D(a.target)}`:D(a.type??"")}};Dr.endpoints=Pl,Dr.styles=[u,Ca,sr,Be.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.range{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.legend{gap:var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.legend .swatch{block-size:.6lh;inline-size:.6lh;border-radius:var(--roxy-radius-full);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-western,.dot-western,.sig-fill-western{background:var(--roxy-accent)}.swatch-vedic,.dot-vedic,.sig-fill-vedic{background:var(--roxy-info)}.swatch-biorhythm,.dot-biorhythm,.sig-fill-biorhythm{background:var(--roxy-success)}.day{gap:var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);grid-template-columns:9ch minmax(0,1fr);display:grid}.day:first-of-type{border-block-start:0}@container (width<=30rem){.day{grid-template-columns:minmax(0,1fr)}}.day-date{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;padding-block-start:calc(var(--roxy-space-unit) / 2)}.events{gap:var(--roxy-space-sm);display:grid}.event{align-items:start;gap:var(--roxy-space-sm);grid-template-columns:.4lh minmax(0,1fr);display:grid}.dot{block-size:.4lh;inline-size:.4lh;border-radius:var(--roxy-radius-full);margin-block-start:var(--roxy-space-xs)}.event-body{min-width:0}.event-line{font-size:var(--roxy-text-sm)}.event-line .moon-mark{margin-inline-end:var(--roxy-space-xs)}.event-line .kind{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}.event-desc{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2)}.sig{align-items:center;gap:var(--roxy-space-xs);margin-block-start:var(--roxy-space-xs);display:flex}.sig-track{max-inline-size:16ch;block-size:calc(var(--roxy-line-thick) * 2);border-radius:var(--roxy-radius-full);background:var(--roxy-border);flex:1;overflow:hidden}.sig-fill{height:100%;display:block}.sig-val{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],Dr=m([x("roxy-forecast-timeline")],Dr);var N=require("lit"),dh=require("lit/directives/if-defined.js");var Ar=class extends g{renderData(a){let e=this.effectiveLang(),t=a.chosen,r=a.input?.text??a.input?.textHebrew??"";return N.html`<article class="card" part="card" aria-labelledby="gematria-title"><header class="head" part="header"><h2 id="gematria-title">${r?`${this.t("Gematria")} \xB7 ${r}`:this.t("Gematria")}</h2>${t?.hebrew?N.html`<span class="hebrew" lang="he" dir="rtl">${t.hebrew}</span>`:N.nothing} ${this.chosenForm(a)?.romanization?N.html`<span class="roman">${this.chosenForm(a)?.romanization}</span>`:N.nothing} ${t?.rule?N.html`<p class="rule">${t.rule}</p>`:N.nothing}</header>${this.renderLetters(e,this.chosenForm(a)?.letters)} ${this.renderValues(e,a.values,this.t("Cipher values"))} ${this.renderForms(e,a)} ${this.renderTransformations(e,a.transformations)} ${this.renderLatin(e,a.latinValues)} ${this.renderMatches(e,a.matches)} ${this.renderConventions(a.conventions)}</article>`}chosenForm(a){let e=a.hebrewForms??[];return e.find(t=>t.hebrew===a.chosen?.hebrew)??e[0]}renderLetters(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section letters"><h3>${this.t("Letters")}</h3><div class="letters" part="chart" dir="rtl">${t.map(r=>N.html`<div class="${`letter${r.isFinal?" is-final":""}`}" dir="ltr" title="${(0,dh.ifDefined)(r.isFinal?this.t("Final form"):void 0)}"><span class="glyph" lang="he">${r.glyph??""}</span> <span class="name">${r.name??""}</span> <span class="num">${q(a,r.value)}</span></div>`)}</div>${t.some(r=>r.isFinal)?N.html`<p class="legend" part="legend"><span class="swatch"></span>${this.t("Final form")}</p>`:N.nothing}</section>`}renderValues(a,e,t){let r=(e??[]).filter(i=>typeof i.value=="number");if(r.length===0)return N.nothing;let n=r.some(i=>(i.alternateValues??[]).length>0);return N.html`<section part="section values"><h3>${t}</h3><div class="scroll" tabindex="0" role="region" aria-label="${t}"><table><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Value")}</th>${n?N.html`<th>${this.t("Also published")}</th>`:N.nothing}</tr></thead><tbody>${r.map(i=>N.html`<tr><td>${D(i.id??"")}</td><td class="num">${q(a,i.value)}</td>${n?N.html`<td class="num">${(i.alternateValues??[]).map(o=>q(a,o)).join(", ")}</td>`:N.nothing}</tr>`)}</tbody></table></div>${this.renderProvenance(r)}</section>`}renderProvenance(a){let e=new Map;for(let t of a)t.tradition&&!e.has(t.tradition)&&e.set(t.tradition,t.source);return e.size===0?N.nothing:N.html`<p class="provenance"><span class="roxy-label">${this.t("Tradition")}</span> ${[...e].map(([t,r],n)=>N.html`${n>0?" \xB7 ":""}${D(t)}${yn(r)?N.html`<a class="src" href="${r}" target="_blank" rel="noopener noreferrer">${this.t("Source")}</a>`:N.nothing}`)}</p>`}renderForms(a,e){let t=e.hebrewForms??[];return t.length<2?N.nothing:N.html`<section part="section spellings"><h3>${this.t("Spellings")}</h3><ul class="forms">${t.map(r=>N.html`<li class="form"><div><span class="hebrew" lang="he" dir="rtl">${r.hebrew??""}</span> ${r.hebrew===e.chosen?.hebrew?N.html`<span class="chosen roxy-chip" data-tone="success">${this.t("Chosen")}</span>`:N.nothing}</div><span class="roman">${r.romanization??""}</span> ${r.rule?N.html`<p class="rule">${r.rule}</p>`:N.nothing} ${this.renderFormTotals(a,r)}</li>`)}</ul></section>`}renderFormTotals(a,e){let t=(e.values??[]).find(r=>typeof r.value=="number");return t?N.html`<p class="rule"><span class="roxy-label">${D(t.id??"")}</span> ${q(a,t.value)}</p>`:N.nothing}renderTransformations(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section substitutions"><h3>${this.t("Substitutions")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Substitutions")}"><table><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Output")}</th><th>${this.t("Value")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td>${D(r.id??"")}</td><td>${r.output?N.html`<span lang="he" dir="rtl">${r.output}</span>`:N.nothing} ${r.outputRomanization?N.html`<span class="roman">${r.outputRomanization}</span>`:N.nothing}</td><td class="num">${q(a,r.value)}</td></tr>`)}</tbody></table></div></section>`}renderLatin(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section latin-ciphers"><h3>${this.t("Latin ciphers")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Latin ciphers")}"><table class="stacked"><thead><tr><th>${this.t("Cipher")}</th><th>${this.t("Value")}</th><th>${this.t("Tradition")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td data-label="${this.t("Cipher")}">${D(r.id??"")} ${r.lineage?N.html`<p class="lineage">${r.lineage}</p>`:N.nothing}</td><td class="num" data-label="${this.t("Value")}">${q(a,r.value)}</td><td data-label="${this.t("Tradition")}">${D(r.tradition??"")}</td></tr>`)}</tbody></table></div></section>`}renderMatches(a,e){let t=e??[];return t.length===0?N.nothing:N.html`<section part="section matches"><h3>${this.t("Equal values")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Equal values")}"><table class="stacked"><thead><tr><th>${this.t("Word")}</th><th>${this.t("Meaning")}</th><th>${this.t("Value")}</th></tr></thead><tbody>${t.map(r=>N.html`<tr><td data-label="${this.t("Word")}"><span lang="he" dir="rtl">${r.hebrew??""}</span> <span class="roman">${r.romanization??""}</span></td><td data-label="${this.t("Meaning")}">${r.meaning??""} ${r.note&&!this.hideReadings?N.html`<p class="match-note" part="reading">${r.note}</p>`:N.nothing}</td><td class="num" data-label="${this.t("Value")}">${q(a,r.value)}</td></tr>`)}</tbody></table></div></section>`}renderConventions(a){let e=this.effectiveLang(),t=[];for(let r of["transliteration","misparGadol"]){let n=a?.[r];n&&t.push([Se(e,r),ie(e,r,n)])}return t.length===0?N.nothing:N.html`<p class="provenance">${t.map(([r,n],i)=>N.html`${i>0?" \xB7 ":""}<span class="roxy-label">${r}</span>${n}`)}</p>`}};Ar.endpoints=Ml,Ar.styles=[u,pa,N.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{justify-items:start;gap:calc(var(--roxy-space-unit) / 2);min-width:0;display:grid}.hebrew{font-size:calc(var(--roxy-text-xl) * 1.3);font-weight:var(--roxy-weight-bold);line-height:1.4}.roman{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.rule{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.provenance .roxy-label,.rule .roxy-label{font-size:inherit;margin-inline-end:var(--roxy-space-xs)}.src{margin-inline-start:var(--roxy-space-xs)}.letters{gap:var(--roxy-space-xs);flex-wrap:wrap;display:flex}.letter{justify-items:center;gap:calc(var(--roxy-space-unit) / 2);min-inline-size:5ch;padding:var(--roxy-space-xs) var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);display:grid}.letter .glyph{font-size:var(--roxy-text-lg);line-height:1.3}.letter .name{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.letter .num{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.letter.is-final{border-color:var(--roxy-accent)}.legend{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:var(--roxy-space-sm)}.legend .swatch{block-size:.6lh;inline-size:.6lh;border:1px solid var(--roxy-accent);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td.num{white-space:nowrap}.provenance{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:var(--roxy-space-sm)}.lineage,.match-note{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);white-space:normal;margin-block-start:calc(var(--roxy-space-unit) / 2)}a{color:var(--roxy-accent-ink)}.forms{gap:var(--roxy-space-md);margin:0;padding:0;list-style:none;display:grid}.form{gap:var(--roxy-space-xs);min-width:0;border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.form:first-child{border-block-start:0;padding-block-start:0}`],Ar=m([x("roxy-gematria")],Ar);var qe=require("lit");var ph=8,Pr=class extends g{renderData(a){let e=a.transitingPlanets??[];if(!e.length)return this.renderEmpty();let t=a.keyTransits??[],r=a.natalPlanets?.find(n=>n.name==="Moon")?.sign;return qe.html`<div class="wrap" part="card" aria-label="${this.t("Gochara transits")}"><header class="head" part="header"><h2>${this.t("Gochara")}</h2><p class="sub">${this.t("Where each graha transits at {{when}}, read against the natal chart of {{birth}}.",{when:fe(this.effectiveLang(),a.transitDatetime),birth:fe(this.effectiveLang(),a.birthDatetime)})}</p>${r?qe.html`<p class="sub">${this.t("Gochara houses are counted from the natal Moon in {{sign}}.",{sign:r})}</p>`:qe.nothing} ${ve(this.effectiveLang(),a.frame,this.translator)}</header><div part="table">${e.map(n=>this.renderPlanet(n))}</div>${t.length&&!this.hideReadings?qe.html`<section class="key" part="section key-transits"><h3>${this.t("Key transits")}</h3>${t.map(n=>qe.html`<p class="key-item">${n.description}</p>`)}</section>`:qe.nothing}</div>`}renderPlanet(a){let e=S(a.name)??"",t=typeof a.longitude=="number"?qt(a.longitude):void 0;return qe.html`<article class="row"><div class="row-top"><span class="graha">${e?qe.html`<span class="glyph roxy-glyph">${e}</span>`:qe.nothing}${a.name} </span><span class="pos">${t?`${a.sign} ${t}`:a.sign} </span>${typeof a.houseFromMoon=="number"?qe.html`<span class="house moon roxy-chip">${this.t("house {{n}} from the Moon",{n:a.houseFromMoon})}</span>`:qe.nothing} ${typeof a.natalHouse=="number"?qe.html`<span class="house lagna roxy-chip">${this.t("house {{n}} from the Lagna",{n:a.natalHouse})}</span>`:qe.nothing}</div>${this.renderKaksha(a.kaksha)} ${this.renderContacts(this.t("Drishti"),a.drishtiToNatal)} ${this.renderContacts(this.t("Aspects"),a.aspectsToNatal)}</article>`}renderContacts(a,e){return e?.length?qe.html`<p class="aspects"><span class="contact-label">${a}</span> ${e.map(t=>typeof t.orb=="number"?this.t("{{aspect}} natal {{planet}} ({{orb}}\xB0)",{aspect:je({type:t.aspectType}),planet:t.natalPlanet,orb:b(this.effectiveLang(),t.orb,1)}):this.t("{{aspect}} natal {{planet}}",{aspect:je({type:t.aspectType}),planet:t.natalPlanet})).join(" \xB7 ")}</p>`:qe.nothing}renderKaksha(a){if(!a||typeof a.number!="number")return qe.nothing;let e=a.number,t=a.bindu===true?"yes":a.bindu===false?"no":"",r=ph,n=a.lord&&typeof a.startDegree=="number"&&typeof a.endDegree=="number"?this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:e,total:r,graha:a.lord,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)}):a.lord?this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}",{n:e,total:r,graha:a.lord}):typeof a.startDegree=="number"&&typeof a.endDegree=="number"?this.t("Kaksha {{n}} of {{total}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:e,total:r,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)}):this.t("Kaksha {{n}} of {{total}}",{n:e,total:r}),i=a.bindu===null||a.bindu===void 0?"":typeof a.binduCount=="number"?a.bindu?this.t("this kaksha lord gave bindu, {{count}} of {{total}} in this sign",{count:a.binduCount,total:r}):this.t("this kaksha lord gave no bindu, {{count}} of {{total}} in this sign",{count:a.binduCount,total:r}):a.bindu?this.t("this kaksha lord gave bindu"):this.t("this kaksha lord gave no bindu");return qe.html`<div class="kaksha-bar" part="chart" role="img" aria-label="${this.t("Kaksha {{n}} of {{total}} within the current sign",{n:e,total:r})}">${Array.from({length:ph},(o,l)=>qe.html`<span class="seg ${l+1===e?`here ${t}`:""}"></span>`)}</div><p class="meta">${i?`${n} \xB7 ${i}`:n}</p>`}};Pr.endpoints=_l,Pr.styles=[u,re,qe.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);display:grid}h2,h3,p{margin:0}.sub,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.pos{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.house.moon{border-color:var(--roxy-accent);color:var(--roxy-fg)}.contact-label{font-weight:var(--roxy-weight-bold);margin-inline-end:var(--roxy-space-xs)}.kaksha-bar{block-size:.4lh;margin-block:var(--roxy-space-xs);grid-template-columns:repeat(8,minmax(0,1fr));gap:1px;display:grid}.seg{background:var(--roxy-border);border-radius:var(--roxy-radius-sm)}.seg.here{background:var(--roxy-muted)}.seg.here.yes{background:var(--roxy-success)}.seg.here.no{background:var(--roxy-warning)}.aspects{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.key{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);display:grid}.key-item{font-size:var(--roxy-text-sm)}`],Pr=m([x("roxy-gochara-table")],Pr);var rt=require("lit");var yu={varna:1,vashya:2,tara:3,yoni:4,"graha maitri":5,gana:6,bhakoot:7,nadi:8},Mr=class extends g{renderData(a){let e=(a.breakdown??[]).filter(c=>c?.category!==void 0),t=a.total??0,r=a.maxScore??36,n=t/r*100,i=n>=70?"high":n>=50?"mid":"low",o=n*2.827,l=(100-n)*2.827;return rt.html`<article class="card" part="card" aria-label="${this.t("Guna Milan score")}"><div class="score-header" part="header"><div class="score-info"><div class="score-bar" part="details"><div><span class="total">${b(this.effectiveLang(),a.total,1)}</span> <span class="over">/ ${a.maxScore}</span> ${typeof a.percentage=="number"?rt.html`<small class="pct">${Ne(this.effectiveLang(),a.percentage,1)}</small>`:rt.nothing}</div><div class="verdict-wrap">${typeof a.isCompatible=="boolean"?rt.html`<span class="verdict roxy-chip ${a.isCompatible?"yes":"no"}" data-tone="${a.isCompatible?"success":"danger"}">${a.isCompatible?this.t("Compatible"):this.t("Not compatible")}</span>`:rt.nothing} ${a.recommendation&&!this.hideReadings?rt.html`<span class="recommendation">${a.recommendation}</span>`:rt.nothing}</div></div></div><div class="score-ring" part="chart" role="meter" aria-label="${this.t("Guna Milan score")}" aria-valuemin="0" aria-valuemax="${r}" aria-valuenow="${t}"><svg viewBox="0 0 100 100" aria-hidden="true"><circle class="ring-track" cx="50" cy="50" r="45"/><circle class="ring-fill" data-band="${i}" cx="50" cy="50" r="45" stroke-dasharray="${o},${l}" transform="rotate(-90 50 50)"/></svg></div></div>${e.length>0?rt.html`<div class="table-scroll" part="table"><table class="stacked"><caption class="roxy-sr-only">${this.t("Guna Milan breakdown: each koota with the classification of person 1 and person 2, and the score it earned out of its maximum.")}</caption><thead><tr><th scope="col">${this.t("Koota")}</th><th scope="col">${this.t("Person 1")}</th><th scope="col">${this.t("Person 2")}</th><th scope="col" class="bar-col">${this.t("Progress")}</th><th scope="col" class="score">${this.t("Points")}</th></tr></thead><tbody>${e.map(c=>{let d=c.score??0,h=c.maxScore??uu(c.category),p=h?d/h*100:0;return rt.html`<tr><td>${c.category} ${c.description?rt.html`<small>${c.description}</small>`:rt.nothing}</td><td class="classification" data-label="${this.t("Person 1")}">${c.person1??""}</td><td class="classification" data-label="${this.t("Person 2")}">${c.person2??""}</td><td class="bar-cell bar-col"><div class="mini-bar"><span style="width:${p}%"></span></div></td><td class="score" data-label="${this.t("Points")}">${b(this.effectiveLang(),d,1)} / ${h}</td></tr>`})}</tbody></table></div>`:rt.nothing} ${(a.doshas?.length??0)>0||(a.doshaCancellations?.length??0)>0?rt.html`<ul class="tags roxy-chips" part="details">${a.doshas?.map(c=>rt.html`<li class="dosha roxy-chip" data-tone="danger">${c}</li>`)} ${a.doshaCancellations?.map(c=>rt.html`<li class="cancel roxy-chip" data-tone="success" title="${c.reason}">${this.t("{{dosha}} cancelled",{dosha:c.dosha})}</li>`)}</ul>`:rt.nothing} ${ve(this.effectiveLang(),a.frame,this.translator)}</article>`}};Mr.endpoints=Nl,Mr.styles=[u,re,pa,rt.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.card>*{min-width:0}.score-header{align-items:center;gap:var(--roxy-space-md);display:flex}.score-info{flex:1;min-width:0}.table-scroll{min-width:0;overflow-x:auto}.score-bar{align-items:center;gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr) auto;display:grid}.total{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.over,.pct{color:var(--roxy-muted)}.pct{font-size:var(--roxy-text-sm);margin-inline-start:var(--roxy-space-sm)}.verdict-wrap{justify-items:end;gap:var(--roxy-space-xs);text-align:end;display:grid}.verdict{font-weight:var(--roxy-weight-bold)}.recommendation{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.score-ring{flex-shrink:0;block-size:5lh;inline-size:5lh}.score-ring svg{block-size:100%;inline-size:100%;display:block}.ring-track,.ring-fill{fill:none;stroke-width:8px}.ring-track{stroke:var(--roxy-border)}.ring-fill{stroke:var(--roxy-danger);stroke-linecap:round}.ring-fill[data-band=mid]{stroke:var(--roxy-warning)}.ring-fill[data-band=high]{stroke:var(--roxy-success)}table{width:100%}td small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-start:calc(var(--roxy-space-unit) / 2);display:block}td.classification{color:var(--roxy-secondary);white-space:nowrap}:is(th,td).score{text-align:end}td.score{font-weight:var(--roxy-weight-bold)}td.bar-cell{width:22%}@container (width<=32rem){.bar-col{display:none}}@container (width<=26rem){.score-header{flex-direction:column-reverse;align-items:stretch}.score-ring{align-self:center}.score-bar{gap:var(--roxy-space-xs);grid-template-columns:minmax(0,1fr)}.verdict-wrap{text-align:start;justify-items:start}}.mini-bar{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.35lh;overflow:hidden}.mini-bar>span{background:var(--roxy-accent);block-size:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}`],Mr=m([x("roxy-guna-milan")],Mr);function uu(s){return s&&yu[s.toLowerCase()]||1}var Ge=require("lit"),mh=require("lit/directives/unsafe-html.js");var _r=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this)}renderChart(e,t,r){let n=new Set(r?e.personAGates:(e.channels??[]).flatMap(p=>p.personAGates??[])),i=new Set(r?e.personBGates:(e.channels??[]).flatMap(p=>p.personBGates??[])),o=new Map;for(let p of new Set([...n,...i]))o.set(p,{left:n.has(p),right:i.has(p)});let l=new Set((e.centers??[]).filter(p=>p.defined).map(p=>p.id)),c=new Map((e.centers??[]).map(p=>[p.id,p.name])),d=new Map;for(let p of e.channels??[])d.set(p.gateA,p.name),d.set(p.gateB,p.name);let h=new Map;for(let[p,f]of o){let L=[f.left&&"A",f.right&&"B"].filter(Boolean).join(" + ");h.set(p,[`Gate ${p}`,d.get(p),L].filter(Boolean).join(" \xB7 "))}return Ge.html`${(0,mh.unsafeHTML)(R`<svg class="chart bodygraph" part="chart" viewBox=${no} preserveAspectRatio="xMidYMid meet" role="img" aria-label=${t}><title>${t}</title>${io({definedCenters:l,gateSources:o,gateTitles:h,centerNames:c,stateWords:{defined:"Defined",open:"Open"}})}</svg>`.markup)} ${r?Ge.nothing:Ge.html`<p class="note">${t}</p>`}<div class="legend" part="legend"><span><span class="swatch source src-left"></span>Person A</span> <span><span class="swatch source src-right"></span>Person B</span> <span><span class="swatch"></span>Open center</span></div>`}renderData(e){let t=Array.isArray(e.personAGates)&&Array.isArray(e.personBGates),r=t?this.t("Combined bodygraph"):this.t("Defined channels"),n=e.channels??[],i=e.centers??[],o=i.filter(l=>l.defined).length;return Ge.html`<div class="wrap bodygraph" part="card" aria-label="Human Design connection"><header class="head" part="header"><h2>Connection</h2>${typeof e.totalChannels=="number"?Ge.html`<span class="count">${e.totalChannels} channels</span>`:Ge.nothing}</header>${this.chartViewport.renderChartViewport(this.renderChart(e,r,t),r,this.translator)} ${Da([{label:"Channels",value:e.totalChannels?.toString()},{label:"Combined definition",value:e.combinedDefinition?D(String(e.combinedDefinition)):void 0},{label:"Centers defined",value:i.length>0?`${o}/${i.length}`:void 0}])} ${this.hideReadings?Ge.nothing:Ge.html`<p class="lead">A connection chart reads the two charts as one bodygraph. Wherever the two of them together hold both gates of a channel, that channel is defined between them, and the centers it joins are defined in the connection whether or not either person defines them alone.</p>`} ${this.renderDynamics(e.summary)} ${this.renderCenters(i)} ${this.renderChannels(n,i)}</div>`}renderDynamics(e){if(!e)return Ge.nothing;let t=[{label:"Electromagnetic",aside:gi(e.electromagnetic),body:"Each person holds one of the two gates, so the channel completes only when they are together. The classic point of attraction."},{label:"Dominance",aside:gi(e.dominance),body:"One person holds both gates and the other holds neither, so the conditioning runs one way, from the person who carries the channel to the person who does not."},{label:"Compromise",aside:gi(e.compromise),body:"One person holds both gates and the other holds a single hanging gate of the same channel, so the channel is complete for one of them and half open for the other."},{label:"Companionship",aside:gi(e.companionship),body:"Both people independently hold both gates, so neither needs the other to complete it. A shared and familiar frequency rather than an attraction."}];return this.renderInterpretation(t,"hd-connection-dynamic","Dynamics")}renderCenters(e){return e.length===0?Ge.nothing:Ge.html`<section class="block" part="section centers"><h3>Centers</h3>${this.hideReadings?Ge.nothing:Ge.html`<p class="note">Defined is the state of the combined chart. Beside it is who already defines that center in their own chart. A center defined only together is what the connection itself creates: it is there when the two are together and gone when they are apart. The combined definition counts how the defined centers hang together, so Single is one connected piece and a split is more than one.</p>`} ${e.map(t=>{let r=t.definedBy??[],n=r.includes("A"),i=r.includes("B"),o=!!t.defined&&!n&&!i;return Ge.html`<div class="row"><span class="cname">${t.name??D(String(t.id??""))}</span> <span class="roxy-chip ${o?"together":""}" data-tone="${t.defined&&!o?"success":Ge.nothing}">${t.defined?o?"Only together":"Defined":"Open"} </span><span class="who">${fu(!!t.defined,n,i)}</span></div>`})}</section>`}renderChannels(e,t){if(e.length===0)return Ge.nothing;let r=new Map(t.map(i=>[String(i.id??""),i.name??""])),n=i=>r.get(i)||D(i);return Ge.html`<section class="block" part="section channels"><h3>Channels</h3><div class="scroll" part="table" tabindex="0" role="region" aria-label="Connection channels"><table role="table"><caption class="roxy-sr-only">Connection channels: each channel with its gates, the centers it links, its circuit and dynamic, and the gates person A and person B each hold.</caption><thead><tr><th scope="col">Channel</th><th scope="col">Gates</th><th scope="col">Centers</th><th scope="col">Circuit</th><th scope="col">Dynamic</th><th scope="col">Person A holds</th><th scope="col">Person B holds</th></tr></thead><tbody>${e.map(i=>Ge.html`<tr><td>${i.name??""}</td><td class="gates">${i.gateA}-${i.gateB}</td><td>${(i.centers??[]).map(n).join(" to ")}</td><td>${i.circuit??""}</td><td>${i.dynamic?Ge.html`<span class="roxy-chip">${i.dynamic}</span>`:Ge.nothing}</td><td class="held">${hh(i.personAGates)}</td><td class="held">${hh(i.personBGates)}</td></tr>`)}</tbody></table></div></section>`}};_r.endpoints=zl,_r.styles=[u,X,me,fr,Dn,jn,et,Ge.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.note{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-block-end:var(--roxy-space-sm)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.row:last-child{border-block-end:0}.cname{flex:1;min-width:16ch}.roxy-chip.together{color:var(--roxy-accent-ink);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.who{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}table{width:100%}th,td{white-space:nowrap}tbody tr:last-child td{border-block-end:0}.gates{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.held{font-variant-numeric:tabular-nums}.scroll{min-width:0;overflow-x:auto}.wrap{--src-left:var(--roxy-info-fg);--src-right:var(--roxy-warning-fg);--src-ink:var(--roxy-bg)}`],_r=m([x("roxy-hd-connection")],_r);function gi(s){if(typeof s=="number")return s===0?"None":s===1?"1 channel":`${s} channels`}function hh(s){let a=s??[];return a.length>0?a.join(", "):"Neither"}function fu(s,a,e){return a&&e?"Defined in both charts":a?"Defined by A":e?"Defined by B":s?"Defined by neither alone, only by the connection":"Open in both charts"}var Le=require("lit");var Nr=require("lit");var Mo=360,xu=470,_o=8,uh=Mo-_o*2,ui=48,en=15,Po=7,gh=16,yi=[{id:"throat",label:"Throat",y:0},{id:"g",label:"G",y:211},{id:"sacral",label:"Sacral",y:422}],fh=`0 0 ${Mo} ${xu}`;function bu(s,a){return _o+uh*(s*2+1)/(a*2)}function xh(s){return Js[s.gateA]==="throat"||Js[s.gateB]==="throat"}function vu(s){return(xh(s)?Js[s.gateA]==="throat":Js[s.gateA]==="g")?s.gateA:s.gateB}function Lu(){return yi.map(s=>Nr.svg`<g>
|
|
83
|
+
<rect class="pn-bar" x=${_o} y=${s.y} width=${uh} height=${ui} rx="10" />
|
|
84
|
+
<text class="pn-bar-label" x=${Mo/2} y=${s.y+ui/2} text-anchor="middle" dominant-baseline="central">${s.label}</text>
|
|
85
|
+
</g>`)}function $u(s,a,e,t){return e.map((r,n)=>Nr.svg`<g>
|
|
86
|
+
<circle class="pn-badge" cx=${s+(n-(e.length-1)/2)*gh} cy=${a} r=${Po} />
|
|
87
|
+
<text class="pn-badge-text" x=${s+(n-(e.length-1)/2)*gh} y=${a} text-anchor="middle" dominant-baseline="central">${t(r)}</text>
|
|
88
|
+
</g>`)}function yh(s,a,e,t,r,n){let i=t.length>0;return Nr.svg`<g>
|
|
89
|
+
<circle class="pn-gate-dot ${i?"on":""}" cx=${s} cy=${a} r=${en} />
|
|
90
|
+
<text class="pn-gate ${i?"on":""}" x=${s} y=${a} text-anchor="middle" dominant-baseline="central">${e}</text>
|
|
91
|
+
${$u(s,a+n,t,r)}
|
|
92
|
+
</g>`}function bh(s){let a=[];for(let e of[true,false]){let t=s.rungs.filter(c=>xh(c)===e),r=e?ui:yi[1].y+ui,n=e?yi[1].y:yi[2].y,i=r+26,o=n-26,l=(i+o)/2;t.forEach((c,d)=>{let h=bu(d,t.length),p=vu(c),f=p===c.gateA?c.gateB:c.gateA,L=`pn-rung ${c.defined?"on":""} ${c.isCore?"core":""}`;a.push(Nr.svg`<g>
|
|
93
|
+
<line class=${L} x1=${h} y1=${i+en} x2=${h} y2=${l-13} />
|
|
94
|
+
<line class=${L} x1=${h} y1=${l+13} x2=${h} y2=${o-en} />
|
|
95
|
+
<text class="pn-name ${c.defined?"on":""}" x=${h} y=${l} text-anchor="middle" dominant-baseline="central">${c.name}</text>
|
|
96
|
+
${yh(h,i,p,s.holders.get(p)??[],s.letterFor,en+Po+7)}
|
|
97
|
+
${yh(h,o,f,s.holders.get(f)??[],s.letterFor,-(en+Po+7))}
|
|
98
|
+
</g>`)})}return Nr.svg`${Lu()}${a.length>0?a:Nr.nothing}`}var zr=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this)}renderChart(e){let t=(e.channels??[]).filter(n=>n.gateA!=null&&n.gateB!=null).map(n=>({gateA:n.gateA,gateB:n.gateB,name:n.name??"",defined:n.defined===true,isCore:n.isCore===true}));if(t.length===0)return Le.nothing;let r=new Map((e.gates??[]).filter(n=>n.gate!=null).map(n=>[n.gate,n.heldBy??[]]));return Le.html`<svg class="chart" part="chart" viewBox="${fh}" preserveAspectRatio="xMidYMid meet" role="img" aria-label="Penta ladder: the Throat, G and Sacral with the six penta channels between them, each marked defined or open and lettered with the members holding its gates"><title>Penta</title>${bh({rungs:t,holders:r,letterFor:vh})}</svg>`}renderData(e){let t=e.channels??[],r=e.gates??[],n=e.summary,i=n?.gapGates??[],o=t.some(l=>l.isCore);return Le.html`<div class="wrap" part="card" aria-label="Human Design penta"><header class="head" part="header"><h2>Penta</h2>${typeof e.memberCount=="number"?Le.html`<span class="count">${e.memberCount} members</span>`:Le.nothing}</header>${this.chartViewport.renderChartViewport(this.renderChart(e),"Penta",this.translator)} ${Da([{label:"Members",value:e.memberCount?.toString()},{label:"Defined channels",value:typeof n?.definedChannels=="number"&&t.length>0?`${n.definedChannels} of ${t.length}`:void 0},{label:"Filled gates",value:typeof n?.filledGates=="number"&&r.length>0?`${n.filledGates} of ${r.length}`:void 0},{label:"Core",value:typeof n?.coreDefined=="boolean"?n.coreDefined?"Defined":"Open":void 0},{label:"Gap gates",value:i.length>0?i.join(", "):void 0}])} ${this.hideReadings?Le.nothing:Le.html`<p class="lead">A penta is the field three to five people form when they work as a group. It is read from the twelve penta gates the members bring between them: a channel with both of its gates held somewhere in the group is a defined Strength, and a gate no member holds is a gap the group has to compensate for.</p>`} ${this.renderGroup("Upper (direction)",t.filter(l=>l.position==="upper"),"Upper channels run from the G Center to the Throat. They carry the leadership of the group and how it presents itself.")} ${this.renderGroup("Lower (execution)",t.filter(l=>l.position==="lower"),"Lower channels run from the G Center to the Sacral. They carry the managed, generative, resource work.")} ${this.renderGroup("Channels",t.filter(l=>l.position!=="upper"&&l.position!=="lower"))} ${o&&!this.hideReadings?Le.html`<p class="footnote">Core is the 2/14 Channel of the Beat, the material core of the penta: gate 2 sets the direction for resources, gate 14 is the resources themselves.</p>`:Le.nothing} ${this.renderGates(r)} ${t.length>0||r.length>0?Le.html`<p class="footnote" part="legend">Members are lettered in the order they were sent, so A is the first member of the group.</p>`:Le.nothing}</div>`}renderGroup(e,t,r){return t.length===0?Le.nothing:Le.html`<div class="section" part="section channels"><h3>${e}</h3>${r&&!this.hideReadings?Le.html`<p class="note">${r}</p>`:Le.nothing} ${t.map(n=>Le.html`<div class="row"><span class="gates">${n.gateA}-${n.gateB}</span> <span class="cname">${n.name??""} ${n.circuit?Le.html`<span class="circuit">${n.circuit} circuit</span>`:Le.nothing} </span><span class="roxy-chip" data-tone="${n.defined?"success":Le.nothing}">${n.defined?"Defined":"Open"}</span> ${n.isCore?Le.html`<span class="roxy-chip core">Core</span>`:Le.nothing} <span class="held">Gate ${n.gateA} held by ${No(n.gateAHeldBy)}. Gate ${n.gateB} held by ${No(n.gateBHeldBy)}.</span></div>`)}</div>`}renderGates(e){if(e.length===0)return Le.nothing;let t=e.filter(r=>r.filled).length;return Le.html`<div class="section" part="section gates"><h3>Gates (${t} of ${e.length} filled)</h3>${this.hideReadings?Le.nothing:Le.html`<p class="note">The role each gate brings to the group, and who carries it. A gap is a role no member holds, so the group compensates for it.</p>`} ${e.map(r=>Le.html`<div class="row"><span class="gate-id">${r.gate}</span> <span class="cname">${r.gateName??""}</span> ${r.filled?Le.html`<span class="who">Held by ${No(r.heldBy)}</span>`:Le.html`<span class="roxy-chip" data-tone="danger">Gap</span>`}</div>`)}</div>`}};zr.endpoints=Ol,zr.styles=[u,et,fr,Le.css`.chart{width:100%;max-width:var(--roxy-chart-max-width,22rem);height:auto;margin:0 auto;display:block}.pn-bar{fill:color-mix(in srgb, var(--roxy-accent) 12%, transparent);stroke:var(--roxy-accent-ink);stroke-width:1.5px}.pn-bar-label{fill:var(--roxy-fg);font-size:calc(var(--roxy-text-base) * .9375);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.pn-rung{stroke:var(--roxy-border);stroke-width:6px;stroke-dasharray:6 6}.pn-rung.on{stroke:var(--roxy-accent-ink);stroke-dasharray:none}.pn-rung.on.core{stroke-width:9px}.pn-name{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .75);font-family:var(--roxy-font-sans)}.pn-name.on{fill:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.pn-gate-dot{fill:var(--_mask);stroke:var(--roxy-border);stroke-width:1.5px;stroke-dasharray:4 4}.pn-gate-dot.on{stroke:var(--roxy-accent-ink);stroke-dasharray:none}.pn-gate{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .8125);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.pn-gate.on{fill:var(--roxy-fg)}.pn-badge{fill:var(--roxy-accent-ink)}.pn-badge-text{fill:var(--roxy-bg);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold);font-family:var(--roxy-font-sans)}.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.section{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md)}.note{margin-block-start:var(--roxy-space-xs)}.note,.held,.who,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.row:last-child{border-block-end:0}.gates,.gate-id{font-variant-numeric:tabular-nums;min-width:5ch;font-weight:var(--roxy-weight-bold);color:var(--roxy-accent-ink)}.cname{flex:1;min-width:16ch}.circuit{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}.held{flex-basis:100%}.roxy-chip.core{color:var(--roxy-accent-ink);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}`],zr=m([x("roxy-hd-penta")],zr);var wu="ABCDE",vh=s=>wu[s]??String(s+1);function No(s){let a=(s??[]).map(vh);return a.length>0?a.join(", "):"nobody"}var _t=require("lit");var Or=class extends g{renderData(a){return ku(a)?this.renderType(a):this.renderProfile(a)}renderType(a){return _t.html`<div class="wrap" part="card"><header class="head" part="header"><h2>${this.t("Type")}</h2>${a.type||a.profile?_t.html`<div class="type-line">${[y(a,"type"),a.profile?this.t("Profile {{profile}}",{profile:a.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:_t.nothing}</header>${Da([{label:this.t("Type"),value:y(a,"type")},{label:this.t("Strategy"),value:y(a,"strategy")},{label:this.t("Authority"),value:y(a,"authority")},{label:this.t("Profile"),value:a.profile}])} ${a.typeDescription&&!this.hideReadings?_t.html`<p class="lead">${a.typeDescription}</p>`:_t.nothing} ${Kn(a.signature?y(a,"signature"):void 0,a.notSelf?y(a,"notSelf"):void 0,this.translator)} ${this.renderInterpretation([{label:this.t("Strategy"),aside:y(a,"strategy"),body:a.strategyDescription},{label:this.t("Authority"),aside:y(a,"authority"),body:a.authorityDescription},{label:this.t("Aura"),body:a.aura}],"hd-type-reading")}</div>`}renderProfile(a){return _t.html`<div class="wrap" part="card"><header class="head" part="header"><h2>${this.t("Profile")}</h2>${a.profile?_t.html`<div class="type-line">${a.profile}</div>`:_t.nothing}</header>${Da([{label:this.t("Profile"),value:a.profile},{label:this.t("Personality line"),value:a.personalityLine?.toString()},{label:this.t("Design line"),value:a.designLine?.toString()}])} ${this.hideReadings?_t.nothing:_t.html`<section class="block" part="section lines"><h3>${this.t("Lines")}</h3>${Vn({personality:a.personalityKeynote,personalityLine:a.personalityLine,design:a.designKeynote,designLine:a.designLine},this.translator)}</section>`}</div>`}};Or.endpoints=Gl,Or.styles=[u,X,me,fr,_t.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.type-line{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`],Or=m([x("roxy-hd-type-card")],Or);function ku(s){return typeof s.type=="string"}var be=require("lit");var Gr=class extends g{renderData(a){let e=[...a.arrows??[]].sort((t,r)=>Lh(t.position)-Lh(r.position));return be.html`<div class="wrap" part="card" aria-label="${this.t("Human Design variables")}"><h2 part="header">${this.t("Variables")}</h2><div class="grid" part="details arrows">${e.map(t=>this.renderArrow(t))}</div>${a.confident===false?be.html`<p class="note" role="note">${typeof a.confidenceMarginDeg=="number"?this.t("Low confidence: a birth time near a color or tone boundary (within {{margin}}\xB0). Verify the exact birth time.",{margin:a.confidenceMarginDeg}):this.t("Low confidence: a birth time near a color or tone boundary. Verify the exact birth time.")}</p>`:be.nothing} ${this.renderReading(e,a.baseDescription)}</div>`}renderArrow(a){let e=a.direction==="left"?"\u2190":"\u2192",t=y(a,"baseName");return be.html`<div class="arrow"><div class="arrow-head"><span class="glyph ${a.activation?.side??""}" aria-hidden="true">${e}</span> <span class="name">${y(a,"name")}</span></div>${a.layer?be.html`<span class="layer">${y(a,"layer")}</span>`:be.nothing} <span class="labels">${[y(a,"directionLabel"),y(a,"colorLabel")].filter(Boolean).join(" \xB7 ")} </span>${typeof a.color=="number"?be.html`<span class="ctb">${this.t("Color {{color}} \xB7 Tone {{tone}} \xB7 Base {{base}}",{color:a.color,tone:a.tone??"",base:a.base??""})}${t?`, ${t}`:""}</span>`:be.nothing} ${a.activation?.planet?be.html`<span class="ctb">${[y(a.activation,"planet"),oo(a.activation.side,this.translator)].filter(Boolean).join(" \xB7 ")}</span>`:be.nothing} ${a.confident===false?be.html`<span class="note" role="note">${this.t("Knife-edge: could flip with a more precise birth time.")}</span>`:be.nothing}</div>`}renderReading(a,e){let t=a.filter(i=>i.description||i.colorMeaning);if(t.length===0||this.hideReadings)return be.nothing;let r=new Map;for(let i of t){let o=i.layer??"",l=r.get(o);l?l.push(i):r.set(o,[i])}let n=0;return be.html`<section class="block" part="section readings"><h3>${this.t("Reading")}</h3>${[...r].map(([i,o])=>be.html`<div class="group">${i?be.html`<p class="group-head">${y(o[0],"layer")}</p>`:be.nothing} ${o[0]?.layerDescription?be.html`<p class="group-note">${o[0].layerDescription}</p>`:be.nothing} ${o.map(l=>this.renderArrowReading(l,n++===0))}</div>`)} ${e?be.html`<p class="footnote">${this.t("Base")}. ${e}</p>`:be.nothing}</section>`}renderArrowReading(a,e){let t=a.cognition,r=t?y(t,"label"):"",n=[{label:this.t("Color"),body:a.colorMeaning},{label:this.t("Tone"),body:a.toneMeaning},{label:this.t("Direction"),body:a.directionMeaning},{label:r?`${this.t("Cognition")} \xB7 ${r}`:this.t("Cognition"),body:t?.description}].filter(i=>!!i.body);return be.html`<details class="interp-card" part="reading" name="hd-variable" ?open="${e}"><summary><span class="interp-lead">${y(a,"name")}</span> ${he()} ${a.position?be.html`<span class="interp-aside"><small>${y(a,"position")}</small></span>`:be.nothing}</summary><div class="interp-body">${a.description?be.html`<p>${a.description}</p>`:be.nothing} ${n.length>0?be.html`<dl class="facets">${n.map(i=>be.html`<dt>${i.label}</dt><dd>${i.body}</dd>`)}</dl>`:be.nothing}</div></details>`}};Gr.endpoints=Il,Gr.styles=[u,X,me,be.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.grid{gap:0 var(--roxy-space-lg);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.arrow{align-content:start;gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.arrow-head{align-items:center;gap:var(--roxy-space-sm);display:flex}.glyph{font-size:var(--roxy-text-xl);color:var(--roxy-accent-ink);line-height:1}.glyph.design{color:var(--roxy-danger-fg)}.glyph.personality{color:var(--roxy-fg)}.name{font-weight:var(--roxy-weight-bold)}.layer,.ctb{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.ctb{font-variant-numeric:tabular-nums}.labels{font-size:var(--roxy-text-sm)}.note{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs)}@container (width<=28rem){.grid{grid-template-columns:minmax(0,1fr)}}.group+.group{margin-block-start:var(--roxy-space-md)}.group-head{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-note,.footnote{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.group-note{margin-block-end:var(--roxy-space-sm)}.facets{gap:var(--roxy-space-xs);margin:0;display:grid}.facets dd{margin:0}`],Gr=m([x("roxy-hd-variables")],Gr);function Lh(s){switch(s){case"Top left":return 0;case"Top right":return 1;case"Bottom left":return 2;case"Bottom right":return 3;default:return 99}}var Rt=require("lit");var Su={udaya:"Rose",asta:"Set"},Ru={udaya:"rises",asta:"sets"},Ir=class extends g{renderData(a){let e=a.grahas??[];return e.length?Rt.html`<div class="wrap" part="card" aria-label="${this.t("Heliacal visibility")}"><header class="head" part="header"><h2>${this.t("Heliacal rising and setting")}</h2><p class="sub">${this.t("Whether each graha stands far enough from the Sun to be seen, for {{date}}. The Sun and the nodes never appear here: they have no heliacal event.",{date:a.date})}</p></header><div part="table">${e.map(t=>this.renderGraha(t))}</div></div>`:this.renderEmpty()}renderGraha(a){let e=S(a.graha)??"";return Rt.html`<article class="row"><div class="row-top"><span class="graha">${e?Rt.html`<span class="glyph roxy-glyph">${e}</span>`:Rt.nothing}${a.graha} </span><span class="state roxy-chip ${a.visible?"visible":"invisible"}" data-tone="${a.visible?Rt.nothing:"warning"}">${a.visible?this.t("Visible"):this.t("Invisible")} </span>${a.retrograde?Rt.html`<span class="retro" title="${this.t("retrograde")}">R</span>`:Rt.nothing}</div><p class="window" part="window">${this.windowLine(a)}</p><p class="meta" part="details">${this.metaLine(a)}</p></article>`}windowLine(a){let e=a.nextEvent,t=a.lastEvent;if(e){let r={event:this.t(Ru[e.type]),where:e.horizon==="east"?this.t("in the east"):this.t("in the west"),when:fe(this.effectiveLang(),e.datetime)};return Rt.html`${a.visible?this.t("Visible until it {{event}} {{where}} on {{when}}",r):this.t("Invisible until it {{event}} {{where}} on {{when}}",r)}`}return t?Rt.html`${this.t("{{event}} {{where}} on {{when}}, with no further event inside the search window",{event:this.t(Su[t.type]),where:t.horizon==="east"?this.t("in the east"):this.t("in the west"),when:fe(this.effectiveLang(),t.datetime)})}`:Rt.html`${this.t("No rising or setting inside the search window, which is normal for a graha far from the Sun")}`}metaLine(a){let e=a.horizon==="east"?this.t("a morning graha, read before sunrise"):this.t("an evening graha, read after sunset"),t=a.nextEvent??a.lastEvent,r=t&&t.kalamsa!==a.kalamsa,n={degrees:b(this.effectiveLang(),a.timeDegrees,2),limit:b(this.effectiveLang(),a.kalamsa,0),shifted:r?b(this.effectiveLang(),t.kalamsa,0):""};return Rt.html`${r?this.t("{{degrees}}\xB0 of time from the Sun against a limit of {{limit}}\xB0, becoming {{shifted}}\xB0 at that event",n):this.t("{{degrees}}\xB0 of time from the Sun against a limit of {{limit}}\xB0",n)} · ${e}`}};Ir.endpoints=Fl,Ir.styles=[u,Rt.css`.wrap{overflow:hidden}.head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);display:grid}h2,p{margin:0}.sub,.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.row{gap:var(--roxy-space-xs);padding:var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.window{font-size:var(--roxy-text-sm)}`],Ir=m([x("roxy-heliacal-table")],Ir);var oe=require("lit");var Fr=class extends g{resolveHexagram(){let a=this.data;if(!a)return null;if("hexagram"in a&&a.hexagram){if("lines"in a){let n=a,i=n.hexagram;return{hex:i,lines:n.lines,date:n.date,changingLinePositions:n.changingLinePositions,changingLines:n.changingLines??i.changingLines,resultingHexagram:n.resultingHexagram}}let t=a,r=t.hexagram;return{hex:r,changingLines:r.changingLines,dailyMessage:t.dailyMessage,date:t.date}}let e=a;return{hex:e,changingLines:e.changingLines}}renderData(){let a=this.resolveHexagram();if(!a)return this.renderEmpty();let{hex:e,lines:t,changingLinePositions:r,changingLines:n,dailyMessage:i,date:o,resultingHexagram:l}=a;return oe.html`<article class="card" part="card" aria-label="${this.t("I Ching hexagram")}">${this.renderHexagram("hexagram",e,t,r,n,i,o)} ${l?oe.html`<details class="result" part="section resulting-hexagram"><summary>${this.t("Becomes hexagram {{number}} {{name}}.",{number:l.number,name:l.english??l.chinese??""})}${he()}</summary><div class="result-chart">${this.renderHexagram("result",l)}</div></details>`:oe.nothing}</article>`}renderHexagram(a,e,t,r,n,i,o){let l=t??this.derivedLines(e),c=Cd(e.number),d=new Set(r??[]),h=!this.hideReadings;return oe.html`<div class="glyphs" part="chart">${c?oe.html`<div class="symbol roxy-glyph">${c}</div>`:oe.nothing} ${l.length>0?oe.html`<div class="lines" aria-hidden="true">${l.slice().reverse().map((p,f)=>{let L=l.length-1-f+1,$=d.has(L),k=p===6||p===8;return oe.html`<div class="line ${`${k?"broken":"solid"}${$?" changing":""}`}">${k?oe.html`<span class="seg"></span><span class="seg"></span>`:oe.html`<span class="seg"></span>`}</div>`})}</div>`:oe.nothing}</div><div part="header"><h2>${[e.number!=null?`${e.number}.`:"",e.english??e.chinese??this.t("I Ching hexagram")].filter(Boolean).join(" ")}</h2>${o?oe.html`<time class="daily-date" part="details" datetime="${o}">${M(this.effectiveLang(),o)}</time>`:oe.nothing}<p class="subtitle">${e.chinese?oe.html`${e.chinese}`:oe.nothing} ${e.pinyin?oe.html`· ${e.pinyin}`:oe.nothing}</p><div class="trigrams roxy-label" part="details">${e.upperTrigram?oe.html`<div>${this.t("Upper")} <span class="tri-glyph roxy-glyph">${or(e.upperTrigram)??""}</span>${e.upperTrigram}</div>`:oe.nothing} ${e.lowerTrigram?oe.html`<div>${this.t("Lower")} <span class="tri-glyph roxy-glyph">${or(e.lowerTrigram)??""}</span>${e.lowerTrigram}</div>`:oe.nothing}</div>${e.judgment&&h?oe.html`<p class="judgment">${e.judgment}</p>`:oe.nothing} ${e.image&&h?oe.html`<p class="image">${e.image}</p>`:oe.nothing} ${i&&h?oe.html`<p class="message">${i}</p>`:oe.nothing} ${e.interpretation?.general&&h?oe.html`<p>${e.interpretation.general}</p>`:oe.nothing} ${d.size>0?oe.html`<div class="changes" part="section changing-lines">${this.t("Changing lines: {{lines}}.",{lines:Array.from(d).sort((p,f)=>p-f).join(", ")})}</div>`:oe.nothing} ${this.renderTopics(e,a)} ${this.renderLines(n??e.changingLines,d,`${a}-lines`)}</div>`}renderTopics(a,e){let t=a.interpretation;return t?this.renderInterpretation([{label:this.t("Love"),body:t.love??""},{label:this.t("Career"),body:t.career??""},{label:this.t("Decision"),body:t.decision??""},{label:this.t("Advice"),body:t.advice??""}].filter(r=>r.body),`${e}-topics`,"Readings"):oe.nothing}renderLines(a,e,t){let r=a??[];if(r.length===0)return oe.nothing;let n=e.size>0,i=n?r.filter(l=>e.has(l.position)):r;if(i.length===0)return oe.nothing;let o=i.map(l=>({label:`Line ${l.position}`,body:l.text??"",extra:l.meaning?oe.html`<p class="line-meaning">${l.meaning}</p>`:oe.nothing}));return this.renderInterpretation(o,t,n?"Changing lines":"Lines")}derivedLines(a){let e=a.binary??"";return/^[01]{6}$/.test(e)?Array.from(e,t=>t==="1"?7:8):[]}};Fr.endpoints=Bl,Fr.styles=[u,X,me,oe.css`.card{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,4lh) minmax(0,1fr);display:grid}.result-chart{gap:var(--roxy-space-lg);grid-template-columns:minmax(0,4lh) minmax(0,1fr);padding-block-start:var(--roxy-space-md);display:grid}.result{border-block-start:1px solid var(--roxy-border);grid-column:1/-1;padding-block-start:var(--roxy-space-md)}.result>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);display:flex}@container (width<=480px){.card,.result-chart{grid-template-columns:minmax(0,1fr)}}h2,p{margin:0}.glyphs{align-content:start;align-self:start;justify-items:center;gap:var(--roxy-space-md);display:grid}.symbol{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2);line-height:1}.lines{gap:calc(var(--roxy-space-unit) * 1.5);inline-size:2lh;display:grid}.line{gap:var(--roxy-space-xs);grid-template-columns:1fr 1fr;display:grid}.seg{block-size:calc(var(--roxy-line-thick) * 3);background:var(--roxy-fg);display:block}.line.solid .seg{grid-column:1/-1}.line.changing .seg{background:var(--roxy-accent)}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm)}.daily-date{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm);display:block}.trigrams{gap:var(--roxy-space-md);flex-wrap:wrap;margin-block-end:var(--roxy-space-sm);display:flex}.tri-glyph{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);vertical-align:middle;margin-inline-end:var(--roxy-space-xs)}.judgment,.image,.message{font-size:var(--roxy-text-sm);margin-block-end:var(--roxy-space-sm)}.judgment:before{content:"Judgment. ";color:var(--roxy-secondary);font-weight:var(--roxy-weight-bold)}.image:before{content:"Image. ";color:var(--roxy-secondary);font-weight:var(--roxy-weight-bold)}.line-meaning{border-inline-start:var(--roxy-line-thick) solid var(--roxy-border);color:var(--roxy-muted);padding-inline-start:var(--roxy-space-sm)}.changes{border-block-start:1px solid var(--roxy-border);color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-md);padding-block-start:var(--roxy-space-md)}`],Fr=m([x("roxy-hexagram")],Fr);var Jt=require("lit");var Br=class extends g{renderData(a){let e=a.dayHoras??[],t=a.nightHoras??[];return e.length===0&&t.length===0?this.renderEmpty():Jt.html`<div class="wrap" part="card" aria-label="${this.t("Hora periods")}"><div class="head" part="header"><h2>${this.t("Hora")}</h2>${a.date?Jt.html`<p class="roxy-label">${M(this.effectiveLang(),a.date)}</p>`:Jt.nothing}</div><div class="cols" part="table">${this.renderColumn(this.t("Daytime"),e)} ${this.renderColumn(this.t("Night"),t)}</div></div>`}renderColumn(a,e){return e.length===0?Jt.nothing:Jt.html`<div class="col"><h3 class="section-label">${a}</h3>${e.map(t=>Jt.html`<div class="row"><span class="glyph roxy-glyph" aria-hidden="true">${S(t.planet)??"\xB7"}</span> <span class="planet">${t.planet}</span> <span class="time">${la(this.effectiveLang(),t)}</span> ${typeof t.number=="number"?Jt.html`<span class="num">${t.number}</span>`:Jt.nothing}</div>`)}</div>`}};Br.endpoints=Hl,Br.styles=[u,Jt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.cols{gap:var(--roxy-space-md);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.section-label{margin-block-end:var(--roxy-space-xs)}.row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-xs);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;display:flex}.row:last-child{border-block-end:0}.glyph{inline-size:2ch;color:var(--roxy-accent-ink);font-size:var(--roxy-text-base);text-align:center;line-height:1}.planet{flex:1}.time{color:var(--roxy-muted);white-space:nowrap}.num{inline-size:3ch;color:var(--roxy-muted);font-size:var(--roxy-text-xs);text-align:end}@container (width<=30rem){.cols{grid-template-columns:minmax(0,1fr)}}`],Br=m([x("roxy-hora-table")],Br);var w=require("lit"),zo=require("lit/decorators.js");var Cu={daily:"Daily",weekly:"Weekly",monthly:"Monthly",yearly:"Yearly"},Tu={aspect:"Aspect","sign-ingress":"Sign ingress","retrograde-station":"Retrograde station","lunar-phase":"Lunar phase",eclipse:"Eclipse","solar-season":"Solar season"},Eu=[["love","Love"],["career","Career"],["health","Health"],["finance","Finance"],["advice","Advice"]],Du=[["love","Love"],["career","Career"],["health","Health"],["finance","Finance"]],xa=class extends g{constructor(){super(...arguments);this.period="daily";this.layout="auto"}renderData(e){let t=e.sign??"",r=J(t)??"",n="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,i=this.effectiveLang(),o="date"in e&&e.date&&M(i,e.date)||"week"in e&&e.week&&M(i,e.week)||"month"in e&&e.month&&rr(i,e.month,"month")||("year"in e&&e.year?String(e.year):"")||"";return w.html`<article class="card" part="card" aria-labelledby="horoscope-title"><header class="head" part="header"><span class="glyph roxy-glyph" aria-hidden="true">${r}</span><div><h2 class="title" id="horoscope-title">${t} ${this.t(Cu[this.period])}</h2>${o?w.html`<p class="date roxy-label">${o}</p>`:w.nothing}</div>${n!==null?w.html`<span class="energy" part="details" aria-label="${this.t("Energy {{value}} of 10",{value:n})}">${this.t("Energy {{value}}/10",{value:n})} <span class="energy-bar"><span style="width:${n/10*100}%"></span></span></span>`:w.nothing}</header>${this.renderReading(e)} ${this.renderSky(e)} ${this.renderEvents(e.events)} ${this.renderYear(e)} ${this.renderMonth(e)} ${(()=>{let l="luckyNumber"in e&&e.luckyNumber!==void 0?e.luckyNumber:void 0,c="luckyColor"in e&&e.luckyColor?e.luckyColor:"",d="luckyNumbers"in e&&e.luckyNumbers?e.luckyNumbers:[],h="luckyDays"in e&&e.luckyDays?e.luckyDays:[],p=e.compatibleSigns??[];return l===void 0&&!c&&d.length===0&&h.length===0&&p.length===0?w.nothing:w.html`<div class="lucky" part="details">${l!==void 0?w.html`<span>${this.t("Lucky number")} <strong>${l}</strong></span>`:w.nothing} ${c?w.html`<span>${this.t("Lucky color")} <strong>${c}</strong></span>`:w.nothing} ${d.length?w.html`<span>${this.t("Lucky numbers")} <strong>${d.join(", ")}</strong></span>`:w.nothing} ${h.length?w.html`<span>${this.t("Lucky days")} <strong>${h.join(", ")}</strong></span>`:w.nothing} ${p.length?w.html`<span class="compat-wrap">${this.t("Best with")}<ul class="compat roxy-chips">${p.map(f=>w.html`<li>${f}</li>`)}</ul></span>`:w.nothing}</div>`})()}</article>`}renderReading(e){if(this.hideReadings)return w.nothing;if(this.layout==="column"||this.layout==="auto"&&!!e.column)return e.column?this.renderColumn(e.column):w.nothing;let r=this.paragraphs(e.overview);return w.html`${r.length?w.html`<div class="overview" part="section overview">${r}</div>`:w.nothing}<div class="sections" part="section outlook">${Eu.map(([n,i])=>{let o=this.paragraphs(e[n]);return o.length?w.html`<div class="section"><h3>${this.t(i)}</h3>${o}</div>`:w.nothing})}</div>`}renderColumn(e){let t=this.paragraphs(e);return t.length===0?w.nothing:w.html`<div class="column" part="section column">${t}</div>`}paragraphs(e){return(e??"").split(/\n\s*\n/).map(t=>t.trim()).filter(Boolean).map(t=>w.html`<p>${t}</p>`)}renderEvents(e){if(!e?.length)return w.nothing;let t=this.effectiveLang();return w.html`<section part="section events"><h3>${this.t("Events")}</h3><ul class="rows" aria-label="${this.t("Events")}">${e.map(r=>this.renderRow(w.html`<time class="row-when" datetime="${r.at}">${rr(t,r.at,"time")}</time>`,this.renderEventBodies(r),w.html`<span class="kind">${this.t(Tu[r.type])}</span> <span>${this.t("House")} ${r.house}</span> ${r.sign?w.html`<span>${this.glyphName(J(r.sign),U(r.sign))}</span>`:w.nothing} ${r.through?w.html`<span>${this.t("through {{date}}",{date:M(t,r.through)})}</span>`:w.nothing}`,{when:"element"}))}</ul></section>`}renderEventBodies(e){let t=(e.bodies??[]).map(r=>this.glyphName(S(r),r));return t.length===2&&e.aspect?w.html`${t[0]} <span class="${`${Qe({type:e.aspect})} roxy-glyph`}">${Ns(e.aspect)??e.aspect}</span> ${t[1]}`:w.html`${t}`}renderYear(e){if(!("themes"in e))return w.nothing;let t=this.effectiveLang();return w.html`${e.themes.length?w.html`<section part="section themes"><h3>${this.t("Themes")}</h3><ul class="rows">${e.themes.map(r=>this.renderRow(Et(t,r.from,r.to),w.html`${this.glyphName(S(r.body),r.body)} ${this.glyphName(J(r.sign),U(r.sign))}`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${e.keyPeriods.length?w.html`<section part="section key-periods"><h3>${this.t("Key periods")}</h3><ul class="rows">${e.keyPeriods.map(r=>this.renderRow(Et(t,r.from,r.to),this.glyphName(S(r.body),r.body),w.html`<span>${this.t("House")} ${r.house}</span><span>${r.focus}</span>`))}</ul></section>`:w.nothing} ${e.eclipses.length?w.html`<section part="section eclipses"><h3>${this.t("Eclipses")}</h3><ul class="rows">${e.eclipses.map(r=>this.renderRow(M(t,r.date),w.html`<span class="name">${r.kind}</span>`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${e.retrogrades.length?w.html`<section part="section retrogrades"><h3>${this.t("Retrogrades")}</h3><ul class="rows">${e.retrogrades.map(r=>this.renderRow(M(t,r.date),w.html`${this.glyphName(S(r.body),r.body)} <span>${r.direction}</span>`,w.html`<span>${this.t("House")} ${r.house}</span><span>${r.theme}</span>`))}</ul></section>`:w.nothing} ${this.renderBestPeriods(e.bestPeriods)}`}renderBestPeriods(e){if(!e)return w.nothing;let t=this.effectiveLang(),r=Du.filter(([n])=>e[n]);return r.length===0?w.nothing:w.html`<section part="section best-periods"><h3>${this.t("Best months")}</h3><div class="tiles" part="details">${r.map(([n,i])=>{let o=e[n];return o?w.html`<div class="tile"><span class="roxy-label">${this.t(i)}</span> <span class="tile-value">${rr(t,o.from,"month")}</span> <span class="tile-note">${this.t("{{count}} harmonious aspects",{count:o.count})}</span></div>`:w.nothing})}</div></section>`}renderRow(e,t,r,n){return w.html`<li class="row" part="label-track">${n?.when==="element"?e:w.html`<span class="row-when">${e}</span>`} <span class="row-what">${t}</span> <span class="row-meta">${r}</span></li>`}glyphName(e,t){return w.html`<span class="roxy-glyph" aria-hidden="true">${e??""}</span> <span class="name">${t}</span>`}renderSky(e){let t="moonSign"in e?e.moonSign:"",r="moonPhase"in e?e.moonPhase:"",n=("activeTransits"in e?e.activeTransits:[])??[];if(!t&&!r&&n.length===0)return w.nothing;let i=J(t)??"";return w.html`<div class="sky" part="section sky">${t||r?w.html`<div class="moon-line">${t?w.html`<span><span class="roxy-label">${this.t("Moon")}</span> <span class="roxy-glyph" aria-hidden="true">${i}</span> <b>${t}</b></span>`:w.nothing} ${r?w.html`<span><span class="roxy-label">${this.t("Phase")}</span> <b>${r}</b></span>`:w.nothing}</div>`:w.nothing} ${n.length?w.html`<ul class="transits" aria-label="${this.t("Active transits")}">${n.map(o=>w.html`<li>${o}</li>`)}</ul>`:w.nothing}</div>`}renderMonth(e){let t=("weekByWeek"in e?e.weekByWeek:[])??[],r=("keyDates"in e?e.keyDates:[])??[];return t.length===0&&r.length===0?w.nothing:w.html`${t.length&&!this.hideReadings?w.html`<section part="section week-by-week"><h3>${this.t("Week by week")}</h3><div class="weeks">${t.map(n=>w.html`<div class="week"><span class="roxy-label">${this.t("Week {{n}}",{n:n.week})}</span><div><div class="week-focus">${n.focus}</div>${n.advice?w.html`<p class="week-advice">${n.advice}</p>`:w.nothing}</div></div>`)}</div></section>`:w.nothing} ${r.length?w.html`<section part="section key-dates"><h3>${this.t("Key dates")}</h3><dl class="dates" part="label-track">${r.map(n=>w.html`<div class="date-row"><dt>${M(this.effectiveLang(),n.date)||n.date}</dt><dd>${n.event}</dd></div>`)}</dl></section>`:w.nothing}`}};xa.endpoints=jl,xa.styles=[u,Ca,wr,w.css`.card{gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}section>h3{margin-block-end:var(--roxy-space-sm)}.head{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.glyph{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);line-height:1}.title{text-transform:capitalize;white-space:nowrap}.energy{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;margin-inline-start:auto}.energy-bar{inline-size:10ch;block-size:var(--roxy-space-sm);background:var(--roxy-border);border-radius:var(--roxy-radius-full);vertical-align:middle;margin-inline-start:var(--roxy-space-xs);display:inline-block;overflow:hidden}.energy-bar>span{background:var(--roxy-accent);height:100%;transition:width var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.column p,.overview p,.section p{line-height:1.7}.overview,.column,.section{align-content:start;gap:var(--roxy-space-sm);display:grid}.column{gap:var(--roxy-space-md)}.sections{gap:var(--roxy-space-lg) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,48ch),1fr));display:grid}.section p{font-size:var(--roxy-text-sm)}.sky,.lucky{border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);padding-block-start:var(--roxy-space-md)}.sky{gap:var(--roxy-space-sm);display:grid}.lucky{gap:var(--roxy-space-sm) var(--roxy-space-md);color:var(--roxy-secondary);flex-wrap:wrap;display:flex}.lucky strong{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.compat-wrap{align-items:center;gap:var(--roxy-space-xs);flex-wrap:wrap;width:100%;display:flex}.compat>li{text-transform:capitalize}.moon-line{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.moon-line b{font-weight:var(--roxy-weight-bold)}.moon-line .roxy-label{margin-inline-end:var(--roxy-space-xs)}.transits{gap:var(--roxy-space-xs);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.transits li::marker{color:var(--roxy-accent)}.weeks{gap:var(--roxy-space-sm);display:grid}.week{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);align-items:baseline;gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.week:first-child{border-block-start:0;padding-block-start:0}.week-focus{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.week-advice{font-size:var(--roxy-text-sm);margin-block-start:calc(var(--roxy-space-unit) / 2)}.dates{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);margin:0;display:grid}.date-row{display:contents}.date-row dt{color:var(--roxy-accent-ink);font-size:inherit;font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.date-row dd{margin:0}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.row:first-child{border-block-start:0;padding-block-start:0}.row-when{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.row-what{font-size:var(--roxy-text-sm)}.row-what .name,.row-meta .kind{font-weight:var(--roxy-weight-bold)}.row-meta{gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-sm);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;grid-column:2;display:flex}@container (width<=30rem){.row-meta{grid-column:1}}.tiles{gap:var(--roxy-space-sm) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));display:grid}.tile{gap:calc(var(--roxy-space-unit) / 2);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm);display:grid}.tile-value{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.tile-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],m([(0,zo.property)({type:String,reflect:true})],xa.prototype,"period",2),m([(0,zo.property)({type:String,reflect:true})],xa.prototype,"layout",2),xa=m([x("roxy-horoscope-card")],xa);var te=require("lit"),wh=require("lit/decorators.js");var Au=[{id:"planets",label:"Planets"},{id:"cusps",label:"Cusps"},{id:"significators",label:"Significators"}],fi=[1,2,3,4];function Oo(s,a){return s?typeof a=="number"?`${s} ${a}`:s:""}function $h(s){return[...new Set(s.map(String))].join(" > ")}function Pu(s){return[...new Set(s??[])]}var Ia=class extends g{constructor(){super(...arguments);this.activeTab="planets"}bodies(){let e=this.data;if(!e)return[];let t=(e.planets??[]).map(n=>({name:n.planet,longitude:n.longitude,house:n.house,nakshatra:n.nakshatra,pada:n.pada,starLord:n.starLord,subLord:n.subLord,subSubLord:n.subSubLord,kpNumber:n.kpNumber,retrograde:n.retrograde})),r=e.nodes;for(let[n,i]of[["Rahu",r?.rahu],["Ketu",r?.ketu]])i&&t.push({name:n,longitude:i.longitude,house:i.house,nakshatra:i.nakshatra,pada:i.pada,starLord:i.starLord,subLord:i.subLord,subSubLord:i.subSubLord,kpNumber:i.kpNumber,retrograde:true});return t}renderData(e){let t=e.ascendant;return te.html`<div class="wrap" part="card" aria-label="KP chart"><header class="head" part="header"><h2 class="title">KP chart</h2>${t?te.html`<div class="asc">Ascendant: <strong>${typeof t.longitude=="number"?pt(t.longitude):t.sign??""} </strong>${t.nakshatra?te.html`· ${Oo(t.nakshatra,t.pada)}`:te.nothing} ${t.subLord?te.html`· sub lord ${t.subLord}`:te.nothing} ${typeof t.kpNumber=="number"?te.html`· KP ${t.kpNumber}`:te.nothing}</div>`:te.nothing} ${typeof e.meta?.ayanamsa=="number"?te.html`<div class="ayan">Ayanamsa: ${ps(this.effectiveLang(),e.meta.ayanamsaType,e.meta.ayanamsa)} ${e.meta.houseSystem?te.html`· ${e.meta.houseSystem} houses`:te.nothing}</div>`:te.nothing}</header>${ut({items:Au,active:this.activeTab,onSelect:r=>{this.activeTab=r},label:"KP chart views",idPrefix:"kp",controls:true})}<div id="kp-panel-${this.activeTab}" part="panel" role="tabpanel" aria-labelledby="kp-tab-${this.activeTab}">${this.activeTab==="planets"?this.renderPlanets():this.activeTab==="cusps"?this.renderCusps():this.renderSignificators()}</div></div>`}renderPlanets(){let e=this.bodies();return e.length?this.scrollBox(te.html`<table part="table" role="table"><caption id="kp-planets-caption" class="roxy-sr-only">KP planets and nodes: each body with its position, house, nakshatra and pada, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">Position</th><th scope="col">House</th><th scope="col">Nakshatra, pada</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(t=>te.html`<tr><td class="body">${t.name}${t.retrograde?te.html`<span class="retro">R</span>`:te.nothing}</td><td class="num">${typeof t.longitude=="number"?pt(t.longitude):""}</td><td class="num">${typeof t.house=="number"?t.house:""}</td><td>${Oo(t.nakshatra,t.pada)}</td><td>${t.starLord??""}</td><td>${t.subLord??""}</td><td>${t.subSubLord??""}</td><td class="num">${typeof t.kpNumber=="number"?t.kpNumber:""}</td></tr>`)}</tbody></table>`,"kp-planets-caption"):te.html`<p class="roxy-empty" role="status">No planets</p>`}renderCusps(){let e=this.data?.cusps??[],t=this.data?.houseThemes;return e.length?this.scrollBox(te.html`<table part="table" role="table"><caption id="kp-cusps-caption" class="roxy-sr-only">KP Placidus cusps: each house cusp with what it signifies, its position, sign lord, nakshatra and pada, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">House</th><th scope="col">Position</th><th scope="col">Sign lord</th><th scope="col">Nakshatra, pada</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(r=>te.html`<tr><td class="body num">${r.house}${this.renderThemes(Ji(r.house,t))}</td><td class="num">${typeof r.longitude=="number"?pt(r.longitude):r.sign??""}</td><td>${r.signLord??""}</td><td>${Oo(r.nakshatra,r.pada)}</td><td>${r.starLord??""}</td><td>${r.subLord??""}</td><td>${r.subSubLord??""}</td><td class="num">${typeof r.kpNumber=="number"?r.kpNumber:""}</td></tr>`)}</tbody></table>`,"kp-cusps-caption"):te.html`<p class="roxy-empty" role="status">No cusps</p>`}renderSignificators(){let e=this.data?.significators,t=this.data?.houseThemes,r=e?.houseWise??[],n=e?.planetWise??[];return!r.length&&!n.length?te.html`<p class="roxy-empty" role="status">No significators</p>`:te.html`${this.renderLevelLegend(r)} ${r.length?te.html`<div class="sig-head"><h3 class="sig-title">House-wise significators</h3><p class="sig-note">Planets that signify each house, strongest level first.</p></div>${this.scrollBox(te.html`<table part="table" role="table"><caption id="kp-house-sig-caption" class="roxy-sr-only">KP house-wise significators: each house, the planets that signify it at levels 1 to 4, and the full strength order.</caption><thead><tr><th scope="col">House</th>${fi.map(i=>te.html`<th scope="col">L${i}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${r.map(i=>te.html`<tr><td class="body num">${i.house}${this.renderThemes(Ji(i.house,t))}</td>${fi.map(o=>this.renderCell(this.planetsAtLevel(i,o).join(", ")))}<td class="chain">${$h(i.all??[])}</td></tr>`)}</tbody></table>`,"kp-house-sig-caption")}`:te.nothing} ${n.length?te.html`<div class="sig-head"><h3 class="sig-title">Planet-wise significators</h3><p class="sig-note">Houses each planet signifies, strongest level first.</p></div>${this.scrollBox(te.html`<table part="table" role="table"><caption id="kp-planet-sig-caption" class="roxy-sr-only">KP planet-wise significators: each planet, the houses it signifies at levels 1 to 4, and the full strength order.</caption><thead><tr><th scope="col">Planet</th>${fi.map(i=>te.html`<th scope="col">L${i}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${n.map(i=>te.html`<tr><td class="body">${i.planet}</td>${fi.map(o=>this.renderCell(this.housesAtLevel(i,o).join(", ")))}<td class="chain">${$h(i.allHouses??[])}${this.renderThemes(ga(Pu(i.allHouses),t))}</td></tr>`)}</tbody></table>`,"kp-planet-sig-caption")}`:te.nothing}`}scrollBox(e,t){return te.html`<div class="scroll" tabindex="0" role="region" aria-labelledby="${t}">${e}</div>`}renderThemes(e){return e?te.html`<span class="themes">${e}</span>`:te.nothing}renderCell(e){return e?te.html`<td>${e}</td>`:te.html`<td class="empty-cell">none</td>`}planetsAtLevel(e,t){return(e.significators??[]).filter(r=>r.level===t).flatMap(r=>r.planets??[])}housesAtLevel(e,t){return(e.signifies??[]).filter(r=>r.level===t).flatMap(r=>r.houses??[])}renderLevelLegend(e){let t=new Map;for(let r of e)for(let n of r.significators??[])n.description&&!t.has(n.level)&&t.set(n.level,n.description);return t.size===0?te.nothing:te.html`<ul class="legend" part="legend" aria-label="Significator levels">${[...t.entries()].sort((r,n)=>r[0]-n[0]).map(([r,n])=>te.html`<li><b>L${r}</b>${n}</li>`)}</ul>`}};Ia.endpoints=Kl,Ia.styles=[u,dt,te.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{gap:var(--roxy-space-xs);display:grid}.title,.sig-title,.sig-note{margin:0}.asc,.ayan{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.asc strong{color:var(--roxy-fg)}[role=tabpanel]:not([hidden]){gap:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.body{font-weight:var(--roxy-weight-bold)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.num{font-variant-numeric:tabular-nums}.sig-head{gap:var(--roxy-space-xs);display:grid}.sig-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.legend b{color:var(--roxy-accent-ink);margin-inline-end:var(--roxy-space-xs)}.chain,.empty-cell{color:var(--roxy-muted)}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-normal);display:block}`],m([(0,wh.state)()],Ia.prototype,"activeTab",2),Ia=m([x("roxy-kp-chart")],Ia);var xe=require("lit");var Mu={strong:"Strong",favourable:"Favourable",mixed:"Mixed",caution:"Caution",unfavourable:"Unfavourable"},_u={favourable:"Favourable",mixed:"Mixed",unfavourable:"Unfavourable",neutral:"Neutral"},kh={cusps:"Cusps",dasha:"Dasha",rulingPlanets:"Ruling planets",moonWindows:"Moon windows"},Nu={gain:"Gain",loss:"Loss"},zu={mahadasha:"Mahadasha",antardasha:"Antardasha",pratyantardasha:"Pratyantardasha",sookshmaDasha:"Sookshma"},Hr=class extends g{renderData(a){return a.layers?xe.html`<div class="wrap" part="card" aria-label="${this.t("KP daily finance")}">${this.renderHead(a)} ${this.renderSignificators(a)}<section class="block" part="section cusps">${this.renderLayer("cusps",a.layers.cusps,this.renderCuspRows(a.layers.cusps.rows))}</section><section class="block" part="section dasha">${this.renderLayer("dasha",a.layers.dasha,this.renderDashaRows(a.layers.dasha.rows))}</section><section class="block" part="section ruling-planets">${this.renderLayer("rulingPlanets",a.layers.rulingPlanets,this.renderRulingRows(a.layers.rulingPlanets.rows))}</section><section class="block" part="section moon-windows">${this.renderLayer("moonWindows",a.layers.moonWindows,this.renderWindowRows(a.layers.moonWindows.rows))}</section>${this.renderWindows(a)}<section class="block" part="section frame">${ve(this.effectiveLang(),{ayanamsa:a.ayanamsa,ayanamsaDegrees:a.ayanamsaDegrees},this.translator)}</section></div>`:this.renderEmpty()}renderHead(a){let e=this.effectiveLang();return xe.html`<header class="head" part="header"><div class="title-row"><h2 class="title">${this.t("KP daily finance")}</h2><span class="when">${fe(e,a.date)}</span></div><div class="verdict-row"><span class="verdict ${a.band}">${this.t(Mu[a.band])}</span> <span class="evidence">${b(e,a.score,1)}</span></div><dl class="roxy-facts" part="details"><div class="fact"><dt>${this.t("Reading moment")}</dt><dd>${fe(e,a.readingAt)}</dd></div><div class="fact"><dt>${this.t("Gain houses")}</dt><dd>${ot(e,a.houses.gain.map(String))}</dd></div><div class="fact"><dt>${this.t("Loss houses")}</dt><dd>${ot(e,a.houses.loss.map(String))}</dd></div></dl></header>`}renderSignificators(a){let e=a.significators,t=this.effectiveLang(),r=n=>xe.html`<div class="roxy-chips">${n.map(i=>xe.html`<span class="chip roxy-chip">${this.glyphName(i)}</span>`)}</div>`;return xe.html`<section class="block" part="section significators"><h3>${this.t("Significators")}</h3><dl class="roxy-facts"><div class="fact"><dt>${this.t("Gain")}</dt><dd>${r(e.gain)}</dd></div><div class="fact"><dt>${this.t("Loss")}</dt><dd>${r(e.loss)}</dd></div></dl>${e.byHouse.length?xe.html`<div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Significators")}"><table><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Significators")}</th></tr></thead><tbody>${e.byHouse.map(n=>xe.html`<tr><td class="num">${n.house} ${this.groupChip(n.group)}</td><td class="names">${ot(t,[...new Set(n.significators)])}</td></tr>`)}</tbody></table></div>`:xe.nothing}</section>`}renderLayer(a,e,t){let r=this.effectiveLang();return xe.html`<div class="block-head"><h3>${this.t(kh[a])}</h3><span class="evidence">${this.t("Weight")} ${Ne(r,e.weight,0)} · ${this.t("Score")} ${b(r,e.score,1)}</span></div><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t(kh[a])}">${t}</div>`}renderCuspRows(a){return xe.html`<table><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Sub lord")}</th><th scope="col">${this.t("Star lord")}</th><th scope="col">${this.t("Sign lord")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(e=>xe.html`<tr><td class="num">${e.house} ${this.groupChip(e.inverted?"loss":"gain")}</td><td>${this.glyphName(e.subLord)}</td><td>${this.glyphName(e.starLord)}</td><td>${this.glyphName(e.signLord)}</td><td>${this.verdictChip(e.verdict)}</td><td class="num">${b(this.effectiveLang(),e.score,0)}</td></tr>`)}</tbody></table>`}renderDashaRows(a){let e=this.effectiveLang();return xe.html`<table><thead><tr><th scope="col">${this.t("Level")}</th><th scope="col">${this.t("Lord")}</th><th scope="col">${this.t("Start")}</th><th scope="col">${this.t("End")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th><th scope="col">${this.t("Weight")}</th></tr></thead><tbody>${a.map(t=>xe.html`<tr><td>${this.t(zu[t.level])}</td><td>${this.glyphName(t.lord,t.retrograde)}</td><td>${fe(e,t.startDate)}</td><td>${fe(e,t.endDate)}</td><td>${this.verdictChip(t.verdict)}</td><td class="num">${b(e,t.score,0)}</td><td class="num">${Ne(e,t.weight,0)}</td></tr>`)}</tbody></table>`}renderRulingRows(a){return xe.html`<table><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(e=>xe.html`<tr><td>${this.glyphName(e.planet,e.retrograde)}</td><td>${this.verdictChip(e.verdict)}</td><td class="num">${b(this.effectiveLang(),e.score,0)}</td></tr>`)}</tbody></table>`}renderWindowRows(a){let e=this.effectiveLang();return xe.html`<table><thead><tr><th scope="col">${this.t("Start")}</th><th scope="col">${this.t("End")}</th><th scope="col">${this.t("Sub lord")}</th><th scope="col">${this.t("Verdict")}</th><th scope="col">${this.t("Score")}</th></tr></thead><tbody>${a.map(t=>xe.html`<tr><td>${Ot(e,t.from)}</td><td>${Ot(e,t.to)}</td><td>${this.glyphName(t.subLord)}</td><td>${this.verdictChip(t.verdict)}</td><td class="num">${b(e,t.score,0)}</td></tr>`)}</tbody></table>`}renderWindows(a){let e=this.effectiveLang(),t=a.bestWindow,r=a.worstWindows??[];if(!t&&!r.length)return xe.nothing;let n=(i,o)=>xe.html`<span class="window roxy-chip ${o}" data-tone="${o==="best"?"success":"danger"}"><span>${this.glyphName(i.subLord)}</span> <small>${la(e,{start:i.from,end:i.to})}</small></span>`;return xe.html`<section class="block" part="section windows"><dl class="roxy-facts">${t?xe.html`<div class="fact"><dt>${this.t("Best window")}</dt><dd><div class="roxy-chips">${n(t,"best")}</div></dd></div>`:xe.nothing} ${r.length?xe.html`<div class="fact"><dt>${this.t("Worst windows")}</dt><dd><div class="roxy-chips">${r.map(i=>n(i,"worst"))}</div></dd></div>`:xe.nothing}</dl></section>`}glyphName(a,e=false){let t=S(a);return xe.html`${t?xe.html`<span class="glyph roxy-glyph" aria-hidden="true">${t}</span>`:xe.nothing}${a}${e?xe.html`<span class="retro roxy-glyph" aria-label="${this.t("retrograde")}">${Ke}</span>`:xe.nothing}`}verdictChip(a){return xe.html`<span class="state ${a}">${this.t(_u[a])}</span>`}groupChip(a){return xe.html`<span class="chip roxy-chip">${this.t(Nu[a])}</span>`}};Hr.endpoints=Vl,Hr.styles=[u,Re,re,xe.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head,.block{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);display:grid}.block{border-block-start:1px solid var(--roxy-border)}.title-row,.block-head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title,.block h3{margin:0}.when{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.verdict-row{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict{font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.evidence{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}:is(.verdict,.state):is(.strong,.favourable){color:var(--roxy-success-fg)}:is(.verdict,.state):is(.mixed,.caution){color:var(--roxy-warning-fg)}:is(.verdict,.state).unfavourable{color:var(--roxy-danger-fg)}.state.neutral{color:var(--roxy-secondary)}.state{font-weight:var(--roxy-weight-bold)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td.names{white-space:normal}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}.window small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}`],Hr=m([x("roxy-kp-finance-card")],Hr);var ba=require("lit");var jr=class extends g{renderData(a){let e=a.planets??[];return ba.html`<div class="wrap" part="card" aria-label="KP planets table"><header class="head" part="header"><h2 class="title">KP planets</h2>${typeof a.ayanamsa=="number"?ba.html`<span class="ayanamsa">Ayanamsa: ${b(this.effectiveLang(),a.ayanamsa,2)}°</span>`:ba.nothing}</header><div class="scroll" tabindex="0" role="region" aria-labelledby="kp-planets-table-caption"><table part="table" role="table"><caption id="kp-planets-table-caption" class="roxy-sr-only">KP planets: each planet with its sign, sign lord, nakshatra, star lord, sub lord, sub sub lord and KP number.</caption><thead><tr><th scope="col">Planet</th><th scope="col">Sign</th><th scope="col">Sign lord</th><th scope="col">Nakshatra</th><th scope="col">Star lord</th><th scope="col">Sub lord</th><th scope="col">Sub-sub lord</th><th scope="col">KP no.</th></tr></thead><tbody>${e.map(t=>ba.html`<tr><td class="planet">${t.planet} ${t.retrograde?ba.html`<span class="retro">R</span>`:ba.nothing}</td><td>${t.sign??""}</td><td>${t.signLord??""}</td><td>${t.nakshatra??""}</td><td>${t.nakshatraLord??""}</td><td>${t.subLord??""}</td><td>${t.subSubLord??""}</td><td>${t.kpNumber??""}</td></tr>`)}</tbody></table></div></div>`}};jr.endpoints=Ul,jr.styles=[u,ba.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.title{margin:0}.ayanamsa{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}td.planet{font-weight:var(--roxy-weight-bold)}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);margin-inline-start:var(--roxy-space-xs)}`],jr=m([x("roxy-kp-planets-table")],jr);var Ct=require("lit");var Kr=class extends g{renderData(a){let e=a.significators??[];return Ct.html`<div class="wrap" part="card" aria-label="KP ruling planets"><header part="header"><h2 class="title">KP ruling planets</h2>${a.dayLord?Ct.html`<div class="day-lord">Day lord: <strong>${a.dayLord}</strong></div>`:Ct.nothing}</header><div class="groups" part="details"><div class="group"><h3>Moon</h3><dl part="label-track"><dt>Sign lord</dt><dd>${a.moonSignLord??""}</dd><dt>Star lord</dt><dd>${a.moonStarLord??""}</dd><dt>Sub lord</dt><dd>${a.moonSublord??""}</dd><dt>Sub-sub lord</dt><dd>${a.moonSubSublord??""}</dd></dl></div><div class="group"><h3>Lagna</h3><dl part="label-track"><dt>Sign lord</dt><dd>${a.lagnaSignLord??""}</dd><dt>Star lord</dt><dd>${a.lagnaStarLord??""}</dd><dt>Sub lord</dt><dd>${a.lagnaSublord??""}</dd><dt>Sub-sub lord</dt><dd>${a.lagnaSubSublord??""}</dd></dl></div></div>${a.rulingPlanets?.length?Ct.html`<div class="rp-list" part="details"><span class="roxy-label">Ruling planets</span><ol class="roxy-chips" aria-label="Ruling planets by strength">${a.rulingPlanets.map((t,r)=>Ct.html`<li class="rp"><span class="rank">${r+1}</span> ${t}</li>`)}</ol></div>`:Ct.nothing} ${e.length?Ct.html`<table part="table"><caption class="roxy-sr-only">House significators: each ruling planet, the houses it signifies, and what those houses stand for.</caption><thead><tr><th scope="col">Planet</th><th scope="col">Signifies houses</th></tr></thead><tbody>${e.map(t=>{let r=ga(t.signifies,a.houseThemes);return Ct.html`<tr><td>${t.planet}</td><td><span class="num">${(t.signifies??[]).join(", ")}</span> ${r?Ct.html`<span class="themes">${r}</span>`:Ct.nothing}</td></tr>`})}</tbody></table>`:Ct.nothing}</div>`}};Kr.endpoints=ql,Kr.styles=[u,Ct.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.title,.group h3{margin:0}.day-lord{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.day-lord strong{color:var(--roxy-fg)}.groups{gap:var(--roxy-space-md) var(--roxy-space-xl);flex-wrap:wrap;display:flex}.group{gap:var(--roxy-space-xs);flex:1 1 0;min-width:min(100%,22ch);display:grid}.group dl{grid-template-columns:var(--roxy-label-col) minmax(0, 1fr);gap:var(--roxy-space-xs) var(--roxy-space-sm);font-size:var(--roxy-text-sm);margin:0;display:grid}.group dd{font-weight:var(--roxy-weight-bold);margin:0}.rp-list{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.rp .rank{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.num{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}`],Kr=m([x("roxy-kp-ruling-planets")],Kr);var de=require("lit"),Sh=require("lit/decorators.js");var Fa=class extends g{constructor(){super(...arguments);this.mode="kua"}renderData(e){let t=this.effectiveLang(),r=e.trigram;return de.html`<article class="card" part="card" aria-labelledby="kua-title"><header class="head" part="header"><h2 class="title" id="kua-title">${this.t("Kua")} ${e.kua??""}</h2>${e.group?de.html`<span class="group">${this.t("{{direction}} group",{direction:ie(t,"facing",U(e.group))})}</span>`:de.nothing}</header><div class="facts" part="details">${r?de.html`<span><span class="roxy-label">${this.t("Trigram")}</span> <span lang="zh">${r.chinese??""}</span> ${Je(or(r.english))} <b>${r.english??""}</b> <span class="element-word ${At(r.element)}">${y(r,"element")}</span></span>`:de.nothing} ${r?.familyMember?de.html`<span><span class="roxy-label">${this.t("Role")}</span>${r.familyMember}</span>`:de.nothing} ${"solarYear"in e&&typeof e.solarYear=="number"?de.html`<span class="solar-year"><span class="roxy-label">${this.t("Year")}</span><b>${rr(t,String(e.solarYear),"year")}</b></span>`:de.nothing} ${"gender"in e&&e.gender?de.html`<span class="formula-gender"><span class="roxy-label">${Se(t,"gender")}</span>${ie(t,"gender",e.gender)}</span>`:de.nothing} ${"boundaryDate"in e&&e.boundaryDate?de.html`<span>${this.t("Year boundary")} ${M(t,e.boundaryDate)}</span>`:de.nothing} ${"reassigned"in e&&e.reassigned?de.html`<span>${this.t("Reassigned from {{value}}",{value:String("rawKua"in e?e.rawKua??"":"")})}</span>`:de.nothing} ${this.renderBestWorst(e)}</div><div class="plate" part="chart plate" role="group" aria-label="${this.t("Eight mansions")}">${pi.map(n=>this.renderSector(e,n))}</div><div class="legend" part="legend"><span><span class="swatch swatch-good"></span>${this.t("Favourable")}</span> <span><span class="swatch swatch-bad"></span>${this.t("Unfavourable")}</span></div>${this.renderSectorRows(e)} ${"conventions"in e?lr(e.conventions,this.translator,this.effectiveLang()):de.nothing}</article>`}renderBestWorst(e){if(this.mode!=="mansions"||!("bestSector"in e))return de.nothing;let t=this.effectiveLang();return de.html`${e.bestSector?de.html`<span><span class="roxy-label">${this.t("Best")}</span><b>${ie(t,"facing",e.bestSector)}</b></span>`:de.nothing} ${e.worstSector?de.html`<span><span class="roxy-label">${this.t("Worst")}</span><b>${ie(t,"facing",e.worstSector)}</b></span>`:de.nothing}`}sectorHeading(e,t){return t==="Center"?this.t("Center"):ie(e,"facing",t)}renderSector(e,t){let r=this.effectiveLang(),n=this.sectorHeading(r,t);if(t==="Center")return de.html`<div class="sector sector-self centre"><span class="kua-number">${e.kua??""}</span> <span class="trigram-symbol roxy-glyph">${or(e.trigram?.english)??""}</span> <span class="sector-name plate-heading">${e.trigram?.english??""}</span></div>`;let i=(e.sectors??[]).find(l=>l.direction===t);if(!i)return de.html`<div class="sector"><span class="sector-name plate-heading">${n}</span></div>`;let o=i.nature==="auspicious";return de.html`<div class="sector ${o?"sector-good":"sector-bad"}"><span class="sector-name plate-heading">${n}</span> <span class="star-name">${y(i,"starName")}</span> ${"chinese"in i&&i.chinese?de.html`<span class="star-hanzi" lang="zh">${i.chinese}</span>`:de.nothing} <span class="domain">${i.domain??""}</span> ${typeof i.rank=="number"?de.html`<span class="rank">${o?this.t("Rank"):this.t("Severity")} ${i.rank}</span>`:de.nothing}</div>`}renderSectorRows(e){let t=e.sectors??[];if(t.length===0)return de.nothing;let r=this.effectiveLang(),n=t.map(i=>{let o=this.mode==="mansions"&&"reading"in i?i.reading:void 0;return!o||this.hideReadings?de.nothing:de.html`<li class="row" part="label-track"><span class="roxy-label">${this.sectorHeading(r,i.direction??"")}</span><div class="row-body"><span>${y(i,"starName")}</span><p part="reading">${o}</p></div></li>`});return n.every(i=>i===de.nothing)?de.nothing:de.html`<section part="section sectors"><h3 class="block-title">${this.t("Sectors")}</h3><ul class="rows">${n}</ul></section>`}};Fa.endpoints=Yl,Fa.styles=[u,ma,re,hi,wr,de.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.group{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.plate{background:var(--roxy-border);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-md);grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;display:grid;overflow:hidden}.sector{align-content:start;gap:calc(var(--roxy-space-unit) / 2);min-block-size:3.5lh;padding:var(--roxy-space-sm);background:var(--roxy-surface);text-align:center;display:grid}.sector-good{background:color-mix(in srgb, var(--roxy-success) 10%, var(--roxy-surface))}.sector-bad{background:color-mix(in srgb, var(--roxy-danger) 10%, var(--roxy-surface))}.sector-self{background:color-mix(in srgb, var(--roxy-accent) 10%, var(--roxy-surface))}:is(.sector-good,.sector-bad,.sector-self) .sector-name,:is(.sector-good,.sector-bad) .rank{color:var(--roxy-secondary)}.star-name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.star-hanzi,.trigram-symbol{color:var(--roxy-accent-ink)}:is(.sector-good,.sector-bad) .star-hanzi{color:var(--roxy-fg)}.domain{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.rank{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.centre{align-content:center}.kua-number{font-size:calc(var(--roxy-text-base) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.trigram-symbol{font-size:calc(var(--roxy-text-base) * 1.5);line-height:var(--roxy-leading-tight)}@container (width<=30rem){.plate{background:var(--roxy-surface);display:block}.sector.centre{display:none}.sector{column-gap:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);text-align:start;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"name rank""star hanzi""domain domain";min-block-size:auto}.sector:last-child{border-block-end:0}.sector-name{grid-area:name;align-self:center}.rank{text-align:end;white-space:nowrap;grid-area:rank;align-self:center}.star-name{grid-area:star}.star-hanzi{text-align:end;grid-area:hanzi}.domain{grid-area:domain}}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-good{background:var(--roxy-success)}.swatch-bad{background:var(--roxy-danger)}.rows{margin:0;padding:0;list-style:none;display:grid}.row{align-items:baseline;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm)}.row:first-child{border-block-start:0;padding-block-start:0}.row-body p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}`],m([(0,Sh.property)({type:String,reflect:true})],Fa.prototype,"mode",2),Fa=m([x("roxy-kua-card")],Fa);var ht=require("lit");var Go=320,Qt=Go/2,Ba=128,Ou=118,Rh=137,Gu=152,Iu=.95,Fu={glyph:11},Bu=Fu.glyph;function Ha(s,a){let e=s*Math.PI/180;return{x:Qt+a*Math.sin(e),y:Qt-a*Math.cos(e)}}var Hu=[{az:0,source:"N"},{az:45,source:"NE"},{az:90,source:"E"},{az:135,source:"SE"},{az:180,source:"S"},{az:225,source:"SW"},{az:270,source:"W"},{az:315,source:"NW"}],Vr=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this)}renderData(e){let t=e.bodies??[],r=e.birthDetails;return ht.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Local space")}</h2>${r?ht.html`<p class="roxy-label">${fe(this.effectiveLang(),r.date,r.time)}</p>`:ht.nothing}</header>${this.chartViewport.renderChartViewport(this.renderDial(t),this.t("Local space"),this.translator)} ${e.summary&&!this.hideReadings?ht.html`<p class="summary">${e.summary}</p>`:ht.nothing} ${this.renderList(t)}</div>`}renderDial(e){return ht.html`<svg viewBox="0 0 ${Go} ${Go}" part="chart" role="img" aria-label="${this.t("Local space compass of planetary directions from the birthplace")}"><title>${this.t("Local space compass")}</title><desc>${this.t("A compass centered on the birthplace. Each body is a line pointing to its azimuth, clockwise from north. Bodies below the horizon are dimmed.")}</desc><circle class="dial-fill" cx="${Qt}" cy="${Qt}" r="${Ba}"/><circle class="dial" cx="${Qt}" cy="${Qt}" r="${Ba*.66}" stroke-width="0.5"/><circle class="dial" cx="${Qt}" cy="${Qt}" r="${Ba*.33}" stroke-width="0.5"/>${this.renderCompassRing()} ${this.renderSpokes(e)}<circle class="center-dot" cx="${Qt}" cy="${Qt}" r="2.5"/></svg>`}renderCompassRing(){let e=[];for(let l=0;l<360;l+=22.5){let c=Ha(l,Ba),d=Ha(l,Ba-(l%45===0?8:4));e.push(ht.svg`<line class="tick" x1=${d.x} y1=${d.y} x2=${c.x} y2=${c.y} />`)}let t=Ha(0,Ba),r=Ha(180,Ba),n=Ha(90,Ba),i=Ha(270,Ba),o=Hu.map(({az:l,source:c})=>{let d=Ha(l,Gu),h=l%90===0;return ht.svg`<text class=${`compass-label${h?" cardinal":""}`} x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${this.t(c)}</text>`});return ht.svg`
|
|
99
99
|
<line class="cardinal-axis" x1=${t.x} y1=${t.y} x2=${r.x} y2=${r.y} />
|
|
100
|
-
<line class="cardinal-axis" x1=${
|
|
101
|
-
${e}${o}`}renderSpokes(e){let t=e.map((
|
|
102
|
-
<line class=${`spoke${d?" below":""}`} stroke=${c} x1=${
|
|
103
|
-
<text class=${`body-glyph${d?" below":""}`} fill=${c} x=${
|
|
104
|
-
</g>`})}renderList(e){if(e.length===0)return tt.nothing;let t=this.t("Local space directions: each body with its compass direction, azimuth, altitude and whether it sits above or below the horizon.");return tt.html`<div class="scroll" part="table" tabindex="0" role="region" aria-label="${t}"><table><caption class="roxy-sr-only">${t}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Direction")}</th><th scope="col" class="num">${this.t("Azimuth")}</th><th scope="col" class="num">${this.t("Altitude")}</th><th scope="col">${this.t("Horizon")}</th></tr></thead><tbody>${e.map((r,s)=>{let i=ls(r.planet,s),o=r.aboveHorizon===false;return tt.html`<tr><td><span class="body-cell"><span class="body-dot" style="${`background: ${i}`}"></span> ${r.symbol?tt.html`<span aria-hidden="true">${r.symbol}</span>`:tt.nothing}${y(r,"planet")}</span></td><td>${r.compassDirection}</td><td class="num">${Math.round(r.azimuth)}°</td><td class="num">${r.altitude>0?"+":""}${Math.round(r.altitude)}°</td><td><span class="${`horizon ${o?"down":"up"}`}">${o?this.t("Below"):this.t("Above")}</span></td></tr>`})}</tbody></table></div>`}};Fr.endpoints=Ol,Fr.styles=[u,Xe,tt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,30rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.dial{fill:none;stroke:var(--roxy-border)}.dial-fill{fill:color-mix(in srgb, var(--roxy-border) 10%, transparent);stroke:var(--roxy-border);stroke-width:1px}.cardinal-axis{stroke:var(--roxy-border);stroke-width:.5px}.tick{stroke:var(--roxy-secondary);stroke-width:.6px;opacity:.5}.compass-label{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold)}.compass-label.cardinal,.center-dot{fill:var(--roxy-fg)}.spoke{stroke-width:1.4px}.spoke.below{stroke-dasharray:3 3;opacity:.4}.body-glyph{font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-bold)}.body-glyph.below{opacity:.45}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td).num{text-align:end}.body-cell{align-items:center;gap:var(--roxy-space-xs);display:inline-flex}.body-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);flex-shrink:0}.horizon.up{color:var(--roxy-success-fg)}.horizon.down{color:var(--roxy-muted)}.summary{font-size:var(--roxy-text-sm)}`],Fr=m([f("roxy-local-space-compass")],Fr);var xt=require("lit"),bt=require("lit/decorators.js");var Ye=class extends Za{constructor(){super(...arguments);this.placeholder="Search city";this.defaultValue="";this.query="";this.results=[];this.isOpen=false;this.isLoading=false;this.highlight=-1;this.error=null;this.debouncedFetch=Wn(e=>{this.fetchResults(e)},300);this.onInput=e=>{let t=e.target.value;if(this.query=t,t.length<2){this.results=[],this.isOpen=false,this.highlight=-1,this.error=null;return}this.debouncedFetch(t)};this.onKeyDown=e=>{if(!this.isOpen||this.results.length===0){e.key==="ArrowDown"&&this.query.length>=2&&(this.fetchResults(this.query),e.preventDefault());return}if(e.key==="ArrowDown")e.preventDefault(),this.highlight=(this.highlight+1)%this.results.length;else if(e.key==="ArrowUp")e.preventDefault(),this.highlight=(this.highlight-1+this.results.length)%this.results.length;else if(e.key==="Enter"){e.preventDefault();let t=this.results[this.highlight]??this.results[0];t&&this.select(t)}else e.key==="Escape"&&(this.isOpen=false)}}connectedCallback(){super.connectedCallback(),this.query=this.defaultValue,this.clickOutsideHandler=e=>{e.composedPath().includes(this)||(this.isOpen=false)},document.addEventListener("mousedown",this.clickOutsideHandler)}willUpdate(e){if(e.has("publishableKey")||e.has("apiKey")){let t=ts(this.publishableKey??this.apiKey);t&&!this.refusal&&vs(this,t,{warn:true}),this.refusal=t}}disconnectedCallback(){super.disconnectedCallback(),this.clickOutsideHandler&&document.removeEventListener("mousedown",this.clickOutsideHandler),this.debouncedFetch.cancel(),this.abortController&&(this.abortController.abort(),this.abortController=void 0)}async fetchResults(e){if(this.refusal)return;this.abortController&&this.abortController.abort();let t=new AbortController;this.abortController=t,this.isLoading=true;try{let r=await this.search(e,t.signal);if(t.signal.aborted)return;this.error=null,this.results=r.cities??[],this.isOpen=true,this.highlight=this.results.length>0?0:-1}catch(r){if(r?.name==="AbortError")return;this.results=[],this.isOpen=false,this.highlight=-1,this.error=r instanceof Error?r.message:String(r)}finally{this.abortController===t&&(this.abortController=void 0),t.signal.aborted||(this.isLoading=false)}}async search(e,t){if(!this.endpoint&&this.submitUrl)return Xa({submitUrl:this.submitUrl,submitContext:this.submitContext},{path:"/location/search",method:"GET",query:{q:e,limit:8}},t);let r=new URL(this.endpoint||`${$s}/location/search`,document.baseURI);r.searchParams.set("q",e),r.searchParams.set("limit","8");let s={Accept:"application/json"};this.apiKey&&this.publishableKey&&console.warn("[roxy-location-search] both api-key and publishable-key set; using publishable-key. Remove api-key from your widget markup.");let i=this.publishableKey??this.apiKey;i&&(s["X-API-Key"]=i);let o=await fetch(r,{headers:s,signal:t});if(!o.ok)throw new Error(await Nc(o));return await o.json()}select(e){this.query=`${e.city}${e.province?`, ${e.province}`:""}, ${e.country}`,this.isOpen=false,this.results=[],this.dispatchEvent(new CustomEvent("roxy-location-select",{detail:e,bubbles:true,composed:true}))}render(){return xt.html`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){return this.refusal?xt.html`<div class="roxy-error" role="alert">${this.t(this.refusal.message)}</div>`:xt.html`<div class="field"><input part="input" type="text" role="combobox" aria-expanded="${this.isOpen?"true":"false"}" aria-controls="roxy-location-listbox" aria-activedescendant="${this.isOpen&&this.highlight>=0?`roxy-location-option-${this.highlight}`:""}" aria-autocomplete="list" autocomplete="off" placeholder="${this.t(this.placeholder)}" .value="${this.query}" @input="${this.onInput}" @keydown="${this.onKeyDown}" @focus="${()=>{this.results.length>0&&(this.isOpen=true)}}"> ${this.isLoading?xt.html`<span class="spinner" role="status" aria-label="${this.t("Loading")}"></span>`:xt.nothing} ${this.isOpen?xt.html`<ul id="roxy-location-listbox" part="results" class="results" role="listbox">${this.results.length===0?xt.html`<li class="empty" role="status">${this.t("No cities found")}</li>`:this.results.map((e,t)=>xt.html`<li role="presentation"><button type="button" part="option" class="option" role="option" id="${`roxy-location-option-${t}`}" aria-selected="${this.highlight===t?"true":"false"}" @click="${()=>this.select(e)}" @mouseenter="${()=>{this.highlight=t}}"><span class="city">${e.city}</span> <span class="where">${e.province?xt.html`${e.province},`:""}${e.country}</span> <span class="tz">UTC${e.utcOffset>=0?"+":""}${e.utcOffset}</span></button></li>`)}</ul>`:xt.nothing}</div>${this.error?xt.html`<p class="search-error" role="alert">${this.t(this.error)}</p>`:xt.nothing}`}};Ye.styles=[u,Yn,xt.css`:host{display:block;position:relative}.field{position:relative}input{inline-size:100%;min-block-size:var(--roxy-touch)}.option .city{font-weight:var(--roxy-weight-bold)}.option .where{color:var(--roxy-muted);flex-grow:1}.option .tz{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.search-error{margin:var(--roxy-space-xs) 0 0;color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm)}`],m([(0,bt.property)({type:String,attribute:"api-key"})],Ye.prototype,"apiKey",2),m([(0,bt.property)({type:String,attribute:"publishable-key"})],Ye.prototype,"publishableKey",2),m([(0,bt.property)({type:String})],Ye.prototype,"endpoint",2),m([(0,bt.property)({type:String,attribute:"submit-url"})],Ye.prototype,"submitUrl",2),m([(0,bt.property)({attribute:"submit-context",converter:pn})],Ye.prototype,"submitContext",2),m([(0,bt.property)({type:String})],Ye.prototype,"placeholder",2),m([(0,bt.property)({type:String,attribute:"default-value"})],Ye.prototype,"defaultValue",2),m([(0,bt.state)()],Ye.prototype,"query",2),m([(0,bt.state)()],Ye.prototype,"results",2),m([(0,bt.state)()],Ye.prototype,"isOpen",2),m([(0,bt.state)()],Ye.prototype,"isLoading",2),m([(0,bt.state)()],Ye.prototype,"highlight",2),m([(0,bt.state)()],Ye.prototype,"refusal",2),m([(0,bt.state)()],Ye.prototype,"error",2),Ye=m([f("roxy-location-search")],Ye);var Fe=require("lit");var Jp={forward:"Forward",reverse:"Backward"},Br=class extends g{renderData(a){let e=this.effectiveLang();return Fe.html`<article class="card" part="card" aria-labelledby="luck-title"><header class="head" part="header"><h2 class="title" id="luck-title">${this.t("Luck pillars")}</h2></header><div class="facts" part="details">${a.direction?Fe.html`<span><span class="roxy-label">${this.t("Direction")}</span><b>${Jp[a.direction]?this.t(Jp[a.direction]):a.direction}</b></span>`:Fe.nothing} ${typeof a.startAge=="number"?Fe.html`<span><span class="roxy-label">${this.t("Starts")}</span><b>${this.ageLabel(e,a.startAge,a.startAgeMonths)}</b></span>`:Fe.nothing} ${a.boundaryTerm?Fe.html`<span><span class="roxy-label">${this.t("Counted to")}</span>${ie(e,"boundaryTerm",a.boundaryTerm)}</span>`:Fe.nothing} ${typeof a.daysToTerm=="number"?Fe.html`<span><span class="roxy-label">${this.t("Days")}</span>${U(e,a.daysToTerm)}</span>`:Fe.nothing} ${a.gender?Fe.html`<span><span class="roxy-label">${this.t("Formula")}</span>${ie(e,"gender",a.gender)}</span>`:Fe.nothing}</div>${this.renderStrip(a,e)} ${this.renderAnnuals(a)} ${a.summary&&!this.hideReadings?Fe.html`<p class="summary" part="section summary">${a.summary}</p>`:Fe.nothing} ${tr(a.conventions,this.translator,this.effectiveLang())}</article>`}ageLabel(a,e,t){let r=U(a,e);return typeof t=="number"&&t>0?this.t("{{years}}y {{months}}m",{years:r,months:U(a,t)}):this.t("{{years}} yrs",{years:r})}renderStrip(a,e){let t=a.luckPillars??[];return t.length===0?Fe.nothing:Fe.html`<div class="strip-wrap" part="chart" role="region" tabindex="0" aria-label="${this.t("Luck pillars")}"><div class="strip">${t.map(r=>Fe.html`<div class="pillar" part="pillar"><span class="ages roxy-label">${this.t("{{start}} to {{end}}",{start:U(e,r.startAge??0),end:U(e,r.endAge??0)})}</span> <span class="god">${y(r.tenGod,"name")}</span> <span class="hanzi" lang="zh">${r.stem?.chinese??""}</span> <span class="romanised">${r.stem?.pinyin??""} <span class="element-word ${Et(r.stem?.element)}">${y(r.stem,"element")}</span></span> <span class="hanzi hanzi-branch" lang="zh">${r.branch?.chinese??""}</span> <span class="romanised">${r.branch?.pinyin??""} ${y(r.branch,"animal")}</span> <span class="years">${this.t("{{start}} to {{end}}",{start:String(r.startYear??""),end:String(r.endYear??"")})}</span></div>`)}</div></div>`}renderAnnuals(a){let e=a.annualPillars??[];return e.length===0?Fe.nothing:Fe.html`<section part="section annual-pillars"><h3 class="block-title">${this.t("Annual pillars")}</h3><ul class="roxy-chips annuals">${e.map(t=>Fe.html`<li class="annual"><span class="yr">${t.year??""}</span> <span lang="zh">${t.tenGod?.chinese??""}</span> <span>${y(t.tenGod,"name")}</span></li>`)}</ul></section>`}};Br.endpoints=Il,Br.styles=[u,ae,la,Fe.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.strip-wrap{min-width:0;overflow-x:auto}.strip{min-width:min-content;display:flex}.pillar{gap:calc(var(--roxy-space-unit) / 2);min-inline-size:12ch;padding:var(--roxy-space-sm);text-align:center;flex:none;align-content:start;display:grid}.pillar+.pillar{border-inline-start:1px solid var(--roxy-border)}.ages,.years{font-variant-numeric:tabular-nums}.ages{font-weight:var(--roxy-weight-bold)}.god{min-block-size:1lh;color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.hanzi{font-size:calc(var(--roxy-text-base) * 1.75);line-height:var(--roxy-leading-tight)}.hanzi-branch{color:var(--roxy-accent-ink)}.romanised,.years{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.annual .yr{font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.summary{margin:0}`],Br=m([f("roxy-luck-pillars")],Br);var O=require("lit"),eh=require("lit/decorators.js");var tu={gentle:"Gentle",indifferent:"Indifferent",violent:"Violent"},au={center:"Center",conception:"Conception arm",destiny:"Destiny arm",left:"Left arm",right:"Right arm"},ru=13;function Qp(n){return"tzolkin"in n}var Ia=class extends g{constructor(){super(...arguments);this.mode="day"}renderData(e){let t=this.effectiveLang(),r=this.mode==="chart"&&Qp(e)?e:void 0,s=Qp(e)?e.tzolkin:e,i=s?.reading,o=i?.numberBand?tu[i.numberBand]:void 0;return O.html`<article class="card" part="card" aria-labelledby="mayan-title"><header class="hero" part="header">${typeof s?.number=="number"?O.html`<div class="coefficient">${U(t,s.number)}</div>`:O.nothing}<div><p class="roxy-label">${this.t("Mayan day sign")}</p><h2 class="title" id="mayan-title">${s?.daySignName??""}</h2><p class="spellings">${s?.daySignClassic?O.html`<span><span class="roxy-label">${this.t("Classic spelling")}</span>${s.daySignClassic}</span>`:O.nothing} ${s?.daySignKiche?O.html`<span><span class="roxy-label">${this.t("Highland spelling")}</span>${s.daySignKiche}</span>`:O.nothing}</p></div></header><div class="facts" part="details">${e.date?O.html`<span><span class="roxy-label">${this.t("Date")}</span><b>${M(t,e.date)}</b></span>`:O.nothing} ${this.renderTrecena(t,s?.trecena)} ${r?this.renderHaabFact(t,r.haab):O.nothing} ${r?.longCount?.formatted?O.html`<span><span class="roxy-label">${this.t("Long Count")}</span><b>${r.longCount.formatted}</b></span>`:O.nothing} ${r?.calendarRound?O.html`<span><span class="roxy-label">${this.t("Calendar Round")}</span><b>${r.calendarRound}</b></span>`:O.nothing} ${r?.yearBearer?.daySignName?O.html`<span><span class="roxy-label">${this.t("Year Bearer")}</span><b>${U(t,r.yearBearer.number)} ${r.yearBearer.daySignName}</b></span>`:O.nothing} ${r?.lordOfNight?.label?O.html`<span><span class="roxy-label">${this.t("Lord of the Night")}</span><b>${r.lordOfNight.label}</b></span>`:O.nothing} ${o?O.html`<span><span class="roxy-label">${this.t("Character of the number")}</span><b class="band">${this.t(o)}</b></span>`:O.nothing} ${e.conventions?.correlation?O.html`<span><span class="roxy-label">${this.t("Correlation")}</span><span title="${e.conventions.correlation}">${ie(t,"correlation",e.conventions.correlation,e.conventions.correlation)}</span></span>`:O.nothing}</div>${i?.keynote&&!this.hideReadings?O.html`<p class="keynote" part="reading">${i.keynote}</p>`:O.nothing} ${this.renderLists(i)} ${this.renderInterpretation(this.sections(r,i),"mayan-day")} ${this.renderCross(t,r?.cross)} ${r?.summary&&!this.hideReadings?O.html`<p class="summary" part="reading">${r.summary}</p>`:O.nothing}</article>`}renderTrecena(e,t){return t?O.html`<span><span class="roxy-label">${this.t("Trecena")}</span><b>${U(e,t.number)}</b> ${typeof t.dayOfTrecena=="number"?this.t("Day {{n}} of {{total}}",{n:U(e,t.dayOfTrecena),total:U(e,ru)}):O.nothing} ${t.rulingSignName?O.html`· <span class="roxy-label">${this.t("Ruling sign")}</span>${t.rulingSignName}`:O.nothing}</span>`:O.nothing}renderHaabFact(e,t){return t?.monthName?O.html`<span><span class="roxy-label">${this.t("Haab")}</span><b>${U(e,t.day)} ${t.monthName}</b> ${t.monthClassic?O.html`(${t.monthClassic})`:O.nothing} ${typeof t.dayOfYear=="number"?O.html`· <span class="roxy-label">${this.t("Day of year")}</span>${U(e,t.dayOfYear)}`:O.nothing}</span>`:O.nothing}renderLists(e){let t=e?.strengths??[],r=e?.challenges??[];return this.hideReadings||t.length===0&&r.length===0?O.nothing:O.html`<div class="lists" part="section readings">${t.length>0?O.html`<div><h3 class="block-title">${this.t("Strengths")}</h3><ul class="plain">${t.map(s=>O.html`<li>${s}</li>`)}</ul></div>`:O.nothing} ${r.length>0?O.html`<div><h3 class="block-title">${this.t("Challenges")}</h3><ul class="plain">${r.map(s=>O.html`<li>${s}</li>`)}</ul></div>`:O.nothing}</div>`}sections(e,t){let r=[];return t?.numberReading&&r.push({label:this.t("Coefficient"),body:t.numberReading}),t?.guidance&&r.push({label:this.t("Guidance"),body:t.guidance}),e?.haab?.reading&&r.push({label:this.t("Haab"),body:e.haab.reading}),e?.lordOfNight?.reading&&r.push({label:this.t("Lord of the Night"),body:e.lordOfNight.reading}),e?.yearBearer?.reading&&r.push({label:this.t("Year Bearer"),body:e.yearBearer.reading}),r}crossLabel(e){let t=au[e??""];return t?this.t(t):D(e??"")}renderCross(e,t){let r=t??[];return r.length===0?O.nothing:O.html`<section part="section cross"><h3 class="block-title">${this.t("Mayan cross")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Mayan cross")}"><table class="stacked"><thead><tr><th>${this.t("Position")}</th><th>${this.t("Offset in days")}</th><th>${this.t("Day sign")}</th></tr></thead><tbody>${r.map(s=>O.html`<tr><td data-label="${this.t("Position")}">${this.crossLabel(s.position)}</td><td class="num" data-label="${this.t("Offset in days")}">${U(e,s.offsetDays)}</td><td data-label="${this.t("Day sign")}">${U(e,s.number)} ${s.daySignName??""} ${s.daySignKiche?O.html`(${s.daySignKiche})`:O.nothing} ${s.reading&&!this.hideReadings?O.html`<p part="reading">${s.reading}</p>`:O.nothing}</td></tr>`)}</tbody></table></div></section>`}};Ia.endpoints=Gl,Ia.styles=[u,me,ia,O.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.coefficient{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * 2.75);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.coefficient){min-width:0}.title,.block-title,p.roxy-label{margin:0}.title{font-size:var(--roxy-text-xl)}.block-title{margin-block-end:var(--roxy-space-sm)}.spellings{gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}span>.roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.keynote,.summary{margin:0;padding-block-start:var(--roxy-space-md)}.summary{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}ul.plain{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-lg)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td.num{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}`],m([(0,eh.property)({type:String,reflect:true})],Ia.prototype,"mode",2),Ia=m([f("roxy-mayan-day-sign")],Ia);var Be=require("lit"),ah=require("lit/decorators.js");var Ga=class extends g{constructor(){super(...arguments);this.mode="current"}renderData(e){let t="phases"in e?e.phases:"calendar"in e?e.calendar:[];if(this.mode!=="current"&&t.length>0){let r=ws(this.effectiveLang(),"year"in e?e.year:void 0,"month"in e?e.month:void 0);return Be.html`<article class="card" part="card" aria-label="${this.t("Moon phase calendar")}"><h2 class="label" part="header">${r||this.t("Moon phase calendar")}</h2><div part="table" role="list">${t.map(s=>this.renderListItem(s))}</div></article>`}return"phase"in e?this.renderSingle(e):Be.nothing}renderSingle(e){let t=e.meaning?.symbol||th(e.phase);return Be.html`<article class="card" part="card" aria-label="${this.t("Current moon phase")}"><div class="hero" part="header"><span class="emoji" aria-hidden="true">${t}</span><div><h2 class="label">${e.phase??this.t("Current moon phase")}</h2>${e.date?Be.html`<p class="roxy-label">${M(this.effectiveLang(),e.date)}</p>`:Be.nothing}</div></div><div class="stats" part="details">${typeof e.illumination=="number"?Be.html`<div><span class="roxy-label">${this.t("Illumination")}</span> <strong>${Oe(this.effectiveLang(),e.illumination,0)}</strong></div>`:Be.nothing} ${typeof e.age=="number"?Be.html`<div><span class="roxy-label">${this.t("Age")}</span> <strong>${this.t("{{count}} days",{count:b(this.effectiveLang(),e.age,1)})}</strong></div>`:Be.nothing} ${e.sign?Be.html`<div><span class="roxy-label">${this.t("Sign")}</span> <strong>${e.sign}</strong></div>`:Be.nothing} ${typeof e.distance=="number"?Be.html`<div><span class="roxy-label">${this.t("Distance")}</span> <strong>${this.t("{{value}}k km",{value:b(this.effectiveLang(),e.distance/1e3,0)})}</strong></div>`:Be.nothing}</div>${e.meaning?.description&&!this.hideReadings?Be.html`<p>${e.meaning.description}</p>`:Be.nothing} ${e.meaning?.keywords?.length&&!this.hideReadings?Be.html`<ul class="roxy-chips">${e.meaning.keywords.map(r=>Be.html`<li>${r}</li>`)}</ul>`:Be.nothing}</article>`}renderListItem(e){let t=th(e.phase);return Be.html`<div class="list-item" role="listitem"><span aria-hidden="true">${t}</span> <span>${e.phase}</span> <span>${M(this.effectiveLang(),e.date)}</span></div>`}};Ga.endpoints=Fl,Ga.styles=[u,Be.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.emoji{font-size:calc(var(--roxy-text-xl) * 2);line-height:1}.label{text-transform:capitalize}.stats{gap:var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:repeat(auto-fit,minmax(min(100%,14ch),1fr));display:grid}.stats .roxy-label{display:block}.stats strong{font-variant-numeric:tabular-nums}.list-item{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);grid-template-columns:auto minmax(0,1fr) auto;display:grid}.list-item:last-child{border-block-end:0}`],m([(0,ah.property)({type:String,reflect:true})],Ga.prototype,"mode",2),Ga=m([f("roxy-moon-phase")],Ga);function th(n){return Qc(n)??"\u{1F319}"}var Ne=require("lit");var Hr=class extends g{renderData(a){let e=a.remedies;return Ne.html`<article class="wrap" part="card" aria-label="${this.t("Nakshatra {{name}}",{name:a.name})}"><header class="head" part="header"><h2>${a.name}</h2>${typeof a.number=="number"?Ne.html`<span class="number">${this.t("Nakshatra {{number}} of 27",{number:a.number})}</span>`:Ne.nothing} ${a.range?Ne.html`<span class="range">${a.range}</span>`:Ne.nothing}</header><dl class="roxy-facts" part="details">${a.lord?Ne.html`<div><dt>${this.t("Lord")}</dt><dd>${a.lord}</dd></div>`:Ne.nothing} ${a.deity?Ne.html`<div><dt>${this.t("Deity")}</dt><dd>${a.deity}</dd></div>`:Ne.nothing} ${a.symbol?Ne.html`<div><dt>${this.t("Symbol")}</dt><dd>${a.symbol}</dd></div>`:Ne.nothing}</dl>${a.characteristics&&!this.hideReadings?Ne.html`<div class="section" part="section characteristics"><h3>${this.t("Characteristics")}</h3><p>${a.characteristics}</p></div>`:Ne.nothing} ${e&&!this.hideReadings?Ne.html`<div class="section" part="section remedies"><h3>${this.t("Remedies")}</h3><div class="remedies">${e.mantras?Ne.html`<div class="remedy"><strong>${this.t("Mantras:")}</strong> ${e.mantras}</div>`:Ne.nothing} ${e.gemstones?Ne.html`<div class="remedy"><strong>${this.t("Gemstones:")}</strong> ${e.gemstones}</div>`:Ne.nothing} ${e.rituals?Ne.html`<div class="remedy"><strong>${this.t("Rituals:")}</strong> ${e.rituals}</div>`:Ne.nothing}</div></div>`:Ne.nothing}</article>`}};Hr.endpoints=Bl,Hr.styles=[u,Se,Ne.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.number{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.range{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.roxy-facts{margin:0}.section h3{margin-block-end:var(--roxy-space-xs)}.section p,.remedy{font-size:var(--roxy-text-sm)}.remedies{gap:var(--roxy-space-xs);display:grid}.remedy strong{color:var(--roxy-secondary)}`],Hr=m([f("roxy-nakshatra-card")],Hr);var R=require("lit");var Re=require("lit");var jr=class extends g{rows(){let a=this.data;if(!a)return[];let e=(a.planets??[]).map(r=>({name:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),longitude:r.longitude,latitude:r.latitude,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,dignity:r.dignity})),t=[["Ascendant",a.ascendant],["Midheaven",a.midheaven],["Part of Fortune",a.partOfFortune],["Vertex",a.vertex]];for(let[r,s]of t)s&&e.push({name:r,label:this.t(r),sign:s.sign,signLabel:y(s,"sign"),longitude:s.longitude,house:"house"in s?s.house:void 0,sect:"sect"in s?s.sect:void 0,isPoint:true});return e}renderData(a){if(!a.planets)return this.renderEmpty();let e=this.rows(),t=a.birthDetails,r=e.some(o=>Number.isFinite(o.latitude)),s=e.some(o=>o.sect),i=["latitude","longitude","timezone"];return Re.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Planetary positions")}</h2>${t?Re.html`<div part="details"><p class="roxy-label">${ue(this.effectiveLang(),t.date,t.time,true)}</p><dl class="roxy-facts">${i.map(o=>Re.html`<div><dt>${ke(this.effectiveLang(),o)}</dt><dd>${b(this.effectiveLang(),t[o],5)}</dd></div>`)}</dl></div>`:Re.nothing}</header><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Western planetary positions")}"><table part="table"><caption class="roxy-sr-only">${this.t("Western planetary positions: each body with its sign, degree, house, essential dignity and motion. The dignity cell is blank for the lunar nodes, Chiron and Lilith, which rule no sign and therefore hold no dignity at all.")}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th>${r?Re.html`<th scope="col">${ke(this.effectiveLang(),"latitude")}</th>`:Re.nothing}<th scope="col">${this.t("House")}</th><th scope="col">${this.t("Dignity")}</th><th scope="col">${this.t("Motion")}</th>${s?Re.html`<th scope="col">${this.t("Sect")}</th>`:Re.nothing}</tr></thead><tbody>${e.map(o=>{let l=S(o.name)??"",c=o.sect==="day"?this.t("Daytime"):o.sect==="night"?this.t("Night"):"",d=Z(o.sign)??"",p=typeof o.speed=="number"?b(this.effectiveLang(),o.speed,6):"";return Re.html`<tr class="${o.isPoint?"point":""}"><td class="body">${l?Re.html`<span class="glyph">${l}</span>`:Re.nothing}${o.label}</td><td>${d?Re.html`<span class="glyph">${d}</span>`:Re.nothing}${o.signLabel??""}</td><td>${typeof o.longitude=="number"?lt(o.longitude,o.signLabel):""}</td><td>${typeof o.longitude=="number"?`${b(this.effectiveLang(),o.longitude,5)}\xB0`:Re.nothing}</td>${r?Re.html`<td>${typeof o.latitude=="number"?`${b(this.effectiveLang(),o.latitude,5)}\xB0`:Re.nothing}</td>`:Re.nothing}<td>${typeof o.house=="number"?o.house:""}</td><td class="dignity">${o.dignity?V(o.dignity):""}</td><td>${p?Re.html`${p}${this.t("\xB0/day")}`:Re.nothing} ${o.isRetrograde?Re.html`<span class="retro">℞</span>`:Re.nothing}</td>${s?Re.html`<td>${c}</td>`:Re.nothing}</tr>`})}</tbody></table></div>${a.houses?.length?Re.html`<details part="section houses"><summary>${this.t("Houses")}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Houses")}"><table part="table"><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th></tr></thead><tbody>${a.houses.map(o=>Re.html`<tr><th scope="row">${b(this.effectiveLang(),o.number,0)}</th><td>${y(o,"sign")}</td><td>${lt(o.longitude,y(o,"sign"))}</td><td>${b(this.effectiveLang(),o.longitude,5)}°</td></tr>`)}</tbody></table></div></details>`:Re.nothing}</div>`}};jr.endpoints=cc,jr.styles=[u,Se,Re.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}h2{overflow-wrap:anywhere}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){white-space:nowrap}tr:not(.point)+tr.point>*{border-block-start:1px solid var(--roxy-secondary)}td.body{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}details>summary{font-weight:var(--roxy-weight-bold)}details>.scroll{margin-block-start:var(--roxy-space-sm)}`],jr=m([f("roxy-western-planets-table")],jr);var li=require("lit/decorators.js"),Ao=require("lit/directives/if-defined.js"),nh=require("lit/directives/unsafe-html.js");var Co=540,X=Co/2,Ms=220,Eo=202,qs=174,Us=144,su=232,To=249,Ys={glyph:14,degree:7},nu=.95,iu=28,ou=13,oi=84;function Do(n){return(n.houses??[]).length===12}function lu(n){let a=n.midheaven?.longitude;return typeof a=="number"?a:null}function jt(n,a){return 180+n.ascendant-a}function rh(n,a={}){let e={data:n,t:dr(a.lang),locale:a.lang,size:a.typeSize??Ys,ascendant:n.ascendant?.longitude??0,hasCusps:Do(n)},t=n.planets??[];return T`<svg class="natal-wheel" xmlns=${cr} viewBox=${`0 0 ${Co} ${Co}`} part="chart" role="img" aria-label=${e.hasCusps?e.t("Natal chart wheel with twelve houses, planets, and aspects"):e.t("Natal chart wheel with planets and aspects, houses shown as equal sectors from the Ascendant")}><title>${e.t("Natal chart wheel")}</title><desc>${e.t("Twelve zodiac sign segments around a circular wheel. Planet glyphs are placed at their ecliptic longitudes. Aspect lines connect related planets.")}</desc>
|
|
105
|
-
<circle class="wheel-line" cx=${
|
|
106
|
-
<circle class="wheel-line" cx=${
|
|
107
|
-
<circle class="wheel-line" cx=${
|
|
108
|
-
<circle class="wheel-line" cx=${
|
|
109
|
-
${
|
|
110
|
-
${
|
|
111
|
-
${
|
|
112
|
-
${
|
|
113
|
-
</svg>`.markup}function
|
|
100
|
+
<line class="cardinal-axis" x1=${n.x} y1=${n.y} x2=${i.x} y2=${i.y} />
|
|
101
|
+
${e}${o}`}renderSpokes(e){let t=e.map((n,i)=>({b:n,i})),r=Bt(Iu*Bu,Rh);return Yt(t,({b:n})=>n.azimuth,r).map(({item:n,displayLongitude:i})=>{let{b:o,i:l}=n,c=ms(o.planet,l),d=o.aboveHorizon===false,h=Ha(o.azimuth,Ou),p=Ha(i,Rh),f=S(o.planet)??y(o,"planet"),L=`${o.altitude>0?"+":""}${Math.round(o.altitude)}\xB0`;return ht.svg`<g>
|
|
102
|
+
<line class=${`spoke${d?" below":""}`} stroke=${c} x1=${Qt} y1=${Qt} x2=${h.x} y2=${h.y}><title>${this.t("{{planet}} {{direction}} {{azimuth}}\xB0 altitude {{altitude}}",{planet:y(o,"planet"),direction:o.compassDirection,azimuth:Math.round(o.azimuth),altitude:L})}</title></line>
|
|
103
|
+
<text class=${`body-glyph roxy-glyph${d?" below":""}`} fill=${c} x=${p.x} y=${p.y} text-anchor="middle" dominant-baseline="central">${f}</text>
|
|
104
|
+
</g>`})}renderList(e){if(e.length===0)return ht.nothing;let t=this.t("Local space directions: each body with its compass direction, azimuth, altitude and whether it sits above or below the horizon.");return ht.html`<div class="scroll" part="table" tabindex="0" role="region" aria-label="${t}"><table><caption class="roxy-sr-only">${t}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Direction")}</th><th scope="col" class="num">${this.t("Azimuth")}</th><th scope="col" class="num">${this.t("Altitude")}</th><th scope="col">${this.t("Horizon")}</th></tr></thead><tbody>${e.map((r,n)=>{let i=ms(r.planet,n),o=r.aboveHorizon===false;return ht.html`<tr><td><span class="body-cell"><span class="body-dot" style="${`background: ${i}`}"></span> ${Je(S(r.planet))}${y(r,"planet")}</span></td><td>${r.compassDirection}</td><td class="num">${Math.round(r.azimuth)}°</td><td class="num">${r.altitude>0?"+":""}${Math.round(r.altitude)}°</td><td><span class="${`horizon ${o?"down":"up"}`}">${o?this.t("Below"):this.t("Above")}</span></td></tr>`})}</tbody></table></div>`}};Vr.endpoints=Wl,Vr.styles=[u,et,ht.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.wrap>*{min-width:0}h2,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,30rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.dial{fill:none;stroke:var(--roxy-border)}.dial-fill{fill:color-mix(in srgb, var(--roxy-border) 10%, transparent);stroke:var(--roxy-border);stroke-width:1px}.cardinal-axis{stroke:var(--roxy-border);stroke-width:.5px}.tick{stroke:var(--roxy-secondary);stroke-width:.6px;opacity:.5}.compass-label{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .5625);font-weight:var(--roxy-weight-bold)}.compass-label.cardinal,.center-dot{fill:var(--roxy-fg)}.spoke{stroke-width:1.4px}.spoke.below{stroke-dasharray:3 3;opacity:.4}.body-glyph{font-size:calc(var(--roxy-text-base) * .6875);font-weight:var(--roxy-weight-bold)}.body-glyph.below{opacity:.45}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td).num{text-align:end}.body-cell{align-items:center;gap:var(--roxy-space-xs);display:inline-flex}.body-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);flex-shrink:0}.horizon.up{color:var(--roxy-success-fg)}.horizon.down{color:var(--roxy-muted)}.summary{font-size:var(--roxy-text-sm)}`],Vr=m([x("roxy-local-space-compass")],Vr);var vt=require("lit"),Lt=require("lit/decorators.js");var We=class extends tr{constructor(){super(...arguments);this.placeholder="Search city";this.defaultValue="";this.query="";this.results=[];this.isOpen=false;this.isLoading=false;this.highlight=-1;this.error=null;this.debouncedFetch=ii(e=>{this.fetchResults(e)},300);this.onInput=e=>{let t=e.target.value;if(this.query=t,t.length<2){this.results=[],this.isOpen=false,this.highlight=-1,this.error=null;return}this.debouncedFetch(t)};this.onKeyDown=e=>{if(!this.isOpen||this.results.length===0){e.key==="ArrowDown"&&this.query.length>=2&&(this.fetchResults(this.query),e.preventDefault());return}if(e.key==="ArrowDown")e.preventDefault(),this.highlight=(this.highlight+1)%this.results.length;else if(e.key==="ArrowUp")e.preventDefault(),this.highlight=(this.highlight-1+this.results.length)%this.results.length;else if(e.key==="Enter"){e.preventDefault();let t=this.results[this.highlight]??this.results[0];t&&this.select(t)}else e.key==="Escape"&&(this.isOpen=false)}}connectedCallback(){super.connectedCallback(),this.query=this.defaultValue,this.clickOutsideHandler=e=>{e.composedPath().includes(this)||(this.isOpen=false)},document.addEventListener("mousedown",this.clickOutsideHandler)}willUpdate(e){if(e.has("publishableKey")||e.has("apiKey")){let t=is(this.publishableKey??this.apiKey);t&&!this.refusal&&Rs(this,t,{warn:true}),this.refusal=t}}disconnectedCallback(){super.disconnectedCallback(),this.clickOutsideHandler&&document.removeEventListener("mousedown",this.clickOutsideHandler),this.debouncedFetch.cancel(),this.abortController&&(this.abortController.abort(),this.abortController=void 0)}async fetchResults(e){if(this.refusal)return;this.abortController&&this.abortController.abort();let t=new AbortController;this.abortController=t,this.isLoading=true;try{let r=await this.search(e,t.signal);if(t.signal.aborted)return;this.error=null,this.results=r.cities??[],this.isOpen=true,this.highlight=this.results.length>0?0:-1}catch(r){if(r?.name==="AbortError")return;this.results=[],this.isOpen=false,this.highlight=-1,this.error=r instanceof Error?r.message:String(r)}finally{this.abortController===t&&(this.abortController=void 0),t.signal.aborted||(this.isLoading=false)}}async search(e,t){if(!this.endpoint&&this.submitUrl)return ar({submitUrl:this.submitUrl,submitContext:this.submitContext},{path:"/location/search",method:"GET",query:{q:e,limit:8}},t);let r=new URL(this.endpoint||`${Ts}/location/search`,document.baseURI);r.searchParams.set("q",e),r.searchParams.set("limit","8");let n={Accept:"application/json"};this.apiKey&&this.publishableKey&&console.warn("[roxy-location-search] both api-key and publishable-key set; using publishable-key. Remove api-key from your widget markup.");let i=this.publishableKey??this.apiKey;i&&(n["X-API-Key"]=i);let o=await fetch(r,{headers:n,signal:t});if(!o.ok)throw new Error(await Jc(o));return await o.json()}select(e){this.query=`${e.city}${e.province?`, ${e.province}`:""}, ${e.country}`,this.isOpen=false,this.results=[],this.dispatchEvent(new CustomEvent("roxy-location-select",{detail:e,bubbles:true,composed:true}))}render(){return vt.html`${this.renderFontStyle()}${this.renderBody()}`}renderBody(){return this.refusal?vt.html`<div class="roxy-error" role="alert">${this.t(this.refusal.message)}</div>`:vt.html`<div class="field"><input part="input" type="text" role="combobox" aria-expanded="${this.isOpen?"true":"false"}" aria-controls="roxy-location-listbox" aria-activedescendant="${this.isOpen&&this.highlight>=0?`roxy-location-option-${this.highlight}`:""}" aria-autocomplete="list" autocomplete="off" placeholder="${this.t(this.placeholder)}" .value="${this.query}" @input="${this.onInput}" @keydown="${this.onKeyDown}" @focus="${()=>{this.results.length>0&&(this.isOpen=true)}}"> ${this.isLoading?vt.html`<span class="spinner" role="status" aria-label="${this.t("Loading")}"></span>`:vt.nothing} ${this.isOpen?vt.html`<ul id="roxy-location-listbox" part="results" class="results" role="listbox">${this.results.length===0?vt.html`<li class="empty" role="status">${this.t("No cities found")}</li>`:this.results.map((e,t)=>vt.html`<li role="presentation"><button type="button" part="option" class="option" role="option" id="${`roxy-location-option-${t}`}" aria-selected="${this.highlight===t?"true":"false"}" @click="${()=>this.select(e)}" @mouseenter="${()=>{this.highlight=t}}"><span class="city">${e.city}</span> <span class="where">${e.province?vt.html`${e.province},`:""}${e.country}</span> <span class="tz">UTC${e.utcOffset>=0?"+":""}${e.utcOffset}</span></button></li>`)}</ul>`:vt.nothing}</div>${this.error?vt.html`<p class="search-error" role="alert">${this.t(this.error)}</p>`:vt.nothing}`}};We.styles=[u,ni,vt.css`:host{display:block;position:relative}.field{position:relative}input{inline-size:100%;min-block-size:var(--roxy-touch)}.option .city{font-weight:var(--roxy-weight-bold)}.option .where{color:var(--roxy-muted);flex-grow:1}.option .tz{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.search-error{margin:var(--roxy-space-xs) 0 0;color:var(--roxy-danger-fg);font-size:var(--roxy-text-sm)}`],m([(0,Lt.property)({type:String,attribute:"api-key"})],We.prototype,"apiKey",2),m([(0,Lt.property)({type:String,attribute:"publishable-key"})],We.prototype,"publishableKey",2),m([(0,Lt.property)({type:String})],We.prototype,"endpoint",2),m([(0,Lt.property)({type:String,attribute:"submit-url"})],We.prototype,"submitUrl",2),m([(0,Lt.property)({attribute:"submit-context",converter:vn})],We.prototype,"submitContext",2),m([(0,Lt.property)({type:String})],We.prototype,"placeholder",2),m([(0,Lt.property)({type:String,attribute:"default-value"})],We.prototype,"defaultValue",2),m([(0,Lt.state)()],We.prototype,"query",2),m([(0,Lt.state)()],We.prototype,"results",2),m([(0,Lt.state)()],We.prototype,"isOpen",2),m([(0,Lt.state)()],We.prototype,"isLoading",2),m([(0,Lt.state)()],We.prototype,"highlight",2),m([(0,Lt.state)()],We.prototype,"refusal",2),m([(0,Lt.state)()],We.prototype,"error",2),We=m([x("roxy-location-search")],We);var He=require("lit");var Ch={forward:"Forward",reverse:"Backward"},Ur=class extends g{renderData(a){let e=this.effectiveLang();return He.html`<article class="card" part="card" aria-labelledby="luck-title"><header class="head" part="header"><h2 class="title" id="luck-title">${this.t("Luck pillars")}</h2></header><div class="facts" part="details">${a.direction?He.html`<span><span class="roxy-label">${this.t("Direction")}</span><b>${Ch[a.direction]?this.t(Ch[a.direction]):a.direction}</b></span>`:He.nothing} ${typeof a.startAge=="number"?He.html`<span><span class="roxy-label">${this.t("Starts")}</span><b>${this.ageLabel(e,a.startAge,a.startAgeMonths)}</b></span>`:He.nothing} ${a.boundaryTerm?He.html`<span><span class="roxy-label">${this.t("Counted to")}</span>${ie(e,"boundaryTerm",a.boundaryTerm)}</span>`:He.nothing} ${typeof a.daysToTerm=="number"?He.html`<span><span class="roxy-label">${this.t("Days")}</span>${q(e,a.daysToTerm)}</span>`:He.nothing} ${a.gender?He.html`<span><span class="roxy-label">${this.t("Formula")}</span>${ie(e,"gender",a.gender)}</span>`:He.nothing}</div>${this.renderStrip(a,e)} ${this.renderAnnuals(a)} ${a.summary&&!this.hideReadings?He.html`<p class="summary" part="section summary">${a.summary}</p>`:He.nothing} ${lr(a.conventions,this.translator,this.effectiveLang())}</article>`}ageLabel(a,e,t){let r=q(a,e);return typeof t=="number"&&t>0?this.t("{{years}}y {{months}}m",{years:r,months:q(a,t)}):this.t("{{years}} yrs",{years:r})}renderStrip(a,e){let t=a.luckPillars??[];return t.length===0?He.nothing:He.html`<div class="strip-wrap" part="chart" role="region" tabindex="0" aria-label="${this.t("Luck pillars")}"><div class="strip">${t.map(r=>He.html`<div class="pillar" part="pillar"><span class="ages roxy-label">${this.t("{{start}} to {{end}}",{start:q(e,r.startAge??0),end:q(e,r.endAge??0)})}</span> <span class="god">${y(r.tenGod,"name")}</span> <span class="hanzi" lang="zh">${r.stem?.chinese??""}</span> <span class="romanised">${r.stem?.pinyin??""} <span class="element-word ${At(r.stem?.element)}">${y(r.stem,"element")}</span></span> <span class="hanzi hanzi-branch" lang="zh">${r.branch?.chinese??""}</span> <span class="romanised">${r.branch?.pinyin??""} ${y(r.branch,"animal")}</span> <span class="years">${this.t("{{start}} to {{end}}",{start:String(r.startYear??""),end:String(r.endYear??"")})}</span></div>`)}</div></div>`}renderAnnuals(a){let e=a.annualPillars??[];return e.length===0?He.nothing:He.html`<section part="section annual-pillars"><h3 class="block-title">${this.t("Annual pillars")}</h3><ul class="roxy-chips annuals">${e.map(t=>He.html`<li class="annual"><span class="yr">${t.year??""}</span> <span lang="zh">${t.tenGod?.chinese??""}</span> <span>${y(t.tenGod,"name")}</span></li>`)}</ul></section>`}};Ur.endpoints=Zl,Ur.styles=[u,re,ma,He.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.strip-wrap{min-width:0;overflow-x:auto}.strip{min-width:min-content;display:flex}.pillar{gap:calc(var(--roxy-space-unit) / 2);min-inline-size:12ch;padding:var(--roxy-space-sm);text-align:center;flex:none;align-content:start;display:grid}.pillar+.pillar{border-inline-start:1px solid var(--roxy-border)}.ages,.years{font-variant-numeric:tabular-nums}.ages{font-weight:var(--roxy-weight-bold)}.god{min-block-size:1lh;color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}.hanzi{font-size:calc(var(--roxy-text-base) * 1.75);line-height:var(--roxy-leading-tight)}.hanzi-branch{color:var(--roxy-accent-ink)}.romanised,.years{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.annual .yr{font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.summary{margin:0}`],Ur=m([x("roxy-luck-pillars")],Ur);var G=require("lit"),Eh=require("lit/decorators.js");var ju={gentle:"Gentle",indifferent:"Indifferent",violent:"Violent"},Ku={center:"Center",conception:"Conception arm",destiny:"Destiny arm",left:"Left arm",right:"Right arm"},Vu=13;function Th(s){return"tzolkin"in s}var ja=class extends g{constructor(){super(...arguments);this.mode="day"}renderData(e){let t=this.effectiveLang(),r=this.mode==="chart"&&Th(e)?e:void 0,n=Th(e)?e.tzolkin:e,i=n?.reading,o=i?.numberBand?ju[i.numberBand]:void 0;return G.html`<article class="card" part="card" aria-labelledby="mayan-title"><header class="hero" part="header">${typeof n?.number=="number"?G.html`<div class="coefficient">${q(t,n.number)}</div>`:G.nothing}<div><p class="roxy-label">${this.t("Mayan day sign")}</p><h2 class="title" id="mayan-title">${n?.daySignName??""}</h2><p class="spellings">${n?.daySignClassic?G.html`<span><span class="roxy-label">${this.t("Classic spelling")}</span>${n.daySignClassic}</span>`:G.nothing} ${n?.daySignKiche?G.html`<span><span class="roxy-label">${this.t("Highland spelling")}</span>${n.daySignKiche}</span>`:G.nothing}</p></div></header><div class="facts" part="details">${e.date?G.html`<span><span class="roxy-label">${this.t("Date")}</span><b>${M(t,e.date)}</b></span>`:G.nothing} ${this.renderTrecena(t,n?.trecena)} ${r?this.renderHaabFact(t,r.haab):G.nothing} ${r?.longCount?.formatted?G.html`<span><span class="roxy-label">${this.t("Long Count")}</span><b>${r.longCount.formatted}</b></span>`:G.nothing} ${r?.calendarRound?G.html`<span><span class="roxy-label">${this.t("Calendar Round")}</span><b>${r.calendarRound}</b></span>`:G.nothing} ${r?.yearBearer?.daySignName?G.html`<span><span class="roxy-label">${this.t("Year Bearer")}</span><b>${q(t,r.yearBearer.number)} ${r.yearBearer.daySignName}</b></span>`:G.nothing} ${r?.lordOfNight?.label?G.html`<span><span class="roxy-label">${this.t("Lord of the Night")}</span><b>${r.lordOfNight.label}</b></span>`:G.nothing} ${o?G.html`<span><span class="roxy-label">${this.t("Character of the number")}</span><b class="band">${this.t(o)}</b></span>`:G.nothing} ${e.conventions?.correlation?G.html`<span><span class="roxy-label">${this.t("Correlation")}</span><span title="${e.conventions.correlation}">${ie(t,"correlation",e.conventions.correlation,e.conventions.correlation)}</span></span>`:G.nothing}</div>${i?.keynote&&!this.hideReadings?G.html`<p class="keynote" part="reading">${i.keynote}</p>`:G.nothing} ${this.renderLists(i)} ${this.renderInterpretation(this.sections(r,i),"mayan-day")} ${this.renderCross(t,r?.cross)} ${r?.summary&&!this.hideReadings?G.html`<p class="summary" part="reading">${r.summary}</p>`:G.nothing}</article>`}renderTrecena(e,t){return t?G.html`<span><span class="roxy-label">${this.t("Trecena")}</span><b>${q(e,t.number)}</b> ${typeof t.dayOfTrecena=="number"?this.t("Day {{n}} of {{total}}",{n:q(e,t.dayOfTrecena),total:q(e,Vu)}):G.nothing} ${t.rulingSignName?G.html`· <span class="roxy-label">${this.t("Ruling sign")}</span>${t.rulingSignName}`:G.nothing}</span>`:G.nothing}renderHaabFact(e,t){return t?.monthName?G.html`<span><span class="roxy-label">${this.t("Haab")}</span><b>${q(e,t.day)} ${t.monthName}</b> ${t.monthClassic?G.html`(${t.monthClassic})`:G.nothing} ${typeof t.dayOfYear=="number"?G.html`· <span class="roxy-label">${this.t("Day of year")}</span>${q(e,t.dayOfYear)}`:G.nothing}</span>`:G.nothing}renderLists(e){let t=e?.strengths??[],r=e?.challenges??[];return this.hideReadings||t.length===0&&r.length===0?G.nothing:G.html`<div class="lists" part="section readings">${t.length>0?G.html`<div><h3 class="block-title">${this.t("Strengths")}</h3><ul class="plain">${t.map(n=>G.html`<li>${n}</li>`)}</ul></div>`:G.nothing} ${r.length>0?G.html`<div><h3 class="block-title">${this.t("Challenges")}</h3><ul class="plain">${r.map(n=>G.html`<li>${n}</li>`)}</ul></div>`:G.nothing}</div>`}sections(e,t){let r=[];return t?.numberReading&&r.push({label:this.t("Coefficient"),body:t.numberReading}),t?.guidance&&r.push({label:this.t("Guidance"),body:t.guidance}),e?.haab?.reading&&r.push({label:this.t("Haab"),body:e.haab.reading}),e?.lordOfNight?.reading&&r.push({label:this.t("Lord of the Night"),body:e.lordOfNight.reading}),e?.yearBearer?.reading&&r.push({label:this.t("Year Bearer"),body:e.yearBearer.reading}),r}crossLabel(e){let t=Ku[e??""];return t?this.t(t):D(e??"")}renderCross(e,t){let r=t??[];return r.length===0?G.nothing:G.html`<section part="section cross"><h3 class="block-title">${this.t("Mayan cross")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Mayan cross")}"><table class="stacked"><thead><tr><th>${this.t("Position")}</th><th>${this.t("Offset in days")}</th><th>${this.t("Day sign")}</th></tr></thead><tbody>${r.map(n=>G.html`<tr><td data-label="${this.t("Position")}">${this.crossLabel(n.position)}</td><td class="num" data-label="${this.t("Offset in days")}">${q(e,n.offsetDays)}</td><td data-label="${this.t("Day sign")}">${q(e,n.number)} ${n.daySignName??""} ${n.daySignKiche?G.html`(${n.daySignKiche})`:G.nothing} ${n.reading&&!this.hideReadings?G.html`<p part="reading">${n.reading}</p>`:G.nothing}</td></tr>`)}</tbody></table></div></section>`}};ja.endpoints=Xl,ja.styles=[u,me,pa,G.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.coefficient{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * 2.75);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;flex-shrink:0;line-height:1}.hero>div:not(.coefficient){min-width:0}.title,.block-title,p.roxy-label{margin:0}.title{font-size:var(--roxy-text-xl)}.block-title{margin-block-end:var(--roxy-space-sm)}.spellings{gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-md);margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}span>.roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.keynote,.summary{margin:0;padding-block-start:var(--roxy-space-md)}.summary{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}ul.plain{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-lg)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td.num{white-space:nowrap}td.num{font-variant-numeric:tabular-nums}td p{margin:calc(var(--roxy-space-unit) / 2) 0 0;color:var(--roxy-secondary);font-size:var(--roxy-text-xs);border-block-start:0}`],m([(0,Eh.property)({type:String,reflect:true})],ja.prototype,"mode",2),ja=m([x("roxy-mayan-day-sign")],ja);var ze=require("lit"),Dh=require("lit/decorators.js");var Uu=88,qu=28,Ka=class extends g{constructor(){super(...arguments);this.mode="current"}renderData(e){let t="phases"in e?e.phases:"calendar"in e?e.calendar:[];if(this.mode!=="current"&&t.length>0){let r=Es(this.effectiveLang(),"year"in e?e.year:void 0,"month"in e?e.month:void 0);return ze.html`<article class="card" part="card" aria-label="${this.t("Moon phase calendar")}"><h2 class="label" part="header">${r||this.t("Moon phase calendar")}</h2><div part="table" role="list">${t.map(n=>this.renderListItem(n))}</div></article>`}return"phase"in e?this.renderSingle(e):ze.nothing}renderSingle(e){let t=e.meaning?.energy,r=t==="waxing"||t==="waning"?t==="waxing":typeof e.age=="number"?e.age<Ps/2:Wi(e.date);return ze.html`<article class="card" part="card" aria-label="${this.t("Current moon phase")}"><div class="hero" part="header">${typeof e.illumination=="number"&&r!==void 0?ea(this,{illumination:e.illumination,waxing:r},Uu):ze.nothing}<div><h2 class="label">${e.phase??this.t("Current moon phase")}</h2>${e.date?ze.html`<p class="roxy-label">${M(this.effectiveLang(),e.date)}</p>`:ze.nothing}</div></div><div class="stats" part="details">${typeof e.illumination=="number"?ze.html`<div><span class="roxy-label">${this.t("Illumination")}</span> <strong>${Ne(this.effectiveLang(),e.illumination,0)}</strong></div>`:ze.nothing} ${typeof e.age=="number"?ze.html`<div><span class="roxy-label">${this.t("Age")}</span> <strong>${this.t("{{count}} days",{count:b(this.effectiveLang(),e.age,1)})}</strong></div>`:ze.nothing} ${e.sign?ze.html`<div><span class="roxy-label">${this.t("Sign")}</span> <strong>${e.sign}</strong></div>`:ze.nothing} ${typeof e.distance=="number"?ze.html`<div><span class="roxy-label">${this.t("Distance")}</span> <strong>${this.t("{{value}}k km",{value:b(this.effectiveLang(),e.distance/1e3,0)})}</strong></div>`:ze.nothing}</div>${e.meaning?.description&&!this.hideReadings?ze.html`<p>${e.meaning.description}</p>`:ze.nothing} ${e.meaning?.keywords?.length&&!this.hideReadings?ze.html`<ul class="roxy-chips">${e.meaning.keywords.map(n=>ze.html`<li>${n}</li>`)}</ul>`:ze.nothing}</article>`}renderListItem(e){let t=Wi(e.date),r="illumination"in e&&t!==void 0?{illumination:e.illumination,waxing:t}:yd(e.date);return ze.html`<div class="list-item" role="listitem">${r?ea(this,r,qu):ze.html`<span></span>`} <span>${e.phase}</span> <span>${M(this.effectiveLang(),e.date)}</span></div>`}};Ka.endpoints=Jl,Ka.styles=[u,sr,ze.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.label{text-transform:capitalize}.stats{gap:var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:repeat(auto-fit,minmax(min(100%,14ch),1fr));display:grid}.stats .roxy-label{display:block}.stats strong{font-variant-numeric:tabular-nums}.list-item{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);grid-template-columns:auto minmax(0,1fr) auto;display:grid}.list-item:last-child{border-block-end:0}`],m([(0,Dh.property)({type:String,reflect:true})],Ka.prototype,"mode",2),Ka=m([x("roxy-moon-phase")],Ka);var Oe=require("lit");var qr=class extends g{renderData(a){let e=a.remedies;return Oe.html`<article class="wrap" part="card" aria-label="${this.t("Nakshatra {{name}}",{name:a.name})}"><header class="head" part="header"><h2>${a.name}</h2>${typeof a.number=="number"?Oe.html`<span class="number">${this.t("Nakshatra {{number}} of 27",{number:a.number})}</span>`:Oe.nothing} ${a.range?Oe.html`<span class="range">${a.range}</span>`:Oe.nothing}</header><dl class="roxy-facts" part="details">${a.lord?Oe.html`<div><dt>${this.t("Lord")}</dt><dd>${a.lord}</dd></div>`:Oe.nothing} ${a.deity?Oe.html`<div><dt>${this.t("Deity")}</dt><dd>${a.deity}</dd></div>`:Oe.nothing} ${a.symbol?Oe.html`<div><dt>${this.t("Symbol")}</dt><dd>${a.symbol}</dd></div>`:Oe.nothing}</dl>${a.characteristics&&!this.hideReadings?Oe.html`<div class="section" part="section characteristics"><h3>${this.t("Characteristics")}</h3><p>${a.characteristics}</p></div>`:Oe.nothing} ${e&&!this.hideReadings?Oe.html`<div class="section" part="section remedies"><h3>${this.t("Remedies")}</h3><div class="remedies">${e.mantras?Oe.html`<div class="remedy"><strong>${this.t("Mantras:")}</strong> ${e.mantras}</div>`:Oe.nothing} ${e.gemstones?Oe.html`<div class="remedy"><strong>${this.t("Gemstones:")}</strong> ${e.gemstones}</div>`:Oe.nothing} ${e.rituals?Oe.html`<div class="remedy"><strong>${this.t("Rituals:")}</strong> ${e.rituals}</div>`:Oe.nothing}</div></div>`:Oe.nothing}</article>`}};qr.endpoints=Ql,qr.styles=[u,Re,Oe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.number{color:var(--roxy-accent-ink);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.range{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.roxy-facts{margin:0}.section h3{margin-block-end:var(--roxy-space-xs)}.section p,.remedy{font-size:var(--roxy-text-sm)}.remedies{gap:var(--roxy-space-xs);display:grid}.remedy strong{color:var(--roxy-secondary)}`],qr=m([x("roxy-nakshatra-card")],qr);var T=require("lit");var Ce=require("lit");var Yr=class extends g{rows(){let a=this.data;if(!a)return[];let e=(a.planets??[]).map(r=>({name:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),longitude:r.longitude,latitude:r.latitude,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,dignity:r.dignity})),t=[["Ascendant",a.ascendant],["Midheaven",a.midheaven],["Part of Fortune",a.partOfFortune],["Vertex",a.vertex]];for(let[r,n]of t)n&&e.push({name:r,label:this.t(r),sign:n.sign,signLabel:y(n,"sign"),longitude:n.longitude,house:"house"in n?n.house:void 0,sect:"sect"in n?n.sect:void 0,isPoint:true});return e}renderData(a){if(!a.planets)return this.renderEmpty();let e=this.rows(),t=a.birthDetails,r=e.some(o=>Number.isFinite(o.latitude)),n=e.some(o=>o.sect),i=["latitude","longitude","timezone"];return Ce.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Planetary positions")}</h2>${t?Ce.html`<div part="details"><p class="roxy-label">${fe(this.effectiveLang(),t.date,t.time,true)}</p><dl class="roxy-facts">${i.map(o=>Ce.html`<div><dt>${Se(this.effectiveLang(),o)}</dt><dd>${b(this.effectiveLang(),t[o],5)}</dd></div>`)}</dl></div>`:Ce.nothing}</header><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Western planetary positions")}"><table part="table"><caption class="roxy-sr-only">${this.t("Western planetary positions: each body with its sign, degree, house, essential dignity and motion. The dignity cell is blank for the lunar nodes, Chiron and Lilith, which rule no sign and therefore hold no dignity at all.")}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th>${r?Ce.html`<th scope="col">${Se(this.effectiveLang(),"latitude")}</th>`:Ce.nothing}<th scope="col">${this.t("House")}</th><th scope="col">${this.t("Dignity")}</th><th scope="col">${this.t("Motion")}</th>${n?Ce.html`<th scope="col">${this.t("Sect")}</th>`:Ce.nothing}</tr></thead><tbody>${e.map(o=>{let l=S(o.name)??"",c=o.sect==="day"?this.t("Daytime"):o.sect==="night"?this.t("Night"):"",d=J(o.sign)??"",h=typeof o.speed=="number"?b(this.effectiveLang(),o.speed,6):"";return Ce.html`<tr class="${o.isPoint?"point":""}"><td class="body">${l?Ce.html`<span class="glyph roxy-glyph">${l}</span>`:Ce.nothing}${o.label}</td><td>${d?Ce.html`<span class="glyph roxy-glyph">${d}</span>`:Ce.nothing}${o.signLabel??""}</td><td>${typeof o.longitude=="number"?pt(o.longitude,o.signLabel):""}</td><td>${typeof o.longitude=="number"?`${b(this.effectiveLang(),o.longitude,5)}\xB0`:Ce.nothing}</td>${r?Ce.html`<td>${typeof o.latitude=="number"?`${b(this.effectiveLang(),o.latitude,5)}\xB0`:Ce.nothing}</td>`:Ce.nothing}<td>${typeof o.house=="number"?o.house:""}</td><td class="dignity">${o.dignity?U(o.dignity):""}</td><td>${h?Ce.html`${h}${this.t("\xB0/day")}`:Ce.nothing} ${o.isRetrograde?Ce.html`<span class="retro roxy-glyph">${Ke}</span>`:Ce.nothing}</td>${n?Ce.html`<td>${c}</td>`:Ce.nothing}</tr>`})}</tbody></table></div>${a.houses?.length?Ce.html`<details part="section houses"><summary>${this.t("Houses")}</summary><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Houses")}"><table part="table"><thead><tr><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th></tr></thead><tbody>${a.houses.map(o=>Ce.html`<tr><th scope="row">${b(this.effectiveLang(),o.number,0)}</th><td>${y(o,"sign")}</td><td>${pt(o.longitude,y(o,"sign"))}</td><td>${b(this.effectiveLang(),o.longitude,5)}°</td></tr>`)}</tbody></table></div></details>`:Ce.nothing}</div>`}};Yr.endpoints=Lc,Yr.styles=[u,Re,Ce.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}h2{overflow-wrap:anywhere}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){white-space:nowrap}tr:not(.point)+tr.point>*{border-block-start:1px solid var(--roxy-secondary)}td.body{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}details>summary{font-weight:var(--roxy-weight-bold)}details>.scroll{margin-block-start:var(--roxy-space-sm)}`],Yr=m([x("roxy-western-planets-table")],Yr);var bi=require("lit/decorators.js"),jo=require("lit/directives/if-defined.js"),Mh=require("lit/directives/unsafe-html.js");var Io=540,Q=Io/2,Bs=220,Bo=202,an=174,tn=144,Yu=232,Fo=249,rn={glyph:14,degree:7},Wu=.95,Zu=28,Xu=13,xi=84;function Ho(s){return(s.houses??[]).length===12}function Ju(s){let a=s.midheaven?.longitude;return typeof a=="number"?a:null}function Vt(s,a){return 180+s.ascendant-a}function Ah(s,a={}){let e={data:s,t:da(a.lang),locale:a.lang,size:a.typeSize??rn,ascendant:s.ascendant?.longitude??0,hasCusps:Ho(s)},t=s.planets??[];return R`<svg class="natal-wheel" xmlns=${ca} viewBox=${`0 0 ${Io} ${Io}`} part="chart" role="img" aria-label=${e.hasCusps?e.t("Natal chart wheel with twelve houses, planets, and aspects"):e.t("Natal chart wheel with planets and aspects, houses shown as equal sectors from the Ascendant")}><title>${e.t("Natal chart wheel")}</title><desc>${e.t("Twelve zodiac sign segments around a circular wheel. Planet glyphs are placed at their ecliptic longitudes. Aspect lines connect related planets.")}</desc>
|
|
105
|
+
<circle class="wheel-line" cx=${Q} cy=${Q} r=${Bs} stroke-width="1.5" />
|
|
106
|
+
<circle class="wheel-line" cx=${Q} cy=${Q} r=${Bo-14} stroke-width="0.8" />
|
|
107
|
+
<circle class="wheel-line" cx=${Q} cy=${Q} r=${an} stroke-width="1" />
|
|
108
|
+
<circle class="wheel-line" cx=${Q} cy=${Q} r=${xi} stroke-width="0.5" />
|
|
109
|
+
${sf(e)} ${tf(e)} ${af(e)}
|
|
110
|
+
${rf(e)} ${nf(e)}
|
|
111
|
+
${lf(e,t,s.aspects??[])} ${of(e,t)}
|
|
112
|
+
${Qu(e)}
|
|
113
|
+
</svg>`.markup}function Qu(s){let a=s.ascendant,e=Ju(s.data),t=[{longitude:a,label:s.t("ASC")},{longitude:Ws(a),label:s.t("DSC")}];e!==null&&(t.push({longitude:e,label:s.t("MC")}),t.push({longitude:Ws(e),label:s.t("IC")}));let r=s.data?.partOfFortune?.longitude;typeof r=="number"&&t.push({longitude:It(r),label:s.t("PoF")});let n=s.data?.vertex?.longitude;return typeof n=="number"&&t.push({longitude:It(n),label:s.t("Vtx")}),Yt(t,i=>i.longitude,Bt(Zu,Fo)).map(({item:i,longitude:o,displayLongitude:l})=>ef(s,o,l,i.label))}function ef(s,a,e,t){let r=Vt(s,a),n=Vt(s,e),i=H(Q,Q,Bs,r),o=H(Q,Q,Yu,r),l=H(Q,Q,Fo,n),c=Math.abs(e-a)>.5,d=H(Q,Q,Fo-8,n);return R`
|
|
114
114
|
<g>
|
|
115
115
|
<line class="angle-tick" x1=${i.x} y1=${i.y} x2=${o.x} y2=${o.y} />
|
|
116
|
-
${c?
|
|
116
|
+
${c?R`<line class="angle-tick" x1=${o.x} y1=${o.y} x2=${d.x} y2=${d.y} />`:""}
|
|
117
117
|
<text class="angle-marker" x=${l.x} y=${l.y} text-anchor="middle" dominant-baseline="central">${t}</text>
|
|
118
118
|
</g>
|
|
119
|
-
`}function
|
|
120
|
-
${
|
|
121
|
-
<text class="planet-glyph" x=${
|
|
122
|
-
<text class="planet-deg" x=${
|
|
123
|
-
</g>`})}function fu(n,a,e){let t=new Map;for(let r of a){if(typeof r.longitude!="number")continue;let s=Rt(r.name);s&&t.set(s,r.longitude)}return e.filter(La).map(r=>{let s=t.get(Rt(r.planet1)),i=t.get(Rt(r.planet2));if(s===void 0||i===void 0)return"";let o=H(X,X,oi-2,jt(n,s)),l=H(X,X,oi-2,jt(n,i)),c=Tt(r),{locale:d}=n,p=b(d,r.orb,1);return T`<line class=${`aspect ${Ze(r)}`} style=${Ts(r)} x1=${o.x} y1=${o.y} x2=${l.x} y2=${l.y}><title>${y(r,"planet1")} ${y(r,"type",c)} ${y(r,"planet2")}${p?` (${n.t("Orb")} ${p}\xB0)`:""}</title></line>`})}var Kr=class{constructor(a,e){this.host=a,this.marks=e,this.size=Object.fromEntries(Object.keys(e).map(t=>[t,e[t][1]])),a.addController(this)}hostConnected(){typeof ResizeObserver>"u"||(this.observer=new ResizeObserver(()=>this.host.requestUpdate()),this.observer.observe(this.host))}hostDisconnected(){this.observer?.disconnect(),this.observer=void 0}hostUpdated(){let a=false;for(let e of Object.keys(this.marks)){let[t]=this.marks[e],r=xu(this.host.renderRoot,t,this.size[e]);r!==this.size[e]&&(this.size[e]=r,a=true)}a&&this.host.requestUpdate()}};function xu(n,a,e){let t=n?.querySelector(a);if(!t||typeof getComputedStyle!="function")return e;let r=Number.parseFloat(getComputedStyle(t).fontSize);return Number.isFinite(r)&&r>0?r:e}var sh={GRAND_CROSS:0,GRAND_TRINE:1,KITE:2,T_SQUARE:3,YOD:4,MYSTIC_RECTANGLE:5,STELLIUM:6},ya=class extends g{constructor(){super(...arguments);this.viewport=new je(this);this.heading="Natal chart";this.view="wheel";this.type=new Kr(this,{glyph:[".planet-glyph",Ys.glyph],degree:[".planet-deg",Ys.degree]})}getPlanets(){return this.data?.planets??[]}renderData(e){let t=this.getPlanets(),r=e.aspects??[],s=this.view;return R.html`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2>${e.birthDetails?R.html`<p class="roxy-label">${ue(this.effectiveLang(),e.birthDetails.date,e.birthDetails.time)}</p>`:R.nothing}</header>${r.length>0?R.html`${gt({items:[{id:"wheel",label:this.t("Wheel")},{id:"grid",label:this.t("Aspect grid")}],active:s,onSelect:i=>{this.view=i},label:this.t("Natal chart views"),idPrefix:"natal",controls:true})}<div id="natal-panel-${s}" part="panel" role="tabpanel" aria-labelledby="natal-tab-${s}">${s==="wheel"?this.renderWheel(e):this.renderAspectGrid(t,r)}</div>`:this.renderWheel(e)}<div class="legend" part="legend"><span>${this.t("{{label}}: {{value}}",{label:this.t("Positions"),value:b(this.effectiveLang(),t.length,0)})}</span> ${r.length>0?R.html`<span>${this.t("{{count}} aspects",{count:s==="grid"?r.length:r.filter(La).length})}</span>`:R.nothing} ${Do(e)&&e.houseSystem?R.html`<span>${this.t("{{label}}: {{value}}",{label:ke(this.effectiveLang(),"houseSystem"),value:ie(this.effectiveLang(),"houseSystem",e.houseSystem)})}</span>`:R.html`<span class="caveat">${this.t("Equal sectors from the Ascendant, no house cusps in this response")}</span>`} ${r.length>0?R.html`<span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span>`:R.nothing}</div>${this.renderPositionDetails(e)} ${this.renderDetails()} ${this.renderPatterns()} ${this.renderAspectDetails(r)} ${this.renderInterpretations()}</div>`}renderWheel(e){return this.viewport.renderChartViewport((0,nh.unsafeHTML)(rh(e,{lang:this.effectiveLang(),typeSize:this.type.size})),this.t(this.heading),this.translator)}renderAspectGrid(e,t){let r=e.map(o=>({name:o.name,label:y(o,"name")})),s=(o,l)=>[Rt(o),Rt(l)].sort().join("|"),i=new Map;for(let o of t)i.set(s(o.planet1,o.planet2),o);return r.length===0?R.html`<p class="roxy-empty" role="status">${this.t("No planets to grid")}</p>`:R.html`<div class="scroll" part="section aspects table aspect-grid" tabindex="0" role="region" aria-label="${this.t("Aspect grid")}"><table class="aspect-grid"><caption class="roxy-sr-only">${this.t("Planet by planet aspect grid: the aspect each pair of planets forms, read from the planet naming the row across to the planet naming the column.")}</caption><thead><tr><td></td>${r.slice(0,-1).map(o=>{let l=S(o.name)??o.label;return R.html`<th scope="col" title="${o.label}">${l}</th>`})}</tr></thead><tbody>${r.slice(1).map((o,l)=>{let c=S(o.name)??o.label;return R.html`<tr><th scope="row" title="${o.label}">${c}</th>${r.slice(0,l+1).map(d=>{let p=i.get(s(o.name,d.name));if(!p)return R.html`<td></td>`;let h=Tt(p),x=Cs(h)??y(p,"type",He(p)),$=b(this.effectiveLang(),p.orb,1);return R.html`<td class="${`cell ${Ze(p)}`}" title="${`${o.label} ${y(p,"type",h)} ${d.label}${$?` (${this.t("Orb")} ${$}\xB0)`:""}`}"><span class="asp">${x}</span></td>`})} ${r.slice(l+1,-1).map(()=>R.html`<td></td>`)}</tr>`})}</tbody></table></div>`}renderPositionDetails(e){return R.html`<details class="block" part="section positions"><summary>${this.t("Chart details")}</summary><roxy-western-planets-table bare lang="${(0,Ao.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${e}"></roxy-western-planets-table></details>`}renderDetails(){let e=this.data?.summary,t=this.data?.aspectsInterpretation;if(!e&&!t)return R.nothing;let r=xn(e,"retrogradePlanets");return R.html`<div class="facts" part="details">${e?.dominantElement||e?.dominantModality?R.html`<ul class="roxy-chips">${e.dominantElement?R.html`<li>${this.t("{{label}}: {{value}}",{label:this.t("Dominant element"),value:y(e,"dominantElement")})}</li>`:R.nothing} ${e.dominantModality?R.html`<li>${this.t("{{label}}: {{value}}",{label:this.t("Dominant modality"),value:y(e,"dominantModality")})}</li>`:R.nothing}</ul>`:R.nothing} ${t?R.html`<p class="counts"><span class="harmonious">${this.t("Harmonious: {{count}}",{count:t.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:t.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:t.neutral})}</span></p>`:R.nothing} ${r.length>0?R.html`<ul class="roxy-chips">${r.map(({value:s,label:i})=>{let o=S(s)??"";return R.html`<li>${o} ${i} ℞</li>`})}</ul>`:R.nothing} ${t?.summary&&!this.hideReadings?R.html`<p>${t.summary}</p>`:R.nothing} ${this.renderElementModalityGrid()}</div>`}renderElementModalityGrid(){let e=this.getPlanets();if(e.length===0)return R.nothing;let t=["Fire","Earth","Air","Water"],r=["Cardinal","Fixed","Mutable"],s={Fire:this.t("Fire"),Earth:this.t("Earth"),Air:this.t("Air"),Water:this.t("Water")},i={Cardinal:{abbr:this.t("Car"),full:this.t("Cardinal")},Fixed:{abbr:this.t("Fix"),full:this.t("Fixed")},Mutable:{abbr:this.t("Mut"),full:this.t("Mutable")}},o=Ie,l=this.data?.summary,c={};for(let $ of t)c[$]={Cardinal:[],Fixed:[],Mutable:[]};let d=0;for(let $ of e){let L=o.indexOf(V($.sign??""));if(L<0)continue;let C=t[L%4],ne=r[L%3],Ce=S($.name)??y($,"name");c[C]?.[ne]?.push(Ce),d++}if(d===0)return R.nothing;let p=$=>t.reduce((L,C)=>L+(c[C]?.[$]?.length??0),0),h=[...Object.entries(l?.elementDistribution??{}).map(([$,L])=>({label:s[V($)]??$,count:L})),...Object.entries(l?.modalityDistribution??{}).map(([$,L])=>({label:i[V($)]?.full??$,count:L}))],x=Object.values(l?.elementDistribution??{}).reduce(($,L)=>$+L,0);return R.html`${h.length?R.html`<section class="block distribution" part="section distribution"><h3>${this.t("Element and modality distribution")}</h3><p class="counts"><span class="roxy-label">${this.t("{{count}} planets",{count:x})}</span> ${h.map(({label:$,count:L})=>R.html`<span>${this.t("{{label}}: {{value}}",{label:$,value:b(this.effectiveLang(),L,0)})}</span>`)}</p></section>`:R.nothing}<div class="scroll" tabindex="0" role="region" aria-label="${this.t("Element and modality distribution")}"><table class="em-grid" part="table element-modality" aria-label="${this.t("Element and modality distribution")}"><caption class="roxy-label">${this.t("All {{count}} bodies in the chart, placed by sign",{count:d})}</caption><thead><tr><td></td>${r.map($=>R.html`<th scope="col" title="${i[$]?.full??$}">${i[$]?.abbr??$}</th>`)}<th scope="col">${this.t("Total")}</th></tr></thead><tbody>${t.map($=>{let L=r.reduce((C,ne)=>C+(c[$]?.[ne]?.length??0),0);return R.html`<tr><th scope="row">${s[$]??$}</th>${r.map(C=>R.html`<td>${(c[$]?.[C]??[]).join(" ")}</td>`)}<td class="em-total">${L}</td></tr>`})}<tr><th scope="row">${this.t("Total")}</th>${r.map($=>R.html`<td class="em-total">${p($)}</td>`)}<td class="em-total">${d}</td></tr></tbody></table></div>`}renderPatterns(){let e=this.data?.patterns??[];if(e.length===0)return R.nothing;let t=[...e].sort((r,s)=>(sh[r.kind]??9)-(sh[s.kind]??9)||(s.tightness??0)-(r.tightness??0));return R.html`<section class="block patterns" part="section patterns"><h3>${this.t("Chart patterns")}</h3>${t.map(r=>this.renderPattern(r))}</section>`}renderPattern(e){let t=e.planets??[],r=e.apex?[...t].sort((s,i)=>+(i===e.apex)-+(s===e.apex)):t;return R.html`<div class="pattern" part="pattern"><div class="pattern-head"><span class="pattern-name">${e.name}</span> ${e.element?R.html`<span class="roxy-chip">${e.element}</span>`:R.nothing} ${e.modality?R.html`<span class="roxy-chip">${e.modality}</span>`:R.nothing} ${e.dissociate?R.html`<span class="roxy-chip" title="${this.t("Out of sign: one or more planets sit outside the pattern element or modality, so the theme holds but runs weaker.")}">${this.t("Dissociate")}</span>`:R.nothing} ${typeof e.tightness=="number"?R.html`<span class="pattern-tight roxy-label">${this.t("{{percent}} tight",{percent:Oe(this.effectiveLang(),e.tightness,0)})}</span>`:R.nothing}</div><ul class="roxy-chips">${r.map(s=>{let i=S(s),o=!!e.apex&&s===e.apex;return R.html`<li class="${o?"roxy-chip apex":"roxy-chip"}">${i?R.html`<span aria-hidden="true">${i}</span>`:R.nothing}${s}${o?R.html`<span>${this.t("apex")}</span>`:R.nothing}</li>`})}</ul>${e.interpretation&&!this.hideReadings?R.html`<p class="pattern-interp">${e.interpretation}</p>`:R.nothing}</div>`}renderAspectDetails(e){return e.length===0?R.nothing:R.html`<details class="block" part="section aspects"><summary>${this.t("Aspects ({{count}})",{count:e.length})}</summary><roxy-aspects-table bare hide-sections="header" lang="${(0,Ao.ifDefined)(this.effectiveLang())}" ?hide-readings="${this.hideReadings}" exportparts="card, header, section, aspects, details, reading, readings, pattern, patterns, strongest" .data="${{aspects:e}}"></roxy-aspects-table></details>`}renderInterpretations(){let e=this.getPlanets().filter(t=>t.interpretation).map(t=>{let r=t.interpretation,s=S(t.name)??"",i=y(t,"name"),o=r.summary||r.detailed||"",l=r.summary?r.detailed:void 0;return{label:`${s} ${i}`.trim(),aside:`${y(t,"sign")} ${Vt(t.longitude)}`,body:o,extra:R.html`${l?R.html`<p>${l}</p>`:R.nothing} ${as(r.keywords)}`}});return this.renderInterpretation(e,"natal-planet-readings","Planet readings")}};ya.endpoints=Hl,ya.styles=[u,Xe,Es,ot,W,me,Nd,R.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}h2{overflow-wrap:anywhere}details.block>summary{font-weight:var(--roxy-weight-bold)}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,42.5rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.counts{font-size:var(--roxy-text-sm);color:var(--roxy-fg)}.legend .caveat{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.scroll{min-width:0;overflow-x:auto}.aspect-grid{margin:0 auto}.aspect-grid :is(th,td){inline-size:var(--roxy-space-lg);block-size:var(--roxy-space-lg);text-align:center;vertical-align:middle;border:1px solid var(--roxy-border);padding:0}.aspect-grid .asp{color:var(--_aspect-ink,var(--roxy-muted))}.facts,.distribution,.patterns{gap:var(--roxy-space-sm);display:grid}.em-grid{width:100%}.em-grid caption{caption-side:top;text-align:start}.em-grid :is(th,td){text-align:center}.em-grid th[scope=row]{text-align:start}.em-grid td{color:var(--roxy-accent-ink)}.em-grid .em-total{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.pattern{gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.pattern-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.pattern-name{font-weight:var(--roxy-weight-bold)}.pattern-tight{font-variant-numeric:tabular-nums;margin-inline-start:auto}.roxy-chip.apex{color:var(--roxy-fg);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.pattern-interp{font-size:var(--roxy-text-sm)}`],m([(0,li.property)({type:String})],ya.prototype,"heading",2),m([(0,li.state)()],ya.prototype,"view",2),ya=m([f("roxy-natal-chart")],ya);var v=require("lit"),oh=require("lit/decorators.js");var bu=new Set([11,22,33]),vu=[["career","Career"],["relationships","Relationships"],["spirituality","Spirituality"]],Fa=class extends g{constructor(){super(...arguments);this.type="life-path"}renderData(e){let t=this.t(Lu[this.type]??this.type);return"coreNumbers"in e?this.renderChart(e,t):"personalDay"in e?this.renderPersonalDay(e,t):"personalMonth"in e?this.renderPersonalMonth(e,t):"personalYear"in e?this.renderPersonalYear(e,t):"dailyMessage"in e?this.renderDailyNumber(e,t):this.renderNumberCard(e,t)}renderNumberCard(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.number,e.meaning?.title,ci(e.number,e.type))} ${e.meaning?.description&&r?v.html`<p>${e.meaning.description}</p>`:v.nothing} ${e.calculation?v.html`<pre class="calc" part="calculation">${e.calculation}</pre>`:v.nothing} ${e.hasKarmicDebt&&e.karmicDebtNumber?v.html`<div class="karmic" part="section karmic-debt"><strong>${this.t("Karmic debt")} ${e.karmicDebtNumber}.</strong> ${r?$u(e.karmicDebtMeaning):""}</div>`:v.nothing} ${this.renderReading(e.meaning,"numerology-guidance")}</article>`}renderDailyNumber(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.number,e.meaning?.title,ci(e.number,e.type))} ${e.dailyMessage&&r?v.html`<p>${e.dailyMessage}</p>`:v.nothing} ${e.meaning?.description&&r?v.html`<p>${e.meaning.description}</p>`:v.nothing} ${this.renderReading(e.meaning,"numerology-daily-guidance")}</article>`}renderPersonalDay(e,t){return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalDay,e.theme)} ${e.guidance&&!this.hideReadings?v.html`<p>${e.guidance}</p>`:v.nothing}<dl class="roxy-facts" part="details">${this.attr(this.t("Date"),M(this.effectiveLang(),e.targetDate))} ${this.attr(this.t("Personal month"),Po(e.personalMonth,e.personalMonthTheme))} ${this.attr(this.t("Personal year"),Po(e.personalYear,e.personalYearTheme))}</dl></article>`}renderPersonalMonth(e,t){return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalMonth,e.theme)} ${e.focus&&!this.hideReadings?v.html`<p>${e.focus}</p>`:v.nothing}<dl class="roxy-facts" part="details">${this.attr(this.t("Calendar month"),e.calendarMonth)} ${this.attr(this.t("Personal year"),Po(e.personalYear,e.personalYearTheme))}</dl></article>`}renderPersonalYear(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalYear,e.theme)} ${e.cycle?v.html`<p class="roxy-label">${e.cycle}</p>`:v.nothing} ${e.forecast&&r?v.html`<p>${e.forecast}</p>`:v.nothing} ${r?this.renderLists(["Opportunities",e.opportunities],["Challenges",e.challenges]):v.nothing} ${e.advice&&r?v.html`<p>${e.advice}</p>`:v.nothing}</article>`}renderChart(e,t){let r=Object.entries(e.coreNumbers??{}).filter(([,d])=>d),s=e.additionalInsights,i=e.luckyAssociations,o=e.birthDayProfile,l=e.maturityStatus,c=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}"><div part="header"><p class="roxy-label">${t}</p>${e.profile?.name?v.html`<h2>${e.profile.name}</h2>`:v.nothing} ${e.profile?.birthdate?v.html`<p class="roxy-label">${M(this.effectiveLang(),e.profile.birthdate)}</p>`:v.nothing}</div>${e.summary&&c?v.html`<p>${e.summary}</p>`:v.nothing} ${r.length>0?v.html`<div class="cores" part="details cores">${r.map(([d,p])=>v.html`<div class="item"><div class="core-head"><span class="core-key">${D(d)}</span> <strong>${p.number??""}</strong></div>${p.meaning?.title?v.html`<span class="core-title">${p.meaning.title}</span>`:v.nothing} ${ci(p.number,p.type)?v.html`<span class="master roxy-chip">${this.t("Master")} ${p.number}</span>`:v.nothing}</div>`)}</div>`:v.nothing} ${this.renderInterpretation(r.map(([d,p])=>({label:D(d),aside:[p.number!=null?`${p.number}`:"",ci(p.number,p.type)?"master":"",p.hasKarmicDebt&&p.karmicDebtNumber?`karmic debt ${p.karmicDebtNumber}`:""].filter(Boolean).join(" \xB7 "),body:p.meaning?.description??"",extra:this.renderReading(p.meaning,`numerology-core-${d}`)})),"numerology-cores","Core numbers")} ${l?v.html`<dl class="roxy-facts" part="details maturity">${this.attr(this.t("Maturity"),l.isActive?this.t("Active"):this.t("Not yet active"))} ${this.attr(this.t("Current age"),l.currentAge)} ${this.attr(this.t("Activates"),l.activationRange)}</dl>`:v.nothing} ${o?v.html`<section class="sub" part="section birth-day-profile"><h3>${this.t("Birth day profile")}</h3>${o.title?v.html`<h4>${[o.day?this.t("Day {{day}}",{day:o.day}):"",o.title].filter(Boolean).join(" \xB7 ")}</h4>`:v.nothing} ${o.description&&c?v.html`<p>${o.description}</p>`:v.nothing} ${this.renderReading(o,"numerology-birth-day-profile")}</section>`:v.nothing} ${s?this.renderInsights(s):v.nothing} ${i?v.html`<section class="sub" part="section lucky-associations"><h3>${this.t("Lucky associations")}</h3><dl class="roxy-facts">${this.attr(this.t("Day"),i.day)} ${this.attr(this.t("Element"),i.element)} ${this.attr(this.t("Ruling planet"),i.rulingPlanet)} ${this.attr(this.t("Colors"),i.colors?.join(", "))} ${this.attr(this.t("Gemstones"),i.gemstones?.join(", "))} ${this.attr(this.t("Compatible"),i.compatibleNumbers?.join(", "))} ${this.attr(this.t("Incompatible"),i.incompatibleNumbers?.join(", "))}</dl></section>`:v.nothing}</article>`}renderInsights(e){let t=e.karmicLessons,r=e.karmicDebt,s=e.personalYear,i=e.hiddenPassion,o=e.subconsciousSelf,l=e.nameLetters,c=Object.entries(t?.presentNumbers??{}),d=!this.hideReadings;return v.html`${t?v.html`<section class="sub" part="section karmic-lessons"><h3>${this.t("Karmic lessons")}</h3>${t.missingNumbers?.length?v.html`<ul class="roxy-chips">${t.missingNumbers.map(p=>v.html`<li>${this.t("Missing")} ${p}</li>`)}</ul>`:v.html`<p>${this.t("No numbers are missing from the birth name.")}</p>`} ${c.length>0?v.html`<ul class="roxy-chips">${c.map(([p,h])=>v.html`<li>${p} x ${h}</li>`)}</ul>`:v.nothing} ${this.renderInterpretation((t.lessons??[]).map(p=>({label:p.lesson??`Lesson ${p.number}`,aside:p.number!=null?`${p.number}`:"",body:p.description??"",extra:p.howToOvercome?v.html`<p><strong>${this.t("How to overcome")}.</strong> ${p.howToOvercome}</p>`:v.nothing})),"numerology-karmic-lessons","Lessons")}</section>`:v.nothing}${r?.hasKarmicDebt?v.html`<section class="sub" part="section karmic-debt"><h3>${this.t("Karmic debt")}</h3>${r.debtNumbers?.length?v.html`<ul class="roxy-chips">${r.debtNumbers.map(p=>v.html`<li>${this.t("Debt")} ${p}</li>`)}</ul>`:v.nothing} ${this.renderInterpretation((r.meanings??[]).map(p=>({label:`${this.t("Karmic debt")} ${p.number}`,body:p.description??"",extra:v.html`${p.challenge?v.html`<p><strong>${this.t("Challenge")}.</strong> ${p.challenge}</p>`:v.nothing}${p.resolution?v.html`<p><strong>${this.t("Resolution")}.</strong> ${p.resolution}</p>`:v.nothing}`})),"numerology-karmic-debt","Debts")}</section>`:v.nothing}${s?v.html`<section class="sub" part="section personal-year"><h3>${this.t("Personal year")}</h3><h4>${[s.personalYear!=null?`${s.personalYear}`:"",s.theme??"",s.cycle??""].filter(Boolean).join(" \xB7 ")}</h4>${s.forecast&&d?v.html`<p>${s.forecast}</p>`:v.nothing} ${d?this.renderLists(["Opportunities",s.opportunities],["Challenges",s.challenges]):v.nothing} ${s.advice&&d?v.html`<p>${s.advice}</p>`:v.nothing} ${s.personalMonth?v.html`<p><strong>${[s.personalMonth.personalMonth!=null?`${this.t("Personal month")} ${s.personalMonth.personalMonth}`:this.t("Personal month"),s.personalMonth.theme??""].filter(Boolean).join(" \xB7 ")}.</strong> ${d?s.personalMonth.focus??"":""}</p>`:v.nothing}</section>`:v.nothing}${e.pinnacles?.length&&d?v.html`<section class="sub" part="section pinnacles"><h3>${this.t("Pinnacles")}</h3>${this.renderInterpretation(e.pinnacles.map(p=>({label:[p.position!=null?`Pinnacle ${p.position}`:"Pinnacle",p.meaning?.title??""].filter(Boolean).join(" \xB7 "),aside:[p.number!=null?`${p.number}`:"",ih(p.startAge,p.endAge)].filter(Boolean).join(" \xB7 "),body:p.meaning?.description??"",extra:this.renderLists(["Opportunities",p.meaning?.opportunities],["Challenges",p.meaning?.challenges])})),"numerology-pinnacles","Life phases")}</section>`:v.nothing}${e.challenges?.length&&d?v.html`<section class="sub" part="section obstacle-periods"><h3>${this.t("Challenges")}</h3>${this.renderInterpretation(e.challenges.map(p=>({label:[p.position!=null?`Challenge ${p.position}`:"Challenge",p.meaning?.title??""].filter(Boolean).join(" \xB7 "),aside:[p.number!=null?`${p.number}`:"",ih(p.startAge,p.endAge)].filter(Boolean).join(" \xB7 "),body:p.meaning?.description??"",extra:v.html`${p.meaning?.lesson?v.html`<p><strong>${this.t("Lesson")}.</strong> ${p.meaning.lesson}</p>`:v.nothing}${p.meaning?.howToOvercome?v.html`<p><strong>${this.t("How to overcome")}.</strong> ${p.meaning.howToOvercome}</p>`:v.nothing}`})),"numerology-challenges","Obstacle periods")}</section>`:v.nothing}${i||o?v.html`<section class="sub" part="section name-numbers"><h3>${this.t("Name numbers")}</h3>${i?v.html`<div><h4>${[i.number!=null?this.t("Hidden passion {{number}}",{number:i.number}):this.t("Hidden passion"),i.title??""].filter(Boolean).join(" \xB7 ")}</h4>${i.description&&d?v.html`<p>${i.description}</p>`:v.nothing} ${typeof i.count=="number"?v.html`<p class="roxy-label">${this.t("Appears {{count}} times in the name",{count:i.count})}</p>`:v.nothing}</div>`:v.nothing} ${o?v.html`<div><h4>${[o.number!=null?this.t("Subconscious self {{number}}",{number:o.number}):this.t("Subconscious self"),o.title??""].filter(Boolean).join(" \xB7 ")}</h4>${o.description&&d?v.html`<p>${o.description}</p>`:v.nothing} ${o.uniqueNumbers?.length?v.html`<p class="roxy-label">${this.t("Numbers present: {{list}}",{list:nt(this.effectiveLang(),o.uniqueNumbers.map(String))})}</p>`:v.nothing}</div>`:v.nothing}</section>`:v.nothing}${l&&d?v.html`<section class="sub" part="section name-letters"><h3>${this.t("Name letters")}</h3>${this.renderInterpretation([{label:this.t("Cornerstone"),aside:Mo(l.cornerstone?.letter,l.cornerstone?.number),body:l.cornerstone?.meaning??""},{label:this.t("Capstone"),aside:Mo(l.capstone?.letter,l.capstone?.number),body:l.capstone?.meaning??""},{label:this.t("First vowel"),aside:Mo(l.firstVowel?.letter),body:l.firstVowel?.meaning??""}],"numerology-name-letters","Letter analysis")}</section>`:v.nothing}`}renderHero(e,t,r,s=false){return v.html`<div class="hero" part="header">${typeof t=="number"?v.html`<div class="numeral">${t}</div>`:v.nothing}<div><p class="roxy-label">${e}</p>${r?v.html`<h2>${r}</h2>`:v.nothing} ${s?v.html`<span class="master roxy-chip">${this.t("Master number")}</span>`:v.nothing}</div></div>`}renderReading(e,t){if(!e||this.hideReadings)return v.nothing;let r=vu.map(([s,i])=>({label:i,body:e[s]??""}));return v.html`${e.keywords?.length?v.html`<ul class="roxy-chips">${e.keywords.map(s=>v.html`<li>${s}</li>`)}</ul>`:v.nothing}${this.renderLists(["Strengths",e.strengths],["Challenges",e.challenges])}${this.renderInterpretation(r,t,"Guidance")}`}renderLists(...e){let t=e.filter(([,r])=>r&&r.length>0);return t.length===0?v.nothing:v.html`<div class="lists">${t.map(([r,s])=>v.html`<div><h3>${this.t(r)}</h3><ul>${(s??[]).map(i=>v.html`<li>${i}</li>`)}</ul></div>`)}</div>`}attr(e,t){return t==null||t===""?v.nothing:v.html`<div><dt>${e}</dt><dd>${t}</dd></div>`}};Fa.endpoints=jl,Fa.styles=[u,W,Se,me,v.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,h4,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2.5);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.master{margin-block-start:var(--roxy-space-xs)}.calc{color:var(--roxy-muted);font-family:var(--roxy-font-mono);font-size:var(--roxy-text-xs);white-space:pre-wrap;overflow-wrap:anywhere;margin:0}.cores{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));padding-block-start:var(--roxy-space-md);display:grid}.cores .item{gap:calc(var(--roxy-space-unit) / 2);font-size:var(--roxy-text-sm);display:grid}.cores .item .core-head{align-items:baseline;gap:var(--roxy-space-xs);display:flex}.cores .item .core-key{color:var(--roxy-muted);text-transform:capitalize}.cores .item strong{color:var(--roxy-accent-ink);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.cores .item .core-title{font-size:var(--roxy-text-xs)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}.lists h3{margin-block-end:var(--roxy-space-xs)}.lists ul{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.sub{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.sub p{font-size:var(--roxy-text-sm)}.roxy-facts{margin:0}.karmic{border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);padding-block-start:var(--roxy-space-md)}.karmic strong{color:var(--roxy-warning-fg);font-weight:var(--roxy-weight-bold)}`],m([(0,oh.property)({type:String,reflect:true})],Fa.prototype,"type",2),Fa=m([f("roxy-numerology-card")],Fa);var Lu={"life-path":"Life Path",expression:"Expression","soul-urge":"Soul Urge",personality:"Personality","birth-day":"Birth Day",maturity:"Maturity",daily:"Daily Number","personal-day":"Personal Day","personal-month":"Personal month","personal-year":"Personal year",chart:"Numerology chart"};function $u(n){return n?[n.description,n.challenge,n.resolution].filter(Boolean).join(" "):""}function ci(n,a){return a==="master"||n!==void 0&&bu.has(n)}function Po(n,a){return[n!=null?`${n}`:"",a??""].filter(Boolean).join(" \xB7 ")}function ih(n,a){return n==null?"":a==null?`ages ${n} onward`:`ages ${n} to ${a}`}function Mo(n,a){return[n??"",a!=null?`${a}`:""].filter(Boolean).join(" \xB7 ")}var J=require("lit"),lh=require("lit/decorators.js");function _o(...n){return n.filter(Boolean).join(" \xB7 ")}function No(...n){return n.filter(Boolean).join(", ")}var Ba=class extends g{constructor(){super(...arguments);this.detail="detailed"}renderData(e){let t="sunrise"in e?e:null,r="sunLongitude"in e?e:null,s=t?[["Brahma Muhurta",t.brahmaMuhurta],["Abhijit Muhurta",t.abhijitMuhurta],["Vijaya Muhurta",t.vijayaMuhurta],["Godhuli Muhurta",t.godhuliMuhurta],["Nishita Muhurta",t.nishitaMuhurta],["Pratah Sandhya",t.pratahSandhya],["Sayahna Sandhya",t.sayahnaSandhya]]:[],i=t?this.expandWindows(this.t("Amrit Kalam"),t.amritKalam):[],o=t?[["Rahu Kaal",t.rahuKaal],["Yamaganda",t.yamaganda],["Gulika",t.gulika]]:[],l=t?[...this.expandWindows(this.t("Dur Muhurta"),t.durMuhurta),...this.expandWindows(this.t("Varjyam"),t.varjyam)]:[],c=this.detail==="detailed"&&t!==null;return J.html`<div class="wrap" part="card" aria-label="${this.t("Panchang")}"><header class="head" part="header"><h2>${this.t("Panchang")}</h2><span class="roxy-label">${t?M(this.effectiveLang(),t.date):""}</span> ${t?this.renderLocation(t.location):J.nothing}</header><table part="table"><tbody>${this.limbs(e,t).map(d=>this.renderLimbRow(d))} ${t?J.html`${this.renderRow(this.t("Sunrise"),Nt(this.effectiveLang(),t.sunrise))} ${this.renderRow(this.t("Sunset"),Nt(this.effectiveLang(),t.sunset))} ${this.renderRow(this.t("Moonrise"),Nt(this.effectiveLang(),t.moonrise))} ${this.renderRow(this.t("Moonset"),Nt(this.effectiveLang(),t.moonset))} ${this.renderRow(this.t("Moon sign"),this.formatRashi(t.moonSign))} ${this.renderRow(this.t("Sun sign"),this.formatRashi(t.sunSign))} ${this.renderRow(this.t("Sun nakshatra"),this.formatSunNakshatra(t.sunNakshatra))} ${this.renderRow(this.t("Hora"),this.formatHora(t.hora))}`:r?J.html`${this.renderRow(this.t("Sun"),this.formatLongitude(r.sunLongitude))} ${this.renderRow(this.t("Moon"),this.formatLongitude(r.moonLongitude))}`:J.nothing}</tbody></table>${t?this.renderTransitions(t.transitions):J.nothing} ${c?J.html`<h3 class="section" part="section auspicious">${this.t("Auspicious muhurtas")}</h3><table part="table auspicious"><tbody>${this.renderPeriodRows([...s.filter(d=>!!d[1]),...i])}</tbody></table><h3 class="section" part="section inauspicious">${this.t("Inauspicious periods")}</h3><table part="table inauspicious"><tbody>${this.renderPeriodRows([...o.filter(d=>!!d[1]),...l])} ${this.renderBhadraRow(t.bhadra)} ${this.renderPanchakaRow(t.panchaka)}</tbody></table>${this.renderBalams(t.chandrabalam,t.tarabalam)}`:J.nothing}</div>`}limbs(e,t){let r=e.tithi,s=e.nakshatra,i=e.yoga,o=e.karana,l=[{label:this.t("Tithi"),value:No(r?.name,r?.paksha?`${r.paksha} paksha`:void 0),meta:_o(r?.rulingPlanet?`Ruled by ${r.rulingPlanet}`:void 0,r?.deity?`Deity ${r.deity}`:void 0,r?.element,typeof r?.percent=="number"?`${Oe(this.effectiveLang(),r.percent,0)} elapsed`:void 0)},{label:this.t("Nakshatra"),value:No(s?.name,typeof s?.pada=="number"?`pada ${s.pada}`:void 0),meta:_o(s?.lord?`Lord ${s.lord}`:void 0,s?.deity?`Deity ${s.deity}`:void 0,s?.symbol?`Symbol ${s.symbol}`:void 0,s?.characteristics)},{label:this.t("Yoga"),value:i?.name??"",meta:i?.characteristics??""},{label:this.t("Karana"),value:No(o?.name,o?.type),meta:o?.characteristics??""}];return t?.vara&&l.push({label:this.t("Vara"),value:Is(t.vara.name,t.vara.sanskritName),meta:t.vara.lord?`Lord ${t.vara.lord}`:""}),l.filter(c=>!!c.value)}renderLimbRow(e){return J.html`<tr><th>${e.label}</th><td>${e.value}${e.meta?J.html`<small>${e.meta}</small>`:J.nothing}</td></tr>`}renderRow(e,t){return t?J.html`<tr><th>${e}</th><td>${t}</td></tr>`:J.nothing}renderTransitions(e){return e?J.html`<h3 class="section" part="section transitions">${this.t("Next transitions")}</h3><table part="table transitions"><tbody>${this.renderTransitionRow(this.t("Tithi"),e.tithi)} ${this.renderTransitionRow(this.t("Nakshatra"),e.nakshatra)} ${this.renderTransitionRow(this.t("Yoga"),e.yoga)} ${this.renderTransitionRow(this.t("Karana"),e.karana)} ${this.renderMoonSignRow(e.moonSign)}</tbody></table>`:J.nothing}renderPeriodRows(e){return e.map(([t,r])=>{let s=na(this.effectiveLang(),r);return s?J.html`<tr><th>${t}</th><td>${s}</td></tr>`:J.nothing})}expandWindows(e,t){return!t||t.length===0?[]:t.map((r,s)=>[t.length>1?`${e} ${s+1}`:e,r])}renderBhadraRow(e){if(!e)return J.nothing;let t=this.formatSpan(e.startsAt,e.endsAt);return J.html`<tr><th>${this.t("Bhadra (Vishti)")}</th><td>${e.active&&t?t:J.html`<span class="quiet">${this.t("None today")}</span>`}</td></tr>`}renderPanchakaRow(e){if(!e)return J.nothing;let t=this.formatSpan(e.startsAt,e.endsAt);return J.html`<tr><th>${this.t("Panchaka")}</th><td>${e.active?J.html`${e.type?this.t("{{type}} Panchaka",{type:e.type}):this.t("Panchaka")}${t?J.html`<small>${t}</small>`:J.nothing}`:J.html`<span class="quiet">${this.t("None today")}</span>`}</td></tr>`}renderBalams(e,t){return!e&&!t?J.nothing:J.html`<h3 class="section" part="section balams">${this.t("Chandrabalam and Tarabalam")}</h3><table part="table balams"><tbody>${e?J.html`<tr><th>${this.t("Favorable Moon signs")}</th><td>${this.renderChips(e.favorableRashis,"success")}</td></tr>${this.renderRow(this.t("Ashtama Chandra rashi"),e.ashtamaChandraRashi??"")}`:J.nothing} ${t?J.html`<tr><th>${this.t("Favorable birth nakshatras")}</th><td>${this.renderChips(t.favorableNakshatras,"success")}</td></tr><tr><th>${this.t("Unfavorable birth nakshatras")}</th><td>${this.renderChips(t.unfavorableNakshatras,"danger")}</td></tr>`:J.nothing}</tbody></table>`}renderChips(e,t){return e?.length?J.html`<ul class="roxy-chips">${e.map(r=>J.html`<li class="roxy-chip" data-tone="${t}">${r}</li>`)}</ul>`:J.html`<span class="quiet">${this.t("None")}</span>`}renderLocation(e){return e?J.html`<dl class="roxy-facts">${["latitude","longitude","timezone"].map(r=>J.html`<div><dt>${ke(this.effectiveLang(),r)}</dt><dd>${b(this.effectiveLang(),e[r],5)}</dd></div>`)}</dl>`:J.nothing}clock(e){let t=this.data?.date;return t&&e.slice(0,10)!==t.slice(0,10)?ue(this.effectiveLang(),e):Nt(this.effectiveLang(),e)}renderTransitionRow(e,t){if(!t?.endsAt)return J.nothing;let r=this.clock(t.endsAt),s=t.next?typeof t.nextPada=="number"?this.t("ends {{time}} to {{next}} pada {{pada}}",{time:r,next:t.next,pada:t.nextPada}):this.t("ends {{time}} to {{next}}",{time:r,next:t.next}):this.t("ends {{time}}",{time:r});return J.html`<tr><th>${e}</th><td>${s}</td></tr>`}renderMoonSignRow(e){return e?.changesAt?J.html`<tr><th>${this.t("Moon sign")}</th><td>${e.next?this.t("{{sign}} until {{time}}, then {{next}}",{sign:e.current??"",time:this.clock(e.changesAt),next:e.next}):this.t("{{sign}} until {{time}}",{sign:e.current??"",time:this.clock(e.changesAt)})}</td></tr>`:J.nothing}formatSpan(e,t){let r=na(this.effectiveLang(),{start:e??void 0,end:t??void 0});return!r||!e||!t||e.slice(0,10)===t.slice(0,10)?r:this.t("{{range}} (ends {{date}})",{range:r,date:M(this.effectiveLang(),t)})}formatRashi(e){return Is(e?.name,e?.sanskritName)}formatSunNakshatra(e){return e?.name?_o(e.name,typeof e.pada=="number"?`pada ${e.pada}`:void 0,e.lord?`lord ${e.lord}`:void 0):""}formatHora(e){if(!e?.current)return"";let t=na(this.effectiveLang(),e);return t?`${e.current} (${t})`:e.current}formatLongitude(e){return typeof e=="number"?lt(e):""}};Ba.endpoints=Kl,Ba.styles=[u,Se,J.css`.wrap{overflow:hidden}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);flex-wrap:wrap;display:flex}h2,h3{margin:0}.head .roxy-facts{flex-basis:100%;margin:0}table{width:100%}th,td{padding-inline:var(--roxy-space-md)}th{width:38%}tbody tr:last-child :is(th,td){border-block-end:0}td small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:normal;margin-block-start:calc(var(--roxy-space-unit) / 2);display:block}.section{padding:var(--roxy-space-sm) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border)}.quiet{color:var(--roxy-muted)}.roxy-chips{margin-block-start:var(--roxy-space-xs)}`],m([(0,lh.property)({type:String,reflect:true})],Ba.prototype,"detail",2),Ba=m([f("roxy-panchang-table")],Ba);var pe=require("lit"),ch=require("lit/decorators.js");var Ha=class extends g{constructor(){super(...arguments);this.heading=""}renderData(e){let t=this.toViewModel(e),r=t.cols;return pe.html`<div class="wrap" part="card"><header part="header"><h2>${this.heading||t.title}</h2>${t.badges.length?pe.html`<ul class="roxy-chips" part="details">${t.badges.map(s=>pe.html`<li>${this.t("{{label}}: {{value}}",{label:s.label,value:s.value})}</li>`)}</ul>`:pe.nothing}</header>${t.summary&&!this.hideReadings?pe.html`<p class="summary">${t.summary}</p>`:pe.nothing}<div class="scroll" part="table" tabindex="0" role="region" aria-label="${t.title}"><table><caption class="roxy-label">${t.title}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Position")}</th>${r.natal?pe.html`<th scope="col">${this.t("Natal")}</th>`:pe.nothing} ${r.house?pe.html`<th scope="col" class="num">${this.t("House")}</th>`:pe.nothing} ${r.motion?pe.html`<th scope="col">${this.t("Motion")}</th>`:pe.nothing} ${r.formula?pe.html`<th scope="col">${this.t("Formula")}</th>`:pe.nothing}</tr></thead><tbody>${t.rows.map(s=>this.renderRow(s,r))}</tbody></table></div>${this.renderReadings(t.rows)}</div>`}renderRow(e,t){let r=S(e.body??e.label);return pe.html`<tr class="${e.isAngle?"angle":""}"><td class="body-cell">${r?pe.html`<span class="glyph">${r}</span>`:pe.nothing}${e.label}</td><td>${this.signCell(e.sign,e.degree,e.signLabel)}</td>${t.natal?pe.html`<td>${e.natalLongitude!=null?this.signFromLongitude(e.natalLongitude):pe.html`—`}</td>`:pe.nothing} ${t.house?pe.html`<td class="num">${e.house!=null?e.house:pe.html`—`}</td>`:pe.nothing} ${t.motion?pe.html`<td>${e.speed!=null?pe.html`${b(this.effectiveLang(),e.speed,3)}${this.t("\xB0/day")}${e.isRetrograde?pe.html`<span class="retro">℞</span>`:pe.nothing}`:pe.html`—`}</td>`:pe.nothing} ${t.formula?pe.html`<td class="formula">${e.formula??pe.html`—`}</td>`:pe.nothing}</tr>`}signCell(e,t,r=e){let s=Z(e);return pe.html`<span class="sign">${s?pe.html`<span class="sg">${s}</span>`:pe.nothing}${Jt(t)} ${r}</span>`}signFromLongitude(e){let t=Kt(e);return this.signCell(t.sign,t.degree+t.minute/60)}renderReadings(e){let t=e.filter(r=>r.interpretation).map(r=>({label:`${S(r.body??r.label)??""} ${r.label}`.trim(),aside:`${r.signLabel??r.sign} ${Jt(r.degree)}`.trim(),body:r.interpretation??""}));return this.renderInterpretation(t,"positions-readings","Readings")}toViewModel(e){if("asteroids"in e)return{title:this.t("Asteroids"),badges:e.houseSystem?[{label:this.t("Houses"),value:e.houseSystem}]:[],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:e.asteroids.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))};if("lilith"in e)return{title:this.t("Black Moon Lilith"),badges:e.houseSystem?[{label:this.t("Houses"),value:e.houseSystem}]:[],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:e.lilith.map(r=>({label:this.t("{{variant}} apogee",{variant:y(r,"variant",V(r.variant))}),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))};if("directed"in e)return{title:this.t("Solar arc directions"),badges:[{label:this.t("Arc"),value:`${b(this.effectiveLang(),e.solarArc,2)}\xB0`},{label:this.t("Directed to"),value:M(this.effectiveLang(),e.targetDate)}],summary:e.summary,cols:{house:false,motion:false,formula:false,natal:true},rows:e.directed.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,natalLongitude:r.natalLongitude,interpretation:r.interpretation}))};if("lots"in e)return{title:this.t("Arabic lots"),badges:e.sect?[{label:this.t("Sect"),value:V(e.sect)}]:[],summary:e.summary,cols:{house:false,motion:false,formula:true,natal:false},rows:e.lots.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,formula:r.formula,interpretation:r.interpretation}))};let t=[];return e.ascendant&&t.push({label:this.t("Ascendant"),sign:e.ascendant.sign,signLabel:y(e.ascendant,"sign"),degree:e.ascendant.degree,isAngle:true}),e.midheaven&&t.push({label:this.t("Midheaven"),sign:e.midheaven.sign,signLabel:y(e.midheaven,"sign"),degree:e.midheaven.degree,isAngle:true}),{title:this.t("Secondary progressions"),badges:[{label:this.t("Progressed to"),value:M(this.effectiveLang(),e.targetDate)},{label:this.t("Elapsed"),value:this.t("{{years}} yrs",{years:b(this.effectiveLang(),e.elapsedYears,1)})}],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:[...t,...e.planets.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))]}}};Ha.endpoints=Vl,Ha.styles=[u,W,me,pe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}header{gap:var(--roxy-space-sm);display:grid}.summary{font-size:var(--roxy-text-sm)}.scroll{min-width:0;overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.body-cell{font-weight:var(--roxy-weight-bold)}.body-cell .glyph{color:var(--roxy-accent-ink);margin-inline-end:var(--roxy-space-xs)}tr.angle td{color:var(--roxy-secondary)}.sign{align-items:baseline;gap:var(--roxy-space-xs);display:inline-flex}.sign .sg{color:var(--roxy-secondary)}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.formula{color:var(--roxy-muted);white-space:normal}`],m([(0,ch.property)({type:String})],Ha.prototype,"heading",2),Ha=m([f("roxy-positions-table")],Ha);var ht=require("lit");var Vr=class extends g{renderData(a){let e=Z(a.profectedSign),t=S(a.lordOfYear),r=Z(a.lordNatalPosition?.sign);return ht.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Annual profection")}</h2>${a.targetDate?ht.html`<p class="roxy-label">${this.t("For")} ${M(this.effectiveLang(),a.targetDate)}</p>`:ht.nothing}</header><div class="focus" part="details"><div class="age"><span class="n">${a.age}</span> <span class="roxy-label">${this.t("Age")}</span></div><span class="arrow">${this.t("Activates")}</span><div class="house"><span class="h">${this.t("House")} ${a.profectedHouse}</span> <span class="sign">${e?ht.html`<span class="sg">${e}</span>`:ht.nothing}${a.profectedSign}</span></div></div><div class="lord" part="details"><span class="roxy-label">${this.t("Lord of the year")}</span> <span class="value">${t?ht.html`<span class="sg" aria-hidden="true">${t}</span>`:ht.nothing}${a.lordOfYear}</span> ${a.lordNatalPosition?ht.html`<span class="sub">${this.t("Natal")} ${r?ht.html`<span class="sg" aria-hidden="true">${r}</span>`:ht.nothing}${this.t("{{sign}} \xB7 house {{house}}",{sign:a.lordNatalPosition.sign,house:a.lordNatalPosition.house})}</span>`:ht.nothing}</div>${a.interpretation&&!this.hideReadings?ht.html`<p class="interp">${a.interpretation}</p>`:ht.nothing}</div>`}};Vr.endpoints=Ul,Vr.styles=[u,ht.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.focus{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.age,.house{gap:calc(var(--roxy-space-unit) / 2);display:grid}.age{justify-items:center}.age .n{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.arrow{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.house .h{font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.house .sign{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.sg{margin-inline-end:var(--roxy-space-xs)}.lord{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;padding-block-start:var(--roxy-space-sm);display:flex}.lord .value{font-weight:var(--roxy-weight-bold)}.lord .sub{color:var(--roxy-muted)}.interp{font-size:var(--roxy-text-sm)}`],Vr=m([f("roxy-profection-card")],Vr);var ct=require("lit");var ph=["name","english","title"],wu=new Set(["description","meaning","characteristics","tagline","definedMeaning","undefinedMeaning","motto"]),ku=new Set(["id","symbol",...ph]),dh=48;function Su(n){return D(n).toLowerCase().replace(/\s+/g,"-")}function Ru(n){return Object.values(Ss(n)).filter(a=>typeof a=="string"||typeof a=="number").map(String).join(" \xB7 ")}var Ur=class extends g{renderData(a){let e=Ss(a),t=this.deriveTitle(e),r=typeof e.symbol=="string"?e.symbol:void 0,s=Array.isArray(e.keywords)?e.keywords.map(String):[],i=[],o=[],l=[],c=(p,h,x)=>{if(h!=null){if(Array.isArray(h)){let $=h.filter(L=>L!=null).map(L=>typeof L=="object"?Ru(L):String(L)).filter(L=>L.length>0);$.length>0&&o.push([p,$,$.some(L=>L.length>dh)])}else if(typeof h=="string")wu.has(p)||h.length>dh?i.push([p,h]):l.push([p,h]);else if(typeof h=="number"||typeof h=="boolean")l.push([p,String(h)]);else if(typeof h=="object"&&x<2)for(let[$,L]of Object.entries(Ss(h)))c(`${p} ${$}`,L,x+1)}};for(let[p,h]of Object.entries(e))ku.has(p)||p==="keywords"&&Array.isArray(h)||c(p,h,0);let d=!this.hideReadings;return ct.html`<article class="card" part="card" aria-label="${t}"><header class="head" part="header">${r?ct.html`<span class="symbol" aria-hidden="true">${r}</span>`:ct.nothing}<div><p class="roxy-label">${this.t("Reference")}</p><h2>${t}</h2></div></header>${s.length>0&&d?ct.html`<ul class="roxy-chips">${s.map(p=>ct.html`<li>${p}</li>`)}</ul>`:ct.nothing} ${d?i.map(([p,h])=>ct.html`<p class="prose"><span class="roxy-label">${ke(this.effectiveLang(),p)}</span>${h}</p>`):ct.nothing} ${l.length>0?ct.html`<div part="details"><dl class="roxy-facts">${l.map(([p,h])=>ct.html`<div><dt>${ke(this.effectiveLang(),p)}</dt><dd>${h}</dd></div>`)}</dl></div>`:ct.nothing} ${o.map(([p,h,x])=>x&&!d?ct.nothing:ct.html`<div class="list" part="section ${Su(p)}"><h3>${ke(this.effectiveLang(),p)}</h3><ul class="roxy-chips">${h.map($=>ct.html`<li>${$}</li>`)}</ul></div>`)}</article>`}deriveTitle(a){for(let r of ph)if(typeof a[r]=="string")return a[r];let e=typeof a.type=="string"?D(a.type):"",t=a.number;return t!=null?`${e} ${t}`.trim():this.t("Reference")}};Ur.endpoints=ql,Ur.styles=[u,Se,ct.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);display:flex}.symbol{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);flex:none;line-height:1}.prose .roxy-label{margin-block-end:calc(var(--roxy-space-unit) / 2);display:block}.list h3{margin-block-end:var(--roxy-space-xs)}.roxy-facts{margin:0}`],Ur=m([f("roxy-reference-card")],Ur);var at=require("lit"),mh=require("lit/directives/if-defined.js");var hh=n=>S(n)??"",qr=class extends g{renderData(a){let e=a.changes,t=["latitude","longitude"];return at.html`<div class="stack" part="stack"><roxy-natal-chart heading="Relocation chart" lang="${(0,mh.ifDefined)(this.effectiveLang())}" exportparts="chart-controls, chart-dialog, card, header, tablist, tab, panel, chart, table, aspects, aspect-grid, element-modality, legend, details, section, patterns, pattern, readings, reading, positions, distribution, houses, strongest" ?hide-readings="${this.hideReadings}" .data="${a}"></roxy-natal-chart><section class="changes" part="card changes"><h2>${this.t("What changes at this location")}</h2>${a.relocation?at.html`<dl class="roxy-facts" part="details">${t.map(r=>at.html`<div><dt>${ke(this.effectiveLang(),r==="latitude"?"relocationLatitude":"relocationLongitude")}</dt><dd>${b(this.effectiveLang(),a.relocation[r],5)}</dd></div>`)}</dl>`:at.nothing}<div class="move" part="details">${typeof e?.distanceKm=="number"?at.html`<span>${Math.round(e.distanceKm)===0?this.t("Same location as birth"):this.t("{{distance}} km {{direction}} of birthplace",{distance:U(this.effectiveLang(),e.distanceKm),direction:e.direction?ie(this.effectiveLang(),"direction",V(e.direction),e.direction):""})}</span>`:at.nothing} ${e?at.html`<span>${a.ascendant?.sign?e.ascendantSignChanged?this.t("Ascendant moves to {{sign}}",{sign:y(a.ascendant,"sign")}):this.t("Ascendant stays in {{sign}}",{sign:y(a.ascendant,"sign")}):e.ascendantSignChanged?this.t("Ascendant changes sign"):this.t("Ascendant keeps its sign")}</span>`:at.nothing}</div>${a.interpretation?.summary&&!this.hideReadings?at.html`<p class="summary">${a.interpretation.summary}</p>`:at.nothing} ${e?.angularPlanets?.length?at.html`<section part="section angular-planets"><h3>${this.t("Angular planets here")}</h3><ul class="roxy-chips">${xn(e,"angularPlanets").map(({value:r,label:s})=>at.html`<li>${hh(r)} ${s}</li>`)}</ul></section>`:at.nothing}<section part="section house-changes"><h3>${this.t("Planets that change house")}</h3>${e?.planetsChangedHouse?.length?at.html`<ul class="moves-list">${e.planetsChangedHouse.map(r=>at.html`<li>${hh(r.planet)} ${this.t("{{planet}}: house {{from}} to {{to}}",{planet:y(r,"planet"),from:r.natalHouse,to:r.relocatedHouse})}</li>`)}</ul>`:at.html`<p class="empty-note">${this.t("No planet changes house at this location.")}</p>`}</section></section></div>`}};qr.endpoints=Yl,qr.styles=[u,Se,at.css`.stack{gap:var(--roxy-space-md);display:grid}.changes{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.changes section{gap:var(--roxy-space-xs);display:grid}.move{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.summary,.moves-list{font-size:var(--roxy-text-sm)}.moves-list{gap:calc(var(--roxy-space-unit) / 2);margin:0;padding:0;list-style:none;display:grid}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`],qr=m([f("roxy-relocation-wheel")],qr);var ys=require("lit"),gs=require("lit/decorators.js");function Cu(n,a){let e=atob(n),t=new Uint8Array(e.length);for(let r=0;r<e.length;r++)t[r]=e.charCodeAt(r);return new Blob([t],{type:a})}var di=class{constructor(a,e){this.host=a;this.type=e;this.revokedOnDisconnect=false;a.addController(this)}urlFor(a){return this.url&&this.source===a?this.url:(this.revoke(),this.url=URL.createObjectURL(Cu(a,this.type)),this.source=a,this.url)}hostConnected(){this.revokedOnDisconnect&&(this.revokedOnDisconnect=false,this.host.requestUpdate())}hostDisconnected(){this.revokedOnDisconnect=this.url!==void 0,this.revoke()}revoke(){this.url&&URL.revokeObjectURL(this.url),this.url=void 0,this.source=void 0}};var Tu=/[\\/:*?"<>|]+/g;function Eu(n){switch(n.status){case 400:return"Check the details and try again.";case 403:return n.code==="origin_not_allowed"?"This website is not allowed to use this key.":void 0;case 429:return"Too many requests. Try again shortly.";case 503:return"Busy right now. Try again in a moment.";default:return}}function Du(n){let a=Ti(n.color),e=Ti(n.accent),t={...n.name?{name:n.name}:{},...n.logo?{logo:n.logo}:{},...n.footer?{footer:n.footer}:{},...a||e?{colors:{...a?{primary:a}:{},...e?{accent:e}:{}}}:{},...sn(n.font)?{font:n.font}:{},...xc(n.theme)?{theme:n.theme}:{}};return Object.keys(t).length>0?t:void 0}var Mt=class extends g{constructor(){super(...arguments);this.format="pdf";this.pdfUrl=new di(this,"application/pdf");this.fitFrame=e=>{let t=e.currentTarget,r=t.contentDocument?.documentElement;if(!r)return;let s=()=>{let i=t.offsetHeight-t.clientHeight;t.style.blockSize=`${Math.ceil(r.getBoundingClientRect().height)+i}px`};s(),this.frameObserver?.disconnect(),this.frameObserver=new ResizeObserver(s),this.frameObserver.observe(r)}}ownRequest(){return{format:this.format==="html"?"html":"pdf",branding:Du({name:this.brandName,logo:this.brandLogo,footer:this.brandFooter,color:this.brandColor,accent:this.brandAccent,font:this.font,theme:this.theme}),readings:this.hideReadings?false:void 0}}disconnectedCallback(){super.disconnectedCallback(),this.frameObserver?.disconnect(),this.frameObserver=void 0}renderData(e){if(e.html)return this.renderDocument(e.html,e.title);if(!e.pdf)return this.renderEmpty();let t=(e.title||this.report||e.template).replace(Tu," ");return ys.html`<article class="card" part="card"><h2 part="header">${e.title}</h2><a class="download" part="download" href="${this.pdfUrl.urlFor(e.pdf)}" download="${`${t}.pdf`}">${this.t("Download PDF")}</a></article>`}renderDocument(e,t){return ys.html`<iframe class="document" part="document" title="${t}" sandbox="allow-same-origin" srcdoc="${e}" @load="${this.fitFrame}"></iframe>`}renderLoading(){return ys.html`<div class="busy" role="status" aria-busy="true" part="loading"><span class="roxy-skeleton"></span><p>${this.t("Preparing your report")}</p></div>`}renderError(e){let t=Eu(this.failure);return t?ys.html`<p class="lead" role="alert">${this.t(t)}</p>${super.renderError(e)}`:super.renderError(e)}};Mt.endpoints=Wl,Mt.styles=[u,ys.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);justify-items:start;display:grid}h2{margin:0}.download{min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-lg);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);font-weight:var(--roxy-weight-bold);align-items:center;text-decoration:none;display:inline-flex}.document{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);background:var(--roxy-surface);inline-size:100%;display:block}.busy{gap:var(--roxy-space-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);display:grid}.busy .roxy-skeleton{block-size:2lh}.busy p,.lead{margin:0}.lead{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);margin-block-end:var(--roxy-space-sm)}`],m([(0,gs.property)({type:String})],Mt.prototype,"report",2),m([(0,gs.property)({type:String})],Mt.prototype,"format",2),m([(0,gs.property)({type:String,attribute:"brand-name"})],Mt.prototype,"brandName",2),m([(0,gs.property)({type:String,attribute:"brand-logo"})],Mt.prototype,"brandLogo",2),m([(0,gs.property)({type:String,attribute:"brand-footer"})],Mt.prototype,"brandFooter",2),m([(0,gs.property)({type:String})],Mt.prototype,"theme",2),Mt=m([f("roxy-report")],Mt);var _t=require("lit");var zo=[{key:"sthanaBala",source:"Sthana",color:"var(--roxy-info)"},{key:"digBala",source:"Dig",color:"var(--roxy-success)"},{key:"kalaBala",source:"Kala",color:"var(--roxy-warning)"},{key:"chestaBala",source:"Chesta",color:"var(--roxy-accent)"},{key:"naisargikaBala",source:"Naisargika",color:"var(--roxy-secondary)"},{key:"drikBala",source:"Drik",color:"var(--roxy-danger)"}],Yr=class extends g{renderData(a){if(!a.planets?.length)return this.renderEmpty();let e=[...a.planets].sort((t,r)=>t.relativeRank-r.relativeRank);return _t.html`<div class="wrap" part="card" aria-label="${this.t("Shadbala planetary strength")}"><div class="head" part="header"><h2 class="title">${this.t("Shadbala")}</h2><p class="subtitle">${this.t("{{count}} planets ranked by strength",{count:e.length})}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</div><div role="list" part="chart bars" aria-label="${this.t("Planet strength bars")}">${e.map(t=>this.renderPlanetRow(t))}</div><div class="legend" part="legend" aria-label="${this.t("Strength component legend")}">${zo.map(t=>_t.html`<div class="legend-row"><span class="legend-swatch" style="background:${t.color}" aria-hidden="true"></span> ${this.t("{{component}} Bala",{component:this.t(t.source)})}</div>`)}</div><p class="footnote" part="legend">${this.t("Ishta Phala is the capacity to give benefic results, Kashta Phala the capacity to give malefic ones. Both are in virupas and are read together, since a planet can be strong and still deliver hardship.")}</p></div>`}renderPlanetRow(a){let e=S(a.planet)??"",t=zo.map(c=>Math.max(0,a[c.key])),r=t.reduce((c,d)=>c+d,0),s=typeof a.strengthRatio=="number"&&a.strengthRatio>=1,i=s?"adequacy-badge--adequate":"adequacy-badge--weak",o=s?this.t("Adequate"):this.t("Weak"),l=b(this.effectiveLang(),a.totalRupas,2)&&b(this.effectiveLang(),a.minRequired,2)?`${b(this.effectiveLang(),a.totalRupas,2)} / ${b(this.effectiveLang(),a.minRequired,2)} R`:"";return _t.html`<div class="planet-row" role="listitem" aria-label="${this.t("{{planet}} Shadbala",{planet:a.planet})}"><div class="planet-label"><span class="glyph" aria-hidden="true">${e}</span> ${a.planet} <span class="rank-badge" aria-label="${this.t("rank {{n}}",{n:a.relativeRank})}">#${a.relativeRank}</span></div><div class="bar-wrap"><div class="bar" role="img" aria-label="${this.t("Strength components for {{planet}}",{planet:a.planet})}">${r>0?zo.map((c,d)=>{let p=t[d];if(p<=0)return _t.nothing;let h=p/r*100;return _t.html`<div class="bar-segment" style="flex-grow:${h};background:${c.color}" title="${this.t("{{component}} {{value}} virupas",{component:this.t(c.source),value:b(this.effectiveLang(),p,1)})}"></div>`}):_t.nothing}</div>${this.renderPhala(a)}</div><div class="pills">${l?_t.html`<span class="rupas-label">${l}</span>`:_t.nothing} <span class="${`adequacy-badge ${i}`}">${o}</span></div></div>`}renderPhala(a){let e=typeof a.ishtaPhala=="number"?a.ishtaPhala:0,t=typeof a.kashtaPhala=="number"?a.kashtaPhala:0;if(e+t<=0)return _t.nothing;let r=b(this.effectiveLang(),e,1)||"0",s=b(this.effectiveLang(),t,1)||"0";return _t.html`<div class="phala" role="img" aria-label="${this.t("Ishta Phala {{ishta}}, Kashta Phala {{kashta}} virupas",{ishta:r,kashta:s})}"><span class="phala-ishta" style="flex-grow:${e}"></span> <span class="phala-kashta" style="flex-grow:${t}"></span></div><div class="phala-label"><span>${this.t("Ishta {{value}}",{value:r})}</span> <span>${this.t("Kashta {{value}}",{value:s})}</span></div>`}};Yr.endpoints=Zl,Yr.styles=[u,ae,_t.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.subtitle,.footnote{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.planet-row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:14ch minmax(0,1fr) auto;display:grid}.planet-row:last-of-type{border-block-end:0}.planet-label{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);display:flex}.glyph{font-size:var(--roxy-text-base);line-height:1}.bar-wrap,.pills{gap:var(--roxy-space-xs);flex-direction:column;display:flex}.pills{align-items:flex-end}.bar{border-radius:var(--roxy-radius-sm);background:var(--roxy-border);block-size:.5lh;display:flex;overflow:hidden}.bar-segment{height:100%;transition:flex-grow var(--roxy-motion-duration) var(--roxy-motion-easing)}.rupas-label{font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;color:var(--roxy-muted);white-space:nowrap}.phala{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.25lh;display:flex;overflow:hidden}.phala-ishta{background:var(--roxy-success)}.phala-kashta{background:var(--roxy-danger)}.phala-label{justify-content:space-between;gap:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);font-variant-numeric:tabular-nums;display:flex}.footnote{font-size:var(--roxy-text-xs);color:var(--roxy-muted)}.adequacy-badge{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.adequacy-badge--adequate{color:var(--roxy-success-fg)}.adequacy-badge--weak{color:var(--roxy-danger-fg)}.rank-badge{font-size:var(--roxy-text-xs);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.legend{gap:var(--roxy-space-sm) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);flex-wrap:wrap;padding-block-start:var(--roxy-space-sm);display:flex}.legend-row{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-xs);color:var(--roxy-muted);display:flex}.legend-swatch{aspect-ratio:1;border-radius:var(--roxy-radius-sm);flex-shrink:0;block-size:.6lh;display:inline-block}@container (width<=480px){.planet-row{grid-template-rows:auto auto;grid-template-columns:12ch minmax(0,1fr)}.pills{flex-direction:row;grid-column:1/-1;justify-content:flex-start;align-items:center}}`],Yr=m([f("roxy-shadbala-table")],Yr);var A=require("lit"),Lh=require("lit/directives/unsafe-html.js");function bh(n){let a=n?.ascendant;if(!a)return;let e=Ie.findIndex(t=>t.toLowerCase()===a.sign.toLowerCase());return e<0?void 0:e*30+a.degree}var Io=680,$e=Io/2,pi=204,Au=186,gh=160,yh=258,Pu=212,Oo=224,hi=86,mi={glyph:18,degree:10},Mu=1.3,_u=.95,uh=8,fh=4;function Wr(n,a){return 180+n.ascendant-a}function vh(n,a={}){let e={t:dr(a.lang),locale:a.lang,size:a.typeSize??mi,ascendant:bh(n.person1)??0},t=n.person1?.planets??[],r=n.person2?.planets??[];return T`<svg class="synastry-wheel" xmlns=${cr} viewBox=${`0 0 ${Io} ${Io}`} part="chart" role="img" aria-label=${e.t("Dual chart wheel comparing two natal charts")}><title>${e.t("Synastry dual wheel")}</title>
|
|
124
|
-
<circle class="wheel-line" cx=${$e} cy=${$e} r=${
|
|
125
|
-
<circle class="wheel-line" cx=${$e} cy=${$e} r=${
|
|
126
|
-
<circle class="wheel-line" cx=${$e} cy=${$e} r=${
|
|
127
|
-
${
|
|
128
|
-
${
|
|
129
|
-
${
|
|
130
|
-
${
|
|
131
|
-
</svg>`.markup}function
|
|
132
|
-
${
|
|
133
|
-
<text class=${r} x=${
|
|
134
|
-
<text class="planet-deg" x=${
|
|
135
|
-
</g>`})}function
|
|
119
|
+
`}function tf(s){let a=s.data?.houses??[];return(s.hasCusps?a.map(t=>t.longitude):Array.from({length:12},(t,r)=>s.ascendant+r*30)).map(t=>{let r=Vt(s,t),n=H(Q,Q,an,r),i=H(Q,Q,Bs,r);return R`<line class="wheel-line" x1=${n.x} y1=${n.y} x2=${i.x} y2=${i.y} stroke-width="0.8" />`})}function af(s){return Ie.map((a,e)=>{let t=Vt(s,e*30+15),r=H(Q,Q,Bo,t);return R`<text class="sign-glyph roxy-glyph" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${J(a)??""}</text>`})}function rf(s){let a=s.data?.houses??[];if(s.hasCusps)return a.map((t,r)=>{let n=a[(r+1)%12],i=zn(t.longitude,n?n.longitude:t.longitude+30),o=H(Q,Q,an-12,Vt(s,i));return R`<text class="house-num" x=${o.x} y=${o.y} text-anchor="middle" dominant-baseline="central">${t.number}</text>`});let e=s.ascendant;return Array.from({length:12},(t,r)=>{let n=Vt(s,e+r*30+15),i=H(Q,Q,an-12,n),o=r+1;return R`<text class="house-num" x=${i.x} y=${i.y} text-anchor="middle" dominant-baseline="central">${o}</text>`})}function sf(s){let a=[];for(let e=0;e<360;e+=5){let t=Vt(s,e),r=e%30===0,n=r?Bo-14:Bs-5,i=H(Q,Q,n,t),o=H(Q,Q,Bs,t);a.push(R`<line class=${r?"tick tick-major":"tick"} x1=${i.x} y1=${i.y} x2=${o.x} y2=${o.y} stroke-width=${r?1:.5} />`)}return a}function nf(s){let a=s.data?.houses??[];return s.hasCusps?a.map(e=>{let t=Vt(s,e.longitude),r=H(Q,Q,an+9,t);return R`<text class="cusp-deg" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${qt(e.longitude)}</text>`}):""}function of(s,a){let e=s.size.degree>rn.degree,t=Wu*s.size.glyph,r={width:t,height:t},n=p=>({width:((e?Ft.whole:Ft.minute)+(p?Ft.retrograde:0))*s.size.degree,height:Ft.ink*s.size.degree}),i=(p,f,L)=>{let $=n(p.isRetrograde===true),k=tn-Ta(f,r,$,ha);return L===0?k:Math.min(k,Math.max(k-Xu,xi+ha+Gd(f,$)))},o=Bt(t,tn),l=n(true),c=Math.max(o,Bt(l.width,tn-Ta(90,r,l,ha))/2),d=Yt(a,p=>p.longitude,c),h=Id(d,({item:p,displayLongitude:f},L)=>{let $=Vt(s,f);return{...H(Q,Q,i(p,$,L),$),...n(p.isRetrograde===true)}});return d.map((p,f)=>{let{item:L,longitude:$,displayLongitude:k}=p,j=Vt(s,$),ue=Vt(s,k),Xe=H(Q,Q,tn,ue),Tt=H(Q,Q,i(L,ue,h[f]??0),ue),oa=H(Q,Q,Bs-4,j),$a=H(Q,Q,tn+8,ue),ln=y(L,"name"),cn=S(L.name)??ln,Hs=L.isRetrograde===true,al=qt(L.longitude),xm=e?`${Ut(L.longitude).degree}\xB0`:al,bm=Math.abs(k-$)>.5;return R`<g>
|
|
120
|
+
${bm?R`<line class="planet-leader" x1=${oa.x} y1=${oa.y} x2=${$a.x} y2=${$a.y} />`:""}
|
|
121
|
+
<text class="planet-glyph roxy-glyph" x=${Xe.x} y=${Xe.y} text-anchor="middle" dominant-baseline="central"><title>${ln}${Hs?` ${s.t("retrograde")}`:""} - ${al} ${y(L,"sign")}</title>${cn}</text>
|
|
122
|
+
<text class="planet-deg" x=${Tt.x} y=${Tt.y} text-anchor="middle" dominant-baseline="central">${xm}${Hs?R`<tspan class="retro roxy-glyph"> ${Ke}</tspan>`:""}</text>
|
|
123
|
+
</g>`})}function lf(s,a,e){let t=new Map;for(let r of a){if(typeof r.longitude!="number")continue;let n=$t(r.name);n&&t.set(n,r.longitude)}return e.filter(Ra).map(r=>{let n=t.get($t(r.planet1)),i=t.get($t(r.planet2));if(n===void 0||i===void 0)return"";let o=H(Q,Q,xi-2,Vt(s,n)),l=H(Q,Q,xi-2,Vt(s,i)),c=Dt(r),{locale:d}=s,h=b(d,r.orb,1);return R`<line class=${`aspect ${Qe(r)}`} style=${zs(r)} x1=${o.x} y1=${o.y} x2=${l.x} y2=${l.y}><title>${y(r,"planet1")} ${y(r,"type",c)} ${y(r,"planet2")}${h?` (${s.t("Orb")} ${h}\xB0)`:""}</title></line>`})}var Wr=class{constructor(a,e){this.host=a,this.marks=e,this.size=Object.fromEntries(Object.keys(e).map(t=>[t,e[t][1]])),a.addController(this)}hostConnected(){typeof ResizeObserver>"u"||(this.observer=new ResizeObserver(()=>this.host.requestUpdate()),this.observer.observe(this.host))}hostDisconnected(){this.observer?.disconnect(),this.observer=void 0}hostUpdated(){let a=false;for(let e of Object.keys(this.marks)){let[t]=this.marks[e],r=cf(this.host.renderRoot,t,this.size[e]);r!==this.size[e]&&(this.size[e]=r,a=true)}a&&this.host.requestUpdate()}};function cf(s,a,e){let t=s?.querySelector(a);if(!t||typeof getComputedStyle!="function")return e;let r=Number.parseFloat(getComputedStyle(t).fontSize);return Number.isFinite(r)&&r>0?r:e}var Ph={GRAND_CROSS:0,GRAND_TRINE:1,KITE:2,T_SQUARE:3,YOD:4,MYSTIC_RECTANGLE:5,STELLIUM:6},va=class extends g{constructor(){super(...arguments);this.viewport=new Ve(this);this.heading="Natal chart";this.view="wheel";this.type=new Wr(this,{glyph:[".planet-glyph",rn.glyph],degree:[".planet-deg",rn.degree]})}getPlanets(){return this.data?.planets??[]}renderData(e){let t=this.getPlanets(),r=e.aspects??[],n=this.view;return T.html`<div class="wrap" part="card"><header part="header"><h2>${this.t(this.heading)}</h2>${e.birthDetails?T.html`<p class="roxy-label">${fe(this.effectiveLang(),e.birthDetails.date,e.birthDetails.time)}</p>`:T.nothing}</header>${r.length>0?T.html`${ut({items:[{id:"wheel",label:this.t("Wheel")},{id:"grid",label:this.t("Aspect grid")}],active:n,onSelect:i=>{this.view=i},label:this.t("Natal chart views"),idPrefix:"natal",controls:true})}<div id="natal-panel-${n}" part="panel" role="tabpanel" aria-labelledby="natal-tab-${n}">${n==="wheel"?this.renderWheel(e):this.renderAspectGrid(t,r)}</div>`:this.renderWheel(e)}<div class="legend" part="legend"><span>${this.t("{{label}}: {{value}}",{label:this.t("Positions"),value:b(this.effectiveLang(),t.length,0)})}</span> ${r.length>0?T.html`<span>${this.t("{{count}} aspects",{count:n==="grid"?r.length:r.filter(Ra).length})}</span>`:T.nothing} ${Ho(e)&&e.houseSystem?T.html`<span>${this.t("{{label}}: {{value}}",{label:Se(this.effectiveLang(),"houseSystem"),value:ie(this.effectiveLang(),"houseSystem",e.houseSystem)})}</span>`:T.html`<span class="caveat">${this.t("Equal sectors from the Ascendant, no house cusps in this response")}</span>`} ${r.length>0?T.html`<span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span>`:T.nothing}</div>${this.renderPositionDetails(e)} ${this.renderDetails()} ${this.renderPatterns()} ${this.renderAspectDetails(r)} ${this.renderInterpretations()}</div>`}renderWheel(e){return this.viewport.renderChartViewport((0,Mh.unsafeHTML)(Ah(e,{lang:this.effectiveLang(),typeSize:this.type.size})),this.t(this.heading),this.translator)}renderAspectGrid(e,t){let r=e.map(o=>({name:o.name,label:y(o,"name")})),n=(o,l)=>[$t(o),$t(l)].sort().join("|"),i=new Map;for(let o of t)i.set(n(o.planet1,o.planet2),o);return r.length===0?T.html`<p class="roxy-empty" role="status">${this.t("No planets to grid")}</p>`:T.html`<div class="scroll" part="section aspects table aspect-grid" tabindex="0" role="region" aria-label="${this.t("Aspect grid")}"><table class="aspect-grid"><caption class="roxy-sr-only">${this.t("Planet by planet aspect grid: the aspect each pair of planets forms, read from the planet naming the row across to the planet naming the column.")}</caption><thead><tr><td></td>${r.slice(0,-1).map(o=>{let l=S(o.name)??o.label;return T.html`<th scope="col" class="roxy-glyph" title="${o.label}">${l}</th>`})}</tr></thead><tbody>${r.slice(1).map((o,l)=>{let c=S(o.name)??o.label;return T.html`<tr><th scope="row" class="roxy-glyph" title="${o.label}">${c}</th>${r.slice(0,l+1).map(d=>{let h=i.get(n(o.name,d.name));if(!h)return T.html`<td></td>`;let p=Dt(h),f=Ns(p)??y(h,"type",je(h)),L=b(this.effectiveLang(),h.orb,1);return T.html`<td class="${`cell ${Qe(h)}`}" title="${`${o.label} ${y(h,"type",p)} ${d.label}${L?` (${this.t("Orb")} ${L}\xB0)`:""}`}"><span class="asp roxy-glyph">${f}</span></td>`})} ${r.slice(l+1,-1).map(()=>T.html`<td></td>`)}</tr>`})}</tbody></table></div>`}renderPositionDetails(e){return T.html`<details class="block" part="section positions"><summary>${this.t("Chart details")}</summary><roxy-western-planets-table bare lang="${(0,jo.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${e}"></roxy-western-planets-table></details>`}renderDetails(){let e=this.data?.summary,t=this.data?.aspectsInterpretation;if(!e&&!t)return T.nothing;let r=Cn(e,"retrogradePlanets");return T.html`<div class="facts" part="details">${e?.dominantElement||e?.dominantModality?T.html`<ul class="roxy-chips">${e.dominantElement?T.html`<li>${this.t("{{label}}: {{value}}",{label:this.t("Dominant element"),value:y(e,"dominantElement")})}</li>`:T.nothing} ${e.dominantModality?T.html`<li>${this.t("{{label}}: {{value}}",{label:this.t("Dominant modality"),value:y(e,"dominantModality")})}</li>`:T.nothing}</ul>`:T.nothing} ${t?T.html`<p class="counts"><span class="harmonious">${this.t("Harmonious: {{count}}",{count:t.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:t.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:t.neutral})}</span></p>`:T.nothing} ${r.length>0?T.html`<ul class="roxy-chips">${r.map(({value:n,label:i})=>{let o=S(n);return T.html`<li>${Je(o)} ${i} <span class="roxy-glyph">${Ke}</span></li>`})}</ul>`:T.nothing} ${t?.summary&&!this.hideReadings?T.html`<p>${t.summary}</p>`:T.nothing} ${this.renderElementModalityGrid()}</div>`}renderElementModalityGrid(){let e=this.getPlanets();if(e.length===0)return T.nothing;let t=["Fire","Earth","Air","Water"],r=["Cardinal","Fixed","Mutable"],n={Fire:this.t("Fire"),Earth:this.t("Earth"),Air:this.t("Air"),Water:this.t("Water")},i={Cardinal:{abbr:this.t("Car"),full:this.t("Cardinal")},Fixed:{abbr:this.t("Fix"),full:this.t("Fixed")},Mutable:{abbr:this.t("Mut"),full:this.t("Mutable")}},o=Ie,l=this.data?.summary,c={};for(let L of t)c[L]={Cardinal:[],Fixed:[],Mutable:[]};let d=0;for(let L of e){let $=o.indexOf(U(L.sign??""));if($<0)continue;let k=t[$%4],j=r[$%3],ue=S(L.name)??y(L,"name");c[k]?.[j]?.push(ue),d++}if(d===0)return T.nothing;let h=L=>t.reduce(($,k)=>$+(c[k]?.[L]?.length??0),0),p=[...Object.entries(l?.elementDistribution??{}).map(([L,$])=>({label:n[U(L)]??L,count:$})),...Object.entries(l?.modalityDistribution??{}).map(([L,$])=>({label:i[U(L)]?.full??L,count:$}))],f=Object.values(l?.elementDistribution??{}).reduce((L,$)=>L+$,0);return T.html`${p.length?T.html`<section class="block distribution" part="section distribution"><h3>${this.t("Element and modality distribution")}</h3><p class="counts"><span class="roxy-label">${this.t("{{count}} planets",{count:f})}</span> ${p.map(({label:L,count:$})=>T.html`<span>${this.t("{{label}}: {{value}}",{label:L,value:b(this.effectiveLang(),$,0)})}</span>`)}</p></section>`:T.nothing}<div class="scroll" tabindex="0" role="region" aria-label="${this.t("Element and modality distribution")}"><table class="em-grid" part="table element-modality" aria-label="${this.t("Element and modality distribution")}"><caption class="roxy-label">${this.t("All {{count}} bodies in the chart, placed by sign",{count:d})}</caption><thead><tr><td></td>${r.map(L=>T.html`<th scope="col" title="${i[L]?.full??L}">${i[L]?.abbr??L}</th>`)}<th scope="col">${this.t("Total")}</th></tr></thead><tbody>${t.map(L=>{let $=r.reduce((k,j)=>k+(c[L]?.[j]?.length??0),0);return T.html`<tr><th scope="row">${n[L]??L}</th>${r.map(k=>T.html`<td class="roxy-glyph">${(c[L]?.[k]??[]).join(" ")}</td>`)}<td class="em-total">${$}</td></tr>`})}<tr><th scope="row">${this.t("Total")}</th>${r.map(L=>T.html`<td class="em-total">${h(L)}</td>`)}<td class="em-total">${d}</td></tr></tbody></table></div>`}renderPatterns(){let e=this.data?.patterns??[];if(e.length===0)return T.nothing;let t=[...e].sort((r,n)=>(Ph[r.kind]??9)-(Ph[n.kind]??9)||(n.tightness??0)-(r.tightness??0));return T.html`<section class="block patterns" part="section patterns"><h3>${this.t("Chart patterns")}</h3>${t.map(r=>this.renderPattern(r))}</section>`}renderPattern(e){let t=e.planets??[],r=e.apex?[...t].sort((n,i)=>+(i===e.apex)-+(n===e.apex)):t;return T.html`<div class="pattern" part="pattern"><div class="pattern-head"><span class="pattern-name">${e.name}</span> ${e.element?T.html`<span class="roxy-chip">${e.element}</span>`:T.nothing} ${e.modality?T.html`<span class="roxy-chip">${e.modality}</span>`:T.nothing} ${e.dissociate?T.html`<span class="roxy-chip" title="${this.t("Out of sign: one or more planets sit outside the pattern element or modality, so the theme holds but runs weaker.")}">${this.t("Dissociate")}</span>`:T.nothing} ${typeof e.tightness=="number"?T.html`<span class="pattern-tight roxy-label">${this.t("{{percent}} tight",{percent:Ne(this.effectiveLang(),e.tightness,0)})}</span>`:T.nothing}</div><ul class="roxy-chips">${r.map(n=>{let i=S(n),o=!!e.apex&&n===e.apex;return T.html`<li class="${o?"roxy-chip apex":"roxy-chip"}">${i?T.html`<span class="roxy-glyph" aria-hidden="true">${i}</span>`:T.nothing}${n}${o?T.html`<span>${this.t("apex")}</span>`:T.nothing}</li>`})}</ul>${e.interpretation&&!this.hideReadings?T.html`<p class="pattern-interp">${e.interpretation}</p>`:T.nothing}</div>`}renderAspectDetails(e){return e.length===0?T.nothing:T.html`<details class="block" part="section aspects"><summary>${this.t("Aspects ({{count}})",{count:e.length})}</summary><roxy-aspects-table bare hide-sections="header" lang="${(0,jo.ifDefined)(this.effectiveLang())}" ?hide-readings="${this.hideReadings}" exportparts="card, header, section, aspects, details, reading, readings, pattern, patterns, strongest" .data="${{aspects:e}}"></roxy-aspects-table></details>`}renderInterpretations(){let e=this.getPlanets().filter(t=>t.interpretation).map(t=>{let r=t.interpretation,n=S(t.name)??"",i=y(t,"name"),o=r.summary||r.detailed||"",l=r.summary?r.detailed:void 0;return{glyph:n,label:i,aside:`${y(t,"sign")} ${qt(t.longitude)}`,body:o,extra:T.html`${l?T.html`<p>${l}</p>`:T.nothing} ${os(r.keywords)}`}});return this.renderInterpretation(e,"natal-planet-readings","Planet readings")}};va.endpoints=ec,va.styles=[u,et,Os,dt,X,me,vd,T.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}h2{overflow-wrap:anywhere}details.block>summary{font-weight:var(--roxy-weight-bold)}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,42.5rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.counts{font-size:var(--roxy-text-sm);color:var(--roxy-fg)}.legend .caveat{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.scroll{min-width:0;overflow-x:auto}.aspect-grid{margin:0 auto}.aspect-grid :is(th,td){inline-size:var(--roxy-space-lg);block-size:var(--roxy-space-lg);text-align:center;vertical-align:middle;border:1px solid var(--roxy-border);padding:0}.aspect-grid .asp{color:var(--_aspect-ink,var(--roxy-muted))}.facts,.distribution,.patterns{gap:var(--roxy-space-sm);display:grid}.em-grid{width:100%}.em-grid caption{caption-side:top;text-align:start}.em-grid :is(th,td){text-align:center}.em-grid th[scope=row]{text-align:start}.em-grid td{color:var(--roxy-accent-ink)}.em-grid .em-total{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.pattern{gap:var(--roxy-space-xs);padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);display:grid}.pattern-head{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.pattern-name{font-weight:var(--roxy-weight-bold)}.pattern-tight{font-variant-numeric:tabular-nums;margin-inline-start:auto}.roxy-chip.apex{color:var(--roxy-fg);border-color:var(--roxy-accent);font-weight:var(--roxy-weight-bold)}.pattern-interp{font-size:var(--roxy-text-sm)}`],m([(0,bi.property)({type:String})],va.prototype,"heading",2),m([(0,bi.state)()],va.prototype,"view",2),va=m([x("roxy-natal-chart")],va);var v=require("lit"),Nh=require("lit/decorators.js");var df=new Set([11,22,33]),pf=[["career","Career"],["relationships","Relationships"],["spirituality","Spirituality"]],Va=class extends g{constructor(){super(...arguments);this.type="life-path"}renderData(e){let t=this.t(hf[this.type]??this.type);return"coreNumbers"in e?this.renderChart(e,t):"personalDay"in e?this.renderPersonalDay(e,t):"personalMonth"in e?this.renderPersonalMonth(e,t):"personalYear"in e?this.renderPersonalYear(e,t):"dailyMessage"in e?this.renderDailyNumber(e,t):this.renderNumberCard(e,t)}renderNumberCard(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.number,e.meaning?.title,vi(e.number,e.type))} ${e.meaning?.description&&r?v.html`<p>${e.meaning.description}</p>`:v.nothing} ${e.calculation?v.html`<pre class="calc" part="calculation">${e.calculation}</pre>`:v.nothing} ${e.hasKarmicDebt&&e.karmicDebtNumber?v.html`<div class="karmic" part="section karmic-debt"><strong>${this.t("Karmic debt")} ${e.karmicDebtNumber}.</strong> ${r?mf(e.karmicDebtMeaning):""}</div>`:v.nothing} ${this.renderReading(e.meaning,"numerology-guidance")}</article>`}renderDailyNumber(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.number,e.meaning?.title,vi(e.number,e.type))} ${e.dailyMessage&&r?v.html`<p>${e.dailyMessage}</p>`:v.nothing} ${e.meaning?.description&&r?v.html`<p>${e.meaning.description}</p>`:v.nothing} ${this.renderReading(e.meaning,"numerology-daily-guidance")}</article>`}renderPersonalDay(e,t){return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalDay,e.theme)} ${e.guidance&&!this.hideReadings?v.html`<p>${e.guidance}</p>`:v.nothing}<dl class="roxy-facts" part="details">${this.attr(this.t("Date"),M(this.effectiveLang(),e.targetDate))} ${this.attr(this.t("Personal month"),Ko(e.personalMonth,e.personalMonthTheme))} ${this.attr(this.t("Personal year"),Ko(e.personalYear,e.personalYearTheme))}</dl></article>`}renderPersonalMonth(e,t){return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalMonth,e.theme)} ${e.focus&&!this.hideReadings?v.html`<p>${e.focus}</p>`:v.nothing}<dl class="roxy-facts" part="details">${this.attr(this.t("Calendar month"),e.calendarMonth)} ${this.attr(this.t("Personal year"),Ko(e.personalYear,e.personalYearTheme))}</dl></article>`}renderPersonalYear(e,t){let r=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}">${this.renderHero(t,e.personalYear,e.theme)} ${e.cycle?v.html`<p class="roxy-label">${e.cycle}</p>`:v.nothing} ${e.forecast&&r?v.html`<p>${e.forecast}</p>`:v.nothing} ${r?this.renderLists(["Opportunities",e.opportunities],["Challenges",e.challenges]):v.nothing} ${e.advice&&r?v.html`<p>${e.advice}</p>`:v.nothing}</article>`}renderChart(e,t){let r=Object.entries(e.coreNumbers??{}).filter(([,d])=>d),n=e.additionalInsights,i=e.luckyAssociations,o=e.birthDayProfile,l=e.maturityStatus,c=!this.hideReadings;return v.html`<article class="card" part="card" aria-label="${t}"><div part="header"><p class="roxy-label">${t}</p>${e.profile?.name?v.html`<h2>${e.profile.name}</h2>`:v.nothing} ${e.profile?.birthdate?v.html`<p class="roxy-label">${M(this.effectiveLang(),e.profile.birthdate)}</p>`:v.nothing}</div>${e.summary&&c?v.html`<p>${e.summary}</p>`:v.nothing} ${r.length>0?v.html`<div class="cores" part="details cores">${r.map(([d,h])=>v.html`<div class="item"><div class="core-head"><span class="core-key">${D(d)}</span> <strong>${h.number??""}</strong></div>${h.meaning?.title?v.html`<span class="core-title">${h.meaning.title}</span>`:v.nothing} ${vi(h.number,h.type)?v.html`<span class="master roxy-chip">${this.t("Master")} ${h.number}</span>`:v.nothing}</div>`)}</div>`:v.nothing} ${this.renderInterpretation(r.map(([d,h])=>({label:D(d),aside:[h.number!=null?`${h.number}`:"",vi(h.number,h.type)?"master":"",h.hasKarmicDebt&&h.karmicDebtNumber?`karmic debt ${h.karmicDebtNumber}`:""].filter(Boolean).join(" \xB7 "),body:h.meaning?.description??"",extra:this.renderReading(h.meaning,`numerology-core-${d}`)})),"numerology-cores","Core numbers")} ${l?v.html`<dl class="roxy-facts" part="details maturity">${this.attr(this.t("Maturity"),l.isActive?this.t("Active"):this.t("Not yet active"))} ${this.attr(this.t("Current age"),l.currentAge)} ${this.attr(this.t("Activates"),l.activationRange)}</dl>`:v.nothing} ${o?v.html`<section class="sub" part="section birth-day-profile"><h3>${this.t("Birth day profile")}</h3>${o.title?v.html`<h4>${[o.day?this.t("Day {{day}}",{day:o.day}):"",o.title].filter(Boolean).join(" \xB7 ")}</h4>`:v.nothing} ${o.description&&c?v.html`<p>${o.description}</p>`:v.nothing} ${this.renderReading(o,"numerology-birth-day-profile")}</section>`:v.nothing} ${n?this.renderInsights(n):v.nothing} ${i?v.html`<section class="sub" part="section lucky-associations"><h3>${this.t("Lucky associations")}</h3><dl class="roxy-facts">${this.attr(this.t("Day"),i.day)} ${this.attr(this.t("Element"),i.element)} ${this.attr(this.t("Ruling planet"),i.rulingPlanet)} ${this.attr(this.t("Colors"),i.colors?.join(", "))} ${this.attr(this.t("Gemstones"),i.gemstones?.join(", "))} ${this.attr(this.t("Compatible"),i.compatibleNumbers?.join(", "))} ${this.attr(this.t("Incompatible"),i.incompatibleNumbers?.join(", "))}</dl></section>`:v.nothing}</article>`}renderInsights(e){let t=e.karmicLessons,r=e.karmicDebt,n=e.personalYear,i=e.hiddenPassion,o=e.subconsciousSelf,l=e.nameLetters,c=Object.entries(t?.presentNumbers??{}),d=!this.hideReadings;return v.html`${t?v.html`<section class="sub" part="section karmic-lessons"><h3>${this.t("Karmic lessons")}</h3>${t.missingNumbers?.length?v.html`<ul class="roxy-chips">${t.missingNumbers.map(h=>v.html`<li>${this.t("Missing")} ${h}</li>`)}</ul>`:v.html`<p>${this.t("No numbers are missing from the birth name.")}</p>`} ${c.length>0?v.html`<ul class="roxy-chips">${c.map(([h,p])=>v.html`<li>${h} x ${p}</li>`)}</ul>`:v.nothing} ${this.renderInterpretation((t.lessons??[]).map(h=>({label:h.lesson??`Lesson ${h.number}`,aside:h.number!=null?`${h.number}`:"",body:h.description??"",extra:h.howToOvercome?v.html`<p><strong>${this.t("How to overcome")}.</strong> ${h.howToOvercome}</p>`:v.nothing})),"numerology-karmic-lessons","Lessons")}</section>`:v.nothing}${r?.hasKarmicDebt?v.html`<section class="sub" part="section karmic-debt"><h3>${this.t("Karmic debt")}</h3>${r.debtNumbers?.length?v.html`<ul class="roxy-chips">${r.debtNumbers.map(h=>v.html`<li>${this.t("Debt")} ${h}</li>`)}</ul>`:v.nothing} ${this.renderInterpretation((r.meanings??[]).map(h=>({label:`${this.t("Karmic debt")} ${h.number}`,body:h.description??"",extra:v.html`${h.challenge?v.html`<p><strong>${this.t("Challenge")}.</strong> ${h.challenge}</p>`:v.nothing}${h.resolution?v.html`<p><strong>${this.t("Resolution")}.</strong> ${h.resolution}</p>`:v.nothing}`})),"numerology-karmic-debt","Debts")}</section>`:v.nothing}${n?v.html`<section class="sub" part="section personal-year"><h3>${this.t("Personal year")}</h3><h4>${[n.personalYear!=null?`${n.personalYear}`:"",n.theme??"",n.cycle??""].filter(Boolean).join(" \xB7 ")}</h4>${n.forecast&&d?v.html`<p>${n.forecast}</p>`:v.nothing} ${d?this.renderLists(["Opportunities",n.opportunities],["Challenges",n.challenges]):v.nothing} ${n.advice&&d?v.html`<p>${n.advice}</p>`:v.nothing} ${n.personalMonth?v.html`<p><strong>${[n.personalMonth.personalMonth!=null?`${this.t("Personal month")} ${n.personalMonth.personalMonth}`:this.t("Personal month"),n.personalMonth.theme??""].filter(Boolean).join(" \xB7 ")}.</strong> ${d?n.personalMonth.focus??"":""}</p>`:v.nothing}</section>`:v.nothing}${e.pinnacles?.length&&d?v.html`<section class="sub" part="section pinnacles"><h3>${this.t("Pinnacles")}</h3>${this.renderInterpretation(e.pinnacles.map(h=>({label:[h.position!=null?`Pinnacle ${h.position}`:"Pinnacle",h.meaning?.title??""].filter(Boolean).join(" \xB7 "),aside:[h.number!=null?`${h.number}`:"",_h(h.startAge,h.endAge)].filter(Boolean).join(" \xB7 "),body:h.meaning?.description??"",extra:this.renderLists(["Opportunities",h.meaning?.opportunities],["Challenges",h.meaning?.challenges])})),"numerology-pinnacles","Life phases")}</section>`:v.nothing}${e.challenges?.length&&d?v.html`<section class="sub" part="section obstacle-periods"><h3>${this.t("Challenges")}</h3>${this.renderInterpretation(e.challenges.map(h=>({label:[h.position!=null?`Challenge ${h.position}`:"Challenge",h.meaning?.title??""].filter(Boolean).join(" \xB7 "),aside:[h.number!=null?`${h.number}`:"",_h(h.startAge,h.endAge)].filter(Boolean).join(" \xB7 "),body:h.meaning?.description??"",extra:v.html`${h.meaning?.lesson?v.html`<p><strong>${this.t("Lesson")}.</strong> ${h.meaning.lesson}</p>`:v.nothing}${h.meaning?.howToOvercome?v.html`<p><strong>${this.t("How to overcome")}.</strong> ${h.meaning.howToOvercome}</p>`:v.nothing}`})),"numerology-challenges","Obstacle periods")}</section>`:v.nothing}${i||o?v.html`<section class="sub" part="section name-numbers"><h3>${this.t("Name numbers")}</h3>${i?v.html`<div><h4>${[i.number!=null?this.t("Hidden passion {{number}}",{number:i.number}):this.t("Hidden passion"),i.title??""].filter(Boolean).join(" \xB7 ")}</h4>${i.description&&d?v.html`<p>${i.description}</p>`:v.nothing} ${typeof i.count=="number"?v.html`<p class="roxy-label">${this.t("Appears {{count}} times in the name",{count:i.count})}</p>`:v.nothing}</div>`:v.nothing} ${o?v.html`<div><h4>${[o.number!=null?this.t("Subconscious self {{number}}",{number:o.number}):this.t("Subconscious self"),o.title??""].filter(Boolean).join(" \xB7 ")}</h4>${o.description&&d?v.html`<p>${o.description}</p>`:v.nothing} ${o.uniqueNumbers?.length?v.html`<p class="roxy-label">${this.t("Numbers present: {{list}}",{list:ot(this.effectiveLang(),o.uniqueNumbers.map(String))})}</p>`:v.nothing}</div>`:v.nothing}</section>`:v.nothing}${l&&d?v.html`<section class="sub" part="section name-letters"><h3>${this.t("Name letters")}</h3>${this.renderInterpretation([{label:this.t("Cornerstone"),aside:Vo(l.cornerstone?.letter,l.cornerstone?.number),body:l.cornerstone?.meaning??""},{label:this.t("Capstone"),aside:Vo(l.capstone?.letter,l.capstone?.number),body:l.capstone?.meaning??""},{label:this.t("First vowel"),aside:Vo(l.firstVowel?.letter),body:l.firstVowel?.meaning??""}],"numerology-name-letters","Letter analysis")}</section>`:v.nothing}`}renderHero(e,t,r,n=false){return v.html`<div class="hero" part="header">${typeof t=="number"?v.html`<div class="numeral">${t}</div>`:v.nothing}<div><p class="roxy-label">${e}</p>${r?v.html`<h2>${r}</h2>`:v.nothing} ${n?v.html`<span class="master roxy-chip">${this.t("Master number")}</span>`:v.nothing}</div></div>`}renderReading(e,t){if(!e||this.hideReadings)return v.nothing;let r=pf.map(([n,i])=>({label:i,body:e[n]??""}));return v.html`${e.keywords?.length?v.html`<ul class="roxy-chips">${e.keywords.map(n=>v.html`<li>${n}</li>`)}</ul>`:v.nothing}${this.renderLists(["Strengths",e.strengths],["Challenges",e.challenges])}${this.renderInterpretation(r,t,"Guidance")}`}renderLists(...e){let t=e.filter(([,r])=>r&&r.length>0);return t.length===0?v.nothing:v.html`<div class="lists">${t.map(([r,n])=>v.html`<div><h3>${this.t(r)}</h3><ul>${(n??[]).map(i=>v.html`<li>${i}</li>`)}</ul></div>`)}</div>`}attr(e,t){return t==null||t===""?v.nothing:v.html`<div><dt>${e}</dt><dd>${t}</dd></div>`}};Va.endpoints=tc,Va.styles=[u,X,Re,me,v.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,h4,p{margin:0}.hero{align-items:center;gap:var(--roxy-space-md);display:flex}.numeral{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 2.5);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.master{margin-block-start:var(--roxy-space-xs)}.calc{color:var(--roxy-muted);font-family:var(--roxy-font-mono);font-size:var(--roxy-text-xs);white-space:pre-wrap;overflow-wrap:anywhere;margin:0}.cores{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));padding-block-start:var(--roxy-space-md);display:grid}.cores .item{gap:calc(var(--roxy-space-unit) / 2);font-size:var(--roxy-text-sm);display:grid}.cores .item .core-head{align-items:baseline;gap:var(--roxy-space-xs);display:flex}.cores .item .core-key{color:var(--roxy-muted);text-transform:capitalize}.cores .item strong{color:var(--roxy-accent-ink);font-size:var(--roxy-text-base);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}.cores .item .core-title{font-size:var(--roxy-text-xs)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}.lists h3{margin-block-end:var(--roxy-space-xs)}.lists ul{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md);display:grid}.sub{gap:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-md);display:grid}.sub p{font-size:var(--roxy-text-sm)}.roxy-facts{margin:0}.karmic{border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);padding-block-start:var(--roxy-space-md)}.karmic strong{color:var(--roxy-warning-fg);font-weight:var(--roxy-weight-bold)}`],m([(0,Nh.property)({type:String,reflect:true})],Va.prototype,"type",2),Va=m([x("roxy-numerology-card")],Va);var hf={"life-path":"Life Path",expression:"Expression","soul-urge":"Soul Urge",personality:"Personality","birth-day":"Birth Day",maturity:"Maturity",daily:"Daily Number","personal-day":"Personal Day","personal-month":"Personal month","personal-year":"Personal year",chart:"Numerology chart"};function mf(s){return s?[s.description,s.challenge,s.resolution].filter(Boolean).join(" "):""}function vi(s,a){return a==="master"||s!==void 0&&df.has(s)}function Ko(s,a){return[s!=null?`${s}`:"",a??""].filter(Boolean).join(" \xB7 ")}function _h(s,a){return s==null?"":a==null?`ages ${s} onward`:`ages ${s} to ${a}`}function Vo(s,a){return[s??"",a!=null?`${a}`:""].filter(Boolean).join(" \xB7 ")}var Z=require("lit"),zh=require("lit/decorators.js");var gf=28;function Uo(...s){return s.filter(Boolean).join(" \xB7 ")}function qo(...s){return s.filter(Boolean).join(", ")}var Ua=class extends g{constructor(){super(...arguments);this.detail="detailed"}renderData(e){let t="sunrise"in e?e:null,r="sunLongitude"in e?e:null,n=t?[["Brahma Muhurta",t.brahmaMuhurta],["Abhijit Muhurta",t.abhijitMuhurta],["Vijaya Muhurta",t.vijayaMuhurta],["Godhuli Muhurta",t.godhuliMuhurta],["Nishita Muhurta",t.nishitaMuhurta],["Pratah Sandhya",t.pratahSandhya],["Sayahna Sandhya",t.sayahnaSandhya]]:[],i=t?this.expandWindows(this.t("Amrit Kalam"),t.amritKalam):[],o=t?[["Rahu Kaal",t.rahuKaal],["Yamaganda",t.yamaganda],["Gulika",t.gulika]]:[],l=t?[...this.expandWindows(this.t("Dur Muhurta"),t.durMuhurta),...this.expandWindows(this.t("Varjyam"),t.varjyam)]:[],c=this.detail==="detailed"&&t!==null;return Z.html`<div class="wrap" part="card" aria-label="${this.t("Panchang")}"><header class="head" part="header"><h2>${this.t("Panchang")}</h2><span class="roxy-label">${t?M(this.effectiveLang(),t.date):""}</span> ${t?this.renderLocation(t.location):Z.nothing}</header><table part="table"><tbody>${this.limbs(e,t).map(d=>this.renderLimbRow(d))} ${t?Z.html`${this.renderRow(this.t("Sunrise"),Ot(this.effectiveLang(),t.sunrise))} ${this.renderRow(this.t("Sunset"),Ot(this.effectiveLang(),t.sunset))} ${this.renderRow(this.t("Moonrise"),Ot(this.effectiveLang(),t.moonrise))} ${this.renderRow(this.t("Moonset"),Ot(this.effectiveLang(),t.moonset))} ${this.renderRow(this.t("Moon sign"),this.formatRashi(t.moonSign))} ${this.renderRow(this.t("Sun sign"),this.formatRashi(t.sunSign))} ${this.renderRow(this.t("Sun nakshatra"),this.formatSunNakshatra(t.sunNakshatra))} ${this.renderRow(this.t("Hora"),this.formatHora(t.hora))}`:r?Z.html`${this.renderRow(this.t("Sun"),this.formatLongitude(r.sunLongitude))} ${this.renderRow(this.t("Moon"),this.formatLongitude(r.moonLongitude))}`:Z.nothing}</tbody></table>${t?this.renderTransitions(t.transitions):Z.nothing} ${c?Z.html`<h3 class="section" part="section auspicious">${this.t("Auspicious muhurtas")}</h3><table part="table auspicious"><tbody>${this.renderPeriodRows([...n.filter(d=>!!d[1]),...i])}</tbody></table><h3 class="section" part="section inauspicious">${this.t("Inauspicious periods")}</h3><table part="table inauspicious"><tbody>${this.renderPeriodRows([...o.filter(d=>!!d[1]),...l])} ${this.renderBhadraRow(t.bhadra)} ${this.renderPanchakaRow(t.panchaka)}</tbody></table>${this.renderBalams(t.chandrabalam,t.tarabalam)}`:Z.nothing}</div>`}limbs(e,t){let r=e.tithi,n=e.nakshatra,i=e.yoga,o=e.karana,l=[{label:this.t("Tithi"),value:qo(r?.name,r?.paksha?`${r.paksha} paksha`:void 0),moon:Ys(r?.number),meta:Uo(r?.rulingPlanet?`Ruled by ${r.rulingPlanet}`:void 0,r?.deity?`Deity ${r.deity}`:void 0,r?.element,typeof r?.percent=="number"?`${Ne(this.effectiveLang(),r.percent,0)} elapsed`:void 0)},{label:this.t("Nakshatra"),value:qo(n?.name,typeof n?.pada=="number"?`pada ${n.pada}`:void 0),meta:Uo(n?.lord?`Lord ${n.lord}`:void 0,n?.deity?`Deity ${n.deity}`:void 0,n?.symbol?`Symbol ${n.symbol}`:void 0,n?.characteristics)},{label:this.t("Yoga"),value:i?.name??"",meta:i?.characteristics??""},{label:this.t("Karana"),value:qo(o?.name,o?.type),meta:o?.characteristics??""}];return t?.vara&&l.push({label:this.t("Vara"),value:qs(t.vara.name,t.vara.sanskritName),meta:t.vara.lord?`Lord ${t.vara.lord}`:""}),l.filter(c=>!!c.value)}renderLimbRow(e){return Z.html`<tr><th>${e.label}</th><td>${e.moon?ea(this,e.moon,gf):Z.nothing}${e.value}${e.meta?Z.html`<small>${e.meta}</small>`:Z.nothing}</td></tr>`}renderRow(e,t){return t?Z.html`<tr><th>${e}</th><td>${t}</td></tr>`:Z.nothing}renderTransitions(e){return e?Z.html`<h3 class="section" part="section transitions">${this.t("Next transitions")}</h3><table part="table transitions"><tbody>${this.renderTransitionRow(this.t("Tithi"),e.tithi)} ${this.renderTransitionRow(this.t("Nakshatra"),e.nakshatra)} ${this.renderTransitionRow(this.t("Yoga"),e.yoga)} ${this.renderTransitionRow(this.t("Karana"),e.karana)} ${this.renderMoonSignRow(e.moonSign)}</tbody></table>`:Z.nothing}renderPeriodRows(e){return e.map(([t,r])=>{let n=la(this.effectiveLang(),r);return n?Z.html`<tr><th>${t}</th><td>${n}</td></tr>`:Z.nothing})}expandWindows(e,t){return!t||t.length===0?[]:t.map((r,n)=>[t.length>1?`${e} ${n+1}`:e,r])}renderBhadraRow(e){if(!e)return Z.nothing;let t=this.formatSpan(e.startsAt,e.endsAt);return Z.html`<tr><th>${this.t("Bhadra (Vishti)")}</th><td>${e.active&&t?t:Z.html`<span class="quiet">${this.t("None today")}</span>`}</td></tr>`}renderPanchakaRow(e){if(!e)return Z.nothing;let t=this.formatSpan(e.startsAt,e.endsAt);return Z.html`<tr><th>${this.t("Panchaka")}</th><td>${e.active?Z.html`${e.type?this.t("{{type}} Panchaka",{type:e.type}):this.t("Panchaka")}${t?Z.html`<small>${t}</small>`:Z.nothing}`:Z.html`<span class="quiet">${this.t("None today")}</span>`}</td></tr>`}renderBalams(e,t){return!e&&!t?Z.nothing:Z.html`<h3 class="section" part="section balams">${this.t("Chandrabalam and Tarabalam")}</h3><table part="table balams"><tbody>${e?Z.html`<tr><th>${this.t("Favorable Moon signs")}</th><td>${this.renderChips(e.favorableRashis,"success")}</td></tr>${this.renderRow(this.t("Ashtama Chandra rashi"),e.ashtamaChandraRashi??"")}`:Z.nothing} ${t?Z.html`<tr><th>${this.t("Favorable birth nakshatras")}</th><td>${this.renderChips(t.favorableNakshatras,"success")}</td></tr><tr><th>${this.t("Unfavorable birth nakshatras")}</th><td>${this.renderChips(t.unfavorableNakshatras,"danger")}</td></tr>`:Z.nothing}</tbody></table>`}renderChips(e,t){return e?.length?Z.html`<ul class="roxy-chips">${e.map(r=>Z.html`<li class="roxy-chip" data-tone="${t}">${r}</li>`)}</ul>`:Z.html`<span class="quiet">${this.t("None")}</span>`}renderLocation(e){return e?Z.html`<dl class="roxy-facts">${["latitude","longitude","timezone"].map(r=>Z.html`<div><dt>${Se(this.effectiveLang(),r)}</dt><dd>${b(this.effectiveLang(),e[r],5)}</dd></div>`)}</dl>`:Z.nothing}clock(e){let t=this.data?.date;return t&&e.slice(0,10)!==t.slice(0,10)?fe(this.effectiveLang(),e):Ot(this.effectiveLang(),e)}renderTransitionRow(e,t){if(!t?.endsAt)return Z.nothing;let r=this.clock(t.endsAt),n=t.next?typeof t.nextPada=="number"?this.t("ends {{time}} to {{next}} pada {{pada}}",{time:r,next:t.next,pada:t.nextPada}):this.t("ends {{time}} to {{next}}",{time:r,next:t.next}):this.t("ends {{time}}",{time:r});return Z.html`<tr><th>${e}</th><td>${n}</td></tr>`}renderMoonSignRow(e){return e?.changesAt?Z.html`<tr><th>${this.t("Moon sign")}</th><td>${e.next?this.t("{{sign}} until {{time}}, then {{next}}",{sign:e.current??"",time:this.clock(e.changesAt),next:e.next}):this.t("{{sign}} until {{time}}",{sign:e.current??"",time:this.clock(e.changesAt)})}</td></tr>`:Z.nothing}formatSpan(e,t){let r=la(this.effectiveLang(),{start:e??void 0,end:t??void 0});return!r||!e||!t||e.slice(0,10)===t.slice(0,10)?r:this.t("{{range}} (ends {{date}})",{range:r,date:M(this.effectiveLang(),t)})}formatRashi(e){return qs(e?.name,e?.sanskritName)}formatSunNakshatra(e){return e?.name?Uo(e.name,typeof e.pada=="number"?`pada ${e.pada}`:void 0,e.lord?`lord ${e.lord}`:void 0):""}formatHora(e){if(!e?.current)return"";let t=la(this.effectiveLang(),e);return t?`${e.current} (${t})`:e.current}formatLongitude(e){return typeof e=="number"?pt(e):""}};Ua.endpoints=ac,Ua.styles=[u,Re,sr,Z.css`.wrap{overflow:hidden}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border);flex-wrap:wrap;display:flex}h2,h3{margin:0}.head .roxy-facts{flex-basis:100%;margin:0}table{width:100%}th,td{padding-inline:var(--roxy-space-md)}th{width:38%}tbody tr:last-child :is(th,td){border-block-end:0}td>.moon-mark{margin-inline-end:var(--roxy-space-sm)}td small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:normal;margin-block-start:calc(var(--roxy-space-unit) / 2);display:block}.section{padding:var(--roxy-space-sm) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border)}.quiet{color:var(--roxy-muted)}.roxy-chips{margin-block-start:var(--roxy-space-xs)}`],m([(0,zh.property)({type:String,reflect:true})],Ua.prototype,"detail",2),Ua=m([x("roxy-panchang-table")],Ua);var pe=require("lit"),Oh=require("lit/decorators.js");var qa=class extends g{constructor(){super(...arguments);this.heading=""}renderData(e){let t=this.toViewModel(e),r=t.cols;return pe.html`<div class="wrap" part="card"><header part="header"><h2>${this.heading||t.title}</h2>${t.badges.length?pe.html`<ul class="roxy-chips" part="details">${t.badges.map(n=>pe.html`<li>${this.t("{{label}}: {{value}}",{label:n.label,value:n.value})}</li>`)}</ul>`:pe.nothing}</header>${t.summary&&!this.hideReadings?pe.html`<p class="summary">${t.summary}</p>`:pe.nothing}<div class="scroll" part="table" tabindex="0" role="region" aria-label="${t.title}"><table><caption class="roxy-label">${t.title}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col">${this.t("Position")}</th>${r.natal?pe.html`<th scope="col">${this.t("Natal")}</th>`:pe.nothing} ${r.house?pe.html`<th scope="col" class="num">${this.t("House")}</th>`:pe.nothing} ${r.motion?pe.html`<th scope="col">${this.t("Motion")}</th>`:pe.nothing} ${r.formula?pe.html`<th scope="col">${this.t("Formula")}</th>`:pe.nothing}</tr></thead><tbody>${t.rows.map(n=>this.renderRow(n,r))}</tbody></table></div>${this.renderReadings(t.rows)}</div>`}renderRow(e,t){let r=S(e.body??e.label);return pe.html`<tr class="${e.isAngle?"angle":""}"><td class="body-cell">${r?pe.html`<span class="glyph roxy-glyph">${r}</span>`:pe.nothing}${e.label}</td><td>${this.signCell(e.sign,e.degree,e.signLabel)}</td>${t.natal?pe.html`<td>${e.natalLongitude!=null?this.signFromLongitude(e.natalLongitude):pe.html`—`}</td>`:pe.nothing} ${t.house?pe.html`<td class="num">${e.house!=null?e.house:pe.html`—`}</td>`:pe.nothing} ${t.motion?pe.html`<td>${e.speed!=null?pe.html`${b(this.effectiveLang(),e.speed,3)}${this.t("\xB0/day")}${e.isRetrograde?pe.html`<span class="retro roxy-glyph">${Ke}</span>`:pe.nothing}`:pe.html`—`}</td>`:pe.nothing} ${t.formula?pe.html`<td class="formula">${e.formula??pe.html`—`}</td>`:pe.nothing}</tr>`}signCell(e,t,r=e){let n=J(e);return pe.html`<span class="sign">${n?pe.html`<span class="sg roxy-glyph">${n}</span>`:pe.nothing}${ta(t)} ${r}</span>`}signFromLongitude(e){let t=Ut(e);return this.signCell(t.sign,t.degree+t.minute/60)}renderReadings(e){let t=e.filter(r=>r.interpretation).map(r=>({glyph:S(r.body??r.label)??"",label:r.label,aside:`${r.signLabel??r.sign} ${ta(r.degree)}`.trim(),body:r.interpretation??""}));return this.renderInterpretation(t,"positions-readings","Readings")}toViewModel(e){if("asteroids"in e)return{title:this.t("Asteroids"),badges:e.houseSystem?[{label:this.t("Houses"),value:e.houseSystem}]:[],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:e.asteroids.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))};if("lilith"in e)return{title:this.t("Black Moon Lilith"),badges:e.houseSystem?[{label:this.t("Houses"),value:e.houseSystem}]:[],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:e.lilith.map(r=>({label:this.t("{{variant}} apogee",{variant:y(r,"variant",U(r.variant))}),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))};if("directed"in e)return{title:this.t("Solar arc directions"),badges:[{label:this.t("Arc"),value:`${b(this.effectiveLang(),e.solarArc,2)}\xB0`},{label:this.t("Directed to"),value:M(this.effectiveLang(),e.targetDate)}],summary:e.summary,cols:{house:false,motion:false,formula:false,natal:true},rows:e.directed.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,natalLongitude:r.natalLongitude,interpretation:r.interpretation}))};if("lots"in e)return{title:this.t("Arabic lots"),badges:e.sect?[{label:this.t("Sect"),value:U(e.sect)}]:[],summary:e.summary,cols:{house:false,motion:false,formula:true,natal:false},rows:e.lots.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,formula:r.formula,interpretation:r.interpretation}))};let t=[];return e.ascendant&&t.push({label:this.t("Ascendant"),sign:e.ascendant.sign,signLabel:y(e.ascendant,"sign"),degree:e.ascendant.degree,isAngle:true}),e.midheaven&&t.push({label:this.t("Midheaven"),sign:e.midheaven.sign,signLabel:y(e.midheaven,"sign"),degree:e.midheaven.degree,isAngle:true}),{title:this.t("Secondary progressions"),badges:[{label:this.t("Progressed to"),value:M(this.effectiveLang(),e.targetDate)},{label:this.t("Elapsed"),value:this.t("{{years}} yrs",{years:b(this.effectiveLang(),e.elapsedYears,1)})}],summary:e.summary,cols:{house:true,motion:true,formula:false,natal:false},rows:[...t,...e.planets.map(r=>({body:r.name,label:y(r,"name"),sign:r.sign,signLabel:y(r,"sign"),degree:r.degree,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde,interpretation:r.interpretation}))]}}};qa.endpoints=rc,qa.styles=[u,X,me,pe.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}header{gap:var(--roxy-space-sm);display:grid}.summary{font-size:var(--roxy-text-sm)}.scroll{min-width:0;overflow-x:auto}table{width:100%}caption{caption-side:top;text-align:start;padding-block-end:var(--roxy-space-xs)}:is(th,td){white-space:nowrap}:is(th,td).num{text-align:end}.body-cell{font-weight:var(--roxy-weight-bold)}.body-cell .glyph{color:var(--roxy-accent-ink);margin-inline-end:var(--roxy-space-xs)}tr.angle td{color:var(--roxy-secondary)}.sign{align-items:baseline;gap:var(--roxy-space-xs);display:inline-flex}.sign .sg{color:var(--roxy-secondary)}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}.formula{color:var(--roxy-muted);white-space:normal}`],m([(0,Oh.property)({type:String})],qa.prototype,"heading",2),qa=m([x("roxy-positions-table")],qa);var gt=require("lit");var Zr=class extends g{renderData(a){let e=J(a.profectedSign),t=S(a.lordOfYear),r=J(a.lordNatalPosition?.sign);return gt.html`<div class="wrap" part="card"><header part="header"><h2>${this.t("Annual profection")}</h2>${a.targetDate?gt.html`<p class="roxy-label">${this.t("For")} ${M(this.effectiveLang(),a.targetDate)}</p>`:gt.nothing}</header><div class="focus" part="details"><div class="age"><span class="n">${a.age}</span> <span class="roxy-label">${this.t("Age")}</span></div><span class="arrow">${this.t("Activates")}</span><div class="house"><span class="h">${this.t("House")} ${a.profectedHouse}</span> <span class="sign">${e?gt.html`<span class="sg roxy-glyph">${e}</span>`:gt.nothing}${a.profectedSign}</span></div></div><div class="lord" part="details"><span class="roxy-label">${this.t("Lord of the year")}</span> <span class="value">${t?gt.html`<span class="sg roxy-glyph" aria-hidden="true">${t}</span>`:gt.nothing}${a.lordOfYear}</span> ${a.lordNatalPosition?gt.html`<span class="sub">${this.t("Natal")} ${r?gt.html`<span class="sg roxy-glyph" aria-hidden="true">${r}</span>`:gt.nothing}${this.t("{{sign}} \xB7 house {{house}}",{sign:a.lordNatalPosition.sign,house:a.lordNatalPosition.house})}</span>`:gt.nothing}</div>${a.interpretation&&!this.hideReadings?gt.html`<p class="interp">${a.interpretation}</p>`:gt.nothing}</div>`}};Zr.endpoints=sc,Zr.styles=[u,gt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}header{gap:var(--roxy-space-xs);display:grid}.focus{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.age,.house{gap:calc(var(--roxy-space-unit) / 2);display:grid}.age{justify-items:center}.age .n{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight);font-variant-numeric:tabular-nums}.arrow{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.house .h{font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.house .sign{color:var(--roxy-secondary);font-size:var(--roxy-text-sm)}.sg{margin-inline-end:var(--roxy-space-xs)}.lord{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;padding-block-start:var(--roxy-space-sm);display:flex}.lord .value{font-weight:var(--roxy-weight-bold)}.lord .sub{color:var(--roxy-muted)}.interp{font-size:var(--roxy-text-sm)}`],Zr=m([x("roxy-profection-card")],Zr);var ct=require("lit");var Ih=["name","english","title"],yf=new Set(["description","meaning","characteristics","tagline","definedMeaning","undefinedMeaning","motto"]);function uf(s){let a=e=>typeof e=="string"?e:void 0;return J(a(s.id))??S(a(s.id))??or(a(s.english))}var ff=new Set(["id","symbol",...Ih]),Gh=48;function xf(s){return D(s).toLowerCase().replace(/\s+/g,"-")}function bf(s){return Object.values(As(s)).filter(a=>typeof a=="string"||typeof a=="number").map(String).join(" \xB7 ")}var Xr=class extends g{renderData(a){let e=As(a),t=this.deriveTitle(e),r=uf(e),n=typeof e.symbol=="string"&&/\p{L}/u.test(e.symbol)?e.symbol:void 0,i=Array.isArray(e.keywords)?e.keywords.map(String):[],o=[],l=[],c=[],d=(p,f,L)=>{if(f!=null){if(Array.isArray(f)){let $=f.filter(k=>k!=null).map(k=>typeof k=="object"?bf(k):String(k)).filter(k=>k.length>0);$.length>0&&l.push([p,$,$.some(k=>k.length>Gh)])}else if(typeof f=="string")yf.has(p)||f.length>Gh?o.push([p,f]):c.push([p,f]);else if(typeof f=="number"||typeof f=="boolean")c.push([p,String(f)]);else if(typeof f=="object"&&L<2)for(let[$,k]of Object.entries(As(f)))d(`${p} ${$}`,k,L+1)}};for(let[p,f]of Object.entries(e))ff.has(p)||p==="keywords"&&Array.isArray(f)||d(p,f,0);let h=!this.hideReadings;return ct.html`<article class="card" part="card" aria-label="${t}"><header class="head" part="header">${r?ct.html`<span class="symbol roxy-glyph" aria-hidden="true">${r}</span>`:n?ct.html`<span class="symbol" aria-hidden="true">${n}</span>`:ct.nothing}<div><p class="roxy-label">${this.t("Reference")}</p><h2>${t}</h2></div></header>${i.length>0&&h?ct.html`<ul class="roxy-chips">${i.map(p=>ct.html`<li>${p}</li>`)}</ul>`:ct.nothing} ${h?o.map(([p,f])=>ct.html`<p class="prose"><span class="roxy-label">${Se(this.effectiveLang(),p)}</span>${f}</p>`):ct.nothing} ${c.length>0?ct.html`<div part="details"><dl class="roxy-facts">${c.map(([p,f])=>ct.html`<div><dt>${Se(this.effectiveLang(),p)}</dt><dd>${f}</dd></div>`)}</dl></div>`:ct.nothing} ${l.map(([p,f,L])=>L&&!h?ct.nothing:ct.html`<div class="list" part="section ${xf(p)}"><h3>${Se(this.effectiveLang(),p)}</h3><ul class="roxy-chips">${f.map($=>ct.html`<li>${$}</li>`)}</ul></div>`)}</article>`}deriveTitle(a){for(let r of Ih)if(typeof a[r]=="string")return a[r];let e=typeof a.type=="string"?D(a.type):"",t=a.number;return t!=null?`${e} ${t}`.trim():this.t("Reference")}};Xr.endpoints=nc,Xr.styles=[u,Re,ct.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.head{align-items:center;gap:var(--roxy-space-md);display:flex}.symbol{color:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-xl) * 1.5);flex:none;line-height:1}.prose .roxy-label{margin-block-end:calc(var(--roxy-space-unit) / 2);display:block}.list h3{margin-block-end:var(--roxy-space-xs)}.roxy-facts{margin:0}`],Xr=m([x("roxy-reference-card")],Xr);var st=require("lit"),Bh=require("lit/directives/if-defined.js");var Fh=s=>S(s)??"",Jr=class extends g{renderData(a){let e=a.changes,t=["latitude","longitude"];return st.html`<div class="stack" part="stack"><roxy-natal-chart heading="Relocation chart" lang="${(0,Bh.ifDefined)(this.effectiveLang())}" exportparts="chart-controls, chart-dialog, card, header, tablist, tab, panel, chart, table, aspects, aspect-grid, element-modality, legend, details, section, patterns, pattern, readings, reading, positions, distribution, houses, strongest" ?hide-readings="${this.hideReadings}" .data="${a}"></roxy-natal-chart><section class="changes" part="card changes"><h2>${this.t("What changes at this location")}</h2>${a.relocation?st.html`<dl class="roxy-facts" part="details">${t.map(r=>st.html`<div><dt>${Se(this.effectiveLang(),r==="latitude"?"relocationLatitude":"relocationLongitude")}</dt><dd>${b(this.effectiveLang(),a.relocation[r],5)}</dd></div>`)}</dl>`:st.nothing}<div class="move" part="details">${typeof e?.distanceKm=="number"?st.html`<span>${Math.round(e.distanceKm)===0?this.t("Same location as birth"):this.t("{{distance}} km {{direction}} of birthplace",{distance:q(this.effectiveLang(),e.distanceKm),direction:e.direction?ie(this.effectiveLang(),"direction",U(e.direction),e.direction):""})}</span>`:st.nothing} ${e?st.html`<span>${a.ascendant?.sign?e.ascendantSignChanged?this.t("Ascendant moves to {{sign}}",{sign:y(a.ascendant,"sign")}):this.t("Ascendant stays in {{sign}}",{sign:y(a.ascendant,"sign")}):e.ascendantSignChanged?this.t("Ascendant changes sign"):this.t("Ascendant keeps its sign")}</span>`:st.nothing}</div>${a.interpretation?.summary&&!this.hideReadings?st.html`<p class="summary">${a.interpretation.summary}</p>`:st.nothing} ${e?.angularPlanets?.length?st.html`<section part="section angular-planets"><h3>${this.t("Angular planets here")}</h3><ul class="roxy-chips">${Cn(e,"angularPlanets").map(({value:r,label:n})=>st.html`<li>${Fh(r)} ${n}</li>`)}</ul></section>`:st.nothing}<section part="section house-changes"><h3>${this.t("Planets that change house")}</h3>${e?.planetsChangedHouse?.length?st.html`<ul class="moves-list">${e.planetsChangedHouse.map(r=>st.html`<li>${Fh(r.planet)} ${this.t("{{planet}}: house {{from}} to {{to}}",{planet:y(r,"planet"),from:r.natalHouse,to:r.relocatedHouse})}</li>`)}</ul>`:st.html`<p class="empty-note">${this.t("No planet changes house at this location.")}</p>`}</section></section></div>`}};Jr.endpoints=ic,Jr.styles=[u,Re,st.css`.stack{gap:var(--roxy-space-md);display:grid}.changes{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,p{margin:0}.changes section{gap:var(--roxy-space-xs);display:grid}.move{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.summary,.moves-list{font-size:var(--roxy-text-sm)}.moves-list{gap:calc(var(--roxy-space-unit) / 2);margin:0;padding:0;list-style:none;display:grid}.empty-note{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}`],Jr=m([x("roxy-relocation-wheel")],Jr);var vs=require("lit"),bs=require("lit/decorators.js");function vf(s,a){let e=atob(s),t=new Uint8Array(e.length);for(let r=0;r<e.length;r++)t[r]=e.charCodeAt(r);return new Blob([t],{type:a})}var Li=class{constructor(a,e){this.host=a;this.type=e;this.revokedOnDisconnect=false;a.addController(this)}urlFor(a){return this.url&&this.source===a?this.url:(this.revoke(),this.url=URL.createObjectURL(vf(a,this.type)),this.source=a,this.url)}hostConnected(){this.revokedOnDisconnect&&(this.revokedOnDisconnect=false,this.host.requestUpdate())}hostDisconnected(){this.revokedOnDisconnect=this.url!==void 0,this.revoke()}revoke(){this.url&&URL.revokeObjectURL(this.url),this.url=void 0,this.source=void 0}};var Lf=/[\\/:*?"<>|]+/g;function $f(s){switch(s.status){case 400:return"Check the details and try again.";case 403:return s.code==="origin_not_allowed"?"This website is not allowed to use this key.":void 0;case 429:return"Too many requests. Try again shortly.";case 503:return"Busy right now. Try again in a moment.";default:return}}function wf(s){let a=Gi(s.color),e=Gi(s.accent),t={...s.name?{name:s.name}:{},...s.logo?{logo:s.logo}:{},...s.footer?{footer:s.footer}:{},...a||e?{colors:{...a?{primary:a}:{},...e?{accent:e}:{}}}:{},...gn(s.font)?{font:s.font}:{},...Ac(s.theme)?{theme:s.theme}:{}};return Object.keys(t).length>0?t:void 0}var Nt=class extends g{constructor(){super(...arguments);this.format="pdf";this.pdfUrl=new Li(this,"application/pdf");this.fitFrame=e=>{let t=e.currentTarget,r=t.contentDocument?.documentElement;if(!r)return;let n=()=>{let i=t.offsetHeight-t.clientHeight;t.style.blockSize=`${Math.ceil(r.getBoundingClientRect().height)+i}px`};n(),this.frameObserver?.disconnect(),this.frameObserver=new ResizeObserver(n),this.frameObserver.observe(r)}}ownRequest(){return{format:this.format==="html"?"html":"pdf",branding:wf({name:this.brandName,logo:this.brandLogo,footer:this.brandFooter,color:this.brandColor,accent:this.brandAccent,font:this.font,theme:this.theme}),readings:this.hideReadings?false:void 0}}disconnectedCallback(){super.disconnectedCallback(),this.frameObserver?.disconnect(),this.frameObserver=void 0}renderData(e){if(e.html)return this.renderDocument(e.html,e.title);if(!e.pdf)return this.renderEmpty();let t=(e.title||this.report||e.template).replace(Lf," ");return vs.html`<article class="card" part="card"><h2 part="header">${e.title}</h2><a class="download" part="download" href="${this.pdfUrl.urlFor(e.pdf)}" download="${`${t}.pdf`}">${this.t("Download PDF")}</a></article>`}renderDocument(e,t){return vs.html`<iframe class="document" part="document" title="${t}" sandbox="allow-same-origin" srcdoc="${e}" @load="${this.fitFrame}"></iframe>`}renderLoading(){return vs.html`<div class="busy" role="status" aria-busy="true" part="loading"><span class="roxy-skeleton"></span><p>${this.t("Preparing your report")}</p></div>`}renderError(e){let t=$f(this.failure);return t?vs.html`<p class="lead" role="alert">${this.t(t)}</p>${super.renderError(e)}`:super.renderError(e)}};Nt.endpoints=oc,Nt.styles=[u,vs.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);justify-items:start;display:grid}h2{margin:0}.download{min-block-size:var(--roxy-touch);padding:var(--roxy-space-sm) var(--roxy-space-lg);background:var(--roxy-accent-ink);color:var(--roxy-bg);border-radius:var(--roxy-radius-md);font-weight:var(--roxy-weight-bold);align-items:center;text-decoration:none;display:inline-flex}.document{border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-lg);background:var(--roxy-surface);inline-size:100%;display:block}.busy{gap:var(--roxy-space-sm);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);display:grid}.busy .roxy-skeleton{block-size:2lh}.busy p,.lead{margin:0}.lead{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold);margin-block-end:var(--roxy-space-sm)}`],m([(0,bs.property)({type:String})],Nt.prototype,"report",2),m([(0,bs.property)({type:String})],Nt.prototype,"format",2),m([(0,bs.property)({type:String,attribute:"brand-name"})],Nt.prototype,"brandName",2),m([(0,bs.property)({type:String,attribute:"brand-logo"})],Nt.prototype,"brandLogo",2),m([(0,bs.property)({type:String,attribute:"brand-footer"})],Nt.prototype,"brandFooter",2),m([(0,bs.property)({type:String})],Nt.prototype,"theme",2),Nt=m([x("roxy-report")],Nt);var zt=require("lit");var Yo=[{key:"sthanaBala",source:"Sthana",color:"var(--roxy-info)"},{key:"digBala",source:"Dig",color:"var(--roxy-success)"},{key:"kalaBala",source:"Kala",color:"var(--roxy-warning)"},{key:"chestaBala",source:"Chesta",color:"var(--roxy-accent)"},{key:"naisargikaBala",source:"Naisargika",color:"var(--roxy-secondary)"},{key:"drikBala",source:"Drik",color:"var(--roxy-danger)"}],Qr=class extends g{renderData(a){if(!a.planets?.length)return this.renderEmpty();let e=[...a.planets].sort((t,r)=>t.relativeRank-r.relativeRank);return zt.html`<div class="wrap" part="card" aria-label="${this.t("Shadbala planetary strength")}"><div class="head" part="header"><h2 class="title">${this.t("Shadbala")}</h2><p class="subtitle">${this.t("{{count}} planets ranked by strength",{count:e.length})}</p>${ve(this.effectiveLang(),a.frame,this.translator)}</div><div role="list" part="chart bars" aria-label="${this.t("Planet strength bars")}">${e.map(t=>this.renderPlanetRow(t))}</div><div class="legend" part="legend" aria-label="${this.t("Strength component legend")}">${Yo.map(t=>zt.html`<div class="legend-row"><span class="legend-swatch" style="background:${t.color}" aria-hidden="true"></span> ${this.t("{{component}} Bala",{component:this.t(t.source)})}</div>`)}</div><p class="footnote" part="legend">${this.t("Ishta Phala is the capacity to give benefic results, Kashta Phala the capacity to give malefic ones. Both are in virupas and are read together, since a planet can be strong and still deliver hardship.")}</p></div>`}renderPlanetRow(a){let e=S(a.planet)??"",t=Yo.map(c=>Math.max(0,a[c.key])),r=t.reduce((c,d)=>c+d,0),n=typeof a.strengthRatio=="number"&&a.strengthRatio>=1,i=n?"adequacy-badge--adequate":"adequacy-badge--weak",o=n?this.t("Adequate"):this.t("Weak"),l=b(this.effectiveLang(),a.totalRupas,2)&&b(this.effectiveLang(),a.minRequired,2)?`${b(this.effectiveLang(),a.totalRupas,2)} / ${b(this.effectiveLang(),a.minRequired,2)} R`:"";return zt.html`<div class="planet-row" role="listitem" aria-label="${this.t("{{planet}} Shadbala",{planet:a.planet})}"><div class="planet-label"><span class="glyph roxy-glyph" aria-hidden="true">${e}</span> ${a.planet} <span class="rank-badge" aria-label="${this.t("rank {{n}}",{n:a.relativeRank})}">#${a.relativeRank}</span></div><div class="bar-wrap"><div class="bar" role="img" aria-label="${this.t("Strength components for {{planet}}",{planet:a.planet})}">${r>0?Yo.map((c,d)=>{let h=t[d];if(h<=0)return zt.nothing;let p=h/r*100;return zt.html`<div class="bar-segment" style="flex-grow:${p};background:${c.color}" title="${this.t("{{component}} {{value}} virupas",{component:this.t(c.source),value:b(this.effectiveLang(),h,1)})}"></div>`}):zt.nothing}</div>${this.renderPhala(a)}</div><div class="pills">${l?zt.html`<span class="rupas-label">${l}</span>`:zt.nothing} <span class="${`adequacy-badge ${i}`}">${o}</span></div></div>`}renderPhala(a){let e=typeof a.ishtaPhala=="number"?a.ishtaPhala:0,t=typeof a.kashtaPhala=="number"?a.kashtaPhala:0;if(e+t<=0)return zt.nothing;let r=b(this.effectiveLang(),e,1)||"0",n=b(this.effectiveLang(),t,1)||"0";return zt.html`<div class="phala" role="img" aria-label="${this.t("Ishta Phala {{ishta}}, Kashta Phala {{kashta}} virupas",{ishta:r,kashta:n})}"><span class="phala-ishta" style="flex-grow:${e}"></span> <span class="phala-kashta" style="flex-grow:${t}"></span></div><div class="phala-label"><span>${this.t("Ishta {{value}}",{value:r})}</span> <span>${this.t("Kashta {{value}}",{value:n})}</span></div>`}};Qr.endpoints=lc,Qr.styles=[u,re,zt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.subtitle,.footnote{margin:0}.subtitle{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.planet-row{align-items:center;gap:var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block-end:1px solid var(--roxy-border);grid-template-columns:14ch minmax(0,1fr) auto;display:grid}.planet-row:last-of-type{border-block-end:0}.planet-label{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);display:flex}.glyph{font-size:var(--roxy-text-base);line-height:1}.bar-wrap,.pills{gap:var(--roxy-space-xs);flex-direction:column;display:flex}.pills{align-items:flex-end}.bar{border-radius:var(--roxy-radius-sm);background:var(--roxy-border);block-size:.5lh;display:flex;overflow:hidden}.bar-segment{height:100%;transition:flex-grow var(--roxy-motion-duration) var(--roxy-motion-easing)}.rupas-label{font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;color:var(--roxy-muted);white-space:nowrap}.phala{border-radius:var(--roxy-radius-full);background:var(--roxy-border);block-size:.25lh;display:flex;overflow:hidden}.phala-ishta{background:var(--roxy-success)}.phala-kashta{background:var(--roxy-danger)}.phala-label{justify-content:space-between;gap:var(--roxy-space-sm);font-size:var(--roxy-text-xs);color:var(--roxy-muted);font-variant-numeric:tabular-nums;display:flex}.footnote{font-size:var(--roxy-text-xs);color:var(--roxy-muted)}.adequacy-badge{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.adequacy-badge--adequate{color:var(--roxy-success-fg)}.adequacy-badge--weak{color:var(--roxy-danger-fg)}.rank-badge{font-size:var(--roxy-text-xs);color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.legend{gap:var(--roxy-space-sm) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);flex-wrap:wrap;padding-block-start:var(--roxy-space-sm);display:flex}.legend-row{align-items:center;gap:var(--roxy-space-xs);font-size:var(--roxy-text-xs);color:var(--roxy-muted);display:flex}.legend-swatch{aspect-ratio:1;border-radius:var(--roxy-radius-sm);flex-shrink:0;block-size:.6lh;display:inline-block}@container (width<=480px){.planet-row{grid-template-rows:auto auto;grid-template-columns:12ch minmax(0,1fr)}.pills{flex-direction:row;grid-column:1/-1;justify-content:flex-start;align-items:center}}`],Qr=m([x("roxy-shadbala-table")],Qr);var A=require("lit"),Wh=require("lit/directives/unsafe-html.js");function qh(s){let a=s?.ascendant;if(!a)return;let e=Ie.findIndex(t=>t.toLowerCase()===a.sign.toLowerCase());return e<0?void 0:e*30+a.degree}var Zo=680,$e=Zo/2,$i=204,kf=186,Hh=160,jh=258,Sf=212,Wo=224,wi=86,ki={glyph:18,degree:10},Rf=1.3,Cf=.95,Kh=8,Vh=4;function es(s,a){return 180+s.ascendant-a}function Yh(s,a={}){let e={t:da(a.lang),locale:a.lang,size:a.typeSize??ki,ascendant:qh(s.person1)??0},t=s.person1?.planets??[],r=s.person2?.planets??[];return R`<svg class="synastry-wheel" xmlns=${ca} viewBox=${`0 0 ${Zo} ${Zo}`} part="chart" role="img" aria-label=${e.t("Dual chart wheel comparing two natal charts")}><title>${e.t("Synastry dual wheel")}</title>
|
|
124
|
+
<circle class="wheel-line" cx=${$e} cy=${$e} r=${$i} stroke-width="1.5" />
|
|
125
|
+
<circle class="wheel-line" cx=${$e} cy=${$e} r=${$i-32} stroke-width="0.8" />
|
|
126
|
+
<circle class="wheel-line" cx=${$e} cy=${$e} r=${wi} stroke-width="0.6" />
|
|
127
|
+
${Tf(e)} ${Ef(e)}
|
|
128
|
+
${Af(e,t,r,s.interAspects??[])}
|
|
129
|
+
${Uh(e,t,Hh,(n,i,o)=>Hh-Ta(n,i,o,ha),"p1",1)} ${Uh(e,r,jh,(n,i,o)=>jh+Ta(n,i,o,ha),"p2",2)}
|
|
130
|
+
${Df(e,s)}
|
|
131
|
+
</svg>`.markup}function Tf(s){return Array.from({length:12},(a,e)=>{let t=es(s,e*30),r=H($e,$e,wi,t),n=H($e,$e,$i,t);return R`<line class="wheel-line" x1=${r.x} y1=${r.y} x2=${n.x} y2=${n.y} stroke-width="0.6" />`})}function Ef(s){return Ie.map((a,e)=>{let t=es(s,e*30+15),r=H($e,$e,kf,t);return R`<text class="sign roxy-glyph" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${J(a)}</text>`})}function Uh(s,a,e,t,r,n){let i={width:Rf*s.size.glyph,height:Cf*s.size.glyph},o=d=>({width:(Ft.whole+(d.isRetrograde===true?Ft.retrograde:0))*s.size.degree,height:Ft.ink*s.size.degree}),l=Bt(i.width,e);return Yt(a,d=>d.longitude,(d,h)=>Math.max(l,Bt((o(d).width+o(h).width)/2,t(90,i,o(d))))).map(({item:d,longitude:h,displayLongitude:p})=>{let f=es(s,p),L=H($e,$e,e,f),$=H($e,$e,t(f,i,o(d)),f),k=S(d.name)??y(d,"name"),j=d.isRetrograde===true,ue=typeof d.house=="number"?` \xB7 ${s.t("House {{n}}",{n:d.house})}`:"",Xe=`${y(d,"name")}${j?` ${s.t("retrograde")}`:""} - ${qt(h)} ${y(d,"sign")}${ue}`,Tt=Math.abs(p-h)>.5,oa=H($e,$e,e+(n===1?Kh:-Kh),es(s,h)),$a=H($e,$e,e+(n===1?Vh:-Vh),f);return R`<g>
|
|
132
|
+
${Tt?R`<line class=${`leader ${r}`} x1=${oa.x} y1=${oa.y} x2=${$a.x} y2=${$a.y} />`:""}
|
|
133
|
+
<text class=${r} x=${L.x} y=${L.y} text-anchor="middle" dominant-baseline="central"><title>${Xe}</title><tspan class="roxy-glyph">${k}</tspan><tspan class="person-tag" dy="-0.55em" dx="0.15em">${n}</tspan></text>
|
|
134
|
+
<text class="planet-deg" x=${$.x} y=${$.y} text-anchor="middle" dominant-baseline="central">${Ut(h).degree}°${j?R`<tspan class="retro roxy-glyph"> ${Ke}</tspan>`:""}</text>
|
|
135
|
+
</g>`})}function Df(s,a){let e=[a.person1,a.person2].flatMap((t,r)=>{let n=qh(t);return n===void 0?[]:[{longitude:n,index:r+1}]});return Yt(e,t=>t.longitude,Bt(34,Wo)).map(({item:t,longitude:r,displayLongitude:n})=>{let i=es(s,r),o=es(s,n),l=H($e,$e,$i,i),c=H($e,$e,Sf,i),d=H($e,$e,Wo,o),h=H($e,$e,Wo-7,o);return R`<g>
|
|
136
136
|
<line class="asc-tick" x1=${l.x} y1=${l.y} x2=${c.x} y2=${c.y} />
|
|
137
|
-
${Math.abs(
|
|
138
|
-
<text class="asc-label" x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${
|
|
139
|
-
</g>`})}function Iu(n,a,e,t){let r=(s,i)=>{let o=V(i);for(let l of s)if(V(l.name)===o&&typeof l.longitude=="number")return l.longitude};return t.filter(La).map(s=>{let i=r(a,s.planet1),o=r(e,s.planet2);if(i===void 0||o===void 0)return"";let l=H($e,$e,hi-2,Wr(n,i)),c=H($e,$e,hi-2,Wr(n,o)),{locale:d}=n,p=b(d,s.orb,1);return T`<line class=${`aspect ${Ze(s)}`} style=${Ts(s)} x1=${l.x} y1=${l.y} x2=${c.x} y2=${c.y}><title>${y(s,"planet1")} ${y(s,"type",He(s))} ${y(s,"planet2")}${p?` (${n.t("Orb")} ${p}\xB0)`:""}</title></line>`})}var Gu=12,Zr=class extends g{constructor(){super(...arguments);this.viewport=new je(this);this.type=new Kr(this,{glyph:[".p1",mi.glyph],degree:[".planet-deg",mi.degree]})}renderData(e){let{person1:t,person2:r,compatibilityScore:s,analysis:i}=e,o=e.interAspects??[],l=t?.planets??[],c=r?.planets??[],d=typeof s=="number"?Math.round(s):void 0,p=i?.overall,h=i?.strengths??[],x=i?.challenges??[],$=l.length>0&&c.length>0,L=[...o].sort((ne,Ce)=>(Ce.strength??0)-(ne.strength??0)),C=L.slice(0,Gu);return A.html`<div class="wrap synastry-wheel" part="card" aria-label="${this.t("Synastry compatibility chart")}"><div class="head" part="header"><h2>${this.t("Synastry")}</h2>${typeof d=="number"?A.html`<span class="score" aria-label="${this.t("Score {{score}} of 100",{score:d})}">${d} / 100</span>`:A.nothing}</div>${this.renderPeople(t,r)} ${$?A.html`${this.viewport.renderChartViewport((0,Lh.unsafeHTML)(vh(e,{lang:this.effectiveLang(),typeSize:this.type.size})),this.t("Synastry dual wheel"),this.translator)}<div class="legend" part="legend"><span><span class="person-dot p1"></span>${this.t("Person 1")}</span> <span><span class="person-dot p2"></span>${this.t("Person 2")}</span> <span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span> <span>${this.t("Sign sectors, not houses")}</span></div>`:A.html`<p role="status">${this.t("Synastry response missing planet positions.")} ${this.t("A current {{endpoint}} response carries {{first}} and {{second}}, and the inter-aspect readings below still work without them.",{endpoint:"/astrology/synastry",first:"person1.planets",second:"person2.planets"})}</p>`} ${this.renderOverlay(t,r)} ${this.renderSummaryCounts(e.summary)} ${p&&!this.hideReadings?A.html`<p class="summary">${p}</p>`:A.nothing} ${C.length>0?A.html`<section class="block" part="section inter-aspects"><h3>${this.t("Inter-aspects")}</h3>${C.map((ne,Ce)=>this.renderAspectCard(ne,Ce))}</section>`:A.nothing} ${L.length>C.length?this.renderCatalog(L):A.nothing} ${!this.hideReadings&&(h.length>0||x.length>0)?A.html`<div class="lists" part="section strengths-challenges">${h.length?A.html`<div><h3>${this.t("Strengths")}</h3><ul>${h.map(ne=>A.html`<li>${ne}</li>`)}</ul></div>`:A.nothing} ${x.length?A.html`<div><h3>${this.t("Challenges")}</h3><ul>${x.map(ne=>A.html`<li>${ne}</li>`)}</ul></div>`:A.nothing}</div>`:A.nothing}</div>`}renderPeople(e,t){let r=(i,o)=>{if(!i)return A.nothing;let l=i.ascendant,d=[["Sun",i.sunSign??"",y(i,"sunSign")],["Moon",i.moonSign??"",y(i,"moonSign")],["ASC",l?.sign??"",l?`${y(l,"sign")} ${Jt(l.degree)}`:""]].filter(([,,p])=>p);return d.length===0?A.nothing:A.html`<div class="person"><span class="person-name"><span class="person-dot p${o}" aria-hidden="true"></span>${i.name||this.t("Person {{n}}",{n:o})}</span><div class="big-three">${d.map(([p,h,x])=>A.html`<span><span class="roxy-label">${this.t(p)}</span> <span aria-hidden="true">${Z(h)??""}</span> ${x}</span>`)}</div></div>`},s=[r(e,1),r(t,2)].filter(i=>i!==A.nothing);return s.length===0?A.nothing:A.html`<div class="people" part="details">${s}</div>`}renderOverlay(e,t){if(!e?.planets?.length||!t?.planets?.length)return A.nothing;let r=(o,l)=>o?.name||this.t("Person {{n}}",{n:l}),s=r(e,1),i=r(t,2);return A.html`<section class="block" part="section house-overlay"><h3>${this.t("Houses")}</h3>${this.renderOverlayTable(e.planets,s,i,1)} ${this.renderOverlayTable(t.planets,i,s,2)}</section>`}renderOverlayTable(e,t,r,s){let i=e.filter(l=>typeof l.houseInOtherChart=="number");if(i.length===0)return A.nothing;let o=`overlay-${s}`;return A.html`<div class="overlay-dir"><h4 id="${o}"><span class="person-dot p${s}" aria-hidden="true"></span>${this.t("{{first}} in the houses of {{second}}",{first:t,second:r})}</h4><div class="scroll" part="table" tabindex="0" role="region" aria-labelledby="${o}"><table aria-labelledby="${o}"><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Own house")}</th></tr></thead><tbody>${i.map(l=>A.html`<tr><td><span aria-hidden="true">${S(l.name)??""}</span> ${y(l,"name")}${l.isRetrograde?A.html`<span class="retro" title="${this.t("retrograde")}">℞</span>`:A.nothing}</td><td><span aria-hidden="true">${Z(l.sign)??""}</span> ${y(l,"sign")}</td><td>${Jt(l.degree)}</td><td class="overlay-house">${l.houseInOtherChart}</td><td class="own-house">${l.house??""}</td></tr>`)}</tbody></table></div></div>`}renderSummaryCounts(e){if(!e||typeof e!="object")return A.nothing;let t=Object.entries(e.byType??{}).sort((r,s)=>s[1]-r[1]);return typeof e.total!="number"&&t.length===0?A.nothing:A.html`<p class="counts" part="details" role="region" aria-label="${this.t("Inter-aspect summary")}">${typeof e.total=="number"?A.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:A.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span> ${t.map(([r,s])=>A.html`<span>${this.t("{{label}}: {{value}}",{label:He({type:r}),value:s})}</span>`)}</p>`}renderAspectCard(e,t){let r=S(e.planet1)??"",s=S(e.planet2)??"",i=e.meaning,o=A.html`<span class="interp-lead"><span aria-hidden="true" class="glyph">${r}</span>${y(e,"planet1")} <span class="asp-name ${Ze(e)}">${y(e,"type",He(e))}</span> <span aria-hidden="true" class="glyph">${s}</span>${y(e,"planet2")}</span>`,l=A.html`<span class="interp-aside"><small>${this.t("orb {{orb}}\xB0 \xB7 str {{strength}}",{orb:b(this.effectiveLang(),e.orb,2),strength:b(this.effectiveLang(),e.strength,0)})}</small></span>`;return this.hideReadings||!i?.relationshipContext&&!i?.description?.short&&!i?.description?.long&&!i?.keywords?.length?A.html`<div class="interp-card" part="reading"><div class="static-head">${o}${l}</div></div>`:A.html`<details class="interp-card" part="reading" name="synastry-aspects" ?open="${t===0}"><summary>${o}${he()}${l}</summary>${this.renderAspectMeaning(i)}</details>`}renderAspectMeaning(e){return A.html`<div class="interp-body">${e.relationshipContext?A.html`<p><span class="context">${this.t("In this pairing")}</span> ${e.relationshipContext}</p>`:A.nothing} ${e.description?.short?A.html`<p>${e.description.short}</p>`:A.nothing} ${e.description?.long&&e.description.long!==e.description.short?A.html`<p>${e.description.long}</p>`:A.nothing} ${as(e.keywords)}</div>`}renderCatalog(e){return A.html`<details class="catalog" part="section aspects inter-aspects"><summary>${he()} ${this.t("All {{count}} inter-aspects",{count:e.length})}</summary><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Inter-aspects")}">${this.renderAspects(e)}</div></details>`}renderAspects(e){return A.html`<table><caption class="roxy-sr-only">${this.t("Inter-chart aspects: the planet from chart 1, the planet from chart 2, the aspect between them, the orb in degrees and the strength.")}</caption><thead><tr><th scope="col">${this.t("Planet 1")}</th><th scope="col">${this.t("Planet 2")}</th><th scope="col">${this.t("Aspect")}</th><th scope="col">${this.t("Orb")}</th><th scope="col">${this.t("Strength")}</th>${this.hideReadings?A.nothing:A.html`<th scope="col">${this.t("Reading")}</th>`}</tr></thead><tbody>${e.map(t=>A.html`<tr><td>${y(t,"planet1")}</td><td>${y(t,"planet2")}</td><td>${y(t,"type",He(t))}</td><td class="orb">${b(this.effectiveLang(),t.orb,1)}</td><td>${b(this.effectiveLang(),t.strength,0)}</td>${this.hideReadings?A.nothing:A.html`<td>${t.meaning?A.html`<details part="reading"><summary>${he()} ${this.t("Reading")}</summary>${this.renderAspectMeaning(t.meaning)}</details>`:A.nothing}</td>`}</tr>`)}</tbody></table>`}};Zr.endpoints=Xl,Zr.styles=[u,Xe,Es,W,me,zd,A.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,h4,p,ul{margin:0}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.score{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,50rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.counts{font-size:var(--roxy-text-sm);color:var(--roxy-fg)}.person-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_person);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.people,.lists{gap:var(--roxy-space-sm) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}.person,.lists>div{gap:var(--roxy-space-xs);align-content:start;display:grid}.person-name{font-weight:var(--roxy-weight-bold)}.big-three{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.lists ul{font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md)}.overlay-dir{gap:var(--roxy-space-xs);display:grid}.overlay-dir+.overlay-dir{margin-block-start:var(--roxy-space-md)}.overlay-house{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.own-house,.retro{color:var(--roxy-muted)}.retro{margin-inline-start:var(--roxy-space-xs)}.glyph{line-height:1}.static-head{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.asp-name,.context{font-weight:var(--roxy-weight-bold)}.catalog>summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);font-size:var(--roxy-text-sm);display:flex}.scroll{min-width:0;overflow-x:auto}.catalog .scroll{margin-block-start:var(--roxy-space-sm)}table{width:100%}td.orb{color:var(--roxy-muted)}td .interp-body{white-space:normal;min-width:32ch}`],Zr=m([f("roxy-synastry-chart")],Zr);var We=require("lit"),$h=require("lit/decorators.js");function us(n,a){return ie(n,"arcana",a,`${V(a)} Arcana`)}function Ws(n,a){return ie(n,"suit",a,V(a))}var Fu=[["love","Love"],["career","Career"],["finances","Finance"],["health","Health"],["spirituality","Spiritual"]],ja=class extends g{constructor(){super(...arguments);this.orientation="upright"}renderData(e){return"card"in e?this.renderDailyCard(e):this.renderFullCard(e)}renderDailyCard(e){let t=e.card,r=!!t.reversed,s=t.keywords??[],i=this.effectiveLang(),o=[t.arcana?us(i,t.arcana):"",t.suit?Ws(i,t.suit):""].filter(Boolean).join(" \xB7 "),l=!this.hideReadings;return We.html`<article class="card" part="card" aria-label="${t.name??this.t("Tarot card")}">${this.renderImage(t.imageUrl,t.name,r)}<div part="header"><div class="meta roxy-label">${o?`${o} \xB7 `:""}<span class="drawn">${r?this.t("drawn reversed"):this.t("drawn upright")}</span></div><h2>${t.name??this.t("Tarot card")}</h2>${e.dailyMessage&&l?We.html`<p class="message">${e.dailyMessage}</p>`:We.nothing} ${t.meaning&&l?We.html`<p class="reading">${t.meaning}</p>`:We.nothing} ${s.length>0&&l?We.html`<ul class="roxy-chips">${s.map(c=>We.html`<li>${c}</li>`)}</ul>`:We.nothing} ${this.renderGuidance(t,"tarot-daily-guidance")}</div></article>`}renderFullCard(e){let t=this.orientation==="reversed",r=t?e.reversed:e.upright,s=(t?e.keywords?.reversed:e.keywords?.upright)??r?.keywords??[],i=!this.hideReadings;return We.html`<article class="card" part="card" aria-label="${e.name??this.t("Tarot card")}">${this.renderImage(e.imageUrl,e.name,t)}<div part="header"><div class="meta roxy-label">${[e.arcana?us(this.effectiveLang(),e.arcana):"",e.suit?Ws(this.effectiveLang(),e.suit):"",e.number!==void 0&&e.number!==null?this.t("no. {{number}}",{number:e.number}):""].filter(Boolean).join(" \xB7 ")}</div><h2>${e.name??this.t("Tarot card")}</h2>${gt({items:[{id:"upright",label:this.t("Upright")},{id:"reversed",label:this.t("Reversed")}],active:this.orientation,onSelect:o=>{this.orientation=o},label:this.t("Card orientation"),idPrefix:"tarot",controls:true})}<div id="tarot-panel-${this.orientation}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="tarot-tab-${this.orientation}">${r?.description&&i?We.html`<p class="reading">${r.description}</p>`:We.nothing} ${s.length>0&&i?We.html`<ul class="roxy-chips">${s.map(o=>We.html`<li>${o}</li>`)}</ul>`:We.nothing} ${this.renderGuidance(r,`tarot-${this.orientation}-guidance`)}</div></div></article>`}renderImage(e,t,r){let s=`image ${r?"reversed":""}`;return e?We.html`<img class="${s}" part="chart" src="${e}" alt="${t??this.t("Tarot card")}">`:We.html`<div class="${s}" part="chart" style="aspect-ratio:0.6;display:flex;align-items:center;justify-content:center;color:var(--roxy-muted)">${t??"?"}</div>`}renderGuidance(e,t){if(!e)return We.nothing;let r=Fu.map(([s,i])=>({label:this.t(i),body:e[s]??""}));return this.renderInterpretation(r,t,"Guidance")}};ja.endpoints=Jl,ja.styles=[u,W,me,ot,We.css`.card{align-items:start;gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,6lh) minmax(0,1fr);display:grid}@container (width<=480px){.card{grid-template-columns:minmax(0,1fr)}}h2,p{margin:0}.image{border-radius:var(--roxy-radius-md);background:var(--roxy-border);width:100%;height:auto;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.image.reversed{transform:rotate(180deg)}.meta{margin-block-end:var(--roxy-space-sm)}.drawn{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.message{margin-block:var(--roxy-space-sm) var(--roxy-space-md)}.reading{white-space:pre-line;margin-block-end:var(--roxy-space-md)}.roxy-tablist{margin-block:var(--roxy-space-sm)}.roxy-chips{margin-block-start:var(--roxy-space-sm)}`],m([(0,$h.state)()],ja.prototype,"orientation",2),ja=m([f("roxy-tarot-card")],ja);var ua=require("lit"),wh=require("lit/decorators.js");var Ka=class extends g{constructor(){super(...arguments);this.heading="";this.rowDetail={tag:"roxy-tarot-card",path:"tarot/cards/{id}"};this.listKey="cards"}renderData(e){let t=e.cards??[];if(t.length===0)return this.renderEmpty();let r=this.heading||this.t("Tarot deck"),s=typeof e.total=="number"?e.total:t.length,i=this.effectiveLang();return ua.html`<section class="wrap" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="count">${s===1?this.t("1 card"):this.t("{{count}} cards",{count:s})}</span></header><ul class="grid" part="section cards">${t.map(o=>ua.html`<li><button type="button" class="tile" aria-pressed="${this.openedRowId===o.id?"true":"false"}" @click="${()=>this.pickRow({id:o.id,name:o.name})}">${o.imageUrl?ua.html`<img class="art" src="${o.imageUrl}" alt="${o.name??this.t("Tarot card")}" loading="lazy">`:ua.html`<div class="art" aria-hidden="true"></div>`}<p class="name">${o.name}</p><p class="meta">${Bu(i,o)}</p></button></li>`)}</ul>${this.renderMore()} ${this.openedRow?ua.html`<div class="detail" part="detail">${this.openedRow}</div>`:ua.nothing}</section>`}};Ka.endpoints=Ql,Ka.styles=[u,ua.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,14ch),1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs);width:100%;padding:var(--roxy-space-xs);color:inherit;border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;border:1px solid #0000;display:grid}.tile[aria-pressed=true],.tile:hover{border-color:var(--roxy-accent)}.detail{margin-block-start:var(--roxy-space-md)}.art{aspect-ratio:2/3;border-radius:var(--roxy-radius-sm);object-fit:cover;background:var(--roxy-border);width:100%}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],m([(0,wh.property)({type:String,reflect:true})],Ka.prototype,"heading",2),Ka=m([f("roxy-tarot-catalog")],Ka);function Bu(n,a){let e=us(n,a.arcana);return a.suit?`${e} \xB7 ${Ws(n,a.suit)}`:e}var se=require("lit"),kh=require("lit/decorators.js");function Hu(n){return n&&n.charAt(0).toUpperCase()+n.slice(1)}var Va=class extends g{constructor(){super(...arguments);this.spread="three-card"}renderData(e){let t="answer"in e,r="cards"in e&&!("spread"in e),s=r?[]:"positions"in e?e.positions??[]:[],i=r&&"cards"in e?e.cards:[],o=t?e:void 0,l=y(o,"strength"),c=o?.card,d=t?this.t("Yes or no"):r?this.t("Card draw"):Hu(("spread"in e?e.spread:"")||this.spread.replace(/-/g," ")),p="question"in e?e.question:void 0,h="summary"in e?e.summary:void 0,x=o?.interpretation,$=o?.answer?o.answer.toLowerCase():"";return se.html`<article class="wrap" part="card" aria-label="${this.t("Tarot spread")}"><header class="head" part="header"><h2 class="title">${d}</h2>${p?se.html`<span class="question">"${p}"</span>`:se.nothing}</header>${t?se.html`<div class="verdict" part="section verdict"><div class="card"><div class="image" part="chart">${c?.imageUrl?se.html`<img src="${c.imageUrl}" alt="${c.name??this.t("Tarot card")}" class="${c.reversed?"reversed":""}">`:se.html`${c?.name??"?"}`}</div><p class="name">${c?.name??""} ${c?.reversed?se.html`<small>${this.t("(reversed)")}</small>`:se.nothing}</p>${c?.arcana?se.html`<p class="roxy-label">${us(this.effectiveLang(),c.arcana)}</p>`:se.nothing}</div><div class="meta" part="details"><div><span class="${`answer ${$}`}">${y(o,"answer")}</span> ${l?se.html`<small>· ${l}</small>`:se.nothing}</div>${c?.keywords&&c.keywords.length>0&&!this.hideReadings?se.html`<ul class="roxy-chips">${c.keywords.map(L=>se.html`<li>${L}</li>`)}</ul>`:se.nothing}</div></div>`:se.nothing} ${s.length>0?se.html`<div class="grid" part="section positions">${s.map(L=>se.html`<div class="card"><p class="roxy-label">${L.name??""}</p><div class="image" part="chart">${L.card?.imageUrl?se.html`<img src="${L.card.imageUrl}" alt="${L.card.name??this.t("Tarot card")}" class="${L.card.reversed?"reversed":""}">`:se.html`${L.card?.name??"?"}`}</div><p class="name">${L.card?.name??""} ${L.card?.reversed?se.html`<small>${this.t("(reversed)")}</small>`:se.nothing}</p>${L.interpretation&&!this.hideReadings?se.html`<p class="interp">${L.interpretation}</p>`:se.nothing}</div>`)}</div>`:se.nothing} ${i.length>0?se.html`<div class="grid" part="section cards">${i.map(L=>se.html`<div class="card"><div class="image" part="chart">${L.imageUrl?se.html`<img src="${L.imageUrl}" alt="${L.name??this.t("Tarot card")}" class="${L.reversed?"reversed":""}">`:se.html`${L.name??"?"}`}</div><p class="name">${L.name??""} ${L.reversed?se.html`<small>${this.t("(reversed)")}</small>`:se.nothing}</p>${L.meaning&&!this.hideReadings?se.html`<p class="interp">${L.meaning}</p>`:se.nothing}</div>`)}</div>`:se.nothing} ${h&&!this.hideReadings?se.html`<p>${h}</p>`:se.nothing} ${x&&!this.hideReadings?se.html`<p>${x}</p>`:se.nothing}</article>`}};Va.endpoints=ec,Va.styles=[u,se.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title{text-transform:capitalize}.question{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-style:italic}.answer{font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight)}.answer.yes{color:var(--roxy-success-fg)}.answer.no{color:var(--roxy-danger-fg)}.answer.maybe{color:var(--roxy-warning-fg)}.verdict{align-items:start;gap:var(--roxy-space-md);grid-template-columns:minmax(0,6lh) minmax(0,1fr);display:grid}@container (width<=26rem){.verdict{grid-template-columns:minmax(0,1fr)}}.verdict .meta{justify-items:start;gap:var(--roxy-space-sm);display:grid}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));display:grid}.card{align-content:start;gap:var(--roxy-space-xs);grid-template-columns:minmax(0,1fr);display:grid}.image{aspect-ratio:.6;border-radius:var(--roxy-radius-sm);background:var(--roxy-border);width:100%;color:var(--roxy-muted);font-size:var(--roxy-text-xs);justify-content:center;align-items:center;display:flex;overflow:hidden}.image img{object-fit:cover;width:100%;height:100%;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.image img.reversed{transform:rotate(180deg)}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.interp{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}`],m([(0,kh.property)({type:String,reflect:true})],Va.prototype,"spread",2),Va=m([f("roxy-tarot-spread")],Va);var F=require("lit");var ui=require("lit/decorators.js"),fi=require("lit/directives/if-defined.js");var Fo=640,le=Fo/2,ju=212,Ku=226,Zs=204,Vu=186,Go=168,Sh=250,Rh=142,Xs=78,Uu=166,Ch={glyph:18,degree:10},qu=.95,Yu=8,Wu=4,gi=(n,a)=>S(n)??a,yi=n=>{let a=new Map;for(let e of n)a.set(V(e.name),e);return a},ta=class extends g{constructor(){super(...arguments);this.viewport=new je(this);this.heading="Transits";this.type=new Kr(this,{glyph:[".natal-glyph",Ch.glyph],degree:[".planet-deg",Ch.degree]})}get effectiveAscendant(){for(let e of[this.ascendant,this.data?.ascendant?.longitude])if(typeof e=="number"&&Number.isFinite(e))return e}get ascendantGiven(){return this.effectiveAscendant!==void 0}get cuspsFromPage(){return Array.isArray(this.houses)}get cusps(){let e=this.houses??this.data?.houses;if(!Array.isArray(e)||e.length!==12)return null;let t=e.map((s,i)=>typeof s=="number"?{number:i+1,longitude:s}:{number:Number(s?.number),longitude:Number(s?.longitude)}).sort((s,i)=>s.number-i.number);return t.every((s,i)=>s.number===i+1&&Number.isFinite(s.longitude))?t:null}toAngle(e){return 180+(this.effectiveAscendant??this.cusps?.[0]?.longitude??0)-e}renderData(e){let t=e.natalPlanets??[],r=e.transitPlanets??[],s=e.aspects??[],i=ue(this.effectiveLang(),e.transitDate),o=s.length>0?this.t("Aspects to the natal chart: {{count}}",{count:s.length}):"",l=[...t,...r].some(c=>Number.isFinite(c.house));return F.html`<div class="wrap" part="card" aria-label="${this.t("Natal and transit bi-wheel")}"><div class="head" part="header"><h2>${this.t(this.heading)}</h2>${i||o?F.html`<p class="roxy-label">${[i,o].filter(Boolean).join(" \xB7 ")}</p>`:F.nothing}</div>${this.renderWheel(t,r,s)} ${this.renderLegend(t,r,s,l?e.houseSystem:void 0)} ${this.renderSummary(e.summary)} ${this.renderPositions(t,r,l)} ${this.renderPositionDetails(e)} ${this.renderAspectDetails(s)}</div>`}get orientationCaption(){return this.ascendantGiven?this.t("Ascendant on the left horizon"):this.cusps?this.t("First house cusp on the left horizon"):this.t("Sign wheel, 0\xB0 Aries on the left")}get cuspCaption(){return this.cusps?this.cuspsFromPage?this.t("House cusps supplied by the page"):this.t("House cusps from the response"):this.t("No house cusps")}renderWheel(e,t,r){return this.viewport.renderChartViewport(F.html`<svg viewBox="0 0 ${Fo} ${Fo}" part="chart" role="img" aria-label="${this.t("Bi-wheel with natal bodies on the inner ring and transiting bodies on the outer ring")}"><title>${this.t("Natal and transit bi-wheel")}</title><desc>${this.t("Twelve zodiac sign segments around a circular wheel. Natal bodies sit at their ecliptic longitudes on the inner ring and transiting bodies on the outer ring, and each line joins a transiting body to the natal body it aspects.")} ${this.orientationCaption}. ${this.cuspCaption}.</desc><circle class="wheel-line" cx="${le}" cy="${le}" r="${Zs}" stroke-width="1.5"/><circle class="wheel-line" cx="${le}" cy="${le}" r="${Go}" stroke-width="0.8"/><circle class="wheel-line" cx="${le}" cy="${le}" r="${Xs}" stroke-width="0.5"/>${this.renderTicks()} ${this.renderSpokes()} ${this.renderSigns()} ${this.renderHouses()} ${this.renderAspectLines(e,t,r)} ${this.renderRing(e,Rh,(s,i,o)=>Rh-wa(s,i,o,oa),"natal-glyph",this.t("Natal"),1)} ${this.renderRing(t,Sh,(s,i,o)=>Sh+wa(s,i,o,oa),"transit-glyph",this.t("Transiting"),-1)} ${this.renderAxis()}</svg>`,this.t("Natal and transit bi-wheel"),this.translator)}renderTicks(){let e=[];for(let t=0;t<360;t+=5){let r=this.toAngle(t),s=t%30===0,i=H(le,le,s?Go:Zs-5,r),o=H(le,le,Zs,r);e.push(F.svg`<line class=${s?"tick tick-major":"tick"} x1=${i.x} y1=${i.y} x2=${o.x} y2=${o.y} stroke-width=${s?1:.5} />`)}return e}renderSpokes(){return Ie.map((e,t)=>{let r=this.toAngle(t*30),s=H(le,le,Xs,r),i=H(le,le,Zs,r);return F.svg`<line class="wheel-line" x1=${s.x} y1=${s.y} x2=${i.x} y2=${i.y} stroke-width="0.6" />`})}renderHouses(){let e=this.cusps;return e?e.map((t,r)=>{let s=e[(r+1)%12],i=this.toAngle(t.longitude),o=H(le,le,Xs,i),l=H(le,le,Go,i),c=H(le,le,Uu,this.toAngle($n(t.longitude,s?.longitude??t.longitude+30)));return F.svg`<g>
|
|
137
|
+
${Math.abs(n-r)>.5?R`<line class="asc-tick" x1=${c.x} y1=${c.y} x2=${h.x} y2=${h.y} />`:""}
|
|
138
|
+
<text class="asc-label" x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${s.t("ASC{{n}}",{n:t.index})}</text>
|
|
139
|
+
</g>`})}function Af(s,a,e,t){let r=(n,i)=>{let o=U(i);for(let l of n)if(U(l.name)===o&&typeof l.longitude=="number")return l.longitude};return t.filter(Ra).map(n=>{let i=r(a,n.planet1),o=r(e,n.planet2);if(i===void 0||o===void 0)return"";let l=H($e,$e,wi-2,es(s,i)),c=H($e,$e,wi-2,es(s,o)),{locale:d}=s,h=b(d,n.orb,1);return R`<line class=${`aspect ${Qe(n)}`} style=${zs(n)} x1=${l.x} y1=${l.y} x2=${c.x} y2=${c.y}><title>${y(n,"planet1")} ${y(n,"type",je(n))} ${y(n,"planet2")}${h?` (${s.t("Orb")} ${h}\xB0)`:""}</title></line>`})}var Pf=12,ts=class extends g{constructor(){super(...arguments);this.viewport=new Ve(this);this.type=new Wr(this,{glyph:[".p1",ki.glyph],degree:[".planet-deg",ki.degree]})}renderData(e){let{person1:t,person2:r,compatibilityScore:n,analysis:i}=e,o=e.interAspects??[],l=t?.planets??[],c=r?.planets??[],d=typeof n=="number"?Math.round(n):void 0,h=i?.overall,p=i?.strengths??[],f=i?.challenges??[],L=l.length>0&&c.length>0,$=[...o].sort((j,ue)=>(ue.strength??0)-(j.strength??0)),k=$.slice(0,Pf);return A.html`<div class="wrap synastry-wheel" part="card" aria-label="${this.t("Synastry compatibility chart")}"><div class="head" part="header"><h2>${this.t("Synastry")}</h2>${typeof d=="number"?A.html`<span class="score" aria-label="${this.t("Score {{score}} of 100",{score:d})}">${d} / 100</span>`:A.nothing}</div>${this.renderPeople(t,r)} ${L?A.html`${this.viewport.renderChartViewport((0,Wh.unsafeHTML)(Yh(e,{lang:this.effectiveLang(),typeSize:this.type.size})),this.t("Synastry dual wheel"),this.translator)}<div class="legend" part="legend"><span><span class="person-dot p1"></span>${this.t("Person 1")}</span> <span><span class="person-dot p2"></span>${this.t("Person 2")}</span> <span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span> <span>${this.t("Sign sectors, not houses")}</span></div>`:A.html`<p role="status">${this.t("Synastry response missing planet positions.")} ${this.t("A current {{endpoint}} response carries {{first}} and {{second}}, and the inter-aspect readings below still work without them.",{endpoint:"/astrology/synastry",first:"person1.planets",second:"person2.planets"})}</p>`} ${this.renderOverlay(t,r)} ${this.renderSummaryCounts(e.summary)} ${h&&!this.hideReadings?A.html`<p class="summary">${h}</p>`:A.nothing} ${k.length>0?A.html`<section class="block" part="section inter-aspects"><h3>${this.t("Inter-aspects")}</h3>${k.map((j,ue)=>this.renderAspectCard(j,ue))}</section>`:A.nothing} ${$.length>k.length?this.renderCatalog($):A.nothing} ${!this.hideReadings&&(p.length>0||f.length>0)?A.html`<div class="lists" part="section strengths-challenges">${p.length?A.html`<div><h3>${this.t("Strengths")}</h3><ul>${p.map(j=>A.html`<li>${j}</li>`)}</ul></div>`:A.nothing} ${f.length?A.html`<div><h3>${this.t("Challenges")}</h3><ul>${f.map(j=>A.html`<li>${j}</li>`)}</ul></div>`:A.nothing}</div>`:A.nothing}</div>`}renderPeople(e,t){let r=(i,o)=>{if(!i)return A.nothing;let l=i.ascendant,d=[["Sun",i.sunSign??"",y(i,"sunSign")],["Moon",i.moonSign??"",y(i,"moonSign")],["ASC",l?.sign??"",l?`${y(l,"sign")} ${ta(l.degree)}`:""]].filter(([,,h])=>h);return d.length===0?A.nothing:A.html`<div class="person"><span class="person-name"><span class="person-dot p${o}" aria-hidden="true"></span>${i.name||this.t("Person {{n}}",{n:o})}</span><div class="big-three">${d.map(([h,p,f])=>A.html`<span><span class="roxy-label">${this.t(h)}</span> <span class="roxy-glyph" aria-hidden="true">${J(p)??""}</span> ${f}</span>`)}</div></div>`},n=[r(e,1),r(t,2)].filter(i=>i!==A.nothing);return n.length===0?A.nothing:A.html`<div class="people" part="details">${n}</div>`}renderOverlay(e,t){if(!e?.planets?.length||!t?.planets?.length)return A.nothing;let r=(o,l)=>o?.name||this.t("Person {{n}}",{n:l}),n=r(e,1),i=r(t,2);return A.html`<section class="block" part="section house-overlay"><h3>${this.t("Houses")}</h3>${this.renderOverlayTable(e.planets,n,i,1)} ${this.renderOverlayTable(t.planets,i,n,2)}</section>`}renderOverlayTable(e,t,r,n){let i=e.filter(l=>typeof l.houseInOtherChart=="number");if(i.length===0)return A.nothing;let o=`overlay-${n}`;return A.html`<div class="overlay-dir"><h4 id="${o}"><span class="person-dot p${n}" aria-hidden="true"></span>${this.t("{{first}} in the houses of {{second}}",{first:t,second:r})}</h4><div class="scroll" part="table" tabindex="0" role="region" aria-labelledby="${o}"><table aria-labelledby="${o}"><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Own house")}</th></tr></thead><tbody>${i.map(l=>A.html`<tr><td><span class="roxy-glyph" aria-hidden="true">${S(l.name)??""}</span> ${y(l,"name")}${l.isRetrograde?A.html`<span class="retro roxy-glyph" title="${this.t("retrograde")}">${Ke}</span>`:A.nothing}</td><td><span class="roxy-glyph" aria-hidden="true">${J(l.sign)??""}</span> ${y(l,"sign")}</td><td>${ta(l.degree)}</td><td class="overlay-house">${l.houseInOtherChart}</td><td class="own-house">${l.house??""}</td></tr>`)}</tbody></table></div></div>`}renderSummaryCounts(e){if(!e||typeof e!="object")return A.nothing;let t=Object.entries(e.byType??{}).sort((r,n)=>n[1]-r[1]);return typeof e.total!="number"&&t.length===0?A.nothing:A.html`<p class="counts" part="details" role="region" aria-label="${this.t("Inter-aspect summary")}">${typeof e.total=="number"?A.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:A.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span> ${t.map(([r,n])=>A.html`<span>${this.t("{{label}}: {{value}}",{label:je({type:r}),value:n})}</span>`)}</p>`}renderAspectCard(e,t){let r=S(e.planet1)??"",n=S(e.planet2)??"",i=e.meaning,o=A.html`<span class="interp-lead"><span aria-hidden="true" class="glyph roxy-glyph">${r}</span>${y(e,"planet1")} <span class="asp-name ${Qe(e)}">${y(e,"type",je(e))}</span> <span aria-hidden="true" class="glyph roxy-glyph">${n}</span>${y(e,"planet2")}</span>`,l=A.html`<span class="interp-aside"><small>${this.t("orb {{orb}}\xB0 \xB7 str {{strength}}",{orb:b(this.effectiveLang(),e.orb,2),strength:b(this.effectiveLang(),e.strength,0)})}</small></span>`;return this.hideReadings||!i?.relationshipContext&&!i?.description?.short&&!i?.description?.long&&!i?.keywords?.length?A.html`<div class="interp-card" part="reading"><div class="static-head">${o}${l}</div></div>`:A.html`<details class="interp-card" part="reading" name="synastry-aspects" ?open="${t===0}"><summary>${o}${he()}${l}</summary>${this.renderAspectMeaning(i)}</details>`}renderAspectMeaning(e){return A.html`<div class="interp-body">${e.relationshipContext?A.html`<p><span class="context">${this.t("In this pairing")}</span> ${e.relationshipContext}</p>`:A.nothing} ${e.description?.short?A.html`<p>${e.description.short}</p>`:A.nothing} ${e.description?.long&&e.description.long!==e.description.short?A.html`<p>${e.description.long}</p>`:A.nothing} ${os(e.keywords)}</div>`}renderCatalog(e){return A.html`<details class="catalog" part="section aspects inter-aspects"><summary>${he()} ${this.t("All {{count}} inter-aspects",{count:e.length})}</summary><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Inter-aspects")}">${this.renderAspects(e)}</div></details>`}renderAspects(e){return A.html`<table><caption class="roxy-sr-only">${this.t("Inter-chart aspects: the planet from chart 1, the planet from chart 2, the aspect between them, the orb in degrees and the strength.")}</caption><thead><tr><th scope="col">${this.t("Planet 1")}</th><th scope="col">${this.t("Planet 2")}</th><th scope="col">${this.t("Aspect")}</th><th scope="col">${this.t("Orb")}</th><th scope="col">${this.t("Strength")}</th>${this.hideReadings?A.nothing:A.html`<th scope="col">${this.t("Reading")}</th>`}</tr></thead><tbody>${e.map(t=>A.html`<tr><td>${y(t,"planet1")}</td><td>${y(t,"planet2")}</td><td>${y(t,"type",je(t))}</td><td class="orb">${b(this.effectiveLang(),t.orb,1)}</td><td>${b(this.effectiveLang(),t.strength,0)}</td>${this.hideReadings?A.nothing:A.html`<td>${t.meaning?A.html`<details part="reading"><summary>${he()} ${this.t("Reading")}</summary>${this.renderAspectMeaning(t.meaning)}</details>`:A.nothing}</td>`}</tr>`)}</tbody></table>`}};ts.endpoints=cc,ts.styles=[u,et,Os,X,me,Ld,A.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,h3,h4,p,ul{margin:0}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.score{color:var(--roxy-accent-ink);font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,50rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-xs);color:var(--roxy-muted);flex-wrap:wrap;display:flex}.counts{font-size:var(--roxy-text-sm);color:var(--roxy-fg)}.person-dot{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_person);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.people,.lists{gap:var(--roxy-space-sm) var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,28ch),1fr));display:grid}.person,.lists>div{gap:var(--roxy-space-xs);align-content:start;display:grid}.person-name{font-weight:var(--roxy-weight-bold)}.big-three{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.lists ul{font-size:var(--roxy-text-sm);padding-inline-start:var(--roxy-space-md)}.overlay-dir{gap:var(--roxy-space-xs);display:grid}.overlay-dir+.overlay-dir{margin-block-start:var(--roxy-space-md)}.overlay-house{color:var(--roxy-accent-ink);font-weight:var(--roxy-weight-bold)}.own-house,.retro{color:var(--roxy-muted)}.retro{margin-inline-start:var(--roxy-space-xs)}.glyph{line-height:1}.static-head{align-items:center;gap:var(--roxy-space-sm);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.asp-name,.context{font-weight:var(--roxy-weight-bold)}.catalog>summary{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);font-size:var(--roxy-text-sm);display:flex}.scroll{min-width:0;overflow-x:auto}.catalog .scroll{margin-block-start:var(--roxy-space-sm)}table{width:100%}td.orb{color:var(--roxy-muted)}td .interp-body{white-space:normal;min-width:32ch}`],ts=m([x("roxy-synastry-chart")],ts);var Ze=require("lit"),Zh=require("lit/decorators.js");function Ls(s,a){return ie(s,"arcana",a,`${U(a)} Arcana`)}function sn(s,a){return ie(s,"suit",a,U(a))}var Mf=[["love","Love"],["career","Career"],["finances","Finance"],["health","Health"],["spirituality","Spiritual"]],Ya=class extends g{constructor(){super(...arguments);this.orientation="upright"}renderData(e){return"card"in e?this.renderDailyCard(e):this.renderFullCard(e)}renderDailyCard(e){let t=e.card,r=!!t.reversed,n=t.keywords??[],i=this.effectiveLang(),o=[t.arcana?Ls(i,t.arcana):"",t.suit?sn(i,t.suit):""].filter(Boolean).join(" \xB7 "),l=!this.hideReadings;return Ze.html`<article class="card" part="card" aria-label="${t.name??this.t("Tarot card")}">${this.renderImage(t.imageUrl,t.name,r)}<div part="header"><div class="meta roxy-label">${o?`${o} \xB7 `:""}<span class="drawn">${r?this.t("drawn reversed"):this.t("drawn upright")}</span></div><h2>${t.name??this.t("Tarot card")}</h2>${e.dailyMessage&&l?Ze.html`<p class="message">${e.dailyMessage}</p>`:Ze.nothing} ${t.meaning&&l?Ze.html`<p class="reading">${t.meaning}</p>`:Ze.nothing} ${n.length>0&&l?Ze.html`<ul class="roxy-chips">${n.map(c=>Ze.html`<li>${c}</li>`)}</ul>`:Ze.nothing} ${this.renderGuidance(t,"tarot-daily-guidance")}</div></article>`}renderFullCard(e){let t=this.orientation==="reversed",r=t?e.reversed:e.upright,n=(t?e.keywords?.reversed:e.keywords?.upright)??r?.keywords??[],i=!this.hideReadings;return Ze.html`<article class="card" part="card" aria-label="${e.name??this.t("Tarot card")}">${this.renderImage(e.imageUrl,e.name,t)}<div part="header"><div class="meta roxy-label">${[e.arcana?Ls(this.effectiveLang(),e.arcana):"",e.suit?sn(this.effectiveLang(),e.suit):"",e.number!==void 0&&e.number!==null?this.t("no. {{number}}",{number:e.number}):""].filter(Boolean).join(" \xB7 ")}</div><h2>${e.name??this.t("Tarot card")}</h2>${ut({items:[{id:"upright",label:this.t("Upright")},{id:"reversed",label:this.t("Reversed")}],active:this.orientation,onSelect:o=>{this.orientation=o},label:this.t("Card orientation"),idPrefix:"tarot",controls:true})}<div id="tarot-panel-${this.orientation}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="tarot-tab-${this.orientation}">${r?.description&&i?Ze.html`<p class="reading">${r.description}</p>`:Ze.nothing} ${n.length>0&&i?Ze.html`<ul class="roxy-chips">${n.map(o=>Ze.html`<li>${o}</li>`)}</ul>`:Ze.nothing} ${this.renderGuidance(r,`tarot-${this.orientation}-guidance`)}</div></div></article>`}renderImage(e,t,r){let n=`image ${r?"reversed":""}`;return e?Ze.html`<img class="${n}" part="chart" src="${e}" alt="${t??this.t("Tarot card")}">`:Ze.html`<div class="${n}" part="chart" style="aspect-ratio:0.6;display:flex;align-items:center;justify-content:center;color:var(--roxy-muted)">${t??"?"}</div>`}renderGuidance(e,t){if(!e)return Ze.nothing;let r=Mf.map(([n,i])=>({label:this.t(i),body:e[n]??""}));return this.renderInterpretation(r,t,"Guidance")}};Ya.endpoints=dc,Ya.styles=[u,X,me,dt,Ze.css`.card{align-items:start;gap:var(--roxy-space-lg);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,6lh) minmax(0,1fr);display:grid}@container (width<=480px){.card{grid-template-columns:minmax(0,1fr)}}h2,p{margin:0}.image{border-radius:var(--roxy-radius-md);background:var(--roxy-border);width:100%;height:auto;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing);display:block}.image.reversed{transform:rotate(180deg)}.meta{margin-block-end:var(--roxy-space-sm)}.drawn{color:var(--roxy-fg);font-weight:var(--roxy-weight-bold)}.message{margin-block:var(--roxy-space-sm) var(--roxy-space-md)}.reading{white-space:pre-line;margin-block-end:var(--roxy-space-md)}.roxy-tablist{margin-block:var(--roxy-space-sm)}.roxy-chips{margin-block-start:var(--roxy-space-sm)}`],m([(0,Zh.state)()],Ya.prototype,"orientation",2),Ya=m([x("roxy-tarot-card")],Ya);var La=require("lit"),Xh=require("lit/decorators.js");var Wa=class extends g{constructor(){super(...arguments);this.heading="";this.rowDetail={tag:"roxy-tarot-card",path:"tarot/cards/{id}"};this.listKey="cards"}renderData(e){let t=e.cards??[];if(t.length===0)return this.renderEmpty();let r=this.heading||this.t("Tarot deck"),n=typeof e.total=="number"?e.total:t.length,i=this.effectiveLang();return La.html`<section class="wrap" part="card" aria-label="${r}"><header class="head" part="header"><h2>${r}</h2><span class="count">${n===1?this.t("1 card"):this.t("{{count}} cards",{count:n})}</span></header><ul class="grid" part="section cards">${t.map(o=>La.html`<li><button type="button" class="tile" aria-pressed="${this.openedRowId===o.id?"true":"false"}" @click="${()=>this.pickRow({id:o.id,name:o.name})}">${o.imageUrl?La.html`<img class="art" src="${o.imageUrl}" alt="${o.name??this.t("Tarot card")}" loading="lazy">`:La.html`<div class="art" aria-hidden="true"></div>`}<p class="name">${o.name}</p><p class="meta">${_f(i,o)}</p></button></li>`)}</ul>${this.renderMore()} ${this.openedRow?La.html`<div class="detail" part="detail">${this.openedRow}</div>`:La.nothing}</section>`}};Wa.endpoints=pc,Wa.styles=[u,La.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.count{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,14ch),1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs);width:100%;padding:var(--roxy-space-xs);color:inherit;border-radius:var(--roxy-radius-md);text-align:start;cursor:pointer;transition:border-color var(--roxy-motion-duration) var(--roxy-motion-easing);background:0 0;border:1px solid #0000;display:grid}.tile[aria-pressed=true],.tile:hover{border-color:var(--roxy-accent)}.detail{margin-block-start:var(--roxy-space-md)}.art{aspect-ratio:2/3;border-radius:var(--roxy-radius-sm);object-fit:cover;background:var(--roxy-border);width:100%}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}`],m([(0,Xh.property)({type:String,reflect:true})],Wa.prototype,"heading",2),Wa=m([x("roxy-tarot-catalog")],Wa);function _f(s,a){let e=Ls(s,a.arcana);return a.suit?`${e} \xB7 ${sn(s,a.suit)}`:e}var ne=require("lit"),Jh=require("lit/decorators.js");function Nf(s){return s&&s.charAt(0).toUpperCase()+s.slice(1)}var Za=class extends g{constructor(){super(...arguments);this.spread="three-card"}renderData(e){let t="answer"in e,r="cards"in e&&!("spread"in e),n=r?[]:"positions"in e?e.positions??[]:[],i=r&&"cards"in e?e.cards:[],o=t?e:void 0,l=y(o,"strength"),c=o?.card,d=t?this.t("Yes or no"):r?this.t("Card draw"):Nf(("spread"in e?e.spread:"")||this.spread.replace(/-/g," ")),h="question"in e?e.question:void 0,p="summary"in e?e.summary:void 0,f=o?.interpretation,L=o?.answer?o.answer.toLowerCase():"";return ne.html`<article class="wrap" part="card" aria-label="${this.t("Tarot spread")}"><header class="head" part="header"><h2 class="title">${d}</h2>${h?ne.html`<span class="question">"${h}"</span>`:ne.nothing}</header>${t?ne.html`<div class="verdict" part="section verdict"><div class="card"><div class="image" part="chart">${c?.imageUrl?ne.html`<img src="${c.imageUrl}" alt="${c.name??this.t("Tarot card")}" class="${c.reversed?"reversed":""}">`:ne.html`${c?.name??"?"}`}</div><p class="name">${c?.name??""} ${c?.reversed?ne.html`<small>${this.t("(reversed)")}</small>`:ne.nothing}</p>${c?.arcana?ne.html`<p class="roxy-label">${Ls(this.effectiveLang(),c.arcana)}</p>`:ne.nothing}</div><div class="meta" part="details"><div><span class="${`answer ${L}`}">${y(o,"answer")}</span> ${l?ne.html`<small>· ${l}</small>`:ne.nothing}</div>${c?.keywords&&c.keywords.length>0&&!this.hideReadings?ne.html`<ul class="roxy-chips">${c.keywords.map($=>ne.html`<li>${$}</li>`)}</ul>`:ne.nothing}</div></div>`:ne.nothing} ${n.length>0?ne.html`<div class="grid" part="section positions">${n.map($=>ne.html`<div class="card"><p class="roxy-label">${$.name??""}</p><div class="image" part="chart">${$.card?.imageUrl?ne.html`<img src="${$.card.imageUrl}" alt="${$.card.name??this.t("Tarot card")}" class="${$.card.reversed?"reversed":""}">`:ne.html`${$.card?.name??"?"}`}</div><p class="name">${$.card?.name??""} ${$.card?.reversed?ne.html`<small>${this.t("(reversed)")}</small>`:ne.nothing}</p>${$.interpretation&&!this.hideReadings?ne.html`<p class="interp">${$.interpretation}</p>`:ne.nothing}</div>`)}</div>`:ne.nothing} ${i.length>0?ne.html`<div class="grid" part="section cards">${i.map($=>ne.html`<div class="card"><div class="image" part="chart">${$.imageUrl?ne.html`<img src="${$.imageUrl}" alt="${$.name??this.t("Tarot card")}" class="${$.reversed?"reversed":""}">`:ne.html`${$.name??"?"}`}</div><p class="name">${$.name??""} ${$.reversed?ne.html`<small>${this.t("(reversed)")}</small>`:ne.nothing}</p>${$.meaning&&!this.hideReadings?ne.html`<p class="interp">${$.meaning}</p>`:ne.nothing}</div>`)}</div>`:ne.nothing} ${p&&!this.hideReadings?ne.html`<p>${p}</p>`:ne.nothing} ${f&&!this.hideReadings?ne.html`<p>${f}</p>`:ne.nothing}</article>`}};Za.endpoints=hc,Za.styles=[u,ne.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.title{text-transform:capitalize}.question{color:var(--roxy-muted);font-size:var(--roxy-text-sm);font-style:italic}.answer{font-size:var(--roxy-text-xl);font-weight:var(--roxy-weight-bold);line-height:var(--roxy-leading-tight)}.answer.yes{color:var(--roxy-success-fg)}.answer.no{color:var(--roxy-danger-fg)}.answer.maybe{color:var(--roxy-warning-fg)}.verdict{align-items:start;gap:var(--roxy-space-md);grid-template-columns:minmax(0,6lh) minmax(0,1fr);display:grid}@container (width<=26rem){.verdict{grid-template-columns:minmax(0,1fr)}}.verdict .meta{justify-items:start;gap:var(--roxy-space-sm);display:grid}.grid{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,16ch),1fr));display:grid}.card{align-content:start;gap:var(--roxy-space-xs);grid-template-columns:minmax(0,1fr);display:grid}.image{aspect-ratio:.6;border-radius:var(--roxy-radius-sm);background:var(--roxy-border);width:100%;color:var(--roxy-muted);font-size:var(--roxy-text-xs);justify-content:center;align-items:center;display:flex;overflow:hidden}.image img{object-fit:cover;width:100%;height:100%;transition:transform var(--roxy-motion-duration) var(--roxy-motion-easing)}.image img.reversed{transform:rotate(180deg)}.name{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.interp{color:var(--roxy-secondary);font-size:var(--roxy-text-xs)}`],m([(0,Jh.property)({type:String,reflect:true})],Za.prototype,"spread",2),Za=m([x("roxy-tarot-spread")],Za);var F=require("lit");var Ci=require("lit/decorators.js"),Ti=require("lit/directives/if-defined.js");var Jo=640,le=Jo/2,zf=212,Of=226,nn=204,Gf=186,Xo=168,Qh=250,em=142,on=78,If=166,tm={glyph:18,degree:10},Ff=.95,Bf=8,Hf=4,Si=(s,a)=>S(s)??a,Ri=s=>{let a=new Map;for(let e of s)a.set(U(e.name),e);return a},sa=class extends g{constructor(){super(...arguments);this.viewport=new Ve(this);this.heading="Transits";this.type=new Wr(this,{glyph:[".natal-glyph",tm.glyph],degree:[".planet-deg",tm.degree]})}get effectiveAscendant(){for(let e of[this.ascendant,this.data?.ascendant?.longitude])if(typeof e=="number"&&Number.isFinite(e))return e}get ascendantGiven(){return this.effectiveAscendant!==void 0}get cuspsFromPage(){return Array.isArray(this.houses)}get cusps(){let e=this.houses??this.data?.houses;if(!Array.isArray(e)||e.length!==12)return null;let t=e.map((n,i)=>typeof n=="number"?{number:i+1,longitude:n}:{number:Number(n?.number),longitude:Number(n?.longitude)}).sort((n,i)=>n.number-i.number);return t.every((n,i)=>n.number===i+1&&Number.isFinite(n.longitude))?t:null}toAngle(e){return 180+(this.effectiveAscendant??this.cusps?.[0]?.longitude??0)-e}renderData(e){let t=e.natalPlanets??[],r=e.transitPlanets??[],n=e.aspects??[],i=fe(this.effectiveLang(),e.transitDate),o=n.length>0?this.t("Aspects to the natal chart: {{count}}",{count:n.length}):"",l=[...t,...r].some(c=>Number.isFinite(c.house));return F.html`<div class="wrap" part="card" aria-label="${this.t("Natal and transit bi-wheel")}"><div class="head" part="header"><h2>${this.t(this.heading)}</h2>${i||o?F.html`<p class="roxy-label">${[i,o].filter(Boolean).join(" \xB7 ")}</p>`:F.nothing}</div>${this.renderWheel(t,r,n)} ${this.renderLegend(t,r,n,l?e.houseSystem:void 0)} ${this.renderSummary(e.summary)} ${this.renderPositions(t,r,l)} ${this.renderPositionDetails(e)} ${this.renderAspectDetails(n)}</div>`}get orientationCaption(){return this.ascendantGiven?this.t("Ascendant on the left horizon"):this.cusps?this.t("First house cusp on the left horizon"):this.t("Sign wheel, 0\xB0 Aries on the left")}get cuspCaption(){return this.cusps?this.cuspsFromPage?this.t("House cusps supplied by the page"):this.t("House cusps from the response"):this.t("No house cusps")}renderWheel(e,t,r){return this.viewport.renderChartViewport(F.html`<svg viewBox="0 0 ${Jo} ${Jo}" part="chart" role="img" aria-label="${this.t("Bi-wheel with natal bodies on the inner ring and transiting bodies on the outer ring")}"><title>${this.t("Natal and transit bi-wheel")}</title><desc>${this.t("Twelve zodiac sign segments around a circular wheel. Natal bodies sit at their ecliptic longitudes on the inner ring and transiting bodies on the outer ring, and each line joins a transiting body to the natal body it aspects.")} ${this.orientationCaption}. ${this.cuspCaption}.</desc><circle class="wheel-line" cx="${le}" cy="${le}" r="${nn}" stroke-width="1.5"/><circle class="wheel-line" cx="${le}" cy="${le}" r="${Xo}" stroke-width="0.8"/><circle class="wheel-line" cx="${le}" cy="${le}" r="${on}" stroke-width="0.5"/>${this.renderTicks()} ${this.renderSpokes()} ${this.renderSigns()} ${this.renderHouses()} ${this.renderAspectLines(e,t,r)} ${this.renderRing(e,em,(n,i,o)=>em-Ta(n,i,o,ha),"natal-glyph",this.t("Natal"),1)} ${this.renderRing(t,Qh,(n,i,o)=>Qh+Ta(n,i,o,ha),"transit-glyph",this.t("Transiting"),-1)} ${this.renderAxis()}</svg>`,this.t("Natal and transit bi-wheel"),this.translator)}renderTicks(){let e=[];for(let t=0;t<360;t+=5){let r=this.toAngle(t),n=t%30===0,i=H(le,le,n?Xo:nn-5,r),o=H(le,le,nn,r);e.push(F.svg`<line class=${n?"tick tick-major":"tick"} x1=${i.x} y1=${i.y} x2=${o.x} y2=${o.y} stroke-width=${n?1:.5} />`)}return e}renderSpokes(){return Ie.map((e,t)=>{let r=this.toAngle(t*30),n=H(le,le,on,r),i=H(le,le,nn,r);return F.svg`<line class="wheel-line" x1=${n.x} y1=${n.y} x2=${i.x} y2=${i.y} stroke-width="0.6" />`})}renderHouses(){let e=this.cusps;return e?e.map((t,r)=>{let n=e[(r+1)%12],i=this.toAngle(t.longitude),o=H(le,le,on,i),l=H(le,le,Xo,i),c=H(le,le,If,this.toAngle(zn(t.longitude,n?.longitude??t.longitude+30)));return F.svg`<g>
|
|
140
140
|
<line class="house-cusp" x1=${o.x} y1=${o.y} x2=${l.x} y2=${l.y} />
|
|
141
141
|
<text class="house-num" x=${c.x} y=${c.y} text-anchor="middle" dominant-baseline="central">${t.number}</text>
|
|
142
|
-
</g>`}):F.nothing}renderSigns(){return Ie.map((e,t)=>{let r=H(le,le,
|
|
143
|
-
${
|
|
144
|
-
<text class=${
|
|
145
|
-
<text class="planet-deg" x=${
|
|
146
|
-
</g>`})}renderAspectLines(e,t,r){let
|
|
142
|
+
</g>`}):F.nothing}renderSigns(){return Ie.map((e,t)=>{let r=H(le,le,Gf,this.toAngle(t*30+15));return F.svg`<text class="sign-glyph roxy-glyph" x=${r.x} y=${r.y} text-anchor="middle" dominant-baseline="central">${J(e)}</text>`})}renderRing(e,t,r,n,i,o){let l=Ff*this.type.size.glyph,c={width:l,height:l},d=f=>({width:(Ft.whole+(f.isRetrograde===true?Ft.retrograde:0))*this.type.size.degree,height:Ft.ink*this.type.size.degree}),h=Bt(l,t);return Yt(e,f=>f.longitude,(f,L)=>Math.max(h,Bt((d(f).width+d(L).width)/2,r(90,c,d(f))))).map(({item:f,longitude:L,displayLongitude:$})=>{let k=this.toAngle($),j=H(le,le,t,k),ue=H(le,le,r(k,c,d(f)),k),Xe=f.isRetrograde===true,Tt=`${Ut(L).degree}\xB0`,oa=y(f,"name"),$a=`${i} ${oa}${Xe?` ${this.t("retrograde")}`:""} - ${qt(L)} ${y(f,"sign")}`,ln=Math.abs($-L)>.5,cn=H(le,le,t+o*Bf,this.toAngle(L)),Hs=H(le,le,t+o*Hf,k);return F.svg`<g>
|
|
143
|
+
${ln?F.svg`<line class=${`leader ${n}`} x1=${cn.x} y1=${cn.y} x2=${Hs.x} y2=${Hs.y} />`:F.nothing}
|
|
144
|
+
<text class=${`${n} roxy-glyph`} x=${j.x} y=${j.y} text-anchor="middle" dominant-baseline="central"><title>${$a}</title>${Si(f.name,oa)}</text>
|
|
145
|
+
<text class="planet-deg" x=${ue.x} y=${ue.y} text-anchor="middle" dominant-baseline="central">${Tt}${Xe?F.svg`<tspan class="retro roxy-glyph"> ${Ke}</tspan>`:F.nothing}</text>
|
|
146
|
+
</g>`})}renderAspectLines(e,t,r){let n=Ri(e),i=Ri(t);return r.filter(Ra).map(o=>{let l=i.get(U(o.planet1)),c=n.get(U(o.planet2));if(!l||!c||!Number.isFinite(l.longitude)||!Number.isFinite(c.longitude))return F.nothing;let d=H(le,le,on-2,this.toAngle(l.longitude)),h=H(le,le,on-2,this.toAngle(c.longitude)),p=Dt(o),f=b(this.effectiveLang(),o.orb,1);return F.svg`<line class=${`aspect ${Qe(o)}`} style=${zs(o)} x1=${d.x} y1=${d.y} x2=${h.x} y2=${h.y}><title>${this.t("Transiting")} ${y(o,"planet1")} ${y(o,"type",p)} ${this.t("Natal")} ${y(o,"planet2")}${f?` (${this.t("Orb")} ${f}\xB0)`:""}</title></line>`})}renderAxis(){let e=this.effectiveAscendant;if(e===void 0)return F.nothing;let t=It(e);return[t,Ws(t)].map((r,n)=>{let i=this.toAngle(r),o=H(le,le,nn,i),l=H(le,le,zf,i),c=H(le,le,Of,i);return F.svg`<g>
|
|
147
147
|
<line class="axis-tick" x1=${o.x} y1=${o.y} x2=${l.x} y2=${l.y} />
|
|
148
|
-
<text class="axis-label" x=${c.x} y=${c.y} text-anchor="middle" dominant-baseline="central">${
|
|
149
|
-
</g>`})}renderLegend(e,t,r,s){return F.html`<div class="legend" part="legend"><span><span class="swatch swatch--natal"></span>${this.t("{{count}} natal bodies",{count:e.length})}</span> <span><span class="swatch swatch--transit"></span>${this.t("{{count}} transiting bodies",{count:t.length})}</span> ${r.length>0?F.html`<span>${this.t("{{count}} aspects",{count:r.filter(La).length})}</span> <span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span>`:F.nothing} ${s?F.html`<span>${this.t("{{label}}: {{value}}",{label:ke(this.effectiveLang(),"houseSystem"),value:ie(this.effectiveLang(),"houseSystem",s)})}</span>`:F.nothing} <span>${this.orientationCaption}</span> <span>${this.cuspCaption}</span></div>`}renderSummary(e){if(!e)return F.nothing;let t=Object.entries(e.byType??{}).sort((r,s)=>s[1]-r[1]);return F.html`<div part="details"><p class="counts" role="region" aria-label="${this.t("Transit aspect summary")}">${typeof e.total=="number"?F.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:F.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span> ${t.map(([r,s])=>F.html`<span>${this.t("{{label}}: {{value}}",{label:He({type:r}),value:s})}</span>`)}</p>${e.strongest?this.renderStrongest(e.strongest):F.nothing}</div>`}renderStrongest(e){let t=y(e,"planet1"),r=y(e,"planet2");return F.html`<div class="strongest" part="details strongest"><span class="roxy-label">${this.t("Strongest")}</span> <span aria-hidden="true" class="glyph">${gi(e.planet1,t)}</span>${this.t("Transiting")} ${t} <span class="asp-name ${Ze(e)}">${y(e,"type",He(e))}</span> <span aria-hidden="true" class="glyph">${gi(e.planet2,r)}</span>${this.t("Natal")} ${r} <span class="meta">${e.isApplying?this.t("Applying"):this.t("Separating")} · ${this.t("Orb")} ${b(this.effectiveLang(),e.orb,2)}° · ${this.t("Strength")} ${b(this.effectiveLang(),e.strength,0)}</span></div>`}renderPositions(e,t,r){if(e.length===0&&t.length===0)return F.nothing;let s=yi(e),i=yi(t),o=e.length>0?e:t,l=d=>d?F.html`${Z(d.sign)??""} ${Vt(d.longitude)} ${y(d,"sign")}${d.isRetrograde?F.html`<span class="retro-badge" aria-label="${this.t("retrograde")}">℞</span>`:F.nothing}`:F.nothing,c=d=>r?F.html`<td>${d&&Number.isFinite(d.house)?d.house:F.nothing}</td>`:F.nothing;return F.html`<div class="scroll" part="table" tabindex="0" role="region" aria-labelledby="transit-positions"><table><caption id="transit-positions" class="roxy-sr-only">${this.t("Every body with its natal position and its position on the transit date, each as a zodiac sign and a degree.")} ${r?this.t("Both house numbers are read against the natal house cusps."):F.nothing}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col"><span class="swatch swatch--natal" aria-hidden="true"></span>${this.t("Natal")}</th>${r?F.html`<th scope="col">${this.t("Natal house")}</th>`:F.nothing}<th scope="col"><span class="swatch swatch--transit" aria-hidden="true"></span>${this.t("Transiting")}</th>${r?F.html`<th scope="col">${this.t("Transiting house")}</th>`:F.nothing}</tr></thead><tbody>${o.map(d=>{let p=V(d.name),h=y(d,"name");return F.html`<tr><th scope="row"><span aria-hidden="true" class="glyph">${gi(d.name,h)}</span> ${h}</th><td>${l(s.get(p))}</td>${c(s.get(p))}<td>${l(i.get(p))}</td>${c(i.get(p))}</tr>`})}</tbody></table></div>`}renderPositionDetails(e){return F.html`<details class="block" part="section positions"><summary>${this.t("Chart details")}</summary><p>${this.t("Natal")}</p><roxy-western-planets-table bare hide-sections="header" lang="${(0,fi.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${{planets:e.natalPlanets,houses:e.houses,ascendant:e.ascendant}}"></roxy-western-planets-table><p>${this.t("Transiting")}</p><roxy-western-planets-table bare hide-sections="header" lang="${(0,fi.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${{planets:e.transitPlanets}}"></roxy-western-planets-table></details>`}renderAspectDetails(e){return e.length===0?F.nothing:F.html`<details class="block" part="section aspects"><summary>${this.t("Aspects ({{count}})",{count:e.length})}</summary><roxy-aspects-table bare hide-sections="header" lang="${(0,fi.ifDefined)(this.effectiveLang())}" ?hide-readings="${this.hideReadings}" exportparts="card, header, section, aspects, details, reading, readings, pattern, patterns, strongest" .data="${{aspects:e}}"></roxy-aspects-table></details>`}};ta.endpoints=tc,ta.styles=[u,Xe,Es,W,F.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}details.block>summary{font-weight:var(--roxy-weight-bold)}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,47.5rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line,.tick{fill:none;stroke:var(--roxy-border)}.tick-major{stroke:var(--roxy-secondary)}.natal-glyph,.swatch--natal{--_ring:var(--roxy-accent-ink)}.transit-glyph,.swatch--transit{--_ring:var(--roxy-fg)}.sign-glyph{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}.transit-glyph,.natal-glyph{fill:var(--_ring);font-size:calc(var(--roxy-text-base) * 1.125);font-weight:var(--roxy-weight-bold)}.leader{stroke:var(--_ring);stroke-width:.6px;opacity:.6}.planet-deg{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .625)}.planet-deg .retro{fill:var(--roxy-danger-fg)}.house-cusp{stroke:var(--roxy-secondary);stroke-width:1px;stroke-dasharray:3 3}.house-num{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .5625)}.axis-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}.axis-label{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .625);font-weight:var(--roxy-weight-bold)}@container (width<=480px){.sign-glyph,.natal-glyph,.transit-glyph{font-size:calc(var(--roxy-text-base) * 1.625)}.planet-deg{font-size:calc(var(--roxy-text-base) * .875)}.house-num{font-size:calc(var(--roxy-text-base) * .75)}}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.counts{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_ring);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.strongest{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;margin-block-start:var(--roxy-space-sm);display:flex}.strongest .meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.glyph{line-height:1}.asp-name{font-weight:var(--roxy-weight-bold)}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){white-space:nowrap}.retro-badge{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}`],m([(0,ui.property)({type:String})],ta.prototype,"heading",2),m([(0,ui.property)({type:Number})],ta.prototype,"ascendant",2),m([(0,ui.property)({type:Array})],ta.prototype,"houses",2),ta=m([f("roxy-transit-wheel")],ta);var mt=require("lit"),Th=require("lit/decorators.js");var Ua=class extends g{constructor(){super(...arguments);this.tab="positions"}renderData(e){if(!e.transitPlanets?.length)return this.renderEmpty();let{transitDate:t,transitTime:r,transitPlanets:s,transitAspects:i,summary:o}=e,l=[M(this.effectiveLang(),t),Nt(this.effectiveLang(),r)].filter(Boolean).join(" "),c=i?.length??0,d=this.tab;return mt.html`<div class="wrap" part="card" aria-label="${this.t("Transits")}"><div class="head" part="header"><h2>${this.t("Transits")}</h2>${l?mt.html`<p class="roxy-label">${l}</p>`:mt.nothing}</div>${c>0?mt.html`${gt({items:[{id:"positions",label:this.t("Positions")},{id:"aspects",label:this.t("Aspects ({{count}})",{count:c})}],active:d,onSelect:p=>{this.tab=p},label:this.t("Transit views"),idPrefix:"transits",controls:true})}<div id="transits-panel-${d}" part="panel" role="tabpanel" aria-labelledby="transits-tab-${d}">${d==="positions"?this.renderPlanetsTable(s):mt.html`${o?this.renderSummaryCounts(o):mt.nothing} ${this.renderAspectsList(i??[])}`}</div>`:this.renderPlanetsTable(s)}</div>`}renderSummaryCounts(e){return mt.html`<p class="counts" part="details" role="region" aria-label="${this.t("Aspect summary")}"><span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.totalAspects})}</span> <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span></p>`}renderPlanetsTable(e){return mt.html`<div class="scroll" tabindex="0" role="region" aria-label="${this.t("Positions")}"><table part="table"><caption class="roxy-sr-only">${this.t("Transiting planets: each planet with its current sign, degree and daily speed.")}</caption><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Speed")}</th></tr></thead><tbody>${e.map(t=>{let r=S(t.name)??"",s=Z(t.sign)??"",i=t.speed>=0?"\u2191":"\u2193";return mt.html`<tr><td><div class="planet-cell"><span class="glyph" aria-hidden="true">${r}</span> ${y(t,"name")} ${t.isRetrograde?mt.html`<span class="retro" aria-label="${this.t("retrograde")}">℞</span>`:mt.nothing}</div></td><td><div class="planet-cell"><span class="glyph" aria-hidden="true">${s}</span> ${y(t,"sign")}</div></td><td class="num">${Jt(t.degree)}</td><td class="speed"><span aria-hidden="true">${i}</span> ${b(this.effectiveLang(),Math.abs(t.speed),2)}${this.t("\xB0/day")}</td></tr>`})}</tbody></table></div>`}renderAspectsList(e){return mt.html`<div part="section aspects" role="list" aria-label="${this.t("Transit aspects")}">${e.map((t,r)=>{let s=S(t.transitPlanet)??"",i=S(t.natalPlanet)??"",o=t.interpretation,l=He(t),c=t.isApplying?this.t("Applying"):this.t("Separating");return mt.html`<details class="aspect-card" part="reading" role="listitem" name="transit-aspects" ?open="${r===0}"><summary><span aria-hidden="true">${s}</span> ${t.transitPlanet} <span class="asp-name ${Ze(t)}">${l}</span> <span aria-hidden="true">${i}</span> ${t.natalPlanet} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:c,orb:b(this.effectiveLang(),t.orb,2),strength:b(this.effectiveLang(),t.strength,1)})} </span>${he()}</summary><div class="interp-body">${zs(o,this.translator)}</div></details>`})}</div>`}};Ua.endpoints=ac,Ua.styles=[u,ot,W,$a,mt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;margin-block-end:var(--roxy-space-sm);display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.scroll{min-width:0;overflow-x:auto}table{width:100%}.glyph{line-height:1}.planet-cell{align-items:baseline;gap:var(--roxy-space-xs);display:flex}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}td.num,.speed{color:var(--roxy-muted)}.speed{white-space:nowrap}.aspect-card{padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.aspect-card summary{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.asp-name{font-weight:var(--roxy-weight-bold)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.aspect-card .interp-body{font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-xs)}.aspect-card .interp-body p{margin:0 0 var(--roxy-space-xs)}`],m([(0,Th.state)()],Ua.prototype,"tab",2),Ua=m([f("roxy-transits-table")],Ua);var aa=require("lit");var Zu=[{key:"timeBased",titleSource:"Time based",noteSource:"From the eightfold division of the day or night, so these depend on the birth time, the place and the weekday."},{key:"sunBased",titleSource:"Sun based",noteSource:"The Dhuma group, derived by fixed arc from the Sun. Dhuma is the Sun plus 133 degrees 20 minutes, and each of the rest follows from the one before it."}],Xr=class extends g{renderData(a){let e=Zu.filter(t=>a[t.key]?.length);return e.length?aa.html`<div class="wrap" part="card" aria-label="${this.t("Upagraha positions")}"><header class="head" part="header"><h2>${this.t("Upagrahas")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header>${e.map(t=>this.renderGroup(t,a[t.key]))}</div>`:this.renderEmpty()}renderGroup(a,e){let t=aa.html`<div class="group-head"><h3>${this.t(a.titleSource)}</h3><p class="group-note">${this.t(a.noteSource)}</p></div><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t(a.titleSource)}"><table role="table"><caption class="roxy-sr-only">${this.t("{{group}} upagrahas: each sub-planet with its rashi, degree in sign, sidereal longitude, and nakshatra with pada.",{group:this.t(a.titleSource)})}</caption><thead><tr><th scope="col">${this.t("Upagraha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th><th scope="col">${this.t("Nakshatra")}</th><th scope="col">${this.t("Pada")}</th></tr></thead><tbody>${e.map(r=>{let s=Z(r.rashi)??"";return aa.html`<tr><td class="name">${r.name}</td><td>${s?aa.html`<span class="glyph">${s}</span>`:aa.nothing}${r.rashi??""}</td><td>${typeof r.longitude=="number"?lt(r.longitude):""}</td><td>${b(this.effectiveLang(),r.longitude,2)}</td><td>${r.nakshatra??""}</td><td>${r.nakshatraPada??""}</td></tr>`})}</tbody></table></div>`;return a.key==="timeBased"?aa.html`<section part="section time-based">${t}</section>`:aa.html`<section part="section sun-based">${t}</section>`}};Xr.endpoints=rc,Xr.styles=[u,ae,aa.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,h3,p{margin:0}.group-head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md) var(--roxy-space-md) 0;display:grid}.group-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr:last-child td{border-block-end:0}td.name{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}`],Xr=m([f("roxy-upagraha-table")],Xr);var _=require("lit"),Ah=require("lit/decorators.js"),Bo=require("lit/directives/if-defined.js");var Xu=["North","East","South","West"],Ju={perimeter:"Perimeter",innerRing:"Inner ring",innerCorner:"Inner corner",center:"Center"},Qu={auspicious:"Favourable",inauspicious:"Unfavourable",mixed:"Mixed"},ef={feet:"ft\xB2",metres:"m\xB2"},xi=.04,tf=8,af=.88;function Eh(n){return"cells"in n}function rf(n){let a=n.map(i=>i.center?.x).filter(i=>i!=null),e=n.map(i=>i.center?.y).filter(i=>i!=null),t=Math.max(0,...n.map(i=>i.rowFromNorth??0),...n.map(i=>i.columnFromWest??0));if(t<2||a.length===0||e.length===0)return;let r=(Math.max(...a)-Math.min(...a))/(t-1),s=(Math.max(...e)-Math.min(...e))/(t-1);if(!(!(r>0)||!(s>0)))return{size:t,cellW:r,cellH:s,originX:Math.min(...a)-r/2,originY:Math.min(...e)-s/2}}function bi(n,a){let e=((a?.x??0)-n.originX)/n.cellW,t=n.size-((a?.y??0)-n.originY)/n.cellH;return[Dh(e),Dh(t)]}function Dh(n){return Math.round(n*1e3)/1e3}var qa=class extends g{constructor(){super(...arguments);this.mode="mandala"}renderData(e){let t=this.effectiveLang(),r=Eh(e)?e:void 0,s=this.mode==="entrance"&&!Eh(e)?e:void 0,i=r?rf(r.cells??[]):sf(e.conventions?.grid);return _.html`<article class="card" part="card" aria-labelledby="vastu-title"><header class="head" part="header"><h2 class="title" id="vastu-title">${s?this.t("Entrance pada"):this.t("Vastu mandala")}</h2>${s?.auspiciousness?_.html`<span class="${`roxy-chip verdict-${s.auspiciousness}`}">${this.verdictLabel(s.auspiciousness)}</span>`:_.nothing}</header>${this.renderGrid(t,i,r,s)} ${this.renderLegend(s,r)} ${this.renderDevatas(t,r?.cells)} ${this.renderFacts(t,e,r,s)} ${s?.effect&&!this.hideReadings?_.html`<p class="effect" part="reading">${s.effect}</p>`:_.nothing} ${s?.reading&&!this.hideReadings?_.html`<p class="reading" part="reading">${s.reading}</p>`:_.nothing} ${this.renderSources(r?.sources??(s?.source?[s.source]:[]))}</article>`}renderGrid(e,t,r,s){if(!t)return _.nothing;let i=t.size,o=`${-xi} ${-xi} ${i+xi*2} ${i+xi*2}`;return _.html`<div class="frame" part="chart">${Xu.map(l=>_.html`<span class="${`compass compass-${l[0]?.toLowerCase()}`}">${ie(e,"facing",l)}</span>`)} <svg viewBox="${o}" role="img" aria-label="${this.t("Vastu grid, north at the top and west on the left")}">${(r?.cells??[]).map(l=>this.renderCell(e,l))} ${s?this.renderEmptyGrid(i):_.nothing} ${s?this.renderDoor(e,s):_.nothing} ${this.renderVamsa(t,r?.vamsa)} ${this.renderBrahmasthan(t,r?.brahmasthan?.polygon)} ${this.renderAtimarma(t,r)}</svg></div>`}renderCell(e,t){let r=t.class??t.role??"",s=["pada",r?`pada-${r}`:"",t.withinPlot===false?"pada-outside":""].filter(Boolean).join(" "),i=t.devataName??"";return this.renderPada(e,t.columnFromWest,t.rowFromNorth,s,t.square,i,[i,this.ringLabel(r)].filter(Boolean).join(" \xB7 "))}renderPada(e,t,r,s,i,o,l){let c=(t??1)-1,d=(r??1)-1,p=o.length>tf;return _.svg`<g>
|
|
150
|
-
<rect class=${
|
|
148
|
+
<text class="axis-label" x=${c.x} y=${c.y} text-anchor="middle" dominant-baseline="central">${n===0?this.t("ASC"):this.t("DSC")}</text>
|
|
149
|
+
</g>`})}renderLegend(e,t,r,n){return F.html`<div class="legend" part="legend"><span><span class="swatch swatch--natal"></span>${this.t("{{count}} natal bodies",{count:e.length})}</span> <span><span class="swatch swatch--transit"></span>${this.t("{{count}} transiting bodies",{count:t.length})}</span> ${r.length>0?F.html`<span>${this.t("{{count}} aspects",{count:r.filter(Ra).length})}</span> <span><span class="aspect-swatch aspect-trine"></span>${this.t("Harmonious aspects")}</span> <span><span class="aspect-swatch aspect-square"></span>${this.t("Challenging aspects")}</span>`:F.nothing} ${n?F.html`<span>${this.t("{{label}}: {{value}}",{label:Se(this.effectiveLang(),"houseSystem"),value:ie(this.effectiveLang(),"houseSystem",n)})}</span>`:F.nothing} <span>${this.orientationCaption}</span> <span>${this.cuspCaption}</span></div>`}renderSummary(e){if(!e)return F.nothing;let t=Object.entries(e.byType??{}).sort((r,n)=>n[1]-r[1]);return F.html`<div part="details"><p class="counts" role="region" aria-label="${this.t("Transit aspect summary")}">${typeof e.total=="number"?F.html`<span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.total})}</span>`:F.nothing} <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span> ${t.map(([r,n])=>F.html`<span>${this.t("{{label}}: {{value}}",{label:je({type:r}),value:n})}</span>`)}</p>${e.strongest?this.renderStrongest(e.strongest):F.nothing}</div>`}renderStrongest(e){let t=y(e,"planet1"),r=y(e,"planet2");return F.html`<div class="strongest" part="details strongest"><span class="roxy-label">${this.t("Strongest")}</span> <span aria-hidden="true" class="glyph roxy-glyph">${Si(e.planet1,t)}</span>${this.t("Transiting")} ${t} <span class="asp-name ${Qe(e)}">${y(e,"type",je(e))}</span> <span aria-hidden="true" class="glyph roxy-glyph">${Si(e.planet2,r)}</span>${this.t("Natal")} ${r} <span class="meta">${e.isApplying?this.t("Applying"):this.t("Separating")} · ${this.t("Orb")} ${b(this.effectiveLang(),e.orb,2)}° · ${this.t("Strength")} ${b(this.effectiveLang(),e.strength,0)}</span></div>`}renderPositions(e,t,r){if(e.length===0&&t.length===0)return F.nothing;let n=Ri(e),i=Ri(t),o=e.length>0?e:t,l=d=>d?F.html`${Je(J(d.sign))} ${qt(d.longitude)} ${y(d,"sign")}${d.isRetrograde?F.html`<span class="retro-badge roxy-glyph" aria-label="${this.t("retrograde")}">${Ke}</span>`:F.nothing}`:F.nothing,c=d=>r?F.html`<td>${d&&Number.isFinite(d.house)?d.house:F.nothing}</td>`:F.nothing;return F.html`<div class="scroll" part="table" tabindex="0" role="region" aria-labelledby="transit-positions"><table><caption id="transit-positions" class="roxy-sr-only">${this.t("Every body with its natal position and its position on the transit date, each as a zodiac sign and a degree.")} ${r?this.t("Both house numbers are read against the natal house cusps."):F.nothing}</caption><thead><tr><th scope="col">${this.t("Body")}</th><th scope="col"><span class="swatch swatch--natal" aria-hidden="true"></span>${this.t("Natal")}</th>${r?F.html`<th scope="col">${this.t("Natal house")}</th>`:F.nothing}<th scope="col"><span class="swatch swatch--transit" aria-hidden="true"></span>${this.t("Transiting")}</th>${r?F.html`<th scope="col">${this.t("Transiting house")}</th>`:F.nothing}</tr></thead><tbody>${o.map(d=>{let h=U(d.name),p=y(d,"name");return F.html`<tr><th scope="row"><span aria-hidden="true" class="glyph roxy-glyph">${Si(d.name,p)}</span> ${p}</th><td>${l(n.get(h))}</td>${c(n.get(h))}<td>${l(i.get(h))}</td>${c(i.get(h))}</tr>`})}</tbody></table></div>`}renderPositionDetails(e){return F.html`<details class="block" part="section positions"><summary>${this.t("Chart details")}</summary><p>${this.t("Natal")}</p><roxy-western-planets-table bare hide-sections="header" lang="${(0,Ti.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${{planets:e.natalPlanets,houses:e.houses,ascendant:e.ascendant}}"></roxy-western-planets-table><p>${this.t("Transiting")}</p><roxy-western-planets-table bare hide-sections="header" lang="${(0,Ti.ifDefined)(this.effectiveLang())}" exportparts="card, header, table, details, section, houses" .data="${{planets:e.transitPlanets}}"></roxy-western-planets-table></details>`}renderAspectDetails(e){return e.length===0?F.nothing:F.html`<details class="block" part="section aspects"><summary>${this.t("Aspects ({{count}})",{count:e.length})}</summary><roxy-aspects-table bare hide-sections="header" lang="${(0,Ti.ifDefined)(this.effectiveLang())}" ?hide-readings="${this.hideReadings}" exportparts="card, header, section, aspects, details, reading, readings, pattern, patterns, strongest" .data="${{aspects:e}}"></roxy-aspects-table></details>`}};sa.endpoints=mc,sa.styles=[u,et,Os,X,F.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}details.block>summary{font-weight:var(--roxy-weight-bold)}svg:where([part~=chart]){width:100%;max-width:var(--roxy-chart-max-width,47.5rem);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line,.tick{fill:none;stroke:var(--roxy-border)}.tick-major{stroke:var(--roxy-secondary)}.natal-glyph,.swatch--natal{--_ring:var(--roxy-accent-ink)}.transit-glyph,.swatch--transit{--_ring:var(--roxy-fg)}.sign-glyph{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .875)}.transit-glyph,.natal-glyph{fill:var(--_ring);font-size:calc(var(--roxy-text-base) * 1.125);font-weight:var(--roxy-weight-bold)}.leader{stroke:var(--_ring);stroke-width:.6px;opacity:.6}.planet-deg{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .625)}.planet-deg .retro{fill:var(--roxy-danger-fg)}.house-cusp{stroke:var(--roxy-secondary);stroke-width:1px;stroke-dasharray:3 3}.house-num{fill:var(--roxy-secondary);font-size:calc(var(--roxy-text-base) * .5625)}.axis-tick{stroke:var(--roxy-accent-ink);stroke-width:1.5px}.axis-label{fill:var(--roxy-accent-ink);font-size:calc(var(--roxy-text-base) * .625);font-weight:var(--roxy-weight-bold)}@container (width<=480px){.sign-glyph,.natal-glyph,.transit-glyph{font-size:calc(var(--roxy-text-base) * 1.625)}.planet-deg{font-size:calc(var(--roxy-text-base) * .875)}.house-num{font-size:calc(var(--roxy-text-base) * .75)}}.legend,.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.counts{color:var(--roxy-fg);font-size:var(--roxy-text-sm)}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border-radius:var(--roxy-radius-full);background:var(--_ring);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.strongest{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);padding-block:var(--roxy-space-sm);border-block:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);flex-wrap:wrap;margin-block-start:var(--roxy-space-sm);display:flex}.strongest .meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.glyph{line-height:1}.asp-name{font-weight:var(--roxy-weight-bold)}.scroll{min-width:0;overflow-x:auto}table{width:100%}:is(th,td){white-space:nowrap}.retro-badge{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold);margin-inline-start:var(--roxy-space-xs)}`],m([(0,Ci.property)({type:String})],sa.prototype,"heading",2),m([(0,Ci.property)({type:Number})],sa.prototype,"ascendant",2),m([(0,Ci.property)({type:Array})],sa.prototype,"houses",2),sa=m([x("roxy-transit-wheel")],sa);var yt=require("lit"),am=require("lit/decorators.js");var Xa=class extends g{constructor(){super(...arguments);this.tab="positions"}renderData(e){if(!e.transitPlanets?.length)return this.renderEmpty();let{transitDate:t,transitTime:r,transitPlanets:n,transitAspects:i,summary:o}=e,l=[M(this.effectiveLang(),t),Ot(this.effectiveLang(),r)].filter(Boolean).join(" "),c=i?.length??0,d=this.tab;return yt.html`<div class="wrap" part="card" aria-label="${this.t("Transits")}"><div class="head" part="header"><h2>${this.t("Transits")}</h2>${l?yt.html`<p class="roxy-label">${l}</p>`:yt.nothing}</div>${c>0?yt.html`${ut({items:[{id:"positions",label:this.t("Positions")},{id:"aspects",label:this.t("Aspects ({{count}})",{count:c})}],active:d,onSelect:h=>{this.tab=h},label:this.t("Transit views"),idPrefix:"transits",controls:true})}<div id="transits-panel-${d}" part="panel" role="tabpanel" aria-labelledby="transits-tab-${d}">${d==="positions"?this.renderPlanetsTable(n):yt.html`${o?this.renderSummaryCounts(o):yt.nothing} ${this.renderAspectsList(i??[])}`}</div>`:this.renderPlanetsTable(n)}</div>`}renderSummaryCounts(e){return yt.html`<p class="counts" part="details" role="region" aria-label="${this.t("Aspect summary")}"><span>${this.t("{{label}}: {{value}}",{label:this.t("Total"),value:e.totalAspects})}</span> <span class="harmonious">${this.t("Harmonious: {{count}}",{count:e.harmonious})}</span> <span class="challenging">${this.t("Challenging: {{count}}",{count:e.challenging})}</span> <span>${this.t("Neutral: {{count}}",{count:e.neutral})}</span></p>`}renderPlanetsTable(e){return yt.html`<div class="scroll" tabindex="0" role="region" aria-label="${this.t("Positions")}"><table part="table"><caption class="roxy-sr-only">${this.t("Transiting planets: each planet with its current sign, degree and daily speed.")}</caption><thead><tr><th scope="col">${this.t("Planet")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Speed")}</th></tr></thead><tbody>${e.map(t=>{let r=S(t.name)??"",n=J(t.sign)??"",i=t.speed>=0?"\u2191":"\u2193";return yt.html`<tr><td><div class="planet-cell"><span class="glyph roxy-glyph" aria-hidden="true">${r}</span> ${y(t,"name")} ${t.isRetrograde?yt.html`<span class="retro roxy-glyph" aria-label="${this.t("retrograde")}">${Ke}</span>`:yt.nothing}</div></td><td><div class="planet-cell"><span class="glyph roxy-glyph" aria-hidden="true">${n}</span> ${y(t,"sign")}</div></td><td class="num">${ta(t.degree)}</td><td class="speed"><span aria-hidden="true">${i}</span> ${b(this.effectiveLang(),Math.abs(t.speed),2)}${this.t("\xB0/day")}</td></tr>`})}</tbody></table></div>`}renderAspectsList(e){return yt.html`<div part="section aspects" role="list" aria-label="${this.t("Transit aspects")}">${e.map((t,r)=>{let n=S(t.transitPlanet)??"",i=S(t.natalPlanet)??"",o=t.interpretation,l=je(t),c=t.isApplying?this.t("Applying"):this.t("Separating");return yt.html`<details class="aspect-card" part="reading" role="listitem" name="transit-aspects" ?open="${r===0}"><summary><span class="roxy-glyph" aria-hidden="true">${n}</span> ${t.transitPlanet} <span class="asp-name ${Qe(t)}">${l}</span> <span class="roxy-glyph" aria-hidden="true">${i}</span> ${t.natalPlanet} <span class="meta">${this.t("{{status}} \xB7 orb {{orb}}\xB0 \xB7 str {{strength}}",{status:c,orb:b(this.effectiveLang(),t.orb,2),strength:b(this.effectiveLang(),t.strength,1)})} </span>${he()}</summary><div class="interp-body">${Vs(o,this.translator)}</div></details>`})}</div>`}};Xa.endpoints=gc,Xa.styles=[u,dt,X,Ca,yt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}h2,p{margin:0}.head{gap:var(--roxy-space-xs);display:grid}.counts{gap:var(--roxy-space-xs) var(--roxy-space-md);font-size:var(--roxy-text-sm);flex-wrap:wrap;margin-block-end:var(--roxy-space-sm);display:flex}.harmonious{color:var(--roxy-info-fg)}.challenging{color:var(--roxy-danger-fg)}.scroll{min-width:0;overflow-x:auto}table{width:100%}.glyph{line-height:1}.planet-cell{align-items:baseline;gap:var(--roxy-space-xs);display:flex}.retro{color:var(--roxy-danger-fg);font-weight:var(--roxy-weight-bold)}td.num,.speed{color:var(--roxy-muted)}.speed{white-space:nowrap}.aspect-card{padding-block:var(--roxy-space-sm);border-block-start:1px solid var(--roxy-border)}.aspect-card summary{align-items:center;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.asp-name{font-weight:var(--roxy-weight-bold)}.meta{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;margin-inline-start:auto}.aspect-card .interp-body{font-size:var(--roxy-text-sm);margin-block-start:var(--roxy-space-xs)}.aspect-card .interp-body p{margin:0 0 var(--roxy-space-xs)}`],m([(0,am.state)()],Xa.prototype,"tab",2),Xa=m([x("roxy-transits-table")],Xa);var na=require("lit");var jf=[{key:"timeBased",titleSource:"Time based",noteSource:"From the eightfold division of the day or night, so these depend on the birth time, the place and the weekday."},{key:"sunBased",titleSource:"Sun based",noteSource:"The Dhuma group, derived by fixed arc from the Sun. Dhuma is the Sun plus 133 degrees 20 minutes, and each of the rest follows from the one before it."}],as=class extends g{renderData(a){let e=jf.filter(t=>a[t.key]?.length);return e.length?na.html`<div class="wrap" part="card" aria-label="${this.t("Upagraha positions")}"><header class="head" part="header"><h2>${this.t("Upagrahas")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header>${e.map(t=>this.renderGroup(t,a[t.key]))}</div>`:this.renderEmpty()}renderGroup(a,e){let t=na.html`<div class="group-head"><h3>${this.t(a.titleSource)}</h3><p class="group-note">${this.t(a.noteSource)}</p></div><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t(a.titleSource)}"><table role="table"><caption class="roxy-sr-only">${this.t("{{group}} upagrahas: each sub-planet with its rashi, degree in sign, sidereal longitude, and nakshatra with pada.",{group:this.t(a.titleSource)})}</caption><thead><tr><th scope="col">${this.t("Upagraha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Longitude")}</th><th scope="col">${this.t("Nakshatra")}</th><th scope="col">${this.t("Pada")}</th></tr></thead><tbody>${e.map(r=>{let n=J(r.rashi)??"";return na.html`<tr><td class="name">${r.name}</td><td>${n?na.html`<span class="glyph roxy-glyph">${n}</span>`:na.nothing}${r.rashi??""}</td><td>${typeof r.longitude=="number"?pt(r.longitude):""}</td><td>${b(this.effectiveLang(),r.longitude,2)}</td><td>${r.nakshatra??""}</td><td>${r.nakshatraPada??""}</td></tr>`})}</tbody></table></div>`;return a.key==="timeBased"?na.html`<section part="section time-based">${t}</section>`:na.html`<section part="section sun-based">${t}</section>`}};as.endpoints=yc,as.styles=[u,re,na.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,h3,p{margin:0}.group-head{gap:var(--roxy-space-xs);padding:var(--roxy-space-md) var(--roxy-space-md) 0;display:grid}.group-note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr:last-child td{border-block-end:0}td.name{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}`],as=m([x("roxy-upagraha-table")],as);var _=require("lit"),nm=require("lit/decorators.js"),Qo=require("lit/directives/if-defined.js");var Kf=["North","East","South","West"],Vf={perimeter:"Perimeter",innerRing:"Inner ring",innerCorner:"Inner corner",center:"Center"},Uf={auspicious:"Favourable",inauspicious:"Unfavourable",mixed:"Mixed"},qf={feet:"ft\xB2",metres:"m\xB2"},Ei=.04,Yf=8,Wf=.88;function rm(s){return"cells"in s}function Zf(s){let a=s.map(i=>i.center?.x).filter(i=>i!=null),e=s.map(i=>i.center?.y).filter(i=>i!=null),t=Math.max(0,...s.map(i=>i.rowFromNorth??0),...s.map(i=>i.columnFromWest??0));if(t<2||a.length===0||e.length===0)return;let r=(Math.max(...a)-Math.min(...a))/(t-1),n=(Math.max(...e)-Math.min(...e))/(t-1);if(!(!(r>0)||!(n>0)))return{size:t,cellW:r,cellH:n,originX:Math.min(...a)-r/2,originY:Math.min(...e)-n/2}}function Di(s,a){let e=((a?.x??0)-s.originX)/s.cellW,t=s.size-((a?.y??0)-s.originY)/s.cellH;return[sm(e),sm(t)]}function sm(s){return Math.round(s*1e3)/1e3}var Ja=class extends g{constructor(){super(...arguments);this.mode="mandala"}renderData(e){let t=this.effectiveLang(),r=rm(e)?e:void 0,n=this.mode==="entrance"&&!rm(e)?e:void 0,i=r?Zf(r.cells??[]):Xf(e.conventions?.grid);return _.html`<article class="card" part="card" aria-labelledby="vastu-title"><header class="head" part="header"><h2 class="title" id="vastu-title">${n?this.t("Entrance pada"):this.t("Vastu mandala")}</h2>${n?.auspiciousness?_.html`<span class="${`roxy-chip verdict-${n.auspiciousness}`}">${this.verdictLabel(n.auspiciousness)}</span>`:_.nothing}</header>${this.renderGrid(t,i,r,n)} ${this.renderLegend(n,r)} ${this.renderDevatas(t,r?.cells)} ${this.renderFacts(t,e,r,n)} ${n?.effect&&!this.hideReadings?_.html`<p class="effect" part="reading">${n.effect}</p>`:_.nothing} ${n?.reading&&!this.hideReadings?_.html`<p class="reading" part="reading">${n.reading}</p>`:_.nothing} ${this.renderSources(r?.sources??(n?.source?[n.source]:[]))}</article>`}renderGrid(e,t,r,n){if(!t)return _.nothing;let i=t.size,o=`${-Ei} ${-Ei} ${i+Ei*2} ${i+Ei*2}`;return _.html`<div class="frame" part="chart">${Kf.map(l=>_.html`<span class="${`compass compass-${l[0]?.toLowerCase()}`}">${ie(e,"facing",l)}</span>`)} <svg viewBox="${o}" role="img" aria-label="${this.t("Vastu grid, north at the top and west on the left")}">${(r?.cells??[]).map(l=>this.renderCell(e,l))} ${n?this.renderEmptyGrid(i):_.nothing} ${n?this.renderDoor(e,n):_.nothing} ${this.renderVamsa(t,r?.vamsa)} ${this.renderBrahmasthan(t,r?.brahmasthan?.polygon)} ${this.renderAtimarma(t,r)}</svg></div>`}renderCell(e,t){let r=t.class??t.role??"",n=["pada",r?`pada-${r}`:"",t.withinPlot===false?"pada-outside":""].filter(Boolean).join(" "),i=t.devataName??"";return this.renderPada(e,t.columnFromWest,t.rowFromNorth,n,t.square,i,[i,this.ringLabel(r)].filter(Boolean).join(" \xB7 "))}renderPada(e,t,r,n,i,o,l){let c=(t??1)-1,d=(r??1)-1,h=o.length>Yf;return _.svg`<g>
|
|
150
|
+
<rect class=${n} x=${c} y=${d} width="1" height="1">
|
|
151
151
|
<title>${l}</title>
|
|
152
152
|
</rect>
|
|
153
|
-
<text class="square-no" x=${c+.5} y=${d+.34}>${
|
|
153
|
+
<text class="square-no" x=${c+.5} y=${d+.34}>${q(e,i)}</text>
|
|
154
154
|
${o?_.svg`<text
|
|
155
155
|
class="devata"
|
|
156
156
|
x=${c+.5}
|
|
157
157
|
y=${d+.68}
|
|
158
|
-
textLength=${(0,
|
|
159
|
-
lengthAdjust=${(0,
|
|
158
|
+
textLength=${(0,Qo.ifDefined)(h?Wf:void 0)}
|
|
159
|
+
lengthAdjust=${(0,Qo.ifDefined)(h?"spacingAndGlyphs":void 0)}
|
|
160
160
|
>${o}</text
|
|
161
161
|
>`:_.nothing}
|
|
162
|
-
</g>`}renderEmptyGrid(e){let t=[];for(let r=0;r<e;r++)for(let s=0;s<e;s++)t.push(_.svg`<rect class="pada" x=${s} y=${r} width="1" height="1"></rect>`);return t}renderDoor(e,t){let r=t.devata?.name??"";return this.renderPada(e,t.cell?.columnFromWest,t.cell?.rowFromNorth,"pada pada-door",t.square,r,r)}renderVamsa(e,t){return(t??[]).map(r=>{let[s,i]=bi(e,r.from),[o,l]=bi(e,r.to);return _.svg`<line class="vamsa" x1=${s} y1=${i} x2=${o} y2=${l}></line>`})}renderBrahmasthan(e,t){let r=t??[];if(r.length<3)return _.nothing;let s=r.map(i=>bi(e,i).join(",")).join(" ");return _.svg`<polygon class="brahmasthan" points=${s}></polygon>`}renderAtimarma(e,t){let r=new Set(t?.atimarma??[]);return r.size===0?_.nothing:(t?.cells??[]).filter(s=>s.square!=null&&r.has(s.square)).map(s=>{let[i,o]=bi(e,s.center);return _.svg`<circle class="atimarma" cx=${i} cy=${o} r="0.06"></circle>`})}renderDevatas(e,t){let r=new Map;for(let s of t??[])!s.devataName||s.square==null||r.set(s.devataName,[...r.get(s.devataName)??[],s.square]);return r.size===0?_.nothing:_.html`<section part="section devatas"><h3 class="block-title">${this.t("Devata")}</h3><ul class="devatas">${[...r].map(([s,i])=>_.html`<li><b>${s}</b> ${i.sort((o,l)=>o-l).map(o=>U(e,o)).join(", ")}</li>`)}</ul></section>`}renderLegend(e,t){if(e)return _.html`<div class="legend" part="legend"><span><span class="swatch swatch-door"></span>${this.t("Door pada")}</span></div>`;let r=(t?.cells??[]).some(s=>s.withinPlot===false);return _.html`<div class="legend" part="legend"><span><span class="swatch swatch-brahma"></span>${this.t("Brahmasthan")}</span> ${r?_.html`<span><span class="swatch swatch-outside"></span>${this.t("Outside the plot")}</span>`:_.nothing}</div>`}renderFacts(e,t,r,s){let i=t.conventions?.grid;return _.html`<div class="facts" part="details">${i?_.html`<span><span class="roxy-label">${ke(e,"grid")}</span><b>${ie(e,"grid",i)}</b></span>`:_.nothing} ${s?.pada!=null?_.html`<span><span class="roxy-label">${this.t("Pada")}</span><b>${U(e,s.pada)}</b></span>`:_.nothing} ${s?.side?_.html`<span><span class="roxy-label">${this.t("Side")}</span><b>${ie(e,"facing",s.side)}</b></span>`:_.nothing} ${s?.startCorner?_.html`<span><span class="roxy-label">${this.t("Counted from")}</span>${ie(e,"facing",s.startCorner)} ${s.ordinalOnSide!=null?_.html`· ${U(e,s.ordinalOnSide)}`:_.nothing}</span>`:_.nothing} ${s?.devata?.name?_.html`<span><span class="roxy-label">${this.t("Devata")}</span><b>${s.devata.name}</b> ${s.devata.padaCount!=null?_.html`· ${this.t("Pada")} ${U(e,s.devata.padaCount)}`:_.nothing}</span>`:_.nothing} ${s?.recommendedPadas?.length?_.html`<span><span class="roxy-label">${this.t("Recommended padas")}</span>${s.recommendedPadas.map(o=>U(e,o)).join(", ")}</span>`:_.nothing} ${r?.brahmasthan?.area!=null?_.html`<span><span class="roxy-label">${this.t("Brahmasthan area")}</span><b>${this.areaLabel(e,r.brahmasthan.area,r.conventions?.unit)}</b></span>`:_.nothing} ${r?.marma?.areaEach!=null?_.html`<span><span class="roxy-label">${this.t("Area of one marma")}</span>${this.areaLabel(e,r.marma.areaEach,r.conventions?.unit)}</span>`:_.nothing} ${r?.atimarma?.length?_.html`<span><span class="roxy-label">${this.t("Crossing points")}</span>${r.atimarma.map(o=>U(e,o)).join(", ")}</span>`:_.nothing}</div>`}renderSources(e){return e.length===0?_.nothing:_.html`<section part="section sources"><ul class="cites">${e.map(t=>_.html`<li>${Ks(t)}</li>`)}</ul></section>`}areaLabel(e,t,r){let s=b(e,t,2);if(!r)return s;let i=ef[r]??`${r}\xB2`;return _.html`<span title="${ie(e,"unit",r)}">${s} ${i}</span>`}ringLabel(e){let t=Ju[e];return t?this.t(t):D(e)}verdictLabel(e){let t=Qu[e];return t?this.t(t):D(e)}};qa.endpoints=sc,qa.styles=[u,_.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);--_brahma:color-mix(in srgb, var(--roxy-accent) 16%, var(--roxy-surface));--_outside:color-mix(in srgb, var(--roxy-muted) 18%, var(--roxy-surface));--_door:color-mix(in srgb, var(--roxy-success) 26%, var(--roxy-surface));grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.verdict-auspicious{color:var(--roxy-success-fg)}.verdict-inauspicious{color:var(--roxy-danger-fg)}.verdict-mixed{color:var(--roxy-warning-fg)}.frame{place-items:center;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-xs);inline-size:100%;max-inline-size:var(--roxy-chart-max-width,32rem);grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:".n.""w plate e"".s.";margin-inline:auto;display:grid}.compass{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.compass-n{grid-area:n}.compass-s{grid-area:s}.compass-w,.compass-e{writing-mode:vertical-rl}.compass-w{grid-area:w;rotate:180deg}.compass-e{grid-area:e}svg{grid-area:plate;width:100%;height:auto;display:block}.pada{fill:var(--roxy-surface);stroke:var(--roxy-border);stroke-width:.012px}.pada-innerRing,.pada-innerCorner,.pada-around-brahma{fill:color-mix(in srgb, var(--roxy-accent) 7%, var(--roxy-surface))}.pada-center,.pada-brahma{fill:var(--_brahma)}.pada-outside{fill:var(--_outside)}.pada-door{fill:var(--_door);stroke:var(--roxy-fg);stroke-width:.03px}.brahmasthan{fill:none;stroke:var(--roxy-accent-ink);stroke-width:.05px}.vamsa{stroke:var(--roxy-secondary);stroke-width:.02px;stroke-dasharray:.12 .1}.atimarma{fill:var(--roxy-accent-ink)}text{fill:var(--roxy-fg);text-anchor:middle}.devata{font-size:calc(var(--roxy-text-base) * .011875)}.square-no{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .00875)}@container (width<=30rem){.devata{display:none}.square-no{font-size:calc(var(--roxy-text-base) * .02125);dominant-baseline:middle;translate:0 .31lh}}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b,.devatas b{color:var(--roxy-fg)}.devatas{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-brahma{background:var(--_brahma)}.swatch-outside{background:var(--_outside)}.swatch-door{background:var(--_door)}.effect{margin:0;padding-block-start:var(--roxy-space-md)}.reading{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);border-block-start:0;margin:0}.cites{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin:0;padding:0;list-style:none}`],m([(0,Ah.property)({type:String,reflect:true})],qa.prototype,"mode",2),qa=m([f("roxy-vastu-mandala")],qa);function sf(n){let a=Number.parseInt(n??"",10),e=Math.round(Math.sqrt(a));if(!(!Number.isFinite(e)||e<2||e*e!==a))return{size:e,originX:0,cellW:1,originY:0,cellH:1}}var rt=require("lit");var Jr=class extends g{renderData(a){let e=a.aspects??[],t=a.mutualAspects??[],r=a.planets??[];if(e.length===0&&t.length===0)return this.renderEmpty();let s=a.datetime?ue(this.effectiveLang(),a.datetime):"";return rt.html`<div class="wrap" part="card" aria-label="${this.t("Vedic aspects")}"><div class="head" part="header"><h2>${this.t("Vedic aspects")}</h2>${s?rt.html`<p class="roxy-label">${this.t("Chart time {{when}}",{when:s})}</p>`:rt.nothing}</div>${r.length>0?rt.html`<div part="section positions"><h3 class="section-label">${this.t("Sidereal positions")}</h3><ul class="roxy-chips">${r.map(i=>rt.html`<li class="position"><strong>${i.name}</strong> ${typeof i.longitude=="number"?lt(i.longitude):i.sign??""}</li>`)}</ul></div>`:rt.nothing} ${t.length>0?rt.html`<div part="section mutual-aspects"><h3 class="section-label">${this.t("Mutual aspects")}</h3><ul class="roxy-chips">${t.map(i=>rt.html`<li class="mutual-pill">${i.planet1} ⟷ ${i.planet2} ${i.aspectType?rt.html`<span class="rel">${i.aspectType}</span>`:rt.nothing}</li>`)}</ul></div>`:rt.nothing} ${e.length>0?rt.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Vedic aspects")}"><table><caption class="roxy-sr-only">${this.t("Vedic planetary aspects: aspecting planet, aspect type, aspected planet, strength and orb.")}</caption><thead><tr><th scope="col">${this.t("From")}</th><th scope="col">${this.t("Aspect")}</th><th scope="col">${this.t("To")}</th><th scope="col">${this.t("Strength")}</th><th scope="col">${this.t("Orb")}</th></tr></thead><tbody>${e.map(i=>rt.html`<tr><td>${i.aspectingPlanet}</td><td><span class="kind">${i.aspectType}</span></td><td>${i.aspectedPlanet}</td><td>${typeof i.strength=="number"?rt.html`<span class="bar" style="--_v:${Math.max(10,Math.min(100,i.strength))}"></span><span class="num">${b(this.effectiveLang(),i.strength,0)}</span>`:rt.nothing}</td><td class="num">${typeof i.orb=="number"?`${b(this.effectiveLang(),i.orb,2)}\xB0`:""}</td></tr>`)}</tbody></table></div>`:rt.nothing}</div>`}};Jr.endpoints=nc,Jr.styles=[u,rt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.section-label{margin-block-end:var(--roxy-space-xs)}.position,.mutual-pill{font-variant-numeric:tabular-nums;min-width:0}.position strong,.mutual-pill{color:var(--roxy-fg)}.overflow-scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}tbody tr:last-child td{border-block-end:0}.kind{font-weight:var(--roxy-weight-bold)}.num{color:var(--roxy-muted)}.bar{inline-size:calc(var(--_v) * 5ch / 100);block-size:.3lh;border-radius:var(--roxy-radius-full);background:var(--roxy-accent);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}`],Jr=m([f("roxy-vedic-aspects")],Jr);var I=require("lit");var Ho={favourable:"Favourable",underdelivered:"Underdelivered",obstructed:"Obstructed",void:"Void",aggravated:"Aggravated",unfavourable:"Unfavourable"},nf=Object.keys(Ho),of={favourable:"success",aggravated:"danger",unfavourable:"danger"},Ph=8,vi={"very-strong":"Very strong",strong:"Strong",moderate:"Moderate",weak:"Weak"},lf={day:"Day",finance:"Finance",natal:"Natal"},Mh={mahadasha:"Mahadasha",antardasha:"Antardasha",pratyantardasha:"Pratyantardasha"},Qr=class extends g{renderData(a){let e=a.grahas??[];return e.length?I.html`<div class="wrap" part="card" aria-label="${this.t("Vedic daily reading")}">${this.renderHead(a)} ${this.renderPanchanga(a)} ${this.renderGrahas(e,a.houseThemes)} ${this.renderWindows(a)} ${this.renderFinance(a)} ${this.renderDasha(a)} ${this.renderProvenance(a)}</div>`:this.renderEmpty()}renderHead(a){let e=new Map((a.tally??[]).map(r=>[r.state,r.count])),t=e.get("favourable")??0;return I.html`<header class="head" part="header"><div class="title-row"><h2>${this.t("Vedic daily")}</h2><span class="roxy-label">${ks(this.effectiveLang(),a.dayStart,a.dayEnd)}</span></div><div class="verdict-row"><span class="verdict ${a.verdict}">${this.t(vi[a.verdict])}</span> <span class="evidence">${this.t("{{supportive}} of {{evaluated}} grahas support this day",{supportive:t,evaluated:a.evaluated})}</span></div>${e.size?I.html`<ul class="tally roxy-chips" part="legend">${nf.filter(r=>e.get(r)).map(r=>I.html`<li class="pill">${this.t(Ho[r])} ${e.get(r)}</li>`)}</ul>`:I.nothing} ${a.subject?I.html`<p class="note">${this.t("Born with the Moon in {{rashi}}, nakshatra {{nakshatra}}",{rashi:a.subject.janmaRashi,nakshatra:a.subject.janmaNakshatra})}</p>`:I.nothing} ${(a.degraded??[]).map(r=>I.html`<p class="note">${this.t("{{component}} unavailable: {{reason}}",{component:r.component,reason:r.reason})}</p>`)}</header>`}renderPanchanga(a){let e=a.panchanga;if(!e)return I.nothing;let t=(r,s)=>s?I.html`<div><dt>${r}</dt><dd>${s.number?`${s.number}. `:""}${s.name} ${s.validTo?I.html`<span class="until">${this.t("until {{time}}",{time:ue(this.effectiveLang(),s.validTo)})}</span>`:I.nothing}</dd></div>`:I.nothing;return I.html`<section class="block" part="section panchanga"><h3>${this.t("Panchang")}</h3><dl class="roxy-facts" part="details"><div><dt>${this.t("Vara")}</dt><dd>${e.vara}</dd></div><div><dt>${this.t("Paksha")}</dt><dd>${e.paksha}</dd></div>${t(this.t("Tithi"),e.tithi)} ${t(this.t("Nakshatra"),e.nakshatra)} ${t(this.t("Yoga"),e.yoga)} ${t(this.t("Karana"),e.karana)}</dl></section>`}theme(a,e){return a?.[String(e)]?.join(", ")??""}renderGrahas(a,e){return I.html`<section class="block" part="section grahas"><h3>${this.t("Grahas today")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Grahas today")}"><table part="table"><caption class="roxy-sr-only">${this.t("Each transiting graha with its sign, the house it occupies from the natal Moon, its bindus, its kaksha and the state the classical rules give it.")}</caption><thead><tr><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Bindus")}</th><th scope="col">${this.t("Kaksha")}</th><th scope="col">${this.t("State")}</th></tr></thead><tbody>${a.map(t=>{let r=S(t.graha)??"",s=this.theme(e,t.houseFromMoon);return I.html`<tr><td>${r?I.html`<span class="glyph">${r}</span>`:I.nothing}${t.graha}</td><td>${t.sign}</td><td title="${s}">${t.houseFromMoon}</td><td>${typeof t.binduCount=="number"?t.binduCount:""}</td><td>${this.renderKaksha(t.kaksha)}</td><td><span class="state roxy-chip ${t.state}" data-tone="${of[t.state]??I.nothing}" title="${t.stateSource??""}">${this.t(Ho[t.state])}</span></td></tr>`})}</tbody></table></div></section>`}renderKaksha(a){if(!a||typeof a.number!="number")return I.nothing;let e=a.bindu===true?"yes":a.bindu===false?"no":"",t=a.bindu===true?this.t("this kaksha lord gave bindu"):a.bindu===false?this.t("this kaksha lord gave no bindu"):"",r=this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:a.number,total:Ph,graha:a.lord,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)});return I.html`<span class="kaksha" title="${t?`${r} \xB7 ${t}`:r}">${a.number}/${Ph} <span class="dot ${e}" aria-hidden="true"></span></span>`}renderWindows(a){let e=a.tara??[],t=a.chandrabala??[];if(!e.length&&!t.length)return I.nothing;let r=(s,i)=>I.html`<small>${ks(this.effectiveLang(),s,i)}</small>`;return I.html`<section class="block" part="section windows"><h3>${this.t("Tara and Chandrabala")}</h3>${e.length?I.html`<div class="chips">${e.map(s=>I.html`<span class="window"><span>${s.number}. ${s.name}${s.quality?` \xB7 ${s.quality}`:""}</span> ${r(s.validFrom,s.validTo)}</span>`)}</div>`:I.nothing} ${t.length?I.html`<div class="chips">${t.map(s=>I.html`<span class="window ${s.favourable?"yes":"no"}"><span>${this.t("Moon in {{sign}}, house {{n}}",{sign:s.moonSign,n:s.houseFromMoon})} ${s.ashtamaChandra?I.html`<span class="mark">· ${this.t("Ashtama Chandra")}</span>`:I.nothing} </span>${r(s.validFrom,s.validTo)}</span>`)}</div>`:I.nothing}</section>`}renderFinance(a){let e=a.areas?.finance;if(!e)return I.nothing;let t=a.houseThemes,r=s=>{let i=this.theme(t,s.house);return I.html`<li>${s.graha} · ${this.t("House {{n}}",{n:s.house})}${i?` (${i})`:""} · ${this.t("level {{level}} {{grade}}",{level:s.level,grade:s.grade})} ${s.dashaLevels?.length?I.html`<span class="note">${s.dashaLevels.map(o=>this.t(Mh[o])).join(", ")}</span>`:I.nothing}</li>`};return I.html`<section class="block" part="section finance"><h3>${this.t("Finance")}</h3><div class="verdict-row"><span class="verdict ${e.band??""}">${e.band?this.t(vi[e.band]):""}</span> ${typeof e.positive=="number"&&typeof e.negative=="number"?I.html`<span class="evidence">${this.t("{{positive}} positive against {{negative}} negative",{positive:e.positive,negative:e.negative})}</span>`:I.nothing}</div><div class="lists">${e.drivers?.length?I.html`<div><h3>${this.t("Drivers")}</h3><ul>${e.drivers.map(r)}</ul></div>`:I.nothing} ${e.cautions?.length?I.html`<div><h3>${this.t("Cautions")}</h3><ul>${e.cautions.map(r)}</ul></div>`:I.nothing}</div>${this.renderComposite(e.composite)}</section>`}renderComposite(a){return a?I.html`<div class="composite"><h3>${this.t("Combined score")}</h3><div class="verdict-row"><span class="verdict ${a.band}">${this.t(vi[a.band])}</span> <span class="evidence">${a.score}</span></div><ul class="layers">${a.layers.map(e=>I.html`<li><span>${this.t(lf[e.layer])}</span> <span class="evidence">${e.score}</span> <span class="band">${this.t(vi[e.band])}</span></li>`)}</ul></div>`:I.nothing}renderDasha(a){let e=a.dasha??[];return e.length?I.html`<section class="block" part="section dasha"><h3>${this.t("Dasha")}</h3><div class="chips">${e.map(t=>I.html`<span class="window"><span>${this.t(Mh[t.level])} · ${t.lord}</span> <small>${ks(this.effectiveLang(),t.startDate,t.endDate)}</small></span>`)}</div></section>`:I.nothing}renderProvenance(a){return a.frames?I.html`<section class="block" part="section frame">${td(this.effectiveLang(),a.frames,this.translator)}</section>`:I.nothing}};Qr.endpoints=ic,Qr.styles=[u,ae,Se,I.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head,.block{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);display:grid}.block{border-block-start:1px solid var(--roxy-border)}h2,h3,p{margin:0}.title-row{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict-row{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict{color:var(--roxy-secondary);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.verdict:is(.very-strong,.strong){color:var(--roxy-success-fg)}.verdict.moderate{color:var(--roxy-accent-ink)}.evidence{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.pill{font-variant-numeric:tabular-nums}.roxy-facts{margin:0}.until{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.state{cursor:help}.kaksha{align-items:center;gap:var(--roxy-space-xs);cursor:help;display:inline-flex}.dot{aspect-ratio:1;border-radius:var(--roxy-radius-full);background:var(--roxy-border);inline-size:1ch}.dot.yes{background:var(--roxy-success)}.dot.no{background:var(--roxy-warning)}.chips{gap:var(--roxy-space-sm) var(--roxy-space-lg);flex-wrap:wrap;display:flex}.window{font-size:var(--roxy-text-sm);display:grid}.window small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.window.yes>:first-child{color:var(--roxy-success-fg)}.window.no>:first-child,.mark{color:var(--roxy-danger-fg)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.lists ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}.note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.composite{gap:var(--roxy-space-sm);display:grid}.layers{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding:0;list-style:none;display:grid}.layers li{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.layers .band{color:var(--roxy-secondary)}`],Qr=m([f("roxy-vedic-daily")],Qr);var _h=require("lit"),Li=require("lit/decorators.js"),Nh=require("lit/directives/unsafe-html.js");var ra=class extends g{constructor(){super(...arguments);this.chartViewport=new je(this);this.chartStyle="north";this.chartReference="lagna";this.lagnaOverride="";this.setStyle=e=>{this.chartStyle=e}}resolveReference(){if(this.lagnaOverride)return this.lagnaOverride;if(this.chartReference==="moon")return this.data?.meta?.Moon?.rashi}viewModel(){return this.data?.meta?Gn(this.data.meta,{divisionLabel:"D1 Rashi",lagnaOverride:this.resolveReference(),states:this.data}):null}renderData(e){let t=this.viewModel();if(!t)return this.renderEmpty();let r=this.chartReference==="moon"&&!this.lagnaOverride?this.t("Chandra lagna"):this.t("Vedic kundli");return _h.html`<div class="wrap" part="card"><div class="header" part="header"><div><h2 class="title">${r}</h2>${ve(this.effectiveLang(),e.frame,this.translator)} ${Bn(t,this.translator)}</div>${Hn(this.chartStyle,this.setStyle,this.translator)}</div><div id="kundli-panel-${this.chartStyle}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}">${this.chartViewport.renderChartViewport((0,Nh.unsafeHTML)(Fn(t,{style:this.chartStyle,lang:this.effectiveLang()})),r,this.translator)}</div></div>`}};ra.endpoints=oc,ra.styles=[u,Xe,ae,An,jn,ot],m([(0,Li.property)({type:String,reflect:true,attribute:"chart-style"})],ra.prototype,"chartStyle",2),m([(0,Li.property)({type:String,reflect:true,attribute:"chart-reference"})],ra.prototype,"chartReference",2),m([(0,Li.property)({type:String,reflect:true,attribute:"lagna-override"})],ra.prototype,"lagnaOverride",2),ra=m([f("roxy-vedic-kundli")],ra);var q=require("lit");var cf=["Lagna","Sun","Moon","Mars","Mercury","Jupiter","Venus","Saturn","Rahu","Ketu"],zh=[["awastha","Baladi."],["jagradadi","Jagradadi."],["deeptadi","Deeptadi."]],es=class extends g{orderedRows(){let a=this.data?.meta??{},e=new Set,t=[];for(let r of cf){let s=a[r];s&&(t.push([r,s]),e.add(r))}for(let[r,s]of Object.entries(a))e.has(r)||t.push([r,s]);return t}renderData(a){if(!a.meta)return this.renderEmpty();let e=this.orderedRows(),t=e.some(([,r])=>r.avasthaInfo);return q.html`<div class="wrap" part="card" aria-label="${this.t("Vedic planetary positions")}"><header class="head" part="header"><h2>${this.t("Planetary positions")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Planetary positions")}"><table role="table"><caption class="roxy-sr-only">${this.t("Vedic planetary positions: each graha with its rashi, degree, nakshatra, pada, nakshatra lord, house, its state in all three avastha systems, and retrograde state. Jagradadi and Deeptadi are read from sign dignity, which the nodes and the Lagna do not have, so those two cells are blank on the Rahu, Ketu and Lagna rows. Uranus, Neptune and Pluto appear only when asked for and rule no sign, so every avastha and house cell is blank on their rows too.")} ${t?this.t("Each avastha state is followed by its meaning."):q.nothing}</caption><thead><tr><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Nakshatra")}</th><th scope="col">${this.t("Pada")}</th><th scope="col">${this.t("Nak. lord")}</th><th scope="col">${this.t("House")}</th><th scope="col" title="${this.t("Baladi: the five age states, set by degree within the sign")}">${this.t("Baladi")}</th><th scope="col" title="${this.t("Jagradadi: the three waking states, set by sign dignity. The seven classical grahas only")}">${this.t("Jagradadi")}</th><th scope="col" title="${this.t("Deeptadi: the nine dispositional states, set by sign dignity. The seven classical grahas only")}">${this.t("Deeptadi")}</th><th scope="col">${this.t("Retro")}</th></tr></thead><tbody>${e.map(([r,s])=>{let i=(s.graha??r)==="Lagna",o=S(s.graha??r)??"",l=Z(s.rashi)??"";return q.html`<tr class="${i?"lagna":""}"><td class="graha">${o?q.html`<span class="glyph">${o}</span>`:q.nothing}${s.graha??r}</td><td>${l?q.html`<span class="glyph">${l}</span>`:q.nothing}${s.rashi??""}</td><td>${typeof s.longitude=="number"?lt(s.longitude):""}</td><td>${s.nakshatra?.name??""}</td><td>${s.nakshatra?.pada??""}</td><td>${s.nakshatra?.lord??""}</td><td>${typeof s.house=="number"?s.house:""}</td>${zh.map(([c])=>q.html`<td>${s[c]??""}${s.avasthaInfo?.[c]?.meaning?q.html`<span class="gloss">${s.avasthaInfo[c].meaning}</span>`:q.nothing}</td>`)}<td>${s.isRetrograde?q.html`<span class="retro">R</span>`:q.nothing}</td></tr>`})} ${this.renderModernRows()}</tbody></table></div>${this.renderCombustion()} ${this.renderPlanetaryWar()} ${this.renderInterpretations()} ${this.renderYogas()} ${this.renderHouses()}</div>`}renderModernRows(){let a=this.data?.modernPlanets??[];return a.length===0?q.nothing:a.map((e,t)=>{let r=Z(e.rashi)??"";return q.html`<tr class="modern ${t===0?"modern-first":""}"><td class="graha">${Is(e.planet,e.sanskritName)}</td><td>${r?q.html`<span class="glyph">${r}</span>`:q.nothing}${e.rashi??""}</td><td>${typeof e.longitude=="number"?lt(e.longitude):""}</td><td>${e.nakshatra?.name??""}</td><td>${e.nakshatra?.pada??""}</td><td>${e.nakshatra?.lord??""}</td><td></td><td></td><td></td><td></td><td>${e.isRetrograde?q.html`<span class="retro">R</span>`:q.nothing}</td></tr>`})}renderCombustion(){let a=this.data?.combustion??[];return a.length===0?q.nothing:q.html`<details class="panel" part="section combustion"><summary>${this.t("Combust grahas")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>{let t=S(e.planet)??"",r=b(this.effectiveLang(),e.distanceFromSun,2),s=b(this.effectiveLang(),e.orb,1);return q.html`<div class="condition"><span class="planet">${t?`${t} `:""}${e.planet}</span> <span class="detail">${this.t("{{distance}} deg from Sun, within {{orb}} deg orb",{distance:r,orb:s})}</span></div>`})}</div></details>`}renderPlanetaryWar(){let a=this.data?.planetaryWar??[];return a.length===0?q.nothing:q.html`<details class="panel" part="section planetary-war"><summary>${this.t("Planetary wars")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>{let t=b(this.effectiveLang(),e.distance,2);return q.html`<div class="condition"><span class="planet">${this.t("{{first}} vs {{second}}",{first:e.planet1,second:e.planet2})}</span> <span class="detail">${this.t("{{distance}} deg apart",{distance:t})}</span> <span class="winner">${this.t("{{graha}} wins",{graha:e.winner})}</span></div>`})}</div></details>`}renderInterpretations(){if(this.hideReadings)return q.nothing;let a=this.data?.interpretations??{},e=this.orderedRows().map(([t,r])=>[r.graha??t,a[r.graha??t],r.avasthaInfo]).filter(([,t,r])=>t!=null||r!=null);return e.length===0?q.nothing:q.html`<details class="panel" part="section readings"><summary>${this.t("Interpretations")}<span class="summary-count">${e.length}</span>${he()}</summary><div class="panel-body">${e.map(([t,r,s])=>{let i=S(t)??"";return q.html`<div class="interp"><span class="planet">${i?`${i} `:""}${t}</span> ${r?.rashi?q.html`<p><span class="label">${this.t("Rashi.")}</span> ${r.rashi}</p>`:q.nothing} ${r?.nakshatra?q.html`<p><span class="label">${this.t("Nakshatra.")}</span> ${r.nakshatra}</p>`:q.nothing} ${zh.map(([o,l])=>s?.[o]?.interpretation?q.html`<p><span class="label">${this.t(l)}</span> ${s[o].interpretation}</p>`:q.nothing)}</div>`})}</div></details>`}renderHouses(){let a=(this.data?.houses??[]).filter(e=>e.name||e.description);return a.length===0?q.nothing:q.html`<details class="panel" part="section bhava-significations"><summary>${this.t("Bhava significations")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>q.html`<div class="bhava"><span class="name">${e.number}. ${e.name??""}</span> ${e.description?q.html`<p class="desc">${e.description}</p>`:q.nothing}</div>`)}</div></details>`}renderYogas(){let a=(this.data?.yogas??[]).filter(e=>e.present);return a.length===0?q.nothing:q.html`<details class="panel" part="section yogas"><summary>${this.t("Yogas")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>q.html`<div class="bhava"><span class="name">${e.name} ${e.quality?q.html`<span class="quality ${e.quality.toLowerCase()}">${e.quality}</span>`:q.nothing}</span> ${e.result?q.html`<p class="desc">${e.result}</p>`:q.nothing}</div>`)}</div></details>`}};es.endpoints=lc,es.styles=[u,ae,W,q.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,p{margin:0}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr.lagna td:first-child{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}tbody tr.lagna .glyph{color:var(--roxy-accent-ink)}tbody tr.modern-first td{border-block-start:var(--roxy-line-thick) solid var(--roxy-border)}td.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.gloss{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);display:block}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}details.panel{border-block-start:1px solid var(--roxy-border)}details.panel>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);padding:var(--roxy-space-sm) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);display:flex}.summary-count{margin-inline:auto var(--roxy-space-xs);color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);font-variant-numeric:tabular-nums}.panel-body{gap:var(--roxy-space-sm);padding:0 var(--roxy-space-md) var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:minmax(0,1fr);display:grid}.condition{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}:is(.condition,.interp) .planet,.bhava .name{font-weight:var(--roxy-weight-bold)}.condition .detail{color:var(--roxy-muted);font-variant-numeric:tabular-nums}.condition .winner{color:var(--roxy-success-fg);font-weight:var(--roxy-weight-bold)}.interp,.bhava{gap:calc(var(--roxy-space-unit) / 2);display:grid}.interp .label{color:var(--roxy-muted);font-weight:var(--roxy-weight-bold)}.bhava .desc{color:var(--roxy-muted)}.quality{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.quality.positive{color:var(--roxy-success-fg)}.quality.negative{color:var(--roxy-danger-fg)}.quality.both{color:var(--roxy-muted)}`],es=m([f("roxy-vedic-planets-table")],es);var ye=require("lit"),Fh=require("lit/decorators.js");function Oh(n){return n.suppressedBy||void 0}var Ih=["classical","asraya","dala","akriti","sankhya"];function Gh(n){let a=Ih.indexOf(n.family);return a===-1?Ih.length:a}var df=[{id:"present",source:"Present",open:true,noteSource:"Every classical condition is satisfied by this chart."},{id:"outranked",source:"Outranked",open:true,noteSource:"The rule matched, but a stronger family silences it under the classical precedence norms. Each card names the family that took precedence."},{id:"absent",source:"Not present",open:false,noteSource:"At least one classical condition fails. Read the evidence for which."}],pf={Positive:"success",Negative:"danger",Both:"warning"},Ya=class extends g{constructor(){super(...arguments);this.filter="";this.handleInput=e=>{this.filter=e.target.value}}verdictOf(e){return e.present?"present":Oh(e)?"outranked":"absent"}renderVerdictGroup(e,t){if(!t.length)return ye.nothing;let r=[...t].sort((s,i)=>Gh(s)-Gh(i));return ye.html`<details class="group" part="section verdict" ?open="${e.open||!!this.filter}"><summary class="group-summary"><span class="group-label">${this.t(e.source)}</span> <span class="group-count">${t.length}</span></summary><p class="group-note">${this.t(e.noteSource)}</p><div class="detail-grid">${r.map(s=>this.renderDetectCard(s))}</div></details>`}renderQualityChip(e){return ye.html`<span class="quality-chip roxy-chip quality-${e}" data-tone="${pf[e]??ye.nothing}">${e}</span>`}renderFamilyChip(e){return e.family?ye.html`<span class="family-chip roxy-chip" title="${this.t("Classical family")}">${V(e.family)}</span>`:ye.nothing}renderDetailCard(e){return ye.html`<div class="detail-card"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):ye.nothing} ${this.renderFamilyChip(e)}</p>${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${this.renderEffects(e.result)}</div>`}renderEffects(e){return!e||this.hideReadings?ye.nothing:ye.html`<details part="reading"><summary>${this.t("Effects")}</summary><div class="result-body">${e}</div></details>`}renderDetectCard(e){let t=e.present?void 0:Oh(e),[r,s,i]=e.present?["is-present","Present","success"]:t?["is-outranked",`Outranked by ${V(t)}`,"warning"]:["is-absent","Not present",void 0];return ye.html`<div class="detail-card ${e.present?"":t?"outranked":"absent"}"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):ye.nothing} ${this.renderFamilyChip(e)} <span class="present-badge roxy-chip ${r}" data-tone="${i??ye.nothing}">${s}</span></p>${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${e.present?this.renderEffects(e.result):ye.nothing} ${e.evidence?ye.html`<p class="evidence">${e.evidence}</p>`:ye.nothing}</div>`}renderData(e){let t=this.filter.toLowerCase();if("description"in e&&typeof e.description=="string"){let r=e;return ye.html`<div class="wrap" part="card">${this.renderDetailCard(r)}</div>`}if("yogas"in e&&Array.isArray(e.yogas)){let r=e.yogas;if(r.length>0&&"present"in r[0]){let c=r,d=t?c.filter(h=>h.name.toLowerCase().includes(t)):c,p=e.total??c.filter(h=>h.present).length;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Detected yogas")}</h2><span class="count">${this.t("{{count}} of {{total}} present",{count:p,total:c.length})}</span></div>${ve(this.effectiveLang(),e.frame,this.translator)}<div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter detected yogas by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="group-stack" part="section verdicts" role="region" aria-live="polite" aria-label="${this.t("Detected yogas")}">${d.length>0?df.map(h=>this.renderVerdictGroup(h,d.filter(x=>this.verdictOf(x)===h.id))):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}if(r.length>0&&"description"in r[0]){let c=r,d=t?c.filter(h=>h.name.toLowerCase().includes(t)):c,p=e.total;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Yoga catalog")}</h2>${p!==void 0?ye.html`<span class="count">${this.t("{{count}} total",{count:p})}</span>`:ye.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter yoga list by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="detail-grid" part="section yogas" role="region" aria-live="polite" aria-label="${this.t("Yoga results")}">${d.length>0?d.map(h=>this.renderDetailCard(h)):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}let i=r,o=t?i.filter(c=>c.name.toLowerCase().includes(t)):i,l=e.total;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Yoga catalog")}</h2>${l!==void 0?ye.html`<span class="count">${this.t("{{count}} total",{count:l})}</span>`:ye.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter yoga list by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="grid" part="section yogas" role="region" aria-live="polite" aria-label="${this.t("Yoga results")}">${o.length>0?o.map(c=>ye.html`<div class="yoga-chip">${c.name}</div>`):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}return ye.html`<div class="roxy-empty" role="status">${this.t("No yoga data")}</div>`}};Ya.endpoints=dc,Ya.styles=[u,ae,ye.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}h2,p{margin:0}.count,.no-results{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.search{inline-size:100%;max-inline-size:32ch;font-size:var(--roxy-text-sm)}.search::placeholder{color:var(--roxy-muted)}.grid{gap:0 var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,22ch),1fr));display:grid}.yoga-chip{padding-block:var(--roxy-space-xs);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);overflow-wrap:anywhere}.detail-card{gap:var(--roxy-space-sm);display:grid}.detail-grid>.detail-card+.detail-card{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm)}.detail-name{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);flex-wrap:wrap;display:flex}.wrap>.detail-card .detail-name{font-size:var(--roxy-text-lg)}.family-chip{color:var(--roxy-fg)}.quality-chip,.present-badge{font-weight:var(--roxy-weight-bold)}.detail-card.absent,.detail-card.outranked{color:var(--roxy-secondary)}.group-stack,.group,.detail-grid{gap:var(--roxy-space-sm);display:grid}.group-stack{gap:var(--roxy-space-md)}.group-summary{align-items:baseline;gap:var(--roxy-space-sm);color:var(--roxy-secondary);list-style:none;display:flex}.group-summary:before,.detail-card details>summary:before{content:"+";font-size:var(--roxy-text-base);line-height:1}.group-summary:before{color:var(--roxy-accent-ink)}.group[open]>.group-summary:before,.detail-card details[open]>summary:before{content:"-"}.group-label{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-count{font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.group-note,.evidence{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.description{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.detail-card details{font-size:var(--roxy-text-sm)}.detail-card details>summary{align-items:center;gap:var(--roxy-space-xs);padding-block:var(--roxy-space-xs);color:var(--roxy-accent-ink);list-style:none;display:flex}.result-body{color:var(--roxy-fg);padding-block-start:var(--roxy-space-xs)}`],m([(0,Fh.state)()],Ya.prototype,"filter",2),Ya=m([f("roxy-yoga-list")],Ya);var k=require("lit"),Hh=require("lit/decorators.js");var $i={"secret-friend":"Secret friend",trine:"Trine",same:"Same",neutral:"Neutral",harm:"Harm",clash:"Clash"},Bh={excellent:"Excellent",strong:"Strong",workable:"Workable",challenging:"Challenging",difficult:"Difficult"},Wa=class extends g{constructor(){super(...arguments);this.mode="sign"}renderData(e){if(this.mode==="compatibility"&&"signs"in e)return this.renderCompatibility(e);let t="animal"in e&&e.animal?e.animal:e,r=this.effectiveLang(),s="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,i="date"in e&&e.date?M(r,e.date):"";return k.html`<article class="card" part="card" aria-labelledby="zodiac-title"><header class="head" part="header"><span class="hanzi" lang="zh">${t.chinese??""}</span><div><h2 class="title" id="zodiac-title">${y(t,"name")}</h2><div class="sub">${t.pinyin??""}${i?` ${i}`:""}</div></div>${s!==null?k.html`<span class="energy" part="details" aria-label="${this.t("Energy {{value}} of 10",{value:s})}">${this.t("Energy {{value}}/10",{value:U(r,s)})} <span class="energy-bar"><span style="width:${s/10*100}%"></span></span></span>`:k.nothing}</header>${this.renderIdentity(e,t)} ${this.renderDaily(e)} ${this.renderReference(e)} ${"interpretation"in e&&e.interpretation&&!this.hideReadings?k.html`<p class="prose" part="section interpretation">${e.interpretation}</p>`:k.nothing} ${"conventions"in e?tr(e.conventions,this.translator,this.effectiveLang()):k.nothing}</article>`}renderIdentity(e,t){let r="yearPillar"in e&&e.yearPillar||"dayPillar"in e&&e.dayPillar||null,s="hours"in e?e.hours:void 0,i="element"in e&&typeof e.element=="string"?e:void 0,o=i?y(i,"element"):y(t,"element"),l=Et(i?.element??t.element),c="polarity"in e&&typeof e.polarity=="string"&&e.polarity||t.polarity||"";return!o&&!c&&!r&&!s&&!t.branch?k.nothing:k.html`<div class="facts" part="details">${o?k.html`<span><span class="roxy-label">${this.t("Element")}</span><b class="element-word ${l}">${o}</b></span>`:k.nothing} ${c?k.html`<span><span class="roxy-label">${this.t("Polarity")}</span>${c}</span>`:k.nothing} ${t.branch?k.html`<span><span class="roxy-label">${this.t("Branch")}</span>${t.branch}</span>`:k.nothing} ${r?k.html`<span><span class="roxy-label">${this.t("Pillar")}</span> <b>${r.stem??""}</b> ${r.branch??""}</span>`:k.nothing} ${s&&typeof s.start=="number"?k.html`<span><span class="roxy-label">${this.t("Hours")}</span>${this.t("{{start}} to {{end}}",{start:this.hourLabel(s.start),end:this.hourLabel(s.end)})}</span>`:k.nothing}</div>`}hourLabel(e){return typeof e=="number"?`${String(e).padStart(2,"0")}:00`:""}renderDaily(e){if(!("relationship"in e)||!("overview"in e))return k.nothing;let t="year"in e?e.year:void 0,r="benMingNian"in e?e.benMingNian:false;return k.html`${k.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Day")}</span><b>${e.relationship&&$i[e.relationship]?this.t($i[e.relationship]):e.relationship??""}</b></span> ${t?k.html`<span><span class="roxy-label">${this.t("Year")}</span>${t.pillar??""} ${y(t,"animal")} ${t.relationship&&$i[t.relationship]?this.t($i[t.relationship]):t.relationship??""}</span>`:k.nothing} ${r?k.html`<span class="roxy-chip tag">${this.t("Ben Ming Nian")}</span>`:k.nothing}</div>`} ${this.hideReadings?k.nothing:k.html`${e.overview?k.html`<p class="prose" part="section overview">${e.overview}</p>`:k.nothing}<div class="sections" part="section outlook">${"love"in e&&e.love?k.html`<div class="section"><h3 class="block-title">${this.t("Love")}</h3><p>${e.love}</p></div>`:k.nothing} ${"career"in e&&e.career?k.html`<div class="section"><h3 class="block-title">${this.t("Career")}</h3><p>${e.career}</p></div>`:k.nothing} ${"advice"in e&&e.advice?k.html`<div class="section"><h3 class="block-title">${this.t("Advice")}</h3><p>${e.advice}</p></div>`:k.nothing}</div>`} ${t?.note&&!this.hideReadings?k.html`<p class="prose" part="reading">${t.note}</p>`:k.nothing}`}renderReference(e){if(!("trine"in e)&&!("secretFriend"in e))return k.nothing;let t=e;return k.html`${t.trine?k.html`<section part="section trine"><h3 class="block-title">${this.t("Trine")} ${t.trine.number??""}</h3><div class="facts"><span><b lang="zh">${t.trine.chinese??""}</b> <span class="element-word ${Et(t.trine.element)}">${y(t.trine,"element")}</span></span> ${t.trine.members?.length?k.html`<span class="roxy-chips">${t.trine.members.map(r=>k.html`<span class="roxy-chip">${r}</span>`)}</span>`:k.nothing} ${t.trine.theme?k.html`<span>${t.trine.theme}</span>`:k.nothing}</div></section>`:k.nothing} ${this.renderPartners(t)} ${this.hideReadings?k.nothing:k.html`${t.summary?k.html`<p class="prose" part="section summary">${t.summary}</p>`:k.nothing} ${t.traits?.length?k.html`<section part="section traits"><h3 class="block-title">${this.t("Traits")}</h3><ul class="roxy-chips">${t.traits.map(r=>k.html`<li>${r}</li>`)}</ul></section>`:k.nothing} ${this.bullets(this.t("Strengths"),t.strengths)} ${this.bullets(this.t("Weaknesses"),t.weaknesses)} ${t.compatibilitySummary?k.html`<p class="prose" part="reading">${t.compatibilitySummary}</p>`:k.nothing}`}`}renderPartners(e){let r=[["Secret friend",e.secretFriend],["Clash",e.clashPartner],["Harm",e.harmPartner]].filter(([,s])=>s?.name);return r.length===0?k.nothing:k.html`<section part="section partners"><div class="partners">${r.map(([s,i])=>k.html`<div class="partner"><span class="role roxy-label">${this.t(s)}</span> <span class="glyph" lang="zh">${i?.chinese??""}</span> <span class="who">${y(i,"name")}</span></div>`)}</div></section>`}bullets(e,t){return t?.length?k.html`<section part="section list"><h3 class="block-title">${e}</h3><ul class="bullets">${t.map(r=>k.html`<li>${r}</li>`)}</ul></section>`:k.nothing}renderCompatibility(e){let t=e.signs?.first,r=e.signs?.second,s=typeof e.score=="number"?e.score:null;return k.html`<article class="card" part="card" aria-labelledby="zodiac-title"><header class="head" part="header"><div class="pair"><span class="side"><span class="hanzi" lang="zh">${t?.chinese??""}</span> <span class="sub">${y(t,"name")}</span></span> <span class="side"><span class="hanzi" lang="zh">${r?.chinese??""}</span> <span class="sub">${y(r,"name")}</span></span></div></header><h2 class="title" id="zodiac-title">${y(e,"relationshipName")} <span lang="zh">${e.relationshipChinese??""}</span></h2>${s!==null?k.html`<div class="score" part="details"><span class="score-value">${s}</span> <span class="score-track"><span class="score-fill" style="width:${Math.max(0,Math.min(100,s))}%"></span></span> ${e.verdict?k.html`<span class="roxy-chip tag">${Bh[e.verdict]?this.t(Bh[e.verdict]):e.verdict}</span>`:k.nothing}</div>`:k.nothing} ${e.sharedElement?k.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Shared element")}</span><b class="element-word ${Et(e.sharedElement)}">${y(e,"sharedElement")}</b></span></div>`:k.nothing} ${this.hideReadings?k.nothing:k.html`${e.summary?k.html`<p class="prose" part="section summary">${e.summary}</p>`:k.nothing} ${this.bullets(this.t("Strengths"),e.strengths)} ${this.bullets(this.t("Frictions"),e.frictions)} ${e.advice?k.html`<p class="prose" part="reading">${e.advice}</p>`:k.nothing}`}</article>`}};Wa.endpoints=pc,Wa.styles=[u,ae,la,k.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.hanzi{font-size:calc(var(--roxy-text-base) * 2.75);color:var(--roxy-accent-ink);line-height:1}.title,.block-title{margin:0}.title{font-size:var(--roxy-text-xl)}.block-title{margin-block-end:var(--roxy-space-sm)}.sub{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.energy{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;margin-inline-start:auto}.energy-bar,.score-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);overflow:hidden}.energy-bar{block-size:.25lh;inline-size:12ch;vertical-align:middle;margin-inline-start:var(--roxy-space-xs);display:inline-block}.energy-bar>span,.score-fill{background:var(--roxy-accent);height:100%;display:block}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;padding-block-start:var(--roxy-space-md);display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.prose{margin:0}.prose[part~=reading]{padding-block-start:var(--roxy-space-md)}section .facts{border-block-start:0;padding-block-start:0}.sections{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.section p{font-size:var(--roxy-text-sm);margin:0}.bullets{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-lg)}.partners{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(16ch,1fr));display:grid}.partner,.pair .side{gap:calc(var(--roxy-space-unit) / 2);text-align:center;display:grid}.partner .glyph{font-size:calc(var(--roxy-text-base) * 1.5);line-height:var(--roxy-leading-tight);color:var(--roxy-accent-ink)}.partner .who{font-size:var(--roxy-text-sm)}.score{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.score-value{font-size:calc(var(--roxy-text-base) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.score-track{flex:1;block-size:.35lh;min-inline-size:16ch}.tag{color:var(--roxy-info-fg)}.pair{justify-content:center;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}`],m([(0,Hh.property)({type:String,reflect:true})],Wa.prototype,"mode",2),Wa=m([f("roxy-zodiac-card")],Wa);var jh={post_astrology_natal_chart:{tag:"roxy-natal-chart",pascal:"RoxyNatalChart",operationId:"generateNatalChart"},post_astrology_synastry:{tag:"roxy-synastry-chart",pascal:"RoxySynastryChart",operationId:"calculateSynastry"},post_astrology_transits:{tag:"roxy-transits-table",pascal:"RoxyTransitsTable",operationId:"calculateTransits"},post_astrology_transit_aspects:{tag:"roxy-transit-wheel",pascal:"RoxyTransitWheel",operationId:"calculateTransitAspects"},post_astrology_aspects:{tag:"roxy-aspects-table",pascal:"RoxyAspectsTable",operationId:"calculateAspects"},post_astrology_aspect_patterns:{tag:"roxy-aspects-table",pascal:"RoxyAspectsTable",operationId:"detectAspectPatterns"},get_astrology_moon_phase_current:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getCurrentMoonPhase",attrs:{mode:"current"}},get_astrology_moon_phase_upcoming:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getUpcomingMoonPhases",attrs:{mode:"upcoming"}},get_astrology_moon_phase_calendar_year_month:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getMoonCalendar",attrs:{mode:"calendar"}},get_astrology_horoscope_sign_daily:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getDailyHoroscope",attrs:{period:"daily"}},get_astrology_horoscope_sign_weekly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getWeeklyHoroscope",attrs:{period:"weekly"}},get_astrology_horoscope_sign_monthly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getMonthlyHoroscope",attrs:{period:"monthly"}},get_astrology_horoscope_sign_yearly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getYearlyHoroscope",attrs:{period:"yearly"}},post_astrology_astrocartography:{tag:"roxy-astrocartography-map",pascal:"RoxyAstrocartographyMap",operationId:"generateAstrocartography"},post_astrology_local_space:{tag:"roxy-local-space-compass",pascal:"RoxyLocalSpaceCompass",operationId:"generateLocalSpace"},post_astrology_relocation_chart:{tag:"roxy-relocation-wheel",pascal:"RoxyRelocationWheel",operationId:"generateRelocationChart"},post_astrology_asteroids:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateAsteroids"},post_astrology_lilith:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateLilith"},post_astrology_progressions:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateProgressions"},post_astrology_solar_arc:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateSolarArc"},post_astrology_arabic_lots:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"calculateArabicLots"},post_astrology_planets_monthly:{tag:"roxy-ephemeris-table",pascal:"RoxyEphemerisTable",operationId:"getMonthlyTropicalEphemeris"},post_vedic_astrology_planetary_positions_monthly:{tag:"roxy-ephemeris-table",pascal:"RoxyEphemerisTable",operationId:"getMonthlyEphemeris"},post_astrology_fixed_stars:{tag:"roxy-fixed-stars",pascal:"RoxyFixedStars",operationId:"generateFixedStars"},post_astrology_profections:{tag:"roxy-profection-card",pascal:"RoxyProfectionCard",operationId:"generateProfections"},post_astrology_compatibility_score:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateCompatibility",attrs:{mode:"astrology"}},post_numerology_compatibility:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateNumCompatibility",attrs:{mode:"numerology"}},post_biorhythm_compatibility:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateBioCompatibility",attrs:{mode:"biorhythm"}},post_vedic_astrology_birth_chart:{tag:"roxy-vedic-kundli",pascal:"RoxyVedicKundli",operationId:"generateBirthChart"},post_vedic_astrology_divisional_chart:{tag:"roxy-divisional-chart",pascal:"RoxyDivisionalChart",operationId:"generateDivisionalChart"},post_vedic_astrology_navamsa:{tag:"roxy-divisional-chart",pascal:"RoxyDivisionalChart",operationId:"generateNavamsa"},post_vedic_astrology_kp_chart:{tag:"roxy-kp-chart",pascal:"RoxyKpChart",operationId:"generateKpChart"},post_vedic_astrology_kp_planets:{tag:"roxy-kp-planets-table",pascal:"RoxyKpPlanetsTable",operationId:"getKpPlanets"},post_vedic_astrology_kp_ruling_planets:{tag:"roxy-kp-ruling-planets",pascal:"RoxyKpRulingPlanets",operationId:"getKpRulingPlanets"},post_vedic_astrology_ashtakavarga:{tag:"roxy-ashtakavarga-grid",pascal:"RoxyAshtakavargaGrid",operationId:"calculateAshtakavarga"},post_vedic_astrology_shadbala:{tag:"roxy-shadbala-table",pascal:"RoxyShadbalaTable",operationId:"calculateShadbala"},post_vedic_astrology_dasha_major:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getMajorDashas",attrs:{period:"major"}},post_vedic_astrology_dasha_current:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getCurrentDasha",attrs:{period:"current"}},post_vedic_astrology_dasha_sub_mahadasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getSubDashas",attrs:{period:"sub"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getPratyantardashas",attrs:{period:"antara"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha_pratyantardasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getSookshmaDashas",attrs:{period:"sookshma"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha_pratyantardasha_sookshma:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getPranaDashas",attrs:{period:"prana"}},post_vedic_astrology_compatibility:{tag:"roxy-guna-milan",pascal:"RoxyGunaMilan",operationId:"calculateGunMilan"},post_vedic_astrology_panchang_detailed:{tag:"roxy-panchang-table",pascal:"RoxyPanchangTable",operationId:"getDetailedPanchang",attrs:{detail:"detailed"}},post_vedic_astrology_panchang_basic:{tag:"roxy-panchang-table",pascal:"RoxyPanchangTable",operationId:"getBasicPanchang",attrs:{detail:"basic"}},post_vedic_astrology_aspects:{tag:"roxy-vedic-aspects",pascal:"RoxyVedicAspects",operationId:"calculateDrishti"},post_vedic_astrology_panchang_hora:{tag:"roxy-hora-table",pascal:"RoxyHoraTable",operationId:"getHora"},post_vedic_astrology_panchang_choghadiya:{tag:"roxy-choghadiya-grid",pascal:"RoxyChoghadiyaGrid",operationId:"getChoghadiya"},post_vedic_astrology_heliacal:{tag:"roxy-heliacal-table",pascal:"RoxyHeliacalTable",operationId:"getHeliacalVisibility"},post_vedic_astrology_daily:{tag:"roxy-vedic-daily",pascal:"RoxyVedicDaily",operationId:"getVedicDailyReading"},post_vedic_astrology_kp_daily_finance:{tag:"roxy-kp-finance-card",pascal:"RoxyKpFinanceCard",operationId:"getKpDailyFinance"},post_vedic_astrology_transit:{tag:"roxy-gochara-table",pascal:"RoxyGocharaTable",operationId:"calculateTransit"},post_vedic_astrology_bhava_bala:{tag:"roxy-bhava-bala-table",pascal:"RoxyBhavaBalaTable",operationId:"calculateBhavaBala"},post_vedic_astrology_bhav_chalit:{tag:"roxy-bhav-chalit-table",pascal:"RoxyBhavChalitTable",operationId:"calculateBhavChalit"},post_vedic_astrology_upagraha:{tag:"roxy-upagraha-table",pascal:"RoxyUpagrahaTable",operationId:"getUpagrahaPositions"},post_vedic_astrology_chara_karakas:{tag:"roxy-chara-karakas",pascal:"RoxyCharaKarakas",operationId:"calculateCharaKarakas"},post_vedic_astrology_arudha:{tag:"roxy-arudha-padas",pascal:"RoxyArudhaPadas",operationId:"calculateArudhaPadas"},get_vedic_astrology_yoga:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"listYogas"},post_vedic_astrology_yoga_detect:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"detectYogas"},get_vedic_astrology_yoga_id:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"getYoga"},get_vedic_astrology_nakshatras_id:{tag:"roxy-nakshatra-card",pascal:"RoxyNakshatraCard",operationId:"getNakshatra"},post_vedic_astrology_dosha_manglik:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkManglikDosha",attrs:{type:"manglik"}},post_vedic_astrology_dosha_kalsarpa:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkKalsarpaDosha",attrs:{type:"kalsarpa"}},post_vedic_astrology_dosha_sadhesati:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkSadhesati",attrs:{type:"sadhesati"}},post_numerology_life_path:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateLifePath",attrs:{type:"life-path"}},post_numerology_expression:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateExpression",attrs:{type:"expression"}},post_numerology_soul_urge:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateSoulUrge",attrs:{type:"soul-urge"}},post_numerology_personality:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonality",attrs:{type:"personality"}},post_numerology_birth_day:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateBirthDay",attrs:{type:"birth-day"}},post_numerology_maturity:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateMaturity",attrs:{type:"maturity"}},post_numerology_daily:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"getDailyNumber",attrs:{type:"daily"}},post_numerology_personal_day:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalDay",attrs:{type:"personal-day"}},post_numerology_personal_month:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalMonth",attrs:{type:"personal-month"}},post_numerology_personal_year:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalYear",attrs:{type:"personal-year"}},post_numerology_chart:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"generateNumerologyChart",attrs:{type:"chart"}},get_numerology_compound_number:{tag:"roxy-compound-number",pascal:"RoxyCompoundNumber",operationId:"getCompoundNumber"},post_kabbalah_gematria:{tag:"roxy-gematria",pascal:"RoxyGematria",operationId:"calculateGematria"},post_tarot_daily:{tag:"roxy-tarot-card",pascal:"RoxyTarotCard",operationId:"getDailyCard"},get_tarot_cards_id:{tag:"roxy-tarot-card",pascal:"RoxyTarotCard",operationId:"getCard"},get_tarot_cards:{tag:"roxy-tarot-catalog",pascal:"RoxyTarotCatalog",operationId:"listCards"},post_tarot_spreads_three_card:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castThreeCard",attrs:{spread:"three-card"}},post_tarot_spreads_celtic_cross:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCelticCross",attrs:{spread:"celtic-cross"}},post_tarot_spreads_love:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castLoveSpread",attrs:{spread:"love"}},post_tarot_spreads_career:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCareerSpread",attrs:{spread:"career"}},post_tarot_spreads_custom:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCustomSpread",attrs:{spread:"custom"}},post_tarot_yes_no:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castYesNo",attrs:{spread:"yes-no"}},post_tarot_draw:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"drawCards",attrs:{spread:"draw"}},post_human_design_bodygraph:{tag:"roxy-bodygraph",pascal:"RoxyBodygraph",operationId:"generateBodygraph"},post_human_design_type:{tag:"roxy-hd-type-card",pascal:"RoxyHdTypeCard",operationId:"calculateType"},post_human_design_profile:{tag:"roxy-hd-type-card",pascal:"RoxyHdTypeCard",operationId:"calculateProfile"},post_human_design_connection:{tag:"roxy-hd-connection",pascal:"RoxyHdConnection",operationId:"calculateConnection"},post_human_design_penta:{tag:"roxy-hd-penta",pascal:"RoxyHdPenta",operationId:"calculatePenta"},post_human_design_variables:{tag:"roxy-hd-variables",pascal:"RoxyHdVariables",operationId:"calculateVariables"},post_forecast_timeline:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"generateTimeline"},post_forecast_significant_dates:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"findSignificantDates"},post_forecast_transits:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"forecastTransits"},post_forecast_digest:{tag:"roxy-forecast-digest",pascal:"RoxyForecastDigest",operationId:"generateDigest"},post_chinese_astrology_bazi_chart:{tag:"roxy-bazi-chart",pascal:"RoxyBaziChart",operationId:"generateBaziChart"},post_chinese_astrology_bazi_luck_pillars:{tag:"roxy-luck-pillars",pascal:"RoxyLuckPillars",operationId:"calculateLuckPillars"},post_chinese_astrology_zodiac_sign:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"calculateZodiacAnimal",attrs:{mode:"sign"}},get_chinese_astrology_zodiac_animals_id:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getZodiacAnimal",attrs:{mode:"animal"}},get_chinese_astrology_zodiac_id_daily:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getDailyZodiacReading",attrs:{mode:"daily"}},get_chinese_astrology_zodiac_compatibility_sign1_sign2:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getZodiacCompatibility",attrs:{mode:"compatibility"}},get_chinese_astrology_calendar_day_date:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"getAlmanacDay",attrs:{mode:"day"}},get_chinese_astrology_calendar_monthly:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"getMonthlyAlmanac",attrs:{mode:"month"}},post_chinese_astrology_calendar_auspicious_days:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"lookupAuspiciousDays",attrs:{mode:"auspicious"}},post_feng_shui_flying_stars_natal:{tag:"roxy-flying-star-chart",pascal:"RoxyFlyingStarChart",operationId:"generateFlyingStarChart",attrs:{mode:"natal"}},get_feng_shui_flying_stars_annual_year:{tag:"roxy-flying-star-chart",pascal:"RoxyFlyingStarChart",operationId:"getAnnualFlyingStars",attrs:{mode:"annual"}},post_feng_shui_kua:{tag:"roxy-kua-card",pascal:"RoxyKuaCard",operationId:"calculateKuaNumber",attrs:{mode:"kua"}},post_feng_shui_eight_mansions:{tag:"roxy-kua-card",pascal:"RoxyKuaCard",operationId:"generateEightMansions",attrs:{mode:"mansions"}},post_mesoamerican_astrology_mayan_tzolkin:{tag:"roxy-mayan-day-sign",pascal:"RoxyMayanDaySign",operationId:"calculateTzolkin",attrs:{mode:"day"}},post_mesoamerican_astrology_mayan_chart:{tag:"roxy-mayan-day-sign",pascal:"RoxyMayanDaySign",operationId:"generateMayanChart",attrs:{mode:"chart"}},post_vastu_mandala:{tag:"roxy-vastu-mandala",pascal:"RoxyVastuMandala",operationId:"generateMandala",attrs:{mode:"mandala"}},post_vastu_entrance:{tag:"roxy-vastu-mandala",pascal:"RoxyVastuMandala",operationId:"calculateEntrancePada",attrs:{mode:"entrance"}},post_biorhythm_daily:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getDailyBiorhythm",attrs:{mode:"daily"}},post_biorhythm_forecast:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getForecast",attrs:{mode:"forecast"}},post_biorhythm_critical_days:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getCriticalDays",attrs:{mode:"critical-days"}},post_ayurveda_constitution:{tag:"roxy-dosha-constitution",pascal:"RoxyDoshaConstitution",operationId:"calculateAyurvedicConstitution"},get_iching_hexagrams_random:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getRandomHexagram"},get_iching_hexagrams_number:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getHexagram"},get_iching_hexagrams_lookup:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"lookupHexagram"},get_iching_cast:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"castReading"},post_iching_daily:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getDailyHexagram"},post_iching_daily_cast:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"castDailyReading"},get_crystals_id:{tag:"roxy-crystal-card",pascal:"RoxyCrystalCard",operationId:"getCrystal"},get_crystals:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"listCrystals"},get_crystals_chakra:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByChakra"},get_crystals_element:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByElement"},get_crystals_zodiac_sign:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByZodiac"},get_crystals_birthstone_month:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getBirthstones"},get_crystals_search:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"searchCrystals"},get_dreams_symbols_id:{tag:"roxy-dream-card",pascal:"RoxyDreamCard",operationId:"getDreamSymbol"},get_dreams_symbols:{tag:"roxy-dream-search",pascal:"RoxyDreamSearch",operationId:"searchDreamSymbols"},get_angel_numbers_number:{tag:"roxy-angel-number-card",pascal:"RoxyAngelNumberCard",operationId:"getAngelNumber"},post_angel_numbers_daily:{tag:"roxy-angel-number-card",pascal:"RoxyAngelNumberCard",operationId:"getDailyAngelNumber"},get_angel_numbers_lookup:{tag:"roxy-angel-number-lookup",pascal:"RoxyAngelNumberLookup",operationId:"analyzeNumberSequence"},post_reports_natal:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateNatalReport",attrs:{report:"natal"}},post_reports_synastry:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateSynastryReport",attrs:{report:"synastry"}},post_reports_kundli:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateKundliReport",attrs:{report:"kundli"}},post_reports_matchmaking:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateMatchmakingReport",attrs:{report:"matchmaking"}},post_reports_yearly_forecast:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateYearlyForecastReport",attrs:{report:"yearly-forecast"}},post_reports_human_design:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateHumanDesignReport",attrs:{report:"human-design"}},post_reports_bazi:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateBaziReport",attrs:{report:"bazi"}},post_reports_numerology:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateNumerologyReport",attrs:{report:"numerology"}},post_reports_tarot:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateTarotReport",attrs:{report:"tarot"}},get_astrology_signs_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getZodiacSign"},get_astrology_planet_meanings_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getPlanetMeaning"},get_vedic_astrology_rashis_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getRashi"},get_iching_trigrams_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getTrigram"},get_human_design_gates_number:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getGate"},get_human_design_centers_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getCenter"},get_numerology_meanings_number:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getNumberMeaning"},get_vedic_astrology_avasthas_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getAvastha"}};function jo(n){let a=n.lastIndexOf(":"),e=a===-1?n:n.slice(a+1),t=jh[e];return t?{...t,toolName:e}:void 0}var wi=[{pascal:"RoxyNatalChart",tag:"roxy-natal-chart",slug:"natal-chart",heading:"Natal chart",description:"Western natal chart wheel for /astrology/natal-chart responses",docsLabel:"Western",endpointLabel:"POST /astrology/natal-chart",docsSummary:"Natal chart wheel with planet glyphs and aspect lines",topic:"Astrology"},{pascal:"RoxySynastryChart",tag:"roxy-synastry-chart",slug:"synastry-chart",heading:"Synastry",description:"Dual-wheel synastry chart with inter-aspects table",docsLabel:"Western",endpointLabel:"POST /astrology/synastry",docsSummary:"Dual-wheel synastry with inter-aspects table",topic:"Astrology"},{pascal:"RoxyWesternPlanetsTable",tag:"roxy-western-planets-table",slug:"western-planets-table",heading:"Western planets",description:"Western planetary positions table with sign, degree, house, and motion plus the chart angles",docsLabel:"Western",endpointLabel:"POST /astrology/natal-chart",docsSummary:"Sign, degree, house, motion columns plus ASC, MC, PoF, Vertex",topic:"Astrology"},{pascal:"RoxyTransitsTable",tag:"roxy-transits-table",slug:"transits-table",heading:"Transits",description:"Live planet positions plus aspects to a natal chart",docsLabel:"Western",endpointLabel:"POST /astrology/transits",docsSummary:"Transit planet positions plus optional aspects to a natal chart",topic:"Astrology"},{pascal:"RoxyTransitWheel",tag:"roxy-transit-wheel",slug:"transit-wheel",heading:"Transit bi-wheel",description:"Natal and transit bi-wheel with an aspect line for every transit to the natal chart",docsLabel:"Western",endpointLabel:"POST /astrology/transit-aspects",docsSummary:"Natal chart on the inner ring, transiting bodies on the outer ring, aspect lines between them",topic:"Astrology"},{pascal:"RoxyAspectsTable",tag:"roxy-aspects-table",slug:"aspects-table",heading:"Aspects",description:"Natal and transit aspect grid with chart-pattern detection (grand trines, t-squares, stelliums, yods)",docsLabel:"Western",endpointLabel:"POST /astrology/aspects, /astrology/transit-aspects, /astrology/aspect-patterns",docsSummary:"Aspect rows coloured by nature with orb and strength, plus detected chart patterns",topic:"Astrology"},{pascal:"RoxyMoonPhase",tag:"roxy-moon-phase",slug:"moon-phase",heading:"Moon phase",description:"Moon phase card and calendar",docsLabel:"Western",endpointLabel:"GET /astrology/moon-phase/{current,upcoming,calendar/...}",docsSummary:"Moon phase card and calendar",topic:"Astrology"},{pascal:"RoxyHoroscopeCard",tag:"roxy-horoscope-card",slug:"horoscope-card",heading:"Horoscope",description:"Daily, weekly, monthly, or yearly horoscope card for /astrology/horoscope/..., with the column, the dated sky events behind it, and the yearly themes, key periods, eclipses, retrogrades and best months",docsLabel:"Western",endpointLabel:"GET /astrology/horoscope/{sign}/{daily,weekly,monthly,yearly}",docsSummary:"Daily, weekly, monthly, or yearly horoscope card",topic:"Astrology"},{pascal:"RoxyAstrocartographyMap",tag:"roxy-astrocartography-map",slug:"astrocartography-map",heading:"Astrocartography",description:"Astrocartography world map plotting each body Midheaven, IC, Ascendant, and Descendant relocation lines",docsLabel:"Western",endpointLabel:"POST /astrology/astrocartography",docsSummary:"World map of planetary MC, IC, Ascendant, and Descendant lines with per-line interpretations",topic:"Astrology"},{pascal:"RoxyLocalSpaceCompass",tag:"roxy-local-space-compass",slug:"local-space-compass",heading:"Local space",description:"Local space compass plotting each body direction from the birthplace by azimuth and altitude",docsLabel:"Western",endpointLabel:"POST /astrology/local-space",docsSummary:"Compass dial of planetary azimuth lines from the birthplace, dimmed below the horizon",topic:"Astrology"},{pascal:"RoxyRelocationWheel",tag:"roxy-relocation-wheel",slug:"relocation-wheel",heading:"Relocation chart",description:"Relocation chart wheel recomputing houses and angles for a new place, with the planets that change house",docsLabel:"Western",endpointLabel:"POST /astrology/relocation-chart",docsSummary:"Relocated chart wheel plus the move geometry, angular planets, and planets that change house",topic:"Astrology"},{pascal:"RoxyPositionsTable",tag:"roxy-positions-table",slug:"positions-table",heading:"Positions table",description:"Editorial positions table for asteroids, Black Moon Lilith, secondary progressions, solar arc directions, and the Arabic lots",docsLabel:"Western",endpointLabel:"POST /astrology/asteroids, /astrology/lilith, /astrology/progressions, /astrology/solar-arc, /astrology/arabic-lots",docsSummary:"Body, sign, degree, and per-shape columns (house, motion, formula, or natal arc) plus each reading",topic:"Astrology"},{pascal:"RoxyEphemerisTable",tag:"roxy-ephemeris-table",slug:"ephemeris-table",heading:"Ephemeris",description:"Monthly ephemeris: every body day by day, with each sign change and retrograde stretch called out",docsLabel:"Cross",endpointLabel:"POST /astrology/planets/monthly, /vedic-astrology/planetary-positions/monthly",docsSummary:"Per-body sign changes and retrograde windows for the month, over the full daily position grid",topic:"Astrology"},{pascal:"RoxyFixedStars",tag:"roxy-fixed-stars",slug:"fixed-stars",heading:"Fixed stars",description:"Fixed star conjunctions to the natal chart, tightest first, with the precessed star catalog",docsLabel:"Western",endpointLabel:"POST /astrology/fixed-stars",docsSummary:"Star to natal point conjunctions with readings, plus a catalog of position, magnitude, nature, and keywords",topic:"Astrology"},{pascal:"RoxyProfectionCard",tag:"roxy-profection-card",slug:"profection-card",heading:"Annual profection",description:"Annual profection card with the profected house and sign, the lord of the year, and its natal placement",docsLabel:"Western",endpointLabel:"POST /astrology/profections",docsSummary:"Profected house and sign for the year, the lord of the year, its natal placement, and the reading",topic:"Astrology"},{pascal:"RoxyCompatibilityCard",tag:"roxy-compatibility-card",slug:"compatibility-card",heading:"Compatibility score",description:"Cross-domain compatibility score card",docsLabel:"Cross",endpointLabel:"POST /astrology/compatibility-score, /numerology/compatibility, /biorhythm/compatibility",docsSummary:"Score card with category breakdown",topic:"Astrology"},{pascal:"RoxyVedicKundli",tag:"roxy-vedic-kundli",slug:"vedic-kundli",heading:"Vedic kundli",description:"South, North, or East Indian Vedic kundli for /vedic-astrology/birth-chart with per-planet degree and nakshatra detail, plus an optional Chandra Lagna (Moon-as-ascendant) reference view",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/birth-chart",docsSummary:"South, North, or East Indian kundli with degree detail and optional Chandra Lagna view",topic:"Vedic"},{pascal:"RoxyDivisionalChart",tag:"roxy-divisional-chart",slug:"divisional-chart",heading:"Divisional chart",description:"D2 to D60 varga chart wheel with Vargottama markers",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/{divisional-chart,navamsa}",docsSummary:"Generic divisional varga wheel from D2 Hora to D60 Shashtiamsa",topic:"Vedic"},{pascal:"RoxyKpChart",tag:"roxy-kp-chart",slug:"kp-chart",heading:"KP chart",description:"Full KP chart with Ascendant, Placidus cusps, and planets and nodes in tabbed stellar-hierarchy tables",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/chart",docsSummary:"Ascendant, cusps, planets and nodes with KP stellar hierarchy and house meanings",topic:"Vedic"},{pascal:"RoxyVedicPlanetsTable",tag:"roxy-vedic-planets-table",slug:"vedic-planets-table",heading:"Vedic planets",description:"Vedic planetary positions table with degree, nakshatra, pada, nakshatra lord, bhava, and all three avastha systems",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/birth-chart",docsSummary:"Degree, nakshatra, pada, lord, bhava, Baladi, Jagradadi and Deeptadi columns",topic:"Vedic"},{pascal:"RoxyKpPlanetsTable",tag:"roxy-kp-planets-table",slug:"kp-planets-table",heading:"KP planets",description:"KP planets table with sub-lord and sub-sub-lord columns",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/planets",docsSummary:"Sub-lord and sub-sub-lord columns",topic:"Vedic"},{pascal:"RoxyKpRulingPlanets",tag:"roxy-kp-ruling-planets",slug:"kp-ruling-planets",heading:"KP ruling planets",description:"KP ruling planets with day lord, Moon and Lagna stellar hierarchies, and house significators",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/ruling-planets",docsSummary:"Day lord, Moon/Lagna hierarchies, ruling planets, significators with house meanings",topic:"Vedic"},{pascal:"RoxyAshtakavargaGrid",tag:"roxy-ashtakavarga-grid",slug:"ashtakavarga-grid",heading:"Ashtakavarga",description:"Sarva and Bhinna ashtakavarga heatmap with bindu scores",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/ashtakavarga",docsSummary:"Sarva, Bhinna, and Shodhya Pinda views in a tabbed heatmap",topic:"Vedic"},{pascal:"RoxyShadbalaTable",tag:"roxy-shadbala-table",slug:"shadbala-table",heading:"Shadbala",description:"Six-fold planetary strength with adequacy badge per planet",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/shadbala",docsSummary:"Six-fold planetary strength bar plus rupas and adequacy badge",topic:"Vedic"},{pascal:"RoxyDashaTimeline",tag:"roxy-dasha-timeline",slug:"dasha-timeline",heading:"Vimshottari dasha",description:"Vimshottari dasha timeline, mahadasha through prana, with the active period highlighted",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/dasha/{current,major,sub/...}",docsSummary:"Vimshottari mahadasha, antardasha, pratyantardasha, sookshma and prana, drill-down at every level",topic:"Vedic"},{pascal:"RoxyGunaMilan",tag:"roxy-guna-milan",slug:"guna-milan",heading:"Guna milan",description:"36-point Ashtakoota matrimonial compatibility breakdown",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/compatibility",docsSummary:"36-point Ashtakoota with eight sub-scores",topic:"Vedic"},{pascal:"RoxyPanchangTable",tag:"roxy-panchang-table",slug:"panchang-table",heading:"Panchang",description:"Panchang muhurta table with auspicious and inauspicious periods",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/{basic,detailed}",docsSummary:"15+ muhurtas in detailed mode",topic:"Vedic"},{pascal:"RoxyVedicAspects",tag:"roxy-vedic-aspects",slug:"vedic-aspects",heading:"Vedic aspects",description:"Vedic graha drishti table: which planet aspects which, with mutual aspects surfaced first",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/aspects",docsSummary:"Graha drishti rows with aspect type, strength, and orb, plus mutual aspects",topic:"Vedic"},{pascal:"RoxyHoraTable",tag:"roxy-hora-table",slug:"hora-table",heading:"Hora",description:"Vedic Hora (planetary hours) table: 12 day and 12 night horas by ruling planet for electional timing",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/hora",docsSummary:"Day and night planetary hours with ruling planet and window",topic:"Vedic"},{pascal:"RoxyChoghadiyaGrid",tag:"roxy-choghadiya-grid",slug:"choghadiya-grid",heading:"Choghadiya",description:"Day and night Choghadiya muhurta tiles for activity timing",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/choghadiya",docsSummary:"Day and night Choghadiya muhurta tiles colored by effect",topic:"Vedic"},{pascal:"RoxyHeliacalTable",tag:"roxy-heliacal-table",slug:"heliacal-table",heading:"Heliacal rising and setting",description:"Whether each graha stands far enough from the Sun to be seen, with the date it next rises or sets",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/heliacal",docsSummary:"Udaya and asta windows for the six visible grahas, the calculation behind Guru Asta and Shukra Asta",topic:"Vedic"},{pascal:"RoxyVedicDaily",tag:"roxy-vedic-daily",slug:"vedic-daily",heading:"Vedic daily",description:"One native, one day: the verdict band, every graha state behind it, the Moon windows and the finance area",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/daily",docsSummary:"Composed Vedic daily reading with the classical rule behind every graha state, the Tara and Chandrabala windows in full, and all three sidereal frames named",topic:"Vedic"},{pascal:"RoxyKpFinanceCard",tag:"roxy-kp-finance-card",slug:"kp-finance-card",heading:"KP daily finance",description:"One native, one day scored for money: the band, the gain and loss significators, and the four sub lord layers behind the score",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/kp/daily-finance",docsSummary:"KP daily finance reading with the cusp sub lords, the running dasha lords, the ruling planets and the Moon sub lord windows each scored against the gain and loss houses, weighed into one band for the day",topic:"Vedic"},{pascal:"RoxyGocharaTable",tag:"roxy-gochara-table",slug:"gochara-table",heading:"Gochara transits",description:"Where each graha transits now, the natal house it falls in, and the Ashtakavarga-qualified kaksha verdict",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/transit",docsSummary:"Vedic gochara with aspects to the natal chart and the Gochara Kaksha reading drawn as a position within the sign",topic:"Vedic"},{pascal:"RoxyBhavaBalaTable",tag:"roxy-bhava-bala-table",slug:"bhava-bala-table",heading:"Bhava Bala",description:"The twelve houses ranked by strength, with the three classical components that make up each total",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/bhava-bala",docsSummary:"House strength in rupas and virupas, ranked, with Bhavadhipati, Dig and Drishti Bala shown as proportions of the total",topic:"Vedic"},{pascal:"RoxyBhavChalitTable",tag:"roxy-bhav-chalit-table",slug:"bhav-chalit-table",heading:"Bhav Chalit",description:"Which grahas change house once the bhavas are cut at their real cusps instead of at sign boundaries",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/bhav-chalit",docsSummary:"The Chalit chart against the Rashi chart, leading with how many grahas move and which, plus the unequal bhava spans",topic:"Vedic"},{pascal:"RoxyUpagrahaTable",tag:"roxy-upagraha-table",slug:"upagraha-table",heading:"Upagrahas",description:"The eleven upagrahas in their time-based and Sun-based groups, with rashi, degree, and nakshatra",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/upagraha",docsSummary:"Time-based and Sun-based upagrahas with rashi, degree, longitude and nakshatra",topic:"Vedic"},{pascal:"RoxyCharaKarakas",tag:"roxy-chara-karakas",slug:"chara-karakas",heading:"Chara karakas",description:"Jaimini chara karakas ranked Atmakaraka first, with the scheme that produced the ranking",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/chara-karakas",docsSummary:"Karaka offices in rank order with graha, degree, scheme, and what each is read for",topic:"Vedic"},{pascal:"RoxyArudhaPadas",tag:"roxy-arudha-padas",slug:"arudha-padas",heading:"Arudha padas",description:"The twelve Jaimini arudha padas with their derivation, the Arudha Lagna and the Upapada marked",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/arudha",docsSummary:"Twelve padas with bhava, lord, pada rashi, house from Lagna, and the classical exception marked",topic:"Vedic"},{pascal:"RoxyYogaList",tag:"roxy-yoga-list",slug:"yoga-list",heading:"Yoga catalog",description:"Yoga reference cards from the catalog with optional detail mode",docsLabel:"Vedic",endpointLabel:"GET /vedic-astrology/yoga, /vedic-astrology/yoga/{id}, POST /vedic-astrology/yoga/detect",docsSummary:"Filterable yoga cards from the 300 plus yoga catalog, grouped by verdict in detect mode",topic:"Vedic"},{pascal:"RoxyNakshatraCard",tag:"roxy-nakshatra-card",slug:"nakshatra-card",heading:"Nakshatra",description:"Nakshatra reference card with lord, deity, symbol, characteristics, and remedies",docsLabel:"Vedic",endpointLabel:"GET /vedic-astrology/nakshatras/{id}",docsSummary:"Lord, deity, symbol, characteristics, remedies",topic:"Vedic"},{pascal:"RoxyDoshaCard",tag:"roxy-dosha-card",slug:"dosha-card",heading:"Manglik dosha",description:"Manglik, Kaal Sarp, or Sade Sati presence card",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/dosha/{manglik,kalsarpa,sadhesati}",docsSummary:"Presence, severity, remedies, scoped effects",topic:"Vedic"},{pascal:"RoxyNumerologyCard",tag:"roxy-numerology-card",slug:"numerology-card",heading:"Life path number",description:"Numerology card for life path, expression, soul urge, personality, personal year, or full chart",docsLabel:"Numerology",endpointLabel:"POST /numerology/{life-path,expression,soul-urge,personality,birth-day,maturity,daily,personal-day,personal-month,personal-year,chart}",docsSummary:"Life path, expression, soul urge, personality, personal year, full chart",topic:"Numerology"},{pascal:"RoxyCompoundNumber",tag:"roxy-compound-number",slug:"compound-number",heading:"Compound number",description:"Chaldean compound number card with the numeral, its symbolic name, root number, fortunate or unfortunate nature, the lower number it repeats, and the meaning",docsLabel:"Numerology",endpointLabel:"GET /numerology/compound-number/{number}",docsSummary:"Compound 10 to 52 with name, root, nature and meaning",topic:"Numerology"},{pascal:"RoxyGematria",tag:"roxy-gematria",slug:"gematria",heading:"Gematria",description:"Gematria calculator that shows its work: every Hebrew spelling the input can take, the value under each cipher with the ones that are not single valued, the per letter breakdown right to left, the two substitution ciphers, the Latin alphabet ciphers and the curated words of equal value",docsLabel:"Kabbalah",endpointLabel:"POST /kabbalah/gematria",docsSummary:"Values by cipher, every candidate Hebrew spelling with its per letter breakdown, and equal-value words",topic:"Kabbalah"},{pascal:"RoxyTarotCard",tag:"roxy-tarot-card",slug:"tarot-card",heading:"Daily tarot card",description:"Single tarot card with upright/reversed flip animation",docsLabel:"Tarot",endpointLabel:"GET /tarot/cards/{id}, POST /tarot/daily",docsSummary:"Single card with upright and reversed flip",topic:"Tarot"},{pascal:"RoxyTarotCatalog",tag:"roxy-tarot-catalog",slug:"tarot-catalog",heading:"Tarot deck",description:"Responsive tarot deck gallery with card art, name, and an arcana and suit caption; a picked tile opens its tarot card in place, and emits roxy-symbol-select for a host that pairs its own",docsLabel:"Tarot",endpointLabel:"GET /tarot/cards",docsSummary:"Deck gallery tiles with card art, name, and arcana and suit; a pick opens the card in place",topic:"Tarot"},{pascal:"RoxyTarotSpread",tag:"roxy-tarot-spread",slug:"tarot-spread",heading:"Three-card spread",description:"Tarot spread renderer for three-card, Celtic Cross, love, or yes/no",docsLabel:"Tarot",endpointLabel:"POST /tarot/spreads/{three-card,celtic-cross,love,career,custom}, /tarot/yes-no, /tarot/draw",docsSummary:"Spreads with positions and reading",topic:"Tarot"},{pascal:"RoxyBodygraph",tag:"roxy-bodygraph",slug:"bodygraph",heading:"Bodygraph",description:"Human Design bodygraph with nine centers, channels, and activated gates, plus the full reading: type, strategy, authority, profile, definition, incarnation cross, and a gate and line meaning for every activation",docsLabel:"Human Design",endpointLabel:"POST /human-design/bodygraph",docsSummary:"Nine-center chart with defined and open centers, active channels, and gates, plus the type, strategy, authority, profile, and definition readings, the channels by circuit, the centers, and every activation with its gate and line meaning",topic:"Human Design"},{pascal:"RoxyHdTypeCard",tag:"roxy-hd-type-card",slug:"hd-type-card",heading:"HD type",description:"Human Design type reading without the chart: type, strategy, authority, and profile, with the aura mechanic, the signature and not-self themes, and the interpretation behind each label. Also renders the profile response with its two line keynotes",docsLabel:"Human Design",endpointLabel:"POST /human-design/type, /human-design/profile",docsSummary:"Type, strategy, authority, and profile tiles with the aura, signature, and not-self themes, plus the reading behind each label and the profile line keynotes",topic:"Human Design"},{pascal:"RoxyHdConnection",tag:"roxy-hd-connection",slug:"hd-connection",heading:"HD connection",description:"Human Design connection chart: the composite channels two people form, with circuit, dynamic, and which person holds each gate",docsLabel:"Human Design",endpointLabel:"POST /human-design/connection",docsSummary:"Electromagnetic, compromise, and dominance channels between two charts",topic:"Human Design"},{pascal:"RoxyHdPenta",tag:"roxy-hd-penta",slug:"hd-penta",heading:"HD penta",description:"Human Design penta for a 3 to 5 person group: upper and lower triangle channels, defined or open, with core channels and member coverage",docsLabel:"Human Design",endpointLabel:"POST /human-design/penta",docsSummary:"Group penta channels split into upper and lower triangles",topic:"Human Design"},{pascal:"RoxyHdVariables",tag:"roxy-hd-variables",slug:"hd-variables",heading:"HD variables",description:"Human Design variables: the four PHS arrows (determination, environment, perspective, motivation) with left/right direction, color, tone, and base, plus the reading for each arrow and the cognition",docsLabel:"Human Design",endpointLabel:"POST /human-design/variables",docsSummary:"The four transformation arrows with direction, color, tone, and base, plus a reading per arrow grouped by layer and the cognition",topic:"Human Design"},{pascal:"RoxyForecastTimeline",tag:"roxy-forecast-timeline",slug:"forecast-timeline",heading:"Forecast timeline",description:"Cross-domain forecast event strip colored by domain and weighted by significance",docsLabel:"Forecast",endpointLabel:"POST /forecast/{timeline,significant-dates,transits}",docsSummary:"Date-grouped events across Western, Vedic, and biorhythm domains, weighted by significance",topic:"Forecast"},{pascal:"RoxyForecastDigest",tag:"roxy-forecast-digest",slug:"forecast-digest",heading:"Forecast digest",description:"Rolled-up forecast across the next 24 hours, 7, 30, and 90 days with per-domain breakdown and top events",docsLabel:"Forecast",endpointLabel:"POST /forecast/digest",docsSummary:"Per-window event counts, domain breakdown, and the highest-significance events",topic:"Forecast"},{pascal:"RoxyBaziChart",tag:"roxy-bazi-chart",slug:"bazi-chart",heading:"Four pillars",description:"BaZi four pillars chart: stem over branch per pillar with the Ten God relation, the stems each branch stores, the Na Yin, the Day Master, the five-element balance and every interaction the pillars form",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/bazi/chart",docsSummary:"Year, month, day and hour pillars in hanzi with hidden stems, Ten Gods, Na Yin, element balance and interactions",topic:"Chinese Astrology"},{pascal:"RoxyLuckPillars",tag:"roxy-luck-pillars",slug:"luck-pillars",heading:"Luck pillars",description:"BaZi luck pillars: the ten-year stretches a chart is read through, each with its stem, branch and Ten God, plus the annual pillars inside them and the direction and starting age the sequence was built from",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/bazi/luck-pillars",docsSummary:"Ten-year luck pillars as a strip with ages and years, the annual pillars, and the direction and start age behind them",topic:"Chinese Astrology"},{pascal:"RoxyZodiacCard",tag:"roxy-zodiac-card",slug:"zodiac-card",heading:"Chinese zodiac",description:"Chinese zodiac card: the animal a date falls in, the reference read of one animal with its trine and partner animals, a daily reading, or the compatibility of a pair",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/zodiac/sign, GET /chinese-astrology/zodiac/{animals/{id},{id}/daily,compatibility/{sign1}/{sign2}}",docsSummary:"The animal for a date, one animal in full, a daily reading, or a pair scored",topic:"Chinese Astrology"},{pascal:"RoxyAlmanacDay",tag:"roxy-almanac-day",slug:"almanac-day",heading:"Chinese almanac",description:"Chinese almanac (Tong Shu): the day officer, what the day favours and avoids, the animal it clashes with, its three pillars and lunar mansion, for one day, a whole month, or a search for a date to act on",docsLabel:"Chinese",endpointLabel:"GET /chinese-astrology/calendar/{day/{date},monthly}, POST /chinese-astrology/calendar/auspicious-days",docsSummary:"Day officer, favours and avoids, clash animal and pillars, as one day, a month, or a date search",topic:"Chinese Astrology"},{pascal:"RoxyFlyingStarChart",tag:"roxy-flying-star-chart",slug:"flying-star-chart",heading:"Flying star chart",description:"Xuan Kong flying star plate: nine palaces on the compass with the mountain, period and water star of each, the facing and sitting mountains, and the structure the pair produces",docsLabel:"Feng Shui",endpointLabel:"POST /feng-shui/flying-stars/natal, GET /feng-shui/flying-stars/annual/{year}",docsSummary:"Nine-palace flying star plate with the mountain, period and water star per palace, the facing and sitting mountains and the structure",topic:"Feng Shui"},{pascal:"RoxyKuaCard",tag:"roxy-kua-card",slug:"kua-card",heading:"Kua and eight mansions",description:"Kua number with its trigram and the Eight Mansions map: all eight compass sectors on the nine-palace grid, each with its star, nature, rank and life domain, and the best and worst of them named",docsLabel:"Feng Shui",endpointLabel:"POST /feng-shui/kua, POST /feng-shui/eight-mansions",docsSummary:"Kua number and trigram over the eight-sector direction map, favourable and unfavourable sectors ranked",topic:"Feng Shui"},{pascal:"RoxyMayanDaySign",tag:"roxy-mayan-day-sign",slug:"mayan-day-sign",heading:"Mayan day sign",description:"Tzolkin day sign in all three of its spellings with the coefficient beside it, the trecena it sits in, the keynote, strengths, challenges and guidance, and on the full chart the Haab date, the Long Count, the Calendar Round, the year bearer and the four-fold cross",docsLabel:"Mesoamerican",endpointLabel:"POST /mesoamerican-astrology/mayan/tzolkin, POST /mesoamerican-astrology/mayan/chart",docsSummary:"Day sign and coefficient with the trecena, the reading, and the Calendar Round on the fuller response",topic:"Mesoamerican"},{pascal:"RoxyVastuMandala",tag:"roxy-vastu-mandala",slug:"vastu-mandala",heading:"Vastu mandala",description:"Vastu Purusha Mandala projected over a plot: every pada with the devata holding it, the brahmasthan block, the vamsa diagonals and where they cross, and in the entrance read the square the main door falls on with the verse effect for that pada",docsLabel:"Vastu",endpointLabel:"POST /vastu/mandala, POST /vastu/entrance",docsSummary:"Pada grid with a devata per square, the brahmasthan, and the entrance pada lit with its effect",topic:"Vastu"},{pascal:"RoxyBiorhythmChart",tag:"roxy-biorhythm-chart",slug:"biorhythm-chart",heading:"Daily biorhythm",description:"Daily biorhythm bars or multi-day forecast cycle lines",docsLabel:"Biorhythm",endpointLabel:"POST /biorhythm/{daily,forecast,critical-days}",docsSummary:"Daily bars, forecast cycle lines, critical days",topic:"Biorhythm"},{pascal:"RoxyDoshaConstitution",tag:"roxy-dosha-constitution",slug:"dosha-constitution",heading:"Ayurvedic constitution",description:"Ayurvedic constitution read from a birth chart: the three humour shares as one bar, the dominant and secondary humour, the three cited factors behind the blend with their verses, the shadbala ranking the third factor reads, and the scope note the response carries",docsLabel:"Ayurveda",endpointLabel:"POST /ayurveda/constitution",docsSummary:"Vata, pitta and kapha shares as one bar with the dominant humour and the cited factors behind it",topic:"Ayurveda"},{pascal:"RoxyHexagram",tag:"roxy-hexagram",slug:"hexagram",heading:"I Ching hexagram",description:"I Ching hexagram drawn line by line with trigram glyphs, judgment, image, and a reading for every line: the oracle statement and what it asks of the querent. A cast highlights the moving lines and shows only their readings, plus the hexagram it transforms into",docsLabel:"I Ching",endpointLabel:"GET /iching/hexagrams/{number}, /iching/hexagrams/random, /iching/hexagrams/lookup, /iching/cast, POST /iching/daily, /iching/daily/cast",docsSummary:"Hexagram figure with trigrams, judgment, image, and a reading per line (statement plus meaning); a cast highlights the moving lines and the resulting hexagram",topic:"I Ching"},{pascal:"RoxyCrystalCard",tag:"roxy-crystal-card",slug:"crystal-card",heading:"Crystal detail",description:"Single-crystal detail card with photo, spiritual, emotional, and physical meaning, metaphysical attributes, affirmation, and pairings; as a widget the visitor types a crystal name and picks it",docsLabel:"Crystals",endpointLabel:"GET /crystals/{id}",docsSummary:"Photo, meaning sections, chakra, zodiac, element, hardness, keywords, and pairings",topic:"Crystals"},{pascal:"RoxyCrystalGrid",tag:"roxy-crystal-grid",slug:"crystal-grid",heading:"Crystal grid",description:"Responsive crystal gallery with photo, name, and colour swatches from any crystals list response, filterable by chakra, zodiac sign, element, colour, and planet; a picked tile opens its crystal card in place",docsLabel:"Crystals",endpointLabel:"GET /crystals, /crystals/chakra/{chakra}, /crystals/element/{element}, /crystals/zodiac/{sign}, /crystals/birthstone/{month}, /crystals/search",docsSummary:"Crystal gallery with chakra, zodiac, element, colour, and planet filters; a pick opens the card in place",topic:"Crystals"},{pascal:"RoxyDreamCard",tag:"roxy-dream-card",slug:"dream-card",heading:"Dream symbol",description:"Dream symbol card with the symbol name, full interpretation, and dictionary letter; as a widget the visitor types a symbol and picks it",docsLabel:"Dreams",endpointLabel:"GET /dreams/symbols/{id}",docsSummary:"Symbol name, interpretation body, and letter chip",topic:"Dreams"},{pascal:"RoxyDreamSearch",tag:"roxy-dream-search",slug:"dream-search",heading:"Dream search",description:"The dream dictionary as selectable tiles under a search box and an A to Z bar; a picked tile opens its dream card in place, and emits roxy-symbol-select for a host that pairs its own",docsLabel:"Dreams",endpointLabel:"GET /dreams/symbols",docsSummary:"The dream dictionary as tiles, browsed A to Z or searched; a pick opens the card in place",topic:"Dreams"},{pascal:"RoxyAngelNumberCard",tag:"roxy-angel-number-card",slug:"angel-number-card",heading:"Angel number",description:"Angel number card with title, core message, badges, keywords, life-area interpretations, affirmation, and action steps",docsLabel:"Angel Numbers",endpointLabel:"GET /angel-numbers/numbers/{number}, POST /angel-numbers/daily",docsSummary:"Number meaning with spiritual, love, career, money, twin flame, biblical, and shadow sections",topic:"Angel Numbers"},{pascal:"RoxyAngelNumberLookup",tag:"roxy-angel-number-lookup",slug:"angel-number-lookup",heading:"Angel number lookup",description:"Angel number sequence analysis with pattern classification, the known meaning when present, and a digit-root fallback for any number",docsLabel:"Angel Numbers",endpointLabel:"GET /angel-numbers/lookup",docsSummary:"Pattern analysis plus known meaning and digit-root fallback",topic:"Angel Numbers"},{pascal:"RoxyReport",tag:"roxy-report",slug:"report",heading:"Branded report",description:"Branded report for any /reports operation: the visitor fills the form, and the finished document arrives under your name as a PDF download or in place on the page",docsLabel:"Reports",endpointLabel:"POST /reports/...",docsSummary:"Form to finished branded report, as a PDF download or inline HTML",topic:"Reports"},{pascal:"RoxyReferenceCard",tag:"roxy-reference-card",slug:"reference-card",heading:"Reference card",description:"Glossary entry for any reference lookup: zodiac sign, planet meaning, rashi, I Ching trigram, Human Design gate or center, or numerology number",docsLabel:"Reference",endpointLabel:"GET /astrology/{signs,planet-meanings}/{id}, /vedic-astrology/{rashis,avasthas}/{id}, /iching/trigrams/{id}, /human-design/gates/{number}, /human-design/centers/{id}, /numerology/meanings/{number}",docsSummary:"Symbol, name, description, keyword chips, and an attribute grid for any glossary lookup",topic:"Helpers"},{pascal:"RoxyEndpointForm",tag:"roxy-endpoint-form",slug:"endpoint-form",heading:"Schema-driven form",description:"Schema-driven form that emits roxy-submit with a validated payload",docsLabel:"Helper",endpointLabel:"Any endpoint, from the spec",docsSummary:"Schema-driven form, emits roxy-submit",topic:"Helpers",selfFetching:true},{pascal:"RoxyLocationSearch",tag:"roxy-location-search",slug:"location-search",heading:"City search",description:"City search input with debounced /location/search calls",docsLabel:"Helper",endpointLabel:"GET /location/search",docsSummary:"Debounced city search input, emits roxy-location-select",topic:"Helpers",selfFetching:true},{pascal:"RoxyData",tag:"roxy-data",slug:"data",heading:"Generic renderer",description:"Generic fallback renderer for any OpenAPI response shape",docsLabel:"Helper",endpointLabel:"Any response shape",docsSummary:"Generic fallback renderer for unknown shapes",topic:"Helpers",selfFetching:true}];var hf=wi.map(n=>n.slug);
|
|
162
|
+
</g>`}renderEmptyGrid(e){let t=[];for(let r=0;r<e;r++)for(let n=0;n<e;n++)t.push(_.svg`<rect class="pada" x=${n} y=${r} width="1" height="1"></rect>`);return t}renderDoor(e,t){let r=t.devata?.name??"";return this.renderPada(e,t.cell?.columnFromWest,t.cell?.rowFromNorth,"pada pada-door",t.square,r,r)}renderVamsa(e,t){return(t??[]).map(r=>{let[n,i]=Di(e,r.from),[o,l]=Di(e,r.to);return _.svg`<line class="vamsa" x1=${n} y1=${i} x2=${o} y2=${l}></line>`})}renderBrahmasthan(e,t){let r=t??[];if(r.length<3)return _.nothing;let n=r.map(i=>Di(e,i).join(",")).join(" ");return _.svg`<polygon class="brahmasthan" points=${n}></polygon>`}renderAtimarma(e,t){let r=new Set(t?.atimarma??[]);return r.size===0?_.nothing:(t?.cells??[]).filter(n=>n.square!=null&&r.has(n.square)).map(n=>{let[i,o]=Di(e,n.center);return _.svg`<circle class="atimarma" cx=${i} cy=${o} r="0.06"></circle>`})}renderDevatas(e,t){let r=new Map;for(let n of t??[])!n.devataName||n.square==null||r.set(n.devataName,[...r.get(n.devataName)??[],n.square]);return r.size===0?_.nothing:_.html`<section part="section devatas"><h3 class="block-title">${this.t("Devata")}</h3><ul class="devatas">${[...r].map(([n,i])=>_.html`<li><b>${n}</b> ${i.sort((o,l)=>o-l).map(o=>q(e,o)).join(", ")}</li>`)}</ul></section>`}renderLegend(e,t){if(e)return _.html`<div class="legend" part="legend"><span><span class="swatch swatch-door"></span>${this.t("Door pada")}</span></div>`;let r=(t?.cells??[]).some(n=>n.withinPlot===false);return _.html`<div class="legend" part="legend"><span><span class="swatch swatch-brahma"></span>${this.t("Brahmasthan")}</span> ${r?_.html`<span><span class="swatch swatch-outside"></span>${this.t("Outside the plot")}</span>`:_.nothing}</div>`}renderFacts(e,t,r,n){let i=t.conventions?.grid;return _.html`<div class="facts" part="details">${i?_.html`<span><span class="roxy-label">${Se(e,"grid")}</span><b>${ie(e,"grid",i)}</b></span>`:_.nothing} ${n?.pada!=null?_.html`<span><span class="roxy-label">${this.t("Pada")}</span><b>${q(e,n.pada)}</b></span>`:_.nothing} ${n?.side?_.html`<span><span class="roxy-label">${this.t("Side")}</span><b>${ie(e,"facing",n.side)}</b></span>`:_.nothing} ${n?.startCorner?_.html`<span><span class="roxy-label">${this.t("Counted from")}</span>${ie(e,"facing",n.startCorner)} ${n.ordinalOnSide!=null?_.html`· ${q(e,n.ordinalOnSide)}`:_.nothing}</span>`:_.nothing} ${n?.devata?.name?_.html`<span><span class="roxy-label">${this.t("Devata")}</span><b>${n.devata.name}</b> ${n.devata.padaCount!=null?_.html`· ${this.t("Pada")} ${q(e,n.devata.padaCount)}`:_.nothing}</span>`:_.nothing} ${n?.recommendedPadas?.length?_.html`<span><span class="roxy-label">${this.t("Recommended padas")}</span>${n.recommendedPadas.map(o=>q(e,o)).join(", ")}</span>`:_.nothing} ${r?.brahmasthan?.area!=null?_.html`<span><span class="roxy-label">${this.t("Brahmasthan area")}</span><b>${this.areaLabel(e,r.brahmasthan.area,r.conventions?.unit)}</b></span>`:_.nothing} ${r?.marma?.areaEach!=null?_.html`<span><span class="roxy-label">${this.t("Area of one marma")}</span>${this.areaLabel(e,r.marma.areaEach,r.conventions?.unit)}</span>`:_.nothing} ${r?.atimarma?.length?_.html`<span><span class="roxy-label">${this.t("Crossing points")}</span>${r.atimarma.map(o=>q(e,o)).join(", ")}</span>`:_.nothing}</div>`}renderSources(e){return e.length===0?_.nothing:_.html`<section part="section sources"><ul class="cites">${e.map(t=>_.html`<li>${Qs(t)}</li>`)}</ul></section>`}areaLabel(e,t,r){let n=b(e,t,2);if(!r)return n;let i=qf[r]??`${r}\xB2`;return _.html`<span title="${ie(e,"unit",r)}">${n} ${i}</span>`}ringLabel(e){let t=Vf[e];return t?this.t(t):D(e)}verdictLabel(e){let t=Uf[e];return t?this.t(t):D(e)}};Ja.endpoints=uc,Ja.styles=[u,_.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);--_brahma:color-mix(in srgb, var(--roxy-accent) 16%, var(--roxy-surface));--_outside:color-mix(in srgb, var(--roxy-muted) 18%, var(--roxy-surface));--_door:color-mix(in srgb, var(--roxy-success) 26%, var(--roxy-surface));grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-md);flex-wrap:wrap;display:flex}.title,.block-title{margin:0}.block-title{margin-block-end:var(--roxy-space-sm)}.verdict-auspicious{color:var(--roxy-success-fg)}.verdict-inauspicious{color:var(--roxy-danger-fg)}.verdict-mixed{color:var(--roxy-warning-fg)}.frame{place-items:center;gap:calc(var(--roxy-space-unit) / 2) var(--roxy-space-xs);inline-size:100%;max-inline-size:var(--roxy-chart-max-width,32rem);grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:".n.""w plate e"".s.";margin-inline:auto;display:grid}.compass{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.compass-n{grid-area:n}.compass-s{grid-area:s}.compass-w,.compass-e{writing-mode:vertical-rl}.compass-w{grid-area:w;rotate:180deg}.compass-e{grid-area:e}svg{grid-area:plate;width:100%;height:auto;display:block}.pada{fill:var(--roxy-surface);stroke:var(--roxy-border);stroke-width:.012px}.pada-innerRing,.pada-innerCorner,.pada-around-brahma{fill:color-mix(in srgb, var(--roxy-accent) 7%, var(--roxy-surface))}.pada-center,.pada-brahma{fill:var(--_brahma)}.pada-outside{fill:var(--_outside)}.pada-door{fill:var(--_door);stroke:var(--roxy-fg);stroke-width:.03px}.brahmasthan{fill:none;stroke:var(--roxy-accent-ink);stroke-width:.05px}.vamsa{stroke:var(--roxy-secondary);stroke-width:.02px;stroke-dasharray:.12 .1}.atimarma{fill:var(--roxy-accent-ink)}text{fill:var(--roxy-fg);text-anchor:middle}.devata{font-size:calc(var(--roxy-text-base) * .011875)}.square-no{fill:var(--roxy-muted);font-size:calc(var(--roxy-text-base) * .00875)}@container (width<=30rem){.devata{display:none}.square-no{font-size:calc(var(--roxy-text-base) * .02125);dominant-baseline:middle;translate:0 .31lh}}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b,.devatas b{color:var(--roxy-fg)}.devatas{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-secondary);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums;flex-wrap:wrap;margin:0;padding:0;list-style:none;display:flex}.legend{gap:var(--roxy-space-xs) var(--roxy-space-md);color:var(--roxy-muted);font-size:var(--roxy-text-xs);flex-wrap:wrap;display:flex}.swatch{inline-size:var(--roxy-space-sm);block-size:var(--roxy-space-sm);border:1px solid var(--roxy-border);border-radius:var(--roxy-radius-sm);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}.swatch-brahma{background:var(--_brahma)}.swatch-outside{background:var(--_outside)}.swatch-door{background:var(--_door)}.effect{margin:0;padding-block-start:var(--roxy-space-md)}.reading{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);border-block-start:0;margin:0}.cites{color:var(--roxy-muted);font-size:var(--roxy-text-xs);margin:0;padding:0;list-style:none}`],m([(0,nm.property)({type:String,reflect:true})],Ja.prototype,"mode",2),Ja=m([x("roxy-vastu-mandala")],Ja);function Xf(s){let a=Number.parseInt(s??"",10),e=Math.round(Math.sqrt(a));if(!(!Number.isFinite(e)||e<2||e*e!==a))return{size:e,originX:0,cellW:1,originY:0,cellH:1}}var nt=require("lit");var rs=class extends g{renderData(a){let e=a.aspects??[],t=a.mutualAspects??[],r=a.planets??[];if(e.length===0&&t.length===0)return this.renderEmpty();let n=a.datetime?fe(this.effectiveLang(),a.datetime):"";return nt.html`<div class="wrap" part="card" aria-label="${this.t("Vedic aspects")}"><div class="head" part="header"><h2>${this.t("Vedic aspects")}</h2>${n?nt.html`<p class="roxy-label">${this.t("Chart time {{when}}",{when:n})}</p>`:nt.nothing}</div>${r.length>0?nt.html`<div part="section positions"><h3 class="section-label">${this.t("Sidereal positions")}</h3><ul class="roxy-chips">${r.map(i=>nt.html`<li class="position"><strong>${i.name}</strong> ${typeof i.longitude=="number"?pt(i.longitude):i.sign??""}</li>`)}</ul></div>`:nt.nothing} ${t.length>0?nt.html`<div part="section mutual-aspects"><h3 class="section-label">${this.t("Mutual aspects")}</h3><ul class="roxy-chips">${t.map(i=>nt.html`<li class="mutual-pill">${i.planet1} <span class="roxy-glyph" aria-hidden="true">${Td}</span> ${i.planet2} ${i.aspectType?nt.html`<span class="rel">${i.aspectType}</span>`:nt.nothing}</li>`)}</ul></div>`:nt.nothing} ${e.length>0?nt.html`<div class="overflow-scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Vedic aspects")}"><table><caption class="roxy-sr-only">${this.t("Vedic planetary aspects: aspecting planet, aspect type, aspected planet, strength and orb.")}</caption><thead><tr><th scope="col">${this.t("From")}</th><th scope="col">${this.t("Aspect")}</th><th scope="col">${this.t("To")}</th><th scope="col">${this.t("Strength")}</th><th scope="col">${this.t("Orb")}</th></tr></thead><tbody>${e.map(i=>nt.html`<tr><td>${i.aspectingPlanet}</td><td><span class="kind">${i.aspectType}</span></td><td>${i.aspectedPlanet}</td><td>${typeof i.strength=="number"?nt.html`<span class="bar" style="--_v:${Math.max(10,Math.min(100,i.strength))}"></span><span class="num">${b(this.effectiveLang(),i.strength,0)}</span>`:nt.nothing}</td><td class="num">${typeof i.orb=="number"?`${b(this.effectiveLang(),i.orb,2)}\xB0`:""}</td></tr>`)}</tbody></table></div>`:nt.nothing}</div>`}};rs.endpoints=fc,rs.styles=[u,nt.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}h2,h3,p{margin:0}.section-label{margin-block-end:var(--roxy-space-xs)}.position,.mutual-pill{font-variant-numeric:tabular-nums;min-width:0}.position strong,.mutual-pill{color:var(--roxy-fg)}.overflow-scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}tbody tr:last-child td{border-block-end:0}.kind{font-weight:var(--roxy-weight-bold)}.num{color:var(--roxy-muted)}.bar{inline-size:calc(var(--_v) * 5ch / 100);block-size:.3lh;border-radius:var(--roxy-radius-full);background:var(--roxy-accent);vertical-align:middle;margin-inline-end:var(--roxy-space-xs);display:inline-block}`],rs=m([x("roxy-vedic-aspects")],rs);var I=require("lit");var el={favourable:"Favourable",underdelivered:"Underdelivered",obstructed:"Obstructed",void:"Void",aggravated:"Aggravated",unfavourable:"Unfavourable"},Jf=Object.keys(el),Qf={favourable:"success",aggravated:"danger",unfavourable:"danger"},im=8,Ai={"very-strong":"Very strong",strong:"Strong",moderate:"Moderate",weak:"Weak"},ex={day:"Day",finance:"Finance",natal:"Natal"},om={mahadasha:"Mahadasha",antardasha:"Antardasha",pratyantardasha:"Pratyantardasha"},ss=class extends g{renderData(a){let e=a.grahas??[];return e.length?I.html`<div class="wrap" part="card" aria-label="${this.t("Vedic daily reading")}">${this.renderHead(a)} ${this.renderPanchanga(a)} ${this.renderGrahas(e,a.houseThemes)} ${this.renderWindows(a)} ${this.renderFinance(a)} ${this.renderDasha(a)} ${this.renderProvenance(a)}</div>`:this.renderEmpty()}renderHead(a){let e=new Map((a.tally??[]).map(r=>[r.state,r.count])),t=e.get("favourable")??0;return I.html`<header class="head" part="header"><div class="title-row"><h2>${this.t("Vedic daily")}</h2><span class="roxy-label">${Ds(this.effectiveLang(),a.dayStart,a.dayEnd)}</span></div><div class="verdict-row"><span class="verdict ${a.verdict}">${this.t(Ai[a.verdict])}</span> <span class="evidence">${this.t("{{supportive}} of {{evaluated}} grahas support this day",{supportive:t,evaluated:a.evaluated})}</span></div>${e.size?I.html`<ul class="tally roxy-chips" part="legend">${Jf.filter(r=>e.get(r)).map(r=>I.html`<li class="pill">${this.t(el[r])} ${e.get(r)}</li>`)}</ul>`:I.nothing} ${a.subject?I.html`<p class="note">${this.t("Born with the Moon in {{rashi}}, nakshatra {{nakshatra}}",{rashi:a.subject.janmaRashi,nakshatra:a.subject.janmaNakshatra})}</p>`:I.nothing} ${(a.degraded??[]).map(r=>I.html`<p class="note">${this.t("{{component}} unavailable: {{reason}}",{component:r.component,reason:r.reason})}</p>`)}</header>`}renderPanchanga(a){let e=a.panchanga;if(!e)return I.nothing;let t=(r,n)=>n?I.html`<div><dt>${r}</dt><dd>${n.number?`${n.number}. `:""}${n.name} ${n.validTo?I.html`<span class="until">${this.t("until {{time}}",{time:fe(this.effectiveLang(),n.validTo)})}</span>`:I.nothing}</dd></div>`:I.nothing;return I.html`<section class="block" part="section panchanga"><h3>${this.t("Panchang")}</h3><dl class="roxy-facts" part="details"><div><dt>${this.t("Vara")}</dt><dd>${e.vara}</dd></div><div><dt>${this.t("Paksha")}</dt><dd>${e.paksha}</dd></div>${t(this.t("Tithi"),e.tithi)} ${t(this.t("Nakshatra"),e.nakshatra)} ${t(this.t("Yoga"),e.yoga)} ${t(this.t("Karana"),e.karana)}</dl></section>`}theme(a,e){return a?.[String(e)]?.join(", ")??""}renderGrahas(a,e){return I.html`<section class="block" part="section grahas"><h3>${this.t("Grahas today")}</h3><div class="scroll" tabindex="0" role="region" aria-label="${this.t("Grahas today")}"><table part="table"><caption class="roxy-sr-only">${this.t("Each transiting graha with its sign, the house it occupies from the natal Moon, its bindus, its kaksha and the state the classical rules give it.")}</caption><thead><tr><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Sign")}</th><th scope="col">${this.t("House")}</th><th scope="col">${this.t("Bindus")}</th><th scope="col">${this.t("Kaksha")}</th><th scope="col">${this.t("State")}</th></tr></thead><tbody>${a.map(t=>{let r=S(t.graha)??"",n=this.theme(e,t.houseFromMoon);return I.html`<tr><td>${r?I.html`<span class="glyph roxy-glyph">${r}</span>`:I.nothing}${t.graha}</td><td>${t.sign}</td><td title="${n}">${t.houseFromMoon}</td><td>${typeof t.binduCount=="number"?t.binduCount:""}</td><td>${this.renderKaksha(t.kaksha)}</td><td><span class="state roxy-chip ${t.state}" data-tone="${Qf[t.state]??I.nothing}" title="${t.stateSource??""}">${this.t(el[t.state])}</span></td></tr>`})}</tbody></table></div></section>`}renderKaksha(a){if(!a||typeof a.number!="number")return I.nothing;let e=a.bindu===true?"yes":a.bindu===false?"no":"",t=a.bindu===true?this.t("this kaksha lord gave bindu"):a.bindu===false?this.t("this kaksha lord gave no bindu"):"",r=this.t("Kaksha {{n}} of {{total}}, ruled by {{graha}}, spanning {{start}}\xB0 to {{end}}\xB0 of the sign",{n:a.number,total:im,graha:a.lord,start:b(this.effectiveLang(),a.startDegree,2),end:b(this.effectiveLang(),a.endDegree,2)});return I.html`<span class="kaksha" title="${t?`${r} \xB7 ${t}`:r}">${a.number}/${im} <span class="dot ${e}" aria-hidden="true"></span></span>`}renderWindows(a){let e=a.tara??[],t=a.chandrabala??[];if(!e.length&&!t.length)return I.nothing;let r=(n,i)=>I.html`<small>${Ds(this.effectiveLang(),n,i)}</small>`;return I.html`<section class="block" part="section windows"><h3>${this.t("Tara and Chandrabala")}</h3>${e.length?I.html`<div class="chips">${e.map(n=>I.html`<span class="window"><span>${n.number}. ${n.name}${n.quality?` \xB7 ${n.quality}`:""}</span> ${r(n.validFrom,n.validTo)}</span>`)}</div>`:I.nothing} ${t.length?I.html`<div class="chips">${t.map(n=>I.html`<span class="window ${n.favourable?"yes":"no"}"><span>${this.t("Moon in {{sign}}, house {{n}}",{sign:n.moonSign,n:n.houseFromMoon})} ${n.ashtamaChandra?I.html`<span class="mark">· ${this.t("Ashtama Chandra")}</span>`:I.nothing} </span>${r(n.validFrom,n.validTo)}</span>`)}</div>`:I.nothing}</section>`}renderFinance(a){let e=a.areas?.finance;if(!e)return I.nothing;let t=a.houseThemes,r=n=>{let i=this.theme(t,n.house);return I.html`<li>${n.graha} · ${this.t("House {{n}}",{n:n.house})}${i?` (${i})`:""} · ${this.t("level {{level}} {{grade}}",{level:n.level,grade:n.grade})} ${n.dashaLevels?.length?I.html`<span class="note">${n.dashaLevels.map(o=>this.t(om[o])).join(", ")}</span>`:I.nothing}</li>`};return I.html`<section class="block" part="section finance"><h3>${this.t("Finance")}</h3><div class="verdict-row"><span class="verdict ${e.band??""}">${e.band?this.t(Ai[e.band]):""}</span> ${typeof e.positive=="number"&&typeof e.negative=="number"?I.html`<span class="evidence">${this.t("{{positive}} positive against {{negative}} negative",{positive:e.positive,negative:e.negative})}</span>`:I.nothing}</div><div class="lists">${e.drivers?.length?I.html`<div><h3>${this.t("Drivers")}</h3><ul>${e.drivers.map(r)}</ul></div>`:I.nothing} ${e.cautions?.length?I.html`<div><h3>${this.t("Cautions")}</h3><ul>${e.cautions.map(r)}</ul></div>`:I.nothing}</div>${this.renderComposite(e.composite)}</section>`}renderComposite(a){return a?I.html`<div class="composite"><h3>${this.t("Combined score")}</h3><div class="verdict-row"><span class="verdict ${a.band}">${this.t(Ai[a.band])}</span> <span class="evidence">${a.score}</span></div><ul class="layers">${a.layers.map(e=>I.html`<li><span>${this.t(ex[e.layer])}</span> <span class="evidence">${e.score}</span> <span class="band">${this.t(Ai[e.band])}</span></li>`)}</ul></div>`:I.nothing}renderDasha(a){let e=a.dasha??[];return e.length?I.html`<section class="block" part="section dasha"><h3>${this.t("Dasha")}</h3><div class="chips">${e.map(t=>I.html`<span class="window"><span>${this.t(om[t.level])} · ${t.lord}</span> <small>${Ds(this.effectiveLang(),t.startDate,t.endDate)}</small></span>`)}</div></section>`:I.nothing}renderProvenance(a){return a.frames?I.html`<section class="block" part="section frame">${Ad(this.effectiveLang(),a.frames,this.translator)}</section>`:I.nothing}};ss.endpoints=xc,ss.styles=[u,re,Re,I.css`.wrap{grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head,.block{gap:var(--roxy-space-sm);padding:var(--roxy-space-md);display:grid}.block{border-block-start:1px solid var(--roxy-border)}h2,h3,p{margin:0}.title-row{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict-row{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.verdict{color:var(--roxy-secondary);font-size:var(--roxy-text-lg);font-weight:var(--roxy-weight-bold)}.verdict:is(.very-strong,.strong){color:var(--roxy-success-fg)}.verdict.moderate{color:var(--roxy-accent-ink)}.evidence{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums}.pill{font-variant-numeric:tabular-nums}.roxy-facts{margin:0}.until{color:var(--roxy-muted);font-size:var(--roxy-text-xs);display:block}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.state{cursor:help}.kaksha{align-items:center;gap:var(--roxy-space-xs);cursor:help;display:inline-flex}.dot{aspect-ratio:1;border-radius:var(--roxy-radius-full);background:var(--roxy-border);inline-size:1ch}.dot.yes{background:var(--roxy-success)}.dot.no{background:var(--roxy-warning)}.chips{gap:var(--roxy-space-sm) var(--roxy-space-lg);flex-wrap:wrap;display:flex}.window{font-size:var(--roxy-text-sm);display:grid}.window small{color:var(--roxy-muted);font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.window.yes>:first-child{color:var(--roxy-success-fg)}.window.no>:first-child,.mark{color:var(--roxy-danger-fg)}.lists{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.lists ul{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-md)}.note{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.composite{gap:var(--roxy-space-sm);display:grid}.layers{gap:var(--roxy-space-xs);font-size:var(--roxy-text-sm);margin:0;padding:0;list-style:none;display:grid}.layers li{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}.layers .band{color:var(--roxy-secondary)}`],ss=m([x("roxy-vedic-daily")],ss);var lm=require("lit"),Pi=require("lit/decorators.js"),cm=require("lit/directives/unsafe-html.js");var ia=class extends g{constructor(){super(...arguments);this.chartViewport=new Ve(this);this.chartStyle="north";this.chartReference="lagna";this.lagnaOverride="";this.setStyle=e=>{this.chartStyle=e}}resolveReference(){if(this.lagnaOverride)return this.lagnaOverride;if(this.chartReference==="moon")return this.data?.meta?.Moon?.rashi}viewModel(){return this.data?.meta?Zn(this.data.meta,{divisionLabel:"D1 Rashi",lagnaOverride:this.resolveReference(),states:this.data}):null}renderData(e){let t=this.viewModel();if(!t)return this.renderEmpty();let r=this.chartReference==="moon"&&!this.lagnaOverride?this.t("Chandra lagna"):this.t("Vedic kundli");return lm.html`<div class="wrap" part="card"><div class="header" part="header"><div><h2 class="title">${r}</h2>${ve(this.effectiveLang(),e.frame,this.translator)} ${Jn(t,this.translator)}</div>${Qn(this.chartStyle,this.setStyle,this.translator)}</div><div id="kundli-panel-${this.chartStyle}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}">${this.chartViewport.renderChartViewport((0,cm.unsafeHTML)(Xn(t,{style:this.chartStyle,lang:this.effectiveLang()})),r,this.translator)}</div></div>`}};ia.endpoints=bc,ia.styles=[u,et,re,En,ei,dt],m([(0,Pi.property)({type:String,reflect:true,attribute:"chart-style"})],ia.prototype,"chartStyle",2),m([(0,Pi.property)({type:String,reflect:true,attribute:"chart-reference"})],ia.prototype,"chartReference",2),m([(0,Pi.property)({type:String,reflect:true,attribute:"lagna-override"})],ia.prototype,"lagnaOverride",2),ia=m([x("roxy-vedic-kundli")],ia);var Y=require("lit");var tx=["Lagna","Sun","Moon","Mars","Mercury","Jupiter","Venus","Saturn","Rahu","Ketu"],dm=[["awastha","Baladi."],["jagradadi","Jagradadi."],["deeptadi","Deeptadi."]],ns=class extends g{orderedRows(){let a=this.data?.meta??{},e=new Set,t=[];for(let r of tx){let n=a[r];n&&(t.push([r,n]),e.add(r))}for(let[r,n]of Object.entries(a))e.has(r)||t.push([r,n]);return t}renderData(a){if(!a.meta)return this.renderEmpty();let e=this.orderedRows(),t=e.some(([,r])=>r.avasthaInfo);return Y.html`<div class="wrap" part="card" aria-label="${this.t("Vedic planetary positions")}"><header class="head" part="header"><h2>${this.t("Planetary positions")}</h2>${ve(this.effectiveLang(),a.frame,this.translator)}</header><div class="scroll" part="table" tabindex="0" role="region" aria-label="${this.t("Planetary positions")}"><table role="table"><caption class="roxy-sr-only">${this.t("Vedic planetary positions: each graha with its rashi, degree, nakshatra, pada, nakshatra lord, house, its state in all three avastha systems, and retrograde state. Jagradadi and Deeptadi are read from sign dignity, which the nodes and the Lagna do not have, so those two cells are blank on the Rahu, Ketu and Lagna rows. Uranus, Neptune and Pluto appear only when asked for and rule no sign, so every avastha and house cell is blank on their rows too.")} ${t?this.t("Each avastha state is followed by its meaning."):Y.nothing}</caption><thead><tr><th scope="col">${this.t("Graha")}</th><th scope="col">${this.t("Rashi")}</th><th scope="col">${this.t("Degree")}</th><th scope="col">${this.t("Nakshatra")}</th><th scope="col">${this.t("Pada")}</th><th scope="col">${this.t("Nak. lord")}</th><th scope="col">${this.t("House")}</th><th scope="col" title="${this.t("Baladi: the five age states, set by degree within the sign")}">${this.t("Baladi")}</th><th scope="col" title="${this.t("Jagradadi: the three waking states, set by sign dignity. The seven classical grahas only")}">${this.t("Jagradadi")}</th><th scope="col" title="${this.t("Deeptadi: the nine dispositional states, set by sign dignity. The seven classical grahas only")}">${this.t("Deeptadi")}</th><th scope="col">${this.t("Retro")}</th></tr></thead><tbody>${e.map(([r,n])=>{let i=(n.graha??r)==="Lagna",o=S(n.graha??r)??"",l=J(n.rashi)??"";return Y.html`<tr class="${i?"lagna":""}"><td class="graha">${o?Y.html`<span class="glyph roxy-glyph">${o}</span>`:Y.nothing}${n.graha??r}</td><td>${l?Y.html`<span class="glyph roxy-glyph">${l}</span>`:Y.nothing}${n.rashi??""}</td><td>${typeof n.longitude=="number"?pt(n.longitude):""}</td><td>${n.nakshatra?.name??""}</td><td>${n.nakshatra?.pada??""}</td><td>${n.nakshatra?.lord??""}</td><td>${typeof n.house=="number"?n.house:""}</td>${dm.map(([c])=>Y.html`<td>${n[c]??""}${n.avasthaInfo?.[c]?.meaning?Y.html`<span class="gloss">${n.avasthaInfo[c].meaning}</span>`:Y.nothing}</td>`)}<td>${n.isRetrograde?Y.html`<span class="retro">R</span>`:Y.nothing}</td></tr>`})} ${this.renderModernRows()}</tbody></table></div>${this.renderCombustion()} ${this.renderPlanetaryWar()} ${this.renderInterpretations()} ${this.renderYogas()} ${this.renderHouses()}</div>`}renderModernRows(){let a=this.data?.modernPlanets??[];return a.length===0?Y.nothing:a.map((e,t)=>{let r=J(e.rashi)??"";return Y.html`<tr class="modern ${t===0?"modern-first":""}"><td class="graha">${qs(e.planet,e.sanskritName)}</td><td>${r?Y.html`<span class="glyph roxy-glyph">${r}</span>`:Y.nothing}${e.rashi??""}</td><td>${typeof e.longitude=="number"?pt(e.longitude):""}</td><td>${e.nakshatra?.name??""}</td><td>${e.nakshatra?.pada??""}</td><td>${e.nakshatra?.lord??""}</td><td></td><td></td><td></td><td></td><td>${e.isRetrograde?Y.html`<span class="retro">R</span>`:Y.nothing}</td></tr>`})}renderCombustion(){let a=this.data?.combustion??[];return a.length===0?Y.nothing:Y.html`<details class="panel" part="section combustion"><summary>${this.t("Combust grahas")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>{let t=S(e.planet)??"",r=b(this.effectiveLang(),e.distanceFromSun,2),n=b(this.effectiveLang(),e.orb,1);return Y.html`<div class="condition"><span class="planet">${Je(t)} ${e.planet}</span> <span class="detail">${this.t("{{distance}} deg from Sun, within {{orb}} deg orb",{distance:r,orb:n})}</span></div>`})}</div></details>`}renderPlanetaryWar(){let a=this.data?.planetaryWar??[];return a.length===0?Y.nothing:Y.html`<details class="panel" part="section planetary-war"><summary>${this.t("Planetary wars")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>{let t=b(this.effectiveLang(),e.distance,2);return Y.html`<div class="condition"><span class="planet">${this.t("{{first}} vs {{second}}",{first:e.planet1,second:e.planet2})}</span> <span class="detail">${this.t("{{distance}} deg apart",{distance:t})}</span> <span class="winner">${this.t("{{graha}} wins",{graha:e.winner})}</span></div>`})}</div></details>`}renderInterpretations(){if(this.hideReadings)return Y.nothing;let a=this.data?.interpretations??{},e=this.orderedRows().map(([t,r])=>[r.graha??t,a[r.graha??t],r.avasthaInfo]).filter(([,t,r])=>t!=null||r!=null);return e.length===0?Y.nothing:Y.html`<details class="panel" part="section readings"><summary>${this.t("Interpretations")}<span class="summary-count">${e.length}</span>${he()}</summary><div class="panel-body">${e.map(([t,r,n])=>{let i=S(t)??"";return Y.html`<div class="interp"><span class="planet">${Je(i)} ${t}</span> ${r?.rashi?Y.html`<p><span class="label">${this.t("Rashi.")}</span> ${r.rashi}</p>`:Y.nothing} ${r?.nakshatra?Y.html`<p><span class="label">${this.t("Nakshatra.")}</span> ${r.nakshatra}</p>`:Y.nothing} ${dm.map(([o,l])=>n?.[o]?.interpretation?Y.html`<p><span class="label">${this.t(l)}</span> ${n[o].interpretation}</p>`:Y.nothing)}</div>`})}</div></details>`}renderHouses(){let a=(this.data?.houses??[]).filter(e=>e.name||e.description);return a.length===0?Y.nothing:Y.html`<details class="panel" part="section bhava-significations"><summary>${this.t("Bhava significations")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>Y.html`<div class="bhava"><span class="name">${e.number}. ${e.name??""}</span> ${e.description?Y.html`<p class="desc">${e.description}</p>`:Y.nothing}</div>`)}</div></details>`}renderYogas(){let a=(this.data?.yogas??[]).filter(e=>e.present);return a.length===0?Y.nothing:Y.html`<details class="panel" part="section yogas"><summary>${this.t("Yogas")}<span class="summary-count">${a.length}</span>${he()}</summary><div class="panel-body">${a.map(e=>Y.html`<div class="bhava"><span class="name">${e.name} ${e.quality?Y.html`<span class="quality ${e.quality.toLowerCase()}">${e.quality}</span>`:Y.nothing}</span> ${e.result?Y.html`<p class="desc">${e.result}</p>`:Y.nothing}</div>`)}</div></details>`}};ns.endpoints=vc,ns.styles=[u,re,X,Y.css`.wrap{overflow:hidden}.head{padding:var(--roxy-space-md);border-block-end:1px solid var(--roxy-border)}h2,p{margin:0}.scroll{min-width:0;overflow-x:auto}table{width:100%}th,td{white-space:nowrap}:is(th,td):first-child{padding-inline-start:var(--roxy-space-md)}:is(th,td):last-child{padding-inline-end:var(--roxy-space-md)}tbody tr.lagna td:first-child{box-shadow:inset var(--roxy-line-thick) 0 0 var(--roxy-accent)}tbody tr.lagna .glyph{color:var(--roxy-accent-ink)}tbody tr.modern-first td{border-block-start:var(--roxy-line-thick) solid var(--roxy-border)}td.graha{font-weight:var(--roxy-weight-bold)}.glyph{color:var(--roxy-muted);margin-inline-end:var(--roxy-space-xs)}.gloss{color:var(--roxy-secondary);font-size:var(--roxy-text-xs);display:block}.retro{color:var(--roxy-warning-fg);font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}details.panel{border-block-start:1px solid var(--roxy-border)}details.panel>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm);padding:var(--roxy-space-sm) var(--roxy-space-md);font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold);display:flex}.summary-count{margin-inline:auto var(--roxy-space-xs);color:var(--roxy-muted);font-weight:var(--roxy-weight-normal);font-variant-numeric:tabular-nums}.panel-body{gap:var(--roxy-space-sm);padding:0 var(--roxy-space-md) var(--roxy-space-md);font-size:var(--roxy-text-sm);grid-template-columns:minmax(0,1fr);display:grid}.condition{align-items:baseline;gap:var(--roxy-space-xs) var(--roxy-space-sm);flex-wrap:wrap;display:flex}:is(.condition,.interp) .planet,.bhava .name{font-weight:var(--roxy-weight-bold)}.condition .detail{color:var(--roxy-muted);font-variant-numeric:tabular-nums}.condition .winner{color:var(--roxy-success-fg);font-weight:var(--roxy-weight-bold)}.interp,.bhava{gap:calc(var(--roxy-space-unit) / 2);display:grid}.interp .label{color:var(--roxy-muted);font-weight:var(--roxy-weight-bold)}.bhava .desc{color:var(--roxy-muted)}.quality{font-size:var(--roxy-text-xs);font-weight:var(--roxy-weight-bold)}.quality.positive{color:var(--roxy-success-fg)}.quality.negative{color:var(--roxy-danger-fg)}.quality.both{color:var(--roxy-muted)}`],ns=m([x("roxy-vedic-planets-table")],ns);var ye=require("lit"),gm=require("lit/decorators.js");function pm(s){return s.suppressedBy||void 0}var hm=["classical","asraya","dala","akriti","sankhya"];function mm(s){let a=hm.indexOf(s.family);return a===-1?hm.length:a}var ax=[{id:"present",source:"Present",open:true,noteSource:"Every classical condition is satisfied by this chart."},{id:"outranked",source:"Outranked",open:true,noteSource:"The rule matched, but a stronger family silences it under the classical precedence norms. Each card names the family that took precedence."},{id:"absent",source:"Not present",open:false,noteSource:"At least one classical condition fails. Read the evidence for which."}],rx={Positive:"success",Negative:"danger",Both:"warning"},Qa=class extends g{constructor(){super(...arguments);this.filter="";this.handleInput=e=>{this.filter=e.target.value}}verdictOf(e){return e.present?"present":pm(e)?"outranked":"absent"}renderVerdictGroup(e,t){if(!t.length)return ye.nothing;let r=[...t].sort((n,i)=>mm(n)-mm(i));return ye.html`<details class="group" part="section verdict" ?open="${e.open||!!this.filter}"><summary class="group-summary"><span class="group-label">${this.t(e.source)}</span> <span class="group-count">${t.length}</span></summary><p class="group-note">${this.t(e.noteSource)}</p><div class="detail-grid">${r.map(n=>this.renderDetectCard(n))}</div></details>`}renderQualityChip(e){return ye.html`<span class="quality-chip roxy-chip quality-${e}" data-tone="${rx[e]??ye.nothing}">${e}</span>`}renderFamilyChip(e){return e.family?ye.html`<span class="family-chip roxy-chip" title="${this.t("Classical family")}">${U(e.family)}</span>`:ye.nothing}renderDetailCard(e){return ye.html`<div class="detail-card"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):ye.nothing} ${this.renderFamilyChip(e)}</p>${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${this.renderEffects(e.result)}</div>`}renderEffects(e){return!e||this.hideReadings?ye.nothing:ye.html`<details part="reading"><summary>${this.t("Effects")}</summary><div class="result-body">${e}</div></details>`}renderDetectCard(e){let t=e.present?void 0:pm(e),[r,n,i]=e.present?["is-present","Present","success"]:t?["is-outranked",`Outranked by ${U(t)}`,"warning"]:["is-absent","Not present",void 0];return ye.html`<div class="detail-card ${e.present?"":t?"outranked":"absent"}"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):ye.nothing} ${this.renderFamilyChip(e)} <span class="present-badge roxy-chip ${r}" data-tone="${i??ye.nothing}">${n}</span></p>${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${e.present?this.renderEffects(e.result):ye.nothing} ${e.evidence?ye.html`<p class="evidence">${e.evidence}</p>`:ye.nothing}</div>`}renderData(e){let t=this.filter.toLowerCase();if("description"in e&&typeof e.description=="string"){let r=e;return ye.html`<div class="wrap" part="card">${this.renderDetailCard(r)}</div>`}if("yogas"in e&&Array.isArray(e.yogas)){let r=e.yogas;if(r.length>0&&"present"in r[0]){let c=r,d=t?c.filter(p=>p.name.toLowerCase().includes(t)):c,h=e.total??c.filter(p=>p.present).length;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Detected yogas")}</h2><span class="count">${this.t("{{count}} of {{total}} present",{count:h,total:c.length})}</span></div>${ve(this.effectiveLang(),e.frame,this.translator)}<div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter detected yogas by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="group-stack" part="section verdicts" role="region" aria-live="polite" aria-label="${this.t("Detected yogas")}">${d.length>0?ax.map(p=>this.renderVerdictGroup(p,d.filter(f=>this.verdictOf(f)===p.id))):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}if(r.length>0&&"description"in r[0]){let c=r,d=t?c.filter(p=>p.name.toLowerCase().includes(t)):c,h=e.total;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Yoga catalog")}</h2>${h!==void 0?ye.html`<span class="count">${this.t("{{count}} total",{count:h})}</span>`:ye.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter yoga list by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="detail-grid" part="section yogas" role="region" aria-live="polite" aria-label="${this.t("Yoga results")}">${d.length>0?d.map(p=>this.renderDetailCard(p)):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}let i=r,o=t?i.filter(c=>c.name.toLowerCase().includes(t)):i,l=e.total;return ye.html`<div class="wrap" part="card"><div class="head" part="header"><h2>${this.t("Yoga catalog")}</h2>${l!==void 0?ye.html`<span class="count">${this.t("{{count}} total",{count:l})}</span>`:ye.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="${this.t("Filter yogas...")}" aria-label="${this.t("Filter yoga list by name")}" .value="${this.filter}" @input="${this.handleInput}"></div><div class="grid" part="section yogas" role="region" aria-live="polite" aria-label="${this.t("Yoga results")}">${o.length>0?o.map(c=>ye.html`<div class="yoga-chip">${c.name}</div>`):ye.html`<p class="no-results">${this.t("No yogas match your search.")}</p>`}</div></div>`}return ye.html`<div class="roxy-empty" role="status">${this.t("No yoga data")}</div>`}};Qa.endpoints=$c,Qa.styles=[u,re,ye.css`.wrap{gap:var(--roxy-space-md);padding:var(--roxy-space-md);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}h2,p{margin:0}.count,.no-results{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.search{inline-size:100%;max-inline-size:32ch;font-size:var(--roxy-text-sm)}.search::placeholder{color:var(--roxy-muted)}.grid{gap:0 var(--roxy-space-md);grid-template-columns:repeat(auto-fill,minmax(min(100%,22ch),1fr));display:grid}.yoga-chip{padding-block:var(--roxy-space-xs);border-block-end:1px solid var(--roxy-border);font-size:var(--roxy-text-sm);overflow-wrap:anywhere}.detail-card{gap:var(--roxy-space-sm);display:grid}.detail-grid>.detail-card+.detail-card{border-block-start:1px solid var(--roxy-border);padding-block-start:var(--roxy-space-sm)}.detail-name{align-items:center;gap:var(--roxy-space-sm);font-weight:var(--roxy-weight-bold);flex-wrap:wrap;display:flex}.wrap>.detail-card .detail-name{font-size:var(--roxy-text-lg)}.family-chip{color:var(--roxy-fg)}.quality-chip,.present-badge{font-weight:var(--roxy-weight-bold)}.detail-card.absent,.detail-card.outranked{color:var(--roxy-secondary)}.group-stack,.group,.detail-grid{gap:var(--roxy-space-sm);display:grid}.group-stack{gap:var(--roxy-space-md)}.group-summary{align-items:baseline;gap:var(--roxy-space-sm);color:var(--roxy-secondary);list-style:none;display:flex}.group-summary:before,.detail-card details>summary:before{content:"+";font-size:var(--roxy-text-base);line-height:1}.group-summary:before{color:var(--roxy-accent-ink)}.group[open]>.group-summary:before,.detail-card details[open]>summary:before{content:"-"}.group-label{font-size:var(--roxy-text-sm);font-weight:var(--roxy-weight-bold)}.group-count{font-size:var(--roxy-text-xs);font-variant-numeric:tabular-nums}.group-note,.evidence{color:var(--roxy-muted);font-size:var(--roxy-text-xs)}.description{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.detail-card details{font-size:var(--roxy-text-sm)}.detail-card details>summary{align-items:center;gap:var(--roxy-space-xs);padding-block:var(--roxy-space-xs);color:var(--roxy-accent-ink);list-style:none;display:flex}.result-body{color:var(--roxy-fg);padding-block-start:var(--roxy-space-xs)}`],m([(0,gm.state)()],Qa.prototype,"filter",2),Qa=m([x("roxy-yoga-list")],Qa);var C=require("lit"),um=require("lit/decorators.js");var Mi={"secret-friend":"Secret friend",trine:"Trine",same:"Same",neutral:"Neutral",harm:"Harm",clash:"Clash"},ym={excellent:"Excellent",strong:"Strong",workable:"Workable",challenging:"Challenging",difficult:"Difficult"},er=class extends g{constructor(){super(...arguments);this.mode="sign"}renderData(e){if(this.mode==="compatibility"&&"signs"in e)return this.renderCompatibility(e);let t="animal"in e&&e.animal?e.animal:e,r=this.effectiveLang(),n="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,i="date"in e&&e.date?M(r,e.date):"";return C.html`<article class="card" part="card" aria-labelledby="zodiac-title"><header class="head" part="header"><span class="hanzi" lang="zh">${t.chinese??""}</span><div><h2 class="title" id="zodiac-title">${y(t,"name")}</h2><div class="sub">${t.pinyin??""}${i?` ${i}`:""}</div></div>${n!==null?C.html`<span class="energy" part="details" aria-label="${this.t("Energy {{value}} of 10",{value:n})}">${this.t("Energy {{value}}/10",{value:q(r,n)})} <span class="energy-bar"><span style="width:${n/10*100}%"></span></span></span>`:C.nothing}</header>${this.renderIdentity(e,t)} ${this.renderDaily(e)} ${this.renderReference(e)} ${"interpretation"in e&&e.interpretation&&!this.hideReadings?C.html`<p class="prose" part="section interpretation">${e.interpretation}</p>`:C.nothing} ${"conventions"in e?lr(e.conventions,this.translator,this.effectiveLang()):C.nothing}</article>`}renderIdentity(e,t){let r="yearPillar"in e&&e.yearPillar||"dayPillar"in e&&e.dayPillar||null,n="hours"in e?e.hours:void 0,i="element"in e&&typeof e.element=="string"?e:void 0,o=i?y(i,"element"):y(t,"element"),l=At(i?.element??t.element),c="polarity"in e&&typeof e.polarity=="string"&&e.polarity||t.polarity||"";return!o&&!c&&!r&&!n&&!t.branch?C.nothing:C.html`<div class="facts" part="details">${o?C.html`<span><span class="roxy-label">${this.t("Element")}</span><b class="element-word ${l}">${o}</b></span>`:C.nothing} ${c?C.html`<span><span class="roxy-label">${this.t("Polarity")}</span>${c}</span>`:C.nothing} ${t.branch?C.html`<span><span class="roxy-label">${this.t("Branch")}</span>${t.branch}</span>`:C.nothing} ${r?C.html`<span><span class="roxy-label">${this.t("Pillar")}</span> <b>${r.stem??""}</b> ${r.branch??""}</span>`:C.nothing} ${n&&typeof n.start=="number"?C.html`<span><span class="roxy-label">${this.t("Hours")}</span>${this.t("{{start}} to {{end}}",{start:this.hourLabel(n.start),end:this.hourLabel(n.end)})}</span>`:C.nothing}</div>`}hourLabel(e){return typeof e=="number"?`${String(e).padStart(2,"0")}:00`:""}renderDaily(e){if(!("relationship"in e)||!("overview"in e))return C.nothing;let t="year"in e?e.year:void 0,r="benMingNian"in e?e.benMingNian:false;return C.html`${C.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Day")}</span><b>${e.relationship&&Mi[e.relationship]?this.t(Mi[e.relationship]):e.relationship??""}</b></span> ${t?C.html`<span><span class="roxy-label">${this.t("Year")}</span>${t.pillar??""} ${y(t,"animal")} ${t.relationship&&Mi[t.relationship]?this.t(Mi[t.relationship]):t.relationship??""}</span>`:C.nothing} ${r?C.html`<span class="roxy-chip tag">${this.t("Ben Ming Nian")}</span>`:C.nothing}</div>`} ${this.hideReadings?C.nothing:C.html`${e.overview?C.html`<p class="prose" part="section overview">${e.overview}</p>`:C.nothing}<div class="sections" part="section outlook">${"love"in e&&e.love?C.html`<div class="section"><h3 class="block-title">${this.t("Love")}</h3><p>${e.love}</p></div>`:C.nothing} ${"career"in e&&e.career?C.html`<div class="section"><h3 class="block-title">${this.t("Career")}</h3><p>${e.career}</p></div>`:C.nothing} ${"advice"in e&&e.advice?C.html`<div class="section"><h3 class="block-title">${this.t("Advice")}</h3><p>${e.advice}</p></div>`:C.nothing}</div>`} ${t?.note&&!this.hideReadings?C.html`<p class="prose" part="reading">${t.note}</p>`:C.nothing}`}renderReference(e){if(!("trine"in e)&&!("secretFriend"in e))return C.nothing;let t=e;return C.html`${t.trine?C.html`<section part="section trine"><h3 class="block-title">${this.t("Trine")} ${t.trine.number??""}</h3><div class="facts"><span><b lang="zh">${t.trine.chinese??""}</b> <span class="element-word ${At(t.trine.element)}">${y(t.trine,"element")}</span></span> ${t.trine.members?.length?C.html`<span class="roxy-chips">${t.trine.members.map(r=>C.html`<span class="roxy-chip">${r}</span>`)}</span>`:C.nothing} ${t.trine.theme?C.html`<span>${t.trine.theme}</span>`:C.nothing}</div></section>`:C.nothing} ${this.renderPartners(t)} ${this.hideReadings?C.nothing:C.html`${t.summary?C.html`<p class="prose" part="section summary">${t.summary}</p>`:C.nothing} ${t.traits?.length?C.html`<section part="section traits"><h3 class="block-title">${this.t("Traits")}</h3><ul class="roxy-chips">${t.traits.map(r=>C.html`<li>${r}</li>`)}</ul></section>`:C.nothing} ${this.bullets(this.t("Strengths"),t.strengths)} ${this.bullets(this.t("Weaknesses"),t.weaknesses)} ${t.compatibilitySummary?C.html`<p class="prose" part="reading">${t.compatibilitySummary}</p>`:C.nothing}`}`}renderPartners(e){let r=[["Secret friend",e.secretFriend],["Clash",e.clashPartner],["Harm",e.harmPartner]].filter(([,n])=>n?.name);return r.length===0?C.nothing:C.html`<section part="section partners"><div class="partners">${r.map(([n,i])=>C.html`<div class="partner"><span class="role roxy-label">${this.t(n)}</span> <span class="glyph" lang="zh">${i?.chinese??""}</span> <span class="who">${y(i,"name")}</span></div>`)}</div></section>`}bullets(e,t){return t?.length?C.html`<section part="section list"><h3 class="block-title">${e}</h3><ul class="bullets">${t.map(r=>C.html`<li>${r}</li>`)}</ul></section>`:C.nothing}renderCompatibility(e){let t=e.signs?.first,r=e.signs?.second,n=typeof e.score=="number"?e.score:null;return C.html`<article class="card" part="card" aria-labelledby="zodiac-title"><header class="head" part="header"><div class="pair"><span class="side"><span class="hanzi" lang="zh">${t?.chinese??""}</span> <span class="sub">${y(t,"name")}</span></span> <span class="side"><span class="hanzi" lang="zh">${r?.chinese??""}</span> <span class="sub">${y(r,"name")}</span></span></div></header><h2 class="title" id="zodiac-title">${y(e,"relationshipName")} <span lang="zh">${e.relationshipChinese??""}</span></h2>${n!==null?C.html`<div class="score" part="details"><span class="score-value">${n}</span> <span class="score-track"><span class="score-fill" style="width:${Math.max(0,Math.min(100,n))}%"></span></span> ${e.verdict?C.html`<span class="roxy-chip tag">${ym[e.verdict]?this.t(ym[e.verdict]):e.verdict}</span>`:C.nothing}</div>`:C.nothing} ${e.sharedElement?C.html`<div class="facts" part="details"><span><span class="roxy-label">${this.t("Shared element")}</span><b class="element-word ${At(e.sharedElement)}">${y(e,"sharedElement")}</b></span></div>`:C.nothing} ${this.hideReadings?C.nothing:C.html`${e.summary?C.html`<p class="prose" part="section summary">${e.summary}</p>`:C.nothing} ${this.bullets(this.t("Strengths"),e.strengths)} ${this.bullets(this.t("Frictions"),e.frictions)} ${e.advice?C.html`<p class="prose" part="reading">${e.advice}</p>`:C.nothing}`}</article>`}};er.endpoints=wc,er.styles=[u,re,ma,C.css`.card{gap:var(--roxy-space-md);padding:var(--roxy-space-lg);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}.hanzi{font-size:calc(var(--roxy-text-base) * 2.75);color:var(--roxy-accent-ink);line-height:1}.title,.block-title{margin:0}.title{font-size:var(--roxy-text-xl)}.block-title{margin-block-end:var(--roxy-space-sm)}.sub{color:var(--roxy-muted);font-size:var(--roxy-text-sm)}.energy{color:var(--roxy-secondary);font-size:var(--roxy-text-sm);font-variant-numeric:tabular-nums;margin-inline-start:auto}.energy-bar,.score-track{background:var(--roxy-border);border-radius:var(--roxy-radius-full);overflow:hidden}.energy-bar{block-size:.25lh;inline-size:12ch;vertical-align:middle;margin-inline-start:var(--roxy-space-xs);display:inline-block}.energy-bar>span,.score-fill{background:var(--roxy-accent);height:100%;display:block}.facts{gap:var(--roxy-space-xs) var(--roxy-space-md);border-block-start:1px solid var(--roxy-border);color:var(--roxy-secondary);font-size:var(--roxy-text-sm);flex-wrap:wrap;padding-block-start:var(--roxy-space-md);display:flex}.facts .roxy-label{margin-inline-end:var(--roxy-space-xs)}.facts b{color:var(--roxy-fg)}.prose{margin:0}.prose[part~=reading]{padding-block-start:var(--roxy-space-md)}section .facts{border-block-start:0;padding-block-start:0}.sections{gap:var(--roxy-space-md);grid-template-columns:repeat(auto-fit,minmax(min(100%,24ch),1fr));display:grid}.section p{font-size:var(--roxy-text-sm);margin:0}.bullets{font-size:var(--roxy-text-sm);margin:0;padding-inline-start:var(--roxy-space-lg)}.partners{gap:var(--roxy-space-sm);grid-template-columns:repeat(auto-fit,minmax(16ch,1fr));display:grid}.partner,.pair .side{gap:calc(var(--roxy-space-unit) / 2);text-align:center;display:grid}.partner .glyph{font-size:calc(var(--roxy-text-base) * 1.5);line-height:var(--roxy-leading-tight);color:var(--roxy-accent-ink)}.partner .who{font-size:var(--roxy-text-sm)}.score{align-items:baseline;gap:var(--roxy-space-sm);flex-wrap:wrap;display:flex}.score-value{font-size:calc(var(--roxy-text-base) * 2);font-weight:var(--roxy-weight-bold);font-variant-numeric:tabular-nums;line-height:1}.score-track{flex:1;block-size:.35lh;min-inline-size:16ch}.tag{color:var(--roxy-info-fg)}.pair{justify-content:center;align-items:center;gap:var(--roxy-space-md);flex-wrap:wrap;display:flex}`],m([(0,um.property)({type:String,reflect:true})],er.prototype,"mode",2),er=m([x("roxy-zodiac-card")],er);var fm={post_astrology_natal_chart:{tag:"roxy-natal-chart",pascal:"RoxyNatalChart",operationId:"generateNatalChart"},post_astrology_synastry:{tag:"roxy-synastry-chart",pascal:"RoxySynastryChart",operationId:"calculateSynastry"},post_astrology_transits:{tag:"roxy-transits-table",pascal:"RoxyTransitsTable",operationId:"calculateTransits"},post_astrology_transit_aspects:{tag:"roxy-transit-wheel",pascal:"RoxyTransitWheel",operationId:"calculateTransitAspects"},post_astrology_aspects:{tag:"roxy-aspects-table",pascal:"RoxyAspectsTable",operationId:"calculateAspects"},post_astrology_aspect_patterns:{tag:"roxy-aspects-table",pascal:"RoxyAspectsTable",operationId:"detectAspectPatterns"},get_astrology_moon_phase_current:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getCurrentMoonPhase",attrs:{mode:"current"}},get_astrology_moon_phase_upcoming:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getUpcomingMoonPhases",attrs:{mode:"upcoming"}},get_astrology_moon_phase_calendar_year_month:{tag:"roxy-moon-phase",pascal:"RoxyMoonPhase",operationId:"getMoonCalendar",attrs:{mode:"calendar"}},get_astrology_horoscope_sign_daily:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getDailyHoroscope",attrs:{period:"daily"}},get_astrology_horoscope_sign_weekly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getWeeklyHoroscope",attrs:{period:"weekly"}},get_astrology_horoscope_sign_monthly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getMonthlyHoroscope",attrs:{period:"monthly"}},get_astrology_horoscope_sign_yearly:{tag:"roxy-horoscope-card",pascal:"RoxyHoroscopeCard",operationId:"getYearlyHoroscope",attrs:{period:"yearly"}},post_astrology_astrocartography:{tag:"roxy-astrocartography-map",pascal:"RoxyAstrocartographyMap",operationId:"generateAstrocartography"},post_astrology_local_space:{tag:"roxy-local-space-compass",pascal:"RoxyLocalSpaceCompass",operationId:"generateLocalSpace"},post_astrology_relocation_chart:{tag:"roxy-relocation-wheel",pascal:"RoxyRelocationWheel",operationId:"generateRelocationChart"},post_astrology_asteroids:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateAsteroids"},post_astrology_lilith:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateLilith"},post_astrology_progressions:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateProgressions"},post_astrology_solar_arc:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"generateSolarArc"},post_astrology_arabic_lots:{tag:"roxy-positions-table",pascal:"RoxyPositionsTable",operationId:"calculateArabicLots"},post_astrology_planets_monthly:{tag:"roxy-ephemeris-table",pascal:"RoxyEphemerisTable",operationId:"getMonthlyTropicalEphemeris"},post_vedic_astrology_planetary_positions_monthly:{tag:"roxy-ephemeris-table",pascal:"RoxyEphemerisTable",operationId:"getMonthlyEphemeris"},post_astrology_fixed_stars:{tag:"roxy-fixed-stars",pascal:"RoxyFixedStars",operationId:"generateFixedStars"},post_astrology_profections:{tag:"roxy-profection-card",pascal:"RoxyProfectionCard",operationId:"generateProfections"},post_astrology_compatibility_score:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateCompatibility",attrs:{mode:"astrology"}},post_numerology_compatibility:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateNumCompatibility",attrs:{mode:"numerology"}},post_biorhythm_compatibility:{tag:"roxy-compatibility-card",pascal:"RoxyCompatibilityCard",operationId:"calculateBioCompatibility",attrs:{mode:"biorhythm"}},post_vedic_astrology_birth_chart:{tag:"roxy-vedic-kundli",pascal:"RoxyVedicKundli",operationId:"generateBirthChart"},post_vedic_astrology_divisional_chart:{tag:"roxy-divisional-chart",pascal:"RoxyDivisionalChart",operationId:"generateDivisionalChart"},post_vedic_astrology_navamsa:{tag:"roxy-divisional-chart",pascal:"RoxyDivisionalChart",operationId:"generateNavamsa"},post_vedic_astrology_kp_chart:{tag:"roxy-kp-chart",pascal:"RoxyKpChart",operationId:"generateKpChart"},post_vedic_astrology_kp_planets:{tag:"roxy-kp-planets-table",pascal:"RoxyKpPlanetsTable",operationId:"getKpPlanets"},post_vedic_astrology_kp_ruling_planets:{tag:"roxy-kp-ruling-planets",pascal:"RoxyKpRulingPlanets",operationId:"getKpRulingPlanets"},post_vedic_astrology_ashtakavarga:{tag:"roxy-ashtakavarga-grid",pascal:"RoxyAshtakavargaGrid",operationId:"calculateAshtakavarga"},post_vedic_astrology_shadbala:{tag:"roxy-shadbala-table",pascal:"RoxyShadbalaTable",operationId:"calculateShadbala"},post_vedic_astrology_dasha_major:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getMajorDashas",attrs:{period:"major"}},post_vedic_astrology_dasha_current:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getCurrentDasha",attrs:{period:"current"}},post_vedic_astrology_dasha_sub_mahadasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getSubDashas",attrs:{period:"sub"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getPratyantardashas",attrs:{period:"antara"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha_pratyantardasha:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getSookshmaDashas",attrs:{period:"sookshma"}},post_vedic_astrology_dasha_sub_mahadasha_antardasha_pratyantardasha_sookshma:{tag:"roxy-dasha-timeline",pascal:"RoxyDashaTimeline",operationId:"getPranaDashas",attrs:{period:"prana"}},post_vedic_astrology_compatibility:{tag:"roxy-guna-milan",pascal:"RoxyGunaMilan",operationId:"calculateGunMilan"},post_vedic_astrology_panchang_detailed:{tag:"roxy-panchang-table",pascal:"RoxyPanchangTable",operationId:"getDetailedPanchang",attrs:{detail:"detailed"}},post_vedic_astrology_panchang_basic:{tag:"roxy-panchang-table",pascal:"RoxyPanchangTable",operationId:"getBasicPanchang",attrs:{detail:"basic"}},post_vedic_astrology_aspects:{tag:"roxy-vedic-aspects",pascal:"RoxyVedicAspects",operationId:"calculateDrishti"},post_vedic_astrology_panchang_hora:{tag:"roxy-hora-table",pascal:"RoxyHoraTable",operationId:"getHora"},post_vedic_astrology_panchang_choghadiya:{tag:"roxy-choghadiya-grid",pascal:"RoxyChoghadiyaGrid",operationId:"getChoghadiya"},post_vedic_astrology_heliacal:{tag:"roxy-heliacal-table",pascal:"RoxyHeliacalTable",operationId:"getHeliacalVisibility"},post_vedic_astrology_daily:{tag:"roxy-vedic-daily",pascal:"RoxyVedicDaily",operationId:"getVedicDailyReading"},post_vedic_astrology_kp_daily_finance:{tag:"roxy-kp-finance-card",pascal:"RoxyKpFinanceCard",operationId:"getKpDailyFinance"},post_vedic_astrology_transit:{tag:"roxy-gochara-table",pascal:"RoxyGocharaTable",operationId:"calculateTransit"},post_vedic_astrology_bhava_bala:{tag:"roxy-bhava-bala-table",pascal:"RoxyBhavaBalaTable",operationId:"calculateBhavaBala"},post_vedic_astrology_bhav_chalit:{tag:"roxy-bhav-chalit-table",pascal:"RoxyBhavChalitTable",operationId:"calculateBhavChalit"},post_vedic_astrology_upagraha:{tag:"roxy-upagraha-table",pascal:"RoxyUpagrahaTable",operationId:"getUpagrahaPositions"},post_vedic_astrology_chara_karakas:{tag:"roxy-chara-karakas",pascal:"RoxyCharaKarakas",operationId:"calculateCharaKarakas"},post_vedic_astrology_arudha:{tag:"roxy-arudha-padas",pascal:"RoxyArudhaPadas",operationId:"calculateArudhaPadas"},get_vedic_astrology_yoga:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"listYogas"},post_vedic_astrology_yoga_detect:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"detectYogas"},get_vedic_astrology_yoga_id:{tag:"roxy-yoga-list",pascal:"RoxyYogaList",operationId:"getYoga"},get_vedic_astrology_nakshatras_id:{tag:"roxy-nakshatra-card",pascal:"RoxyNakshatraCard",operationId:"getNakshatra"},post_vedic_astrology_dosha_manglik:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkManglikDosha",attrs:{type:"manglik"}},post_vedic_astrology_dosha_kalsarpa:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkKalsarpaDosha",attrs:{type:"kalsarpa"}},post_vedic_astrology_dosha_sadhesati:{tag:"roxy-dosha-card",pascal:"RoxyDoshaCard",operationId:"checkSadhesati",attrs:{type:"sadhesati"}},post_numerology_life_path:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateLifePath",attrs:{type:"life-path"}},post_numerology_expression:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateExpression",attrs:{type:"expression"}},post_numerology_soul_urge:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateSoulUrge",attrs:{type:"soul-urge"}},post_numerology_personality:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonality",attrs:{type:"personality"}},post_numerology_birth_day:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateBirthDay",attrs:{type:"birth-day"}},post_numerology_maturity:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculateMaturity",attrs:{type:"maturity"}},post_numerology_daily:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"getDailyNumber",attrs:{type:"daily"}},post_numerology_personal_day:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalDay",attrs:{type:"personal-day"}},post_numerology_personal_month:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalMonth",attrs:{type:"personal-month"}},post_numerology_personal_year:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"calculatePersonalYear",attrs:{type:"personal-year"}},post_numerology_chart:{tag:"roxy-numerology-card",pascal:"RoxyNumerologyCard",operationId:"generateNumerologyChart",attrs:{type:"chart"}},get_numerology_compound_number:{tag:"roxy-compound-number",pascal:"RoxyCompoundNumber",operationId:"getCompoundNumber"},post_kabbalah_gematria:{tag:"roxy-gematria",pascal:"RoxyGematria",operationId:"calculateGematria"},post_tarot_daily:{tag:"roxy-tarot-card",pascal:"RoxyTarotCard",operationId:"getDailyCard"},get_tarot_cards_id:{tag:"roxy-tarot-card",pascal:"RoxyTarotCard",operationId:"getCard"},get_tarot_cards:{tag:"roxy-tarot-catalog",pascal:"RoxyTarotCatalog",operationId:"listCards"},post_tarot_spreads_three_card:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castThreeCard",attrs:{spread:"three-card"}},post_tarot_spreads_celtic_cross:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCelticCross",attrs:{spread:"celtic-cross"}},post_tarot_spreads_love:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castLoveSpread",attrs:{spread:"love"}},post_tarot_spreads_career:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCareerSpread",attrs:{spread:"career"}},post_tarot_spreads_custom:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castCustomSpread",attrs:{spread:"custom"}},post_tarot_yes_no:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"castYesNo",attrs:{spread:"yes-no"}},post_tarot_draw:{tag:"roxy-tarot-spread",pascal:"RoxyTarotSpread",operationId:"drawCards",attrs:{spread:"draw"}},post_human_design_bodygraph:{tag:"roxy-bodygraph",pascal:"RoxyBodygraph",operationId:"generateBodygraph"},post_human_design_type:{tag:"roxy-hd-type-card",pascal:"RoxyHdTypeCard",operationId:"calculateType"},post_human_design_profile:{tag:"roxy-hd-type-card",pascal:"RoxyHdTypeCard",operationId:"calculateProfile"},post_human_design_connection:{tag:"roxy-hd-connection",pascal:"RoxyHdConnection",operationId:"calculateConnection"},post_human_design_penta:{tag:"roxy-hd-penta",pascal:"RoxyHdPenta",operationId:"calculatePenta"},post_human_design_variables:{tag:"roxy-hd-variables",pascal:"RoxyHdVariables",operationId:"calculateVariables"},post_forecast_timeline:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"generateTimeline"},post_forecast_significant_dates:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"findSignificantDates"},post_forecast_transits:{tag:"roxy-forecast-timeline",pascal:"RoxyForecastTimeline",operationId:"forecastTransits"},post_forecast_digest:{tag:"roxy-forecast-digest",pascal:"RoxyForecastDigest",operationId:"generateDigest"},post_chinese_astrology_bazi_chart:{tag:"roxy-bazi-chart",pascal:"RoxyBaziChart",operationId:"generateBaziChart"},post_chinese_astrology_bazi_luck_pillars:{tag:"roxy-luck-pillars",pascal:"RoxyLuckPillars",operationId:"calculateLuckPillars"},post_chinese_astrology_zodiac_sign:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"calculateZodiacAnimal",attrs:{mode:"sign"}},get_chinese_astrology_zodiac_animals_id:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getZodiacAnimal",attrs:{mode:"animal"}},get_chinese_astrology_zodiac_id_daily:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getDailyZodiacReading",attrs:{mode:"daily"}},get_chinese_astrology_zodiac_compatibility_sign1_sign2:{tag:"roxy-zodiac-card",pascal:"RoxyZodiacCard",operationId:"getZodiacCompatibility",attrs:{mode:"compatibility"}},get_chinese_astrology_calendar_day_date:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"getAlmanacDay",attrs:{mode:"day"}},get_chinese_astrology_calendar_monthly:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"getMonthlyAlmanac",attrs:{mode:"month"}},post_chinese_astrology_calendar_auspicious_days:{tag:"roxy-almanac-day",pascal:"RoxyAlmanacDay",operationId:"lookupAuspiciousDays",attrs:{mode:"auspicious"}},post_feng_shui_flying_stars_natal:{tag:"roxy-flying-star-chart",pascal:"RoxyFlyingStarChart",operationId:"generateFlyingStarChart",attrs:{mode:"natal"}},get_feng_shui_flying_stars_annual_year:{tag:"roxy-flying-star-chart",pascal:"RoxyFlyingStarChart",operationId:"getAnnualFlyingStars",attrs:{mode:"annual"}},post_feng_shui_kua:{tag:"roxy-kua-card",pascal:"RoxyKuaCard",operationId:"calculateKuaNumber",attrs:{mode:"kua"}},post_feng_shui_eight_mansions:{tag:"roxy-kua-card",pascal:"RoxyKuaCard",operationId:"generateEightMansions",attrs:{mode:"mansions"}},post_mesoamerican_astrology_mayan_tzolkin:{tag:"roxy-mayan-day-sign",pascal:"RoxyMayanDaySign",operationId:"calculateTzolkin",attrs:{mode:"day"}},post_mesoamerican_astrology_mayan_chart:{tag:"roxy-mayan-day-sign",pascal:"RoxyMayanDaySign",operationId:"generateMayanChart",attrs:{mode:"chart"}},post_vastu_mandala:{tag:"roxy-vastu-mandala",pascal:"RoxyVastuMandala",operationId:"generateMandala",attrs:{mode:"mandala"}},post_vastu_entrance:{tag:"roxy-vastu-mandala",pascal:"RoxyVastuMandala",operationId:"calculateEntrancePada",attrs:{mode:"entrance"}},post_biorhythm_daily:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getDailyBiorhythm",attrs:{mode:"daily"}},post_biorhythm_forecast:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getForecast",attrs:{mode:"forecast"}},post_biorhythm_critical_days:{tag:"roxy-biorhythm-chart",pascal:"RoxyBiorhythmChart",operationId:"getCriticalDays",attrs:{mode:"critical-days"}},post_ayurveda_constitution:{tag:"roxy-dosha-constitution",pascal:"RoxyDoshaConstitution",operationId:"calculateAyurvedicConstitution"},get_iching_hexagrams_random:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getRandomHexagram"},get_iching_hexagrams_number:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getHexagram"},get_iching_hexagrams_lookup:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"lookupHexagram"},get_iching_cast:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"castReading"},post_iching_daily:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"getDailyHexagram"},post_iching_daily_cast:{tag:"roxy-hexagram",pascal:"RoxyHexagram",operationId:"castDailyReading"},get_crystals_id:{tag:"roxy-crystal-card",pascal:"RoxyCrystalCard",operationId:"getCrystal"},get_crystals:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"listCrystals"},get_crystals_chakra:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByChakra"},get_crystals_element:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByElement"},get_crystals_zodiac_sign:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getCrystalsByZodiac"},get_crystals_birthstone_month:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"getBirthstones"},get_crystals_search:{tag:"roxy-crystal-grid",pascal:"RoxyCrystalGrid",operationId:"searchCrystals"},get_dreams_symbols_id:{tag:"roxy-dream-card",pascal:"RoxyDreamCard",operationId:"getDreamSymbol"},get_dreams_symbols:{tag:"roxy-dream-search",pascal:"RoxyDreamSearch",operationId:"searchDreamSymbols"},get_angel_numbers_number:{tag:"roxy-angel-number-card",pascal:"RoxyAngelNumberCard",operationId:"getAngelNumber"},post_angel_numbers_daily:{tag:"roxy-angel-number-card",pascal:"RoxyAngelNumberCard",operationId:"getDailyAngelNumber"},get_angel_numbers_lookup:{tag:"roxy-angel-number-lookup",pascal:"RoxyAngelNumberLookup",operationId:"analyzeNumberSequence"},post_reports_natal:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateNatalReport",attrs:{report:"natal"}},post_reports_synastry:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateSynastryReport",attrs:{report:"synastry"}},post_reports_kundli:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateKundliReport",attrs:{report:"kundli"}},post_reports_matchmaking:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateMatchmakingReport",attrs:{report:"matchmaking"}},post_reports_yearly_forecast:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateYearlyForecastReport",attrs:{report:"yearly-forecast"}},post_reports_human_design:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateHumanDesignReport",attrs:{report:"human-design"}},post_reports_bazi:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateBaziReport",attrs:{report:"bazi"}},post_reports_numerology:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateNumerologyReport",attrs:{report:"numerology"}},post_reports_tarot:{tag:"roxy-report",pascal:"RoxyReport",operationId:"generateTarotReport",attrs:{report:"tarot"}},get_astrology_signs_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getZodiacSign"},get_astrology_planet_meanings_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getPlanetMeaning"},get_vedic_astrology_rashis_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getRashi"},get_iching_trigrams_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getTrigram"},get_human_design_gates_number:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getGate"},get_human_design_centers_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getCenter"},get_numerology_meanings_number:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getNumberMeaning"},get_vedic_astrology_avasthas_id:{tag:"roxy-reference-card",pascal:"RoxyReferenceCard",operationId:"getAvastha"}};function tl(s){let a=s.lastIndexOf(":"),e=a===-1?s:s.slice(a+1),t=fm[e];return t?{...t,toolName:e}:void 0}var _i=[{pascal:"RoxyNatalChart",tag:"roxy-natal-chart",slug:"natal-chart",heading:"Natal chart",description:"Western natal chart wheel for /astrology/natal-chart responses",docsLabel:"Western",endpointLabel:"POST /astrology/natal-chart",docsSummary:"Natal chart wheel with planet glyphs and aspect lines",topic:"Astrology"},{pascal:"RoxySynastryChart",tag:"roxy-synastry-chart",slug:"synastry-chart",heading:"Synastry",description:"Dual-wheel synastry chart with inter-aspects table",docsLabel:"Western",endpointLabel:"POST /astrology/synastry",docsSummary:"Dual-wheel synastry with inter-aspects table",topic:"Astrology"},{pascal:"RoxyWesternPlanetsTable",tag:"roxy-western-planets-table",slug:"western-planets-table",heading:"Western planets",description:"Western planetary positions table with sign, degree, house, and motion plus the chart angles",docsLabel:"Western",endpointLabel:"POST /astrology/natal-chart",docsSummary:"Sign, degree, house, motion columns plus ASC, MC, PoF, Vertex",topic:"Astrology"},{pascal:"RoxyTransitsTable",tag:"roxy-transits-table",slug:"transits-table",heading:"Transits",description:"Live planet positions plus aspects to a natal chart",docsLabel:"Western",endpointLabel:"POST /astrology/transits",docsSummary:"Transit planet positions plus optional aspects to a natal chart",topic:"Astrology"},{pascal:"RoxyTransitWheel",tag:"roxy-transit-wheel",slug:"transit-wheel",heading:"Transit bi-wheel",description:"Natal and transit bi-wheel with an aspect line for every transit to the natal chart",docsLabel:"Western",endpointLabel:"POST /astrology/transit-aspects",docsSummary:"Natal chart on the inner ring, transiting bodies on the outer ring, aspect lines between them",topic:"Astrology"},{pascal:"RoxyAspectsTable",tag:"roxy-aspects-table",slug:"aspects-table",heading:"Aspects",description:"Natal and transit aspect grid with chart-pattern detection (grand trines, t-squares, stelliums, yods)",docsLabel:"Western",endpointLabel:"POST /astrology/aspects, /astrology/transit-aspects, /astrology/aspect-patterns",docsSummary:"Aspect rows coloured by nature with orb and strength, plus detected chart patterns",topic:"Astrology"},{pascal:"RoxyMoonPhase",tag:"roxy-moon-phase",slug:"moon-phase",heading:"Moon phase",description:"Moon phase card and calendar",docsLabel:"Western",endpointLabel:"GET /astrology/moon-phase/{current,upcoming,calendar/...}",docsSummary:"Moon phase card and calendar",topic:"Astrology"},{pascal:"RoxyHoroscopeCard",tag:"roxy-horoscope-card",slug:"horoscope-card",heading:"Horoscope",description:"Daily, weekly, monthly, or yearly horoscope card for /astrology/horoscope/..., with the column, the dated sky events behind it, and the yearly themes, key periods, eclipses, retrogrades and best months",docsLabel:"Western",endpointLabel:"GET /astrology/horoscope/{sign}/{daily,weekly,monthly,yearly}",docsSummary:"Daily, weekly, monthly, or yearly horoscope card",topic:"Astrology"},{pascal:"RoxyAstrocartographyMap",tag:"roxy-astrocartography-map",slug:"astrocartography-map",heading:"Astrocartography",description:"Astrocartography world map plotting each body Midheaven, IC, Ascendant, and Descendant relocation lines",docsLabel:"Western",endpointLabel:"POST /astrology/astrocartography",docsSummary:"World map of planetary MC, IC, Ascendant, and Descendant lines with per-line interpretations",topic:"Astrology"},{pascal:"RoxyLocalSpaceCompass",tag:"roxy-local-space-compass",slug:"local-space-compass",heading:"Local space",description:"Local space compass plotting each body direction from the birthplace by azimuth and altitude",docsLabel:"Western",endpointLabel:"POST /astrology/local-space",docsSummary:"Compass dial of planetary azimuth lines from the birthplace, dimmed below the horizon",topic:"Astrology"},{pascal:"RoxyRelocationWheel",tag:"roxy-relocation-wheel",slug:"relocation-wheel",heading:"Relocation chart",description:"Relocation chart wheel recomputing houses and angles for a new place, with the planets that change house",docsLabel:"Western",endpointLabel:"POST /astrology/relocation-chart",docsSummary:"Relocated chart wheel plus the move geometry, angular planets, and planets that change house",topic:"Astrology"},{pascal:"RoxyPositionsTable",tag:"roxy-positions-table",slug:"positions-table",heading:"Positions table",description:"Editorial positions table for asteroids, Black Moon Lilith, secondary progressions, solar arc directions, and the Arabic lots",docsLabel:"Western",endpointLabel:"POST /astrology/asteroids, /astrology/lilith, /astrology/progressions, /astrology/solar-arc, /astrology/arabic-lots",docsSummary:"Body, sign, degree, and per-shape columns (house, motion, formula, or natal arc) plus each reading",topic:"Astrology"},{pascal:"RoxyEphemerisTable",tag:"roxy-ephemeris-table",slug:"ephemeris-table",heading:"Ephemeris",description:"Monthly ephemeris: every body day by day, with each sign change and retrograde stretch called out",docsLabel:"Cross",endpointLabel:"POST /astrology/planets/monthly, /vedic-astrology/planetary-positions/monthly",docsSummary:"Per-body sign changes and retrograde windows for the month, over the full daily position grid",topic:"Astrology"},{pascal:"RoxyFixedStars",tag:"roxy-fixed-stars",slug:"fixed-stars",heading:"Fixed stars",description:"Fixed star conjunctions to the natal chart, tightest first, with the precessed star catalog",docsLabel:"Western",endpointLabel:"POST /astrology/fixed-stars",docsSummary:"Star to natal point conjunctions with readings, plus a catalog of position, magnitude, nature, and keywords",topic:"Astrology"},{pascal:"RoxyProfectionCard",tag:"roxy-profection-card",slug:"profection-card",heading:"Annual profection",description:"Annual profection card with the profected house and sign, the lord of the year, and its natal placement",docsLabel:"Western",endpointLabel:"POST /astrology/profections",docsSummary:"Profected house and sign for the year, the lord of the year, its natal placement, and the reading",topic:"Astrology"},{pascal:"RoxyCompatibilityCard",tag:"roxy-compatibility-card",slug:"compatibility-card",heading:"Compatibility score",description:"Cross-domain compatibility score card",docsLabel:"Cross",endpointLabel:"POST /astrology/compatibility-score, /numerology/compatibility, /biorhythm/compatibility",docsSummary:"Score card with category breakdown",topic:"Astrology"},{pascal:"RoxyVedicKundli",tag:"roxy-vedic-kundli",slug:"vedic-kundli",heading:"Vedic kundli",description:"South, North, or East Indian Vedic kundli for /vedic-astrology/birth-chart with per-planet degree and nakshatra detail, plus an optional Chandra Lagna (Moon-as-ascendant) reference view",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/birth-chart",docsSummary:"South, North, or East Indian kundli with degree detail and optional Chandra Lagna view",topic:"Vedic"},{pascal:"RoxyDivisionalChart",tag:"roxy-divisional-chart",slug:"divisional-chart",heading:"Divisional chart",description:"D2 to D60 varga chart wheel with Vargottama markers",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/{divisional-chart,navamsa}",docsSummary:"Generic divisional varga wheel from D2 Hora to D60 Shashtiamsa",topic:"Vedic"},{pascal:"RoxyKpChart",tag:"roxy-kp-chart",slug:"kp-chart",heading:"KP chart",description:"Full KP chart with Ascendant, Placidus cusps, and planets and nodes in tabbed stellar-hierarchy tables",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/chart",docsSummary:"Ascendant, cusps, planets and nodes with KP stellar hierarchy and house meanings",topic:"Vedic"},{pascal:"RoxyVedicPlanetsTable",tag:"roxy-vedic-planets-table",slug:"vedic-planets-table",heading:"Vedic planets",description:"Vedic planetary positions table with degree, nakshatra, pada, nakshatra lord, bhava, and all three avastha systems",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/birth-chart",docsSummary:"Degree, nakshatra, pada, lord, bhava, Baladi, Jagradadi and Deeptadi columns",topic:"Vedic"},{pascal:"RoxyKpPlanetsTable",tag:"roxy-kp-planets-table",slug:"kp-planets-table",heading:"KP planets",description:"KP planets table with sub-lord and sub-sub-lord columns",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/planets",docsSummary:"Sub-lord and sub-sub-lord columns",topic:"Vedic"},{pascal:"RoxyKpRulingPlanets",tag:"roxy-kp-ruling-planets",slug:"kp-ruling-planets",heading:"KP ruling planets",description:"KP ruling planets with day lord, Moon and Lagna stellar hierarchies, and house significators",docsLabel:"Vedic (KP)",endpointLabel:"POST /vedic-astrology/kp/ruling-planets",docsSummary:"Day lord, Moon/Lagna hierarchies, ruling planets, significators with house meanings",topic:"Vedic"},{pascal:"RoxyAshtakavargaGrid",tag:"roxy-ashtakavarga-grid",slug:"ashtakavarga-grid",heading:"Ashtakavarga",description:"Sarva and Bhinna ashtakavarga heatmap with bindu scores",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/ashtakavarga",docsSummary:"Sarva, Bhinna, and Shodhya Pinda views in a tabbed heatmap",topic:"Vedic"},{pascal:"RoxyShadbalaTable",tag:"roxy-shadbala-table",slug:"shadbala-table",heading:"Shadbala",description:"Six-fold planetary strength with adequacy badge per planet",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/shadbala",docsSummary:"Six-fold planetary strength bar plus rupas and adequacy badge",topic:"Vedic"},{pascal:"RoxyDashaTimeline",tag:"roxy-dasha-timeline",slug:"dasha-timeline",heading:"Vimshottari dasha",description:"Vimshottari dasha timeline, mahadasha through prana, with the active period highlighted",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/dasha/{current,major,sub/...}",docsSummary:"Vimshottari mahadasha, antardasha, pratyantardasha, sookshma and prana, drill-down at every level",topic:"Vedic"},{pascal:"RoxyGunaMilan",tag:"roxy-guna-milan",slug:"guna-milan",heading:"Guna milan",description:"36-point Ashtakoota matrimonial compatibility breakdown",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/compatibility",docsSummary:"36-point Ashtakoota with eight sub-scores",topic:"Vedic"},{pascal:"RoxyPanchangTable",tag:"roxy-panchang-table",slug:"panchang-table",heading:"Panchang",description:"Panchang muhurta table with auspicious and inauspicious periods",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/{basic,detailed}",docsSummary:"15+ muhurtas in detailed mode",topic:"Vedic"},{pascal:"RoxyVedicAspects",tag:"roxy-vedic-aspects",slug:"vedic-aspects",heading:"Vedic aspects",description:"Vedic graha drishti table: which planet aspects which, with mutual aspects surfaced first",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/aspects",docsSummary:"Graha drishti rows with aspect type, strength, and orb, plus mutual aspects",topic:"Vedic"},{pascal:"RoxyHoraTable",tag:"roxy-hora-table",slug:"hora-table",heading:"Hora",description:"Vedic Hora (planetary hours) table: 12 day and 12 night horas by ruling planet for electional timing",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/hora",docsSummary:"Day and night planetary hours with ruling planet and window",topic:"Vedic"},{pascal:"RoxyChoghadiyaGrid",tag:"roxy-choghadiya-grid",slug:"choghadiya-grid",heading:"Choghadiya",description:"Day and night Choghadiya muhurta tiles for activity timing",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/panchang/choghadiya",docsSummary:"Day and night Choghadiya muhurta tiles colored by effect",topic:"Vedic"},{pascal:"RoxyHeliacalTable",tag:"roxy-heliacal-table",slug:"heliacal-table",heading:"Heliacal rising and setting",description:"Whether each graha stands far enough from the Sun to be seen, with the date it next rises or sets",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/heliacal",docsSummary:"Udaya and asta windows for the six visible grahas, the calculation behind Guru Asta and Shukra Asta",topic:"Vedic"},{pascal:"RoxyVedicDaily",tag:"roxy-vedic-daily",slug:"vedic-daily",heading:"Vedic daily",description:"One native, one day: the verdict band, every graha state behind it, the Moon windows and the finance area",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/daily",docsSummary:"Composed Vedic daily reading with the classical rule behind every graha state, the Tara and Chandrabala windows in full, and all three sidereal frames named",topic:"Vedic"},{pascal:"RoxyKpFinanceCard",tag:"roxy-kp-finance-card",slug:"kp-finance-card",heading:"KP daily finance",description:"One native, one day scored for money: the band, the gain and loss significators, and the four sub lord layers behind the score",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/kp/daily-finance",docsSummary:"KP daily finance reading with the cusp sub lords, the running dasha lords, the ruling planets and the Moon sub lord windows each scored against the gain and loss houses, weighed into one band for the day",topic:"Vedic"},{pascal:"RoxyGocharaTable",tag:"roxy-gochara-table",slug:"gochara-table",heading:"Gochara transits",description:"Where each graha transits now, the natal house it falls in, and the Ashtakavarga-qualified kaksha verdict",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/transit",docsSummary:"Vedic gochara with aspects to the natal chart and the Gochara Kaksha reading drawn as a position within the sign",topic:"Vedic"},{pascal:"RoxyBhavaBalaTable",tag:"roxy-bhava-bala-table",slug:"bhava-bala-table",heading:"Bhava Bala",description:"The twelve houses ranked by strength, with the three classical components that make up each total",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/bhava-bala",docsSummary:"House strength in rupas and virupas, ranked, with Bhavadhipati, Dig and Drishti Bala shown as proportions of the total",topic:"Vedic"},{pascal:"RoxyBhavChalitTable",tag:"roxy-bhav-chalit-table",slug:"bhav-chalit-table",heading:"Bhav Chalit",description:"Which grahas change house once the bhavas are cut at their real cusps instead of at sign boundaries",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/bhav-chalit",docsSummary:"The Chalit chart against the Rashi chart, leading with how many grahas move and which, plus the unequal bhava spans",topic:"Vedic"},{pascal:"RoxyUpagrahaTable",tag:"roxy-upagraha-table",slug:"upagraha-table",heading:"Upagrahas",description:"The eleven upagrahas in their time-based and Sun-based groups, with rashi, degree, and nakshatra",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/upagraha",docsSummary:"Time-based and Sun-based upagrahas with rashi, degree, longitude and nakshatra",topic:"Vedic"},{pascal:"RoxyCharaKarakas",tag:"roxy-chara-karakas",slug:"chara-karakas",heading:"Chara karakas",description:"Jaimini chara karakas ranked Atmakaraka first, with the scheme that produced the ranking",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/chara-karakas",docsSummary:"Karaka offices in rank order with graha, degree, scheme, and what each is read for",topic:"Vedic"},{pascal:"RoxyArudhaPadas",tag:"roxy-arudha-padas",slug:"arudha-padas",heading:"Arudha padas",description:"The twelve Jaimini arudha padas with their derivation, the Arudha Lagna and the Upapada marked",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/arudha",docsSummary:"Twelve padas with bhava, lord, pada rashi, house from Lagna, and the classical exception marked",topic:"Vedic"},{pascal:"RoxyYogaList",tag:"roxy-yoga-list",slug:"yoga-list",heading:"Yoga catalog",description:"Yoga reference cards from the catalog with optional detail mode",docsLabel:"Vedic",endpointLabel:"GET /vedic-astrology/yoga, /vedic-astrology/yoga/{id}, POST /vedic-astrology/yoga/detect",docsSummary:"Filterable yoga cards from the 300 plus yoga catalog, grouped by verdict in detect mode",topic:"Vedic"},{pascal:"RoxyNakshatraCard",tag:"roxy-nakshatra-card",slug:"nakshatra-card",heading:"Nakshatra",description:"Nakshatra reference card with lord, deity, symbol, characteristics, and remedies",docsLabel:"Vedic",endpointLabel:"GET /vedic-astrology/nakshatras/{id}",docsSummary:"Lord, deity, symbol, characteristics, remedies",topic:"Vedic"},{pascal:"RoxyDoshaCard",tag:"roxy-dosha-card",slug:"dosha-card",heading:"Manglik dosha",description:"Manglik, Kaal Sarp, or Sade Sati presence card",docsLabel:"Vedic",endpointLabel:"POST /vedic-astrology/dosha/{manglik,kalsarpa,sadhesati}",docsSummary:"Presence, severity, remedies, scoped effects",topic:"Vedic"},{pascal:"RoxyNumerologyCard",tag:"roxy-numerology-card",slug:"numerology-card",heading:"Life path number",description:"Numerology card for life path, expression, soul urge, personality, personal year, or full chart",docsLabel:"Numerology",endpointLabel:"POST /numerology/{life-path,expression,soul-urge,personality,birth-day,maturity,daily,personal-day,personal-month,personal-year,chart}",docsSummary:"Life path, expression, soul urge, personality, personal year, full chart",topic:"Numerology"},{pascal:"RoxyCompoundNumber",tag:"roxy-compound-number",slug:"compound-number",heading:"Compound number",description:"Chaldean compound number card with the numeral, its symbolic name, root number, fortunate or unfortunate nature, the lower number it repeats, and the meaning",docsLabel:"Numerology",endpointLabel:"GET /numerology/compound-number/{number}",docsSummary:"Compound 10 to 52 with name, root, nature and meaning",topic:"Numerology"},{pascal:"RoxyGematria",tag:"roxy-gematria",slug:"gematria",heading:"Gematria",description:"Gematria calculator that shows its work: every Hebrew spelling the input can take, the value under each cipher with the ones that are not single valued, the per letter breakdown right to left, the two substitution ciphers, the Latin alphabet ciphers and the curated words of equal value",docsLabel:"Kabbalah",endpointLabel:"POST /kabbalah/gematria",docsSummary:"Values by cipher, every candidate Hebrew spelling with its per letter breakdown, and equal-value words",topic:"Kabbalah"},{pascal:"RoxyTarotCard",tag:"roxy-tarot-card",slug:"tarot-card",heading:"Daily tarot card",description:"Single tarot card with upright/reversed flip animation",docsLabel:"Tarot",endpointLabel:"GET /tarot/cards/{id}, POST /tarot/daily",docsSummary:"Single card with upright and reversed flip",topic:"Tarot"},{pascal:"RoxyTarotCatalog",tag:"roxy-tarot-catalog",slug:"tarot-catalog",heading:"Tarot deck",description:"Responsive tarot deck gallery with card art, name, and an arcana and suit caption; a picked tile opens its tarot card in place, and emits roxy-symbol-select for a host that pairs its own",docsLabel:"Tarot",endpointLabel:"GET /tarot/cards",docsSummary:"Deck gallery tiles with card art, name, and arcana and suit; a pick opens the card in place",topic:"Tarot"},{pascal:"RoxyTarotSpread",tag:"roxy-tarot-spread",slug:"tarot-spread",heading:"Three-card spread",description:"Tarot spread renderer for three-card, Celtic Cross, love, or yes/no",docsLabel:"Tarot",endpointLabel:"POST /tarot/spreads/{three-card,celtic-cross,love,career,custom}, /tarot/yes-no, /tarot/draw",docsSummary:"Spreads with positions and reading",topic:"Tarot"},{pascal:"RoxyBodygraph",tag:"roxy-bodygraph",slug:"bodygraph",heading:"Bodygraph",description:"Human Design bodygraph with nine centers, channels, and activated gates, plus the full reading: type, strategy, authority, profile, definition, incarnation cross, and a gate and line meaning for every activation",docsLabel:"Human Design",endpointLabel:"POST /human-design/bodygraph",docsSummary:"Nine-center chart with defined and open centers, active channels, and gates, plus the type, strategy, authority, profile, and definition readings, the channels by circuit, the centers, and every activation with its gate and line meaning",topic:"Human Design"},{pascal:"RoxyHdTypeCard",tag:"roxy-hd-type-card",slug:"hd-type-card",heading:"HD type",description:"Human Design type reading without the chart: type, strategy, authority, and profile, with the aura mechanic, the signature and not-self themes, and the interpretation behind each label. Also renders the profile response with its two line keynotes",docsLabel:"Human Design",endpointLabel:"POST /human-design/type, /human-design/profile",docsSummary:"Type, strategy, authority, and profile tiles with the aura, signature, and not-self themes, plus the reading behind each label and the profile line keynotes",topic:"Human Design"},{pascal:"RoxyHdConnection",tag:"roxy-hd-connection",slug:"hd-connection",heading:"HD connection",description:"Human Design connection chart: the composite channels two people form, with circuit, dynamic, and which person holds each gate",docsLabel:"Human Design",endpointLabel:"POST /human-design/connection",docsSummary:"Electromagnetic, compromise, and dominance channels between two charts",topic:"Human Design"},{pascal:"RoxyHdPenta",tag:"roxy-hd-penta",slug:"hd-penta",heading:"HD penta",description:"Human Design penta for a 3 to 5 person group: upper and lower triangle channels, defined or open, with core channels and member coverage",docsLabel:"Human Design",endpointLabel:"POST /human-design/penta",docsSummary:"Group penta channels split into upper and lower triangles",topic:"Human Design"},{pascal:"RoxyHdVariables",tag:"roxy-hd-variables",slug:"hd-variables",heading:"HD variables",description:"Human Design variables: the four PHS arrows (determination, environment, perspective, motivation) with left/right direction, color, tone, and base, plus the reading for each arrow and the cognition",docsLabel:"Human Design",endpointLabel:"POST /human-design/variables",docsSummary:"The four transformation arrows with direction, color, tone, and base, plus a reading per arrow grouped by layer and the cognition",topic:"Human Design"},{pascal:"RoxyForecastTimeline",tag:"roxy-forecast-timeline",slug:"forecast-timeline",heading:"Forecast timeline",description:"Cross-domain forecast event strip colored by domain and weighted by significance",docsLabel:"Forecast",endpointLabel:"POST /forecast/{timeline,significant-dates,transits}",docsSummary:"Date-grouped events across Western, Vedic, and biorhythm domains, weighted by significance",topic:"Forecast"},{pascal:"RoxyForecastDigest",tag:"roxy-forecast-digest",slug:"forecast-digest",heading:"Forecast digest",description:"Rolled-up forecast across the next 24 hours, 7, 30, and 90 days with per-domain breakdown and top events",docsLabel:"Forecast",endpointLabel:"POST /forecast/digest",docsSummary:"Per-window event counts, domain breakdown, and the highest-significance events",topic:"Forecast"},{pascal:"RoxyBaziChart",tag:"roxy-bazi-chart",slug:"bazi-chart",heading:"Four pillars",description:"BaZi four pillars chart: stem over branch per pillar with the Ten God relation, the stems each branch stores, the Na Yin, the Day Master, the five-element balance and every interaction the pillars form",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/bazi/chart",docsSummary:"Year, month, day and hour pillars in hanzi with hidden stems, Ten Gods, Na Yin, element balance and interactions",topic:"Chinese Astrology"},{pascal:"RoxyLuckPillars",tag:"roxy-luck-pillars",slug:"luck-pillars",heading:"Luck pillars",description:"BaZi luck pillars: the ten-year stretches a chart is read through, each with its stem, branch and Ten God, plus the annual pillars inside them and the direction and starting age the sequence was built from",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/bazi/luck-pillars",docsSummary:"Ten-year luck pillars as a strip with ages and years, the annual pillars, and the direction and start age behind them",topic:"Chinese Astrology"},{pascal:"RoxyZodiacCard",tag:"roxy-zodiac-card",slug:"zodiac-card",heading:"Chinese zodiac",description:"Chinese zodiac card: the animal a date falls in, the reference read of one animal with its trine and partner animals, a daily reading, or the compatibility of a pair",docsLabel:"Chinese",endpointLabel:"POST /chinese-astrology/zodiac/sign, GET /chinese-astrology/zodiac/{animals/{id},{id}/daily,compatibility/{sign1}/{sign2}}",docsSummary:"The animal for a date, one animal in full, a daily reading, or a pair scored",topic:"Chinese Astrology"},{pascal:"RoxyAlmanacDay",tag:"roxy-almanac-day",slug:"almanac-day",heading:"Chinese almanac",description:"Chinese almanac (Tong Shu): the day officer, what the day favours and avoids, the animal it clashes with, its three pillars and lunar mansion, for one day, a whole month, or a search for a date to act on",docsLabel:"Chinese",endpointLabel:"GET /chinese-astrology/calendar/{day/{date},monthly}, POST /chinese-astrology/calendar/auspicious-days",docsSummary:"Day officer, favours and avoids, clash animal and pillars, as one day, a month, or a date search",topic:"Chinese Astrology"},{pascal:"RoxyFlyingStarChart",tag:"roxy-flying-star-chart",slug:"flying-star-chart",heading:"Flying star chart",description:"Xuan Kong flying star plate: nine palaces on the compass with the mountain, period and water star of each, the facing and sitting mountains, and the structure the pair produces",docsLabel:"Feng Shui",endpointLabel:"POST /feng-shui/flying-stars/natal, GET /feng-shui/flying-stars/annual/{year}",docsSummary:"Nine-palace flying star plate with the mountain, period and water star per palace, the facing and sitting mountains and the structure",topic:"Feng Shui"},{pascal:"RoxyKuaCard",tag:"roxy-kua-card",slug:"kua-card",heading:"Kua and eight mansions",description:"Kua number with its trigram and the Eight Mansions map: all eight compass sectors on the nine-palace grid, each with its star, nature, rank and life domain, and the best and worst of them named",docsLabel:"Feng Shui",endpointLabel:"POST /feng-shui/kua, POST /feng-shui/eight-mansions",docsSummary:"Kua number and trigram over the eight-sector direction map, favourable and unfavourable sectors ranked",topic:"Feng Shui"},{pascal:"RoxyMayanDaySign",tag:"roxy-mayan-day-sign",slug:"mayan-day-sign",heading:"Mayan day sign",description:"Tzolkin day sign in all three of its spellings with the coefficient beside it, the trecena it sits in, the keynote, strengths, challenges and guidance, and on the full chart the Haab date, the Long Count, the Calendar Round, the year bearer and the four-fold cross",docsLabel:"Mesoamerican",endpointLabel:"POST /mesoamerican-astrology/mayan/tzolkin, POST /mesoamerican-astrology/mayan/chart",docsSummary:"Day sign and coefficient with the trecena, the reading, and the Calendar Round on the fuller response",topic:"Mesoamerican"},{pascal:"RoxyVastuMandala",tag:"roxy-vastu-mandala",slug:"vastu-mandala",heading:"Vastu mandala",description:"Vastu Purusha Mandala projected over a plot: every pada with the devata holding it, the brahmasthan block, the vamsa diagonals and where they cross, and in the entrance read the square the main door falls on with the verse effect for that pada",docsLabel:"Vastu",endpointLabel:"POST /vastu/mandala, POST /vastu/entrance",docsSummary:"Pada grid with a devata per square, the brahmasthan, and the entrance pada lit with its effect",topic:"Vastu"},{pascal:"RoxyBiorhythmChart",tag:"roxy-biorhythm-chart",slug:"biorhythm-chart",heading:"Daily biorhythm",description:"Daily biorhythm bars or multi-day forecast cycle lines",docsLabel:"Biorhythm",endpointLabel:"POST /biorhythm/{daily,forecast,critical-days}",docsSummary:"Daily bars, forecast cycle lines, critical days",topic:"Biorhythm"},{pascal:"RoxyDoshaConstitution",tag:"roxy-dosha-constitution",slug:"dosha-constitution",heading:"Ayurvedic constitution",description:"Ayurvedic constitution read from a birth chart: the three humour shares as one bar, the dominant and secondary humour, the three cited factors behind the blend with their verses, the shadbala ranking the third factor reads, and the scope note the response carries",docsLabel:"Ayurveda",endpointLabel:"POST /ayurveda/constitution",docsSummary:"Vata, pitta and kapha shares as one bar with the dominant humour and the cited factors behind it",topic:"Ayurveda"},{pascal:"RoxyHexagram",tag:"roxy-hexagram",slug:"hexagram",heading:"I Ching hexagram",description:"I Ching hexagram drawn line by line with trigram glyphs, judgment, image, and a reading for every line: the oracle statement and what it asks of the querent. A cast highlights the moving lines and shows only their readings, plus the hexagram it transforms into",docsLabel:"I Ching",endpointLabel:"GET /iching/hexagrams/{number}, /iching/hexagrams/random, /iching/hexagrams/lookup, /iching/cast, POST /iching/daily, /iching/daily/cast",docsSummary:"Hexagram figure with trigrams, judgment, image, and a reading per line (statement plus meaning); a cast highlights the moving lines and the resulting hexagram",topic:"I Ching"},{pascal:"RoxyCrystalCard",tag:"roxy-crystal-card",slug:"crystal-card",heading:"Crystal detail",description:"Single-crystal detail card with photo, spiritual, emotional, and physical meaning, metaphysical attributes, affirmation, and pairings; as a widget the visitor types a crystal name and picks it",docsLabel:"Crystals",endpointLabel:"GET /crystals/{id}",docsSummary:"Photo, meaning sections, chakra, zodiac, element, hardness, keywords, and pairings",topic:"Crystals"},{pascal:"RoxyCrystalGrid",tag:"roxy-crystal-grid",slug:"crystal-grid",heading:"Crystal grid",description:"Responsive crystal gallery with photo, name, and colour swatches from any crystals list response, filterable by chakra, zodiac sign, element, colour, and planet; a picked tile opens its crystal card in place",docsLabel:"Crystals",endpointLabel:"GET /crystals, /crystals/chakra/{chakra}, /crystals/element/{element}, /crystals/zodiac/{sign}, /crystals/birthstone/{month}, /crystals/search",docsSummary:"Crystal gallery with chakra, zodiac, element, colour, and planet filters; a pick opens the card in place",topic:"Crystals"},{pascal:"RoxyDreamCard",tag:"roxy-dream-card",slug:"dream-card",heading:"Dream symbol",description:"Dream symbol card with the symbol name, full interpretation, and dictionary letter; as a widget the visitor types a symbol and picks it",docsLabel:"Dreams",endpointLabel:"GET /dreams/symbols/{id}",docsSummary:"Symbol name, interpretation body, and letter chip",topic:"Dreams"},{pascal:"RoxyDreamSearch",tag:"roxy-dream-search",slug:"dream-search",heading:"Dream search",description:"The dream dictionary as selectable tiles under a search box and an A to Z bar; a picked tile opens its dream card in place, and emits roxy-symbol-select for a host that pairs its own",docsLabel:"Dreams",endpointLabel:"GET /dreams/symbols",docsSummary:"The dream dictionary as tiles, browsed A to Z or searched; a pick opens the card in place",topic:"Dreams"},{pascal:"RoxyAngelNumberCard",tag:"roxy-angel-number-card",slug:"angel-number-card",heading:"Angel number",description:"Angel number card with title, core message, badges, keywords, life-area interpretations, affirmation, and action steps",docsLabel:"Angel Numbers",endpointLabel:"GET /angel-numbers/numbers/{number}, POST /angel-numbers/daily",docsSummary:"Number meaning with spiritual, love, career, money, twin flame, biblical, and shadow sections",topic:"Angel Numbers"},{pascal:"RoxyAngelNumberLookup",tag:"roxy-angel-number-lookup",slug:"angel-number-lookup",heading:"Angel number lookup",description:"Angel number sequence analysis with pattern classification, the known meaning when present, and a digit-root fallback for any number",docsLabel:"Angel Numbers",endpointLabel:"GET /angel-numbers/lookup",docsSummary:"Pattern analysis plus known meaning and digit-root fallback",topic:"Angel Numbers"},{pascal:"RoxyReport",tag:"roxy-report",slug:"report",heading:"Branded report",description:"Branded report for any /reports operation: the visitor fills the form, and the finished document arrives under your name as a PDF download or in place on the page",docsLabel:"Reports",endpointLabel:"POST /reports/...",docsSummary:"Form to finished branded report, as a PDF download or inline HTML",topic:"Reports"},{pascal:"RoxyReferenceCard",tag:"roxy-reference-card",slug:"reference-card",heading:"Reference card",description:"Glossary entry for any reference lookup: zodiac sign, planet meaning, rashi, I Ching trigram, Human Design gate or center, or numerology number",docsLabel:"Reference",endpointLabel:"GET /astrology/{signs,planet-meanings}/{id}, /vedic-astrology/{rashis,avasthas}/{id}, /iching/trigrams/{id}, /human-design/gates/{number}, /human-design/centers/{id}, /numerology/meanings/{number}",docsSummary:"Symbol, name, description, keyword chips, and an attribute grid for any glossary lookup",topic:"Helpers"},{pascal:"RoxyEndpointForm",tag:"roxy-endpoint-form",slug:"endpoint-form",heading:"Schema-driven form",description:"Schema-driven form that emits roxy-submit with a validated payload",docsLabel:"Helper",endpointLabel:"Any endpoint, from the spec",docsSummary:"Schema-driven form, emits roxy-submit",topic:"Helpers",selfFetching:true},{pascal:"RoxyLocationSearch",tag:"roxy-location-search",slug:"location-search",heading:"City search",description:"City search input with debounced /location/search calls",docsLabel:"Helper",endpointLabel:"GET /location/search",docsSummary:"Debounced city search input, emits roxy-location-select",topic:"Helpers",selfFetching:true},{pascal:"RoxyData",tag:"roxy-data",slug:"data",heading:"Generic renderer",description:"Generic fallback renderer for any OpenAPI response shape",docsLabel:"Helper",endpointLabel:"Any response shape",docsSummary:"Generic fallback renderer for unknown shapes",topic:"Helpers",selfFetching:true}];var sx=_i.map(s=>s.slug);
|