@import "https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Fredoka:wght@500;600;700&family=Nunito:wght@500;700;800&display=swap";:root{color:#3b2418;font-synthesis:none;text-rendering:optimizelegibility;--ink:#2b211c;--paper:#fff8ee;--coral:#ff6b4a;--sun:#ffc83d;--sky:#7ec8ff;--mint:#7dcea0;--line:#2b211c;background:#fff3df;font-family:Nunito,system-ui,sans-serif}body{min-width:320px;min-height:100vh;margin:0}button,input{font:inherit}button{cursor:pointer;border:0}button:disabled{cursor:not-allowed;opacity:.55}button,a{touch-action:manipulation}.app-shell{min-height:100vh;padding:0 4.6vw calc(24px + env(safe-area-inset-bottom));color:var(--ink);background:radial-gradient(circle at 8% 12%,#ff6b4a2e,#0000 18%),radial-gradient(circle at 92% 0,#ffc83d57,#0000 22%),radial-gradient(circle at 80% 88%,#7ec8ff47,#0000 20%),repeating-linear-gradient(0deg,#0000,#0000 27px,#2b211c09 28px),#fff3df}.app-shell.dark{color:#fff4e6;background:radial-gradient(circle at 10% 0,#ff6b4a38,#0000 26%),radial-gradient(circle at 90% 10%,#ffc83d1f,#0000 24%),repeating-linear-gradient(0deg,#0000,#0000 27px,#fff4e609 28px),#241c18}.topbar{justify-content:space-between;align-items:center;gap:16px;max-width:1440px;height:86px;margin:0 auto;display:flex}.brand-lockup,.topbar-actions,.status-chip,.section-kicker,.api-badge,.display-meta,.display-hint,.display-footer,.copy-button,.calculator-note,.history-footer,.history-time,.search-box,.text-button{align-items:center;display:flex}.brand-lockup{gap:10px}.brand-mark{background:0 0;place-items:center;width:52px;height:60px;display:grid}.brand-pebble{width:52px;height:62px}.brand-name{letter-spacing:-.03em;font-family:Fredoka,Nunito,sans-serif;font-size:28px;font-weight:700}.brand-caption{color:#a15a42;letter-spacing:.14em;margin-top:1px;font:700 10px/1 DM Mono,monospace}.dark .brand-caption{color:#ffc8a8}.topbar-actions{gap:10px}.status-chip,.docs-link,.icon-button,.api-badge{border:2.5px solid var(--line);box-shadow:3px 3px 0 var(--line)}.status-chip{color:#6d5348;background:#fff;border-radius:999px;gap:8px;padding:8px 12px;font-size:13px;font-weight:800}.dark .status-chip{color:#ffe7d4;background:#3a2c26;border-color:#f3d7b5;box-shadow:3px 3px #f3d7b5}.status-chip.online{color:#1f7a49;background:#e8ffe8}.dark .status-chip.online{color:#d9ffe4;background:#24543a}.status-dot,.live-dot{background:#b7a598;border-radius:50%;width:8px;height:8px}.status-chip.online .status-dot,.live-dot{background:#21a35a;box-shadow:0 0 0 4px #21a35a29}.icon-button{width:40px;height:40px;color:var(--ink);background:var(--sun);border-radius:14px;place-items:center;display:grid}.dark .icon-button{color:#2b211c;background:var(--sun);border-color:#f3d7b5;box-shadow:3px 3px #f3d7b5}.docs-link{color:#17486d;background:var(--sky);border-radius:14px;padding:8px 12px;font-size:13px;font-weight:800;text-decoration:none}.dark .docs-link{color:#17364d;background:var(--sky);border-color:#f3d7b5;box-shadow:3px 3px #f3d7b5}.content-grid{grid-template-columns:minmax(0,1.45fr) minmax(320px,.9fr);align-items:start;gap:22px;max-width:1440px;margin:18px auto 22px;display:grid}.card-surface{border:3px solid var(--line);background:#fff8eef0;border-radius:28px;box-shadow:8px 8px #2b211ce0}.dark .card-surface{background:#342820;border-color:#f3d7b5;box-shadow:8px 8px #f3d7b5b8}.calculator-card{min-height:700px;padding:28px 32px 22px;position:relative}.history-card{flex-direction:column;min-height:700px;padding:26px 24px 18px;display:flex}.section-kicker{color:#c4532d;letter-spacing:.14em;gap:7px;font:800 11px/1 DM Mono,monospace}.dark .section-kicker{color:#ffb089}.calculator-heading{justify-content:space-between;align-items:flex-start;gap:18px;margin-top:14px;display:flex}.title-row{align-items:center;gap:8px;display:flex}h1,h2,p{margin:0}h1,h2{letter-spacing:-.03em;font-family:Fredoka,Nunito,sans-serif}h1{max-width:640px;font-size:clamp(32px,4vw,50px);line-height:1.02}h1 span{color:#e85d3a}h2{font-size:28px}h1+p,.title-row p{color:#7c655b;max-width:560px;margin-top:10px;font-size:15px;font-weight:700}.dark h1 span{color:#ffb089}.dark .title-row p,.dark h1+p{color:#f0d7c8}.pebble-sticker{justify-items:center;min-width:92px;display:grid}.heading-pebble{width:92px;height:112px}.pebble-sticker span{border:2px solid var(--line);background:var(--sun);color:var(--ink);border-radius:999px;margin-top:-6px;padding:2px 8px;font:800 11px/1.4 Fredoka,sans-serif;transform:rotate(-6deg)}.dark .pebble-sticker span{border-color:#f3d7b5}.api-badge{white-space:nowrap;color:#6a2140;background:#ffd0e0;border-radius:999px;gap:7px;padding:9px 12px;font-weight:800}.dark .api-badge{color:#3d1828}button.api-badge{cursor:pointer}.api-badge.online{background:#ffe08a}.connection-panel{border:3px solid var(--line);background:#fff;border-radius:18px;margin-top:16px;padding:16px 18px;box-shadow:4px 4px #2b211c2e}.dark .connection-panel{background:#2a211c;border-color:#f3d7b5}.connection-title{color:#c4532d;align-items:center;gap:8px;font-size:15px;font-weight:800;display:flex}.dark .connection-title{color:#ffb089}.connection-panel p{color:#7c655b;margin:8px 0 0;font-size:13px;font-weight:700;line-height:1.55}.dark .connection-panel p{color:#f0d7c8}.connection-panel dl{gap:8px;margin:12px 0;display:grid}.connection-panel dl div{grid-template-columns:120px minmax(0,1fr);align-items:baseline;gap:10px;display:grid}.connection-panel dt{color:#a15a42;letter-spacing:.08em;text-transform:uppercase;font:700 11px DM Mono,monospace}.connection-panel dd{overflow-wrap:anywhere;color:#2b211c;margin:0;font:500 13px DM Mono,monospace}.dark .connection-panel dd{color:#fff4e6}.connection-panel a{color:#0d6e9e;font-size:13px;font-weight:800}.display-panel{border:3px solid var(--line);background:linear-gradient(#fff,#fff6df);border-radius:22px;margin-top:22px;padding:18px 20px 14px}.dark .display-panel{background:linear-gradient(#1d1714,#2c221c);border-color:#f3d7b5}.display-meta{color:#8a6d60;letter-spacing:.08em;text-transform:uppercase;justify-content:space-between;font:700 11px DM Mono,monospace}.display-hint{gap:5px}.display-expression{color:#a15a42;white-space:nowrap;min-height:28px;margin-top:16px;font:500 16px DM Mono,monospace;overflow-x:auto}.display-result{color:#2b211c;letter-spacing:-.04em;white-space:nowrap;min-height:68px;margin-top:2px;font:700 clamp(40px,6vw,64px)/1.05 Fredoka,sans-serif;overflow-x:auto}.dark .display-result{color:#fff8ee}.display-result.error{color:#d23b4b;letter-spacing:-.02em;white-space:normal;font-family:Nunito,sans-serif;font-size:22px}.steps{color:#6a4634;background:#ffc83d47;border-radius:12px;margin:10px 0 0;padding:8px 8px 8px 26px;font:500 13px/1.7 DM Mono,monospace}.dark .steps{color:#ffe7d2;background:#ffc83d1f}.display-footer{color:#8a6d60;border-top:2px dashed #2b211c40;justify-content:space-between;gap:14px;padding-top:12px;font-size:12px;font-weight:800}.dark .display-footer{color:#f0d7c8;border-top-color:#f3d7b54d}.copy-button{color:#c4532d;background:0 0;gap:5px;padding:0;font-size:13px;font-weight:800}.dark .copy-button{color:#ffb089}.function-row{grid-template-columns:repeat(auto-fit,minmax(68px,1fr));gap:8px;margin-top:16px;display:grid}.keypad{grid-template-columns:repeat(5,minmax(50px,1fr));gap:10px;margin-top:12px;display:grid}.key{height:56px;color:var(--ink);border:2.5px solid var(--line);background:#fff;border-radius:16px;font-size:20px;font-weight:800;box-shadow:3px 3px #2b211cd9}.key:hover:not(:disabled){box-shadow:4px 4px 0 var(--line);transform:translate(-1px,-1px)}.key:active:not(:disabled){box-shadow:0 0 0 var(--line);transform:translate(2px,2px)}.dark .key{color:#fff8ee;background:#4a382f;border-color:#f3d7b5;box-shadow:3px 3px #f3d7b5b3}.key.utility{background:#ffe7c2}.dark .key.utility{color:#2b211c;background:#ffd7a1}.key.operator{color:#8a2d16;background:#ffd0c2}.dark .key.operator{color:#4a1b10;background:#ffb39a}.key.function{color:#17486d;background:#d9f1ff;border-radius:12px;height:42px;font-size:14px}.dark .key.function{color:#17364d;background:#b7e4ff}.key.equals{color:#fff;background:var(--coral);font-size:26px}.calculator-note{color:#8a6d60;text-align:center;justify-content:center;gap:7px;margin-top:16px;font-size:12px;font-weight:800}.dark .calculator-note{color:#f0d7c8}.history-heading{justify-content:space-between;align-items:flex-start;gap:12px;display:flex}.history-actions{gap:12px;display:flex}.text-button{color:#0d6e9e;background:0 0;gap:5px;padding:4px 0;font-size:13px;font-weight:800}.text-button.danger{color:#d23b4b}.stats-row{grid-template-columns:.7fr 1.3fr;gap:10px;margin-top:18px;display:grid}.stat-box{border:2.5px solid var(--line);background:#fff6d8;border-radius:16px;min-height:72px;padding:12px 14px}.dark .stat-box{background:#4a382f;border-color:#f3d7b5}.stat-box span{color:#8a6d60;font-size:11px;font-weight:800;display:block}.dark .stat-box span{color:#f0d7c8}.stat-box strong{color:#c4532d;margin-top:6px;font:700 20px Fredoka,sans-serif;display:block}.stat-wide strong{color:#3b2418;font-size:13px;line-height:1.35}.dark .stat-wide strong{color:#fff4e6}.search-box{border:2.5px solid var(--line);background:#fff;border-radius:14px;gap:8px;margin-top:14px;padding:10px 12px;font-weight:800}.dark .search-box{color:#fff4e6;background:#241c18;border-color:#f3d7b5}.search-box input{min-width:0;color:inherit;background:0 0;border:0;outline:none;flex:1;font-size:14px;font-weight:700}.search-box input::placeholder{color:#b39788}.search-box kbd{color:#2b211c;background:#ffe7c2;border-radius:6px;padding:2px 6px;font:800 11px DM Mono,monospace}.history-list{flex:1;min-height:280px;margin-top:8px;overflow-y:auto}.history-item{border-bottom:2px dashed #2b211c29;align-items:center;gap:8px;padding:12px 2px;display:flex}.dark .history-item{border-bottom-color:#f3d7b533}.history-reuse{min-width:0;color:inherit;text-align:left;background:0 0;flex:1;align-items:center;gap:10px;padding:0;display:flex}.history-item-main{flex:1;min-width:0}.history-expression{color:#6a4634;text-overflow:ellipsis;white-space:nowrap;font:500 14px DM Mono,monospace;overflow:hidden}.dark .history-expression{color:#ffe7d2}.history-time{color:#a58b7e;gap:4px;margin-top:4px;font-size:11px;font-weight:800}.history-item-result{color:#c4532d;font:700 18px Fredoka,sans-serif}.favorite-button,.delete-button{color:#a58b7e;background:0 0;border:2px solid #0000;border-radius:10px;place-items:center;width:30px;height:30px;display:grid}.favorite-button.active,.favorite-button:hover{color:#c4532d;border-color:var(--line);background:#fff0b8}.delete-button:hover{color:#d23b4b;border-color:var(--line);background:#ffe1e4}.empty-state{color:#8a6d60;text-align:center;flex-direction:column;justify-content:center;align-items:center;gap:8px;min-height:280px;display:flex}.empty-pebble{width:86px;height:104px}.empty-state strong{color:#6a4634;font-size:15px}.dark .empty-state strong{color:#ffe7d2}.empty-state span{max-width:240px;font-size:13px;font-weight:700;line-height:1.55}.history-footer{color:#8a6d60;justify-content:space-between;padding-top:12px;font-size:12px;font-weight:800}.dark .history-footer{color:#f0d7c8}.history-footer>span:first-child{align-items:center;gap:8px;display:flex}.footer{color:#8a6d60;justify-content:space-between;gap:12px;max-width:1440px;margin:0 auto;font:800 12px Nunito,sans-serif;display:flex}.dark .footer{color:#f0d7c8}@media (width<=980px){.content-grid{grid-template-columns:1fr}.calculator-card,.history-card{min-height:auto}}@media (width<=560px){.app-shell{padding:0 14px 18px}.topbar{align-items:flex-start;height:auto;min-height:74px;padding-top:10px}.brand-caption{display:none}.brand-name{font-size:24px}.topbar-actions{flex-wrap:wrap;justify-content:flex-end;gap:6px}.docs-link,.status-chip{box-shadow:2px 2px 0 var(--line);padding:7px 8px;font-size:11px}.calculator-card,.history-card{border-radius:22px;padding:18px 14px 16px}.calculator-heading,.title-row{display:block}.pebble-sticker{display:none}.api-badge{margin-top:14px;display:inline-flex}h1{font-size:34px}.display-panel{padding:16px 14px 12px}.keypad{gap:8px}.key{border-radius:14px;height:52px;min-height:48px}.function-row{grid-template-columns:repeat(4,minmax(0,1fr))}.stats-row{grid-template-columns:1fr}.connection-panel dl div{grid-template-columns:1fr;gap:2px}.footer{line-height:1.7;display:block}}
