@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;600&family=Noto+Serif+SC:wght@600&display=swap");

/* 青年美图风格 - 全局变量 */
:root {
  --gp-body-bg: #f0f0f0;
  --gp-text: #222222;
  --gp-text-secondary: #5a5a5a;
  --gp-link: #1e73be;
  --gp-link-hover: #000000;
  --gp-accent: #1e73be;
  --gp-header-bg: #ffffff;
  --gp-footer-bg: #222222;
  --gp-footer-text: #ffffff;
  --gp-card-bg: #ffffff;
  --gp-border: #e8e8e8;
  --gp-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

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

html {
  background: var(--gp-body-bg);
  scroll-behavior: smooth;
}

body {
  font-family: "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  background: var(--gp-body-bg);
  color: var(--gp-text);
  min-height: 100vh;
  padding-bottom: 0;
}

a {
  color: var(--gp-link);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--gp-link-hover);
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* 涓诲鍣?*/
.site-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.max-w-screen-xl {
  max-width: 1200px !important;
  margin: 0 auto;
}

/* ==================== 椤堕儴瀵艰埅鏍?- 淇甯冨眬 ==================== */
.site-header {
  background: var(--gp-header-bg);
  border-bottom: 1px solid var(--gp-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: none;
}

.site-header .header-inner {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0 40px;
  max-width: 1400px;
  margin: 0 auto;
  height: 60px;
  gap: 0;
  flex-wrap: nowrap;
}

/* 网站标题 */
.site-branding {
  flex-shrink: 0;
  margin-right: 30px;
}

.site-title {
  font-size: 24px;
  font-weight: 700;
  margin: 0;
  white-space: nowrap;
}

.site-title a {
  color: var(--gp-text);
  text-decoration: none;
  font-family: "Noto Serif SC", serif;
}

.site-title a:hover {
  color: var(--gp-accent);
}

/* Logo图片样式 */
.site-logo {
  height: 36px;
  width: auto;
  max-width: 140px;
  display: block;
  object-fit: contain;
}

.logo-container {
  display: flex;
  align-items: center;
  height: 100%;
}

.logo-container a {
  display: flex;
  align-items: center;
  height: 100%;
}

/* 移动端Logo调整 */
@media (max-width: 768px) {
  .site-logo {
    height: 28px;
    max-width: 110px;
  }
}

/* 娑撹顕遍懜顏囧綅閸?*/
.main-navigation {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.main-navigation ul,
.main-navigation .menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0;
}

.main-navigation li {
  position: relative;
}

.main-navigation a {
  display: flex;
  align-items: center;
  padding: 0 20px;
  height: 60px;
  color: var(--gp-text);
  font-size: 15px;
  font-weight: 500;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.main-navigation a:hover,
.main-navigation .current-menu-item a {
  color: var(--gp-accent);
}

/* 澶撮儴鍙充晶鎿嶄綔鍖?*/
.header-actions {
  display: flex;
  align-items: center;
  margin-left: auto;
  gap: 10px;
  flex-shrink: 0;
}

/* 鎼滅储妗?*/
.search-group {
  display: flex;
  align-items: center;
  background: #f7f7f7;
  border: 1px solid var(--gp-border);
  border-radius: 3px;
  overflow: hidden;
  height: 36px;
}

.search-input {
  background: transparent;
  border: none;
  padding: 0 12px;
  font-size: 14px;
  color: var(--gp-text);
  width: 160px;
  height: 100%;
  outline: none;
}

.search-input::placeholder {
  color: #999;
}

.search-input:focus {
  background: #fff;
}

/* 按钮样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 500;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
  height: 36px;
}

.btn-primary {
  background: var(--gp-accent);
  color: #fff;
}

.btn-primary:hover {
  background: #155a8a;
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--gp-text);
  border: 1px solid var(--gp-border);
}

.btn-secondary:hover {
  background: var(--gp-text);
  color: #fff;
  border-color: var(--gp-text);
}

.btn-success {
  background: #28a745;
  color: #fff;
}

.btn-success:hover {
  background: #218838;
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--gp-text);
}

.btn-ghost:hover {
  color: var(--gp-accent);
}

.btn-sm {
  padding: 6px 14px;
  font-size: 13px;
  height: 32px;
}

/* 涓诲唴瀹瑰尯鍩?*/
main {
  padding: 30px 0;
}

.site-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* 鍥鹃泦缃戞牸 - 鐎戝竷娴侀鏍?*/
#albumGrid,
#favoriteGrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 20px;
}

@media (max-width: 1024px) {
  #albumGrid,
  #favoriteGrid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  #albumGrid,
  #favoriteGrid {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    padding: 15px;
  }
}

/* 图集卡片 - 青年美图风格 */
.album-card {
  background: var(--gp-card-bg);
  border-radius: 0;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.album-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.album-card .post-image {
  position: relative;
  overflow: hidden;
}

.album-card .album-image {
  width: 100%;
  height: auto;
  aspect-ratio: 2/3;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.album-card:hover .album-image {
  transform: scale(1.03);
}

.album-card .inside-article {
  padding: 15px;
}

.album-card .entry-header {
  margin-bottom: 10px;
}

.album-card .album-title,
.album-card .entry-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--gp-text);
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.album-card .entry-title a {
  color: inherit;
}

.album-card .entry-title a:hover {
  color: var(--gp-accent);
}

.album-card .entry-meta {
  font-size: 13px;
  color: var(--gp-text-secondary);
  margin-top: 8px;
}

.album-card .cat-links {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.album-card .cat-links a {
  background: #f0f0f0;
  padding: 3px 10px;
  font-size: 12px;
  color: var(--gp-text-secondary);
  border-radius: 2px;
}

.album-card .cat-links a:hover {
  background: var(--gp-accent);
  color: #fff;
}

/* 收藏按钮 */
.album-card .album-fav-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(0,0,0,0.5);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 16px;
}

.album-card .album-fav-btn:hover {
  background: var(--gp-accent);
}

/* 分页导航 - 青年美图风格 */
.pagination-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 30px 20px;
  gap: 5px;
  background: transparent;
  position: static;
  border: none;
}

.pagination-bar a,
.pagination-bar span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 15px;
  background: var(--gp-card-bg);
  color: var(--gp-text);
  border: 1px solid var(--gp-border);
  font-size: 14px;
  transition: all 0.2s ease;
}

