/* 한스푼 스튜디오 로비 (/) — standalone; /books and /apps use styles.css */
:root {
  --bg: #fbfaf8;
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --faint: #8e8e93;
  --books: #ffe9dc;
  --books-ink: #7a4b33;
  --apps: #ece8ff;
  --apps-ink: #4b3b8f;
  --tutor: #f3ead9;
  --tutor-ink: #7a6340;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.lobby {
  display: flex;
  flex-direction: column;
  width: min(100%, 960px);
  min-height: 100vh;
  min-height: 100svh;
  margin: 0 auto;
}

/* ── header ───────────────────────────── */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 22px 20px 0;
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand img {
  display: block;
  width: auto;
  height: 30px;
}

/* ── intro ────────────────────────────── */
.intro {
  display: grid;
  gap: 10px;
  padding: 32px 20px 22px;
}

.intro h1 {
  margin: 0;
  font-size: clamp(34px, 9.4vw, 56px);
  font-weight: 800;
  line-height: 1.22;
  letter-spacing: -0.035em;
}

.intro p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

/* ── rooms (bento cards) ──────────────── */
.rooms {
  display: grid;
  gap: 12px;
  padding: 0 16px;
}

.room {
  position: relative;
  display: block;
  height: 236px;
  overflow: hidden;
  border-radius: 28px;
  color: var(--ink);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform 240ms ease;
}

.room:active {
  transform: scale(0.985);
}

.room:focus-visible {
  outline: 3px solid rgba(29, 29, 31, 0.28);
  outline-offset: 3px;
}

.room-books {
  background: var(--books);
}

.room-apps {
  background: var(--apps);
}

.room-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 20px 0;
}

.room-title {
  display: grid;
  gap: 2px;
}

.room-title strong {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.room-title small {
  font-size: 14px;
}

.room-books small {
  color: var(--books-ink);
}

.room-apps small {
  color: var(--apps-ink);
}

.room-go {
  display: grid;
  flex: none;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #ffffff;
  transition: transform 240ms ease;
}

.room:hover .room-go {
  transform: translateX(3px);
}

.room-covers {
  position: absolute;
  right: 0;
  bottom: -20px;
  left: 0;
  display: flex;
  justify-content: center;
  gap: 10px;
}

.room-covers img {
  width: min(92px, 26vw);
  height: auto;
  aspect-ratio: 92 / 130;
  object-fit: cover;
  border-radius: 4px 10px 10px 4px;
  box-shadow: 0 10px 24px rgba(122, 75, 51, 0.18);
  transition: transform 260ms ease;
}

.room:hover .room-covers img {
  transform: translateY(-6px);
}

.room:hover .room-covers img:nth-child(2) {
  transition-delay: 40ms;
}

.room:hover .room-covers img:nth-child(3) {
  transition-delay: 80ms;
}

.room-icons {
  position: absolute;
  bottom: 22px;
  left: 20px;
  display: grid;
  grid-template-columns: repeat(4, 56px);
  gap: 12px;
}

.room-icons img {
  width: 56px;
  height: 56px;
  border-radius: 13px;
  transition: transform 260ms ease;
}

.room:hover .room-icons img {
  transform: translateY(-3px);
}

/* 프랑스푼 — a wide card under the two rooms, not a third room */
.room-wide {
  display: flex;
  align-items: center;
  gap: 14px;
  height: auto;
  padding: 18px 18px 18px 20px;
  background: var(--tutor);
}

.room-wide-icon {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 13px;
  box-shadow: 0 4px 10px rgba(122, 99, 64, 0.16);
}

.room-wide .room-title {
  flex: 1;
  min-width: 0;
}

.room-wide small {
  color: var(--tutor-ink);
}

.room-badge {
  margin-left: 4px;
  padding: 2px 7px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--tutor-ink);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0;
  vertical-align: 3px;
}

/* ── notice (AVIS): one line, opens on tap ── */
.notice {
  position: relative;
  margin: 0 16px 12px;
  overflow: hidden;
  border: 1.5px solid #f2dcae;
  border-radius: 20px;
  background: #fffaf0;
  box-shadow: 0 8px 20px rgba(160, 120, 40, 0.08);
}

.notice::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: linear-gradient(#2f5fd0 0 33.3%, #ffffff 33.3% 66.6%, #ef4a43 66.6%);
}

.notice summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 10px 16px 10px 18px;
  cursor: pointer;
  list-style: none;
  -webkit-tap-highlight-color: transparent;
}

.notice summary::-webkit-details-marker {
  display: none;
}

