/* Novellesiden (single.php). Flyttet ud af skabelonen, så browseren kan cache den. */
/* --- Titel, rating og tags øverst --- */
                /* Overstyrer margin fra style.css så rating sidder flot og tæt under titlen */
                .story-title {
                    margin-bottom: 12px !important;
                }
                
                /* Det centrale metadata-panel lige under overskriften */
                .tf-story-read-time-container {
                    display: flex;
                    justify-content: center;
                    align-items: center;
                    font-size: 0.85em;
                    margin-bottom: 25px; /* Luft ned til kategorierne */
                    letter-spacing: 0.5px;
                }
                .tf-read-time {
                    opacity: 0.7;
                    text-transform: uppercase;
                }
                .tf-top-rating {
                    color: var(--accent-purple);
                    font-weight: 600;
                    transition: opacity 0.2s ease;
                }
                .tf-top-rating:hover {
                    opacity: 0.7;
                }
                .tf-meta-divider {
                    margin: 0 10px;
                    color: var(--border-color);
                    opacity: 0.5;
                }

                /* Kategoripiller placeret under rating */
                .tf-story-top-categories {
                    display: flex;
                    flex-wrap: wrap;
                    justify-content: center;
                    gap: 8px;
                    margin-bottom: 10px;
                }

                /* Styling til inline tags placeret i toppen */
                .tf-story-tags-top-inline {
                    display: flex;
                    justify-content: center;
                    flex-wrap: wrap;
                    gap: 12px;
                    margin-top: 8px;
                    margin-bottom: 25px;
                }
                
                .tf-story-tags-top-inline .tf-tag-link {
                    background-color: transparent !important;
                    padding: 0 !important;
                    color: var(--accent-purple) !important;
                    font-weight: 600;
                    font-size: 0.9em;
                    letter-spacing: 0.5px;
                    opacity: 0.85;
                    text-decoration: none;
                    transition: opacity 0.2s ease, color 0.2s ease;
                }
                
                .tf-story-tags-top-inline .tf-tag-link:hover {
                    opacity: 1;
                    color: var(--text-main) !important;
                }
                
                /* CSS for smooth scrolling when clicking the top rating */
                html {
                    scroll-behavior: smooth;
                }
