/* SubUTF8 PWA polish – active only when installed as a web app */
@media (display-mode: standalone) {
  html, body {
    background: #f5f5f7;
    min-height: 100%;
    overscroll-behavior-y: none;
  }

  body {
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
  }

  input, textarea, [contenteditable="true"] {
    -webkit-user-select: text;
  }

  .shell {
    max-width: 760px;
    padding:
      calc(18px + env(safe-area-inset-top))
      14px
      calc(28px + env(safe-area-inset-bottom));
  }

  header,
  .heroHeader {
    margin: 8px 2px 18px;
    gap: 14px;
  }

  .brandLogo {
    width: min(330px, 88%) !important;
    margin-bottom: 10px !important;
  }

  .heroDescription {
    font-size: 15px !important;
    line-height: 1.42 !important;
  }

  .heroDescriptionEn {
    margin-top: 5px !important;
    font-size: 11px !important;
    line-height: 1.4 !important;
    opacity: .82;
  }

  .privacy {
    font-size: 11px;
    padding: 8px 10px;
    border-radius: 999px;
  }

  .card {
    border-radius: 22px;
    margin-bottom: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,.04);
  }

  .drop {
    padding: 28px 16px;
    border-radius: 20px;
    transition: transform .16s ease, box-shadow .16s ease;
  }

  .drop:active {
    transform: scale(.995);
  }

  .drop .icon {
    width: 54px;
    height: 54px;
    border-radius: 17px;
    margin-bottom: 12px;
  }

  .drop h2 {
    font-size: 22px;
    letter-spacing: -.02em;
  }

  .drop p {
    margin: 7px auto 16px;
    max-width: 520px;
  }

  .primary,
  .secondary {
    min-height: 50px;
    border-radius: 15px;
    font-size: 16px;
    font-weight: 750;
    transition: transform .12s ease, opacity .12s ease;
  }

  .primary:active,
  .secondary:active {
    transform: scale(.985);
  }

  .row {
    border-radius: 16px;
  }

  .controls {
    padding: 15px;
  }

  .fileNameNotice {
    margin: 14px 0 4px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255,149,0,.08);
    border: 1px solid rgba(255,149,0,.20);
    color: #6b4a00;
    font-size: 13px;
    line-height: 1.42;
  }
}

@media (display-mode: standalone) and (prefers-color-scheme: dark) {
  html, body { background: #000; }
  .fileNameNotice {
    background: rgba(255,159,10,.12);
    border-color: rgba(255,159,10,.24);
    color: #ffd28a;
  }
}
