/* Generated file. Source: shared/brand/styles/life/life-layout.css. Do not edit directly. Run: node tools/brand/sync-shared-brand.mjs */
/* ============================================================
   life-layout.css — life.tomatronic.com 布局系统
   铁律：不写任何 color/background/border-color/box-shadow/font-family/transition/animation/opacity
   ============================================================ */

/* ── 页面级容器 ── */
.life-shell {
  position: relative;
  z-index: 1;
  padding-top: calc(56px + env(safe-area-inset-top, 0px));
}

.life-shell::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

/* ── 内容区 ── */
.life-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px var(--shell-gutter);
}

.life-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}

/* ── Gallery 瀑布流 ── */
.life-gallery {
  columns: 4 280px;
  column-gap: 16px;
}

.life-gallery-item {
  break-inside: avoid;
  margin-bottom: 16px;
  position: relative;
  display: block;
  padding: 6px;
  width: 100%;
  overflow: hidden;
}

.life-gallery-item:hover {
  transform: translateY(-4px);
}

.life-gallery-item .info {
  padding: 12px;
}

.life-gallery-item .info .code {
  margin-top: 4px;
}

.life-gallery-item .info h3 {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── 卡片信息区 ── */
.life-card-info {
  padding: 12px 14px 14px;
}

.life-card-code {
  margin-top: 4px;
}

.life-card-image {
  overflow: hidden;
}

.life-card-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.life-card-title {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── 统计卡片 grid ── */
.life-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
}

/* ── 工具栏 ── */
.life-toolbar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ── 表格 ── */
.life-table-wrap {
  overflow-x: auto;
  max-width: 100%;
}

.life-table {
  width: 100%;
  border-collapse: collapse;
}

.life-table th {
  position: sticky;
  top: 0;
}

.life-table th,
.life-table td {
  padding: 10px 12px;
}

/* ── 居中表单 ── */
.life-center {
  max-width: 400px;
  margin: 60px auto;
}

/* ── 模态弹窗 ── */
.life-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--life-z-modal);
}

.life-modal-box {
  width: 90%;
  max-width: 500px;
}

/* ── 轮播 ── */
.life-carousel {
  overflow: hidden;
  max-width: 100%;
}

.life-carousel-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 4px;
  max-width: 100%;
}

.life-carousel-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
}

.life-carousel-slide img {
  display: block;
  width: 100%;
  max-height: 60vh;
}

/* ── 元信息条 ── */
.life-print-meta {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

/* ── 媒体列表 ── */
.life-media-list {
  margin-top: 12px;
}

.life-media-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
}

/* ── 编辑表单 ── */
.life-edit-form {
  margin-top: 20px;
}

/* ── 搜索栏 ── */
.life-search-bar {
  display: flex;
  max-width: 500px;
  margin: 20px auto;
  position: relative;
}

.life-search-bar::before {
  content: '> find prints --query';
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  white-space: nowrap;
}

.life-search-bar .life-input {
  flex: 1;
  min-width: 0;
  padding: 14px 14px 14px 210px;
}

.life-search-bar .btn {
  padding: 12px 14px;
}

/* ── Hero ── */
.life-hero {
  text-align: center;
  padding: 60px 20px 20px;
}

.life-hero p {
  margin-top: 6px;
}

/* ── 分页 ── */
.life-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
}

/* ── 标题栏 ── */
.life-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ── 按钮行 ── */
.life-btn-row {
  display: flex;
  gap: 8px;
}

.life-btn:hover {
  transform: scale(1.02);
}

.life-btn:active {
  transform: scale(0.98);
}

/* ── 标签布局 ── */
.life-label {
  display: block;
  margin-bottom: 6px;
}

/* ── 状态徽章布局 ── */
.life-status {
  display: inline-block;
  padding: 2px 8px;
}

/* ── 统计数据标签 ── */
.life-stat-card .label {
  margin-top: 4px;
}

/* ── 提示消息布局 ── */
.life-error-msg {
  margin-top: 8px;
}

/* ── 空态/加载态布局 ── */
.life-empty {
  padding: 80px 20px;
}

.life-loading {
  padding: 40px;
}

/* ── 所有者入口布局 ── */
.life-owner-entry {
  margin-top: 24px;
}

.life-owner-entry p {
  margin-bottom: 8px;
}

/* ── 分隔线间距 ── */
hr {
  margin: 20px 0;
}

/* ── § Section 空态隐藏 ── */
.life-section.is-empty {
  display: none;
}

/* ── § 策展分段布局 ── */
.life-section-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.life-section-head::after {
  content: '';
  flex: 1;
  height: 1px;
}

.life-section-featured {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
  margin-bottom: 32px;
}