.pagination-bar a:hover {
  background: var(--gp-accent);
  color: #fff;
  border-color: var(--gp-accent);
}

.pagination-bar .current,
.pagination-bar span.current {
  background: var(--gp-accent);
  color: #fff;
  border-color: var(--gp-accent);
}

/* 鎼存洟鍎寸€佃壈鍩呴弽?- 闂堟帒鍕剧紘搴℃禈妞嬪孩鐗?*/
.site-footer {
  background: var(--gp-footer-bg);
  color: var(--gp-footer-text);
  padding: 30px 0;
  margin-top: 40px;
}

.site-footer .inside-site-info {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  text-align: center;
}

.site-footer .footer-bar {
  margin-bottom: 15px;
}

.site-footer .footer-bar a {
  color: rgba(255,255,255,0.8);
  margin: 0 10px;
  font-size: 14px;
}

.site-footer .footer-bar a:hover {
  color: #fff;
}

.site-footer .copyright-bar {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
}

.site-footer .copyright-bar a {
  color: rgba(255,255,255,0.8);
}

/* 缁夎濮╃粩顖氱俺闁劌顕遍懜?- 闂呮劘妫?*/
.mobile-bottom-nav,
.desktop-bottom-nav {
  display: none !important;
}

/* 回到顶部按钮 */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  background: var(--gp-accent);
  color: #fff;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 99;
  text-decoration: none;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: #155a8a;
  color: #fff;
}

/* 页面标题区域 */
.page-header {
  background: var(--gp-card-bg);
  padding: 30px;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--gp-border);
}

.page-header .page-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--gp-text);
  margin: 0;
}

.section-head {
  padding: 20px;
  margin-bottom: 0;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--gp-text);
  font-family: "Noto Serif SC", serif;
}

/* 图集详情页 */
.album-header {
  background: var(--gp-header-bg);
  padding: 15px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--gp-border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.album-header .logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--gp-text);
}

