/* ===== フォント読み込み ===== */
@font-face {
  font-family: "MyAquaFont";
  src: url("fonts/MyFont.ttf") format("truetype");
}

/* ===== 全体設定 ===== */
body {
  margin: 0;
  height: 100vh;
  background: linear-gradient(180deg,#ccefff,#66caff);
  overflow: hidden;
  font-family: "MyAquaFont",sans-serif;
}

/* 時計 */
.clock {
  position: fixed;
  top: 15px;
  right: 30px;
  font-size: 18px;
  color: #003366;
  text-shadow: 0 0 6px white;
}

/* サイドバー */
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: 200px;
  height: 100%;
  padding: 20px;
  background: linear-gradient(180deg,#ffffffcc,#b4dcffcc);
  box-shadow: 5px 0 20px rgba(0,100,255,0.3);
}

.sidebar button {
  display: block;
  width: 100%;
  margin: 12px 0;
  padding: 10px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  background: linear-gradient(180deg,#ffffff,#cceeff);
}

/* ウインドウ */
.window {
  position: absolute;
  width: 450px;
  border-radius: 12px;
  background: #e6f6ff;
  box-shadow: 0 20px 40px rgba(0,80,200,0.4);
  border: 1px solid #7fbfff;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.window.minimized {
  transform: scale(0.1);
  opacity: 0;
  pointer-events: none;
}

.titlebar {
  height: 30px;
  background: linear-gradient(180deg,#8fd3ff,#2ea3ff);
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  display: flex;
  align-items: center;
  cursor: grab;
}

.buttons {
  display: flex;
  gap: 6px;
  margin-left: 10px;
}

.button {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  cursor: pointer;
}

.close { background: #ff5f57; }
.minimize { background: #ffbd2e; }

.title {
  flex: 1;
  text-align: center;
  font-size: 14px;
  font-weight: bold;
  color: #003366;
}

.content {
  padding: 20px;
  color: #003366;
}

/* Dock */
.dock {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 15px;
  padding: 10px 20px;
  border-radius: 20px;
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(10px);
}

.dock-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: linear-gradient(180deg,#ffffff,#cceeff);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 12px;
  text-align: center;
}

/* ===== スマホ専用レイアウト ===== */
@media (max-width: 768px) {

  body {
    overflow: auto; /* スクロール許可 */
  }

  /* サイドバーを上部バーに変更 */
  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    display: flex;
    gap: 10px;
    padding: 10px;
  }

  .sidebar button {
    flex: 1;
    margin: 0;
    font-size: 12px;
  }

  /* ウインドウをカード化 */
  .window {
    position: relative;
    width: 95%;
    margin: 20px auto;
    left: 0 !important;
    top: 0 !important;
  }

  /* ドラッグカーソル無効化 */
  .titlebar {
    cursor: default;
  }

  /* Dockを少し小さく */
  .dock {
    bottom: 10px;
    gap: 10px;
  }

  .dock-icon {
    width: 40px;
    height: 40px;
    font-size: 10px;
  }

  /* 時計サイズ調整 */
  .clock {
    font-size: 14px;
    right: 15px;
  }
}