/* ==========================================================================
   KAKA AMIR - Haute Joaillerie
   Admin Control Panel Stylesheet
   ========================================================================== */

:root {
    --font-arabic: 'Tajawal', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-arabic-calligraphic: 'Amiri', Georgia, serif;
    --font-heading: 'Cinzel', serif;
    --admin-gold: #d4af37;
    --admin-gold-bright: #f9e27a;
    --admin-bg-dark: #0a0a0d;
    --admin-card-bg: rgba(18, 17, 24, 0.88);
    --admin-border: rgba(212, 175, 55, 0.28);
    --admin-wa-green: #25d366;
    --admin-danger: #e63946;
}

body.admin-body,
input, button, select, textarea {
    font-family: var(--font-arabic);
}

body.admin-body {
    background-color: var(--admin-bg-dark);
    color: #f5f5f5;
    font-family: var(--font-arabic);
    margin: 0;
    min-height: 100vh;
    padding-bottom: 3rem;
}

/* ==========================================================================
   1. PIN Lock Screen
   ========================================================================== */
.pin-lock-overlay {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 50% 40%, rgba(26, 24, 34, 0.96) 0%, rgba(6, 6, 8, 0.99) 100%);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.pin-lock-overlay.unlock-anim {
    opacity: 0;
    transform: scale(1.05);
    pointer-events: none;
}

.pin-lock-card {
    background: linear-gradient(180deg, rgba(22, 20, 28, 0.95) 0%, rgba(12, 11, 16, 0.98) 100%);
    border: 1px solid rgba(212, 175, 55, 0.45);
    border-radius: 28px;
    padding: 3.2rem 2.5rem;
    width: 100%;
    max-width: 440px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(212, 175, 55, 0.15);
}

.pin-crest {
    width: 75px;
    height: 75px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.22), rgba(245, 215, 127, 0.05));
    border: 1.5px solid var(--admin-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--admin-gold-bright);
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.3);
}

.pin-title {
    font-family: var(--font-arabic-calligraphic);
    font-size: 1.9rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.2rem;
}

.pin-subtitle {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--admin-gold);
    letter-spacing: 0.18em;
    margin-bottom: 1.5rem;
}

.pin-instruction {
    font-size: 0.95rem;
    color: rgba(230, 225, 215, 0.8);
    margin-bottom: 1.8rem;
}

.pin-dots-container {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    margin-bottom: 1.8rem;
}

.pin-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 1.5px solid var(--admin-gold);
    background: transparent;
    transition: all 0.25s ease;
}

.pin-dot.filled {
    background: var(--admin-gold-bright);
    box-shadow: 0 0 12px var(--admin-gold-bright);
    transform: scale(1.15);
}

.pin-input-group {
    margin-bottom: 1.5rem;
}

.pin-input-group input {
    width: 100%;
    max-width: 280px;
    background: rgba(10, 10, 14, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 14px;
    padding: 0.9rem 1rem;
    font-size: 1.4rem;
    letter-spacing: 0.35em;
    text-align: center;
    color: #ffffff;
    outline: none;
    transition: border-color 0.3s;
}

.pin-input-group input:focus {
    border-color: var(--admin-gold-bright);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.35);
}

.pin-unlock-btn {
    width: 100%;
    max-width: 280px;
    background: linear-gradient(135deg, #d4af37, #f6e27a 50%, #b8860b 100%);
    color: #0d0c0a;
    border: none;
    border-radius: 999px;
    padding: 0.95rem;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.pin-unlock-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.55);
}

.pin-error-msg {
    display: none;
    color: #ff5e62;
    font-size: 0.9rem;
    font-weight: 600;
    margin-top: 1.2rem;
}

.pin-hint {
    margin-top: 1.5rem;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.45);
}

.pin-hint strong {
    color: var(--admin-gold-bright);
}

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

.shake-anim {
    animation: shakeAnim 0.4s ease-in-out;
}

/* ==========================================================================
   2. Main Dashboard & Navigation
   ========================================================================== */
.admin-wrapper {
    max-width: 1360px;
    margin: 0 auto;
    padding: 1.5rem 1.8rem;
    position: relative;
    z-index: 10;
}

.admin-navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.1rem 1.8rem;
    background: var(--admin-card-bg);
    border: 1px solid var(--admin-border);
    border-radius: 20px;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1.2rem;
}

.admin-brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.admin-logo {
    width: 44px;
    height: auto;
    filter: drop-shadow(0 0 8px rgba(212, 175, 55, 0.4));
}

