/* ============================================
   Visual style presets
   data-style="pixel" keeps the current site look.
   data-style="vereis" applies a softer hand-drawn palette.
   ============================================ */

html[data-style="vereis"] {
  --style-bg: #fff8ef;
  --style-bg-soft: #fef1ee;
  --style-bg-lavender: #f4efff;
  --style-card: rgba(255, 252, 247, 0.9);
  --style-card-solid: #fffcf7;
  --style-border: rgba(220, 175, 190, 0.38);
  --style-border-strong: rgba(192, 146, 168, 0.58);
  --style-text: #383348;
  --style-muted: #746c82;
  --style-title: #2f3047;
  --style-accent: #b78bec;
  --style-accent-pink: #ee9ab3;
  --style-accent-mint: #76bea7;
  --style-shadow: 0 18px 45px rgba(143, 102, 128, 0.14);
  --style-shadow-soft: 0 8px 24px rgba(143, 102, 128, 0.11);
  --style-radius: 18px;
  --style-radius-sm: 12px;
  color-scheme: light;
}

html[data-style="vereis"][data-theme="dark"] {
  --style-bg: #171522;
  --style-bg-soft: #211b2d;
  --style-bg-lavender: #272138;
  --style-card: rgba(34, 29, 45, 0.9);
  --style-card-solid: #221d2d;
  --style-border: rgba(221, 190, 224, 0.22);
  --style-border-strong: rgba(221, 190, 224, 0.34);
  --style-text: #eee9f3;
  --style-muted: #beb4ca;
  --style-title: #fff8ff;
  --style-accent: #caa6ff;
  --style-accent-pink: #f1a7bf;
  --style-accent-mint: #90d6bf;
  --style-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
  --style-shadow-soft: 0 8px 24px rgba(0, 0, 0, 0.22);
  color-scheme: dark;
}

html[data-style="vereis"] body {
  font-family: "Trebuchet MS", "Hiragino Sans GB", "Microsoft YaHei", "PingFang SC", sans-serif !important;
  color: var(--style-text) !important;
  background:
    radial-gradient(circle at 12% 18%, rgba(238, 154, 179, 0.22), transparent 24rem),
    radial-gradient(circle at 82% 12%, rgba(183, 139, 236, 0.18), transparent 22rem),
    linear-gradient(180deg, var(--style-bg) 0%, var(--style-bg-soft) 54%, var(--style-bg) 100%) !important;
  letter-spacing: 0;
}

html[data-style="vereis"] #web_bg {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.32) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.32) 1px, transparent 1px),
    linear-gradient(180deg, var(--style-bg) 0%, var(--style-bg-soft) 100%) !important;
  background-size: 44px 44px, 44px 44px, auto !important;
}

html[data-style="vereis"] #cloud-bg .bg-layer {
  background:
    radial-gradient(circle at 20% 22%, rgba(238, 154, 179, 0.2), transparent 22rem),
    radial-gradient(circle at 72% 8%, rgba(183, 139, 236, 0.18), transparent 24rem),
    linear-gradient(180deg, #fff8ef 0%, #fef1ee 48%, #fffaf2 100%) !important;
}

html[data-style="vereis"][data-theme="dark"] #cloud-bg .bg-layer {
  background:
    radial-gradient(circle at 18% 18%, rgba(183, 139, 236, 0.18), transparent 22rem),
    radial-gradient(circle at 78% 12%, rgba(238, 154, 179, 0.13), transparent 24rem),
    linear-gradient(180deg, #171522 0%, #211b2d 54%, #171522 100%) !important;
}

html[data-style="vereis"] #cloud-bg .far-cloud {
  opacity: 0.32 !important;
  filter: saturate(0.72) brightness(1.08);
  animation-duration: 180s !important;
}

html[data-style="vereis"] #cloud-bg .near-cloud {
  opacity: 0.42 !important;
  filter: saturate(0.68) brightness(1.1);
  animation-duration: 110s !important;
}

