/*
Theme Name: Velocity Funded GeneratePress Child
Theme URI: https://velocityfunded.com/
Description: Custom, high-performance GeneratePress Child Theme for Velocity Funded, styled beautifully like thedefiant.io.
Author: Antigravity AI
Author URI: https://velocityfunded.com/
Template: generatepress
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: gp-velocity-funded
*/

/* ==========================================
   Google Fonts Import
   ========================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap');

/* ==========================================
   CSS Variables & Design Tokens
   ========================================== */
:root {
    --bg-color: #060709;
    --card-bg: #0d0f12;
    --card-bg-hover: #12151b;
    --border-color: #1a1e24;
    --border-color-light: #252b34;
    
    --primary-glow: #00f2fe;
    --secondary-glow: #9b51e0;
    --accent-gradient: linear-gradient(135deg, var(--primary-glow) 0%, var(--secondary-glow) 100%);
    
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --white: #ffffff;
    
    --font-heading: 'Space Grotesk', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.7);
    --glow-shadow: 0 0 15px rgba(0, 242, 254, 0.15);
    
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    --container-width: 1240px;
    --header-height: 80px;
}

/* ==========================================
   Base resets & Setup
   ========================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.25;
    color: var(--white);
    margin-bottom: 0.5em;
}

/* ==========================================
   Utility Classes
   ========================================== */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

.text-gradient {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.glow-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-gradient);
    color: var(--bg-color);
    font-family: var(--font-heading);
    font-weight: 600;
    padding: 10px 22px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    letter-spacing: 0.5px;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.glow-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(0, 242, 254, 0.4);
    color: var(--bg-color);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color-light);
    font-family: var(--font-heading);
    font-weight: 500;
    padding: 10px 22px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background var(--transition-fast), border var(--transition-fast);
}

.btn-secondary:hover {
    background: var(--border-color);
    border-color: var(--primary-glow);
}

/* ==========================================
   Header & Navigation
   ========================================== */
.site-header {
    height: var(--header-height);
    background: rgba(6, 7, 9, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-logo {
    font-family: var(--font-heading);
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.site-logo span {
    font-weight: 400;
    color: var(--text-secondary);
}

.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 28px;
}

.nav-item {
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    position: relative;
    padding: 8px 0;
}

.nav-item:hover, .nav-item.active {
    color: var(--white);
}

.nav-item::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width var(--transition-fast);
}

.nav-item:hover::after, .nav-item.active::after {
    width: 100%;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--white);
}

/* ==========================================
   News Ticker
   ========================================== */
.news-ticker-bar {
    background: #000000;
    border-bottom: 1px solid var(--border-color);
    height: 36px;
    overflow: hidden;
    display: flex;
    align-items: center;
    font-size: 12px;
    font-weight: 500;
    font-family: var(--font-heading);
}

.ticker-label {
    background: var(--accent-gradient);
    color: var(--bg-color);
    padding: 0 16px;
    height: 100%;
    display: flex;
    align-items: center;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    z-index: 10;
    position: relative;
}

.ticker-content {
    display: flex;
    white-space: nowrap;
    animation: ticker 40s linear infinite;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    padding: 0 24px;
    color: var(--text-secondary);
}

.ticker-item::after {
    content: '•';
    color: var(--secondary-glow);
    margin-left: 24px;
}

@keyframes ticker {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-50%, 0, 0); }
}

/* ==========================================
   Homepage Hero Layout
   ========================================== */
.hero-editorial {
    padding: 40px 0;
    border-bottom: 1px solid var(--border-color);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.7fr 1fr;
    gap: 32px;
}

/* Featured Article Card (Left) */
.featured-story-card {
    display: flex;
    flex-direction: column;
    gap: 20px;
    cursor: pointer;
}

.featured-img-wrapper {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    aspect-ratio: 16/9;
    border: 1px solid var(--border-color);
}

.featured-img-wrapper img, .featured-img-wrapper svg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.featured-story-card:hover .featured-img-wrapper img,
.featured-story-card:hover .featured-img-wrapper svg {
    transform: scale(1.03);
}

.category-tag {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--primary-glow);
    margin-bottom: 8px;
}

.featured-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.2;
}

.featured-story-card:hover .featured-title {
    color: var(--primary-glow);
}

.featured-excerpt {
    color: var(--text-secondary);
    font-size: 15px;
    margin-bottom: 16px;
}

.post-meta-row {
    display: flex;
    align-items: center;
    gap: 16px;
    font-family: var(--font-heading);
    font-size: 12px;
    color: var(--text-muted);
}