/* --- Lydafspiller --- */
                /* Fikset Pause-ikon (matematisk centreret) */
                .play-btn.playing::after {
                    border: none !important; 
                    width: 14px; 
                    height: 16px;
                    border-left: 4px solid #ffffff !important;
                    border-right: 4px solid #ffffff !important;
                    background-color: transparent !important;
                    box-shadow: none !important;
                    margin-left: 0 !important; 
                    box-sizing: border-box;
                }
                    .podcast-player { 
                        margin-bottom: 15px !important; 
                    }

                    .subscribe-box-icons {
                        background-color: transparent;
                        border: 1px solid var(--border-color);
                        border-radius: 12px;
                        padding: 15px 20px;
                        text-align: center;
                        font-family: var(--font-sans), Arial, sans-serif;
                        margin-bottom: 3rem;
                        box-sizing: border-box;
                    }
                    
                    .subscribe-text-icons {
                        margin: 0 0 15px 0;
                        font-weight: 600;
                        color: var(--text-main);
                        font-size: 0.95rem;
                        display: block;
                    }
                    
                    .subscribe-buttons-icons {
                        display: flex;
                        justify-content: center;
                        align-items: center;
                        flex-wrap: wrap; 
                        gap: 12px; 
                    }
                    
                    .btn-icon {
                        display: inline-flex;
                        align-items: center;
                        justify-content: center;
                        text-decoration: none;
                        height: 40px;
                        padding: 0 20px;
                        border-radius: 20px; 
                        font-size: 0.85rem;
                        font-weight: 600;
                        color: white !important;
                        box-sizing: border-box;
                        transition: transform 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease;
                    }
                    
                    .btn-icon:hover {
                        transform: translateY(-2px);
                        box-shadow: 0 4px 12px rgba(0,0,0,0.15);
                    }

                    .btn-icon svg {
                        width: 18px;
                        height: 18px;
                        margin-right: 8px;
                        fill: currentColor; 
                    }

                    .brand-spotify { 
                        background-color: #1DB954; 
                    }
                    
                    .brand-apple { 
                        background-color: #000000; 
                    }
                    .dark-mode .brand-apple { 
                        background-color: #ffffff; 
                        color: #000000 !important; 
                    }

                    .tf-more-platforms-btn {
                        background: none;
                        border: none;
                        color: var(--accent-purple);
                        font-family: var(--font-sans), Arial, sans-serif;
                        font-size: 0.85rem;
                        font-weight: 600;
                        cursor: pointer;
                        padding: 0 10px;
                        text-decoration: none;
                        transition: color 0.2s;
                    }
                    
                    .tf-more-platforms-btn:hover {
                        color: var(--accent-hover);
                        text-decoration: underline;
                    }

                    .tf-extra-platforms {
                        display: none;
                        width: 100%;
                        margin-top: 15px;
                        padding-top: 15px;
                        border-top: 1px solid var(--border-color);
                        text-align: left;
                        animation: tfFadeInDown 0.3s ease forwards;
                    }
                    
                    .tf-extra-platforms.is-visible {
                        display: flex;
                        flex-wrap: wrap;
                        gap: 15px;
                        justify-content: center;
                    }
                    
                    .tf-extra-platforms a {
                        color: var(--text-muted);
                        text-decoration: none;
                        font-size: 0.85rem;
                        font-weight: 500;
                        transition: color 0.2s;
                    }
                    
                    .tf-extra-platforms a:hover {
                        color: var(--accent-purple);
                    }

                    @keyframes tfFadeInDown {
                        from { opacity: 0; transform: translateY(-5px); }
                        to { opacity: 1; transform: translateY(0); }
                    }

                    @media(min-width: 768px) {
                        .subscribe-box-icons {
                            text-align: left;
                            display: flex;
                            flex-wrap: wrap;
                            align-items: center;
                            justify-content: space-between;
                        }
                        .subscribe-text-icons {
                            margin: 0;
                            flex: 1;
                            min-width: max-content;
                        }
                        .subscribe-buttons-icons {
                            flex: 2;
                            justify-content: flex-end;
                        }
                        .tf-extra-platforms.is-visible {
                            justify-content: flex-end;
                        }
                    }

/* --- MERE SOM DENNE --- */
/* Bryder ud af den smalle læsekolonne (720px), så fire kort kan stå på række */
.tf-related {
    width: min(1200px, calc(100vw - 3rem));
    margin-left: calc(50% - min(600px, 50vw - 1.5rem));
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(169, 103, 191, 0.2);
}
.tf-related-title {
    font-family: var(--font-serif);
    text-align: center;
    font-size: 1.9rem;
    margin: 0 0 2rem;
}
.tf-related-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
    margin-bottom: 0;
}
@media (max-width: 1100px) {
    .tf-related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .tf-related-grid { grid-template-columns: 1fr; }
}

/* Kom man fra ▶ på et kort (#listen), men browseren blokerede autoplay: play-knappen pulserer */
@keyframes tf-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(148, 86, 171, 0.55); } 50% { box-shadow: 0 0 0 12px rgba(148, 86, 171, 0); } }
.play-btn.tf-pulse { animation: tf-pulse 1.4s ease-out infinite; }

/* "Continuing from 12:34 · Start from the beginning" under afspilleren (Continue listening) */
.tf-resume-note { margin: 0.6rem 0 0; font-size: 0.85rem; color: var(--text-muted); text-align: center; }
.tf-resume-note button {
    -webkit-appearance: none; appearance: none; background: none; border: 0; padding: 0; min-height: 0; box-shadow: none;
    font: inherit; color: var(--accent-purple); font-weight: 600; cursor: pointer; text-decoration: underline;
}
