/* Gayatri Jewellers – premium cream & gold 16:9 rate display.
   UI ONLY: backend, API, SSE, admin panel and display.js are unmodified.
   Rate cards are generated by the existing display.js exactly as before. */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;500;600;700&family=Jost:wght@300;400;500;600&display=swap');
:root{--ink:#321c10;--gold:#ac751a;--brown:#593a23;--muted:#755138;--up:#138045;--down:#ab252a}
*{box-sizing:border-box}
html,body{margin:0;min-height:100%;width:100%}
html{background:#2a2018}
body{height:100vh;min-height:100vh;display:flex;align-items:center;justify-content:center;overflow:hidden;color:var(--ink);font-family:'Jost','Segoe UI',Arial,sans-serif;font-variant-numeric:tabular-nums lining-nums}
.board{width:min(100vw,177.77778vh);height:min(100vh,56.25vw);aspect-ratio:16/9;position:relative;isolation:isolate;overflow:hidden;container-type:size;
background:radial-gradient(ellipse at 49% 18%,#fff6eb 0%,#efdbc6 43%,#d4b593 85%,#b99065 120%);box-shadow:0 0 6vw #0a030444}
.board::before{content:'';position:absolute;inset:0;pointer-events:none;z-index:0;background:linear-gradient(130deg,transparent 0 10%,#fff8eb9a 24%,transparent 32%,transparent 58%,#fff5e36b 76%,transparent 84%),radial-gradient(ellipse at 50% 105%,#b68e62aa,transparent 57%)}
.board::after{content:'';position:absolute;inset:0;z-index:9;pointer-events:none;border:1px solid #b5813a30;box-shadow:inset 0 0 5cqw #60350e13}
.wood{position:absolute;left:0;top:0;width:7.8%;height:78%;z-index:0;opacity:.78;background:repeating-linear-gradient(90deg,#4b2a12 0 1.1cqw,#2c190f 1.15cqw 1.55cqw,#79502b 1.6cqw 1.78cqw);box-shadow:inset -2.3cqw 0 2.2cqw #d6a97b,1.5cqw 0 2.5cqw #6d401b50;-webkit-mask-image:linear-gradient(to bottom,#000 0 62%,transparent 100%);mask-image:linear-gradient(to bottom,#000 0 62%,transparent 100%)}
.arch{position:absolute;left:9%;top:-20%;height:88%;width:13%;border-left:.52cqw solid #cc99493d;border-radius:50%;transform:rotate(11deg);box-shadow:-.8cqw 0 1cqw #fff8e144;z-index:0}
.ray{position:absolute;width:77%;height:12%;top:14%;left:7%;transform:rotate(-27deg);transform-origin:0 0;background:linear-gradient(180deg,transparent,#fff7e669,transparent);filter:blur(2cqw);opacity:.54;pointer-events:none;z-index:0}
.floor{position:absolute;bottom:0;width:100%;height:11%;z-index:0;background:linear-gradient(0deg,#e7c9a3,#f4e5d2b9 35%,transparent 100%);box-shadow:0 -1px #e8d6b1a0}
.decor{position:absolute;z-index:1;pointer-events:none;background-repeat:no-repeat;background-size:contain;}
.decor.bangles{left:-.6%;bottom:-1.5%;width:24%;height:34%;background-image:url('../img/decor_bangles.webp');background-position:left bottom}
.decor.bars{right:11%;bottom:-1.5%;width:20%;height:21%;background-image:url('../img/decor_gold_bars.webp');background-position:center bottom}
.decor.silver-bowl{right:-1%;bottom:-1.5%;width:20%;height:29%;background-image:url('../img/decor_silver_bowl.webp');background-position:right bottom}
.decor.leaves{right:-1%;top:-1%;width:25%;height:35%;background-image:url('../img/decor_leaves.webp');background-position:right top;opacity:.72}
/* Brand masthead matches the previous showroom design. */
.top{position:absolute;z-index:4;top:.65%;left:0;width:100%;height:29%;text-align:center}
.shop-logo{position:absolute;display:block;width:13%;height:39%;top:0;left:43.5%;object-fit:contain;filter:drop-shadow(0 .2cqw .22cqw #8c571b28)}
.brand{position:absolute;left:0;right:0;top:39%}
.brand h1{font-family:'Cormorant Garamond',Georgia,serif;font-size:3.14cqw;line-height:1.06;letter-spacing:.29cqw;font-weight:600;margin:0;text-shadow:0 .12cqw .3cqw #fff5e4;color:#321d12;white-space:nowrap}
.brand h1::before,.brand h1::after{content:'';display:inline-block;width:6.5cqw;height:1px;vertical-align:middle;margin:0 1.1cqw .9cqw;background:linear-gradient(90deg,transparent,#b27d25)}
.brand h1::after{transform:rotate(180deg)}
.brand p{margin:.75cqw 0 0;font-size:1.1cqw;letter-spacing:.34cqw;font-weight:500;white-space:nowrap;color:#473020}
.brand p span{font-size:.75em;color:#5a3620;padding:0 .3cqw}
.when{position:absolute;top:84%;width:100%;left:0;text-align:center;display:flex;align-items:center;flex-direction:column;gap:.3cqw}
.date-pill{display:flex;align-items:center;justify-content:center;gap:.75cqw;height:3.15cqw;min-width:28%;border:.12cqw solid #4d2d1c;border-radius:20cqw;background:#ffefdc60;box-shadow:inset 0 .15cqw .7cqw #fff9f6aa;padding:0 1.2cqw;white-space:nowrap}
.date-pill svg{width:1.75cqw;height:1.75cqw;flex:none}
#date{font-family:'Cormorant Garamond',Georgia,serif;font-weight:600;letter-spacing:.09cqw;font-size:1.55cqw;text-transform:uppercase}
.clock{font-size:.78cqw;letter-spacing:.16cqw;color:#7a5437;line-height:1.1;font-weight:500}
.heading{position:absolute;z-index:3;top:30.5%;left:0;width:100%;text-align:center;font-family:'Cormorant Garamond',Georgia,serif;font-weight:600;font-size:6.55cqw;line-height:1;letter-spacing:-.16cqw;text-shadow:0 .15cqw .25cqw #fff5e5}
.subheading{position:absolute;z-index:3;top:39%;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:2.6cqw;color:#a66c16;font-family:'Cormorant Garamond',Georgia,serif;font-size:6.1cqw;line-height:1;font-weight:500;white-space:nowrap}
.subheading::before,.subheading::after{content:'';width:14cqw;height:.11cqw;background:linear-gradient(90deg,transparent,#ba7a16 40%,#ba7a16 90%,transparent)}
.subheading::after{transform:rotate(180deg)}
/* Existing renderer injects .card / .name / .value / .unit / .delta and sets --cols. */
.cards{position:absolute;z-index:4;top:47%;left:11.1%;width:77.8%;height:34.5%;display:grid;grid-template-columns:repeat(var(--cols,5),minmax(0,1fr));gap:1.2cqw;align-items:stretch;justify-content:center;min-height:0}
.card{position:relative;min-width:0;min-height:0;display:block;background: url('../img/frame_gold.svg') center/100% 100% no-repeat;filter:drop-shadow(0 .25cqw .4cqw #663b1631);transition:transform .35s ease,filter .35s ease;isolation:isolate}
.card:hover{transform:translateY(-.5cqw);filter:drop-shadow(0 .55cqw .7cqw #70421665)}
.card#c-silver{background-image:url('../img/frame_silver.svg')}
.card .name{position:absolute;top:0;left:0;width:100%;height:100%;font-size:0;color:transparent;line-height:0;pointer-events:none}
.card .name small{display:none}
.card .name::before{content:'';position:absolute;left:12%;top:8.5%;width:76%;height:32%;display:block;background-repeat:no-repeat;background-position:center;background-size:contain;filter:drop-shadow(0 .17cqw .1cqw #5e39052e);transition:transform .35s ease}
.card:hover .name::before{transform:translateY(-.12cqw) scale(1.055)}
#c-gold24 .name::before{background-image:url('../img/24kt_gold_bars.png')}
#c-gold22 .name::before{background-image:url('../img/22ct_rings.png')}
#c-gold20 .name::before{background-image:url('../img/20ct_bangles.png');top:6%;height:37%}
#c-gold18 .name::before{background-image:url('../img/18ct_necklace.png');left:7%;width:86%;top:8%;height:32%}
#c-silver .name::before{background-image:url('../img/silver_999_bars.png');top:7%;height:35%}
.card .name::after{content:'GOLD';position:absolute;top:43%;left:0;width:100%;text-align:center;font-family:'Cormorant Garamond',Georgia,serif;font-size:2.72cqw;line-height:1.15;font-weight:600;white-space:nowrap;color:#382317}
#c-gold24 .name::after{content:'24 CT'}
#c-gold22 .name::after{content:'22 CT'}
#c-gold20 .name::after{content:'20 CT'}
#c-gold18 .name::after{content:'18 CT'}
#c-silver .name::after{content:'999'}
/* Ornamental divider at the same place as the reference design. */
.card::after{content:'◆';position:absolute;top:57.1%;left:16%;width:68%;height:1px;background:linear-gradient(90deg,transparent,#9e702f 15%,#9e702f 85%,transparent);color:#805019;font-size:.83cqw;line-height:0;text-align:center;text-shadow:0 1px #f7e9d8;pointer-events:none}
#c-silver::after{background:linear-gradient(90deg,transparent,#898f92 15%,#898f92 85%,transparent);color:#717678}
.card>div:nth-child(2){position:absolute;top:64.2%;left:4.5%;width:91%;height:32%;border-radius:.7cqw;border:.11cqw solid #f7cb6a;background:linear-gradient(130deg,#8f550a,#af7419 52%,#885209);box-shadow:inset 0 0 0 .16cqw #9f6a16,inset 0 .15cqw 1.5cqw #fbd88e29,0 .14cqw .3cqw #69410e4c;display:flex;flex-direction:column;justify-content:center;align-items:center;overflow:hidden}
.card>div:nth-child(2)::before{content:'';position:absolute;left:-140%;top:-70%;height:240%;width:45%;background:linear-gradient(90deg,transparent,#fff5c94f,transparent);transform:rotate(24deg);pointer-events:none;animation:shine 10s ease-in-out infinite}
#c-silver>div:nth-child(2){border-color:#bfc2c3;background:linear-gradient(120deg,#45484a,#6a6d70 54%,#3b3e41);box-shadow:inset 0 0 0 .14cqw #74777a,inset 0 .15cqw 1cqw #ffffff20,0 .1cqw .3cqw #43474d50}
.value{display:flex;align-items:baseline;justify-content:center;gap:.08em;white-space:nowrap;font-family:'Cormorant Garamond',Georgia,serif;font-size:2.5cqw;line-height:1.1;font-weight:500;color:#fff;text-shadow:0 .15cqw .2cqw #3e230b44;letter-spacing:-.05cqw;position:relative}
.value b{font-weight:500}
.value span{font-size:.85em}
.unit{margin-top:.3cqw;font-size:1.12cqw;line-height:1.2;color:#fff5e6;white-space:nowrap;font-weight:400;position:relative;text-align:center}
/* The original direction-change and stale signals are retained, just restyled. */
.delta{position:absolute;top:94%;right:8%;transform:translateY(-50%);min-height:0;font-size:.75cqw;font-weight:700;white-space:nowrap;color:#f1e8c7;border-radius:2cqw;z-index:5;line-height:1.2}
.delta:empty{display:none}
.card.up .delta{color:#d3ffc8;text-shadow:0 1px 3px #184d27}
.card.down .delta{color:#ffd0cf;text-shadow:0 1px 3px #6e1721}
.card.stale{filter:grayscale(.55) drop-shadow(0 .25cqw .4cqw #663b1631)}
/* Bottom ornament, actual API mode / data status, notice and scrolling ticker. */
.bottom{position:absolute;z-index:6;left:27.5%;width:45%;top:84.3%;height:15%;display:flex;flex-direction:column;align-items:center;text-align:center}
.footer-divider{height:2.6cqw;width:100%;display:flex;align-items:center;justify-content:center;gap:.65cqw;color:#a16b20;flex:none}
.footer-divider::before,.footer-divider::after{content:'';height:1px;flex:1;background:linear-gradient(90deg,transparent,#aa721f)}
.footer-divider::after{transform:rotate(180deg)}
.footer-divider svg{height:2.2cqw;width:3.5cqw;flex:none}
.footer-text{font-size:1.13cqw;letter-spacing:.33cqw;white-space:nowrap;font-weight:500;color:#3f291b;line-height:1.4}
.footer-metadata{width:100%;display:flex;flex-direction:column;align-items:center;gap:.18cqw;font-size:.71cqw;color:#684429;line-height:1.2;position:relative;margin-top:.18cqw}
.status{display:inline-flex;align-items:center;gap:.3cqw;font-weight:600;color:#624126;white-space:nowrap;max-width:95%;overflow:hidden;text-overflow:ellipsis}
.status i{height:.5cqw;width:.5cqw;border-radius:50%;background:#d9a747;flex:none}
.status.live i{background:#12804c;box-shadow:0 0 .5cqw #12804c}
.status.demo i,.status.manual i,.status.empty i{background:#c48d22}
.status.stale{color:#af2631}
.status.stale i{background:#c12835;box-shadow:0 0 .5cqw #c12835}
.notice{max-width:98%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#795025}
.notice:empty{display:none}
.ticker{position:relative;width:100%;max-height:1.3cqw;overflow:hidden;white-space:nowrap}
.track{display:inline-block;padding-left:100%;font-size:.73cqw;letter-spacing:.02cqw;animation:scroll 40s linear infinite;white-space:nowrap}
.track:empty{display:none}
@keyframes scroll{to{transform:translateX(-100%)}}
@keyframes shine{0%,62%,100%{left:-140%}75%{left:160%}}
@media(prefers-reduced-motion:reduce){.track{animation-duration:120s}.card>div:nth-child(2)::before{animation:none}.card{transition:none}}
/* Desktop / TV: date and clock flank the Rates heading, like the reference. */
.registered-symbol{position:absolute;top:.3cqw;left:calc(50% + 2.65cqw);font-family:Arial,sans-serif;font-size:1.35cqw;line-height:1;font-weight:600;color:#b98527}
.time-pill{display:contents}
.time-pill svg{display:none}
@media not all and (max-width:720px) and (orientation:portrait){
  .heading{top:26.5%}
  .subheading{top:35.6%;gap:0}
  .subheading::before,.subheading::after{display:none}
  .when{top:139%;left:0;width:100%;display:grid;grid-template-columns:34% 34%;justify-content:space-between;align-items:center;padding:0 11.1%;gap:0}
  .date-pill,.time-pill{display:flex;align-items:center;justify-content:center;gap:.75cqw;min-width:0;height:3.15cqw;border:.12cqw solid #4d2d1c;border-radius:20cqw;background:#ffefdc60;box-shadow:inset 0 .15cqw .7cqw #fff9f6aa;padding:0 .8cqw;white-space:nowrap}
  .time-pill svg{display:block;width:1.75cqw;height:1.75cqw;flex:none}
  #date{font-size:1.35cqw;letter-spacing:.055cqw}
  .clock{font-family:'Cormorant Garamond',Georgia,serif;font-size:1.95cqw;letter-spacing:.08cqw;font-weight:600;color:#4d2d1c;text-transform:uppercase;line-height:1}
}
/* Mobile-only actions are never visible in the desktop/TV layout. */
.mobile-actions,.mobile-date{display:none}
/* Dedicated portrait layout — same data and renderer, new presentation only. */
@media(max-width:720px) and (orientation:portrait){
  html,body{height:auto;min-height:100%;overflow-x:hidden;overflow-y:auto;background:#f5efe6}
  body{display:block;padding:0;color:#382619}
  .board{width:100%;max-width:100%;height:auto;min-height:100dvh;aspect-ratio:auto;container-type:inline-size;overflow:visible;padding:0 14px calc(100px + env(safe-area-inset-bottom,0px));background:#f5efe6;box-shadow:none}
  .board::before,.board::after,.wood,.arch,.ray,.floor,.decor{display:none}
  .top{position:relative;top:auto;left:auto;width:auto;height:auto;min-height:0;margin:0 -14px;padding:13px 14px 16px;display:flex;flex-direction:column;align-items:center;background:radial-gradient(ellipse at 50% 0%,#684829,#382313 75%);color:#fff5dd;border-bottom:3px solid #c89a45;border-radius:0 0 20px 20px;box-shadow:0 8px 24px #51351617}
  .shop-logo{position:static;display:block;width:76px;height:56px;object-fit:contain;filter:drop-shadow(0 2px 8px #e7ad412b)}
  .registered-symbol{top:14px;left:calc(50% + 26px);font-size:12px;color:#e9bf66}
  .brand{position:static;width:100%;margin-top:5px}
  .brand h1{font-size:clamp(21px,6.3cqw,32px);letter-spacing:.05em;line-height:1.2;white-space:normal;color:#fff1d2;text-shadow:none}
  .brand h1::before,.brand h1::after{display:none}
  .brand p{font-size:clamp(9px,2.75cqw,12px);letter-spacing:.065em;color:#e8cd9e;margin:5px 0 0;white-space:normal}
  .brand p span{color:#e5b75a;padding:0 2px}
  .when{position:static;width:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;gap:6px;margin-top:12px;flex-wrap:wrap}
  .date-pill,.time-pill{display:flex;align-items:center;justify-content:center;gap:7px;min-width:0;width:max-content;max-width:100%;height:auto;min-height:30px;border:1px solid #dcb77a66;border-radius:8px;background:#fff4d012;box-shadow:none;padding:5px 11px;white-space:nowrap;color:#fff3db}
  .date-pill svg,.time-pill svg{display:block;width:15px;height:15px;flex:none}
  #date{display:none}.mobile-date{display:block;font-family:'Jost','Segoe UI',sans-serif;font-size:12px;font-weight:500;letter-spacing:.025em}
  .clock{font-family:'Jost','Segoe UI',sans-serif;font-size:14px;font-weight:600;letter-spacing:.025em;color:#fff3db;text-transform:uppercase;line-height:1.2}
  .heading{position:relative;top:auto;font-size:clamp(22px,7.5cqw,35px);letter-spacing:-.02em;margin-top:19px;text-shadow:none;line-height:1}
  .subheading{position:relative;top:auto;left:auto;transform:none;justify-content:center;margin:1px 0 14px;font-size:clamp(22px,7cqw,31px);gap:12px;line-height:1}
  .subheading::before,.subheading::after{width:42px;height:1px}
  .cards{position:relative;top:auto;left:auto;width:100%;height:auto;display:grid;grid-template-columns:minmax(0,1fr)!important;gap:14px;margin:0 auto;max-width:520px}
  .card,.card#c-silver{width:100%;height:auto;min-height:0;max-height:none;aspect-ratio:auto;display:flex;flex-direction:column;gap:10px;padding:12px;background:#fffdf9;border:1px solid #eadbc6;border-radius:18px;box-shadow:0 6px 18px #4e321310;filter:none;overflow:hidden;transition:none}
  .card#c-silver{background:#fefefe;border-color:#dce1e5;grid-column:auto}
  .card:hover{transform:none;filter:none}
  .card.stale{filter:grayscale(.35)}
  .card::after,#c-silver::after{display:none}
  .card .name{position:relative;top:auto;left:auto;width:100%;height:98px;display:block;font-size:0;line-height:0;pointer-events:none}
  .card .name::before,#c-gold20 .name::before,#c-gold18 .name::before,#c-silver .name::before{top:0;left:0;width:100%;height:65px;filter:drop-shadow(0 3px 3px #9a692222);transform:none}
  .card:hover .name::before{transform:none}
  .card .name::after{top:68px;left:0;width:100%;font-family:'Cormorant Garamond',Georgia,serif;font-size:clamp(24px,8cqw,32px);line-height:1.1;font-weight:700;color:#39291b;letter-spacing:0}
  #c-gold24 .name::after{content:'24 CT Gold'}
  #c-gold22 .name::after{content:'22 CT Gold'}
  #c-gold20 .name::after{content:'20 CT Gold'}
  #c-gold18 .name::after{content:'18 CT Gold'}
  #c-silver .name::after{content:'999 Silver';color:#353d44}
  .card>div:nth-child(2),#c-silver>div:nth-child(2){position:relative;top:auto;left:auto;width:100%;height:auto;min-height:94px;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;gap:4px;padding:11px 14px;border:1px solid #d7ac65;border-radius:12px;background:linear-gradient(120deg,#80500e,#b5812d);box-shadow:none;overflow:hidden}
  #c-silver>div:nth-child(2){border-color:#9ba4ac;background:linear-gradient(120deg,#434b54,#68727b)}
  .card>div:nth-child(2)::before{content:'DISPLAY RATE';position:static;left:auto;top:auto;width:auto;height:auto;background:none;transform:none;animation:none;color:#fff0d2;font-size:10px;font-weight:600;letter-spacing:.12em;line-height:1.2}
  #c-silver>div:nth-child(2)::before{color:#e7edf3}
  .value{font-family:'Jost','Segoe UI',Arial,sans-serif;font-size:clamp(27px,9.6cqw,38px);line-height:1.06;font-weight:600;letter-spacing:-.04em;color:#fff;justify-content:flex-start;text-shadow:none;max-width:100%}
  .value b{font-weight:600}.value span{font-size:.8em}
  .unit{margin:0;font-size:12px;font-weight:400;line-height:1.35;text-align:left;color:#fff4e5;white-space:normal}
  .delta{position:static;transform:none;align-self:flex-end;min-height:0;font-size:11px;line-height:1.3;color:#695234;margin-top:-3px;white-space:nowrap}
  .delta:empty{display:none}.card.up .delta{color:#187345;text-shadow:none}.card.down .delta{color:#a52d36;text-shadow:none}
  .bottom{position:relative;top:auto;left:auto;width:100%;height:auto;margin:22px auto 0;max-width:520px}
  .footer-divider{height:24px}.footer-divider svg{width:34px;height:23px}
  .footer-text{font-size:11px;letter-spacing:.12em;white-space:normal;margin-top:4px}
  .footer-metadata{font-size:12px;margin-top:8px;gap:6px;line-height:1.4}
  .status{gap:6px;white-space:normal;max-width:100%;overflow:visible;text-overflow:clip}.status i{height:7px;width:7px}
  .notice{white-space:normal;overflow:visible}.ticker{max-height:24px}.track{font-size:11px}
  .mobile-actions{position:fixed;z-index:20;bottom:0;left:0;right:0;display:flex;justify-content:space-between;align-items:center;gap:8px;padding:9px 14px calc(9px + env(safe-area-inset-bottom,0px));background:#fffdf8f5;border-top:1px solid #e8d8c0;box-shadow:0 -5px 25px #38230b12}
  .mobile-status{display:flex;align-items:center;gap:6px;color:#725738;background:#f4ede3;border-radius:999px;padding:10px 11px;font-size:11px;font-weight:600;white-space:nowrap;min-width:0}
  .mobile-status i{width:8px;height:8px;border-radius:50%;background:#c39440;flex:none}
  .mobile-status.live i{background:#16834c}.mobile-status.stale i{background:#b93539}
  .whatsapp-share{display:flex;align-items:center;justify-content:center;gap:7px;padding:11px 15px;border-radius:999px;background:#146c43;color:#fff;text-decoration:none;font-size:12px;font-weight:600;white-space:nowrap;min-height:44px;box-shadow:0 3px 10px #146c4326}
  .whatsapp-share svg{width:19px;height:19px;flex:none}.whatsapp-share:focus-visible{outline:3px solid #c28c3e;outline-offset:3px}
  @media(max-width:340px){.mobile-actions{padding-left:8px;padding-right:8px}.mobile-status{padding:9px 8px;font-size:10px}.whatsapp-share{padding:10px 11px;font-size:11px}}
}