.gallery {
  max-width: 900px;
  margin: 0 auto;
  padding: 30px 20px;
}

.gallery h1 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--gp-text);
}

#album-images {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

#album-images img {
  width: 100%;
  height: auto;
}

/* 浮动按钮 */
.floating-btn {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.6);
  color: #fff;
  padding: 15px 20px;
  cursor: pointer;
  font-size: 14px;
  z-index: 99;
  transition: background 0.2s ease;
}

.floating-btn:hover {
  background: var(--gp-accent);
}

.floating-btn.left {
  left: 0;
  border-radius: 0 3px 3px 0;
}

.floating-btn.right {
  right: 0;
  border-radius: 3px 0 0 3px;
}

/* 閸濆秴绨插蹇氱殶閺?*/
@media (max-width: 992px) {
  .site-header .header-inner {
    padding: 0 20px;
  }

  .main-navigation a {
    padding: 0 15px;
  }

  .search-input {
    width: 120px;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  .site-header .header-inner {
    padding: 0 15px;
    height: 50px;
    flex-wrap: wrap;
  }

  .site-branding {
    margin-right: 15px;
  }

  .site-title {
    font-size: 18px;
  }

  .main-navigation {
    display: none;
  }

  .main-navigation.toggled {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--gp-header-bg);
    border-bottom: 1px solid var(--gp-border);
    box-shadow: 0 5px 10px rgba(0,0,0,0.1);
  }

  .main-navigation.toggled ul {
    flex-direction: column;
    width: 100%;
  }

  .main-navigation.toggled a {
    height: auto;
    padding: 15px 20px;
    border-bottom: 1px solid var(--gp-border);
  }

  .header-actions {
    gap: 8px;
  }

  .search-group {
    display: none;
  }

  .btn-sm {
    padding: 5px 10px;
    font-size: 12px;
    height: 28px;
  }

  main {
    padding: 20px 0;
  }

  .page-header {
    padding: 20px;
  }

  .page-header .page-title {
    font-size: 22px;
  }

  .floating-btn {
    padding: 10px 15px;
    font-size: 12px;
  }
}

/* 绉诲姩绔彍鍗曟寜閽?*/
.menu-toggle {
  display: none;
  background: none;
  border: none;
  padding: 10px;
  cursor: pointer;
  order: 10;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--gp-text);
  margin: 5px 0;
  transition: all 0.3s ease;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
}

/* 搜索图标 */
.gp-icon {
  display: inline-flex;
  align-items: center;
}

.gp-icon svg {
  width: 1em;
  height: 1em;
  fill: currentColor;
}

/* 分类图标 */
.icon-categories svg {
  margin-right: 5px;
}

/* 表单样式 */
input[type="text"],
input[type="password"],
textarea {
  border: 1px solid var(--gp-border);
  padding: 10px 15px;
  font-size: 14px;
  border-radius: 3px;
  transition: border-color 0.2s ease;
}

input[type="text"]:focus,
input[type="password"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--gp-accent);
}

/* 用户资料页面 */
.profile-avatar {
  border: 3px solid var(--gp-border);
}

/* 上传页面容器 */
.upload-container {
  background: var(--gp-card-bg);
  border-radius: 3px;
  padding: 30px;
  max-width: 600px;
  margin: 0 auto;
}

/* 杩涘害鏉?*/
.progress-bar {
  height: 4px;
  background: #e0e0e0;
  border-radius: 2px;
  overflow: hidden;
}

.progress-bar::after {
  content: '';
  display: block;
  height: 100%;
  background: var(--gp-accent);
  width: 0;
  transition: width 0.3s ease;
}

/* 闅愯棌绫?*/
.hidden {
  display: none !important;
}

/* 閸ョ偓鐖ｉ弽宄扮础 - 缁犫偓閸?*/
.icon-home,
.icon-heart,
.icon-upload,
.icon-user {
  display: none;
}

/* 加载动画 */
@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid var(--gp-accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* 宸茬櫥褰曠敤鎴锋樉绀?*/
#userInfo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--gp-text);
}