.admin-titles {
    display: flex;
    flex-direction: column;
}

.admin-main-name {
    font-family: var(--font-arabic-calligraphic);
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
}

.admin-sub-name {
    font-family: var(--font-heading);
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    color: var(--admin-gold);
}

.admin-nav-actions {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
}

.nav-preview-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.06);
    color: var(--admin-gold-bright) !important;
    border: 1px solid rgba(212, 175, 55, 0.35);
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none !important;
    transition: all 0.25s ease;
}

.nav-preview-link:hover {
    background: rgba(212, 175, 55, 0.2);
    border-color: var(--admin-gold-bright);
    color: #ffffff !important;
    transform: translateY(-2px);
}

.nav-logout-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(230, 57, 70, 0.18);
    color: #ff8a8a;
    border: 1px solid rgba(230, 57, 70, 0.4);
    padding: 0.55rem 1.2rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
}

.nav-logout-btn:hover {
    background: rgba(230, 57, 70, 0.4);
    color: #ffffff;
}

/* ==========================================================================
   3. Stats Row
   ========================================================================== */
.admin-stats-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.2rem;
}

.stat-card {
    background: var(--admin-card-bg);
    border: 1px solid var(--admin-border);
    border-radius: 18px;
    padding: 1.4rem 1.6rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-3px);
    border-color: var(--admin-gold-bright);
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.18);
}

.stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: #ffffff;
}

.stat-icon.gold-icon {
    background: rgba(212, 175, 55, 0.18);
    color: var(--admin-gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.stat-icon.emerald-icon {
    background: rgba(46, 204, 113, 0.18);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.35);
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-count {
    font-size: 1.8rem;
    font-weight: 800;
    color: #ffffff;
    font-family: var(--font-heading);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.88rem;
    color: rgba(230, 225, 215, 0.75);
}

/* ==========================================================================
   4. Form & Layout
   ========================================================================== */
.admin-grid-layout {
    display: grid;
    grid-template-columns: 460px 1fr;
    gap: 2.2rem;
    align-items: start;
}

.admin-card {
    background: var(--admin-card-bg);
    border: 1px solid var(--admin-border);
    border-radius: 24px;
    padding: 2rem 2.2rem;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 1.8rem;
    padding-bottom: 1.2rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    flex-wrap: wrap;
}

.card-title {
    font-family: var(--font-arabic-calligraphic);
    font-size: 1.45rem;
    color: #ffffff;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.card-title i {
    color: var(--admin-gold-bright);
}

.card-tag {
    font-size: 0.75rem;
    background: rgba(212, 175, 55, 0.15);
    color: var(--admin-gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.3);
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
}

.form-group {
    margin-bottom: 1.4rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.col-half {
    flex: 1;
}

.form-label {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--admin-gold-bright);
    margin-bottom: 0.55rem;
}

.form-label i {
    margin-left: 0.3rem;
}

.category-radio-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.9rem;
}

.radio-card {
    cursor: pointer;
}

.radio-card input {
    display: none;
}

.radio-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.85rem;
    border-radius: 14px;
    background: rgba(10, 10, 14, 0.75);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    color: rgba(240, 235, 220, 0.8);
    font-weight: 700;
    transition: all 0.25s ease;
}

.radio-card input:checked + .radio-content {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(245, 215, 127, 0.08));
    border-color: var(--admin-gold-bright);
    color: #ffffff;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.3);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    background: rgba(10, 10, 14, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 12px;
    padding: 0.85rem 1rem;
    font-size: 0.98rem;
    color: #ffffff;
    outline: none;
    font-family: inherit;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    border-color: var(--admin-gold-bright);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.25);
}

.form-select option {
    background: #121218;
    color: #f5f5f7;
    padding: 8px 12px;
}

/* Image Upload Stage */
.image-upload-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.upload-dropzone {
    border: 1.5px dashed rgba(212, 175, 55, 0.45);
    border-radius: 16px;
    background: rgba(12, 12, 16, 0.65);
    padding: 1.8rem 1.2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.upload-dropzone:hover,
.upload-dropzone.drag-over {
    border-color: var(--admin-gold-bright);
    background: rgba(212, 175, 55, 0.08);
}

.dropzone-prompt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.upload-icon-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--admin-gold-bright);
}

.upload-main-text {
    font-weight: 700;
    color: #ffffff;
    font-size: 0.95rem;
}

.upload-sub-text {
    font-size: 0.8rem;
    color: rgba(230, 225, 215, 0.72);
    line-height: 1.5;
}

.upload-picker-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.55rem;
    margin-top: 0.65rem;
    width: 100%;
}

