/* 🧱 حوائط الإبداع — ملف مشترك بين بوابة الطالب ولوحة المعلم */
html.wall-on body{overflow:hidden}
.wall-ov{--wbg:#dbeafe;--wac:#2563eb;position:fixed;inset:0;z-index:2147483000;display:flex;flex-direction:column;direction:rtl;color:#1e293b;
  background:var(--wbg) radial-gradient(rgba(0,0,0,.06) 1.2px,transparent 1.4px) 0 0/22px 22px;font-family:inherit}
.wall-ov.dark{color:#e2e8f0}
.wall-load{margin:auto;font-weight:800;display:flex;gap:.6rem;align-items:center}
.wall-top{display:flex;gap:.8rem;align-items:flex-start;padding:max(.8rem,env(safe-area-inset-top)) 1rem .7rem;flex-wrap:wrap}
.wall-x{flex:none;width:42px;height:42px;border-radius:50%;border:2px solid #1e293b;background:#fff;font-size:1.2rem;font-weight:900;cursor:pointer;box-shadow:0 3px 0 #1e293b}
.wall-ttl{flex:1;min-width:200px}
.wall-ttl h2{margin:0;display:inline-block;background:#fff;color:#1e293b;border:2.5px solid #1e293b;border-radius:16px;padding:.35rem .9rem;font-size:clamp(1.15rem,3.4vw,1.8rem);box-shadow:0 4px 0 #1e293b;transform:rotate(-.6deg)}
.wall-ttl p{margin:.55rem 0 0;display:inline-block;background:#fff;color:#334155;border:2px solid #1e293b;border-radius:12px;padding:.3rem .7rem;font-size:.9rem;max-width:100%}
.wall-chips{display:flex;gap:.4rem;flex-wrap:wrap;margin-top:.5rem}
.wall-chips span{background:#fff;color:#1e293b;border:2px solid #1e293b;border-radius:99px;padding:.12rem .6rem;font-size:.78rem;font-weight:700}
.wall-chips .warn{background:#fef3c7}
.wall-acts{display:flex;gap:.5rem;flex-wrap:wrap}
.wall-btn{border:2px solid #1e293b;background:#fff;color:#1e293b;border-radius:12px;padding:.5rem .9rem;font:inherit;font-weight:800;cursor:pointer;box-shadow:0 3px 0 #1e293b;white-space:nowrap}
.wall-btn.main{background:var(--wac,#2563eb);color:#fff}
.wall-btn:disabled{opacity:.55;cursor:default}
.wall-btn:active{transform:translateY(2px);box-shadow:0 1px 0 #1e293b}
.wall-body{flex:1;overflow:auto;padding:.4rem 1rem calc(1.2rem + env(safe-area-inset-bottom));-webkit-overflow-scrolling:touch}
.wall-note{background:#fff;border:2px dashed #1e293b;border-radius:12px;padding:.45rem .8rem;margin:0 0 .8rem;font-size:.86rem;font-weight:700;color:#1e293b}
.wall-note.soft{border-style:dotted;font-weight:600}
.wall-grid{columns:4 250px;column-gap:14px}
.wcard{--cbg:#fef9c3;break-inside:avoid;margin:0 0 14px;background:var(--cbg);color:#1e293b;border:2.5px solid #1e293b;border-radius:18px;padding:.75rem;box-shadow:0 4px 0 #1e293b;position:relative;display:flex;flex-direction:column;gap:.55rem}
.wcard.dim{opacity:.8;border-style:dashed}
.wcard.pin{outline:3px solid var(--wac);outline-offset:2px}
.wall-pin{position:absolute;top:-14px;left:50%;font-size:1.5rem;transform:translateX(-50%) rotate(-20deg)}
.wc-h{display:flex;align-items:center;gap:.55rem}
.wc-h>div{flex:1;min-width:0;display:flex;flex-direction:column;line-height:1.3}
.wc-h b{font-size:.95rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.wc-h small{color:#64748b;font-size:.74rem}
.wc-av{flex:none;width:36px;height:36px;border-radius:50%;display:grid;place-items:center;font-weight:900;background:hsl(var(--h),70%,85%);border:2px solid #1e293b;font-size:1rem}
.wc-del{border:0;background:rgba(255,255,255,.7);border-radius:50%;width:30px;height:30px;cursor:pointer}
.wc-t{margin:0;white-space:pre-wrap;word-break:break-word;font-size:1rem;line-height:1.75;font-weight:600}
.wall-img{display:block;border-radius:12px;overflow:hidden;border:2px solid #1e293b;background:#fff}
.wall-img img{display:block;width:100%;height:auto;max-height:70vh;object-fit:contain;background:#fff}
.wall-vid{width:100%;border-radius:12px;border:2px solid #1e293b;background:#000;max-height:60vh}
.wall-file{display:flex;align-items:center;gap:.6rem;background:#fff;border:2px solid #1e293b;border-radius:12px;padding:.5rem;text-decoration:none;color:#1e293b}
.wall-file b{background:#ef4444;color:#fff;border-radius:8px;padding:.45rem .5rem;font-size:.75rem}
.wall-file span{display:flex;flex-direction:column;min-width:0;font-weight:700;font-size:.85rem;overflow:hidden;text-overflow:ellipsis}
.wall-file small{color:#64748b;font-weight:500}
.wall-yt{position:relative;display:block;border-radius:12px;overflow:hidden;border:2px solid #1e293b}
.wall-yt img{display:block;width:100%;aspect-ratio:16/9;object-fit:cover}
.wall-yt i{position:absolute;inset:0;margin:auto;width:58px;height:40px;border-radius:12px;background:#ef4444;color:#fff;display:grid;place-items:center;font-style:normal;font-size:1.2rem}
.wall-link{display:block;background:#fff;border:2px solid #1e293b;border-radius:10px;padding:.4rem .6rem;color:#1d4ed8;font-weight:700;font-size:.85rem;word-break:break-all;text-decoration:none;direction:ltr;text-align:left}
.wall-st{border-radius:10px;padding:.3rem .55rem;font-size:.8rem;font-weight:800;background:#fff7ed;border:1.5px dashed #ea580c;color:#9a3412}
.wall-st.hid{background:#f1f5f9;border-color:#64748b;color:#334155}
.wc-f{display:flex;justify-content:flex-end}
.wc-like{border:2px solid #1e293b;background:#fff;border-radius:99px;padding:.2rem .7rem;font:inherit;font-weight:800;cursor:pointer;display:inline-flex;gap:.3rem;align-items:center}
.wc-like.on{background:#ffe4e6}
.wall-mod{display:flex;gap:.35rem;flex-wrap:wrap;border-top:2px dashed rgba(30,41,59,.25);padding-top:.5rem}
.wall-mod button{flex:1;border:2px solid #1e293b;background:#fff;border-radius:10px;padding:.35rem .4rem;font:inherit;font-size:.8rem;font-weight:800;cursor:pointer}
.wall-mod .ok{background:#16a34a;color:#fff}
.wall-mod .del{flex:none}
.wall-mod .vote{flex-basis:100%;background:#fef3c7}
.wall-mod .vote.sent{background:#dcfce7}
.wc-sheet label{display:flex;flex-direction:column;gap:.25rem;font-weight:700;font-size:.88rem}
.wc-sheet input[type=text],.wc-sheet input[type=password],.wc-sheet select{width:100%;box-sizing:border-box;border:2px solid #cbd5e1;border-radius:12px;padding:.55rem .7rem;font:inherit}
.wc-sheet .muted{color:#64748b;font-size:.82rem;font-weight:500}
.wall-empty{margin:12vh auto 0;text-align:center;display:flex;flex-direction:column;gap:.4rem;align-items:center;background:#fff;border:2.5px dashed #1e293b;border-radius:20px;padding:1.5rem 2rem;max-width:360px;color:#1e293b}
.wall-empty div{font-size:3rem}
/* إضافة منشور */
.wall-comp{position:absolute;inset:0;background:rgba(15,23,42,.45);display:flex;align-items:flex-end;justify-content:center;padding:1rem}
.wc-sheet{background:#fff;color:#1e293b;width:min(560px,100%);border:2.5px solid #1e293b;border-radius:20px;padding:1rem;box-shadow:0 6px 0 #1e293b;display:flex;flex-direction:column;gap:.6rem;margin-bottom:env(safe-area-inset-bottom);max-height:92vh;overflow:auto}
.wc-sheet h3{margin:0;font-size:1.05rem}
.wc-sheet textarea,.wc-sheet input[type=url]{width:100%;box-sizing:border-box;border:2px solid #cbd5e1;border-radius:12px;padding:.6rem .7rem;font:inherit;font-size:1rem}
.wc-sheet textarea:focus,.wc-sheet input:focus{outline:none;border-color:var(--wac,#2563eb)}
.wcp-files{display:flex;gap:.6rem;align-items:center;flex-wrap:wrap}
.wcp-hint{font-size:.78rem;color:#64748b}
.wcp-list{display:flex;flex-direction:column;gap:.35rem}
.wcp-chip{display:flex;gap:.4rem;align-items:center;background:#f1f5f9;border-radius:10px;padding:.35rem .55rem;font-size:.85rem;font-weight:600}
.wcp-chip small{color:#64748b;margin-inline-start:auto}
.wcp-chip button{border:0;background:#e2e8f0;border-radius:50%;width:24px;height:24px;cursor:pointer}
.wcp-prog{height:22px;background:#e2e8f0;border-radius:99px;position:relative;overflow:hidden}
.wcp-prog i{position:absolute;inset:0 0 0 auto;width:0;background:var(--wac,#2563eb);transition:width .25s}
.wcp-prog span{position:relative;display:block;text-align:center;font-size:.75rem;font-weight:800;line-height:22px;color:#0f172a}
.wcp-prog.hide{display:none}
.wcp-acts{display:flex;gap:.5rem;justify-content:flex-end}
/* 📽️ وضع العرض */
html.wall-proj .wall-mod,html.wall-proj .wall-acts .main,html.wall-proj .wc-del,html.wall-proj .wall-note{display:none!important}
html.wall-proj .wall-grid{columns:4 300px}
html.wall-proj .wc-t{font-size:1.2rem}
@media (max-width:600px){.wall-grid{columns:1}.wall-top{padding-inline:.7rem}.wall-body{padding-inline:.7rem}}
@media (min-width:601px) and (max-width:900px){.wall-grid{columns:2}}
/* بطاقة «حوائط الإبداع» في الصفحة الرئيسية لبوابة الطالب */
.walls-card{background:#fff;border:1.5px solid #e2e8f0;border-radius:18px;padding:.8rem;margin:.8rem 0}
.walls-card h3{margin:0 0 .6rem;font-size:1rem;display:flex;align-items:center;gap:.4rem}
.walls-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:.55rem}
.wall-tile{--wbg:#dbeafe;--wac:#2563eb;position:relative;text-align:right;border:2px solid #1e293b;border-radius:14px;padding:.55rem .6rem;min-width:0;background:var(--wbg);cursor:pointer;font:inherit;color:#1e293b;box-shadow:0 3px 0 #1e293b;display:flex;flex-direction:column;gap:.2rem}
.wall-tile.dark{color:#e2e8f0}
.wall-tile .e{font-size:1.35rem;line-height:1}
.wall-tile b{font-size:.86rem;line-height:1.35;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.wall-tile small{font-size:.74rem;opacity:.8}
.wall-tile .new{position:absolute;top:-8px;left:-6px;background:#e11d48;color:#fff;border-radius:99px;font-size:.7rem;font-weight:800;padding:.1rem .45rem;border:2px solid #fff}
