/* ============================================
   LENSPO CONTESTS STYLING
   Self-contained styles for the contest archive,
   single contest, winners and filter components.
   Brand primary: #6C1CEA
   ============================================ */

/* ---------- Filter bar (category / status / year) ---------- */
.contest-filter-panel {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    align-items: end;
    padding: 24px;
    margin-bottom: 40px;
    background: #F8F9FA;
    border: 1px solid #EDE4FC;
    border-radius: 16px;
}

.contest-filter-panel.winner-filter-panel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.contest-filter-field label {
    display: block;
    margin-bottom: 8px;
    color: #1d1d1d;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.contest-filter-field input,
.contest-filter-field select {
    width: 100%;
    min-height: 48px;
    padding: 10px 14px;
    border: 1px solid #E5E7EB;
    border-radius: 10px;
    background: #fff;
    color: #333;
    font-size: 15px;
    outline: none;
}

.contest-filter-field input:focus,
.contest-filter-field select:focus {
    border-color: #6C1CEA;
    box-shadow: 0 0 0 3px rgba(43, 139, 71, 0.12);
}

.contest-filter-search {
    grid-column: span 2;
}

.contest-filter-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.contest-reset-link {
    color: #666;
}

.contest-filter {
    list-style: none;
    padding: 0;
    margin: 0 0 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.contest-filter li {
    margin: 0;
}

.contest-filter a {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 30px;
    background: #F3ECFE;
    color: #333;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.25s ease;
    border: 1px solid transparent;
}

.contest-filter a:hover {
    background: #F3ECFE;
    color: #6C1CEA;
}

.contest-filter a.current {
    background: #6C1CEA;
    color: #fff;
    border-color: #6C1CEA;
}

/* Month/year sub filter */
.contest-subfilter {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 35px;
}

.contest-subfilter a {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 6px;
    background: #fff;
    border: 1px solid #e0e0e0;
    color: #555;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.contest-subfilter a:hover {
    border-color: #6C1CEA;
    color: #6C1CEA;
}

.contest-subfilter a.current {
    background: #6C1CEA;
    border-color: #6C1CEA;
    color: #fff;
}

/* ---------- Contest cards ---------- */
.contest-card {
    position: relative;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.06);
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contest-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.contest-card .contest-card-img {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: #F3ECFE;
}

.contest-card .contest-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.contest-card:hover .contest-card-img img {
    transform: scale(1.06);
}

.contest-card .contest-card-body {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.contest-badge-row {
    position: absolute;
    top: 14px;
    left: 14px;
    right: 14px;
    z-index: 10;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
}

.contest-badge-row.static {
    position: static;
    justify-content: flex-start;
    margin-bottom: 16px;
}

.contest-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 30px;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.contest-chip-category {
    background: #1d1d1d;
}

.contest-chip-status.badge-running,
.contest-chip-status.bg-success {
    background: #6C1CEA;
}

.contest-chip-status.badge-upcoming,
.contest-chip-status.bg-info {
    background: #2271b1;
}

.contest-chip-status.badge-ended,
.contest-chip-status.bg-secondary {
    background: #787c82;
}

.contest-featured-badge {
    position: absolute;
    left: 14px;
    bottom: 14px;
    z-index: 10;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 30px;
    background: #f0b849;
    color: #1d1d1d;
    font-size: 12px;
    font-weight: 800;
}

.contest-card .contest-card-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 8px;
    line-height: 1.3;
}

.contest-card .contest-card-title a {
    color: #1d1d1d;
    text-decoration: none;
}

.contest-card .contest-card-title a:hover {
    color: #6C1CEA;
}

.contest-card .contest-card-meta {
    font-size: 13px;
    color: #7a7a7a;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.contest-card .contest-card-meta i {
    color: #6C1CEA;
}

.contest-card-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    margin-bottom: 10px;
    color: #666;
    font-size: 13px;
    font-weight: 700;
}

.contest-card-facts i {
    color: #6C1CEA;
}

.contest-deadline {
    margin-bottom: 12px;
    color: #444;
    font-size: 13px;
}

.contest-card .contest-card-desc {
    font-size: 14px;
    color: #555;
    line-height: 1.6;
    margin-bottom: 18px;
}

.contest-card .read-more {
    margin-top: auto;
    align-self: flex-start;
}

/* ---------- Status badge ---------- */
.contest-status-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 5px 12px;
    border-radius: 30px;
    color: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.contest-status-badge.bg-success { background: #6C1CEA; }
.contest-status-badge.bg-info    { background: #2271b1; }
.contest-status-badge.bg-secondary { background: #787c82; }

/* Featured contest */
.contest-featured-section {
    background: #fff;
}

.contest-featured-card {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    gap: 0;
    overflow: hidden;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.08);
}

.contest-featured-image {
    min-height: 390px;
    background: #F3ECFE;
}

.contest-featured-image img {
    width: 100%;
    height: 100%;
    min-height: 390px;
    object-fit: cover;
    display: block;
}

.contest-featured-content {
    padding: 42px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contest-featured-meta {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    padding: 0;
    margin: 0 0 20px;
    list-style: none;
}

.contest-featured-meta li {
    padding: 12px;
    border-radius: 10px;
    background: #F8F9FA;
    color: #1d1d1d;
    font-weight: 800;
}

.contest-featured-meta span {
    display: block;
    margin-bottom: 4px;
    color: #777;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* ---------- Single contest ---------- */
/* The single contest hero reuses the convertsite page hero markup
   (.top-single-bkg.topsinglepage + .inner-desc + .display-2.single-post-title),
   which is already styled in the main stylesheet, so no overrides are needed. */

/* Contest info strip */
.contest-info-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin: 0 0 35px;
    padding: 0;
    list-style: none;
}

.contest-info-strip li {
    flex: 1;
    min-width: 160px;
    background: #F8F9FA;
    border: 1px solid #EDE4FC;
    border-radius: 10px;
    padding: 16px 18px;
}

.contest-info-strip .label {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #8a8a8a;
    margin-bottom: 4px;
    font-weight: 600;
}

.contest-info-strip .value {
    font-size: 16px;
    font-weight: 700;
    color: #1d1d1d;
}

.contest-featured-figure {
    margin: 0;
    overflow: hidden;
    border-radius: 16px;
    background: #F3ECFE;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

.contest-featured-figure img {
    width: 100%;
    height: auto;
    display: block;
}

.contest-download-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.contest-download-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 30px;
    background: #F8F9FA;
    border: 1px solid #EDE4FC;
    color: #1d1d1d;
    font-weight: 700;
    text-decoration: none;
}

.contest-download-item:hover {
    background: #6C1CEA;
    color: #fff;
    text-decoration: none;
}

.contest-related-card {
    padding: 44px 28px;
    border-radius: 18px;
    background: #F8F9FA;
    border: 1px solid #EDE4FC;
}

/* Winner cards reuse the convertsite markup
   (.winner-card.bg-white.radius10.shadow-sm.p-4 + .card-type-badge.bg-success +
   .winner-name / .winner-title / .winner-desc), styled via the shared utility
   classes already present in the main stylesheet â€” no overrides needed here so
   the winner section stays visually identical to the original. */

/* ---------- Winners page (search + clickable cards) ---------- */
.winner-search-wrap {
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.winner-search-input {
    width: 100%;
    padding: 14px 22px;
    font-size: 16px;
    border: 1px solid #e0e6e2;
    border-radius: 30px;
    background: #fff;
    color: #333;
    outline: none;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.winner-search-input:focus {
    border-color: #6C1CEA;
    box-shadow: 0 0 0 3px rgba(43, 139, 71, 0.12);
}

/* Winner cards link to their Single Winner page without changing the design. */
.winner-card-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
    transition: transform 0.3s ease;
}

.winner-card-link:hover {
    transform: translateY(-6px);
    text-decoration: none;
    color: inherit;
}

.winner-card-link .winner-card {
    transition: box-shadow 0.3s ease;
}

.winner-card-link:hover .winner-card {
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.winner-category-badge {
    margin-bottom: 12px;
    box-shadow: none;
}

.winner-description {
    font-size: 15px;
    line-height: 1.7;
    color: #555;
    margin-bottom: 20px;
}

/* ---------- Not Found / 404 / empty states ---------- */
.lenspo-notfound {
    padding-top: 70px !important;
    padding-bottom: 70px !important;
}

.lenspo-notfound-icon i {
    font-size: 56px;
    color: #6C1CEA;
}

.lenspo-notfound-actions {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 32px;
}

@media (max-width: 768px) {
    .lenspo-notfound {
        padding-top: 48px !important;
        padding-bottom: 48px !important;
    }

    .lenspo-notfound-actions {
        margin-top: 24px;
    }
}

.error-404-image {
    max-width: 460px;
    margin-left: auto;
    margin-right: auto;
}

.error-404-image img {
    width: 100%;
}

/* Featured contests strip */
.featured-contests {
    background: #F8F9FA;
}


/* ---------- Homepage: How to enter ---------- */
#contest-section.vl-contest-section {
    --contest-primary: var(--lp-primary, #6C1CEA);
    --contest-primary-dark: var(--lp-primary-dark, #5815C9);
    --contest-soft: var(--lp-primary-soft, #F3ECFE);
    --contest-ink: var(--lp-ink, #0E082B);
    --contest-muted: var(--lp-muted, #6B7A72);
    --contest-surface: var(--lp-surface, #fff);
    position: relative;
    overflow: hidden;
    background: var(--lp-surface-2, #F8F9FA) !important;
}

#contest-section.vl-contest-section::before,
#contest-section.vl-contest-section::after {
    display: none;
}

#contest-section .container {
    position: relative;
    z-index: 1;
}

#contest-section .vl-section-title4 {
    max-width: 760px;
    margin-right: auto;
    margin-left: auto;
}

#contest-section .vl-section-title4 .subtitle {
    color: var(--lp-green-deep, #4510A0);
}

#contest-section .vl-section-title4 .subtitle::before {
    display: none;
    content: none;
}

#contest-section .vl-section-title4 .title {
    color: var(--contest-ink);
}

#contest-section .contest-container {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
}

#contest-section .contest-content {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
}

#contest-section .contest-left,
#contest-section .contest-right {
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
    border-radius: 20px;
    background: var(--contest-surface);
    border: 1px solid rgba(108, 28, 234, 0.08);
    box-shadow: 0 10px 30px rgba(14, 8, 43, 0.06);
}

#contest-section .contest-image,
#contest-section .contest-right-image {
    position: relative;
    overflow: hidden;
    min-height: 280px;
    background: var(--contest-soft);
}

#contest-section .contest-image::after,
#contest-section .contest-right-image::after {
    position: absolute;
    inset: 0;
    content: "";
    pointer-events: none;
    background: linear-gradient(180deg, transparent 58%, rgba(14, 8, 43, 0.32));
}

#contest-section .contest-image img,
#contest-section .contest-right-image img {
    display: block;
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.7s ease;
}

#contest-section .contest-left:hover .contest-image img,
#contest-section .contest-right:hover .contest-right-image img {
    transform: scale(1.04);
}