.life-section-featured .life-gallery-item {
  break-inside: auto;
  margin-bottom: 0;
}

.life-section-featured .life-gallery-item:first-child {
  grid-row: span 2;
}

.life-section-featured .life-card-image {
  min-height: 100%;
}

.life-section-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.life-tag-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  cursor: pointer;
}

/* ── § 参数面板布局 ── */
.life-specs-panel {
  margin: 20px 0;
}

.life-specs-panel .spec-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 8px 0;
}

.life-specs-panel .spec-label {
  flex: 0 0 120px;
}

.life-specs-panel .spec-group {
  padding-left: 16px;
  margin-top: 4px;
}

.life-specs-panel .spec-group-header {
  padding: 6px 0 2px;
}

/* ── § 关联推荐布局 ── */
.life-related-section {
  margin-top: 32px;
}

.life-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.life-related-section .life-section-head {
  margin-bottom: 16px;
}

/* ── § 统计数据条 ── */
.life-hero-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-top: 20px;
}

/* ── Hero 轮播布局 ── */
.life-hero-carousel {
  position: relative;
  overflow: hidden;
  max-width: 100%;
  margin: 0 auto 24px;
  min-height: 360px;
  max-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.life-hero-track {
  display: flex;
}

.life-hero-slide {
  flex: 0 0 100%;
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.life-hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.life-hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
}

.life-hero-arrow--prev {
  left: 8px;
}

.life-hero-arrow--next {
  right: 8px;
}

.life-hero-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.life-hero-dot {
  width: 8px;
  height: 8px;
  border: none;
  cursor: pointer;
}

.life-hero-dot.is-active {
  transform: scale(1.35);
}

.life-hero-title-zh {
  margin-top: 4px;
}

/* ── Admin Panel — Tab Navigation ── */
.admin-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 20px;
}

.admin-tab {
  padding: 10px 20px;
  border: none;
  cursor: pointer;
}

.admin-tab-content {
  display: block;
}

.admin-tab-content.hidden {
  display: none;
}

/* ── Admin Panel — Detail Drawer ── */
.detail-drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
}

.detail-drawer-overlay.open {
  display: block;
}

.detail-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 440px;
  max-width: 100vw;
  height: 100%;
  z-index: 1001;
  overflow-y: auto;
  transform: translateX(100%);
}

.detail-drawer.open {
  transform: translateX(0);
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  position: sticky;
  top: 0;
  z-index: 1;
}

.drawer-header h2 {
  margin: 0;
}

.drawer-close-btn {
  border: none;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
}

.drawer-body {
  padding: 24px;
}

.drawer-section {
  margin-bottom: 24px;
}

.drawer-section-title {
  margin-bottom: 12px;
}

.detail-fields {
  display: grid;
  gap: 12px;
}

.detail-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.detail-field-value {
  word-break: break-word;
}

.drawer-actions {
  display: flex;
  gap: 8px;
  padding: 16px 24px;
  position: sticky;
  bottom: 0;
}

/* ── Admin Panel — Media Gallery ── */
.media-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 8px;
}

.media-gallery-item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.media-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
}

.media-gallery-item .media-type-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  padding: 2px 6px;
}

.media-gallery-item .media-size {
  position: absolute;
  bottom: 4px;
  right: 4px;
  padding: 2px 6px;
}

.media-gallery-empty {
  padding: 20px;
  text-align: center;
}

/* ── Admin Panel — Status Toggle Buttons (layout-only) ── */
.btn-status-disabled {
  cursor: not-allowed;
}

/* ── Admin Panel — Upload Zone ── */
.upload-zone {
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
}

.upload-zone-icon {
  display: block;
  margin-bottom: 12px;
}

.upload-zone-text {
  margin: 0;
}

.upload-zone-hint {
  margin-top: 8px;
}

.upload-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
  gap: 8px;
  margin-top: 16px;
}

.upload-preview-item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.upload-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.upload-preview-remove {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 22px;
  height: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* ── Admin Panel — Test Prints List ── */
.test-prints-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
}

/* ── Admin Panel — Status Modal ── */
.status-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1002;
  display: flex;
  align-items: center;
  justify-content: center;
}

.status-modal-box {
  padding: 24px;
  width: 380px;
  max-width: calc(100vw - 32px);
}

.status-modal-box h3 {
  margin-bottom: 16px;
  margin-top: 0;
}

.status-modal-box .life-input {
  width: 100%;
  box-sizing: border-box;
}

.status-modal-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  justify-content: flex-end;
}

/* ── 下拉刷新指示器（layout） ── */
.pull-refresh {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
}

.pull-refresh .spinner {
  width: 14px;
  height: 14px;
  display: inline-block;
}

