/* ============================================================
   style.css — جسر التوحد v3
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@300;400;500;600;700&display=swap');

:root {
  --blue:        #004B7C;
  --blue-dark:   #002F4F;
  --blue-light:  #EBF3F9;
  --red:         #E8312A;
  --green:       #95B4AA;
  --green-light: #C8DDD1;
  --green-bg:    #F0F7F4;
  --bg:          #F4F7F9;
  --white:       #ffffff;
  --text:        #1a2e40;
  --muted:       #7a8a99;
  --border:      #e8eef3;
  --radius:      14px;
  --radius-sm:   10px;
  --shadow:      0 4px 20px rgba(0,75,124,0.10);
  --shadow-lg:   0 12px 40px rgba(0,75,124,0.15);
}

/* === RESET === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'IBM Plex Sans Arabic', sans-serif;
  background: var(--bg);
  color: var(--text);
  direction: rtl;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  
}

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

/* === NAV === */
.nav {
  background: var(--blue);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(0,0,0,0.2);
  width: 100%;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.nav-logo-text { color: #fff; font-size: 14px; font-weight: 700; letter-spacing: .3px; }
.nav-logo-sub  { color: var(--green-light); font-size: 9px; }

.nav-links {
  display: flex;
  gap: 6px;
  align-items: center;
}
.nav-links a {
  color: rgba(200,221,209,.8);
  font-size: 12px;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 20px;
  transition: all .2s;
  white-space: nowrap;
}
.nav-links a:hover,
.nav-links a.active {
  color: #fff;
  background: rgba(255,255,255,.12);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.nav-user-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--green-light);
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid rgba(200,221,209,.25);
  transition: background .2s;
  white-space: nowrap;
}
.nav-user-btn:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-logout-btn {
  color: #ffaaaa;
  font-size: 11px;
  padding: 6px 14px;
  border: 1px solid rgba(255,100,100,.25);
  border-radius: 20px;
  transition: background .2s;
  white-space: nowrap;
}
.nav-logout-btn:hover { background: rgba(255,100,100,.1); }
.nav-login-btn {
  color: var(--green-light);
  font-size: 12px;
  padding: 6px 16px;
  border: 1px solid rgba(200,221,209,.3);
  border-radius: 20px;
  white-space: nowrap;
  transition: background .2s;
}
.nav-login-btn:hover { background: rgba(255,255,255,.08); color: #fff; }
.nav-register-btn {
  background: var(--red);
  color: #fff;
  font-size: 12px;
  padding: 7px 18px;
  border-radius: 20px;
  font-weight: 700;
  white-space: nowrap;
  transition: opacity .2s;
}
.nav-register-btn:hover { opacity: .88; }

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 28px;
  border-radius: 28px;
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  transition: all .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,0,0,.15); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--red);  color: #fff; }
.btn-blue    { background: var(--blue); color: #fff; }
.btn-outline { background: transparent; color: var(--blue); border: 1.5px solid var(--blue); }
.btn-full    { width: 100%; }

/* === FORM === */
.form-label {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
  font-weight: 600;
  letter-spacing: .3px;
}
.form-input {
  width: 100%;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  font-size: 13px;
  color: var(--text);
  outline: none;
  transition: border-color .2s, background .2s;
}
.form-input:focus { border-color: var(--blue); background: #fff; box-shadow: 0 0 0 3px rgba(0,75,124,.08); }
.form-group { margin-bottom: 16px; }

/* === ALERTS === */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.alert-success { background: var(--green-bg); color: #2E7D32; border: 1px solid var(--green-light); }
.alert-error   { background: #FFF0F0; color: #CC3300; border: 1px solid #FFCACA; }
.alert-info    { background: var(--blue-light); color: var(--blue); border: 1px solid #c5d9e8; }

/* === TAGS === */
.tag { font-size: 9px; padding: 3px 10px; border-radius: 9px; font-weight: 700; display: inline-block; letter-spacing: .3px; }
.tag-blue  { background: var(--blue-light); color: var(--blue); }
.tag-new   { background: var(--red); color: #fff; }
.tag-best  { background: var(--blue); color: #fff; }
.tag-green { background: var(--green-bg); color: #2E7D32; }

/* === HERO === */
.hero {
  background: linear-gradient(160deg, var(--blue-dark) 0%, var(--blue) 60%, #006ba8 100%);
  padding: 72px 32px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -20%;
  width: 100%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,.04) 0%, transparent 70%);
  pointer-events: none;
}
.hero-tag {
  display: inline-block;
  background: rgba(200,221,209,.15);
  color: var(--green-light);
  font-size: 11px;
  padding: 6px 18px;
  border-radius: 20px;
  margin-bottom: 20px;
  border: 1px solid rgba(200,221,209,.2);
  letter-spacing: .5px;
}
.hero h1 {
  color: #fff;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 16px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.hero h1 span { color: #ff6b6b; }
.hero-sub {
  color: rgba(200,221,209,.9);
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 32px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}
.hero-btns {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-bottom: 52px;
  flex-wrap: wrap;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 56px;
  padding: 24px 0;
  border-top: 1px solid rgba(255,255,255,.1);
  max-width: 500px;
  margin: 0 auto;
}
.stat-n { color: #fff; font-size: 26px; font-weight: 700; }
.stat-l { color: var(--green); font-size: 11px; margin-top: 2px; }

/* === SECTION === */
.section {
  padding: 56px 32px;
  max-width: 1080px;
  margin: 0 auto;
}
.section-label {
  font-size: 11px;
  color: var(--green);
  text-align: center;
  margin-bottom: 8px;
  font-weight: 700;
  letter-spacing: 1.5px;
}
.section-title {
  font-size: 26px;
  font-weight: 700;
  color: var(--blue);
  text-align: center;
  margin-bottom: 10px;
}
.section-sub {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  margin-bottom: 36px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* === BOOKS GRID === */
.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 20px;
}
.book-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  cursor: pointer;
  transition: box-shadow .25s, transform .25s;
  text-decoration: none;
  display: block;
  position: relative;
}
.book-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.book-cover {
  height: 150px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.book-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.book-card:hover .book-cover img { transform: scale(1.04); }
.book-badge { position: absolute; top: 10px; right: 10px; z-index: 1; }
.book-body { padding: 14px 16px; }
.book-cat { font-size: 10px; color: var(--green); margin-bottom: 5px; font-weight: 600; letter-spacing: .3px; }
.book-title { font-size: 13px; font-weight: 700; color: var(--text); line-height: 1.45; margin-bottom: 10px; }
.book-footer { display: flex; align-items: center; justify-content: space-between; }
.book-price { font-size: 18px; font-weight: 700; color: var(--red); }
.book-price-lbl { font-size: 10px; color: var(--muted); display: block; }
.book-btn {
  background: var(--blue);
  color: #fff;
  font-size: 11px;
  padding: 8px 16px;
  border-radius: 10px;
  border: none;
  font-weight: 700;
  transition: opacity .2s;
  cursor: pointer;
}
.book-btn:hover { opacity: .85; }

/* === PAGE HERO === */
.page-hero {
  background: linear-gradient(135deg, var(--blue-dark), var(--blue));
  padding: 40px 32px;
  text-align: center;
}
.page-hero h1 { color: #fff; font-size: 26px; font-weight: 700; margin-bottom: 8px; }
.page-hero p  { color: var(--green); font-size: 13px; }

/* === SEARCH & FILTER === */
.search-bar {
  background: var(--white);
  padding: 16px 32px;
  border-bottom: 1px solid var(--border);
  display: flex;
  gap: 10px;
  max-width: 600px;
  margin: 0 auto;
}
.search-field {
  flex: 1;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 24px;
  padding: 10px 18px;
  font-size: 12px;
  outline: none;
  transition: border-color .2s;
}
.search-field:focus { border-color: var(--blue); }
.search-btn {
  background: var(--blue);
  color: #fff;
  border: none;
  border-radius: 24px;
  padding: 10px 22px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.filter-bar {
  background: var(--white);
  padding: 12px 32px;
  border-bottom: 1px solid var(--border);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}
.fchip {
  padding: 7px 18px;
  border-radius: 22px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all .2s;
  text-decoration: none;
  display: inline-block;
}
.fchip.on  { background: var(--blue); color: #fff; }
.fchip.off { background: var(--white); color: #555; border: 1.5px solid var(--border); }
.fchip.off:hover { border-color: var(--blue); color: var(--blue); }

.results-bar {
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1080px;
  margin: 0 auto;
}
.sort-sel {
  font-size: 11px;
  color: var(--blue);
  background: var(--white);
  border: 1.5px solid var(--border);
  padding: 6px 14px;
  border-radius: 10px;
  cursor: pointer;
}

/* === BOOK DETAIL === */
.breadcrumb {
  padding: 14px 32px;
  font-size: 11px;
  color: var(--muted);
  background: var(--white);
  border-bottom: 1px solid var(--border);
}
.breadcrumb a { color: var(--blue); }

.book-hero-detail {
  background: var(--white);
  padding: 32px;
  display: flex;
  gap: 28px;
  border-bottom: 1px solid var(--border);
  max-width: 900px;
  margin: 0 auto;
}
.book-cover-lg {
  width: 140px;
  height: 180px;
  flex-shrink: 0;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
}
.book-cover-lg img { width: 100%; height: 100%; object-fit: cover; }
.book-main-title { font-size: 20px; font-weight: 700; color: var(--text); margin: 10px 0 8px; line-height: 1.4; }
.price-big { font-size: 28px; font-weight: 700; color: var(--red); margin: 14px 0; }
.price-big small { font-size: 13px; color: var(--muted); font-weight: 400; }

.btn-buy-main {
  background: var(--red);
  color: #fff;
  font-size: 14px;
  padding: 14px;
  border-radius: 14px;
  border: none;
  font-weight: 700;
  width: 100%;
  cursor: pointer;
  transition: opacity .2s, transform .1s;
  display: block;
  text-align: center;
}
.btn-buy-main:hover { opacity: .9; transform: translateY(-1px); }
.btn-preview-main {
  background: var(--blue-light);
  color: var(--blue);
  font-size: 13px;
  padding: 12px;
  border-radius: 14px;
  border: none;
  width: 100%;
  margin-top: 10px;
  cursor: pointer;
  font-weight: 600;
  display: block;
  text-align: center;
}
.act-btns { display: flex; flex-direction: column; }
.trust-row {
  display: flex;
  justify-content: space-around;
  background: var(--green-bg);
  padding: 10px;
  border-radius: 10px;
  margin-top: 12px;
}
.trust-sm { display: flex; align-items: center; gap: 5px; font-size: 10px; color: var(--blue); font-weight: 600; }

.sec-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin: 20px auto;
  overflow: hidden;
  max-width: 860px;
}
.sec-head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.sec-head-title { font-size: 13px; font-weight: 700; color: var(--blue); }

.preview-pg {
  background: #F8FBFA;
  border-radius: 9px;
  padding: 14px;
  margin-bottom: 12px;
  border-right: 3px solid var(--green-light);
}
.preview-pg-num  { font-size: 10px; color: var(--green); margin-bottom: 5px; font-weight: 600; }
.preview-pg-text { font-size: 12px; color: #555; line-height: 1.85; }
.preview-lock {
  background: var(--bg);
  border-radius: 10px;
  padding: 28px;
  text-align: center;
  border: 1.5px dashed var(--green-light);
  margin-top: 12px;
}

.prot-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 20px;
  border-bottom: 1px solid #f5f7f9;
  font-size: 12px;
  color: #444;
}
.prot-row:last-child { border-bottom: none; }
.picon { width: 24px; height: 24px; border-radius: 6px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.picon-ok { background: #F0F7F4; }
.picon-no { background: #FFF0F0; }

/* === CHECKOUT === */
.progress-bar {
  background: var(--white);
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.steps { display: flex; align-items: center; justify-content: center; }
.step  { display: flex; align-items: center; gap: 8px; }
.step-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}
.sc-done    { background: var(--blue); color: #fff; }
.sc-active  { background: var(--red);  color: #fff; }
.sc-pending { background: var(--border); color: var(--muted); }
.step-lbl   { font-size: 11px; font-weight: 600; }
.sl-done    { color: var(--blue); }
.sl-active  { color: var(--red); }
.sl-pending { color: var(--muted); }
.step-line  { width: 36px; height: 2px; margin: 0 6px; border-radius: 2px; }
.sl-line-done    { background: var(--blue); }
.sl-line-pending { background: var(--border); }

.checkout-wrap { max-width: 600px; margin: 0 auto; padding: 24px 20px 48px; }
.obox {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 16px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.obox-head {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fafcff;
}
.obox-title { font-size: 13px; font-weight: 700; color: var(--blue); }
.pr-row { display: flex; justify-content: space-between; padding: 7px 0; font-size: 12px; }
.pr-divider { height: 1px; background: var(--border); margin: 8px 0; }
.sec-strip {
  background: var(--green-bg);
  border-radius: 10px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: #2E7D32;
  border: 1px solid var(--green-light);
  margin-top: 12px;
}

/* Moyasar */
.mysr-form { direction: ltr; }
.mysr-form .mysr-pay-button {
  border-radius: 14px !important;
  background: var(--red) !important;
  font-family: 'IBM Plex Sans Arabic', sans-serif !important;
  font-size: 14px !important;
  padding: 14px !important;
  font-weight: 700 !important;
}

/* === SUCCESS === */
.success-wrap { max-width: 600px; margin: 0 auto; padding: 32px 20px 56px; }
.check-circle {
  width: 72px;
  height: 72px;
  background: var(--green-bg);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  border: 2px solid var(--green-light);
}
.succ-hero {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 32px 24px;
  text-align: center;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}
.succ-title { font-size: 22px; font-weight: 700; color: var(--blue); margin-bottom: 8px; }
.succ-sub   { font-size: 13px; color: var(--muted); line-height: 1.8; margin-bottom: 16px; }
.order-badge {
  display: inline-block;
  background: var(--blue-light);
  color: var(--blue);
  font-size: 11px;
  padding: 5px 18px;
  border-radius: 20px;
  font-weight: 600;
}

/* === ACCOUNT === */
.profile-bg {
  background: linear-gradient(135deg, var(--blue-dark), var(--blue));
  padding: 36px 24px;
  text-align: center;
}
.profile-avatar {
  width: 64px;
  height: 64px;
  background: rgba(200,221,209,.2);
  border-radius: 50%;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255,255,255,.2);
}
.profile-name  { color: #fff; font-size: 18px; font-weight: 700; margin-bottom: 4px; }
.profile-email { color: var(--green); font-size: 12px; margin-bottom: 20px; }
.profile-stats { display: flex; justify-content: center; gap: 40px; }
.ps-n { color: #fff; font-size: 20px; font-weight: 700; }
.ps-l { color: var(--green); font-size: 11px; }

.tabs-bar {
  background: var(--white);
  display: flex;
  border-bottom: 2px solid var(--border);
  max-width: 900px;
  margin: 0 auto;
}
.tab-item {
  flex: 1;
  padding: 14px 6px;
  text-align: center;
  font-size: 12px;
  cursor: pointer;
  border: none;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  border-bottom: 2.5px solid transparent;
  margin-bottom: -2px;
  transition: color .2s;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tab-item.on { color: var(--blue); border-bottom-color: var(--blue); }
.tab-item.logout-tab { color: #CC3300; }

.account-body { padding: 20px 24px 40px; max-width: 900px; margin: 0 auto; }
.lib-card {
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin-bottom: 14px;
  overflow: hidden;
  transition: box-shadow .2s;
}
.lib-card:hover { box-shadow: var(--shadow); }
.lib-body { padding: 16px 18px; display: flex; gap: 14px; align-items: center; }
.lib-cover {
  width: 56px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--blue-light), var(--green-light));
  display: flex;
  align-items: center;
  justify-content: center;
}
.lib-cover img { width: 100%; height: 100%; object-fit: cover; }
.lib-foot {
  background: #F8FBFA;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border);
}
.dl-btn {
  background: var(--red);
  color: #fff;
  font-size: 11px;
  padding: 9px 18px;
  border-radius: 10px;
  border: none;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  cursor: pointer;
  transition: opacity .2s;
}
.dl-btn:hover { opacity: .88; }

/* === AUTH === */
.auth-wrap {
  min-height: calc(100vh - 62px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 16px;
  background: linear-gradient(160deg, var(--blue-dark) 0%, #006ba8 100%);
}
.auth-box { width: 100%; max-width: 420px; }
.auth-logo { text-align: center; margin-bottom: 24px; }
.auth-logo-title { color: #fff; font-size: 16px; font-weight: 700; }
.auth-logo-sub   { color: var(--green-light); font-size: 11px; margin-top: 2px; }
.auth-card {
  background: var(--white);
  border-radius: 18px;
  padding: 32px;
  box-shadow: 0 24px 60px rgba(0,0,0,.25);
}
.auth-title { font-size: 22px; font-weight: 700; color: var(--blue); margin-bottom: 5px; }
.auth-sub   { font-size: 12px; color: var(--muted); margin-bottom: 22px; }
.auth-footer { text-align: center; margin-top: 18px; font-size: 12px; color: var(--muted); }
.auth-footer a { color: var(--blue); font-weight: 600; }

/* === ADMIN === */
.admin-nav {
  background: var(--blue-dark);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.admin-nav h1 { color: #fff; font-size: 14px; font-weight: 700; }
.admin-nav-links { display: flex; gap: 20px; align-items: center; }
.admin-nav-links a { color: var(--green); font-size: 12px; text-decoration: none; transition: color .2s; }
.admin-nav-links a:hover { color: #fff; }
.admin-nav-links .logout { color: #ffaaaa; }

.admin-body { padding: 24px; max-width: 1200px; margin: 0 auto; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.stat-box {
  background: var(--white);
  border-radius: 14px;
  padding: 20px;
  border: 1px solid var(--border);
  text-align: center;
  box-shadow: var(--shadow);
}
.stat-num { font-size: 28px; font-weight: 700; color: var(--blue); }
.stat-lbl { font-size: 11px; color: var(--muted); margin-top: 5px; }

.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--border);
  font-size: 12px;
  box-shadow: var(--shadow);
}
.admin-table th {
  background: var(--blue);
  color: #fff;
  padding: 12px 16px;
  text-align: right;
  font-weight: 600;
  font-size: 11px;
}
.admin-table td { padding: 12px 16px; border-bottom: 1px solid #f0f4f8; vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #f8faff; }
.cover-thumb {
  width: 36px;
  height: 46px;
  border-radius: 5px;
  object-fit: cover;
  background: var(--bg);
  display: block;
}
.form-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

/* === FOOTER === */
.footer {
  background: var(--blue-dark);
  padding: 40px 32px;
  text-align: center;
  margin-top: 60px;
}
.footer-logo { color: #fff; font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.footer-sub  { color: var(--green); font-size: 12px; margin-bottom: 20px; }
.footer-links { display: flex; justify-content: center; gap: 24px; margin-bottom: 16px; flex-wrap: wrap; }
.footer-links a { color: var(--green); font-size: 12px; transition: color .2s; }
.footer-links a:hover { color: #fff; }
.footer-copy { color: #5a7a8a; font-size: 11px; }

/* === TRUST CARDS === */
.trust-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.trust-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px;
  transition: box-shadow .2s;
}
.trust-card:hover { box-shadow: var(--shadow); }
.trust-icon {
  width: 36px;
  height: 36px;
  background: var(--blue-light);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}
.trust-title { font-size: 13px; font-weight: 700; color: var(--blue); margin-bottom: 5px; }
.trust-desc  { font-size: 11px; color: var(--muted); line-height: 1.7; }

/* === TESTIMONIAL === */
.testimonial-bg {
  background: linear-gradient(135deg, var(--blue) 0%, #006ba8 100%);
  padding: 56px 32px;
  text-align: center;
}
.quote-text   { color: #fff; font-size: 15px; line-height: 2; max-width: 580px; margin: 12px auto 16px; font-style: italic; opacity: .95; }
.quote-author { color: var(--green-light); font-size: 13px; font-weight: 600; }

/* === CATEGORIES === */
.cats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 640px; margin: 24px auto 0; }
.cat-card {
  border-radius: var(--radius);
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  display: block;
  transition: transform .2s, box-shadow .2s;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.cat-c1 { background: var(--blue-light); border: 1.5px solid var(--green-light); }
.cat-c2 { background: #FFF0F0; border: 1.5px solid #FFCACA; }
.cat-icon { width: 48px; height: 48px; border-radius: 50%; margin: 0 auto 12px; display: flex; align-items: center; justify-content: center; }
.cat-c1 .cat-icon { background: var(--blue); }
.cat-c2 .cat-icon { background: var(--red); }
.cat-name { font-size: 15px; font-weight: 700; color: var(--blue); margin-bottom: 5px; }
.cat-sub  { font-size: 12px; color: var(--muted); }

/* === PAGES === */
.page-content {
  max-width: 780px;
  margin: 48px auto;
  padding: 0 32px 72px;
}
.page-content h2 { font-size: 22px; color: var(--blue); margin: 32px 0 14px; }
.page-content h3 { font-size: 16px; color: var(--blue); margin: 22px 0 10px; }
.page-content p  { font-size: 13px; color: #444; line-height: 2; margin-bottom: 16px; }
.page-content ul { padding-right: 22px; margin-bottom: 16px; }
.page-content ul li { font-size: 13px; color: #444; line-height: 2; margin-bottom: 8px; }

/* === RESPONSIVE === */
@media (max-width: 900px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .nav { padding: 0 16px; height: 56px; }
  .nav-links { display: none; }
  .hero { padding: 48px 20px 0; }
  .hero h1 { font-size: 26px; }
  .hero-stats { gap: 28px; }
  .section { padding: 36px 16px; }
  .books-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .book-hero-detail { flex-direction: column; padding: 20px; }
  .book-cover-lg { width: 100%; height: 220px; }
  .cats-row { grid-template-columns: 1fr 1fr; }
  .checkout-wrap { padding: 16px 14px 36px; }
  .search-bar { padding: 12px 16px; }
  .filter-bar { padding: 10px 16px; }
  .results-bar { padding: 10px 16px; }
  .account-body { padding: 14px 16px 32px; }
  .admin-body { padding: 16px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .trust-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 22px; }
  .books-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .hero-btns { flex-direction: column; align-items: center; }
  .auth-card { padding: 24px 20px; }
}
html, body { width: 100%; max-width: 100%; }