#contest-section .contest-instructions,
#contest-section .contest-benefits {
    padding: 32px;
}

#contest-section .instruction-title,
#contest-section .benefits-title {
    margin: 0 0 12px;
    color: var(--contest-ink);
    font-size: clamp(22px, 2.2vw, 30px);
    line-height: 1.25;
    letter-spacing: -0.02em;
}

#contest-section .contest-instructions > .para {
    margin-bottom: 24px;
    color: var(--contest-muted);
}

#contest-section .instruction-steps {
    display: grid;
    gap: 12px;
}

#contest-section .step {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border: 1px solid rgba(108, 28, 234, 0.1);
    border-radius: 14px;
    background: var(--contest-soft);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

#contest-section .step:hover {
    border-color: rgba(108, 28, 234, 0.28);
    box-shadow: 0 10px 24px rgba(108, 28, 234, 0.08);
    transform: translateX(3px);
}

#contest-section .step-number {
    display: grid;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--lp-primary-deep, #4510A0), var(--contest-primary));
    box-shadow: 0 8px 18px rgba(108, 28, 234, 0.22);
    color: #fff;
    font-weight: 800;
}

#contest-section .step-title {
    margin: 0;
    color: var(--contest-ink);
    font-size: 16px;
    font-weight: 700;
    line-height: 1.45;
}

