[hidden] {
  display: none!important;
}

html,
body {
  height: 100%;
  overscroll-behavior: none;
  touch-action: manipulation;
}

body {
  background: var(--page-bg);
  color: var(--page-ink);
  font-family: var(--body);
  font-size: 14px;
  margin: 0;
  overflow: hidden;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
  border: 0;
  background: none;
  padding: 0;
}

button: disabled {
  cursor: default;
}

input,
textarea {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}

.screen {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

.screen input,
.screen textarea {
  -webkit-user-select: text;
  user-select: text;
}

.screen button {
  transition: transform .18s cubic-bezier(.2, .8, .2, 1), filter .18s, opacity .18s, background .25s, border-color .25s, box-shadow .25s, color .25s;
}

.screen .pressed {
  transform: scale(.98);
  filter: brightness(1.15);
  transition-duration: .06s;
}

.screen .mic.pressed,
.screen .x.pressed,
.screen .add-entry.pressed {
  transform: scale(.9);
}

.screen .pass .eye.pressed {
  transform: translateY(-50%) scale(.88);
}

.screen .link.pressed,
.screen .tabs button.pressed {
  transform: none;
  filter: none;
  background: rgba(34, 211, 238, .08);
}

.screen .nav button.pressed {
  transform: translateZ(0);
  filter: none;
  transition-duration: .15s;
}

.screen .mood.pressed {
  transform: scale(.9);
}

.stage {
  height: 100%;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.phone-wrap {
  position: relative;
}

.phone {
  width: 412px;
  height: 868px;
  border-radius: 58px;
  background: #05070a;
  padding: 11px;
  position: absolute;
  left: 0;
  top: 0;
  transform-origin: 0 0;
  box-shadow: 0 40px 90px -30px rgba(0, 120, 140, .45), 0 0 0 1.5px #23272d inset, 0 0 0 4px #15181c;
}

.screen {
  width: 100%;
  height: 100%;
  border-radius: 47px;
  clip-path: inset(0 round 47px);
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  position: relative;
  display: flex;
  flex-direction: column;
  isolation: isolate;
  font-size: 14px;
}

body.bare .phone {
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  background: var(--bg);
}

body.bare .screen {
  border-radius: 0;
  clip-path: none;
  --st: max(env(safe-area-inset-top), 14px);
  --sb: max(env(safe-area-inset-bottom), 12px);
}

body.bare .status,
body.bare .home-ind {
  display: none;
}

body.bare {
  position: fixed;
  inset: 0;
  -webkit-text-size-adjust: 100%;
}

body.bare .input,
body.bare .sheet textarea {
  font-size: 16px;
}

.rotate {
  display: none;
}

body.bare.landscape .rotate {
  display: flex;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--bg);
  color: var(--text-2);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .14em;
  text-align: center;
}

body.bare.landscape .rotate img {
  width: 72px;
  height: 72px;
  border-radius: 50%;
}

img {
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
}

.status {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 46px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 30px;
  font-weight: 600;
  font-size: 14.5px;
  z-index: 60;
  pointer-events: none;
  color: #fff;
}

.status .island {
  position: absolute;
  left: 50%;
  top: 10px;
  transform: translateX(-50%);
  width: 112px;
  height: 31px;
  border-radius: 20px;
  background: #000;
}

.status .sig {
  display: flex;
  gap: 5px;
  align-items: center;
}

.status .sig svg {
  height: 12px;
}

.home-ind {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 134px;
  height: 5px;
  border-radius: 3px;
  background: rgba(255, 255, 255, .55);
  z-index: 70;
  pointer-events: none;
}

.label {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--cyan);
}

.label.orange {
  color: var(--orange-soft);
}

.card {
  border: 1px solid var(--line);
  background: var(--glass);
  padding: 16px;
  position: relative;
}

.card-h {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 4px 10px;
  margin-bottom: 12px;
}

.small-mono {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--muted);
  letter-spacing: .06em;
}

