@roxyapi/ui 0.25.0 → 0.26.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 +9 -1
- package/components-catalog.json +125 -125
- package/dist/cdn/components/endpoint-form.js +1 -1
- package/dist/cdn/components/endpoint-form.js.map +1 -1
- package/dist/cdn/components/natal-chart.js.map +2 -2
- package/dist/cdn/components/relocation-wheel.js.map +2 -2
- package/dist/cdn/components/transit-wheel.js +12 -12
- package/dist/cdn/components/transit-wheel.js.map +3 -3
- package/dist/cdn/locales/de.js +1 -1
- package/dist/cdn/locales/de.js.map +2 -2
- package/dist/cdn/locales/es.js +1 -1
- package/dist/cdn/locales/es.js.map +2 -2
- package/dist/cdn/locales/fr.js +1 -1
- package/dist/cdn/locales/fr.js.map +2 -2
- package/dist/cdn/locales/hi.js +1 -1
- package/dist/cdn/locales/hi.js.map +2 -2
- package/dist/cdn/locales/pt.js +1 -1
- package/dist/cdn/locales/pt.js.map +2 -2
- package/dist/cdn/locales/ru.js +1 -1
- package/dist/cdn/locales/ru.js.map +2 -2
- package/dist/cdn/locales/tr.js +1 -1
- package/dist/cdn/locales/tr.js.map +2 -2
- package/dist/cdn/roxy-ui.js +17 -17
- package/dist/cdn/roxy-ui.js.map +3 -3
- package/dist/components/endpoint-form.js +1 -1
- package/dist/components/endpoint-form.js.map +1 -1
- package/dist/components/natal-chart.d.ts +4 -0
- package/dist/components/natal-chart.d.ts.map +1 -1
- package/dist/components/natal-chart.js.map +2 -2
- package/dist/components/relocation-wheel.js.map +2 -2
- package/dist/components/transit-wheel.d.ts +79 -37
- package/dist/components/transit-wheel.d.ts.map +1 -1
- package/dist/components/transit-wheel.js +11 -11
- package/dist/components/transit-wheel.js.map +3 -3
- package/dist/i18n/chrome-strings.d.ts +1 -1
- package/dist/i18n/chrome-strings.d.ts.map +1 -1
- package/dist/index.cjs +5 -5
- package/dist/index.cjs.map +3 -3
- package/dist/index.js +5 -5
- package/dist/index.js.map +3 -3
- package/dist/locales/de.d.ts.map +1 -1
- package/dist/locales/de.js +1 -1
- package/dist/locales/de.js.map +2 -2
- package/dist/locales/es.d.ts.map +1 -1
- package/dist/locales/es.js +1 -1
- package/dist/locales/es.js.map +2 -2
- package/dist/locales/fr.d.ts.map +1 -1
- package/dist/locales/fr.js +1 -1
- package/dist/locales/fr.js.map +2 -2
- package/dist/locales/hi.d.ts.map +1 -1
- package/dist/locales/hi.js +1 -1
- package/dist/locales/hi.js.map +2 -2
- package/dist/locales/pt.d.ts.map +1 -1
- package/dist/locales/pt.js +1 -1
- package/dist/locales/pt.js.map +2 -2
- package/dist/locales/ru.d.ts.map +1 -1
- package/dist/locales/ru.js +1 -1
- package/dist/locales/ru.js.map +2 -2
- package/dist/locales/tr.d.ts.map +1 -1
- package/dist/locales/tr.js +1 -1
- package/dist/locales/tr.js.map +2 -2
- package/dist/types/types.gen.d.ts +46 -0
- package/dist/types/types.gen.d.ts.map +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/components/natal-chart.ts +11 -1
- package/src/components/transit-wheel.ts +115 -49
- package/src/i18n/chrome-strings.ts +1 -0
- package/src/locales/de.ts +1 -0
- package/src/locales/es.ts +2 -0
- package/src/locales/fr.ts +1 -0
- package/src/locales/hi.ts +1 -0
- package/src/locales/pt.ts +1 -0
- package/src/locales/ru.ts +1 -0
- package/src/locales/tr.ts +1 -0
- package/src/types/types.gen.ts +46 -0
- package/src/version.ts +1 -1
package/dist/index.cjs
CHANGED
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
`}function Ml(n){let t=n.lagnaSign.toLowerCase();return Y.svg`
|
|
80
80
|
${zl(n.divisionLabel)}
|
|
81
81
|
${xe.map(e=>El(e,n.placements[e.toLowerCase()]??[],e.toLowerCase()===t,po(e,n.lagnaSign)))}
|
|
82
|
-
`}function _a(n,t){switch(t){case"north":return Al(n);case"east":return Ml(n);default:return wl(n)}}function Ka(n,t){return _e({items:yl,active:n,onSelect:t,label:"Kundli style",idPrefix:"kundli",controls:!0})}var mo=require("lit"),qa=mo.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);display:grid}.header{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.line{fill:#0000;stroke:var(--roxy-border,#d4d4d8)}.sign-text{fill:var(--roxy-muted,#71717a);font-size:11px;font-weight:500;font-family:var(--roxy-font-sans);text-transform:uppercase;letter-spacing:.04em}.rashi-num{fill:var(--roxy-muted,#71717a);font-size:12px;font-weight:500;font-family:var(--roxy-font-sans)}.house-num{fill:var(--roxy-accent-ink,#b45309);font-size:11px;font-weight:600;font-family:var(--roxy-font-sans);opacity:.85}.planet-text{fill:var(--roxy-fg,#0a0a0a);font-size:13px;font-weight:600;font-family:var(--roxy-font-sans)}.centre-label{fill:var(--roxy-muted,#71717a);font-size:14px;font-weight:600;font-family:var(--roxy-font-sans);letter-spacing:.02em}.lagna-marker{fill:var(--roxy-accent-ink,#b45309);font-size:10px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.08em;text-transform:uppercase}.lagna-bg{fill:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent)}.lagna-slash{stroke:var(--roxy-accent,#f59e0b);stroke-linecap:round;opacity:.7}`;var Or=class extends g{constructor(){super(...arguments);this.chartStyle="north";this.setStyle=e=>{this.chartStyle=e}}viewModel(){if(!this.data?.chart?.meta)return null;let{division:e}=this.data,r=`D${e.number} ${e.name}`;return Fa(this.data.chart.meta,r)}renderEmpty(){return sr.html`<div class="roxy-empty" role="status">No divisional chart data</div>`}renderData(e){let r=this.viewModel();if(!r)return this.renderEmpty();let{division:a,vargottama:s}=e;return sr.html`<div class="wrap"><div class="header"><div><h2 class="title">D${a.number} ${a.name} ${$s(a.name,a.sanskritName)?sr.html`<span class="division-meta">· ${a.sanskritName}</span>`:sr.nothing}</h2>${a.significance?sr.html`<p class="significance">${a.significance}</p>`:sr.nothing} ${ce(e.frame)}</div>${Ka(this.chartStyle,this.setStyle)}</div><div id="kundli-panel-${this.chartStyle}" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}"><svg viewBox="0 0 400 400" preserveAspectRatio="xMidYMid meet" role="img" aria-label="D${a.number} ${a.name} divisional chart with twelve sign houses"><title>D${a.number} ${a.name}</title>${_a(r,this.chartStyle)}</svg></div>${s&&s.length>0?sr.html`<div class="vargottama-row" role="list" aria-label="Vargottama planets"><span class="vargottama-label">Vargottama:</span> ${s.map(o=>sr.html`<span class="vargottama-pill" role="listitem">${k(o)??""} ${o}</span>`)}</div>`:sr.nothing}</div>`}};Or.styles=[y,de,qa,Ee,sr.css`.division-meta{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);margin:0}.significance{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);border-left:2px solid var(--roxy-border,#e4e4e7);padding-left:var(--roxy-space-sm,.5rem);margin:0}.vargottama-row{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;align-items:center;display:flex}.vargottama-label{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);margin-right:var(--roxy-space-xs,.25rem);font-weight:500}.vargottama-pill{font-size:var(--roxy-text-sm,.875rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 22%, transparent);color:var(--roxy-fg,#0a0a0a);border:1px solid color-mix(in srgb, var(--roxy-accent,#f59e0b) 45%, transparent);border-radius:999px;align-items:center;gap:.2em;padding:.15em .6em;font-weight:600;display:inline-flex}`],p([(0,Va.property)({type:String,reflect:!0,attribute:"chart-style"})],Or.prototype,"chartStyle",2),Or=p([(0,Va.customElement)("roxy-divisional-chart")],Or);var ye=require("lit"),Za=require("lit/decorators.js");var Pl={manglik:"Mangal Dosha",kalsarpa:"Kaal Sarp Dosha",sadhesati:"Sade Sati"},Ir=class extends g{constructor(){super(...arguments);this.type="manglik"}renderEmpty(){return ye.html`<div class="roxy-empty" role="status">No dosha data</div>`}renderData(e){let r=!!e.present,a=Pl[this.type]??this.type,s=(e.severity??"").toLowerCase(),o=s==="severe"?3:s==="moderate"?2:s==="mild"?1:0,i=o*33,l=o===3?"var(--roxy-danger)":o>=1?"var(--roxy-warning)":"transparent";return ye.html`<article class="card" part="card" aria-label="${a}"><header class="head" part="header"><h2 class="title">${a}</h2><span class="${`badge ${r?"present":"absent"}`}">${r?"Present":"Absent"} </span>${ce(e.frame)}</header>${"type"in e&&e.type?ye.html`<p class="subtype"><span class="subtype-label">${this.type==="sadhesati"?"Current phase":"Type"}</span>${e.type}</p>`:ye.nothing} ${e.severity?ye.html`<div class="severity-bar" part="details" role="meter" aria-valuemin="0" aria-valuemax="3" aria-valuenow="${o}" aria-label="Severity ${e.severity}"><span class="severity-fill" style="width:${i}%;background:${l}"></span></div>`:ye.nothing} ${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${this.renderEffects(e)} ${e.remedies&&e.remedies.length>0&&!this.hideReadings?ye.html`<div part="section remedies"><h3>Remedies</h3><ul>${e.remedies.map(d=>ye.html`<li>${d}</li>`)}</ul></div>`:ye.nothing} ${"exceptions"in e&&e.exceptions&&e.exceptions.length>0&&!this.hideReadings?ye.html`<div part="section exceptions"><h3>Exceptions</h3><ul>${e.exceptions.map(d=>ye.html`<li>${d}</li>`)}</ul></div>`:ye.nothing}</article>`}renderEffects(e){if(!e.effects||this.hideReadings)return ye.nothing;let r=[];for(let[a,s]of Object.entries(e.effects))if(typeof s=="string"&&s.length>0)r.push(ye.html`<div><h3>${a}</h3><p>${s}</p></div>`);else if(s&&typeof s=="object")for(let[o,i]of Object.entries(s))typeof i=="string"&&i.length>0&&r.push(ye.html`<div><h3>${o}</h3><p>${i}</p></div>`);return r.length===0?ye.nothing:ye.html`<div class="effects" part="section effects">${r}</div>`}};Ir.styles=[y,de,ye.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:capitalize;margin:0}.subtype{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.subtype .subtype-label{color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-size:var(--roxy-text-xs,.75rem);margin-right:.4rem}.badge{align-items:center;gap:var(--roxy-space-xs,.25rem);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em;padding:4px 10px;display:inline-flex}.badge.absent{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.present{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.severity-bar{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 30%, transparent);border-radius:4px;width:100%;height:8px;position:relative;overflow:hidden}.severity-fill{height:100%;transition:width var(--roxy-motion-duration,.2s) ease-out;border-radius:4px;display:block}@media (prefers-reduced-motion:reduce){.severity-fill{transition:none}}.description{color:var(--roxy-fg,#0a0a0a);margin:0}h3{margin:0 0 var(--roxy-space-xs,.25rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}ul{padding-left:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);margin:0}.effects{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.effects p{font-size:var(--roxy-text-sm,.875rem);margin:0}`],p([(0,Za.property)({type:String,reflect:!0})],Ir.prototype,"type",2),Ir=p([(0,Za.customElement)("roxy-dosha-card")],Ir);var dr=require("lit"),go=require("lit/decorators.js");var ht=class extends g{renderData(t){return dr.html`<article class="card" part="card" aria-label="${t.name??"Dream symbol"}"><header class="head" part="header">${t.letter?dr.html`<span class="letter" aria-hidden="true">${t.letter}</span>`:dr.nothing}<div><p class="label">Dream symbol</p>${t.name?dr.html`<h2 class="name">${t.name}</h2>`:dr.nothing}</div></header>${t.meaning?dr.html`<p class="meaning">${t.meaning}</p>`:dr.nothing}</article>`}renderEmpty(){return dr.html`<div class="roxy-empty" role="status">No dream symbol</div>`}};ht.styles=[y,dr.css`.card{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md,1rem);display:flex}.letter{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);width:2.5rem;height:2.5rem;color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-variant-numeric:tabular-nums;flex:none;justify-content:center;align-items:center;display:inline-flex}.label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.name{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.meaning{color:var(--roxy-fg,#0a0a0a);margin:0;line-height:1.6}`],ht=p([(0,go.customElement)("roxy-dream-card")],ht);var Rr=require("lit"),ho=require("lit/decorators.js");var yt=class extends g{renderEmpty(){return Rr.html`<div class="roxy-empty" role="status">No symbols match</div>`}renderData(t){let e=t.symbols??[];if(e.length===0)return this.renderEmpty();let r=typeof t.total=="number"?t.total:e.length;return Rr.html`<section class="wrap" aria-label="Dream symbols"><header class="head"><h2 class="title">Dream symbols</h2><span class="count">${r} match${r===1?"":"es"}</span></header><ul class="grid">${e.map(a=>Rr.html`<li><button type="button" class="result" @click="${()=>this.select(a)}">${a.letter?Rr.html`<span class="letter" aria-hidden="true">${a.letter}</span>`:Rr.nothing} <span class="name">${a.name}</span></button></li>`)}</ul></section>`}select(t){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:{id:t.id,name:t.name,letter:t.letter},bubbles:!0,composed:!0}))}};yt.styles=[y,Rr.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.grid{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fill,minmax(8rem,1fr));margin:0;padding:0;list-style:none;display:grid}.result{align-items:center;gap:var(--roxy-space-sm,.5rem);text-align:left;width:100%;font:inherit;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);cursor:pointer;background:0 0;transition:border-color .12s,background .12s;display:flex}.result:hover,.result:focus-visible{border-color:var(--roxy-accent,#f59e0b);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent);outline:none}.letter{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);width:1.6rem;height:1.6rem;color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;flex:none;place-items:center;display:grid}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:500}`],yt=p([(0,ho.customElement)("roxy-dream-search")],yt);var W=require("lit"),je=require("lit/decorators.js"),Ja=require("lit/directives/if-defined.js");var Nl=12,Is=["latitude","longitude","timezone"],Hs=["latitude","longitude"];function Gl(n){let t=n.match(/^(.+?)(Latitude|Longitude)$/);return t?{group:t[1],leaf:t[2].toLowerCase()}:null}var Bl=xe.map(n=>n.toLowerCase());function Ya(n,t){if(n){if("$ref"in n&&n.$ref){let e=n.$ref.split("/").pop();return e?t[e]:void 0}return n}}function yo(n){let t=n.anyOf??n.oneOf;return!t||t.length===0?n:t.find(e=>Array.isArray(e.enum))??t.find(e=>Os(e)&&Os(e)!=="null")??t[0]??n}function Os(n){if(typeof n.type=="string")return n.type;if(!Array.isArray(n.type))return;let t=n.type.filter(e=>e!=="null");return t.length===1?t[0]:void 0}function Ol(n){let t=yo(n),e=Os(t);return Array.isArray(t.enum)?t.enum.length<=Nl?"tiles":"select":e==="boolean"?"toggle":t.format==="date"?"date":t.format==="time"?"time":t.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function uo(n){if(n.length!==12)return!1;let t=new Set(n.map(e=>e.toLowerCase()));return Bl.every(e=>t.has(e))}function Ua(n,t,e){let r=yo(t);return{key:e.key,name:n,group:e.group,inQuery:e.inQuery,kind:Ol(t)??"text",required:e.required,description:r.description??t.description,enum:r.enum,min:r.minimum,max:r.maximum,default:t.default??r.default,example:t.example??r.example}}function xo(n,t,e){let r=[],a=!1,s=n.requestBody?.content?.["application/json"]?.schema,o=Ya(s,t);if(o?.properties){let i=new Set(o.required??[]);for(let[l,d]of Object.entries(o.properties)){let m=Ya(d,t)??{};if(m.type==="object"&&m.properties){let c=new Set(m.required??[]);for(let[u,z]of Object.entries(m.properties)){let $=Ya(z,t)??{};r.push(Ua(u,$,{key:`${l}.${u}`,group:l,required:i.has(l)&&c.has(u)}))}}else{let c=Gl(l);r.push(c?Ua(c.leaf,m,{key:l,group:c.group,required:i.has(l)}):Ua(l,m,{key:l,required:i.has(l)}))}}}for(let i of n.parameters??[]){if(i.in!=="path"&&i.in!=="query")continue;if(i.name==="lang"&&i.in==="query"){a=!0;continue}let l=Ya(i.schema,t)??{};r.push(Ua(i.name,l,{key:i.name,required:!!i.required,inQuery:i.in==="query"}))}return{title:Il(n.summary,e),fields:r,hasLang:a}}function Il(n,t){let e=n?.split(" - ")[0]?.trim();return e||T(t.split("/").pop()??"")}function fo(n){let t=n.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(t)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(t)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(t)?"Get reading":"Generate"}function bo(n,t){let e=t.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${n.toLowerCase()}--${e}.json`}var Wa="0.25.0";var vo="https://roxyapi.com/api/v2/openapi.json",Hl=`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${Wa}/dist/schemas`,js=new Map;async function jl(n){let t=js.get(n);return t||(t=fetch(n).then(async e=>{if(!e.ok)throw new Error(`HTTP ${e.status}`);return await e.json()}).catch(e=>{throw js.delete(n),e}),js.set(n,t)),t}function Fl(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}function _l(n){let t=n.trim();if(!t)return[];try{let e=JSON.parse(t);if(Array.isArray(e))return e}catch{}return t.split(",").map(e=>e.trim()).filter(Boolean)}var Se=class extends W.LitElement{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.fields=[];this.formTitle="";this.hasLang=!1;this.values={};this.loaded=!1;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=!1,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){let r=e instanceof Error?e.message:String(e);this.specError=r,this.loaded=!0,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||vo,message:r},bubbles:!0,composed:!0}))}}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(vo)}async modelFromSpec(e){let r=await jl(e),a=`/${this.endpoint.replace(/^\//,"")}`,s=r.paths?.[a]?.[this.method.toLowerCase()];if(!s)throw new Error(`Endpoint ${this.method} ${a} not found in OpenAPI spec`);return xo(s,r.components?.schemas??{},this.endpoint)}async tryLoadSlice(){try{let e=await fetch(`${Hl}/${bo(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){this.fields=e.fields,this.formTitle=e.title,this.hasLang=e.hasLang;let r={};for(let a of e.fields){a.default!==void 0&&(r[a.key]=a.default);let s=a.group?this.initialValues?.[a.group]?.[a.name]:this.initialValues?.[a.name];s!==void 0&&(r[a.key]=s)}this.values=r,this.loaded=!0}setValue(e,r){this.values={...this.values,[e]:r}}roleOf(e){return e.name==="seed"?"seed":(e.name==="limit"||e.name==="offset")&&!e.required?"hidden-default":Is.includes(e.name)&&this.groupHasLocation(e.group)||e.name==="timezone"&&this.locationGroups().some(r=>this.timezoneFieldFor(r)?.key===e.key)?"location":"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){let e=[];for(let r of this.fields)e.includes(r.group)||e.push(r.group);return e}groupHasLocation(e){let r=this.fields.filter(a=>a.group===e);return Hs.every(a=>r.some(s=>s.name===a))}locationGroups(){return this.groupKeys().filter(e=>this.groupHasLocation(e))}timezoneFieldFor(e){let r=this.fields.find(a=>a.group===e&&a.name==="timezone");if(r)return r;if(this.locationGroups()[0]===e)return this.fields.find(a=>a.group===void 0&&a.name==="timezone")}locationRequired(e){let r=this.fields.filter(a=>a.group===e);return Is.some(a=>r.some(s=>s.name===a&&s.required))}groupIsRequired(e){return this.groupHasLocation(e)||this.fields.some(r=>r.group===e&&r.required)}get singleEnumField(){if(this.groupKeys().some(a=>this.groupHasLocation(a))||this.groupKeys().some(a=>a!==void 0))return null;let e=this.fields.filter(a=>a.required&&this.isRendered(a)),r=e[0];return e.length!==1||!r?null:r.kind==="tiles"||r.kind==="select"?r:null}effectiveSubmitLabel(){return this.submitLabel||fo(this.endpoint)}effectiveLang(){return dn(this)}onLocationFor(e){return r=>{let a=r.detail;if(!a)return;let s=m=>this.fields.find(c=>c.group===e&&c.name===m)?.key,o={...this.values},i=s("latitude"),l=s("longitude");i&&(o[i]=a.latitude),l&&(o[l]=a.longitude);let d=this.timezoneFieldFor(e);d&&(o[d.key]=a.timezone??a.utcOffset),this.values=o}}selectTile(e,r){this.setValue(e.key,r),this.singleEnumField?.key===e.key&&this.submit()}onTilesKeyDown(e){return r=>{let a=e.enum??[];if(a.length===0)return;let s=a.indexOf(this.values[e.key]),o;if(r.key==="Home")o=0;else if(r.key==="End")o=a.length-1;else if(r.key==="ArrowRight"||r.key==="ArrowDown")o=s===-1?0:(s+1)%a.length;else if(r.key==="ArrowLeft"||r.key==="ArrowUp")o=s===-1?a.length-1:(s-1+a.length)%a.length;else return;r.preventDefault();let i=a[o];if(i===void 0)return;this.selectTile(e,i);let l=r.currentTarget;requestAnimationFrame(()=>l.querySelector(`[data-tile='${o}']`)?.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:!0,composed:!0}));return}this.validationErrors=[];let r={};for(let o of this.fields){let i=this.values[o.key];if(o.name==="seed"&&(i===void 0||i==="")&&(i=Fl()),!(i===void 0||i===""))if(o.kind==="array"&&typeof i=="string"&&(i=_l(i)),o.group){let l=r[o.group]??{};l[o.name]=i,r[o.group]=l}else r[o.name]=i}let a=this.fields.filter(o=>o.inQuery).map(o=>o.name),s=this.effectiveLang();this.hasLang&&s&&(r.lang=s,a.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:r,queryKeys:a,sticky:this.singleEnumField!=null},bubbles:!0,composed:!0}))}collectMissing(){let e=[],r=[],a=new Set;for(let s of this.fields){if(!s.required)continue;let o=this.roleOf(s)==="location";if(!this.isRendered(s)&&!o)continue;let i=this.values[s.key];if(!(i!==void 0&&i!=="")){if(e.push(s.key),o){a.add(s.group);continue}r.push(s.group?`${T(s.group)} ${T(s.name)}`:T(s.name))}}for(let s of a)r.push(s?`${T(s)} location`:"Birth location");return{keys:e,labels:r}}reqMark(e){return e.required?W.html`<span class="req" aria-hidden="true">*</span>`:W.nothing}description(e){if(!e.description)return W.nothing;if(e.description.length<=120)return W.html`<small class="help">${e.description}</small>`;let r=e.description.split(". ")[0]??e.description;return W.html`<details class="help-details"><summary><span class="help-lead">${r}</span>${te()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let r=`roxy-form-${e.key}-label`,a=!!e.enum&&uo(e.enum),s=e.enum??[],o=s.indexOf(this.values[e.key]),i=o===-1?0:o;return W.html`<div class="field tiles-field"><span class="label" id="${r}">${T(e.name)}${this.reqMark(e)}</span><div class="tiles" role="radiogroup" aria-labelledby="${r}" @keydown="${this.onTilesKeyDown(e)}">${s.map((l,d)=>{let m=this.values[e.key]===l,c=a?q(l):void 0;return W.html`<button type="button" class="tile" role="radio" data-tile="${d}" aria-checked="${m?"true":"false"}" tabindex="${d===i?"0":"-1"}" @click="${()=>this.selectTile(e,l)}">${c?W.html`<span class="tile-glyph" aria-hidden="true">${c}</span>`:W.nothing} <span class="tile-label">${T(l)}</span></button>`})}</div>${this.description(e)}</div>`}renderSelect(e){let r=`roxy-form-${e.key}`;return W.html`<div class="field"><label for="${r}">${T(e.name)}${this.reqMark(e)}</label> <select id="${r}" ?required="${e.required}" @change="${a=>this.setValue(e.key,a.target.value)}"><option value="">Choose</option>${(e.enum??[]).map(a=>W.html`<option value="${a}" ?selected="${this.values[e.key]===a}">${T(a)}</option>`)}</select> ${this.description(e)}</div>`}renderToggle(e){let r=`roxy-form-${e.key}`,a=this.values[e.key]===!0;return W.html`<div class="field"><div class="toggle-row"><button type="button" id="${r}" class="toggle" role="switch" aria-checked="${a?"true":"false"}" @click="${()=>this.setValue(e.key,!a)}"><span class="knob"></span></button> <label class="toggle-label" for="${r}">${T(e.name)}${this.reqMark(e)}</label></div>${this.description(e)}</div>`}renderInput(e){let r=`roxy-form-${e.key}`,a=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,s=e.kind==="array"?"Comma separated":e.example!=null?String(e.example):"";return W.html`<div class="field"><label for="${r}">${T(e.name)}${this.reqMark(e)}</label> <input id="${r}" type="${e.kind==="array"?"text":a}" ?required="${e.required}" min="${(0,Ja.ifDefined)(e.min)}" max="${(0,Ja.ifDefined)(e.max)}" step="${e.kind==="number"?"any":W.nothing}" placeholder="${s||W.nothing}" .value="${this.values[e.key]??""}" @input="${o=>this.setValue(e.key,this.coerce(e.kind,o.target.value))}"> ${this.description(e)}</div>`}renderField(e){switch(e.kind){case"tiles":return this.renderTiles(e);case"select":return this.renderSelect(e);case"toggle":return this.renderToggle(e);default:return this.renderInput(e)}}locationFillList(e){let r=[...Hs];return this.timezoneFieldFor(e)&&r.push("timezone"),r.join(", ")}locationBlock(e){return W.html`<div class="location-block"><label>${e?`${T(e)} location`:"Birth location"}${this.locationRequired(e)?W.html`<span class="req" aria-hidden="true">*</span>`:W.nothing}</label><roxy-location-search publishable-key="${(0,Ja.ifDefined)(this.publishableKey)}" @roxy-location-select="${this.onLocationFor(e)}" placeholder="${e?`${T(e)} city`:"City of birth"}"></roxy-location-search><small class="help">Fills ${this.locationFillList(e)}. Pick a city to autofill.</small></div>`}groupCard(e){let r=this.fields.filter(a=>a.group===e&&this.isRendered(a));return W.html`<fieldset class="person-group"><legend>${T(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):W.nothing}<div class="fields">${r.map(a=>this.renderField(a))}</div></fieldset>`}render(){if(!this.loaded)return W.html`<form><div class="roxy-skeleton" style="height:8rem"></div></form>`;if(this.specError)return W.html`<div class="spec-error" role="alert">Schema load failed: ${this.specError} <button type="button" class="submit" @click="${this.retryLoadSchema}">Retry</button></div>`;let e=this.fields.filter(d=>!d.group&&this.isRendered(d)),r=e.filter(d=>d.required),a=e.filter(d=>!d.required),s=this.groupKeys().filter(d=>d!==void 0),o=s.filter(d=>this.groupIsRequired(d)),i=s.filter(d=>!this.groupIsRequired(d)),l=a.length>0||i.length>0;return W.html`<form @submit="${this.onSubmit}"><h2 class="title">${this.formTitle}</h2>${this.validationErrors.length>0?W.html`<div class="validation-error" role="alert"><strong>Please complete:</strong> ${this.validationErrors.join(", ")}</div>`:W.nothing}<div class="fields">${r.map(d=>this.renderField(d))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):W.nothing} ${o.map(d=>this.groupCard(d))} ${l?W.html`<details class="advanced"><summary>Advanced${te()}</summary><div class="fields">${a.map(d=>this.renderField(d))}</div>${i.map(d=>this.groupCard(d))}</details>`:W.nothing} ${this.singleEnumField?W.nothing:W.html`<button class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,r){if(r!==""){if(e==="number"){let a=Number(r);return Number.isFinite(a)?a:void 0}return r}}};Se.styles=[y,O,W.css`form{gap:var(--roxy-space-md,1rem);background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.fields{align-items:start;gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.fields:empty{display:none}.person-group{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-md,1rem);min-inline-size:0;margin:0;display:grid}.person-group legend{padding:0 var(--roxy-space-xs,.25rem);font-weight:var(--roxy-weight-bold,600)}.field{gap:var(--roxy-space-xs,.25rem);flex-direction:column;min-width:0;display:flex}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569)}.req{color:var(--roxy-danger-fg,#991b1b);margin-left:4px}input,select{box-sizing:border-box;width:100%;padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);font-size:var(--roxy-text-base,1rem);color:var(--roxy-fg,#0a0a0a);background:var(--roxy-bg,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);font-family:inherit}input:focus,select:focus{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px;border-color:var(--roxy-accent-ink,#b45309)}.help{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.help-details>summary{cursor:pointer;color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);align-items:center;gap:4px;display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-top:var(--roxy-space-xs,.25rem);display:block}.location-block{gap:var(--roxy-space-xs,.25rem);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fit,minmax(5.5rem,1fr));display:grid}.tile{min-height:44px;padding:var(--roxy-space-sm,.5rem);background:var(--roxy-bg,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-fg,#0a0a0a);font-family:inherit;font-size:var(--roxy-text-sm,.875rem);cursor:pointer;transition:border-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease), background-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-direction:column;justify-content:center;align-items:center;gap:2px;display:flex}.tile:hover{border-color:var(--roxy-accent,#f59e0b)}.tile[aria-checked=true]{border-color:var(--roxy-accent,#f59e0b);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 12%, transparent);color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.tile:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.tile-glyph{font-size:1.35em;line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm,.5rem);display:flex}.toggle{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);background:var(--roxy-border,#e4e4e7);cursor:pointer;width:44px;height:26px;transition:background-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-shrink:0;padding:0;position:relative}.toggle[aria-checked=true]{background:var(--roxy-accent,#f59e0b);border-color:var(--roxy-accent,#f59e0b)}.toggle .knob{background:var(--roxy-bg,#fff);width:20px;height:20px;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);border-radius:50%;position:absolute;top:2px;left:2px}.toggle[aria-checked=true] .knob{transform:translate(18px)}.toggle:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.advanced>summary{cursor:pointer;font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);align-items:center;gap:6px;display:flex}.advanced[open]>summary{margin-bottom:var(--roxy-space-md,1rem)}.advanced .fields,.advanced .person-group{margin-top:var(--roxy-space-md,1rem)}.validation-error{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);background:color-mix(in srgb, var(--roxy-danger,#dc2626) 8%, transparent);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);display:grid}button.submit{background:var(--roxy-accent-ink,#b45309);color:var(--roxy-bg,#fff);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-lg,1.5rem);font-size:var(--roxy-text-base,1rem);font-weight:var(--roxy-weight-bold,600);cursor:pointer;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}button.submit:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.spec-error{gap:var(--roxy-space-md,1rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);justify-items:start;display:grid}`],p([(0,je.property)({type:String,attribute:"data-endpoint"})],Se.prototype,"endpoint",2),p([(0,je.property)({type:String})],Se.prototype,"method",2),p([(0,je.property)({type:String,attribute:"spec-url"})],Se.prototype,"specUrl",2),p([(0,je.property)({type:String,attribute:"submit-label"})],Se.prototype,"submitLabel",2),p([(0,je.property)({type:String,attribute:"publishable-key"})],Se.prototype,"publishableKey",2),p([(0,je.property)({attribute:!1})],Se.prototype,"initialValues",2),p([(0,je.state)()],Se.prototype,"fields",2),p([(0,je.state)()],Se.prototype,"formTitle",2),p([(0,je.state)()],Se.prototype,"hasLang",2),p([(0,je.state)()],Se.prototype,"values",2),p([(0,je.state)()],Se.prototype,"loaded",2),p([(0,je.state)()],Se.prototype,"specError",2),p([(0,je.state)()],Se.prototype,"validationErrors",2),Se=p([(0,je.customElement)("roxy-endpoint-form")],Se);var be=require("lit"),Lo=require("lit/decorators.js");var ut=class extends g{renderEmpty(){return be.html`<div class="roxy-empty" role="status">No fixed star data</div>`}renderData(t){let e=t.conjunctions??[],r=t.stars??[];return be.html`<div class="wrap" part="card"><header part="header"><h2 class="title">Fixed stars</h2>${typeof t.orb=="number"?be.html`<span class="badge"><b>Orb</b> ${x(t.orb,1)}°</span>`:be.nothing}</header>${t.summary&&!this.hideReadings?be.html`<p class="summary">${t.summary}</p>`:be.nothing} ${e.length?be.html`<section part="section conjunctions"><p class="subhead">Conjunctions to the chart</p>${e.map((a,s)=>be.html`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${s===0}"><summary><span class="interp-lead"><span class="point">${a.point}</span> conjunct ${a.star}</span> ${te()} <span class="interp-aside"><small>orb ${x(a.orb,2)}°</small></span></summary>${a.interpretation&&!this.hideReadings?be.html`<div class="interp-body"><p>${a.interpretation}</p></div>`:be.nothing}</details>`)}</section>`:be.html`<p class="empty-note">No star sits within the orb of a natal point.</p>`} ${r.length?this.renderCatalog(r):be.nothing}</div>`}renderCatalog(t){return be.html`<details class="catalog"><summary>${te()} Star catalog (${t.length})</summary><div class="scroll"><table><caption class="subhead">Precessed positions for the chart date</caption><thead><tr><th scope="col">Star</th><th scope="col">Position</th><th scope="col" class="num">Mag</th><th scope="col">Nature</th><th scope="col">Keywords</th></tr></thead><tbody>${t.map(e=>{let r=q(e.sign);return be.html`<tr><td>${e.name}</td><td>${r?be.html`<span class="sg">${r}</span>`:be.nothing}${mt(e.degree)} ${e.sign}</td><td class="num">${x(e.magnitude,1)}</td><td>${e.nature}</td><td><div class="kw">${(e.keywords??[]).map(a=>be.html`<span>${a}</span>`)}</div></td></tr>`})}</tbody></table></div></details>`}};ut.styles=[y,O,K,be.css`.wrap{background:var(--roxy-surface,#fff);width:100%;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}header{align-items:baseline;gap:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-primary,#0f172a);margin:0}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);padding:2px 8px}.badge b{color:var(--roxy-accent-ink,#b45309);font-weight:600}.summary{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);margin:0}.empty-note{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.subhead{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0 0 var(--roxy-space-sm,.5rem);font-weight:600}.interp-lead .point{color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{cursor:pointer;color:var(--roxy-fg,#0a0a0a);align-items:center;gap:.5rem;font-weight:600;display:flex}.scroll{min-width:0;margin-top:var(--roxy-space-sm,.5rem);overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{text-align:left;border-bottom:1px solid var(--roxy-border,#e4e4e7);white-space:nowrap;vertical-align:top;padding:6px 10px}th{color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.04em;font-weight:600;font-size:var(--roxy-text-xs,.75rem)}td.num{text-align:right;font-variant-numeric:tabular-nums}.sg{color:var(--roxy-secondary,#475569);margin-right:.3rem}.kw{white-space:normal;flex-wrap:wrap;gap:.2rem;max-width:18rem;display:flex}.kw span{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a);padding:0 6px}`],ut=p([(0,Lo.customElement)("roxy-fixed-stars")],ut);var We=require("lit"),$o=require("lit/decorators.js");var xt=class extends g{renderEmpty(){return We.html`<div class="roxy-empty" role="status">No digest data</div>`}renderData(t){let e=t.windows??[];if(e.length===0)return this.renderEmpty();let r=[D(this.effectiveLang(),t.startDate),D(this.effectiveLang(),t.endDate)].filter(Boolean).join(" \u2013 ");return We.html`<div class="wrap" part="card" aria-label="Forecast digest"><div class="head" part="header"><h2 class="title">Forecast digest</h2>${r?We.html`<p class="subtitle">${r}</p>`:We.nothing}</div>${e.map(a=>this.renderWindow(a))}</div>`}windowLabel(t){return t===1?"Next 24 hours":typeof t=="number"?`Next ${t} days`:"Window"}renderWindow(t){let e=[...t.top??[]].sort((s,o)=>(o.significance??0)-(s.significance??0)),r=t.byDomain??{},a=Object.entries(r);return We.html`<section class="window" part="section window"><div class="window-head" part="details"><span class="window-label">${this.windowLabel(t.days)}</span> <span class="window-count">${t.count??0} event${t.count===1?"":"s"}</span></div>${a.length>0?We.html`<div class="domains" part="legend">${a.map(([s,o])=>We.html`<span class="domain-chip"><span class="swatch sw-${s}"></span>${T(s)} ${o}</span>`)}</div>`:We.nothing} ${e.length>0?We.html`<div role="list">${e.map(s=>this.renderEvent(s))}</div>`:We.html`<p class="quiet">No notable events.</p>`}</section>`}renderEvent(t){let e=typeof t.significance=="number"?t.significance:0,r=this.hideReadings||t.description==null?T(t.type??""):t.description;return We.html`<div class="event" role="listitem"><span class="event-date">${D(this.effectiveLang(),t.date)}</span> <span class="event-desc">${r}</span> <span class="sig" role="img" aria-label="significance ${x(e,0)} of 100"><span class="sig-fill ${t.domain}" style="width:${Math.max(0,Math.min(100,e))}%"></span></span></div>`}};xt.styles=[y,We.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.window{gap:var(--roxy-space-sm,.5rem);padding-top:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);display:grid}.window:first-of-type{border-top:none;padding-top:0}.window-head{flex-wrap:wrap;align-items:baseline;gap:.5rem;display:flex}.window-label{font-weight:var(--roxy-weight-bold,600)}.window-count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;margin-left:auto}.domains{flex-wrap:wrap;gap:.4rem;display:flex}.domain-chip{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);align-items:center;gap:.35rem;display:inline-flex}.swatch{border-radius:2px;width:.65rem;height:.65rem;display:inline-block}.sw-western{background:var(--roxy-accent,#f59e0b)}.sw-vedic{background:var(--roxy-info,#2563eb)}.sw-biorhythm{background:var(--roxy-success,#16a34a)}.event{grid-template-columns:auto 1fr;align-items:baseline;gap:.25rem .6rem;display:grid}.event-date{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;white-space:nowrap}.event-desc{font-size:var(--roxy-text-sm,.875rem);line-height:1.4}.sig{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:2px;grid-column:2;height:4px;overflow:hidden}.sig-fill{border-radius:2px;height:100%;display:block}.sig-fill.western{background:var(--roxy-accent,#f59e0b)}.sig-fill.vedic{background:var(--roxy-info,#2563eb)}.sig-fill.biorhythm{background:var(--roxy-success,#16a34a)}.quiet{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-style:italic}`],xt=p([(0,$o.customElement)("roxy-forecast-digest")],xt);var ue=require("lit"),wo=require("lit/decorators.js");var Kl={western:"Western",vedic:"Vedic",biorhythm:"Biorhythm"},ql=["western","vedic","biorhythm"],ft=class extends g{renderEmpty(){return ue.html`<div class="roxy-empty" role="status">No forecast data</div>`}renderData(t){let e=t.events??[],r=this.groupByDate(e),a=ql.filter(s=>e.some(o=>o.domain===s));return ue.html`<div class="wrap" part="card" aria-label="Forecast timeline"><header class="head" part="header"><h2 class="title">Forecast timeline</h2>${t.startDate&&t.endDate?ue.html`<div class="range">${D(this.effectiveLang(),t.startDate)} - ${D(this.effectiveLang(),t.endDate)} · ${t.count??e.length} events</div>`:ue.nothing}</header>${a.length?ue.html`<div class="legend" part="legend">${a.map(s=>ue.html`<span><span class="swatch swatch-${s}"></span>${Kl[s]}</span>`)}</div>`:ue.nothing} ${r.length?ue.html`<div class="days" part="section events" role="list">${r.map(([s,o])=>this.renderDay(s,o))}</div>`:ue.html`<p class="roxy-empty" role="status">No events in this window</p>`}</div>`}groupByDate(t){let e=new Map;for(let r of t){let a=r.date??"",s=e.get(a)??[];s.push(r),e.set(a,s)}return[...e.entries()]}renderDay(t,e){return ue.html`<div class="day" role="listitem"><div class="day-date">${D(this.effectiveLang(),t)}</div><div class="events">${e.map(r=>this.renderEvent(r))}</div></div>`}renderEvent(t){let e=typeof t.significance=="number"?t.significance:0,r=Math.max(0,Math.min(100,e));return ue.html`<div class="event"><span class="dot dot-${t.domain}" aria-hidden="true"></span><div class="event-body"><div class="event-line">${this.renderHeadline(t)}</div>${t.description&&!this.hideReadings?ue.html`<p class="event-desc">${t.description}</p>`:ue.nothing}<div class="sig" title="Significance ${r} of 100"><span class="sig-track"><span class="sig-fill sig-fill-${t.domain}" style="width:${r}%"></span> </span><span class="sig-val">${r}</span></div></div></div>`}renderHeadline(t){let e=t.body?Z(t.body):"",r=t.target?Z(t.target):"",a=or({type:t.aspect}),s=vr[a]??"",o=a?ba(t.aspect)??ke({type:t.aspect}):"",i=typeof t.orb=="number"?x(t.orb,1):"",l=this.typeQualifier(t);return a&&r?ue.html`<strong>${e}</strong> <span class="${s}">${o}</span> <strong>${r}</strong>${i?ue.html`<span class="kind">orb ${i}°</span>`:ue.nothing}`:ue.html`<strong>${e||T(t.type??"")}</strong>${l?ue.html`<span class="kind">${l}</span>`:ue.nothing}`}typeQualifier(t){return t.type==="sign-ingress"&&t.target?`enters ${Z(t.target)}`:t.type==="retrograde-station"&&t.station?t.station:t.type==="eclipse"?[t.kind,"eclipse"].filter(Boolean).join(" "):t.type==="critical-day"?"critical day":t.type==="dasha-change"&&t.target?`dasha ${Z(t.target)}`:T(t.type??"")}};ft.styles=[y,ue.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.range{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-variant-numeric:tabular-nums}.legend{gap:var(--roxy-space-md,1rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);flex-wrap:wrap;display:flex}.legend .swatch{vertical-align:middle;border-radius:50%;width:10px;height:10px;margin-right:4px;display:inline-block}.swatch-western{background:var(--roxy-accent,#f59e0b)}.swatch-vedic{background:var(--roxy-info,#2563eb)}.swatch-biorhythm{background:var(--roxy-success,#16a34a)}.day{gap:var(--roxy-space-md,1rem);padding-block:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:4.5rem 1fr;display:grid}.day:first-of-type{border-top:none}.day-date{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;padding-top:2px}.events{gap:var(--roxy-space-sm,.5rem);display:grid}.event{gap:var(--roxy-space-sm,.5rem);grid-template-columns:.6rem 1fr;align-items:start;display:grid}.dot{border-radius:50%;width:.6rem;height:.6rem;margin-top:4px}.dot-western{background:var(--roxy-accent,#f59e0b)}.dot-vedic{background:var(--roxy-info,#2563eb)}.dot-biorhythm{background:var(--roxy-success,#16a34a)}.event-body{min-width:0}.event-line{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.event-line .aspect-trine,.event-line .aspect-sextile{color:var(--roxy-success-fg,#166534)}.event-line .aspect-square,.event-line .aspect-opposition{color:var(--roxy-danger-fg,#991b1b)}.event-line .aspect-conjunction{color:var(--roxy-accent-ink,#b45309)}.event-line .kind{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.04em;margin-left:.35em}.event-desc{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:2px 0 0}.sig{align-items:center;gap:.4rem;margin-top:4px;display:flex}.sig-track{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);flex:1;max-width:8rem;height:4px;overflow:hidden}.sig-fill{border-radius:var(--roxy-radius-full,9999px);height:100%;display:block}.sig-fill-western{background:var(--roxy-accent,#f59e0b)}.sig-fill-vedic{background:var(--roxy-info,#2563eb)}.sig-fill-biorhythm{background:var(--roxy-success,#16a34a)}.sig-val{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums}`],ft=p([(0,wo.customElement)("roxy-forecast-timeline")],ft);var ie=require("lit"),ko=require("lit/decorators.js");var Xa=8,bt=class extends g{renderEmpty(){return ie.html`<div class="roxy-empty" role="status">No transit data</div>`}renderData(t){let e=t.transitingPlanets??[];if(!e.length)return this.renderEmpty();let r=t.keyTransits??[];return ie.html`<div class="wrap" part="card" aria-label="Gochara transits"><header class="head" part="header"><h2 class="title">Gochara</h2><p class="sub">Where each graha transits at <strong>${Oe(this.effectiveLang(),t.transitDatetime)}</strong>, read against the natal chart of ${Oe(this.effectiveLang(),t.birthDatetime)}.</p></header><div part="table">${e.map(a=>this.renderPlanet(a))}</div>${r.length&&!this.hideReadings?ie.html`<section class="key" part="section key-transits"><h3 class="key-title">Key transits</h3>${r.map(a=>ie.html`<p class="key-item">${a.description} ${typeof a.natalHouse=="number"?ie.html`<span class="meta">· natal house ${a.natalHouse}</span>`:ie.nothing}</p>`)}</section>`:ie.nothing}</div>`}renderPlanet(t){let e=k(t.name)??"",r=typeof t.longitude=="number"?He(t.longitude):void 0,a=t.aspectsToNatal??[];return ie.html`<article class="row"><div class="row-top"><span class="graha">${e?ie.html`<span class="glyph">${e}</span>`:ie.nothing}${t.name} </span><span class="pos">${t.sign}${r?ie.html`${mt(r.degree)}`:ie.nothing} </span>${typeof t.natalHouse=="number"?ie.html`<span class="house">natal house ${t.natalHouse}</span>`:ie.nothing}</div>${this.renderKaksha(t.kaksha)} ${a.length?ie.html`<p class="aspects">${a.map(s=>`${ke({type:s.aspectType})} natal ${s.natalPlanet}${typeof s.orb=="number"?` (${x(s.orb,1)}\xB0)`:""}`).join(" \xB7 ")}</p>`:ie.nothing}</article>`}renderKaksha(t){if(!t||typeof t.number!="number")return ie.nothing;let e=t.number,r=t.bindu===!0?"yes":t.bindu===!1?"no":"";return ie.html`<div class="kaksha-bar" part="chart" role="img" aria-label="Kaksha ${e} of ${Xa} within ${""}the current sign">${Array.from({length:Xa},(a,s)=>ie.html`<span class="seg ${s+1===e?`here ${r}`:""}"></span>`)}</div><p class="meta">Kaksha <span class="num">${e}</span> of ${Xa}${t.lord?ie.html`, ruled by ${t.lord}`:""}${typeof t.startDegree=="number"&&typeof t.endDegree=="number"?ie.html`, spanning <span class="num">${x(t.startDegree,2)}° to ${x(t.endDegree,2)}°</span> of the sign`:""}${t.bindu===null||t.bindu===void 0?"":ie.html` · this kaksha lord ${t.bindu?"gave":"gave no"} bindu${typeof t.binduCount=="number"?ie.html`, <span class="num">${t.binduCount}</span> of ${Xa} in this sign`:""}`}</p>`}};bt.styles=[y,ie.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sub{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.row{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold,600)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.35em}.pos{color:var(--roxy-secondary,#475569);font-size:var(--roxy-text-sm,.875rem);font-variant-numeric:tabular-nums}.house{font-size:var(--roxy-text-xs,.75rem);border-radius:var(--roxy-radius-sm,4px);border:1px solid var(--roxy-border,#e4e4e7);padding:.1rem .45rem}.kaksha-bar{grid-template-columns:repeat(8,1fr);gap:2px;height:10px;margin:.15rem 0;display:grid}.seg{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:2px}.seg.here{background:color-mix(in srgb, var(--roxy-muted,#71717a) 45%, transparent)}.seg.here.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 55%, transparent)}.seg.here.no{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 55%, transparent)}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.num{font-variant-numeric:tabular-nums}.aspects{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-secondary,#475569);line-height:var(--roxy-leading-normal,1.5);margin:0}.key{padding:var(--roxy-space-md,1rem);border-top:2px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-sm,.5rem);display:grid}.key-title{font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em;color:var(--roxy-muted,#71717a);margin:0}.key-item{font-size:var(--roxy-text-sm,.875rem);line-height:var(--roxy-leading-normal,1.5);margin:0}`],bt=p([(0,ko.customElement)("roxy-gochara-table")],bt);var ve=require("lit"),So=require("lit/decorators.js");var Vl={varna:1,vashya:2,tara:3,yoni:4,"graha maitri":5,gana:6,bhakoot:7,nadi:8},vt=class extends g{renderEmpty(){return ve.html`<div class="roxy-empty" role="status">No Guna Milan data</div>`}renderData(t){let e=(t.breakdown??[]).filter(m=>m?.category!==void 0),r=t.total??0,a=t.maxScore??36,s=r/a*100,o="color-mix(in srgb, var(--roxy-border) 50%, transparent)",i=s>=70?"var(--roxy-success)":s>=50?"var(--roxy-warning)":"var(--roxy-danger)",l=s*2.827,d=(100-s)*2.827;return ve.html`<article class="card" part="card" aria-label="Guna Milan score"><div class="score-header" part="header"><div class="score-info"><div class="score-bar" part="details"><div><span class="total">${x(t.total,1)}</span> <span class="over">/ ${t.maxScore}</span> ${typeof t.percentage=="number"?ve.html`<small style="margin-left:.5rem;color:var(--roxy-muted)">${An(t.percentage,1)}</small>`:ve.nothing}</div><div class="verdict-wrap">${typeof t.isCompatible=="boolean"?ve.html`<span class="verdict ${t.isCompatible?"yes":"no"}">${t.isCompatible?"Compatible":"Not compatible"}</span>`:ve.nothing} ${t.recommendation&&!this.hideReadings?ve.html`<span class="recommendation">${t.recommendation}</span>`:ve.nothing}</div></div></div><div class="score-ring" part="chart" role="meter" aria-label="Guna milan score" aria-valuemin="0" aria-valuemax="36" aria-valuenow="${r}"><svg viewBox="0 0 100 100" aria-hidden="true"><circle class="ring-track" cx="50" cy="50" r="45" fill="none" stroke="${o}" stroke-width="8"/><circle class="ring-fill" cx="50" cy="50" r="45" fill="none" stroke="${i}" stroke-width="8" stroke-dasharray="${l},${d}" stroke-linecap="round" transform="rotate(-90 50 50)"/><text x="50" y="50" text-anchor="middle" dominant-baseline="central" class="ring-text">${r}</text><text x="50" y="64" text-anchor="middle" dominant-baseline="central" class="ring-max">/${a}</text></svg></div></div>${e.length>0?ve.html`<div class="table-scroll" part="table"><table><caption class="roxy-sr-only">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">Koota</th><th scope="col">Person 1</th><th scope="col">Person 2</th><th scope="col" class="bar-col">Progress</th><th scope="col" class="score">Score</th></tr></thead><tbody>${e.map(m=>{let c=m.score??0,u=m.maxScore??Zl(m.category),z=u?c/u*100:0;return ve.html`<tr><td>${m.category} ${m.description?ve.html`<small>${m.description}</small>`:ve.nothing}</td><td class="classification">${m.person1??""}</td><td class="classification">${m.person2??""}</td><td class="bar-cell bar-col"><div class="mini-bar"><span style="width:${z}%"></span></div></td><td class="score">${x(c,1)} / ${u}</td></tr>`})}</tbody></table></div>`:ve.nothing} ${(t.doshas?.length??0)>0||(t.doshaCancellations?.length??0)>0?ve.html`<div class="tags" part="details">${t.doshas?.map(m=>ve.html`<span class="dosha">${m}</span>`)} ${t.doshaCancellations?.map(m=>ve.html`<span class="cancel" title="${m.reason}">${m.dosha} cancelled</span>`)}</div>`:ve.nothing} ${ce(t.frame)}</article>`}};vt.styles=[y,de,ve.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.card>*{min-width:0}.score-header{align-items:center;gap:1rem;display:flex}.score-info{flex:1;min-width:0}.table-scroll{-webkit-overflow-scrolling:touch;min-width:0;overflow-x:auto}.score-bar{align-items:center;gap:var(--roxy-space-md,1rem);grid-template-columns:1fr auto;display:grid}.total{font-size:2.25rem;font-weight:var(--roxy-weight-bold,600);color:var(--roxy-accent-ink,#b45309);font-variant-numeric:tabular-nums;line-height:1}.over{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-base,1rem)}.verdict-wrap{justify-items:end;gap:var(--roxy-space-xs,.25rem);text-align:right;display:grid}.verdict{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 10px}.verdict.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.verdict.no{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.recommendation{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569)}.score-ring{flex-shrink:0;width:120px;height:120px}.score-ring svg{width:100%;height:100%}.score-ring .ring-text{fill:var(--roxy-fg,#0a0a0a);font-size:22px;font-weight:700;font-family:var(--roxy-font-sans)}.score-ring .ring-max{fill:var(--roxy-muted,#71717a);font-size:10px;font-family:var(--roxy-font-sans)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}td small{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin-top:2px;line-height:1.5;display:block}td.classification{color:var(--roxy-secondary,#475569);white-space:nowrap}th.score{text-align:right}td.score{text-align:right;font-variant-numeric:tabular-nums;color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}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-ring .ring-text,.score-ring .ring-max{display:none}.score-bar{gap:var(--roxy-space-xs,.25rem);grid-template-columns:1fr}.verdict-wrap{text-align:left;justify-items:start}}.mini-bar{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);height:8px;overflow:hidden}.mini-bar>span{background:var(--roxy-accent,#f59e0b);height:100%;transition:width var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.tags{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.tags span{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}.tags .dosha{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.tags .cancel{background:color-mix(in srgb, var(--roxy-success,#16a34a) 18%, transparent);color:var(--roxy-success-fg,#166534)}`],vt=p([(0,So.customElement)("roxy-guna-milan")],vt);function Zl(n){return n&&Vl[n.toLowerCase()]||1}var Le=require("lit"),Co=require("lit/decorators.js");var Lt=class extends g{renderData(t){let e=t.channels??[],r=t.centers??[],a=r.filter(s=>s.defined).length;return Le.html`<div class="wrap" part="card" aria-label="Human Design connection"><header class="head" part="header"><h2 class="title">Connection</h2>${typeof t.totalChannels=="number"?Le.html`<span class="count">${t.totalChannels} channels</span>`:Le.nothing}</header>${wr([{label:"Channels",value:t.totalChannels?.toString()},{label:"Combined definition",value:t.combinedDefinition?T(String(t.combinedDefinition)):void 0},{label:"Centers defined",value:r.length>0?`${a} of ${r.length}`:void 0}])} ${this.hideReadings?Le.nothing:Le.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(t.summary)} ${this.renderCenters(r)} ${this.renderChannels(e,r)}</div>`}renderDynamics(t){if(!t)return Le.nothing;let e=[{label:"Electromagnetic",aside:Qa(t.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:Qa(t.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:Qa(t.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:Qa(t.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(e,"hd-connection-dynamic","Dynamics")}renderCenters(t){return t.length===0?Le.nothing:Le.html`<section class="block" part="section centers"><h3>Centers</h3>${this.hideReadings?Le.nothing:Le.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>`} ${t.map(e=>{let r=e.definedBy??[],a=r.includes("A"),s=r.includes("B"),o=!!e.defined&&!a&&!s;return Le.html`<div class="row"><span class="cname">${e.name??T(String(e.id??""))}</span> <span class="badge ${e.defined?o?"together":"defined":"open"}">${e.defined?o?"Only together":"Defined":"Open"} </span><span class="who">${Yl(!!e.defined,a,s)}</span></div>`})}</section>`}renderChannels(t,e){if(t.length===0)return Le.nothing;let r=new Map(e.map(s=>[String(s.id??""),s.name??""])),a=s=>r.get(s)||T(s);return Le.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>${t.map(s=>Le.html`<tr><td>${s.name??""}</td><td class="gates">${s.gateA}-${s.gateB}</td><td>${(s.centers??[]).map(a).join(" to ")}</td><td>${s.circuit??""}</td><td>${s.dynamic?Le.html`<span class="dyn">${s.dynamic}</span>`:Le.nothing}</td><td class="held">${Ro(s.personAGates)}</td><td class="held">${Ro(s.personBGates)}</td></tr>`)}</tbody></table></div></section>`}renderEmpty(){return Le.html`<div class="roxy-empty" role="status">No connection data</div>`}};Lt.styles=[y,O,K,Mr,Le.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);font-variant-numeric:tabular-nums}.note{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-sm,.5rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;display:flex}.row:last-child{border-bottom:none}.cname{flex:1;min-width:8rem}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 8px;display:inline-flex}.badge.defined{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.open{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.together{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a)}.who{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{text-align:left;padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr:last-child td{border-bottom:none}.gates{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.dyn{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);color:var(--roxy-fg,#0a0a0a);padding:1px 8px;display:inline-block}.held{font-variant-numeric:tabular-nums}.scroll{min-width:0;overflow-x:auto}`],Lt=p([(0,Co.customElement)("roxy-hd-connection")],Lt);function Qa(n){if(typeof n=="number")return n===0?"None":n===1?"1 channel":`${n} channels`}function Ro(n){let t=n??[];return t.length>0?t.join(", "):"Neither"}function Yl(n,t,e){return t&&e?"Defined in both charts":t?"Defined by A":e?"Defined by B":n?"Defined by neither alone, only by the connection":"Open in both charts"}var re=require("lit"),Ao=require("lit/decorators.js");var $t=class extends g{renderData(t){let e=t.channels??[],r=t.gates??[],a=t.summary,s=a?.gapGates??[],o=e.some(i=>i.isCore);return re.html`<div class="wrap" part="card" aria-label="Human Design penta"><header class="head" part="header"><h2 class="title">Penta</h2>${typeof t.memberCount=="number"?re.html`<span class="count">${t.memberCount} members</span>`:re.nothing}</header>${wr([{label:"Members",value:t.memberCount?.toString()},{label:"Defined channels",value:typeof a?.definedChannels=="number"&&e.length>0?`${a.definedChannels} of ${e.length}`:void 0},{label:"Filled gates",value:typeof a?.filledGates=="number"&&r.length>0?`${a.filledGates} of ${r.length}`:void 0},{label:"Core",value:typeof a?.coreDefined=="boolean"?a.coreDefined?"Defined":"Open":void 0},{label:"Gap gates",value:s.length>0?s.join(", "):void 0}])} ${this.hideReadings?re.nothing:re.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)",e.filter(i=>i.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)",e.filter(i=>i.position==="lower"),"Lower channels run from the G Center to the Sacral. They carry the managed, generative, resource work.")} ${this.renderGroup("Channels",e.filter(i=>i.position!=="upper"&&i.position!=="lower"))} ${o&&!this.hideReadings?re.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>`:re.nothing} ${this.renderGates(r)} ${e.length>0||r.length>0?re.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>`:re.nothing}</div>`}renderGroup(t,e,r){return e.length===0?re.nothing:re.html`<div class="section" part="section channels"><h3>${t}</h3>${r&&!this.hideReadings?re.html`<p class="note">${r}</p>`:re.nothing} ${e.map(a=>re.html`<div class="row"><span class="gates">${a.gateA}-${a.gateB}</span> <span class="cname">${a.name??""} ${a.circuit?re.html`<span class="circuit">${a.circuit} circuit</span>`:re.nothing} </span><span class="badge ${a.defined?"defined":"open"}">${a.defined?"Defined":"Open"}</span> ${a.isCore?re.html`<span class="badge core">Core</span>`:re.nothing} <span class="held">Gate ${a.gateA} held by ${Fs(a.gateAHeldBy)}. Gate ${a.gateB} held by ${Fs(a.gateBHeldBy)}.</span></div>`)}</div>`}renderGates(t){if(t.length===0)return re.nothing;let e=t.filter(r=>r.filled).length;return re.html`<div class="section" part="section gates"><h3>Gates (${e} of ${t.length} filled)</h3>${this.hideReadings?re.nothing:re.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>`} ${t.map(r=>re.html`<div class="row"><span class="gate-id">${r.gate}</span> <span class="cname">${r.gateName??""}</span> ${r.filled?re.html`<span class="who">Held by ${Fs(r.heldBy)}</span>`:re.html`<span class="badge gap">Gap</span>`}</div>`)}</div>`}renderEmpty(){return re.html`<div class="roxy-empty" role="status">No penta data</div>`}};$t.styles=[y,Mr,re.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600)}.section{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.section h3{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.note{margin:var(--roxy-space-xs,.25rem) 0 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-sm,.5rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;display:flex}.row:last-child{border-bottom:none}.gates,.gate-id{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600);min-width:3.5rem}.cname{flex:1;min-width:8rem}.circuit{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);display:block}.held{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);flex-basis:100%;line-height:1.6}.who{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 8px;display:inline-flex}.badge.defined{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.open{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.core{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.gap{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.footnote{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0;line-height:1.6}`],$t=p([(0,Ao.customElement)("roxy-hd-penta")],$t);var Ul="ABCDE";function Fs(n){let t=(n??[]).map(e=>Ul[e]??String(e+1));return t.length>0?t.join(", "):"nobody"}var Je=require("lit"),Do=require("lit/decorators.js");var wt=class extends g{renderEmpty(){return Je.html`<div class="roxy-empty" role="status">${this.t("No Human Design data")}</div>`}renderData(t){return Wl(t)?this.renderType(t):this.renderProfile(t)}renderType(t){return Je.html`<div class="wrap" part="card"><header class="head" part="header"><h2 class="title">${this.t("Type")}</h2>${t.type||t.profile?Je.html`<div class="type-line">${[b(t,"type"),t.profile?this.t("Profile {{profile}}",{profile:t.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:Je.nothing}</header>${wr([{label:this.t("Type"),value:b(t,"type")},{label:this.t("Strategy"),value:b(t,"strategy")},{label:this.t("Authority"),value:b(t,"authority")},{label:this.t("Profile"),value:t.profile}])} ${t.typeDescription&&!this.hideReadings?Je.html`<p class="lead">${t.typeDescription}</p>`:Je.nothing} ${za(t.signature?b(t,"signature"):void 0,t.notSelf?b(t,"notSelf"):void 0,this.translator)} ${this.renderInterpretation([{label:this.t("Strategy"),aside:b(t,"strategy"),body:t.strategyDescription},{label:this.t("Authority"),aside:b(t,"authority"),body:t.authorityDescription},{label:this.t("Aura"),body:t.aura}],"hd-type-reading")}</div>`}renderProfile(t){return Je.html`<div class="wrap" part="card"><header class="head" part="header"><h2 class="title">${this.t("Profile")}</h2>${t.profile?Je.html`<div class="type-line">${t.profile}</div>`:Je.nothing}</header>${wr([{label:this.t("Profile"),value:t.profile},{label:this.t("Personality line"),value:t.personalityLine?.toString()},{label:this.t("Design line"),value:t.designLine?.toString()}])} ${this.hideReadings?Je.nothing:Je.html`<section class="block" part="section lines"><h3>${this.t("Lines")}</h3>${Ea({personality:t.personalityKeynote,personalityLine:t.personalityLine,design:t.designKeynote,designLine:t.designLine},this.translator)}</section>`}</div>`}};wt.styles=[y,O,K,Mr,Je.css`.wrap{background:var(--roxy-surface,#fff);width:100%;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.type-line{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}`],wt=p([(0,Do.customElement)("roxy-hd-type-card")],wt);function Wl(n){return typeof n.type=="string"}var Q=require("lit"),zo=require("lit/decorators.js");var kt=class extends g{renderData(t){let e=[...t.arrows??[]].sort((r,a)=>To(r.position)-To(a.position));return Q.html`<div class="wrap" part="card" aria-label="${this.t("Human Design variables")}"><h2 class="title" part="header">${this.t("Variables")}</h2><div class="grid" part="details arrows">${e.map(r=>this.renderArrow(r))}</div>${t.confident===!1?Q.html`<p class="note" role="note">${typeof t.confidenceMarginDeg=="number"?this.t("Low confidence: a birth time near a color or tone boundary (within {{margin}}\xB0). Verify the exact birth time.",{margin:t.confidenceMarginDeg}):this.t("Low confidence: a birth time near a color or tone boundary. Verify the exact birth time.")}</p>`:Q.nothing} ${this.renderReading(e,t.baseDescription)}</div>`}renderArrow(t){let e=t.direction==="left"?"\u2190":"\u2192",r=b(t,"baseName");return Q.html`<div class="arrow"><div class="arrow-head"><span class="glyph" aria-hidden="true">${e}</span> <span class="name">${b(t,"name")}</span></div>${t.layer?Q.html`<span class="layer">${b(t,"layer")}</span>`:Q.nothing} <span class="labels">${[b(t,"directionLabel"),b(t,"colorLabel")].filter(Boolean).join(" \xB7 ")} </span>${typeof t.color=="number"?Q.html`<span class="ctb">${this.t("Color {{color}} \xB7 Tone {{tone}} \xB7 Base {{base}}",{color:t.color,tone:t.tone??"",base:t.base??""})}${r?`, ${r}`:""}</span>`:Q.nothing} ${t.activation?.planet?Q.html`<span class="ctb">${[t.activation.planet,Ta(t.activation.side,this.translator)].filter(Boolean).join(" \xB7 ")}</span>`:Q.nothing} ${t.confident===!1?Q.html`<span class="note" role="note">${this.t("Knife-edge: could flip with a more precise birth time.")}</span>`:Q.nothing}</div>`}renderReading(t,e){let r=t.filter(o=>o.description||o.colorMeaning);if(r.length===0||this.hideReadings)return Q.nothing;let a=new Map;for(let o of r){let i=o.layer??"",l=a.get(i);l?l.push(o):a.set(i,[o])}let s=0;return Q.html`<section class="block" part="section readings"><h3>${this.t("Reading")}</h3>${[...a].map(([o,i])=>Q.html`<div class="group">${o?Q.html`<p class="group-head">${b(i[0],"layer")}</p>`:Q.nothing} ${i[0]?.layerDescription?Q.html`<p class="group-note">${i[0].layerDescription}</p>`:Q.nothing} ${i.map(l=>this.renderArrowReading(l,s++===0))}</div>`)} ${e?Q.html`<p class="footnote">${this.t("Base")}. ${e}</p>`:Q.nothing}</section>`}renderArrowReading(t,e){let r=t.cognition,a=r?b(r,"label"):"",s=[{label:this.t("Color"),body:t.colorMeaning},{label:this.t("Tone"),body:t.toneMeaning},{label:this.t("Direction"),body:t.directionMeaning},{label:a?`${this.t("Cognition")} \xB7 ${a}`:this.t("Cognition"),body:r?.description}].filter(o=>!!o.body);return Q.html`<details class="interp-card" part="reading" name="hd-variable" ?open="${e}"><summary><span class="interp-lead">${b(t,"name")}</span> ${te()} ${t.position?Q.html`<span class="interp-aside"><small>${b(t,"position")}</small></span>`:Q.nothing}</summary><div class="interp-body">${t.description?Q.html`<p>${t.description}</p>`:Q.nothing} ${s.length>0?Q.html`<dl class="facets">${s.map(o=>Q.html`<dt>${o.label}</dt><dd>${o.body}</dd>`)}</dl>`:Q.nothing}</div></details>`}renderEmpty(){return Q.html`<div class="roxy-empty" role="status">${this.t("No variables data")}</div>`}};kt.styles=[y,O,K,Q.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.arrow{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-xs,.25rem);align-content:start;display:grid}.arrow-head{align-items:center;gap:var(--roxy-space-sm,.5rem);display:flex}.glyph{color:var(--roxy-accent-ink,#b45309);font-size:1.75rem;line-height:1}.name{font-weight:var(--roxy-weight-bold,600)}.layer{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.labels{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.ctb{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums}.note{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-warning-fg,#9a3412)}@container (width<=28rem){.grid{grid-template-columns:minmax(0,1fr)}}.group{margin-bottom:var(--roxy-space-md,1rem)}.group:last-of-type{margin-bottom:0}.group-head{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.group-note{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.facets{gap:var(--roxy-space-xs,.25rem);margin:0;display:grid}.facets dt{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.facets dd{margin:0}.footnote{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0;line-height:1.6}`],kt=p([(0,zo.customElement)("roxy-hd-variables")],kt);function To(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 qe=require("lit"),Eo=require("lit/decorators.js");var Jl={udaya:"Rose",asta:"Set"},Xl={udaya:"rises",asta:"sets"},St=class extends g{renderEmpty(){return qe.html`<div class="roxy-empty" role="status">No heliacal data</div>`}renderData(t){let e=t.grahas??[];return e.length?qe.html`<div class="wrap" aria-label="Heliacal visibility"><header class="head"><h2 class="title">Heliacal rising and setting</h2><p class="sub">Whether each graha stands far enough from the Sun to be seen, for ${t.date}. The Sun and the nodes never appear here: they have no heliacal event.</p></header><div class="rows">${e.map(r=>this.renderGraha(r))}</div></div>`:this.renderEmpty()}renderGraha(t){let e=k(t.graha)??"";return qe.html`<article class="row"><div class="row-top"><span class="graha">${e?qe.html`<span class="glyph">${e}</span>`:qe.nothing}${t.graha} </span><span class="state ${t.visible?"visible":"invisible"}">${t.visible?"Visible":"Invisible"} </span>${t.retrograde?qe.html`<span class="retro" title="retrograde">R</span>`:qe.nothing}</div><p class="window">${this.windowLine(t)}</p><p class="meta">${this.metaLine(t)}</p></article>`}windowLine(t){let e=t.nextEvent,r=t.lastEvent;if(e){let a=Xl[e.type],s=e.horizon==="east"?"in the east":"in the west";return qe.html`${t.visible?"Visible until it":"Invisible until it"} ${a} ${s} on <strong>${Oe(this.effectiveLang(),e.datetime)}</strong>`}return r?qe.html`${Jl[r.type]} ${r.horizon==="east"?"in the east":"in the west"} on <strong>${Oe(this.effectiveLang(),r.datetime)}</strong>, with no further event inside the search window`:qe.html`No rising or setting inside the search window, which is normal for a graha far from the Sun`}metaLine(t){let e=t.horizon==="east"?"a morning graha, read before sunrise":"an evening graha, read after sunset",r=t.nextEvent??t.lastEvent,a=r&&r.kalamsa!==t.kalamsa;return qe.html`<span class="num">${x(t.timeDegrees,2)}°</span> of time from the Sun against a limit of <span class="num">${x(t.kalamsa,0)}°</span>${a?qe.html`, becoming <span class="num">${x(r.kalamsa,0)}°</span> at that event`:""} · ${e}`}};St.styles=[y,qe.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sub{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:0}.rows{display:grid}.row{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.35em}.state{font-size:var(--roxy-text-xs,.75rem);border-radius:var(--roxy-radius-sm,4px);border:1px solid var(--roxy-border,#e4e4e7);color:var(--roxy-fg,#0a0a0a);padding:.1rem .45rem}.state.invisible{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 14%, transparent)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600)}.window{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.num{font-variant-numeric:tabular-nums}`],St=p([(0,Eo.customElement)("roxy-heliacal-table")],St);var J=require("lit"),Mo=require("lit/decorators.js");var Rt=class extends g{resolveHexagram(){let t=this.data;if(!t)return null;if("hexagram"in t&&t.hexagram){if("lines"in t){let r=t;return{hex:r.hexagram,lines:r.lines,changingLinePositions:r.changingLinePositions,resultingHexagram:r.resultingHexagram}}let e=t;return{hex:e.hexagram,dailyMessage:e.dailyMessage}}return{hex:t}}renderEmpty(){return J.html`<div class="roxy-empty" role="status">No hexagram data</div>`}renderData(){let t=this.resolveHexagram();if(!t)return this.renderEmpty();let{hex:e,lines:r,changingLinePositions:a,dailyMessage:s,resultingHexagram:o}=t,i=r??this.derivedLines(e),l=new Set(a??[]),d=!this.hideReadings;return J.html`<article class="card" part="card" aria-label="I Ching hexagram"><div class="glyphs" part="chart">${e.symbol?J.html`<div class="symbol">${e.symbol}</div>`:J.nothing}<div class="lines" aria-hidden="true">${i.slice().reverse().map((m,c)=>{let u=i.length-1-c+1,z=l.has(u),$=m===6||m===8;return J.html`<div class="line ${`${$?"broken":"solid"}${z?" changing":""}`}">${$?J.svg`<span class="seg"></span><span class="seg"></span>`:J.svg`<span class="seg"></span>`}</div>`})}</div></div><div part="header"><h2 class="title">${[e.number!=null?`${e.number}.`:"",e.english??e.chinese??"Hexagram"].filter(Boolean).join(" ")}</h2><p class="subtitle">${e.chinese?J.html`${e.chinese}`:J.nothing} ${e.pinyin?J.html`· ${e.pinyin}`:J.nothing}</p><div class="trigrams" part="details">${e.upperTrigram?J.html`<div>Upper <span class="tri-glyph">${xs(e.upperTrigram)??""}</span>${e.upperTrigram}</div>`:J.nothing} ${e.lowerTrigram?J.html`<div>Lower <span class="tri-glyph">${xs(e.lowerTrigram)??""}</span>${e.lowerTrigram}</div>`:J.nothing}</div>${e.judgment&&d?J.html`<p class="judgment">${e.judgment}</p>`:J.nothing} ${e.image&&d?J.html`<p class="image">${e.image}</p>`:J.nothing} ${s&&d?J.html`<p class="message">${s}</p>`:J.nothing} ${e.interpretation?.general&&d?J.html`<p>${e.interpretation.general}</p>`:J.nothing} ${l.size>0?J.html`<div class="changing" part="section changing-lines">Changing lines: ${Array.from(l).sort((m,c)=>m-c).join(", ")}. ${o?.english?J.html`Becomes hexagram ${o.number} ${o.english}.`:J.nothing}</div>`:J.nothing} ${this.renderLines(e,l)}</div></article>`}renderLines(t,e){let r=t.changingLines??[];if(r.length===0)return J.nothing;let a=e.size>0,s=a?r.filter(i=>e.has(i.position)):r;if(s.length===0)return J.nothing;let o=s.map(i=>({label:`Line ${i.position}`,body:i.text??"",extra:i.meaning?J.html`<p class="line-meaning">${i.meaning}</p>`:J.nothing}));return this.renderInterpretation(o,"hexagram-lines",a?"Changing lines":"Lines")}derivedLines(t){let e=t.binary??"";return/^[01]{6}$/.test(e)?Array.from(e,r=>r==="1"?7:8):Array.from({length:6},()=>7)}};Rt.styles=[y,O,K,J.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-lg,1.5rem);grid-template-columns:6rem 1fr;display:grid}@container (width<=480px){.card{grid-template-columns:1fr}}.glyphs{gap:var(--roxy-space-md,1rem);align-content:start;align-self:start;justify-items:center;display:grid}.symbol{color:var(--roxy-accent-ink,#b45309);font-size:3rem;line-height:1}.lines{gap:4px;width:4rem;display:grid}.line{justify-content:center;align-items:center;gap:4px;height:8px;display:flex}.seg{background:var(--roxy-fg,#0a0a0a);border-radius:1px;height:6px;display:block}.line.broken .seg{width:1.4rem}.line.solid .seg{width:3rem}.line.changing .seg{background:var(--roxy-accent,#f59e0b)}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0 0 var(--roxy-space-sm,.5rem)}.trigrams{gap:var(--roxy-space-md,1rem);margin-bottom:var(--roxy-space-sm,.5rem);color:var(--roxy-secondary,#475569);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;display:flex}.tri-glyph{font-size:var(--roxy-text-xl,1.5rem);color:var(--roxy-accent-ink,#b45309);vertical-align:middle;margin-right:4px}.judgment,.image,.message{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.judgment:before{content:"Judgment. ";font-weight:var(--roxy-weight-bold,600);color:var(--roxy-secondary,#475569)}.image:before{content:"Image. ";font-weight:var(--roxy-weight-bold,600);color:var(--roxy-secondary,#475569)}.line-meaning{padding-left:var(--roxy-space-sm,.5rem);border-left:2px solid var(--roxy-border,#e4e4e7);color:var(--roxy-muted,#71717a);margin:0}.changing{margin-top:var(--roxy-space-md,1rem);padding-top:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem)}`],Rt=p([(0,Mo.customElement)("roxy-hexagram")],Rt);var nr=require("lit"),Po=require("lit/decorators.js");var Ct=class extends g{renderEmpty(){return nr.html`<div class="roxy-empty" role="status">No hora data</div>`}renderData(t){let e=t.dayHoras??[],r=t.nightHoras??[];return e.length===0&&r.length===0?this.renderEmpty():nr.html`<div class="wrap" aria-label="Hora periods"><div class="head"><h2 class="title">Hora</h2>${t.date?nr.html`<p class="subtitle">${D(this.effectiveLang(),t.date)}</p>`:nr.nothing}</div><div class="cols">${this.renderColumn("Day",e)} ${this.renderColumn("Night",r)}</div></div>`}renderColumn(t,e){return e.length===0?nr.nothing:nr.html`<div class="col"><p class="section-label">${t}</p>${e.map(r=>nr.html`<div class="row"><span class="glyph" aria-hidden="true">${k(r.planet)??"\xB7"}</span> <span class="planet">${r.planet}</span> <span class="time">${Tr(this.effectiveLang(),r)}</span> ${typeof r.number=="number"?nr.html`<span class="num">${r.number}</span>`:nr.nothing}</div>`)}</div>`}};Ct.styles=[y,nr.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.cols{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.section-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin:0 0 var(--roxy-space-xs,.25rem) 0}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-xs,.25rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);display:flex}.row:last-child{border-bottom:none}.glyph{color:var(--roxy-accent-ink,#b45309);text-align:center;width:1.25em;font-size:1.15em;line-height:1}.planet{flex:1;font-weight:500}.time{color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums;white-space:nowrap}.num{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;text-align:right;width:1.5em}@container (width<=30rem){.cols{grid-template-columns:1fr}}`],Ct=p([(0,Po.customElement)("roxy-hora-table")],Ct);var C=require("lit"),es=require("lit/decorators.js");var Hr=class extends g{constructor(){super(...arguments);this.period="daily"}renderEmpty(){return C.html`<div class="roxy-empty" role="status">No horoscope data</div>`}renderData(e){let r=e.sign??"",a=q(r)??"",s="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,o="date"in e&&e.date&&D(this.effectiveLang(),e.date)||"week"in e&&e.week||"month"in e&&e.month||"";return C.html`<article class="card" part="card" aria-label="${`${this.period} horoscope for ${r}`}"><header class="head" part="header"><span class="glyph" aria-hidden="true">${a}</span><div><h2 class="title">${r} ${this.period}</h2>${o?C.html`<div class="date">${o}</div>`:C.nothing}</div>${s!==null?C.html`<span class="energy" part="details" aria-label="${`Energy ${s} of 10`}">Energy ${s}/10 <span class="energy-bar"><span style="width:${s/10*100}%"></span></span></span>`:C.nothing}</header>${e.overview&&!this.hideReadings?C.html`<p class="overview">${e.overview}</p>`:C.nothing} ${this.renderSky(e)} ${this.hideReadings?C.nothing:C.html`<div class="sections" part="section outlook">${e.love?C.html`<div class="section"><h3>Love</h3><p>${e.love}</p></div>`:C.nothing} ${e.career?C.html`<div class="section"><h3>Career</h3><p>${e.career}</p></div>`:C.nothing} ${e.health?C.html`<div class="section"><h3>Health</h3><p>${e.health}</p></div>`:C.nothing} ${e.finance?C.html`<div class="section"><h3>Finance</h3><p>${e.finance}</p></div>`:C.nothing} ${"advice"in e&&e.advice?C.html`<div class="section"><h3>Advice</h3><p>${e.advice}</p></div>`:C.nothing}</div>`} ${this.renderMonth(e)} ${(()=>{let i="luckyNumber"in e&&e.luckyNumber!==void 0?e.luckyNumber:void 0,l="luckyColor"in e&&e.luckyColor?e.luckyColor:"",d="luckyNumbers"in e&&e.luckyNumbers?e.luckyNumbers:[],m="luckyDays"in e&&e.luckyDays?e.luckyDays:[],c=e.compatibleSigns??[];return i===void 0&&!l&&d.length===0&&m.length===0&&c.length===0?C.nothing:C.html`<div class="lucky" part="details">${i!==void 0?C.html`<span>Lucky number <strong>${i}</strong></span>`:C.nothing} ${l?C.html`<span>Lucky color <strong>${l}</strong></span>`:C.nothing} ${d.length?C.html`<span>Lucky numbers <strong>${d.join(", ")}</strong></span>`:C.nothing} ${m.length?C.html`<span>Lucky days <strong>${m.join(", ")}</strong></span>`:C.nothing} ${c.length?C.html`<span class="compat-wrap">Best with <span class="compat">${c.map(u=>C.html`<span>${u}</span>`)}</span></span>`:C.nothing}</div>`})()}</article>`}renderSky(e){let r="moonSign"in e?e.moonSign:"",a="moonPhase"in e?e.moonPhase:"",s=("activeTransits"in e?e.activeTransits:[])??[];if(!r&&!a&&s.length===0)return C.nothing;let o=q(r)??"";return C.html`<div class="sky" part="section sky">${r||a?C.html`<div class="moon-line">${r?C.html`<span><span class="lbl">Moon</span> <span aria-hidden="true">${o}</span> <b>${r}</b></span>`:C.nothing} ${a?C.html`<span><span class="lbl">Phase</span> <b>${a}</b></span>`:C.nothing}</div>`:C.nothing} ${s.length?C.html`<ul class="transits" aria-label="Active transits">${s.map(i=>C.html`<li>${i}</li>`)}</ul>`:C.nothing}</div>`}renderMonth(e){let r=("weekByWeek"in e?e.weekByWeek:[])??[],a=("keyDates"in e?e.keyDates:[])??[];return r.length===0&&a.length===0?C.nothing:C.html`${r.length&&!this.hideReadings?C.html`<section part="section week-by-week"><h3 class="block-title">Week by week</h3><div class="weeks">${r.map(s=>C.html`<div class="week"><span class="week-no">Week ${s.week}</span><div><div class="week-focus">${s.focus}</div>${s.advice?C.html`<p class="week-advice">${s.advice}</p>`:C.nothing}</div></div>`)}</div></section>`:C.nothing} ${a.length?C.html`<section part="section key-dates"><h3 class="block-title">Key dates</h3><dl class="dates">${a.map(s=>C.html`<div class="date-row"><dt>${D(this.effectiveLang(),s.date)||s.date}</dt><dd>${s.event}</dd></div>`)}</dl></section>`:C.nothing}`}};Hr.styles=[y,C.css`.card{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md,1rem);display:flex}.glyph{color:var(--roxy-accent-ink,#b45309);font-size:2.25rem;line-height:1}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);text-transform:capitalize;margin:0}.date{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a)}.energy{font-variant-numeric:tabular-nums;font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569);margin-left:auto}.energy-bar{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);vertical-align:middle;width:6rem;height:6px;margin-left:6px;display:inline-block;overflow:hidden}.energy-bar>span{background:var(--roxy-accent,#f59e0b);height:100%;transition:width var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.overview{font-size:var(--roxy-text-base,1rem);color:var(--roxy-fg,#0a0a0a);margin:0}.sections{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.section h3{margin:0 0 var(--roxy-space-xs,.25rem) 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em}.section p{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.lucky{gap:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569);flex-wrap:wrap;display:flex}.lucky strong{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}.compat-wrap{align-items:center;gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;width:100%;display:flex}.compat{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.compat span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);text-transform:capitalize;padding:2px 8px}.sky{gap:var(--roxy-space-sm,.5rem);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);display:grid}.moon-line{align-items:baseline;gap:.35rem var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;display:flex}.moon-line b{font-weight:var(--roxy-weight-bold,600)}.moon-line .lbl{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin-right:.35rem}.transits{gap:.25rem;margin:0;padding:0;list-style:none;display:grid}.transits li{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);padding-left:.9rem;position:relative}.transits li:before{content:"";background:var(--roxy-accent,#f59e0b);border-radius:50%;width:5px;height:5px;position:absolute;top:.5em;left:0}.block-title{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em}.weeks{gap:var(--roxy-space-sm,.5rem);display:grid}.week{gap:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-sm,.5rem);grid-template-columns:3.5rem 1fr;align-items:baseline;display:grid}.week:first-child{border-top:0;padding-top:0}.week-no{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.week-focus{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem)}.week-advice{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:.15rem 0 0}.dates{gap:.3rem var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);grid-template-columns:max-content 1fr;margin:0;display:grid}.date-row{display:contents}.date-row dt{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600);white-space:nowrap}.date-row dd{color:var(--roxy-fg,#0a0a0a);margin:0}`],p([(0,es.property)({type:String,reflect:!0})],Hr.prototype,"period",2),Hr=p([(0,es.customElement)("roxy-horoscope-card")],Hr);var N=require("lit"),ts=require("lit/decorators.js");var Ql=[{id:"planets",label:"Planets"},{id:"cusps",label:"Cusps"},{id:"significators",label:"Significators"}],rs=[1,2,3,4];function _s(n,t){return n?typeof t=="number"?`${n} ${t}`:n:""}function No(n){return[...new Set(n.map(String))].join(" > ")}function ed(n){return[...new Set(n??[])]}var jr=class extends g{constructor(){super(...arguments);this.activeTab="planets"}bodies(){let e=this.data;if(!e)return[];let r=(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})),a=e.nodes;for(let[s,o]of[["Rahu",a?.rahu],["Ketu",a?.ketu]])o&&r.push({name:s,longitude:o.longitude,house:o.house,nakshatra:o.nakshatra,starLord:o.starLord,subLord:o.subLord,subSubLord:o.subSubLord,kpNumber:o.kpNumber,retrograde:!0});return r}renderEmpty(){return N.html`<div class="roxy-empty" role="status">No KP chart data</div>`}renderData(e){let r=e.ascendant;return N.html`<div class="wrap" aria-label="KP chart" tabindex="0"><header class="head"><h2 class="title">KP chart</h2>${r?N.html`<div class="asc">Ascendant: <strong>${typeof r.longitude=="number"?Ue(r.longitude):r.sign??""} </strong>${r.nakshatra?N.html`· ${_s(r.nakshatra,r.pada)}`:N.nothing} ${r.subLord?N.html`· sub lord ${r.subLord}`:N.nothing} ${typeof r.kpNumber=="number"?N.html`· KP ${r.kpNumber}`:N.nothing}</div>`:N.nothing} ${typeof e.meta?.ayanamsa=="number"?N.html`<div class="ayan">Ayanamsa: ${_t(e.meta.ayanamsaType,e.meta.ayanamsa)} ${e.meta.houseSystem?N.html`· ${e.meta.houseSystem} houses`:N.nothing}</div>`:N.nothing}</header>${_e({items:Ql,active:this.activeTab,onSelect:a=>{this.activeTab=a},label:"KP chart views",idPrefix:"kp",controls:!0})}<div id="kp-panel-${this.activeTab}" 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?N.html`<table role="table"><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">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(r=>N.html`<tr><td class="body">${r.name}${r.retrograde?N.html`<span class="retro">R</span>`:N.nothing}</td><td class="num">${typeof r.longitude=="number"?Ue(r.longitude):""}</td><td class="num">${typeof r.house=="number"?r.house:""}</td><td>${_s(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>`:N.html`<p class="roxy-empty" role="status">No planets</p>`}renderCusps(){let e=this.data?.cusps??[],r=this.data?.houseThemes;return e.length?N.html`<table role="table"><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(a=>N.html`<tr><td class="body num">${a.house}${this.renderThemes(ws(a.house,r))}</td><td class="num">${typeof a.longitude=="number"?Ue(a.longitude):a.sign??""}</td><td>${a.signLord??""}</td><td>${_s(a.nakshatra,a.pada)}</td><td>${a.starLord??""}</td><td>${a.subLord??""}</td><td>${a.subSubLord??""}</td><td class="num">${typeof a.kpNumber=="number"?a.kpNumber:""}</td></tr>`)}</tbody></table>`:N.html`<p class="roxy-empty" role="status">No cusps</p>`}renderSignificators(){let e=this.data?.significators,r=this.data?.houseThemes,a=e?.houseWise??[],s=e?.planetWise??[];return!a.length&&!s.length?N.html`<p class="roxy-empty" role="status">No significators</p>`:N.html`${this.renderLevelLegend(a)} ${a.length?N.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><table role="table"><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>${rs.map(o=>N.html`<th scope="col">L${o}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${a.map(o=>N.html`<tr><td class="body num">${o.house}${this.renderThemes(ws(o.house,r))}</td>${rs.map(i=>this.renderCell(this.planetsAtLevel(o,i).join(", ")))}<td class="chain">${No(o.all??[])}</td></tr>`)}</tbody></table>`:N.nothing} ${s.length?N.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><table role="table"><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>${rs.map(o=>N.html`<th scope="col">L${o}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${s.map(o=>N.html`<tr><td class="body">${o.planet}</td>${rs.map(i=>this.renderCell(this.housesAtLevel(o,i).join(", ")))}<td class="chain">${No(o.allHouses??[])}${this.renderThemes(ur(ed(o.allHouses),r))}</td></tr>`)}</tbody></table>`:N.nothing}`}renderThemes(e){return e?N.html`<span class="themes">${e}</span>`:N.nothing}renderCell(e){return e?N.html`<td>${e}</td>`:N.html`<td class="empty-cell">none</td>`}planetsAtLevel(e,r){return(e.significators??[]).filter(a=>a.level===r).flatMap(a=>a.planets??[])}housesAtLevel(e,r){return(e.signifies??[]).filter(a=>a.level===r).flatMap(a=>a.houses??[])}renderLevelLegend(e){let r=new Map;for(let a of e)for(let s of a.significators??[])s.description&&!r.has(s.level)&&r.set(s.level,s.description);return r.size===0?N.nothing:N.html`<ul class="legend" aria-label="Significator levels">${[...r.entries()].sort((a,s)=>a[0]-s[0]).map(([a,s])=>N.html`<li><b>L${a}</b>${s}</li>`)}</ul>`}};jr.styles=[y,Ee,N.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);width:100%;overflow:auto}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.asc,.ayan{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.asc strong{color:var(--roxy-fg,#0a0a0a)}.roxy-tablist{padding:0 var(--roxy-space-md,1rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:620px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}td.body{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);margin-left:4px}.num{font-variant-numeric:tabular-nums}.sig-head{padding:var(--roxy-space-md,1rem) var(--roxy-space-md,1rem) 0;gap:var(--roxy-space-xs,.25rem);display:grid}.sig-title{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sig-note{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:0}.legend{gap:var(--roxy-space-xs,.25rem) var(--roxy-space-md,1rem);padding:var(--roxy-space-md,1rem) var(--roxy-space-md,1rem) 0;color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);flex-wrap:wrap;margin:0;list-style:none;display:flex}.legend b{color:var(--roxy-accent-ink,#b45309);margin-right:4px}.chain,.empty-cell{color:var(--roxy-muted,#71717a)}.themes{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-normal,400);text-transform:none;letter-spacing:normal;display:block}`],p([(0,ts.state)()],jr.prototype,"activeTab",2),jr=p([(0,ts.customElement)("roxy-kp-chart")],jr);var gr=require("lit"),Go=require("lit/decorators.js");var At=class extends g{renderEmpty(){return gr.html`<div class="roxy-empty" role="status">No KP data</div>`}renderData(t){let e=t.planets??[];return gr.html`<div class="wrap" aria-label="KP planets table" tabindex="0"><header class="head"><h2 class="title">KP planets</h2>${typeof t.ayanamsa=="number"?gr.html`<span class="ayanamsa">Ayanamsa: ${x(t.ayanamsa,2)}°</span>`:gr.nothing}</header><table role="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(r=>gr.html`<tr><td class="planet">${r.planet} ${r.retrograde?gr.html`<span class="retro">R</span>`:gr.nothing}</td><td>${r.sign??""}</td><td>${r.signLord??""}</td><td>${r.nakshatra??""}</td><td>${r.nakshatraLord??""}</td><td>${r.subLord??""}</td><td>${r.subSubLord??""}</td><td>${r.kpNumber??""}</td></tr>`)}</tbody></table></div>`}};At.styles=[y,gr.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:auto}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);justify-content:space-between;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.ayanamsa{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:560px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}td.planet{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);margin-left:4px}`],At=p([(0,Go.customElement)("roxy-kp-planets-table")],At);var Ve=require("lit"),Bo=require("lit/decorators.js");var Dt=class extends g{renderEmpty(){return Ve.html`<div class="roxy-empty" role="status">No ruling planets data</div>`}renderData(t){let e=t.significators??[];return Ve.html`<div class="wrap" aria-label="KP ruling planets"><header><h2 class="title">KP ruling planets</h2>${t.dayLord?Ve.html`<div class="day-lord">Day lord: <strong>${t.dayLord}</strong></div>`:Ve.nothing}</header><div class="groups"><div class="group"><h3>Moon</h3><dl><dt>Sign lord</dt><dd>${t.moonSignLord??""}</dd><dt>Star lord</dt><dd>${t.moonStarLord??""}</dd><dt>Sub lord</dt><dd>${t.moonSublord??""}</dd><dt>Sub-sub lord</dt><dd>${t.moonSubSublord??""}</dd></dl></div><div class="group"><h3>Lagna</h3><dl><dt>Sign lord</dt><dd>${t.lagnaSignLord??""}</dd><dt>Star lord</dt><dd>${t.lagnaStarLord??""}</dd><dt>Sub lord</dt><dd>${t.lagnaSublord??""}</dd><dt>Sub-sub lord</dt><dd>${t.lagnaSubSublord??""}</dd></dl></div></div>${t.rulingPlanets?.length?Ve.html`<div class="rp-list" role="list" aria-label="Ruling planets by strength"><span class="rp-label">Ruling planets</span> ${t.rulingPlanets.map((r,a)=>Ve.html`<span class="rp" role="listitem"><span class="rank">${a+1}</span> ${r}</span>`)}</div>`:Ve.nothing} ${e.length?Ve.html`<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(r=>{let a=ur(r.signifies,t.houseThemes);return Ve.html`<tr><td>${r.planet}</td><td><span class="num">${(r.signifies??[]).join(", ")}</span> ${a?Ve.html`<span class="themes">${a}</span>`:Ve.nothing}</td></tr>`})}</tbody></table>`:Ve.nothing}</div>`}};Dt.styles=[y,Ve.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-md,1rem);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.day-lord{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.day-lord strong{color:var(--roxy-fg,#0a0a0a)}.groups{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));display:grid}.group h3{margin:0 0 var(--roxy-space-xs,.25rem);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.group dl{gap:2px var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);grid-template-columns:auto 1fr;margin:0;display:grid}.group dt{color:var(--roxy-muted,#71717a)}.group dd{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600);margin:0}.rp-list{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;align-items:center;display:flex}.rp-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em;margin-right:var(--roxy-space-xs,.25rem)}.rp{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:999px;align-items:center;gap:.3em;padding:.15em .6em;display:inline-flex}.rp .rank{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-accent-ink,#b45309)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-xs,.25rem) var(--roxy-space-sm,.5rem);text-align:left;border-bottom:1px solid var(--roxy-border,#e4e4e7)}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}.num{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);display:block}`],Dt=p([(0,Bo.customElement)("roxy-kp-ruling-planets")],Dt);var $e=require("lit"),Oo=require("lit/decorators.js");var Ks=320,cr=Ks/2,Cr=128,rd=118,td=140,ad=150;function Ar(n,t){let e=n*Math.PI/180;return{x:cr+t*Math.sin(e),y:cr-t*Math.cos(e)}}var sd=[{az:0,label:"N"},{az:45,label:"NE"},{az:90,label:"E"},{az:135,label:"SE"},{az:180,label:"S"},{az:225,label:"SW"},{az:270,label:"W"},{az:315,label:"NW"}],Tt=class extends g{renderEmpty(){return $e.html`<div class="roxy-empty" role="status">No local space data</div>`}renderData(t){let e=t.bodies??[],r=t.birthDetails;return $e.html`<div class="wrap"><header><h2 class="title">Local space</h2>${r?$e.html`<div class="meta">${Oe(this.effectiveLang(),r.date,r.time)}</div>`:$e.nothing}</header>${this.renderDial(e)} ${t.summary?$e.html`<p class="summary">${t.summary}</p>`:$e.nothing} ${this.renderList(e)}</div>`}renderDial(t){return $e.html`<svg viewBox="0 0 ${Ks} ${Ks}" role="img" aria-label="Local space compass of planetary directions from the birthplace"><title>Local space compass</title><desc>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="${cr}" cy="${cr}" r="${Cr}"/><circle class="dial" cx="${cr}" cy="${cr}" r="${Cr*.66}" stroke-width="0.5"/><circle class="dial" cx="${cr}" cy="${cr}" r="${Cr*.33}" stroke-width="0.5"/>${this.renderCompassRing()} ${this.renderSpokes(t)}<circle class="center-dot" cx="${cr}" cy="${cr}" r="2.5"/></svg>`}renderCompassRing(){let t=[];for(let i=0;i<360;i+=22.5){let l=Ar(i,Cr),d=Ar(i,Cr-(i%45===0?8:4));t.push($e.svg`<line class="tick" x1=${d.x} y1=${d.y} x2=${l.x} y2=${l.y} />`)}let e=Ar(0,Cr),r=Ar(180,Cr),a=Ar(90,Cr),s=Ar(270,Cr),o=sd.map(({az:i,label:l})=>{let d=Ar(i,ad),m=i%90===0;return $e.svg`<text class=${`compass-label${m?" cardinal":""}`} x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${l}</text>`});return $e.svg`
|
|
82
|
+
`}function _a(n,t){switch(t){case"north":return Al(n);case"east":return Ml(n);default:return wl(n)}}function Ka(n,t){return _e({items:yl,active:n,onSelect:t,label:"Kundli style",idPrefix:"kundli",controls:!0})}var mo=require("lit"),qa=mo.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);display:grid}.header{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.line{fill:#0000;stroke:var(--roxy-border,#d4d4d8)}.sign-text{fill:var(--roxy-muted,#71717a);font-size:11px;font-weight:500;font-family:var(--roxy-font-sans);text-transform:uppercase;letter-spacing:.04em}.rashi-num{fill:var(--roxy-muted,#71717a);font-size:12px;font-weight:500;font-family:var(--roxy-font-sans)}.house-num{fill:var(--roxy-accent-ink,#b45309);font-size:11px;font-weight:600;font-family:var(--roxy-font-sans);opacity:.85}.planet-text{fill:var(--roxy-fg,#0a0a0a);font-size:13px;font-weight:600;font-family:var(--roxy-font-sans)}.centre-label{fill:var(--roxy-muted,#71717a);font-size:14px;font-weight:600;font-family:var(--roxy-font-sans);letter-spacing:.02em}.lagna-marker{fill:var(--roxy-accent-ink,#b45309);font-size:10px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.08em;text-transform:uppercase}.lagna-bg{fill:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent)}.lagna-slash{stroke:var(--roxy-accent,#f59e0b);stroke-linecap:round;opacity:.7}`;var Or=class extends g{constructor(){super(...arguments);this.chartStyle="north";this.setStyle=e=>{this.chartStyle=e}}viewModel(){if(!this.data?.chart?.meta)return null;let{division:e}=this.data,r=`D${e.number} ${e.name}`;return Fa(this.data.chart.meta,r)}renderEmpty(){return sr.html`<div class="roxy-empty" role="status">No divisional chart data</div>`}renderData(e){let r=this.viewModel();if(!r)return this.renderEmpty();let{division:a,vargottama:s}=e;return sr.html`<div class="wrap"><div class="header"><div><h2 class="title">D${a.number} ${a.name} ${$s(a.name,a.sanskritName)?sr.html`<span class="division-meta">· ${a.sanskritName}</span>`:sr.nothing}</h2>${a.significance?sr.html`<p class="significance">${a.significance}</p>`:sr.nothing} ${ce(e.frame)}</div>${Ka(this.chartStyle,this.setStyle)}</div><div id="kundli-panel-${this.chartStyle}" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}"><svg viewBox="0 0 400 400" preserveAspectRatio="xMidYMid meet" role="img" aria-label="D${a.number} ${a.name} divisional chart with twelve sign houses"><title>D${a.number} ${a.name}</title>${_a(r,this.chartStyle)}</svg></div>${s&&s.length>0?sr.html`<div class="vargottama-row" role="list" aria-label="Vargottama planets"><span class="vargottama-label">Vargottama:</span> ${s.map(o=>sr.html`<span class="vargottama-pill" role="listitem">${k(o)??""} ${o}</span>`)}</div>`:sr.nothing}</div>`}};Or.styles=[y,de,qa,Ee,sr.css`.division-meta{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);margin:0}.significance{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);border-left:2px solid var(--roxy-border,#e4e4e7);padding-left:var(--roxy-space-sm,.5rem);margin:0}.vargottama-row{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;align-items:center;display:flex}.vargottama-label{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);margin-right:var(--roxy-space-xs,.25rem);font-weight:500}.vargottama-pill{font-size:var(--roxy-text-sm,.875rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 22%, transparent);color:var(--roxy-fg,#0a0a0a);border:1px solid color-mix(in srgb, var(--roxy-accent,#f59e0b) 45%, transparent);border-radius:999px;align-items:center;gap:.2em;padding:.15em .6em;font-weight:600;display:inline-flex}`],p([(0,Va.property)({type:String,reflect:!0,attribute:"chart-style"})],Or.prototype,"chartStyle",2),Or=p([(0,Va.customElement)("roxy-divisional-chart")],Or);var ye=require("lit"),Za=require("lit/decorators.js");var Pl={manglik:"Mangal Dosha",kalsarpa:"Kaal Sarp Dosha",sadhesati:"Sade Sati"},Ir=class extends g{constructor(){super(...arguments);this.type="manglik"}renderEmpty(){return ye.html`<div class="roxy-empty" role="status">No dosha data</div>`}renderData(e){let r=!!e.present,a=Pl[this.type]??this.type,s=(e.severity??"").toLowerCase(),o=s==="severe"?3:s==="moderate"?2:s==="mild"?1:0,i=o*33,l=o===3?"var(--roxy-danger)":o>=1?"var(--roxy-warning)":"transparent";return ye.html`<article class="card" part="card" aria-label="${a}"><header class="head" part="header"><h2 class="title">${a}</h2><span class="${`badge ${r?"present":"absent"}`}">${r?"Present":"Absent"} </span>${ce(e.frame)}</header>${"type"in e&&e.type?ye.html`<p class="subtype"><span class="subtype-label">${this.type==="sadhesati"?"Current phase":"Type"}</span>${e.type}</p>`:ye.nothing} ${e.severity?ye.html`<div class="severity-bar" part="details" role="meter" aria-valuemin="0" aria-valuemax="3" aria-valuenow="${o}" aria-label="Severity ${e.severity}"><span class="severity-fill" style="width:${i}%;background:${l}"></span></div>`:ye.nothing} ${e.description&&!this.hideReadings?ye.html`<p class="description">${e.description}</p>`:ye.nothing} ${this.renderEffects(e)} ${e.remedies&&e.remedies.length>0&&!this.hideReadings?ye.html`<div part="section remedies"><h3>Remedies</h3><ul>${e.remedies.map(d=>ye.html`<li>${d}</li>`)}</ul></div>`:ye.nothing} ${"exceptions"in e&&e.exceptions&&e.exceptions.length>0&&!this.hideReadings?ye.html`<div part="section exceptions"><h3>Exceptions</h3><ul>${e.exceptions.map(d=>ye.html`<li>${d}</li>`)}</ul></div>`:ye.nothing}</article>`}renderEffects(e){if(!e.effects||this.hideReadings)return ye.nothing;let r=[];for(let[a,s]of Object.entries(e.effects))if(typeof s=="string"&&s.length>0)r.push(ye.html`<div><h3>${a}</h3><p>${s}</p></div>`);else if(s&&typeof s=="object")for(let[o,i]of Object.entries(s))typeof i=="string"&&i.length>0&&r.push(ye.html`<div><h3>${o}</h3><p>${i}</p></div>`);return r.length===0?ye.nothing:ye.html`<div class="effects" part="section effects">${r}</div>`}};Ir.styles=[y,de,ye.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:capitalize;margin:0}.subtype{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.subtype .subtype-label{color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-size:var(--roxy-text-xs,.75rem);margin-right:.4rem}.badge{align-items:center;gap:var(--roxy-space-xs,.25rem);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em;padding:4px 10px;display:inline-flex}.badge.absent{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.present{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.severity-bar{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 30%, transparent);border-radius:4px;width:100%;height:8px;position:relative;overflow:hidden}.severity-fill{height:100%;transition:width var(--roxy-motion-duration,.2s) ease-out;border-radius:4px;display:block}@media (prefers-reduced-motion:reduce){.severity-fill{transition:none}}.description{color:var(--roxy-fg,#0a0a0a);margin:0}h3{margin:0 0 var(--roxy-space-xs,.25rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}ul{padding-left:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);margin:0}.effects{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.effects p{font-size:var(--roxy-text-sm,.875rem);margin:0}`],p([(0,Za.property)({type:String,reflect:!0})],Ir.prototype,"type",2),Ir=p([(0,Za.customElement)("roxy-dosha-card")],Ir);var dr=require("lit"),go=require("lit/decorators.js");var ht=class extends g{renderData(t){return dr.html`<article class="card" part="card" aria-label="${t.name??"Dream symbol"}"><header class="head" part="header">${t.letter?dr.html`<span class="letter" aria-hidden="true">${t.letter}</span>`:dr.nothing}<div><p class="label">Dream symbol</p>${t.name?dr.html`<h2 class="name">${t.name}</h2>`:dr.nothing}</div></header>${t.meaning?dr.html`<p class="meaning">${t.meaning}</p>`:dr.nothing}</article>`}renderEmpty(){return dr.html`<div class="roxy-empty" role="status">No dream symbol</div>`}};ht.styles=[y,dr.css`.card{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md,1rem);display:flex}.letter{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);width:2.5rem;height:2.5rem;color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-variant-numeric:tabular-nums;flex:none;justify-content:center;align-items:center;display:inline-flex}.label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.name{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.meaning{color:var(--roxy-fg,#0a0a0a);margin:0;line-height:1.6}`],ht=p([(0,go.customElement)("roxy-dream-card")],ht);var Rr=require("lit"),ho=require("lit/decorators.js");var yt=class extends g{renderEmpty(){return Rr.html`<div class="roxy-empty" role="status">No symbols match</div>`}renderData(t){let e=t.symbols??[];if(e.length===0)return this.renderEmpty();let r=typeof t.total=="number"?t.total:e.length;return Rr.html`<section class="wrap" aria-label="Dream symbols"><header class="head"><h2 class="title">Dream symbols</h2><span class="count">${r} match${r===1?"":"es"}</span></header><ul class="grid">${e.map(a=>Rr.html`<li><button type="button" class="result" @click="${()=>this.select(a)}">${a.letter?Rr.html`<span class="letter" aria-hidden="true">${a.letter}</span>`:Rr.nothing} <span class="name">${a.name}</span></button></li>`)}</ul></section>`}select(t){this.dispatchEvent(new CustomEvent("roxy-symbol-select",{detail:{id:t.id,name:t.name,letter:t.letter},bubbles:!0,composed:!0}))}};yt.styles=[y,Rr.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.grid{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fill,minmax(8rem,1fr));margin:0;padding:0;list-style:none;display:grid}.result{align-items:center;gap:var(--roxy-space-sm,.5rem);text-align:left;width:100%;font:inherit;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);cursor:pointer;background:0 0;transition:border-color .12s,background .12s;display:flex}.result:hover,.result:focus-visible{border-color:var(--roxy-accent,#f59e0b);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent);outline:none}.letter{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);width:1.6rem;height:1.6rem;color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;flex:none;place-items:center;display:grid}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:500}`],yt=p([(0,ho.customElement)("roxy-dream-search")],yt);var W=require("lit"),je=require("lit/decorators.js"),Ja=require("lit/directives/if-defined.js");var Nl=12,Is=["latitude","longitude","timezone"],Hs=["latitude","longitude"];function Gl(n){let t=n.match(/^(.+?)(Latitude|Longitude)$/);return t?{group:t[1],leaf:t[2].toLowerCase()}:null}var Bl=xe.map(n=>n.toLowerCase());function Ya(n,t){if(n){if("$ref"in n&&n.$ref){let e=n.$ref.split("/").pop();return e?t[e]:void 0}return n}}function yo(n){let t=n.anyOf??n.oneOf;return!t||t.length===0?n:t.find(e=>Array.isArray(e.enum))??t.find(e=>Os(e)&&Os(e)!=="null")??t[0]??n}function Os(n){if(typeof n.type=="string")return n.type;if(!Array.isArray(n.type))return;let t=n.type.filter(e=>e!=="null");return t.length===1?t[0]:void 0}function Ol(n){let t=yo(n),e=Os(t);return Array.isArray(t.enum)?t.enum.length<=Nl?"tiles":"select":e==="boolean"?"toggle":t.format==="date"?"date":t.format==="time"?"time":t.format==="date-time"?"datetime":e==="integer"||e==="number"?"number":e==="string"?"text":e==="array"?"array":null}function uo(n){if(n.length!==12)return!1;let t=new Set(n.map(e=>e.toLowerCase()));return Bl.every(e=>t.has(e))}function Ua(n,t,e){let r=yo(t);return{key:e.key,name:n,group:e.group,inQuery:e.inQuery,kind:Ol(t)??"text",required:e.required,description:r.description??t.description,enum:r.enum,min:r.minimum,max:r.maximum,default:t.default??r.default,example:t.example??r.example}}function xo(n,t,e){let r=[],a=!1,s=n.requestBody?.content?.["application/json"]?.schema,o=Ya(s,t);if(o?.properties){let i=new Set(o.required??[]);for(let[l,d]of Object.entries(o.properties)){let m=Ya(d,t)??{};if(m.type==="object"&&m.properties){let c=new Set(m.required??[]);for(let[u,z]of Object.entries(m.properties)){let $=Ya(z,t)??{};r.push(Ua(u,$,{key:`${l}.${u}`,group:l,required:i.has(l)&&c.has(u)}))}}else{let c=Gl(l);r.push(c?Ua(c.leaf,m,{key:l,group:c.group,required:i.has(l)}):Ua(l,m,{key:l,required:i.has(l)}))}}}for(let i of n.parameters??[]){if(i.in!=="path"&&i.in!=="query")continue;if(i.name==="lang"&&i.in==="query"){a=!0;continue}let l=Ya(i.schema,t)??{};r.push(Ua(i.name,l,{key:i.name,required:!!i.required,inQuery:i.in==="query"}))}return{title:Il(n.summary,e),fields:r,hasLang:a}}function Il(n,t){let e=n?.split(" - ")[0]?.trim();return e||T(t.split("/").pop()??"")}function fo(n){let t=n.toLowerCase();return/compat|synastry|guna|connection|penta|composite/.test(t)?"Compare":/\bcast\b|\/draw|iching|hexagram|tarot/.test(t)?"Cast":/horoscope|dream|angel|nakshatra|crystal|meaning|reference/.test(t)?"Get reading":"Generate"}function bo(n,t){let e=t.replace(/^\//,"").replace(/[{}]/g,"").replace(/\//g,"-");return`${n.toLowerCase()}--${e}.json`}var Wa="0.26.0";var vo="https://roxyapi.com/api/v2/openapi.json",Hl=`https://cdn.jsdelivr.net/npm/@roxyapi/ui@${Wa}/dist/schemas`,js=new Map;async function jl(n){let t=js.get(n);return t||(t=fetch(n).then(async e=>{if(!e.ok)throw new Error(`HTTP ${e.status}`);return await e.json()}).catch(e=>{throw js.delete(n),e}),js.set(n,t)),t}function Fl(){return globalThis.crypto?.randomUUID?.()??Math.random().toString(36).slice(2)}function _l(n){let t=n.trim();if(!t)return[];try{let e=JSON.parse(t);if(Array.isArray(e))return e}catch{}return t.split(",").map(e=>e.trim()).filter(Boolean)}var Se=class extends W.LitElement{constructor(){super(...arguments);this.endpoint="vedic-astrology/birth-chart";this.method="POST";this.specUrl="";this.submitLabel="";this.fields=[];this.formTitle="";this.hasLang=!1;this.values={};this.loaded=!1;this.specError=null;this.validationErrors=[];this.retryLoadSchema=()=>{this.loaded=!1,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){let r=e instanceof Error?e.message:String(e);this.specError=r,this.loaded=!0,this.dispatchEvent(new CustomEvent("roxy-spec-error",{detail:{url:this.specUrl||vo,message:r},bubbles:!0,composed:!0}))}}async resolveModel(){return this.specUrl?this.modelFromSpec(this.specUrl):await this.tryLoadSlice()??this.modelFromSpec(vo)}async modelFromSpec(e){let r=await jl(e),a=`/${this.endpoint.replace(/^\//,"")}`,s=r.paths?.[a]?.[this.method.toLowerCase()];if(!s)throw new Error(`Endpoint ${this.method} ${a} not found in OpenAPI spec`);return xo(s,r.components?.schemas??{},this.endpoint)}async tryLoadSlice(){try{let e=await fetch(`${Hl}/${bo(this.method,this.endpoint)}`);return e.ok?await e.json():null}catch{return null}}applyModel(e){this.fields=e.fields,this.formTitle=e.title,this.hasLang=e.hasLang;let r={};for(let a of e.fields){a.default!==void 0&&(r[a.key]=a.default);let s=a.group?this.initialValues?.[a.group]?.[a.name]:this.initialValues?.[a.name];s!==void 0&&(r[a.key]=s)}this.values=r,this.loaded=!0}setValue(e,r){this.values={...this.values,[e]:r}}roleOf(e){return e.name==="seed"?"seed":(e.name==="limit"||e.name==="offset")&&!e.required?"hidden-default":Is.includes(e.name)&&this.groupHasLocation(e.group)||e.name==="timezone"&&this.locationGroups().some(r=>this.timezoneFieldFor(r)?.key===e.key)?"location":"normal"}isRendered(e){return this.roleOf(e)==="normal"}groupKeys(){let e=[];for(let r of this.fields)e.includes(r.group)||e.push(r.group);return e}groupHasLocation(e){let r=this.fields.filter(a=>a.group===e);return Hs.every(a=>r.some(s=>s.name===a))}locationGroups(){return this.groupKeys().filter(e=>this.groupHasLocation(e))}timezoneFieldFor(e){let r=this.fields.find(a=>a.group===e&&a.name==="timezone");if(r)return r;if(this.locationGroups()[0]===e)return this.fields.find(a=>a.group===void 0&&a.name==="timezone")}locationRequired(e){let r=this.fields.filter(a=>a.group===e);return Is.some(a=>r.some(s=>s.name===a&&s.required))}groupIsRequired(e){return this.groupHasLocation(e)||this.fields.some(r=>r.group===e&&r.required)}get singleEnumField(){if(this.groupKeys().some(a=>this.groupHasLocation(a))||this.groupKeys().some(a=>a!==void 0))return null;let e=this.fields.filter(a=>a.required&&this.isRendered(a)),r=e[0];return e.length!==1||!r?null:r.kind==="tiles"||r.kind==="select"?r:null}effectiveSubmitLabel(){return this.submitLabel||fo(this.endpoint)}effectiveLang(){return dn(this)}onLocationFor(e){return r=>{let a=r.detail;if(!a)return;let s=m=>this.fields.find(c=>c.group===e&&c.name===m)?.key,o={...this.values},i=s("latitude"),l=s("longitude");i&&(o[i]=a.latitude),l&&(o[l]=a.longitude);let d=this.timezoneFieldFor(e);d&&(o[d.key]=a.timezone??a.utcOffset),this.values=o}}selectTile(e,r){this.setValue(e.key,r),this.singleEnumField?.key===e.key&&this.submit()}onTilesKeyDown(e){return r=>{let a=e.enum??[];if(a.length===0)return;let s=a.indexOf(this.values[e.key]),o;if(r.key==="Home")o=0;else if(r.key==="End")o=a.length-1;else if(r.key==="ArrowRight"||r.key==="ArrowDown")o=s===-1?0:(s+1)%a.length;else if(r.key==="ArrowLeft"||r.key==="ArrowUp")o=s===-1?a.length-1:(s-1+a.length)%a.length;else return;r.preventDefault();let i=a[o];if(i===void 0)return;this.selectTile(e,i);let l=r.currentTarget;requestAnimationFrame(()=>l.querySelector(`[data-tile='${o}']`)?.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:!0,composed:!0}));return}this.validationErrors=[];let r={};for(let o of this.fields){let i=this.values[o.key];if(o.name==="seed"&&(i===void 0||i==="")&&(i=Fl()),!(i===void 0||i===""))if(o.kind==="array"&&typeof i=="string"&&(i=_l(i)),o.group){let l=r[o.group]??{};l[o.name]=i,r[o.group]=l}else r[o.name]=i}let a=this.fields.filter(o=>o.inQuery).map(o=>o.name),s=this.effectiveLang();this.hasLang&&s&&(r.lang=s,a.push("lang")),this.dispatchEvent(new CustomEvent("roxy-submit",{detail:{endpoint:this.endpoint,values:r,queryKeys:a,sticky:this.singleEnumField!=null},bubbles:!0,composed:!0}))}collectMissing(){let e=[],r=[],a=new Set;for(let s of this.fields){if(!s.required)continue;let o=this.roleOf(s)==="location";if(!this.isRendered(s)&&!o)continue;let i=this.values[s.key];if(!(i!==void 0&&i!=="")){if(e.push(s.key),o){a.add(s.group);continue}r.push(s.group?`${T(s.group)} ${T(s.name)}`:T(s.name))}}for(let s of a)r.push(s?`${T(s)} location`:"Birth location");return{keys:e,labels:r}}reqMark(e){return e.required?W.html`<span class="req" aria-hidden="true">*</span>`:W.nothing}description(e){if(!e.description)return W.nothing;if(e.description.length<=120)return W.html`<small class="help">${e.description}</small>`;let r=e.description.split(". ")[0]??e.description;return W.html`<details class="help-details"><summary><span class="help-lead">${r}</span>${te()}</summary><small class="help help-full">${e.description}</small></details>`}renderTiles(e){let r=`roxy-form-${e.key}-label`,a=!!e.enum&&uo(e.enum),s=e.enum??[],o=s.indexOf(this.values[e.key]),i=o===-1?0:o;return W.html`<div class="field tiles-field"><span class="label" id="${r}">${T(e.name)}${this.reqMark(e)}</span><div class="tiles" role="radiogroup" aria-labelledby="${r}" @keydown="${this.onTilesKeyDown(e)}">${s.map((l,d)=>{let m=this.values[e.key]===l,c=a?q(l):void 0;return W.html`<button type="button" class="tile" role="radio" data-tile="${d}" aria-checked="${m?"true":"false"}" tabindex="${d===i?"0":"-1"}" @click="${()=>this.selectTile(e,l)}">${c?W.html`<span class="tile-glyph" aria-hidden="true">${c}</span>`:W.nothing} <span class="tile-label">${T(l)}</span></button>`})}</div>${this.description(e)}</div>`}renderSelect(e){let r=`roxy-form-${e.key}`;return W.html`<div class="field"><label for="${r}">${T(e.name)}${this.reqMark(e)}</label> <select id="${r}" ?required="${e.required}" @change="${a=>this.setValue(e.key,a.target.value)}"><option value="">Choose</option>${(e.enum??[]).map(a=>W.html`<option value="${a}" ?selected="${this.values[e.key]===a}">${T(a)}</option>`)}</select> ${this.description(e)}</div>`}renderToggle(e){let r=`roxy-form-${e.key}`,a=this.values[e.key]===!0;return W.html`<div class="field"><div class="toggle-row"><button type="button" id="${r}" class="toggle" role="switch" aria-checked="${a?"true":"false"}" @click="${()=>this.setValue(e.key,!a)}"><span class="knob"></span></button> <label class="toggle-label" for="${r}">${T(e.name)}${this.reqMark(e)}</label></div>${this.description(e)}</div>`}renderInput(e){let r=`roxy-form-${e.key}`,a=e.kind==="datetime"?"datetime-local":e.kind==="number"?"number":e.kind,s=e.kind==="array"?"Comma separated":e.example!=null?String(e.example):"";return W.html`<div class="field"><label for="${r}">${T(e.name)}${this.reqMark(e)}</label> <input id="${r}" type="${e.kind==="array"?"text":a}" ?required="${e.required}" min="${(0,Ja.ifDefined)(e.min)}" max="${(0,Ja.ifDefined)(e.max)}" step="${e.kind==="number"?"any":W.nothing}" placeholder="${s||W.nothing}" .value="${this.values[e.key]??""}" @input="${o=>this.setValue(e.key,this.coerce(e.kind,o.target.value))}"> ${this.description(e)}</div>`}renderField(e){switch(e.kind){case"tiles":return this.renderTiles(e);case"select":return this.renderSelect(e);case"toggle":return this.renderToggle(e);default:return this.renderInput(e)}}locationFillList(e){let r=[...Hs];return this.timezoneFieldFor(e)&&r.push("timezone"),r.join(", ")}locationBlock(e){return W.html`<div class="location-block"><label>${e?`${T(e)} location`:"Birth location"}${this.locationRequired(e)?W.html`<span class="req" aria-hidden="true">*</span>`:W.nothing}</label><roxy-location-search publishable-key="${(0,Ja.ifDefined)(this.publishableKey)}" @roxy-location-select="${this.onLocationFor(e)}" placeholder="${e?`${T(e)} city`:"City of birth"}"></roxy-location-search><small class="help">Fills ${this.locationFillList(e)}. Pick a city to autofill.</small></div>`}groupCard(e){let r=this.fields.filter(a=>a.group===e&&this.isRendered(a));return W.html`<fieldset class="person-group"><legend>${T(e)}</legend>${this.groupHasLocation(e)?this.locationBlock(e):W.nothing}<div class="fields">${r.map(a=>this.renderField(a))}</div></fieldset>`}render(){if(!this.loaded)return W.html`<form><div class="roxy-skeleton" style="height:8rem"></div></form>`;if(this.specError)return W.html`<div class="spec-error" role="alert">Schema load failed: ${this.specError} <button type="button" class="submit" @click="${this.retryLoadSchema}">Retry</button></div>`;let e=this.fields.filter(d=>!d.group&&this.isRendered(d)),r=e.filter(d=>d.required),a=e.filter(d=>!d.required),s=this.groupKeys().filter(d=>d!==void 0),o=s.filter(d=>this.groupIsRequired(d)),i=s.filter(d=>!this.groupIsRequired(d)),l=a.length>0||i.length>0;return W.html`<form @submit="${this.onSubmit}"><h2 class="title">${this.formTitle}</h2>${this.validationErrors.length>0?W.html`<div class="validation-error" role="alert"><strong>Please complete:</strong> ${this.validationErrors.join(", ")}</div>`:W.nothing}<div class="fields">${r.map(d=>this.renderField(d))}</div>${this.groupHasLocation(void 0)?this.locationBlock(void 0):W.nothing} ${o.map(d=>this.groupCard(d))} ${l?W.html`<details class="advanced"><summary>Advanced${te()}</summary><div class="fields">${a.map(d=>this.renderField(d))}</div>${i.map(d=>this.groupCard(d))}</details>`:W.nothing} ${this.singleEnumField?W.nothing:W.html`<button class="submit" type="submit">${this.effectiveSubmitLabel()}</button>`}</form>`}coerce(e,r){if(r!==""){if(e==="number"){let a=Number(r);return Number.isFinite(a)?a:void 0}return r}}};Se.styles=[y,O,W.css`form{gap:var(--roxy-space-md,1rem);background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.fields{align-items:start;gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.fields:empty{display:none}.person-group{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-md,1rem);min-inline-size:0;margin:0;display:grid}.person-group legend{padding:0 var(--roxy-space-xs,.25rem);font-weight:var(--roxy-weight-bold,600)}.field{gap:var(--roxy-space-xs,.25rem);flex-direction:column;min-width:0;display:flex}.tiles-field{grid-column:1/-1}label,.label{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569)}.req{color:var(--roxy-danger-fg,#991b1b);margin-left:4px}input,select{box-sizing:border-box;width:100%;padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);font-size:var(--roxy-text-base,1rem);color:var(--roxy-fg,#0a0a0a);background:var(--roxy-bg,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);font-family:inherit}input:focus,select:focus{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px;border-color:var(--roxy-accent-ink,#b45309)}.help{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.help-details>summary{cursor:pointer;color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);align-items:center;gap:4px;display:flex}.help-details .help-lead{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.help-details .help-full{margin-top:var(--roxy-space-xs,.25rem);display:block}.location-block{gap:var(--roxy-space-xs,.25rem);grid-column:1/-1;display:grid}.tiles{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fit,minmax(5.5rem,1fr));display:grid}.tile{min-height:44px;padding:var(--roxy-space-sm,.5rem);background:var(--roxy-bg,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-fg,#0a0a0a);font-family:inherit;font-size:var(--roxy-text-sm,.875rem);cursor:pointer;transition:border-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease), background-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-direction:column;justify-content:center;align-items:center;gap:2px;display:flex}.tile:hover{border-color:var(--roxy-accent,#f59e0b)}.tile[aria-checked=true]{border-color:var(--roxy-accent,#f59e0b);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 12%, transparent);color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.tile:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.tile-glyph{font-size:1.35em;line-height:1}.toggle-row{align-items:center;gap:var(--roxy-space-sm,.5rem);display:flex}.toggle{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);background:var(--roxy-border,#e4e4e7);cursor:pointer;width:44px;height:26px;transition:background-color var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);flex-shrink:0;padding:0;position:relative}.toggle[aria-checked=true]{background:var(--roxy-accent,#f59e0b);border-color:var(--roxy-accent,#f59e0b)}.toggle .knob{background:var(--roxy-bg,#fff);width:20px;height:20px;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,ease);border-radius:50%;position:absolute;top:2px;left:2px}.toggle[aria-checked=true] .knob{transform:translate(18px)}.toggle:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}.toggle-label{cursor:pointer}@media (prefers-reduced-motion:reduce){.tile,.toggle,.toggle .knob{transition:none}}.advanced{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.advanced>summary{cursor:pointer;font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);align-items:center;gap:6px;display:flex}.advanced[open]>summary{margin-bottom:var(--roxy-space-md,1rem)}.advanced .fields,.advanced .person-group{margin-top:var(--roxy-space-md,1rem)}.validation-error{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);background:color-mix(in srgb, var(--roxy-danger,#dc2626) 8%, transparent);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);display:grid}button.submit{background:var(--roxy-accent-ink,#b45309);color:var(--roxy-bg,#fff);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-lg,1.5rem);font-size:var(--roxy-text-base,1rem);font-weight:var(--roxy-weight-bold,600);cursor:pointer;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));border:0;justify-self:start}button.submit:hover{transform:scale(1.02)}button.submit:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:2px}@media (prefers-reduced-motion:reduce){button.submit{transition:none}}.spec-error{gap:var(--roxy-space-md,1rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-danger,#dc2626);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);color:var(--roxy-danger-fg,#991b1b);font-size:var(--roxy-text-sm,.875rem);justify-items:start;display:grid}`],p([(0,je.property)({type:String,attribute:"data-endpoint"})],Se.prototype,"endpoint",2),p([(0,je.property)({type:String})],Se.prototype,"method",2),p([(0,je.property)({type:String,attribute:"spec-url"})],Se.prototype,"specUrl",2),p([(0,je.property)({type:String,attribute:"submit-label"})],Se.prototype,"submitLabel",2),p([(0,je.property)({type:String,attribute:"publishable-key"})],Se.prototype,"publishableKey",2),p([(0,je.property)({attribute:!1})],Se.prototype,"initialValues",2),p([(0,je.state)()],Se.prototype,"fields",2),p([(0,je.state)()],Se.prototype,"formTitle",2),p([(0,je.state)()],Se.prototype,"hasLang",2),p([(0,je.state)()],Se.prototype,"values",2),p([(0,je.state)()],Se.prototype,"loaded",2),p([(0,je.state)()],Se.prototype,"specError",2),p([(0,je.state)()],Se.prototype,"validationErrors",2),Se=p([(0,je.customElement)("roxy-endpoint-form")],Se);var be=require("lit"),Lo=require("lit/decorators.js");var ut=class extends g{renderEmpty(){return be.html`<div class="roxy-empty" role="status">No fixed star data</div>`}renderData(t){let e=t.conjunctions??[],r=t.stars??[];return be.html`<div class="wrap" part="card"><header part="header"><h2 class="title">Fixed stars</h2>${typeof t.orb=="number"?be.html`<span class="badge"><b>Orb</b> ${x(t.orb,1)}°</span>`:be.nothing}</header>${t.summary&&!this.hideReadings?be.html`<p class="summary">${t.summary}</p>`:be.nothing} ${e.length?be.html`<section part="section conjunctions"><p class="subhead">Conjunctions to the chart</p>${e.map((a,s)=>be.html`<details class="interp-card" part="reading" name="fixed-star-contacts" ?open="${s===0}"><summary><span class="interp-lead"><span class="point">${a.point}</span> conjunct ${a.star}</span> ${te()} <span class="interp-aside"><small>orb ${x(a.orb,2)}°</small></span></summary>${a.interpretation&&!this.hideReadings?be.html`<div class="interp-body"><p>${a.interpretation}</p></div>`:be.nothing}</details>`)}</section>`:be.html`<p class="empty-note">No star sits within the orb of a natal point.</p>`} ${r.length?this.renderCatalog(r):be.nothing}</div>`}renderCatalog(t){return be.html`<details class="catalog"><summary>${te()} Star catalog (${t.length})</summary><div class="scroll"><table><caption class="subhead">Precessed positions for the chart date</caption><thead><tr><th scope="col">Star</th><th scope="col">Position</th><th scope="col" class="num">Mag</th><th scope="col">Nature</th><th scope="col">Keywords</th></tr></thead><tbody>${t.map(e=>{let r=q(e.sign);return be.html`<tr><td>${e.name}</td><td>${r?be.html`<span class="sg">${r}</span>`:be.nothing}${mt(e.degree)} ${e.sign}</td><td class="num">${x(e.magnitude,1)}</td><td>${e.nature}</td><td><div class="kw">${(e.keywords??[]).map(a=>be.html`<span>${a}</span>`)}</div></td></tr>`})}</tbody></table></div></details>`}};ut.styles=[y,O,K,be.css`.wrap{background:var(--roxy-surface,#fff);width:100%;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}header{align-items:baseline;gap:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-primary,#0f172a);margin:0}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);padding:2px 8px}.badge b{color:var(--roxy-accent-ink,#b45309);font-weight:600}.summary{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);margin:0}.empty-note{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.subhead{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0 0 var(--roxy-space-sm,.5rem);font-weight:600}.interp-lead .point{color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.interp-aside small{font-variant-numeric:tabular-nums}.catalog summary{cursor:pointer;color:var(--roxy-fg,#0a0a0a);align-items:center;gap:.5rem;font-weight:600;display:flex}.scroll{min-width:0;margin-top:var(--roxy-space-sm,.5rem);overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{text-align:left;border-bottom:1px solid var(--roxy-border,#e4e4e7);white-space:nowrap;vertical-align:top;padding:6px 10px}th{color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.04em;font-weight:600;font-size:var(--roxy-text-xs,.75rem)}td.num{text-align:right;font-variant-numeric:tabular-nums}.sg{color:var(--roxy-secondary,#475569);margin-right:.3rem}.kw{white-space:normal;flex-wrap:wrap;gap:.2rem;max-width:18rem;display:flex}.kw span{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a);padding:0 6px}`],ut=p([(0,Lo.customElement)("roxy-fixed-stars")],ut);var We=require("lit"),$o=require("lit/decorators.js");var xt=class extends g{renderEmpty(){return We.html`<div class="roxy-empty" role="status">No digest data</div>`}renderData(t){let e=t.windows??[];if(e.length===0)return this.renderEmpty();let r=[D(this.effectiveLang(),t.startDate),D(this.effectiveLang(),t.endDate)].filter(Boolean).join(" \u2013 ");return We.html`<div class="wrap" part="card" aria-label="Forecast digest"><div class="head" part="header"><h2 class="title">Forecast digest</h2>${r?We.html`<p class="subtitle">${r}</p>`:We.nothing}</div>${e.map(a=>this.renderWindow(a))}</div>`}windowLabel(t){return t===1?"Next 24 hours":typeof t=="number"?`Next ${t} days`:"Window"}renderWindow(t){let e=[...t.top??[]].sort((s,o)=>(o.significance??0)-(s.significance??0)),r=t.byDomain??{},a=Object.entries(r);return We.html`<section class="window" part="section window"><div class="window-head" part="details"><span class="window-label">${this.windowLabel(t.days)}</span> <span class="window-count">${t.count??0} event${t.count===1?"":"s"}</span></div>${a.length>0?We.html`<div class="domains" part="legend">${a.map(([s,o])=>We.html`<span class="domain-chip"><span class="swatch sw-${s}"></span>${T(s)} ${o}</span>`)}</div>`:We.nothing} ${e.length>0?We.html`<div role="list">${e.map(s=>this.renderEvent(s))}</div>`:We.html`<p class="quiet">No notable events.</p>`}</section>`}renderEvent(t){let e=typeof t.significance=="number"?t.significance:0,r=this.hideReadings||t.description==null?T(t.type??""):t.description;return We.html`<div class="event" role="listitem"><span class="event-date">${D(this.effectiveLang(),t.date)}</span> <span class="event-desc">${r}</span> <span class="sig" role="img" aria-label="significance ${x(e,0)} of 100"><span class="sig-fill ${t.domain}" style="width:${Math.max(0,Math.min(100,e))}%"></span></span></div>`}};xt.styles=[y,We.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.window{gap:var(--roxy-space-sm,.5rem);padding-top:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);display:grid}.window:first-of-type{border-top:none;padding-top:0}.window-head{flex-wrap:wrap;align-items:baseline;gap:.5rem;display:flex}.window-label{font-weight:var(--roxy-weight-bold,600)}.window-count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;margin-left:auto}.domains{flex-wrap:wrap;gap:.4rem;display:flex}.domain-chip{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);align-items:center;gap:.35rem;display:inline-flex}.swatch{border-radius:2px;width:.65rem;height:.65rem;display:inline-block}.sw-western{background:var(--roxy-accent,#f59e0b)}.sw-vedic{background:var(--roxy-info,#2563eb)}.sw-biorhythm{background:var(--roxy-success,#16a34a)}.event{grid-template-columns:auto 1fr;align-items:baseline;gap:.25rem .6rem;display:grid}.event-date{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;white-space:nowrap}.event-desc{font-size:var(--roxy-text-sm,.875rem);line-height:1.4}.sig{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:2px;grid-column:2;height:4px;overflow:hidden}.sig-fill{border-radius:2px;height:100%;display:block}.sig-fill.western{background:var(--roxy-accent,#f59e0b)}.sig-fill.vedic{background:var(--roxy-info,#2563eb)}.sig-fill.biorhythm{background:var(--roxy-success,#16a34a)}.quiet{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-style:italic}`],xt=p([(0,$o.customElement)("roxy-forecast-digest")],xt);var ue=require("lit"),wo=require("lit/decorators.js");var Kl={western:"Western",vedic:"Vedic",biorhythm:"Biorhythm"},ql=["western","vedic","biorhythm"],ft=class extends g{renderEmpty(){return ue.html`<div class="roxy-empty" role="status">No forecast data</div>`}renderData(t){let e=t.events??[],r=this.groupByDate(e),a=ql.filter(s=>e.some(o=>o.domain===s));return ue.html`<div class="wrap" part="card" aria-label="Forecast timeline"><header class="head" part="header"><h2 class="title">Forecast timeline</h2>${t.startDate&&t.endDate?ue.html`<div class="range">${D(this.effectiveLang(),t.startDate)} - ${D(this.effectiveLang(),t.endDate)} · ${t.count??e.length} events</div>`:ue.nothing}</header>${a.length?ue.html`<div class="legend" part="legend">${a.map(s=>ue.html`<span><span class="swatch swatch-${s}"></span>${Kl[s]}</span>`)}</div>`:ue.nothing} ${r.length?ue.html`<div class="days" part="section events" role="list">${r.map(([s,o])=>this.renderDay(s,o))}</div>`:ue.html`<p class="roxy-empty" role="status">No events in this window</p>`}</div>`}groupByDate(t){let e=new Map;for(let r of t){let a=r.date??"",s=e.get(a)??[];s.push(r),e.set(a,s)}return[...e.entries()]}renderDay(t,e){return ue.html`<div class="day" role="listitem"><div class="day-date">${D(this.effectiveLang(),t)}</div><div class="events">${e.map(r=>this.renderEvent(r))}</div></div>`}renderEvent(t){let e=typeof t.significance=="number"?t.significance:0,r=Math.max(0,Math.min(100,e));return ue.html`<div class="event"><span class="dot dot-${t.domain}" aria-hidden="true"></span><div class="event-body"><div class="event-line">${this.renderHeadline(t)}</div>${t.description&&!this.hideReadings?ue.html`<p class="event-desc">${t.description}</p>`:ue.nothing}<div class="sig" title="Significance ${r} of 100"><span class="sig-track"><span class="sig-fill sig-fill-${t.domain}" style="width:${r}%"></span> </span><span class="sig-val">${r}</span></div></div></div>`}renderHeadline(t){let e=t.body?Z(t.body):"",r=t.target?Z(t.target):"",a=or({type:t.aspect}),s=vr[a]??"",o=a?ba(t.aspect)??ke({type:t.aspect}):"",i=typeof t.orb=="number"?x(t.orb,1):"",l=this.typeQualifier(t);return a&&r?ue.html`<strong>${e}</strong> <span class="${s}">${o}</span> <strong>${r}</strong>${i?ue.html`<span class="kind">orb ${i}°</span>`:ue.nothing}`:ue.html`<strong>${e||T(t.type??"")}</strong>${l?ue.html`<span class="kind">${l}</span>`:ue.nothing}`}typeQualifier(t){return t.type==="sign-ingress"&&t.target?`enters ${Z(t.target)}`:t.type==="retrograde-station"&&t.station?t.station:t.type==="eclipse"?[t.kind,"eclipse"].filter(Boolean).join(" "):t.type==="critical-day"?"critical day":t.type==="dasha-change"&&t.target?`dasha ${Z(t.target)}`:T(t.type??"")}};ft.styles=[y,ue.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.range{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-variant-numeric:tabular-nums}.legend{gap:var(--roxy-space-md,1rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);flex-wrap:wrap;display:flex}.legend .swatch{vertical-align:middle;border-radius:50%;width:10px;height:10px;margin-right:4px;display:inline-block}.swatch-western{background:var(--roxy-accent,#f59e0b)}.swatch-vedic{background:var(--roxy-info,#2563eb)}.swatch-biorhythm{background:var(--roxy-success,#16a34a)}.day{gap:var(--roxy-space-md,1rem);padding-block:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:4.5rem 1fr;display:grid}.day:first-of-type{border-top:none}.day-date{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;padding-top:2px}.events{gap:var(--roxy-space-sm,.5rem);display:grid}.event{gap:var(--roxy-space-sm,.5rem);grid-template-columns:.6rem 1fr;align-items:start;display:grid}.dot{border-radius:50%;width:.6rem;height:.6rem;margin-top:4px}.dot-western{background:var(--roxy-accent,#f59e0b)}.dot-vedic{background:var(--roxy-info,#2563eb)}.dot-biorhythm{background:var(--roxy-success,#16a34a)}.event-body{min-width:0}.event-line{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.event-line .aspect-trine,.event-line .aspect-sextile{color:var(--roxy-success-fg,#166534)}.event-line .aspect-square,.event-line .aspect-opposition{color:var(--roxy-danger-fg,#991b1b)}.event-line .aspect-conjunction{color:var(--roxy-accent-ink,#b45309)}.event-line .kind{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.04em;margin-left:.35em}.event-desc{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:2px 0 0}.sig{align-items:center;gap:.4rem;margin-top:4px;display:flex}.sig-track{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);flex:1;max-width:8rem;height:4px;overflow:hidden}.sig-fill{border-radius:var(--roxy-radius-full,9999px);height:100%;display:block}.sig-fill-western{background:var(--roxy-accent,#f59e0b)}.sig-fill-vedic{background:var(--roxy-info,#2563eb)}.sig-fill-biorhythm{background:var(--roxy-success,#16a34a)}.sig-val{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums}`],ft=p([(0,wo.customElement)("roxy-forecast-timeline")],ft);var ie=require("lit"),ko=require("lit/decorators.js");var Xa=8,bt=class extends g{renderEmpty(){return ie.html`<div class="roxy-empty" role="status">No transit data</div>`}renderData(t){let e=t.transitingPlanets??[];if(!e.length)return this.renderEmpty();let r=t.keyTransits??[];return ie.html`<div class="wrap" part="card" aria-label="Gochara transits"><header class="head" part="header"><h2 class="title">Gochara</h2><p class="sub">Where each graha transits at <strong>${Oe(this.effectiveLang(),t.transitDatetime)}</strong>, read against the natal chart of ${Oe(this.effectiveLang(),t.birthDatetime)}.</p></header><div part="table">${e.map(a=>this.renderPlanet(a))}</div>${r.length&&!this.hideReadings?ie.html`<section class="key" part="section key-transits"><h3 class="key-title">Key transits</h3>${r.map(a=>ie.html`<p class="key-item">${a.description} ${typeof a.natalHouse=="number"?ie.html`<span class="meta">· natal house ${a.natalHouse}</span>`:ie.nothing}</p>`)}</section>`:ie.nothing}</div>`}renderPlanet(t){let e=k(t.name)??"",r=typeof t.longitude=="number"?He(t.longitude):void 0,a=t.aspectsToNatal??[];return ie.html`<article class="row"><div class="row-top"><span class="graha">${e?ie.html`<span class="glyph">${e}</span>`:ie.nothing}${t.name} </span><span class="pos">${t.sign}${r?ie.html`${mt(r.degree)}`:ie.nothing} </span>${typeof t.natalHouse=="number"?ie.html`<span class="house">natal house ${t.natalHouse}</span>`:ie.nothing}</div>${this.renderKaksha(t.kaksha)} ${a.length?ie.html`<p class="aspects">${a.map(s=>`${ke({type:s.aspectType})} natal ${s.natalPlanet}${typeof s.orb=="number"?` (${x(s.orb,1)}\xB0)`:""}`).join(" \xB7 ")}</p>`:ie.nothing}</article>`}renderKaksha(t){if(!t||typeof t.number!="number")return ie.nothing;let e=t.number,r=t.bindu===!0?"yes":t.bindu===!1?"no":"";return ie.html`<div class="kaksha-bar" part="chart" role="img" aria-label="Kaksha ${e} of ${Xa} within ${""}the current sign">${Array.from({length:Xa},(a,s)=>ie.html`<span class="seg ${s+1===e?`here ${r}`:""}"></span>`)}</div><p class="meta">Kaksha <span class="num">${e}</span> of ${Xa}${t.lord?ie.html`, ruled by ${t.lord}`:""}${typeof t.startDegree=="number"&&typeof t.endDegree=="number"?ie.html`, spanning <span class="num">${x(t.startDegree,2)}° to ${x(t.endDegree,2)}°</span> of the sign`:""}${t.bindu===null||t.bindu===void 0?"":ie.html` · this kaksha lord ${t.bindu?"gave":"gave no"} bindu${typeof t.binduCount=="number"?ie.html`, <span class="num">${t.binduCount}</span> of ${Xa} in this sign`:""}`}</p>`}};bt.styles=[y,ie.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid;overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sub{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.row{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold,600)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.35em}.pos{color:var(--roxy-secondary,#475569);font-size:var(--roxy-text-sm,.875rem);font-variant-numeric:tabular-nums}.house{font-size:var(--roxy-text-xs,.75rem);border-radius:var(--roxy-radius-sm,4px);border:1px solid var(--roxy-border,#e4e4e7);padding:.1rem .45rem}.kaksha-bar{grid-template-columns:repeat(8,1fr);gap:2px;height:10px;margin:.15rem 0;display:grid}.seg{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:2px}.seg.here{background:color-mix(in srgb, var(--roxy-muted,#71717a) 45%, transparent)}.seg.here.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 55%, transparent)}.seg.here.no{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 55%, transparent)}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.num{font-variant-numeric:tabular-nums}.aspects{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-secondary,#475569);line-height:var(--roxy-leading-normal,1.5);margin:0}.key{padding:var(--roxy-space-md,1rem);border-top:2px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-sm,.5rem);display:grid}.key-title{font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em;color:var(--roxy-muted,#71717a);margin:0}.key-item{font-size:var(--roxy-text-sm,.875rem);line-height:var(--roxy-leading-normal,1.5);margin:0}`],bt=p([(0,ko.customElement)("roxy-gochara-table")],bt);var ve=require("lit"),So=require("lit/decorators.js");var Vl={varna:1,vashya:2,tara:3,yoni:4,"graha maitri":5,gana:6,bhakoot:7,nadi:8},vt=class extends g{renderEmpty(){return ve.html`<div class="roxy-empty" role="status">No Guna Milan data</div>`}renderData(t){let e=(t.breakdown??[]).filter(m=>m?.category!==void 0),r=t.total??0,a=t.maxScore??36,s=r/a*100,o="color-mix(in srgb, var(--roxy-border) 50%, transparent)",i=s>=70?"var(--roxy-success)":s>=50?"var(--roxy-warning)":"var(--roxy-danger)",l=s*2.827,d=(100-s)*2.827;return ve.html`<article class="card" part="card" aria-label="Guna Milan score"><div class="score-header" part="header"><div class="score-info"><div class="score-bar" part="details"><div><span class="total">${x(t.total,1)}</span> <span class="over">/ ${t.maxScore}</span> ${typeof t.percentage=="number"?ve.html`<small style="margin-left:.5rem;color:var(--roxy-muted)">${An(t.percentage,1)}</small>`:ve.nothing}</div><div class="verdict-wrap">${typeof t.isCompatible=="boolean"?ve.html`<span class="verdict ${t.isCompatible?"yes":"no"}">${t.isCompatible?"Compatible":"Not compatible"}</span>`:ve.nothing} ${t.recommendation&&!this.hideReadings?ve.html`<span class="recommendation">${t.recommendation}</span>`:ve.nothing}</div></div></div><div class="score-ring" part="chart" role="meter" aria-label="Guna milan score" aria-valuemin="0" aria-valuemax="36" aria-valuenow="${r}"><svg viewBox="0 0 100 100" aria-hidden="true"><circle class="ring-track" cx="50" cy="50" r="45" fill="none" stroke="${o}" stroke-width="8"/><circle class="ring-fill" cx="50" cy="50" r="45" fill="none" stroke="${i}" stroke-width="8" stroke-dasharray="${l},${d}" stroke-linecap="round" transform="rotate(-90 50 50)"/><text x="50" y="50" text-anchor="middle" dominant-baseline="central" class="ring-text">${r}</text><text x="50" y="64" text-anchor="middle" dominant-baseline="central" class="ring-max">/${a}</text></svg></div></div>${e.length>0?ve.html`<div class="table-scroll" part="table"><table><caption class="roxy-sr-only">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">Koota</th><th scope="col">Person 1</th><th scope="col">Person 2</th><th scope="col" class="bar-col">Progress</th><th scope="col" class="score">Score</th></tr></thead><tbody>${e.map(m=>{let c=m.score??0,u=m.maxScore??Zl(m.category),z=u?c/u*100:0;return ve.html`<tr><td>${m.category} ${m.description?ve.html`<small>${m.description}</small>`:ve.nothing}</td><td class="classification">${m.person1??""}</td><td class="classification">${m.person2??""}</td><td class="bar-cell bar-col"><div class="mini-bar"><span style="width:${z}%"></span></div></td><td class="score">${x(c,1)} / ${u}</td></tr>`})}</tbody></table></div>`:ve.nothing} ${(t.doshas?.length??0)>0||(t.doshaCancellations?.length??0)>0?ve.html`<div class="tags" part="details">${t.doshas?.map(m=>ve.html`<span class="dosha">${m}</span>`)} ${t.doshaCancellations?.map(m=>ve.html`<span class="cancel" title="${m.reason}">${m.dosha} cancelled</span>`)}</div>`:ve.nothing} ${ce(t.frame)}</article>`}};vt.styles=[y,de,ve.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.card>*{min-width:0}.score-header{align-items:center;gap:1rem;display:flex}.score-info{flex:1;min-width:0}.table-scroll{-webkit-overflow-scrolling:touch;min-width:0;overflow-x:auto}.score-bar{align-items:center;gap:var(--roxy-space-md,1rem);grid-template-columns:1fr auto;display:grid}.total{font-size:2.25rem;font-weight:var(--roxy-weight-bold,600);color:var(--roxy-accent-ink,#b45309);font-variant-numeric:tabular-nums;line-height:1}.over{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-base,1rem)}.verdict-wrap{justify-items:end;gap:var(--roxy-space-xs,.25rem);text-align:right;display:grid}.verdict{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 10px}.verdict.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.verdict.no{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.recommendation{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569)}.score-ring{flex-shrink:0;width:120px;height:120px}.score-ring svg{width:100%;height:100%}.score-ring .ring-text{fill:var(--roxy-fg,#0a0a0a);font-size:22px;font-weight:700;font-family:var(--roxy-font-sans)}.score-ring .ring-max{fill:var(--roxy-muted,#71717a);font-size:10px;font-family:var(--roxy-font-sans)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}td small{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin-top:2px;line-height:1.5;display:block}td.classification{color:var(--roxy-secondary,#475569);white-space:nowrap}th.score{text-align:right}td.score{text-align:right;font-variant-numeric:tabular-nums;color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}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-ring .ring-text,.score-ring .ring-max{display:none}.score-bar{gap:var(--roxy-space-xs,.25rem);grid-template-columns:1fr}.verdict-wrap{text-align:left;justify-items:start}}.mini-bar{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);height:8px;overflow:hidden}.mini-bar>span{background:var(--roxy-accent,#f59e0b);height:100%;transition:width var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.tags{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.tags span{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}.tags .dosha{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.tags .cancel{background:color-mix(in srgb, var(--roxy-success,#16a34a) 18%, transparent);color:var(--roxy-success-fg,#166534)}`],vt=p([(0,So.customElement)("roxy-guna-milan")],vt);function Zl(n){return n&&Vl[n.toLowerCase()]||1}var Le=require("lit"),Co=require("lit/decorators.js");var Lt=class extends g{renderData(t){let e=t.channels??[],r=t.centers??[],a=r.filter(s=>s.defined).length;return Le.html`<div class="wrap" part="card" aria-label="Human Design connection"><header class="head" part="header"><h2 class="title">Connection</h2>${typeof t.totalChannels=="number"?Le.html`<span class="count">${t.totalChannels} channels</span>`:Le.nothing}</header>${wr([{label:"Channels",value:t.totalChannels?.toString()},{label:"Combined definition",value:t.combinedDefinition?T(String(t.combinedDefinition)):void 0},{label:"Centers defined",value:r.length>0?`${a} of ${r.length}`:void 0}])} ${this.hideReadings?Le.nothing:Le.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(t.summary)} ${this.renderCenters(r)} ${this.renderChannels(e,r)}</div>`}renderDynamics(t){if(!t)return Le.nothing;let e=[{label:"Electromagnetic",aside:Qa(t.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:Qa(t.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:Qa(t.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:Qa(t.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(e,"hd-connection-dynamic","Dynamics")}renderCenters(t){return t.length===0?Le.nothing:Le.html`<section class="block" part="section centers"><h3>Centers</h3>${this.hideReadings?Le.nothing:Le.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>`} ${t.map(e=>{let r=e.definedBy??[],a=r.includes("A"),s=r.includes("B"),o=!!e.defined&&!a&&!s;return Le.html`<div class="row"><span class="cname">${e.name??T(String(e.id??""))}</span> <span class="badge ${e.defined?o?"together":"defined":"open"}">${e.defined?o?"Only together":"Defined":"Open"} </span><span class="who">${Yl(!!e.defined,a,s)}</span></div>`})}</section>`}renderChannels(t,e){if(t.length===0)return Le.nothing;let r=new Map(e.map(s=>[String(s.id??""),s.name??""])),a=s=>r.get(s)||T(s);return Le.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>${t.map(s=>Le.html`<tr><td>${s.name??""}</td><td class="gates">${s.gateA}-${s.gateB}</td><td>${(s.centers??[]).map(a).join(" to ")}</td><td>${s.circuit??""}</td><td>${s.dynamic?Le.html`<span class="dyn">${s.dynamic}</span>`:Le.nothing}</td><td class="held">${Ro(s.personAGates)}</td><td class="held">${Ro(s.personBGates)}</td></tr>`)}</tbody></table></div></section>`}renderEmpty(){return Le.html`<div class="roxy-empty" role="status">No connection data</div>`}};Lt.styles=[y,O,K,Mr,Le.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);font-variant-numeric:tabular-nums}.note{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-sm,.5rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;display:flex}.row:last-child{border-bottom:none}.cname{flex:1;min-width:8rem}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 8px;display:inline-flex}.badge.defined{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.open{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.together{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a)}.who{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{text-align:left;padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr:last-child td{border-bottom:none}.gates{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600)}.dyn{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);color:var(--roxy-fg,#0a0a0a);padding:1px 8px;display:inline-block}.held{font-variant-numeric:tabular-nums}.scroll{min-width:0;overflow-x:auto}`],Lt=p([(0,Co.customElement)("roxy-hd-connection")],Lt);function Qa(n){if(typeof n=="number")return n===0?"None":n===1?"1 channel":`${n} channels`}function Ro(n){let t=n??[];return t.length>0?t.join(", "):"Neither"}function Yl(n,t,e){return t&&e?"Defined in both charts":t?"Defined by A":e?"Defined by B":n?"Defined by neither alone, only by the connection":"Open in both charts"}var re=require("lit"),Ao=require("lit/decorators.js");var $t=class extends g{renderData(t){let e=t.channels??[],r=t.gates??[],a=t.summary,s=a?.gapGates??[],o=e.some(i=>i.isCore);return re.html`<div class="wrap" part="card" aria-label="Human Design penta"><header class="head" part="header"><h2 class="title">Penta</h2>${typeof t.memberCount=="number"?re.html`<span class="count">${t.memberCount} members</span>`:re.nothing}</header>${wr([{label:"Members",value:t.memberCount?.toString()},{label:"Defined channels",value:typeof a?.definedChannels=="number"&&e.length>0?`${a.definedChannels} of ${e.length}`:void 0},{label:"Filled gates",value:typeof a?.filledGates=="number"&&r.length>0?`${a.filledGates} of ${r.length}`:void 0},{label:"Core",value:typeof a?.coreDefined=="boolean"?a.coreDefined?"Defined":"Open":void 0},{label:"Gap gates",value:s.length>0?s.join(", "):void 0}])} ${this.hideReadings?re.nothing:re.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)",e.filter(i=>i.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)",e.filter(i=>i.position==="lower"),"Lower channels run from the G Center to the Sacral. They carry the managed, generative, resource work.")} ${this.renderGroup("Channels",e.filter(i=>i.position!=="upper"&&i.position!=="lower"))} ${o&&!this.hideReadings?re.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>`:re.nothing} ${this.renderGates(r)} ${e.length>0||r.length>0?re.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>`:re.nothing}</div>`}renderGroup(t,e,r){return e.length===0?re.nothing:re.html`<div class="section" part="section channels"><h3>${t}</h3>${r&&!this.hideReadings?re.html`<p class="note">${r}</p>`:re.nothing} ${e.map(a=>re.html`<div class="row"><span class="gates">${a.gateA}-${a.gateB}</span> <span class="cname">${a.name??""} ${a.circuit?re.html`<span class="circuit">${a.circuit} circuit</span>`:re.nothing} </span><span class="badge ${a.defined?"defined":"open"}">${a.defined?"Defined":"Open"}</span> ${a.isCore?re.html`<span class="badge core">Core</span>`:re.nothing} <span class="held">Gate ${a.gateA} held by ${Fs(a.gateAHeldBy)}. Gate ${a.gateB} held by ${Fs(a.gateBHeldBy)}.</span></div>`)}</div>`}renderGates(t){if(t.length===0)return re.nothing;let e=t.filter(r=>r.filled).length;return re.html`<div class="section" part="section gates"><h3>Gates (${e} of ${t.length} filled)</h3>${this.hideReadings?re.nothing:re.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>`} ${t.map(r=>re.html`<div class="row"><span class="gate-id">${r.gate}</span> <span class="cname">${r.gateName??""}</span> ${r.filled?re.html`<span class="who">Held by ${Fs(r.heldBy)}</span>`:re.html`<span class="badge gap">Gap</span>`}</div>`)}</div>`}renderEmpty(){return re.html`<div class="roxy-empty" role="status">No penta data</div>`}};$t.styles=[y,Mr,re.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600)}.section{border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem)}.section h3{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.note{margin:var(--roxy-space-xs,.25rem) 0 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-sm,.5rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;display:flex}.row:last-child{border-bottom:none}.gates,.gate-id{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600);min-width:3.5rem}.cname{flex:1;min-width:8rem}.circuit{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);display:block}.held{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);flex-basis:100%;line-height:1.6}.who{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.badge{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);padding:1px 8px;display:inline-flex}.badge.defined{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.badge.open{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 45%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.core{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a)}.badge.gap{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.footnote{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0;line-height:1.6}`],$t=p([(0,Ao.customElement)("roxy-hd-penta")],$t);var Ul="ABCDE";function Fs(n){let t=(n??[]).map(e=>Ul[e]??String(e+1));return t.length>0?t.join(", "):"nobody"}var Je=require("lit"),Do=require("lit/decorators.js");var wt=class extends g{renderEmpty(){return Je.html`<div class="roxy-empty" role="status">${this.t("No Human Design data")}</div>`}renderData(t){return Wl(t)?this.renderType(t):this.renderProfile(t)}renderType(t){return Je.html`<div class="wrap" part="card"><header class="head" part="header"><h2 class="title">${this.t("Type")}</h2>${t.type||t.profile?Je.html`<div class="type-line">${[b(t,"type"),t.profile?this.t("Profile {{profile}}",{profile:t.profile}):""].filter(Boolean).join(" \xB7 ")}</div>`:Je.nothing}</header>${wr([{label:this.t("Type"),value:b(t,"type")},{label:this.t("Strategy"),value:b(t,"strategy")},{label:this.t("Authority"),value:b(t,"authority")},{label:this.t("Profile"),value:t.profile}])} ${t.typeDescription&&!this.hideReadings?Je.html`<p class="lead">${t.typeDescription}</p>`:Je.nothing} ${za(t.signature?b(t,"signature"):void 0,t.notSelf?b(t,"notSelf"):void 0,this.translator)} ${this.renderInterpretation([{label:this.t("Strategy"),aside:b(t,"strategy"),body:t.strategyDescription},{label:this.t("Authority"),aside:b(t,"authority"),body:t.authorityDescription},{label:this.t("Aura"),body:t.aura}],"hd-type-reading")}</div>`}renderProfile(t){return Je.html`<div class="wrap" part="card"><header class="head" part="header"><h2 class="title">${this.t("Profile")}</h2>${t.profile?Je.html`<div class="type-line">${t.profile}</div>`:Je.nothing}</header>${wr([{label:this.t("Profile"),value:t.profile},{label:this.t("Personality line"),value:t.personalityLine?.toString()},{label:this.t("Design line"),value:t.designLine?.toString()}])} ${this.hideReadings?Je.nothing:Je.html`<section class="block" part="section lines"><h3>${this.t("Lines")}</h3>${Ea({personality:t.personalityKeynote,personalityLine:t.personalityLine,design:t.designKeynote,designLine:t.designLine},this.translator)}</section>`}</div>`}};wt.styles=[y,O,K,Mr,Je.css`.wrap{background:var(--roxy-surface,#fff);width:100%;color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.type-line{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}`],wt=p([(0,Do.customElement)("roxy-hd-type-card")],wt);function Wl(n){return typeof n.type=="string"}var Q=require("lit"),zo=require("lit/decorators.js");var kt=class extends g{renderData(t){let e=[...t.arrows??[]].sort((r,a)=>To(r.position)-To(a.position));return Q.html`<div class="wrap" part="card" aria-label="${this.t("Human Design variables")}"><h2 class="title" part="header">${this.t("Variables")}</h2><div class="grid" part="details arrows">${e.map(r=>this.renderArrow(r))}</div>${t.confident===!1?Q.html`<p class="note" role="note">${typeof t.confidenceMarginDeg=="number"?this.t("Low confidence: a birth time near a color or tone boundary (within {{margin}}\xB0). Verify the exact birth time.",{margin:t.confidenceMarginDeg}):this.t("Low confidence: a birth time near a color or tone boundary. Verify the exact birth time.")}</p>`:Q.nothing} ${this.renderReading(e,t.baseDescription)}</div>`}renderArrow(t){let e=t.direction==="left"?"\u2190":"\u2192",r=b(t,"baseName");return Q.html`<div class="arrow"><div class="arrow-head"><span class="glyph" aria-hidden="true">${e}</span> <span class="name">${b(t,"name")}</span></div>${t.layer?Q.html`<span class="layer">${b(t,"layer")}</span>`:Q.nothing} <span class="labels">${[b(t,"directionLabel"),b(t,"colorLabel")].filter(Boolean).join(" \xB7 ")} </span>${typeof t.color=="number"?Q.html`<span class="ctb">${this.t("Color {{color}} \xB7 Tone {{tone}} \xB7 Base {{base}}",{color:t.color,tone:t.tone??"",base:t.base??""})}${r?`, ${r}`:""}</span>`:Q.nothing} ${t.activation?.planet?Q.html`<span class="ctb">${[t.activation.planet,Ta(t.activation.side,this.translator)].filter(Boolean).join(" \xB7 ")}</span>`:Q.nothing} ${t.confident===!1?Q.html`<span class="note" role="note">${this.t("Knife-edge: could flip with a more precise birth time.")}</span>`:Q.nothing}</div>`}renderReading(t,e){let r=t.filter(o=>o.description||o.colorMeaning);if(r.length===0||this.hideReadings)return Q.nothing;let a=new Map;for(let o of r){let i=o.layer??"",l=a.get(i);l?l.push(o):a.set(i,[o])}let s=0;return Q.html`<section class="block" part="section readings"><h3>${this.t("Reading")}</h3>${[...a].map(([o,i])=>Q.html`<div class="group">${o?Q.html`<p class="group-head">${b(i[0],"layer")}</p>`:Q.nothing} ${i[0]?.layerDescription?Q.html`<p class="group-note">${i[0].layerDescription}</p>`:Q.nothing} ${i.map(l=>this.renderArrowReading(l,s++===0))}</div>`)} ${e?Q.html`<p class="footnote">${this.t("Base")}. ${e}</p>`:Q.nothing}</section>`}renderArrowReading(t,e){let r=t.cognition,a=r?b(r,"label"):"",s=[{label:this.t("Color"),body:t.colorMeaning},{label:this.t("Tone"),body:t.toneMeaning},{label:this.t("Direction"),body:t.directionMeaning},{label:a?`${this.t("Cognition")} \xB7 ${a}`:this.t("Cognition"),body:r?.description}].filter(o=>!!o.body);return Q.html`<details class="interp-card" part="reading" name="hd-variable" ?open="${e}"><summary><span class="interp-lead">${b(t,"name")}</span> ${te()} ${t.position?Q.html`<span class="interp-aside"><small>${b(t,"position")}</small></span>`:Q.nothing}</summary><div class="interp-body">${t.description?Q.html`<p>${t.description}</p>`:Q.nothing} ${s.length>0?Q.html`<dl class="facets">${s.map(o=>Q.html`<dt>${o.label}</dt><dd>${o.body}</dd>`)}</dl>`:Q.nothing}</div></details>`}renderEmpty(){return Q.html`<div class="roxy-empty" role="status">${this.t("No variables data")}</div>`}};kt.styles=[y,O,K,Q.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.arrow{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-xs,.25rem);align-content:start;display:grid}.arrow-head{align-items:center;gap:var(--roxy-space-sm,.5rem);display:flex}.glyph{color:var(--roxy-accent-ink,#b45309);font-size:1.75rem;line-height:1}.name{font-weight:var(--roxy-weight-bold,600)}.layer{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.labels{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.ctb{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums}.note{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-warning-fg,#9a3412)}@container (width<=28rem){.grid{grid-template-columns:minmax(0,1fr)}}.group{margin-bottom:var(--roxy-space-md,1rem)}.group:last-of-type{margin-bottom:0}.group-head{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.group-note{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:1.6}.facets{gap:var(--roxy-space-xs,.25rem);margin:0;display:grid}.facets dt{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.facets dd{margin:0}.footnote{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0;line-height:1.6}`],kt=p([(0,zo.customElement)("roxy-hd-variables")],kt);function To(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 qe=require("lit"),Eo=require("lit/decorators.js");var Jl={udaya:"Rose",asta:"Set"},Xl={udaya:"rises",asta:"sets"},St=class extends g{renderEmpty(){return qe.html`<div class="roxy-empty" role="status">No heliacal data</div>`}renderData(t){let e=t.grahas??[];return e.length?qe.html`<div class="wrap" aria-label="Heliacal visibility"><header class="head"><h2 class="title">Heliacal rising and setting</h2><p class="sub">Whether each graha stands far enough from the Sun to be seen, for ${t.date}. The Sun and the nodes never appear here: they have no heliacal event.</p></header><div class="rows">${e.map(r=>this.renderGraha(r))}</div></div>`:this.renderEmpty()}renderGraha(t){let e=k(t.graha)??"";return qe.html`<article class="row"><div class="row-top"><span class="graha">${e?qe.html`<span class="glyph">${e}</span>`:qe.nothing}${t.graha} </span><span class="state ${t.visible?"visible":"invisible"}">${t.visible?"Visible":"Invisible"} </span>${t.retrograde?qe.html`<span class="retro" title="retrograde">R</span>`:qe.nothing}</div><p class="window">${this.windowLine(t)}</p><p class="meta">${this.metaLine(t)}</p></article>`}windowLine(t){let e=t.nextEvent,r=t.lastEvent;if(e){let a=Xl[e.type],s=e.horizon==="east"?"in the east":"in the west";return qe.html`${t.visible?"Visible until it":"Invisible until it"} ${a} ${s} on <strong>${Oe(this.effectiveLang(),e.datetime)}</strong>`}return r?qe.html`${Jl[r.type]} ${r.horizon==="east"?"in the east":"in the west"} on <strong>${Oe(this.effectiveLang(),r.datetime)}</strong>, with no further event inside the search window`:qe.html`No rising or setting inside the search window, which is normal for a graha far from the Sun`}metaLine(t){let e=t.horizon==="east"?"a morning graha, read before sunrise":"an evening graha, read after sunset",r=t.nextEvent??t.lastEvent,a=r&&r.kalamsa!==t.kalamsa;return qe.html`<span class="num">${x(t.timeDegrees,2)}°</span> of time from the Sun against a limit of <span class="num">${x(t.kalamsa,0)}°</span>${a?qe.html`, becoming <span class="num">${x(r.kalamsa,0)}°</span> at that event`:""} · ${e}`}};St.styles=[y,qe.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sub{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:0}.rows{display:grid}.row{gap:var(--roxy-space-xs,.25rem);padding:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);grid-template-columns:minmax(0,1fr);display:grid}.row-top{align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.graha{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.35em}.state{font-size:var(--roxy-text-xs,.75rem);border-radius:var(--roxy-radius-sm,4px);border:1px solid var(--roxy-border,#e4e4e7);color:var(--roxy-fg,#0a0a0a);padding:.1rem .45rem}.state.invisible{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 14%, transparent)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600)}.window{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.num{font-variant-numeric:tabular-nums}`],St=p([(0,Eo.customElement)("roxy-heliacal-table")],St);var J=require("lit"),Mo=require("lit/decorators.js");var Rt=class extends g{resolveHexagram(){let t=this.data;if(!t)return null;if("hexagram"in t&&t.hexagram){if("lines"in t){let r=t;return{hex:r.hexagram,lines:r.lines,changingLinePositions:r.changingLinePositions,resultingHexagram:r.resultingHexagram}}let e=t;return{hex:e.hexagram,dailyMessage:e.dailyMessage}}return{hex:t}}renderEmpty(){return J.html`<div class="roxy-empty" role="status">No hexagram data</div>`}renderData(){let t=this.resolveHexagram();if(!t)return this.renderEmpty();let{hex:e,lines:r,changingLinePositions:a,dailyMessage:s,resultingHexagram:o}=t,i=r??this.derivedLines(e),l=new Set(a??[]),d=!this.hideReadings;return J.html`<article class="card" part="card" aria-label="I Ching hexagram"><div class="glyphs" part="chart">${e.symbol?J.html`<div class="symbol">${e.symbol}</div>`:J.nothing}<div class="lines" aria-hidden="true">${i.slice().reverse().map((m,c)=>{let u=i.length-1-c+1,z=l.has(u),$=m===6||m===8;return J.html`<div class="line ${`${$?"broken":"solid"}${z?" changing":""}`}">${$?J.svg`<span class="seg"></span><span class="seg"></span>`:J.svg`<span class="seg"></span>`}</div>`})}</div></div><div part="header"><h2 class="title">${[e.number!=null?`${e.number}.`:"",e.english??e.chinese??"Hexagram"].filter(Boolean).join(" ")}</h2><p class="subtitle">${e.chinese?J.html`${e.chinese}`:J.nothing} ${e.pinyin?J.html`· ${e.pinyin}`:J.nothing}</p><div class="trigrams" part="details">${e.upperTrigram?J.html`<div>Upper <span class="tri-glyph">${xs(e.upperTrigram)??""}</span>${e.upperTrigram}</div>`:J.nothing} ${e.lowerTrigram?J.html`<div>Lower <span class="tri-glyph">${xs(e.lowerTrigram)??""}</span>${e.lowerTrigram}</div>`:J.nothing}</div>${e.judgment&&d?J.html`<p class="judgment">${e.judgment}</p>`:J.nothing} ${e.image&&d?J.html`<p class="image">${e.image}</p>`:J.nothing} ${s&&d?J.html`<p class="message">${s}</p>`:J.nothing} ${e.interpretation?.general&&d?J.html`<p>${e.interpretation.general}</p>`:J.nothing} ${l.size>0?J.html`<div class="changing" part="section changing-lines">Changing lines: ${Array.from(l).sort((m,c)=>m-c).join(", ")}. ${o?.english?J.html`Becomes hexagram ${o.number} ${o.english}.`:J.nothing}</div>`:J.nothing} ${this.renderLines(e,l)}</div></article>`}renderLines(t,e){let r=t.changingLines??[];if(r.length===0)return J.nothing;let a=e.size>0,s=a?r.filter(i=>e.has(i.position)):r;if(s.length===0)return J.nothing;let o=s.map(i=>({label:`Line ${i.position}`,body:i.text??"",extra:i.meaning?J.html`<p class="line-meaning">${i.meaning}</p>`:J.nothing}));return this.renderInterpretation(o,"hexagram-lines",a?"Changing lines":"Lines")}derivedLines(t){let e=t.binary??"";return/^[01]{6}$/.test(e)?Array.from(e,r=>r==="1"?7:8):Array.from({length:6},()=>7)}};Rt.styles=[y,O,K,J.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-lg,1.5rem);grid-template-columns:6rem 1fr;display:grid}@container (width<=480px){.card{grid-template-columns:1fr}}.glyphs{gap:var(--roxy-space-md,1rem);align-content:start;align-self:start;justify-items:center;display:grid}.symbol{color:var(--roxy-accent-ink,#b45309);font-size:3rem;line-height:1}.lines{gap:4px;width:4rem;display:grid}.line{justify-content:center;align-items:center;gap:4px;height:8px;display:flex}.seg{background:var(--roxy-fg,#0a0a0a);border-radius:1px;height:6px;display:block}.line.broken .seg{width:1.4rem}.line.solid .seg{width:3rem}.line.changing .seg{background:var(--roxy-accent,#f59e0b)}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0 0 var(--roxy-space-sm,.5rem)}.trigrams{gap:var(--roxy-space-md,1rem);margin-bottom:var(--roxy-space-sm,.5rem);color:var(--roxy-secondary,#475569);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;display:flex}.tri-glyph{font-size:var(--roxy-text-xl,1.5rem);color:var(--roxy-accent-ink,#b45309);vertical-align:middle;margin-right:4px}.judgment,.image,.message{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a)}.judgment:before{content:"Judgment. ";font-weight:var(--roxy-weight-bold,600);color:var(--roxy-secondary,#475569)}.image:before{content:"Image. ";font-weight:var(--roxy-weight-bold,600);color:var(--roxy-secondary,#475569)}.line-meaning{padding-left:var(--roxy-space-sm,.5rem);border-left:2px solid var(--roxy-border,#e4e4e7);color:var(--roxy-muted,#71717a);margin:0}.changing{margin-top:var(--roxy-space-md,1rem);padding-top:var(--roxy-space-md,1rem);border-top:1px solid var(--roxy-border,#e4e4e7);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-sm,.875rem)}`],Rt=p([(0,Mo.customElement)("roxy-hexagram")],Rt);var nr=require("lit"),Po=require("lit/decorators.js");var Ct=class extends g{renderEmpty(){return nr.html`<div class="roxy-empty" role="status">No hora data</div>`}renderData(t){let e=t.dayHoras??[],r=t.nightHoras??[];return e.length===0&&r.length===0?this.renderEmpty():nr.html`<div class="wrap" aria-label="Hora periods"><div class="head"><h2 class="title">Hora</h2>${t.date?nr.html`<p class="subtitle">${D(this.effectiveLang(),t.date)}</p>`:nr.nothing}</div><div class="cols">${this.renderColumn("Day",e)} ${this.renderColumn("Night",r)}</div></div>`}renderColumn(t,e){return e.length===0?nr.nothing:nr.html`<div class="col"><p class="section-label">${t}</p>${e.map(r=>nr.html`<div class="row"><span class="glyph" aria-hidden="true">${k(r.planet)??"\xB7"}</span> <span class="planet">${r.planet}</span> <span class="time">${Tr(this.effectiveLang(),r)}</span> ${typeof r.number=="number"?nr.html`<span class="num">${r.number}</span>`:nr.nothing}</div>`)}</div>`}};Ct.styles=[y,nr.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.cols{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}.section-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin:0 0 var(--roxy-space-xs,.25rem) 0}.row{align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-xs,.25rem) 0;border-bottom:1px solid var(--roxy-border,#e4e4e7);font-size:var(--roxy-text-sm,.875rem);display:flex}.row:last-child{border-bottom:none}.glyph{color:var(--roxy-accent-ink,#b45309);text-align:center;width:1.25em;font-size:1.15em;line-height:1}.planet{flex:1;font-weight:500}.time{color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums;white-space:nowrap}.num{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;text-align:right;width:1.5em}@container (width<=30rem){.cols{grid-template-columns:1fr}}`],Ct=p([(0,Po.customElement)("roxy-hora-table")],Ct);var C=require("lit"),es=require("lit/decorators.js");var Hr=class extends g{constructor(){super(...arguments);this.period="daily"}renderEmpty(){return C.html`<div class="roxy-empty" role="status">No horoscope data</div>`}renderData(e){let r=e.sign??"",a=q(r)??"",s="energyRating"in e&&typeof e.energyRating=="number"?e.energyRating:null,o="date"in e&&e.date&&D(this.effectiveLang(),e.date)||"week"in e&&e.week||"month"in e&&e.month||"";return C.html`<article class="card" part="card" aria-label="${`${this.period} horoscope for ${r}`}"><header class="head" part="header"><span class="glyph" aria-hidden="true">${a}</span><div><h2 class="title">${r} ${this.period}</h2>${o?C.html`<div class="date">${o}</div>`:C.nothing}</div>${s!==null?C.html`<span class="energy" part="details" aria-label="${`Energy ${s} of 10`}">Energy ${s}/10 <span class="energy-bar"><span style="width:${s/10*100}%"></span></span></span>`:C.nothing}</header>${e.overview&&!this.hideReadings?C.html`<p class="overview">${e.overview}</p>`:C.nothing} ${this.renderSky(e)} ${this.hideReadings?C.nothing:C.html`<div class="sections" part="section outlook">${e.love?C.html`<div class="section"><h3>Love</h3><p>${e.love}</p></div>`:C.nothing} ${e.career?C.html`<div class="section"><h3>Career</h3><p>${e.career}</p></div>`:C.nothing} ${e.health?C.html`<div class="section"><h3>Health</h3><p>${e.health}</p></div>`:C.nothing} ${e.finance?C.html`<div class="section"><h3>Finance</h3><p>${e.finance}</p></div>`:C.nothing} ${"advice"in e&&e.advice?C.html`<div class="section"><h3>Advice</h3><p>${e.advice}</p></div>`:C.nothing}</div>`} ${this.renderMonth(e)} ${(()=>{let i="luckyNumber"in e&&e.luckyNumber!==void 0?e.luckyNumber:void 0,l="luckyColor"in e&&e.luckyColor?e.luckyColor:"",d="luckyNumbers"in e&&e.luckyNumbers?e.luckyNumbers:[],m="luckyDays"in e&&e.luckyDays?e.luckyDays:[],c=e.compatibleSigns??[];return i===void 0&&!l&&d.length===0&&m.length===0&&c.length===0?C.nothing:C.html`<div class="lucky" part="details">${i!==void 0?C.html`<span>Lucky number <strong>${i}</strong></span>`:C.nothing} ${l?C.html`<span>Lucky color <strong>${l}</strong></span>`:C.nothing} ${d.length?C.html`<span>Lucky numbers <strong>${d.join(", ")}</strong></span>`:C.nothing} ${m.length?C.html`<span>Lucky days <strong>${m.join(", ")}</strong></span>`:C.nothing} ${c.length?C.html`<span class="compat-wrap">Best with <span class="compat">${c.map(u=>C.html`<span>${u}</span>`)}</span></span>`:C.nothing}</div>`})()}</article>`}renderSky(e){let r="moonSign"in e?e.moonSign:"",a="moonPhase"in e?e.moonPhase:"",s=("activeTransits"in e?e.activeTransits:[])??[];if(!r&&!a&&s.length===0)return C.nothing;let o=q(r)??"";return C.html`<div class="sky" part="section sky">${r||a?C.html`<div class="moon-line">${r?C.html`<span><span class="lbl">Moon</span> <span aria-hidden="true">${o}</span> <b>${r}</b></span>`:C.nothing} ${a?C.html`<span><span class="lbl">Phase</span> <b>${a}</b></span>`:C.nothing}</div>`:C.nothing} ${s.length?C.html`<ul class="transits" aria-label="Active transits">${s.map(i=>C.html`<li>${i}</li>`)}</ul>`:C.nothing}</div>`}renderMonth(e){let r=("weekByWeek"in e?e.weekByWeek:[])??[],a=("keyDates"in e?e.keyDates:[])??[];return r.length===0&&a.length===0?C.nothing:C.html`${r.length&&!this.hideReadings?C.html`<section part="section week-by-week"><h3 class="block-title">Week by week</h3><div class="weeks">${r.map(s=>C.html`<div class="week"><span class="week-no">Week ${s.week}</span><div><div class="week-focus">${s.focus}</div>${s.advice?C.html`<p class="week-advice">${s.advice}</p>`:C.nothing}</div></div>`)}</div></section>`:C.nothing} ${a.length?C.html`<section part="section key-dates"><h3 class="block-title">Key dates</h3><dl class="dates">${a.map(s=>C.html`<div class="date-row"><dt>${D(this.effectiveLang(),s.date)||s.date}</dt><dd>${s.event}</dd></div>`)}</dl></section>`:C.nothing}`}};Hr.styles=[y,C.css`.card{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{align-items:center;gap:var(--roxy-space-md,1rem);display:flex}.glyph{color:var(--roxy-accent-ink,#b45309);font-size:2.25rem;line-height:1}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);text-transform:capitalize;margin:0}.date{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a)}.energy{font-variant-numeric:tabular-nums;font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569);margin-left:auto}.energy-bar{background:var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-full,9999px);vertical-align:middle;width:6rem;height:6px;margin-left:6px;display:inline-block;overflow:hidden}.energy-bar>span{background:var(--roxy-accent,#f59e0b);height:100%;transition:width var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.overview{font-size:var(--roxy-text-base,1rem);color:var(--roxy-fg,#0a0a0a);margin:0}.sections{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(12rem,1fr));display:grid}.section h3{margin:0 0 var(--roxy-space-xs,.25rem) 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em}.section p{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:0}.lucky{gap:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-secondary,#475569);flex-wrap:wrap;display:flex}.lucky strong{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}.compat-wrap{align-items:center;gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;width:100%;display:flex}.compat{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.compat span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 16%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);text-transform:capitalize;padding:2px 8px}.sky{gap:var(--roxy-space-sm,.5rem);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);display:grid}.moon-line{align-items:baseline;gap:.35rem var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;display:flex}.moon-line b{font-weight:var(--roxy-weight-bold,600)}.moon-line .lbl{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin-right:.35rem}.transits{gap:.25rem;margin:0;padding:0;list-style:none;display:grid}.transits li{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);padding-left:.9rem;position:relative}.transits li:before{content:"";background:var(--roxy-accent,#f59e0b);border-radius:50%;width:5px;height:5px;position:absolute;top:.5em;left:0}.block-title{margin:0 0 var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em}.weeks{gap:var(--roxy-space-sm,.5rem);display:grid}.week{gap:var(--roxy-space-sm,.5rem);border-top:1px solid var(--roxy-border,#e4e4e7);padding-top:var(--roxy-space-sm,.5rem);grid-template-columns:3.5rem 1fr;align-items:baseline;display:grid}.week:first-child{border-top:0;padding-top:0}.week-no{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.week-focus{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem)}.week-advice{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);margin:.15rem 0 0}.dates{gap:.3rem var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);grid-template-columns:max-content 1fr;margin:0;display:grid}.date-row{display:contents}.date-row dt{font-variant-numeric:tabular-nums;color:var(--roxy-accent-ink,#b45309);font-weight:var(--roxy-weight-bold,600);white-space:nowrap}.date-row dd{color:var(--roxy-fg,#0a0a0a);margin:0}`],p([(0,es.property)({type:String,reflect:!0})],Hr.prototype,"period",2),Hr=p([(0,es.customElement)("roxy-horoscope-card")],Hr);var N=require("lit"),ts=require("lit/decorators.js");var Ql=[{id:"planets",label:"Planets"},{id:"cusps",label:"Cusps"},{id:"significators",label:"Significators"}],rs=[1,2,3,4];function _s(n,t){return n?typeof t=="number"?`${n} ${t}`:n:""}function No(n){return[...new Set(n.map(String))].join(" > ")}function ed(n){return[...new Set(n??[])]}var jr=class extends g{constructor(){super(...arguments);this.activeTab="planets"}bodies(){let e=this.data;if(!e)return[];let r=(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})),a=e.nodes;for(let[s,o]of[["Rahu",a?.rahu],["Ketu",a?.ketu]])o&&r.push({name:s,longitude:o.longitude,house:o.house,nakshatra:o.nakshatra,starLord:o.starLord,subLord:o.subLord,subSubLord:o.subSubLord,kpNumber:o.kpNumber,retrograde:!0});return r}renderEmpty(){return N.html`<div class="roxy-empty" role="status">No KP chart data</div>`}renderData(e){let r=e.ascendant;return N.html`<div class="wrap" aria-label="KP chart" tabindex="0"><header class="head"><h2 class="title">KP chart</h2>${r?N.html`<div class="asc">Ascendant: <strong>${typeof r.longitude=="number"?Ue(r.longitude):r.sign??""} </strong>${r.nakshatra?N.html`· ${_s(r.nakshatra,r.pada)}`:N.nothing} ${r.subLord?N.html`· sub lord ${r.subLord}`:N.nothing} ${typeof r.kpNumber=="number"?N.html`· KP ${r.kpNumber}`:N.nothing}</div>`:N.nothing} ${typeof e.meta?.ayanamsa=="number"?N.html`<div class="ayan">Ayanamsa: ${_t(e.meta.ayanamsaType,e.meta.ayanamsa)} ${e.meta.houseSystem?N.html`· ${e.meta.houseSystem} houses`:N.nothing}</div>`:N.nothing}</header>${_e({items:Ql,active:this.activeTab,onSelect:a=>{this.activeTab=a},label:"KP chart views",idPrefix:"kp",controls:!0})}<div id="kp-panel-${this.activeTab}" 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?N.html`<table role="table"><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">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(r=>N.html`<tr><td class="body">${r.name}${r.retrograde?N.html`<span class="retro">R</span>`:N.nothing}</td><td class="num">${typeof r.longitude=="number"?Ue(r.longitude):""}</td><td class="num">${typeof r.house=="number"?r.house:""}</td><td>${_s(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>`:N.html`<p class="roxy-empty" role="status">No planets</p>`}renderCusps(){let e=this.data?.cusps??[],r=this.data?.houseThemes;return e.length?N.html`<table role="table"><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(a=>N.html`<tr><td class="body num">${a.house}${this.renderThemes(ws(a.house,r))}</td><td class="num">${typeof a.longitude=="number"?Ue(a.longitude):a.sign??""}</td><td>${a.signLord??""}</td><td>${_s(a.nakshatra,a.pada)}</td><td>${a.starLord??""}</td><td>${a.subLord??""}</td><td>${a.subSubLord??""}</td><td class="num">${typeof a.kpNumber=="number"?a.kpNumber:""}</td></tr>`)}</tbody></table>`:N.html`<p class="roxy-empty" role="status">No cusps</p>`}renderSignificators(){let e=this.data?.significators,r=this.data?.houseThemes,a=e?.houseWise??[],s=e?.planetWise??[];return!a.length&&!s.length?N.html`<p class="roxy-empty" role="status">No significators</p>`:N.html`${this.renderLevelLegend(a)} ${a.length?N.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><table role="table"><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>${rs.map(o=>N.html`<th scope="col">L${o}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${a.map(o=>N.html`<tr><td class="body num">${o.house}${this.renderThemes(ws(o.house,r))}</td>${rs.map(i=>this.renderCell(this.planetsAtLevel(o,i).join(", ")))}<td class="chain">${No(o.all??[])}</td></tr>`)}</tbody></table>`:N.nothing} ${s.length?N.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><table role="table"><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>${rs.map(o=>N.html`<th scope="col">L${o}</th>`)}<th scope="col">Strength order</th></tr></thead><tbody>${s.map(o=>N.html`<tr><td class="body">${o.planet}</td>${rs.map(i=>this.renderCell(this.housesAtLevel(o,i).join(", ")))}<td class="chain">${No(o.allHouses??[])}${this.renderThemes(ur(ed(o.allHouses),r))}</td></tr>`)}</tbody></table>`:N.nothing}`}renderThemes(e){return e?N.html`<span class="themes">${e}</span>`:N.nothing}renderCell(e){return e?N.html`<td>${e}</td>`:N.html`<td class="empty-cell">none</td>`}planetsAtLevel(e,r){return(e.significators??[]).filter(a=>a.level===r).flatMap(a=>a.planets??[])}housesAtLevel(e,r){return(e.signifies??[]).filter(a=>a.level===r).flatMap(a=>a.houses??[])}renderLevelLegend(e){let r=new Map;for(let a of e)for(let s of a.significators??[])s.description&&!r.has(s.level)&&r.set(s.level,s.description);return r.size===0?N.nothing:N.html`<ul class="legend" aria-label="Significator levels">${[...r.entries()].sort((a,s)=>a[0]-s[0]).map(([a,s])=>N.html`<li><b>L${a}</b>${s}</li>`)}</ul>`}};jr.styles=[y,Ee,N.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);width:100%;overflow:auto}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);gap:var(--roxy-space-xs,.25rem);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.asc,.ayan{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.asc strong{color:var(--roxy-fg,#0a0a0a)}.roxy-tablist{padding:0 var(--roxy-space-md,1rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:620px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}td.body{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);margin-left:4px}.num{font-variant-numeric:tabular-nums}.sig-head{padding:var(--roxy-space-md,1rem) var(--roxy-space-md,1rem) 0;gap:var(--roxy-space-xs,.25rem);display:grid}.sig-title{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);margin:0}.sig-note{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);margin:0}.legend{gap:var(--roxy-space-xs,.25rem) var(--roxy-space-md,1rem);padding:var(--roxy-space-md,1rem) var(--roxy-space-md,1rem) 0;color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);flex-wrap:wrap;margin:0;list-style:none;display:flex}.legend b{color:var(--roxy-accent-ink,#b45309);margin-right:4px}.chain,.empty-cell{color:var(--roxy-muted,#71717a)}.themes{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-normal,400);text-transform:none;letter-spacing:normal;display:block}`],p([(0,ts.state)()],jr.prototype,"activeTab",2),jr=p([(0,ts.customElement)("roxy-kp-chart")],jr);var gr=require("lit"),Go=require("lit/decorators.js");var At=class extends g{renderEmpty(){return gr.html`<div class="roxy-empty" role="status">No KP data</div>`}renderData(t){let e=t.planets??[];return gr.html`<div class="wrap" aria-label="KP planets table" tabindex="0"><header class="head"><h2 class="title">KP planets</h2>${typeof t.ayanamsa=="number"?gr.html`<span class="ayanamsa">Ayanamsa: ${x(t.ayanamsa,2)}°</span>`:gr.nothing}</header><table role="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(r=>gr.html`<tr><td class="planet">${r.planet} ${r.retrograde?gr.html`<span class="retro">R</span>`:gr.nothing}</td><td>${r.sign??""}</td><td>${r.signLord??""}</td><td>${r.nakshatra??""}</td><td>${r.nakshatraLord??""}</td><td>${r.subLord??""}</td><td>${r.subSubLord??""}</td><td>${r.kpNumber??""}</td></tr>`)}</tbody></table></div>`}};At.styles=[y,gr.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:auto}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);justify-content:space-between;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.ayanamsa{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:560px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}td.planet{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);margin-left:4px}`],At=p([(0,Go.customElement)("roxy-kp-planets-table")],At);var Ve=require("lit"),Bo=require("lit/decorators.js");var Dt=class extends g{renderEmpty(){return Ve.html`<div class="roxy-empty" role="status">No ruling planets data</div>`}renderData(t){let e=t.significators??[];return Ve.html`<div class="wrap" aria-label="KP ruling planets"><header><h2 class="title">KP ruling planets</h2>${t.dayLord?Ve.html`<div class="day-lord">Day lord: <strong>${t.dayLord}</strong></div>`:Ve.nothing}</header><div class="groups"><div class="group"><h3>Moon</h3><dl><dt>Sign lord</dt><dd>${t.moonSignLord??""}</dd><dt>Star lord</dt><dd>${t.moonStarLord??""}</dd><dt>Sub lord</dt><dd>${t.moonSublord??""}</dd><dt>Sub-sub lord</dt><dd>${t.moonSubSublord??""}</dd></dl></div><div class="group"><h3>Lagna</h3><dl><dt>Sign lord</dt><dd>${t.lagnaSignLord??""}</dd><dt>Star lord</dt><dd>${t.lagnaStarLord??""}</dd><dt>Sub lord</dt><dd>${t.lagnaSublord??""}</dd><dt>Sub-sub lord</dt><dd>${t.lagnaSubSublord??""}</dd></dl></div></div>${t.rulingPlanets?.length?Ve.html`<div class="rp-list" role="list" aria-label="Ruling planets by strength"><span class="rp-label">Ruling planets</span> ${t.rulingPlanets.map((r,a)=>Ve.html`<span class="rp" role="listitem"><span class="rank">${a+1}</span> ${r}</span>`)}</div>`:Ve.nothing} ${e.length?Ve.html`<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(r=>{let a=ur(r.signifies,t.houseThemes);return Ve.html`<tr><td>${r.planet}</td><td><span class="num">${(r.signifies??[]).join(", ")}</span> ${a?Ve.html`<span class="themes">${a}</span>`:Ve.nothing}</td></tr>`})}</tbody></table>`:Ve.nothing}</div>`}};Dt.styles=[y,Ve.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);padding:var(--roxy-space-md,1rem);gap:var(--roxy-space-md,1rem);box-shadow:var(--roxy-shadow-sm);grid-template-columns:minmax(0,1fr);display:grid}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.day-lord{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.day-lord strong{color:var(--roxy-fg,#0a0a0a)}.groups{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));display:grid}.group h3{margin:0 0 var(--roxy-space-xs,.25rem);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em}.group dl{gap:2px var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);grid-template-columns:auto 1fr;margin:0;display:grid}.group dt{color:var(--roxy-muted,#71717a)}.group dd{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600);margin:0}.rp-list{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;align-items:center;display:flex}.rp-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.05em;margin-right:var(--roxy-space-xs,.25rem)}.rp{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 18%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:999px;align-items:center;gap:.3em;padding:.15em .6em;display:inline-flex}.rp .rank{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-accent-ink,#b45309)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-xs,.25rem) var(--roxy-space-sm,.5rem);text-align:left;border-bottom:1px solid var(--roxy-border,#e4e4e7)}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}.num{font-variant-numeric:tabular-nums}.themes{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);display:block}`],Dt=p([(0,Bo.customElement)("roxy-kp-ruling-planets")],Dt);var $e=require("lit"),Oo=require("lit/decorators.js");var Ks=320,cr=Ks/2,Cr=128,rd=118,td=140,ad=150;function Ar(n,t){let e=n*Math.PI/180;return{x:cr+t*Math.sin(e),y:cr-t*Math.cos(e)}}var sd=[{az:0,label:"N"},{az:45,label:"NE"},{az:90,label:"E"},{az:135,label:"SE"},{az:180,label:"S"},{az:225,label:"SW"},{az:270,label:"W"},{az:315,label:"NW"}],Tt=class extends g{renderEmpty(){return $e.html`<div class="roxy-empty" role="status">No local space data</div>`}renderData(t){let e=t.bodies??[],r=t.birthDetails;return $e.html`<div class="wrap"><header><h2 class="title">Local space</h2>${r?$e.html`<div class="meta">${Oe(this.effectiveLang(),r.date,r.time)}</div>`:$e.nothing}</header>${this.renderDial(e)} ${t.summary?$e.html`<p class="summary">${t.summary}</p>`:$e.nothing} ${this.renderList(e)}</div>`}renderDial(t){return $e.html`<svg viewBox="0 0 ${Ks} ${Ks}" role="img" aria-label="Local space compass of planetary directions from the birthplace"><title>Local space compass</title><desc>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="${cr}" cy="${cr}" r="${Cr}"/><circle class="dial" cx="${cr}" cy="${cr}" r="${Cr*.66}" stroke-width="0.5"/><circle class="dial" cx="${cr}" cy="${cr}" r="${Cr*.33}" stroke-width="0.5"/>${this.renderCompassRing()} ${this.renderSpokes(t)}<circle class="center-dot" cx="${cr}" cy="${cr}" r="2.5"/></svg>`}renderCompassRing(){let t=[];for(let i=0;i<360;i+=22.5){let l=Ar(i,Cr),d=Ar(i,Cr-(i%45===0?8:4));t.push($e.svg`<line class="tick" x1=${d.x} y1=${d.y} x2=${l.x} y2=${l.y} />`)}let e=Ar(0,Cr),r=Ar(180,Cr),a=Ar(90,Cr),s=Ar(270,Cr),o=sd.map(({az:i,label:l})=>{let d=Ar(i,ad),m=i%90===0;return $e.svg`<text class=${`compass-label${m?" cardinal":""}`} x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${l}</text>`});return $e.svg`
|
|
83
83
|
<line class="cardinal-axis" x1=${e.x} y1=${e.y} x2=${r.x} y2=${r.y} />
|
|
84
84
|
<line class="cardinal-axis" x1=${a.x} y1=${a.y} x2=${s.x} y2=${s.y} />
|
|
85
85
|
${t}${o}`}renderSpokes(t){return t.map((e,r)=>{let a=at(e.planet,r),s=e.aboveHorizon===!1,o=Ar(e.azimuth,rd),i=Ar(e.azimuth,td),l=e.symbol||k(e.planet)||e.planet,d=`${e.altitude>0?"+":""}${Math.round(e.altitude)}\xB0`;return $e.svg`<g>
|
|
@@ -100,15 +100,15 @@
|
|
|
100
100
|
</g>`})}renderAscendants(t){let e=[],r=(a,s)=>{if(!a)return;let o=xe.findIndex(u=>u.toLowerCase()===a.sign.toLowerCase());if(o===-1)return;let i=o*30+a.degree,l=this.toAngle(i),d=s===1?Qs+14:Jt+14,m=M(ge,ge,d,l),c=M(ge,ge,Xs+14,l);e.push(R.svg`<g>
|
|
101
101
|
<line class="asc-tick" x1=${m.x} y1=${m.y} x2=${c.x} y2=${c.y} />
|
|
102
102
|
<text class="asc-label" x=${c.x} y=${c.y} text-anchor="middle" dominant-baseline="central">Asc${s}</text>
|
|
103
|
-
</g>`)};return r(t.person1?.ascendant,1),r(t.person2?.ascendant,2),e}renderInterAspectLines(t,e,r){let a=(s,o)=>{let i=Z(o);for(let l of s)if(Z(l.name)===i&&typeof l.longitude=="number")return l.longitude};return r.map(s=>{let o=a(t,s.planet1),i=a(e,s.planet2);if(o===void 0||i===void 0)return R.nothing;let l=M(ge,ge,Qs-12,this.toAngle(o)),d=M(ge,ge,Jt+8,this.toAngle(i)),m=or(s),c=vr[m]??"aspect-other",u=x(s.orb,1);return R.svg`<line class=${`aspect ${c}`} x1=${l.x} y1=${l.y} x2=${d.x} y2=${d.y}><title>${s.planet1} ${m} ${s.planet2}${u?` (orb ${u}\xB0)`:""}</title></line>`})}renderAspects(t){return R.html`<table><caption class="roxy-sr-only">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">Planet 1</th><th scope="col">Planet 2</th><th scope="col">Aspect</th><th scope="col">Orb</th><th scope="col">Strength</th></tr></thead><tbody>${t.map(e=>R.html`<tr><td>${e.planet1}</td><td>${e.planet2}</td><td>${ke(e)}</td><td class="orb">${x(e.orb,1)}</td><td>${x(e.strength,0)}</td></tr>`)}</tbody></table>`}};Gt.styles=[y,O,K,R.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.score{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold,600);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-xl,1.5rem)}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line{fill:none;stroke:var(--roxy-border,#e4e4e7)}.sign{fill:var(--roxy-secondary,#475569);font-size:14px}.p1{fill:var(--roxy-accent,#f59e0b);font-size:13px;font-weight:600}.p2{fill:var(--roxy-info,#0284c7);font-size:13px;font-weight:600}.person-tag{opacity:.85;font-size:7px;font-weight:700}.planet-deg{fill:var(--roxy-muted,#71717a);font-size:7px;font-family:var(--roxy-font-sans)}.planet-deg .retro{fill:var(--roxy-danger,#dc2626)}.asc-tick{stroke:var(--roxy-accent-ink,#b45309);stroke-width:1px;opacity:.75}.asc-label{fill:var(--roxy-accent-ink,#b45309);font-size:9px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.04em}.aspect{stroke-width:.8px;fill:none;opacity:.5}.aspect-trine,.aspect-sextile{stroke:var(--roxy-success,#16a34a)}.aspect-square,.aspect-opposition{stroke:var(--roxy-danger,#dc2626)}.aspect-conjunction{stroke:var(--roxy-accent-ink,#b45309)}.aspect-other{stroke:var(--roxy-muted,#71717a);opacity:.35}.legend-row{gap:var(--roxy-space-md,1rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin-top:calc(var(--roxy-space-xs,.25rem) * -1);flex-wrap:wrap;display:flex}.legend-row .swatch{vertical-align:middle;border-radius:50%;width:8px;height:8px;margin-right:4px;display:inline-block}.summary{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-base,1rem);margin:0}.people{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));display:grid}.person{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);gap:.3rem;display:grid}.person-name{font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);align-items:center;gap:.4rem;display:flex}.person-dot{border-radius:50%;flex-shrink:0;width:8px;height:8px}.person-dot.p1{background:var(--roxy-accent,#f59e0b)}.person-dot.p2{background:var(--roxy-info,#0284c7)}.big-three{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;gap:.25rem .75rem;display:flex}.big-three span{align-items:baseline;gap:.25rem;display:inline-flex}.big-three .lbl{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.summary-pills{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.pill{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);color:var(--roxy-fg,#0a0a0a);padding:2px 8px}.pill--success{background:color-mix(in srgb, var(--roxy-success,#16a34a) 12%, transparent);color:var(--roxy-success-fg,#166534)}.pill--danger{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 12%, transparent);color:var(--roxy-danger-fg,#991b1b)}.glyph{font-size:1.1em;line-height:1}.static-head{align-items:center;gap:var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;font-weight:500;display:flex}.asp-name{font-weight:var(--roxy-weight-bold,600);text-transform:capitalize}.asp-name.harmonious{color:var(--roxy-success-fg,#166534)}.asp-name.challenging{color:var(--roxy-danger-fg,#991b1b)}.interp-keywords{flex-wrap:wrap;gap:.25rem;display:flex}.interp-keywords .kw{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);padding:1px 8px}.context{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.catalog>summary{cursor:pointer;font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);align-items:center;gap:.5rem;display:flex}.scroll{min-width:0;margin-top:var(--roxy-space-sm,.5rem);overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}td.orb{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a)}.lists{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(14rem,1fr));display:grid}.lists h3{margin:0 0 var(--roxy-space-xs,.25rem) 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}.lists ul{padding-left:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);margin:0}.missing-planets{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);line-height:1.5}.missing-planets code{font-family:var(--roxy-font-mono,ui-monospace, SFMono-Regular, Menlo, monospace);background:color-mix(in srgb, var(--roxy-fg,#0a0a0a) 6%, transparent);border-radius:4px;padding:0 4px;font-size:.95em}`],Gt=p([(0,Xo.customElement)("roxy-synastry-chart")],Gt);var fe=require("lit"),ls=require("lit/decorators.js");var fd=[["love","Love"],["career","Career"],["finances","Finances"],["health","Health"],["spirituality","Spirituality"]],Vr=class extends g{constructor(){super(...arguments);this.orientation="upright"}renderEmpty(){return fe.html`<div class="roxy-empty" role="status">No tarot data</div>`}renderData(e){return"card"in e?this.renderDailyCard(e):this.renderFullCard(e)}renderDailyCard(e){let r=e.card,a=!!r.reversed,s=r.keywords??[],o=[r.arcana?`${r.arcana} arcana`:"",r.suit??""].filter(Boolean).join(" \xB7 "),i=!this.hideReadings;return fe.html`<article class="card" part="card" aria-label="${r.name??"Tarot card"}">${this.renderImage(r.imageUrl,r.name,a)}<div part="header"><div class="meta">${o?`${o} \xB7 `:""}<span class="drawn">${a?"drawn reversed":"drawn upright"}</span></div><h2 class="title">${r.name??"Tarot card"}</h2>${e.dailyMessage&&i?fe.html`<p class="message">${e.dailyMessage}</p>`:fe.nothing} ${r.meaning&&i?fe.html`<p class="reading">${r.meaning}</p>`:fe.nothing} ${s.length>0&&i?fe.html`<div class="chips">${s.map(l=>fe.html`<span>${l}</span>`)}</div>`:fe.nothing} ${this.renderGuidance(r,"tarot-daily-guidance")}</div></article>`}renderFullCard(e){let r=this.orientation==="reversed",a=r?e.reversed:e.upright,s=(r?e.keywords?.reversed:e.keywords?.upright)??a?.keywords??[],o=!this.hideReadings;return fe.html`<article class="card" part="card" aria-label="${e.name??"Tarot card"}">${this.renderImage(e.imageUrl,e.name,r)}<div part="header"><div class="meta">${[e.arcana?`${e.arcana} arcana`:"",e.suit??"",e.number!==void 0&&e.number!==null?`no. ${e.number}`:""].filter(Boolean).join(" \xB7 ")}</div><h2 class="title">${e.name??"Tarot card"}</h2>${_e({items:[{id:"upright",label:"Upright"},{id:"reversed",label:"Reversed"}],active:this.orientation,onSelect:i=>{this.orientation=i},label:"Card orientation",idPrefix:"tarot",controls:!0})}<div id="tarot-panel-${this.orientation}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="tarot-tab-${this.orientation}">${a?.description&&o?fe.html`<p class="reading">${a.description}</p>`:fe.nothing} ${s.length>0&&o?fe.html`<div class="chips">${s.map(i=>fe.html`<span>${i}</span>`)}</div>`:fe.nothing} ${this.renderGuidance(a,`tarot-${this.orientation}-guidance`)}</div></div></article>`}renderImage(e,r,a){let s=`image ${a?"reversed":""}`;return e?fe.html`<img class="${s}" part="chart" src="${e}" alt="${r??"Tarot card"}">`:fe.html`<div class="${s}" part="chart" style="aspect-ratio:0.6;display:flex;align-items:center;justify-content:center;color:var(--roxy-muted)">${r??"?"}</div>`}renderGuidance(e,r){if(!e)return fe.nothing;let a=fd.map(([s,o])=>({label:o,body:e[s]??""}));return this.renderInterpretation(a,r,"Guidance")}};Vr.styles=[y,O,K,Ee,fe.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-lg,1.5rem);grid-template-columns:minmax(0,9rem) 1fr;align-items:start;display:grid}@container (width<=480px){.card{grid-template-columns:1fr}}.image{border-radius:var(--roxy-radius-md,8px);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);width:100%;height:auto;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.image.reversed{transform:rotate(180deg)}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);margin:0}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);text-transform:uppercase;letter-spacing:.06em;margin-bottom:var(--roxy-space-sm,.5rem)}.drawn{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}.message{color:var(--roxy-fg,#0a0a0a);margin:var(--roxy-space-sm,.5rem) 0 var(--roxy-space-md,1rem)}.reading{margin:0 0 var(--roxy-space-md,1rem);white-space:pre-line}.roxy-tablist{margin:var(--roxy-space-sm,.5rem) 0}.chips{gap:var(--roxy-space-xs,.25rem);margin-top:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.chips span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}`],p([(0,ls.state)()],Vr.prototype,"orientation",2),Vr=p([(0,ls.customElement)("roxy-tarot-card")],Vr);var Yr=require("lit"),ds=require("lit/decorators.js");var Zr=class extends g{constructor(){super(...arguments);this.heading=""}renderEmpty(){return Yr.html`<div class="roxy-empty" role="status">No cards</div>`}renderData(e){let r=e.cards??[];if(r.length===0)return this.renderEmpty();let a=this.heading||"Tarot deck",s=typeof e.total=="number"?e.total:r.length;return Yr.html`<section class="wrap" aria-label="${a}"><header class="head"><h2 class="title">${a}</h2><span class="count">${s} ${s===1?"card":"cards"}</span></header><ul class="grid">${r.map(o=>Yr.html`<li class="tile">${o.imageUrl?Yr.html`<img class="art" src="${o.imageUrl}" alt="${o.name??"Tarot card"}" loading="lazy">`:Yr.html`<div class="art" aria-hidden="true"></div>`}<p class="name">${o.name}</p><p class="meta">${bd(o)}</p></li>`)}</ul></section>`}};Zr.styles=[y,Yr.css`.wrap{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fill,minmax(7rem,1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs,.25rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem);box-shadow:var(--roxy-shadow-sm);display:grid}.art{aspect-ratio:2/3;border-radius:var(--roxy-radius-sm,4px);object-fit:cover;background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 35%, transparent);width:100%}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.meta{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0}`],p([(0,ds.property)({type:String,reflect:!0})],Zr.prototype,"heading",2),Zr=p([(0,ds.customElement)("roxy-tarot-catalog")],Zr);function bd(n){return n.suit?`${Z(n.arcana)} \xB7 ${Z(n.suit)}`:`${Z(n.arcana)} Arcana`}var B=require("lit"),cs=require("lit/decorators.js");function vd(n){return n&&n.charAt(0).toUpperCase()+n.slice(1)}var Ur=class extends g{constructor(){super(...arguments);this.spread="three-card"}renderEmpty(){return B.html`<div class="roxy-empty" role="status">No tarot spread</div>`}renderData(e){let r="answer"in e,a="cards"in e&&!("spread"in e),s=a?[]:"positions"in e?e.positions??[]:[],o=a&&"cards"in e?e.cards:[],i=r?e.answer:void 0,l=r?e.strength:void 0,d=r?e.card:void 0,m=r?"Yes or no":a?"Card draw":vd(("spread"in e?e.spread:"")||this.spread.replace(/-/g," ")),c="question"in e?e.question:void 0,u="summary"in e?e.summary:void 0,z=r?e.interpretation:void 0,$=i?i.toLowerCase().replace(/[^a-z]/g,""):"";return B.html`<article class="wrap" part="card" aria-label="Tarot spread"><header class="head" part="header"><h2 class="title">${m}</h2>${c?B.html`<span class="question">"${c}"</span>`:B.nothing}</header>${r?B.html`<div class="verdict" part="section verdict"><div class="card"><div class="image" part="chart">${d?.imageUrl?B.html`<img src="${d.imageUrl}" alt="${d.name??"tarot card"}" class="${d.reversed?"reversed":""}">`:B.html`${d?.name??"?"}`}</div><p class="name">${d?.name??""} ${d?.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${d?.arcana?B.html`<p class="arcana">${d.arcana} arcana</p>`:B.nothing}</div><div class="meta" part="details"><div><span class="${`answer ${$}`}">${i}</span> ${l?B.html`<small>· ${l}</small>`:B.nothing}</div>${d?.keywords&&d.keywords.length>0&&!this.hideReadings?B.html`<div class="chips">${d.keywords.map(v=>B.html`<span>${v}</span>`)}</div>`:B.nothing}</div></div>`:B.nothing} ${s.length>0?B.html`<div class="grid" part="section positions">${s.map(v=>B.html`<div class="card"><p class="label">${v.name??""}</p><div class="image" part="chart">${v.card?.imageUrl?B.html`<img src="${v.card.imageUrl}" alt="${v.card.name??"tarot card"}" class="${v.card.reversed?"reversed":""}">`:B.html`${v.card?.name??"?"}`}</div><p class="name">${v.card?.name??""} ${v.card?.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${v.interpretation&&!this.hideReadings?B.html`<p class="interp">${v.interpretation}</p>`:B.nothing}</div>`)}</div>`:B.nothing} ${o.length>0?B.html`<div class="grid" part="section cards">${o.map(v=>B.html`<div class="card"><div class="image" part="chart">${v.imageUrl?B.html`<img src="${v.imageUrl}" alt="${v.name??"tarot card"}" class="${v.reversed?"reversed":""}">`:B.html`${v.name??"?"}`}</div><p class="name">${v.name??""} ${v.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${v.meaning&&!this.hideReadings?B.html`<p class="interp">${v.meaning}</p>`:B.nothing}</div>`)}</div>`:B.nothing} ${u&&!this.hideReadings?B.html`<p class="reading">${u}</p>`:B.nothing} ${z&&!this.hideReadings?B.html`<p class="reading">${z}</p>`:B.nothing}</article>`}};Ur.styles=[y,B.css`.wrap{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;align-items:baseline;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:capitalize;margin:0}.question{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-style:italic}.answer{border-radius:var(--roxy-radius-full,9999px);font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-base,1rem);text-transform:uppercase;letter-spacing:.06em;padding:4px 14px;display:inline-block}.answer.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.answer.no{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.answer.maybe{background:color-mix(in srgb, var(--roxy-warning,#ea580c) 16%, transparent);color:var(--roxy-warning-fg,#9a3412)}.chips{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.chips span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}.verdict{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,8rem) 1fr;align-items:start;display:grid}@container (width<=26rem){.verdict{grid-template-columns:1fr}}.verdict .meta{gap:var(--roxy-space-sm,.5rem);justify-items:start;display:grid}.arcana{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(8rem,1fr));display:grid}.card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem);background:var(--roxy-surface,#fff);gap:var(--roxy-space-xs,.25rem);grid-template-columns:minmax(0,1fr);display:grid}.label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.image{aspect-ratio:.6;background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:var(--roxy-radius-sm,4px);width:100%;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);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,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1))}.image img.reversed{transform:rotate(180deg)}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);margin:0}.interp{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-secondary,#475569);margin:0}.reading{color:var(--roxy-fg,#0a0a0a);margin:0}`],p([(0,cs.property)({type:String,reflect:!0})],Ur.prototype,"spread",2),Ur=p([(0,cs.customElement)("roxy-tarot-spread")],Ur);var S=require("lit"),Qt=require("lit/decorators.js");var an=400,_=an/2,Ld=184,la=170,$d=154,rn=140,wd=124,kd=135,Sd=94,Rd=83,Qo=112,Cd=104,tn=70,Ad=58,Dd=13,Td=15,zd=8,Ed=4,Xt=(n,t)=>k(n)??t,ei=n=>{let t=He(n);return`${t.degree}\xB0${String(t.minute).padStart(2,"0")}'`},ri=n=>typeof n=="number"&&Number.isFinite(n)?String(Math.round(n)):"",ps=n=>{let t=new Map;for(let e of n)t.set(Z(e.name),e);return t},xr=class extends g{constructor(){super(...arguments);this.heading="Transits"}get ascendantGiven(){return typeof this.ascendant=="number"&&Number.isFinite(this.ascendant)}get cusps(){let e=this.houses;if(!Array.isArray(e)||e.length!==12)return null;let r=e.map((s,o)=>typeof s=="number"?{number:o+1,longitude:s}:{number:Number(s?.number),longitude:Number(s?.longitude)}).sort((s,o)=>s.number-o.number);return r.every((s,o)=>s.number===o+1&&Number.isFinite(s.longitude))?r:null}toAngle(e){return 180+(this.ascendantGiven?this.ascendant:this.cusps?.[0]?.longitude??0)-e}renderEmpty(){return S.html`<div class="roxy-empty" role="status">${this.t("No transit data")}</div>`}renderData(e){let r=e.natalPlanets??[],a=e.transitPlanets??[],s=e.aspects??[],o=Oe(this.effectiveLang(),e.transitDate),i=s.length>0?this.t("Aspects to the natal chart: {{count}}",{count:s.length}):"",l=[...r,...a].some(d=>Number.isFinite(d.house));return S.html`<div class="wrap" part="card" aria-label="${this.t("Natal and transit bi-wheel")}"><div class="head" part="header"><h2 class="title">${this.t(this.heading)}</h2>${o||i?S.html`<p class="subtitle">${[o,i].filter(Boolean).join(" \xB7 ")}</p>`:S.nothing}</div>${this.renderWheel(r,a,s)} ${this.renderLegend(r,a,s,l?e.houseSystem:void 0)} ${this.renderSummary(e.summary)} ${this.renderPositions(r,a,l)} ${this.renderReadings(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.t("House cusps supplied by the page"):this.t("No house cusps")}renderWheel(e,r,a){return S.html`<svg viewBox="0 0 ${an} ${an}" 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="${_}" cy="${_}" r="${la}" stroke-width="1.5"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${rn}" stroke-width="0.8"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${Qo}" stroke-width="0.6"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${tn}" stroke-width="0.5"/>${this.renderTicks()} ${this.renderSpokes()} ${this.renderSigns()} ${this.renderHouses()} ${this.renderAspectLines(e,r,a)} ${this.renderRing(e,Sd,Rd,"natal-glyph",this.t("Natal"),1)} ${this.renderRing(r,wd,kd,"transit-glyph",this.t("Transiting"),-1)} ${this.renderAxis()}</svg>`}renderTicks(){let e=[];for(let r=0;r<360;r+=5){let a=this.toAngle(r),s=r%30===0,o=M(_,_,s?rn:la-5,a),i=M(_,_,la,a);e.push(S.svg`<line class=${s?"tick tick-major":"tick"} x1=${o.x} y1=${o.y} x2=${i.x} y2=${i.y} stroke-width=${s?1:.5} />`)}return e}renderSpokes(){return xe.map((e,r)=>{let a=this.toAngle(r*30),s=M(_,_,tn,a),o=M(_,_,la,a);return S.svg`<line class="wheel-line" x1=${s.x} y1=${s.y} x2=${o.x} y2=${o.y} stroke-width="0.6" />`})}renderHouses(){let e=this.cusps;return e?e.map((r,a)=>{let s=e[(a+1)%12],o=this.toAngle(r.longitude),i=M(_,_,tn,o),l=M(_,_,rn,o),d=M(_,_,Ad,this.toAngle(Ha(r.longitude,s?.longitude??r.longitude+30)));return S.svg`<g>
|
|
103
|
+
</g>`)};return r(t.person1?.ascendant,1),r(t.person2?.ascendant,2),e}renderInterAspectLines(t,e,r){let a=(s,o)=>{let i=Z(o);for(let l of s)if(Z(l.name)===i&&typeof l.longitude=="number")return l.longitude};return r.map(s=>{let o=a(t,s.planet1),i=a(e,s.planet2);if(o===void 0||i===void 0)return R.nothing;let l=M(ge,ge,Qs-12,this.toAngle(o)),d=M(ge,ge,Jt+8,this.toAngle(i)),m=or(s),c=vr[m]??"aspect-other",u=x(s.orb,1);return R.svg`<line class=${`aspect ${c}`} x1=${l.x} y1=${l.y} x2=${d.x} y2=${d.y}><title>${s.planet1} ${m} ${s.planet2}${u?` (orb ${u}\xB0)`:""}</title></line>`})}renderAspects(t){return R.html`<table><caption class="roxy-sr-only">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">Planet 1</th><th scope="col">Planet 2</th><th scope="col">Aspect</th><th scope="col">Orb</th><th scope="col">Strength</th></tr></thead><tbody>${t.map(e=>R.html`<tr><td>${e.planet1}</td><td>${e.planet2}</td><td>${ke(e)}</td><td class="orb">${x(e.orb,1)}</td><td>${x(e.strength,0)}</td></tr>`)}</tbody></table>`}};Gt.styles=[y,O,K,R.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:center;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.score{font-variant-numeric:tabular-nums;font-weight:var(--roxy-weight-bold,600);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-xl,1.5rem)}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line{fill:none;stroke:var(--roxy-border,#e4e4e7)}.sign{fill:var(--roxy-secondary,#475569);font-size:14px}.p1{fill:var(--roxy-accent,#f59e0b);font-size:13px;font-weight:600}.p2{fill:var(--roxy-info,#0284c7);font-size:13px;font-weight:600}.person-tag{opacity:.85;font-size:7px;font-weight:700}.planet-deg{fill:var(--roxy-muted,#71717a);font-size:7px;font-family:var(--roxy-font-sans)}.planet-deg .retro{fill:var(--roxy-danger,#dc2626)}.asc-tick{stroke:var(--roxy-accent-ink,#b45309);stroke-width:1px;opacity:.75}.asc-label{fill:var(--roxy-accent-ink,#b45309);font-size:9px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.04em}.aspect{stroke-width:.8px;fill:none;opacity:.5}.aspect-trine,.aspect-sextile{stroke:var(--roxy-success,#16a34a)}.aspect-square,.aspect-opposition{stroke:var(--roxy-danger,#dc2626)}.aspect-conjunction{stroke:var(--roxy-accent-ink,#b45309)}.aspect-other{stroke:var(--roxy-muted,#71717a);opacity:.35}.legend-row{gap:var(--roxy-space-md,1rem);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin-top:calc(var(--roxy-space-xs,.25rem) * -1);flex-wrap:wrap;display:flex}.legend-row .swatch{vertical-align:middle;border-radius:50%;width:8px;height:8px;margin-right:4px;display:inline-block}.summary{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-base,1rem);margin:0}.people{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fit,minmax(11rem,1fr));display:grid}.person{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);gap:.3rem;display:grid}.person-name{font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);align-items:center;gap:.4rem;display:flex}.person-dot{border-radius:50%;flex-shrink:0;width:8px;height:8px}.person-dot.p1{background:var(--roxy-accent,#f59e0b)}.person-dot.p2{background:var(--roxy-info,#0284c7)}.big-three{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;gap:.25rem .75rem;display:flex}.big-three span{align-items:baseline;gap:.25rem;display:inline-flex}.big-three .lbl{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem)}.summary-pills{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.pill{border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);color:var(--roxy-fg,#0a0a0a);padding:2px 8px}.pill--success{background:color-mix(in srgb, var(--roxy-success,#16a34a) 12%, transparent);color:var(--roxy-success-fg,#166534)}.pill--danger{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 12%, transparent);color:var(--roxy-danger-fg,#991b1b)}.glyph{font-size:1.1em;line-height:1}.static-head{align-items:center;gap:var(--roxy-space-sm,.5rem);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;font-weight:500;display:flex}.asp-name{font-weight:var(--roxy-weight-bold,600);text-transform:capitalize}.asp-name.harmonious{color:var(--roxy-success-fg,#166534)}.asp-name.challenging{color:var(--roxy-danger-fg,#991b1b)}.interp-keywords{flex-wrap:wrap;gap:.25rem;display:flex}.interp-keywords .kw{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);padding:1px 8px}.context{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.catalog>summary{cursor:pointer;font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-fg,#0a0a0a);align-items:center;gap:.5rem;display:flex}.scroll{min-width:0;margin-top:var(--roxy-space-sm,.5rem);overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}td.orb{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a)}.lists{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(14rem,1fr));display:grid}.lists h3{margin:0 0 var(--roxy-space-xs,.25rem) 0;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em}.lists ul{padding-left:var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);margin:0}.missing-planets{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);line-height:1.5}.missing-planets code{font-family:var(--roxy-font-mono,ui-monospace, SFMono-Regular, Menlo, monospace);background:color-mix(in srgb, var(--roxy-fg,#0a0a0a) 6%, transparent);border-radius:4px;padding:0 4px;font-size:.95em}`],Gt=p([(0,Xo.customElement)("roxy-synastry-chart")],Gt);var fe=require("lit"),ls=require("lit/decorators.js");var fd=[["love","Love"],["career","Career"],["finances","Finances"],["health","Health"],["spirituality","Spirituality"]],Vr=class extends g{constructor(){super(...arguments);this.orientation="upright"}renderEmpty(){return fe.html`<div class="roxy-empty" role="status">No tarot data</div>`}renderData(e){return"card"in e?this.renderDailyCard(e):this.renderFullCard(e)}renderDailyCard(e){let r=e.card,a=!!r.reversed,s=r.keywords??[],o=[r.arcana?`${r.arcana} arcana`:"",r.suit??""].filter(Boolean).join(" \xB7 "),i=!this.hideReadings;return fe.html`<article class="card" part="card" aria-label="${r.name??"Tarot card"}">${this.renderImage(r.imageUrl,r.name,a)}<div part="header"><div class="meta">${o?`${o} \xB7 `:""}<span class="drawn">${a?"drawn reversed":"drawn upright"}</span></div><h2 class="title">${r.name??"Tarot card"}</h2>${e.dailyMessage&&i?fe.html`<p class="message">${e.dailyMessage}</p>`:fe.nothing} ${r.meaning&&i?fe.html`<p class="reading">${r.meaning}</p>`:fe.nothing} ${s.length>0&&i?fe.html`<div class="chips">${s.map(l=>fe.html`<span>${l}</span>`)}</div>`:fe.nothing} ${this.renderGuidance(r,"tarot-daily-guidance")}</div></article>`}renderFullCard(e){let r=this.orientation==="reversed",a=r?e.reversed:e.upright,s=(r?e.keywords?.reversed:e.keywords?.upright)??a?.keywords??[],o=!this.hideReadings;return fe.html`<article class="card" part="card" aria-label="${e.name??"Tarot card"}">${this.renderImage(e.imageUrl,e.name,r)}<div part="header"><div class="meta">${[e.arcana?`${e.arcana} arcana`:"",e.suit??"",e.number!==void 0&&e.number!==null?`no. ${e.number}`:""].filter(Boolean).join(" \xB7 ")}</div><h2 class="title">${e.name??"Tarot card"}</h2>${_e({items:[{id:"upright",label:"Upright"},{id:"reversed",label:"Reversed"}],active:this.orientation,onSelect:i=>{this.orientation=i},label:"Card orientation",idPrefix:"tarot",controls:!0})}<div id="tarot-panel-${this.orientation}" part="panel" role="tabpanel" tabindex="0" aria-labelledby="tarot-tab-${this.orientation}">${a?.description&&o?fe.html`<p class="reading">${a.description}</p>`:fe.nothing} ${s.length>0&&o?fe.html`<div class="chips">${s.map(i=>fe.html`<span>${i}</span>`)}</div>`:fe.nothing} ${this.renderGuidance(a,`tarot-${this.orientation}-guidance`)}</div></div></article>`}renderImage(e,r,a){let s=`image ${a?"reversed":""}`;return e?fe.html`<img class="${s}" part="chart" src="${e}" alt="${r??"Tarot card"}">`:fe.html`<div class="${s}" part="chart" style="aspect-ratio:0.6;display:flex;align-items:center;justify-content:center;color:var(--roxy-muted)">${r??"?"}</div>`}renderGuidance(e,r){if(!e)return fe.nothing;let a=fd.map(([s,o])=>({label:o,body:e[s]??""}));return this.renderInterpretation(a,r,"Guidance")}};Vr.styles=[y,O,K,Ee,fe.css`.card{background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-lg,1.5rem);grid-template-columns:minmax(0,9rem) 1fr;align-items:start;display:grid}@container (width<=480px){.card{grid-template-columns:1fr}}.image{border-radius:var(--roxy-radius-md,8px);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);width:100%;height:auto;transition:transform var(--roxy-motion-duration,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1));display:block}.image.reversed{transform:rotate(180deg)}.title{font-size:var(--roxy-text-xl,1.5rem);font-weight:var(--roxy-weight-bold,600);letter-spacing:var(--roxy-tracking-tight);margin:0}.meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);text-transform:uppercase;letter-spacing:.06em;margin-bottom:var(--roxy-space-sm,.5rem)}.drawn{color:var(--roxy-fg,#0a0a0a);font-weight:var(--roxy-weight-bold,600)}.message{color:var(--roxy-fg,#0a0a0a);margin:var(--roxy-space-sm,.5rem) 0 var(--roxy-space-md,1rem)}.reading{margin:0 0 var(--roxy-space-md,1rem);white-space:pre-line}.roxy-tablist{margin:var(--roxy-space-sm,.5rem) 0}.chips{gap:var(--roxy-space-xs,.25rem);margin-top:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.chips span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}`],p([(0,ls.state)()],Vr.prototype,"orientation",2),Vr=p([(0,ls.customElement)("roxy-tarot-card")],Vr);var Yr=require("lit"),ds=require("lit/decorators.js");var Zr=class extends g{constructor(){super(...arguments);this.heading=""}renderEmpty(){return Yr.html`<div class="roxy-empty" role="status">No cards</div>`}renderData(e){let r=e.cards??[];if(r.length===0)return this.renderEmpty();let a=this.heading||"Tarot deck",s=typeof e.total=="number"?e.total:r.length;return Yr.html`<section class="wrap" aria-label="${a}"><header class="head"><h2 class="title">${a}</h2><span class="count">${s} ${s===1?"card":"cards"}</span></header><ul class="grid">${r.map(o=>Yr.html`<li class="tile">${o.imageUrl?Yr.html`<img class="art" src="${o.imageUrl}" alt="${o.name??"Tarot card"}" loading="lazy">`:Yr.html`<div class="art" aria-hidden="true"></div>`}<p class="name">${o.name}</p><p class="meta">${bd(o)}</p></li>`)}</ul></section>`}};Zr.styles=[y,Yr.css`.wrap{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.count{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem)}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fill,minmax(7rem,1fr));margin:0;padding:0;list-style:none;display:grid}.tile{gap:var(--roxy-space-xs,.25rem);background:var(--roxy-surface,#fff);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem);box-shadow:var(--roxy-shadow-sm);display:grid}.art{aspect-ratio:2/3;border-radius:var(--roxy-radius-sm,4px);object-fit:cover;background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 35%, transparent);width:100%}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);margin:0}.meta{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);margin:0}`],p([(0,ds.property)({type:String,reflect:!0})],Zr.prototype,"heading",2),Zr=p([(0,ds.customElement)("roxy-tarot-catalog")],Zr);function bd(n){return n.suit?`${Z(n.arcana)} \xB7 ${Z(n.suit)}`:`${Z(n.arcana)} Arcana`}var B=require("lit"),cs=require("lit/decorators.js");function vd(n){return n&&n.charAt(0).toUpperCase()+n.slice(1)}var Ur=class extends g{constructor(){super(...arguments);this.spread="three-card"}renderEmpty(){return B.html`<div class="roxy-empty" role="status">No tarot spread</div>`}renderData(e){let r="answer"in e,a="cards"in e&&!("spread"in e),s=a?[]:"positions"in e?e.positions??[]:[],o=a&&"cards"in e?e.cards:[],i=r?e.answer:void 0,l=r?e.strength:void 0,d=r?e.card:void 0,m=r?"Yes or no":a?"Card draw":vd(("spread"in e?e.spread:"")||this.spread.replace(/-/g," ")),c="question"in e?e.question:void 0,u="summary"in e?e.summary:void 0,z=r?e.interpretation:void 0,$=i?i.toLowerCase().replace(/[^a-z]/g,""):"";return B.html`<article class="wrap" part="card" aria-label="Tarot spread"><header class="head" part="header"><h2 class="title">${m}</h2>${c?B.html`<span class="question">"${c}"</span>`:B.nothing}</header>${r?B.html`<div class="verdict" part="section verdict"><div class="card"><div class="image" part="chart">${d?.imageUrl?B.html`<img src="${d.imageUrl}" alt="${d.name??"tarot card"}" class="${d.reversed?"reversed":""}">`:B.html`${d?.name??"?"}`}</div><p class="name">${d?.name??""} ${d?.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${d?.arcana?B.html`<p class="arcana">${d.arcana} arcana</p>`:B.nothing}</div><div class="meta" part="details"><div><span class="${`answer ${$}`}">${i}</span> ${l?B.html`<small>· ${l}</small>`:B.nothing}</div>${d?.keywords&&d.keywords.length>0&&!this.hideReadings?B.html`<div class="chips">${d.keywords.map(v=>B.html`<span>${v}</span>`)}</div>`:B.nothing}</div></div>`:B.nothing} ${s.length>0?B.html`<div class="grid" part="section positions">${s.map(v=>B.html`<div class="card"><p class="label">${v.name??""}</p><div class="image" part="chart">${v.card?.imageUrl?B.html`<img src="${v.card.imageUrl}" alt="${v.card.name??"tarot card"}" class="${v.card.reversed?"reversed":""}">`:B.html`${v.card?.name??"?"}`}</div><p class="name">${v.card?.name??""} ${v.card?.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${v.interpretation&&!this.hideReadings?B.html`<p class="interp">${v.interpretation}</p>`:B.nothing}</div>`)}</div>`:B.nothing} ${o.length>0?B.html`<div class="grid" part="section cards">${o.map(v=>B.html`<div class="card"><div class="image" part="chart">${v.imageUrl?B.html`<img src="${v.imageUrl}" alt="${v.name??"tarot card"}" class="${v.reversed?"reversed":""}">`:B.html`${v.name??"?"}`}</div><p class="name">${v.name??""} ${v.reversed?B.html`<small>(reversed)</small>`:B.nothing}</p>${v.meaning&&!this.hideReadings?B.html`<p class="interp">${v.meaning}</p>`:B.nothing}</div>`)}</div>`:B.nothing} ${u&&!this.hideReadings?B.html`<p class="reading">${u}</p>`:B.nothing} ${z&&!this.hideReadings?B.html`<p class="reading">${z}</p>`:B.nothing}</article>`}};Ur.styles=[y,B.css`.wrap{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;align-items:baseline;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);text-transform:capitalize;margin:0}.question{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);font-style:italic}.answer{border-radius:var(--roxy-radius-full,9999px);font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-base,1rem);text-transform:uppercase;letter-spacing:.06em;padding:4px 14px;display:inline-block}.answer.yes{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.answer.no{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 16%, transparent);color:var(--roxy-danger-fg,#991b1b)}.answer.maybe{background:color-mix(in srgb, var(--roxy-warning,#ea580c) 16%, transparent);color:var(--roxy-warning-fg,#9a3412)}.chips{gap:var(--roxy-space-xs,.25rem);flex-wrap:wrap;display:flex}.chips span{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);padding:2px 8px}.verdict{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,8rem) 1fr;align-items:start;display:grid}@container (width<=26rem){.verdict{grid-template-columns:1fr}}.verdict .meta{gap:var(--roxy-space-sm,.5rem);justify-items:start;display:grid}.arcana{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.grid{gap:var(--roxy-space-md,1rem);grid-template-columns:repeat(auto-fit,minmax(8rem,1fr));display:grid}.card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem);background:var(--roxy-surface,#fff);gap:var(--roxy-space-xs,.25rem);grid-template-columns:minmax(0,1fr);display:grid}.label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;margin:0}.image{aspect-ratio:.6;background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);border-radius:var(--roxy-radius-sm,4px);width:100%;font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);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,.2s) var(--roxy-motion-easing,cubic-bezier(.4, 0, .2, 1))}.image img.reversed{transform:rotate(180deg)}.name{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);margin:0}.interp{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-secondary,#475569);margin:0}.reading{color:var(--roxy-fg,#0a0a0a);margin:0}`],p([(0,cs.property)({type:String,reflect:!0})],Ur.prototype,"spread",2),Ur=p([(0,cs.customElement)("roxy-tarot-spread")],Ur);var S=require("lit"),Qt=require("lit/decorators.js");var an=400,_=an/2,Ld=184,la=170,$d=154,rn=140,wd=124,kd=135,Sd=94,Rd=83,Qo=112,Cd=104,tn=70,Ad=58,Dd=13,Td=15,zd=8,Ed=4,Xt=(n,t)=>k(n)??t,ei=n=>{let t=He(n);return`${t.degree}\xB0${String(t.minute).padStart(2,"0")}'`},ri=n=>typeof n=="number"&&Number.isFinite(n)?String(Math.round(n)):"",ps=n=>{let t=new Map;for(let e of n)t.set(Z(e.name),e);return t},xr=class extends g{constructor(){super(...arguments);this.heading="Transits"}get payload(){return this.data}get effectiveAscendant(){for(let e of[this.ascendant,this.payload?.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.payload?.houses;if(!Array.isArray(e)||e.length!==12)return null;let r=e.map((s,o)=>typeof s=="number"?{number:o+1,longitude:s}:{number:Number(s?.number),longitude:Number(s?.longitude)}).sort((s,o)=>s.number-o.number);return r.every((s,o)=>s.number===o+1&&Number.isFinite(s.longitude))?r:null}toAngle(e){return 180+(this.effectiveAscendant??this.cusps?.[0]?.longitude??0)-e}renderEmpty(){return S.html`<div class="roxy-empty" role="status">${this.t("No transit data")}</div>`}renderData(e){let r=e.natalPlanets??[],a=e.transitPlanets??[],s=e.aspects??[],o=Oe(this.effectiveLang(),e.transitDate),i=s.length>0?this.t("Aspects to the natal chart: {{count}}",{count:s.length}):"",l=[...r,...a].some(d=>Number.isFinite(d.house));return S.html`<div class="wrap" part="card" aria-label="${this.t("Natal and transit bi-wheel")}"><div class="head" part="header"><h2 class="title">${this.t(this.heading)}</h2>${o||i?S.html`<p class="subtitle">${[o,i].filter(Boolean).join(" \xB7 ")}</p>`:S.nothing}</div>${this.renderWheel(r,a,s)} ${this.renderLegend(r,a,s,l?e.houseSystem:void 0)} ${this.renderSummary(e.summary)} ${this.renderPositions(r,a,l)} ${this.renderReadings(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,r,a){return S.html`<svg viewBox="0 0 ${an} ${an}" 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="${_}" cy="${_}" r="${la}" stroke-width="1.5"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${rn}" stroke-width="0.8"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${Qo}" stroke-width="0.6"/><circle class="wheel-line" cx="${_}" cy="${_}" r="${tn}" stroke-width="0.5"/>${this.renderTicks()} ${this.renderSpokes()} ${this.renderSigns()} ${this.renderHouses()} ${this.renderAspectLines(e,r,a)} ${this.renderRing(e,Sd,Rd,"natal-glyph",this.t("Natal"),1)} ${this.renderRing(r,wd,kd,"transit-glyph",this.t("Transiting"),-1)} ${this.renderAxis()}</svg>`}renderTicks(){let e=[];for(let r=0;r<360;r+=5){let a=this.toAngle(r),s=r%30===0,o=M(_,_,s?rn:la-5,a),i=M(_,_,la,a);e.push(S.svg`<line class=${s?"tick tick-major":"tick"} x1=${o.x} y1=${o.y} x2=${i.x} y2=${i.y} stroke-width=${s?1:.5} />`)}return e}renderSpokes(){return xe.map((e,r)=>{let a=this.toAngle(r*30),s=M(_,_,tn,a),o=M(_,_,la,a);return S.svg`<line class="wheel-line" x1=${s.x} y1=${s.y} x2=${o.x} y2=${o.y} stroke-width="0.6" />`})}renderHouses(){let e=this.cusps;return e?e.map((r,a)=>{let s=e[(a+1)%12],o=this.toAngle(r.longitude),i=M(_,_,tn,o),l=M(_,_,rn,o),d=M(_,_,Ad,this.toAngle(Ha(r.longitude,s?.longitude??r.longitude+30)));return S.svg`<g>
|
|
104
104
|
<line class="house-cusp" x1=${i.x} y1=${i.y} x2=${l.x} y2=${l.y} />
|
|
105
105
|
<text class="house-num" x=${d.x} y=${d.y} text-anchor="middle" dominant-baseline="central">${r.number}</text>
|
|
106
106
|
</g>`}):S.nothing}renderSigns(){return xe.map((e,r)=>{let a=M(_,_,$d,this.toAngle(r*30+15));return S.svg`<text class="sign-glyph" x=${a.x} y=${a.y} text-anchor="middle" dominant-baseline="central">${q(e)}</text>`})}renderRing(e,r,a,s,o,i){let l=Math.max(Gs(Dd,r),Gs(Td,a));return io(e,d=>d.longitude,l).map(({item:d,longitude:m,displayLongitude:c})=>{let u=this.toAngle(c),z=M(_,_,r,u),$=M(_,_,a,u),v=d.isRetrograde===!0,Re=`${He(m).degree}\xB0`,Ce=b(d,"name"),hr=`${o} ${Ce}${v?` ${this.t("retrograde")}`:""} - ${ei(m)} ${b(d,"sign")}`,Xr=Math.abs(c-m)>.5,da=M(_,_,r+i*zd,this.toAngle(m)),nn=M(_,_,r+i*Ed,u);return S.svg`<g>
|
|
107
107
|
${Xr?S.svg`<line class=${`leader ${s}`} x1=${da.x} y1=${da.y} x2=${nn.x} y2=${nn.y} />`:S.nothing}
|
|
108
108
|
<text class=${s} x=${z.x} y=${z.y} text-anchor="middle" dominant-baseline="central"><title>${hr}</title>${Xt(d.name,Ce)}</text>
|
|
109
109
|
<text class="planet-deg" x=${$.x} y=${$.y} text-anchor="middle" dominant-baseline="central">${Re}${v?S.svg`<tspan class="retro"> ℞</tspan>`:S.nothing}</text>
|
|
110
|
-
</g>`})}renderAspectLines(e,r,a){let s=ps(e),o=ps(r);return a.map(i=>{let l=o.get(Z(i.planet1)),d=s.get(Z(i.planet2));if(!l||!d||!Number.isFinite(l.longitude)||!Number.isFinite(d.longitude))return S.nothing;let m=M(_,_,Qo,this.toAngle(l.longitude)),c=M(_,_,Cd,this.toAngle(d.longitude)),u=or(i),z=x(i.orb,1);return S.svg`<line class=${`aspect ${vr[u]??"aspect-other"}`} x1=${m.x} y1=${m.y} x2=${c.x} y2=${c.y}><title>${this.t("Transiting")} ${b(i,"planet1")} ${b(i,"type",u)} ${this.t("Natal")} ${b(i,"planet2")}${z?` (${this.t("orb")} ${z}\xB0)`:""}</title></line>`})}renderAxis(){if(
|
|
111
|
-
<line class="axis-tick" x1=${
|
|
112
|
-
<text class="axis-label" x=${
|
|
110
|
+
</g>`})}renderAspectLines(e,r,a){let s=ps(e),o=ps(r);return a.map(i=>{let l=o.get(Z(i.planet1)),d=s.get(Z(i.planet2));if(!l||!d||!Number.isFinite(l.longitude)||!Number.isFinite(d.longitude))return S.nothing;let m=M(_,_,Qo,this.toAngle(l.longitude)),c=M(_,_,Cd,this.toAngle(d.longitude)),u=or(i),z=x(i.orb,1);return S.svg`<line class=${`aspect ${vr[u]??"aspect-other"}`} x1=${m.x} y1=${m.y} x2=${c.x} y2=${c.y}><title>${this.t("Transiting")} ${b(i,"planet1")} ${b(i,"type",u)} ${this.t("Natal")} ${b(i,"planet2")}${z?` (${this.t("orb")} ${z}\xB0)`:""}</title></line>`})}renderAxis(){let e=this.effectiveAscendant;if(e===void 0)return S.nothing;let r=ar(e);return[r,oa(r)].map((a,s)=>{let o=this.toAngle(a),i=M(_,_,la,o),l=M(_,_,Ld,o);return S.svg`<g>
|
|
111
|
+
<line class="axis-tick" x1=${i.x} y1=${i.y} x2=${l.x} y2=${l.y} />
|
|
112
|
+
<text class="axis-label" x=${l.x} y=${l.y} text-anchor="middle" dominant-baseline="central">${s===0?"ASC":"DSC"}</text>
|
|
113
113
|
</g>`})}renderLegend(e,r,a,s){return S.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:r.length})}</span> ${a.length>0?S.html`<span><span class="swatch swatch--harmonious"></span>${this.t("Harmonious")}</span> <span><span class="swatch swatch--challenging"></span>${this.t("Challenging")}</span>`:S.nothing} ${s?S.html`<span>${this.t("{{system}} houses",{system:s})}</span>`:S.nothing} <span>${this.orientationCaption}</span> <span>${this.cuspCaption}</span></div>`}renderSummary(e){if(!e)return S.nothing;let r=Object.entries(e.byType??{}).sort((a,s)=>s[1]-a[1]);return S.html`<div part="details"><div class="summary-pills" role="region" aria-label="${this.t("Transit aspect summary")}">${typeof e.total=="number"?S.html`<span class="pill pill--muted">${this.t("Total")}: ${e.total}</span>`:S.nothing} <span class="pill pill--success">${this.t("Harmonious")}: ${e.harmonious}</span> <span class="pill pill--danger">${this.t("Challenging")}: ${e.challenging}</span> <span class="pill pill--muted">${this.t("Neutral")}: ${e.neutral}</span> ${r.map(([a,s])=>S.html`<span class="pill pill--muted">${ke({type:a})}: ${s}</span>`)}</div>${e.strongest?this.renderStrongest(e.strongest):S.nothing}</div>`}renderStrongest(e){let r=b(e,"planet1"),a=b(e,"planet2");return S.html`<div class="strongest" part="details strongest"><span class="label">${this.t("Strongest")}</span> <span aria-hidden="true" class="glyph">${Xt(e.planet1,r)}</span>${this.t("Transiting")} ${r} <span class="nature-badge ${(e.interpretation??"neutral").toLowerCase()}">${b(e,"type",ke(e))}</span> <span aria-hidden="true" class="glyph">${Xt(e.planet2,a)}</span>${this.t("Natal")} ${a} <span class="meta">${e.isApplying?this.t("Applying"):this.t("Separating")} · ${this.t("orb")} ${x(e.orb,2)}° · ${this.t("strength")} ${ri(e.strength)}</span></div>`}renderPositions(e,r,a){if(e.length===0&&r.length===0)return S.nothing;let s=ps(e),o=ps(r),i=e.length>0?e:r,l=m=>m?S.html`${q(m.sign)??""} ${ei(m.longitude)} ${b(m,"sign")}${m.isRetrograde?S.html`<span class="retro-badge" aria-label="${this.t("retrograde")}">℞</span>`:S.nothing}`:S.nothing,d=m=>a?S.html`<td>${m&&Number.isFinite(m.house)?m.house:S.nothing}</td>`:S.nothing;return S.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.")} ${a?this.t("Both house numbers are read against the natal house cusps."):S.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>${a?S.html`<th scope="col">${this.t("Natal house")}</th>`:S.nothing}<th scope="col"><span class="swatch swatch--transit" aria-hidden="true"></span>${this.t("Transiting")}</th>${a?S.html`<th scope="col">${this.t("Transiting house")}</th>`:S.nothing}</tr></thead><tbody>${i.map(m=>{let c=Z(m.name),u=b(m,"name");return S.html`<tr><th scope="row"><span aria-hidden="true" class="glyph">${Xt(m.name,u)}</span> ${u}</th><td>${l(s.get(c))}</td>${d(s.get(c))}<td>${l(o.get(c))}</td>${d(o.get(c))}</tr>`})}</tbody></table></div>`}renderReadings(e){let r=e.filter(a=>a.transitInterpretation?.summary).map(a=>{let s=a.transitInterpretation,o=b(a,"planet1"),i=b(a,"planet2");return{label:`${Xt(a.planet1,o)} ${o} ${b(a,"type",ke(a))} ${Xt(a.planet2,i)} ${i}`,aside:`${this.t("orb")} ${x(a.orb,2)}\xB0 \xB7 ${this.t("strength")} ${ri(a.strength)}`,body:s.summary,extra:S.html`${s.impact?S.html`<p><strong>${this.t("Impact")}:</strong> ${s.impact}</p>`:S.nothing} ${s.timing?S.html`<p><strong>${this.t("Timing")}:</strong> ${s.timing}</p>`:S.nothing} ${s.guidance?S.html`<p><strong>${this.t("Guidance")}:</strong> ${s.guidance}</p>`:S.nothing} ${s.keywords?.length?S.html`<div class="interp-keywords">${s.keywords.map(l=>S.html`<span class="kw">${l}</span>`)}</div>`:S.nothing}`}});return this.renderInterpretation(r,"transit-aspect-readings",this.t("Transit readings"))}};xr.styles=[y,O,K,S.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}svg{width:100%;max-width:var(--roxy-chart-max-width,560px);aspect-ratio:1;height:auto;margin:0 auto;display:block}.wheel-line{fill:none;stroke:var(--roxy-border,#e4e4e7)}.sign-glyph{fill:var(--roxy-secondary,#475569);font-size:14px;font-family:var(--roxy-font-sans)}.natal-glyph{fill:var(--roxy-accent-ink,#b45309);font-size:13px;font-weight:600;font-family:var(--roxy-font-sans)}.transit-glyph{fill:var(--roxy-info,#0284c7);font-size:13px;font-weight:600;font-family:var(--roxy-font-sans)}.leader{stroke:currentColor;stroke-width:.6px;opacity:.6}.leader.natal-glyph{stroke:var(--roxy-accent-ink,#b45309)}.leader.transit-glyph{stroke:var(--roxy-info,#0284c7)}.planet-deg{fill:var(--roxy-muted,#71717a);font-size:7px;font-family:var(--roxy-font-sans)}.planet-deg .retro{fill:var(--roxy-danger,#dc2626)}@container (width<=480px){.sign-glyph,.natal-glyph,.transit-glyph{font-size:18px}.planet-deg{font-size:10px}.house-num{font-size:12px}}.tick{stroke:var(--roxy-border,#e4e4e7)}.tick-major{stroke:var(--roxy-secondary,#475569)}.house-cusp{stroke:var(--roxy-secondary,#475569);stroke-width:1px;stroke-dasharray:3 3}.house-num{fill:var(--roxy-secondary,#475569);font-size:9px;font-family:var(--roxy-font-sans)}.axis-tick{stroke:var(--roxy-accent-ink,#b45309);stroke-width:1.5px}.axis-label{fill:var(--roxy-accent-ink,#b45309);font-size:10px;font-weight:700;font-family:var(--roxy-font-sans);letter-spacing:.04em}.aspect{stroke-width:.8px;fill:none;opacity:.55}.aspect-trine,.aspect-sextile{stroke:var(--roxy-success,#16a34a)}.aspect-square,.aspect-opposition{stroke:var(--roxy-danger,#dc2626)}.aspect-conjunction{stroke:var(--roxy-accent-ink,#b45309)}.aspect-other{stroke:var(--roxy-muted,#71717a);opacity:.4}.swatch{vertical-align:middle;border-radius:50%;width:8px;height:8px;margin-right:4px;display:inline-block}.swatch--natal{background:var(--roxy-accent-ink,#b45309)}.swatch--transit{background:var(--roxy-info,#0284c7)}.swatch--harmonious{background:var(--roxy-success,#16a34a)}.swatch--challenging{background:var(--roxy-danger,#dc2626)}.legend{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.summary-pills{gap:var(--roxy-space-sm,.5rem);margin-bottom:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.pill{padding:2px var(--roxy-space-sm,.5rem);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);border:1px solid;align-items:center;gap:4px;display:inline-flex}.pill--muted{color:var(--roxy-fg,#0a0a0a);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent)}.pill--success{color:var(--roxy-success-fg,#166534);background:color-mix(in srgb, var(--roxy-success,#16a34a) 10%, transparent)}.pill--danger{color:var(--roxy-danger-fg,#991b1b);background:color-mix(in srgb, var(--roxy-danger,#dc2626) 10%, transparent)}.strongest{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;align-items:center;gap:.4rem;display:flex}.strongest .label{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600)}.strongest .meta{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;margin-left:auto}.glyph{font-size:1.1em;line-height:1}.nature-badge{font-size:var(--roxy-text-xs,.75rem);text-transform:capitalize;border-radius:9999px;padding:1px 8px;font-weight:600;display:inline-block}.nature-badge.harmonious{background:color-mix(in srgb, var(--roxy-success,#16a34a) 12%, transparent);color:var(--roxy-success-fg,#166534)}.nature-badge.challenging{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 12%, transparent);color:var(--roxy-danger-fg,#991b1b)}.nature-badge.neutral{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);color:var(--roxy-fg,#0a0a0a)}.scroll{-webkit-overflow-scrolling:touch;min-width:0;overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left;white-space:nowrap}thead th{color:var(--roxy-muted,#71717a);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}th{font-weight:var(--roxy-weight-bold,600)}td{font-variant-numeric:tabular-nums}.retro-badge{color:var(--roxy-danger-fg,#991b1b);font-weight:var(--roxy-weight-bold,600);margin-left:.25rem}.interp-keywords{flex-wrap:wrap;gap:.25rem;display:flex}.interp-keywords .kw{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-xs,.75rem);padding:1px 8px}`],p([(0,Qt.property)({type:String})],xr.prototype,"heading",2),p([(0,Qt.property)({type:Number})],xr.prototype,"ascendant",2),p([(0,Qt.property)({type:Array})],xr.prototype,"houses",2),xr=p([(0,Qt.customElement)("roxy-transit-wheel")],xr);var ee=require("lit"),ms=require("lit/decorators.js");var Wr=class extends g{constructor(){super(...arguments);this.tab="positions"}renderEmpty(){return ee.html`<div class="roxy-empty" role="status">No transits data</div>`}renderData(e){if(!e.transitPlanets?.length)return this.renderEmpty();let{transitDate:r,transitTime:a,transitPlanets:s,transitAspects:o,summary:i}=e,l=[D(this.effectiveLang(),r),Fe(this.effectiveLang(),a)].filter(Boolean).join(" "),d=o?.length??0,m=this.tab;return ee.html`<div class="wrap" aria-label="Transits"><div class="head"><h2 class="title">Transits</h2>${l?ee.html`<p class="subtitle">${l}</p>`:ee.nothing}</div>${d>0?ee.html`${_e({items:[{id:"positions",label:"Positions"},{id:"aspects",label:`Aspects (${d})`}],active:m,onSelect:c=>{this.tab=c},label:"Transit views",idPrefix:"transits",controls:!0})}<div id="transits-panel-${m}" role="tabpanel" aria-labelledby="transits-tab-${m}">${m==="positions"?ee.html`<div class="overflow-scroll">${this.renderPlanetsTable(s)}</div>`:ee.html`${i?this.renderSummaryPills(i):ee.nothing}<div class="overflow-scroll">${this.renderAspectsList(o??[])}</div>`}</div>`:ee.html`<div class="overflow-scroll">${this.renderPlanetsTable(s)}</div>`}</div>`}renderSummaryPills(e){return ee.html`<div class="summary-pills" role="region" aria-label="Aspect summary"><span class="pill pill--muted">Total: ${e.totalAspects} </span><span class="pill pill--success">Harmonious: ${e.harmonious} </span><span class="pill pill--danger">Challenging: ${e.challenging} </span><span class="pill pill--muted">Neutral: ${e.neutral}</span></div>`}renderPlanetsTable(e){return ee.html`<table class="planets-table"><caption class="roxy-sr-only">Transiting planets: each planet with its current sign, degree and daily speed.</caption><thead><tr><th scope="col">Planet</th><th scope="col">Sign</th><th scope="col">Degree</th><th scope="col">Speed</th></tr></thead><tbody>${e.map(r=>{let a=k(r.name)??"",s=q(r.sign)??"",o=r.speed>=0?"\u2191":"\u2193";return ee.html`<tr><td><div class="planet-cell"><span class="glyph" aria-hidden="true">${a}</span> ${r.name} ${r.isRetrograde?ee.html`<span class="retro-badge" aria-label="retrograde">R</span>`:ee.nothing}</div></td><td><div class="planet-cell"><span class="glyph" aria-hidden="true">${s}</span> ${r.sign}</div></td><td class="num">${x(r.degree,2)}</td><td class="speed"><span class="speed-arrow" aria-hidden="true">${o}</span> ${x(Math.abs(r.speed),2)}°/day</td></tr>`})}</tbody></table>`}renderAspectsList(e){return ee.html`<div role="list" aria-label="Transit aspects">${e.map((r,a)=>{let s=k(r.transitPlanet)??"",o=k(r.natalPlanet)??"",i=(r.nature??"neutral").toLowerCase(),l=r.interpretation,d=ke(r),m=r.isApplying?"Applying":"Separating";return ee.html`<details class="aspect-card" role="listitem" name="transit-aspects" ?open="${a===0}"><summary><span aria-hidden="true">${s}</span> ${r.transitPlanet} <span class="nature-badge ${i}">${d}</span> <span aria-hidden="true">${o}</span> ${r.natalPlanet} <span class="meta">${m} · orb ${x(r.orb,2)}° · strength ${x(r.strength,1)} </span>${te()}</summary><div class="interp-body">${l?.summary?ee.html`<p>${l.summary}</p>`:ee.nothing} ${l?.impact?ee.html`<p><strong>Impact:</strong> ${l.impact}</p>`:ee.nothing} ${l?.timing?ee.html`<p><strong>Timing:</strong> ${l.timing}</p>`:ee.nothing} ${l?.guidance?ee.html`<p><strong>Guidance:</strong> ${l.guidance}</p>`:ee.nothing} ${l?.keywords?.length?ee.html`<div class="interp-keywords">${l.keywords.map(c=>ee.html`<span class="kw">${c}</span>`)}</div>`:ee.nothing}</div></details>`})}</div>`}};Wr.styles=[y,Ee,O,ee.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.summary-pills{gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.pill{padding:2px var(--roxy-space-sm,.5rem);border-radius:var(--roxy-radius-full,9999px);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);border:1px solid;align-items:center;gap:4px;display:inline-flex}.pill--muted{color:var(--roxy-fg,#0a0a0a);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent)}.pill--success{color:var(--roxy-success-fg,#166534);background:color-mix(in srgb, var(--roxy-success,#16a34a) 10%, transparent)}.pill--danger{color:var(--roxy-danger-fg,#991b1b);background:color-mix(in srgb, var(--roxy-danger,#dc2626) 10%, transparent)}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}.section-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin:0 0 var(--roxy-space-xs,.25rem) 0}.glyph{margin-right:2px;font-size:1.1em;line-height:1}.planet-cell{white-space:nowrap;align-items:center;gap:4px;display:flex}.retro-badge{border-radius:var(--roxy-radius-sm,4px);background:color-mix(in srgb, var(--roxy-warning,#ea580c) 12%, transparent);color:var(--roxy-warning-fg,#9a3412);font-size:.7em;font-weight:var(--roxy-weight-bold,600);vertical-align:middle;margin-left:2px;padding:1px 4px;display:inline-block}.speed{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a);white-space:nowrap}.speed-arrow{font-size:.85em}td.num{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a)}.overflow-scroll{-webkit-overflow-scrolling:touch;min-width:0;overflow-x:auto}.aspect-card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);margin-bottom:var(--roxy-space-xs,.25rem)}.aspect-card summary{cursor:pointer;color:var(--roxy-fg,#0a0a0a);flex-wrap:wrap;align-items:center;gap:.5em;font-weight:500;display:flex}.aspect-card summary .meta{color:var(--roxy-muted,#71717a);font-weight:400;font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums;margin-left:auto}.aspect-card .interp-body{margin-top:var(--roxy-space-xs,.25rem);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);line-height:1.45}.aspect-card .interp-body p{margin:0 0 var(--roxy-space-xs,.25rem)}.interp-keywords{flex-wrap:wrap;gap:.25rem;margin-top:.5rem;display:flex}.interp-keywords .kw{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-accent-ink,#b45309);font-size:var(--roxy-text-xs,.75rem);border-radius:9999px;padding:1px 8px}.nature-badge{font-size:var(--roxy-text-xs,.75rem);border-radius:9999px;padding:1px 8px;font-weight:600;display:inline-block}.nature-badge.harmonious{background:color-mix(in srgb, var(--roxy-success,#16a34a) 12%, transparent);color:var(--roxy-success-fg,#166534)}.nature-badge.challenging{background:color-mix(in srgb, var(--roxy-danger,#dc2626) 12%, transparent);color:var(--roxy-danger-fg,#991b1b)}.nature-badge.neutral{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 60%, transparent);color:var(--roxy-fg,#0a0a0a)}`],p([(0,ms.state)()],Wr.prototype,"tab",2),Wr=p([(0,ms.customElement)("roxy-transits-table")],Wr);var fr=require("lit"),ti=require("lit/decorators.js");var Md=[{key:"timeBased",title:"Time based",note:"From the eightfold division of the day or night, so these depend on the birth time, the place and the weekday."},{key:"sunBased",title:"Sun based",note:"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."}],Bt=class extends g{renderEmpty(){return fr.html`<div class="roxy-empty" role="status">No upagraha data</div>`}renderData(t){let e=Md.filter(r=>t[r.key]?.length);return e.length?fr.html`<div class="wrap" aria-label="Upagraha positions"><header class="head"><h2 class="title">Upagrahas</h2>${ce(t.frame)}</header>${e.map(r=>this.renderGroup(r,t[r.key]))}</div>`:this.renderEmpty()}renderGroup(t,e){return fr.html`<section><div class="group-head"><h3 class="group-title">${t.title}</h3><p class="group-note">${t.note}</p></div><div class="scroll" tabindex="0"><table role="table"><caption class="roxy-sr-only">${t.title} upagrahas: each sub-planet with its rashi, degree in sign, sidereal longitude, and nakshatra with pada.</caption><thead><tr><th scope="col">Upagraha</th><th scope="col">Rashi</th><th scope="col">Degree</th><th scope="col">Longitude</th><th scope="col">Nakshatra</th><th scope="col">Pada</th></tr></thead><tbody>${e.map(r=>{let a=q(r.rashi)??"";return fr.html`<tr><td class="name">${r.name}</td><td>${a?fr.html`<span class="glyph">${a}</span>`:fr.nothing}${r.rashi??""}</td><td class="num">${typeof r.longitude=="number"?Ue(r.longitude):""}</td><td class="num">${x(r.longitude,2)}</td><td>${r.nakshatra??""}</td><td class="num">${r.nakshatraPada??""}</td></tr>`})}</tbody></table></div></section>`}};Bt.styles=[y,de,fr.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7)}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.group-head{padding:var(--roxy-space-md,1rem) var(--roxy-space-md,1rem) 0;gap:var(--roxy-space-xs,.25rem);display:grid}.group-title{font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);margin:0}.group-note{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-xs,.75rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.scroll{min-width:0;overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:520px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}td.name{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.4em}.num{font-variant-numeric:tabular-nums}`],Bt=p([(0,ti.customElement)("roxy-upagraha-table")],Bt);var we=require("lit"),ai=require("lit/decorators.js");var Ot=class extends g{renderEmpty(){return we.html`<div class="roxy-empty" role="status">No aspect data</div>`}renderData(t){let e=t.aspects??[],r=t.mutualAspects??[],a=t.planets??[];if(e.length===0&&r.length===0)return this.renderEmpty();let s=t.datetime?`${D(this.effectiveLang(),t.datetime)}, ${Fe(this.effectiveLang(),t.datetime)}`:"";return we.html`<div class="wrap" aria-label="Vedic aspects"><div class="head"><h2 class="title">Vedic aspects</h2>${s?we.html`<p class="subtitle">Chart time ${s}</p>`:we.nothing}</div>${a.length>0?we.html`<div><p class="section-label">Sidereal positions</p><div class="mutual">${a.map(o=>we.html`<span class="position"><strong>${o.name}</strong> ${typeof o.longitude=="number"?Ue(o.longitude):o.sign??""}</span>`)}</div></div>`:we.nothing} ${r.length>0?we.html`<div><p class="section-label">Mutual aspects</p><div class="mutual">${r.map(o=>we.html`<span class="mutual-pill">${o.planet1} ⟷ ${o.planet2} ${o.aspectType?we.html`<span class="rel">${o.aspectType}</span>`:we.nothing}</span>`)}</div></div>`:we.nothing} ${e.length>0?we.html`<div class="overflow-scroll"><table><caption class="roxy-sr-only">Vedic planetary aspects: aspecting planet, aspect type, aspected planet, strength and orb.</caption><thead><tr><th scope="col">From</th><th scope="col">Aspect</th><th scope="col">To</th><th scope="col">Strength</th><th scope="col">Orb</th></tr></thead><tbody>${e.map(o=>we.html`<tr><td>${o.aspectingPlanet}</td><td><span class="kind">${o.aspectType}</span></td><td>${o.aspectedPlanet}</td><td>${typeof o.strength=="number"?we.html`<span class="bar" style="width:${Math.max(4,Math.min(100,o.strength)*.4)}px"></span><span class="num">${x(o.strength,0)}</span>`:we.nothing}</td><td class="num">${typeof o.orb=="number"?`${x(o.orb,2)}\xB0`:""}</td></tr>`)}</tbody></table></div>`:we.nothing}</div>`}};Ot.styles=[y,we.css`.wrap{background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-lg,1.5rem);box-shadow:var(--roxy-shadow-sm);gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-md,1rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.subtitle{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);margin:0}.section-label{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);text-transform:uppercase;letter-spacing:.06em;font-weight:var(--roxy-weight-bold,600);margin:0 0 var(--roxy-space-xs,.25rem) 0}.mutual{gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.mutual-pill{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 14%, transparent);color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);align-items:center;gap:.35rem;padding:2px 10px;display:inline-flex}.mutual-pill .rel{font-size:var(--roxy-text-xs,.75rem);font-weight:400}.position{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 55%, transparent);font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-fg,#0a0a0a);font-variant-numeric:tabular-nums;align-items:baseline;gap:.35rem;padding:2px 10px;display:inline-flex}.position strong{color:var(--roxy-fg,#0a0a0a);font-size:var(--roxy-text-sm,.875rem)}.overflow-scroll{-webkit-overflow-scrolling:touch;min-width:0;overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem)}th,td{padding:var(--roxy-space-sm,.5rem);border-bottom:1px solid var(--roxy-border,#e4e4e7);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.06em}tbody tr:last-child td{border-bottom:none}.kind{border-radius:var(--roxy-radius-full,9999px);background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 55%, transparent);font-size:var(--roxy-text-xs,.75rem);padding:1px 8px;font-weight:600;display:inline-block}.num{font-variant-numeric:tabular-nums;color:var(--roxy-muted,#71717a)}.bar{background:var(--roxy-accent,#f59e0b);vertical-align:middle;border-radius:3px;height:6px;margin-right:6px;display:inline-block}`],Ot=p([(0,ai.customElement)("roxy-vedic-aspects")],Ot);var sn=require("lit"),ea=require("lit/decorators.js");var br=class extends g{constructor(){super(...arguments);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?Fa(this.data.meta,"D1 Rashi",this.resolveReference()):null}renderEmpty(){return sn.html`<div class="roxy-empty" role="status">No kundli data</div>`}renderData(e){let r=this.viewModel();if(!r)return this.renderEmpty();let a=this.chartReference==="moon"&&!this.lagnaOverride?"Chandra lagna":"Vedic kundli";return sn.html`<div class="wrap"><div class="header"><div><h2 class="title">${a}</h2>${ce(e.frame)}</div>${Ka(this.chartStyle,this.setStyle)}</div><div id="kundli-panel-${this.chartStyle}" role="tabpanel" tabindex="0" aria-labelledby="kundli-tab-${this.chartStyle}"><svg viewBox="0 0 400 400" preserveAspectRatio="xMidYMid meet" role="img" aria-label="Vedic birth chart with twelve sign houses"><title>Vedic kundli</title>${_a(r,this.chartStyle)}</svg></div></div>`}};br.styles=[y,de,qa,Ee],p([(0,ea.property)({type:String,reflect:!0,attribute:"chart-style"})],br.prototype,"chartStyle",2),p([(0,ea.property)({type:String,reflect:!0,attribute:"chart-reference"})],br.prototype,"chartReference",2),p([(0,ea.property)({type:String,reflect:!0,attribute:"lagna-override"})],br.prototype,"lagnaOverride",2),br=p([(0,ea.customElement)("roxy-vedic-kundli")],br);var P=require("lit"),si=require("lit/decorators.js");var Pd=["Lagna","Sun","Moon","Mars","Mercury","Jupiter","Venus","Saturn","Rahu","Ketu"],It=class extends g{orderedRows(){let t=this.data?.meta??{},e=new Set,r=[];for(let a of Pd){let s=t[a];s&&(r.push([a,s]),e.add(a))}for(let[a,s]of Object.entries(t))e.has(a)||r.push([a,s]);return r}renderEmpty(){return P.html`<div class="roxy-empty" role="status">No chart data</div>`}renderData(t){if(!t.meta)return this.renderEmpty();let e=this.orderedRows();return P.html`<div class="wrap" aria-label="Vedic planetary positions"><header class="head"><h2 class="title">Planetary positions</h2>${ce(t.frame)}</header><div class="scroll" tabindex="0"><table role="table"><caption class="roxy-sr-only">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.</caption><thead><tr><th scope="col">Graha</th><th scope="col">Rashi</th><th scope="col">Degree</th><th scope="col">Nakshatra</th><th scope="col">Pada</th><th scope="col">Nak. lord</th><th scope="col">House</th><th scope="col" title="Baladi: the five age states, set by degree within the sign">Baladi</th><th scope="col" title="Jagradadi: the three waking states, set by sign dignity. The seven classical grahas only">Jagradadi</th><th scope="col" title="Deeptadi: the nine dispositional states, set by sign dignity. The seven classical grahas only">Deeptadi</th><th scope="col">Retro</th></tr></thead><tbody>${e.map(([r,a])=>{let s=(a.graha??r)==="Lagna",o=k(a.graha??r)??"",i=q(a.rashi)??"";return P.html`<tr class="${s?"lagna":""}"><td class="graha">${o?P.html`<span class="glyph">${o}</span>`:P.nothing}${a.graha??r}</td><td>${i?P.html`<span class="glyph">${i}</span>`:P.nothing}${a.rashi??""}</td><td class="num">${typeof a.longitude=="number"?Ue(a.longitude):""}</td><td>${a.nakshatra?.name??""}</td><td class="num">${a.nakshatra?.pada??""}</td><td>${a.nakshatra?.lord??""}</td><td class="num">${typeof a.house=="number"?a.house:""}</td><td>${a.awastha??""}</td><td>${a.jagradadi??""}</td><td>${a.deeptadi??""}</td><td>${a.isRetrograde?P.html`<span class="retro">R</span>`:P.nothing}</td></tr>`})} ${this.renderModernRows()}</tbody></table></div>${this.renderCombustion()} ${this.renderPlanetaryWar()} ${this.renderInterpretations()} ${this.renderYogas()} ${this.renderHouses()}</div>`}renderModernRows(){let t=this.data?.modernPlanets??[];return t.length===0?P.nothing:t.map((e,r)=>{let a=q(e.rashi)??"";return P.html`<tr class="modern ${r===0?"modern-first":""}"><td class="graha">${aa(e.planet,e.sanskritName)}</td><td>${a?P.html`<span class="glyph">${a}</span>`:P.nothing}${e.rashi??""}</td><td class="num">${typeof e.longitude=="number"?Ue(e.longitude):""}</td><td>${e.nakshatra?.name??""}</td><td class="num">${e.nakshatra?.pada??""}</td><td>${e.nakshatra?.lord??""}</td><td></td><td></td><td></td><td></td><td>${e.isRetrograde?P.html`<span class="retro">R</span>`:P.nothing}</td></tr>`})}renderCombustion(){let t=this.data?.combustion??[];return t.length===0?P.nothing:P.html`<details class="panel"><summary>Combust grahas<span class="summary-count">${t.length}</span>${te()}</summary><div class="panel-body">${t.map(e=>{let r=k(e.planet)??"",a=x(e.distanceFromSun,2),s=x(e.orb,1);return P.html`<div class="condition"><span class="planet">${r?`${r} `:""}${e.planet}</span> <span class="detail">${a} deg from Sun, within ${s} deg orb</span></div>`})}</div></details>`}renderPlanetaryWar(){let t=this.data?.planetaryWar??[];return t.length===0?P.nothing:P.html`<details class="panel"><summary>Planetary wars<span class="summary-count">${t.length}</span>${te()}</summary><div class="panel-body">${t.map(e=>{let r=x(e.distance,2);return P.html`<div class="condition"><span class="planet">${e.planet1} vs ${e.planet2}</span> <span class="detail">${r} deg apart</span> <span class="winner">${e.winner} wins</span></div>`})}</div></details>`}renderInterpretations(){let t=this.data?.interpretations??{},e=this.orderedRows().map(([r,a])=>[a.graha??r,t[a.graha??r]]).filter(([,r])=>r!=null);return e.length===0?P.nothing:P.html`<details class="panel"><summary>Interpretations<span class="summary-count">${e.length}</span>${te()}</summary><div class="panel-body">${e.map(([r,a])=>{let s=k(r)??"";return P.html`<div class="interp"><span class="planet">${s?`${s} `:""}${r}</span> ${a.rashi?P.html`<p><span class="label">Rashi.</span> ${a.rashi}</p>`:P.nothing} ${a.nakshatra?P.html`<p><span class="label">Nakshatra.</span> ${a.nakshatra}</p>`:P.nothing}</div>`})}</div></details>`}renderHouses(){let t=(this.data?.houses??[]).filter(e=>e.name||e.description);return t.length===0?P.nothing:P.html`<details class="panel"><summary>Bhava significations<span class="summary-count">${t.length}</span>${te()}</summary><div class="panel-body">${t.map(e=>P.html`<div class="bhava"><span class="name">${e.number}. ${e.name??""}</span> ${e.description?P.html`<p class="desc">${e.description}</p>`:P.nothing}</div>`)}</div></details>`}renderYogas(){let t=(this.data?.yogas??[]).filter(e=>e.present);return t.length===0?P.nothing:P.html`<details class="panel"><summary>Yogas<span class="summary-count">${t.length}</span>${te()}</summary><div class="panel-body">${t.map(e=>P.html`<div class="bhava"><span class="name">${e.name} ${e.quality?P.html`<span class="quality ${e.quality.toLowerCase()}">${e.quality}</span>`:P.nothing}</span> ${e.result?P.html`<p class="desc">${e.result}</p>`:P.nothing}</div>`)}</div></details>`}};It.styles=[y,de,O,P.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:hidden}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7)}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.scroll{min-width:0;overflow-x:auto}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:760px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}tbody tr.lagna{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 10%, transparent)}tbody tr.modern-first{border-top-width:2px}td.graha{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.4em}tbody tr.lagna .glyph{color:var(--roxy-accent-ink,#b45309)}.retro{color:var(--roxy-warning-fg,#9a3412);font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600)}.num{font-variant-numeric:tabular-nums}details.panel{border-top:1px solid var(--roxy-border,#e4e4e7)}details.panel>summary{justify-content:space-between;align-items:center;gap:var(--roxy-space-sm,.5rem);padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);cursor:pointer;font-size:var(--roxy-text-sm,.875rem);font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a);display:flex}details.panel>summary:focus-visible{outline:2px solid var(--roxy-ring,#f59e0b66);outline-offset:-2px}.summary-count{margin-left:auto;margin-right:var(--roxy-space-xs,.25rem);font-weight:var(--roxy-weight-normal,400);color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums}.panel-body{padding:0 var(--roxy-space-md,1rem) var(--roxy-space-md,1rem);gap:var(--roxy-space-sm,.5rem);grid-template-columns:minmax(0,1fr);display:grid}.condition{font-size:var(--roxy-text-sm,.875rem);flex-wrap:wrap;align-items:baseline;gap:.4em;display:flex}.condition .planet{font-weight:var(--roxy-weight-bold,600)}.condition .detail{color:var(--roxy-muted,#71717a);font-variant-numeric:tabular-nums}.condition .winner{color:var(--roxy-success-fg,#166534);font-weight:var(--roxy-weight-bold,600)}.interp{gap:.15em;display:grid}.interp .planet{font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem)}.interp p{font-size:var(--roxy-text-sm,.875rem);line-height:var(--roxy-leading-normal,1.5);margin:0}.interp .label{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600)}.bhava{gap:.15em;display:grid}.bhava .name{font-weight:var(--roxy-weight-bold,600);font-size:var(--roxy-text-sm,.875rem)}.bhava .desc{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);line-height:var(--roxy-leading-normal,1.5);margin:0}.quality{font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.04em}.quality.positive{color:var(--roxy-success-fg,#166534)}.quality.negative{color:var(--roxy-danger-fg,#991b1b)}.quality.both{color:var(--roxy-muted,#71717a)}`],It=p([(0,si.customElement)("roxy-vedic-planets-table")],It);var rr=require("lit"),ni=require("lit/decorators.js");var Ht=class extends g{rows(){let t=this.data;if(!t)return[];let e=(t.planets??[]).map(r=>({name:r.name,sign:r.sign,longitude:r.longitude,house:r.house,speed:r.speed,isRetrograde:r.isRetrograde}));for(let[r,a]of[["Ascendant",t.ascendant],["Midheaven",t.midheaven],["Part of Fortune",t.partOfFortune],["Vertex",t.vertex]])a&&e.push({name:r,sign:a.sign,longitude:a.longitude,isPoint:!0});return e}renderEmpty(){return rr.html`<div class="roxy-empty" role="status">No chart data</div>`}renderData(t){if(!t.planets)return this.renderEmpty();let e=this.rows();return rr.html`<div class="wrap" aria-label="Western planetary positions" tabindex="0"><header class="head"><h2 class="title">Planetary positions</h2></header><table role="table"><caption class="roxy-sr-only">Western planetary positions: each body with its sign, degree, house and motion.</caption><thead><tr><th scope="col">Body</th><th scope="col">Sign</th><th scope="col">Degree</th><th scope="col">House</th><th scope="col">Motion</th></tr></thead><tbody>${e.map(r=>{let a=k(r.name)??"",s=q(r.sign)??"",o=typeof r.speed=="number"?x(r.speed,3):"";return rr.html`<tr class="${r.isPoint?"point":""}"><td class="body">${a?rr.html`<span class="glyph">${a}</span>`:rr.nothing}${r.name}</td><td>${s?rr.html`<span class="glyph">${s}</span>`:rr.nothing}${r.sign??""}</td><td class="num">${typeof r.longitude=="number"?Ue(r.longitude):""}</td><td class="num">${typeof r.house=="number"?r.house:""}</td><td class="num">${o?rr.html`${o}°/day`:rr.nothing} ${r.isRetrograde?rr.html`<span class="retro">℞</span>`:rr.nothing}</td></tr>`})}</tbody></table></div>`}};Ht.styles=[y,rr.css`.wrap{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);box-shadow:var(--roxy-shadow-sm);overflow:auto}.head{padding:var(--roxy-space-md,1rem);border-bottom:1px solid var(--roxy-border,#e4e4e7)}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}table{border-collapse:collapse;width:100%;font-size:var(--roxy-text-sm,.875rem);min-width:460px}thead{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 20%, transparent)}th,td{padding:var(--roxy-space-sm,.5rem) var(--roxy-space-md,1rem);text-align:left;white-space:nowrap}th{color:var(--roxy-muted,#71717a);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;font-size:var(--roxy-text-xs,.75rem);letter-spacing:.04em}tbody tr{border-top:1px solid var(--roxy-border,#e4e4e7)}tbody tr.point{background:color-mix(in srgb, var(--roxy-accent,#f59e0b) 8%, transparent)}td.body{font-weight:var(--roxy-weight-bold,600);color:var(--roxy-fg,#0a0a0a)}.glyph{color:var(--roxy-muted,#71717a);margin-right:.4em}.retro{color:var(--roxy-danger,#dc2626);font-weight:var(--roxy-weight-bold,600)}.num{font-variant-numeric:tabular-nums}`],Ht=p([(0,ni.customElement)("roxy-western-planets-table")],Ht);var X=require("lit"),gs=require("lit/decorators.js");function oi(n){return n.suppressedBy||void 0}var ii=["classical","asraya","dala","akriti","sankhya"];function li(n){let t=ii.indexOf(n.family);return t===-1?ii.length:t}var Nd=[{id:"present",label:"Present",open:!0,note:"Every classical condition is satisfied by this chart."},{id:"outranked",label:"Outranked",open:!0,note:"The rule matched, but a stronger family silences it under the classical precedence norms. Each card names the family that took precedence."},{id:"absent",label:"Not present",open:!1,note:"At least one classical condition fails. Read the evidence for which."}],Jr=class extends g{constructor(){super(...arguments);this.filter="";this.handleInput=e=>{this.filter=e.target.value}}verdictOf(e){return e.present?"present":oi(e)?"outranked":"absent"}renderVerdictGroup(e,r){if(!r.length)return X.nothing;let a=[...r].sort((s,o)=>li(s)-li(o));return X.html`<details class="group" part="section verdict" ?open="${e.open||!!this.filter}"><summary class="group-summary"><span class="group-label">${e.label}</span> <span class="group-count">${r.length}</span></summary><p class="group-note">${e.note}</p><div class="detail-grid">${a.map(s=>this.renderDetectCard(s))}</div></details>`}renderQualityChip(e){let r=`quality-chip quality-${e}`;return X.html`<span class="${r}">${e}</span>`}renderFamilyChip(e){return e.family?X.html`<span class="family-chip" title="Classical family">${Z(e.family)}</span>`:X.nothing}renderDetailCard(e){return X.html`<div class="detail-card"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):X.nothing} ${this.renderFamilyChip(e)}</p>${e.description&&!this.hideReadings?X.html`<p class="description">${e.description}</p>`:X.nothing} ${this.renderEffects(e.result)}</div>`}renderEffects(e){return!e||this.hideReadings?X.nothing:X.html`<details part="reading"><summary>Effects</summary><div class="result-body">${e}</div></details>`}renderDetectCard(e){let r=e.present?void 0:oi(e),[a,s]=e.present?["is-present","Present"]:r?["is-outranked",`Outranked by ${Z(r)}`]:["is-absent","Not present"];return X.html`<div class="detail-card ${e.present?"":r?"outranked":"absent"}"><p class="detail-name">${e.name} ${e.quality?this.renderQualityChip(e.quality):X.nothing} ${this.renderFamilyChip(e)} <span class="present-badge ${a}">${s}</span></p>${e.description&&!this.hideReadings?X.html`<p class="description">${e.description}</p>`:X.nothing} ${e.present?this.renderEffects(e.result):X.nothing} ${e.evidence?X.html`<p class="evidence">${e.evidence}</p>`:X.nothing}</div>`}renderEmpty(){return X.html`<div class="roxy-empty" role="status">No yoga data</div>`}renderData(e){let r=this.filter.toLowerCase();if("description"in e&&typeof e.description=="string"){let a=e;return X.html`<div class="wrap" part="card">${this.renderDetailCard(a)}</div>`}if("yogas"in e&&Array.isArray(e.yogas)){let a=e.yogas;if(a.length>0&&"present"in a[0]){let d=a,m=r?d.filter(u=>u.name.toLowerCase().includes(r)):d,c=e.total??d.filter(u=>u.present).length;return X.html`<div class="wrap" part="card"><div class="head" part="header"><h2 class="title">Detected yogas</h2><span class="count">${c} of ${d.length} present</span></div>${ce(e.frame)}<div class="search-wrap"><input class="search" type="search" placeholder="Filter yogas..." aria-label="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="Detected yogas">${m.length>0?Nd.map(u=>this.renderVerdictGroup(u,m.filter(z=>this.verdictOf(z)===u.id))):X.html`<p class="no-results">No yogas match your search.</p>`}</div></div>`}if(a.length>0&&"description"in a[0]){let d=a,m=r?d.filter(u=>u.name.toLowerCase().includes(r)):d,c=e.total;return X.html`<div class="wrap" part="card"><div class="head" part="header"><h2 class="title">Yoga catalog</h2>${c!==void 0?X.html`<span class="count">${c} total</span>`:X.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="Filter yogas..." aria-label="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="Yoga results">${m.length>0?m.map(u=>this.renderDetailCard(u)):X.html`<p class="no-results">No yogas match your search.</p>`}</div></div>`}let o=a,i=r?o.filter(d=>d.name.toLowerCase().includes(r)):o,l=e.total;return X.html`<div class="wrap" part="card"><div class="head" part="header"><h2 class="title">Yoga catalog</h2>${l!==void 0?X.html`<span class="count">${l} total</span>`:X.nothing}</div><div class="search-wrap"><input class="search" type="search" placeholder="Filter yogas..." aria-label="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="Yoga results">${i.length>0?i.map(d=>X.html`<div class="yoga-chip">${d.name}</div>`):X.html`<p class="no-results">No yogas match your search.</p>`}</div></div>`}return X.html`<div class="roxy-empty" role="status">No yoga data</div>`}};Jr.styles=[y,de,X.css`.wrap{gap:var(--roxy-space-md,1rem);grid-template-columns:minmax(0,1fr);display:grid}.head{justify-content:space-between;align-items:baseline;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;display:flex}.title{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);margin:0}.count{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a)}.search-wrap{align-items:center;gap:var(--roxy-space-sm,.5rem);display:flex}.search{width:100%;max-width:280px;font-size:var(--roxy-text-sm,.875rem);font-family:var(--roxy-font-sans);border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);outline:none;padding:.35em .75em}.search::placeholder{color:var(--roxy-fg,#0a0a0a);opacity:.65}.search:focus{border-color:var(--roxy-accent,#f59e0b);box-shadow:0 0 0 2px color-mix(in srgb, var(--roxy-accent,#f59e0b) 30%, transparent)}.grid{gap:var(--roxy-space-sm,.5rem);grid-template-columns:repeat(auto-fill,minmax(180px,1fr));display:grid}.yoga-chip{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);font-size:var(--roxy-text-sm,.875rem);background:var(--roxy-surface,#fff);color:var(--roxy-fg,#0a0a0a);word-break:break-word;padding:.4em .8em}.yoga-chip .yoga-id{color:var(--roxy-fg,#0a0a0a);opacity:.75;margin-top:.15em;font-size:.7em;display:block}.detail-card{border:1px solid var(--roxy-border,#e4e4e7);border-radius:var(--roxy-radius-md,8px);padding:var(--roxy-space-md,1rem);background:var(--roxy-surface,#fff);gap:var(--roxy-space-sm,.5rem);display:grid}.detail-name{font-size:var(--roxy-text-lg,1.125rem);font-weight:var(--roxy-weight-bold,600);align-items:center;gap:var(--roxy-space-sm,.5rem);flex-wrap:wrap;margin:0;display:flex}.quality-chip{font-size:var(--roxy-text-xs,.75rem);border-radius:999px;padding:.15em .6em;font-weight:600;display:inline-block}.quality-Positive{background:color-mix(in srgb, var(--roxy-success,#22c55e) 18%, transparent);color:var(--roxy-success-fg,#15803d);border:1px solid color-mix(in srgb, var(--roxy-success,#22c55e) 40%, transparent)}.quality-Negative{background:color-mix(in srgb, var(--roxy-danger,#ef4444) 18%, transparent);color:var(--roxy-danger-fg,#b91c1c);border:1px solid color-mix(in srgb, var(--roxy-danger,#ef4444) 40%, transparent)}.quality-Both{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 18%, transparent);color:var(--roxy-warning-fg,#b45309);border:1px solid color-mix(in srgb, var(--roxy-warning,#f59e0b) 40%, transparent)}.family-chip{font-size:var(--roxy-text-xs,.75rem);border:1px solid var(--roxy-border,#e4e4e7);color:var(--roxy-fg,#0a0a0a);border-radius:999px;padding:.15em .6em;font-weight:500;display:inline-block}.present-badge{font-size:var(--roxy-text-xs,.75rem);border-radius:999px;padding:.15em .6em;font-weight:600;display:inline-block}.present-badge.is-present{background:color-mix(in srgb, var(--roxy-success,#16a34a) 16%, transparent);color:var(--roxy-success-fg,#166534)}.present-badge.is-absent{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 55%, transparent);color:var(--roxy-fg,#0a0a0a)}.present-badge.is-outranked{background:color-mix(in srgb, var(--roxy-warning,#f59e0b) 16%, transparent);color:var(--roxy-warning-fg,#b45309)}.detail-card.absent{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 22%, var(--roxy-surface,#fff))}.detail-card.outranked{background:color-mix(in srgb, var(--roxy-border,#e4e4e7) 10%, var(--roxy-surface,#fff))}.group-stack{gap:var(--roxy-space-md,1rem);display:grid}.group{gap:var(--roxy-space-sm,.5rem);display:grid}.group-summary{align-items:baseline;gap:var(--roxy-space-sm,.5rem);cursor:pointer;color:var(--roxy-muted,#71717a);list-style:none;display:flex}.group-summary:before{content:"+";color:var(--roxy-accent-ink,#b45309);font-size:1.1em;line-height:1}.group[open]>.group-summary:before{content:"-"}.group-label{font-size:var(--roxy-text-xs,.75rem);font-weight:var(--roxy-weight-bold,600);text-transform:uppercase;letter-spacing:.06em}.group-count{font-size:var(--roxy-text-xs,.75rem);font-variant-numeric:tabular-nums}.group-note,.evidence{font-size:var(--roxy-text-xs,.75rem);color:var(--roxy-muted,#71717a);line-height:var(--roxy-leading-normal,1.5);margin:0}.description{font-size:var(--roxy-text-sm,.875rem);color:var(--roxy-muted,#71717a);line-height:var(--roxy-leading-normal,1.5);margin:0}.detail-card details{font-size:var(--roxy-text-sm,.875rem)}.detail-card details>summary{cursor:pointer;color:var(--roxy-accent-ink,#b45309);align-items:center;gap:.4em;padding:.25em 0;font-weight:500;list-style:none;display:flex}.detail-card details>summary:before{content:"+";font-size:1.1em;line-height:1}.detail-card details[open]>summary:before{content:"-"}.detail-card details .result-body{padding-top:var(--roxy-space-xs,.25rem);color:var(--roxy-fg,#0a0a0a);line-height:var(--roxy-leading-normal,1.5)}.no-results{color:var(--roxy-muted,#71717a);font-size:var(--roxy-text-sm,.875rem);padding:var(--roxy-space-md,1rem) 0;text-align:center}.detail-grid{gap:var(--roxy-space-sm,.5rem);display:grid}`],p([(0,gs.state)()],Jr.prototype,"filter",2),Jr=p([(0,gs.customElement)("roxy-yoga-list")],Jr);var hs=[{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:"Daily horoscope",description:"Daily, weekly, or monthly horoscope card for /astrology/horoscope/...",docsLabel:"Western",endpointLabel:"GET /astrology/horoscope/{sign}/{daily,weekly,monthly}",docsSummary:"Daily, weekly, or monthly 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:"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:"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, 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:"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 from the tarot catalog response",docsLabel:"Tarot",endpointLabel:"GET /tarot/cards",docsSummary:"Deck gallery tiles with card art, name, and arcana and suit",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}, /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:"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:"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/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",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",docsLabel:"Crystals",endpointLabel:"GET /crystals, /crystals/chakra/{chakra}, /crystals/element/{element}, /crystals/zodiac/{sign}, /crystals/birthstone/{month}, /crystals/search",docsSummary:"Crystal gallery tiles with photo, name, and colour swatches",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",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:"Dream-symbol search results as selectable tiles; emits roxy-symbol-select to pair with roxy-dream-card",docsLabel:"Dreams",endpointLabel:"GET /dreams/symbols",docsSummary:"Matched dream symbols as selectable tiles with a letter chip",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}",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:"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, numerology number or compound number",docsLabel:"Reference",endpointLabel:"GET /astrology/{signs,planet-meanings}/{id}, /vedic-astrology/rashis/{id}, /iching/trigrams/{id}, /human-design/{gates,centers}/{id}, /numerology/{meanings,compound-number}/{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:!0},{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:!0},{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:!0}];var Gd=hs.map(n=>n.slug);
|
|
114
114
|
//# sourceMappingURL=index.cjs.map
|