html[data-style="vereis"][data-theme="dark"] #cloud-bg .far-cloud,
html[data-style="vereis"][data-theme="dark"] #cloud-bg .near-cloud {
  opacity: 0.08 !important;
  filter: saturate(0.55) brightness(0.75);
}

html[data-style="vereis"] body.page-type-home #page-header.full_page {
  min-height: 660px;
  background-position: center top !important;
}

html[data-style="vereis"] body.page-type-home #page-header.full_page::before {
  background:
    radial-gradient(circle at 34% 42%, rgba(255, 248, 239, 0.8), transparent 24rem),
    linear-gradient(90deg, rgba(255, 248, 239, 0.9) 0%, rgba(255, 248, 239, 0.62) 42%, rgba(255, 248, 239, 0.28) 100%) !important;
}

html[data-style="vereis"][data-theme="dark"] body.page-type-home #page-header.full_page::before {
  background:
    radial-gradient(circle at 34% 42%, rgba(39, 33, 56, 0.78), transparent 24rem),
    linear-gradient(90deg, rgba(23, 21, 34, 0.92) 0%, rgba(23, 21, 34, 0.72) 48%, rgba(23, 21, 34, 0.36) 100%) !important;
}

html[data-style="vereis"] body.page-type-home #page-header.full_page #site-info {
  top: 50%;
  left: 50%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 42px;
  align-items: center;
  width: min(1120px, calc(100% - 48px));
  padding: 0;
  text-align: left;
  transform: translate(-50%, -48%);
}

html[data-style="vereis"] body.page-type-home #site-title,
html[data-style="vereis"] body.page-type-home #site-subtitle,
html[data-style="vereis"] body.page-type-home #scroll-down .scroll-down-effects {
  text-align: left !important;
}

html[data-style="vereis"] body.page-type-home #site-title,
html[data-style="vereis"] body.page-type-home #site-subtitle,
html[data-style="vereis"] body.page-type-home #site_social_icons {
  grid-column: 1;
}

html[data-style="vereis"] body.page-type-home #site-title {
  max-width: 620px;
  color: var(--style-title) !important;
  font-size: 3.75rem !important;
  line-height: 1.08 !important;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.76) !important;
}

html[data-style="vereis"][data-theme="dark"] body.page-type-home #site-title {
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.28) !important;
}

html[data-style="vereis"] body.page-type-home #site-subtitle {
  max-width: 560px;
  margin-top: 16px;
  color: var(--style-muted) !important;
  font-size: 1.38rem !important;
  line-height: 1.6;
  text-shadow: none !important;
}

html[data-style="vereis"] body.page-type-home #site_social_icons {
  display: flex !important;
  justify-content: flex-start;
  gap: 12px;
  margin: 26px 0 0;
  text-align: left;
}

html[data-style="vereis"] body.page-type-home #site_social_icons .social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0;
  border: 1px solid var(--style-border-strong);
  border-radius: 999px;
  background: rgba(255, 252, 247, 0.82);
  color: var(--style-title) !important;
  box-shadow: var(--style-shadow-soft);
  text-shadow: none !important;
}

html[data-style="vereis"] body.page-type-home #site_social_icons .social-icon:hover {
  border-color: var(--style-accent-pink);
  color: var(--style-accent-pink) !important;
  transform: translateY(-2px);
}

.vereis-home-panel[hidden] {
  display: none !important;
}

html[data-style="vereis"] .vereis-home-panel {
  position: relative;
  grid-column: 2;
  grid-row: 1 / span 3;
  align-self: center;
  display: grid;
  gap: 18px;
  min-height: 320px;
  padding: 26px;
  border: 1px solid var(--style-border);
  border-radius: 24px;
  background:
    radial-gradient(circle at 82% 12%, rgba(183, 139, 236, 0.2), transparent 9rem),
    linear-gradient(180deg, rgba(255, 252, 247, 0.92), rgba(255, 247, 252, 0.82));
  box-shadow: var(--style-shadow);
  color: var(--style-text);
  backdrop-filter: blur(20px);
  overflow: hidden;
}

