/* ==========================================================================
   Bento Grid — Homepage Feature Showcase
   ========================================================================== */

.bento-showcase {
    padding: 5rem 2rem;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Card Base
   -------------------------------------------------------------------------- */

.bento-card {
    display: flex;
    flex-direction: column;
    padding: 1.75rem;
    border-radius: 12px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    text-decoration: none;
    color: var(--text-primary);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}

.bento-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.04) 0%, transparent 60%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.bento-card:hover {
    transform: translateY(-5px);
    border-color: rgba(16, 185, 129, 0.5);
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.12);
    color: var(--text-primary);
    text-decoration: none;
}

.bento-card:hover::before {
    opacity: 1;
}

/* Featured cards span 2 columns */
.bento-card--featured {
    grid-column: span 2;
    padding: 2rem;
}

/* --------------------------------------------------------------------------
   Card Content (text area)
   -------------------------------------------------------------------------- */

.bento-card__content {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 2;
}

/* --------------------------------------------------------------------------
   Card Elements
   -------------------------------------------------------------------------- */

.bento-card__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(16, 185, 129, 0.05) 100%);
    border: 1px solid rgba(16, 185, 129, 0.25);
    margin-bottom: 1rem;
    font-size: 1.25rem;
    color: var(--cta-primary);
    flex-shrink: 0;
}

.bento-card--featured .bento-card__icon {
    width: 56px;
    height: 56px;
    font-size: 1.5rem;
}

.bento-card__title {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
    color: var(--text-primary);
}

.bento-card--featured .bento-card__title {
    font-size: 1.25rem;
}

.bento-card__desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0 0 auto;
    padding-bottom: 1rem;
}

.bento-card__badge {
    display: inline-flex;
    align-items: center;
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--cta-primary);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 20px;
    padding: 0.25rem 0.75rem;
    margin-bottom: 0.75rem;
    width: fit-content;
}

.bento-card__cta {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--cta-primary);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.bento-card__cta i {
    transition: transform 0.2s ease;
    font-size: 0.75rem;
}

.bento-card:hover .bento-card__cta i {
    transform: translateX(4px);
}

/* -- "How it works" deep-link -- */
.bento-hiw-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.75rem;
    color: var(--text-secondary);
    opacity: 0.6;
    margin-top: 0.25rem;
    cursor: pointer;
    transition: opacity 0.2s, color 0.2s;
    position: relative;
    z-index: 3;
}

.bento-hiw-link:hover {
    opacity: 1;
    color: var(--cta-primary);
}

.bento-hiw-link i {
    font-size: 0.6rem;
}

/* --------------------------------------------------------------------------
   Peek Window Preview
   -------------------------------------------------------------------------- */

.bento-card__preview {
    height: 90px;
    margin: 0 -1.75rem -1.75rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.4s ease, opacity 0.4s ease;
    opacity: 0.65;
    pointer-events: none;
}

.bento-card__preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 30px;
    background: linear-gradient(to bottom, var(--card-bg), transparent);
    z-index: 1;
}

.bento-card:hover .bento-card__preview {
    transform: translateY(-20px);
    opacity: 0.9;
}

.bento-card--featured .bento-card__preview {
    height: 110px;
    margin: 0 -2rem -2rem;
}

/* --------------------------------------------------------------------------
   Peek Mockup Utilities
   -------------------------------------------------------------------------- */

.peek-mock {
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.7rem;
    padding: 0.75rem 1.75rem;
    pointer-events: none;
    color: var(--text-secondary);
}

.bento-card--featured .peek-mock {
    padding: 0.75rem 2rem;
}

