/*
Theme Name: GospoHot
Theme URI: https://gospohot.com/
Author: GospoHot
Author URI: https://gospohot.com/
Description: Lightweight, SEO-first music download theme for GospoHot. Zero page builder, no jQuery dependency, built-in sticky audio player, automatic internal linking, MusicRecording schema and IndexNow instant indexing. Built to replace Newsmag/tagDiv Composer.
Version: 1.1.0
Requires at least: 6.2
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: gospohot
*/

/* ============================================================
   Design tokens
   ============================================================ */
:root {
    --gh-primary: #16161a;          /* near-black text / headings */
    --gh-accent: #dd3302;           /* GospoHot orange-red (change in Customizer) */
    --gh-accent-ink: #ffffff;
    --gh-bg: #f2f3f5;               /* page background */
    --gh-card: #ffffff;
    --gh-muted: #6b7280;
    --gh-border: #e6e7eb;
    --gh-footer-bg: #0f0f10;
    --gh-footer-ink: #b9b9c0;
    --gh-radius: 12px;
    --gh-shadow: 0 4px 18px rgba(0, 0, 0, .06);
    --gh-shadow-lg: 0 10px 40px rgba(0, 0, 0, .14);
    --gh-container: 1180px;
    --gh-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

/* ============================================================
   Reset / base
   ============================================================ */
* , *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--gh-font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--gh-primary);
    background: var(--gh-bg);
}
img, svg, video { max-width: 100%; height: auto; vertical-align: middle; }
a { color: var(--gh-accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; font-weight: 700; color: var(--gh-primary); }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 1rem; }
ul { padding-left: 1.25rem; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--gh-accent); outline-offset: 2px; }

