/* REVALY ACCOUNT 1.0A — UNIFIED PREMIUM SHELL
   Namespaced visual layer; existing JS/Supabase and commerce rules unchanged. */
body.rvac-unified{background:#f3f7fd!important;color:#10264c;font-family:Inter,"Plus Jakarta Sans",Manrope,Arial,sans-serif;}
body.rvac-unified::before{display:none!important;}
body.rvac-unified .rvac-layout{display:grid;grid-template-columns:226px minmax(0,1fr);min-height:100vh;align-items:stretch;}
.rvac-icon{width:19px;height:19px;display:block;flex:none}
.rvac-sidebar{height:100vh;position:sticky;top:0;box-sizing:border-box;background:#fff;border-right:1px solid #dce6f4;padding:25px 14px 17px;display:flex;flex-direction:column;min-width:0;z-index:30;overflow-y:auto;scrollbar-width:thin;scrollbar-color:#d3dfed transparent;}
.rvac-brand{display:flex;align-items:center;justify-content:space-between;gap:7px;padding:4px 8px 24px;margin-bottom:22px;border-bottom:1px solid #e6edf7;}
.rvac-brand img{width:109px;height:auto;display:block;object-fit:contain;}
.rvac-brand-chip{font-size:9px;letter-spacing:.03em;border:1px solid #d7e5fc;background:#edf4ff;color:#1b57b4;padding:7px 8px;border-radius:999px;font-weight:850;white-space:nowrap;}
.rvac-side-label{padding:6px 9px 10px;font-size:10px;font-weight:850;color:#8799b4;letter-spacing:.13em;}
.rvac-nav{display:grid;gap:4px;}
.rvac-nav-link{display:flex;gap:12px;align-items:center;border:1px solid transparent;border-radius:12px;padding:11px 10px;color:#24436d!important;text-decoration:none!important;min-height:56px;transition:background .14s,border-color .14s;}
.rvac-nav-link>.rvac-icon{color:#3a669f;}
.rvac-nav-text{display:flex;flex-direction:column;gap:4px;min-width:0;}
.rvac-nav-text strong{font-size:12px;font-weight:800;color:#153364;line-height:1.25;}
.rvac-nav-text small{font-size:10px;color:#7b8da6;line-height:1.3;}
.rvac-nav-link:hover{background:#f7faff;border-color:#ebf0f9;}
.rvac-nav-link:focus-visible{outline:2px solid #2473e2;outline-offset:2px;}
.rvac-nav-link.is-active{background:#eaf2ff;border-color:#cee0ff;box-shadow:inset 3px 0 0 #2668df;}
.rvac-nav-link.is-active>.rvac-icon,.rvac-nav-link.is-active strong{color:#0952af;}
.rvac-side-grow{flex:1;min-height:32px;}
.rvac-lower-nav{padding-bottom:17px;border-bottom:1px solid #e7edf5;}
.rvac-side-footer{display:flex;align-items:center;gap:9px;padding:18px 7px 2px;}
.rvac-side-footer-icon{display:grid;place-items:center;border-radius:10px;background:#eef5ff;color:#1d5abc;width:34px;height:34px;flex:none;}
.rvac-side-footer-icon .rvac-icon{width:18px;height:18px;}
.rvac-side-footer strong{display:block;font-size:11px;color:#213b66;}
.rvac-side-footer small{display:block;margin-top:5px;font-size:9px;line-height:1.35;color:#8596ae;}
.rvac-content{min-width:0;min-height:100vh;}
.rvac-mobile-topbar{display:none;}
body.rvac-unified .rvac-content>.page{max-width:1320px!important;width:100%;margin:0 auto!important;padding:32px clamp(20px,3vw,48px) 70px!important;box-sizing:border-box;}
body.rvac-unified .top{align-items:center;gap:20px;margin-bottom:25px;padding:0 0 23px;border-bottom:1px solid #dfe8f4;}
body.rvac-unified .account-v2-top .account-wordmark,body.rvac-unified .billing-v2-page .account-wordmark,body.rvac-unified .affiliate-page .account-wordmark{display:none;}
.rvac-kicker{font-size:10px;letter-spacing:.16em;color:#255fbe;font-weight:850;margin:0 0 10px;}
.rvac-page-subtitle{color:#8291a6;margin:0 0 10px;font-size:12px;line-height:1.55;max-width:560px;}
body.rvac-unified h1{font-size:clamp(25px,2.3vw,33px)!important;margin:0 0 8px!important;letter-spacing:-.045em!important;color:#0d244c!important;font-weight:850!important;}
body.rvac-unified .account-v2-top #accountEmail{font-size:12px;margin:6px 0 0;}
body.rvac-unified .top>.admin-top-actions{align-items:center;flex-wrap:wrap;justify-content:flex-end;}
body.rvac-unified .top .btn{border-radius:11px;min-height:42px;padding:11px 15px;font-size:12px;box-shadow:none;}
body.rvac-unified .top .btn.secondary.rvac-upgrade-button{background:linear-gradient(135deg,#13498e,#2465cc);color:#fff;border-color:#174f9e;gap:9px;}
.rvac-upgrade-button .rvac-icon{width:15px;height:15px;}
.rvac-hero{position:relative;isolation:isolate;overflow:hidden;min-height:222px;background:linear-gradient(112deg,#092454 0%,#133e83 57%,#2569c8 100%);border-radius:21px;padding:32px 34px;color:#fff;display:flex;align-items:center;margin:10px 0 24px;box-shadow:0 18px 35px rgba(16,54,118,.11);}
.rvac-hero-left{position:relative;z-index:2;max-width:690px;}
.rvac-hero-eyebrow{font-size:10px;letter-spacing:.22em;font-weight:850;color:#c5dcff;margin-bottom:12px;}
body.rvac-unified .rvac-hero h2{color:#fff;font-size:clamp(22px,2.55vw,31px);line-height:1.2;letter-spacing:-.035em;margin:0 0 12px;}
.rvac-hero p{color:#c8dcfa;font-size:12px;line-height:1.65;margin:0;max-width:480px;}
.rvac-hero-actions{display:flex;align-items:center;flex-wrap:wrap;gap:15px;margin-top:20px;}
.rvac-hero-button{display:inline-flex;align-items:center;gap:8px;background:#fff;color:#14498f!important;font-size:11px;font-weight:850;border-radius:10px;padding:11px 14px;border:1px solid rgba(255,255,255,.8);}
.rvac-hero-button:hover{background:#e9f3ff;}
.rvac-hero-button .rvac-icon{width:15px;height:15px;}
.rvac-hero-link{color:#e1eeff!important;font-size:11px;font-weight:750;border-bottom:1px solid #7fa7eb;padding-bottom:3px;}
.rvac-hero-decor{position:absolute;right:-20px;top:-86px;width:430px;height:400px;opacity:.6;pointer-events:none;}
.rvac-orbit{position:absolute;border:1px solid rgba(255,255,255,.22);border-radius:50%;transform:rotate(-22deg);}
.rvac-orbit-one{inset:35px 22px 35px 22px;}
.rvac-orbit-two{inset:88px 76px 88px 76px;}
.rvac-hero-mark{position:absolute;right:137px;top:151px;font-size:100px;line-height:1;font-weight:900;letter-spacing:-.15em;color:rgba(255,255,255,.13);font-family:Arial,sans-serif;}
body.rvac-unified .account-v2-page>.summary{margin-bottom:26px!important;}
body.rvac-unified .card{border-radius:17px;border-color:#dde7f5;box-shadow:0 9px 24px rgba(22,52,105,.038);background:#fff;}
body.rvac-unified #accountSummary{padding:24px 26px;border-color:#d2e1f4;background:#fff;}
body.rvac-unified #accountSummary h2{font-size:21px;margin:0 0 6px;letter-spacing:-.02em;}
body.rvac-unified .section{margin-top:30px;scroll-margin-top:25px;}
body.rvac-unified #overview,body.rvac-unified #apps,body.rvac-unified #access,body.rvac-unified #usage{scroll-margin-top:25px;}
body.rvac-unified .section-heading-row{margin-bottom:15px;}
body.rvac-unified .section-heading-row h2{font-size:19px;letter-spacing:-.025em;color:#102650;margin-bottom:7px;}
body.rvac-unified .section-heading-row .muted{font-size:12px;line-height:1.65;max-width:680px;margin:0;}
body.rvac-unified .grid{grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:13px;}
body.rvac-unified .usage-product-grid{gap:13px;}
body.rvac-unified #productGrid .card,body.rvac-unified #entitlementGrid .card,body.rvac-unified #usageGrid .card{padding:19px;}
body.rvac-unified #productGrid .card:hover,body.rvac-unified #entitlementGrid .card:hover,body.rvac-unified #usageGrid .card:hover{border-color:#b5cff0;box-shadow:0 13px 27px rgba(23,72,150,.095);}
body.rvac-unified .affiliate-page .top,body.rvac-unified .billing-v2-page .top{margin-bottom:28px;}
body.rvac-unified .affiliate-page .top .eyebrow{font-size:10px;color:#3267b0;margin-bottom:8px;}
body.rvac-unified .affiliate-page,.rvac-unified .billing-v2-page{max-width:1360px;}
body.rvac-unified .affiliate-page .affiliate-metric-grid{gap:12px;}
body.rvac-unified .affiliate-page .affiliate-hero,body.rvac-unified .billing-v2-page .summary{border-color:#cddff6;background:linear-gradient(135deg,#fff,#f6faff);}
.rvac-mobile-overlay[hidden]{display:none!important;}
@media(min-width:901px){.rvac-mobile-overlay{display:none!important;}}
@media(max-width:1100px) and (min-width:901px){body.rvac-unified .rvac-layout{grid-template-columns:207px minmax(0,1fr);} .rvac-sidebar{padding:20px 10px;}body.rvac-unified .rvac-content>.page{padding:28px 20px 60px!important;}}
@media(max-width:900px){
 body.rvac-unified .rvac-layout{display:block;}
 .rvac-sidebar{position:fixed;left:0;top:0;width:min(285px,88vw);height:100dvh;transform:translateX(-103%);transition:transform .2s ease;box-shadow:0 20px 60px rgba(12,30,65,.22);}
 body.rvac-unified.rvac-menu-open .rvac-sidebar{transform:translateX(0);}
 .rvac-mobile-topbar{height:66px;display:flex;align-items:center;gap:14px;padding:0 18px;background:#fff;border-bottom:1px solid #dce7f3;position:sticky;top:0;z-index:20;}
 .rvac-mobile-topbar img{width:105px;height:auto;}
 .rvac-mobile-topbar span{font-size:9px;font-weight:850;letter-spacing:.12em;color:#40639c;border-left:1px solid #dbe6f5;padding-left:12px;}
 .rvac-menu-btn{display:grid;place-items:center;border-radius:10px;width:36px;height:36px;border:1px solid #dce7f5;background:#f3f7ff;color:#2460b5;cursor:pointer;}
 .rvac-mobile-overlay:not([hidden]){display:block;position:fixed;inset:0;background:rgba(9,25,55,.45);z-index:25;}
 body.rvac-unified .rvac-content>.page{padding:24px 18px 60px!important;}
 body.rvac-unified .top{flex-wrap:wrap;align-items:flex-start;}
 body.rvac-unified .top>.admin-top-actions{width:100%;justify-content:flex-start;}
 body.rvac-unified .rvac-hero{min-height:0;padding:26px 24px;}
}
@media(max-width:600px){
 body.rvac-unified .rvac-content>.page{padding:20px 14px 56px!important;}
 body.rvac-unified .top{margin-bottom:18px;padding-bottom:18px;}
 body.rvac-unified .top .admin-top-actions .btn{flex:0 1 auto;font-size:11px;padding:10px 12px;}
 body.rvac-unified .rvac-hero{padding:23px 20px;border-radius:17px;}
 body.rvac-unified .rvac-hero h2{font-size:22px;}
 body.rvac-unified .rvac-hero-decor{right:-235px;opacity:.25;}
 body.rvac-unified .rvac-hero p{font-size:11px;}
 body.rvac-unified #accountSummary{padding:18px;}
 body.rvac-unified .section{margin-top:25px;}
 body.rvac-unified .grid{grid-template-columns:repeat(auto-fit,minmax(170px,1fr));}
 body.rvac-unified .rvac-content .card{max-width:100%;}
}
@media(prefers-reduced-motion:reduce){.rvac-sidebar,.rvac-nav-link,.rvac-hero-button{transition:none!important;}}

/* 1.0B Focused Account navigation: data containers remain mounted for native JS.
   Only the selected account view renders. No observer, polling or rerender. */
body.rvac-unified.rvac-focused [data-rvac-section]:not(.rvac-section-active){display:none!important;}
body.rvac-unified.rvac-focused .account-v2-page>.section.rvac-section-active{margin-top:0;}
body.rvac-unified.rvac-focused #subscriptionCard.rvac-section-active{margin-top:20px;}
body.rvac-unified.rvac-focused #apps.rvac-section-active,
body.rvac-unified.rvac-focused #access.rvac-section-active,
body.rvac-unified.rvac-focused #usage.rvac-section-active{animation:rvacViewReveal .14s ease-out both;}
@keyframes rvacViewReveal{from{opacity:.6;transform:translateY(4px)}to{opacity:1;transform:none}}
body.rvac-unified.rvac-focused .rvac-nav-link[aria-current="page"]{font-weight:inherit;}
@media(prefers-reduced-motion:reduce){body.rvac-unified.rvac-focused [data-rvac-section]{animation:none!important;}}

/* Page title replaces duplicated per-section headings. */
body.rvac-unified.rvac-focused #apps.rvac-section-active > .section-heading-row,
body.rvac-unified.rvac-focused #access.rvac-section-active > .section-heading-row,
body.rvac-unified.rvac-focused #usage.rvac-section-active > .section-heading-row{display:none!important;}
body.rvac-unified.rvac-focused #subscriptionCard.rvac-section-active{margin:0 0 20px!important;}

/* 1.0C: active sidebar follows actual account view, including deep links.
   Billing/Affiliate still use the existing static aria-current marker. */
body.rvac-unified .rvac-sidebar a.rvac-nav-link[aria-current="page"],
body.rvac-unified.rvac-focused[data-rvac-current-view="overview"] .rvac-sidebar a.rvac-nav-link[href$="#overview"],
body.rvac-unified.rvac-focused[data-rvac-current-view="apps"] .rvac-sidebar a.rvac-nav-link[href$="#apps"],
body.rvac-unified.rvac-focused[data-rvac-current-view="access"] .rvac-sidebar a.rvac-nav-link[href$="#access"],
body.rvac-unified.rvac-focused[data-rvac-current-view="usage"] .rvac-sidebar a.rvac-nav-link[href$="#usage"] {
 background:#eaf2ff!important;
 border-color:#cee0ff!important;
 box-shadow:inset 3px 0 0 #2668df!important;
}
body.rvac-unified .rvac-sidebar a.rvac-nav-link[aria-current="page"]>.rvac-icon,
body.rvac-unified .rvac-sidebar a.rvac-nav-link[aria-current="page"] strong {color:#0952af!important;}
