/* ===== Limited Time Free App Gallery - iOS 26 Design ===== */

/* ===== Global Box Sizing ===== */
* {
    box-sizing: border-box;
}

:root {
    --ltf-primary: #0285e5;
    --ltf-secondary: #ff6b6b;
    --ltf-accent: #ffc107;
    --ltf-dark: #1a1a1a;
    --ltf-light: #f8f9fa;
    --ltf-text: #333333;
    --ltf-text-muted: #888888;
    --ltf-border: #e0e0e0;
    --ltf-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    --ltf-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.12);
    --ltf-transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --ltf-glass-bg: rgba(255, 255, 255, 0.7);
    --ltf-glass-border: rgba(255, 255, 255, 0.5);
}

/* ===== Main Layout ===== */
.wrap-modern {
    width: 100%;
    background: linear-gradient(180deg, #f5f7fa 0%, #e8ecf1 100%);
    min-height: 100vh;
    padding: 40px 0;
    overflow-x: hidden;
}

.ltf-header {
    width: 100%;
    background: linear-gradient(135deg, var(--ltf-primary) 0%, #0061b8 100%);
    padding: 60px 20px 40px;
    margin-bottom: 40px;
    box-shadow: var(--ltf-shadow-hover);
    backdrop-filter: blur(20px);
}

.ltf-header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
    width: 100%;
}

.ltf-header-main {
    text-align: center;
    margin-bottom: 25px;
    overflow: hidden;
}

.ltf-title {
    font-size: 3em;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 15px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    letter-spacing: -0.5px;
}

.ltf-badge {
    font-size: 1.2em;
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.ltf-subtitle {
    font-size: 1.1em;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    font-weight: 300;
    letter-spacing: 0.5px;
}

/* ===== Header Tags ===== */
.ltf-tags-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    align-items: center;
    padding: 0 20px;
    box-sizing: border-box;
}

.ltf-tag {
    display: inline-block;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.95em;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: var(--ltf-transition);
    cursor: default;
}

.ltf-tag:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

/* ===== Container & Grid ===== */
.ltf-container {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    gap: 30px;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.ltf-grid-wrapper {
    flex: 1;
    min-width: 0;
    width: 100%;
}

.ltf-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    width: 100%;
}

.ltf-sidebar {
    width: 300px;
    flex-shrink: 0;
}

/* ===== Card Styles - iOS 26 Design ===== */
.ltf-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--ltf-shadow);
    transition: var(--ltf-transition);
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.ltf-card:hover {
    box-shadow: var(--ltf-shadow-hover);
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.9);
}

.ltf-card-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    background: linear-gradient(135deg, #f0f0f0 0%, #e8e8e8 100%);
    overflow: hidden;
}

.ltf-card-image-wrapper a {
    display: block;
    width: 100%;
    height: 100%;
    position: relative;
}

.ltf-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--ltf-transition);
}

.ltf-card:hover .ltf-card-image {
    transform: scale(1.08);
}

.ltf-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(2, 133, 229, 0.08);
    opacity: 0;
    transition: var(--ltf-transition);
}

.ltf-card:hover .ltf-card-overlay {
    opacity: 1;
}

