@font-face {
  font-family: 'R404';
  src: url('/assets/font.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg-desktop: url('/assets/back-desktop.webp');
  --bg-mobile: url('/assets/back-mobile.webp');
  --gold: #f5d67b;
  --gold-1: #d4af37;
  --gold-2: #b8860b;
  --gold-3: #fff3c4;
  --gold-4: #8a6a12;
  --black: #000000;
  --ink: #05050a;
  --ink-2: #0b0b12;
  --white: #ffffff;
  --glow: 0 0 18px rgba(245, 214, 123, .55), 0 0 42px rgba(212, 175, 55, .28);
  --glow-s: 0 0 12px rgba(245, 214, 123, .45);
  --ring: rgba(245, 214, 123, .28);
  --muted: #b9b39a;
  --danger: #ff5f5f;
  --r: 14px;
  --ease: cubic-bezier(.2, .8, .2, 1);
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'R404', 'Segoe UI', Tahoma, sans-serif;
  background: var(--black);
  color: var(--white);
  min-height: 100vh;
  line-height: 1.9;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body.locked { overflow: hidden; }

::selection { background: var(--gold-1); color: #000; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #07070c; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(var(--gold-1), var(--gold-2));
  border-radius: 8px;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font-family: inherit; font-size: inherit; }

.gold-text {
  background: linear-gradient(115deg, var(--gold-3) 0%, var(--gold-1) 22%, var(--gold-4) 42%,
    var(--gold-3) 55%, var(--gold-1) 72%, var(--gold-4) 100%);
  background-size: 260% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 7s linear infinite;
}

@keyframes shimmer {
  0% { background-position: 260% 0; }
  100% { background-position: -160% 0; }
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 14px rgba(212, 175, 55, .35); }
  50% { box-shadow: 0 0 34px rgba(245, 214, 123, .7); }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}

@keyframes spin { to { transform: rotate(360deg); } }

.rise { animation: rise .7s var(--ease) both; }
.d1 { animation-delay: .08s; }
.d2 { animation-delay: .16s; }
.d3 { animation-delay: .24s; }
.d4 { animation-delay: .32s; }

.trap {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}


.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 26px;
  border: 1px solid var(--ring);
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(245, 214, 123, .13), rgba(0, 0, 0, .55));
  color: var(--gold-3);
  font-weight: 700;
  cursor: pointer;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s;
  overflow: hidden;
  isolation: isolate;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 20%, rgba(255, 255, 255, .35) 50%, transparent 80%);
  transform: translateX(-130%);
  transition: transform .7s var(--ease);
  z-index: -1;
}

.btn:hover {
  transform: translateY(-2px);
  border-color: var(--gold-1);
  box-shadow: var(--glow);
  color: #fff;
}

