/* ============================================================
   Nokia J2ME Arcade — giao diện "chiếc điện thoại Nokia"
   Display LCD:  VT323   |  Nhãn pixel: Silkscreen  |  Chrome: Space Grotesk
   ============================================================ */

:root {
  --dev:      #1a1d24;
  --dev-hi:   #353b46;
  --dev-edge: #0a0b0e;
  --dev-key:  #23272f;
  --dev-key2: #181b21;

  --lcd:      #b4c196;   /* nền màn hình STN xanh ô-liu nhạt */
  --lcd-2:    #a9b78b;
  --ink:      #19261a;   /* mực xanh đen */
  --ink-dim:  #51613f;
  --ink-soft: #6f7d59;

  --led:      #5fd97a;
  --led-red:  #e8604c;

  --desk-1:   #0a1316;
  --desk-2:   #0e1d20;
  --desk-3:   #12262a;

  --r-phone: 38px;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: "Space Grotesk", system-ui, sans-serif;
  color: #cdd8d2;
  background:
    radial-gradient(120% 90% at 50% -10%, var(--desk-3), transparent 60%),
    radial-gradient(80% 70% at 50% 120%, #0c2024, transparent 55%),
    linear-gradient(160deg, var(--desk-1), var(--desk-2));
  background-attachment: fixed;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(16px, 4vw, 48px) 14px 60px;
}

/* faint dot grid on the desk */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(rgba(120, 200, 160, .06) 1px, transparent 1px);
  background-size: 22px 22px;
  pointer-events: none;
  z-index: 0;
}

/* ------------------------- Language gate ------------------------- */

