
/* Books library: bilingual copy with the cover carousel between the two columns. */
.books-content{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,2.35fr) minmax(0,1fr);direction:ltr;align-items:center;gap:18px;padding:18px 24px 24px}
.book-intro{min-width:0;margin:0;font-weight:600;font-size:clamp(13px,1.2vw,17px);line-height:1.55;color:#102d49}
.book-intro p{margin:0}
.book-intro-en{grid-column:1;grid-row:1;text-align:left;direction:ltr}
.book-intro-ar{grid-column:3;grid-row:1;text-align:right;direction:rtl;font-family:Tahoma,Arial,sans-serif}
.books-center{grid-column:2;grid-row:1;min-width:0}
.book-carousel{position:relative;display:flex;align-items:center;min-width:0}
.book-list{display:flex;direction:ltr;gap:14px;width:100%;min-width:0;overflow-x:auto;overflow-y:hidden;scroll-behavior:smooth;scroll-snap-type:x mandatory;scrollbar-width:none;padding:3px 2px 9px}
.book-list::-webkit-scrollbar{display:none}
.book-card{flex:0 0 calc((100% - 42px)/4);min-width:0;display:flex;align-items:center;justify-content:center;scroll-snap-align:start;border-radius:4px;padding:0;background:transparent;transition:transform .25s ease,filter .25s ease}
.book-card:hover{transform:translateY(-5px);filter:drop-shadow(0 9px 10px rgba(7,29,49,.2))}
.book-card img{display:block;width:100%;height:clamp(145px,17vw,218px);object-fit:contain;object-position:center;filter:drop-shadow(2px 5px 5px rgba(0,0,0,.28));}
.book-arrow{position:absolute;z-index:2;top:50%;transform:translateY(-50%);width:31px;height:42px;border:1px solid rgba(196,151,61,.65);border-radius:8px;background:rgba(7,43,73,.92);color:#f7d47c;font-size:27px;line-height:1;cursor:pointer;box-shadow:0 3px 10px #00172b30}
.book-prev{left:-13px}.book-next{right:-13px}
.book-arrow:hover{background:#bd8c35;color:#fff}
.book-detail-page{max-width:1120px;margin:28px auto 45px;padding:0 20px}
.book-back-link{display:inline-flex;margin:0 0 16px;color:#123d61;font-weight:700;text-decoration:none}
.book-detail-card{display:grid;grid-template-columns:minmax(260px,.85fr) minmax(0,1.4fr);gap:42px;align-items:center;padding:clamp(20px,4vw,42px);border:1px solid rgba(190,147,62,.55);border-radius:22px;background:linear-gradient(145deg,#fffefa,#f2f5f6);box-shadow:0 14px 35px rgba(7,37,64,.13)}
.book-detail-cover{display:flex;justify-content:center;align-items:center;min-width:0}
.book-detail-cover img{display:block;width:auto;max-width:min(100%,340px);height:auto;max-height:560px;object-fit:contain;filter:drop-shadow(0 12px 12px rgba(0,0,0,.23));border-radius:3px}
.book-detail-copy{min-width:0;color:#102d49}
.book-detail-language h1,.book-detail-language h2{margin:0 0 12px;font-size:clamp(22px,2.4vw,32px);color:#0b3558}
.book-detail-ar{text-align:right;direction:rtl;font-family:Tahoma,Arial,sans-serif}
.book-detail-en{text-align:left;direction:ltr}
.book-detail-language p{margin:0;font-size:clamp(15px,1.35vw,18px);line-height:1.9;white-space:normal}
.book-detail-separator{height:1px;margin:24px 0;background:linear-gradient(90deg,transparent,#c59a48,transparent)}
.book-detail-actions{display:flex;gap:13px;flex-wrap:wrap;margin-top:28px}
.book-action{min-width:180px;display:inline-flex;justify-content:center;align-items:center;gap:8px;padding:13px 20px;border-radius:10px;border:1px solid #bd913e;background:linear-gradient(135deg,#0b3558,#174e76);color:#fff;text-decoration:none;font-weight:700;box-shadow:0 5px 12px #092b4925;transition:transform .2s,box-shadow .2s}
.book-action span{font-size:12px;opacity:.85}
.book-action:hover{transform:translateY(-2px);box-shadow:0 8px 17px #092b4935}
.book-action.book-read{background:linear-gradient(135deg,#b98936,#d6b15f);color:#102b45}
.book-action.is-disabled{opacity:.45;cursor:not-allowed;box-shadow:none}
.book-not-found{min-height:40vh;display:grid;place-content:center;text-align:center}
.book-not-found a{color:#12466e}
.book-admin-thumb{width:52px;height:70px;object-fit:contain;background:#f4f5f5}
.book-admin-cover-preview{display:block;width:auto;max-width:110px;height:145px;object-fit:contain;margin-top:8px;border:1px solid #ddd;padding:3px;background:#fff}
.books-intro-fields{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-bottom:15px}
.books-intro-fields label{display:flex;flex-direction:column;gap:7px;font-weight:700}
.books-intro-fields textarea{width:100%;min-height:105px;padding:10px;border:1px solid #cbd4de;border-radius:8px;font:14px/1.7 Tahoma,Arial,sans-serif}
@media(max-width:900px){
 .books-content{grid-template-columns:minmax(0,1fr) minmax(0,2fr) minmax(0,1fr);gap:12px;padding:15px}
 .book-card{flex-basis:calc((100% - 14px)/2)}
 .book-card img{height:175px}
 .book-arrow{width:27px;height:37px}
 .book-detail-card{gap:25px}
}
@media(max-width:600px){
 .books-content{grid-template-columns:1fr;gap:15px;padding:14px}
 .book-intro-en{grid-column:1;grid-row:1;text-align:left}
 .books-center{grid-column:1;grid-row:2}
 .book-intro-ar{grid-column:1;grid-row:3;text-align:right}
 .book-intro{font-size:14px;line-height:1.65;padding:0 4px}
 .book-list{gap:12px}
 .book-card{flex-basis:calc((100% - 12px)/2)}
 .book-card img{height:clamp(165px,53vw,230px)}
 .book-prev{left:-8px}.book-next{right:-8px}
 .book-detail-page{margin:15px auto 28px;padding:0 12px}
 .book-detail-card{grid-template-columns:1fr;gap:24px;padding:18px 15px;border-radius:16px}
 .book-detail-cover img{max-height:430px;max-width:min(78%,300px)}
 .book-detail-copy{width:100%}
 .book-detail-language h1,.book-detail-language h2{font-size:23px}
 .book-detail-language p{font-size:15px;line-height:1.8}
 .book-detail-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-top:22px}
 .book-action{min-width:0;padding:12px 7px;flex-direction:column;gap:3px;font-size:14px}
 .books-intro-fields{grid-template-columns:1fr;gap:12px}
}


/* Luxury bilingual books masthead with the supplied centered book icon. */
.books-panel>.section-title.books-section-heading{
 min-height:88px;
 padding:10px clamp(16px,3.2vw,44px);
 display:grid;
 grid-template-columns:minmax(0,1fr) 84px minmax(0,1fr);
 grid-template-rows:1fr;
 align-items:center;
 gap:18px;
 direction:ltr;
 color:#f8f5ed;
 background:
   radial-gradient(ellipse at 50% 0%,rgba(255,255,255,.20),transparent 58%),
   linear-gradient(112deg,#0c3556 0%,#174c72 24%,#eaf0f2 50%,#174c72 76%,#0c3556 100%);
 border-bottom:3px solid #c99a43;
 border-top:1px solid rgba(255,255,255,.8);
 box-shadow:inset 0 1px 0 rgba(255,255,255,.45),0 5px 14px rgba(9,38,61,.12);
 position:relative;
 overflow:hidden;
}
.books-panel>.section-title.books-section-heading:before,
.books-panel>.section-title.books-section-heading:after{
 content:"";
 position:absolute;
 top:50%;
 width:calc(50% - 75px);
 height:1px;
 background:linear-gradient(90deg,transparent,#d6aa51);
 opacity:.95;
 pointer-events:none;
}
.books-panel>.section-title.books-section-heading:before{left:0}
.books-panel>.section-title.books-section-heading:after{right:0;transform:scaleX(-1)}
.books-panel>.section-title.books-section-heading .books-heading-en,
.books-panel>.section-title.books-section-heading .books-heading-ar{
 position:relative;
 z-index:1;
 margin:0;
 color:#fff;
 font-size:clamp(16px,2vw,25px);
 font-weight:800;
 line-height:1.25;
 text-shadow:0 2px 5px rgba(0,20,38,.45);
}
.books-panel>.section-title.books-section-heading .books-heading-en{
 grid-column:1;grid-row:1;text-align:left;direction:ltr;justify-self:start;
}
.books-panel>.section-title.books-section-heading .books-heading-ar{
 grid-column:3;grid-row:1;text-align:right;direction:rtl;justify-self:end;
 font-family:Tahoma,Arial,sans-serif;
}
.books-panel>.section-title.books-section-heading .books-heading-icon{
 grid-column:2;grid-row:1;
 z-index:2;
 display:block;
 width:64px;height:64px;
 object-fit:contain;
 justify-self:center;
 filter:drop-shadow(0 3px 4px rgba(0,0,0,.25));
}
@media(max-width:600px){
 .books-panel>.section-title.books-section-heading{
  min-height:68px;
  padding:7px 10px;
  grid-template-columns:minmax(0,1fr) 52px minmax(0,1fr);
  gap:7px;
 }
 .books-panel>.section-title.books-section-heading:before,
 .books-panel>.section-title.books-section-heading:after{width:calc(50% - 47px)}
 .books-panel>.section-title.books-section-heading .books-heading-en,
 .books-panel>.section-title.books-section-heading .books-heading-ar{font-size:clamp(11px,3.1vw,15px)}
 .books-panel>.section-title.books-section-heading .books-heading-icon{width:46px;height:46px}
}
/* Compact, text-only book management table. */
.books-admin-table-wrap{margin-top:20px}
.books-admin-table{width:100%;border-collapse:separate;border-spacing:0;background:#fff;border:1px solid #e2e8ef;border-radius:12px;overflow:hidden}
.books-admin-table thead th{background:linear-gradient(90deg,#102f4b,#17476b);color:#fff;padding:14px 16px;text-align:right;font-size:14px;font-weight:800}
.books-admin-table tbody td{padding:13px 16px;border-bottom:1px solid #edf1f5;text-align:right;vertical-align:middle}
.books-admin-table tbody tr:last-child td{border-bottom:0}
.books-admin-table tbody tr:hover{background:#f8fafc}
.books-admin-table td strong{display:block;color:#153b5c;font-size:15px}
.books-admin-table td small{display:block;color:#718096;margin-top:3px;font-size:12px}
.books-admin-table .book-row-number{width:55px;color:#a17a32;font-weight:800}
.books-admin-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.books-admin-actions a{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-width:92px;padding:8px 13px;border-radius:8px;text-decoration:none;font-size:13px;font-weight:700;transition:transform .18s,box-shadow .18s}
.books-admin-actions a:hover{transform:translateY(-1px);box-shadow:0 4px 10px rgba(15,45,70,.12)}
.book-admin-edit{background:#eaf2f8;color:#17486e;border:1px solid #cbdce9}
.book-admin-delete{background:#fff1f0;color:#a33b36;border:1px solid #f0d0ce}
.books-admin-actions span{font-size:15px;line-height:1}
@media(max-width:600px){
 .books-admin-table thead th,.books-admin-table tbody td{padding:10px 8px;font-size:12px}
 .books-admin-table .book-row-number{width:32px}
 .books-admin-table td strong{font-size:13px}
 .books-admin-actions{gap:5px}
 .books-admin-actions a{min-width:0;padding:7px 9px;font-size:12px}
}
