.geometry-universe-active { --gw-gold: #f6d48b; --gw-ink: #f4f0e6; }
.geometry-universe-active [hidden] { display: none !important; }
.geometry-universe-active .study-kicker { color: var(--gw-gold); letter-spacing: .03em; }
.geometry-universe-active .study-heading h1 { max-width: 26ch; }
.geometry-universe-active .study-subtitle { max-width: 68ch; }
.gw-lesson { color: #f4f0e6; }
.gw-section { padding: 1.6rem 0; border-bottom: 1px solid rgba(246,212,139,.16); }
.gw-section h2 { margin: 0 0 .9rem; font-size: clamp(1.35rem,2.7vw,1.8rem); line-height: 1.25; color: #f6d48b; }
.gw-section h3 { margin: 1.3rem 0 .7rem; color: #f6d48b; }
.gw-section p, .gw-section li { max-width: 78ch; line-height: 1.75; }
.gw-section ol, .gw-section ul { padding-left: 1.5rem; }
.gw-section li + li { margin-top: .65rem; }
.gw-section a, .gw-source a { color: #f6d48b; }
#qg.geometry-universe-hub .section-nav-back { width: auto; min-width: 5rem; height: 2.75rem; margin-top: 0; padding: 0 1rem; border: 1px solid #b9ab7877; border-radius: .5rem; clip-path: none; background: #24251d; box-shadow: none; filter: none; }
#qg.geometry-universe-hub .section-nav-back::before { content: "Voltar"; color: #e3c375; font: 600 .875rem/1.4 system-ui,sans-serif; }
#qg.geometry-universe-hub .section-nav-back:hover { transform: none; background: #3b3826; }
.gw-hub-intro { margin-bottom: 1rem; grid-column: 1 / -1; }
.gw-hub-block { grid-column: 1 / -1; width: 100%; margin: 0 0 1.8rem; }
.gw-lesson-list { list-style: none; padding: 0 !important; margin: 1.2rem 0 0; }
.gw-lesson-list li { max-width: none; margin: 0 !important; border-bottom: 1px solid rgba(246,212,139,.14); }
.gw-lesson-link { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; padding: 1.1rem .5rem; text-decoration: none; color: #f6ead4 !important; border-radius: .4rem; }
.gw-lesson-link:hover { background: rgba(246,212,139,.07); }
.gw-lesson-link strong { font-size: 1.12rem; line-height: 1.4; display: block; }
.gw-lesson-description { display: block; margin-top: .4rem; font-size: .95rem; color: #d6d4d0; line-height: 1.6; }
.gw-study-action { flex: 0 0 auto; color: #e3c375; font: 600 .875rem/1.4 system-ui,sans-serif; }
.gw-internal-nav { display: flex; flex-wrap: wrap; gap: .65rem 1.2rem; padding: 1rem 0; margin: .5rem 0 1.5rem; border-bottom: 1px solid rgba(246,212,139,.22); }
.gw-internal-nav a { color: #f6d48b; padding: .5rem 0; text-underline-offset: .3em; }
.gw-source { margin: 0; }
.gw-source > section { margin: 1.4rem 0; }
.gw-lesson .math-concept, .gw-lesson .review-theory { background: transparent; border: 0; box-shadow: none; padding: 1.3rem 0; }
.gw-lesson .math-hero { background: transparent; border: 0; box-shadow: none; padding: 1.2rem 0 1.6rem; display: block; }
.gw-lesson .math-hero h2 { color: #f6d48b; }
.gw-lesson .math-hero p, .gw-lesson .math-concept p { line-height: 1.75; }
.gw-lesson .math-goals { border-color: rgba(246,212,139,.2); background: rgba(246,212,139,.035); }
.gw-practice { padding: 1.1rem 0; border-block: 1px solid rgba(246,212,139,.2); margin: 1.7rem 0; }
.gw-practice > summary, .gw-proof-extension > summary, .gw-section details > summary { cursor: pointer; padding: .65rem .1rem; font-weight: 700; color: #f6d48b; line-height: 1.6; }
.gw-practice > section { margin: 1.4rem 0; }
.gw-lab { padding: 1.7rem; margin: 1.5rem 0; border: 1px solid rgba(246,212,139,.24); border-radius: 1rem; background: rgba(246,212,139,.04); }
.gw-controls { display: flex; gap: .65rem; flex-wrap: wrap; margin: 1.1rem 0; }
.gw-controls button { border: 1px solid rgba(246,212,139,.38); border-radius: .55rem; padding: .75rem .85rem; min-height: 44px; background: #162d40; color: #f3ece1; font: inherit; font-size: .95rem; cursor: pointer; }
.gw-controls button[aria-pressed="true"] { background: #f6d48b; color: #162d40; border-color: #f6d48b; }
.gw-lesson :focus-visible, .gw-lesson-link:focus-visible { outline: 3px solid #8ef0d3; outline-offset: 4px; }
.gw-lab label { display: flex; gap: .7rem; align-items: center; flex-wrap: wrap; margin: 1rem 0; }
.gw-lab input[type="range"] { accent-color: #f6d48b; flex: 1 1 180px; min-height: 44px; }
.gw-lab output { font-variant-numeric: tabular-nums; }
.gw-figure, .gw-lesson svg.math-geometry-figure { display: block; width: 100%; max-width: 44rem; height: auto; min-height: 0; margin: 1.2rem auto; overflow: hidden; }
.gw-figure { background: #102334; border-radius: .5rem; }
.gw-figure text, .gw-lesson .tales-figure svg text { fill: #f4f0e6; font: 17px system-ui,sans-serif; }
.gw-base { stroke: #9ce6d7; stroke-width: 3; }
.gw-accent { stroke: #f6d48b; stroke-width: 4; }
.gw-dashed { stroke-dasharray: 9 6; }
.gw-construction { stroke: #f6d48b; stroke-width: 2; opacity: .8; }
.gw-radius { stroke: #9ce6d7; stroke-width: 2; stroke-dasharray: 6 5; }
.gw-side-extension { stroke: #79909e; stroke-width: 1; stroke-dasharray: 6 6; }
.gw-point, .gw-small-point { fill: #9ce6d7; }
.gw-center-point { fill: #f6d48b; stroke: #102334; stroke-width: 2; }
.gw-geometric-circle { fill: none; stroke: #9ce6d7; stroke-width: 2; }
.gw-triangle { fill: rgba(126,218,192,.08); stroke: #e7efeb; stroke-width: 2; }
.gw-drag { fill: #f6d48b; fill-opacity: .5; stroke: transparent; stroke-width: 44; vector-effect: non-scaling-stroke; pointer-events: all; cursor: grab; touch-action: none; }
.gw-drag:active { cursor: grabbing; }
.gw-drag:focus-visible { fill: #8ef0d3; fill-opacity: 1; }
.gw-angle-selected { fill: #f6d48b !important; font-weight: 800 !important; font-size: 22px !important; }
.gw-area-one { fill: #f6d48b; opacity: .23; }
.gw-area-two { fill: #80e7cb; opacity: .23; }
.gw-area-piece { fill: rgba(246,212,139,.3); stroke: #f6d48b; stroke-width: 2; }
.gw-compass-circle { fill: none; stroke: #f6d48b; stroke-width: 1.5; stroke-dasharray: 6 5; opacity: .6; }
.gw-lab select { padding: .7rem; min-height: 44px; color: #f4f0e6; background: #102334; border: 1px solid #8b9da1; border-radius: .4rem; font: inherit; }
.gw-tile-board { display: grid; grid-template-columns: repeat(4,1fr); width: min(100%,17rem); border: 1px solid #9ce6d7; gap: 2px; padding: 2px; margin: 1.2rem auto; }
.gw-tile-board button { aspect-ratio: 1; min-width: 44px; min-height: 44px; background: #122b3d; border: 1px solid #587687; cursor: pointer; }
.gw-tile-board button[aria-pressed="true"] { background: #f6d48b; border-color: #f6d48b; }
.gw-coordinates { margin: 1.5rem 0; padding: .8rem 1rem; border: 1px solid rgba(246,212,139,.25); border-radius: .5rem; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .8rem; }
.gw-coordinates legend { padding: 0 .4rem; line-height: 1.5; }
.gw-coordinates > div { min-width: 0; }
.gw-coordinates label { margin: .6rem 0; display: flex; flex-wrap: nowrap; }
.gw-coordinates input { min-width: 0; width: 100%; max-width: 7rem; padding: .65rem .5rem; min-height: 44px; background: #102334; border: 1px solid #8b9da1; border-radius: .3rem; color: #f4f0e6; font: inherit; }
.gw-table-wrap { overflow-x: auto; margin: 1.3rem 0; }
.gw-table-wrap table { border-collapse: collapse; width: 100%; font-size: .95rem; line-height: 1.6; }
.gw-table-wrap caption { text-align: left; padding: .7rem 0; font-weight: 700; color: #f6d48b; }
.gw-table-wrap th, .gw-table-wrap td { padding: .8rem; text-align: left; border: 1px solid rgba(246,212,139,.22); vertical-align: top; }
.gw-table-wrap thead { background: rgba(246,212,139,.06); }
@media(max-width:650px) {
  .gw-lab { padding: 1rem .75rem; }
  .gw-lesson-link { align-items: flex-start; gap: .6rem; padding: 1rem .2rem; }
  .gw-study-action { padding-top: .2rem; }
  .gw-lesson-description { font-size: .88rem; }
  .gw-coordinates { grid-template-columns: 1fr; }
  .gw-coordinates > div { display: flex; align-items: center; gap: .8rem; }
  .gw-coordinates label { flex: 1; }
  .gw-controls button { flex: 1 1 130px; }
  .gw-figure text { font-size: 29px; }
  .gw-figure .gw-angle-selected { font-size: 31px !important; }
  .gw-table-wrap th, .gw-table-wrap td { padding: .55rem; }
  .gw-section h2 { overflow-wrap: anywhere; }
}
@media(prefers-reduced-motion:reduce) { .gw-lesson *, .gw-lesson-link, #qg.geometry-universe-hub .section-nav-back { scroll-behavior: auto !important; transition: none !important; } }