.langgate {
  position: relative;
  z-index: 1;
  width: min(420px, 94vw);
  margin: auto;
  padding: 26px 22px 28px;
  border-radius: 22px;
  background: linear-gradient(180deg, #1b2026, #14181e);
  box-shadow: inset 0 0 0 1px #2a313b, 0 30px 60px -24px rgba(0,0,0,.8);
  text-align: center;
}
.langgate__brand {
  font-family: "Silkscreen", monospace;
  letter-spacing: 3px;
  font-size: 12px;
  color: var(--led);
  text-transform: uppercase;
  margin-bottom: 6px;
}
.langgate__title {
  font-family: "VT323", monospace;
  font-size: 30px;
  color: #cdd8d2;
  margin: 0 0 18px;
  line-height: 1.1;
}
.langgate__title span {
  display: block;
  font-size: 13px;
  color: #6f8189;
  letter-spacing: 1px;
  margin-top: 2px;
}
.langgate__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.langgate__opt {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: #0f1418;
  border: 1px solid #232c33;
  color: #dbe6df;
  text-decoration: none;
  transition: background .12s ease, border-color .12s ease, transform .05s ease;
}
.langgate__opt:hover { background: #15323a; border-color: #2f5f5a; }
.langgate__opt:active { transform: translateY(1px); }
.langgate__code {
  font-family: "Silkscreen", monospace;
  font-size: 11px;
  letter-spacing: 1px;
  color: #0c1316;
  background: var(--led);
  border-radius: 6px;
  padding: 3px 6px;
  min-width: 30px;
  text-align: center;
}
.langgate__name { font-size: 15px; }

/* ---------------------------- Handset ---------------------------- */

.phone {
  position: relative;
  z-index: 1;
  width: min(384px, 96vw);
  padding: 20px 18px 26px;
  border-radius: var(--r-phone);
  background:
    linear-gradient(180deg, #ece4fb 0%, #ddd0f4 20%, #cdbcee 82%, #bda7e6 100%);
  box-shadow:
    inset 0 2px 0 rgba(255,255,255,.65),
    inset 0 0 0 2px #b6a2e0,
    inset 0 0 0 3px #e8e0f8,
    0 30px 60px -22px rgba(60,40,95,.5),
    0 8px 20px -10px rgba(60,40,95,.4);
}
/* glossy edge highlight */
.phone::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: calc(var(--r-phone) - 8px);
  pointer-events: none;
  box-shadow: inset 0 1px 1px rgba(255,255,255,.05);
}

.phone__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 8px 14px;
}
.speaker {
  width: 54px; height: 7px;
  border-radius: 7px;
  background: linear-gradient(#0a0c0f, #1c2128);
  box-shadow: inset 0 1px 1px rgba(0,0,0,.9), 0 1px 0 rgba(255,255,255,.04);
}
.wordmark {
  font-family: "Silkscreen", monospace;
  font-size: 13px;
  letter-spacing: 4px;
  color: #5a3fa0;
  text-shadow: 0 1px 0 rgba(255,255,255,.5);
}
.dot-cam {
  width: 8px; height: 8px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #3a4452, #0c0f13);
  box-shadow: inset 0 0 2px #000;
}

/* ---------------------------- Screen ---------------------------- */

.screen {
  border-radius: 14px;
  padding: 12px;
  background: linear-gradient(#0c0e12, #16191f);
  box-shadow:
    inset 0 2px 6px rgba(0,0,0,.9),
    inset 0 0 0 1px #05060a;
}

.lcd {
  position: relative;
  border-radius: 6px;
  background: var(--lcd);
  color: var(--ink);
  overflow: hidden;
  font-family: "VT323", monospace;
  /* màn hình hơi cong + ánh sáng */
  box-shadow:
    inset 0 0 0 1px #7c8a63,
    inset 0 0 18px rgba(0,0,0,.18);
}
/* scanline + vignette để giống LCD thật */
.lcd::after {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(180deg, rgba(0,0,0,.05) 0 1px, transparent 1px 3px),
    radial-gradient(120% 100% at 50% 0%, transparent 70%, rgba(0,0,0,.12));
  mix-blend-mode: multiply;
}
/* hiệu ứng bật nguồn */
@keyframes lcd-on {
  0%   { filter: brightness(2.4) contrast(.4); opacity: 0; }
  40%  { opacity: 1; }
  100% { filter: none; opacity: 1; }
}
.lcd.power-on { animation: lcd-on .5s ease-out both; }

.lcd__status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 3px 8px 2px;
  font-family: "Silkscreen", monospace;
  font-size: 8px;
  letter-spacing: 1px;
  color: var(--ink);
  border-bottom: 1px solid rgba(25,38,26,.35);
}
.sig { display: inline-flex; align-items: flex-end; gap: 2px; height: 10px; }
.sig i { width: 3px; background: var(--ink); display: inline-block; }
.sig i:nth-child(1){ height: 3px; }
.sig i:nth-child(2){ height: 5px; }
.sig i:nth-child(3){ height: 7px; }
.sig i:nth-child(4){ height: 9px; }
.sig i.off { background: var(--ink-dim); opacity: .35; }
.batt {
  display: inline-flex; align-items: center; gap: 3px;
}
.batt .cell { width: 16px; height: 9px; border: 1px solid var(--ink); position: relative; }
.batt .cell::before { content:""; position:absolute; inset:1px; right: 5px; background: var(--ink); }
.batt .cell::after  { content:""; position:absolute; right:-3px; top:2px; width:2px; height:5px; background: var(--ink); }

.lcd__title {
  font-family: "VT323", monospace;
  font-size: 22px;
  line-height: 1;
  padding: 6px 10px 4px;
  letter-spacing: 1px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  border-bottom: 1px solid rgba(25,38,26,.4);
}
.lcd__title small { font-size: 13px; color: var(--ink-dim); letter-spacing: 1px; }

.lcd__soft {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 10px 6px;
  font-family: "VT323", monospace;
  font-size: 18px;
  border-top: 1px solid rgba(25,38,26,.4);
}
.lcd__soft span { min-width: 56px; }
.lcd__soft .mid { color: var(--ink-dim); font-size: 14px; letter-spacing: 1px; }
.lcd__soft .r { text-align: right; }

/* Menu chức năng trong màn LCD */
.lcd__menu {
  display: flex; flex-wrap: wrap; gap: 6px;
  padding: 7px 2px 1px; margin-top: 6px;
  border-top: 1px dashed rgba(25,38,26,.30);
}
.lcd__act {
  font-family: "VT323", monospace; font-size: 17px; line-height: 1;
  color: var(--ink); text-decoration: none; white-space: nowrap;
  padding: 4px 9px; border: 1px solid rgba(25,38,26,.5);
  border-radius: 6px; background: rgba(25,38,26,.05);
  cursor: pointer; -webkit-appearance: none; appearance: none;
}
.lcd__act:hover, .lcd__act:active, .lcd__act.sel { background: var(--ink); color: var(--lcd); }

/* Form upload .jar ngay trong màn LCD */
.up { font-family: "VT323", monospace; color: var(--ink); padding: 4px 2px; }
.up__sub { font-size: 15px; margin: 0 0 10px; opacity: .85; }
.up__msg { font-size: 15px; padding: 7px 9px; border-radius: 7px; margin: 0 0 10px; border: 1px solid rgba(25,38,26,.4); }
.up__msg.ok { background: rgba(25,38,26,.10); }
.up__msg.err { background: rgba(140,20,20,.14); border-color: rgba(140,20,20,.5); color: #5a1e1e; }
.up__row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 4px; }
.up__fname { font-size: 15px; opacity: .8; flex: 1; min-width: 70px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up__head { font-size: 14px; opacity: .7; border-top: 1px dashed rgba(25,38,26,.3); padding-top: 8px; margin-top: 10px; }
.up__list { display: flex; flex-direction: column; gap: 5px; margin-top: 6px; }
.up__item { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid rgba(25,38,26,.28); border-radius: 7px; background: rgba(25,38,26,.04); font-size: 15px; }
.up__item-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up__del { font-family: "VT323", monospace; cursor: pointer; color: #5a1e1e; background: rgba(140,20,20,.12); border: 1px solid rgba(140,20,20,.4); border-radius: 6px; padding: 2px 8px; font-size: 14px; -webkit-appearance: none; appearance: none; }
.up__del:hover, .up__del.sel { background: #5a1e1e; color: #e8d6d2; }

/* Danh sách chọn ngôn ngữ trong màn LCD */
.lcd__langs { display: flex; flex-direction: column; gap: 5px; padding: 6px 2px; }
.lcd__lang {
  display: flex; align-items: center; gap: 9px;
  padding: 8px 9px; border-radius: 7px;
  color: var(--ink); text-decoration: none;
  border: 1px solid rgba(25,38,26,.28); background: rgba(25,38,26,.04);
  font-family: "VT323", monospace;
}
.lcd__lang:hover, .lcd__lang:active, .lcd__lang.sel { background: var(--ink); color: var(--lcd); }
.lcd__lang-code {
  flex: none; font-family: "Silkscreen", monospace; font-size: 10px; letter-spacing: 1px;
  background: var(--ink); color: var(--lcd); border-radius: 5px;
  padding: 4px 6px; min-width: 30px; text-align: center;
}
.lcd__lang:hover .lcd__lang-code, .lcd__lang:active .lcd__lang-code, .lcd__lang.sel .lcd__lang-code { background: var(--lcd); color: var(--ink); }
.lcd__lang-name { flex: 1; font-size: 19px; line-height: 1; }
.lcd__lang-go { font-size: 18px; opacity: .55; }

/* ----------------------- Catalog grid (Series 40) ----------------------- */

.lcd__body {
  height: 300px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--ink-dim) transparent;
}
.lcd__body::-webkit-scrollbar { width: 6px; }
.lcd__body::-webkit-scrollbar-thumb { background: var(--ink-dim); border-radius: 6px; }

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 8px;
}
.tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 4px 6px;
  border: 1px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  color: var(--ink);
  text-decoration: none;
  outline: none;
}
.tile .ic {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  image-rendering: pixelated;
  background: rgba(25,38,26,.08);
  border: 1px solid rgba(25,38,26,.25);
  overflow: hidden;
}
.tile .ic img { width: 100%; height: 100%; object-fit: contain; image-rendering: pixelated; }
.tile .ic .ph {
  font-family: "VT323", monospace;
  font-size: 26px;
  color: var(--ink);
}
.tile .cap {
  font-family: "VT323", monospace;
  font-size: 15px;
  line-height: 1.05;
  text-align: center;
  max-width: 100%;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
/* lựa chọn kiểu Series 40: đảo màu */
.tile.sel, .tile:hover, .tile:focus-visible {
  background: var(--ink);
  color: var(--lcd);
  border-color: var(--ink);
}
.tile.sel .ic, .tile:hover .ic, .tile:focus-visible .ic {
  background: rgba(180,193,150,.12);
  border-color: var(--lcd);
}
.tile.sel .ic .ph, .tile:hover .ic .ph, .tile:focus-visible .ic .ph { color: var(--lcd); }

/* dòng mô tả game đang chọn */
.selinfo {
  border-top: 1px solid rgba(25,38,26,.4);
  padding: 3px 10px 4px;
  font-family: "VT323", monospace;
  font-size: 16px;
  min-height: 24px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  color: var(--ink);
}
.selinfo b { color: var(--ink); }
.selinfo span { color: var(--ink-dim); }

/* màn hình rỗng / thông báo */
.lcd__msg {
  height: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-align: center;
  padding: 16px;
  font-family: "VT323", monospace;
}
.lcd__msg .big { font-size: 40px; line-height: 1; }
.lcd__msg p { font-size: 17px; margin: 0; color: var(--ink); max-width: 240px; }
.lcd__msg .hint { color: var(--ink-dim); font-size: 15px; }

/* ----------------------- Emulator (play) ----------------------- */

.lcd--play .lcd__body {
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0b0d0a;
  overflow: hidden;
}
.lcd--play iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: #0b0d0a;
}

/* ---------------------------- Nav cluster ---------------------------- */

.nav {
  display: grid;
  grid-template-columns: 1fr 1.55fr 1fr;
  align-items: center;
  gap: 6px;
  padding: 14px 6px 6px;
}
/* Hai cụm soft key: nút gọi căn giữa ngay dưới phím mềm, cả cụm đẩy ra mép
   ngoài, đối xứng tuyệt đối qua D-pad */
.nav > div:first-child,
.nav > div:last-child {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.nav > div:first-child { justify-self: start; }
.nav > div:last-child  { justify-self: end; }
.softkey {
  height: 30px;
  min-width: 60px;
  padding: 0 10px;
  border: none;
  cursor: pointer;
  font-family: "Silkscreen", monospace;
  font-size: 9px;
  letter-spacing: 1px;
  text-align: center;
  color: #c7d0da;
  background: linear-gradient(#2b3038, #1b1f26);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 2px 4px rgba(0,0,0,.5);
}
.softkey.l { border-radius: 16px 6px 18px 8px; transform: rotate(-6deg); }
.softkey.r { border-radius: 6px 16px 8px 18px; transform: rotate(6deg); }
.softkey:active { background: #14171c; box-shadow: inset 0 2px 4px rgba(0,0,0,.7); }

.dpad {
  position: relative;
  width: 132px; height: 86px;
  margin: 0 auto;
  justify-self: center;
}
.dpad .ring {
  position: absolute; inset: 0;
  border-radius: 50%/70%;
  background: radial-gradient(circle at 50% 38%, #2e343d, #14171c 70%);
  box-shadow: inset 0 2px 4px rgba(255,255,255,.06), 0 3px 8px rgba(0,0,0,.6);
}
.dpad button {
  position: absolute;
  border: none;
  background: transparent;
  color: #8b96a2;
  cursor: pointer;
  font-size: 17px;
  padding: 8px 11px;
}
.dpad .up   { top: 2px; left: 50%; transform: translateX(-50%); }
.dpad .down { bottom: 2px; left: 50%; transform: translateX(-50%); }
.dpad .left { left: 6px; top: 50%; transform: translateY(-50%); }
.dpad .right{ right: 6px; top: 50%; transform: translateY(-50%); }
.dpad button:active { color: var(--led); }
.dpad .ok {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 56px; height: 36px; border-radius: 18px;
  background: linear-gradient(#3a4350, #20252d);
  color: #d8e0ea; font-family: "Silkscreen", monospace; font-size: 11px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 2px 5px rgba(0,0,0,.6);
}
.dpad .ok:active { background: #161a20; }

.callkeys {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.callbtn {
  width: 30px; height: 26px; border: none; border-radius: 8px;
  cursor: pointer; font-size: 13px; color: #fff;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 2px 4px rgba(0,0,0,.5);
}
.callbtn.green { background: linear-gradient(#2f9b54, #1c6b39); }
.callbtn.red   { background: linear-gradient(#c14a3b, #8a2f25); }
.callbtn:active { filter: brightness(.8); }

/* ---------------------------- Keypad ---------------------------- */

.keys {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  padding: 10px 4px 2px;
}
.key {
  position: relative;
  border: none;
  cursor: pointer;
  padding: 8px 4px 6px;
  border-radius: 12px;
  background: linear-gradient(#2a2f38, var(--dev-key2));
  color: #e7edf3;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.1),
    inset 0 -2px 3px rgba(0,0,0,.5),
    0 3px 5px rgba(0,0,0,.45);
  font-family: "VT323", monospace;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
  transition: transform .04s ease, background .08s ease;
}
.key .num { font-size: 22px; }
.key .sub {
  font-family: "Silkscreen", monospace;
  font-size: 7px;
  letter-spacing: 1px;
  color: #7f8a96;
  margin-top: 3px;
  min-height: 7px;
}
.key:active { transform: translateY(2px); background: #14171c; }
.key.wide { grid-column: span 1; }

/* chin */
.phone__chin {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding-top: 14px;
}
.phone__chin .led {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--led);
  box-shadow: 0 0 8px var(--led);
}
.phone__chin .label {
  font-family: "Silkscreen", monospace;
  font-size: 9px; letter-spacing: 3px; color: #6a51ad;
}

/* ---------------------------- Toolbar (real-world) ---------------------------- */

.toolbar {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 10px;
  margin-top: 22px;
  flex-wrap: wrap;
  justify-content: center;
}
.btn {
  font-family: "Space Grotesk", sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .3px;
  text-decoration: none;
  color: #bfe8cf;
  padding: 9px 16px;
  border-radius: 10px;
  border: 1px solid rgba(95,217,122,.28);
  background: rgba(95,217,122,.07);
  cursor: pointer;
  transition: background .15s ease, transform .08s ease;
}
.btn:hover { background: rgba(95,217,122,.16); }
.btn:active { transform: translateY(1px); }
.btn.ghost { color: #9fb0bb; border-color: rgba(159,176,187,.25); background: transparent; }

.tip {
  position: relative; z-index: 1;
  margin-top: 14px;
  max-width: 420px;
  text-align: center;
  font-size: 12.5px;
  line-height: 1.5;
  color: #6f8189;
}
.tip kbd {
  font-family: "Silkscreen", monospace;
  font-size: 10px;
  background: #11181b;
  border: 1px solid #29343a;
  border-radius: 5px;
  padding: 2px 5px;
  color: #aebccf;
}

/* ---------------------------- Forms (login/upload) ---------------------------- */

.card {
  position: relative; z-index: 1;
  width: min(420px, 94vw);
  margin-top: 8px;
  background: rgba(12,22,25,.7);
  border: 1px solid rgba(95,217,122,.18);
  border-radius: 16px;
  padding: 26px 24px;
  backdrop-filter: blur(4px);
}
.card h1 {
  font-size: 20px; margin: 0 0 4px;
  font-family: "Space Grotesk", sans-serif;
}
.card p.sub { margin: 0 0 18px; color: #6f8189; font-size: 13px; }
.field { margin-bottom: 14px; }
.field label {
  display: block; font-size: 12px; color: #8aa0a9; margin-bottom: 6px;
  letter-spacing: .3px;
}
.field input[type=password],
.field input[type=text],
.field input[type=file] {
  width: 100%;
  padding: 11px 12px;
  border-radius: 9px;
  border: 1px solid #25353a;
  background: #0a1316;
  color: #d7e2dc;
  font-size: 14px;
  font-family: "Space Grotesk", sans-serif;
}
.field input:focus { outline: 2px solid rgba(95,217,122,.4); border-color: transparent; }
.alert {
  background: rgba(232,96,76,.12);
  border: 1px solid rgba(232,96,76,.4);
  color: #f3b3a8;
  padding: 10px 12px; border-radius: 9px; font-size: 13px; margin-bottom: 14px;
}
.ok {
  background: rgba(95,217,122,.12);
  border: 1px solid rgba(95,217,122,.4);
  color: #bfe8cf;
  padding: 10px 12px; border-radius: 9px; font-size: 13px; margin-bottom: 14px;
}

/* ---------------------------- Responsive ---------------------------- */

@media (max-width: 600px) {
  html, body { height: 100%; }
  body {
    min-height: var(--app-h, 100dvh);
    padding: 6px;
    justify-content: flex-start;
  }
  .phone {
    width: calc(100vw - 12px);
    max-width: 384px;
    height: calc(var(--app-h, 100dvh) - 12px);
    display: flex; flex-direction: column;
    padding: 10px 12px 12px;
    border-radius: 28px;
  }
  .phone__top { flex: 0 0 auto; padding: 2px 8px 8px; }
  .screen { flex: 1 1 auto; min-height: 0; display: flex; padding: 8px; }
  .lcd { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; width: 100%; }
  .lcd__body, .lcd__msg, .lcd--play .lcd__body { flex: 1 1 auto; min-height: 0; height: auto; }
  .lcd__title { font-size: 19px; }
  .lcd__msg .big { font-size: 32px; }
  .lcd__msg p { font-size: 15px; }
  .lcd__msg .hint { font-size: 13px; }
  .lcd__act { font-size: 15px; padding: 3px 7px; }
  .nav { flex: 0 0 auto; padding: 8px 6px 5px; }
  .keys { flex: 0 0 auto; gap: 6px; padding: 7px 2px 2px; }
  .key { padding: 5px 4px 4px; border-radius: 10px; }
  .key .num { font-size: 18px; }
  .key .sub { font-size: 6px; margin-top: 2px; }
  .phone__chin { flex: 0 0 auto; padding-top: 6px; }
  .langgate { width: calc(100vw - 16px); padding: 22px 16px 24px; }
  .langgate__grid { grid-template-columns: 1fr; }
  .langgate__title { font-size: 27px; }
  .toolbar { margin-top: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .lcd.power-on { animation: none; }
}