html[data-style="vereis"] .vereis-home-panel::before {
  content: "";
  position: absolute;
  right: -32px;
  bottom: -38px;
  width: 148px;
  height: 148px;
  border: 1px solid rgba(238, 154, 179, 0.32);
  border-radius: 45% 55% 48% 52%;
  background: rgba(238, 154, 179, 0.14);
}

html[data-style="vereis"][data-theme="dark"] .vereis-home-panel {
  background:
    radial-gradient(circle at 82% 12%, rgba(202, 166, 255, 0.18), transparent 9rem),
    linear-gradient(180deg, rgba(34, 29, 45, 0.94), rgba(39, 33, 56, 0.84));
}

html[data-style="vereis"] .vereis-panel-status,
html[data-style="vereis"] .vereis-panel-grid span {
  display: inline-flex;
  align-items: center;
}

html[data-style="vereis"] .vereis-panel-status {
  width: fit-content;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid rgba(118, 190, 167, 0.32);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  color: var(--style-muted);
  font-size: 0.86rem;
  font-weight: 700;
}

html[data-style="vereis"] .vereis-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--style-accent-mint);
  box-shadow: 0 0 0 4px rgba(118, 190, 167, 0.18);
}

html[data-style="vereis"] .vereis-panel-main {
  position: relative;
  z-index: 1;
}

html[data-style="vereis"] .vereis-panel-kicker {
  display: block;
  margin-bottom: 10px;
  color: var(--style-accent-pink);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

html[data-style="vereis"] .vereis-panel-main strong {
  display: block;
  color: var(--style-title);
  font-size: 1.55rem;
  line-height: 1.25;
}

html[data-style="vereis"] .vereis-panel-main p {
  margin: 12px 0 0;
  color: var(--style-muted);
  font-size: 0.98rem;
  line-height: 1.75;
}

html[data-style="vereis"] .vereis-panel-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-self: end;
}

html[data-style="vereis"] .vereis-panel-grid span {
  justify-content: center;
  gap: 6px;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid var(--style-border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.48);
  color: var(--style-title);
  font-size: 0.82rem;
  font-weight: 700;
}

html[data-style="vereis"] .vereis-panel-grid i {
  color: var(--style-accent);
}

html[data-style="vereis"] #nav,
html[data-style="vereis"] body.page-type-home #nav,
html[data-style="vereis"] body.page-type-archive #nav,
html[data-style="vereis"] body.page-type-tag #nav,
html[data-style="vereis"] body.page-type-category #nav,
html[data-style="vereis"] body.page-type-about #nav,
html[data-style="vereis"] body.page-type-post #nav {
  background: rgba(255, 250, 244, 0.78) !important;
  border-bottom: 1px solid var(--style-border);
  box-shadow: 0 8px 24px rgba(143, 102, 128, 0.08);
  backdrop-filter: blur(18px);
}

html[data-style="vereis"][data-theme="dark"] #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-home #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-archive #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-tag #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-category #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-about #nav,
html[data-style="vereis"][data-theme="dark"] body.page-type-post #nav {
  background: rgba(29, 24, 39, 0.82) !important;
}

html[data-style="vereis"] #nav a,
html[data-style="vereis"] #nav .site-name {
  color: var(--style-title) !important;
  text-shadow: none !important;
}

html[data-style="vereis"] .layout,
html[data-style="vereis"] .recent-post-item,
html[data-style="vereis"] #post,
html[data-style="vereis"] #page,
html[data-style="vereis"] .post-content,
html[data-style="vereis"] .card-widget,
html[data-style="vereis"] body.page-type-home .card-widget,
html[data-style="vereis"] body.page-type-archive .card-widget,
html[data-style="vereis"] body.page-type-tag .card-widget,
html[data-style="vereis"] body.page-type-category .card-widget,
html[data-style="vereis"] body.page-type-about .card-widget,
html[data-style="vereis"] body.page-type-post .card-widget {
  background: var(--style-card) !important;
  border: 1px solid var(--style-border) !important;
  border-radius: var(--style-radius) !important;
  box-shadow: var(--style-shadow-soft) !important;
  backdrop-filter: blur(18px);
}

