/* =========================
   PROMPTHAVEN PREMIUM - Guide Page (Matches Prompt Detail)
   ========================= */

:root {
    --ph-bg: #09090b;
    --ph-card-bg: #121214;
    --ph-border: rgba(255, 255, 255, 0.08);
    --ph-yellow: #F59E0B;
    --ph-yellow-hover: #d97706;
    --ph-red: #DC2626;
    --ph-text-main: #ECECEC;
    --ph-text-muted: #A1A1AA;
}

body {
    background-color: var(--ph-bg);
    background-image: linear-gradient(var(--ph-border) 1px, transparent 1px),
                      linear-gradient(90deg, var(--ph-border) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    color: var(--ph-text-main);
    font-family: 'Inter', system-ui, sans-serif;
    padding-top: 0;
    position: relative;
}

/* --- GLOBAL HEADER SAFETY --- */
/* Scoped: only fix the main site header, not every nav/header element */
.main-header,
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10000;
}

/* --- PARENT CONTAINER FIX --- */
body,
html {
    overflow: visible !important;
}

/* --- Layout Container --- */
.guide-layout,
.split-layout-container {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 24px;
    max-width: 1400px;
    margin: 40px auto;
    padding: 0 24px;
    align-items: start;
    margin-top: 120px !important;
}

/* --- HERO (H1 + Meta) --- */
.guide-hero {
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px 24px 0;
}

/* --- LEFT: The Article CARD --- */
.guide-article,
.guide-content-wrapper {
    background: var(--ph-card-bg);
    border: 1px solid var(--ph-border);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    font-size: 1.1rem;
    line-height: 1.8;
}

.guide-content-wrapper h1 {
    position: relative;
    display: block;
    font-size: 2.5rem;
    font-weight: 800;
    margin-top: 0;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
    z-index: 2;
    clear: both;
}

.guide-content-wrapper .meta-info,
.guide-content-wrapper p.subtitle {
    position: relative;
    display: block;
    margin-bottom: 2rem;
    clear: both;
}

.guide-content-wrapper img {
    border-radius: 12px;
    border: 1px solid var(--ph-border);
}

/* --- RIGHT: The Sidebar CARD (SIDEBAR TERMINATOR FIX) --- */
.guide-sidebar {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 110px !important;
    height: auto;
    max-height: calc(100vh - 120px) !important;
    z-index: 99 !important;
    background: var(--ph-card-bg);
    border: 1px solid var(--ph-border);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid var(--ph-border);
    background: rgba(255,255,255,0.01);
}

.action-title {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--ph-text-muted);
    margin-bottom: 16px;
    font-weight: 600;
}

.ph-btn-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ph-actions-row {
    display: flex;
    gap: 12px;
}

.ph-actions-row .ph-btn {
    flex: 1;
    font-size: 0.9rem;
    padding: 12px;
}

.ph-btn svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.ph-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    width: 100%;
}

/* Fix Button Internals */
.ph-btn-primary {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Push text left and count right */
    width: 100%;
    padding: 14px 20px;
    background: var(--ph-yellow);
    color: #000;
}

.ph-btn-content-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ph-btn-primary:hover {
    background: var(--ph-yellow-hover);
    transform: translateY(-1px);
}

.ph-btn.liked,
.ph-btn-primary.liked {
    background: var(--ph-red);
    color: #fff;
}

.ph-btn-secondary {
    background: rgba(255,255,255,0.05);
    color: var(--ph-text-main);
    border: 1px solid var(--ph-border);
}

.ph-btn-secondary:hover {
    background: rgba(255,255,255,0.1);
}

.ph-btn.saved {
    border-color: var(--ph-yellow);
    color: var(--ph-yellow);
}

.ph-btn-danger {
    background: var(--ph-red);
    color: #fff;
}

.sidebar-comments-area {
    flex: 1;
    overflow-y: auto;
    background: #0e0e10;
}

.comment-item {
    padding: 16px;
    border-bottom: 1px solid var(--ph-border);
}

.sidebar-footer {
    padding: 20px;
    background: var(--ph-card-bg);
    border-top: 1px solid var(--ph-border);
}

/* IG-style action buttons (used in sidebar) */
.ig-action-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.ig-group-left, .ig-group-right {
    display: flex;
    gap: 16px;
    align-items: center;
}

