/* PHP 前台适配层：保留原版舞台光效与牌面，不使用 React 运行时。 */
.oracle-page {
  font-family: var(--font-body);
}
.muted {
  color: var(--o-muted, #cbb8df);
}
.oracle-mobile-menu[hidden] {
  display: none;
}
.oracle-menu-toggle {
  border: 0;
  background: none;
}
.oracle-footer {
  position: relative;
}
.php-portals {
  position: relative;
  max-width: 1050px;
  margin: 64px auto 100px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  padding: 0 24px;
}
.php-portals > a {
  background: #140b22;
  padding: 38px 20px 28px;
  text-align: center;
  border-radius: 120px 120px 20px 20px;
  transition:
    background 0.3s,
    transform 0.3s;
}
.php-portals > a:hover {
  background: #211032;
  transform: translateY(-5px);
}
.php-portals h2 {
  font-family: var(--o-display);
  font-size: 24px;
}
.php-portals .oracle-sigil {
  width: 56px;
  height: 56px;
  color: var(--o-gold);
  margin-bottom: 22px;
}
.php-portals p {
  font-size: 14px;
  color: var(--o-muted);
  min-height: 50px;
}
.php-portals span {
  font-size: 12px;
  color: var(--o-gold);
}
.php-editorial,
.content-wrap {
  max-width: 1100px;
  margin: auto;
  padding: 42px 32px 90px;
}
.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 26px;
}
.section-title h2 {
  font-size: 25px;
  margin: 0;
}
.section-title a {
  font-size: 14px;
  color: var(--o-muted);
}
.article-list {
  display: grid;
  gap: 28px;
}
.article-preview {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 24px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--o-line);
  align-items: center;
}
.article-preview img {
  width: 96px;
  aspect-ratio: 518/920;
  object-fit: contain;
  border-radius: 6px;
}
.article-preview h2,
.article-preview h3 {
  font-size: 20px;
  margin: 8px 0 12px;
}
.article-preview p {
  color: var(--o-muted);
  max-width: 650px;
  margin: 0;
}
.article-preview span {
  font-size: 12px;
  color: var(--o-gold);
}
.solid-action,
.plain-action {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  min-height: 48px;
  padding: 12px 27px;
  border-radius: 12px;
  border: 1px solid #d8bbdf75;
  background: #e2c89b;
  color: #29162c;
  font-weight: 500;
  transition:
    background 0.2s,
    transform 0.2s;
}
.solid-action:hover {
  background: #f1d7b0;
  transform: translateY(-1px);
}
.plain-action {
  background: transparent;
  color: var(--o-text);
  padding: 9px 18px;
  min-height: 44px;
  border-color: var(--o-line);
}
.plain-action:hover {
  background: #ffffff0d;
}
.form-error {
  color: #f4c3bb;
  font-size: 14px;
  min-height: 24px;
}
.content-page {
  background:
    radial-gradient(ellipse at 50% -10%, #4d286d 0, transparent 60%), #190f2c;
}
.content-wrap > h1 {
  font-size: 32px;
  margin-bottom: 30px;
}
.category-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0 0 35px;
}
.category-nav > a {
  font-size: 14px;
  border: 1px solid var(--o-line);
  padding: 7px 16px;
  border-radius: 22px;
}
.article-detail {
  max-width: 810px;
  margin: auto;
  padding: 40px 32px 90px;
}
.article-detail h1 {
  font-size: 34px;
  line-height: 1.4;
  margin: 20px 0;
}
.article-cover {
  float: right;
  width: 170px;
  margin: 0 0 26px 32px;
  border-radius: 7px;
}
.prose {
  font-size: 17px;
  line-height: 2;
}
.prose p {
  margin-bottom: 25px;
}
.article-detail .plain-action {
  margin-top: 24px;
}
.search-field {
  display: flex;
  gap: 15px;
  align-items: center;
  color: var(--o-muted);
  margin-bottom: 35px;
}
.search-field input {
  padding: 10px 16px;
  border: 1px solid var(--o-line);
  border-radius: 10px;
  background: #211331;
  color: var(--o-text);
}
.card-library {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 30px 22px;
}
.card-library img {
  border-radius: 7px;
  transition: transform 0.3s;
}
.card-library a:hover img {
  transform: translateY(-5px);
}
.card-library h2 {
  font-size: 16px;
  margin: 12px 0 4px;
  text-align: center;
}
.card-library p {
  font-size: 11px;
  text-align: center;
  color: var(--o-muted);
}
.card-detail {
  max-width: 1000px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 65px;
  margin: auto;
  padding: 40px 32px 80px;
}
.card-detail > img {
  position: sticky;
  top: 35px;
  border-radius: 8px;
}
.card-detail h1 {
  font-size: 36px;
  margin: 18px 0;
}
.card-detail h2 {
  font-size: 19px;
  margin: 30px 0 12px;
}
.card-detail p {
  line-height: 1.9;
}
#card-dialog {
  padding: 18px;
  background: #21132e;
  border: 1px solid #aa8bb955;
  border-radius: 14px;
  max-height: 95svh;
  color: #fff;
}
#card-dialog::backdrop {
  background: #100717dd;
}
#card-dialog > img {
  max-height: 80svh;
  max-width: 80vw;
  object-fit: contain;
  margin: 12px auto 0;
}
#card-dialog button {
  display: block;
  margin-left: auto;
  background: none;
  border: 0;
  color: #fff;
  padding: 5px 12px;
}
.account-bar {
  display: flex;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid var(--o-line);
  padding-bottom: 25px;
}
.account-bar form {
  margin-left: auto;
}
.account-bar button {
  border: 0;
  background: none;
  color: var(--o-muted);
}
.journal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--o-line);
  padding: 25px 0;
}
.journal-row h2 {
  font-size: 18px;
  margin: 0 0 8px;
}
.journal-row p {
  font-size: 13px;
  margin: 0;
  color: var(--o-muted);
}
.journal-row > span {
  white-space: nowrap;
  color: var(--o-gold);
  font-size: 13px;
}
.empty-state {
  padding: 70px 0;
  text-align: center;
}
.profile-wrap {
  max-width: 600px;
  margin: 50px auto;
  text-align: center;
  padding: 25px;
}
.avatar {
  background: #5b3b74;
  color: #eddbc0;
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  font-size: 30px;
  border-radius: 50%;
  margin: 0 auto 20px;
}
.message-wrap {
  max-width: 800px;
  margin: auto;
  padding: 30px 26px 70px;
}
.message-history {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin: 30px 0;
}
.message {
  padding: 15px 20px;
  border-radius: 14px;
  background: #321e43;
  width: fit-content;
  max-width: 85%;
  overflow-wrap: anywhere;
}
.message.mine {
  align-self: flex-end;
  background: #4a315c;
}
.message p {
  margin: 8px 0;
}
.message a,
.message time {
  font-size: 12px;
  color: var(--o-muted);
}
.message-form {
  display: grid;
  gap: 12px;
}
.message-form textarea {
  background: #21132f;
  color: var(--o-text);
  border: 1px solid var(--o-line);
  border-radius: 10px;
  min-height: 100px;
  padding: 15px;
}
.message-form button {
  justify-self: end;
}
@media (max-width: 700px) {
  .php-portals {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    padding: 0 20px;
    margin: 44px auto 65px;
  }
  .php-portals > a {
    padding: 28px 14px 20px;
    border-radius: 100px 100px 16px 16px;
  }
  .php-portals h2 {
    font-size: 21px;
  }
  .php-portals p {
    font-size: 13px;
  }
  .php-editorial,
  .content-wrap {
    padding: 26px 22px 55px;
  }
  .section-title h2 {
    font-size: 21px;
  }
  .article-preview {
    grid-template-columns: 75px 1fr;
    gap: 18px;
  }
  .article-preview img {
    width: 75px;
  }
  .article-preview h2,
  .article-preview h3 {
    font-size: 17px;
    line-height: 1.5;
    margin: 5px 0 8px;
  }
  .article-preview p {
    font-size: 13px;
    line-height: 1.65;
  }
  .content-wrap > h1 {
    font-size: 27px;
  }
  .article-detail {
    padding: 26px 22px 60px;
  }
  .article-detail h1 {
    font-size: 27px;
  }
  .article-cover {
    width: 120px;
    margin-left: 20px;
  }
  .prose {
    font-size: 16px;
    line-height: 1.95;
  }
  .card-library {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px 14px;
  }
  .card-library h2 {
    font-size: 14px;
  }
  .card-library p {
    font-size: 10px;
  }
  .search-field {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  .card-detail {
    display: block;
    padding: 25px 22px 60px;
  }
  .card-detail > img {
    position: static;
    width: 190px;
    margin: 0 auto 35px;
  }
  .card-detail h1 {
    font-size: 29px;
  }
  .account-bar {
    gap: 16px;
    font-size: 13px;
  }
  .journal-row h2 {
    font-size: 16px;
  }
  .journal-row {
    gap: 14px;
  }
  .journal-row > span {
    font-size: 12px;
  }
}
@media print {
  .oracle-header,
  .oracle-footer,
  .report-share,
  .solid-action {
    display: none !important;
  }
  .oracle-page {
    background: #fff;
    color: #222;
  }
  .report-body,
  .report-question,
  .report-answer > p,
  .muted {
    color: #222;
  }
  .report-content {
    padding: 0;
    max-width: none;
  }
  .card-meaning,
  .report-spread,
  section {
    break-inside: avoid;
  }
}
