/**
 * Ladders Archive - Modern Grid View
 * Modern card-based design for ladders
 * @package team-exciting
 * @version 1.0.0
 */

/* ===================================
   LADDERS PAGE HEADER
   =================================== */

.trn-ladders-page-header {
    background: linear-gradient(135deg, rgba(255, 165, 0, 0.1), rgba(255, 215, 0, 0.05));
    border: 2px solid rgba(255, 165, 0, 0.2);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

.trn-ladders-page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #ffa500, #ffd700, #ffa500);
    background-size: 200% 100%;
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.trn-ladders-page-header h1 {
    font-size: 48px;
    font-weight: 900;
    background: linear-gradient(135deg, #ffa500, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 15px;
}

.trn-ladders-stats-overview {
    display: flex;
    gap: 30px;
    margin-top: 25px;
    flex-wrap: wrap;
}

.trn-stat-box {
    flex: 1;
    min-width: 150px;
    background: rgba(26, 26, 26, 0.8);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid rgba(255, 165, 0, 0.2);
    text-align: center;
    transition: all 0.3s ease;
}

.trn-stat-box:hover {
    transform: translateY(-5px);
    border-color: #ffa500;
    box-shadow: 0 10px 30px rgba(255, 165, 0, 0.3);
}

.trn-stat-box-value {
    font-size: 36px;
    font-weight: 900;
    color: #ffa500;
    display: block;
    margin-bottom: 8px;
}

.trn-stat-box-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===================================
   SEARCH AND FILTERS
   =================================== */

.trn-ladders-filters {
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.trn-ladders-search {
    position: relative;
    flex: 1;
    min-width: 280px;
    max-width: 500px;
}

.trn-ladders-search i {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.5);
    font-size: 18px;
}

.trn-ladders-search input {
    width: 100%;
    padding: 15px 20px 15px 50px;
    background: rgba(26, 26, 26, 0.8);
    border: 2px solid rgba(255, 165, 0, 0.2);
    border-radius: 30px;
    color: #fff;
    font-size: 16px;
    transition: all 0.3s ease;
}

.trn-ladders-search input:focus {
    outline: none;
    border-color: #ffa500;
    box-shadow: 0 0 20px rgba(255, 165, 0, 0.3);
}

.trn-ladders-filter-btn {
    padding: 12px 25px;
    background: rgba(26, 26, 26, 0.8);
    border: 2px solid rgba(255, 165, 0, 0.2);
    border-radius: 25px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.trn-ladders-filter-btn:hover {
    background: rgba(255, 165, 0, 0.1);
    border-color: #ffa500;
    color: #ffa500;
}

.trn-ladders-filter-btn.active {
    background: linear-gradient(135deg, rgba(255, 165, 0, 0.2), rgba(255, 215, 0, 0.1));
    border-color: #ffa500;
    color: #ffa500;
}

/* ===================================
   LADDERS GRID
   =================================== */

.trn-ladders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

/* ===================================
   LADDER CARD
   =================================== */

.trn-ladder-card {
    background: linear-gradient(145deg, rgba(26, 26, 26, 0.95), rgba(37, 37, 37, 0.95));
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
}

.trn-ladder-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #ffa500, #ffd700);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.trn-ladder-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 70px rgba(255, 165, 0, 0.5);
    border-color: rgba(255, 165, 0, 0.5);
}

.trn-ladder-card:hover::before {
    transform: scaleX(1);
}

/* Card Header */
.trn-ladder-card-header {
    padding: 30px;
    text-align: center;
    position: relative;
    background: linear-gradient(180deg, rgba(255, 165, 0, 0.05), transparent);
}

.trn-ladder-game-thumbnail {
    width: 120px;
    height: 120px;
    margin: 0 auto 20px;
    border-radius: 16px;
    overflow: hidden;
    border: 3px solid rgba(255, 165, 0, 0.3);
    position: relative;
    transition: all 0.4s ease;
}

.trn-ladder-card:hover .trn-ladder-game-thumbnail {
    transform: scale(1.1);
    border-color: #ffa500;
    box-shadow: 0 10px 30px rgba(255, 165, 0, 0.4);
}

.trn-ladder-game-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.trn-ladder-card:hover .trn-ladder-game-thumbnail img {
    transform: scale(1.1);
}

/* Active Badge */
.trn-ladder-active-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 12px;
    background: linear-gradient(135deg, #38ff1e, #00a000);
    color: #000;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    animation: pulse 2s ease infinite;
    box-shadow: 0 4px 12px rgba(56, 255, 30, 0.3);
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Card Body */
.trn-ladder-card-body {
    padding: 0 30px 30px;
}

.trn-ladder-name {
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 8px;
    text-align: center;
    transition: color 0.3s ease;
}

.trn-ladder-card:hover .trn-ladder-name {
    color: #ffa500;
}

.trn-ladder-type {
    display: block;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 165, 0, 0.8);
    margin-bottom: 20px;
}

/* Meta Info */
.trn-ladder-meta {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.trn-ladder-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.trn-ladder-meta-item i {
    color: #ffa500;
    font-size: 16px;
}

/* Stats */
.trn-ladder-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.trn-ladder-stat {
    text-align: center;
}

.trn-ladder-stat-value {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: #ffa500;
    margin-bottom: 5px;
}

.trn-ladder-stat-label {
    display: block;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Card Footer */
.trn-ladder-card-footer {
    padding: 20px 30px;
    background: rgba(0, 0, 0, 0.3);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.trn-ladder-view-btn {
    display: block;
    width: 100%;
    padding: 12px 20px;
    background: linear-gradient(135deg, rgba(255, 165, 0, 0.2), rgba(255, 215, 0, 0.1));
    border: 2px solid rgba(255, 165, 0, 0.3);
    border-radius: 10px;
    color: #ffa500;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.trn-ladder-view-btn:hover {
    background: linear-gradient(135deg, #ffa500, #ffd700);
    border-color: #ffa500;
    color: #000;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 165, 0, 0.4);
}

/* ===================================
   RANKING TYPE BADGES
   =================================== */

.trn-ladder-ranking-badge {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(255, 165, 0, 0.1);
    border: 1px solid rgba(255, 165, 0, 0.3);
    border-radius: 12px;
    color: #ffa500;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    margin-top: 8px;
}

/* ===================================
   RESPONSIVE
   =================================== */

@media (max-width: 768px) {
    .trn-ladders-page-header h1 {
        font-size: 36px;
    }

    .trn-ladders-page-header {
        padding: 30px 20px;
    }

    .trn-ladders-stats-overview {
        flex-direction: column;
    }

    .trn-ladders-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .trn-ladders-search {
        max-width: 100%;
    }

    .trn-ladders-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .trn-ladders-page-header h1 {
        font-size: 28px;
    }

    .trn-stat-box-value {
        font-size: 28px;
    }

    .trn-ladder-game-thumbnail {
        width: 100px;
        height: 100px;
    }

    .trn-ladder-name {
        font-size: 18px;
    }

    .trn-ladder-meta {
        grid-template-columns: 1fr;
    }
}
