/* Redway Studio shared public navigation. Loaded by every public page.
   Scoped to .rw- so the homepage's older global nav rules cannot reach in. */
:root{
  --rw-bg:#0A0C11;--rw-panel:#141824;--rw-line:#2A3142;
  --rw-chalk:#F4F2EC;--rw-mut:#AFB5C4;--rw-red:#E8442E;--rw-amber:#FFB454;
  --rw-body:'Archivo',system-ui,-apple-system,'Segoe UI',sans-serif;
}
.rw-header{
  position:sticky;top:0;z-index:100;
  background:rgba(10,12,17,.9);
  -webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);
  border-bottom:1px solid var(--rw-line);
}
.rw-header a{text-underline-offset:4px}
.rw-nav-wrap{
  width:min(1180px,calc(100% - 48px));margin:0 auto;position:relative;
  display:flex;align-items:center;justify-content:space-between;gap:20px;
  padding:13px 0;
}
.rw-brand{
  display:inline-flex;align-items:center;gap:10px;flex:none;
  color:var(--rw-chalk);text-decoration:none;font-weight:800;font-size:1.03rem;white-space:nowrap;
}
.rw-brand img{width:30px;height:30px;display:block}
.rw-brand:focus-visible{outline:3px solid var(--rw-amber);outline-offset:4px;border-radius:6px}
.rw-menu{
  display:flex;align-items:center;gap:6px 22px;flex-wrap:wrap;
  font:500 .93rem/1 var(--rw-body);
}
.rw-menu a{
  display:inline-flex;align-items:center;min-height:44px;padding:4px 2px;
  color:var(--rw-mut);text-decoration:none;
}
.rw-menu a:hover{color:var(--rw-chalk)}
.rw-menu a:focus-visible{outline:3px solid var(--rw-amber);outline-offset:3px;border-radius:6px}
.rw-menu a[aria-current=page],.rw-menu a[aria-current=true]{
  color:var(--rw-chalk);text-decoration:underline;
  text-decoration-color:var(--rw-red);text-underline-offset:8px;
}
.rw-book{
  padding:10px 20px !important;min-height:44px;
  border:1px solid var(--rw-line);border-radius:999px;color:var(--rw-chalk) !important;
}
.rw-book:hover{border-color:var(--rw-red)}
.rw-menu-toggle{
  display:none;align-items:center;justify-content:center;gap:8px;
  min-height:44px;min-width:44px;padding:9px 16px;
  background:var(--rw-panel);color:var(--rw-chalk);
  border:1px solid var(--rw-line);border-radius:999px;
  font:600 .9rem/1 var(--rw-body);cursor:pointer;
}
.rw-menu-toggle:focus-visible{outline:3px solid var(--rw-amber);outline-offset:3px}

/* Narrow screens. The dropdown only becomes a menu once JS has marked the
   header ready. Without JS the links below stay in normal flow and remain
   usable — the menu never hides behind a button that cannot open it. */
@media(max-width:860px){
  .rw-nav-wrap{width:calc(100% - 32px)}
  .rw-header[data-nav-ready] .rw-menu-toggle{display:inline-flex}
  .rw-header[data-nav-ready] .rw-menu{
    position:absolute;top:calc(100% + 8px);left:0;right:0;
    display:none;flex-direction:column;align-items:stretch;gap:0;
    background:var(--rw-panel);border:1px solid var(--rw-line);border-radius:14px;
    padding:8px;box-shadow:0 22px 48px rgba(0,0,0,.5);
    max-height:min(68vh,460px);overflow-y:auto;
  }
  .rw-header[data-nav-ready][data-open="true"] .rw-menu{display:flex}
  .rw-header[data-nav-ready] .rw-menu a{
    min-height:48px;padding:12px 14px;border-radius:9px;
    color:var(--rw-chalk);font-size:1.02rem;font-weight:700;
  }
  .rw-header[data-nav-ready] .rw-menu a:hover{background:rgba(255,255,255,.05)}
  .rw-header[data-nav-ready] .rw-menu a[aria-current=page]{
    text-decoration:none;box-shadow:inset 3px 0 0 var(--rw-red);
  }
  .rw-header[data-nav-ready] .rw-menu .rw-book{
    margin-top:6px;justify-content:center;border-radius:10px;
    background:var(--rw-red);border-color:var(--rw-red);color:#fff !important;
  }
  .rw-header[data-nav-ready] .rw-menu .rw-book:hover{background:#F0553F}
}
@media(max-width:420px){
  .rw-brand{font-size:.98rem;gap:8px}
  .rw-brand img{width:26px;height:26px}
}
@media(prefers-reduced-motion:reduce){
  .rw-header{transition:none}
}