.btn:hover::after { transform: translateX(130%); }
.btn:active { transform: translateY(0) scale(.985); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

.btn-gold {
  background: linear-gradient(140deg, var(--gold-1), var(--gold-2) 45%, var(--gold-4));
  color: #120d00;
  border-color: var(--gold-3);
  text-shadow: 0 1px 0 rgba(255, 255, 255, .35);
  box-shadow: 0 6px 24px rgba(180, 140, 30, .35);
}

.btn-gold:hover { color: #000; box-shadow: 0 10px 40px rgba(245, 214, 123, .55); }

.btn-discord {
  background: linear-gradient(140deg, #5865F2, #3b47c9);
  border-color: #7b86ff;
  color: #fff;
  box-shadow: 0 6px 26px rgba(88, 101, 242, .45);
  padding: 11px 20px;
  border-radius: 999px;
}

.btn-discord:hover { box-shadow: 0 10px 38px rgba(88, 101, 242, .8); border-color: #aab2ff; }

.btn-danger {
  background: linear-gradient(140deg, rgba(255, 80, 80, .18), rgba(0, 0, 0, .6));
  border-color: rgba(255, 95, 95, .5);
  color: #ffb3b3;
}

.btn-danger:hover { box-shadow: 0 0 20px rgba(255, 80, 80, .5); border-color: var(--danger); color: #fff; }

.btn-lg { padding: 18px 42px; font-size: 1.22rem; border-radius: 16px; }


.field { margin-bottom: 16px; text-align: right; }

.field label {
  display: block;
  margin-bottom: 8px;
  color: var(--gold-3);
  font-weight: 700;
  font-size: .98rem;
}

.field .hint { color: var(--muted); font-size: .84rem; font-weight: 400; }

.input {
  width: 100%;
  padding: 13px 16px;
  background: rgba(0, 0, 0, .65);
  border: 1px solid rgba(245, 214, 123, .2);
  border-radius: 12px;
  color: #fff;
  transition: border-color .2s, box-shadow .2s, background .2s;
  outline: none;
}

.input::placeholder { color: #6d6a5c; }

.input:focus {
  border-color: var(--gold-1);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, .14), var(--glow-s);
  background: rgba(0, 0, 0, .85);
}

textarea.input { resize: vertical; min-height: 118px; line-height: 1.85; }

.drop {
  position: relative;
  border: 2px dashed rgba(245, 214, 123, .32);
  border-radius: 16px;
  background: rgba(0, 0, 0, .5);
  padding: 26px 18px;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s, box-shadow .2s;
}

.drop:hover, .drop.hot {
  border-color: var(--gold-1);
  background: rgba(212, 175, 55, .07);
  box-shadow: var(--glow-s);
}

.drop .t1 { color: var(--gold-3); font-weight: 700; font-size: 1.05rem; }
.drop .t2 { color: var(--muted); font-size: .87rem; margin-top: 4px; }
.drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

.picked {
  margin-top: 10px;
  font-size: .88rem;
  color: var(--gold-3);
  word-break: break-all;
  min-height: 20px;
}


.card {
  background: linear-gradient(165deg, rgba(12, 12, 18, .92), rgba(0, 0, 0, .92));
  border: 1px solid rgba(245, 214, 123, .18);
  border-radius: var(--r);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .7);
}


.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  background: linear-gradient(180deg, rgba(0, 0, 0, .82), rgba(0, 0, 0, 0));
  backdrop-filter: blur(9px);
  -webkit-backdrop-filter: blur(9px);
}

.brand { display: flex; align-items: center; gap: 10px; font-size: 1.12rem; font-weight: 700; }
.brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: var(--glow-s); }

.topbar-side { display: flex; align-items: center; gap: 12px; }

/* بطاقة الحساب المسجل دخول */
.me {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 13px 5px 6px;
  border: 1px solid rgba(255, 205, 84, .3);
  border-radius: 999px;
  background: rgba(255, 255, 255, .045);
}
.me[hidden] { display: none; }
.me-av {
  width: 30px; height: 30px;
  border-radius: 50%;
  object-fit: cover;
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 205, 84, .35);
  flex: 0 0 auto;
}
.me-av-blank { border-style: dashed; }
.me-txt { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.me-name {
  font-weight: 700;
  font-size: .9rem;
  max-width: 190px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.me-sub { font-size: .68rem; opacity: .6; }

@media (max-width: 560px) {
  .me { padding: 4px; }
  .me-txt { display: none; }
}


.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 110px 20px 60px;
  text-align: center;
  isolation: isolate;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background: #000 var(--bg-desktop) center / cover no-repeat fixed;
  filter: saturate(1.15) contrast(1.08);
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(70% 55% at 50% 40%, transparent 0%, rgba(0, 0, 0, .55) 70%, rgba(0, 0, 0, .9) 100%),
    linear-gradient(180deg, rgba(0, 0, 0, .72), rgba(0, 0, 0, .25) 30%, rgba(0, 0, 0, .55) 72%, #000 100%);
}

.hero-logo {
  width: clamp(110px, 20vw, 178px);
  height: clamp(110px, 20vw, 178px);
  border-radius: 50%;
  margin: 0 auto 18px;
  object-fit: cover;
  border: 2px solid var(--ring);
  box-shadow: 0 0 46px rgba(212, 175, 55, .45), inset 0 0 26px rgba(0, 0, 0, .6);
  animation: floaty 6s ease-in-out infinite;
}

.hero h1 {
  font-size: clamp(3rem, 12vw, 7.4rem);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: 1px;
  text-shadow: 0 0 40px rgba(212, 175, 55, .4);
}

.hero .tag {
  margin-top: 10px;
  color: #e7e2d2;
  font-size: clamp(1rem, 2.6vw, 1.35rem);
  text-shadow: 0 2px 18px rgba(0, 0, 0, .9);
}

.hero .rule {
  width: min(340px, 74%);
  height: 2px;
  margin: 26px auto;
  background: linear-gradient(90deg, transparent, var(--gold-1), var(--gold-3), var(--gold-1), transparent);
  box-shadow: var(--glow);
  border-radius: 2px;
}

.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 6px; }

.scroll-cue {
  position: absolute;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--gold-3);
  font-size: .82rem;
  opacity: .75;
  animation: floaty 2.6s ease-in-out infinite;
}


.section { max-width: 1200px; margin: 0 auto; padding: 78px 20px 30px; }

.sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 30px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(245, 214, 123, .16);
}