.sub {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
  margin: 0;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 46px;
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  border: 1px solid var(--orange);
  color: #ffd2bf;
  background: rgba(255, 72, 0, .1);
  box-shadow: 0 0 22px -6px rgba(255, 72, 0, .55), inset 0 0 18px -8px rgba(255, 72, 0, .6);
  transition: transform .15s, box-shadow .2s, background .2s, opacity .2s;
}

@media (hover: hover) and (pointer: fine) {
  .btn:hover {
    background: rgba(255, 72, 0, .16);
  }
  .mood:hover svg {
    transform: scale(1.08);
  }
}

.btn.cyan {
  border-color: var(--cyan);
  color: var(--cyan-soft);
  background: rgba(34, 211, 238, .07);
  box-shadow: 0 0 22px -8px rgba(34, 211, 238, .5), inset 0 0 18px -10px rgba(34, 211, 238, .6);
}

.btn.ghost {
  border-color: var(--line);
  color: var(--text-2);
  background: transparent;
  box-shadow: none;
}

.btn:disabled {
  opacity: .55;
}

.link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
  margin: -14px -4px;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--cyan-soft);
  letter-spacing: .06em;
}

.chip {
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-2);
  white-space: nowrap;
  background: rgba(8, 14, 22, .6);
}

.chip.on {
  border-color: var(--cyan);
  color: var(--cyan-soft);
  background: rgba(34, 211, 238, .08);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field span {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

.input {
  height: 48px;
  border: 1px solid var(--line);
  background: rgba(8, 14, 22, .7);
  padding: 0 14px;
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: .03em;
  color: var(--text);
  outline: none;
  width: 100%;
  transition: border-color .2s, box-shadow .2s;
}

.input::placeholder {
  color: var(--dim);
}

.input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, .12);
}

.input.err {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(255, 77, 106, .12);
}

.err-text {
  font-size: 12px;
  color: var(--red);
  min-height: 16px;
  margin: 0;
}

.shake.shake {
  animation: shake .38s;
}

@keyframes shake {
  20% {
    transform: translateX(-6px);
  }
  40% {
    transform: translateX(5px);
  }
  60% {
    transform: translateX(-3px);
  }
  80% {
    transform: translateX(2px);
  }
}

.spin {
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: rot .7s linear infinite;
}

@keyframes rot {
  to {
    transform: rotate(360deg);
  }
}

.rise {
  opacity: 0;
  transform: translateY(14px);
  animation: rise .55s cubic-bezier(.2, .8, .2, 1) forwards;
  animation-delay: calc(var(--i, 0) * 70ms);
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

.fade-in {
  animation: fadein .35s ease both;
}

@keyframes fadein {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.screen-in {
  animation: screenin .5s cubic-bezier(.2, .8, .2, 1) both;
}

@keyframes screenin {
  from {
    opacity: 0;
    transform: scale(1.03);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes ringpulse {
  0% {
    transform: scale(.55);
    opacity: .9;
  }
  100% {
    transform: scale(1.35);
    opacity: 0;
  }
}

@keyframes pop {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes breathe {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.01);
  }
}

.btn.ok-state,
.btn.ok-state:disabled {
  opacity: 1;
  border-color: var(--green);
  color: #bff3db;
  background: rgba(61, 220, 151, .08);
  box-shadow: 0 0 22px -8px rgba(61, 220, 151, .6);
}

@keyframes fadeout {
  to {
    opacity: 0;
  }
}

.pimg {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, .55));
}

@media (max-width: 380px) {
  .label {
    letter-spacing: .1em;
  }
  .small-mono {
    letter-spacing: .03em;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

.haptic-switch {
  position: fixed;
  left: -200px;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}


/* ---------- Визуальный язык концепта Home Rev02 ---------- */

.label {
  font-family: var(--body);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .07em;
}

.card {
  border-radius: 12px;
  border-color: rgba(34, 211, 238, .3);
  background: rgba(6, 12, 20, .78);
}

.chip {
  border-radius: 18px;
  padding: 0 14px;
  font-family: var(--body);
  font-size: 13px;
}

.btn {
  border-radius: 10px;
}

.alert {
  border-radius: 10px;
}

.ai-box {
  border-radius: 10px;
}

.input {
  border-radius: 10px;
}