.notice summary:focus-visible {
  outline: 3px solid rgba(29, 29, 31, 0.28);
  outline-offset: -3px;
  border-radius: 20px;
}

.notice-tag {
  flex: none;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--ink);
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.notice-title {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.notice-more {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #9a7a3c;
  font-size: 12px;
  font-weight: 800;
}

.notice-more::before {
  content: "눌러서 보기";
}

.notice[open] .notice-more::before {
  content: "접기";
}

.notice-more::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 200ms ease;
}

.notice[open] .notice-more::after {
  transform: translateY(2px) rotate(225deg);
}

.notice-body {
  padding: 0 18px 16px 20px;
  color: #4a4540;
  font-size: 14px;
  line-height: 1.65;
  word-break: keep-all;
}

.notice-body p {
  margin: 0;
}

.notice-lead {
  margin-bottom: 6px !important;
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.notice-who {
  margin: 0 0 8px;
  padding-left: 20px;
  font-size: 13.5px;
}

.notice-who li + li {
  margin-top: 2px;
}

.notice-body ol {
  margin: 10px 0 0;
  padding-left: 20px;
  font-size: 13.5px;
}

.notice-body li + li {
  margin-top: 4px;
}

.notice-note {
  margin-top: 10px !important;
  padding: 8px 12px;
  border-radius: 12px;
  background: #fff1d6;
  color: #7a5a1f;
  font-size: 12.5px;
}

.notice-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
}

.notice-cta {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--ink);
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.notice-sign {
  color: #9a7a3c;
  font-size: 12.5px;
  font-style: italic;
  font-weight: 700;
}

/* ── 업데이트 소식 ───────────────────────────── */
.notice-update {
  border-color: #cfe3f7;
  background: #f6faff;
  box-shadow: 0 8px 20px rgba(31, 99, 214, 0.07);
}

.notice-update .notice-tag {
  background: #1f63d6;
}

.notice-update .notice-more {
  color: #3d6fae;
}

.notice-update .notice-title {
  word-break: keep-all;
}

.notice-update .upd-day:first-of-type {
  margin-top: 12px;
}

.notice-sub {
  display: block;
  margin-top: 2px;
  color: #5b6b80;
  font-size: 12.5px;
  font-weight: 700;
}

.upd-day + .upd-day {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed #d6e3f1;
}

.upd-date {
  color: #1f63d6;
  font-size: 13px;
  font-weight: 800;
}

.upd-day ul {
  margin: 6px 0 0;
  padding-left: 18px;
  font-size: 13.5px;
}

.upd-day li + li {
  margin-top: 4px;
}

.upd-next {
  margin-top: 12px !important;
  padding: 8px 12px;
  border-radius: 12px;
  background: #e8f1fc;
  color: #2f5583;
  font-size: 12.5px;
}

/* ── footer ───────────────────────────── */
.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding: 28px 20px calc(26px + env(safe-area-inset-bottom));
}

.foot small {
  color: var(--faint);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.foot-links {
  display: flex;
  gap: 6px;
}

.foot-links a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: var(--ink);
  transition: color 160ms ease, background 160ms ease;
}

.foot-links a:hover {
  background: rgba(29, 29, 31, 0.05);
}

.sns-instagram:hover { color: #e1306c; }
.sns-blog:hover { color: #03c75a; }
.sns-youtube:hover { color: #ff0000; }

/* ── wider screens: cards side by side ── */
@media (min-width: 760px) {
  .brand {
    padding: 32px 32px 0;
  }

  .intro {
    padding: 72px 32px 40px;
  }

  .rooms {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    padding: 0 32px;
  }

  .notice {
    margin: 0 32px 16px;
  }

  .room {
    height: 340px;
    border-radius: 32px;
  }

  .room:hover {
    transform: translateY(-4px);
  }

  .room-head {
    padding: 26px 26px 0;
  }

  .room-title strong {
    font-size: 24px;
  }

  .room-covers {
    bottom: -24px;
    gap: 14px;
  }

  .room-covers img {
    width: 118px;
  }

  .room-icons {
    bottom: 30px;
    left: 26px;
    grid-template-columns: repeat(4, 64px);
    gap: 14px;
  }

  .room-icons img {
    width: 64px;
    height: 64px;
    border-radius: 15px;
  }

  .room-wide {
    grid-column: 1 / -1;
    height: auto;
    gap: 18px;
    padding: 22px 26px;
  }

  .room-wide-icon {
    width: 64px;
    height: 64px;
    border-radius: 15px;
  }

  .foot {
    padding: 40px 32px 36px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .room,
  .room-go,
  .room-covers img,
  .room-icons img {
    transition: none;
  }
}
