@font-face {
    font-family: "MMEstedad";
    src: url("../fonts/Estedad-Medium.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

/* =========================================================
   MM Ebooks - Global Scope
========================================================= */

.mmeb-panel-wrap,
.mmeb-panel-wrap *,
.mmeb-panel-wrap *::before,
.mmeb-panel-wrap *::after,
.mmeb-ebook-buttons,
.mmeb-ebook-buttons *,
.mmeb-ebook-buttons *::before,
.mmeb-ebook-buttons *::after,
.mmeb-cart-ebook-note,
.mmeb-toast {
    box-sizing: border-box !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-panel-wrap {
    width: 100% !important;
    direction: rtl !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

/* =========================================================
   Panel Layout
========================================================= */

.mmeb-panel-container {
    width: 100% !important;
    display: flex !important;
    gap: 24px !important;
    align-items: flex-start !important;
}

.mmeb-panel-sidebar {
    width: 300px !important;
    min-width: 300px !important;
    background: #ffffff !important;
    border: 1px solid #eeeeee !important;
    border-radius: 18px !important;
    padding: 20px !important;
}

.mmeb-panel-content {
    flex: 1 !important;
    min-width: 0 !important;
}

.mmeb-panel-card,
.mmeb-panel-section {
    width: 100% !important;
    background: #ffffff !important;
    border: 1px solid #eeeeee !important;
    border-radius: 18px !important;
    padding: 24px !important;
}

.mmeb-panel-section-head {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    margin-bottom: 22px !important;
}

.mmeb-panel-heading,
.mmeb-panel-title {
    margin: 0 !important;
    font-size: 24px !important;
    font-weight: 800 !important;
    color: #111827 !important;
    line-height: 1.7 !important;
}

.mmeb-panel-text {
    margin: 0 !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    color: #4b5563 !important;
    line-height: 2 !important;
}

/* =========================================================
   User Box & Menu
========================================================= */

.mmeb-panel-user-box {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding-bottom: 18px !important;
    margin-bottom: 18px !important;
    border-bottom: 1px solid #eeeeee !important;
}

.mmeb-panel-avatar img {
    width: 72px !important;
    height: 72px !important;
    border-radius: 50% !important;
    display: block !important;
}

.mmeb-panel-user-info {
    display: flex !important;
    flex-direction: column !important;
    gap: 6px !important;
    min-width: 0 !important;
}

.mmeb-panel-user-info strong {
    font-size: 16px !important;
    font-weight: 700 !important;
    color: #111827 !important;
}

.mmeb-panel-user-info span {
    font-size: 13px !important;
    font-weight: 500 !important;
    color: #6b7280 !important;
    word-break: break-all !important;
}

.mmeb-panel-menu {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
}

.mmeb-panel-menu-item {
    display: flex !important;
    align-items: center !important;
    min-height: 46px !important;
    padding: 10px 14px !important;
    border-radius: 12px !important;
    background: #f9fafb !important;
    color: #111827 !important;
    text-decoration: none !important;
    transition: all 0.25s ease !important;
    font-size: 14px !important;
    font-weight: 700 !important;
}

.mmeb-panel-menu-item:hover,
.mmeb-panel-menu-item.is-active {
    background: #111827 !important;
    color: #ffffff !important;
}

/* =========================================================
   Empty State
========================================================= */

.mmeb-panel-empty {
    width: 100% !important;
    min-height: 190px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    padding: 30px !important;
    border: 1px dashed #d1d5db !important;
    border-radius: 16px !important;
    background: #f9fafb !important;
    color: #6b7280 !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    line-height: 2.2 !important;
}

/* =========================================================
   Books Grid & Cards
========================================================= */

.mmeb-books-grid {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 20px !important;
}

.mmeb-book-card {
    position: relative !important;
    width: 100% !important;
    background: #ffffff !important;
    border: 1px solid #eeeeee !important;
    border-radius: 18px !important;
    overflow: visible !important;
    box-shadow: 0 10px 28px rgba(17, 24, 39, 0.06) !important;
    transition: all 0.25s ease !important;
}

.mmeb-book-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 14px 36px rgba(17, 24, 39, 0.1) !important;
}

.mmeb-book-card-image {
    width: 100% !important;
    height: 230px !important;
    display: block !important;
    overflow: hidden !important;
    border-radius: 18px 18px 0 0 !important;
    background: #f3f4f6 !important;
}

.mmeb-book-card-image img {
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    object-fit: cover !important;
}

.mmeb-book-card-no-image {
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #9ca3af !important;
    font-size: 14px !important;
    font-weight: 700 !important;
}

.mmeb-book-card-body {
    padding: 16px !important;
}

.mmeb-book-card-title {
    margin: 0 !important;
    min-height: 54px !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    line-height: 1.8 !important;
    color: #111827 !important;
}

.mmeb-book-card-title a {
    color: inherit !important;
    text-decoration: none !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-book-card-separator {
    width: 100% !important;
    height: 1px !important;
    background: #eeeeee !important;
    margin: 14px 0 !important;
}

.mmeb-book-card-footer {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
}

.mmeb-book-card-status {
    display: inline-flex !important;
    align-items: center !important;
    min-height: 30px !important;
    padding: 4px 12px !important;
    border-radius: 999px !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    line-height: 1.7 !important;
}

.mmeb-book-card-status.is-sample {
    background: #fef3c7 !important;
    color: #92400e !important;
}

.mmeb-book-card-status.is-purchased {
    background: #dcfce7 !important;
    color: #15803d !important;
}

.mmeb-book-card.is-removing {
    opacity: 0 !important;
    transform: scale(0.96) !important;
    transition: all 0.25s ease !important;
}

/* =========================================================
   More Menu
========================================================= */

.mmeb-book-more {
    position: relative !important;
}

.mmeb-book-more-btn {
    width: 36px !important;
    height: 36px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 50% !important;
    background: #ffffff !important;
    cursor: pointer !important;
    padding: 0 !important;
    transition: all 0.25s ease !important;
}

.mmeb-book-more-btn:hover {
    background: #f9fafb !important;
}

.mmeb-book-more-btn img {
    width: 20px !important;
    height: 20px !important;
    display: block !important;
}

.mmeb-book-more-menu {
    position: absolute !important;
    left: 0 !important;
    bottom: 44px !important;
    width: 235px !important;
    display: none !important;
    flex-direction: column !important;
    background: #ffffff !important;
    border: 1px solid #eeeeee !important;
    border-radius: 14px !important;
    box-shadow: 0 18px 45px rgba(17, 24, 39, 0.14) !important;
    overflow: hidden !important;
    z-index: 50 !important;
}

.mmeb-book-more.is-open .mmeb-book-more-menu {
    display: flex !important;
}

.mmeb-book-more-item {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    min-height: 46px !important;
    padding: 10px 14px !important;
    color: #111827 !important;
    text-decoration: none !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 1.8 !important;
    border: 0 !important;
    border-bottom: 1px solid #f1f1f1 !important;
    background: #ffffff !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
    text-align: right !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-book-more-item:last-child {
    border-bottom: 0 !important;
}

.mmeb-book-more-item:hover {
    background: #f9fafb !important;
}

.mmeb-book-more-item img {
    width: 18px !important;
    height: 18px !important;
    display: block !important;
    flex: 0 0 18px !important;
}

.mmeb-book-more-item.is-danger {
    color: #dc2626 !important;
}

.mmeb-book-more-item[disabled] {
    opacity: 0.55 !important;
    cursor: not-allowed !important;
}

.mmeb-book-bookmark-btn.is-active {
    color: #111827 !important;
    background: #fff7ed !important;
}

.mmeb-book-bookmark-btn.is-active img {
    filter: brightness(0) saturate(100%) invert(48%) sepia(90%) saturate(1549%) hue-rotate(1deg) brightness(102%) contrast(103%) !important;
}

.mmeb-book-bookmark-btn.is-loading,
.mmeb-book-remove-btn.is-loading,
.mmeb-book-shelf-btn.is-loading {
    opacity: 0.65 !important;
    pointer-events: none !important;
}

/* =========================================================
   Reading Progress
========================================================= */

.mmeb-reading-progress {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    margin: 0 !important;
}

.mmeb-reading-progress-top {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 10px !important;
}

.mmeb-reading-progress-top span {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #374151 !important;
    line-height: 1.8 !important;
}

.mmeb-reading-progress-top strong {
    font-size: 13px !important;
    font-weight: 900 !important;
    color: #111827 !important;
    line-height: 1.8 !important;
}

.mmeb-reading-progress-bar {
    position: relative !important;
    width: 100% !important;
    height: 9px !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    background: #f3f4f6 !important;
}

.mmeb-reading-progress-bar span {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    height: 100% !important;
    display: block !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, #16a34a, #22c55e) !important;
    transition: width 0.35s ease !important;
}

.mmeb-reading-progress-meta {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
}

.mmeb-reading-progress-meta span {
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #6b7280 !important;
    line-height: 1.8 !important;
}

/* =========================================================
   Ebook Buttons
========================================================= */

.mmeb-panel-guest {
    max-width: 520px !important;
    margin: 40px auto !important;
}

.mmeb-panel-button,
.mmeb-ebook-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 48px !important;
    padding: 12px 22px !important;
    border-radius: 12px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    line-height: 1.8 !important;
    text-decoration: none !important;
    border: 1px solid transparent !important;
    transition: all 0.25s ease !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-ebook-buttons {
    width: 100% !important;
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    direction: rtl !important;
}

.mmeb-panel-button,
.mmeb-ebook-btn-buy {
    background: #111827 !important;
    color: #ffffff !important;
}

.mmeb-panel-button:hover,
.mmeb-ebook-btn-buy:hover {
    background: #000000 !important;
    color: #ffffff !important;
}

.mmeb-ebook-btn-sample {
    background: #ffffff !important;
    color: #111827 !important;
    border-color: #d1d5db !important;
}

.mmeb-ebook-btn-sample:hover {
    background: #f9fafb !important;
    color: #111827 !important;
}

.mmeb-ebook-btn-disabled {
    background: #f3f4f6 !important;
    color: #9ca3af !important;
    cursor: not-allowed !important;
}


.mmeb-ebook-read-button-wrap {
    display: inline-flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 0 !important;
}

.mmeb-ebook-read-button-wrap .mmeb-ebook-btn-read {
    border-radius: 14px 14px 0 0 !important;
    background: #111827 !important;
    color: #ffffff !important;
    border-color: #111827 !important;
}

.mmeb-ebook-read-button-wrap .mmeb-ebook-btn-read:hover {
    background: #000000 !important;
    color: #ffffff !important;
}

.mmeb-ebook-button-progress {
    width: 100% !important;
    height: 7px !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #e5e7eb !important;
    border-radius: 0 0 14px 14px !important;
    overflow: hidden !important;
}

.mmeb-ebook-button-progress span {
    display: block !important;
    height: 100% !important;
    background: #111827 !important;
}

.mmeb-ebook-button-progress-text {
    display: block !important;
    margin: 4px 0 0 !important;
    color: #6b7280 !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    line-height: 1.6 !important;
    text-align: center !important;
}

.mmeb-cart-ebook-note {
    display: inline-block !important;
    margin-top: 6px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #16a34a !important;
    line-height: 1.8 !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
    white-space: nowrap !important;
}

/* =========================================================
   Shelves Grid
========================================================= */

.mmeb-shelves-grid {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 20px !important;
}

.mmeb-shelf-create-card,
.mmeb-shelf-card {
    min-height: 220px !important;
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    padding: 24px !important;
    border: 1px solid #eeeeee !important;
    border-radius: 18px !important;
    background: #ffffff !important;
    cursor: pointer !important;
    text-align: center !important;
    box-shadow: 0 10px 28px rgba(17, 24, 39, 0.06) !important;
    transition: all 0.25s ease !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-shelf-create-card {
    border-style: dashed !important;
    background: #fafafa !important;
}

.mmeb-shelf-create-card:hover,
.mmeb-shelf-card:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 14px 36px rgba(17, 24, 39, 0.1) !important;
}

.mmeb-shelf-create-icon,
.mmeb-shelf-card-icon {
    width: 70px !important;
    height: 70px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 22px !important;
    background: #f3f4f6 !important;
}

.mmeb-shelf-create-icon img,
.mmeb-shelf-card-icon img {
    width: 48px !important;
    height: 48px !important;
    display: block !important;
}

.mmeb-shelf-create-card strong,
.mmeb-shelf-card strong {
    font-size: 17px !important;
    font-weight: 900 !important;
    line-height: 1.8 !important;
    color: #111827 !important;
}

.mmeb-shelf-create-card small,
.mmeb-shelf-card small {
    max-width: 230px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.9 !important;
    color: #6b7280 !important;
}

/* =========================================================
   Shelf Sidebar Mode
========================================================= */

.mmeb-panel-sidebar.is-shelf-mode {
    min-height: 520px !important;
    display: flex !important;
    flex-direction: column !important;
}

.mmeb-shelf-sidebar-box,
.mmeb-shelf-sidebar-box * {
    box-sizing: border-box !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-shelf-sidebar-box {
    width: 100% !important;
    min-height: 480px !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    gap: 20px !important;
}

.mmeb-shelf-sidebar-main {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    text-align: center !important;
    gap: 12px !important;
}

.mmeb-shelf-sidebar-icon {
    width: 88px !important;
    height: 88px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 28px !important;
    background: #f3f4f6 !important;
    margin-bottom: 4px !important;
}

.mmeb-shelf-sidebar-icon img {
    width: 66px !important;
    height: 66px !important;
    display: block !important;
}

.mmeb-shelf-sidebar-box h3 {
    margin: 0 !important;
    color: #111827 !important;
    font-size: 20px !important;
    font-weight: 900 !important;
    line-height: 1.8 !important;
}

.mmeb-shelf-sidebar-box p {
    margin: 0 !important;
    color: #6b7280 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 2 !important;
}

.mmeb-shelf-sidebar-actions {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    margin-top: 10px !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn,
.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn {
    width: 100% !important;
    justify-content: center !important;
}

.mmeb-shelf-sidebar-box .mmeb-shelf-back-btn {
    width: 100% !important;
    min-height: 46px !important;
    justify-content: center !important;
    margin-top: auto !important;
}

/* =========================================================
   Shelf Detail
========================================================= */

.mmeb-shelf-detail-head {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 18px !important;
    margin-bottom: 24px !important;
}

.mmeb-shelf-back-btn {
    width: fit-content !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: #f3f4f6 !important;
    color: #111827 !important;
    padding: 9px 14px !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-shelf-back-btn img {
    width: 20px !important;
    height: 20px !important;
}

.mmeb-shelf-detail-hero {
    display: none !important;
}

.mmeb-shelf-detail-actions {
    display: none !important;
}

.mmeb-shelf-edit-btn,
.mmeb-shelf-delete-btn {
    min-height: 42px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 12px !important;
    background: #ffffff !important;
    padding: 9px 14px !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-shelf-edit-btn img,
.mmeb-shelf-delete-btn img {
    width: 19px !important;
    height: 19px !important;
}

.mmeb-shelf-delete-btn {
    color: #dc2626 !important;
}

/* =========================================================
   Modal Base
========================================================= */

.mmeb-modal-backdrop {
    position: fixed !important;
    inset: 0 !important;
    z-index: 999999 !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
    background: rgba(17, 24, 39, 0.42) !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: all 0.2s ease !important;
}

.mmeb-modal-backdrop[style*="display: none"],
.mmeb-modal-backdrop:not(.is-open) {
    pointer-events: none !important;
}

.mmeb-modal-backdrop.is-open {
    display: flex !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

.mmeb-modal {
    position: relative !important;
    width: 100% !important;
    max-width: 520px !important;
    padding: 24px !important;
    border-radius: 20px !important;
    background: #ffffff !important;
    box-shadow: 0 24px 80px rgba(17, 24, 39, 0.24) !important;
    direction: rtl !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
    transform: translateY(14px) scale(0.98) !important;
    transition: all 0.2s ease !important;
}

.mmeb-modal-backdrop.is-open .mmeb-modal {
    transform: translateY(0) scale(1) !important;
}

.mmeb-modal-close {
    position: absolute !important;
    top: 14px !important;
    left: 14px !important;
    width: 34px !important;
    height: 34px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 0 !important;
    border-radius: 50% !important;
    background: #f3f4f6 !important;
    color: #111827 !important;
    font-size: 22px !important;
    cursor: pointer !important;
}

.mmeb-modal h3 {
    margin: 0 0 22px 0 !important;
    padding-left: 42px !important;
    font-size: 21px !important;
    font-weight: 900 !important;
    color: #111827 !important;
    line-height: 1.8 !important;
}

.mmeb-modal-field {
    margin-bottom: 14px !important;
}

.mmeb-modal-field input,
.mmeb-modal-field textarea {
    width: 100% !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    color: #111827 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1.9 !important;
    padding: 13px 14px !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
    outline: none !important;
}

.mmeb-modal-field textarea {
    resize: vertical !important;
    min-height: 120px !important;
}

.mmeb-modal-field input:focus,
.mmeb-modal-field textarea:focus {
    border-color: #111827 !important;
    box-shadow: 0 0 0 1px #111827 !important;
}

.mmeb-modal-submit {
    width: 100% !important;
    min-height: 48px !important;
    border: 0 !important;
    border-radius: 14px !important;
    background: #111827 !important;
    color: #ffffff !important;
    font-size: 15px !important;
    font-weight: 900 !important;
    cursor: pointer !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-modal-submit:disabled {
    opacity: 0.65 !important;
    cursor: not-allowed !important;
}

/* =========================================================
   Delete Modal
========================================================= */

.mmeb-delete-modal p {
    margin: 0 0 20px 0 !important;
    color: #4b5563 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 2.1 !important;
}

.mmeb-delete-actions {
    display: flex !important;
    gap: 10px !important;
    align-items: center !important;
}

.mmeb-delete-confirm,
.mmeb-delete-cancel {
    flex: 1 !important;
    min-height: 46px !important;
    border: 0 !important;
    border-radius: 13px !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    cursor: pointer !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-delete-confirm {
    background: #dc2626 !important;
    color: #ffffff !important;
}

.mmeb-delete-cancel {
    background: #f3f4f6 !important;
    color: #111827 !important;
}

/* =========================================================
   Book Shelf Picker Modal
========================================================= */

.mmeb-book-shelf-modal-desc {
    margin: -8px 0 18px 0 !important;
    color: #6b7280 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 2 !important;
}

.mmeb-book-shelf-list {
    width: 100% !important;
    max-height: 430px !important;
    overflow-y: auto !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    padding-left: 4px !important;
}

.mmeb-book-shelf-create-inline,
.mmeb-book-shelf-option {
    width: 100% !important;
    min-height: 58px !important;
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    border: 1px solid #eeeeee !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    color: #111827 !important;
    padding: 12px !important;
    cursor: pointer !important;
    text-align: right !important;
    transition: all 0.2s ease !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-book-shelf-create-inline {
    border-style: dashed !important;
    background: #f9fafb !important;
}

.mmeb-book-shelf-create-inline:hover,
.mmeb-book-shelf-option:hover {
    background: #f3f4f6 !important;
    border-color: #d1d5db !important;
}

.mmeb-book-shelf-create-inline img,
.mmeb-book-shelf-option img {
    width: 34px !important;
    height: 34px !important;
    display: block !important;
    flex: 0 0 34px !important;
}

.mmeb-book-shelf-create-inline span,
.mmeb-book-shelf-option span {
    color: #111827 !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1.8 !important;
}

.mmeb-book-shelf-option.is-loading {
    opacity: 0.65 !important;
    pointer-events: none !important;
}

/* =========================================================
   Toast
========================================================= */

.mmeb-toast {
    position: fixed !important;
    right: 24px !important;
    bottom: 24px !important;
    z-index: 9999999 !important;
    max-width: calc(100% - 48px) !important;
    min-height: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 10px 18px !important;
    border-radius: 12px !important;
    background: #111827 !important;
    color: #ffffff !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.8 !important;
    box-shadow: 0 16px 40px rgba(17, 24, 39, 0.22) !important;
    opacity: 0 !important;
    transform: translateY(12px) !important;
    transition: all 0.25s ease !important;
}

.mmeb-toast.is-visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* =========================================================
   Responsive
========================================================= */

@media (max-width: 1024px) {
    .mmeb-books-grid,
    .mmeb-shelves-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 768px) {
    .mmeb-panel-container {
        flex-direction: column !important;
    }

    .mmeb-panel-sidebar {
        width: 100% !important;
        min-width: 0 !important;
    }

    .mmeb-books-grid,
    .mmeb-shelves-grid {
        grid-template-columns: 1fr !important;
    }

    .mmeb-panel-heading,
    .mmeb-panel-title {
        font-size: 20px !important;
    }

    .mmeb-ebook-buttons {
        flex-direction: column !important;
    }

    .mmeb-ebook-btn {
        width: 100% !important;
    }

    .mmeb-book-more-menu {
        left: 0 !important;
        right: auto !important;
        width: 230px !important;
    }

    .mmeb-delete-actions {
        flex-direction: column !important;
    }

    .mmeb-delete-confirm,
    .mmeb-delete-cancel {
        width: 100% !important;
    }

    .mmeb-modal {
        max-width: 100% !important;
        padding: 20px !important;
    }

    .mmeb-shelf-sidebar-box {
        min-height: auto !important;
    }
}
.mmeb-book-shelf-btn.is-in-shelf {
    background: #ecfdf5 !important;
    color: #047857 !important;
}

.mmeb-book-shelf-btn.is-in-shelf span {
    color: #047857 !important;
    font-weight: 900 !important;
}

.mmeb-book-shelf-btn.is-in-shelf img {
    filter: brightness(0) saturate(100%) invert(35%) sepia(61%) saturate(1031%) hue-rotate(127deg) brightness(92%) contrast(96%) !important;
}

.mmeb-shelf-sidebar-actions {
    width: 100% !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    margin-top: 14px !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn,
.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn {
    width: auto !important;
    flex: 1 1 0 !important;
    min-height: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
    font-weight: 900 !important;
    line-height: 1.8 !important;
    text-decoration: none !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn {
    border: 1px solid #d1d5db !important;
    background: #ffffff !important;
    color: #111827 !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn {
    border: 1px solid #fecaca !important;
    background: #fff1f2 !important;
    color: #dc2626 !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn span,
.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn span {
    color: inherit !important;
    font-weight: 900 !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn img,
.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn img {
    width: 18px !important;
    height: 18px !important;
    display: block !important;
    flex: 0 0 18px !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-edit-btn:hover {
    background: #f9fafb !important;
    color: #111827 !important;
}

.mmeb-shelf-sidebar-actions .mmeb-shelf-delete-btn:hover {
    background: #fee2e2 !important;
    color: #b91c1c !important;
}

@media (max-width: 768px) {
    .mmeb-shelf-sidebar-actions {
        flex-direction: row !important;
    }
}
/* =========================================================
   Purchased Book Reading Button
========================================================= */

.mmeb-book-read-action {
    width: 100% !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: space-between !important;
    gap: 0 !important;
    margin: 0 !important;
    border-radius: 16px !important;
    overflow: hidden !important;
    background: #111827 !important;
    box-shadow: 0 12px 28px rgba(17, 24, 39, 0.16) !important;
}

.mmeb-book-read-main-btn {
    flex: 1 1 auto !important;
    min-height: 48px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    padding: 10px 14px !important;
    background: #111827 !important;
    color: #ffffff !important;
    text-decoration: none !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    line-height: 1.8 !important;
    font-family: "MMEstedad", "Estedad", Tahoma, Arial, sans-serif !important;
}

.mmeb-book-read-main-btn:hover,
.mmeb-book-read-main-btn:focus,
.mmeb-book-read-main-btn:active {
    color: #ffffff !important;
    background: #111827 !important;
    text-decoration: none !important;
}

.mmeb-book-read-main-btn img {
    width: 20px !important;
    height: 20px !important;
    display: block !important;
    filter: brightness(0) invert(1) !important;
}

.mmeb-book-read-percent {
    min-width: 82px !important;
    flex: 0 0 82px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0 !important;
    padding: 7px 8px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
    border-right: 1px solid rgba(255, 255, 255, 0.16) !important;
}

.mmeb-book-read-percent strong {
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: 950 !important;
    line-height: 1.4 !important;
}

.mmeb-book-read-percent span {
    color: rgba(255, 255, 255, 0.75) !important;
    font-size: 10px !important;
    font-weight: 800 !important;
    line-height: 1.5 !important;
}

.mmeb-reading-progress.is-sticky-to-button {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

.mmeb-reading-progress.is-sticky-to-button .mmeb-reading-progress-bar {
    height: 6px !important;
    border-radius: 0 0 999px 999px !important;
    background: #e5e7eb !important;
    overflow: hidden !important;
}

.mmeb-reading-progress.is-sticky-to-button .mmeb-reading-progress-bar span {
    background: #111827 !important;
}