html[data-style="vereis"] .recent-post-item {
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

html[data-style="vereis"] .recent-post-item:hover {
  border-color: var(--style-border-strong) !important;
  box-shadow: var(--style-shadow) !important;
  transform: translateY(-3px);
}

html[data-style="vereis"] .recent-post-item .post_cover img.post-bg,
html[data-style="vereis"] .recent-post-item .post_cover .post-bg {
  filter: saturate(0.86) brightness(1.03);
}

html[data-style="vereis"] .recent-post-info {
  padding: 28px !important;
}

html[data-style="vereis"] .recent-post-info .article-title {
  display: inline;
  background-image: linear-gradient(transparent 66%, rgba(238, 154, 179, 0.28) 0);
  background-size: 100% 100%;
  font-size: 1.28rem !important;
  line-height: 1.45;
}

html[data-style="vereis"] .article-meta-wrap {
  color: var(--style-muted) !important;
  font-size: 0.82rem !important;
}

html[data-style="vereis"] .article-meta-wrap a,
html[data-style="vereis"] .article-meta-wrap span,
html[data-style="vereis"] .article-meta-wrap time {
  color: var(--style-muted) !important;
}

html[data-style="vereis"] .card-widget {
  padding: 24px !important;
}

html[data-style="vereis"] .card-widget .item-headline {
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--style-border);
}

html[data-style="vereis"] .card-widget.card-info {
  background:
    radial-gradient(circle at 80% 0%, rgba(183, 139, 236, 0.18), transparent 10rem),
    var(--style-card) !important;
}

html[data-style="vereis"] #article-container,
html[data-style="vereis"] #article-container p,
html[data-style="vereis"] #article-container li,
html[data-style="vereis"] .post-content,
html[data-style="vereis"] .post-content p,
html[data-style="vereis"] .post-content li,
html[data-style="vereis"] .recent-post-info .content,
html[data-style="vereis"] .card-widget,
html[data-style="vereis"] .card-widget *:not(a):not(i) {
  color: var(--style-text) !important;
}

html[data-style="vereis"] h1,
html[data-style="vereis"] h2,
html[data-style="vereis"] h3,
html[data-style="vereis"] h4,
html[data-style="vereis"] h5,
html[data-style="vereis"] h6,
html[data-style="vereis"] .post-title,
html[data-style="vereis"] .article-title,
html[data-style="vereis"] .recent-post-info .article-title,
html[data-style="vereis"] .card-widget .item-headline {
  color: var(--style-title) !important;
  letter-spacing: 0;
  text-shadow: none !important;
}

html[data-style="vereis"] a {
  color: #8f68d6 !important;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

html[data-style="vereis"] a:hover {
  color: var(--style-accent-pink) !important;
}

html[data-style="vereis"][data-theme="dark"] a {
  color: var(--style-accent) !important;
}

html[data-style="vereis"] .card-widget .button--animated,
html[data-style="vereis"] .pagination .page-number.current,
html[data-style="vereis"] .post-meta__tag-list a,
html[data-style="vereis"] .post-tag a,
html[data-style="vereis"] #tag-page-tags a,
html[data-style="vereis"] .tag-cloud a {
  border-radius: 999px !important;
  border: 1px solid var(--style-border-strong) !important;
  background: linear-gradient(135deg, rgba(255, 247, 252, 0.92), rgba(244, 239, 255, 0.92)) !important;
  color: var(--style-title) !important;
  box-shadow: 0 5px 14px rgba(143, 102, 128, 0.1) !important;
}

html[data-style="vereis"] .card-widget .button--animated:hover,
html[data-style="vereis"] .post-meta__tag-list a:hover,
html[data-style="vereis"] .post-tag a:hover,
html[data-style="vereis"] #tag-page-tags a:hover,
html[data-style="vereis"] .tag-cloud a:hover {
  border-color: var(--style-accent-pink) !important;
  transform: translateY(-1px);
}

html[data-style="vereis"] blockquote {
  background: linear-gradient(90deg, rgba(244, 239, 255, 0.78), rgba(255, 247, 252, 0.72)) !important;
  border-left: 4px solid var(--style-accent) !important;
  color: var(--style-muted) !important;
  border-radius: 0 var(--style-radius-sm) var(--style-radius-sm) 0;
}

html[data-style="vereis"] code {
  background: rgba(244, 239, 255, 0.8) !important;
  color: #9b5678 !important;
  border: 1px solid rgba(183, 139, 236, 0.18);
  border-radius: 7px;
}

html[data-style="vereis"][data-theme="dark"] code {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #f4b6ca !important;
}

html[data-style="vereis"] #footer,
html[data-style="vereis"] body.page-type-home #footer,
html[data-style="vereis"] body.page-type-archive #footer,
html[data-style="vereis"] body.page-type-tag #footer,
html[data-style="vereis"] body.page-type-category #footer,
html[data-style="vereis"] body.page-type-about #footer,
html[data-style="vereis"] body.page-type-post #footer {
  background: rgba(255, 250, 244, 0.72) !important;
  border-top: 1px solid var(--style-border);
  color: var(--style-muted) !important;
  backdrop-filter: blur(18px);
}

