:root {
  color-scheme: light;
  --ink: #1e2329;
  --muted: #68717d;
  --line: #dfe5ea;
  --paper: #fbfaf7;
  --surface: #ffffff;
  --accent: #0f766e;
  --accent-soft: #d9f0ed;
  --warm: #f6d58f;
  --shadow: 0 18px 55px rgba(31, 41, 55, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Microsoft YaHei", "PingFang SC", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background:
    linear-gradient(120deg, rgba(217, 240, 237, 0.72), rgba(246, 213, 143, 0.28)),
    var(--paper);
}

.gate-body {
  display: grid;
  place-items: center;
}

.gate-shell {
  width: min(100% - 32px, 440px);
}

.gate-panel {
  background: var(--surface);
  border: 1px solid rgba(15, 118, 110, 0.16);
  box-shadow: var(--shadow);
  padding: 34px;
}

.gate-panel h1 {
  margin: 0 0 24px;
  font-size: clamp(2rem, 7vw, 3.4rem);
  line-height: 1.08;
}

.gate-form {
  display: grid;
  gap: 16px;
}

.gate-form button {
  width: 100%;
  border: 0;
  background: var(--accent);
  color: #ffffff;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  min-height: 46px;
  padding: 0 16px;
  transition: background 160ms ease, transform 160ms ease;
}

.gate-form button:hover {
  background: #0b5f59;
}

.gate-form button:active {
  transform: translateY(1px);
}

.gate-message {
  min-height: 24px;
  margin: 0;
  color: #b42318;
  font-size: 0.92rem;
}

.action-link,
.plain-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  color: #ffffff;
  background: var(--accent);
  font-weight: 700;
  text-decoration: none;
  transition: background 160ms ease, transform 160ms ease;
}

.action-link {
  margin-top: 22px;
}

.action-link:hover,
.plain-link:hover {
  background: #0b5f59;
}

.action-link:active,
.plain-link:active {
  transform: translateY(1px);
}

.plain-link {
  justify-self: start;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 40px 0;
}

.profile-panel {
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  align-items: center;
  gap: 28px;
  padding: 30px;
  min-height: 230px;
  background: var(--surface);
  border: 1px solid rgba(15, 118, 110, 0.16);
  box-shadow: var(--shadow);
}

.avatar-wrap {
  width: 148px;
  aspect-ratio: 1;
  padding: 7px;
  background: linear-gradient(135deg, var(--accent-soft), var(--warm));
}

.avatar {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  border: 4px solid var(--surface);
}

.avatar.is-empty {
  visibility: hidden;
}

.profile-copy h1 {
  margin: 0;
  min-height: 1.04em;
  font-size: clamp(2rem, 5vw, 4.5rem);
  line-height: 1.04;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.profile-copy p {
  min-height: 1.8em;
  max-width: 720px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.8;
  overflow-wrap: anywhere;
}

.content-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  margin-top: 24px;
  align-items: start;
}

.article-view,
.editor-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 12px 36px rgba(31, 41, 55, 0.08);
}

.article-view {
  min-height: 560px;
  padding: clamp(28px, 5vw, 56px);
}

.quote-view {
  min-height: 240px;
  margin-top: 24px;
}

.article-kicker {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.article-view h2 {
  margin: 0;
  font-size: clamp(1.7rem, 3.5vw, 3.1rem);
  line-height: 1.18;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.article-body {
  margin-top: 28px;
  color: #333b44;
  font-size: 1.04rem;
  line-height: 1.95;
}

.article-body p {
  margin: 0 0 1.2em;
  overflow-wrap: anywhere;
}

.gallery-section {
  display: grid;
  gap: 28px;
  margin-top: 24px;
}

.gallery-block {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 12px 36px rgba(31, 41, 55, 0.08);
  padding: clamp(18px, 3vw, 28px);
}

.gallery-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.gallery-header h2 {
  margin: 0;
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  line-height: 1.15;
}

.gallery-landscapes,
.gallery-portraits {
  display: grid;
  gap: 14px;
}

.gallery-landscapes {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 14px;
}

.gallery-portraits {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

figure {
  margin: 0;
  overflow: hidden;
  background: #eef3f4;
}

.gallery-landscapes figure {
  aspect-ratio: 16 / 9;
}

.gallery-portraits figure {
  aspect-ratio: 3 / 4;
  background: #f4f6f6;
}

figure img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

.gallery-portraits img {
  object-fit: contain;
}

.score-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: clamp(24px, 5vw, 48px);
}

.score-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}

.score-header h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.8rem);
  line-height: 1.08;
}

.score-header p:last-child {
  margin: 12px 0 0;
  color: var(--muted);
}

.score-table {
  width: 100%;
  border-collapse: collapse;
  overflow-wrap: anywhere;
}

.score-table th,
.score-table td {
  border-bottom: 1px solid var(--line);
  padding: 16px 14px;
  text-align: left;
}

.score-table th {
  color: var(--muted);
  font-size: 0.9rem;
}

.score-table td:nth-child(2),
.score-table td:nth-child(3) {
  font-weight: 700;
}

.editor-panel {
  position: sticky;
  top: 24px;
  display: grid;
  gap: 16px;
  padding: 22px;
}

.editor-panel h2 {
  margin: 0 0 2px;
  font-size: 1.1rem;
}

label {
  display: grid;
  gap: 7px;
}

label span {
  color: var(--muted);
  font-size: 0.88rem;
}

input,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #f8fafb;
  color: var(--ink);
  font: inherit;
  line-height: 1.5;
  padding: 11px 12px;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

textarea {
  resize: vertical;
  min-height: 180px;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

@media (max-width: 880px) {
  .page-shell {
    width: min(100% - 24px, 680px);
    padding: 20px 0;
  }

  .profile-panel,
  .content-panel,
  .gallery-landscapes,
  .gallery-portraits {
    grid-template-columns: 1fr;
  }

  .profile-panel {
    justify-items: start;
    padding: 24px;
  }

  .editor-panel {
    position: static;
  }

  .score-header {
    display: grid;
  }
}

@media (max-width: 520px) {
  .profile-panel {
    gap: 18px;
  }

  .avatar-wrap {
    width: 118px;
  }

  .article-view {
    min-height: 420px;
  }

  .quote-view {
    min-height: 220px;
  }
}
