/* Inner portal refinement. Keep the approved homepage, artwork and all data intact. */
:root {
  --portal-silver: #eff8f1;
  --portal-soft: #c2d5d0;
  --portal-gold: #ffe17b;
  --portal-card: linear-gradient(132deg, #e4fff411, transparent 48%, #e9d79905), rgba(8, 20, 21, .48);
}

/* Inner routes get the same generous working area as the approved arrival. */
.portal-layout:not(:has(#inicio:not([hidden]))) {
  grid-template-columns: 210px minmax(0, 1fr);
}
.portal-layout:not(:has(#inicio:not([hidden]))) > .portal-rail { display: none; }
.portal-main:not(:has(#inicio:not([hidden]))) { min-width: 0; }
.portal-main:not(:has(#inicio:not([hidden]))) .portal-pagebar {
  margin: 0 0 18px;
  padding: 0 6px;
}
.portal-main:not(:has(#inicio:not([hidden]))) .portal-pagebar :is(p, strong, .portal-language) { font-size: .875rem; }
.portal-main:not(:has(#inicio:not([hidden]))) > :is(.section, .portal-account, .dex-panel) {
  --page-accent: #8befce;
  position: relative;
  padding: clamp(22px, 3vw, 44px);
  border-radius: 24px;
  border-color: #d5f2ee30;
  border-top-color: #e4fff35c;
  box-shadow: inset 0 1px 0 #ffffff12, 0 24px 65px #0004;
  margin-top: 0;
  margin-bottom: 24px;
  min-width: 0;
}
.portal-main:not(:has(#inicio:not([hidden]))) :is(.section-heading h2, .world-map-heading h2, .drawer-head h2, .dex-heading h1, .download-copy h2, .faq-layout h2, .maintenance-section h2) {
  font-family: var(--display);
  font-size: clamp(1.85rem, 3vw, 2.7rem);
  line-height: 1.16;
  font-weight: 750;
  letter-spacing: -.04em;
  text-transform: none;
  color: var(--portal-silver);
}
.portal-main:not(:has(#inicio:not([hidden]))) :is(.kicker, .dex-eyebrow, .profile-eyebrow) {
  font-size: .8125rem;
  line-height: 1.6;
  letter-spacing: .13em;
}
.portal-main:not(:has(#inicio:not([hidden]))) :is(.section-heading, .world-map-heading) { margin-bottom: 30px; }
.portal-main:not(:has(#inicio:not([hidden]))) :is(.section-heading p:not(.kicker), .world-map-heading p:not(.kicker), .download-copy > p:not(.kicker), .faq-layout > div > p:not(.kicker)) {
  font-size: 1rem;
  line-height: 1.75;
  max-width: 62ch;
  color: var(--portal-soft);
}
.portal-main:not(:has(#inicio:not([hidden]))) :is(button, a, input, select, summary):focus-visible {
  outline: 2px solid var(--portal-gold);
  outline-offset: 4px;
}
.portal-main:not(:has(#inicio:not([hidden]))) :is(.button, .account-primary, .account-secondary, .card-link, .text-link) { min-height: 44px; }
.portal-main:not(:has(#inicio:not([hidden]))) :is(.card-link, .text-link) { display: inline-flex; align-items: center; }

/* Pokédex: collectible-looking single-frame portraits, working controls first. */
#pokedex .dex-heading { align-items: center; }
.dex-panel .dex-heading { margin-bottom: 28px; }
.dex-panel .dex-tabs {
  padding: 5px;
  border-radius: 12px;
  margin-bottom: 28px;
  background: #05161280;
}
.dex-panel .dex-tabs a { border-radius: 8px; padding-inline: 26px; }
.dex-panel .dex-tabs a[aria-current="page"] {
  background: linear-gradient(120deg, #fff09b, #ffda58);
  box-shadow: 0 2px 14px #e1bf3117;
}
.dex-panel .dex-counter {
  border: 1px solid #ffe17b38;
  border-radius: 16px;
  background: linear-gradient(125deg, #ffe17b12, #ffe17b03);
  padding: 20px 24px;
}
.dex-panel .dex-counter strong { font-family: var(--display); font-size: 2.4rem; }
.dex-panel .dex-counter span { font-size: .875rem; }
.dex-panel .dex-controls { padding: 22px; border-radius: 16px; gap: 18px; background: var(--portal-card); }
.dex-panel .dex-controls :is(input, select) { border-radius: 10px; min-height: 50px; }
.dex-panel .dex-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.dex-panel .dex-card {
  padding: 18px 16px 22px;
  border-radius: 19px;
  background: radial-gradient(ellipse at 50% 36%, color-mix(in srgb, var(--dex-accent) 9%, transparent), transparent 64%), var(--portal-card);
  border-color: color-mix(in srgb, var(--dex-accent) 26%, #172523);
  box-shadow: inset 0 1px 0 #ffffff0e, 0 8px 22px #0002;
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.dex-panel .dex-card:hover {
  transform: translateY(-4px);
  border-color: var(--dex-accent);
  box-shadow: inset 0 1px 0 #ffffff18, 0 14px 28px #0005;
}
.dex-panel .dex-portrait { height: 150px; margin-block: 10px 14px; }
.dex-panel .dex-portrait img { width: 112px; height: 112px; }
.dex-panel .dex-portrait::after { width: 90px; bottom: 12px; }
.dex-panel .dex-card h2 { font-size: 1.25rem; line-height: 1.3; min-height: 3.25rem; margin-bottom: 16px; }
.dex-panel .dex-number { font-size: .875rem; }
.dex-panel .dex-form { font-size: .75rem; border-radius: 6px; padding: 3px 8px; }
.dex-panel .dex-type { font-size: .875rem; border-radius: 7px; padding: 5px 10px; }
.dex-panel .dex-results-head { margin-block: 22px 14px; }
.dex-panel .dex-pagination { justify-content: space-between; gap: 12px; padding: 16px 0 0; border-top: 1px solid var(--line); }
.dex-panel .dex-pagination-top { margin-top: 0; padding: 0 0 18px; border-top: 0; border-bottom: 1px solid var(--line); }
.dex-panel .dex-pagination button { border-radius: 10px; min-width: 118px; min-height: 46px; }
.dex-panel .dex-pagination span { font-size: .875rem; }
.dex-panel .dex-footnote { font-size: .875rem; line-height: 1.75; }
.dex-panel .dex-message { border-radius: 16px; padding: 36px 24px; background: var(--portal-card); }

/* Natures remain the server's real catalogue, with clearer reading and spacing. */
#natures .nature-signature { padding: 24px; gap: 22px; border-radius: 18px; background: linear-gradient(135deg, #c9b2ff0e, #c9b2ff03); border-color: #c9b2ff38; }
#natures .nature-signature strong { font-family: var(--display); font-size: 2.4rem; }
#natures .nature-signature > span { font-size: .875rem; }
#natures .nature-explainer { padding: 24px 28px; gap: 30px; border-radius: 14px; background: var(--portal-card); }
#natures .nature-explainer p, #natures .nature-legacy p { font-size: 1rem; line-height: 1.75; }
#natures .nature-table-wrap { border-radius: 18px; }
#natures .nature-table { font-size: 1rem; }
#natures .nature-table th { font-size: .875rem; padding: 18px 22px; background: #20322e90; }
#natures .nature-table td { padding: 20px 22px; }
#natures .nature-table tr:nth-child(even) td { background: #bdeed305; }
#natures .nature-name { font-size: 1.0625rem; }
#natures .nature-custom { font-size: .8125rem; }
#natures .nature-legacy { border-radius: 16px; padding: 26px; }

/* Map: generous canvas, no visual overlay on the actual terrain. */
#universo .world-map { border-radius: 18px; box-shadow: 0 18px 40px #0004; }
#universo .world-map-toolbar { padding: 14px; gap: 10px; }
#universo .world-map button, #universo .world-map select { border-radius: 10px; }
#universo .world-map [data-map-expand] { border-color: #e7ce7a66; color: var(--portal-gold); }
#universo .world-map-help { padding: 14px 18px; background: #091815; }
#universo .world-map-status { padding: 4px 10px; border: 1px solid #ffe17b30; border-radius: 6px; background: #ffe17b09; }
#universo .world-map-note { font-size: .875rem; margin-top: 16px; }
#universo .pillars-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 30px; }
#universo .pillar { padding: 22px; border: 1px solid var(--line); border-radius: 15px; background: var(--portal-card); }
#universo .pillar-number { color: #8befce; font-size: .875rem; }
#universo .pillar h3 { font-size: 1.25rem; margin-block: 16px 10px; }
#universo .pillar p { font-size: 1rem; line-height: 1.7; color: var(--portal-soft); }

/* Account: original client art beside the real login, never behind the fields. */
.portal-account .account-drawer { padding: 0; }
.portal-account .drawer-head { align-items: center; padding-bottom: 24px; }
.portal-account .drawer-head::after { display: none; }
.portal-account .drawer-notice { border-radius: 12px; margin-block: 22px; padding: 16px 20px; }
.portal-account .drawer-notice p { font-size: 1rem; }
.portal-account .account-tabs {
  display: flex;
  gap: 6px;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 28px;
  padding: 5px;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  background: #05161280;
}
.portal-account .account-tabs button { min-width: 128px; padding: 12px 22px; border-radius: 8px; font-size: .9375rem; }
.portal-account .account-tabs button[aria-selected="true"] { background: linear-gradient(120deg, #fff09b, #ffda58); color: #181c13; }
.portal-account .account-panel { max-width: none; margin: 0; }
.portal-account #account-panel-login:not([hidden]) { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 64px); align-items: stretch; }
.trainer-welcome-art {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 410px;
  padding: 35px;
  border: 1px solid #d9ecca38;
  border-radius: 20px;
  background: linear-gradient(0deg, #041512e6, transparent 58%), url('/assets/journey-world-r1.webp') 79% center / cover;
  box-shadow: inset 0 1px 0 #ffffff20;
}
.trainer-welcome-art img { width: min(290px, 88%); height: auto; filter: none; }
.portal-account #journey-login { align-content: center; gap: 14px; padding: 16px 0; max-width: 520px; width: 100%; justify-self: center; }
.portal-account #journey-login h3 { font-family: var(--display); font-size: clamp(1.6rem, 2.4vw, 2.1rem); }
.portal-account #journey-login > .account-primary { margin-top: 4px; }
.portal-account .journey-account-form input:not([type=radio]) { min-height: 52px; border-radius: 10px; }
.portal-account .journey-account-form .password-field input { padding-right: 58px; }
.portal-account .journey-account-form small { font-size: .875rem; line-height: 1.65; }
.portal-account :is(.account-primary, .account-secondary) { border-radius: 10px; min-height: 48px; }
.portal-account .account-primary { background: linear-gradient(120deg, #fff09b, #ffda58); color: #181c13; box-shadow: inset 0 1px 0 #fff7, 0 5px 18px #e8bd3a12; }
.portal-account .account-primary:hover:not(:disabled) { background: #ffeba2; }
.portal-account #account-panel-register { max-width: none; }
.portal-account .registration-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding: 0; margin-bottom: 28px; border: 0; }
.portal-account .registration-steps li { padding: 17px 20px; font-size: .9375rem; border: 1px solid var(--line); border-radius: 12px; background: #ffffff03; }
.portal-account .registration-steps li span { font-size: .8125rem; }
.portal-account .registration-steps li[aria-current=step] { border-color: #ffe17b66; background: linear-gradient(120deg, #ffe17b12, #ffe17b03); box-shadow: inset 0 2px 0 #ffe17b; }
.portal-account #journey-register > fieldset:not([data-registration-step="2"]) { max-width: 720px; }
.portal-account #journey-register legend { font-family: var(--display); }
.portal-account .account-field-grid { grid-template-columns: 1fr 1fr; }
.portal-account .starter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.portal-account .starter-card { border-radius: 18px; padding: 20px; gap: 14px; grid-template-rows: auto 130px auto auto; background: var(--portal-card); }
.portal-account .starter-card.selected { padding: 19px; background: linear-gradient(130deg, #ffe17b12, #ffe17b03); box-shadow: 0 8px 24px #ffe17b0c; }
.portal-account .starter-type { font-size: .875rem; border-radius: 7px; }
.portal-account .starter-card h4 { font-size: 1.25rem; }
.portal-account .starter-card button { min-height: 46px; border-radius: 9px; }
.portal-account .starter-summary { padding: 20px; border-radius: 10px; }
.portal-account .account-actions { margin-top: 20px; gap: 14px; }
.portal-account #account-panel-recover { padding: 30px; border: 1px solid #ffe17b33; border-radius: 18px; background: linear-gradient(120deg, #ffe17b09, transparent); max-width: 760px; }
.portal-account #account-panel-recover h3 { font-size: 1.75rem; line-height: 1.25; }
.portal-account #account-panel-recover p { font-size: 1rem; line-height: 1.75; }
.portal-account .registration-success { padding: 28px; border: 1px solid #8befce38; border-radius: 18px; background: #8befce05; }

/* Private profile: same portraits, six slots and XP values, stronger presentation. */
.portal-account .profile-toolbar { padding-block: 24px; }
.portal-account .trainer-profile { grid-template-columns: minmax(240px, .8fr) minmax(0, 1.4fr); border-radius: 20px; background: var(--portal-card); }
.portal-account .trainer-stage { min-height: 350px; padding: 35px 24px; background: radial-gradient(ellipse at 50% 60%, #8befce16, transparent 65%), #8befce03; }
.portal-account #journey-profile .trainer-nickname { font-size: 1.7rem; margin-bottom: 14px; }
.portal-account .trainer-portrait { width: 180px; height: 170px; border-color: #a8dcb3; }
.portal-account .trainer-summary { padding: 38px; }
.portal-account #journey-profile .trainer-heading { font-size: clamp(1.5rem, 2.4vw, 2.15rem); }
.portal-account .trainer-stats { gap: 14px; }
.portal-account .trainer-stats > div { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: #ffffff03; }
.portal-account .trainer-stats dt, .portal-account .trainer-progress-heading, .portal-account .profile-status { font-size: .875rem; }
.portal-account .trainer-stats > div:first-child dd { font-family: var(--display); font-size: 2.1rem; }
.portal-account .profile-team { margin-top: 34px; }
.portal-account .team-member { border-radius: 17px; padding: 20px; background: var(--portal-card); }
.portal-account .team-member.is-empty { border-style: dashed; background: #ffffff01; }
.portal-account .team-portrait { background: radial-gradient(ellipse, #8befce0c, transparent 67%); }
.portal-account .profile-save-note { font-size: .875rem; line-height: 1.65; }
.portal-account :is(.profile-loading, .profile-empty, .profile-character) { border-radius: 16px; padding: 26px; }

/* News keeps the artwork-led hierarchy; homepage cards stay byte-for-byte styled. */
.portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured { grid-template-columns: 1.15fr 1fr; min-height: 340px; }
.portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured .news-art { height: 100%; min-height: 340px; }
.portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured .news-content { display: flex; flex-direction: column; justify-content: center; padding: 34px; }
.portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured .news-content h3 { font-size: clamp(1.55rem, 2.3vw, 2rem); }
.portal-main:not(:has(#inicio:not([hidden]))) .news-card:not(.news-card--featured) .news-art { height: 240px; }

/* Community: real existing destinations, honest maintenance states. */
#ecossistema .ecosystem-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
#ecossistema .ecosystem-card { padding: 30px; border-radius: 18px; background: var(--portal-card); }
#ecossistema .ecosystem-card--account { border-top: 2px solid #8befce80; }
#ecossistema .ecosystem-card h3 { font-size: 1.5rem; margin-block: 16px 12px; }
#ecossistema .ecosystem-card p, #ecossistema .ecosystem-card li { font-size: 1rem; line-height: 1.7; color: var(--portal-soft); }
#ecossistema .system-icon { width: 52px; height: 52px; border: 1px solid #8befce40; border-radius: 14px; display: grid; place-items: center; color: #8befce; background: #8befce07; font-size: 1.2rem; }
#ecossistema .status-pill { font-size: .8125rem; border-radius: 6px; }
#ecossistema .ecosystem-card--wide { grid-column: 1 / -1; display: grid; grid-template-columns: 1.3fr 1fr; gap: 36px; align-items: center; }
#ecossistema .support-links { display: grid; gap: 10px; margin-top: 0; }
#ecossistema .support-links button { min-height: 48px; border-radius: 10px; font-size: .9375rem; }
.portal-main :is(#rankings, #treinadores) .maintenance-notice { max-width: 800px; padding: 28px 32px; border-radius: 16px; border-left: 3px solid #ffe17b; background: var(--portal-card); }
.portal-main :is(#rankings, #treinadores) .maintenance-notice p { font-size: 1rem; line-height: 1.8; color: var(--portal-soft); margin-bottom: 0; }

/* Installation and help use a readable guide, not a second oversized homepage. */
#download .download-layout { grid-template-columns: 1fr 1fr; gap: 36px; align-items: stretch; }
#download::before { content: none; }
#download .download-copy { padding: 34px; border: 1px solid #c9e5c538; border-radius: 18px; background: linear-gradient(0deg, #051511bd, #051511f0 38%), url('/assets/journey-world-r1.webp') 78% center / cover; }
#download .download-copy h2 { margin-bottom: 22px; }
#download .compatibility { margin-top: 24px; font-size: .875rem; color: #b7d9c9; }
#download .download-options { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
#download .download-card { padding: 24px; border: 1px solid var(--glass-border); border-radius: 18px; background: var(--portal-card); gap: 16px; min-width: 0; }
#download .download-card--windows { grid-column: 1 / -1; display: grid; grid-template-columns: auto minmax(0, 1fr); border-color: #ffe17b66; background: linear-gradient(125deg, #ffe17b0d, transparent), rgba(16, 23, 18, .55); }
#download .download-card--windows .platform-icon { color: var(--portal-gold); }
#download .download-card h3 { font-size: 1.65rem; line-height: 1.2; margin-block: 6px 10px; }
#download .download-card p { font-size: 1rem; line-height: 1.6; }
#download .download-card small { font-size: .8125rem; line-height: 1.5; }
#download .download-card > .download-action { grid-column: 1 / -1; margin: 6px 0 0; min-height: 52px; border: 0; border-radius: 10px; background: linear-gradient(120deg, #fff09b, #ffda58); color: #181c13; width: 100%; font-size: 1rem; font-weight: 700; }
#download .download-card--muted { display: block; opacity: 1; background: #ffffff03; }
#download .download-card--muted .platform-icon { display: none; }
#download .download-card--muted h3 { font-size: 1.25rem; }
#download .download-card--muted p { font-size: .875rem; color: var(--portal-soft); }
#primeiros-passos .journey-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
#primeiros-passos .journey-steps li { display: flex; flex-direction: column; gap: 24px; padding: 28px; border: 1px solid var(--glass-border); border-radius: 18px; background: var(--portal-card); }
#primeiros-passos .journey-steps li > span { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 13px; background: #ffe17b0f; border: 1px solid #ffe17b38; color: var(--portal-gold); font: 650 1.2rem var(--display); }
#primeiros-passos .journey-steps h3 { font-size: 1.35rem; margin-bottom: 12px; }
#primeiros-passos .journey-steps p { font-size: 1rem; line-height: 1.75; color: var(--portal-soft); }
#ajuda .faq-layout { grid-template-columns: minmax(210px, .65fr) minmax(0, 1.35fr); gap: 48px; }
#ajuda .faq-list { display: grid; align-content: start; gap: 12px; }
#ajuda .faq-list details, #ajuda .faq-list details:first-child { border: 1px solid var(--glass-border); border-radius: 14px; padding: 0 22px; background: var(--portal-card); }
#ajuda .faq-list summary { padding-block: 22px; font-size: 1.0625rem; line-height: 1.5; gap: 18px; }
#ajuda .faq-list summary::after { flex-shrink: 0; color: var(--portal-gold); }
#ajuda .faq-list details[open] { border-color: #8befce70; background: #8befce05; }
#ajuda .faq-list p { font-size: 1rem; line-height: 1.8; margin: 0 0 24px; padding: 0; color: var(--portal-soft); }
.article-dialog { border-radius: 22px; border-color: var(--glass-border); background: #0c1919; color: var(--portal-silver); box-shadow: 0 35px 100px #0009; }
.article-dialog h2 { font-family: var(--display); line-height: 1.2; }
.article-dialog p { font-size: 1rem; line-height: 1.8; color: var(--portal-soft); }

@media (min-width: 821px) and (max-width: 1200px) {
  .portal-layout:not(:has(#inicio:not([hidden]))) { grid-template-columns: 190px minmax(0, 1fr); gap: 18px; }
  .dex-panel .dex-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  #universo .pillars-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .portal-account #account-panel-login:not([hidden]) { gap: 28px; grid-template-columns: minmax(0, .75fr) minmax(0, 1fr); }
  .trainer-welcome-art { padding: 20px; }
  .portal-account .trainer-summary { padding: 24px; }
  .portal-account .trainer-stats { grid-template-columns: 1fr; }
  .portal-account .trainer-stats > div { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
  .portal-account .trainer-stats dt { margin: 0; }
  #download .download-layout, #ajuda .faq-layout { grid-template-columns: 1fr; gap: 24px; }
  #primeiros-passos .journey-steps { grid-template-columns: 1fr; }
  #primeiros-passos .journey-steps li { flex-direction: row; }
  #primeiros-passos .journey-steps li > span { flex-shrink: 0; }
}
@media (max-width: 820px) {
  .portal-layout:not(:has(#inicio:not([hidden]))) { display: block; }
  .portal-main:not(:has(#inicio:not([hidden]))) > :is(.section, .portal-account, .dex-panel) { padding: 26px; border-radius: 20px; }
  .dex-panel .dex-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .dex-panel .dex-card { padding: 16px 12px; }
  #universo .pillars-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .portal-account #account-panel-login:not([hidden]) { grid-template-columns: 1fr; gap: 24px; }
  .trainer-welcome-art { min-height: 180px; padding: 22px; background-position: 79% 57%; }
  .trainer-welcome-art img { width: 180px; }
  .portal-account #journey-login { max-width: none; }
  .portal-account .trainer-profile { grid-template-columns: 1fr; }
  .portal-account .trainer-stage { min-height: 280px; border-right: 0; border-bottom: 1px solid var(--line); }
  .portal-account .trainer-summary { padding: 28px; }
  .portal-account .registration-steps li { padding: 15px; }
  #natures .nature-explainer { grid-template-columns: 1fr; gap: 16px; }
  #download .download-layout, #ajuda .faq-layout { grid-template-columns: 1fr; gap: 26px; }
  #primeiros-passos .journey-steps { grid-template-columns: 1fr; }
  #primeiros-passos .journey-steps li { flex-direction: row; }
  #primeiros-passos .journey-steps li > span { flex-shrink: 0; }
}
@media (max-width: 600px) {
  .portal-main:not(:has(#inicio:not([hidden]))) > :is(.section, .portal-account, .dex-panel) { padding: 22px 16px; border-radius: 17px; }
  .portal-main:not(:has(#inicio:not([hidden]))) .portal-pagebar :is(p, strong, .portal-language) { font-size: .8125rem; }
  .dex-panel .dex-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .dex-panel .dex-counter { padding: 12px 16px; align-items: baseline; width: 100%; border-radius: 12px; }
  .dex-panel .dex-counter strong { font-size: 1.85rem; }
  .dex-panel .dex-controls { padding: 16px; gap: 12px; }
  .dex-panel .dex-portrait { height: 120px; }
  .dex-panel .dex-portrait img { width: 96px; height: 96px; }
  .dex-panel .dex-card h2 { font-size: 1.0625rem; min-height: 2.8rem; }
  .dex-panel .dex-type { font-size: .8125rem; padding-inline: 7px; }
  .dex-panel .dex-pagination { flex-wrap: wrap; justify-content: center; }
  .dex-panel .dex-pagination button { min-width: 94px; padding-inline: 10px; }
  .dex-panel .dex-pagination span { white-space: normal; text-align: center; }
  .dex-panel .dex-tabs a { padding-inline: 20px; }
  #natures .nature-signature { gap: 24px; }
  #natures .nature-explainer { padding: 20px; }
  #natures .nature-table { min-width: 540px; }
  #natures .nature-table :is(th, td) { padding: 16px; }
  #natures .nature-legacy { padding: 20px; align-items: flex-start; }
  #universo .world-map-toolbar { padding: 10px; gap: 7px; }
  #universo .world-map-help { padding: 12px; }
  #universo .pillars-grid { gap: 10px; }
  #universo .pillar { padding: 17px; }
  .portal-account .account-tabs { width: 100%; }
  .portal-account .account-tabs button { flex: 1; min-width: 0; padding: 12px 9px; font-size: .875rem; }
  .portal-account .drawer-notice { padding: 14px; }
  .portal-account .registration-steps { gap: 8px; }
  .portal-account .registration-steps li { padding: 12px 9px; font-size: .875rem; }
  .portal-account .account-field-grid { grid-template-columns: 1fr; }
  .portal-account .starter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .portal-account .starter-card { padding: 14px 10px; grid-template-rows: auto 110px auto auto; }
  .portal-account .starter-card.selected { padding: 13px 9px; }
  .portal-account .starter-card h4 { font-size: 1.0625rem; }
  .portal-account .trainer-summary { padding: 24px 18px; }
  .portal-account .trainer-stats { grid-template-columns: 1fr; }
  .portal-account .trainer-stats > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .portal-account .trainer-stats dt { margin: 0; }
  .portal-account #account-panel-recover { padding: 22px; }
  .portal-account .registration-success { padding: 22px; }
  .portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured { display: block; min-height: 0; }
  .portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured .news-art,
  .portal-main:not(:has(#inicio:not([hidden]))) .news-card:not(.news-card--featured) .news-art { min-height: 0; height: 210px; }
  .portal-main:not(:has(#inicio:not([hidden]))) .news-card--featured .news-content { padding: 24px; }
  #ecossistema .ecosystem-grid, #ecossistema .ecosystem-card--wide { grid-template-columns: 1fr; }
  #ecossistema .ecosystem-card { padding: 24px; }
  #ecossistema .ecosystem-card--wide { gap: 24px; }
  #download .download-copy, #download .download-card { padding: 24px; }
  #download .download-options { gap: 12px; }
  #download .download-card--muted { padding: 18px; }
  #primeiros-passos .journey-steps li { padding: 24px 20px; gap: 18px; }
  #ajuda .faq-list details { padding-inline: 18px; }
  #ajuda .faq-list summary { font-size: 1rem; }
}
@media (max-width: 380px) {
  .dex-panel .dex-controls { grid-template-columns: 1fr; }
  .dex-panel .dex-form { font-size: .75rem; padding-inline: 4px; }
  .dex-panel .dex-card-top { flex-wrap: wrap; }
  #universo .pillars-grid { grid-template-columns: 1fr; }
  .portal-account .registration-steps { grid-template-columns: 1fr; }
  .portal-account .registration-steps li { display: flex; gap: 12px; align-items: center; }
  .portal-account .registration-steps li span { margin-bottom: 0; }
  #download .download-options { grid-template-columns: 1fr; }
  #primeiros-passos .journey-steps li { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  .dex-panel .dex-card { transition: none; }
  .dex-panel .dex-card:hover { transform: none; }
}
.effects-off .dex-panel .dex-card { transition: none; }
.effects-off .dex-panel .dex-card:hover { transform: none; }
@media (prefers-reduced-transparency: reduce) {
  :root { --portal-card: #14201e; }
  .portal-main:not(:has(#inicio:not([hidden]))) > :is(.section, .portal-account, .dex-panel) { background: #141d1b; backdrop-filter: none; -webkit-backdrop-filter: none; }
}
@media (forced-colors: active) {
  :root { --portal-card: Canvas; --portal-soft: CanvasText; --portal-silver: CanvasText; --portal-gold: LinkText; }
  .trainer-welcome-art { display: none; }
  .portal-account #account-panel-login:not([hidden]) { grid-template-columns: 1fr; }
  .portal-main:not(:has(#inicio:not([hidden]))) :is(.section, .portal-account, .dex-panel, .dex-card, .dex-counter, .dex-controls, .nature-signature, .nature-table th, .nature-table td, .nature-explainer, .trainer-stage, .trainer-profile, .starter-card, .journey-steps li, .download-copy, .download-card, .faq-list details) { background: Canvas; color: CanvasText; border-color: CanvasText; box-shadow: none; }
  .portal-main:not(:has(#inicio:not([hidden]))) :is(a, button, summary):focus-visible { outline-color: Highlight; }
  .portal-account .account-primary, #download .download-card > .download-action, .dex-panel .dex-tabs a[aria-current="page"], .portal-account .account-tabs button[aria-selected="true"] { color: HighlightText; background: Highlight; }
}