/* ===== Limited Time Badge ===== */
.ltf-badge-limited {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(135deg, var(--ltf-secondary) 0%, #ff5252 100%);
    backdrop-filter: blur(10px);
    padding: 8px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 16px rgba(255, 107, 107, 0.3);
    z-index: 2;
    animation: badgePulse 2s ease-in-out infinite;
}

.ltf-badge-text {
    color: #ffffff;
    font-size: 0.75em;
    font-weight: 700;
    letter-spacing: 0.8px;
    display: block;
}

@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ===== Card Content ===== */
.ltf-card-content {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.ltf-card-header {
    margin-bottom: 8px;
}

.ltf-card-title {
    font-size: 1em;
    font-weight: 700;
    color: var(--ltf-dark);
    margin: 0;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: var(--ltf-transition);
    line-height: 1.3;
}

.ltf-card-title:hover {
    color: var(--ltf-primary);
}

/* ===== Price Section ===== */
.ltf-card-price {
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.ltf-price-badge {
    font-size: 0.95em;
    font-weight: 700;
    color: #ffffff;
    background: linear-gradient(135deg, var(--ltf-secondary) 0%, #ff5252 100%);
    padding: 4px 10px;
    border-radius: 8px;
    letter-spacing: 0.5px;
    display: inline-block;
}

.ltf-price-original {
    font-size: 0.85em;
    color: var(--ltf-text-muted);
    text-decoration: line-through;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

.ltf-price-free-badge {
    font-size: 0.9em;
    font-weight: 700;
    color: var(--ltf-secondary);
    letter-spacing: 0.3px;
}

/* ===== Card Meta ===== */
.ltf-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    font-size: 0.8em;
}

.ltf-rating {
    display: flex;
    align-items: center;
    gap: 4px;
}

.ltf-stars {
    font-size: 0.9em;
    color: var(--ltf-accent);
    font-weight: 600;
}

.ltf-rating-count {
    font-size: 0.8em;
    color: #6d28d9;
    background: rgba(168, 85, 247, 0.14);
    padding: 3px 8px;
    border-radius: 999px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.ltf-rating-count::before {
    content: "";
    width: 12px;
    height: 12px;
    display: inline-block;
    background: url('/content/images/man.png') no-repeat center;
    background-size: 12px 12px;
}

.ltf-size {
    font-size: 0.8em;
    color: var(--ltf-text-muted);
    background: rgba(0, 0, 0, 0.05);
    padding: 3px 6px;
    border-radius: 6px;
}

/* ===== Description ===== */
.ltf-card-description {
    font-size: 0.85em;
    color: var(--ltf-text-muted);
    line-height: 1.4;
    margin: 0;
    padding-bottom: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ltf-card-spacer {
    flex: 1;
    min-height: 8px;
}

/* ===== Card Footer Button - iOS 26 Style ===== */
.ltf-btn-details {
    display: block;
    width: 100%;
    padding: 9px 12px;
    background: linear-gradient(135deg, var(--ltf-primary) 0%, #0061b8 100%);
    color: #ffffff;
    text-decoration: none;
    text-align: center;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85em;
    transition: var(--ltf-transition);
    border: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    flex-shrink: 0;
    box-sizing: border-box;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.4;
    box-shadow: 0 4px 12px rgba(2, 133, 229, 0.2);
}

.ltf-btn-details:hover {
    background: linear-gradient(135deg, #0061b8 0%, #004a94 100%);
    box-shadow: 0 8px 20px rgba(2, 133, 229, 0.35);
    transform: translateY(-2px);
}

.ltf-btn-details:active {
    transform: translateY(0);
}

/* ===== Responsive Design ===== */
@media (max-width: 1400px) {
    .ltf-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1200px) {
    .ltf-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .ltf-title {
        font-size: 2.2em;
    }
}

@media (max-width: 768px) {
    .wrap-modern {
        padding: 20px 0;
    }

    .ltf-header {
        padding: 40px 20px 30px;
        margin-bottom: 30px;
    }

    .ltf-header-main {
        margin-bottom: 20px;
    }

    .ltf-title {
        font-size: 1.8em;
        gap: 8px;
    }

    .ltf-subtitle {
        font-size: 1em;
    }

    .ltf-tags-container {
        gap: 8px;
    }

    .ltf-tag {
        font-size: 0.85em;
        padding: 6px 12px;
        border-radius: 16px;
    }

    .ltf-container {
        flex-direction: column;
        gap: 20px;
        padding: 0 15px;
    }

    .ltf-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .ltf-sidebar {
        width: 100%;
    }

    .ltf-card {
        border-radius: 18px;
    }

    .ltf-card-content {
        padding: 14px;
    }

    .ltf-card-title {
        font-size: 0.95em;
    }

    .ltf-card-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .ltf-btn-details {
        padding: 8px 10px;
        font-size: 0.8em;
        border-radius: 8px;
    }

    .ltf-badge-limited {
        padding: 6px 10px;
        border-radius: 10px;
        top: 10px;
        right: 10px;
    }

    .ltf-badge-text {
        font-size: 0.7em;
    }
}

@media (max-width: 480px) {
    .ltf-header {
        padding: 30px 15px;
        margin-bottom: 20px;
    }

    .ltf-header-main {
        margin-bottom: 15px;
    }

    .ltf-title {
        font-size: 1.5em;
        gap: 6px;
    }

    .ltf-subtitle {
        font-size: 0.9em;
    }

    .ltf-tags-container {
        gap: 6px;
    }

    .ltf-tag {
        font-size: 0.75em;
        padding: 5px 10px;
        border-radius: 14px;
    }

    .ltf-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .ltf-container {
        padding: 0 10px;
    }

    .ltf-card {
        border-radius: 16px;
    }

    .ltf-card-meta {
        font-size: 0.75em;
    }

    .ltf-badge-limited {
        padding: 5px 8px;
    }

    .ltf-badge-text {
        font-size: 0.65em;
    }

    .ltf-card-price {
        margin-bottom: 10px;
        padding-bottom: 8px;
    }

    .ltf-card-description {
        font-size: 0.8em;
    }

    .ltf-price-badge {
        font-size: 0.85em;
        padding: 3px 8px;
    }

    .ltf-price-original {
        font-size: 0.75em;
    }

    .ltf-price-free-badge {
        font-size: 0.8em;
    }
}

/* ===== Data Item Container ===== */
.data_item {
    display: contents;
}

/* ===== Utility Classes ===== */
.clearbox {
    clear: both;
    display: block;
}

.next {
    display: none;
}

/* ===== Smooth Transitions ===== */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== Animation for Loading ===== */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ltf-card {
    animation: slideInUp 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Right Sidebar Styling ===== */
.ltf-sidebar > div {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 20px;
    padding: 20px;
    box-shadow: var(--ltf-shadow);
}