.ig-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: var(--ph-text-muted);
    transition: transform 0.2s ease, color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ig-btn svg {
    width: 26px;
    height: 26px;
    stroke-width: 2px;
    fill: transparent;
    stroke: currentColor;
}

.ig-btn:hover { color: var(--ph-text-main); transform: scale(1.1); }
.like-btn:hover { color: #ed4956; }
.comment-btn:hover { color: #58c5ff; }

.ig-btn.liked svg {
    fill: #ed4956;
    stroke: #ed4956;
    animation: like-bounce 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes like-bounce {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

.likes-count {
    margin-top: 8px;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--ph-text-main);
    cursor: pointer;
}

.comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743);
    flex-shrink: 0;
}

.comment-content { display: flex; flex-direction: column; gap: 4px; }
.comment-username { font-weight: 700; color: var(--ph-text-main); }
.comment-text { color: var(--ph-text-muted); line-height: 1.4; }
.comment-meta { font-size: 0.75rem; color: var(--ph-text-muted); margin-top: 4px; }

.comment-input-wrapper { display: flex; align-items: center; gap: 10px; }
.comment-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--ph-text-main);
    font-size: 0.95rem;
    padding: 10px 0;
    outline: none;
}

.post-btn {
    background: none;
    border: none;
    color: var(--ph-yellow);
    font-weight: 600;
    cursor: pointer;
    font-size: 0.95rem;
    opacity: 0.5;
    pointer-events: none;
}

.post-btn.active { opacity: 1; pointer-events: all; }

/* --- BOTTOM: "You Might Also Like" --- */
.related-section {
    max-width: 1400px;
    margin: 60px auto;
    padding: 0 24px;
}

.related-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
    border-left: 4px solid var(--ph-yellow);
    padding-left: 16px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.related-card {
    background: var(--ph-card-bg);
    border: 1px solid var(--ph-border);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s;
    cursor: pointer;
}

.related-card:hover {
    transform: translateY(-5px);
    border-color: var(--ph-yellow);
}

.related-img {
    height: 180px;
    background: #222;
    background-size: cover;
    background-position: center;
}

.related-info {
    padding: 16px;
}

@media (max-width: 1024px) {
    .split-layout-container { grid-template-columns: 1fr; }
    .guide-sidebar { height: auto; position: relative; top: 0; max-height: 500px; margin-top: 40px; }
}

/* Article typography (inside split layout) */
.guide-content-wrapper h2,
.article-container h2,
.guide-article h2 {
    font-size: 1.75rem;
    margin-top: 2.5em;
    margin-bottom: 1em;
    color: var(--ph-text-main);
    border-left: 4px solid var(--ph-yellow);
    padding-left: 16px;
}

.guide-content-wrapper h3,
.article-container h3,
.guide-article h3 {
    font-size: 1.35rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--ph-text-main);
}

.guide-content-wrapper p,
.article-container p,
.guide-article .content-section p {
    margin-bottom: 1.5em;
    color: var(--ph-text-muted);
}

.guide-content-wrapper a,
.article-container a {
    color: var(--ph-yellow);
}

.guide-content-wrapper a:hover {
    color: var(--ph-yellow-hover);
}

/* =========================
   LEGACY / ADDITIONAL GUIDE STYLES
   ========================= */

/* Genel Layout */
.guide-container {
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 20px;
    box-sizing: border-box;
    flex: 1; /* Sticky footer için */
}

/* Galeriye Dönüş Butonu */
.back-to-gallery-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px; /* İkon ile yazı arası boşluk */
    
    color: #FFD700; /* Sarı yazı rengi */
    background-color: rgba(255, 215, 0, 0.1); /* Çok hafif sarı şeffaf arka plan */
    border: 1px solid rgba(255, 215, 0, 0.3); /* İnce sarı çerçeve */
    
    padding: 12px 24px;
    border-radius: 50px; /* Tam yuvarlak köşeler */
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    margin-bottom: 30px; /* Başlıktan uzaklaştır */
}

/* Hover Efekti */
.back-to-gallery-btn:hover {
    background-color: #FFD700; /* Üzerine gelince tam sarı olsun */
    color: #000000; /* Yazı siyah olsun (kontrast için) */
    transform: translateX(-5px); /* Hafif sola kayma efekti */
    border-color: #FFD700;
}

/* --- NAVIGASYON --- */
.guide-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 5%;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    background: rgba(5, 5, 5, 0.95);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* --- Premium SaaS Navigation Styles --- */

