/* ═══════════════════════════════════════════════════════════
   PRUVN DESKTOP THEME v3
   Vibrant, modern newsroom. Trust through clarity and energy.
   ═══════════════════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,400;0,500;0,600;0,700;0,800&family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,700&display=swap');

/* ── KILL MOBILE ── */
.pv-desktop .app-shell,
.pv-desktop .top-bar,
.pv-desktop .bottom-nav,
.pv-desktop .app-header,
.pv-desktop .scroll-area,
.pv-desktop #pv-app-banner,
.pv-desktop #pv-onboard { display:none !important }

.pv-desktop {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: #F4F2EE;
    color: #1B1B18;
    -webkit-font-smoothing: antialiased;
}

/* ═══════════════════════════════════════════
   TOPBAR
   ═══════════════════════════════════════════ */
.dt-topbar {
    position: fixed; top: 0; left: 0; right: 0; height: 56px; z-index: 100;
    background: #fff;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 28px;
    border-bottom: 1px solid #E5E2DC;
}
.dt-topbar-left { display: flex; align-items: center; gap: 32px }
.dt-topbar-logo {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 24px; font-weight: 700; color: var(--brand);
    text-decoration: none; letter-spacing: -0.5px;
}
.dt-topbar-nav { display: flex; align-items: center; gap: 4px }
.dt-topbar-link {
    padding: 7px 16px; font-size: 13px; font-weight: 600;
    color: #8C8C80; text-decoration: none;
    border-radius: 8px; transition: all 0.15s;
}
.dt-topbar-link:hover { color: #1B1B18; background: #F4F2EE }
.dt-topbar-link.active { color: var(--brand); background: var(--brand-light) }

.dt-topbar-right { display: flex; align-items: center; gap: 10px }
.dt-topbar-actions { display: flex; align-items: center; gap: 6px }

.dt-icon-btn {
    width: 36px; height: 36px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: #8C8C80; font-size: 18px; text-decoration: none;
    transition: all 0.15s; cursor: pointer; border: none; background: none;
}
.dt-icon-btn:hover { background: #F4F2EE; color: #1B1B18 }

.dt-avatar {
    width: 34px; height: 34px; border-radius: 10px;
    background: linear-gradient(135deg, #2D6A4F, #40916C);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700; text-decoration: none;
    box-shadow: 0 2px 8px rgba(45,106,79,0.3);
}

.dt-login-btn {
    padding: 8px 24px; border-radius: 8px;
    background: var(--brand); color: #fff;
    font-size: 13px; font-weight: 700;
    border: none; cursor: pointer;
    transition: all 0.15s;
    box-shadow: 0 2px 8px rgba(45,106,79,0.25);
}
.dt-login-btn:hover { background: var(--brand-dark); box-shadow: 0 4px 12px rgba(45,106,79,0.35) }

.dt-announcement {
    background: linear-gradient(90deg, #FEF3C7, #FDE68A);
    color: #92400E; padding: 5px 14px; border-radius: 8px;
    font-size: 11px; font-weight: 600;
    display: flex; align-items: center; gap: 8px;
}
.dt-announcement button {
    background: none; border: none; color: #D97706;
    font-size: 15px; cursor: pointer; padding: 0; line-height: 1;
}

/* ═══════════════════════════════════════════
   SIDEBAR
   ═══════════════════════════════════════════ */
.dt-sidebar {
    position: fixed; top: 56px; left: 0; bottom: 0; width: 248px;
    background: #fff; z-index: 90;
    display: flex; flex-direction: column;
    border-right: 1px solid #E5E2DC;
    overflow-y: auto;
}
.dt-sidebar::-webkit-scrollbar { width: 0 }

.dt-sidebar-brand {
    display: flex; align-items: center; gap: 12px;
    padding: 24px 20px 16px;
}
.dt-brand-icon {
    width: 40px; height: 40px; border-radius: 12px;
    background: linear-gradient(135deg, #2D6A4F 0%, #52B788 100%);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Fraunces', Georgia, serif;
    font-size: 18px; font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(45,106,79,0.3);
}
.dt-brand-name {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 17px; font-weight: 700; color: #1B1B18;
    letter-spacing: -0.3px;
}
.dt-brand-tag {
    font-size: 10px; font-weight: 700; color: var(--brand);
    text-transform: uppercase; letter-spacing: 1.5px;
    margin-top: 2px;
}

.dt-nav { flex: 1; padding: 8px 10px }
.dt-nav-item {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 14px; margin-bottom: 2px;
    font-size: 13.5px; font-weight: 600; color: #7A7A6E;
    text-decoration: none; border-radius: 10px;
    transition: all 0.15s;
}
.dt-nav-item:hover { background: #F4F2EE; color: #1B1B18 }
.dt-nav-item.active {
    color: var(--brand);
    background: var(--brand-light);
    box-shadow: inset 3px 0 0 var(--brand);
}
.dt-nav-item i { font-size: 18px; width: 22px; text-align: center }
.dt-nav-sep { height: 1px; background: #EDECE8; margin: 10px 14px }

.dt-sidebar-bottom {
    padding: 14px 10px; border-top: 1px solid #EDECE8;
}
.dt-sidebar-cta {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; padding: 12px; border-radius: 10px;
    background: linear-gradient(135deg, #2D6A4F, #40916C);
    color: #fff;
    font-size: 13px; font-weight: 700;
    text-decoration: none; border: none; cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(45,106,79,0.25);
}
.dt-sidebar-cta:hover {
    box-shadow: 0 6px 20px rgba(45,106,79,0.35);
    transform: translateY(-1px);
}
.dt-sidebar-cta i { font-size: 16px }
.dt-sidebar-links {
    display: flex; flex-direction: column; gap: 2px; padding: 10px 4px 0;
}
.dt-sidebar-links a {
    display: flex; align-items: center; gap: 8px;
    padding: 6px 10px; font-size: 12px; color: #A0A090;
    text-decoration: none; border-radius: 6px; transition: all 0.15s;
}
.dt-sidebar-links a:hover { color: var(--brand); background: #F9F8F5 }
.dt-sidebar-links a i { font-size: 14px }

/* ═══════════════════════════════════════════
   MAIN CONTENT
   ═══════════════════════════════════════════ */
.dt-main {
    margin-left: 248px; margin-top: 56px;
    min-height: calc(100vh - 56px);
    background: #F4F2EE;
}
.dt-content {
    padding: 32px 40px;
    max-width: 1320px;
    margin: 0 auto;
}

/* ═══════════════════════════════════════════
   FEED: Masonry columns (variable height cards)
   ═══════════════════════════════════════════ */
.pv-desktop .dt-content #feed {
    columns: 3;
    column-gap: 20px;
    padding: 0;
}
.pv-desktop .dt-content #feed .news-card {
    break-inside: avoid;
    margin-bottom: 20px;
    display: inline-block;
    width: 100%;
}
@media (max-width: 1300px) {
    .pv-desktop .dt-content #feed { columns: 2 }
}
@media (max-width: 900px) {
    .pv-desktop .dt-content #feed { columns: 1; max-width: 580px }
}

/* ═══════════════════════════════════════════
   CARDS - Clean, vibrant, alive
   ═══════════════════════════════════════════ */
.pv-desktop .dt-content .news-card {
    border-radius: 14px;
    transition: all 0.2s ease;
    cursor: pointer; overflow: hidden;
    background: #fff;
    border: 1px solid transparent;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.02);
}
.pv-desktop .dt-content .news-card:hover {
    box-shadow: 0 12px 40px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.04);
    transform: translateY(-3px);
}

/* Type accents: vibrant top strip */
.pv-desktop .news-card[data-type="verified"] {
    border-top: 3px solid var(--brand);
}
.pv-desktop .news-card[data-type="misleading"] {
    border-top: 3px solid var(--mis);
}
.pv-desktop .news-card[data-type="developing"] {
    border-top: 3px solid var(--dev);
}

.pv-desktop .card-headline {
    font-family: 'Fraunces', Georgia, serif !important;
    font-size: 17px !important; line-height: 1.35 !important;
    font-weight: 600 !important; letter-spacing: -0.2px;
    color: #1B1B18;
}
.pv-desktop .card-summary {
    font-size: 13px !important; line-height: 1.6 !important;
    color: #6B6B5E;
}
.pv-desktop .cvt-text {
    font-size: 12.5px !important; line-height: 1.55 !important;
}

/* Card images: subtle zoom on hover */
.pv-desktop .news-card img {
    transition: transform 0.3s ease;
}
.pv-desktop .news-card:hover img {
    transform: scale(1.03);
}

/* Stamp badges */
.pv-desktop .stamp {
    font-size: 10px; padding: 4px 10px; border-radius: 6px;
    letter-spacing: 0.5px;
}

/* ═══════════════════════════════════════════
   FEED HEADER
   ═══════════════════════════════════════════ */
.dt-feed-header {
    margin-bottom: 24px;
    display: flex; justify-content: space-between; align-items: flex-end;
    flex-wrap: wrap; gap: 16px;
    padding-bottom: 20px;
    border-bottom: 1px solid #E5E2DC;
}
.dt-feed-title {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 38px; font-weight: 700; color: #1B1B18;
    letter-spacing: -1px; line-height: 1.1;
}
.dt-feed-subtitle {
    font-size: 14px; color: #8C8C80; margin-top: 6px;
    font-weight: 500;
}
.dt-feed-chips { display: flex; gap: 8px; flex-wrap: wrap }
.dt-feed-chip {
    padding: 8px 18px; border-radius: 10px;
    font-size: 12px; font-weight: 700;
    background: #fff; color: #7A7A6E;
    border: 1.5px solid #E5E2DC;
    cursor: pointer;
    transition: all 0.15s;
    display: flex; align-items: center; gap: 6px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}
.dt-feed-chip:hover {
    border-color: #C8C4BA; color: #1B1B18;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.dt-feed-chip.active {
    background: var(--brand); color: #fff; border-color: var(--brand);
    box-shadow: 0 4px 12px rgba(45,106,79,0.25);
}
.dt-feed-chip.active-mis {
    background: var(--mis); color: #fff; border-color: var(--mis);
    box-shadow: 0 4px 12px rgba(185,28,28,0.25);
}
.dt-feed-chip.active-dev {
    background: var(--dev); color: #fff; border-color: var(--dev);
    box-shadow: 0 4px 12px rgba(180,83,9,0.25);
}
.dt-feed-chip i { font-size: 14px }

/* Language selector override for desktop */
.pv-desktop select {
    padding: 7px 14px !important; border-radius: 8px !important;
    border: 1.5px solid #E5E2DC !important; font-size: 12px !important;
    font-weight: 600 !important; color: #7A7A6E !important;
    background: #fff !important; cursor: pointer !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    transition: border-color 0.15s !important;
}
.pv-desktop select:hover { border-color: #C8C4BA !important }
.pv-desktop select:focus { border-color: var(--brand) !important; outline: none !important }

/* ═══════════════════════════════════════════
   MOBILE PAGES IN DESKTOP WRAPPER
   ═══════════════════════════════════════════ */
.pv-desktop .dt-content > [class*="sticky"][class*="top-[52px]"],
.pv-desktop .dt-content > [class*="sticky"][class*="top-[92px]"] {
    top: 0 !important;
}
.pv-desktop .dt-content > .px-4,
.pv-desktop .dt-content > .px-3 {
    max-width: 780px;
    margin-left: auto; margin-right: auto;
}
.pv-desktop .dt-content > div > .px-4:first-child,
.pv-desktop .dt-content > div > .px-3:first-child {
    max-width: 780px;
    margin-left: auto; margin-right: auto;
}
.pv-desktop [class*="fixed"][class*="bottom-20"] {
    bottom: 24px !important; right: 40px !important;
    left: auto !important; max-width: none !important;
}

/* Per-page */
.pv-desktop #pv-claim-text {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 18px; line-height: 1.7;
}
.pv-desktop .pv-ct-btn {
    padding: 10px 20px !important; font-size: 13px !important;
    border-radius: 10px !important; font-weight: 700 !important;
}
.pv-desktop #pv-impact-content { max-width: 780px; margin: 0 auto }
.pv-desktop #pv-settings { max-width: 600px; margin: 0 auto }
.pv-desktop .max-w-sm { max-width: 600px !important; margin: 0 auto }
.pv-desktop .dt-content > [class*="overflow-x-auto"] { overflow-x: visible !important }

/* Fix white background leaks: bg-white and inline bg:#fff on page-level elements */
.pv-desktop .dt-content .bg-white,
.pv-desktop .dt-content > .bg-white,
.pv-desktop .dt-content [class*="bg-white"]:not(.news-card):not(.share-sheet):not(.msg-bot):not([class*="modal"]) {
    background: #F4F2EE !important;
}
/* Sticky headers should match page background */
.pv-desktop .dt-content [class*="sticky"][class*="bg-white"] {
    background: #F4F2EE !important;
    border-bottom: 1px solid #E5E2DC !important;
}
/* Auth sheet, share sheet, modals keep white */
.pv-desktop .share-sheet,
.pv-desktop .auth-sheet,
.pv-desktop [class*="modal"],
.pv-desktop .msg-bot { background: #fff !important }

/* Input/textarea polish */
.pv-desktop input[type="text"],
.pv-desktop input[type="tel"],
.pv-desktop textarea {
    border-radius: 10px !important;
    border: 1.5px solid #E5E2DC !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    transition: border-color 0.15s !important;
}
.pv-desktop input[type="text"]:focus,
.pv-desktop input[type="tel"]:focus,
.pv-desktop textarea:focus {
    border-color: var(--brand) !important;
    box-shadow: 0 0 0 3px rgba(45,106,79,0.1) !important;
    outline: none !important;
}

/* Buttons polish */
.pv-desktop button, .pv-desktop .btn {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
}

/* ═══════════════════════════════════════════
   OVERLAYS / MODALS
   ═══════════════════════════════════════════ */
.dt-overlay {
    position: fixed; inset: 0; z-index: 300;
    background: rgba(27,27,24,0.45);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.pv-desktop .overlay {
    position: fixed; inset: 0; z-index: 300;
    background: rgba(27,27,24,0.45);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    display: none;
}
.pv-desktop .overlay.show {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}
.pv-desktop .share-sheet {
    border-radius: 16px !important;
    max-height: 85vh; max-width: 500px; width: 90%;
    margin: 0 !important;
    animation: dtFadeUp 0.25s cubic-bezier(0.16,1,0.3,1);
    box-shadow: 0 24px 80px rgba(0,0,0,0.15);
}
@keyframes dtFadeUp {
    from { opacity: 0; transform: translateY(16px) scale(0.98) }
    to { opacity: 1; transform: translateY(0) scale(1) }
}

/* Notification Drawer */
.dt-notif-drawer {
    position: fixed; top: 0; right: 0;
    width: 400px; height: 100vh;
    background: #fff;
    box-shadow: -8px 0 40px rgba(0,0,0,0.1);
    display: flex; flex-direction: column;
    animation: dtSlideLeft 0.25s cubic-bezier(0.16,1,0.3,1);
}
@keyframes dtSlideLeft {
    from { transform: translateX(100%) }
    to { transform: translateX(0) }
}
.dt-notif-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 20px 24px; border-bottom: 1px solid #EDECE8;
    font-family: 'Fraunces', Georgia, serif;
    font-size: 18px; font-weight: 600; color: #1B1B18;
}
.dt-notif-header button {
    background: none; border: none; font-size: 22px;
    color: #A0A090; cursor: pointer; line-height: 1;
}
.dt-notif-body {
    flex: 1; overflow-y: auto; padding: 16px 24px;
    font-size: 13px; color: #6B6B5E; line-height: 1.6;
}

/* Story Overlay */
.pv-desktop #pv-story-overlay { position: fixed; inset: 0; z-index: 250 }
.pv-desktop #pv-story-overlay .text-xl,
.pv-desktop #pv-story-overlay .text-lg {
    font-family: 'Fraunces', Georgia, serif !important;
}

/* Toast */
.pv-desktop #pv-toast {
    position: fixed; bottom: 24px; left: 272px;
    z-index: 400; max-width: none;
    font-size: 13px; font-weight: 600;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

/* Offline banner */
.dt-offline {
    position: fixed; top: 56px; left: 248px; right: 0; z-index: 999;
    background: linear-gradient(90deg, #EF4444, #DC2626);
    color: #fff; text-align: center;
    padding: 8px; font-size: 12px; font-weight: 700;
    box-shadow: 0 2px 8px rgba(239,68,68,0.3);
}

/* ═══════════════════════════════════════════
   TYPOGRAPHY
   ═══════════════════════════════════════════ */
.pv-desktop .text-lg {
    font-family: 'Fraunces', Georgia, serif !important;
    font-size: 20px !important; font-weight: 600 !important;
}
.pv-desktop .text-xl {
    font-family: 'Fraunces', Georgia, serif !important;
    font-size: 24px !important; font-weight: 600 !important;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 1024px) {
    .dt-sidebar { width: 210px }
    .dt-main { margin-left: 210px }
    .dt-content { padding: 24px 28px }
    .dt-topbar-nav { display: none }
    .dt-offline { left: 210px }
    .pv-desktop #pv-toast { left: 230px }
    .dt-feed-title { font-size: 32px }
}

@media (max-width: 1024px) {
    .pv-desktop #pv-story-overlay { left: 210px !important }
}

/* ═══════════════════════════════════════════
   SCROLLBARS
   ═══════════════════════════════════════════ */
.pv-desktop ::-webkit-scrollbar { width: 6px; height: 6px }
.pv-desktop ::-webkit-scrollbar-track { background: transparent }
.pv-desktop ::-webkit-scrollbar-thumb { background: transparent; border-radius: 3px }
.pv-desktop *:hover::-webkit-scrollbar-thumb { background: rgba(160,160,144,0.3) }

/* ═══════════════════════════════════════════
   SPECIAL: New stories pill animation
   ═══════════════════════════════════════════ */
#pv-new-content {
    animation: pvPulseIn 0.3s cubic-bezier(0.16,1,0.3,1);
}
@keyframes pvPulseIn {
    from { opacity: 0; transform: translateX(-50%) translateY(-8px) scale(0.95) }
    to { opacity: 1; transform: translateX(-50%) translateY(0) scale(1) }
}