/* -- Matchup / Predictions mock -- */
.peek-mock--picks {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.peek-mock__matchup {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.peek-mock__team {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.75rem;
}

.peek-mock__vs {
    color: var(--text-secondary);
    opacity: 0.5;
    font-size: 0.65rem;
}

.peek-mock__bar-wrap {
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.peek-mock__bar {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--cta-primary), rgba(16, 185, 129, 0.5));
}

.peek-mock__pill {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 0.6rem;
    font-weight: 600;
    width: fit-content;
}

.peek-mock__pill--elite {
    background: rgba(16, 185, 129, 0.15);
    color: var(--cta-primary);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

/* -- Report Card / Teams mock -- */
.peek-mock--teams {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.peek-mock__logo-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.7rem;
    color: var(--cta-primary);
}

.peek-mock__grade {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--cta-primary);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 6px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.peek-mock__stats {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.peek-mock__stat-bar {
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.peek-mock__stat-fill {
    height: 100%;
    border-radius: 2px;
    background: var(--cta-primary);
    opacity: 0.6;
}

/* -- Simulator mock -- */
.peek-mock--sim {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.peek-mock__sim-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.7rem;
}

.peek-mock__sim-team {
    font-weight: 600;
    color: var(--text-primary);
}

.peek-mock__sim-score {
    color: var(--text-secondary);
    font-size: 0.65rem;
}

.peek-mock__prob-bar {
    height: 8px;
    border-radius: 4px;
    display: flex;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.06);
}

.peek-mock__prob-fill--a {
    background: var(--cta-primary);
}

.peek-mock__prob-fill--b {
    background: rgba(239, 68, 68, 0.5);
}

.peek-mock__prob-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.6rem;
    color: var(--text-secondary);
}

/* -- Constellation / node graph mock -- */
.peek-mock--constellation {
    position: relative;
    height: 100%;
    min-height: 60px;
}

.peek-mock__node {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--cta-primary);
    position: absolute;
    opacity: 0.7;
}

.peek-mock__node--dim {
    opacity: 0.3;
    background: var(--text-secondary);
    width: 7px;
    height: 7px;
}

.peek-mock__edge {
    position: absolute;
    height: 1px;
    background: rgba(16, 185, 129, 0.25);
    transform-origin: left center;
}

/* -- Galaxy / transfer mock -- */
.peek-mock--galaxy {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
}

.peek-mock__school {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.peek-mock__school-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1.5px solid rgba(16, 185, 129, 0.4);
    background: rgba(16, 185, 129, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.5rem;
    color: var(--text-secondary);
}

.peek-mock__school-label {
    font-size: 0.5rem;
    color: var(--text-secondary);
}

.peek-mock__arrow {
    color: var(--cta-primary);
    font-size: 0.6rem;
    opacity: 0.6;
}

.peek-mock__transfer-count {
    font-size: 0.5rem;
    color: var(--cta-primary);
    background: rgba(16, 185, 129, 0.1);
    border-radius: 8px;
    padding: 0 4px;
}

/* -- Blog / Edge Report mock -- */
.peek-mock--blog {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.peek-mock__blog-title {
    height: 5px;
    width: 75%;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.12);
}

.peek-mock__blog-meta {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.peek-mock__blog-date {
    font-size: 0.55rem;
    color: var(--text-secondary);
    opacity: 0.6;
}

.peek-mock__blog-cat {
    font-size: 0.5rem;
    background: rgba(16, 185, 129, 0.1);
    color: var(--cta-primary);
    padding: 0 5px;
    border-radius: 6px;
}

.peek-mock__blog-line {
    height: 3px;
    border-radius: 1.5px;
    background: rgba(255, 255, 255, 0.06);
}

/* --------------------------------------------------------------------------
   Responsive — Tablet (2 columns)
   -------------------------------------------------------------------------- */

@media (max-width: 992px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bento-showcase {
        padding: 3rem 1rem;
    }
}

/* --------------------------------------------------------------------------
   Responsive — Mobile (1 column)
   -------------------------------------------------------------------------- */

@media (max-width: 576px) {
    .bento-grid {
        grid-template-columns: 1fr;
    }

    .bento-card--featured {
        grid-column: span 1;
    }

    .bento-card {
        padding: 1.25rem;
    }

    .bento-card__preview {
        height: 70px;
        margin: 0 -1.25rem -1.25rem;
        overflow: hidden;
    }

    .bento-card--featured .bento-card__preview {
        height: 80px;
        margin: 0 -1.25rem -1.25rem;
    }

    .peek-mock {
        padding: 0.75rem 1.25rem;
    }

    .bento-card--featured .peek-mock {
        padding: 0.75rem 1.25rem;
    }

    .bento-showcase {
        padding: 2.5rem 0.75rem;
    }
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
    .bento-card {
        transition: none;
    }

    .bento-card::before {
        transition: none;
    }

    .bento-card__cta i {
        transition: none;
    }

    .bento-card__preview {
        transition: none;
    }
}
