/* Tank Logic — walstad-calculator.css  NATURE THEME */
.unit-selector-row { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; padding: 12px 14px; background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-lg); }
.unit-selector-label { font-size: var(--sz-13); font-weight: 600; color: var(--tx); white-space: nowrap; }
.unit-selector-btns  { display: flex; gap: 8px; }
.walstad-unit-btn { display: flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--bg-1); border: 1px solid var(--border-mid); border-radius: var(--r-md); color: var(--tx-lo); cursor: pointer; font-family: var(--font); transition: all var(--t) var(--ease); min-width: 0; flex: 1 1 auto; justify-content: center; }
.walstad-unit-btn.active { background: var(--accent-lo); border-color: var(--accent-mid); color: var(--accent); }
.walstad-unit-btn:not(.active):hover { border-color: var(--border-hi); color: var(--tx); }
.unit-big-name { font-size: var(--sz-13); font-weight: 600; color: var(--tx); }
.unit-big-abbr { font-size: var(--sz-11); background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 1px 5px; margin-left: auto; color: var(--tx-xlo); }
.walstad-unit-btn.active .unit-big-abbr { background: var(--accent-mid); border-color: var(--accent-mid); color: var(--accent); }

.walstad-method-selector { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.walstad-method-btn { display: flex; align-items: center; gap: 12px; padding: 13px 16px; background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-lg); color: var(--tx); cursor: pointer; font-family: var(--font); text-align: left; box-shadow: var(--shadow-sm); transition: all var(--t) var(--ease); }
.walstad-method-btn:hover  { border-color: var(--border-mid); }
.walstad-method-btn.active { background: var(--accent-lo); border-color: var(--accent-mid); }
.method-icon { font-size: 1.3rem; flex-shrink: 0; }
.walstad-method-btn strong { display: block; font-family: var(--font-head); font-size: var(--sz-14); font-weight: 700; color: var(--tx-hi); line-height: 1; margin-bottom: 3px; }
.walstad-method-btn small  { font-size: var(--sz-13); color: var(--tx-lo); }
.walstad-method-btn.active strong { color: var(--accent); }

.depth-inputs { padding: 16px; background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-lg); margin-bottom: 14px; animation: slide-in 0.22s var(--ease); }

.substrate-diagram { display: flex; flex-direction: column-reverse; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--border); margin-bottom: 18px; min-height: 100px; }
.substrate-layer { display: flex; align-items: center; padding: 0 16px; font-family: var(--font-head); font-size: var(--sz-12); font-weight: 700; letter-spacing: -0.01em; transition: height 0.3s var(--ease); }
.substrate-layer--sand    { background: linear-gradient(135deg, var(--accent-lo), rgba(45,122,58,0.04)); color: var(--accent); border-bottom: 1px solid var(--accent-mid); }
.substrate-layer--soil    { background: linear-gradient(135deg, var(--gold-lo), rgba(200,134,10,0.04)); color: var(--gold); border-bottom: 1px solid rgba(200,134,10,0.15); }
.substrate-layer--mineral { background: linear-gradient(135deg, var(--purple-lo), rgba(107,95,168,0.04)); color: var(--purple); border-bottom: 1px solid rgba(107,95,168,0.15); }
.substrate-layer--tank    { background: var(--bg-2); color: var(--tx-xlo); height: 24px !important; font-size: var(--sz-11); letter-spacing: 0.04em; text-transform: uppercase; }

.walstad-results-grid { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.walstad-result-row   { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-md); flex-wrap: wrap; }
.walstad-result-layer { display: flex; align-items: center; gap: 9px; flex: 1 1 140px; min-width: 0; }
.walstad-result-icon  { font-size: 1rem; }
.walstad-result-name  { font-family: var(--font-head); font-size: var(--sz-14); font-weight: 700; color: var(--tx-hi); }
.walstad-result-depth { font-size: var(--sz-12); color: var(--tx-lo); background: var(--bg-1); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 2px 7px; margin-left: 2px; }
.walstad-result-vals  { display: flex; gap: 16px; }
.walstad-val          { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; }
.walstad-val-num      { font-family: var(--font-head); font-size: var(--sz-16); font-weight: 800; color: var(--tx-hi); letter-spacing: -0.02em; line-height: 1; }
.walstad-val-unit     { font-size: var(--sz-11); color: var(--tx-lo); font-weight: 600; letter-spacing: 0.03em; }

.walstad-guidance       { background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; }
.walstad-guidance-title { font-family: var(--font-head); font-size: var(--sz-12); font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--tx-lo); padding: 10px 14px; border-bottom: 1px solid var(--border); background: var(--bg-1); }
.walstad-step { display: flex; align-items: flex-start; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--border); font-size: var(--sz-14); color: var(--tx); line-height: 1.65; }
.walstad-step:last-of-type { border-bottom: none; }
.step-n { width: 20px; height: 20px; border-radius: 50%; background: var(--accent-lo); border: 1px solid var(--accent-mid); color: var(--accent); font-family: var(--font-head); font-size: var(--sz-11); font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 1px; }
.walstad-filter-note { padding: 11px 14px; font-size: var(--sz-13); color: var(--tx); line-height: 1.65; background: var(--water-lo); border-top: 1px solid var(--water-mid); }
.walstad-results { border-color: var(--accent-mid) !important; animation: slide-in 0.28s var(--ease); }

@media (max-width: 480px) { .walstad-result-vals { gap: 10px; } .walstad-method-selector { gap: 5px; } }

@media(max-width:380px){ .unit-selector-btns{flex-wrap:wrap;} .walstad-unit-btn{flex:1 1 100%;} }
