
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 12px;
  background: #eaf2e5;
  font-family: "Microsoft JhengHei", sans-serif;
  color: #50694f;
}

.phone {
  width: min(100%, 360px);
  height: min(740px, calc(100dvh - 32px));
  min-height: 560px;
  padding: 10px;
  border-radius: 42px;
  background: #354238;
  box-shadow: 0 18px 45px #52664a40;
}

.screen {
  height: 100%;
  position: relative;
  overflow: hidden;
  border-radius: 33px;
  background: #f6f8ee;
  display: flex;
  flex-direction: column;
}

.status {
  display: flex;
  justify-content: space-between;
  padding: 16px 20px 8px;
  font-size: 12px;
  background: #f6f8ee;
}

.wallpaper {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 20px 18px;

  background-image: url("../images/桌布.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* 上方長方形圖片小工具 */
.photo-widget {
  width: 100%;
  max-width: 310px;
  margin: 10px auto 25px;
  background: white;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 5px 20px #00000020;
}

/* 小工具上方圖片 */
.photo-widget img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  display: block;
}





.widget-info p {
  text-align: center;
  font-size: 12px;
  color: #65756A;
  margin: 3px 0;
  padding-bottom: 3px;
}



/* APP 圖示 */
.apps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px 12px;
}

.app {
  display: block;
  text-decoration: none;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
  min-width: 0;
}

.app-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 6px;
  display: block;
  border-radius: 14px;
  overflow: hidden;
  transition: transform .18s ease;
}

.app-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.app:active .app-icon {
  transform: scale(.91);
}

.app-name {
  display: block;
  font-size: 11px;
  text-align: center;
}

/* 底部快捷列 */
.dock {
  display: flex;
  justify-content: space-around;
  padding: 12px 8px 18px;
  margin: 0 12px 10px;
  border-radius: 22px;
  background: #ffffffa8;
}

.dock a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 15px;
  background: #e8f0df;
  font-size: 21px;
  text-decoration: none;
  color: inherit;
}

/* APP 內頁 */
.page-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 16px;
  background: #e7f0df;
}

.back {
  border: 0;
  background: #ffffffb8;
  color: #50694f;
  border-radius: 12px;
  padding: 8px 12px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
}

.page-title {
  margin: 0;
  font-size: 17px;
  font-weight: normal;
}

.page-content {
  padding: 22px 20px;
  overflow-y: auto;
  line-height: 1.9;
  font-size: 14px;
}

.profile-card {
  padding: 16px;
  margin-bottom: 14px;
  border-radius: 18px;
  background: #e9f1e3;
}

.profile-card h3 {
  margin: 0 0 6px;
}

.note {
  text-align: center;
  margin-top: 22px;
  font-size: 11px;
  color: #81927a;
}

/* 小螢幕調整 */
@media (max-width: 380px) {
  body {
    padding: 8px 6px;
  }

  .phone {
    padding: 7px;
    border-radius: 34px;
    height: min(740px, calc(100dvh - 16px));
  }

  .screen {
    border-radius: 27px;
  }

  .app-icon {
    width: 52px;
    height: 52px;
  }

  .apps {
    gap: 20px 8px;
  }
}

@media (max-height: 600px) {
  body {
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .phone {
    min-height: 0;
    height: calc(100dvh - 16px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

/* 手機底部系統導覽列 */
.system-nav {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 45px;

  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;

  background: #ffffff;
  border-top: 1px solid #e8eee7;
  z-index: 100;
}

/* 三個位置的共同設定 */
.system-nav button {
  height: 100%;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #65756A;
}

/* 左側返回鍵 */
.nav-back {
  font-size: 32px;
}

/* 中間首頁鍵 */
.nav-home span {
  width: 19px;
  height: 19px;
  border: 2px solid #65756A;
  border-radius: 6px;
}

/* 右側個人圖片 */
.nav-picture {
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-picture img {
  width: 27px;
  height: 27px;
  border-radius: 50%;
  object-fit: cover;
}