/* Magazine Widgets Pro Styling */

/* Trending List */
.myfoly-trending-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.myfoly-trending-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.trending-rank {
    font-size: 1.8rem;
    font-weight: 900;
    color: #6366f1;
    line-height: 1;
    min-width: 40px;
    text-align: center;
}

.trending-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.trending-title {
    color: #ffffff;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    line-height: 1.3;
    transition: color 0.2s ease;
}

.trending-title:hover {
    color: #a855f7;
}

.trending-date {
    font-size: 0.8rem;
    color: #8b949e;
}

/* Social Grid */
.myfoly-social-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.social-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 10px;
    border-radius: 8px;
    text-decoration: none;
    color: #ffffff !important;
    font-size: 0.85rem;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.social-box:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}

.social-box i {
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.social-count {
    font-weight: 700;
    font-size: 1rem;
}

.social-name {
    font-size: 0.75rem;
    opacity: 0.8;
}

.social-box.fb { background: #1877f2; }
.social-box.tw { background: #1da1f2; }
.social-box.ig { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.social-box.yt { background: #ff0000; }

/* Newsletter Card */
.myfoly-newsletter-card {
    background: linear-gradient(135deg, #6366f1, #a855f7);
    padding: 25px;
    border-radius: 12px;
    color: #ffffff;
    text-align: center;
}

.newsletter-card-title {
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: #ffffff;
}

.newsletter-card-desc {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 18px;
}

.newsletter-card-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.newsletter-card-form input[type="email"] {
    width: 100%;
    padding: 12px 15px;
    border-radius: 6px;
    border: none;
    outline: none;
    font-size: 0.9rem;
    box-sizing: border-box;
}

.newsletter-card-form button[type="submit"] {
    padding: 12px;
    background: #0d1117;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

.newsletter-card-form button[type="submit"]:hover {
    background: #161b22;
}

/* Author Spotlight */
.myfoly-author-card {
    background: #161b22;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.author-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 12px;
    border: 2px solid #a855f7;
}

.author-name {
    color: #ffffff;
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.author-bio {
    color: #8b949e;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ==========================================================================
   Single Post: Category Badge Over Featured Image
   ========================================================================== */
.myfoly-single-post__thumb {
    position: relative;
    overflow: hidden;
    border-radius: var(--myfoly-radius, 10px);
    margin-block: 20px 30px;
}

.myfoly-single-thumb-cats {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 10;
}

/* ==========================================================================
   Automatic Table of Contents (TOC) Styling
   ========================================================================== */
.myfoly-toc-box {
    background: var(--myfoly-surface, #f7f7f9);
    border: 1px solid var(--myfoly-border, #e6e6ea);
    border-left: 4px solid var(--myfoly-accent, #e63946);
    border-radius: 8px;
    padding: 20px 24px;
    margin-block: 24px 32px;
}

.myfoly-toc-box .toc-header {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--myfoly-ink, #17181c);
}

.myfoly-toc-box .toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.myfoly-toc-box .toc-item a {
    color: var(--myfoly-ink-soft, #4b4d55);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.myfoly-toc-box .toc-item a:hover {
    color: var(--myfoly-accent, #e63946);
    text-decoration: underline;
}

.myfoly-toc-box .toc-item.level-3 {
    margin-left: 16px;
    font-size: 0.9rem;
}

/* ==========================================================================
   In-Article "Read More:" Same Tag Link Box Styling
   ========================================================================== */
.myfoly-inarticle-readmore {
    display: flex;
    align-items: center;
    gap: 12px;
    background: color-mix(in srgb, var(--myfoly-accent, #e63946) 8%, transparent);
    border-left: 4px solid var(--myfoly-accent, #e63946);
    padding: 14px 20px;
    border-radius: 6px;
    margin-block: 28px;
    font-size: 0.98rem;
    font-weight: 600;
}

.myfoly-inarticle-readmore .readmore-label {
    color: var(--myfoly-accent, #e63946);
    text-transform: uppercase;
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

.myfoly-inarticle-readmore .readmore-link {
    color: var(--myfoly-ink, #17181c);
    text-decoration: none;
    transition: color 0.2s ease;
}

.myfoly-inarticle-readmore .readmore-link:hover {
    color: var(--myfoly-accent, #e63946);
    text-decoration: underline;
}