/* Container: Ensures it takes full width and pushes content down (No Overlap) */
.academy-nav-header {
    display: block;
    width: 100%;
    padding: 20px 0; /* Vertical spacing */
    margin-bottom: 20px; /* Space between button and Title */
    border-bottom: 1px solid rgba(255, 255, 255, 0.05); /* Subtle separator line */
}

/* The Button Itself (Pill Shape) */
.nav-pill-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background-color: rgba(255, 255, 255, 0.05); /* Very subtle transparent bg */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px; /* Pill shape */
    color: #aaa;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Hover State: Premium Gold Glow */
.nav-pill-back:hover {
    background-color: rgba(255, 215, 0, 0.1); /* Low opacity gold bg */
    border-color: rgba(255, 215, 0, 0.4);
    color: #FFD700; /* Theme Yellow */
    transform: translateX(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.nav-pill-back i {
    font-size: 0.8rem;
}

.back-btn {
    color: #94a3b8;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex; 
    align-items: center; 
    gap: 8px;
    transition: 0.3s;
    text-decoration: none;
}
.back-btn:hover { 
    color: #ffd700; 
    transform: translateX(-5px); 
}

.nav-logo-box {
    display: flex; 
    align-items: center; 
    gap: 10px;
    font-weight: 700; 
    color: #fff; 
    letter-spacing: 0.5px; 
    font-size: 1.1rem;
}
.nav-logo-box img { 
    width: 28px; 
    border-radius: 6px; 
}

/* --- HERO BÖLÜMÜ --- */
.guide-hero {
    text-align: center;
    padding: 40px 20px;
    margin-bottom: 60px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 15px;
    color: #fff;
    letter-spacing: -1px;
}

.gold-text {
    background: linear-gradient(135deg, #ffd700, #ffecb3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 40px rgba(255, 215, 0, 0.4);
    display: inline-block;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: #94a3b8;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* --- BÖLÜM 1: 3 ADIMLI GRID --- */
.guide-steps-section {
    margin-bottom: 80px;
}

.guide-steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 50px;
}

.step-card {
    background: #151515; /* Çok koyu gri */
    border: 1px solid #333;
    border-radius: 20px;
    padding: 30px;
    transition: transform 0.3s ease, border-color 0.3s ease;
    display: flex;
    flex-direction: column;
}

.step-card:hover { 
    transform: translateY(-5px); 
    border-color: #ffd700; 
}

.step-icon {
    color: #ffd700;
    font-size: 1.5rem;
    margin-bottom: 15px;
    background: rgba(255, 215, 0, 0.1);
    width: 50px; 
    height: 50px;
    display: flex; 
    align-items: center; 
    justify-content: center;
    border-radius: 50%;
}

.step-card h3 {
    color: #fff;
    font-size: 1.5rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.step-card p {
    color: #94a3b8;
    line-height: 1.6;
    font-size: 1rem;
}

/* --- BÖLÜM 2: PRO PARAMETERS --- */
.pro-parameters-section {
    margin-bottom: 80px;
}

.section-title {
    display: flex; 
    align-items: center; 
    gap: 10px;
    font-size: 1.8rem; 
    margin-bottom: 20px; 
    margin-top: 50px;
    color: #fff;
    font-weight: 700;
}

.section-desc {
    color: #94a3b8;
    font-size: 1rem;
    margin-bottom: 30px;
    line-height: 1.6;
}

.blue-accent {
    color: #3b82f6;
}

.params-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.param-card {
    background: #1a1a1a;
    padding: 25px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1px solid #2d2d2d;
    transition: border-color 0.3s ease;
}

.param-card:hover {
    border-color: #3b82f6;
}

.code-badge {
    background: #2563eb; /* Mavi kod arka planı */
    color: white;
    font-family: monospace;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    white-space: nowrap;
    font-weight: 600;
    flex-shrink: 0;
}

.param-info {
    flex: 1;
}

.param-info h4 {
    color: #fff;
    margin-bottom: 8px;
    font-size: 1.1rem;
    font-weight: 600;
}

.param-info p {
    color: #94a3b8;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0;
}

code.gold {
    color: #ffd700;
    background: rgba(255, 215, 0, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
}

code.red {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
}

/* --- BÖLÜM 3: MASTERING AI PORTRAITURE --- */
.mastering-section {
    margin-bottom: 80px;
}

.mastering-content {
    background: #1e1e1e;
    border-left: 4px solid #ffd700; /* Sol tarafta sarı dikey çizgi */
    padding: 40px;
    border-radius: 16px;
    border-top: 1px solid #333;
    border-right: 1px solid #333;
    border-bottom: 1px solid #333;
}

.mastering-content h3 {
    color: #fff;
    font-size: 1.5rem;
    margin-top: 35px;
    margin-bottom: 15px;
    font-weight: 700;
}

.mastering-content h3:first-of-type {
    margin-top: 0;
}

.mastering-content p {
    color: #94a3b8;
    line-height: 1.8;
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.mastering-content ul {
    margin-bottom: 25px;
    padding-left: 20px;
    list-style-type: disc;
}

.mastering-content ul li {
    color: #94a3b8;
    margin-bottom: 10px;
    line-height: 1.8;
}

.mastering-content strong {
    color: #fff;
    font-weight: 600;
}

.highlight {
    color: #ffd700;
    font-weight: bold;
}

.mastering-content code {
    background: #222;
    padding: 2px 6px;
    border-radius: 4px;
    color: #ffd700;
    font-family: monospace;
    font-size: 0.9em;
}

.info-card {
    background: rgba(255, 215, 0, 0.05);
    padding: 25px;
    border-radius: 12px;
    margin-top: 30px;
    border: 1px dashed rgba(255, 215, 0, 0.3);
}

.info-card h4 {
    color: #fff;
    font-size: 1.2rem;
    margin-bottom: 15px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-card p {
    color: #94a3b8;
    line-height: 1.8;
    margin: 0;
}

/* --- CTA SECTION --- */
.ready-cta {
    text-align: center;
    padding: 40px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1), transparent);
    border-radius: 24px;
    border: 1px solid rgba(255, 215, 0, 0.2);
    margin-bottom: 40px;
}

.ready-cta h2 {
    color: #fff;
    margin-bottom: 30px;
    font-size: 2rem;
    font-weight: 700;
}

/* Sayfa Altındaki Galeri Linki */
.guide-footer-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 50px; /* İçerikten iyice uzaklaştır */
    margin-bottom: 30px;
    
    color: #cbd5e1 !important; /* "Sapsarı" yerine okunaklı AÇIK GRİ/GÜMÜŞ */
    font-weight: 500;
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border-bottom: 1px solid transparent; /* Hover için hazırlık */
}

/* Hover Efekti */
.guide-footer-link:hover {
    color: #FFD700 !important; /* Sadece üzerine gelince canlansın (Sarı) */
    border-bottom-color: #FFD700; /* Alt çizgi efekti */
}

/* --- FOOTER --- */
.simple-footer {
    text-align: center;
    padding: 40px;
    color: #475569;
    font-size: 0.9rem;
    margin-top: auto; /* Sticky footer için */
}

/* --- GENEL TİPOGRAFİ --- */
.guide-container h1,
.guide-container h2,
.guide-container h3,
.guide-container h4 {
    color: #ffffff !important;
}

.guide-container p,
.guide-container li {
    color: #94a3b8 !important;
}

.guide-container a {
    color: #ffd700 !important;
    transition: color 0.2s ease;
}

.guide-container a:hover {
    color: #ffed4a !important;
}

/* MOBİL */
@media screen and (max-width: 768px) {
    .hero-title { 
        font-size: 2.5rem; 
    }
    
    .guide-steps-grid {
        grid-template-columns: 1fr;
    }
    
    .params-grid {
        grid-template-columns: 1fr;
    }
    
    .param-card {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .guide-nav {
        padding: 15px 20px;
    }
    
    .guide-container {
        padding: 0 15px;
        margin: 20px auto;
    }
    
    .mastering-content {
        padding: 25px 20px;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
}

/* --- MAKALE DETAY SAYFASI STİLLERİ --- */

/* Makale Kapsayıcısı - Okuma kolaylığı için dar tutuyoruz */
.article-wrapper {
    max-width: 800px; /* Çok geniş satırlar okumayı zorlaştırır */
    margin: 100px auto 60px auto; /* Navbar payı + Alt boşluk */
    padding: 0 20px;
}

/* Makale Başlığı */
.article-header {
    position: relative;
    margin-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 20px;
}

.article-category {
    color: #ffd700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 700;
    margin-bottom: 10px;
    display: block;
}

.article-header h1 {
    font-size: 2.5rem;
    color: #fff;
    line-height: 1.2;
    margin: 0;
}

/* Makale İçeriği (Typography) */
.article-body {
    color: #e2e8f0; /* Tam beyaz değil, göz yormayan gri-beyaz */
    font-size: 1.1rem;
    line-height: 1.8; /* Satır aralığı geniş olmalı */
}

.article-body h2 {
    color: #fff;
    font-size: 1.8rem;
    margin-top: 40px;
    margin-bottom: 20px;
    border-left: 4px solid #ffd700; /* Sol tarafa sarı şerit */
    padding-left: 15px;
}

.article-body h3 {
    color: #f1f5f9;
    font-size: 1.4rem;
    margin-top: 30px;
    margin-bottom: 15px;
}

.article-body p {
    margin-bottom: 20px;
}

.article-body ul, .article-body ol {
    margin-bottom: 20px;
    padding-left: 20px;
}

.article-body li {
    margin-bottom: 10px;
}

.article-body strong {
    color: #fff; /* Vurgulu yerler parlasın */
}

.code-block {
    background: #1e1e1e;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    font-family: 'Courier New', monospace;
    color: #a5b4fc;
    margin: 20px 0;
    overflow-x: auto;
}

/* Back Link (Geri Dön) */
.back-nav {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #94a3b8;
    text-decoration: none;
    margin-bottom: 30px;
    font-size: 0.9rem;
    transition: color 0.2s;
}
.back-nav:hover { color: #fff; }

/* =========================
   PREMIUM READING MODE (Medium-like)
   Scoped to guide pages only
   ========================= */

.guide-article,
.guide-article article,
.article-container.guide-article,
main.guide-article {
    max-width: 780px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 24px;
    box-sizing: border-box;
}

.guide-article,
.guide-article p,
.article-container .content-section p,
.guide-article .content-section p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #e2e8f0;
}

.guide-article h1,
.article-container h1,
.guide-article .main-title {
    position: relative;
    font-size: 2.5rem;
    line-height: 1.2;
    margin-top: 0;
    margin-bottom: 1rem;
    color: #fff;
}

.guide-article h2,
.article-container h2 {
    font-size: 1.75rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
}

.guide-article h3,
.article-container h3 {
    font-size: 1.35rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #f1f5f9;
}

.guide-article pre,
.article-container pre,
.guide-article .prompt-box,
.article-container .prompt-box {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    overflow-x: auto;
    margin: 1.5rem 0;
    font-size: 0.95rem;
}

.guide-article code,
.article-container code {
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    padding: 2px 6px;
    border-radius: 4px;
}

.guide-article img,
.article-container img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.guide-article blockquote,
.article-container blockquote,
.guide-article .note-box,
.article-container .note-box {
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
    border-left: 4px solid rgba(255, 215, 0, 0.5);
    background: rgba(255, 255, 255, 0.03);
    border-radius: 0 8px 8px 0;
    color: #94a3b8;
}

.guide-article ul,
.article-container ul,
.guide-article ol,
.article-container ol {
    margin: 1.25rem 0;
    padding-left: 1.5rem;
    line-height: 1.8;
}

.guide-article li,
.article-container li {
    margin-bottom: 0.5rem;
}

/* --- INTERACTION BAR (Guide scope) --- */

.guide-interactions {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 0;
    margin: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.guide-interactions .btn-hype,
.guide-interactions .btn-down,
.guide-interactions .btn-comment {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    color: #94a3b8;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.guide-interactions .btn-hype:hover,
.guide-interactions .btn-down:hover,
.guide-interactions .btn-comment:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 215, 0, 0.3);
    color: #e2e8f0;
}

.guide-interactions .btn-hype:active,
.guide-interactions .btn-down:active,
.guide-interactions .btn-comment:active {
    transform: scale(0.98);
}

/* --- CARD PLACEHOLDER (Academy feed - missing images) --- */

.card-placeholder-gradient {
    width: 100%;
    height: 100%;
    min-height: 200px;
    background: linear-gradient(135deg, #1e1e2e 0%, #2a2a40 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.card-placeholder-gradient::after {
    content: 'PromptHaven';
    font-weight: 700;
    color: rgba(255,255,255,0.05);
    font-size: 1.5rem;
    letter-spacing: 2px;
}

/* --- Comment Drawer (Sidebar) --- */
.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.drawer-overlay.open {
    opacity: 1;
    visibility: visible;
}

.comments-drawer {
    position: fixed;
    top: 0;
    right: -450px;
    width: 400px;
    max-width: 90%;
    height: 100vh;
    background: #000;
    border-left: 1px solid rgba(255, 255, 255, 0.15);
    z-index: 999;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 30px rgba(0,0,0,0.5);
}

.comments-drawer.open {
    right: 0;
}

.drawer-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.drawer-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
}

.close-drawer-btn {
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1.5rem;
    padding: 5px;
}

.comments-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.comment-item {
    display: flex;
    gap: 12px;
    font-size: 0.95rem;
}

.comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    flex-shrink: 0;
}

.comment-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.comment-username {
    font-weight: 700;
    color: #fff;
    margin-right: 6px;
}

.comment-text {
    color: #e0e0e0;
    line-height: 1.4;
}

.comment-meta {
    font-size: 0.75rem;
    color: #888;
    margin-top: 4px;
}

.drawer-footer {
    padding: 15px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: #000;
}

.comment-input-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.comment-input {
    flex: 1;
    background: none;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    padding: 10px 0;
    outline: none;
}

.post-btn {
    background: none;
    border: none;
    color: #0095f6;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.95rem;
    opacity: 0.5;
    pointer-events: none;
}

.post-btn.active {
    opacity: 1;
    pointer-events: all;
}

/* === HERO & LAYOUT SPACING FIX (FINAL) === */

.guide-content-wrapper {
    position: relative;
    z-index: 1;
    padding-bottom: 3.5rem !important;
    margin-bottom: 3rem !important;
    margin-top: 0;
}

.guide-content-wrapper h1 {
    position: relative;
    display: block;
    margin-bottom: 1.5rem;
    clear: both;
}

.guide-content-wrapper .meta-info,
.guide-content-wrapper p.subtitle {
    display: block;
    margin-bottom: 2.5rem;
}

/* ===============================
   SIDEBAR SCROLL BEHAVIOR FIX
   =============================== */

/* Force sidebar to behave like normal content */
.guide-sidebar {
    position: relative !important;
    top: auto !important;
    bottom: auto !important;
    z-index: auto !important;
    max-height: none !important;
    overflow: visible !important;
}

/* Safety: prevent parent containers from re-enabling sticky */
.split-layout-container,
.guide-layout,
.guide-grid {
    overflow: visible;
}

/* ===============================
   FOOTER POSITION FIX
   =============================== */

/* Ensure guide footer is always last */
.guide-footer {
    margin-top: 5rem;
    padding: 2.5rem 1rem;
    text-align: center;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.4);
    border-top: 1px solid rgba(255,255,255,0.08);
}

/* Prevent footer from appearing inside content flow */
.guide-content-wrapper .guide-footer {
    order: 999;
}

/* --- EMOJI PICKER STYLES --- */
.comment-input-wrapper {
    position: relative; /* Anchor for the absolute picker */
    background: #18181b; /* Darker input background */
    border: 1px solid var(--ph-border);
    border-radius: 24px; /* Rounded pill shape */
    padding: 4px 12px; /* Internal spacing */
    transition: border-color 0.2s;
}

.comment-input-wrapper:focus-within {
    border-color: var(--ph-yellow);
}

/* The Smiley Button */
.emoji-toggle-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #a1a1aa;
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.emoji-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.emoji-toggle-btn svg {
    width: 20px;
    height: 20px;
}

/* The Popup Grid */
.emoji-picker-popup {
    position: absolute;
    bottom: 120%; /* Push it up a bit more for clearance */
    left: 0;

    /* --- CRITICAL FIX --- */
    width: 100%; /* Match the parent width exactly */
    box-sizing: border-box; /* Include padding in width calculation */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(28px, 1fr)); /* Auto-adjust columns based on width */
    /* -------------------- */

    background: #18181b;
    border: 1px solid var(--ph-border);
    border-radius: 12px;
    padding: 12px;
    gap: 8px;

    box-shadow: 0 10px 30px rgba(0,0,0,0.8); /* Stronger shadow for depth */
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 999; /* Ensure it floats above everything */
}

.emoji-picker-popup.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Individual Emoji */
.emoji-item {
    font-size: 1.25rem;
    cursor: pointer;
    text-align: center;
    padding: 6px;
    border-radius: 8px;
    transition: background 0.1s;
    user-select: none;
}

.emoji-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.2);
}
