/* 原子结构特有样式（通用样式见 ../shared/base.css） */

#atom { position: absolute; inset: 0; touch-action: manipulation; }
[hidden] { display: none !important; }

.seg.wide { display: flex; width: 100%; }
.seg.wide button { flex: 1; font-size: 13px; padding: 5px 0; }
.scenes { margin: 0 0 12px; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.btns.tight { margin: 0 0 0 auto; gap: 4px; }
.btns.tight .small { padding: 0 10px; font-size: 15px; line-height: 20px; }
#panel h2 .h2s { font-size: 11px; color: var(--muted); font-weight: normal; margin-left: 6px; letter-spacing: 0; }

/* 读数 */
.readout .big { font-size: 18px; }
#rSym { font-family: var(--mono); }
#rSym.cation { color: #ff8a65; }
#rSym.anion { color: #64b5f6; }
.readout .tip { font-size: 12px; color: var(--accent); margin-top: 4px; }
.readout dd { font-variant-numeric: tabular-nums; }
.readout dt { white-space: nowrap; }
.eq { color: var(--muted); }
.lt { color: #ff8a65; }
.gt { color: #64b5f6; }
#rFact { margin-top: 8px; }

/* 1–20 号元素周期表 */
.ptable { display: grid; grid-template-columns: 14px repeat(8, 1fr); gap: 3px; }
.ptable .gh, .ptable .rh { font-size: 10px; color: var(--muted); text-align: center; align-self: end; }
.ptable .rh { align-self: center; }
.ptable .el { position: relative; font: inherit; padding: 9px 0 2px; color: var(--text); background: var(--panel-2);
  border: 1px solid var(--line); border-top: 2px solid var(--c); border-radius: 5px; cursor: pointer; line-height: 1.1; min-width: 0; }
.ptable .el i { position: absolute; left: 3px; top: 1px; font-style: normal; font-size: 9px; color: var(--muted); font-family: var(--mono); }
.ptable .el b { display: block; font-size: 15px; }
.ptable .el span { display: block; font-size: 10px; color: var(--muted); }
.ptable .el:hover { border-color: var(--c); }
.ptable .el.on { background: var(--c); border-color: var(--c); color: #111; }
.ptable .el.on i, .ptable .el.on span { color: #111; }
.metal { --c: #ffb36b; }
.nonmetal { --c: #4fc3f7; }
.noble { --c: #c9a7ff; }
.legend { align-items: center; }
.legend .lg { width: 10px; height: 10px; border-radius: 2px; background: var(--c); }

/* 按钮组 */
.presets { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.presets.three { grid-template-columns: 1fr 1fr 1fr; }
.presets button, .isos button, .qopts button { font: inherit; font-size: 13px; color: var(--text); background: var(--panel-2);
  border: 1px solid var(--line); border-radius: 8px; padding: 6px 0; cursor: pointer; }
.presets button:hover:not(:disabled), .isos button:hover, .qopts button:hover:not(:disabled) { border-color: var(--accent); }
.presets button.on, .isos button.on { border-color: var(--accent); background: rgba(255,201,74,.14); }
.presets button:disabled { opacity: .4; cursor: default; }

.isos { display: flex; flex-wrap: wrap; gap: 6px; }
.isos button { flex: 1 1 56px; padding: 4px 6px; }
.isos b { display: block; font-size: 15px; font-family: var(--mono); }
.isos small { font-size: 11px; color: var(--muted); }

/* 离子的形成：步骤 */
.tsteps { margin: 10px 0 0; padding-left: 22px; font-size: 13px; }
.tsteps li { margin: 3px 0; color: var(--muted); cursor: pointer; }
.tsteps li.cur { color: var(--accent); font-weight: 600; }
.tsteps li.done { color: var(--text); }
.raykey { list-style: none; padding: 0; margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.raykey li { margin: 4px 0; }
.raykey .dot, .raykey .ring { display: inline-block; width: 9px; height: 9px; border-radius: 50%; vertical-align: middle; margin-right: 6px; }
.raykey .ring { border: 1px dashed #ff6ec7; }

/* 练习 */
.score { font-size: 13px; color: var(--muted); font-weight: normal; margin-left: auto; }
.qopts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.qopts button { font-family: var(--mono); font-size: 18px; padding: 8px 0; }
.qopts button:disabled { cursor: default; }
.qopts button.right { border-color: #7ee081; background: rgba(126,224,129,.16); }
.qopts button.wrong { border-color: #ff6b6b; background: rgba(255,107,107,.16); }
#qFeedback.ok { color: #7ee081; }
#qFeedback.bad { color: #ff9b8a; }
.rules { margin: 0; padding-left: 18px; font-size: 13px; }
.rules li { margin: 3px 0; }
.rules b.c { color: #ff8a65; }
.rules b.a { color: #64b5f6; }
