/* ===== Geometric Bold · 情侣空间 ===== */
:root {
  --black: #000;
  --white: #fff;
  --red: #ef4444;
  --blue: #2563eb;
  --yellow: #facc15;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: "Arial Black", "Helvetica Neue", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: 900;
  background: var(--white);
  color: var(--black);
  -webkit-font-smoothing: antialiased;
}
button, input, textarea { font-family: inherit; font-weight: 900; }

/* ---- 按钮 / 输入 token ---- */
.btn {
  border: 4px solid var(--black);
  background: var(--black);
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  padding: 12px 22px;
  cursor: pointer;
  transition: background-color 0.1s linear, color 0.1s linear;
  font-size: 14px;
}
.btn:hover { background: var(--yellow); color: var(--black); }
.btn:active { transform: translateY(2px); }
.btn-black { background: var(--black); color: var(--white); }
.btn-outline { background: var(--white); color: var(--black); }
.btn-red { background: var(--red); color: var(--white); border-color: var(--black); }
.btn-red:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-sm { padding: 8px 14px; font-size: 12px; }

.field {
  border: 4px solid var(--black);
  background: var(--white);
  padding: 12px 14px;
  font-size: 16px;
  font-weight: 700;
  width: 100%;
  outline: none;
  transition: background-color 0.1s linear;
}
.field:focus { background: var(--yellow); }
.area { resize: vertical; }
.cap { max-width: 220px; }

/* ---- 门禁 ---- */
.gate {
  position: fixed; inset: 0;
  background: var(--black);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  z-index: 50;
}
.gate-deco { position: absolute; }
.deco-circle {
  width: 320px; height: 320px; border-radius: 9999px;
  background: var(--blue); right: -80px; top: -80px;
}
.deco-tri {
  width: 0; height: 0;
  border-left: 160px solid transparent;
  border-right: 160px solid transparent;
  border-bottom: 280px solid var(--red);
  left: -60px; bottom: -60px;
  transform: rotate(15deg);
}
.gate-box {
  position: relative; z-index: 2;
  background: var(--white);
  border: 6px solid var(--white);
  padding: 48px 40px;
  max-width: 440px; width: 90%;
  text-align: center;
}
.lock-tag {
  display: inline-block;
  background: var(--yellow);
  border: 4px solid var(--black);
  padding: 4px 12px; font-size: 12px; letter-spacing: 0.2em;
  margin-bottom: 18px;
}
.gate-title {
  font-size: clamp(40px, 9vw, 68px);
  text-transform: uppercase; line-height: 0.95;
  margin-bottom: 10px;
}
.gate-sub { font-weight: 700; font-size: 14px; margin-bottom: 22px; }
.gate-form { display: flex; flex-direction: column; gap: 14px; }
.gate-error { margin-top: 14px; color: var(--red); font-size: 13px; min-height: 16px; }

/* ---- 顶栏 ---- */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  border-bottom: 6px solid var(--black);
  padding: 14px 20px;
  position: sticky; top: 0; background: var(--white); z-index: 20;
}
.brand { font-size: 24px; letter-spacing: 0.05em; }
.tabs { display: flex; gap: 0; }
.tab {
  border: 4px solid var(--black);
  background: var(--white); color: var(--black);
  padding: 8px 20px; cursor: pointer; font-size: 14px;
  text-transform: uppercase; letter-spacing: 0.1em;
  border-right-width: 0;
  transition: background-color 0.1s linear, color 0.1s linear;
}
.tab:last-child { border-right-width: 4px; }
.tab.active { background: var(--red); color: var(--white); }
.tab:hover:not(.active) { background: var(--yellow); }

/* ---- 主体 ---- */
.main { max-width: 920px; margin: 0 auto; padding: 28px 20px 80px; }
.panel { animation: none; }

/* ---- 发布框 ---- */
.composer {
  border: 4px solid var(--black);
  background: var(--white);
  padding: 18px;
  margin-bottom: 28px;
  display: flex; flex-direction: column; gap: 14px;
}
.composer-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.file-label { cursor: pointer; }
.file-name { font-weight: 700; font-size: 12px; color: var(--blue); }