html[data-style="vereis"][data-theme="dark"] #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-home #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-archive #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-tag #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-category #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-about #footer,
html[data-style="vereis"][data-theme="dark"] body.page-type-post #footer {
  background: rgba(29, 24, 39, 0.82) !important;
}

html[data-style="vereis"] #rightside button,
html[data-style="vereis"] #rightside a {
  background: var(--style-card-solid) !important;
  color: var(--style-title) !important;
  border: 1px solid var(--style-border) !important;
  box-shadow: var(--style-shadow-soft);
}

html[data-style="vereis"] #rightside button:hover,
html[data-style="vereis"] #rightside a:hover {
  background: linear-gradient(135deg, #fff7fc, #f4efff) !important;
  color: var(--style-accent-pink) !important;
}

#style-switcher-btn {
  position: relative;
}

#style-switcher-btn[aria-pressed="true"] i {
  color: var(--style-accent-pink, #ee9ab3);
}

html[data-style="vereis"] #style-switcher-btn::after {
  content: "";
  position: absolute;
  top: 7px;
  right: 7px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--style-accent-mint);
  box-shadow: 0 0 0 2px var(--style-card-solid);
}

html[data-style="vereis"] input,
html[data-style="vereis"] textarea,
html[data-style="vereis"] select {
  background: rgba(255, 252, 247, 0.88) !important;
  border: 1px solid var(--style-border) !important;
  border-radius: var(--style-radius-sm) !important;
  color: var(--style-text) !important;
}

html[data-style="vereis"][data-theme="dark"] input,
html[data-style="vereis"][data-theme="dark"] textarea,
html[data-style="vereis"][data-theme="dark"] select {
  background: rgba(34, 29, 45, 0.92) !important;
}

@media (max-width: 768px) {
  html[data-style="vereis"] body.page-type-home #page-header.full_page {
    min-height: 720px;
  }

  html[data-style="vereis"] body.page-type-home #page-header.full_page #site-info {
    top: 54%;
    grid-template-columns: 1fr;
    gap: 24px;
    width: min(100% - 32px, 520px);
    transform: translate(-50%, -50%);
  }

  html[data-style="vereis"] body.page-type-home #site-title {
    font-size: 2.55rem !important;
  }

  html[data-style="vereis"] body.page-type-home #site-subtitle {
    font-size: 1.05rem !important;
  }

  html[data-style="vereis"] .vereis-home-panel {
    grid-column: 1;
    grid-row: auto;
    min-height: 0;
    padding: 20px;
  }

  html[data-style="vereis"] .vereis-panel-main strong {
    font-size: 1.24rem;
  }

  html[data-style="vereis"] .vereis-panel-grid {
    grid-template-columns: 1fr;
  }

  html[data-style="vereis"] .recent-post-info {
    padding: 22px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  html[data-style="vereis"] *,
  html[data-style="vereis"] *::before,
  html[data-style="vereis"] *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
