/* Avlu content pages share the same bronze frame, typographic scale and spacing. */
.avlu-page {
  --avlu-line: #755331;
  --avlu-soft-line: #a078443b;
  --avlu-title: #f3ce91;
  --avlu-card: linear-gradient(120deg, #33231a, #1c140f 58%, #251911);
  min-width: 0;
}

.avlu-intro {
  --avlu-art: url('../avlu/castle.webp');
  display: grid;
  align-content: center;
  gap: 9px;
  min-height: clamp(150px, 17cqw, 255px);
  padding: clamp(20px, 3.4cqw, 58px);
  border-bottom: 1px solid #ad7a46;
  background: linear-gradient(90deg, #120d09 0%, #1a100bec 41%, #21150c60 72%, #291a0e35),
    var(--avlu-art) right 42% / 65% auto no-repeat, #18100c;
}
.avlu-art-works { --avlu-art: url('../avlu/dev.webp'); }
.avlu-art-courtyard { --avlu-art: url('../avlu/avlu-placeholder.webp'); }
.avlu-intro h1 {
  font: 700 clamp(30px, 4.5cqw, 65px)/1.08 Georgia, serif;
  color: var(--avlu-title);
  text-shadow: 0 3px 12px #060301;
  overflow-wrap: anywhere;
}
.avlu-intro > p { max-width: 52ch; color: #e5d2b3; font-size: clamp(14px, 1.35cqw, 19px); }
.avlu-crumb { display: flex; flex-wrap: wrap; gap: 5px 10px; font-size: 12px; color: #c5aa84; }
.avlu-crumb a:hover { color: #ffe0a4; }
.avlu-content {
  display: grid;
  gap: clamp(12px, 1.8cqw, 28px);
  min-width: 0;
  padding: clamp(14px, 2.3cqw, 36px) clamp(10px, 2.7cqw, 44px) clamp(22px, 3cqw, 48px);
}
.court-shell > .avlu-page > .section { padding: 0; background: transparent; }
.avlu-card,
.avlu-page :is(.auth-card,.panel-card,.panel-aside,.support-faq) {
  min-width: 0;
  background: var(--avlu-card, linear-gradient(120deg,#33231a,#19110d));
  border: 1px solid var(--avlu-line, #755331);
  border-image: none;
  border-radius: 0;
  box-shadow: inset 0 0 0 2px #110a07aa, 0 8px 28px #0b060475;
}
.avlu-card { padding: clamp(12px, 1.8cqw, 28px); }
.avlu-card :is(h2,h3),
.avlu-page :is(.panel-card-head,.support-faq,.staff-inbox-heading) h2 {
  color: var(--avlu-title, #f3ce91);
  font: 700 clamp(19px, 2cqw, 28px)/1.2 Georgia, serif;
  overflow-wrap: anywhere;
}
.avlu-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 5px 16px;
  border-bottom: 1px solid #aa7c4960;
  padding-bottom: 10px;
  margin-bottom: 6px;
}
.avlu-card-head a,
.avlu-content :is(.avlu-steps,.avlu-auth-aside,.avlu-article) a {
  color: #f2c983;
  text-underline-offset: 3px;
}
.avlu-card-head a:hover, .avlu-steps a:hover, .avlu-auth-aside a:hover, .avlu-article a:hover { text-decoration: underline; }
.avlu-page .btn-primary {
  background: linear-gradient(#70251b, #46140e);
  border: 1px solid #af7a43;
  box-shadow: inset 0 0 0 2px #2b120b8c;
  color: #ffe4aa;
}
.avlu-page .btn-primary:is(:hover,:focus-visible) { background: linear-gradient(#92351f,#541a10); color: #fff1c9; }
.avlu-page .btn-outline { color: #eed2a9; border-color: #806035; background: #291c13; }
.avlu-page .btn-outline:is(:hover,:focus-visible) { background: #4a2d18; color: #ffe4ac; }
.avlu-page :is(.input,.select) {
  color-scheme: dark;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  background-color: #18110d;
  border-color: #755438;
}
.avlu-page textarea { resize: vertical; }
.avlu-page .input:-webkit-autofill { -webkit-box-shadow: 0 0 0 60px #231811 inset; -webkit-text-fill-color: #f5ddb6; }
.avlu-page :is(a,button,input,select,textarea):focus-visible { outline: 2px solid #ffda91; outline-offset: 2px; }
.avlu-page :is(.auth-card,.panel-card,.form-grid,.support-layout,.staff-inbox) > * { min-width: 0; }
.avlu-page .panel-card-head { background: #422b1991; padding: clamp(13px,1.35cqw,22px); border-bottom-color: #805735; }
.avlu-page .panel-card-head p,
.avlu-page .panel-card-body .section-note { color: #cdb493; overflow-wrap: anywhere; }
.avlu-page .panel-card-body { padding: clamp(12px,1.6cqw,26px); }
.avlu-page .session-row { border-bottom-color: var(--avlu-soft-line); }
.avlu-page .badge { align-self: start; }

/* Home */
.avlu-home {
  display: grid;
  grid-template-columns: minmax(0, 2.45fr) minmax(0, 1fr);
  gap: clamp(9px, 1.25cqw, 20px);
  margin-block: clamp(10px, 1.3cqw, 20px);
  --avlu-line: #88633e;
  --avlu-title: #f3ce91;
  --avlu-card: linear-gradient(135deg, #302218ef, #1c1511f2 64%, #24180ef2),
    url('../avlu/nav-avlu-stone.webp') center / cover;
}
.avlu-home-main, .avlu-home-aside { display: grid; gap: clamp(9px, 1.25cqw, 20px); min-width: 0; align-content: start; }
.avlu-home .avlu-card {
  padding: clamp(10px,1.35cqw,22px);
  box-shadow: inset 0 0 0 2px #120b07, inset 0 0 0 3px #ad803728, 0 5px 18px #0a0604a6;
}
.avlu-home .avlu-card-head {
  border-image: linear-gradient(90deg, #ba8558, #9870474d 70%, #986b3833) 1;
}
.avlu-entry-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(7px, .95cqw, 12px);
}
.avlu-home .avlu-card:is(.avlu-ares, .avlu-follow, .avlu-home-news), .avlu-feature, .avlu-entry-links a {
  --entry-tint: #71382d71;
  position: relative;
  isolation: isolate;
  border: 1px solid #977045;
  box-shadow: inset 0 0 0 2px #140d09, inset 0 0 0 3px #ac7d483d, 0 4px 14px #08030175;
  background:
    radial-gradient(ellipse at 79% 35%, var(--entry-tint), transparent 65%),
    linear-gradient(90deg, #17110ef2, #2418104d),
    url('../avlu/nav-avlu-stone.webp') center / cover;
}
.avlu-entry-links a {
  --entry-art: url('../avlu/character_karus1.png');
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-width: 0;
  min-height: clamp(85px, 13.6cqw, 140px);
  padding: 11px clamp(11px, 1.9cqw, 25px);
  color: #f3d7a6;
  font: 700 clamp(15px, 2.15cqw, 26px)/1.12 Georgia, serif;
  overflow: hidden;
  transition: border-color .2s, color .2s, box-shadow .2s;
}
.avlu-entry-links a::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: 2px;
  background: var(--entry-art) right clamp(3px, 1cqw, 11px) top 0 / auto 150% no-repeat;
  filter: drop-shadow(0 4px 5px #0e0709b3);
  transition: filter .2s;
}
.avlu-entry-links span {
  display: grid;
  justify-items: start;
  gap: clamp(6px, .85cqw, 11px);
  max-width: 70%;
  text-shadow: 0 2px 4px #0c0604, 0 0 12px #120a05;
}
.avlu-entry-links span::after {
  content: "";
  width: 44px;
  height: 1px;
  background: linear-gradient(90deg, #d7a568, #a66a3400);
  transition: width .2s;
}
.avlu-entry-links a::after, .avlu-home .avlu-card:is(.avlu-ares, .avlu-follow, .avlu-home-news)::after, .avlu-feature::after {
  content: "";
  position: absolute;
  inset: 2px;
  border: 8px solid transparent;
  border-image: url('../avlu/frame.png') 10 stretch;
  opacity: .55;
  pointer-events: none;
}
.avlu-entry-links a::after { z-index: -1; }
.avlu-entry-links .avlu-entry-register {
  --entry-art: url('../avlu/character_elmorad3.png');
  --entry-tint: #534a7170;
}
.avlu-entry-links .avlu-entry-market {
  grid-column: 1 / -1;
  min-height: clamp(57px, 7.8cqw, 83px);
  --entry-tint: #82603576;
}
.avlu-entry-links .avlu-entry-market::before {
  background:
    url('../avlu/character_karus4.png') right 2% top 1px / auto 275% no-repeat,
    url('../avlu/character_elmorad2.png') right clamp(63px, 15%, 115px) top 1px / auto 245% no-repeat;
}
.avlu-entry-links a:is(:hover, :focus-visible) {
  border-color: #dcab69;
  color: #ffe8b8;
  box-shadow: inset 0 0 24px #edaa4330, inset 0 0 0 2px #352017, 0 4px 16px #080301a6;
}
.avlu-entry-links a:is(:hover, :focus-visible) span::after { width: 64px; }
.avlu-entry-links a:is(:hover, :focus-visible)::before {
  filter: brightness(1.12) drop-shadow(0 4px 5px #0e0709b3);
}
.avlu-entry-links a:focus-visible { outline: 2px solid #ffe6aa; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  .avlu-entry-links a, .avlu-entry-links a::before, .avlu-entry-links span::after { transition: none; }
}
.avlu-home-news #court-news a, .avlu-update-list #court-news a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "title category";
  gap: 6px 13px;
  align-items: center;
  padding: 11px 2px;
  border-top: 1px solid #a0784433;
}
.avlu-news-title { grid-area: title; color: #f2debd; overflow-wrap: anywhere; }
.avlu-home-news #court-news small, .avlu-update-list #court-news small {
  grid-area: category;
  margin: 0;
  padding: 3px 7px;
  border: 1px solid #845832;
  color: #f5ce9a;
  background: #4a291b;
  font: 600 11px system-ui;
}
.avlu-home-news a:hover .avlu-news-title, .avlu-update-list a:hover .avlu-news-title { color: #ffdb9f; }
.avlu-home-news #court-news a {
  padding-inline: clamp(5px, .8cqw, 12px);
  transition: background-color .15s;
}
.avlu-home-news #court-news a:is(:hover, :focus-visible) { background-color: #9b5d2928; }
.avlu-home-news #court-news small { background: linear-gradient(#572c1c, #351b14); }
.avlu-feature { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.07fr); min-width: 0; }
.avlu-feature > img { display: block; height: 100%; object-fit: cover; }
.avlu-home .avlu-feature .avlu-card {
  display: grid;
  align-content: center;
  gap: 11px;
  justify-items: start;
  border: 0;
  box-shadow: none;
  background: transparent;
}
.avlu-feature .btn { color: #ffdda4; border-color: #8b6338; padding: 10px 14px; }
.avlu-social-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px 6px;
  margin: 13px 0 10px;
}
.avlu-social-list li { display: grid; justify-items: center; align-content: start; gap: 5px; min-width: 0; }
.avlu-social-list img { width: min(100%, 36px); height: 32px; object-fit: contain; border-radius: 4px; }
.avlu-social-list li { padding: 6px 0; background: linear-gradient(#19120de6, #1d140e66); border-block-start: 1px solid #936b453d; }
.avlu-social-list span { font: 500 10px/1.3 system-ui, sans-serif; color: #dbc4a4; overflow-wrap: anywhere; }
.avlu-social-note { color: #c4ab89; font-size: 13px; line-height: 1.45; }
@container (min-width: 481px) and (max-width: 620px) {
  .avlu-social-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.avlu-castle-vignette { border: 1px solid #785431; }
.avlu-home .avlu-card.avlu-follow { --entry-tint: #534a7156; }
.avlu-home .avlu-card.avlu-ares {
  --entry-tint: #79502b69;
  padding: 9px clamp(12px, 1.55cqw, 18px) 11px;
}
.avlu-ares h2 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  margin-bottom: 7px;
  padding-block: 2px 5px;
  color: #f5d6a6;
  font-size: 20px;
  letter-spacing: .19em;
  text-shadow: 0 2px 3px #0b0604;
}
.avlu-ares h2::before, .avlu-ares h2::after {
  content: "";
  flex: 1;
  height: 6px;
  background:
    linear-gradient(45deg, transparent 20%, #c99b62 21% 79%, transparent 80%) right center / 4px 4px no-repeat,
    linear-gradient(90deg, transparent, #997347) center / 100% 1px no-repeat;
}
.avlu-ares h2::after { transform: scaleX(-1); }
#court-status {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.avlu-channel {
  display: grid;
  grid-template-columns: minmax(max-content, 1fr) minmax(0, 1.7fr);
  align-items: center;
  gap: 8px;
  min-height: 27px;
  padding: 3px 8px;
  border: 1px solid #9e774447;
  background: linear-gradient(100deg, #4d372249, #100c0ac9 80%);
  box-shadow: inset 0 1px #d7a67212;
}
.avlu-channel-name {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #f0d9b6;
  font: 600 14px/1.25 var(--font-ui, system-ui);
  overflow-wrap: anywhere;
}
.avlu-channel-name::before {
  content: "";
  flex: 0 0 auto;
  width: 4px;
  height: 4px;
  rotate: 45deg;
  background: #ae8556;
}
.court-status-loading {
  padding: 9px 8px;
  color: #c9b49a;
  font: 500 clamp(11px, 1.16cqw, 15px)/1.3 system-ui, sans-serif;
}
.avlu-channel :is(meter, .avlu-channel-unknown) {
  --channel-track: repeating-linear-gradient(90deg, transparent 0 calc(12.5% - 1px), #140d09 calc(12.5% - 1px) 12.5%),
    linear-gradient(#453728, #35271e 58%, #483728);
  --channel-fill: linear-gradient(180deg, #eed5a5 0%, #c2985e 42%, #8a5b34 100%);
  display: block;
  width: 100%;
  height: 8px;
  border: 1px solid #806444;
  border-radius: 2px;
  background: var(--channel-track);
}
.avlu-channel meter { appearance: none; }
.avlu-channel meter::-webkit-meter-bar {
  border: 0;
  border-radius: 1px;
  background: var(--channel-track);
}
.avlu-channel meter::-webkit-meter-optimum-value { border-radius: 1px; background: var(--channel-fill); }
.avlu-channel meter::-moz-meter-bar { border-radius: 1px; background: var(--channel-fill); }
.avlu-channel .avlu-channel-unknown {
  border-color: #68594a;
  background: repeating-linear-gradient(135deg, #443b32 0 2px, #211b17 2px 5px);
}

/* Announcements, updates and the guide */
.avlu-news-filter {
  padding: 11px clamp(9px,1.3cqw,18px);
  margin: 0;
  gap: 6px;
  border: 1px solid #76522e;
  background: #24180f;
  flex-wrap: wrap;
}
.avlu-page .chip { border-color: #795637; color: #d8bd90; }
.avlu-page .chip.is-active { background: #6a281b; color: #ffe2a8; }
.avlu-page .news-grid-page { grid-template-columns: repeat(3,minmax(0,1fr)); gap: clamp(12px,1.55cqw,24px); }
.avlu-page .news-card {
  background: var(--avlu-card);
  border: 1px solid var(--avlu-line);
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.avlu-page .news-card-media {
  min-height: 0;
  height: auto;
  aspect-ratio: 2.68;
  border-bottom: 1px solid var(--avlu-line);
  background: linear-gradient(0deg,#10090493,transparent 70%), url('../avlu/castle.webp') center / cover;
}
.avlu-page .news-card-media[data-kind="update"] { background-image: linear-gradient(0deg,#10090493,transparent 70%),url('../avlu/dev.webp'); }
.avlu-page .news-card-media[data-kind="event"] { background-image: linear-gradient(0deg,#10090493,transparent 70%),url('../avlu/avlu-placeholder.webp'); }
.avlu-page .news-card-media::before, .avlu-page .news-card-media::after,
.avlu-page :is(.news-card-letter,.news-card-tag) { display: none; }
.avlu-page .news-card-body { flex: 1; display: flex; flex-direction: column; align-items: flex-start; padding: clamp(13px,1.45cqw,24px); }
.avlu-page .news-card-body h3 { color: var(--avlu-title); overflow-wrap: anywhere; }
.avlu-page .news-card-summary { margin-bottom: 16px; color: var(--muted); overflow-wrap: anywhere; }
.avlu-page .news-card-body .text-link { margin-top: auto; color: #f2cb8a; }
.avlu-article { padding-inline: clamp(15px,3.4cqw,52px); }
.avlu-article p { max-width: 84ch; overflow-wrap: anywhere; }
.avlu-steps { display: grid; gap: 8px; counter-reset: step; margin-top: 12px; }
.avlu-steps > li {
  counter-increment: step;
  position: relative;
  min-width: 0;
  padding: 10px 10px 10px 44px;
  background: #17100bad;
  border: 1px solid #75533187;
}
.avlu-steps > li::before {
  content: counter(step);
  position: absolute;
  display: grid;
  place-items: center;
  top: 11px;
  left: 10px;
  width: 25px;
  aspect-ratio: 1;
  border: 1px solid #8a6039;
  background: #372217;
  color: #f6d498;
  font: 700 14px Georgia,serif;
}
.avlu-steps li > :is(a,strong) { color: #f3cf96; font-weight: 700; }
.avlu-steps li p { color: #d6c2a4; }
.avlu-guide-start .avlu-steps { grid-template-columns: repeat(3,minmax(0,1fr)); }
.avlu-inline-links { display: flex; gap: 8px; flex-wrap: wrap; }
.avlu-inline-links a { padding: 5px 12px; border: 1px solid #795835; background: #302015; color: #ffdfab; }
.avlu-nation .classes { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: clamp(6px,1.1cqw,18px); padding-top: 8px; }
.avlu-nation figure {
  border: 1px solid #8c622b;
  background: radial-gradient(ellipse at 50% 35%,#3f443b,#16130e 78%);
}
.avlu-karus figure { background: radial-gradient(ellipse at 50% 35%,#563028,#17100e 78%); }
.avlu-nation img { width: 100%; height: clamp(126px,19cqw,308px); padding: 6px; object-fit: contain; }
.avlu-nation figcaption { border-top: 1px solid #9c6b3a75; padding: 5px; background: #1a130e; color: #f6d69d; }

/* Download and help */
.avlu-download-layout, .avlu-page .support-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1.25fr); gap: clamp(12px,1.75cqw,28px); }
.avlu-download-primary { display: grid; align-content: start; justify-items: start; gap: 10px; }
.avlu-download-primary .btn { margin: 4px 0; white-space: normal; text-align: center; }
.avlu-file-meta { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 5px 14px; width: 100%; padding-block: 10px; border-block: 1px solid var(--avlu-soft-line); }
.avlu-file-meta dd { overflow-wrap: anywhere; }
.avlu-requirements dl { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; margin-top: 12px; }
.avlu-requirements dl div { padding: 10px; border: 1px solid #77563585; background: #20170f; }
.avlu-requirements dt { color: #cab18c; font-size: 12px; }
.avlu-requirements dd { color: #f0d5a9; overflow-wrap: anywhere; }
.avlu-content .faq { margin: 0; }
.avlu-content .faq details, .avlu-page .support-faq details {
  border-color: #765034;
  color: #eed3a3;
  background: #251910;
}
.avlu-content .faq summary, .avlu-page .support-faq summary { cursor: pointer; }
.avlu-page .support-faq { margin-top: 20px; padding: clamp(13px,1.7cqw,25px); }
.avlu-page .support-faq h2 { margin-bottom: 12px; }
.avlu-page .support-message { background: #20160f; border-color: #745538ab; }
.avlu-page .support-ticket[aria-current] { border-color: #e3af62; background: #48301c; }

/* Login, registration, account overview and management */
.avlu-page .avlu-auth-layout { display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr); align-items: start; gap: clamp(14px,2.55cqw,40px); }
.avlu-page .auth-card { padding: clamp(14px,2.4cqw,40px); }
.avlu-page .avlu-auth-aside {
  --aside-image: url('../avlu/castle.webp');
  min-height: clamp(200px,23cqw,376px);
  display: grid;
  align-content: end;
  border: 1px solid var(--avlu-line);
  padding: clamp(16px,2cqw,30px);
  background: linear-gradient(0deg,#130b06 2%,#1c110bd9 31%,transparent 83%),var(--aside-image) center/cover;
}
.avlu-page .avlu-auth-courtyard { --aside-image: url('../avlu/avlu-placeholder.webp'); }
.avlu-auth-aside h3 { color: var(--avlu-title); font: 700 clamp(20px,2.1cqw,30px) Georgia,serif; }
.avlu-auth-aside p { max-width: 41ch; color: #e1be91; margin: 5px 0 12px; }
.avlu-page .field-row { grid-template-columns: repeat(2,minmax(0,1fr)); }
.avlu-page .checkline, .avlu-page .support-close-check { overflow-wrap: anywhere; }
.embedded .avlu-intro { display: none; }
.embedded .avlu-content { display: block; padding: 0; }
.embedded .avlu-page .avlu-auth-layout { display: block; }
.embedded .avlu-page .avlu-auth-aside { display: none; }
.embedded .avlu-page .auth-card { padding: clamp(15px,4vw,30px); border: 0; }
.avlu-page .panel-shell:not([hidden]) { display: grid; grid-template-columns: minmax(0,1fr); gap: 18px; }
.avlu-page .panel-aside { display: flex; position: static; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 9px; }
.avlu-page .panel-user { display: grid; grid-template-columns: auto minmax(0,1fr); align-items: center; text-align: left; gap: 2px 10px; padding: 8px; border-bottom: 0; }
.avlu-page .panel-user-avatar { grid-row: span 2; margin: 0; width: 42px; height: 42px; background: #44301d; }
.avlu-page .panel-user-name { margin: 0; overflow-wrap: anywhere; }
.avlu-page :is(.panel-user-status,.profile-management) { grid-column: 2; }
.avlu-page .panel-nav { display: flex; padding: 5px; flex-wrap: wrap; align-items: stretch; }
.avlu-page .panel-nav button { border: 1px solid #69492b; color: #e2c595; padding: 8px 12px; }
.avlu-page .panel-nav button.is-active { background: #55241a; color: #ffe1a5; border-color: #a57950; }
.avlu-page .panel-body { min-width: 0; grid-template-columns: minmax(0, 1fr); }
.avlu-page .panel-body > section { min-width: 0; }
.avlu-page .balance-strip { grid-template-columns: repeat(2,minmax(0,1fr)); }
.avlu-page .balance-cell { background: linear-gradient(120deg,#432c1c,#201510); border-color: #785434; }
.avlu-page .balance-cell strong, .avlu-page dd { overflow-wrap: anywhere; }
.avlu-page [data-panel-body]:not([hidden]) > .panel-card { margin-bottom: 12px; }
.avlu-page .kv { grid-template-columns: minmax(85px, 1fr) minmax(0, 2.6fr); }
.avlu-page .table-scroll { overflow-x: auto; }
.avlu-page .staff-inbox { grid-template-columns: minmax(0,1fr) minmax(0,1.65fr); }
.avlu-page .staff-filters { grid-template-columns: repeat(3,minmax(0,1fr)); }
.avlu-page .staff-inbox > * { min-width: 0; }

@container (max-width: 720px) {
  .avlu-intro { background-size: auto, 100% auto; }
  .avlu-home { grid-template-columns: minmax(0,1fr); }
  .avlu-home-aside { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .avlu-castle-vignette { display: none !important; }
  .avlu-page .avlu-auth-layout, .avlu-download-layout, .avlu-page .staff-inbox, .avlu-page .support-layout { grid-template-columns: minmax(0,1fr); }
  .avlu-page .news-grid-page { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .avlu-guide-start .avlu-steps { grid-template-columns: minmax(0,1fr); }
  .avlu-page .avlu-auth-aside { min-height: 150px; }
}
@container (max-width: 480px) {
  .avlu-intro { min-height: 132px; padding: 15px 12px; }
  .avlu-home-aside, .avlu-feature, .avlu-page .news-grid-page { grid-template-columns: minmax(0,1fr); }
  .avlu-feature > img { height: 120px; }
  .avlu-page .avlu-nation .classes { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .avlu-page :is(.field-row,.form-grid,.staff-filters), .avlu-requirements dl { grid-template-columns: minmax(0,1fr); }
  .avlu-page .panel-nav button { padding: 6px 8px; }
  .avlu-home-news #court-news a, .avlu-update-list #court-news a { grid-template-columns: minmax(0,1fr); grid-template-areas: "category" "title"; justify-items: start; }
}
#account-popup iframe { max-height: calc(95dvh - 70px); }

/* Account and sign-in */
.account-page :is(.panel-shell, [data-panel-body])[hidden] { display: none; }
.account-page .avlu-page {
  --avlu-card: linear-gradient(135deg, #2e2117ef, #1c1510f5 68%, #24180ff5),
    url('../avlu/nav-avlu-stone.webp') center / cover;
}
.account-page .avlu-page .panel-aside {
  padding: clamp(10px, 1.6cqw, 22px);
  background: linear-gradient(90deg, #281a12 15%, #211710ef 54%, #21160cce),
    url('../avlu/castle.webp') center 40% / cover;
}
.account-page .avlu-page .panel-user {
  gap: 4px 13px;
  padding: 2px;
  background: transparent;
}
.account-page .avlu-page .panel-user-avatar {
  width: clamp(42px, 5cqw, 60px);
  height: auto;
  aspect-ratio: 1;
  border: 1px solid #a27648;
  border-radius: 0;
  background: radial-gradient(at 45% 10%, #6a4328, #2e1b13 75%);
  box-shadow: inset 0 0 0 3px #20130ea1, 0 3px 8px #0c0906a8;
  color: #ffe2a9;
  font: 700 clamp(16px, 2.1cqw, 25px)/1 Georgia, serif;
}
.account-page .avlu-page .panel-user-name { color: #ffe7bb; font: 700 clamp(16px, 2cqw, 24px)/1.2 Georgia, serif; }
.account-page .avlu-page .panel-nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-flow: row; gap: 4px; padding: 0; }
.account-page .avlu-page .panel-nav button {
  justify-content: center;
  min-height: 42px;
  background: #20160edb;
  border-color: #8b65428c;
  color: #ecd2a8;
  text-align: center;
  white-space: normal;
}
.account-page .avlu-page .panel-nav button:is(:hover, :focus-visible) { background: #442b19; color: #ffeac1; }
.account-page .avlu-page .panel-nav button.is-active {
  background: linear-gradient(#5e2c20, #391b13);
  border-color: #b1784b;
  box-shadow: inset 0 -2px #c18a50a6;
}
.account-page .balance-strip { margin-bottom: 14px; }
.account-page .avlu-page .balance-cell { padding: clamp(12px, 1.8cqw, 24px); }
.account-page .avlu-page .balance-cell small { color: #e2bc90; }
.account-shop-link {
  display: block;
  width: fit-content;
  padding: 5px 0;
  border: 0;
  background: transparent;
  color: #edc58b;
  font: 600 13px/1.3 var(--font-ui);
  text-align: left;
  cursor: pointer;
}
.account-shop-link:hover { color: #ffdfa4; text-decoration: underline; text-underline-offset: 3px; }
.account-page .avlu-page .panel-card-head { gap: 10px; background: linear-gradient(110deg, #573721a8, #2b1c13a8 72%); }
.account-page .avlu-page .kv { row-gap: 0; }
.account-page .avlu-page .kv > * { padding-block: 7px; border-bottom: 1px solid #8e64382d; }
.account-page .avlu-page .kv > :nth-last-child(-n+2) { border-bottom: 0; }

.account-page .avlu-page .cash-store {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 20px;
  padding: clamp(18px, 3cqw, 44px);
  background: linear-gradient(110deg, #21150ce6 8%, #2f1d10ec 58%, #20150dcc),
    url('../avlu/castle.webp') center 52% / cover;
  border-color: #ad7846;
}
.cash-store-provider { display: inline-block; margin-bottom: 8px; color: #dfb583; font: 600 13px/1.3 var(--font-ui); }
.cash-store h2 { color: var(--avlu-title); font: 700 clamp(26px, 3.6cqw, 43px)/1.16 Georgia, serif; }
.cash-store p { max-width: 50ch; margin-top: 8px; color: #ead8ba; }
.cash-store-action { display: grid; gap: 8px; justify-items: start; }
.cash-store-action .badge { color: #f1ce92; border-color: #b781514d; }
.cash-store-action .btn:disabled { opacity: .65; cursor: default; }

.game-pin-list { display: grid; gap: 10px; }
.game-pin-list [hidden] { display: none; }
.game-pin-list > p { color: #dfc39d; }
.game-pin-list > p:empty { display: none; }
#game-pins-refresh { justify-self: start; }
.game-pin {
  border: 1px solid #8b624075;
  background: linear-gradient(115deg, #291c13, #20160f);
}
.game-pin summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  padding: 12px 14px;
  color: #f2d2a0;
  font: 700 clamp(15px, 1.85cqw, 20px)/1.2 Georgia, serif;
  cursor: pointer;
}
.game-pin summary::before { content: '›' / ''; color: #c28e59; font-size: 1.35em; line-height: .8; }
.game-pin summary::-webkit-details-marker { display: none; }
.game-pin[open] summary::before { transform: rotate(90deg); }
.game-pin summary:is(:hover, :focus-visible) { background: #58391c4d; }
.game-pin summary:focus-visible { outline: 2px solid #ffda91; outline-offset: -2px; }
.game-pin-state {
  margin-inline-start: auto;
  color: #e1bb8c;
  font: 600 12px/1.3 var(--font-ui);
}
.game-pin-state.is-configured { color: #b5ca92; }
.game-pin-help { margin-inline: 14px; padding-block: 10px; border-top: 1px solid #8b62404d; color: #ddc5a7; }
.game-pin-editor { padding: 2px 14px 14px; }
.game-pin-editor fieldset { min-inline-size: 0; padding: 0; border: 0; }

.avlu-page .avlu-login {
  background: linear-gradient(145deg, #322115f2, #1a120ef7 53%, #25170ff2),
    url('../avlu/nav-avlu-stone.webp') center / cover;
}
.avlu-login-head { margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid #96704a80; }
.avlu-login .avlu-login-head h2 {
  margin-bottom: 6px;
  color: #f8d69e;
  font: 700 clamp(22px, 4.2cqw, 33px)/1.16 Georgia, serif;
  text-shadow: 0 2px 4px #140a05;
}
.avlu-login .auth-card-sub { margin-bottom: 0; color: #e6cfb0; }
.avlu-login .form-foot { margin-top: 18px; padding-top: 13px; border-top: 1px solid #8e62395e; }

@container (max-width: 600px) {
  .account-page .avlu-page .panel-nav { width: 100%; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-page .avlu-page .cash-store { grid-template-columns: minmax(0, 1fr); }
}