#contest-section .contest-benefits {
    padding-bottom: 20px;
}

#contest-section .benefits-list {
    display: grid;
    gap: 12px;
    margin-top: 20px;
}

#contest-section .benefit-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    border: 1px solid rgba(108, 28, 234, 0.1);
    border-radius: 14px;
    background: var(--contest-soft);
}

#contest-section .benefit-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--lp-primary-deep, #4510A0), var(--contest-primary));
    box-shadow: 0 8px 18px rgba(108, 28, 234, 0.2);
    color: #fff;
}

#contest-section .benefit-icon i,
#contest-section .benefit-icon .svg-inline--fa {
    color: #fff !important;
    font-size: 1rem;
    line-height: 1;
}

#contest-section .benefit-text {
    margin: 0;
    color: var(--contest-muted);
    line-height: 1.65;
}

#contest-section .benefit-text strong {
    color: var(--contest-ink);
}

#contest-section .contest-cta {
    margin: auto 32px 32px;
}

#contest-section .contest-cta .btn-area4 {
    justify-content: flex-start;
}

#contest-section .contest-cta .header-btn1 {
    width: auto !important;
}

/* Empty state */
.contest-empty {
    text-align: center;
    color: #888;
    padding: 40px 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    #contest-section .contest-container {
        padding: 0;
        border-radius: 0;
    }

    #contest-section .contest-content {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    #contest-section .contest-left,
    #contest-section .contest-right {
        border-radius: 16px;
    }

    #contest-section .contest-image,
    #contest-section .contest-right-image {
        min-height: 220px;
    }

    #contest-section .contest-image img,
    #contest-section .contest-right-image img {
        height: 220px;
    }

    #contest-section .contest-instructions,
    #contest-section .contest-benefits {
        padding: 22px 18px;
    }

    #contest-section .contest-cta {
        margin: 0 18px 22px;
    }

    #contest-section .contest-cta .btn-area4 {
        justify-content: center;
    }

    #contest-section .step,
    #contest-section .benefit-item {
        padding: 13px;
    }

    .contest-filter-panel,
    .contest-filter-panel.winner-filter-panel {
        grid-template-columns: 1fr;
        padding: 18px;
    }

    .contest-filter-search {
        grid-column: auto;
    }

    .contest-featured-card {
        grid-template-columns: 1fr;
    }

    .contest-featured-image,
    .contest-featured-image img {
        min-height: 260px;
    }

    .contest-featured-content {
        padding: 26px;
    }

    .contest-featured-meta {
        grid-template-columns: 1fr;
    }

    .contest-card .contest-card-title {
        font-size: 18px;
    }
}