.picker-btn-albums {
    background: linear-gradient(135deg, #d4af37, #f5d77f);
    color: #0b0b0f;
    border: none;
    border-radius: 10px;
    padding: 0.58rem 1rem;
    font-family: inherit;
    font-size: 0.84rem;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    box-shadow: 0 4px 14px rgba(212, 175, 55, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.picker-btn-albums:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(212, 175, 55, 0.5);
}

.picker-btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: #f0e6cc;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 10px;
    padding: 0.54rem 0.85rem;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.2s ease;
}

.picker-btn-secondary:hover {
    background: rgba(212, 175, 55, 0.18);
    border-color: var(--admin-gold-bright);
    color: #ffffff;
}

.image-preview-stage {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0.5rem;
}

.preview-img {
    max-width: 140px;
    max-height: 140px;
    border-radius: 14px;
    object-fit: cover;
    border: 2px solid var(--admin-gold);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.7);
}

.remove-image-btn {
    position: absolute;
    top: 0;
    right: 25%;
    background: rgba(230, 57, 70, 0.9);
    color: #ffffff;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    transition: transform 0.2s;
}

.remove-image-btn:hover {
    transform: scale(1.15);
}

/* Multi Images Preview Styling */
.selected-count-badge {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(212, 175, 55, 0.1));
    border: 1px solid var(--admin-gold);
    color: var(--admin-gold-bright);
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
}

.multi-images-preview-stage {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    width: 100%;
}

.multi-preview-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    flex-wrap: wrap;
    gap: 0.5rem;
}

.multi-preview-counter {
    color: var(--admin-gold-bright);
    font-weight: 700;
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.multi-preview-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.btn-more-images {
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid var(--admin-gold);
    color: var(--admin-gold-bright);
    border-radius: 8px;
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: all 0.2s ease;
}

.btn-more-images:hover {
    background: var(--admin-gold);
    color: #000;
}

.btn-clear-images {
    background: rgba(230, 57, 70, 0.15);
    border: 1px solid rgba(230, 57, 70, 0.4);
    color: #ff8a8a;
    border-radius: 8px;
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: all 0.2s ease;
}

.btn-clear-images:hover {
    background: rgba(230, 57, 70, 0.4);
    color: #fff;
}

.multi-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(85px, 1fr));
    gap: 0.7rem;
    max-height: 250px;
    overflow-y: auto;
    padding: 0.3rem;
}

.multi-preview-thumb-box {
    position: relative;
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    border: 1.5px solid rgba(212, 175, 55, 0.4);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    background: #000;
}

.multi-preview-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.multi-preview-thumb-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.75);
    border: 1px solid rgba(230, 57, 70, 0.8);
    color: #ff5555;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 2;
}

.multi-preview-thumb-remove:hover {
    background: #e63946;
    color: #fff;
    transform: scale(1.1);
}

.multi-preview-thumb-index {
    position: absolute;
    bottom: 4px;
    left: 4px;
    background: rgba(0, 0, 0, 0.75);
    color: var(--admin-gold-bright);
    font-size: 10px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 6px;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.preset-stone-selector {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.preset-label {
    font-size: 0.82rem;
    color: rgba(230, 225, 215, 0.75);
}

/* Actions */
.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.8rem;
}

.submit-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    background: linear-gradient(135deg, #d4af37, #f6e27a 50%, #b8860b 100%);
    color: #0d0c0a;
    border: none;
    border-radius: 12px;
    padding: 0.95rem;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.35);
    transition: transform 0.25s, box-shadow 0.25s;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.55);
}

.cancel-edit-btn {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 0.95rem 1.4rem;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
}

/* PIN Change card */
.pin-change-card {
    margin-top: 1.8rem;
    padding: 1.4rem 1.8rem;
}

.card-header-sm {
    margin-bottom: 0.8rem;
}

.card-title-sm {
    font-size: 1rem;
    color: var(--admin-gold-bright);
    margin: 0;
}

.pin-change-row {
    display: flex;
    gap: 0.8rem;
    margin-top: 0.6rem;
}