.meta-author {
    font-weight: 600;
    color: var(--text-secondary);
}

/* Trending Stack (Right) */
.trending-column {
    display: flex;
    flex-direction: column;
    border-left: 1px solid var(--border-color);
    padding-left: 32px;
}

.section-label {
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--white);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-label::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: var(--primary-glow);
    border-radius: 50%;
}

.trending-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.trending-item {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.trending-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.trending-number {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 700;
    color: var(--border-color-light);
    line-height: 1;
}

.trending-item:hover .trending-number {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.trending-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.trending-title {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
}

.trending-item:hover .trending-title {
    color: var(--primary-glow);
}

/* ==========================================
   Newsletter CTA Banner
   ========================================== */
.newsletter-banner {
    padding: 60px 0;
    border-bottom: 1px solid var(--border-color);
    background: radial-gradient(circle at 80% 20%, rgba(155, 81, 224, 0.08) 0%, rgba(6, 7, 9, 0) 60%),
                radial-gradient(circle at 10% 80%, rgba(0, 242, 254, 0.05) 0%, rgba(6, 7, 9, 0) 50%);
}

.newsletter-box {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.newsletter-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--accent-gradient);
}

.newsletter-text {
    max-width: 500px;
}

.newsletter-text h3 {
    font-size: 24px;
    margin-bottom: 8px;
}

.newsletter-text p {
    color: var(--text-secondary);
    font-size: 14px;
}

.newsletter-form {
    display: flex;
    gap: 12px;
    flex-grow: 1;
    max-width: 480px;
}

.newsletter-form input {
    background: var(--bg-color);
    border: 1px solid var(--border-color-light);
    border-radius: 4px;
    padding: 12px 16px;
    color: var(--white);
    font-size: 14px;
    flex-grow: 1;
    transition: border var(--transition-fast);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--primary-glow);
    box-shadow: var(--glow-shadow);
}

/* ==========================================
   Editorial Card Grid & Sidebar Section
   ========================================== */
.main-feed-section {
    padding: 60px 0;
}

.feed-grid-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
}

.latest-articles-container {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.article-feed-card {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 24px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.article-feed-card:last-child {
    border-bottom: none;
}

.feed-img-wrapper {
    border-radius: 4px;
    overflow: hidden;
    aspect-ratio: 4/3;
    border: 1px solid var(--border-color);
}

.feed-img-wrapper img, .feed-img-wrapper svg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.article-feed-card:hover .feed-img-wrapper img,
.article-feed-card:hover .feed-img-wrapper svg {
    transform: scale(1.03);
}

.feed-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.feed-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.3;
}

.article-feed-card:hover .feed-title {
    color: var(--primary-glow);
}

.feed-excerpt {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Sidebar widgets */
.sidebar-wrapper {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.widget {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 24px;
}

.widget-title {
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
    margin-bottom: 16px;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 8px;
}

.widget-title::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    background: var(--secondary-glow);
    border-radius: 50%;
}

.about-widget p {
    color: var(--text-secondary);
    font-size: 13.5px;
    margin-bottom: 16px;
}

.social-links-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.social-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    padding: 10px;
    border-radius: 4px;
    font-size: 12px;
    font-family: var(--font-heading);
    font-weight: 500;
    transition: border var(--transition-fast), background var(--transition-fast);
}

.social-item:hover {
    border-color: var(--primary-glow);
    background: var(--card-bg-hover);
}

/* ==========================================
   Institutional Risk Warning & Footer
   ========================================== */
.site-footer {
    background: #030405;
    border-top: 1px solid var(--border-color);
    padding: 60px 0 30px 0;
    font-size: 13px;
    color: var(--text-muted);
}

.footer-top {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 48px;
}

.footer-brand h4 {
    font-size: 18px;
    margin-bottom: 12px;
}

.footer-brand p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.footer-links-col h5 {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    color: var(--white);
}

.footer-links-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links-col a {
    color: var(--text-secondary);
}

.footer-links-col a:hover {
    color: var(--primary-glow);
}

.risk-disclosure-box {
    background: #07080a;
    border: 1px solid var(--border-color);
    padding: 20px;
    border-radius: 4px;
    margin-bottom: 40px;
    line-height: 1.7;
}

.risk-disclosure-box h6 {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--white);
    margin-bottom: 8px;
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid #101217;
    padding-top: 24px;
}

/* ==========================================
   Mobile Nav Drawer
   ========================================== */
.mobile-nav-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 320px;
    height: 100%;
    background: #0d0f12;
    border-left: 1px solid #1a1e24;
    z-index: 9999;
    padding: 80px 24px 40px 24px;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -10px 0 30px rgba(0,0,0,0.5);
    overflow-y: auto;
}