/* ── 底部加载指示器（layout） ── */
.load-more-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.load-more-indicator .spinner {
  width: 14px;
  height: 14px;
  display: inline-block;
}

/* ── 卡片数据面板（layout） ── */
.life-card-panel {
  position: relative;
}

.life-card-panel .life-holo-id {
  position: absolute;
  top: 8px;
  right: 10px;
  pointer-events: none;
}

.life-card-panel .life-material-badge {
  position: absolute;
  bottom: 8px;
  right: 10px;
  padding: 2px 6px;
  pointer-events: none;
}

.life-card-panel .life-status-dot {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 8px;
  height: 8px;
  pointer-events: none;
}

/* ── 详情页：Hero 封面（layout） ── */
.life-hero-cover {
  position: relative;
  overflow: hidden;
  max-width: 100%;
}

.life-hero-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.life-hero-cover.is-portrait {
  max-width: 420px;
  margin: 0 auto;
}

.life-hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 20px 18px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.life-hero-overlay h1 {
  margin: 0 0 4px;
}

.life-hero-share {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.life-hero-share button {
  cursor: pointer;
  padding: 5px 10px;
}

/* ── 详情页：缩略条（layout） ── */
.life-thumb-strip {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.life-thumb-strip img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  cursor: pointer;
}

.life-thumb-more {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── 详情页：媒体图标（layout） ── */
.life-media-icons {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.life-media-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  cursor: pointer;
}

.life-media-play .life-media-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  flex-shrink: 0;
}

.life-media-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  flex-shrink: 0;
}

/* ── 详情页：规格卡片（layout） ── */
.life-spec-card {
  overflow: hidden;
}

.life-spec-header {
  padding: 10px 16px 6px;
}

.life-spec-grid {
  padding: 0 16px 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
}

.life-spec-grid .spec-item {
  display: flex;
  width: 50%;
  padding: 5px 0;
  align-items: center;
}

.life-spec-grid .spec-label {
  width: 36px;
  flex-shrink: 0;
}

.life-spec-sub {
  margin: 0 12px 8px;
  padding-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 2px 0;
}

.life-spec-sub .spec-item {
  display: flex;
  width: 50%;
  padding: 2px 4px;
  align-items: center;
}

.life-spec-sub .spec-label {
  width: 36px;
  flex-shrink: 0;
}

/* ── 详情页：描述（layout） ── */

/* ── 详情页：关联作品标题（layout） ── */

/* ── Nav 下划线（layout-only, visual part in life-visual.css） ── */

/* ── 返回顶部按钮（layout） ── */
.back-to-top {
  width: 32px;
  height: 32px;
  cursor: pointer;
  flex-shrink: 0;
}

/* ── ============================================================
     响应式 — 放文件末尾，仅调布局参数
   nav/footer 响应式由 web-page-shell.css 管理
   ============================================================ */
@media (max-width: 720px) {
  .life-container {
    padding: 16px var(--shell-gutter);
  }
  .life-content {
    padding: 12px;
  }
  .life-gallery {
    columns: 2 160px;
    column-gap: 8px;
  }

  /* ── 策展分段移动端 ── */
  .life-section-featured {
    grid-template-columns: 1fr;
  }
  .life-section-featured .life-gallery-item:first-child {
    grid-row: auto;
  }

  /* ── 参数面板移动端 ── */
  .life-specs-panel .spec-row {
    flex-direction: column;
    gap: 2px;
  }
  .life-specs-panel .spec-label {
    flex: none;
  }

  /* ── Hero 统计条移动端 ── */
  .life-hero-stats {
    flex-wrap: wrap;
    gap: 16px;
  }

  /* ── Hero 轮播移动端 ── */
  .life-hero-slide {
    min-height: 240px;
  }
}

@media (max-width: 768px) {
  .detail-drawer {
    width: 100%;
    top: auto;
    bottom: 0;
    height: 85vh;
    transform: translateY(100%);
  }

  .detail-drawer.open {
    transform: translateY(0);
  }

  .life-hero-overlay {
    padding: 16px 12px 12px;
  }

  .life-hero-share button {
    padding: 4px 8px;
  }

  .life-thumb-strip {
    gap: 6px;
  }

  .life-thumb-strip img {
    width: 42px;
    height: 42px;
  }

  .life-thumb-more {
    width: 42px;
    height: 42px;
  }

  .life-media-icons {
    gap: 8px;
  }

  .life-media-btn {
    padding: 5px 12px;
  }

  .life-spec-header {
    padding: 8px 14px 6px;
  }

  .life-spec-grid {
    padding: 0 14px 8px;
  }
}