.form-input-sm {
    flex: 1;
    background: rgba(10, 10, 14, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 10px;
    padding: 0.6rem 0.9rem;
    color: #ffffff;
    font-size: 0.95rem;
}

.btn-sm {
    background: rgba(212, 175, 55, 0.2);
    color: var(--admin-gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 10px;
    padding: 0.6rem 1.2rem;
    font-weight: 700;
    cursor: pointer;
}

/* ==========================================================================
   5. Catalog Items List
   ========================================================================== */
.catalog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.8rem;
    padding-bottom: 1.2rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    flex-wrap: wrap;
    gap: 1rem;
}

.catalog-titles .card-title {
    margin-bottom: 0.25rem;
}

.card-subtitle {
    font-size: 0.88rem;
    color: rgba(230, 225, 215, 0.7);
    margin: 0;
}

.catalog-filters {
    display: flex;
    gap: 0.5rem;
}

.filter-pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.25);
    color: rgba(240, 235, 220, 0.8);
    padding: 0.4rem 1.1rem;
    border-radius: 999px;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s;
}

.filter-pill.active {
    background: var(--admin-gold-bright);
    color: #121008;
    border-color: var(--admin-gold-bright);
    box-shadow: 0 2px 10px rgba(212, 175, 55, 0.4);
}

.catalog-items-list {
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
}

.catalog-item-card {
    background: rgba(14, 13, 18, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.22);
    border-radius: 18px;
    padding: 1.4rem;
    display: flex;
    gap: 1.4rem;
    transition: all 0.3s ease;
}

.catalog-item-card:hover {
    border-color: rgba(212, 175, 55, 0.5);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    transform: translateY(-2px);
}

.item-thumb-wrapper {
    flex-shrink: 0;
    width: 110px;
    height: 110px;
    border-radius: 14px;
    overflow: hidden;
    background: radial-gradient(circle, rgba(30, 30, 40, 0.8) 0%, rgba(10, 10, 14, 0.95) 100%);
    border: 1px solid rgba(212, 175, 55, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.item-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.item-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.4rem;
}

.item-category-tag {
    font-size: 0.76rem;
    font-weight: 700;
    padding: 0.22rem 0.75rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.badge-necklace {
    background: rgba(212, 175, 55, 0.2);
    color: var(--admin-gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.4);
}

.badge-bracelet {
    background: rgba(46, 204, 113, 0.18);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.4);
}

.item-date {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.4);
}

.item-title {
    font-family: var(--font-arabic-calligraphic);
    font-size: 1.3rem;
    color: #ffffff;
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.item-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.6rem;
}

.detail-tag {
    font-size: 0.78rem;
    color: var(--admin-gold);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.2);
    padding: 0.18rem 0.55rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.item-desc {
    color: rgba(230, 225, 215, 0.85);
    font-size: 0.94rem;
    line-height: 1.65;
    margin-bottom: 1rem;
    flex: 1;
}

.item-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 0.8rem;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.preview-item-link {
    font-size: 0.85rem;
    color: var(--admin-gold);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.preview-item-link:hover {
    text-decoration: underline;
    color: #ffffff;
}

.item-actions {
    display: flex;
    gap: 0.6rem;
}

.action-btn {
    border: none;
    border-radius: 8px;
    padding: 0.45rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.2s;
}

.action-btn.edit-btn {
    background: rgba(212, 175, 55, 0.18);
    color: var(--admin-gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.action-btn.edit-btn:hover {
    background: var(--admin-gold-bright);
    color: #121008;
}

.action-btn.delete-btn {
    background: rgba(230, 57, 70, 0.18);
    color: #ff8a8a;
    border: 1px solid rgba(230, 57, 70, 0.35);
}

.action-btn.delete-btn:hover {
    background: var(--admin-danger);
    color: #ffffff;
}

.empty-catalog-box {
    text-align: center;
    padding: 4rem 2rem;
    color: rgba(255, 255, 255, 0.45);
}

.empty-catalog-box i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: rgba(212, 175, 55, 0.4);
}

.empty-catalog-box p {
    font-size: 1.1rem;
    color: #ffffff;
    margin-bottom: 0.4rem;
}

/* Responsive */
@media (max-width: 992px) {
    .admin-grid-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 580px) {
    .catalog-item-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .item-top-row {
        justify-content: center;
        gap: 1rem;
    }
    .item-tags {
        justify-content: center;
    }
    .item-footer {
        flex-direction: column;
        gap: 0.8rem;
    }
    .form-row {
        flex-direction: column;
        gap: 0;
    }
}

/* ==========================================================================
   Admin Master Navigation Tabs & Management Sections
   ========================================================================== */
.admin-tab-nav-wrapper {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    background: rgba(18, 18, 22, 0.7);
    padding: 0.5rem;
    border-radius: 16px;
    border: 1px solid rgba(212, 175, 55, 0.25);
    flex-wrap: wrap;
}

.admin-tab-nav-btn {
    flex: 1;
    min-width: 200px;
    padding: 0.9rem 1.4rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 12px;
    color: rgba(230, 225, 215, 0.75);
    font-size: 0.98rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}

.admin-tab-nav-btn:hover {
    color: #ffffff;
    background: rgba(212, 175, 55, 0.1);
    border-color: rgba(212, 175, 55, 0.3);
}

.admin-tab-nav-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(212, 175, 55, 0.08));
    border-color: var(--admin-gold);
    color: var(--admin-gold-bright);
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.15);
}