.sec-head h2 {
  font-size: clamp(1.6rem, 4.6vw, 2.5rem);
  position: relative;
  padding-right: 16px;
}

.sec-head h2::before {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 5px;
  height: 70%;
  border-radius: 4px;
  background: linear-gradient(var(--gold-3), var(--gold-2));
  box-shadow: var(--glow-s);
}

.head-tools { display: flex; gap: 10px; flex-wrap: wrap; }


.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(288px, 1fr));
  gap: 22px;
}

.pcard {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
  animation: rise .6s var(--ease) both;
}

.pcard:hover {
  transform: translateY(-6px);
  border-color: var(--gold-1);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .8), 0 0 30px rgba(212, 175, 55, .3);
}

.pcard .thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  background: linear-gradient(140deg, #0c0c14, #000);
  overflow: hidden;
  border-bottom: 1px solid rgba(245, 214, 123, .16);
}

.pcard .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .55s var(--ease); }
.pcard:hover .thumb img { transform: scale(1.07); }

.pcard .thumb .ph {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 2.6rem;
  font-weight: 700;
  color: rgba(212, 175, 55, .5);
  background: radial-gradient(circle at 50% 45%, rgba(212, 175, 55, .16), transparent 68%);
}

.pcard .body { padding: 16px 17px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.pcard h3 { font-size: 1.2rem; color: var(--gold-3); word-break: break-word; }
.pcard p { color: #cfc9b6; font-size: .93rem; word-break: break-word; }

.pcard .meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 12px;
  color: var(--muted);
  font-size: .82rem;
  border-top: 1px solid rgba(245, 214, 123, .12);
}

.pcard .acts { display: flex; gap: 8px; }
.pcard .acts .btn { padding: 8px 14px; font-size: .86rem; }

.badge-off {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 3px 11px;
  border-radius: 999px;
  font-size: .74rem;
  background: rgba(255, 95, 95, .16);
  border: 1px solid rgba(255, 95, 95, .45);
  color: #ffbcbc;
  backdrop-filter: blur(4px);
}

.empty {
  padding: 66px 22px;
  text-align: center;
  border: 1px dashed rgba(245, 214, 123, .22);
  border-radius: var(--r);
  color: var(--muted);
  background: rgba(0, 0, 0, .4);
}

.empty .big { font-size: 1.24rem; color: var(--gold-3); margin-bottom: 6px; }


.footer {
  margin-top: 60px;
  padding: 40px 20px 34px;
  text-align: center;
  border-top: 1px solid rgba(245, 214, 123, .14);
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .92));
}

.footer .fname { font-size: 1.4rem; margin-bottom: 8px; }
.footer .fdev { color: #ded8c4; font-size: 1.02rem; }
.footer .fdev b { color: var(--gold-3); font-weight: 700; }


.overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, .8);
  backdrop-filter: blur(11px);
  -webkit-backdrop-filter: blur(11px);
  overflow-y: auto;
}

.overlay.open { display: flex; animation: rise .28s var(--ease); }

.modal {
  width: min(640px, 100%);
  max-height: 92svh;
  overflow-y: auto;
  padding: 26px;
  border-radius: 20px;
  background: linear-gradient(165deg, #0d0d15, #000);
  border: 1px solid rgba(245, 214, 123, .28);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .9), 0 0 40px rgba(212, 175, 55, .18);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(245, 214, 123, .16);
}

.modal-head h3 { font-size: 1.36rem; }

.x-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(245, 214, 123, .25);
  background: rgba(0, 0, 0, .6);
  color: var(--gold-3);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  transition: .2s;
}