/* ---- 说说流 ---- */
.feed { display: flex; flex-direction: column; gap: 20px; }
.card {
  border: 4px solid var(--black);
  background: var(--white);
  padding: 18px 20px;
  position: relative;
}
.card .meta { font-weight: 700; font-size: 12px; color: var(--blue); margin-bottom: 8px; letter-spacing: 0.1em; }
.card .text { font-weight: 700; font-size: 17px; line-height: 1.5; word-break: break-word; }
.card .img { margin-top: 14px; border: 4px solid var(--black); display: block; width: 100%; }
.card .del {
  position: absolute; top: 10px; right: 10px;
  border: 3px solid var(--black); background: var(--white);
  width: 30px; height: 30px; cursor: pointer; font-size: 16px; line-height: 1;
  transition: background-color 0.1s linear;
}
.card .del:hover { background: var(--red); color: var(--white); }

/* ---- 相册网格 ---- */
.photo-grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 700px) { .photo-grid { grid-template-columns: repeat(3, 1fr); } }
.photo {
  position: relative;
  border: 4px solid var(--black);
  background: var(--black);
  aspect-ratio: 1 / 1;
  overflow: hidden;
  cursor: pointer;
}
.photo img, .photo video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover;
}
.photo .live-badge {
  position: absolute; left: 8px; top: 8px; z-index: 3;
  background: var(--blue); color: var(--white);
  border: 3px solid var(--black);
  font-size: 11px; letter-spacing: 0.15em; padding: 2px 8px;
}
.photo .del {
  position: absolute; right: 8px; top: 8px; z-index: 3;
  border: 3px solid var(--black); background: var(--white);
  width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1;
  transition: background-color 0.1s linear;
}
.photo .del:hover { background: var(--red); color: var(--white); }
.photo .cap {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3;
  background: var(--yellow); color: var(--black);
  border-top: 3px solid var(--black);
  font-size: 11px; padding: 4px 8px; font-weight: 700;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* ---- 选择 / 批量删除 ---- */
.album-detail-topbar { display: flex; gap: 8px; margin-bottom: 14px; }
.batch-bar {
  display: flex; align-items: center; gap: 10px;
  border: 4px solid var(--black); background: var(--white);
  padding: 8px 12px; margin: 8px 0 16px;
}
.batch-count { font-weight: 700; font-size: 13px; margin-right: auto; }
/* 选择模式：隐藏单独的删除/编辑按钮，单元格可点选 */
#album-images.selecting .photo .del,
#album-images.selecting .photo .edit { display: none; }
#album-images.selecting .photo { cursor: pointer; }
.photo .check {
  position: absolute; left: 8px; top: 8px; z-index: 4;
  display: none;
  width: 26px; height: 26px; border: 3px solid var(--black); background: var(--white);
}
.photo .check::after {
  content: "✓"; display: none;
  position: absolute; inset: 0; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 900; color: var(--white);
}
#album-images.selecting .photo .check { display: block; }
.photo.selected { outline: 5px solid var(--red); outline-offset: -5px; }
.photo.selected .check { background: var(--red); }
.photo.selected .check::after { display: flex; }

/* ---- 灯箱 ---- */
.lightbox {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(0,0,0,0.92);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.lb-content { max-width: 100%; max-height: 100%; position: relative; }
.lb-content img, .lb-content video { max-width: 92vw; max-height: 86vh; border: 6px solid var(--white); display: block; }
.lb-close {
  position: absolute; top: 16px; right: 20px;
  border: 4px solid var(--white); background: var(--red); color: var(--white);
  width: 44px; height: 44px; font-size: 24px; cursor: pointer; line-height: 1;
}

.empty { border: 4px dashed var(--black); padding: 40px; text-align: center; font-weight: 700; color: var(--black); }

/* ---- 待上传预览（批量） ---- */
.pending-grid {
  display: grid; gap: 12px;
  grid-template-columns: repeat(3, 1fr);
}
@media (min-width: 700px) { .pending-grid { grid-template-columns: repeat(5, 1fr); } }
.pending {
  position: relative;
  border: 4px solid var(--black);
  background: var(--black);
  aspect-ratio: 1 / 1;
  overflow: hidden;
}
.pending.live { border-color: var(--blue); }
.pending img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pending .rm {
  position: absolute; right: 4px; top: 4px; z-index: 3;
  border: 3px solid var(--black); background: var(--white);
  width: 26px; height: 26px; cursor: pointer; font-size: 14px; line-height: 1;
  transition: background-color 0.1s linear;
}
.pending .rm:hover { background: var(--red); color: var(--white); }
.photo-warn { font-weight: 700; font-size: 12px; color: var(--red); min-height: 14px; }

/* ---- 相册（主题相册管理）---- */
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.section-title { font-size: clamp(26px, 6vw, 40px); text-transform: uppercase; letter-spacing: 0.02em; line-height: 1; }

.theme-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.theme-chip {
  border: 3px solid var(--black); background: var(--white); color: var(--black);
  padding: 5px 14px; font-size: 12px; cursor: pointer; letter-spacing: 0.05em;
  transition: background-color 0.1s linear, color 0.1s linear;
}
.theme-chip:hover { background: var(--yellow); }
.theme-chip.active { background: var(--blue); color: var(--white); }

.theme-badge {
  display: inline-block; border: 3px solid var(--black); background: var(--yellow);
  color: var(--black); font-size: 11px; letter-spacing: 0.1em; padding: 2px 10px; font-weight: 900;
}

/* 相册网格 */
.album-grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 700px) { .album-grid { grid-template-columns: repeat(3, 1fr); } }
.album-card {
  position: relative; border: 4px solid var(--black); background: var(--white);
  cursor: pointer; overflow: hidden; display: flex; flex-direction: column;
  transition: transform 0.1s linear;
}
.album-card:hover { background: var(--yellow); }
.album-card:hover .album-cover img { transform: scale(1.04); }
.album-cover { position: relative; width: 100%; aspect-ratio: 4 / 3; overflow: hidden; border-bottom: 4px solid var(--black); background: var(--black); }
.album-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.1s linear; }
.album-cover-empty {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  text-align: center; font-size: 18px; letter-spacing: 0.1em; color: var(--white); line-height: 1.2;
}
.album-card .theme-badge { position: absolute; left: 8px; top: 8px; z-index: 3; }
.album-card .del {
  position: absolute; right: 8px; top: 8px; z-index: 4;
  border: 3px solid var(--black); background: var(--white);
  width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1;
  transition: background-color 0.1s linear;
}
.album-card .del:hover { background: var(--red); color: var(--white); }
.album-name { font-size: 16px; font-weight: 900; padding: 10px 12px 2px; word-break: break-word; }
.album-meta { font-size: 12px; font-weight: 700; color: var(--blue); padding: 0 12px 12px; letter-spacing: 0.05em; }

