/* ===== coinbix-single.css ===== */
/* Single post template — single.php only */

/* Breadcrumb — hidden visually, Schema output only for SEO */

/* ===== :root variables — sp- prefix ===== */
:root {
    --sp-surface:                #0a1325;
    --sp-surface-container-low:  #0e1a30;
    --sp-surface-container:      #12213b;
    --sp-surface-container-high: #172846;
    --sp-surface-container-highest: #1c3050;
    --sp-surface-variant:        #2c3548;
    --sp-surface-bright:         #1e3558;
    --sp-surface-container-lowest: #050e20;
    --sp-gold:        #f2c35b;
    --sp-gold-mid:    #d4a843;
    --sp-gold-dark:   #b8923a;
    --sp-gold-glow:   rgba(242,195,91,0.08);
    --sp-green:       #4ae176;
    --sp-red:         #e74c3c;
    --sp-text:        #FFFFFF;
    --sp-text-secondary: #c0c8d8;
    --sp-text-muted:  #8B9DB7;
    --sp-text-dim:    #4A5F7A;
    --sp-text-disabled: #3A4A5E;
    --sp-ghost:       rgba(255,255,255,0.05);
    --sp-divider: rgba(255,255,255,0.1);
    --sp-max: 1200px;
}

/* Reset & Base */
body.single {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    background: var(--sp-surface) !important;
    color: var(--sp-text) !important;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
/* GP reset handled by functions.php coinbix-gp-reset */
body.single { background: var(--sp-surface) !important; }

.sp-wrapper { width:100%!important; max-width:none!important; margin:0!important; padding:0!important; }
.sp-wrapper a { text-decoration: none; color: inherit; }
.sp-wrapper img { max-width: 100%; height: auto; }

/* ===== ARTICLE HERO (full-width bg image + overlay) ===== */
.sp-article-hero {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    min-height: 540px;
    display: flex;
    align-items: flex-end;
    margin-top: -120px;
    padding-top: 180px;
    margin-bottom: 48px;
    overflow: hidden;
}
.sp-article-hero-bg {
    position: absolute; inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
}
.sp-article-hero-overlay {
    position: absolute; inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1;
}
.sp-article-hero-content {
    position: relative; z-index: 2;
    max-width: var(--sp-max);
    margin: 0 auto;
    padding: 60px 32px 48px;
    width: 100%;
}
.sp-main { max-width: var(--sp-max); margin: 0 auto; padding: 0 32px 80px; }
.sp-cat-badge {
    display: inline-block; padding: 4px 14px;
    background: rgba(242,195,91,0.2); color: var(--sp-gold);
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 2px; border-radius: 20px; margin-bottom: 20px;
}
.sp-article-title {
    font-family: 'Inter', sans-serif;
    font-size: 32px; font-weight: 700; line-height: 1.2;
    letter-spacing: -0.02em; color: #fff; margin-bottom: 28px;
    max-width: 800px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.sp-meta-row {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: 16px; padding: 0;
}
.sp-author-block { display: flex; align-items: center; gap: 12px; }
.sp-author-avatar {
    width: 44px; height: 44px; border-radius: 50%; object-fit: cover;
    border: 2px solid rgba(255,255,255,0.3);
}
.sp-author-name { font-weight: 600; color: #fff; }
.sp-author-date { font-size: 14px; color: rgba(255,255,255,0.7); }
.sp-share-row { display: flex; gap: 8px; }
.sp-share-btn {
    width: 40px; height: 40px; border-radius: 50%;
    background: rgba(255,255,255,0.1); display: flex; align-items: center;
    justify-content: center; color: rgba(255,255,255,0.7); transition: all 200ms ease; cursor: pointer;
    backdrop-filter: blur(8px);
}
.sp-share-btn:hover { background: rgba(255,255,255,0.2); color: #fff; }

/* ===== BODY LAYOUT ===== */
.sp-body-layout { display: flex; gap: 64px; max-width: var(--sp-max); margin: 0 auto; }
.sp-article-body { flex: 1; max-width: 760px; }
.sp-sidebar { width: 320px; flex-shrink: 0; }

/* ===== ARTICLE CONTENT ===== */
.sp-content { font-size: 18px; line-height: 1.8; color: #FFFFFF; }
.sp-content p { margin-bottom: 24px; }
.sp-content > p:first-of-type::first-letter {
    font-family: 'Inter', sans-serif;
    font-size: 3.5em; float: left; margin-right: 12px; margin-top: 4px;
    color: var(--sp-gold); line-height: 0.8;
}
/* 2026-04-28 fix: drop cap을 .sp-content 직계 첫 <p>에만 적용 (이전 .sp-key-takeaways 내부 K가 drop cap 받던 버그 차단) */
.sp-content h2 {
    font-family: 'Inter', sans-serif;
    font-size: 24px; font-weight: 700; color: var(--sp-text); margin: 48px 0 16px;
    letter-spacing: -0.02em;
}
.sp-content h3 {
    font-size: 20px; font-weight: 700; color: var(--sp-text);
    margin: 28px 0 8px;
}
.sp-content h3 + p { margin-top: 4px; }
.sp-content blockquote {
    background: var(--sp-surface-container-low); padding: 32px;
    border-radius: 12px; border-left: 4px solid rgba(242,195,91,0.2);
    font-family: 'Inter', sans-serif;
    font-size: 20px; color: var(--sp-gold); margin: 40px 0;
}
.sp-content a { color: var(--sp-gold); text-decoration: underline !important; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.sp-content a:hover { color: var(--sp-gold); }
.sp-content ul, .sp-content ol { margin: 16px 0; padding-left: 24px; }
.sp-content li { margin-bottom: 8px; }
.sp-content img { border-radius: 12px; margin: 32px 0; }

/* ===== INLINE CTA ===== */
.sp-inline-cta {
    background: var(--sp-surface-container); border-radius: 12px;
    padding: 32px; margin: 48px 0;
    border-left: 4px solid var(--sp-gold);
    display: flex; flex-wrap: wrap; align-items: center; gap: 24px;
}
.sp-inline-cta-body { flex: 1; min-width: 200px; }
.sp-inline-cta-title {
    font-family: 'Inter', sans-serif;
    font-size: 22px; color: var(--sp-gold); margin-bottom: 8px;
}
.sp-inline-cta-text { font-size: 14px; color: var(--sp-text-muted); }
.sp-inline-cta-btn {
    display: inline-block; padding: 14px 32px;
    background: linear-gradient(135deg, var(--sp-gold), var(--sp-gold-mid));
    color: #0a1325; font-weight: 600; font-size: 16px; border-radius: 10px;
    white-space: nowrap; transition: all 200ms ease;
}
.sp-inline-cta-btn:hover { opacity: 0.9; transform: scale(1.02); }
.sp-inline-cta-disclosure {
    width: 100%; font-size: 10px; text-transform: uppercase; letter-spacing: 2px;
    color: var(--sp-text-dim); margin-top: 16px; text-align: center;
}

/* ===== TAGS ===== */
.sp-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 48px; }
.sp-tag {
    padding: 6px 16px; border-radius: 20px; font-size: 12px; font-weight: 600;
    transition: all 200ms ease; cursor: pointer;
}
.sp-tag-primary { background: var(--sp-gold); color: #0a1325; }
.sp-tag-secondary { background: var(--sp-surface-variant); color: #cbd5e1; }
.sp-tag-secondary:hover { background: var(--sp-surface-container-highest); }

/* ===== PREV/NEXT ===== */
.sp-post-nav { display: flex; justify-content: space-between; gap: 16px; padding: 32px 0; margin-top: 48px; }
.sp-post-nav-item { flex: 1; }
.sp-post-nav-item.next { text-align: right; }
.sp-post-nav-label { font-size: 11px; text-transform: uppercase; letter-spacing: 2px; color: var(--sp-text-dim); margin-bottom: 8px; }
.sp-post-nav-title {
    font-family: 'Inter', sans-serif;
    font-size: 18px; color: var(--sp-text); transition: all 200ms ease;
}
.sp-post-nav-title:hover { color: var(--sp-gold); }

/* ===== SIDEBAR ===== */
.sp-sidebar-section { margin-bottom: 48px; }
.sp-sidebar-label {
    font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 3px;
    color: var(--sp-text-dim); margin-bottom: 24px;
    display: flex; align-items: center; gap: 12px;
}
.sp-sidebar-label::after { content: ''; flex: 1; height: 1px; background: var(--sp-ghost); }

/* Referral Banner */
.sp-referral-banner {
    background: linear-gradient(135deg, var(--sp-gold), #8b6b28);
    border-radius: 12px; padding: 28px; color: #0a1325; position: relative; overflow: hidden;
}
.sp-referral-banner h3 { font-size: 22px; font-weight: 800; margin-bottom: 12px; line-height: 1.3; }
.sp-referral-banner p { font-size: 14px; opacity: 0.85; margin-bottom: 20px; font-weight: 500; }
.sp-referral-btn {
    display: block; width: 100%; padding: 14px; text-align: center;
    background: #ffffff; color: #0a1325; font-weight: 800; font-size: 14px;
    border-radius: 10px; transition: all 200ms ease; letter-spacing: 0.5px;
}
.sp-referral-btn:hover { background: #e8e8e8; color: #0a1325; }

/* Popular Posts */
.sp-popular-item { margin-bottom: 20px; cursor: pointer; }
.sp-popular-cat { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 4px; }
.sp-popular-cat.green { color: var(--sp-green); }
.sp-popular-cat.gold { color: var(--sp-gold); }
.sp-popular-cat.muted { color: var(--sp-text-muted); }
.sp-popular-title { font-weight: 700; color: var(--sp-text); line-height: 1.4; transition: all 200ms ease; }
.sp-popular-item:hover .sp-popular-title { color: var(--sp-gold); }

/* Sidebar Categories */
.sp-sidebar-cat {
    display: flex; justify-content: space-between; align-items: center;
    padding: 8px 0; color: var(--sp-text-muted); transition: all 200ms ease;
}
.sp-sidebar-cat:hover { color: #fff; }
.sp-sidebar-cat-count {
    font-size: 12px; background: var(--sp-surface-container); padding: 2px 8px; border-radius: 4px;
}

/* ===== RELATED ARTICLES ===== */
.sp-related { margin-top: 80px; }
.sp-related-head {
    font-family: 'Inter', sans-serif;
    font-size: 36px; margin-bottom: 48px; display: flex; align-items: baseline; gap: 16px;
}
.sp-related-sub { font-family: 'Inter', sans-serif;  font-size: 13px; letter-spacing: 3px; color: var(--sp-text-dim); }
.sp-related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.sp-related-card { cursor: pointer; transition: all 200ms ease; }
.sp-related-card:nth-child(2) { margin-top: 48px; }
.sp-related-img {
    aspect-ratio: 4/5; border-radius: 12px; overflow: hidden;
    background: var(--sp-surface-container); margin-bottom: 20px;
}
.sp-related-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 200ms ease; }
.sp-related-cat { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 2px; margin-bottom: 12px; }
.sp-related-title {
    font-family: 'Inter', sans-serif;
    font-size: 20px; line-height: 1.3; margin-bottom: 12px; transition: all 200ms ease;
}
.sp-related-card:hover .sp-related-title { color: var(--sp-gold); }
.sp-related-excerpt { font-size: 14px; color: var(--sp-text-dim); line-height: 1.5; }

/* ===== NEWSLETTER ===== */
.sp-newsletter {
    margin-top: 80px; background: var(--sp-surface-container);
    border-radius: 12px; padding: 64px; position: relative; overflow: hidden;
}
.sp-newsletter-inner { max-width: 640px; position: relative; z-index: 1; }
.sp-newsletter h2 {
    font-family: 'Inter', sans-serif;
    font-size: 36px; margin-bottom: 16px; line-height: 1.2;
}
.sp-newsletter p { font-size: 18px; color: var(--sp-text-muted); margin-bottom: 32px; }
.sp-newsletter-form { display: flex; gap: 12px; }
.sp-newsletter-input {
    flex: 1; padding: 14px 20px; background: var(--sp-surface-container-lowest);
    border: none; border-radius: 8px; color: var(--sp-text); font-size: 15px;
    outline: none; transition: all 200ms ease;
}
.sp-newsletter-input:focus { box-shadow: 0 0 0 2px rgba(242,195,91,0.3); }
.sp-newsletter-input::placeholder { color: var(--sp-text-dim); }
.sp-newsletter-btn {
    padding: 14px 32px; background: var(--sp-gold); color: #0a1325;
    font-weight: 600; font-size: 16px; border: none; border-radius: 10px;
    cursor: pointer; transition: all 200ms ease;
}
.sp-newsletter-btn:hover { opacity: 0.9; transform: scale(1.02); }
.sp-newsletter-fine { font-size: 10px; text-transform: uppercase; letter-spacing: 2px; color: var(--sp-text-dim); margin-top: 20px; }
.sp-newsletter-glow {
    position: absolute; right: -80px; bottom: -80px;
    width: 384px; height: 384px; background: rgba(242,195,91,0.04);
    border-radius: 50%; filter: blur(60px);
}

/* ===== MOBILE FLOATING BAR ===== */
.sp-mobile-bar { display: none !important; }
.sp-mobile-cta-sticky {
    display: none; position: fixed; bottom: 20px; left: 16px; right: 16px; z-index: 89;
    background: linear-gradient(135deg, var(--sp-gold), var(--sp-gold-mid));
    color: #0a1325; text-align: center; padding: 12px; border-radius: 10px;
    font-weight: 700; font-size: 14px; box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

/* ===== KEY TAKEAWAYS INDICATORS ===== */
.kt-bear { color: #e74c3c; font-size: 14px; margin-right: 6px; }
.kt-bull { color: #4ae176; font-size: 14px; margin-right: 6px; }
.kt-neutral { color: #8B9DB7; font-size: 10px; margin-right: 6px; }

/* ===== CONTENT BODY OVERRIDES (design.md compliance) ===== */
/* Strip inline author blocks injected by content-writer */
.sp-content > div[style*="border-top"] { display: none !important; }
.sp-content > div[style*="By Leon"] { display: none !important; }

/* Key Takeaways — override inline styles with design.md tokens */
.sp-content .sp-key-takeaways,
.sp-content > div[style*="border-left:4px"] {
    background: #1a1f2e !important;
    border-left: 4px solid #f2c35b !important;
    border-radius: 8px !important;
    padding: 20px 24px !important;
    margin-bottom: 28px !important;
    color: #e0e0e0 !important;
}
.sp-content .sp-key-takeaways ul,
.sp-content > div[style*="border-left:4px"] ul {
    list-style: none !important;
    padding-left: 0 !important;
    margin: 12px 0 0 0 !important;
}

/* Disclaimer & Affiliate — styled by template, not content */
.sp-disclaimer {
    margin-top: 48px;
    padding-top: 20px;
    font-size: 11px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--sp-text-dim);
    letter-spacing: 0.5px;
}
.sp-disclaimer a { color: var(--sp-gold); }
.sp-disclaimer p { margin-bottom: 8px; }

/* Image placeholders — ensure chart images get proper styling */
.sp-content figure { margin: 32px 0; }
.sp-content figure img {
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
}
.sp-content figcaption {
    color: var(--sp-text-muted);
    font-size: 12px;
    text-align: center;
    margin-top: 8px;
}

/* Override any inline gold color to Coinbix gold */
.sp-content a[style*="f0b90b"] { color: var(--sp-gold) !important; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .sp-body-layout { flex-direction: column; }
    .sp-sidebar { width: 100%; }
    .sp-related-grid { grid-template-columns: repeat(2, 1fr); }
    .sp-related-card:nth-child(2) { margin-top: 0; }
}
@media (max-width: 768px) {
    .sp-article-title { font-size: 28px; }
    .sp-article-hero { min-height: 360px; }
    .sp-article-hero-content { padding: 40px 20px 32px; }
    .sp-content { font-size: 16px; }
    .sp-related-grid { grid-template-columns: 1fr; }
    .sp-related-card:nth-child(2) { margin-top: 0; }
    .sp-related-head { font-size: 28px; }
    .sp-newsletter { padding: 36px 24px; }
    .sp-newsletter h2 { font-size: 28px; }
    .sp-newsletter-form { flex-direction: column; }
    .sp-main { padding: 60px 20px 100px; }
    .sp-inline-cta { flex-direction: column; text-align: center; }
    .sp-post-nav { flex-direction: column; }
    .sp-post-nav-item.next { text-align: left; }
    .sp-mobile-cta-sticky { display: block; }
    .sp-meta-row { flex-direction: column; align-items: flex-start; }
}

/* 2026-04-19: Bybit CTA 블록 (referral-cta 대체) */
.bybit-cta {
    display: flex;
    width: 100%;
    max-width: 760px;
    margin: 24px auto;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    min-height: 140px;
    text-decoration: none;
    color: #fff;
}
.bybit-cta:hover { opacity: 0.92; }
.bybit-cta__logo {
    flex: 0 0 30%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px 20px;
}
.bybit-cta__logo img {
    max-width: 100%;
    max-height: 56px;
    object-fit: contain;
    margin-top: -10px;
}
.bybit-cta__text {
    flex: 1;
    padding: 30px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.bybit-cta__title {
    font-size: 26px;
    font-weight: 700;
    line-height: 1.2;
    color: #fff;
}
@media (max-width: 640px) {
    .bybit-cta {
        flex-direction: column;
        min-height: auto;
    }
    .bybit-cta__logo {
        flex: none;
        padding: 24px 20px 8px;
    }
    .bybit-cta__logo img { margin-top: 0; max-height: 44px; }
    .bybit-cta__text { padding: 12px 24px 24px; }
    .bybit-cta__title { font-size: 20px; }
}