.x-btn:hover { border-color: var(--danger); color: #fff; box-shadow: 0 0 16px rgba(255, 95, 95, .45); }

.modal-foot { display: flex; gap: 10px; margin-top: 22px; }
.modal-foot .btn { flex: 1; }

.note {
  padding: 10px 13px;
  border-radius: 10px;
  font-size: .86rem;
  background: rgba(255, 95, 95, .1);
  border: 1px solid rgba(255, 95, 95, .32);
  color: #ffc0c0;
  margin-bottom: 14px;
}

.note.ok {
  background: rgba(245, 214, 123, .1);
  border-color: rgba(245, 214, 123, .35);
  color: var(--gold-3);
}

.note.kb {
  background: rgba(255, 180, 60, .12);
  border-color: rgba(255, 180, 60, .45);
  color: #ffd79a;
}

.pw { position: relative; }

.pw .input { padding-left: 78px; }

.eye {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  padding: 8px 14px;
  border: 1px solid rgba(245, 214, 123, .28);
  border-radius: 9px;
  background: rgba(0, 0, 0, .7);
  color: var(--gold-3);
  font-weight: 700;
  font-size: .84rem;
  cursor: pointer;
  transition: .2s;
}

.eye:hover { border-color: var(--gold-1); box-shadow: var(--glow-s); }

.kbhint {
  margin-top: 14px;
  text-align: center;
  color: var(--muted);
  font-size: .85rem;
}

.spinner {
  width: 17px;
  height: 17px;
  border: 2px solid rgba(0, 0, 0, .25);
  border-top-color: #000;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}


.auth-wrap {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 24px 18px;
  position: relative;
  isolation: isolate;
}

.auth-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -2;
  background: #000 var(--bg-desktop) center / cover no-repeat fixed;
  filter: blur(7px) saturate(1.1) brightness(.5);
  transform: scale(1.08);
}

.auth-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(60% 50% at 50% 45%, rgba(0, 0, 0, .5), rgba(0, 0, 0, .93));
}

.auth-card {
  width: min(430px, 100%);
  padding: 34px 30px;
  border-radius: 22px;
  background: linear-gradient(165deg, rgba(13, 13, 20, .96), rgba(0, 0, 0, .97));
  border: 1px solid rgba(245, 214, 123, .25);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .9), 0 0 34px rgba(212, 175, 55, .18);
  animation: rise .55s var(--ease) both;
}

.auth-card .logo {
  width: 82px;
  height: 82px;
  margin: 0 auto 14px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--ring);
  box-shadow: var(--glow);
}

.auth-card h1 { text-align: center; font-size: 1.8rem; margin-bottom: 4px; }
.auth-card .sub { text-align: center; color: var(--muted); font-size: .92rem; margin-bottom: 24px; }

.shake { animation: shake .4s; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(5px); }
}

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

.panel-stats { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }

.stat {
  flex: 1 1 170px;
  padding: 16px 18px;
  border-radius: var(--r);
  background: linear-gradient(160deg, rgba(12, 12, 18, .9), rgba(0, 0, 0, .9));
  border: 1px solid rgba(245, 214, 123, .18);
}

.stat .k { color: var(--muted); font-size: .86rem; }
.stat .v { font-size: 1.75rem; color: var(--gold-3); font-weight: 700; text-shadow: var(--glow-s); }

.toast {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%) translateY(140%);
  z-index: 300;
  padding: 13px 26px;
  border-radius: 12px;
  background: linear-gradient(140deg, #0d0d15, #000);
  border: 1px solid rgba(245, 214, 123, .4);
  color: var(--gold-3);
  box-shadow: 0 16px 50px rgba(0, 0, 0, .9), var(--glow);
  transition: transform .4s var(--ease);
  font-weight: 700;
  max-width: 92vw;
  text-align: center;
}