.album-detail-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.album-count { font-size: 13px; font-weight: 700; color: var(--blue); }

/* 编辑按钮 */
.photo .edit {
  position: absolute; right: 8px; top: 44px; z-index: 3;
  border: 3px solid var(--black); background: var(--white);
  width: 28px; height: 28px; cursor: pointer; font-size: 14px; line-height: 1;
  transition: background-color 0.1s linear;
}
.photo .edit:hover { background: var(--blue); color: var(--white); }

/* ---- 弹窗（新建相册 / 编辑图片）---- */
.modal {
  position: fixed; inset: 0; z-index: 70;
  background: rgba(0,0,0,0.85);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal-box {
  background: var(--white); border: 6px solid var(--white);
  width: 100%; max-width: 420px; padding: 28px 24px;
  display: flex; flex-direction: column; gap: 12px;
}
.modal-title { font-size: 24px; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 4px; }
.modal-sub { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; color: var(--black); margin-top: 4px; }
.theme-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 10px; }

/* ---- 顶栏右侧 ---- */
.topbar-right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---- 作者身份徽章 ---- */
.author {
  display: inline-block; border: 3px solid var(--black); border-radius: 9999px;
  font-size: 11px; letter-spacing: 0.05em; padding: 1px 9px; font-weight: 900;
  margin-left: 8px; vertical-align: middle;
}
.author.boy { background: var(--blue); color: var(--white); }
.author.girl { background: var(--red); color: var(--white); }

