/* ---------------------------------------------------------------
   home-feed.css  —  "What's New" unified activity feed
   Scoped with .hf-* prefix. Uses theme CSS variables only.
   Created by ESAGAMES HOSTING SHIELD SRL
   v2 — pixel-perfect visual polish pass
--------------------------------------------------------------- */

/* ============================================================
   SECTION WRAPPER
   ============================================================ */
.hf-section {
    padding: 70px 0;
}

/* Section heading: "What's New" with a subtle live pulse dot */
.hf-section-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

/* The "live" pulse dot — a single small indicator, no heavy glow */
.hf-live-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--green);
    flex-shrink: 0;
    position: relative;
}

.hf-live-dot::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    background: rgba(46, 230, 166, 0.28);
    animation: hf-pulse 2.4s ease-in-out infinite;
}

@keyframes hf-pulse {
    0%, 100% { transform: scale(1);   opacity: .7; }
    50%       { transform: scale(1.5); opacity: 0;  }
}

/* ============================================================
   TIMELINE LIST
   ============================================================ */
.hf-timeline {
    display: flex;
    flex-direction: column;
    gap: 0;
    background: linear-gradient(145deg, var(--surface-2), var(--surface));
    border: 1px solid var(--border);
    border-radius: 18px;
    overflow: hidden;
}

/* ── Single feed row ── */
.hf-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-soft);
    text-decoration: none;
    color: inherit;
    position: relative;
    /* staggered entrance via CSS custom property */
    transition:
        background  0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
    animation: hf-fadein 0.38s var(--hf-delay, 0s) both;
}
.hf-item:hover {
    background: rgba(var(--primary-rgb), 0.07);
    border-color: rgba(var(--primary-rgb), 0.15);
    /* Subtle inset left bar to "lift" the row */
    box-shadow: inset 3px 0 0 var(--primary);
}

.hf-item:last-child {
    border-bottom: none;
}

/* Left accent line on hover (animating ::before, complementing inset box-shadow) */
.hf-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    border-radius: 0 2px 2px 0;
    background: var(--grad-primary);
    transform: scaleY(0);
    transform-origin: center;
    transition: transform 0.18s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hf-item:hover::before {
    transform: scaleY(1);
}

/* ── Icon bubble ── */
.hf-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(
        135deg,
        rgba(var(--primary-rgb), 0.22),
        rgba(var(--primary-rgb), 0.08)
    );
    border: 1px solid rgba(var(--primary-rgb), 0.18);
    display: grid;
    place-items: center;
    font-size: 18px;
    flex-shrink: 0;
    transition: transform 0.18s ease, background 0.18s ease;
}

.hf-item:hover .hf-item-icon {
    transform: scale(1.08);
    background: linear-gradient(
        135deg,
        rgba(var(--primary-rgb), 0.32),
        rgba(var(--primary-rgb), 0.14)
    );
}

/* ── Text body ── */
.hf-item-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.hf-item-text {
    font-size: 13.5px;
    color: var(--text-dim);
    line-height: 1.45;
    /* allow wrapping so long names don't overflow */
    word-break: break-word;
}

.hf-item-text b {
    color: #fff;
    font-weight: 600;
}

.hf-item-time {
    font-size: 11.5px;
    color: var(--text-mute);
    font-weight: 500;
    white-space: nowrap;
}

/* ── Right chevron ── */
.hf-item-arrow {
    font-size: 18px;
    color: var(--text-mute);
    flex-shrink: 0;
    transition: color 0.15s ease, transform 0.15s ease;
    margin-left: 4px;
    line-height: 1;
}

.hf-item:hover .hf-item-arrow {
    color: var(--primary-2);
    transform: translateX(3px);
}

/* ── Staggered entrance animation ── */
@keyframes hf-fadein {
    from {
        opacity: 0;
        transform: translateX(-12px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ============================================================
   EMPTY STATE
   ============================================================ */
.hf-empty {
    text-align: center;
    padding: 52px 20px;
    color: var(--text-mute);
    font-size: 14px;
    background: linear-gradient(145deg, var(--surface-2), var(--surface));
    border: 1px solid var(--border);
    border-radius: 18px;
}

.hf-empty-ico {
    font-size: 38px;
    margin-bottom: 12px;
    display: block;
}

.hf-empty p {
    margin: 0 0 18px;
    color: var(--text-dim);
}

/* ============================================================
   DESKTOP ENHANCEMENT — 1280px+
   ============================================================ */
@media (min-width: 1280px) {
    .hf-section {
        padding: 80px 0;
    }

    .hf-item {
        padding: 18px 26px;
        gap: 18px;
    }

    .hf-item-icon {
        width: 46px;
        height: 46px;
        font-size: 20px;
        border-radius: 14px;
    }

    .hf-item-text {
        font-size: 14.5px;
    }

    .hf-item-time {
        font-size: 12.5px;
    }

    .hf-item-arrow {
        font-size: 20px;
    }

    .hf-timeline {
        border-radius: 20px;
    }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* ── 768 px — tablet ── */
@media (max-width: 768px) {
    .hf-section {
        padding: 56px 0;
    }

    .hf-item {
        padding: 14px 18px;
    }
}

/* ── 600 px — large phone ── */
@media (max-width: 600px) {
    .hf-section {
        padding: 48px 0;
    }

    .hf-item {
        padding: 13px 16px;
        gap: 11px;
    }

    .hf-item-icon {
        width: 36px;
        height: 36px;
        font-size: 16px;
        border-radius: 10px;
    }

    .hf-item-text {
        font-size: 13px;
    }

    .hf-item-arrow {
        display: none; /* save space on small screens */
    }
}

/* ── 480 px — small phone ── */
@media (max-width: 480px) {
    .hf-section {
        padding: 40px 0;
    }

    .hf-item {
        padding: 12px 14px;
        gap: 10px;
    }

    .hf-item-icon {
        width: 34px;
        height: 34px;
        font-size: 15px;
        border-radius: 9px;
    }

    .hf-item-text {
        font-size: 12.5px;
    }

    .hf-item-time {
        font-size: 11px;
    }

    .hf-timeline {
        border-radius: 14px;
    }

    .hf-empty {
        padding: 40px 16px;
        border-radius: 14px;
    }
}

/* ── 360 px — very small phone ── */
@media (max-width: 380px) {
    .hf-item {
        padding: 11px 12px;
        gap: 9px;
    }

    .hf-item-icon {
        width: 30px;
        height: 30px;
        font-size: 14px;
        border-radius: 8px;
    }

    .hf-item-text {
        font-size: 12px;
    }
}

/* ============================================================
   PREFERS-REDUCED-MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    .hf-live-dot::after {
        animation: none;
    }

    .hf-item,
    .hf-item::before,
    .hf-item-icon,
    .hf-item-arrow {
        transition: none !important;
        animation: none !important;
    }
}
