@font-face{font-family:"AKbalthom Angkor 2";src:url("assets/fonts/AKbalthom-Angkor-2.ttf") format("truetype");font-display:swap}
@font-face{font-family:"Kh Content";src:url("assets/fonts/Kh-Content.ttf") format("truetype");font-display:swap}
@font-face{font-family:"AKbalthom Moul";src:url("assets/fonts/AKbalthom-Moul-8.ttf") format("truetype");font-display:swap}
body{background:#fff;color:#171717;font-family:"Kh Content","Khmer UI","Noto Sans Khmer",sans-serif}
/* The supplied zodiac artwork becomes the home backdrop.  The photo and orbit overlay move independently for a calm celestial effect. */
body.home-page{position:relative;isolation:isolate;min-height:100vh;background:#030817;color:#171717}
body.home-page::before{content:"";position:fixed;inset:0;z-index:-2;background-image:linear-gradient(135deg,#01081755,#07152a60),url("assets/home-zodiac-orbit.webp");background-position:center,center;background-size:cover,clamp(360px,50vw,860px) auto;background-repeat:no-repeat,no-repeat;transform:scale(1.04);transform-origin:center;animation:home-solar-drift 30s ease-in-out infinite alternate;will-change:transform}
body.home-page::after{content:"";position:fixed;inset:-20vmax;z-index:-1;pointer-events:none;opacity:.32;background:repeating-radial-gradient(ellipse at center,transparent 0 17%,#f4bd5b00 17.05%,#f4bd5b4d 17.18%,#f4bd5b00 17.36%,transparent 26%);transform-origin:center;animation:home-zodiac-orbit 48s linear infinite;will-change:transform}
@keyframes home-solar-drift{0%{transform:scale(1.04) rotate(-.35deg);filter:saturate(1.02) brightness(.94)}100%{transform:scale(1.12) rotate(.35deg);filter:saturate(1.14) brightness(1.05)}}
@keyframes home-zodiac-orbit{to{transform:rotate(360deg)}}
body.home-page header{background:#ffffff8c;border-bottom-color:#8ebdcab8;backdrop-filter:blur(10px)}
body.home-page header h1,body.home-page header p,body.home-page header .eyebrow{color:#17667d}
body.home-page .form-card,body.home-page .identity,body.home-page .calendar-card,body.home-page .sun-times,body.home-page .element-key{background:#ffffff8c;backdrop-filter:blur(9px)}
body.home-page .page-links .page-link{background:#ffffffb3}
body.home-page main{display:block;max-width:1600px}
body.home-page .calendar-card{border-color:#8ebdcab8;color:#17667d}
body.home-page .calendar-title{background:#f2fbfda6;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}
body.home-page .calendar-title.dark{color:#17667d}
body.home-page .calendar-row{background:#ffffff91;border-top-color:#8ebdca99}
body.home-page .calendar-row span{border-right-color:#8ebdca99;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}
body.home-page .calendar-row span:nth-child(1),body.home-page .calendar-row span:nth-child(3){background:#e8f6f4a3;color:#17667d}
body.home-page .calendar-row span:nth-child(2),body.home-page .calendar-row span:nth-child(4){color:#17667d}
body.home-page .sun-times{border-color:#8ebdcab8;background:#ffffff91;color:#17667d}
body.home-page .sun-times span{border-right-color:#8ebdca99;color:#17667d}
body.home-page .sun-times b{color:#17667d}
/* Keep the live date details compact at the bottom of the home page, without a coloured panel behind them. */
body.home-page{display:flex;flex-direction:column}
body.home-page main{display:flex;flex:1;width:min(1600px,100%);padding-bottom:6px}
body.home-page .content{display:flex;flex:1;flex-direction:column;gap:12px}
body.home-page .calendar-card{align-self:center;width:min(100%,780px);margin-top:auto;border-color:#d6f2fa9c;background:transparent;backdrop-filter:none;color:#eafaff}
body.home-page .calendar-title,body.home-page .calendar-title.dark,body.home-page .calendar-row,body.home-page .calendar-row span,body.home-page .calendar-row span:nth-child(1),body.home-page .calendar-row span:nth-child(2),body.home-page .calendar-row span:nth-child(3),body.home-page .calendar-row span:nth-child(4){background:transparent;color:#eafaff;text-shadow:0 1px 3px #00111e}
body.home-page .calendar-title{padding:4px 7px;font-size:12px}
body.home-page .calendar-row{border-top-color:#d6f2fa78}
body.home-page .calendar-row span{padding:4px 7px;border-right-color:#d6f2fa78;font-size:13px}
body.home-page .home-live-info{align-self:center;width:min(100%,900px);margin-top:auto;display:grid;justify-items:center;gap:4px;color:#eafaff;text-align:center}
body.home-page .sun-times{align-self:center;width:auto;margin:0;display:flex;flex-wrap:nowrap;justify-content:center;gap:10px;border:0;background:transparent;backdrop-filter:none;color:#eafaff;white-space:nowrap}
body.home-page .sun-times span{padding:0;border:0;color:#eafaff;text-shadow:0 1px 3px #00111e;font-size:15.6px;line-height:1.5}
body.home-page .sun-times b{color:inherit;font-size:inherit;font-weight:400}
body.home-page .current-date-lines{
  align-self:center;
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:4px;
  margin:0;
  color:#eafaff;
  text-align:center;
  text-shadow:0 1px 3px #00111e
}
body.home-page .current-date-lines span{
  display:block;
  color:#eafaff;
  font:400 15.6px/1.5 "Kh Content","Khmer UI",sans-serif;
  text-align:center
}
body.home-page .current-date-lines .current-solar-date{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  flex-wrap:wrap
}
body.home-page .current-date-lines .current-clock,
body.home-page .current-date-lines .current-yam{
  display:inline-flex;
  align-items:center;
  min-height:25px;
  padding:1px 9px;
  border:1px solid #eafaff99;
  border-radius:999px;
  background:#07122673;
  color:#fff;
  font:400 14px/1.4 "Kh Content","Khmer UI",sans-serif;
  text-shadow:0 1px 3px #00111e;
  white-space:nowrap;
  text-decoration:none
}
body.home-page .current-date-lines .current-sutin-row{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  flex-wrap:wrap;
  margin-top:2px
}
body.home-page .current-date-lines .current-sutin{
  display:inline-block;
  align-self:center;
  margin-top:0;
  padding:3px 12px;
  border-radius:8px;
  background:rgba(255,255,255,.92);
  color:#c62828;
  font:400 15.6px/1.5 "Kh Content","Khmer UI",sans-serif;
  text-shadow:none;
  white-space:nowrap
}
body.home-page .current-date-lines a.current-moon-mansion{
  text-decoration:none;
  white-space:normal;
  max-width:min(100%, 34em);
  text-align:center
}
body.home-page .current-date-lines .current-moon-course{
  white-space:nowrap
}
body.home-page .current-date-lines a.current-moon-mansion:hover,
body.home-page .current-date-lines a.current-moon-mansion:focus-visible{
  background:#fff;
  color:#8b1515;
  box-shadow:0 0 0 1px #c62828
}
body.home-page .current-date-lines .current-moon-change-row{
  margin-top:4px
}
/* Leave the animated zodiac artwork visible behind the home page heading. */
body.home-page header{background:transparent;backdrop-filter:none;border-bottom-color:transparent}
body.home-page header h1,body.home-page header p,body.home-page header .eyebrow{color:#fff}
/* Give every standard site button a clear, consistent hover state. */
button:not(:disabled),.page-link{transition:background-color .18s ease,color .18s ease,border-color .18s ease,box-shadow .18s ease,transform .18s ease}
button:not(:disabled):hover,.page-link:hover{background:#e7b84f!important;color:#171717!important;border-color:#f7d77f!important;box-shadow:0 9px 20px #0000003b!important;transform:translateY(-2px)}
@media(prefers-reduced-motion:reduce){body.home-page::before,body.home-page::after{animation:none!important}}
@media(max-width:700px){body.home-page::before{background-size:cover,calc(100vw - 36px) auto}}
header{background:#fff;border-bottom:2px solid #171717;text-align:center;justify-content:center}
header>div:first-child{display:grid;justify-items:center}
.eyebrow{order:4;margin-top:7px;font-family:"Kh Content",sans-serif;font-weight:700}
header h1{font-family:"AKbalthom Angkor 2","Khmer UI",sans-serif;font-size:35px;font-weight:400;line-height:1.45}
header h1,.form-card h2,.table-card h2{color:#171717}.form-card h2{font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:16px;text-align:center}
header p:last-child,.eyebrow{color:#595959}
.header-mark{display:none}
.form-card,.identity,.table-card{background:#fff;border:1px solid #171717;box-shadow:none;border-radius:0}
.form-card>p,.element-key,.element-key i{color:#4d4d4d}
label{color:#252525}input{border-color:#3a3a3a;border-radius:2px;background:#fff;color:#171717}
button{border-radius:2px;background:#171717;color:#fff}button:disabled{opacity:.65;cursor:wait}
.wheels{gap:14px}.wheels article{background:#fff;border:1px solid #17120f;border-radius:0;padding:10px 4px 4px}
.wheels h2{color:#171717;font-family:"Kh Content","Khmer UI","Noto Sans Khmer",sans-serif}
.wheels canvas{width:518px;height:619px;max-width:100%;object-fit:contain}
.table-card{padding:14px}.element-key{justify-content:center;border-top:1px solid #ddd;border-bottom:1px solid #ddd;padding:8px 0;text-align:center;font-size:15.6px;line-height:1.8}.element-key i{min-width:0;text-align:center}.element-key .fire{color:#a80000}.element-key .water{color:#173f7a}.element-key .earth{color:#617a18}.element-key .air{color:#686868}
.sun-times{display:grid;grid-template-columns:repeat(3,1fr);border:1px solid #171717;background:#fff7d6}.sun-times span{padding:8px;text-align:center;border-right:1px solid #171717;font-family:"Kh Content",sans-serif}.sun-times span:last-child{border-right:0}.sun-times b{color:#005fc7;font-size:16px}
.comparison-tables{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.comparison-table{border:1px solid #171717;overflow:auto}.comparison-table h3{margin:0;padding:8px;text-align:center;background:#fff200;color:#171717;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:13px}.comparison-table table{min-width:0;font-size:12px}.comparison-table td,.comparison-table th{padding:6px 4px;white-space:nowrap}.comparison-table th{background:#f7df9f}
.table-card>h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:16px}
.page-link{justify-self:start;display:inline-block;border:1px solid #171717;background:#fff200;color:#171717;padding:7px 12px;text-decoration:none;font-family:"Kh Content",sans-serif}.reference-page{display:block;max-width:900px}.reference-card{margin:auto;padding:22px;background:#fff;border:1px solid #171717;text-align:center}.reference-card h2{margin-bottom:16px;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:17px}.reference-card h2+h2{margin-top:14px}.reference-card img{display:block;width:min(100%,650px);height:auto;margin:0 auto 16px;border:1px solid #171717}.reference-card .page-link{display:inline-block}
.page-links{display:flex;flex-wrap:wrap;gap:8px}.ephemeris-page{display:block;max-width:1600px}.ephemeris-card{padding:22px;background:#fff;border:1px solid #171717}.ephemeris-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px}.ephemeris-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#555}.ephemeris-form{display:grid;grid-template-columns:repeat(5,minmax(90px,1fr)) auto;gap:10px;align-items:end;margin-bottom:16px}.ephemeris-form label{font-family:"Kh Content",sans-serif}.ephemeris-form select{min-width:0;width:100%;border:1px solid #3a3a3a;border-radius:2px;background:#fff;color:#171717;padding:9px 10px;font:500 14px "Kh Content","Khmer UI",sans-serif}.ephemeris-form button{margin:0;white-space:nowrap}.ephemeris-result-tools{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 8px}.ephemeris-result-tools button{margin:0;white-space:nowrap}.ephemeris-note{margin:0;font-family:"Kh Content",sans-serif}.ephemeris-table-wrap{overflow:auto;border:1px solid #171717}.ephemeris-table-wrap table{min-width:1150px;font-family:"Kh Content",sans-serif;font-size:12px}.ephemeris-table-wrap th{background:#fff200}.ephemeris-table-wrap td{padding:6px 5px}.ephemeris-table-wrap td b{color:#d82121}.ephemeris-table-wrap small{color:#555}@media(max-width:700px){.ephemeris-form{grid-template-columns:1fr 1fr}.ephemeris-form button{grid-column:1/-1}.ephemeris-result-tools{align-items:stretch;flex-direction:column}}
.moon-form{display:grid;grid-template-columns:repeat(5,minmax(70px,1fr)) auto;gap:8px;align-items:end;margin:0 auto 14px;text-align:left}.moon-form label{font-family:"Kh Content",sans-serif}.moon-form button{margin:0;white-space:nowrap}.moon-results{margin:0 auto 22px;text-align:left}.moon-summary{display:grid;grid-template-columns:repeat(3,1fr);border:1px solid #171717}.moon-summary>div{min-height:100px;padding:10px;border-right:1px solid #171717}.moon-summary>div:last-child{border-right:0}.moon-summary b,.moon-summary strong,.moon-summary span{display:block}.moon-summary b{color:#555;font-family:"Kh Content",sans-serif}.moon-summary strong{margin:4px 0;color:#d82121;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:14px}.moon-summary span{font-family:"Kh Content",sans-serif}.eclipse-panel{margin-top:12px;border:1px solid #171717;padding:12px}.eclipse-panel h3{margin:0 0 6px;text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:14px}.eclipse-panel p{margin-bottom:8px;font-family:"Kh Content",sans-serif}.eclipse-panel table{min-width:0;font-size:12px}.eclipse-panel th,.eclipse-panel td{padding:6px}.selected-eclipse{background:#fff200!important}.eclipse-panel small{display:block;margin-top:8px;color:#555;font-family:"Kh Content",sans-serif}@media(max-width:700px){.moon-form{grid-template-columns:repeat(2,1fr)}.moon-form button{grid-column:1/-1}.moon-summary{grid-template-columns:1fr}.moon-summary>div{border-right:0;border-bottom:1px solid #171717}.moon-summary>div:last-child{border-bottom:0}}
@media(max-width:1100px){.comparison-tables{grid-template-columns:1fr}}
@media(max-width:700px){.sun-times{grid-template-columns:1fr}.sun-times span{border-right:0;border-bottom:1px solid #171717}.sun-times span:last-child{border-bottom:0}}
.transit-page{display:block;max-width:1100px}.transit-card{padding:22px;background:#fff;border:1px solid #171717}.transit-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px}.transit-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#555}.transit-form{display:grid;grid-template-columns:1fr 1fr;gap:12px}.transit-form fieldset{min-width:0;border:1px solid #171717;padding:12px}.transit-form legend{padding:0 6px;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:14px}.transit-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}.transit-form label{font-family:"Kh Content",sans-serif}.transit-location{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr auto;gap:10px;align-items:end}.transit-location button{margin:0;white-space:nowrap}.transit-results{margin:18px 0}.transit-summary{display:flex;justify-content:space-between;gap:12px;padding:9px;border:1px solid #171717;border-bottom:0;font-family:"Kh Content",sans-serif}.transit-summary b{font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;color:#d82121}.transit-table-wrap{overflow:auto;border:1px solid #171717}.transit-table-wrap table{min-width:680px;font-family:"Kh Content",sans-serif}.transit-table-wrap th{background:#fff200}.transit-table-wrap td,.transit-table-wrap th{padding:7px}.aspect-card{margin-top:18px;border:1px solid #171717;padding:12px}.aspect-card h3{margin:0;text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:15px}.aspect-card p{margin:4px 0 8px;text-align:center;font-family:"Kh Content",sans-serif;color:#555}.aspect-card .transit-table-wrap table{min-width:1060px}@media(max-width:700px){.transit-form{grid-template-columns:1fr}.transit-grid{grid-template-columns:repeat(2,1fr)}.transit-location{grid-template-columns:1fr}.transit-summary{flex-direction:column}}
.mundane-page{display:block;max-width:1280px}.mundane-card{padding:22px;background:#fff;border:1px solid #171717}.mundane-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px}.mundane-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#555}.mundane-form{display:grid;grid-template-columns:repeat(5,minmax(90px,1fr)) auto;gap:10px;align-items:end}.mundane-form label{font-family:"Kh Content",sans-serif}.mundane-form button{margin:0;white-space:nowrap}.mundane-disclaimer{padding:9px;border-left:4px solid #d82121;background:#fff7d6!important;text-align:left!important;color:#4b3a18!important}.mundane-results{margin:16px 0}.mundane-date{padding:8px;text-align:center;background:#fff200;border:1px solid #171717;font-family:"Kh Content",sans-serif}.mundane-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}.mundane-topic{border:1px solid #171717}.mundane-topic h3{min-height:44px;margin:0;padding:9px;text-align:center;background:#c6e0b4;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:13px}.mundane-topic table{min-width:0;font-family:"Kh Content",sans-serif}.mundane-topic th{width:110px;background:#fff7d6;text-align:left}.mundane-topic td,.mundane-topic th{padding:8px;vertical-align:top}.mundane-reading{text-align:left!important;line-height:1.55}.aspect-card th:last-child{text-align:center!important}.retrograde{color:#d82121;font-weight:700;white-space:nowrap}.direct{color:#16723d;white-space:nowrap}@media(max-width:800px){.mundane-form{grid-template-columns:1fr 1fr}.mundane-form button{grid-column:1/-1}.mundane-grid{grid-template-columns:1fr}}
.ancient-page{display:block;max-width:1280px}.ancient-card{padding:22px;background:#fff;border:1px solid #171717}.ancient-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px}.ancient-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#555}.ancient-form{display:grid;grid-template-columns:repeat(5,minmax(90px,1fr)) auto;gap:10px;align-items:end}.ancient-form label{font-family:"Kh Content",sans-serif}.ancient-form button{margin:0;white-space:nowrap}.ancient-results{margin:16px 0}.ancient-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}@media(max-width:800px){.ancient-form{grid-template-columns:1fr 1fr}.ancient-form button{grid-column:1/-1}.ancient-grid{grid-template-columns:1fr}}
.ancient-page{display:block;max-width:1280px}.ancient-card{padding:22px;background:#fff;border:1px solid #171717}.ancient-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px}.ancient-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#555}.ancient-form{display:grid;grid-template-columns:repeat(5,minmax(90px,1fr)) auto;gap:10px;align-items:end}.ancient-form label{font-family:"Kh Content",sans-serif}.ancient-form button{margin:0;white-space:nowrap}.ancient-results{margin:16px 0}.ancient-date-info{display:grid;grid-template-columns:145px 240px 215px 1fr;border:1px solid #171717;font-family:"Kh Content",sans-serif}.atta-table-card{border:1px solid #171717;overflow:auto}.atta-table-card h3{margin:0;padding:9px;text-align:center;background:#fff200;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:14px}.atta-table-card p{margin:0;padding:7px;text-align:center;font-family:"Kh Content",sans-serif;color:#555}.atta-source-table{width:100%;min-width:530px;font-family:"Kh Content",sans-serif}.atta-source-table td{padding:6px 4px;text-align:center}.atta-label-row td{background:#c7bea0;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:12px}.atta-value-row td{color:#d82121;font-size:15px}.ancient-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}@media(max-width:800px){.ancient-form{grid-template-columns:1fr 1fr}.ancient-form button{grid-column:1/-1}.ancient-date-info{grid-template-columns:110px 1fr}.atta-tables,.ancient-grid{grid-template-columns:1fr}}
.atta-table-card .atta-note{background:#fff7d6;color:#6b4a00;text-align:left}
.atta-cycle-value-row td{color:#171717}.atta-age-label{background:#fff!important;color:#17667d!important}.atta-age-circle{display:inline-flex;min-width:34px;height:34px;padding:0 6px;align-items:center;justify-content:center;border:3px solid #7020a0;border-radius:50%;background:transparent;color:inherit;font-size:18px;line-height:1;box-shadow:0 0 0 2px #f0b429}.atta-table-card .atta-cycle-note{background:#e4ecdf;color:#171717;text-align:center}
.atta-lower-age-planet .atta-age-circle{background:transparent;color:inherit;border-color:#7020a0;box-shadow:0 0 0 2px #f0b429,0 0 8px #7020a066}
.maha-daksa-card{margin-top:14px;border:1px solid #171717;background:#fff;overflow:hidden}.maha-daksa-card h3{margin:0;padding:13px;text-align:center;background:linear-gradient(90deg,#0b6478 0%,#35a8b8 50%,#0b6478 100%);border-bottom:3px solid #e8bd57;color:#fff;font-family:"Kh Content","Khmer UI",sans-serif;font-size:21px;font-weight:400;line-height:1.5;text-shadow:0 1px 1px #073945}.maha-daksa-figure{display:flex;justify-content:center;align-items:center;padding:20px;background:#fff}.maha-daksa-wheel{position:relative;width:min(100%,476px);aspect-ratio:1;background:#fff}.maha-daksa-wheel-base{position:absolute;inset:2.4%;overflow:hidden;border:1px solid #777;border-radius:50%;background:#fff;pointer-events:none}.maha-daksa-inner-ring{position:absolute;inset:10.3%;z-index:2;border:1px solid #888;border-radius:50%}.maha-daksa-grid-line{position:absolute;z-index:1;background:#888}.maha-daksa-grid-line.vertical-one,.maha-daksa-grid-line.vertical-two{top:0;bottom:0;width:1px}.maha-daksa-grid-line.vertical-one{left:35.7%}.maha-daksa-grid-line.vertical-two{left:64.3%}.maha-daksa-grid-line.horizontal-one,.maha-daksa-grid-line.horizontal-two{left:0;right:0;height:1px}.maha-daksa-grid-line.horizontal-one{top:35.7%}.maha-daksa-grid-line.horizontal-two{top:64.3%}.maha-daksa-ring-label,.maha-daksa-base-number{position:absolute;z-index:3;transform:translate(-50%,-50%);color:#111;text-align:center;white-space:nowrap}.maha-daksa-ring-label{font:400 clamp(12px,2.2vw,25px)/1.15 "AKbalthom Moul","Khmer UI",sans-serif}.maha-daksa-ring-label.ring-slot-1{left:23%;top:17%;transform:translate(-50%,-50%) rotate(-42deg)}.maha-daksa-ring-label.ring-slot-2{left:50%;top:6.5%}.maha-daksa-ring-label.ring-slot-3{left:77%;top:17%;transform:translate(-50%,-50%) rotate(42deg)}.maha-daksa-ring-label.ring-slot-4{left:93%;top:50%;transform:translate(-50%,-50%) rotate(90deg)}.maha-daksa-ring-label.ring-slot-7{left:77%;top:83%;transform:translate(-50%,-50%) rotate(-42deg)}.maha-daksa-ring-label.ring-slot-5{left:50%;top:93.5%}.maha-daksa-ring-label.ring-slot-8{left:23%;top:83%;transform:translate(-50%,-50%) rotate(42deg)}.maha-daksa-ring-label.ring-slot-6{left:7%;top:50%;transform:translate(-50%,-50%) rotate(-90deg)}.maha-daksa-base-number{font:400 clamp(25px,4.2vw,44px)/1 "AKbalthom Moul","Khmer UI",sans-serif}.maha-daksa-base-number.planet-1{left:31.5%;top:30.5%}.maha-daksa-base-number.planet-2{left:49%;top:31%}.maha-daksa-base-number.planet-3{left:69.5%;top:31%}.maha-daksa-base-number.planet-4{left:69.5%;top:50%}.maha-daksa-base-number.planet-5{left:49%;top:69.5%}.maha-daksa-base-number.planet-6{left:31.5%;top:50%}.maha-daksa-base-number.planet-7{left:69.5%;top:69.5%}.maha-daksa-base-number.planet-8{left:31.5%;top:69.5%}.maha-daksa-base-number.planet-9{left:50%;top:50%}.maha-daksa-wheel[data-active-planet="1"] .maha-daksa-base-number.planet-1,.maha-daksa-wheel[data-active-planet="2"] .maha-daksa-base-number.planet-2,.maha-daksa-wheel[data-active-planet="3"] .maha-daksa-base-number.planet-3,.maha-daksa-wheel[data-active-planet="4"] .maha-daksa-base-number.planet-4,.maha-daksa-wheel[data-active-planet="5"] .maha-daksa-base-number.planet-5,.maha-daksa-wheel[data-active-planet="6"] .maha-daksa-base-number.planet-6,.maha-daksa-wheel[data-active-planet="7"] .maha-daksa-base-number.planet-7,.maha-daksa-wheel[data-active-planet="8"] .maha-daksa-base-number.planet-8,.maha-daksa-wheel[data-active-planet="9"] .maha-daksa-base-number.planet-9{color:#d7191c}.maha-daksa-wheel-labels{position:absolute;inset:0;z-index:4;pointer-events:none}.maha-daksa-wheel-label{position:absolute;left:var(--wheel-x);top:var(--wheel-y);transform:translate(-50%,-50%);display:flex;justify-content:center;padding:0;background:transparent;color:#a21313;font-family:"Kh Content","Khmer UI",sans-serif;font-size:14px;font-weight:400;line-height:1.35;text-align:center;white-space:nowrap;box-shadow:none}
.maha-daksa-pair{display:grid;grid-template-columns:repeat(2,minmax(0,520px));justify-content:center;gap:12px}.maha-daksa-pair .maha-daksa-card{width:100%}@media(max-width:850px){.maha-daksa-pair{grid-template-columns:minmax(0,520px)}}
.maha-bhuta-wheel-label{color:#176879;font-size:12px}
.maha-daksa-card{--daksa-text-size:clamp(13px,1.55vw,16px);--daksa-number-size:clamp(28px,3.5vw,36px)}
.maha-daksa-card h3,.maha-daksa-ring-label,.maha-daksa-wheel-label,.maha-bhuta-wheel-label{font-family:"Kh Content","Khmer UI",sans-serif;font-size:var(--daksa-text-size);font-style:normal;font-weight:400;font-synthesis:none;line-height:1.35}
.maha-daksa-base-number{font-family:"AKbalthom Moul","Khmer UI",sans-serif;font-size:var(--daksa-number-size);font-style:normal;font-weight:400;font-synthesis:none;line-height:1}
.maha-daksa-wheel-base .maha-daksa-ring-label{inset:0;left:0;top:0;width:100%;height:100%;transform:none}
.maha-daksa-ring-character{position:absolute;left:var(--ring-x);top:var(--ring-y);transform:translate(-50%,-50%) rotate(var(--ring-rotate));transform-origin:center;color:#111;font:inherit;line-height:1;white-space:pre}
.atta-strength-label-row td{background:#fff!important;color:#17667d!important}.atta-strength-value-row td{background:#fff!important;color:#17667d!important}
.ancient-form{grid-template-columns:repeat(6,minmax(80px,1fr)) auto}.ancient-form select{min-width:0;border:1px solid #3a3a3a;border-radius:2px;background:#fff;color:#171717;padding:9px 10px;font:500 14px "Kh Content","Khmer UI",sans-serif}@media(max-width:800px){.ancient-form{grid-template-columns:1fr 1fr}.ancient-form button{grid-column:1/-1}}
.atta-table-card>h3{padding:13px;background:linear-gradient(90deg,#0b6478 0%,#35a8b8 50%,#0b6478 100%);border-bottom:3px solid #e8bd57;color:#fff;font-size:21px;font-weight:400;line-height:1.5;text-shadow:0 1px 1px #073945;box-shadow:inset 0 1px 0 #ffffff55}
.taksa-prediction-section{margin-top:16px;border:1px solid #174e5a;background:#f7fbfa;font-family:"Kh Content","Khmer UI",sans-serif;color:#182326;overflow:hidden}.taksa-prediction-section>h3{margin:0;padding:14px 18px;background:linear-gradient(90deg,#0b6478 0%,#35a8b8 50%,#0b6478 100%);border-bottom:3px solid #e8bd57;color:#fff;font-size:21px;font-weight:400;line-height:1.55;text-align:center;text-shadow:0 1px 1px #073945}.taksa-prediction-intro{margin:0;padding:14px 18px;background:#e7f2ef;border-bottom:1px solid #b9d6d0;text-align:center;font-size:16px;line-height:1.8}.taksa-reading-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:16px}.taksa-reading-card{position:relative;border:1px solid #b8cbc7;border-left:5px solid #447a84;border-radius:5px;background:#fff;box-shadow:0 2px 8px #12333b12;overflow:hidden}.taksa-reading-card.tone-positive{border-left-color:#13804b}.taksa-reading-card.tone-steady{border-left-color:#25729b}.taksa-reading-card.tone-warning{border-left-color:#d18a00}.taksa-reading-card.tone-danger{border-left-color:#b83232}.taksa-reading-card.is-current{box-shadow:0 0 0 3px #d7191c,0 5px 16px #7320202b}.taksa-reading-card.is-current:after{content:"អាយុចរបច្ចុប្បន្ន";position:absolute;right:9px;top:48px;padding:3px 8px;border-radius:999px;background:#d7191c;color:#fff;font-size:11px}.taksa-reading-card header{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:10px 12px;background:#edf5f3;border-bottom:1px solid #c9ddd8}.taksa-reading-role{color:#913026;font-size:18px}.taksa-reading-planet{color:#176879;font-size:14px;text-align:right}.taksa-reading-maha{padding:9px 12px;background:#fff7d6;color:#4d430e}.taksa-reading-maha strong{color:#9a3c23;font-weight:400}.taksa-reading-card h4{margin:10px 12px 4px;color:#174e5a;font-size:18px;font-weight:400}.taksa-reading-card p{margin:6px 12px 11px;font-size:15px;line-height:1.9}.taksa-reading-guidance{padding-top:8px;border-top:1px dashed #c6d6d2;color:#435359}.taksa-reading-guidance b{color:#176879;font-weight:400}.transit-taksa-prediction{position:relative}.transit-reading-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));border-bottom:1px solid #c9dcd8;background:#edf5f3}.transit-reading-summary>div{display:flex;min-height:82px;padding:10px 12px;flex-direction:column;align-items:center;justify-content:center;border-right:1px solid #c9dcd8;text-align:center}.transit-reading-summary>div:last-child{border-right:0}.transit-reading-summary span{color:#4c6469;font-size:13px}.transit-reading-summary strong{margin-top:3px;color:#174e5a;font-size:19px;font-weight:400}.transit-reading-summary em{color:#4c6469;font-size:12px;font-style:normal}.transit-reading-summary .active-transit-number{display:inline-flex;width:36px;height:36px;align-items:center;justify-content:center;border:3px solid #d7191c;border-radius:50%;color:#d7191c;font-size:22px}.transit-quality{width:max-content;margin:14px auto 0;padding:5px 16px;border-radius:999px;background:#e5edf0;color:#174e5a;font-size:15px}.transit-quality.positive{background:#d9f1e3;color:#11643b}.transit-quality.warning{background:#fff0c2;color:#8b5d00}.transit-quality.danger{background:#f8dddd;color:#9a2424}.transit-main-reading{margin:12px 18px;padding:13px 15px;border:1px solid #d1dedb;border-radius:5px;background:#fff;font-size:17px;line-height:1.95}.transit-natal-filter{margin:12px 18px;padding:12px 14px;border-left:5px solid #c29222;background:#fff7d8;font-size:15px;line-height:1.85}.transit-natal-filter b{color:#8a5520;font-weight:400}.transit-reading-details{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:2px 18px 16px}.transit-reading-details article{border:1px solid #c8d8d5;border-radius:5px;background:#fff;padding:12px 14px}.transit-reading-details h4{margin:0 0 6px;color:#176879;font-size:17px;font-weight:400}.transit-reading-details p{margin:0;font-size:15px;line-height:1.85}.taksa-source-note{margin:0;padding:11px 16px;background:#e7f2ef;border-top:1px solid #bfd5d0;color:#4c6469;font-size:13px;line-height:1.7;text-align:center}@media(max-width:760px){.taksa-reading-grid,.transit-reading-details{grid-template-columns:1fr}.transit-reading-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.transit-reading-summary>div:nth-child(2){border-right:0}.transit-reading-summary>div:nth-child(-n+2){border-bottom:1px solid #c9dcd8}.taksa-reading-card.is-current:after{position:static;display:block;width:max-content;margin:8px 12px 0}}@media print{.taksa-reading-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;padding:9px}.taksa-reading-card{break-inside:avoid}.taksa-reading-card p,.transit-reading-details p{font-size:11px;line-height:1.55}.taksa-prediction-section>h3{font-size:15px;padding:8px}.taksa-prediction-intro,.transit-main-reading,.transit-natal-filter{font-size:11px;line-height:1.55}.transit-reading-summary>div{min-height:54px;padding:5px}.transit-reading-details{gap:7px;padding:2px 9px 9px}.transit-reading-details article{padding:7px}}
.ancient-form input,.ancient-form select,.ancient-form button{height:42px}.ancient-form button{display:flex;align-items:center;justify-content:center;padding-top:0;padding-bottom:0}
.ancient-overview-table{display:grid;grid-template-columns:minmax(72px,.65fr) minmax(110px,1fr) minmax(105px,.9fr) minmax(210px,1.5fr) minmax(115px,.95fr) minmax(190px,1.3fr);border:1px solid #171717;overflow-x:auto;font-family:"Kh Content",sans-serif}
.ancient-overview-table>*{min-width:0;padding:8px;border-right:1px solid #aaa;border-bottom:1px solid #aaa;display:flex;align-items:center;overflow-wrap:anywhere}
.ancient-overview-table .overview-title{grid-column:span 2;justify-content:center;text-align:center;background:#c6d4be;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:13px}
.ancient-overview-table .overview-title-wide{grid-column:1 / -1}
.ancient-overview-table .overview-label{background:#e4ecdf;font-weight:400}
.ancient-overview-table .overview-value{background:#f7f7f2;color:#d82121;font-weight:400}
.ancient-overview-table .overview-age{font-size:15px}
.ancient-overview-table .overview-cell-end{border-right:0}
.ancient-overview-table>*:nth-last-child(-n+6){border-bottom:0}.natal-prediction-panel{overflow:hidden;border:1px solid #174e5a;background:#f7fbfa;color:#182326;font-family:"Kh Content","Khmer UI",sans-serif;text-align:left;box-shadow:0 3px 12px #12333b18}.natal-prediction-panel>header{padding:13px 15px;background:linear-gradient(90deg,#0b6478 0%,#35a8b8 50%,#0b6478 100%);border-bottom:3px solid #e8bd57;color:#fff;text-align:center}.natal-prediction-panel>header span{display:block;font-size:11px;opacity:.92}.natal-prediction-panel>header h2{margin:3px 0 0;color:#fff;font-size:20px;font-weight:400;line-height:1.55}@media print{.natal-prediction-panel{box-shadow:none}.natal-prediction-panel>header{padding:6px;border-bottom-width:1px}.natal-prediction-panel>header span{display:none}.natal-prediction-panel>header h2{font-size:13px}}
.atta-prediction-page{display:block;max-width:1280px}.atta-prediction-card{padding:22px;border:1px solid #171717;background:#fff;color:#171717;font-family:"Kh Content","Khmer UI",sans-serif}.atta-prediction-card>h2{margin:0;text-align:center;color:#174e5a;font-size:22px;font-weight:400}.atta-prediction-card>p{margin:5px 0 18px;text-align:center;color:#536669}.atta-prediction-results{display:grid;gap:14px;margin:18px 0}.atta-reading-grid h4,.atta-related-section h3,.atta-strength-section h3,.atta-source-preview h3{margin:0 0 6px;color:#176879;font-size:18px;font-weight:400}.atta-related-section,.atta-strength-section,.atta-source-preview{padding:15px;border:1px solid #b8cbc7;background:#f7fbfa}.atta-related-section>p,.atta-strength-section>p{margin:0 0 11px;color:#536669;line-height:1.7}.atta-related-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.atta-related-card{padding:10px 12px;border:1px solid #c7d4d1;border-left:5px solid #447a84;background:#fff}.atta-related-card.tone-positive{border-left-color:#13804b}.atta-related-card.tone-warning{border-left-color:#d18a00}.atta-related-card.tone-danger{border-left-color:#b83232}.atta-related-card span{color:#6b7a7d;font-size:11px}.atta-related-card h4{margin:2px 0;color:#913026;font-size:17px;font-weight:400}.atta-related-card p{margin:0;font-size:13px;line-height:1.7}.atta-source-preview .atta-source-table{min-width:760px}.atta-prediction-error{padding:15px;border:1px solid #b83232;background:#f8dddd;color:#8d2525;text-align:center}@media(max-width:820px){.atta-reading-grid,.atta-related-grid{grid-template-columns:1fr}}@media print{.atta-prediction-card{padding:0;border:0}.atta-prediction-card form,.atta-prediction-card>p,.atta-prediction-links,.atta-source-preview{display:none!important}.atta-prediction-results{gap:7px}.atta-reading-grid p,.atta-related-card p{font-size:10px;line-height:1.45}.atta-related-section,.atta-strength-section{padding:7px}.atta-related-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:4px}.atta-related-card{padding:5px}}
.ancient-mode-nav{display:flex;justify-content:center;flex-wrap:wrap;gap:10px;margin:16px 0 2px}.ancient-mode-nav .page-link{margin:0}.ancient-mode-nav .page-link[aria-current="page"]{background:#4d2f75;color:#fff;border-color:#4d2f75}

/* Keep the page surface open while retaining table and form dividers. */
.form-card,.identity,.table-card,.reference-card,.ephemeris-card,.transit-card,.mundane-card,.ancient-card,.atta-prediction-card{border:0}.page-link[href="index.html"],.ancient-mode-nav,.dashboard-header>a[href="index.html"]{display:none}
.wheels h2{position:relative;z-index:1;transform:translateY(50%);margin:0 0 2px;line-height:1.5}
/* Equal planet columns on screen + print (date/lunar/Sid.t stay a bit wider). */
.ephemeris-table-wrap table{table-layout:fixed;width:100%}
.ephemeris-table-wrap col.ephemeris-col-date{width:7%}
.ephemeris-table-wrap col.ephemeris-col-lunar{width:8.5%}
.ephemeris-table-wrap col.ephemeris-col-sidt{width:4.5%}
.ephemeris-table-wrap col.ephemeris-col-planet{width:5.714%}
.ephemeris-table-wrap .ephemeris-planet-col{width:5.714%;overflow-wrap:anywhere;word-break:break-word}
.ephemeris-table-wrap .planet-name{display:inline-block;max-width:100%}
.ephemeris-print-credit{display:none}

@media print{
  @page{size:landscape;margin:8mm}
  body{background:#fff!important;color:#000!important;padding-bottom:0!important}
  header,.ephemeris-form,.page-link,.ephemeris-result-tools button,
  .global-home-button,.app-auth-bar,.ephemeris-tool-navigation,.tool-navigation-backdrop,
  .mobile-bottom-nav,.mobile-app-install{
    display:none!important
  }
  /* PDF only: hide lunar (ចន្ទគតិ); screen keeps the column. */
  .ephemeris-table-wrap col.ephemeris-col-lunar,
  .ephemeris-table-wrap .ephemeris-lunar-col{
    display:none!important
  }
  .ephemeris-page,.ephemeris-card{max-width:none!important;margin:0!important;padding:0!important;border:0!important;box-shadow:none!important}
  .ephemeris-card>p{display:none}
  .ephemeris-table-wrap{overflow:visible!important;border:1px solid #171717;margin:0!important}
  .ephemeris-table-wrap table{
    width:100%!important;min-width:0!important;table-layout:fixed!important;
    font-size:6.4px!important;line-height:1.25!important
  }
  .ephemeris-table-wrap th,.ephemeris-table-wrap td{
    padding:1px 0!important;vertical-align:top;overflow:hidden
  }
  /* Redistribute widths after lunar is removed (date + Sid.t + 14 equal planets). */
  .ephemeris-table-wrap col.ephemeris-col-date,
  .ephemeris-table-wrap .ephemeris-date-col{width:7.5%!important}
  .ephemeris-table-wrap col.ephemeris-col-sidt,
  .ephemeris-table-wrap .ephemeris-sidt-col{width:5%!important}
  .ephemeris-table-wrap col.ephemeris-col-planet,
  .ephemeris-table-wrap .ephemeris-planet-col{width:6.25%!important}
  .ephemeris-table-wrap .planet-glyph{font-size:.95em;line-height:1}
  .ephemeris-table-wrap .planet-name{font-size:.92em}
  .ephemeris-table-wrap th,.ephemeris-table-wrap td b,
  .ephemeris-table-wrap td span{font-size:inherit}
  .ephemeris-result-tools{display:block!important}
  .ephemeris-note{display:block!important;margin:0 0 4px!important;font-size:9px!important}
  .ephemeris-card h2{font-size:13px!important;margin:0 0 4px!important}
  /* Single in-flow credit AFTER the table — never fixed, never tfoot (Chrome overlays those). */
  .ephemeris-print-credit{
    display:block!important;position:static!important;float:none!important;
    width:100%!important;max-width:none!important;margin:10px 0 0!important;padding:6px 4px 0!important;
    border:0!important;border-top:1px solid #151515!important;background:transparent!important;
    color:#151515!important;text-align:center!important;
    font:400 8px/1.3 "Kh Content","Khmer UI",sans-serif!important;white-space:nowrap!important;
    page-break-inside:avoid;break-inside:avoid
  }
}
.atta-matter-picker-section{border:1px solid #5b3d79;background:#faf8fc;overflow:hidden}.atta-matter-picker-section>header{display:block;padding:14px 18px;border-bottom:3px solid #e8bd57;background:linear-gradient(90deg,#4d2f75,#8b5eae,#4d2f75);color:#fff;text-align:center}.atta-matter-picker-section>header h3{margin:0;color:#fff;font-size:22px;font-weight:400;text-align:center}.atta-matter-picker-section>header p{max-width:900px;margin:5px auto 0;font-size:14px;line-height:1.75;text-align:center}.atta-matter-picker-label{display:flex;align-items:center;justify-content:center;padding:14px 18px;background:#f0e9f6;border-bottom:1px solid #d2c2df}.atta-matter-picker-label select{width:min(100%,850px);height:46px;border:1px solid #694788;border-radius:4px;background:#fff;color:#231d28;padding:7px 11px;font:400 16px "Kh Content","Khmer UI",sans-serif}.atta-matter-reading{margin:14px;border:1px solid #b8cbc7;border-left:7px solid #447a84;background:#fff;box-shadow:0 3px 11px #2d194015;overflow:hidden}.atta-matter-reading.tone-positive{border-left-color:#13804b}.atta-matter-reading.tone-warning{border-left-color:#d18a00}.atta-matter-reading.tone-danger{border-left-color:#b83232}.atta-matter-reading>header{padding:11px 14px;background:#edf5f3;border-bottom:1px solid #c6d6d2}.atta-matter-reading.tone-positive>header{background:#e4f3e9}.atta-matter-reading.tone-warning>header{background:#fff3cf}.atta-matter-reading.tone-danger>header{background:#f8e1e1}.atta-matter-reading>header span{display:block;color:#5b6970;font-size:12px}.atta-matter-reading>header h4{margin:2px 0 0;color:#4d2f75;font-size:22px;font-weight:400}.atta-matter-reading-body{padding:13px 15px}.atta-matter-reading-body>p{margin:8px 0;font-size:15px;line-height:1.85}.atta-matter-status{padding:10px 12px;border-left:5px solid #c29222;background:#fff7d8}.atta-matter-evidence{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:11px 0}.atta-matter-evidence section{padding:11px 12px;border:1px solid #c9d7d4;background:#f8fbfa}.atta-matter-evidence h5{margin:0 0 7px;color:#176879;font-size:16px;font-weight:400}.atta-matter-evidence ul{display:grid;gap:6px;margin:0;padding:0;list-style:none}.atta-matter-evidence li{display:grid;grid-template-columns:minmax(90px,.4fr) minmax(0,1.6fr);gap:8px;padding-bottom:5px;border-bottom:1px dashed #d2ddda;font-size:13px;line-height:1.65}.atta-matter-evidence li:last-child{padding-bottom:0;border-bottom:0}.atta-matter-evidence li b{color:#913026;font-weight:400}.atta-matter-evidence section>p{margin:5px 0;font-size:13px;line-height:1.7}.atta-matter-advice{padding:9px 11px;background:#eaf3f1;color:#344f54}.atta-matter-caution{padding:9px 11px;border:1px solid #dda8a8;background:#fff0f0;color:#892b2b}@media(max-width:760px){.atta-matter-evidence{grid-template-columns:1fr}.atta-matter-picker-label{padding:10px}.atta-matter-reading{margin:9px}.atta-matter-evidence li{grid-template-columns:1fr}}@media print{.atta-matter-picker-label{display:none}.atta-matter-picker-section>header{padding:6px}.atta-matter-picker-section>header h3{font-size:14px}.atta-matter-picker-section>header p{display:none}.atta-matter-reading{margin:6px;box-shadow:none}.atta-matter-reading-body{padding:6px}.atta-matter-reading-body>p,.atta-matter-evidence li,.atta-matter-evidence section>p{font-size:9px;line-height:1.4}.atta-matter-evidence{gap:4px;margin:4px 0}.atta-matter-evidence section{padding:5px}.atta-matter-reading>header{padding:5px}.atta-matter-reading>header h4{font-size:13px}}
.atta-birth-info{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;box-shadow:0 7px 15px #174f5d1c}.atta-birth-summary.ancient-overview-table{border:0;border-radius:0;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}.atta-birth-summary.ancient-overview-table>*{border-color:#d4e9ee;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}.atta-birth-summary.ancient-overview-table .overview-title{background:#f2fbfd;color:#17667d;font-size:14px;font-weight:400}.atta-birth-summary.ancient-overview-table .overview-label{background:#f7fcfd;color:#17667d}.atta-birth-summary.ancient-overview-table .overview-value{background:#fff;color:#17667d;font-weight:400}.atta-birth-summary.ancient-overview-table .overview-age{color:#17667d;font-size:15px}.atta-birth-observed{margin:0;padding:11px 14px;border:0;border-top:1px solid #d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-size:15px;font-weight:400;text-align:center}@media(max-width:720px){.atta-birth-info{border-radius:14px}.atta-birth-observed{padding:9px 10px;font-size:13px;line-height:1.65}}@media print{.atta-birth-info{border-radius:0;box-shadow:none}.atta-birth-observed{padding:5px;font-size:9px}}

/* Home-style surface for the lunar mansion and eclipse calculator. */
.lunar-eclipse-page .reference-page{max-width:1080px}
.lunar-eclipse-page .reference-card{
  padding:24px;
  border:1px solid #8ebdca;
  border-radius:22px;
  background:#ffffffd9;
  color:#17667d;
  box-shadow:0 12px 28px #174f5d1f;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .reference-card h2{color:#17667d;font-size:21px}
.lunar-eclipse-page .lunar-reference-tabs{
  display:flex;
  flex-wrap:wrap;
  align-items:stretch;
  justify-content:center;
  gap:12px;
  width:100%;
  margin:0 auto 18px
}
.lunar-eclipse-page .lunar-reference-tab{
  display:inline-flex;
  flex:0 1 220px;
  min-height:48px;
  align-items:center;
  justify-content:center;
  margin:0;
  padding:8px 18px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  font:400 16px "Kh Content","Khmer UI",sans-serif;
  text-align:center;
  cursor:pointer;
  box-shadow:0 7px 15px #174f5d1c;
  transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease,color .18s ease
}
.lunar-eclipse-page .lunar-reference-tab:hover,
.lunar-eclipse-page .lunar-reference-tab:focus-visible{
  background:#f2fbfd;
  color:#d82121;
  box-shadow:0 9px 18px #174f5d29;
  transform:translateY(-1px)
}
.lunar-eclipse-page .lunar-reference-tab:focus-visible{outline:3px solid #b9dfe7;outline-offset:2px}
.lunar-eclipse-page .lunar-reference-tab.is-active{background:#e8f5f8;color:#17667d}
.lunar-eclipse-page .lunar-reference-panel[hidden]{display:none!important}
.lunar-eclipse-page .lunar-empty-state{
  margin-top:14px;
  padding:22px 16px;
  border:1px solid #d4e9ee;
  border-radius:18px;
  background:#f7fcfd;
  color:#17667d;
  text-align:center
}
.lunar-eclipse-page .moon-form{gap:10px}
.lunar-eclipse-page .moon-form[hidden]{display:none!important}
.lunar-eclipse-page .eclipse-annual-toolbar{display:flex;justify-content:center;margin:0 auto 14px}
.lunar-eclipse-page .eclipse-annual-toolbar[hidden]{display:none}
.lunar-eclipse-page .kalayog-annual-toolbar{
  width:min(100%,900px);
  margin:0 auto 14px;
  padding:22px 20px 14px;
  border:1px solid #171717;
  background:#fff;
  color:#17667d
}
.lunar-eclipse-page .kalayog-annual-toolbar[hidden]{display:none}
.lunar-eclipse-page .kalayog-annual-heading{text-align:center}
.lunar-eclipse-page .kalayog-annual-heading h2{
  margin:0;
  color:#17667d;
  font:400 20px/1.45 "Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .kalayog-annual-heading p{
  margin:4px 0 18px;
  color:#536669;
  font:400 14px/1.55 "Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .kalayog-annual-controls{
  display:flex;
  align-items:center;
  justify-content:center
}
.lunar-eclipse-page .kalayog-annual-timezone{
  margin:14px 0 0;
  color:#17667d;
  text-align:center;
  font:400 14px/1.5 "Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .moon-form label{color:#17667d;font-size:14px;font-weight:400;text-align:center}
.lunar-eclipse-page .moon-form input{
  min-height:46px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  padding:8px 15px;
  text-align:left;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 5px 12px #174f5d0d
}
.lunar-eclipse-page .moon-form input:focus{outline:3px solid #b9dfe7;outline-offset:1px}
.lunar-eclipse-page .moon-form button{
  min-height:46px;
  margin:0;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  padding:8px 18px;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 7px 15px #174f5d1c
}
.lunar-eclipse-page .moon-birth-info{
  overflow-x:auto;
  margin:14px 0;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  box-shadow:0 7px 15px #174f5d12
}
.lunar-eclipse-page .moon-birth-info:empty{display:none}
.lunar-eclipse-page .moon-birth-info table{
  width:100%;
  min-width:680px;
  border-collapse:collapse;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .moon-birth-info th{
  padding:10px 12px;
  border-right:1px solid #d4e9ee;
  border-bottom:1px solid #d4e9ee;
  background:#f2fbfd;
  color:#17667d;
  font-weight:400;
  text-align:center
}
.lunar-eclipse-page .moon-birth-info th:last-child{border-right:0}
.lunar-eclipse-page .moon-birth-info td{
  padding:9px 12px;
  border-right:1px solid #d4e9ee;
  border-bottom:1px solid #d4e9ee;
  background:#fff;
  color:#17667d;
  font-weight:400
}
.lunar-eclipse-page .moon-birth-info tr:last-child td{border-bottom:0}
.lunar-eclipse-page .moon-birth-info td:last-child{border-right:0}
.lunar-eclipse-page .moon-birth-info td:nth-child(odd){width:15%;background:#f7fcfd}
.lunar-eclipse-page .moon-birth-info td:nth-child(2){width:20%}
.lunar-eclipse-page .moon-birth-info td:nth-child(4){width:50%}
.lunar-eclipse-page .moon-summary{
  grid-template-columns:repeat(2,1fr);
  overflow:hidden;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  box-shadow:0 7px 15px #174f5d12
}
.lunar-eclipse-page .moon-summary>div{border-color:#d4e9ee;background:#f7fcfd;color:#17667d}
.lunar-eclipse-page .moon-summary>div:nth-child(even){background:#fff}
.lunar-eclipse-page .moon-summary b{color:#17667d;font-weight:400}
.lunar-eclipse-page .moon-summary strong{color:#d82121;font-size:16px}
.lunar-eclipse-page .moon-summary span{color:#171717}
.lunar-eclipse-page .moon-summary .moon-guidance{
  grid-column:1/-1;
  min-height:0;
  border-top:1px solid #d4e9ee;
  border-right:0;
  background:#f7fcfd;
  padding:14px 16px;
  text-align:left
}
.lunar-eclipse-page .moon-guidance strong{margin:0 0 6px;color:#d82121;font-size:17px;line-height:1.65}
.lunar-eclipse-page .moon-guidance span{font-size:15px;line-height:1.9}
.lunar-eclipse-page .eclipse-panel{
  overflow:hidden;
  margin-top:16px;
  padding:16px;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#ffffffeb;
  box-shadow:0 7px 15px #174f5d12
}
.lunar-eclipse-page .eclipse-panel h3{color:#17667d;font-size:18px}
.lunar-eclipse-page .eclipse-panel p{color:#17667d}
.lunar-eclipse-page .eclipse-panel .eclipse-empty-status{
  color:#d82121;
  text-align:center;
}
.lunar-eclipse-page .eclipse-panel table{
  overflow:hidden;
  border-radius:14px;
  background:#fff;
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .eclipse-panel th{
  border-color:#d4e9ee;
  background:#f2fbfd;
  color:#17667d;
  font-weight:400
}
.lunar-eclipse-page .eclipse-panel td{border-color:#d4e9ee;background:#fff;color:#171717}
.lunar-eclipse-page .eclipse-panel tr:nth-child(even) td{background:#f7fcfd}
.lunar-eclipse-page .selected-eclipse{background:#fff2bd!important;color:#17667d!important}
.lunar-eclipse-page .eclipse-panel small{color:#536669}
.lunar-eclipse-page .kalayog-panel{
  margin-top:16px;
  overflow:hidden;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  box-shadow:0 7px 15px #174f5d12
}
.lunar-eclipse-page .kalayog-table-scroll{
  width:100%;
  overflow-x:auto;
  overscroll-behavior-inline:contain;
  -webkit-overflow-scrolling:touch
}
.lunar-eclipse-page .kalayog-table{
  width:100%;
  min-width:720px;
  table-layout:fixed;
  border-collapse:collapse;
  background:#fff;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif
}
.lunar-eclipse-page .kalayog-table col{width:20%}
.lunar-eclipse-page .kalayog-table th,
.lunar-eclipse-page .kalayog-table td{
  width:20%;
  padding:8px 9px;
  border-right:1px solid #d4e9ee;
  border-bottom:1px solid #d4e9ee;
  background:#fff;
  color:#17667d;
  font-weight:400;
  text-align:center;
  vertical-align:middle
}
.lunar-eclipse-page .kalayog-table tr>:last-child{border-right:0}
.lunar-eclipse-page .kalayog-table tr:last-child>*{border-bottom:0}
.lunar-eclipse-page .kalayog-table th:first-child{text-align:left}
.lunar-eclipse-page .kalayog-table tr:nth-child(even)>*{background:#f7fcfd}
.lunar-eclipse-page .kalayog-table .kalayog-section-head>*{
  background:#e6f3e0;
  color:#17667d
}
@media(max-width:700px){
  .lunar-eclipse-page .reference-card{padding:15px;border-radius:16px}
  .lunar-eclipse-page .lunar-reference-tabs{gap:8px;margin-bottom:14px}
  .lunar-eclipse-page .lunar-reference-tab{flex:1 1 100%;width:100%;min-height:44px;padding:7px 12px}
  .lunar-eclipse-page .moon-form{grid-template-columns:repeat(3,minmax(0,1fr))}
  .lunar-eclipse-page .moon-birth-info{border-radius:14px}
  .lunar-eclipse-page .moon-summary{grid-template-columns:1fr;border-radius:14px}
  .lunar-eclipse-page .eclipse-panel{padding:10px;border-radius:14px;overflow:auto}
  .lunar-eclipse-page .kalayog-panel{border-radius:14px}
  .lunar-eclipse-page .kalayog-table{min-width:660px}
  .lunar-eclipse-page .kalayog-table th,
  .lunar-eclipse-page .kalayog-table td{padding:7px 6px}
}
.lunar-eclipse-page .reference-card,
.lunar-eclipse-page .reference-card :where(h2,h3,p,label,input,button,table,th,td,b,strong,span,small,a),
.lunar-eclipse-page .moon-results{
  font-size:16px!important
}

/* Unified Home-style page menu: equal-size controls centred in every row. */
.page-links{justify-content:center;align-items:stretch;gap:12px}
.page-links .page-link{display:inline-flex;width:176px;min-height:48px;align-items:center;justify-content:center;gap:0;border-color:#8ebdca;border-radius:999px;background:#fff;color:#17667d;padding:7px 14px;text-align:center;font-weight:400;line-height:1.35;box-shadow:0 7px 15px #174f5d1c;transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease}
.page-links .page-link::before{content:none}
.page-links .page-link:hover{background:#f2fbfd;box-shadow:0 9px 18px #174f5d29;transform:translateY(-1px)}
.page-links .page-link:focus-visible{outline:3px solid #b9dfe7;outline-offset:2px}
@media(max-width:700px){.page-links .page-link{width:calc(50% - 6px);min-height:48px;padding-inline:9px;gap:0;font-size:14px}}
/* Home navigation is intentionally a left-hand vertical menu. */
body.home-page .page-links{align-self:flex-start;display:flex;flex-direction:column;flex-wrap:nowrap;align-items:stretch;justify-content:flex-start;width:min(100%,230px);gap:10px;margin:0}
body.home-page .page-links .page-link{width:100%;margin:0}

/* Keep the prediction selector compact: label at left, selector at right. */
.atta-matter-picker-section{border:0;background:transparent;overflow:visible}.atta-matter-picker-label{display:grid;grid-template-columns:max-content minmax(0,850px);justify-content:start;gap:12px;padding:0;background:transparent;border:0;text-align:left}.atta-matter-picker-label>span{display:inline-flex;min-height:46px;align-items:center;color:#171717;font-family:"Kh Content","Khmer UI",sans-serif;font-size:17px;font-weight:400;white-space:nowrap}.atta-matter-picker-label select{width:100%;height:46px;border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;padding:7px 16px;font:400 16px "Kh Content","Khmer UI",sans-serif;box-shadow:0 7px 15px #174f5d12}.atta-matter-picker-label select:focus{outline:3px solid #b9dfe7;outline-offset:1px}@media(max-width:760px){.atta-matter-picker-label{grid-template-columns:1fr;gap:4px;padding:0}.atta-matter-picker-label>span{min-height:auto;font-size:16px}.atta-matter-picker-label select{height:44px}}
.atta-fate-reading{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;color:#17667d;box-shadow:0 7px 15px #174f5d1c;font-family:inherit}.atta-fate-reading>header{display:block!important;padding:15px 18px;border-bottom:1px solid #d4e9ee;background:#f2fbfd;text-align:center}.atta-fate-reading>header h3{margin:0;color:#17667d;font-size:21px;font-weight:400}.atta-fate-reading>header p{max-width:920px;margin:6px auto 0;color:#536669;font-size:14px;line-height:1.75}.atta-fate-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;gap:12px;padding:16px}.atta-fate-card{padding:14px 16px;border:1px solid #d4e9ee;border-left:5px solid #176879;border-radius:12px;background:#fff}.atta-fate-card:last-child:nth-child(odd){grid-column:2}.atta-fate-card.is-caution{border-left-color:#c78a14;background:#fffdf5}.atta-fate-card h4{margin:0 0 7px;color:#4d2f75;font-size:18px;font-weight:400}.atta-fate-card p{margin:7px 0 0;color:#243e45;font-size:15px;line-height:1.9}.atta-fate-card .atta-fate-evidence{margin:0;padding:8px 10px;border-radius:8px;background:#f2fbfd;color:#17667d;font-size:13px;line-height:1.7}@media(max-width:760px){.atta-fate-reading{border-radius:14px}.atta-fate-reading>header{padding:13px 12px}.atta-fate-reading>header h3{font-size:19px}.atta-fate-grid{grid-template-columns:1fr;gap:9px;padding:10px}.atta-fate-card:last-child:nth-child(odd){grid-column:auto}.atta-fate-card{padding:12px}.atta-fate-card h4{font-size:17px}.atta-fate-card p{font-size:14px;line-height:1.8}}@media print{.atta-fate-reading{box-shadow:none}.atta-fate-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;padding:7px}.atta-fate-card{padding:7px;break-inside:avoid}.atta-fate-card p,.atta-fate-card .atta-fate-evidence{font-size:9px;line-height:1.45}.atta-fate-reading>header{padding:7px}.atta-fate-reading>header h3{font-size:14px}.atta-fate-reading>header p{display:none}}
.atta-fate-note{margin:0;padding:10px 16px;border-top:1px solid #d4e9ee;background:#f8fbfc;color:#536669;font-size:12px;line-height:1.7;text-align:center}@media(max-width:760px){.atta-fate-note{padding:9px 12px;font-size:11px}}@media print{.atta-fate-note{display:none}}

/* Keep fate item 7 directly below item 6 in the desktop two-column grid. */
.atta-fate-grid>.atta-fate-card:nth-child(7){grid-column:2}
@media(max-width:760px){.atta-fate-grid>.atta-fate-card:nth-child(7){grid-column:auto}}

/* Stack each desktop column independently so cards fit without row-height gaps. */
.atta-fate-column{display:flex;min-width:0;flex-direction:column;gap:12px}
@media(max-width:760px){.atta-fate-grid{display:flex;flex-direction:column}.atta-fate-column{display:contents}.atta-fate-column>.atta-fate-card{order:var(--fate-order)}}

/* Ephemeris uses the same light, rounded Home visual language. */
.ephemeris-card h2,.ephemeris-card>p{color:#17667d}.ephemeris-form label{color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}.ephemeris-form input,.ephemeris-form select{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;box-shadow:inset 0 1px 2px #174f5d0d}.ephemeris-form input:focus,.ephemeris-form select:focus{outline:3px solid #b9dfe7;outline-offset:1px}.ephemeris-form button,.ephemeris-result-tools button{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;box-shadow:0 7px 15px #174f5d1c;transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease}.ephemeris-form button:hover,.ephemeris-result-tools button:hover{background:#f2fbfd;box-shadow:0 9px 18px #174f5d29;transform:translateY(-1px)}.ephemeris-note{color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}.ephemeris-table-wrap{border:1px solid #8ebdca;border-radius:18px;background:#fff;box-shadow:0 7px 15px #174f5d1c}.ephemeris-table-wrap table{background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}.ephemeris-table-wrap th{border-color:#d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}.ephemeris-table-wrap td{border-color:#d4e9ee;background:#fff;color:#17667d;font-weight:400}.ephemeris-table-wrap tr:nth-child(even) td{background:#fff}.ephemeris-table-wrap td b{color:#17667d;font-weight:400}.ephemeris-table-wrap small{color:#536669}

/* Transit uses the same light, rounded Home visual language. */
.transit-card>h2,.transit-card>p,.transit-form label,.transit-form legend,.transit-summary,.aspect-card h3,.aspect-card p{color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important;font-weight:400}.transit-card>p,.aspect-card p{color:#536669!important}.transit-form fieldset,.aspect-card{border:1px solid #8ebdca!important;border-radius:18px!important;background:#fff!important;box-shadow:0 7px 15px #174f5d12}.transit-form input{border:1px solid #8ebdca!important;border-radius:999px!important;background:#fff!important;color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important;font-weight:400;box-shadow:inset 0 1px 2px #174f5d0d}.transit-form input:focus{outline:3px solid #b9dfe7;outline-offset:1px}.transit-location button{border:1px solid #8ebdca!important;border-radius:999px!important;background:#fff!important;color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important;font-weight:400;box-shadow:0 7px 15px #174f5d1c;transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease}.transit-location button:hover{background:#f2fbfd!important;box-shadow:0 9px 18px #174f5d29;transform:translateY(-1px)}.transit-summary{border:1px solid #8ebdca!important;border-bottom:0!important;border-radius:18px 18px 0 0;background:#f2fbfd!important}.transit-summary b,.transit-shift{color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important;font-weight:400}.transit-table-wrap{border:1px solid #8ebdca!important;border-radius:0 0 18px 18px;background:#fff;box-shadow:0 7px 15px #174f5d1c}.aspect-card .transit-table-wrap{border-radius:18px!important}.transit-table-wrap table{background:#fff!important;color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important}.transit-table-wrap th{border-color:#d4e9ee!important;background:#f2fbfd!important;color:#17667d!important;font-family:"Kh Content","Khmer UI",sans-serif!important;font-weight:400}.transit-table-wrap td{border-color:#d4e9ee!important;background:#fff!important;color:#17667d!important;font-weight:400}.transit-table-wrap tr:nth-child(even) td{background:#fff!important}.transit-table-wrap td b,.transit-table-wrap td span,.transit-table-wrap td small{color:#17667d!important;font-weight:400}

/* Transit-age circles must stay red across every Attha row. */
.atta-table-card.atta-restored-table .atta-age-circle{border-color:#d7191c!important;color:#d7191c!important;box-shadow:0 0 0 2px #ffe0e0,0 0 8px #d7191c33!important}

/* Reassert the Home palette for every visible Ephemeris control and table cell. */
.ephemeris-page .ephemeris-card h2,.ephemeris-page .ephemeris-card>p,.ephemeris-page .ephemeris-form label,.ephemeris-page .ephemeris-note{color:#17667d!important}.ephemeris-page .ephemeris-form input,.ephemeris-page .ephemeris-form select{border-color:#8ebdca!important;border-radius:999px!important;background:#fff!important;color:#17667d!important}.ephemeris-page .ephemeris-form button,.ephemeris-page .ephemeris-result-tools button{border:1px solid #8ebdca!important;border-radius:999px!important;background:#fff!important;color:#17667d!important;box-shadow:0 7px 15px #174f5d1c!important}.ephemeris-page .ephemeris-table-wrap{border-color:#8ebdca!important;border-radius:18px!important;background:#fff!important;box-shadow:0 7px 15px #174f5d1c!important}.ephemeris-page .ephemeris-table-wrap th{border-color:#d4e9ee!important;background:#f2fbfd!important;color:#17667d!important}.ephemeris-page .ephemeris-table-wrap td,.ephemeris-page .ephemeris-table-wrap tr:nth-child(even) td{border-color:#d4e9ee!important;background:#fff!important;color:#17667d!important}.ephemeris-page .ephemeris-table-wrap td b{color:#17667d!important}.ephemeris-table-wrap .planet-glyph{display:inline-block;font-family:"Segoe UI Symbol","Noto Sans Symbols2","DejaVu Sans",sans-serif;font-size:1.15em;line-height:1.1;color:#17667d}.ephemeris-table-wrap th .planet-glyph{font-size:1.25em;margin-bottom:2px}.ephemeris-table-wrap th .planet-name{display:inline-block}.ephemeris-page .ephemeris-table-wrap .planet-glyph{color:#17667d!important}

/* Mundane astrology uses the same light, rounded Home visual language. */
.mundane-theme-page .mundane-card{
  padding:22px;
  border:0;
  background:#fff;
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.mundane-theme-page .mundane-card>h2,
.mundane-theme-page .mundane-card>p{
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-weight:400
}
.mundane-theme-page .mundane-card>p{color:#536669}
.mundane-theme-page .mundane-form label{
  color:#17667d;
  text-align:center;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-weight:400
}
.mundane-theme-page .mundane-form input{
  height:42px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  padding:9px 14px;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:inset 0 1px 2px #174f5d0d
}
.mundane-theme-page .mundane-form input:focus{
  outline:3px solid #b9dfe7;
  outline-offset:1px
}
.mundane-theme-page .mundane-form button{
  min-height:42px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 7px 15px #174f5d1c;
  transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease
}
.mundane-theme-page .mundane-form button:hover{
  background:#f2fbfd;
  box-shadow:0 9px 18px #174f5d29;
  transform:translateY(-1px)
}
/* Keep the five date/time fields and the primary action in two compact
   desktop rows while leaving the existing mobile layout untouched. */
@media(min-width:1101px){
  .mundane-theme-page .mundane-form{
    grid-template-columns:repeat(3,minmax(0,1fr));
    max-width:1040px;
    margin-inline:auto
  }
  .mundane-theme-page .mundane-form button{
    grid-column:3;
    grid-row:2;
    width:100%
  }
}

/* Excel-backed Attha planet-pair meanings. */
.atta-prediction-page .atta-planet-pairs{
  margin-top:16px;
  border:1px solid #174e5a;
  background:#fff;
  overflow:hidden
}
.atta-prediction-page .atta-planet-pairs>h3{
  margin:0;
  padding:13px 16px;
  border-bottom:3px solid #e8bd57;
  background:linear-gradient(90deg,#0b6478 0%,#35a8b8 50%,#0b6478 100%);
  color:#fff;
  font:400 21px/1.5 "Kh Content","Khmer UI",sans-serif;
  text-align:center;
  text-shadow:0 1px 1px #073945
}
.atta-prediction-page .atta-pair-intro{
  margin:0;
  padding:10px 14px;
  border-bottom:1px solid #c8dedd;
  background:#edf6f5;
  color:#415c62;
  text-align:center;
  line-height:1.7
}
.atta-prediction-page .atta-pair-table-wrap{overflow-x:auto}
.atta-prediction-page .atta-pair-table{
  width:100%;
  min-width:560px;
  border-collapse:collapse;
  background:#fff;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.atta-prediction-page .atta-pair-table th,
.atta-prediction-page .atta-pair-table td{
  padding:9px 12px;
  border-right:1px solid #c8dedd;
  border-bottom:1px solid #c8dedd;
  line-height:1.7;
  text-align:left;
  vertical-align:middle
}
.atta-prediction-page .atta-pair-table tr>*:last-child{border-right:0}
.atta-prediction-page .atta-pair-table thead th{
  background:#f4ead2;
  color:#8b2f24;
  font-weight:400;
  text-align:center
}
.atta-prediction-page .atta-pair-table tbody th{
  width:190px;
  background:#f7fbfb;
  color:#176879;
  font-weight:400;
  text-align:center;
  white-space:nowrap
}
.atta-prediction-page .atta-element-pairs{margin-top:16px}
.atta-prediction-page .atta-element-pair-table tbody td:nth-child(2){
  width:170px;
  color:#52676c;
  text-align:center;
  white-space:nowrap
}
.atta-prediction-page .atta-element-pair-table tbody td:last-child{
  color:#174e5a;
  text-align:center
}
.atta-prediction-page .atta-pair-table tbody tr:nth-child(even) td{background:#fbfdfd}
.atta-prediction-page .atta-pair-table tbody tr:last-child>*{border-bottom:0}
/* Match the readable centered width used by the Attha input and result panels. */
@media(min-width:701px){
  .mundane-theme-page .mundane-disclaimer,
  .mundane-theme-page .mundane-results{
    width:min(1040px,100%);
    margin-inline:auto
  }
}
.mundane-theme-page .mundane-disclaimer{
  margin-top:12px;
  padding:11px 16px;
  border:1px solid #d4e9ee;
  border-left:1px solid #d4e9ee;
  border-radius:16px;
  background:#f7fcfd!important;
  color:#536669!important;
  font:400 15px/1.8 "Kh Content","Khmer UI",sans-serif!important;
  box-shadow:0 5px 12px #174f5d0d
}
.mundane-theme-page .mundane-date{
  padding:11px 16px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  font:400 16px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 7px 15px #174f5d12
}
.mundane-theme-page .mundane-grid{gap:14px}
.mundane-theme-page .mundane-topic{
  overflow:hidden;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  color:#17667d;
  box-shadow:0 7px 15px #174f5d12
}
.mundane-theme-page .mundane-topic h3{
  min-height:48px;
  border-bottom:1px solid #d4e9ee;
  background:#f2fbfd;
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-size:16px;
  font-weight:400
}
.mundane-theme-page .mundane-topic table{
  width:100%;
  border-collapse:collapse;
  background:#fff;
  color:#17667d;
  font:400 16px "Kh Content","Khmer UI",sans-serif
}
.mundane-theme-page .mundane-topic th,
.mundane-theme-page .mundane-topic td{
  border-color:#d4e9ee;
  background:#fff;
  color:#17667d;
  font-size:16px;
  font-weight:400;
  line-height:1.75
}
.mundane-theme-page .mundane-topic th{
  width:118px;
  background:#f7fcfd
}
.mundane-theme-page .mundane-topic tr:nth-child(even) td,
.mundane-theme-page .mundane-topic tr:nth-child(even) th{background:#f7fcfd}
.mundane-theme-page .mundane-reading{color:#171717!important}
@media(max-width:800px){
  .mundane-theme-page .mundane-card{padding:15px}
  .mundane-theme-page .mundane-disclaimer,
  .mundane-theme-page .mundane-topic{border-radius:14px}
  .mundane-theme-page .mundane-topic th,
  .mundane-theme-page .mundane-topic td{font-size:15px}
}
.daily-rasi-wrap{margin:16px 0;overflow:auto}
.daily-rasi-table{width:100%;min-width:520px;border-collapse:collapse;table-layout:fixed;font:400 16px/1.55 "Kh Content","Khmer UI",sans-serif;color:#111;background:#fff}
.daily-rasi-table :is(th,td){border:1px solid #171717;padding:8px 10px;text-align:center;vertical-align:middle;font:inherit}
.daily-rasi-sutin-label{background:#f3e6dc}
.daily-rasi-sutin-value{background:#fff}
.daily-rasi-animal-label,.daily-rasi-animal-value{background:#c5e1f5}
.daily-rasi-animal-select{display:block}
.daily-rasi-animal-select select{width:100%;border:0;background:transparent;color:#111;font:inherit;text-align:center;cursor:pointer}
.daily-rasi-animal-select select:focus{outline:2px solid #7eb6d4;outline-offset:1px}
.daily-rasi-reading{text-align:left!important;padding:12px 14px!important;line-height:1.55;background:#fff}
.visually-hidden{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:700px){
  .daily-rasi-table{min-width:0;font-size:16px}
  .daily-rasi-table :is(th,td){padding:7px 6px}
}

/* Taksa and Maha Bhuta use the same light, rounded Home visual language. */
.taksa-page .ancient-page{max-width:1280px}
.taksa-page .ancient-card{padding:22px;border:0;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}
.taksa-page .ancient-card>h2,.taksa-page .ancient-card>p{color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}
.taksa-page .ancient-card>p{color:#536669}
.taksa-page .ancient-form label{color:#17667d;text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}
.taksa-page .ancient-form input,.taksa-page .ancient-form select{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font:400 15px "Kh Content","Khmer UI",sans-serif;box-shadow:inset 0 1px 2px #174f5d0d}
.taksa-page .ancient-form input:focus,.taksa-page .ancient-form select:focus{outline:3px solid #b9dfe7;outline-offset:1px}
.taksa-page .ancient-form button{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font:400 15px "Kh Content","Khmer UI",sans-serif;box-shadow:0 7px 15px #174f5d1c;transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease}
.taksa-page .ancient-form button:hover{background:#f2fbfd;box-shadow:0 9px 18px #174f5d29;transform:translateY(-1px)}
.taksa-page .ancient-overview-table,.taksa-page .ancient-date-info{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;color:#17667d;box-shadow:0 7px 15px #174f5d12}
.taksa-page .ancient-overview-table .overview-title,.taksa-page .ancient-info-title{border-color:#d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}
.taksa-page .ancient-overview-table .overview-label,.taksa-page .ancient-overview-table .overview-value,.taksa-page .ancient-info-row span,.taksa-page .ancient-info-row b{border-color:#d4e9ee;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}
.taksa-page .ancient-overview-table .overview-label,.taksa-page .ancient-info-row span{background:#f7fcfd}
.taksa-page .ancient-overview-table .overview-age{color:#17667d}
.taksa-page .ancient-summary{margin-top:10px;padding:10px 16px;border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;box-shadow:0 7px 15px #174f5d12}
.taksa-page .maha-daksa-card{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;box-shadow:0 7px 15px #174f5d12}
.taksa-page .maha-daksa-card h3{border-bottom:1px solid #d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-size:19px;font-weight:400;text-shadow:none}
.maha-daksa-card h3,
.taksa-page .maha-daksa-card h3{background:transparent;border-bottom:0;box-shadow:none}
.taksa-page .maha-daksa-transit-card .kalayog-wheel-label{position:absolute;left:var(--kalayog-x);top:var(--kalayog-y);transform:translate(-50%,-50%);display:flex;width:18%;flex-direction:column;align-items:center;gap:2px;color:#176879;font-family:"Kh Content","Khmer UI",sans-serif;font-size:6px!important;font-weight:400;line-height:1.12!important;text-align:center}
.taksa-page .maha-daksa-transit-card .kalayog-wheel-label.planet-3[data-count="2"]{font-size:8px!important}
.taksa-page .maha-daksa-transit-card .kalayog-transit-marker{display:block;max-width:100%;font-size:inherit!important;line-height:inherit!important;white-space:nowrap}
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-1,
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-2,
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-3{top:34%}
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-5,
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-7,
.taksa-page .maha-daksa-transit-card .maha-daksa-base-number.planet-8{top:68%}
.taksa-page .maha-daksa-figure{background:#fff}
.maha-daksa-card{--daksa-number-size:clamp(14px,1.75vw,18px);border:0;border-radius:0;box-shadow:none}
.taksa-page .maha-daksa-card{border:0;border-radius:0;box-shadow:none}
.maha-daksa-wheel-base,.maha-daksa-inner-ring{border-color:#000}
.maha-daksa-grid-line{background:#000}
.taksa-page .maha-daksa-data-table{border-collapse:collapse;background:#fff;color:#17667d;font:400 16px "Kh Content","Khmer UI",sans-serif}
.taksa-page .maha-daksa-data-table th{border:1px solid #d4e9ee;background:#f2fbfd;color:#17667d;font-size:16px;font-weight:400}
.taksa-page .maha-daksa-data-table td,.taksa-page .maha-daksa-data-table td:last-child{border:1px solid #d4e9ee;background:#fff;color:#17667d;font-size:16px;font-weight:400}
.taksa-page .maha-daksa-data-table tr:nth-child(even) td{background:#f7fcfd}
.taksa-page .ancient-system{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;color:#17667d;box-shadow:0 7px 15px #174f5d12}
.taksa-page .ancient-system h3{border-color:#d4e9ee;background:#f2fbfd;color:#17667d;font-weight:400}
.taksa-page .ancient-system table{background:#fff;color:#17667d}
.taksa-page .ancient-system th{border-color:#d4e9ee;background:#f2fbfd;color:#17667d;font-weight:400}
.taksa-page .ancient-system td{border-color:#d4e9ee;background:#fff;color:#17667d}
.taksa-page .ancient-system tr:nth-child(even) td{background:#f7fcfd}
.taksa-page .taksa-prediction-section{overflow:hidden;border:1px solid #8ebdca;border-radius:18px;background:#fff;color:#17667d;box-shadow:0 7px 15px #174f5d12}
.taksa-page .taksa-prediction-section>h3{border-bottom:1px solid #d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;text-shadow:none}
.taksa-page .taksa-prediction-intro,.taksa-page .transit-reading-summary{border-color:#d4e9ee;background:#f7fcfd;color:#17667d}
.taksa-page .taksa-reading-card,.taksa-page .transit-reading-details article,.taksa-page .transit-natal-filter{border-color:#d4e9ee;border-radius:14px;background:#fff;color:#17667d;box-shadow:none}
.taksa-page .taksa-reading-card header{border-color:#d4e9ee;background:#f2fbfd;color:#17667d}
.taksa-page .taksa-prediction-section :where(h4,p,span,strong,b,em){font-family:"Kh Content","Khmer UI",sans-serif}
@media(max-width:700px){.taksa-page .ancient-card{padding:15px}.taksa-page .ancient-overview-table,.taksa-page .ancient-date-info,.taksa-page .maha-daksa-card,.taksa-page .ancient-system,.taksa-page .taksa-prediction-section{border-radius:14px}}

/* Attha form and source table use the same light, rounded Home visual language. */
.atta-prediction-card>h2,.atta-prediction-card>p{color:#17667d}.atta-prediction-card .ancient-form label{color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}.atta-prediction-card .ancient-form input,.atta-prediction-card .ancient-form select{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;box-shadow:inset 0 1px 2px #174f5d0d}.atta-prediction-card .ancient-form input:focus,.atta-prediction-card .ancient-form select:focus{outline:3px solid #b9dfe7;outline-offset:1px}.atta-prediction-card .ancient-form button{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#c62828;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;box-shadow:0 7px 15px #174f5d1c;transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease}.atta-prediction-card .ancient-form button:hover{background:#fef5f5;box-shadow:0 9px 18px #b53a3a24;transform:translateY(-1px)}.atta-table-card.atta-restored-table{border:1px solid #8ebdca;border-radius:18px;background:#fff;box-shadow:0 7px 15px #174f5d1c}.atta-table-card.atta-restored-table>h3{border-bottom:1px solid #d4e9ee;background:#f2fbfd;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-size:19px;font-weight:400;line-height:1.5;text-shadow:none;box-shadow:none}.atta-table-card.atta-restored-table .atta-source-table{background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif}.atta-table-card.atta-restored-table .atta-source-table td{border-color:#d4e9ee;background:#fff;color:#17667d;font-weight:400}.atta-table-card.atta-restored-table .atta-source-table tr:nth-child(even) td{background:#fff}.atta-table-card.atta-restored-table .atta-label-row td{background:#fff;color:#17667d;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400}.atta-table-card.atta-restored-table .atta-value-row td{background:#fff;color:#17667d}.atta-table-card.atta-restored-table .atta-strength-label-row td{background:#fff!important;color:#17667d!important}.atta-table-card.atta-restored-table .atta-strength-value-row td{background:#fff!important;color:#17667d!important}.atta-table-card.atta-restored-table .atta-cycle-value-row td{background:#fff;color:#17667d}.atta-table-card.atta-restored-table .atta-age-label,.atta-table-card.atta-restored-table .atta-age-origin,.atta-table-card.atta-restored-table .atta-lower-age-planet{background:#fff!important;color:#17667d!important;box-shadow:none!important}.atta-table-card.atta-restored-table .atta-cycle-note{background:#f2fbfd;color:#17667d}.atta-table-card.atta-restored-table .atta-cycle-note strong{color:#17667d;font-weight:400}.atta-table-card.atta-restored-table .atta-age-circle,.atta-table-card.atta-restored-table .atta-cycle-planet{border-color:#d7191c;color:#d7191c;box-shadow:0 0 0 2px #ffe0e0,0 0 8px #d7191c33}

/* Active Attha house keeps the red circle only; cell fill matches every other house. */
.atta-table-card .atta-age-label,
.atta-table-card.atta-restored-table .atta-age-label,
.atta-table-card .atta-age-origin,
.atta-table-card.atta-restored-table .atta-age-origin{
  background:#fff!important;
  color:#17667d!important;
  box-shadow:none!important;
  font-weight:400
}

/* Auspicious astrology: separate, matching birth-information panels for each child. */
.auspicious-card{
  max-width:1280px;
  margin:0 auto;
  border:0;
  background:#fff;
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.auspicious-card>h2,
.auspicious-card>p{
  color:#17667d;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-weight:400
}
.auspicious-card>p{color:#536669}
.auspicious-info-grid{display:grid;grid-template-columns:1fr;gap:18px;margin-top:22px}
.auspicious-info-panel{
  overflow:hidden;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  box-shadow:0 7px 15px #174f5d12
}
.auspicious-info-panel h3{
  margin:0;
  padding:13px 16px;
  border-bottom:1px solid #d4e9ee;
  background:#f2fbfd;
  color:#17667d;
  text-align:center;
  font:400 18px "Kh Content","Khmer UI",sans-serif
}
.auspicious-info-form{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;padding:16px}
.auspicious-info-form label{
  display:grid;
  gap:5px;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif
}
.auspicious-info-form .auspicious-name-field{grid-column:1/-1}
.auspicious-info-form input{
  box-sizing:border-box;
  width:100%;
  min-height:42px;
  padding:8px 12px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:inset 0 1px 2px #174f5d0d
}
.auspicious-info-form input:focus{
  outline:3px solid #b9dfe7;
  outline-offset:1px
}
.auspicious-info-form button{
  grid-column:1/-1;
  justify-self:center;
  min-width:210px;
  min-height:42px;
  padding:8px 18px;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#c62828;
  cursor:pointer;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 7px 15px #174f5d1c;
  transition:transform .18s ease,box-shadow .18s ease,background-color .18s ease
}
.auspicious-info-form button:hover{background:#fef5f5;box-shadow:0 9px 18px #b53a3a24;transform:translateY(-1px)}
.auspicious-info-form button:disabled{cursor:wait;opacity:.7;transform:none}
.auspicious-result{
  min-height:48px;
  margin:0 16px 16px;
  overflow-x:auto;
  border:1px solid #d4e9ee;
  border-radius:14px;
  background:#f7fcfd;
  color:#536669;
  font:400 15px/1.65 "Kh Content","Khmer UI",sans-serif
}
.auspicious-result:not(:has(.auspicious-birth-table)){padding:10px 13px;text-align:center}
.auspicious-birth-table{
  display:grid;
  grid-template-columns:minmax(72px,.65fr) minmax(110px,1fr) minmax(105px,.9fr) minmax(210px,1.5fr) minmax(115px,.95fr) minmax(190px,1.3fr);
  min-width:780px;
  background:#fff;
  color:#17667d
}
.auspicious-birth-table>*{
  min-width:0;
  padding:8px;
  border-right:1px solid #d4e9ee;
  border-bottom:1px solid #d4e9ee;
  display:flex;
  align-items:center;
  overflow-wrap:anywhere;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-weight:400
}
.auspicious-birth-table .auspicious-result-title{
  grid-column:span 2;
  justify-content:center;
  background:#f2fbfd;
  color:#17667d;
  text-align:center
}
.auspicious-birth-table .auspicious-result-title-wide{grid-column:1 / -1}
.auspicious-birth-table .auspicious-result-label{background:#f7fcfd;color:#17667d}
.auspicious-birth-table .auspicious-result-value{background:#fff;color:#17667d}
.auspicious-birth-table .auspicious-age-value{display:block;color:#c62828}
.auspicious-birth-table .auspicious-result-end{border-right:0}
.auspicious-birth-table .auspicious-result-observed{
  grid-column:1/-1;
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:center;
  gap:6px 12px;
  border-right:0;
  border-bottom:0;
  background:#f2fbfd;
  color:#17667d;
  text-align:center
}
.auspicious-birth-table .auspicious-true-age{
  color:#536669;
  font-size:13px;
  font-weight:400;
  white-space:nowrap
}
@media(max-width:700px){
  .auspicious-card{padding:15px}
  .auspicious-info-grid{gap:14px;margin-top:16px}
  .auspicious-info-panel{border-radius:14px}
  .auspicious-info-form{grid-template-columns:repeat(3,minmax(0,1fr))}
  .auspicious-info-form .auspicious-name-field{grid-column:auto}
  .auspicious-info-form button{grid-column:1/-1;width:100%}
  .auspicious-card .auspicious-info-form button{
    grid-column:1/-1;
    grid-row:auto;
    min-width:0;
    width:100%;
    margin:0;
    align-self:stretch;
    display:flex;
    align-items:center;
    justify-content:center;
    box-sizing:border-box;
    padding-inline:16px;
    text-align:center;
    white-space:nowrap
  }
  .auspicious-result{margin:0 10px 10px;border-radius:12px}
}

/* Keep both child calculators together on wide screens and compact the result grids. */
.auspicious-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
.auspicious-birth-table{
  grid-template-columns:minmax(0,.55fr) minmax(0,.9fr) minmax(0,.75fr) minmax(0,1.1fr) minmax(0,.8fr) minmax(0,1.1fr);
  min-width:0;
  font-size:12px;
  line-height:1.45
}
.auspicious-birth-table>*{padding:6px 5px}
.auspicious-birth-table .auspicious-result-title{font-size:12px}
.auspicious-birth-table .auspicious-true-age{font-size:11px}
@media(max-width:760px){
  .auspicious-info-grid{grid-template-columns:1fr}
  .auspicious-birth-table{min-width:0;font-size:13px}
  .auspicious-birth-table>*{padding:7px 6px}
}

/* Shared auspicious timing table below the two child information panels. */
.auspicious-timing-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
  margin-top:18px;
  align-items:stretch
}
.auspicious-timing-card{
  min-width:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  color:#17667d;
  box-shadow:0 7px 15px #174f5d12
}
.auspicious-timing-card h3{
  margin:0;
  min-height:48px;
  box-sizing:border-box;
  padding:12px 16px;
  border-bottom:1px solid #d4e9ee;
  background:#d9ead3;
  color:#17667d;
  text-align:center;
  display:flex;
  align-items:center;
  justify-content:center;
  font:400 18px "Kh Content","Khmer UI",sans-serif
}
.auspicious-timing-table{
  width:100%!important;
  min-width:0!important;
  height:100%;
  flex:1;
  border-collapse:collapse;
  table-layout:fixed!important;
  color:#17667d;
  font:400 16px/1.5 "Kh Content","Khmer UI",sans-serif
}
.auspicious-timing-table th,
.auspicious-timing-table td{
  width:50%!important;
  box-sizing:border-box;
  padding:8px 12px;
  border:1px solid #b8cfd3;
  text-align:center;
  vertical-align:middle
}
.auspicious-timing-table th{
  background:#e4e4e4;
  color:#17667d;
  font-weight:400
}
.auspicious-timing-table td{background:#e4e4e4;color:#17667d}
.auspicious-timing-table tr:nth-child(even) th,
.auspicious-timing-table tr:nth-child(even) td{background:#ececec}
.auspicious-timing-table .auspicious-timing-note{color:#c62828}
.auspicious-timing-table .auspicious-timing-result{color:#c62828;font-weight:400}
.auspicious-timing-empty-row th,.auspicious-timing-empty-row td{height:30px}
.auspicious-timing-table .auspicious-remainder{width:100%!important;color:#c62828;font-size:14px;line-height:1.55;text-align:center}
.auspicious-detail-card{
  width:100%;
  max-width:none;
  margin:18px auto 0;
  overflow:hidden;
  border:1px solid #8ebdca;
  border-radius:18px;
  background:#fff;
  color:#17667d;
  box-shadow:0 7px 15px #174f5d12
}
.auspicious-detail-card h3{
  margin:0;
  padding:12px 16px;
  border-bottom:1px solid #d4e9ee;
  background:#d9ead3;
  color:#17667d;
  text-align:center;
  font:400 18px "Kh Content","Khmer UI",sans-serif
}
#auspicious-detail-heading.auspicious-verdict-good{color:#16834b}
#auspicious-detail-heading.auspicious-verdict-bad{color:#c62828}
.auspicious-detail-table-wrap{overflow-x:auto}
.auspicious-detail-tables{
  display:grid;
  grid-template-columns:minmax(520px,1fr) minmax(260px,max-content);
  width:100%;
  min-width:780px;
  align-items:stretch
}
.auspicious-detail-table{
  width:100%!important;
  min-width:520px!important;
  border-collapse:collapse;
  table-layout:fixed;
  color:#17667d;
  font:400 15px/1.45 "Kh Content","Khmer UI",sans-serif
}
.auspicious-side-table{
  width:100%!important;
  min-width:260px!important;
  table-layout:auto;
  margin-left:-1px
}
.auspicious-side-table th:first-child,
.auspicious-side-table td:first-child{
  width:auto!important
}
.auspicious-side-table th:last-child,
.auspicious-side-table td:last-child{
  width:auto!important;
  min-width:240px
}
.auspicious-side-table .auspicious-opening-months{
  padding:7px 9px;
  color:#17667d;
  line-height:1.65;
  overflow:visible;
  white-space:nowrap
}
.auspicious-side-table .auspicious-opening-days{
  padding:7px 9px;
  color:#17667d;
  line-height:1.65;
  overflow:visible;
  white-space:nowrap
}
.auspicious-opening-months-line{
  display:inline-block;
  width:max-content;
  min-width:100%;
  white-space:nowrap
}
.auspicious-detail-table th,.auspicious-detail-table td{
  padding:7px 6px;
  border:1px solid #b8cfd3;
  text-align:center;
  vertical-align:middle
}
.auspicious-detail-table thead th{background:#d9ead3;color:#17667d;font-weight:400}
.auspicious-detail-table tbody th,.auspicious-detail-table tbody td{background:#e4e4e4;color:#17667d;font-weight:400}
.auspicious-detail-table tbody tr:nth-child(even) th,.auspicious-detail-table tbody tr:nth-child(even) td{background:#ececec}
.auspicious-detail-table th:first-child{width:22%}
.auspicious-detail-table .auspicious-lunar-index-cell{width:10%;padding-left:4px;padding-right:4px}
.auspicious-detail-table .auspicious-lunar-index-cell,
.auspicious-detail-table .auspicious-lunar-sequence-cell{color:#c62828}
.auspicious-detail-table .auspicious-lunar-index-cell>span,
.auspicious-detail-table .auspicious-lunar-sequence-cell>span{display:inline-flex;min-width:1.65em;height:1.65em;align-items:center;justify-content:center;border-radius:50%;line-height:1}
.auspicious-detail-table .auspicious-transit-active>span{border:3px solid #d7191c;color:#d7191c;box-shadow:0 0 0 2px #ffe0e0}
.auspicious-detail-table .auspicious-lunar-label{width:22%;white-space:nowrap;font-weight:400}

/* Match every auspicious surface to the translucent white Home button. */
body.auspicious-page{
  --auspicious-home-surface:rgba(255,255,255,.94);
  background:#fff
}
.auspicious-card,
.auspicious-info-panel,
.auspicious-info-panel h3,
.auspicious-info-form input,
.auspicious-info-form button,
.auspicious-result,
.auspicious-birth-table,
.auspicious-birth-table .auspicious-result-title,
.auspicious-birth-table .auspicious-result-label,
.auspicious-birth-table .auspicious-result-value,
.auspicious-birth-table .auspicious-result-observed,
.auspicious-timing-card,
.auspicious-timing-card h3,
.auspicious-timing-table th,
.auspicious-timing-table td,
.auspicious-timing-table tr:nth-child(even) th,
.auspicious-timing-table tr:nth-child(even) td,
.auspicious-detail-card,
.auspicious-detail-card h3,
.auspicious-detail-table thead th,
.auspicious-detail-table tbody th,
.auspicious-detail-table tbody td,
.auspicious-detail-table tbody tr:nth-child(even) th,
.auspicious-detail-table tbody tr:nth-child(even) td{
  background:var(--auspicious-home-surface)
}
.auspicious-info-panel,
.auspicious-timing-card,
.auspicious-detail-card{
  backdrop-filter:blur(8px)
}
@media(max-width:760px){
  .auspicious-timing-grid{grid-template-columns:1fr;gap:14px}
  .auspicious-timing-card{border-radius:14px}
  .auspicious-timing-card h3{font-size:16px;padding:10px 12px}
  .auspicious-timing-table{font-size:14px}
  .auspicious-timing-table th,.auspicious-timing-table td{padding:7px 8px}
  .auspicious-detail-card{border-radius:14px}
  .auspicious-detail-card h3{font-size:16px;padding:10px 12px}
  .auspicious-detail-table{font-size:14px}
}

/* Use one readable type size across every auspicious-astrology panel. */
.auspicious-card{
  --auspicious-unified-font-size:16px;
}
.auspicious-card,
.auspicious-card :where(h2,h3,p,label,input,select,button,table,thead,tbody,tr,th,td,b,strong,span,small,em,div){
  font-size:var(--auspicious-unified-font-size)!important;
}

/* Keep all three timing cards fully usable on narrow mobile screens. */
@media(max-width:760px){
  .auspicious-card,
  .auspicious-card :where(h2,h3,p,label,input,select,button,table,thead,tbody,tr,th,td,b,strong,span,small,em,div){
    font-size:var(--auspicious-unified-font-size)!important;
  }
  .auspicious-card{
    padding:10px;
    padding-bottom:calc(116px + env(safe-area-inset-bottom));
    margin-bottom:0;
  }
  .auspicious-timing-grid{
    display:grid;
    grid-template-columns:minmax(0,1fr);
    max-width:100%;
    gap:10px;
    margin-top:12px;
    padding:0 2px 10px;
    overflow:visible;
  }
  .auspicious-timing-card{
    display:block;
    width:100%;
    overflow:visible;
  }
  .auspicious-timing-card h3,
  .auspicious-detail-card h3{
    min-height:40px;
    padding:8px 10px;
    line-height:1.4;
  }
  .auspicious-timing-table th,
  .auspicious-timing-table td{
    padding:6px 5px;
    line-height:1.4;
  }
  .auspicious-timing-table{
    display:table!important;
    height:auto!important;
    flex:none!important;
  }
  .auspicious-timing-table tbody{
    display:table-row-group!important;
  }
  .auspicious-timing-table tr,
  .auspicious-timing-empty-row{
    display:table-row!important;
    visibility:visible!important;
  }
  .auspicious-timing-empty-row th,
  .auspicious-timing-empty-row td{
    display:table-cell!important;
    visibility:visible!important;
    height:auto!important;
    min-height:38px;
    padding:8px 6px!important;
    white-space:normal;
    overflow-wrap:anywhere;
  }
  .auspicious-card .auspicious-info-form{
    gap:8px;
    padding:10px;
  }
  .auspicious-card .auspicious-info-form input,
  .auspicious-card .auspicious-info-form button{
    min-height:38px;
    padding:6px 10px;
  }
}

/* Keep birth-result tables on the same 16px type size as the rest of the card. */
.auspicious-card .auspicious-birth-table{
  --auspicious-birth-font-size:16px;
  grid-template-columns:minmax(42px,.5fr) minmax(38px,.55fr) minmax(60px,.7fr) minmax(0,1.25fr) minmax(60px,.72fr) minmax(0,1.75fr);
  font-size:var(--auspicious-birth-font-size)!important;
  line-height:1.35
}
.auspicious-card .auspicious-birth-table > *,
.auspicious-card .auspicious-birth-table :where(b,small,span,div){
  font-size:var(--auspicious-birth-font-size)!important;
  line-height:1.35
}
.auspicious-card .auspicious-birth-table .auspicious-age-value{
  white-space:nowrap
}
.auspicious-card .auspicious-birth-table .auspicious-result-observed{
  gap:4px 10px
}
.auspicious-card .auspicious-birth-table .auspicious-true-age{
  white-space:nowrap
}
@media(max-width:760px){
  .auspicious-card .auspicious-info-panel{min-width:0}
  .auspicious-card .auspicious-result{
    margin:0 4px 8px;
    overflow:hidden
  }
  .auspicious-card .auspicious-birth-table{
    --auspicious-birth-font-size:16px;
    grid-template-columns:minmax(30px,.5fr) minmax(28px,.5fr) minmax(42px,.68fr) minmax(0,1.25fr) minmax(42px,.7fr) minmax(0,1.8fr);
    width:100%;
    min-width:0
  }
  .auspicious-card .auspicious-birth-table > *{padding:5px 2px}
}

/* Transit aspect results: keep the table grid, but remove the outer card frame. */
.transit-page .aspect-card{
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:transparent!important;
  padding:12px 0 0!important
}

/* Lunar/eclipses page: remove only the large outer frame and keep inner panels. */
.lunar-eclipse-page .reference-card{
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  background:transparent!important
}

/* Keep every lunar/eclipses information surface on the same centred axis. */
@media(min-width:701px){
  .lunar-eclipse-page .reference-page{
    width:min(100%,1080px);
    margin-inline:auto
  }
  .lunar-eclipse-page .reference-card{
    width:100%;
    margin-inline:auto
  }
  .lunar-eclipse-page .moon-form,
  .lunar-eclipse-page .lunar-reference-panel,
  .lunar-eclipse-page .moon-birth-info,
  .lunar-eclipse-page .moon-results,
  .lunar-eclipse-page .kalayog-results{
    width:min(100%,900px);
    margin-left:auto;
    margin-right:auto
  }
}

/* Construction astrology choices: equal Home-style buttons centred on the page. */
.construction-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:14px;
  margin:28px auto 0
}
.construction-actions button:not(.tool-navigation-toggle){
  display:inline-flex;
  width:210px;
  min-height:50px;
  align-items:center;
  justify-content:center;
  margin:0;
  border:1px solid #8ebdca;
  border-radius:999px;
  background:#fff;
  color:#17667d;
  padding:8px 18px;
  font:400 16px "Kh Content","Khmer UI",sans-serif;
  box-shadow:0 7px 15px #174f5d1c;
  cursor:pointer;
  transition:transform .18s ease,background-color .18s ease,box-shadow .18s ease
}
.construction-actions button:not(.tool-navigation-toggle):hover{
  background:#eaf7fa;
  box-shadow:0 9px 18px #174f5d29;
  transform:translateY(-1px)
}
.construction-card-heading{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:center;
  gap:10px 14px;
  margin:0 0 2px
}
.construction-card-heading h2{
  margin:0
}
.construction-land-shape-select{
  box-sizing:border-box;
  min-width:min(100%,280px);
  max-width:min(100%,420px);
  height:42px;
  padding:0 36px 0 12px;
  border:1px solid #8fc7d4;
  border-radius:10px;
  background:#fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2317667d' d='M1 1.5L6 6.5L11 1.5'/%3E%3C/svg%3E") no-repeat right 12px center;
  color:#17667d;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  appearance:none;
  -webkit-appearance:none
}
.construction-land-shape-select:is(:hover,:focus){
  border-color:#17667d;
  box-shadow:0 0 0 3px rgba(23,102,125,.12);
  outline:0
}
@media(max-width:520px){
  .construction-land-shape-select{
    width:100%;
    max-width:none;
    min-width:0
  }
}
.construction-land-shape-panel{
  margin-top:18px
}
.construction-land-shape-hint{
  margin:18px auto;
  max-width:36rem;
  color:#5d7880;
  font:400 15px "Kh Content","Khmer UI",sans-serif;
  text-align:center
}
.construction-land-shape-plan{
  display:none;
  justify-items:center;
  gap:14px;
  margin:18px auto 8px;
  max-width:1100px;
  width:100%
}
.construction-land-shape-plan:not([hidden]){
  display:grid
}
.construction-land-shape-drawing{
  display:block;
  width:100%;
  height:auto;
  border:1px solid #cfc3ae;
  border-radius:4px;
  box-shadow:0 8px 20px rgba(55,42,20,.08);
  object-fit:contain;
  background:#e8f0e4
}
.construction-land-shape-iso-view{
  max-height:none;
  min-height:0
}
.construction-land-shape-plan figcaption{
  display:grid;
  gap:6px;
  color:#17667d;
  font:400 14px "Kh Content","Khmer UI",sans-serif;
  text-align:center
}
.construction-land-shape-plan figcaption strong{
  color:#9b1c1c;
  font-weight:600;
  font-size:16px
}
.construction-land-shape-prediction{
  display:none;
  margin:18px auto 8px;
  max-width:1100px;
  width:100%;
  padding:18px 20px;
  border:1px solid #9bc8d3;
  border-radius:16px;
  background:rgba(247,252,253,.96);
  color:#174e5a;
  box-shadow:0 8px 22px rgba(7,94,121,.06);
  font-family:"Kh Content","Khmer UI",sans-serif;
  text-align:left
}
.construction-land-shape-prediction:not([hidden]){display:grid;gap:12px}
.construction-land-shape-prediction h3{
  margin:0;
  color:#075e79;
  font-size:18px;
  font-weight:400;
  text-align:center
}
.construction-land-shape-prediction-name{
  margin:0;
  color:#075e79;
  font-size:17px;
  text-align:center
}
.construction-land-shape-prediction[data-state="good"] .construction-land-shape-prediction-name{color:#16834b}
.construction-land-shape-prediction[data-state="bad"] .construction-land-shape-prediction-name{color:#c62828}
.construction-land-shape-prediction-grid{
  display:grid;
  gap:12px;
  margin:0
}
.construction-land-shape-prediction-grid>div{
  display:grid;
  gap:4px;
  padding:12px 14px;
  border:1px solid #d4e9ee;
  border-radius:12px;
  background:#fff
}
.construction-land-shape-prediction-grid dt{
  color:#5d7880;
  font-size:14px
}
.construction-land-shape-prediction-grid dd{
  margin:0;
  color:#174e5a;
  font-size:16px;
  line-height:1.7;
  white-space:pre-line
}
.construction-actions .construction-action-active{
  border-color:#17667d;
  background:#f2fbfd;
  color:#17667d
}
.construction-information{margin-top:20px}
.construction-information .auspicious-info-grid{margin-top:0}
.construction-spouse-reference{
  width:min(100%,1100px);
  margin:20px auto 0;
  color:#075e79;
  font-family:"Kh Content","Khmer UI",sans-serif;
  text-align:center
}
.construction-spouse-layout{
  display:flex;
  align-items:stretch;
  gap:14px
}
.construction-spouse-reference-scroll{
  flex:1 1 auto;
  min-width:0;
  overflow-x:auto;
  border:1px solid #b9d8df;
  border-radius:16px;
  background:#fff;
  box-shadow:0 8px 22px rgba(7,94,121,.06)
}
.construction-spouse-reference table{
  width:100%;
  min-width:650px;
  border-collapse:collapse;
  table-layout:fixed
}
.construction-spouse-reference :is(th,td){
  padding:10px 8px;
  border-right:1px solid #cfe3e8;
  border-bottom:1px solid #cfe3e8;
  font-size:16px!important;
  font-weight:400;
  text-align:center
}
.construction-spouse-reference tr>*:last-child{border-right:0}
.construction-spouse-reference tbody tr:last-child>*{border-bottom:0}
.construction-spouse-reference thead th{
  background:#e7f3f7;
  color:#075e79
}
.construction-spouse-reference tbody th{
  background:#f4fafc;
  color:#075e79
}
.construction-spouse-reference tbody th>span{display:block}
.construction-spouse-reference tbody th>small{
  display:none!important
}
.construction-spouse-reference td{color:#111}
.construction-spouse-reference .construction-spouse-remainder-active{
  background:transparent
}
.construction-spouse-reference .construction-spouse-remainder-active>span{
  display:inline-flex;
  width:1.8em;
  height:1.8em;
  align-items:center;
  justify-content:center;
  border:2px solid #d51f2b;
  border-radius:50%;
  color:#d51f2b;
  font-size:16px!important;
  line-height:1
}
.construction-spouse-prediction{
  flex:0 0 clamp(220px,28%,300px);
  width:auto;
  margin:0;
  padding:16px 18px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  border:1px solid #9bc8d3;
  border-radius:16px;
  background:rgba(247,252,253,.96);
  color:#111;
  text-align:center;
  box-shadow:0 8px 22px rgba(7,94,121,.06);
  font-family:"Kh Content","Khmer UI",sans-serif
}
.construction-spouse-prediction h3{
  margin:0 0 8px;
  color:#075e79;
  font-size:18px;
  font-weight:400
}
.construction-spouse-prediction-verdict{
  margin:0 0 6px;
  font-size:20px;
  font-weight:700
}
.construction-spouse-prediction[data-state="good"] .construction-spouse-prediction-verdict{color:#16834b}
.construction-spouse-prediction[data-state="medium"] .construction-spouse-prediction-verdict{color:#9a5b00}
.construction-spouse-prediction[data-state="bad"] .construction-spouse-prediction-verdict{color:#c62828}
.construction-spouse-prediction-reading{
  margin:0;
  color:#174e5a;
  font-size:16px;
  line-height:1.7
}
.construction-spouse-prediction[data-state="missing"] .construction-spouse-prediction-reading{color:#5d7880}
@media(max-width:860px){
  .construction-spouse-layout{
    flex-direction:column
  }
  .construction-spouse-prediction{
    flex:none;
    width:100%
  }
}
@media(max-width:600px){
  .construction-spouse-reference{
    margin-top:14px
  }
  .construction-spouse-reference :is(th,td){
    padding:8px 6px;
    font-size:16px!important
  }
}
.construction-formula-panel{
  width:min(100%,920px);
  margin:24px auto 0;
  overflow-x:auto;
  border-radius:20px;
  box-shadow:0 10px 26px rgba(23,102,125,.1)
}
.construction-formula-table{
  width:max-content;
  min-width:100%;
  max-width:none;
  margin-inline:auto;
  table-layout:auto;
  border-collapse:collapse;
  color:#17667d;
  font:400 20px "Kh Content","Khmer UI",sans-serif
}
.construction-formula-table :is(th,td){
  height:56px;
  border:0;
  border-right:1px solid #b9d8df;
  border-bottom:1px solid #b9d8df;
  width:auto;
  padding:0;
  white-space:nowrap;
  text-align:center;
  vertical-align:middle
}
.construction-formula-table tr>*:first-child{border-left:1px solid #b9d8df}
.construction-formula-table thead tr:first-child>*{border-top:1px solid #b9d8df}
.construction-formula-table thead tr:first-child>th:first-child{border-top-left-radius:18px}
.construction-formula-table thead tr:first-child>th:last-child{border-top-right-radius:18px}
.construction-formula-table tbody tr:last-child>*:first-child{border-bottom-left-radius:18px}
.construction-formula-table tbody tr:last-child>*:last-child{border-bottom-right-radius:18px}
.construction-formula-table thead th{
  background:#dcefd6;
  font-weight:400
}
.construction-land-heading{
  display:flex;
  min-height:56px;
  align-items:center;
  justify-content:center;
  padding:5px 12px
}
.construction-formula-table tbody th{
  background:#f1f8f9;
  font-weight:400
}
.construction-formula-table :is(input,select,.construction-area-output){
  width:auto;
  height:100%;
  min-width:8ch;
  max-width:100%;
  border:0;
  border-radius:0;
  background:#fffdf8;
  color:#17667d;
  padding:8px 12px;
  text-align:center;
  font:inherit;
  outline-offset:-2px
}
.construction-formula-table input{
  field-sizing:content
}
.construction-formula-table select{
  width:calc(100% - 16px);
  min-width:18ch;
  height:44px;
  margin:6px 8px;
  border:1px solid #8fc7d4;
  border-radius:12px;
  background-color:#fff;
  padding:6px 36px 6px 12px;
  text-align:start;
  font:inherit;
  cursor:pointer;
  box-shadow:0 3px 10px rgba(23,102,125,.08);
  transition:border-color .18s ease,box-shadow .18s ease
}
.construction-formula-table select:is(:hover,:focus){
  border-color:#17667d;
  box-shadow:0 0 0 3px rgba(23,102,125,.12);
  outline:0
}
.construction-formula-table .construction-direction-heading,
.construction-formula-table .construction-direction-cell{
  min-width:20ch
}

/* Keep the direction control fully readable on the desktop web layout. */
@media (min-width:769px){
  .construction-formula-panel{
    width:min(100%,1400px);
    overflow-x:visible
  }
  .construction-formula-table{
    width:100%;
    min-width:1400px
  }
  .construction-formula-table .construction-direction-heading,
  .construction-formula-table .construction-direction-cell{
    width:260px;
    min-width:260px
  }
  .construction-formula-table .construction-direction-cell{
    padding:6px 10px
  }
  .construction-formula-table .construction-direction-cell select{
    display:block;
    box-sizing:border-box;
    width:100%;
    min-width:238px;
    max-width:none;
    height:46px;
    margin:0;
    padding:7px 40px 7px 14px;
    font-size:20px;
    line-height:1.35;
    white-space:nowrap
  }
}
.construction-formula-table .construction-area-output{
  display:flex;
  min-width:14ch;
  align-items:center;
  justify-content:center
}
.construction-formula-table .construction-area-label{
  min-width:20ch;
  padding-inline:18px;
  white-space:nowrap
}
.construction-formula-table .construction-area-cell{
  min-width:15ch
}
.construction-formula-table tbody th{
  padding-inline:12px
}
@media(max-width:520px){
  .construction-actions{align-items:center;flex-direction:column}
  .construction-actions button:not(.tool-navigation-toggle){width:min(100%,260px)}
  .construction-formula-panel{
    width:100%;
    overflow-x:visible
  }
  .construction-formula-table{
    display:block;
    width:100%;
    min-width:0;
    font-size:16px
  }
  .construction-formula-table :is(thead,tbody){display:block}
  .construction-formula-table thead tr{
    display:block;
    width:100%
  }
  .construction-formula-table thead .construction-land-heading{
    width:100%;
    min-height:48px;
    border:1px solid #b9d8df;
    border-radius:18px 18px 0 0
  }
  .construction-formula-table thead .construction-direction-heading{display:none}
  .construction-formula-table tbody tr{
    display:grid;
    grid-template-columns:minmax(112px,.9fr) minmax(0,1.1fr);
    width:100%
  }
  .construction-formula-table :is(th,td){
    box-sizing:border-box;
    display:flex;
    width:auto;
    min-width:0;
    align-items:center;
    justify-content:center;
    border-right:1px solid #b9d8df;
    border-bottom:1px solid #b9d8df;
    white-space:normal
  }
  .construction-formula-table .construction-area-label{
    min-width:0;
    padding-inline:10px;
    white-space:normal
  }
  .construction-formula-table .construction-area-cell{
    min-width:0
  }
  .construction-formula-table tbody th{
    min-width:0;
    padding-inline:7px
  }
  .construction-formula-table :is(input,select,.construction-area-output){
    box-sizing:border-box;
    width:100%;
    min-width:0;
    max-width:none;
    padding-inline:6px
  }
  .construction-formula-table .construction-direction-cell{
    display:grid;
    grid-column:1 / -1;
    grid-template-columns:minmax(112px,.9fr) minmax(0,1.1fr);
    width:100%;
    min-width:0;
    height:56px;
    padding:0
  }
  .construction-formula-table .construction-direction-cell::before{
    content:"ដីបែរទៅទិស";
    display:flex;
    height:100%;
    align-items:center;
    justify-content:center;
    border-right:1px solid #b9d8df;
    background:#f2fbfd;
    color:#17667d
  }
  .construction-formula-table select{
    width:calc(100% - 12px);
    min-width:0;
    height:42px;
    margin:5px 6px;
    padding-inline:10px 32px;
    font-size:16px
  }
  .construction-land-heading{min-height:48px;padding-inline:7px}
}

/* Auspicious astrology sections: equal Home-style actions below the page title. */
.auspicious-page header>div:first-child{
  width:min(100%,980px)
}


/* About page: warm Khmer editorial layout with compact mobile reading flow. */
body.about-page{
  min-height:100vh;
  background:
    radial-gradient(circle at 8% 5%,#e7b84f30 0 10%,transparent 30%),
    radial-gradient(circle at 92% 12%,#8ebdca38 0 8%,transparent 27%),
    #f7f4ed;
  color:#25212a;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.about-header{
  min-height:310px;
  align-items:center;
  border:0;
  background:linear-gradient(130deg,#2d174c 0%,#56347d 55%,#17667d 100%);
  color:#fff;
  padding:52px 24px;
  position:relative;
  overflow:hidden
}
.about-header::before,.about-header::after{
  content:"";
  position:absolute;
  border:1px solid #ffffff2c;
  border-radius:50%;
  pointer-events:none
}
.about-header::before{width:390px;height:390px;right:-150px;top:-230px}
.about-header::after{width:260px;height:260px;left:-120px;bottom:-185px}
.about-header>div:first-child{position:relative;z-index:1;max-width:900px}
.about-header h1{
  margin:8px 0 14px;
  color:#fff;
  font-family:"AKbalthom Angkor 1 Plus","Kh Content",sans-serif;
  font-size:clamp(34px,5vw,58px);
  line-height:1.25
}
.about-kicker{
  margin:0;
  color:#e7b84f;
  font-weight:700;
  letter-spacing:.04em
}
.about-main{width:min(1180px,calc(100% - 32px));margin:-52px auto 0;padding:0 0 42px;position:relative;z-index:2}
.about-surface{
  border:1px solid #d5cbb9;
  border-radius:24px;
  background:#fffdf9;
  box-shadow:0 18px 45px #31244314
}
.about-intro{display:grid;grid-template-columns:82px 1fr;gap:24px;padding:34px}
.about-main h2{margin:0 0 12px;color:#3b235e;font-weight:700;line-height:1.55}
.about-main p{margin:0 0 12px;line-height:1.9}
.about-section{padding:54px 0 20px}
.about-section-heading{display:flex;align-items:center;gap:16px;margin-bottom:24px}
.about-section-heading>span{
  display:grid;
  width:52px;
  height:52px;
  flex:0 0 auto;
  place-items:center;
  border-radius:50%;
  background:#e7b84f;
  color:#2d174c;
  font-weight:700
}
.about-section-heading h2,.about-section-heading p{margin:0}
.about-section-heading p{color:#6d6472}
.about-feature-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.about-feature{
  min-height:145px;
  border:1px solid #dce8e9;
  border-radius:18px;
  background:#ffffffc7;
  padding:22px;
  box-shadow:0 8px 24px #174f5d0b
}
.about-feature::before{content:"✦";display:block;margin-bottom:9px;color:#c58b17}
.about-feature b{color:#17667d;font-size:18px;font-weight:700}
.about-feature p{margin:6px 0 0;color:#554e58}
.about-two-column{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin:36px 0}
.about-two-column>section{padding:30px}
.about-card-label{
  display:inline-flex;
  margin-bottom:14px;
  border-radius:999px;
  background:#edf7f8;
  color:#17667d;
  padding:6px 13px;
  font-weight:700
}
.about-mission ul{display:grid;gap:9px;margin:0;padding:0;list-style:none}
.about-mission li{position:relative;padding-left:27px;line-height:1.65}
.about-mission li::before{content:"✓";position:absolute;left:0;color:#b97909;font-weight:700}
.about-disclaimer{
  display:grid;
  grid-template-columns:52px 1fr;
  gap:20px;
  border:1px solid #e6c777;
  border-radius:22px;
  background:#fff8df;
  padding:28px
}
.about-disclaimer-icon{
  display:grid;
  width:46px;
  height:46px;
  place-items:center;
  border:2px solid #b97909;
  border-radius:50%;
  color:#9a6508;
  font:bold 24px Georgia,serif
}
.about-join{margin-top:36px;padding:38px;text-align:center}
.about-join>p{max-width:880px;margin-left:auto;margin-right:auto}
.about-site-link{
  display:inline-flex;
  margin:12px 0 8px;
  border-radius:999px;
  background:#56347d;
  color:#fff;
  padding:11px 24px;
  text-decoration:none;
  box-shadow:0 9px 20px #56347d33
}
.about-site-link:hover{background:#e7b84f!important;color:#171717!important}
.about-tagline{color:#17667d;font-weight:700}
@media(max-width:860px){
  .about-feature-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .about-two-column{grid-template-columns:1fr}
}
@media(max-width:600px){
  .about-header{min-height:260px;padding:36px 16px 68px}
  .about-main{width:min(100% - 20px,1180px);margin-top:-40px}
  .about-intro{grid-template-columns:1fr;padding:24px}
  .about-section{padding-top:38px}
  .about-section-heading{align-items:flex-start}
  .about-feature-grid{grid-template-columns:1fr}
  .about-feature{min-height:auto;padding:18px}
  .about-two-column>section,.about-disclaimer,.about-join{padding:22px}
  .about-disclaimer{grid-template-columns:1fr}
}

/* Dragon lineage: centred reference illustration below both birth panels. */
.dragon-lineage-illustration{
  width:min(100%,1400px);
  max-width:100%;
  margin:30px auto 0;
  padding:0;
  text-align:center
}
.dragon-lineage-visual{
  position:relative;
  width:100%
}
.dragon-lineage-illustration img{
  display:block;
  width:100%;
  height:auto;
  margin:0 auto;
  border-radius:0;
  object-fit:contain;
  box-shadow:none
}
.dragon-lineage-numbers{
  position:absolute;
  inset:0;
  pointer-events:none
}
.dragon-lineage-numbers>span{
  position:absolute;
  top:79.5%;
  left:var(--dragon-number-position);
  display:flex;
  width:4.6%;
  aspect-ratio:1;
  align-items:center;
  justify-content:center;
  transform:translate(-50%,-50%);
  border:0;
  border-radius:50%;
  background:transparent;
  color:#000;
  font:400 16px/1 "Kh Content","Khmer UI",sans-serif;
  box-shadow:none;
  transition:color .2s ease,box-shadow .2s ease
}
.dragon-lineage-numbers>span:is(
  .dragon-lineage-son-selected,
  .dragon-lineage-daughter-selected
){
  z-index:2;
  background:transparent;
  font-size:20px;
  font-weight:700;
  box-shadow:none;
  -webkit-text-stroke:0
}
.dragon-lineage-numbers>span.dragon-lineage-son-selected{
  background:transparent;
  color:#075e79;
  box-shadow:none
}
.dragon-lineage-numbers>span.dragon-lineage-daughter-selected{
  background:transparent;
  color:#a5213b;
  box-shadow:none
}
.dragon-lineage-numbers>span.dragon-lineage-both-selected{
  background:transparent;
  color:#692e3c;
  box-shadow:none
}
.dragon-lineage-selection-summary{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:10px 18px;
  margin-top:16px;
  color:#075e79;
  font:400 16px/1.6 "Kh Content","Khmer UI",sans-serif
}
.dragon-lineage-selection-summary>span{
  padding:5px 14px;
  border-radius:999px;
  background:#f4fbfd
}
.dragon-lineage-prediction{
  width:min(100%,960px);
  margin:22px auto 0;
  padding:20px 24px;
  border:1px solid #9bc8d3;
  border-radius:18px;
  background:rgba(247,252,253,.96);
  color:#111;
  text-align:center;
  box-shadow:0 8px 24px rgba(7,94,121,.08);
  font-family:"Kh Content","Khmer UI",sans-serif
}
.dragon-lineage-prediction h3{
  margin:0 0 10px;
  color:#075e79;
  font-size:21px;
  font-weight:400
}
.dragon-lineage-prediction p{
  margin:0
}
.dragon-lineage-prediction-pair{
  display:inline-block;
  margin-bottom:10px!important;
  padding:5px 16px;
  border-radius:999px;
  background:#fff4d7;
  color:#9a5b00;
  font-size:17px
}
.dragon-lineage-prediction-reading{
  font-size:17px;
  line-height:1.9
}
.dragon-lineage-prediction[data-state="error"] .dragon-lineage-prediction-reading,
.dragon-lineage-prediction[data-state="missing"] .dragon-lineage-prediction-reading{
  color:#b42318
}
@media(min-width:769px){
  body.dragon-lineage-page .auspicious-info-grid,
  body.dragon-lineage-page .auspicious-info-grid :where(
    h3,form,label,input,button,div,table,thead,tbody,tr,th,td,b,strong,span,small,em
  ){
    font-size:16px!important
  }
}
@media(max-width:600px){
  .dragon-lineage-illustration{
    width:100%;
    margin-top:18px
  }
  .dragon-lineage-illustration img{
    border-radius:12px
  }
  .dragon-lineage-numbers>span{
    border-width:0;
    box-shadow:none
  }
  .dragon-lineage-selection-summary{
    margin-top:10px;
    font-size:14px
  }
  .dragon-lineage-prediction{
    margin-top:14px;
    padding:16px 14px;
    border-radius:14px
  }
  .dragon-lineage-prediction h3{
    font-size:18px
  }
  .dragon-lineage-prediction-pair,
  .dragon-lineage-prediction-reading{
    font-size:15px
  }
}

/* About page: clean mobile editorial presentation inspired by the supplied layout. */
body.about-page{
  background:#fff!important;
  color:#8f3525;
  font-family:"Kh Content","Khmer UI",sans-serif
}
.about-page .about-header{
  display:block;
  min-height:0;
  padding:0;
  border:0;
  background:#f8f0ee;
  color:#8f3525;
  overflow:visible
}
.about-page .about-header::before,
.about-page .about-header::after{display:none}
.about-page .about-titlebar{
  position:relative;
  display:grid;
  width:min(100%,760px);
  min-height:94px;
  margin:0 auto;
  place-items:center;
  padding:18px 58px
}
.about-page .about-titlebar h1{
  margin:0;
  color:#8f3525;
  font-family:"AKbalthom Angkor 1 Plus","Kh Content",sans-serif;
  font-size:clamp(26px,4vw,36px);
  font-weight:400;
  line-height:1.4;
  text-align:center
}
.about-page .about-back{
  position:absolute;
  left:18px;
  top:50%;
  color:#6d6864;
  font:300 52px/.7 system-ui,sans-serif;
  text-decoration:none;
  transform:translateY(-50%)
}
.about-page .about-back:hover{color:#8f3525}
.about-page .about-main{
  width:min(100% - 36px,760px);
  margin:0 auto;
  padding:28px 0 38px
}
.about-page .about-portrait{
  width:184px;
  height:184px;
  margin:0 auto 26px;
  overflow:hidden;
  border:2px solid #9e3827;
  border-radius:50%;
  background:#fff
}
.about-page .about-portrait img{
  display:block;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center 38%
}
.about-page .about-surface,
.about-page .about-intro,
.about-page .about-feature,
.about-page .about-disclaimer{
  border:0;
  border-radius:0;
  background:transparent;
  box-shadow:none
}
.about-page .about-intro{
  display:block;
  padding:0
}
.about-page .about-intro-mark{display:none}
.about-page .about-main h2{
  margin:0 0 12px;
  color:#963824;
  font-size:23px;
  font-weight:500;
  line-height:1.55;
  text-align:left
}
.about-page .about-main p,
.about-page .about-main li{
  color:#8f3525;
  font-size:17px;
  line-height:1.9;
  text-align:left
}
.about-page .about-main p{margin:0 0 14px}
.about-page .about-section{padding:24px 0 8px}
.about-page .about-section-heading{
  display:block;
  margin:0 0 12px
}
.about-page .about-section-heading>span,
.about-page .about-section-heading p{display:none}
.about-page .about-feature-grid{
  display:block
}
.about-page .about-feature{
  min-height:0;
  padding:0 0 10px 28px;
  position:relative
}
.about-page .about-feature::before{
  content:"•";
  position:absolute;
  left:6px;
  top:0;
  margin:0;
  color:#c49337;
  font-size:21px
}
.about-page .about-feature b{
  display:inline;
  color:#8f3525;
  font-size:17px;
  font-weight:600
}
.about-page .about-feature p{
  display:inline;
  margin:0;
  font-size:17px
}
.about-page .about-feature p::before{content:" — "}
.about-page .about-two-column{
  display:block;
  margin:18px 0 0
}
.about-page .about-two-column>section{padding:0 0 22px}
.about-page .about-card-label{
  margin:0 0 8px;
  padding:0;
  border-radius:0;
  background:transparent;
  color:#963824;
  font-size:23px;
  font-weight:500
}
.about-page .about-mission ul{
  display:block;
  margin:0;
  padding:0;
  list-style:none
}
.about-page .about-mission li{padding:0 0 7px 28px}
.about-page .about-mission li::before{
  content:"•";
  left:6px;
  color:#c49337
}
.about-page .about-disclaimer{
  display:block;
  padding:0 0 22px
}
.about-page .about-disclaimer-icon{display:none}
.about-page .about-join{
  margin:0;
  padding:0;
  text-align:left
}
.about-page .about-join .about-kicker{
  color:#963824;
  font-size:23px;
  font-weight:500
}
.about-page .about-site-link{
  margin:8px 0 12px;
  border:1px solid #9e3827;
  border-radius:999px;
  background:#fff;
  color:#8f3525;
  padding:9px 18px;
  box-shadow:none
}
.about-page .about-tagline{color:#8f3525;font-weight:500}
.about-page .about-footer{
  display:block;
  margin-top:28px;
  border-top:1px solid #c9bdb8;
  padding:18px 0 0;
  color:#8f3525;
  text-align:left
}
.about-page .about-footer span,
.about-page .about-footer a{
  display:block;
  margin-bottom:5px;
  color:#8f3525
}
@media(max-width:600px){
  .about-page .about-titlebar{min-height:84px}
  .about-page .about-main{width:calc(100% - 34px);padding-top:24px}
  .about-page .about-portrait{width:154px;height:154px;margin-bottom:24px}
  .about-page .about-main h2,
  .about-page .about-card-label,
  .about-page .about-join .about-kicker{font-size:20px}
  .about-page .about-main p,
  .about-page .about-main li,
  .about-page .about-feature b,
  .about-page .about-feature p{font-size:16px}
}

/* About page: single-column document layout, intentionally plain and easy to read. */
body.about-page{
  background:#fff!important;
  color:#111!important
}
.about-page .about-header{
  background:#fff!important;
  border-bottom:1px solid #d8d8d8
}
.about-page .about-titlebar{
  width:min(100% - 32px,980px);
  min-height:76px;
  padding:14px 48px
}
.about-page .about-titlebar h1{
  color:#111!important;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-size:24px;
  font-weight:700
}
.about-page .about-back{
  left:0;
  color:#111
}
.about-page .about-main{
  display:block!important;
  grid-template-columns:1fr!important;
  gap:0!important;
  width:min(100% - 40px,940px);
  padding:30px 0 42px
}
.about-page .about-portrait{display:none}
.about-page .about-main h2,
.about-page .about-card-label,
.about-page .about-join .about-kicker{
  margin:0 0 8px;
  color:#111!important;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-size:19px;
  font-weight:700
}
.about-page .about-main p,
.about-page .about-main li,
.about-page .about-feature b,
.about-page .about-feature p{
  color:#111!important;
  font-family:"Kh Content","Khmer UI",sans-serif;
  font-size:17px;
  line-height:1.85
}
.about-page .about-main p{
  margin:0 0 10px;
  text-align:justify;
  text-indent:2em
}
.about-page .about-section{padding:14px 0 4px}
.about-page .about-section-heading{margin-bottom:6px}
.about-page .about-feature{
  padding:0 0 3px 28px
}
.about-page .about-feature::before,
.about-page .about-mission li::before{
  content:"•";
  color:#111
}
.about-page .about-feature p::before{content:" "}
.about-page .about-two-column{margin-top:8px}
.about-page .about-two-column>section,
.about-page .about-disclaimer{padding:0 0 14px}
.about-page .about-mission li{padding-bottom:3px}
.about-page .about-join{text-align:left}
.about-page .about-join>p{max-width:none}
.about-page .about-site-link{
  margin:4px 0;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
  color:#111!important;
  font-weight:700
}
.about-page .about-footer{
  margin-top:16px;
  border-top:1px solid #bbb;
  color:#111!important
}
.about-page .about-footer span,
.about-page .about-footer a{
  color:#111!important
}
@media(max-width:600px){
  .about-page .about-titlebar{min-height:64px}
  .about-page .about-main{
    width:calc(100% - 30px);
    padding-top:22px
  }
  .about-page .about-titlebar h1{font-size:21px}
  .about-page .about-main h2,
  .about-page .about-card-label,
  .about-page .about-join .about-kicker{font-size:18px}
  .about-page .about-main p,
  .about-page .about-main li,
  .about-page .about-feature b,
  .about-page .about-feature p{font-size:16px}
}

/* About page: orderly Khmer typography and consistent reading rhythm. */
.about-page .about-main{
  width:min(100% - 40px,900px);
  padding:34px 0 48px
}
.about-page .about-main section{
  width:100%;
  margin:0;
  padding:22px 0;
  border-bottom:1px solid #d7d7d7
}
.about-page .about-main section:first-of-type{padding-top:0}
.about-page .about-main section:last-of-type{
  border-bottom:0;
  padding-bottom:0
}
.about-page .about-main h2,
.about-page .about-card-label,
.about-page .about-join .about-kicker{
  display:block;
  margin:0 0 14px;
  padding:0;
  color:#111!important;
  font-size:20px;
  font-weight:700;
  line-height:1.65;
  text-align:left
}
.about-page .about-main p,
.about-page .about-main li,
.about-page .about-feature b,
.about-page .about-feature p{
  color:#111!important;
  font-size:17px;
  line-height:1.9;
  letter-spacing:0;
  word-spacing:0
}
.about-page .about-main p{
  margin:0 0 14px;
  text-align:left;
  text-indent:0
}
.about-page .about-main p:last-child{margin-bottom:0}
.about-page .about-section-heading{margin:0}
.about-page .about-feature-grid{display:block}
.about-page .about-feature{
  display:block;
  min-height:0;
  margin:0;
  padding:5px 0 5px 28px
}
.about-page .about-feature::before{
  top:5px;
  left:7px;
  color:#111
}
.about-page .about-feature b,
.about-page .about-feature p{
  display:inline;
  margin:0
}
.about-page .about-feature p::before{content:" — "}
.about-page .about-two-column{
  display:block;
  margin:0
}
.about-page .about-two-column>section{padding:22px 0}
.about-page .about-mission ul{
  margin:0;
  padding:0;
  list-style:none
}
.about-page .about-mission li{
  margin:0;
  padding:5px 0 5px 28px;
  text-align:left
}
.about-page .about-mission li::before{
  top:5px;
  left:7px;
  color:#111
}
.about-page .about-disclaimer{display:block}
.about-page .about-join{text-align:left}
.about-page .about-site-link{
  display:inline-block;
  margin:4px 0 10px;
  color:#111!important;
  text-decoration:underline;
  text-underline-offset:4px
}
@media(max-width:600px){
  .about-page .about-main{
    width:calc(100% - 32px);
    padding:24px 0 36px
  }
  .about-page .about-main section,
  .about-page .about-two-column>section{padding:18px 0}
  .about-page .about-main h2,
  .about-page .about-card-label,
  .about-page .about-join .about-kicker{
    margin-bottom:10px;
    font-size:18px
  }
  .about-page .about-main p,
  .about-page .about-main li,
  .about-page .about-feature b,
  .about-page .about-feature p{
    font-size:16px;
    line-height:1.85
  }
}
.construction-land-diagram {
  display: none;
}

@media (min-width: 769px) {
  .construction-land-diagram {
    display: block;
    margin-top: 18px;
    color: #075e79;
  }

  .construction-land-canvas {
    box-sizing: border-box;
    min-height: 390px;
    padding: 150px 150px 96px 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
    border: 0;
    background: #fff;
  }

  .construction-land-plot {
    --construction-land-grid-color: #087493;
    --construction-land-grid-line: 1px;
    position: relative;
    box-sizing: border-box;
    flex: 0 0 auto;
    border: 0;
    background-color: transparent;
    background-image: none;
    box-shadow: none;
  }

  .construction-land-mesh {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    z-index: 1;
    pointer-events: none;
  }

  #constructionLandGridLines polyline {
    fill: none;
    stroke: var(--construction-land-grid-color);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
  }

  #constructionLandCells polygon {
    fill: transparent;
    stroke: none;
  }

  .construction-land-cell-labels {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
  }

  .construction-land-cell-labels > span {
    position: absolute;
    transform: translate(-50%, -50%);
    color: #075e79;
    font: 400 16px "Kh Content", "Khmer UI", sans-serif;
    white-space: nowrap;
    text-align: center;
    line-height: 1.2;
    padding: 1px 4px;
    background: rgba(255, 255, 255, 0.92);
    border-radius: 3px;
  }

  .construction-land-cell-labels > span.construction-land-cell-danger {
    color: #c62828;
  }


  .construction-land-front-scale,
  .construction-land-back-scale,
  .construction-land-left-scale,
  .construction-land-right-scale {
    position: absolute;
    z-index: 1;
    display: grid;
    color: #075e79;
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-style: normal;
    font-synthesis: none;
    font-weight: 400;
    line-height: 1;
    pointer-events: none;
  }

  .construction-land-front-scale {
    left: 0;
    top: -40px;
    width: 100%;
    height: 22px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .construction-land-back-scale {
    left: 0;
    bottom: -28px;
    width: 100%;
    height: 22px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .construction-land-left-scale {
    top: 0;
    right: calc(100% + 8px);
    width: 64px;
    height: 100%;
    grid-template-rows: repeat(5, minmax(0, 1fr));
  }

  .construction-land-right-scale {
    top: 0;
    left: calc(100% + 8px);
    width: 64px;
    height: 100%;
    grid-template-rows: repeat(5, minmax(0, 1fr));
  }

  .construction-land-front-scale > span,
  .construction-land-back-scale > span,
  .construction-land-left-scale > span,
  .construction-land-right-scale > span {
    display: flex;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 0;
    white-space: nowrap;
  }

  .construction-land-front-label {
    position: absolute;
    z-index: 3;
    left: var(--land-front-label-left, 50%);
    top: -78px;
    transform: translateX(-50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    white-space: nowrap;
  }

  .construction-land-back-label {
    position: absolute;
    z-index: 3;
    left: var(--land-back-label-left, 50%);
    top: var(--land-back-label-top, 100%);
    transform: translate(-50%, 38px);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    white-space: nowrap;
  }

  .construction-land-left-label {
    position: absolute;
    z-index: 3;
    left: var(--land-left-label-left, 0%);
    top: var(--land-left-label-top, 50%);
    transform: translate(calc(-100% - 104px), -50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    writing-mode: vertical-rl;
    white-space: nowrap;
  }

  .construction-land-right-label {
    position: absolute;
    z-index: 3;
    left: var(--land-right-label-left, 100%);
    top: var(--land-right-label-top, 50%);
    transform: translate(104px, -50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    writing-mode: vertical-rl;
    white-space: nowrap;
  }

  .construction-land-direction-label {
    position: absolute;
    z-index: 4;
    top: -108px;
    left: 50%;
    transform: translateX(-50%);
    color: #075e79;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    white-space: nowrap;
  }



  .construction-land-diagram-hint {
    margin: 0;
    color: #5b6b72;
  }
}

/* Phone/app only: fit the 25-cell land board and its labels to the viewport.
   Desktop web keeps the fixed 16px readable scale. */
@media (max-width: 768px) {
  .construction-land-diagram {
    display: block;
    margin-top: 12px;
    color: #075e79;
  }

  .construction-land-canvas {
    box-sizing: border-box;
    width: 100%;
    height: calc(100dvh - 250px);
    min-height: 220px;
    max-height: 70dvh;
    padding: 58px 42px 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 0;
    background: #fff;
  }

  .construction-land-plot {
    --construction-land-grid-color: #087493;
    --construction-land-grid-line: 1px;
    --construction-land-text-size: 12px;
    --construction-land-scale-size: 12px;
    position: relative;
    box-sizing: border-box;
    flex: 0 0 auto;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .construction-land-mesh {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    z-index: 1;
    pointer-events: none;
  }

  #constructionLandGridLines polyline {
    fill: none;
    stroke: var(--construction-land-grid-color);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
  }

  #constructionLandCells polygon {
    fill: transparent;
    stroke: none;
  }

  .construction-land-cell-labels {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
  }

  .construction-land-cell-labels > span {
    position: absolute;
    transform: translate(-50%, -50%);
    color: #075e79;
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size) !important;
    font-weight: 400;
    white-space: nowrap;
    max-width: none;
    text-align: center;
    line-height: 1.15;
    padding: 0 2px;
    background: rgba(255, 255, 255, 0.92);
    border-radius: 3px;
  }

  .construction-land-cell-labels > span.construction-land-cell-danger {
    color: #c62828;
  }


  .construction-land-front-scale,
  .construction-land-back-scale,
  .construction-land-left-scale,
  .construction-land-right-scale {
    position: absolute;
    z-index: 1;
    display: grid;
    color: #075e79;
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-scale-size, var(--construction-land-text-size));
    font-style: normal;
    font-synthesis: none;
    font-weight: 400;
    line-height: 1;
    pointer-events: none;
  }

  .construction-land-front-scale {
    left: 0;
    top: calc(-1 * (var(--construction-land-scale-size, 12px) + 16px));
    width: 100%;
    height: calc(var(--construction-land-scale-size, 12px) + 6px);
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .construction-land-back-scale {
    left: 0;
    bottom: calc(-1 * (var(--construction-land-scale-size, 12px) + 8px));
    width: 100%;
    height: calc(var(--construction-land-scale-size, 12px) + 6px);
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .construction-land-left-scale {
    top: 0;
    right: calc(100% + 4px);
    width: calc(var(--construction-land-scale-size, 12px) * 3.4);
    height: 100%;
    grid-template-rows: repeat(5, minmax(0, 1fr));
  }

  .construction-land-right-scale {
    top: 0;
    left: calc(100% + 4px);
    width: calc(var(--construction-land-scale-size, 12px) * 3.4);
    height: 100%;
    grid-template-rows: repeat(5, minmax(0, 1fr));
  }

  .construction-land-front-scale > span,
  .construction-land-back-scale > span,
  .construction-land-left-scale > span,
  .construction-land-right-scale > span {
    display: flex;
    box-sizing: border-box;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 0;
    white-space: nowrap;
    font-size: var(--construction-land-scale-size, 10px) !important;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
  }

  .construction-land-front-label {
    position: absolute;
    z-index: 3;
    left: var(--land-front-label-left, 50%);
    top: -52px;
    transform: translateX(-50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    white-space: nowrap;
  }

  .construction-land-back-label {
    position: absolute;
    z-index: 3;
    left: var(--land-back-label-left, 50%);
    top: var(--land-back-label-top, 100%);
    transform: translate(-50%, 24px);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    white-space: nowrap;
  }

  .construction-land-left-label {
    position: absolute;
    z-index: 3;
    left: var(--land-left-label-left, 0%);
    top: var(--land-left-label-top, 50%);
    transform: translate(calc(-100% - 44px), -50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    writing-mode: vertical-rl;
    white-space: nowrap;
  }

  .construction-land-right-label {
    position: absolute;
    z-index: 3;
    left: var(--land-right-label-left, 100%);
    top: var(--land-right-label-top, 50%);
    transform: translate(44px, -50%);
    font-family: "Kh Content", "Khmer UI", sans-serif;
    font-size: var(--construction-land-text-size);
    font-weight: 400;
    writing-mode: vertical-rl;
    white-space: nowrap;
  }

  .construction-land-direction-label {
    position: absolute;
    z-index: 4;
    top: -72px;
    left: 50%;
    transform: translateX(-50%);
    color: #075e79;
    font-size: var(--construction-land-text-size) !important;
    white-space: nowrap;
  }



  .construction-land-diagram-hint {
    margin: 0;
    color: #5b6b72;
  }
}

@media (max-width: 768px) {
  .construction-land-front-scale,
  .construction-land-back-scale,
  .construction-land-left-scale,
  .construction-land-right-scale {
    font-size: var(--construction-land-scale-size, var(--construction-land-text-size)) !important;
  }

  .construction-land-front-label,
  .construction-land-back-label,
  .construction-land-left-label,
  .construction-land-right-label {
    font-size: var(--construction-land-text-size) !important;
  }
}
/* Construction plot always has exactly 25 cells as a true 5x5 trapezoid mesh. */
#constructionLandPlot .construction-land-mesh {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  z-index: 1;
}

#constructionLandPlot,
#constructionLandPlot::before,
#constructionLandPlot::after {
  background-image: none !important;
}


.ephemeris-tool-navigation {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 0 auto 28px;
}

.ephemeris-tool-navigation a {
  display: inline-flex;
  box-sizing: border-box;
  flex: 1 1 190px;
  max-width: 240px;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  border: 1px solid #8ebdca;
  border-radius: 999px;
  background: #fff;
  color: #17667d;
  font: 400 16px "Kh Content", "Khmer UI", sans-serif;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 7px 15px #174f5d1c;
  transition: transform .18s ease, background-color .18s ease, box-shadow .18s ease;
}

.ephemeris-tool-navigation a:hover {
  background: #eaf7fa;
  box-shadow: 0 9px 18px #174f5d29;
  transform: translateY(-1px);
}

.ephemeris-tool-navigation a[aria-current="page"] {
  border-color: #17667d;
  background: #f2fbfd;
}

.ephemeris-tool-navigation .tool-navigation-close,
.tool-navigation-backdrop {
  display: none;
}

@media (min-width: 1100px) {
  body:has(main > section > .ephemeris-tool-navigation) .global-home-button {
    min-height: 48px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  main > section:has(> .ephemeris-tool-navigation) {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    column-gap: 0;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation {
    grid-column: 1;
    grid-row: 1 / span 100;
    width: 240px;
    margin: 0;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: flex-start;
    align-self: start;
    position: fixed;
    top: 14px;
    left: 132px;
    z-index: 100;
    padding: 0;
    border-radius: 24px;
    overflow: visible;
    transition: width .24s ease, box-shadow .24s ease, background-color .24s ease;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation:not(.is-collapsed) {
    padding: 0;
    background: transparent;
    box-shadow: none;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation.is-collapsed {
    width: 190px;
    gap: 0;
  }

  main > section:has(> .ephemeris-tool-navigation.is-collapsed) {
    grid-template-columns: minmax(0, 1fr);
  }

  .ephemeris-tool-navigation .tool-navigation-toggle {
    display: inline-flex;
    box-sizing: border-box;
    width: 100%;
    min-height: 48px;
    margin: 0;
    padding: 8px 14px;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    border: 1px solid #17667d;
    border-radius: 24px;
    background: #f2fbfd;
    color: #17667d;
    font: 400 16px "Kh Content", "Khmer UI", sans-serif;
    white-space: nowrap;
    cursor: pointer;
  }

  .ephemeris-tool-navigation .tool-navigation-toggle span {
    width: 19px;
    flex: 0 0 19px;
    font: 400 21px/1 "Segoe UI Symbol", sans-serif;
    text-align: center;
  }

  .ephemeris-tool-navigation.is-collapsed .tool-navigation-toggle {
    padding: 8px 13px;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation a {
    width: 100%;
    max-width: none;
    flex: 0 0 auto;
    transition: min-height .2s ease, padding .2s ease, opacity .16s ease, transform .2s ease;
  }

  main > section:has(> .construction-tool-navigation) > .construction-tool-navigation button:not(.tool-navigation-toggle) {
    width: 100%;
    max-width: none;
    flex: 0 0 auto;
    transition: min-height .2s ease, padding .2s ease, opacity .16s ease, transform .2s ease;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation.is-collapsed a {
    min-height: 0;
    height: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(-24px);
    overflow: hidden;
  }

  main > section:has(> .construction-tool-navigation) > .construction-tool-navigation.is-collapsed button:not(.tool-navigation-toggle) {
    min-height: 0;
    height: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(-24px);
    overflow: hidden;
  }

  main > section:has(> .ephemeris-tool-navigation) > :not(.ephemeris-tool-navigation) {
    grid-column: 1;
    min-width: 0;
  }
}

@media (max-width: 1099px) {
  body:has(main > section > .ephemeris-tool-navigation) .global-home-button {
    min-height: 44px;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation {
    position: fixed;
    top: 14px;
    left: 132px;
    z-index: 10001;
    display: flex;
    width: min(240px, calc(100vw - 150px));
    margin: 0;
    padding: 0;
    flex-direction: column;
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 8px;
    border-radius: 22px;
    background: transparent;
    box-shadow: none;
    overflow: visible;
  }

  .ephemeris-tool-navigation .tool-navigation-toggle {
    display: inline-flex;
    box-sizing: border-box;
    width: 100%;
    min-height: 44px;
    margin: 0;
    padding: 7px 13px;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    border: 1px solid #17667d;
    border-radius: 22px;
    background: #f2fbfd;
    color: #17667d;
    font: 400 16px "Kh Content", "Khmer UI", sans-serif;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 7px 22px #1a485024;
  }

  .ephemeris-tool-navigation .tool-navigation-toggle span {
    width: 19px;
    flex: 0 0 19px;
    font: 400 21px/1 "Segoe UI Symbol", sans-serif;
    text-align: center;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation a {
    width: 100%;
    max-width: none;
    flex: 0 0 auto;
    transition: min-height .2s ease, padding .2s ease, opacity .16s ease, transform .2s ease;
  }

  main > section:has(> .construction-tool-navigation) > .construction-tool-navigation button:not(.tool-navigation-toggle) {
    width: 100%;
    max-width: none;
    flex: 0 0 auto;
    transition: min-height .2s ease, padding .2s ease, opacity .16s ease, transform .2s ease;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation.is-collapsed {
    gap: 0;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation.is-collapsed a {
    min-height: 0;
    height: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(-24px);
    overflow: hidden;
  }

  main > section:has(> .construction-tool-navigation) > .construction-tool-navigation.is-collapsed button:not(.tool-navigation-toggle) {
    min-height: 0;
    height: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateX(-24px);
    overflow: hidden;
  }
}

@media (max-width: 800px) {
  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation {
    top: auto;
    right: 12px;
    bottom: calc(77.3px + env(safe-area-inset-bottom, 0px));
    left: 12px;
    width: auto;
    max-height: calc(100dvh - 104px);
    padding: 8px;
    overflow-x: hidden;
    overflow-y: auto;
    border: 1px solid #b9d6de;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 -9px 28px #163f4a2e;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity .2s ease, visibility .2s ease, transform .24s ease;
  }

  main > section:has(> .ephemeris-tool-navigation) > .ephemeris-tool-navigation.is-collapsed {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(18px);
  }

  .ephemeris-tool-navigation .tool-navigation-close {
    display: inline-flex;
    box-sizing: border-box;
    width: 100%;
    min-height: 44px;
    margin: 0 0 4px;
    padding: 7px 13px;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    border: 1px solid #17667d;
    border-radius: 22px;
    background: #f2fbfd;
    color: #17667d;
    font: 400 16px "Kh Content", "Khmer UI", sans-serif;
    white-space: nowrap;
    cursor: pointer;
  }

  .ephemeris-tool-navigation .tool-navigation-close span {
    width: 19px;
    flex: 0 0 19px;
    font: 400 24px/1 "Segoe UI Symbol", sans-serif;
    text-align: center;
  }

  .ephemeris-tool-navigation.is-collapsed .tool-navigation-close {
    display: none;
  }

  .tool-navigation-backdrop {
    position: fixed;
    inset: 0;
    z-index: 10000;
    margin: 0;
    padding: 0;
    border: 0;
    background: #14242e66;
    cursor: pointer;
  }

  .tool-navigation-backdrop[hidden] {
    display: none !important;
  }

  body.tool-navigation-open {
    overflow: hidden;
  }

  body:has(main > section > .ephemeris-tool-navigation) .mobile-bottom-nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  body:has(main > section > .ephemeris-tool-navigation) .mobile-bottom-nav > .tool-navigation-toggle {
    display: grid !important;
    box-sizing: border-box;
    min-width: 0 !important;
    min-height: 55.3px !important;
    height: 55.3px !important;
    margin: 0 !important;
    padding: 0 1.7px !important;
    place-items: center;
    align-content: center;
    gap: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: #176879 !important;
    font: 400 12.1px/1 "Kh Content", "Khmer UI", sans-serif !important;
    box-shadow: none !important;
  }

  body:has(main > section > .ephemeris-tool-navigation) .mobile-bottom-nav > .tool-navigation-toggle span {
    width: auto;
    height: auto;
    flex: none;
    font: 400 19px/1 "Segoe UI Symbol", sans-serif !important;
  }

  body:has(main > section > .ephemeris-tool-navigation) .mobile-bottom-nav > .tool-navigation-toggle b {
    font: inherit;
    font-weight: 400;
  }

  body:has(main > section > .ephemeris-tool-navigation) .mobile-bottom-nav > .tool-navigation-toggle[aria-expanded="true"] {
    color: #176879 !important;
  }
}

/* Attha prediction action matches the authenticated Home button typography
   and colour treatment. */
.atta-prediction-card .ancient-form button{
  border:1px solid rgba(23,104,121,.45)!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.94)!important;
  color:#176879!important;
  font:400 14px "Kh Content","Khmer UI",sans-serif!important;
  box-shadow:0 7px 22px rgba(26,72,80,.14)!important
}
.atta-prediction-card .ancient-form button:hover,
.atta-prediction-card .ancient-form button:focus-visible{
  background:#176879!important;
  color:#fff!important;
  border-color:#176879!important;
  outline:0
}

/* Attha calculator and generated tables use the Home button's type scale and
   blue-green palette instead of the legacy black/beige table theme. */
body[data-ancient-view="atta"] .ancient-card :where(
  h2,p,label,input,select,button,
  .ancient-results,.ancient-overview-table,
  .ancient-overview-table>*,.atta-table-card,
  .atta-table-card h3,.atta-source-table,
  .atta-source-table tr,.atta-source-table td,
  .atta-source-table span,.atta-source-table strong
){
  color:#176879!important;
  font-family:"Kh Content","Khmer UI",sans-serif!important;
  font-size:14px!important;
  font-weight:400!important
}
body[data-ancient-view="atta"] .ancient-form input,
body[data-ancient-view="atta"] .ancient-form select{
  border:1px solid rgba(23,104,121,.45)!important;
  border-radius:999px!important;
  background:#fff!important;
  box-shadow:inset 0 1px 2px rgba(23,79,93,.05)!important
}
body[data-ancient-view="atta"] .ancient-form button{
  border:1px solid rgba(23,104,121,.45)!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.94)!important;
  color:#176879!important;
  font:400 14px "Kh Content","Khmer UI",sans-serif!important;
  box-shadow:0 7px 22px rgba(26,72,80,.14)!important
}
body[data-ancient-view="atta"] .ancient-form button:hover,
body[data-ancient-view="atta"] .ancient-form button:focus-visible{
  border-color:#176879!important;
  background:#176879!important;
  color:#fff!important;
  outline:0
}
body[data-ancient-view="atta"] .ancient-overview-table,
body[data-ancient-view="atta"] .atta-table-card{
  overflow:hidden;
  border:1px solid rgba(23,104,121,.45)!important;
  border-radius:18px!important;
  background:#fff!important;
  box-shadow:0 7px 22px rgba(26,72,80,.14)!important
}
body[data-ancient-view="atta"] .ancient-overview-table>*,
body[data-ancient-view="atta"] .atta-source-table td{
  border-color:#d4e9ee!important;
  background:#fff!important
}
body[data-ancient-view="atta"] .ancient-overview-table .overview-title,
body[data-ancient-view="atta"] .atta-table-card>h3,
body[data-ancient-view="atta"] .atta-label-row td,
body[data-ancient-view="atta"] .atta-cycle-note{
  border-color:#d4e9ee!important;
  background:#f2fbfd!important;
  color:#176879!important;
  text-shadow:none!important;
  box-shadow:none!important
}
body[data-ancient-view="atta"] .ancient-overview-table .overview-label,
body[data-ancient-view="atta"] .atta-cycle-value-row td{
  background:#f7fcfd!important
}
body[data-ancient-view="atta"] .atta-age-label{
  background:#f2fbfd!important;
  color:#176879!important;
  box-shadow:inset 0 0 0 2px #8ebdca!important
}
body[data-ancient-view="atta"] .atta-age-circle,
body[data-ancient-view="atta"] .atta-cycle-planet{
  border-color:#176879!important;
  color:#176879!important;
  box-shadow:0 0 0 2px #d9f0f5!important
}

/* FINAL ephemeris print kill-switch (file end): hide every floating credit/nav chrome.
   Companion to mobile-app.css end block — covers cases where overrides load alone. */
@media print{
  .global-home-button,
  .app-auth-bar,
  .mobile-bottom-nav,
  body>.creator-footer,
  body:not(.auth-page)>.creator-footer,
  body:not(.auth-page) .mobile-bottom-nav>.creator-footer,
  .creator-footer{
    display:none!important;
    visibility:hidden!important;
    position:static!important
  }
  .ephemeris-print-credit{
    display:block!important;
    position:static!important;
    visibility:visible!important
  }
}

/* retrograde-calendar-v1 */
.retrograde-page{display:block;max-width:1100px}
.retrograde-card{padding:22px;background:#fff;border:1px solid #171717}
.retrograde-card h2{text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:18px;color:#17667d}
.retrograde-card>p{text-align:center;margin:5px 0 16px;font-family:"Kh Content",sans-serif;color:#536669}
.retrograde-toolbar{display:flex;flex-wrap:wrap;gap:12px;align-items:center;justify-content:space-between;margin:0 0 10px}
.retrograde-year-nav{display:flex;gap:6px;flex-wrap:wrap}
.retrograde-year-nav a{display:inline-block;padding:7px 12px;border:1px solid #8ebdca;border-radius:999px;text-decoration:none;color:#17667d;background:#fff;font-family:"Kh Content",sans-serif}
.retrograde-year-nav a[aria-current="page"]{background:#17667d;color:#fff;border-color:#17667d}
.retrograde-year-nav .retrograde-year-disabled{display:inline-block;padding:7px 12px;border:1px solid #d4e9ee;border-radius:999px;color:#8aa8b0;background:#f7fbfc;font-family:"Kh Content",sans-serif;opacity:.55}
.retrograde-frame{display:grid;gap:4px;font-family:"Kh Content",sans-serif;color:#17667d}
.retrograde-frame select{border:1px solid #8ebdca;border-radius:999px;background:#fff;color:#17667d;padding:8px 12px;font:400 14px "Kh Content","Khmer UI",sans-serif}
.retrograde-timezone{margin:0 0 14px!important;font-family:"Kh Content",sans-serif;color:#17667d!important}
.retrograde-results{margin:12px 0 18px}
.retrograde-section{margin:0 0 18px}
.retrograde-section h3{margin:0 0 8px;text-align:center;font-family:"Kh Content","Khmer UI",sans-serif;font-weight:400;font-synthesis:none;font-size:15px;color:#17667d}
.retrograde-empty{text-align:center;font-family:"Kh Content",sans-serif;color:#555}
.retrograde-table-wrap{overflow:auto;border:1px solid #8ebdca;border-radius:18px;background:#fff;box-shadow:0 7px 15px #174f5d1c}
.retrograde-table-wrap table{width:100%;min-width:720px;border-collapse:collapse;table-layout:fixed;font:400 16px/1.4 "Kh Content","Khmer UI",sans-serif}
.retrograde-table-wrap th{background:#f2fbfd;color:#17667d;border-bottom:1px solid #d4e9ee;padding:9px 8px;text-align:left;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.retrograde-table-wrap td{border-top:1px solid #e7f3f6;padding:9px 8px;vertical-align:middle;color:#17667d;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.retrograde-table-wrap :is(th,td,b,small,a,span){font-size:16px!important}
.retrograde-table-wrap td br{display:none}
.retrograde-planet{display:flex;min-width:0;align-items:center;gap:6px;overflow:hidden;white-space:nowrap}
.retrograde-planet b{font-weight:400;font-family:"Kh Content","Khmer UI",sans-serif}
.retrograde-planet b,.retrograde-planet small{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.retrograde-planet small,.retrograde-table-wrap small{color:#536669}
.retrograde-planet .planet-glyph{font-size:16px;line-height:1}
.retrograde-days{white-space:nowrap;font-weight:700;color:#d82121}
.retrograde-impact{color:#d96b00;text-decoration:none;font-family:"Kh Content",sans-serif}
.retrograde-impact:hover{text-decoration:underline}
@media(max-width:700px){.retrograde-toolbar{flex-direction:column;align-items:stretch}.retrograde-frame select{width:100%}}

.annual-eclipse-page .retrograde-table-wrap :is(th,td){text-align:center}
@media(max-width:700px){
  .annual-eclipse-page .retrograde-year-nav{justify-content:center}
  .annual-eclipse-page .retrograde-card{padding:14px 10px}
  .annual-eclipse-page .retrograde-table-wrap{overflow:hidden}
  .annual-eclipse-page .retrograde-table-wrap table{width:100%;min-width:0}
  .annual-eclipse-page .retrograde-table-wrap :is(th,td){padding:7px 3px;white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere}
  .annual-eclipse-page .retrograde-table-wrap :is(th,td,b,small,a,span){font-size:12px!important;line-height:1.35}
  .annual-eclipse-page .retrograde-table-wrap :is(th,td):nth-child(1){width:35%}
  .annual-eclipse-page .retrograde-table-wrap :is(th,td):nth-child(2){width:25%}
  .annual-eclipse-page .retrograde-table-wrap :is(th,td):nth-child(3){width:40%}
}
@media(max-width:700px){
  .lunar-eclipse-page .kalayog-annual-toolbar{padding:16px 12px 12px}
  .lunar-eclipse-page .kalayog-annual-controls,
  .lunar-eclipse-page .kalayog-annual-toolbar .retrograde-year-nav{justify-content:center}
}

/* retrograde-transit-wheel-v1 */
.retrograde-transit{margin:14px 0 22px;padding:18px;background:#f7f7f7;border:1px solid #d4d4d4;border-radius:12px;text-align:center;color:#171717;font-family:Arial,sans-serif}
.retrograde-transit h3{margin:0 0 3px;font-size:19px;color:#171717;font-family:Arial,sans-serif;font-weight:700}
.retrograde-transit>p{margin:0 0 12px;color:#555;font-size:13px}
.retrograde-wheel{display:block;width:min(100%,620px);height:auto;margin:0 auto;background:#fff;filter:drop-shadow(0 5px 12px #00000018)}
.retrograde-wheel-back{display:inline-block;margin:0 0 12px;color:#17667d;text-decoration:none;font-family:"Kh Content",sans-serif}.retrograde-wheel-back:hover{text-decoration:underline}
.retrograde-wheel-backdrop{fill:#fff;stroke:#171717;stroke-width:1.6}.retrograde-wheel-zodiac{fill:#fff;stroke:#171717;stroke-width:1.6}.retrograde-wheel-tick{stroke:#333;stroke-width:.55}.retrograde-wheel-tick.is-major{stroke-width:1.4}.retrograde-wheel-division{stroke:#171717;stroke-width:1.5}.retrograde-wheel-sign{font:27px "Segoe UI Symbol","Noto Sans Symbols2",sans-serif;text-anchor:middle;dominant-baseline:middle}.retrograde-wheel-aspect{stroke-width:1;opacity:.85}.retrograde-wheel-motion{fill:none;stroke:#e33b31;stroke-width:3;stroke-linecap:round}.retrograde-wheel-start{fill:#fff;stroke:#e33b31;stroke-width:2}.retrograde-wheel-end{fill:#e33b31;stroke:#fff;stroke-width:1.5}.retrograde-wheel-marker circle{fill:#5d9429;stroke:#fff;stroke-width:1.2}.retrograde-wheel-marker.is-selected circle{fill:#e33b31}.retrograde-wheel-marker text{fill:#fff;font:10px "Segoe UI Symbol","Noto Sans Symbols2",sans-serif;text-anchor:middle}.retrograde-wheel-center{fill:#fff;stroke:#171717;stroke-width:1}.retrograde-wheel-planet{font:34px "Segoe UI Symbol","Noto Sans Symbols2",sans-serif;text-anchor:middle}.retrograde-wheel-title{font:700 21px Arial,sans-serif;text-anchor:middle}.retrograde-wheel-detail{font:700 12px Arial,sans-serif;text-anchor:middle}.retrograde-wheel-date,.retrograde-wheel-timezone{font:12px Arial,sans-serif;text-anchor:middle}.retrograde-wheel-loading,.retrograde-wheel-error{padding:24px 8px;margin:0;color:#555;font-family:"Kh Content",sans-serif}.retrograde-wheel-error{color:#a31d1d}
@media(max-width:560px){.retrograde-transit{padding:10px}.retrograde-wheel{width:calc(100vw - 42px)}.retrograde-wheel-sign{font-size:24px}}

/* Ephemeris now fixes its calculation time at 00:00 UT. */
.ephemeris-form{grid-template-columns:repeat(2,minmax(0,1fr)) minmax(180px,1fr) auto}
.ephemeris-page.is-khmer .ephemeris-form{grid-template-columns:repeat(2,minmax(0,1fr)) auto}
.ephemeris-page.is-khmer .ephemeris-frame{display:none}

/* Place the active travelling age directly on its Attha house. */
.atta-prediction-page .atta-source-table .atta-age-house{
  background:#f2fbfd!important;
  box-shadow:inset 0 0 0 2px #8ebdca!important;
  vertical-align:middle
}
.atta-prediction-page .atta-age-house-name{display:block}
.atta-prediction-page .atta-age-house-marker{
  display:inline-block;
  margin-top:4px;
  color:#c62828!important;
  font-size:13px!important;
  font-weight:400!important;
  line-height:1.3;
  white-space:nowrap
}
.atta-prediction-page .atta-source-table .atta-age-planet-match{
  background:#fff1f1!important;
  box-shadow:inset 0 0 0 1px #ef9a9a!important
}
.atta-prediction-page .atta-source-table .atta-age-circle{
  display:inline-flex;
  min-width:28px;
  height:28px;
  padding:0 5px;
  align-items:center;
  justify-content:center;
  border:2px solid #c62828!important;
  border-radius:50%;
  color:#c62828!important;
  font-size:16px!important;
  font-weight:400!important;
  line-height:1;
  box-shadow:0 0 0 2px #ffe0e0!important
}

/* Keep each Attha input, information, and reference panel at one readable width. */
@media(min-width:701px){
  .atta-prediction-card .ancient-form{
    grid-template-columns:repeat(4,minmax(150px,1fr));
    max-width:1040px;
    margin-inline:auto
  }
  .atta-prediction-card .ancient-form label{
    display:grid;
    grid-template-columns:44px minmax(0,1fr);
    align-items:center;
    gap:8px;
    text-align:left
  }
  .atta-prediction-card .ancient-form :is(input,select){
    width:100%
  }
  .atta-prediction-card .ancient-form button{
    grid-column:3/-1;
    width:100%
  }
  .atta-prediction-page .atta-prediction-results{justify-items:center}
  .atta-prediction-page .atta-prediction-results>*{
    width:min(1040px,100%);
    box-sizing:border-box;
    margin-inline:auto
  }
  .atta-prediction-page .atta-birth-info{overflow-x:auto}
  .atta-prediction-page .atta-birth-summary.ancient-overview-table{
    grid-template-columns:repeat(6,minmax(0,1fr));
    width:100%;
    min-width:0;
    box-sizing:border-box
  }
  .atta-prediction-page .atta-source-table{width:100%;min-width:0}
  .atta-prediction-page .atta-matter-picker-label{
    grid-template-columns:max-content minmax(0,1fr)
  }
  .atta-prediction-page .atta-matter-picker-label select{max-width:none}
  .atta-prediction-page #attaMatterReading{width:100%}
  .atta-prediction-page .atta-matter-reading{
    width:100%;
    box-sizing:border-box;
    margin:14px 0 0
  }
}

/* Use one readable type scale throughout the Attha prediction content. */
.atta-prediction-page .atta-prediction-card,
.atta-prediction-page .atta-prediction-card *{font-size:16px!important}

/* Give the planetary-strength rows their own warm colour treatment. */
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-label-row td{
  background:#ffe4a3!important;
  color:#7c4700!important;
  box-shadow:inset 0 1px 0 #d79b21,inset 0 -1px 0 #d79b21!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-value-row td{
  background:#fff4cf!important;
  color:#875000!important;
  box-shadow:inset 0 -1px 0 #efd48b!important
}

/* Keep the Attha source table neutral, except for the planetary-strength rows. */
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td{
  background:#fff!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-label-row td{
  background:#ffe4a3!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-value-row td{
  background:#fff4cf!important
}

/* Remove every other table surface colour, including the title and row layers. */
.atta-prediction-page .atta-table-card.atta-restored-table,
.atta-prediction-page .atta-table-card.atta-restored-table>h3,
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table,
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table tr,
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td{
  background:#fff!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-label-row td{
  background:#ffe4a3!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-strength-value-row td{
  background:#fff4cf!important
}

/* Related numbers keep a circle; only the active travelling-age position is filled. */
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td.atta-age-planet-match{
  background:#fff!important;
  box-shadow:none!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td.atta-age-planet-match .atta-age-circle{
  background:#fff!important;
  border-color:#d7191c!important;
  color:#d7191c!important;
  box-shadow:0 0 0 2px #ffe0e0!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td.atta-age-current{
  background:#fff0c9!important;
  color:#9b3d00!important;
  box-shadow:inset 0 0 0 2px #d97706!important
}
.atta-prediction-page .atta-table-card.atta-restored-table .atta-source-table td.atta-age-current .atta-age-circle{
  background:#9b3d00!important;
  border-color:#9b3d00!important;
  color:#fff!important;
  box-shadow:0 0 0 2px #ffe0a3!important
}

/* Keep the Attha input panel compact in two equal desktop rows. */
@media(min-width:801px){
  body[data-ancient-view] .ancient-page .ancient-card .ancient-form{
    grid-template-columns:repeat(4,minmax(0,1fr));
    max-width:1040px;
    margin-inline:auto
  }
  body[data-ancient-view] .ancient-page .ancient-card .ancient-form button{
    grid-column:3/-1;
    width:100%
  }
}

/* Keep every ancient-astrology result panel on the same readable desktop width. */
@media(min-width:701px){
  body[data-ancient-view] .ancient-results{
    width:min(1040px,100%);
    margin-inline:auto
  }
}

/* Keep the main calculator controls on one shared centered desktop axis. */
@media(min-width:1101px){
  .ancient-page .ancient-form,
  .atta-prediction-page .ancient-form,
  .mundane-page .mundane-form,
  .reference-page .moon-form,
  .ephemeris-page .ephemeris-form,
  .transit-page .transit-form{
    width:min(1040px,100%);
    margin-inline:auto
  }
}
