/**
 * Packages Listing Page Styles
 * Style: Business Premium / Corporate
 */

.pkg-listing-main {
    background: #ffffff;
    min-height: 100vh;
    padding-bottom: 8rem;
    padding-top: 120px; /* Prevent header overlap */
}

.pkg-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Banner - Light Soft Premium Corporate */
.pkg-listing-banner-wrapper {
    width: 100%;
    padding: 0 2rem;
    margin-bottom: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pkg-back-btn {
    align-self: flex-start;
    margin-left: max(0px, calc(50% - 650px)); /* max-width 1300 / 2 */
    margin-bottom: 1.5rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    background: #ffffff;
    border-radius: 100px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.pkg-back-btn:hover {
    color: #0f172a;
    transform: translateX(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.05);
}

.pkg-listing-banner {
    position: relative;
    width: 100%;
    max-width: 1300px;
    height: 250px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.03);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.02);
    border-radius: 2rem;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4rem;
    text-align: center;
}

/* Background Shapes */
.pkg-banner-bg-elements {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
    background: radial-gradient(120% 120% at 50% 10%, #ffffff 40%, #f0f7ff 100%);
}

.pkg-soft-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.6;
    animation: floatShapePkg 12s ease-in-out infinite alternate;
}

.pkg-shape-1 {
    width: 300px;
    height: 300px;
    background: #e0f2fe;
    top: -100px;
    left: 10%;
}

.pkg-shape-2 {
    width: 400px;
    height: 400px;
    background: #fdf4ff;
    bottom: -200px;
    right: 15%;
    animation-delay: -5s;
}

@keyframes floatShapePkg {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -20px) scale(1.05); }
    100% { transform: translate(-20px, 30px) scale(0.95); }
}

.pkg-banner-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
}

.pkg-title {
    font-family: "Inter", sans-serif;
    font-size: clamp(2rem, 3.5vw, 3.2rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
    color: #0f172a;
}

.pkg-subtitle {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
    line-height: 1.6;
}

/* Toolbar */
.pkg-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    background: #ffffff;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f1f5f9;
    position: sticky;
    top: 90px;
    z-index: 100;
}

.pkg-search-wrap {
    flex: 1;
    position: relative;
    max-width: 400px;
}

.pkg-search-wrap i {
    position: absolute;
    left: 1.2rem;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
    font-size: 1.2rem;
}

#pkg-search-input {
    width: 100%;
    padding: 0.9rem 1rem 0.9rem 3.2rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.3s ease;
    background: #f8fafc;
}

#pkg-search-input:focus {
    outline: none;
    border-color: #1e3a5f;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(30, 58, 95, 0.05);
}

.pkg-filters-trigger button {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    padding: 0.9rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    color: #0f172a;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.pkg-filters-trigger button:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.pkg-filters-trigger button.active {
    background: #0f172a;
    color: #ffffff;
    border-color: #0f172a;
}

#pkg-sort-select {
    padding: 0.9rem 1.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #ffffff;
    font-weight: 600;
    color: #0f172a;
    cursor: pointer;
    outline: none;
}

/* Filters Drawer */
.pkg-filters-drawer {
    background: #f8fafc;
    border-radius: 8px;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 0;
    border: 0 solid #e2e8f0;
}

.pkg-filters-drawer.active {
    padding: 2.5rem;
    max-height: 500px;
    margin-bottom: 3rem;
    border-width: 1px;
}

.pkg-filters-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.filter-group label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 1rem;
}

.pkg-filter-field {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #ffffff;
    font-weight: 500;
    outline: none;
}

/* Loading Bar */
.pkg-loading-bar {
    height: 3px;
    width: 0;
    background: #1e3a5f;
    position: absolute;
    left: 0;
    margin-top: -3px;
    transition: width 0.3s ease;
}

.pkg-loading-bar.active {
    width: 100%;
    animation: loadingAnim 2s infinite linear;
}

@keyframes loadingAnim {
    0% { transform: translateX(-100%); width: 30%; }
    100% { transform: translateX(400%); width: 30%; }
}

/* Results Meta */
.pkg-results-meta {
    margin-bottom: 2.5rem;
    font-size: 0.95rem;
    color: #64748b;
}

.pkg-results-meta strong {
    color: #0f172a;
}

/* Grid - Robust Flex Layout */
.pkg-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    margin: 0 -1.25rem !important;
    gap: 0 !important; /* Managed by card padding */
    width: calc(100% + 2.5rem) !important;
}

/* Card Wrapper in Grid */
.pkg-grid > article {
    width: 33.333% !important;
    padding: 1.25rem !important;
    display: flex;
}

/* The Card itself */
.biz-elite-card {
    width: 100% !important;
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(15, 23, 42, 0.03);
    transition: all 0.5s cubic-bezier(0.2, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.biz-elite-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px rgba(15, 23, 42, 0.08);
    border-color: #e2e8f0;
}

.pkg-grid .biz-elite-thumb {
    height: 220px;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.biz-elite-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s ease;
}

.biz-elite-card:hover .biz-elite-img {
    transform: scale(1.05);
}

.biz-elite-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: #0f172a;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0.4rem 0.8rem;
    border-radius: 2px;
    letter-spacing: 0.1em;
    z-index: 2;
}

.pkg-grid .biz-elite-body {
    padding: 2.5rem;
}

.pkg-grid .biz-elite-title {
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

.pkg-grid .biz-elite-baseline {
    margin-bottom: 2.5rem;
    font-size: 1rem;
}

.no-packages-found {
    grid-column: 1 / -1;
    padding: 8rem 0;
    text-align: center;
    color: #94a3b8;
    font-size: 1.1rem;
    border: 2px dashed #f1f5f9;
    border-radius: 12px;
}

/* Pagination */
.pkg-pagination {
    margin-top: 6rem;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
}

.pkg-pagination a, .pkg-pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    padding: 0 0.5rem;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    color: #64748b;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.pkg-pagination a:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #0f172a;
}

.pkg-pagination .current {
    background: #0f172a;
    color: #ffffff;
    border-color: #0f172a;
}

/* Responsive */
@media (max-width: 1100px) {
    .pkg-grid > article { width: 50% !important; }
    .pkg-filters-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .pkg-grid > article { width: 100% !important; }
    .pkg-title { font-size: 2.5rem; }
    .pkg-toolbar { flex-direction: column; align-items: stretch; top: 0; position: relative; }
    .pkg-search-wrap { max-width: none; }
    .pkg-filters-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}
