/* ============================================
   Admin Event Packages — Safari Vents Compact
   Prefix: ap-
   ============================================ */

.ap {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    color: #2A2A2A;
    background: #f5f3ef;
    min-height: 100vh;
    padding: 1.25rem 1.5rem;
}

/* ── Header ── */
.ap-header {
    background: linear-gradient(135deg, #2A2A2A 0%, #3d3d3d 100%);
    border-radius: 14px; padding: 1.25rem 1.5rem;
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 1rem;
}
.ap-header-title { font-size: 1rem; font-weight: 800; color: #fff; letter-spacing: -0.02em; margin: 0 0 0.125rem 0; }
.ap-header-sub { font-size: 0.6875rem; color: rgba(255,255,255,0.55); margin: 0; }
.ap-header-actions { display: flex; gap: 0.375rem; align-items: center; }

/* ── Buttons ── */
.ap-btn {
    display: inline-flex; align-items: center; gap: 0.375rem;
    font-size: 0.6875rem; font-weight: 600; padding: 0.35rem 0.625rem;
    border-radius: 8px; border: none; cursor: pointer;
    transition: all 0.15s ease; text-decoration: none; white-space: nowrap;
}
.ap-btn-refresh { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.8); border: 1px solid rgba(255,255,255,0.15); }
.ap-btn-refresh:hover { background: rgba(255,255,255,0.18); color: #fff; }
.ap-btn-sm { font-size: 0.5625rem; padding: 0.2rem 0.4rem; border-radius: 6px; }
.ap-btn-approve { background: rgba(72,140,130,0.1); color: #488C82; }
.ap-btn-approve:hover { background: rgba(72,140,130,0.2); }
.ap-btn-reject { background: rgba(200,80,60,0.08); color: #c8503c; }
.ap-btn-reject:hover { background: rgba(200,80,60,0.15); }
.ap-btn-delete { background: rgba(200,80,60,0.06); color: #c8503c; }
.ap-btn-delete:hover { background: rgba(200,80,60,0.12); }

/* ── Stats ── */
.ap-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.625rem; margin-bottom: 1rem; }
.ap-stat {
    background: #fff; border: 1px solid rgba(158,139,99,0.12); border-radius: 12px;
    padding: 0.75rem 0.875rem; display: flex; align-items: center; justify-content: space-between;
    transition: border-color 0.15s ease;
}
.ap-stat:hover { border-color: rgba(158,139,99,0.25); }
.ap-stat-value { font-size: 1.25rem; font-weight: 800; color: #2A2A2A; letter-spacing: -0.02em; line-height: 1; }
.ap-stat-label { font-size: 0.5625rem; color: #8a8177; font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; margin-top: 0.125rem; }
.ap-stat-icon { width: 32px; height: 32px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 0.8125rem; flex-shrink: 0; }
.ap-icon-terracotta { background: rgba(200,121,65,0.1); color: #C87941; }
.ap-icon-teal { background: rgba(72,140,130,0.1); color: #488C82; }
.ap-icon-bronze { background: rgba(158,139,99,0.1); color: #9E8B63; }
.ap-icon-charcoal { background: rgba(42,42,42,0.06); color: #2A2A2A; }

/* ── Search & Filter ── */
.ap-search-bar { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem; flex-wrap: wrap; }
.ap-search-wrap { position: relative; flex: 1; min-width: 200px; }
.ap-search-wrap i { position: absolute; left: 0.625rem; top: 50%; transform: translateY(-50%); font-size: 0.6875rem; color: #9E8B63; pointer-events: none; }
.ap-search-input {
    width: 100%; padding: 0.4rem 0.625rem 0.4rem 1.75rem; font-size: 0.6875rem; font-family: inherit;
    border: 1px solid rgba(158,139,99,0.18); border-radius: 8px; background: #fff; color: #2A2A2A; outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.ap-search-input::placeholder { color: #b5a98a; }
.ap-search-input:focus { border-color: #C87941; box-shadow: 0 0 0 2px rgba(200,121,65,0.1); }
.ap-filter-select {
    padding: 0.4rem 0.625rem; font-size: 0.6875rem; font-family: inherit;
    border: 1px solid rgba(158,139,99,0.18); border-radius: 8px; background: #fff; color: #2A2A2A;
    outline: none; cursor: pointer; min-width: 130px; transition: border-color 0.15s ease;
}
.ap-filter-select:focus { border-color: #C87941; }
.ap-search-count { font-size: 0.5625rem; color: #8a8177; white-space: nowrap; }

/* ── Grid ── */
.ap-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 0.75rem; padding: 0.75rem 1rem; }

/* ── Package Card ── */
.ap-item { background: #fff; border: 1px solid rgba(158,139,99,0.12); border-radius: 12px; overflow: hidden; transition: border-color 0.15s ease; }
.ap-item:hover { border-color: rgba(158,139,99,0.25); }
.ap-item-img { position: relative; height: 120px; overflow: hidden; background: linear-gradient(135deg, #C87941, #9E8B63); display: flex; align-items: center; justify-content: center; }
.ap-item-img img { width: 100%; height: 100%; object-fit: cover; }
.ap-item-img-placeholder { color: rgba(255,255,255,0.5); font-size: 2rem; }
.ap-featured { position: absolute; top: 0.375rem; right: 0.375rem; font-size: 0.5rem; font-weight: 700; background: rgba(200,121,65,0.9); color: #fff; padding: 0.1rem 0.3rem; border-radius: 4px; display: flex; align-items: center; gap: 0.15rem; }
.ap-item-body { padding: 0.625rem; }
.ap-item-name { font-size: 0.75rem; font-weight: 700; color: #2A2A2A; margin: 0 0 0.25rem 0; }
.ap-item-desc { font-size: 0.5625rem; color: #8a8177; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: 0.375rem; }

/* ── Owner Info ── */
.ap-owner-info { display: flex; align-items: center; gap: 0.375rem; padding: 0.375rem; background: rgba(158,139,99,0.04); border-radius: 8px; margin-bottom: 0.375rem; border: 1px solid rgba(158,139,99,0.08); }
.ap-owner-info i { color: #9E8B63; font-size: 0.6875rem; }
.ap-owner-name { font-size: 0.5625rem !important; font-weight: 700; color: #2A2A2A; }
.ap-owner-email { font-size: 0.5rem; color: #8a8177; margin-left: auto; }

/* ── Badges ── */
.ap-badges { display: flex; flex-wrap: wrap; gap: 0.25rem; margin-bottom: 0.375rem; }
.ap-badge { font-size: 0.5rem; font-weight: 700; padding: 0.1rem 0.3rem; border-radius: 4px; text-transform: uppercase; letter-spacing: 0.03em; display: inline-flex; align-items: center; gap: 0.15rem; }
.ap-badge-type { background: rgba(158,139,99,0.1); color: #9E8B63; }
.ap-badge-approved { background: rgba(72,140,130,0.1); color: #488C82; }
.ap-badge-pending { background: rgba(200,121,65,0.1); color: #C87941; }
.ap-badge-active { background: rgba(72,140,130,0.08); color: #488C82; }
.ap-badge-inactive { background: rgba(42,42,42,0.05); color: #8a8177; }

/* ── Price ── */
.ap-price-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.375rem; }
.ap-price { font-size: 0.8125rem; font-weight: 800; color: #488C82; }
.ap-price-old { font-size: 0.5625rem; color: #8a8177; text-decoration: line-through; margin-right: 0.25rem; }
.ap-guests { font-size: 0.5625rem; color: #8a8177; display: flex; align-items: center; gap: 0.2rem; }

/* ── Actions ── */
.ap-actions { display: flex; gap: 0.25rem; }
.ap-actions .ap-btn { flex: 1; justify-content: center; }

/* ── Card Shell ── */
.ap-card { background: #fff; border: 1px solid rgba(158,139,99,0.12); border-radius: 14px; overflow: hidden; margin-bottom: 0.75rem; }
.ap-card-header { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1rem; border-bottom: 1px solid rgba(158,139,99,0.08); }
.ap-card-title { font-size: 0.75rem; font-weight: 700; color: #2A2A2A; display: flex; align-items: center; gap: 0.375rem; margin: 0; }
.ap-card-title i { color: #9E8B63; font-size: 0.8125rem; }
.ap-card-count { font-size: 0.5625rem; font-weight: 700; background: rgba(200,121,65,0.1); color: #C87941; padding: 0.125rem 0.375rem; border-radius: 6px; }

/* ── Empty / Loading ── */
.ap-empty { text-align: center; padding: 2.5rem 1rem; }
.ap-empty-icon { font-size: 2rem; color: #c4b99a; margin-bottom: 0.5rem; }
.ap-empty-title { font-size: 0.875rem; font-weight: 700; color: #2A2A2A; margin-bottom: 0.25rem; }
.ap-empty-text { font-size: 0.6875rem; color: #8a8177; }
.ap-loading { text-align: center; padding: 2.5rem 1rem; }
.ap-spinner { display: inline-block; width: 24px; height: 24px; border: 3px solid rgba(200,121,65,0.15); border-top-color: #C87941; border-radius: 50%; animation: ap-spin 0.6s linear infinite; }
@keyframes ap-spin { to { transform: rotate(360deg); } }
.ap-loading-text { font-size: 0.6875rem; color: #8a8177; margin-top: 0.5rem; }

/* ── Responsive ── */
@media (max-width: 992px) { .ap-stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) { .ap { padding: 0.75rem; } .ap-header { flex-direction: column; align-items: flex-start; gap: 0.75rem; } .ap-grid { grid-template-columns: 1fr; } }
@media (max-width: 576px) { .ap-stats { grid-template-columns: 1fr; } }