/* ---- 相册地理位置 ---- */
.album-loc {
  font-weight: 700; font-size: 13px; color: var(--black);
  background: var(--yellow); border: 4px solid var(--black);
  padding: 8px 12px; margin-bottom: 18px;
}
.album-loc a { color: var(--blue); text-decoration: underline; }
.album-loc .loc-name { font-weight: 900; }
.album-loc + #album-images, .album-location + form { margin-top: 0; }
.album-location { margin-bottom: 18px; }

/* ---- 纪念日 ---- */
.anni-grid {
  display: grid; gap: 16px;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 700px) { .anni-grid { grid-template-columns: repeat(3, 1fr); } }
.anni-card {
  position: relative; border: 4px solid var(--black); background: var(--white);
  padding: 20px 18px 18px; text-align: center; overflow: hidden;
}
.anni-card:nth-child(3n+1) { background: var(--blue); color: var(--white); }
.anni-card:nth-child(3n+2) { background: var(--red); color: var(--white); }
.anni-card:nth-child(3n+3) { background: var(--yellow); color: var(--black); }
.anni-title { font-size: 17px; font-weight: 900; word-break: break-word; line-height: 1.3; }
.anni-date { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; margin-top: 6px; opacity: 0.85; }
.anni-num {
  font-size: clamp(48px, 12vw, 88px); line-height: 1; font-weight: 900;
  margin-top: 12px; letter-spacing: -0.02em;
}
.anni-unit { font-size: 12px; font-weight: 700; letter-spacing: 0.2em; margin-top: 4px; }
.anni-next { font-size: 12px; font-weight: 700; margin-top: 10px; }
.anni-next b { font-size: 15px; }
.anni-card .del {
  position: absolute; right: 8px; top: 8px; z-index: 3;
  border: 3px solid var(--black); background: var(--white); color: var(--black);
  width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1;
  transition: background-color 0.1s linear;
}
.anni-card .del:hover { background: var(--black); color: var(--white); }

/* ---- 待办 ---- */
.todo-list { display: flex; flex-direction: column; gap: 12px; }
.todo-item {
  border: 4px solid var(--black); background: var(--white);
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
}
.todo-check {
  flex: none; width: 30px; height: 30px; cursor: pointer;
  border: 4px solid var(--black); background: var(--white); color: var(--black);
  font-size: 16px; line-height: 1; font-weight: 900;
  transition: background-color 0.1s linear, color 0.1s linear;
}
.todo-item.done .todo-check { background: var(--blue); color: var(--white); }
.todo-text { flex: 1; font-weight: 700; font-size: 16px; word-break: break-word; }
.todo-item.done .todo-text { text-decoration: line-through; color: #888; }
.todo-item .del {
  flex: none; border: 3px solid var(--black); background: var(--white);
  width: 28px; height: 28px; cursor: pointer; font-size: 15px; line-height: 1;
  transition: background-color 0.1s linear;
}
.todo-item .del:hover { background: var(--red); color: var(--white); }

/* ---- 账号设置弹窗 ---- */
.settings-box { max-width: 460px; }
.modal-hint { font-weight: 700; font-size: 12px; color: var(--blue); margin-bottom: 6px; }
.account-edit { border: 4px solid var(--black); padding: 12px; margin-bottom: 12px; }
.account-head {
  display: inline-block; border: 3px solid var(--black); padding: 2px 12px; font-size: 13px;
  font-weight: 900; letter-spacing: 0.1em; margin-bottom: 8px;
}
.account-head.boy { background: var(--blue); color: var(--white); }
.account-head.girl { background: var(--red); color: var(--white); }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.swatch {
  width: 34px; height: 34px; border: 4px solid var(--black); cursor: pointer;
  font-size: 16px; color: var(--white); line-height: 1;
  transition: transform 0.1s linear;
}
.swatch.active { transform: scale(1.18); outline: 3px solid var(--black); outline-offset: 2px; }
.identity-switch { display: flex; gap: 10px; }
.identity-opt {
  flex: 1; border: 4px solid var(--black); background: var(--white); color: var(--black);
  padding: 10px; cursor: pointer; font-weight: 900; font-size: 13px;
  transition: background-color 0.1s linear, color 0.1s linear;
}
.identity-opt.active { background: var(--yellow); }
.anni-yearly { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13px; margin-top: 10px; }
.anni-yearly input { width: 18px; height: 18px; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