.gh-container { width: 100%; max-width: var(--gh-container); margin: 0 auto; padding: 0 16px; }
.screen-reader-text {
    position: absolute !important; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 8px; top: 8px; background: #fff; padding: 10px 16px; z-index: 100000; border-radius: 8px; }

/* ============================================================
   Header / navigation
   ============================================================ */
.gh-header {
    position: sticky; top: 0; z-index: 900;
    background: #fff;
    border-bottom: 1px solid var(--gh-border);
}
.gh-header__bar {
    display: flex; align-items: center; gap: 16px;
    min-height: 62px;
}
.gh-brand { display: inline-flex; align-items: center; font-weight: 800; font-size: 1.25rem; color: var(--gh-primary); }
.gh-brand img { max-height: 42px; width: auto; }
.gh-brand:hover { text-decoration: none; }
.custom-logo-link { display: inline-flex; align-items: center; }
.custom-logo { max-height: 44px; width: auto; }

.gh-nav { margin-left: auto; }
.gh-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.gh-nav a {
    display: block; padding: 8px 12px; color: var(--gh-primary); font-weight: 600; font-size: .95rem;
    border-radius: 8px;
}
.gh-nav a:hover { background: var(--gh-bg); text-decoration: none; }
.gh-nav .current-menu-item > a { color: var(--gh-accent); }

.gh-nav-toggle {
    display: none; margin-left: auto; background: none; border: 1px solid var(--gh-border);
    border-radius: 8px; width: 42px; height: 42px; align-items: center; justify-content: center;
}
.gh-nav-toggle span, .gh-nav-toggle span::before, .gh-nav-toggle span::after {
    content: ""; display: block; width: 20px; height: 2px; background: var(--gh-primary); position: relative;
}
.gh-nav-toggle span::before { position: absolute; top: -6px; }
.gh-nav-toggle span::after { position: absolute; top: 6px; }

@media (max-width: 860px) {
    .gh-nav-toggle { display: inline-flex; }
    .gh-nav {
        position: absolute; left: 0; right: 0; top: 100%;
        background: #fff; border-bottom: 1px solid var(--gh-border);
        display: none; padding: 8px 16px 16px;
    }
    .gh-nav.is-open { display: block; }
    .gh-nav ul { flex-direction: column; gap: 2px; }
    .gh-nav a { padding: 12px; border-radius: 8px; }
}

/* ============================================================
   Hero search
   ============================================================ */
.gh-hero { background: #fff; border-bottom: 1px solid var(--gh-border); padding: 22px 0; }
.gh-hero__inner { max-width: 640px; margin: 0 auto; text-align: center; }
.gh-search { position: relative; }
.gh-search form { display: flex; box-shadow: var(--gh-shadow); border: 1px solid var(--gh-border); border-radius: 999px; overflow: hidden; background: #fff; }
.gh-search input[type="search"] {
    flex: 1; border: 0; padding: 14px 18px; font-size: 1rem; outline: none; background: transparent; min-width: 0;
}
.gh-search button {
    border: 0; background: var(--gh-accent); color: var(--gh-accent-ink);
    padding: 0 22px; font-weight: 700; border-radius: 999px; margin: 4px;
}
.gh-search__results {
    position: absolute; left: 0; right: 0; top: calc(100% + 8px);
    background: #fff; border: 1px solid var(--gh-border); border-radius: var(--gh-radius);
    box-shadow: var(--gh-shadow-lg); text-align: left; overflow: hidden; z-index: 50; display: none;
}
.gh-search__results.is-open { display: block; }
.gh-search__results a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; color: var(--gh-primary); border-bottom: 1px solid var(--gh-border); }
.gh-search__results a:last-child { border-bottom: 0; }
.gh-search__results a:hover { background: var(--gh-bg); text-decoration: none; }
.gh-search__results img { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; flex: 0 0 44px; }
.gh-discover { margin-top: 12px; font-size: .85rem; color: var(--gh-muted); }
.gh-discover a { color: var(--gh-muted); margin: 0 6px; border-bottom: 1px solid var(--gh-border); }

/* ============================================================
   Layout: content + sidebar
   ============================================================ */
.gh-layout { display: grid; grid-template-columns: 1fr 320px; gap: 34px; padding: 24px 0 48px; }
.gh-content { min-width: 0; }
@media (max-width: 980px) { .gh-layout { grid-template-columns: 1fr; } }

.gh-searchform { display: flex; gap: 6px; }
.gh-searchform input { flex: 1; padding: 8px 12px; border: 1px solid var(--gh-border); border-radius: 8px; min-width: 0; }
.gh-searchform button { border: 0; background: var(--gh-accent); color: #fff; border-radius: 8px; padding: 0 14px; font-weight: 600; }
.gh-archive-desc { color: var(--gh-muted); margin-bottom: 18px; }
.gh-comments { margin-top: 26px; }
.gh-comment-list { list-style: none; padding: 0; }
.gh-comment-list ul { list-style: none; }

.gh-section-title {
    font-size: 1.15rem; margin-bottom: 18px; position: relative; padding-bottom: 8px;
}
.gh-section-title::after { content: ""; position: absolute; left: 0; bottom: 0; width: 46px; height: 3px; background: var(--gh-accent); border-radius: 3px; }

/* ============================================================
   Card grid
   ============================================================ */
.gh-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .gh-grid { grid-template-columns: 1fr; } }

.gh-card {
    display: flex; background: var(--gh-card); border-radius: var(--gh-radius);
    box-shadow: var(--gh-shadow); overflow: hidden; min-height: 116px;
    transition: box-shadow .25s ease, transform .25s ease;
}
.gh-card:hover { box-shadow: var(--gh-shadow-lg); transform: translateY(-2px); }
.gh-card__media { position: relative; flex: 0 0 116px; width: 116px; background: #ddd; overflow: hidden; }
.gh-card__media img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    transition: transform .5s cubic-bezier(.2, .7, .2, 1);
}
.gh-card:hover .gh-card__media img,
.gh-card:focus-within .gh-card__media img,
.gh-card:active .gh-card__media img { transform: scale(1.09); }
.gh-card__body { padding: 12px 14px; display: flex; flex-direction: column; justify-content: center; gap: 6px; min-width: 0; }
.gh-tag {
    display: inline-block; align-self: flex-start; background: var(--gh-accent); color: #fff;
    font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px;
    padding: 3px 8px; border-radius: 5px;
}
.gh-tag:hover { text-decoration: none; opacity: .9; }
.gh-card__title { font-size: .98rem; margin: 0; line-height: 1.35; }
.gh-card__title a { color: var(--gh-primary); }
.gh-card__title a:hover { color: var(--gh-accent); text-decoration: none; }

/* Play button overlay */
.gh-play {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .95);
    color: var(--gh-accent); display: flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, .35);
    transition: transform .18s ease, background-color .18s ease;
    animation: gh-pulse 2.4s ease-out infinite;
}
.gh-card:hover .gh-play,
.gh-play:hover { transform: translate(-50%, -50%) scale(1.12); background: #fff; animation-play-state: paused; }
.gh-play:active { transform: translate(-50%, -50%) scale(.96); }
.gh-play svg { width: 20px; height: 20px; fill: currentColor; }

@keyframes gh-pulse {
    0%   { box-shadow: 0 6px 20px rgba(0, 0, 0, .35), 0 0 0 0 rgba(221, 51, 2, .45); }
    70%  { box-shadow: 0 6px 20px rgba(0, 0, 0, .35), 0 0 0 14px rgba(221, 51, 2, 0); }
    100% { box-shadow: 0 6px 20px rgba(0, 0, 0, .35), 0 0 0 0 rgba(221, 51, 2, 0); }
}

/* ============================================================
   Single post
   ============================================================ */
.gh-breadcrumb { font-size: .82rem; color: var(--gh-muted); margin-bottom: 12px; }
.gh-breadcrumb a { color: var(--gh-muted); }

.gh-post { background: var(--gh-card); border-radius: var(--gh-radius); box-shadow: var(--gh-shadow); overflow: hidden; }
.gh-post__inner { padding: 22px; }
@media (max-width: 560px) { .gh-post__inner { padding: 16px; } }
.gh-post__title { font-size: 1.5rem; margin-bottom: 10px; }
.gh-post__meta { display: flex; flex-wrap: wrap; gap: 14px; font-size: .82rem; color: var(--gh-muted); margin-bottom: 16px; }
.gh-post__meta strong { color: var(--gh-primary); }
.gh-post__cover {
    border-radius: var(--gh-radius); overflow: hidden; margin: 0 auto 18px;
    max-width: 520px; width: 100%;
}
.gh-post__cover img { display: block; width: 100%; transition: transform .55s cubic-bezier(.2, .7, .2, 1); }
.gh-post__cover:hover img { transform: scale(1.04); }

.gh-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0; }
.gh-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 11px 22px; border-radius: 999px;
    font-weight: 700; font-size: .95rem; border: 0;
}
.gh-btn--play { background: var(--gh-primary); color: #fff; }
.gh-btn--dl { background: var(--gh-accent); color: #fff; }
.gh-btn:hover { text-decoration: none; opacity: .92; }
.gh-btn svg { width: 18px; height: 18px; fill: currentColor; }

.gh-entry { font-size: 1rem; line-height: 1.7; }
.gh-entry img { border-radius: 8px; height: auto; }
.gh-entry h2 { font-size: 1.25rem; margin-top: 1.4em; }
.gh-entry h3 { font-size: 1.08rem; margin-top: 1.2em; }
.gh-entry a[href$=".mp3"], .gh-entry .wp-block-button__link {
    display: inline-block; background: var(--gh-primary); color: #fff !important;
    padding: 8px 18px; border-radius: 999px; font-weight: 600; text-decoration: none;
}
.gh-entry audio, .gh-entry .wp-block-audio { width: 100%; margin: 1rem 0; }
.gh-entry table { width: 100%; border-collapse: collapse; }
.gh-entry th, .gh-entry td { border: 1px solid var(--gh-border); padding: 8px 10px; }

.gh-lyrics { margin-top: 24px; border-top: 1px solid var(--gh-border); padding-top: 18px; white-space: pre-wrap; font-size: .96rem; }

.gh-tags { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 8px; }
.gh-tags a { background: var(--gh-bg); border-radius: 999px; padding: 6px 12px; font-size: .8rem; color: var(--gh-primary); font-weight: 600; }
.gh-tags a:hover { text-decoration: none; background: var(--gh-border); }

.gh-share { display: flex; gap: 10px; margin-top: 20px; }
.gh-share a, .gh-share button {
    width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center;
    justify-content: center; color: #fff; border: 0;
}
.gh-share svg { width: 20px; height: 20px; fill: currentColor; }
.gh-share .is-fb { background: #1877f2; }
.gh-share .is-wa { background: #25d366; }
.gh-share .is-x { background: #000; }
.gh-share .is-copy { background: var(--gh-muted); font-size: 10px; font-weight: 700; }

.gh-nextprev { display: flex; justify-content: space-between; gap: 16px; margin-top: 24px; font-size: .9rem; }
.gh-nextprev span { display: block; color: var(--gh-muted); font-size: .78rem; }

.gh-related { margin-top: 30px; }
.gh-related .gh-grid { grid-template-columns: 1fr 1fr; }
@media (max-width: 560px) { .gh-related .gh-grid { grid-template-columns: 1fr; } }

/* ============================================================
   Sidebar widgets
   ============================================================ */
.gh-widget { background: var(--gh-card); border-radius: var(--gh-radius); box-shadow: var(--gh-shadow); padding: 18px; margin-bottom: 22px; }
.gh-widget__title { font-size: 1rem; margin-bottom: 14px; padding-bottom: 8px; border-bottom: 2px solid var(--gh-bg); }
.gh-widget ul { list-style: none; margin: 0; padding: 0; }
.gh-mini { display: flex; gap: 12px; align-items: center; padding: 8px 0; color: var(--gh-primary); }
.gh-mini:hover { text-decoration: none; color: var(--gh-accent); }
.gh-mini img {
    width: 60px; height: 60px; object-fit: cover; border-radius: 10px; flex: 0 0 60px;
    transition: transform .35s ease;
}
.gh-mini:hover img { transform: scale(1.06); }
.gh-mini span { font-size: .9rem; font-weight: 600; line-height: 1.35; }

/* ============================================================
   Pagination
   ============================================================ */
.pagination, .gh-pagination { margin-top: 30px; }
.pagination .nav-links, .gh-pagination .nav-links { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.pagination .page-numbers, .gh-pagination .page-numbers {
    display: inline-flex; min-width: 40px; height: 40px; align-items: center; justify-content: center;
    padding: 0 10px; border-radius: 8px; background: #fff; border: 1px solid var(--gh-border);
    color: var(--gh-primary); font-weight: 600;
}
.pagination .page-numbers.current, .gh-pagination .page-numbers.current { background: var(--gh-accent); color: #fff; border-color: var(--gh-accent); }
.pagination a.page-numbers:hover, .gh-pagination a.page-numbers:hover { text-decoration: none; border-color: var(--gh-accent); }

/* ============================================================
   Footer
   ============================================================ */
.gh-footer { background: var(--gh-footer-bg); color: var(--gh-footer-ink); padding: 26px 0; margin-top: 30px; text-align: center; font-size: .9rem; }
.gh-footer__copy { line-height: 2; }
.gh-footer__copy a { color: #fff; white-space: nowrap; }
.gh-footer__copy a:hover { color: var(--gh-accent); text-decoration: none; }

/* ============================================================
   Sticky audio player
   ============================================================ */
.gh-player {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 9999;
    background: rgba(17, 17, 19, .98); color: #fff; backdrop-filter: blur(8px);
    border-top: 1px solid rgba(255, 255, 255, .08); transform: translateY(100%);
    transition: transform .25s ease;
}
.gh-player.is-visible { transform: translateY(0); }
.gh-player__inner { display: flex; align-items: center; gap: 14px; height: 74px; }
.gh-player__thumb { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; background: #333; flex: 0 0 48px; }
.gh-player__info { min-width: 0; flex: 0 1 200px; }
.gh-player__title { display: block; font-weight: 700; font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gh-player__artist { display: block; font-size: .72rem; color: rgba(255, 255, 255, .6); }
.gh-player__controls { display: flex; align-items: center; gap: 6px; }
.gh-player__controls button { background: none; border: 0; color: rgba(255, 255, 255, .8); display: flex; padding: 8px; }
.gh-player__controls button svg { width: 20px; height: 20px; fill: currentColor; }
.gh-player__play { background: #fff !important; color: var(--gh-primary) !important; width: 42px; height: 42px; border-radius: 50%; align-items: center; justify-content: center; }
.gh-player__bar-wrap { flex: 1; display: flex; align-items: center; gap: 8px; font-size: .7rem; color: rgba(255, 255, 255, .6); }
.gh-player__bar { flex: 1; height: 4px; background: rgba(255, 255, 255, .15); border-radius: 2px; cursor: pointer; position: relative; overflow: hidden; }
.gh-player__bar-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--gh-accent); }
.gh-player__close { background: none; border: 0; color: rgba(255, 255, 255, .7); padding: 8px; display: flex; }
.gh-player__close svg { width: 16px; height: 16px; }
.gh-player__time { font-variant-numeric: tabular-nums; min-width: 38px; }

@media (max-width: 700px) {
    .gh-player__bar-wrap, .gh-player__artist { display: none; }
    .gh-player__inner { height: 62px; gap: 10px; }
    .gh-player__info { flex: 1; }
}

/* Give the body room so the fixed player never covers footer links */
body.gh-player-open { padding-bottom: 74px; }

/* ============================================================
   Respect users who ask for less motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
        scroll-behavior: auto !important;
    }
}