.toast.show { transform: translateX(-50%) translateY(0); }
.toast.err { border-color: rgba(255, 95, 95, .5); color: #ffb3b3; box-shadow: 0 16px 50px rgba(0, 0, 0, .9), 0 0 20px rgba(255, 80, 80, .35); }


.seg {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 5px;
  margin-bottom: 20px;
  border-radius: 13px;
  background: rgba(0, 0, 0, .65);
  border: 1px solid rgba(245, 214, 123, .2);
}

.seg-btn {
  position: relative;
  z-index: 2;
  padding: 11px 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
  cursor: pointer;
  transition: color .25s var(--ease);
}

.seg-btn.on { color: #120d00; }

.seg-ind {
  position: absolute;
  z-index: 1;
  top: 5px;
  bottom: 5px;
  right: 5px;
  width: calc(50% - 7px);
  border-radius: 9px;
  background: linear-gradient(140deg, var(--gold-1), var(--gold-2) 50%, var(--gold-4));
  box-shadow: 0 4px 18px rgba(180, 140, 30, .4);
  transition: transform .3s var(--ease), width .3s var(--ease);
}

.seg.link .seg-ind { right: auto; left: 5px; }


.pmain { max-width: 940px; margin: 0 auto; padding: 104px 20px 40px; }

.pback {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: .95rem;
  transition: color .2s, transform .2s;
}

.pback:hover { color: var(--gold-3); transform: translateX(-4px); }

.pwrap { overflow: hidden; animation: rise .55s var(--ease) both; }

.phead {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 22px;
  border-bottom: 1px solid rgba(245, 214, 123, .16);
  background: linear-gradient(140deg, rgba(212, 175, 55, .07), transparent 65%);
}

.pcover {
  flex: 0 0 148px;
  width: 148px;
  height: 112px;
  border-radius: 13px;
  overflow: hidden;
  border: 1px solid var(--ring);
  background: linear-gradient(140deg, #0c0c14, #000);
  box-shadow: 0 8px 26px rgba(0, 0, 0, .6);
  position: relative;
}

.pcover img { width: 100%; height: 100%; object-fit: cover; }

.pcover .ph {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 2.7rem;
  font-weight: 700;
  color: rgba(212, 175, 55, .55);
  background: radial-gradient(circle at 50% 45%, rgba(212, 175, 55, .17), transparent 68%);
}

.ptitle { flex: 1; min-width: 0; }

.ptitle h1 {
  font-size: clamp(1.4rem, 4.4vw, 2.1rem);
  line-height: 1.35;
  word-break: break-word;
}

.pmeta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-top: 10px;
  color: var(--muted);
  font-size: .87rem;
}

.pbody { padding: 26px 22px; }

.pbody h2 {
  font-size: 1.1rem;
  color: var(--gold-3);
  margin-bottom: 12px;
  padding-right: 12px;
  position: relative;
}

.pbody h2::before {
  content: '';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 72%;
  border-radius: 3px;
  background: linear-gradient(var(--gold-3), var(--gold-2));
  box-shadow: var(--glow-s);
}

.pdesc { color: #d8d2c0; font-size: 1.02rem; white-space: pre-wrap; word-break: break-word; }

.purl {
  margin-top: 6px;
  font-size: .8rem;
  color: var(--gold-1);
  word-break: break-all;
  background: rgba(0, 0, 0, .55);
  border: 1px solid rgba(245, 214, 123, .16);
  border-radius: 8px;
  padding: 6px 9px;
}

.pact {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 22px;
  border-top: 1px solid rgba(245, 214, 123, .14);
  background: rgba(0, 0, 0, .45);
}

.pact .btn { flex: 1 1 170px; }

@media (max-width: 620px) {
  .phead { flex-direction: column; text-align: center; }
  .pcover { flex: none; width: 100%; height: 168px; }
  .pmeta { justify-content: center; }
}

@media (max-width: 560px) {
  .sec-head { flex-direction: column; align-items: stretch; }
  .head-tools { justify-content: stretch; }
  .head-tools .btn { flex: 1; }
  .modal { padding: 20px 17px; }
  .hero { padding-top: 96px; }
}

/* ===== خلفية الموقع: جهاز كبير = ديسكتوب / جهاز صغير = جوال ===== */
@media (max-width: 1024px) {
  :root {
    --bg-desktop: url('/assets/back-mobile.webp');
  }

  .hero-bg {
    background: #000 var(--bg-mobile) center top / cover no-repeat;
  }

  .auth-wrap::before {
    background: #000 var(--bg-mobile) center / cover no-repeat;
    filter: saturate(1.1) brightness(.55);
  }
}

@supports not (background: url('data:image/webp;base64,AA==')) {
  :root {
    --bg-desktop: url('/assets/back-desktop.jpg');
  }

  @media (max-width: 1024px) {
    :root {
      --bg-desktop: url('/assets/back-mobile.png');
    }
  }
}