.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(4px);
    z-index: 9998;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* ==========================================
   Skeleton Loading State Styling
   ========================================== */
.skeleton-pulse {
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

@keyframes skeleton-glow {
    0% { background: #0f1115; }
    50% { background: #1a1e25; }
    100% { background: #0f1115; }
}

.skeleton-featured {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.skeleton-featured .skeleton-img {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 6px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-tag {
    width: 120px;
    height: 12px;
    border-radius: 2px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-title {
    width: 80%;
    height: 32px;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-title-sm {
    width: 90%;
    height: 20px;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
    margin-bottom: 10px;
}

.skeleton-text {
    width: 100%;
    height: 60px;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-text-sm {
    width: 100%;
    height: 40px;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
    margin-bottom: 10px;
}

.skeleton-meta {
    width: 250px;
    height: 12px;
    border-radius: 2px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-trending {
    display: flex;
    flex-direction: column;
    border-left: 1px solid var(--border-color);
    padding-left: 32px;
    gap: 24px;
}

.skeleton-trending .skeleton-label {
    width: 150px;
    height: 16px;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-trending-item {
    height: 80px;
    border-radius: 6px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-feed-card {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 24px;
}

.skeleton-feed-img {
    aspect-ratio: 4/3;
    border-radius: 4px;
    background: #0f1115;
    animation: skeleton-glow 1.5s ease-in-out infinite;
}

.skeleton-feed-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* ==========================================
   Headless Article slide Modal (Reader Room)
   ========================================== */
.post-reader-room {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    z-index: 2000;
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow-y: hidden;
}

.post-reader-room.active {
    right: 0;
}

.reader-header {
    height: 70px;
    background: rgba(6, 7, 9, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10;
}

.reading-progress-bar {
    position: absolute;
    bottom: -1px;
    left: 0;
    height: 3px;
    background: var(--accent-gradient);
    width: 0%;
    z-index: 11;
    transition: width 0.1s ease-out;
}

.share-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
    transition: border var(--transition-fast), color var(--transition-fast);
}

.share-btn:hover {
    border-color: var(--primary-glow);
    color: var(--primary-glow);
}

.reader-article-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px auto;
}

.reader-article-headline {
    font-size: 38px;
    font-weight: 700;
    line-height: 1.15;
    margin: 16px 0 24px 0;
    color: var(--white);
}

.reader-hero-image {
    max-width: 900px;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 16/9;
    border: 1px solid var(--border-color);
    margin: 0 auto 48px auto;
}

.reader-hero-image img, .reader-hero-image svg {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.reader-body-content {
    font-size: 17px;
    line-height: 1.85;
    color: #e2e8f0;
    max-width: 740px;
    margin: 0 auto;
}

.reader-body-content p {
    margin-bottom: 24px;
}

.reader-body-content h2, .reader-body-content h3 {
    margin-top: 40px;
    margin-bottom: 16px;
}

.reader-body-content h2 {
    font-size: 26px;
}

.reader-body-content h3 {
    font-size: 20px;
}

.reader-body-content blockquote {
    border-left: 3px solid var(--primary-glow);
    padding-left: 20px;
    margin: 32px 0;
    font-style: italic;
    color: var(--white);
    font-size: 18px;
    background: rgba(0, 242, 254, 0.03);
    padding: 16px 20px 16px 24px;
    border-radius: 0 4px 4px 0;
}

.reader-body-content ul, .reader-body-content ol {
    margin-bottom: 24px;
    padding-left: 24px;
}

.reader-body-content li {
    margin-bottom: 8px;
}

/* ==========================================
   Mobile Responsive Styles
   ========================================== */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }
    
    .trending-column, .skeleton-trending {
        border-left: none;
        padding-left: 0;
        border-top: 1px solid var(--border-color);
        padding-top: 32px;
    }
    
    .feed-grid-layout {
        grid-template-columns: 1fr;
    }
    
    .sidebar-wrapper {
        border-top: 1px solid var(--border-color);
        padding-top: 40px;
    }
    
    .footer-top {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .site-header {
        height: 64px;
    }
    
    .nav-menu {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .featured-title {
        font-size: 24px;
    }
    
    .newsletter-box {
        flex-direction: column;
        padding: 24px;
    }
    
    .newsletter-form {
        width: 100%;
    }
    
    .article-feed-card, .skeleton-feed-card {
        grid-template-columns: 1fr;
    }
    
    .reader-article-headline {
        font-size: 26px;
    }
    
    .footer-top {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}
