/* Season 7 (Curse Research Lab) calculators - shared styles. Plain CSS, no build step. */
:root {
    --s7-sky: #f7dfa5;
    --s7-sand: #e2b866;
    --s7-sand-deep: #b9822f;
    --s7-night: #2a1a0a;
    --s7-accent: #d98a0b;
    --s7-accent-dark: #a85d06;
    --s7-ink: #3a2410;
    --s7-ink-soft: #7c5a2e;
    --s7-panel: #fff8ea;
    --s7-line: #ecd29b;
}
* { box-sizing: border-box; }
html { background: var(--s7-sand-deep); }
body.s7 {
    margin: 0;
    min-height: 100vh;
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    -webkit-tap-highlight-color: transparent;
    color: var(--s7-ink);
    background:
        radial-gradient(420px 420px at 82% 8%, rgba(255, 244, 200, .95) 0%, rgba(255, 224, 140, .55) 38%, transparent 70%),
        radial-gradient(150% 34% at 20% 104%, #a8701f 0 62%, transparent 63%),
        radial-gradient(130% 30% at 95% 101%, #c58a33 0 62%, transparent 63%),
        radial-gradient(160% 26% at 50% 98%, #d9a24a 0 62%, transparent 63%),
        linear-gradient(180deg, var(--s7-sky) 0%, var(--s7-sand) 55%, #c98f3c 100%) fixed;
    padding: 1rem 0.75rem 3rem;
}
.s7-back {
    position: fixed; top: 1rem; right: 1rem; z-index: 100;
    background: rgba(42, 26, 10, 0.92); border: 1px solid var(--s7-accent);
    color: #fff; text-decoration: none; font-size: 13px; font-weight: 700;
    padding: 8px 18px; border-radius: 12px; box-shadow: 0 4px 6px rgba(0,0,0,.3);
}
.s7-back:hover { background: #fff; color: var(--s7-night); }
.s7-top { display: block; width: max-content; margin: 1.6rem auto 0; background: rgba(42, 26, 10, 0.92); border: 1px solid var(--s7-accent);
    color: #fff; text-decoration: none; font-size: 13px; font-weight: 700; padding: 8px 18px; border-radius: 12px; box-shadow: 0 4px 6px rgba(0,0,0,.3); }
.s7-top:hover { background: #fff; color: var(--s7-night); }
.s7-wrap { max-width: 44rem; margin: 0 auto; }
.s7-card {
    background: rgba(255, 249, 236, 0.94);
    border: 1px solid rgba(169, 108, 20, 0.45);
    border-radius: 1rem;
    box-shadow: 0 20px 40px rgba(0,0,0,.4);
    padding: 1rem 1.25rem 1.5rem;
}
@media (min-width: 640px) { .s7-card { padding: 1rem 2.5rem 2rem; } }
.s7-kicker { text-align: center; margin: 2.5rem 0 0; font-size: .7rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--s7-accent-dark); }
.s7-title { text-align: center; font-size: 1.75rem; font-weight: 800; margin: .25rem 0 .25rem; color: #2a1708; }
.s7-sub { text-align: center; font-size: .8rem; color: var(--s7-ink-soft); margin: 0 0 1.25rem; }

.s7-label { display: block; font-size: .85rem; font-weight: 600; color: var(--s7-ink); margin-bottom: .35rem; }
.s7-input, .s7-select {
    width: 100%; padding: .6rem .7rem; font-size: .95rem; color: var(--s7-ink);
    background: #fffdf6; border: 1px solid var(--s7-line); border-radius: .6rem;
}
.s7-input:focus, .s7-select:focus { outline: 2px solid var(--s7-accent); border-color: var(--s7-accent); }
.s7-center { text-align: center; }
.s7-field { margin-bottom: 1rem; text-align: center; }
.s7-field .s7-input { max-width: 16rem; margin: 0 auto; display: block; }
.s7-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.s7-link { color: var(--s7-accent-dark); text-decoration: underline dotted; cursor: pointer; }

.s7-rows { display: flex; flex-direction: column; gap: .6rem; margin-bottom: 1rem; }
.s7-row {
    display: flex; align-items: center; justify-content: space-between; gap: .75rem;
    background: rgba(245, 158, 11, 0.08); border: 1px solid var(--s7-line);
    border-radius: .75rem; padding: .7rem .85rem;
}
.s7-row-name { font-weight: 600; font-size: .95rem; flex: 1 1 auto; }
.s7-row .s7-select { width: 5.5rem; }
.s7-row-val { font-size: .8rem; font-weight: 700; color: var(--s7-accent-dark); white-space: nowrap; text-align: right; min-width: 7.5rem; }
.s7-row-sub { font-size: .72rem; font-weight: 500; color: var(--s7-ink-soft); display: block; }
.s7-fountain-row { display: block; }
.s7-fountain-row .s7-row-top { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .5rem; }
.s7-fountain-row .s7-pair { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.s7-fountain-row .s7-pair label { font-size: .7rem; color: var(--s7-ink-soft); display: block; margin-bottom: .15rem; }

.s7-stepper { display: flex; align-items: stretch; justify-content: center; }
.s7-stepper .s7-select { border-radius: 0; width: auto; min-width: 4.5rem; text-align: center; }
.s7-step {
    background: #f6e2b8; border: 1px solid var(--s7-line); color: var(--s7-ink); cursor: pointer;
    padding: 0 .75rem; font-size: .8rem;
}
.s7-step:first-child { border-radius: .6rem 0 0 .6rem; }
.s7-step:last-child { border-radius: 0 .6rem .6rem 0; }
.s7-step:active { background: #edd08a; }

.s7-stat {
    display: flex; justify-content: space-around; gap: 1rem; margin: 0 0 1rem;
    background: rgba(245, 158, 11, 0.1); border: 1px solid var(--s7-line); border-radius: .75rem; padding: .85rem;
}
.s7-stat > div { text-align: center; }
.s7-stat .k { display: block; font-size: .75rem; font-weight: 600; color: var(--s7-ink-soft); margin-bottom: .2rem; }
.s7-stat .v { font-size: 1.15rem; font-weight: 800; color: var(--s7-accent-dark); }
.s7-stat .v.big { font-size: 1.35rem; }

.s7-btn {
    display: block; width: 100%; padding: .75rem 1rem; border-radius: .75rem; cursor: pointer;
    font-weight: 700; font-size: .95rem; margin-bottom: .6rem;
    background: #fff3d6; color: var(--s7-accent-dark); border: 1px solid var(--s7-line);
}
.s7-btn:hover { background: #ffe9b3; }

.s7-result {
    text-align: center; padding: 1.1rem; border-radius: .75rem; margin-bottom: 1rem;
    background: rgba(245, 158, 11, 0.12); border: 1px solid var(--s7-line);
}
.s7-result .head { font-weight: 800; font-size: 1.05rem; margin: 0 0 .3rem; }
.s7-result .time { font-size: 1.9rem; font-weight: 900; color: var(--s7-accent-dark); margin: 0 0 .6rem; }
.s7-result p { margin: .25rem 0; font-size: .85rem; }
.s7-result .small { font-size: .75rem; color: var(--s7-ink-soft); font-style: italic; }
.s7-ok { color: #15803d; font-weight: 800; }
.s7-bad { color: #b91c1c; font-weight: 700; }
.s7-warn {
    font-size: .75rem; background: #fff1c2; border: 1px solid #f3cf62; color: #7a4b00;
    border-radius: .6rem; padding: .5rem .7rem; margin: 0 0 1rem; text-align: left;
}

.s7-breakdown { width: 100%; border-collapse: collapse; font-size: .78rem; margin-top: .6rem; }
.s7-breakdown th, .s7-breakdown td { padding: .3rem .4rem; text-align: right; border-bottom: 1px solid var(--s7-line); }
.s7-breakdown th:first-child, .s7-breakdown td:first-child { text-align: left; }
.s7-breakdown tfoot td { font-weight: 800; border-top: 2px solid var(--s7-accent); border-bottom: none; }

details.s7-data { margin-top: 1.5rem; border: 1px solid var(--s7-line); border-radius: .75rem; background: rgba(255,253,246,.7); }
details.s7-data > summary { cursor: pointer; padding: .8rem 1rem; font-weight: 700; font-size: .9rem; color: var(--s7-ink); }
details.s7-data[open] > summary { border-bottom: 1px solid var(--s7-line); }
.s7-data-body { padding: .75rem; }
.s7-data-note { font-size: .72rem; color: var(--s7-ink-soft); margin: 0 0 .6rem; }
.s7-table-scroll { overflow-x: auto; }
.s7-table { width: 100%; border-collapse: collapse; font-size: .75rem; white-space: nowrap; }
.s7-table th, .s7-table td { padding: .3rem .5rem; text-align: right; border-bottom: 1px solid var(--s7-line); }
.s7-table th { position: sticky; top: 0; background: #f9e7bd; font-weight: 700; }
.s7-table th:first-child, .s7-table td:first-child { text-align: center; }
.s7-table tr.in-range td { background: rgba(245, 158, 11, 0.18); }
.s7-table tr.est td { font-style: italic; color: var(--s7-ink-soft); }

.s7-modal { position: fixed; inset: 0; background: rgba(0,0,0,.6); display: none; align-items: center; justify-content: center; padding: 1rem; z-index: 200; }
.s7-modal.open { display: flex; }
.s7-modal-box { background: #fff; border-radius: 1rem; max-width: 24rem; width: 100%; padding: 1.25rem; position: relative; }
.s7-modal-box h3 { margin: 0 0 .5rem; font-size: 1.05rem; }
.s7-modal-box p { margin: 0; font-size: .85rem; line-height: 1.5; color: var(--s7-ink-soft); }
.s7-modal-x { position: absolute; top: .4rem; right: .8rem; border: 0; background: none; font-size: 1.5rem; cursor: pointer; color: var(--s7-ink-soft); }

#google_translate_element { margin-top: 1.5rem; display: flex; justify-content: center; }

/* ---- Mummy / Doom Elite battle calculators ---- */
.s7-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin-bottom: .8rem; }
.s7-checks { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-bottom: 1rem; }
.s7-check {
    display: flex; align-items: center; gap: .5rem; padding: .45rem .6rem; cursor: pointer;
    background: #fffdf6; border: 1px solid var(--s7-line); border-radius: .6rem;
    font-size: .78rem; font-weight: 700; color: var(--s7-ink);
}
.s7-check input { width: 1rem; height: 1rem; accent-color: var(--s7-accent); }
.s7-mini { display: block; font-size: .68rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--s7-ink-soft); margin-bottom: .25rem; }
.s7-squad { background: rgba(255, 253, 246, .7); border: 1px solid var(--s7-line); border-radius: .75rem; padding: .75rem; margin-bottom: .75rem; }
.s7-squad-title { display: flex; justify-content: space-between; align-items: center; margin: 0 0 .5rem; font-size: .8rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--s7-accent-dark); }
.s7-squad-title label { display: flex; align-items: center; gap: .4rem; cursor: pointer; text-transform: none; letter-spacing: 0; }
.s7-squad-title input { accent-color: var(--s7-accent); }
.s7-input.ph { font-style: italic; }
.s7-lines { background: var(--s7-night); color: #fff3d6; border-radius: .75rem; padding: .75rem 1rem; margin: .6rem 0; }
.s7-lines div { display: flex; justify-content: space-between; align-items: center; padding: .35rem 0; font-size: .8rem; }
.s7-lines div + div { border-top: 1px solid rgba(255, 243, 214, .18); }
.s7-lines b { font-size: .9rem; }
.s7-lines .big { font-size: 1.5rem; font-weight: 900; }
.s7-verdict { text-align: center; padding: .9rem; border-radius: .75rem; font-weight: 800; font-size: 1.05rem; color: #fff; margin: .6rem 0; box-shadow: inset 0 2px 4px rgba(0, 0, 0, .25); }
.s7-verdict.win { background: #15803d; }
.s7-verdict.risk { background: #d97706; }
.s7-verdict.lose { background: #b91c1c; }
.s7-verdict.na { background: #78716c; }
.s7-note { font-size: .78rem; color: var(--s7-ink); background: rgba(245, 158, 11, .12); border: 1px solid var(--s7-line); border-radius: .6rem; padding: .6rem .8rem; margin: .6rem 0; }
@media (max-width: 480px) { .s7-grid3 { grid-template-columns: 1fr 1fr; } }

/* ---- Combat Plans table ---- */
.s7-wrap.wide { max-width: 62rem; }
.s7-filters { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; margin-bottom: .8rem; }
.s7-chip {
    border: 1px solid var(--s7-line); background: #fffdf6; color: var(--s7-ink); cursor: pointer;
    padding: .4rem .9rem; border-radius: 999px; font: 700 .78rem 'Inter', system-ui, sans-serif;
}
.s7-chip.on { background: var(--s7-night); color: #fff3d6; border-color: var(--s7-night); }
.s7-chip .n { opacity: .7; font-weight: 600; margin-left: .25rem; }
.s7-plans { width: 100%; border-collapse: collapse; font-size: .8rem; }
.s7-plans th { background: #f9e7bd; font-weight: 700; text-align: left; padding: .5rem .6rem; white-space: nowrap; }
.s7-plans th.sort { cursor: pointer; user-select: none; }
.s7-plans td { padding: .55rem .6rem; border-bottom: 1px solid var(--s7-line); vertical-align: top; }
.s7-plans td.nm { font-weight: 800; min-width: 5.5rem; }
.s7-plans td.ic { width: 4.8rem; padding-right: 0; }
.s7-plans td.ic img { display: block; width: 4.5rem; height: auto; border-radius: .4rem; }
.s7-plans td.lv { white-space: nowrap; text-align: center; font-weight: 700; }
.s7-plans td.fx div + div { margin-top: .3rem; }
.s7-plans td.fx { line-height: 1.45; min-width: 14rem; }
.s7-type { display: inline-block; color: #fff; font-size: .68rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; padding: .15rem .55rem; border-radius: 999px; }
.s7-plans td.gc { min-width: 14.5rem; line-height: 1.4; }
.s7-plans .gr { display: flex; flex-direction: column; margin-bottom: .45rem; }
.s7-plans .gw { font-size: .72rem; color: var(--s7-ink-soft); }
.s7-plans .gv { font-weight: 600; }
.s7-plans .gv strong { color: var(--s7-accent-dark); font-weight: 800; }
.s7-plans .gstars { display: flex; flex-wrap: nowrap; gap: .18rem; }
.s7-plans .sv { display: flex; flex-direction: column; align-items: center; min-width: 2.3rem; padding: .1rem .2rem .15rem; border: 1px solid var(--s7-line); border-radius: .4rem; font-weight: 700; font-size: .72rem; background: rgba(255, 253, 246, .85); }
.s7-plans .sv small { font-size: .62rem; font-weight: 700; color: var(--s7-ink-soft); }
.s7-plans .sv.est { border-style: dashed; font-weight: 600; font-style: italic; color: var(--s7-ink-soft); background: transparent; }
.s7-plans .gk { font-size: .66rem; font-weight: 600; color: var(--s7-ink-soft); }
.s7-plans .gp { display: inline-block; margin-left: .3rem; font-size: .7rem; font-weight: 800; color: #166534; background: rgba(34, 197, 94, .16); border-radius: .4rem; padding: .05rem .4rem; }
.s7-plans .gn { font-size: .75rem; color: var(--s7-ink-soft); font-style: italic; }
.s7-plans strong.up { color: var(--s7-accent-dark); background: rgba(245, 158, 11, .16); border-radius: .25rem; padding: 0 .15rem; }
.s7-plans details.s7-old { margin-top: .4rem; font-size: .72rem; color: var(--s7-ink-soft); }
.s7-plans details.s7-old summary { cursor: pointer; font-weight: 700; }
.s7-plans details.s7-old div { margin-top: .2rem; }
.s7-plans .tag { display: inline-block; margin-top: .35rem; font-size: .7rem; font-weight: 700; color: var(--s7-accent-dark); background: rgba(245, 158, 11, .16); border-radius: .4rem; padding: .15rem .45rem; }
@media (max-width: 640px) {
    .s7-plans .gstars { flex-wrap: wrap; }
    .s7-plans thead { display: none; }
    .s7-plans, .s7-plans tbody { display: block; width: 100%; }
    .s7-plans tr { display: grid; grid-template-columns: 4rem 1fr; column-gap: .7rem; align-items: start; border: 1px solid var(--s7-line); border-radius: .75rem; background: rgba(255, 253, 246, .7); margin-bottom: .6rem; padding: .5rem .6rem; }
    .s7-plans td { display: block; grid-column: 2; width: auto; border: 0; padding: .15rem 0; text-align: left !important; white-space: normal !important; min-width: 0 !important; }
    .s7-plans td.ic { grid-column: 1; grid-row: 1 / span 4; width: auto; }
    .s7-plans td.ic img { width: 4rem; }
    .s7-plans td.lv::before { content: 'Combat Lab '; font-weight: 600; color: var(--s7-ink-soft); }
}

/* ---- Season 7 overview ---- */
.s7-h2 { font-size: 1.15rem; font-weight: 800; color: #2a1708; margin: 1.8rem 0 .5rem; padding-bottom: .3rem; border-bottom: 2px solid var(--s7-line); }
.s7-p { font-size: .88rem; line-height: 1.6; color: var(--s7-ink); margin: .5rem 0; }
.s7-diff { width: 100%; border-collapse: collapse; font-size: .8rem; }
.s7-diff th { background: #f9e7bd; text-align: left; padding: .5rem .6rem; font-weight: 700; }
.s7-diff td { padding: .55rem .6rem; border-bottom: 1px solid var(--s7-line); vertical-align: top; line-height: 1.45; }
.s7-diff td:first-child { font-weight: 800; white-space: nowrap; }
.s7-pill { display: inline-block; font-size: .65rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; padding: .12rem .5rem; border-radius: 999px; color: #fff; white-space: nowrap; }
.s7-pill.new { background: #15803d; }
.s7-pill.chg { background: #d97706; }
.s7-pill.same { background: #78716c; }
.s7-pill.unk { background: #b91c1c; }
.s7-figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1rem; margin: .8rem 0 1rem; align-items: start; }
.s7-fig { margin: 0; background: rgba(255, 253, 246, .8); border: 1px solid var(--s7-line); border-radius: .75rem; padding: .5rem; }
.s7-fig img { display: block; width: 100%; height: auto; border-radius: .5rem; cursor: zoom-in; }
/* click-to-zoom overlay (S7_zoom.js) */
.s7-zoom { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; background: rgba(20, 12, 4, .9); cursor: zoom-out; padding: 1rem; }
.s7-zoom img { max-width: 100%; max-height: 100%; width: auto; height: auto; border-radius: .5rem; box-shadow: 0 8px 30px rgba(0,0,0,.6); object-fit: contain; }
.s7-zoom-x { position: absolute; top: .6rem; right: .8rem; width: 2.4rem; height: 2.4rem; border-radius: 50%; border: 1px solid var(--s7-accent); background: rgba(42, 26, 10, .92); color: #fff; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.s7-fig figcaption { font-size: .74rem; line-height: 1.45; color: var(--s7-ink-soft); padding: .5rem .2rem .1rem; }
.s7-fig.wide { grid-column: 1 / -1; }
.s7-fig.wide img { max-width: 44rem; margin: 0 auto; }
.s7-mini-table { border-collapse: collapse; font-size: .78rem; margin: .5rem 0; }
.s7-mini-table th, .s7-mini-table td { padding: .3rem .7rem; border-bottom: 1px solid var(--s7-line); text-align: right; }
.s7-mini-table th { background: #f9e7bd; }
.s7-mini-table td:first-child, .s7-mini-table th:first-child { text-align: left; }
.s7-list { font-size: .86rem; line-height: 1.6; margin: .4rem 0 .4rem 1.1rem; padding: 0; }
.s7-tools { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: .6rem; margin-top: .6rem; }
.s7-tools a { display: block; text-decoration: none; color: var(--s7-ink); background: #fffdf6; border: 1px solid var(--s7-line); border-left: 4px solid var(--s7-accent); border-radius: .6rem; padding: .55rem .7rem; font-size: .8rem; }
.s7-tools a b { display: block; color: var(--s7-accent-dark); }
@media (max-width: 640px) { .s7-diff td:first-child { white-space: normal; } }

/* Enemy health bar in the battle calculators */
.s7-hp { margin: .8rem 0 .4rem; text-align: left; }
.s7-hp-top { display: flex; justify-content: space-between; font-size: .8rem; margin-bottom: .25rem; }
.s7-hp-bar { height: 1.05rem; border-radius: .55rem; background: #d9d3c4; border: 1px solid var(--s7-line); overflow: hidden; }
.s7-hp-fill { height: 100%; background: linear-gradient(90deg, #dc2626, #ef4444); transition: width .25s; }
.s7-hp-own { background: linear-gradient(90deg, #15803d, #22c55e); }
.s7-hp-sub { display: flex; justify-content: space-between; font-size: .72rem; color: var(--s7-ink-soft); margin-top: .2rem; }