.admin-tab-section {
    display: none;
    animation: fadeInTab 0.35s ease;
}

.admin-tab-section.active {
    display: block;
}

@keyframes fadeInTab {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Custom Stones Management Grid */
.stones-mgmt-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.2rem;
    margin-top: 1.2rem;
}

.stone-mgmt-card {
    background: rgba(12, 12, 16, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 16px;
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stone-mgmt-card:hover {
    border-color: var(--admin-gold);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7);
}

.stone-mgmt-card.is-custom {
    border-color: rgba(212, 175, 55, 0.5);
    background: linear-gradient(160deg, rgba(212, 175, 55, 0.08), rgba(12, 12, 16, 0.9));
}

.stone-mgmt-header {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.stone-mgmt-img {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    object-fit: cover;
    border: 1.5px solid var(--admin-gold);
    background: #000;
}

.stone-mgmt-info h4 {
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.2rem;
}

.stone-mgmt-sub {
    font-size: 0.8rem;
    color: var(--admin-gold);
}

.stone-mgmt-badge {
    display: inline-block;
    font-size: 0.75rem;
    background: rgba(212, 175, 55, 0.15);
    color: var(--admin-gold-bright);
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    border: 1px solid rgba(212, 175, 55, 0.3);
    align-self: flex-start;
}

.stone-mgmt-desc {
    font-size: 0.84rem;
    color: rgba(230, 225, 215, 0.7);
    line-height: 1.45;
    flex-grow: 1;
}

.stone-mgmt-actions {
    display: flex;
    gap: 0.6rem;
    margin-top: 0.5rem;
    padding-top: 0.7rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-delete-stone {
    background: rgba(230, 57, 70, 0.15);
    border: 1px solid rgba(230, 57, 70, 0.4);
    color: #ff8a8a;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.2s ease;
}

.btn-delete-stone:hover {
    background: rgba(230, 57, 70, 0.4);
    color: #fff;
}

/* Settings Form Grid */
.settings-grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 1.8rem;
}

.setting-tip-box {
    background: rgba(212, 175, 55, 0.08);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    font-size: 0.84rem;
    color: rgba(230, 225, 215, 0.85);
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.2rem;
}

.setting-tip-box i {
    color: var(--admin-gold-bright);
    font-size: 1.1rem;
}

.chip-num {
    display: none !important;
}

/* Live Model Counts Per Section & Stone */
.radio-count-pill {
    display: inline-block;
    color: var(--admin-gold-bright);
    font-weight: 800;
    font-size: 0.82rem;
    margin-right: 0.25rem;
}

.stone-model-count-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.28rem 0.72rem;
    border-radius: 999px;
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stone-model-count-badge.has-models {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.22), rgba(212, 175, 55, 0.2));
    border: 1px solid rgba(46, 204, 113, 0.6);
    color: #7dffb3;
}

.stone-model-count-badge.has-models:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 12px rgba(46, 204, 113, 0.3);
}

.stone-model-count-badge.is-empty {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: rgba(220, 215, 205, 0.6);
}

.catalog-stone-counts-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-bottom: 0.9rem;
    padding: 0.65rem 0.75rem;
    border-radius: 12px;
    background: rgba(12, 12, 18, 0.75);
    border: 1px solid rgba(212, 175, 55, 0.22);
}

.stone-count-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.32rem 0.7rem;
    border-radius: 999px;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.32);
    color: #f3e6c2;
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.stone-count-pill:hover,
.stone-count-pill.active {
    background: linear-gradient(135deg, #d4af37, #f5d77f);
    color: #0b0b0f;
    border-color: #f9e27a;
}

.stone-count-pill i {
    font-size: 0.72rem;
    opacity: 0.9;
}

.stone-count-num {
    background: rgba(0, 0, 0, 0.35);
    color: #ffd700;
    padding: 0.08rem 0.45rem;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 900;
}

.stone-count-pill:hover .stone-count-num,
.stone-count-pill.active .stone-count-num {
    background: rgba(0, 0, 0, 0.22);
    color: #0b0b0f;
}
