/* ===== Цвета (меняй здесь) ===== */
:root {
  --bg: #fbf1e8;          /* светлый беж */
  --bg-2: #f3e3d3;        /* беж потемнее */
  --pink: #f4cdd5;        /* нежно-розовый */
  --pink-2: #f9e3e7;      /* очень светлый розовый */
  --pink-deep: #d98fa0;   /* акцентный розовый */
  --beige-deep: #cfb59b;  /* тёмный беж */
  --text: #5b3d43;        /* тёплый коричнево-розовый */
  --text-soft: #8d6f74;
  --font-title: "Cormorant Garamond", Georgia, serif;
  --font-body: "Nunito", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-body);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 8%, var(--pink-2) 0, transparent 40%),
    radial-gradient(circle at 90% 30%, var(--bg-2) 0, transparent 45%),
    var(--bg);
  background-attachment: fixed;
}

button { font-family: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--pink-deep); outline-offset: 3px; }

/* ===== Меню ===== */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: rgba(251, 241, 232, .88);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--pink);
}
.menu {
  max-width: 900px; margin: 0 auto; padding: 14px 16px;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px;
}
.menu-btn {
  border: 1.5px solid var(--pink);
  background: var(--pink-2);
  color: var(--text);
  padding: 9px 22px;
  border-radius: 999px;
  font-size: 1rem; font-weight: 600;
  transition: background .2s, border-color .2s, transform .2s;
}
.menu-btn:hover { background: var(--pink); transform: translateY(-2px); }
.menu-btn.active { background: var(--pink-deep); border-color: var(--pink-deep); color: #fff; }

/* ===== Страницы ===== */
main { max-width: 900px; margin: 0 auto; padding: 36px 18px 80px; }
.page { display: none; }
.page.active { display: block; animation: show .5s ease; }
@keyframes show { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.page-title {
  font-family: var(--font-title);
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  font-weight: 600; font-style: italic;
  text-align: center; margin-bottom: 36px;
  color: var(--pink-deep);
}
h2 { font-family: var(--font-title); font-size: 1.7rem; font-weight: 600; margin-bottom: 10px; }

/* ===== Страница «Зачем я сделал сайт»: 3 разных стиля ===== */
.text { margin-bottom: 30px; max-width: 680px; }
.text p { font-size: 1.05rem; }

/* стиль 1: мягкая розовая карточка */
.text-card {
  background: var(--pink-2);
  border-radius: 28px;
  padding: 30px 34px;
  box-shadow: 0 10px 30px rgba(217, 143, 160, .22);
}

/* стиль 2: бежевая записка с полоской слева */
.text-note {
  margin-left: auto;
  background: var(--bg-2);
  border-left: 8px solid var(--beige-deep);
  border-radius: 6px 22px 22px 6px;
  padding: 26px 30px;
  font-style: italic;
}

/* стиль 3: рамка с пунктиром по центру */
.text-frame {
  margin-left: auto; margin-right: auto;
  text-align: center;
  background: linear-gradient(135deg, var(--pink-2), var(--bg-2));
  border: 2px dashed var(--pink-deep);
  border-radius: 40px 12px 40px 12px;
  padding: 34px 36px;
}

/* ===== Анкета ===== */
.survey { max-width: 680px; margin: 0 auto; display: grid; gap: 22px; }
.q { display: block; }
.q::before {
  content: attr(data-question);       /* текст вопроса берётся из атрибута data-question */
  display: block;
  font-family: var(--font-title);
  font-size: 1.3rem; font-weight: 600;
  margin: 0 0 6px 6px;
}
.q textarea {
  width: 100%; resize: vertical;
  font: inherit; color: var(--text);
  background: #fffaf6;
  border: 1.5px solid var(--pink);
  border-radius: 18px;
  padding: 12px 16px;
  transition: border-color .2s, box-shadow .2s;
}
.q textarea::placeholder { color: var(--beige-deep); font-style: italic; }  /* подсказка/пример */
.q textarea:focus { outline: none; border-color: var(--pink-deep); box-shadow: 0 0 0 4px var(--pink-2); }

.copy-btn {
  justify-self: center; margin-top: 10px;
  background: var(--pink-deep); color: #fff; border: none;
  padding: 12px 30px; border-radius: 999px;
  font-size: 1rem; font-weight: 600;
  transition: transform .2s, background .2s;
}
.copy-btn:hover { background: #c97b8e; transform: translateY(-2px); }

/* ===== Музыка: папки ===== */
.folders { display: flex; flex-wrap: wrap; gap: 28px; justify-content: center; }
.folder {
  width: 190px; border: none; background: none; text-align: center; color: var(--text);
  transition: transform .25s;
}
.folder:hover { transform: translateY(-6px); }
.folder-shape { position: relative; height: 130px; margin-bottom: 10px; }
.folder-shape::before {          /* язычок папки */
  content: ""; position: absolute; left: 0; top: 0;
  width: 70px; height: 22px;
  background: var(--beige-deep); border-radius: 12px 12px 0 0;
}
.folder-shape::after {           /* корпус папки */
  content: ""; position: absolute; left: 0; right: 0; top: 14px; bottom: 0;
  background: linear-gradient(160deg, var(--pink), var(--pink-deep));
  border-radius: 6px 18px 18px 18px;
  box-shadow: 0 10px 22px rgba(217, 143, 160, .35);
}
.folder-cover {                  /* картинка, выглядывающая из папки */
  position: absolute; z-index: 1; left: 50%; top: 34px;
  width: 70px; height: 70px; margin-left: -35px;
  border-radius: 50%; border: 4px solid #fff8f3;
  background: var(--bg-2) center / cover;
}
.folder.open .folder-shape::after { background: linear-gradient(160deg, var(--pink-deep), #c97b8e); }
.folder-title { font-family: var(--font-title); font-size: 1.3rem; font-weight: 600; }
.folder-count { font-size: .85rem; color: var(--text-soft); }

/* ===== Музыка: диски ===== */
.disc-area { margin-top: 44px; text-align: center; }
.folder-name { font-style: italic; color: var(--pink-deep); font-size: 2rem; margin-bottom: 24px; }
.discs { display: flex; flex-wrap: wrap; gap: 34px; justify-content: center; }

.disc-item { width: 170px; border: none; background: none; color: var(--text); }
.disc {
  position: relative; width: 170px; height: 170px; border-radius: 50%;
  background: var(--bg-2) center / cover;      /* картинка наложена на диск */
  border: 2px solid #000;                      /* чёрная обводка по краю */
  box-shadow: 0 10px 26px rgba(91, 61, 67, .25);
  animation: spin 6s linear infinite;
  animation-play-state: paused;
  overflow: hidden;
}
.disc::before {                                 /* блик диска поверх картинки */
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(rgba(255,255,255,.55), transparent 25%, rgba(255,255,255,.4) 50%, transparent 75%, rgba(255,255,255,.55));
  mix-blend-mode: soft-light;
}
.disc::after {                                  /* дырка в центре */
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border-radius: 50%; background: var(--bg);
  border: 5px solid rgba(255, 255, 255, .7);
}
.disc-item.playing .disc { animation-play-state: running; }
@keyframes spin { to { transform: rotate(360deg); } }
.disc-item:hover .disc { box-shadow: 0 14px 30px rgba(217, 143, 160, .5); }
.disc-title { display: block; margin-top: 12px; font-weight: 600; }

/* ===== Маленький диск снизу справа ===== */
.mini-disc {
  position: fixed; right: 20px; bottom: 20px; z-index: 20;
  width: 92px; height: 92px; padding: 0;
  border: none; background: none; border-radius: 50%;
  transition: transform .2s;
}
.mini-disc[hidden] { display: none; }
.mini-disc:hover { transform: scale(1.08); }
.mini-disc .disc { width: 92px; height: 92px; border-width: 3px; }
.mini-disc .disc::after { width: 20px; height: 20px; margin: -10px 0 0 -10px; border-width: 3px; }
.mini-disc.playing .disc { animation-play-state: running; }

.now-playing { margin: 30px 0 10px; font-family: var(--font-title); font-size: 1.4rem; font-style: italic; min-height: 1.6em; }
audio { width: min(100%, 460px); accent-color: var(--pink-deep); }

@media (max-width: 520px) {
  .text-card, .text-note, .text-frame { padding: 22px; }
  .menu-btn { padding: 8px 16px; font-size: .9rem; }
}
@media (prefers-reduced-motion: reduce) {
  .page.active { animation: none; }
  .disc { animation-duration: 20s; }
}
