/* Stock Market Website - Unified Style */
/* Inspired by WSJ News color scheme - bright and professional */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background-color: #f5f7fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
header {
    background: #f8f9fa;
    color: #2c3e50;
    padding: 30px 0;
    border-bottom: 2px solid #e9ecef;
    position: relative;
}

header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #1565c0 0%, #42a5f5 50%, #1565c0 100%);
    opacity: 0.3;
}

header h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 6px;
    color: #1a237e;
    letter-spacing: -0.5px;
}

header p {
    font-size: 15px;
    color: #546e7a;
    font-weight: 400;
}

/* Navigation */
nav {
    /* Funnel mode: hide navigation (homepage-centric) */
    display: none !important;
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 10px 0;
    background: rgba(255, 255, 255, 0.86);
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: none;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 18px;
    flex-wrap: nowrap;
    margin: 0;
    padding: 0;
    justify-content: center;
    align-items: center;
}

nav ul li {
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
}

nav ul li a {
    color: rgba(15, 23, 42, 0.78);
    text-decoration: none;
    font-weight: 650;
    font-size: 14px;
    letter-spacing: 0.2px;
    transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 12px;
    border-radius: 999px;
    position: relative;
    gap: 8px;
}

nav ul li a:hover {
    color: #1565c0;
    background: rgba(21, 101, 192, 0.08);
    text-decoration: none;
}

/* Active nav (premium + subtle): no big background, just a small indicator */
nav ul li a.is-active,
nav ul li a[aria-current="page"] {
    color: #0d47a1;
    background: transparent;
}

nav ul li a.is-active::after,
nav ul li a[aria-current="page"]::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 4px;
    width: 18px;
    height: 2px;
    transform: translateX(-50%);
    border-radius: 999px;
    background: rgba(13, 71, 161, 0.65);
}

nav ul li a:active {
    color: #1565c0;
    background: rgba(21, 101, 192, 0.12);
    transform: translateY(0.5px);
}

.nav-icon {
    /* Make nav minimal: hide icons (keep markup unchanged) */
    display: none !important;
}

nav ul li:nth-child(1) .nav-icon::before {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid currentColor;
    border-radius: 2px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

nav ul li:nth-child(1) .nav-icon::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: currentColor;
    top: 2px;
    left: 2px;
    border-radius: 1px;
}

nav ul li:nth-child(2) .nav-icon::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 2px;
    background: currentColor;
    top: 6px;
    left: 1px;
    box-shadow: 0 4px 0 currentColor, 0 8px 0 currentColor, 0 12px 0 currentColor;
}

nav ul li:nth-child(3) .nav-icon::before {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    border: 2px solid currentColor;
    border-top: none;
    border-radius: 0 0 2px 2px;
    top: 2px;
    left: 3px;
}

nav ul li:nth-child(3) .nav-icon::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 8px;
    background: currentColor;
    top: 4px;
    left: 9px;
}

nav ul li:nth-child(4) .nav-icon::before {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 8px solid currentColor;
    top: 4px;
    left: 4px;
}

nav ul li:nth-child(4) .nav-icon::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 2px;
    background: currentColor;
    top: 12px;
    left: 4px;
}

nav ul li a:hover .nav-icon {
    transform: translateY(-2px);
}

.nav-text {
    font-size: 14px;
    line-height: 1;
    font-weight: 650;
    letter-spacing: 0.2px;
}

/* Main Content */
main {
    padding: 0 0;
    min-height: 600px;
}

article {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    margin-bottom: 30px;
}

article h1 {
    color: #1565c0;
    font-size: 36px;
    margin-bottom: 20px;
    line-height: 1.2;
}

article h2 {
    color: #1e88e5;
    font-size: 28px;
    margin-top: 30px;
    margin-bottom: 15px;
    border-left: 4px solid #1e88e5;
    padding-left: 15px;
}

article h3 {
    color: #424242;
    font-size: 22px;
    margin-top: 25px;
    margin-bottom: 12px;
}

article p {
    margin-bottom: 15px;
    font-size: 16px;
    line-height: 1.8;
}

article ul, article ol {
    margin: 20px 0;
    padding-left: 30px;
}

article li {
    margin-bottom: 10px;
    line-height: 1.7;
}

/* Meta Information */
.meta {
    color: #757575;
    font-size: 14px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.meta span {
    margin-right: 20px;
}

/* Highlight Boxes */
.highlight-box {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border-left: 4px solid #1e88e5;
    padding: 20px;
    margin: 25px 0;
    border-radius: 4px;
}

.warning-box {
    background: #fff3e0;
    border-left: 4px solid #ff9800;
    padding: 20px;
    margin: 25px 0;
    border-radius: 4px;
}

.success-box {
    background: #e8f5e9;
    border-left: 4px solid #4caf50;
    padding: 20px;
    margin: 25px 0;
    border-radius: 4px;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

table th {
    background: linear-gradient(135deg, #1e88e5 0%, #1565c0 100%);
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

table td {
    padding: 12px;
    border-bottom: 1px solid #e0e0e0;
}

table tr:hover {
    background-color: #f5f7fa;
}

/* Footer */
footer {
    background-color: #263238;
    color: #b0bec5;
    padding: 30px 0;
    margin-top: 50px;
    text-align: center;
}

footer p {
    margin: 5px 0;
    font-size: 14px;
}

/* Links */
a {
    color: #1e88e5;
    text-decoration: none;
    transition: color 0.2s ease;
    background: transparent;
}

a:hover {
    color: #0d47a1;
    text-decoration: none;
    background: transparent !important;
}

/* Specific override for Beginner's Guide link - no background change */
.hero a[href*="tutorials/001"],
a[href*="tutorials/001"]:not(.beta-access-btn) {
    background: transparent !important;
}

.hero a[href*="tutorials/001"]:hover,
a[href*="tutorials/001"]:not(.beta-access-btn):hover {
    background: transparent !important;
    color: #0d47a1;
}

/* Hero Section - WSJ Style */
.hero {
    background: #ffffff;
    color: #2c3e50;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
    border-bottom: 1px solid #e0e0e0;
    position: relative;
}

.hero .container {
    max-width: 900px;
}

.hero h1 {
    font-size: 42px;
    font-weight: 600;
    margin-bottom: 25px;
    color: #1565c0;
    line-height: 1.2;
}

.hero p {
    font-size: 18px;
    margin-bottom: 20px;
    color: #546e7a;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.8;
    font-weight: 400;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
}

/* CTA Buttons */
.cta-button {
    display: inline-block;
    padding: 18px 40px;
    background: white;
    color: #1565c0;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 18px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    border: 2px solid white;
    cursor: pointer;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* Beta Banner Button Hover - Only for beta-access-btn */
.beta-access-btn:hover {
    background: #0d47a1 !important;
}

/* Remove background change for regular tutorial links */
a[href*="tutorials"]:not(.beta-access-btn):hover {
    background: transparent !important;
}

.cta-button:hover {
    background: #f5f5f5;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    color: #0d47a1;
}

.cta-button-secondary {
    background: transparent;
    color: #1565c0;
    border: 2px solid #1565c0;
}

.cta-button-secondary:hover {
    background: #e3f2fd;
    color: #0d47a1;
    border-color: #0d47a1;
}

/* Trust Badges - WSJ Style */
.trust-badges {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.trust-badge {
    text-align: center;
}

.trust-badge-number {
    font-size: 36px;
    font-weight: 700;
    color: #1565c0;
    display: block;
    margin-bottom: 5px;
}

.trust-badge-label {
    font-size: 14px;
    color: #757575;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Feature Icons - WSJ Style */
.feature-icon-large {
    font-size: 56px;
    margin-bottom: 20px;
    display: block;
}

/* Testimonial Section */
.testimonials {
    background: transparent;
    padding: 0;
    margin: 0;
}

.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.testimonial-card {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border-left: 3px solid #1e88e5;
}

.testimonial-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.testimonial-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #1e88e5;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 20px;
    margin-right: 15px;
}

.testimonial-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.testimonial-stars {
    color: #ff9800;
    font-size: 14px;
    margin-bottom: 10px;
}

.testimonial-text {
    color: #424242;
    line-height: 1.7;
    font-style: italic;
}

.testimonial-verified {
    font-size: 12px;
    color: #757575;
    margin-top: 10px;
}

/* Free Resource Box */
.free-resource-box {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 40px;
    margin: 50px 0;
    text-align: left;
    box-shadow: none;
}

.free-resource-box h2 {
    color: #e65100;
    font-size: 36px;
    margin-bottom: 20px;
    font-weight: 700;
}

.free-resource-box p {
    font-size: 20px;
    color: #5d4037;
    margin-bottom: 30px;
    line-height: 1.8;
}

.resource-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
    text-align: left;
}

.resource-item {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.resource-item strong {
    color: #e65100;
    font-size: 18px;
    display: block;
    margin-bottom: 10px;
}

/* Stats Section */
.stats-section {
    background: #f5f7fa;
    padding: 60px 0;
    margin: 50px 0;
    border-radius: 15px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    text-align: center;
}

.stat-item {
    padding: 20px;
}

.stat-number {
    font-size: 48px;
    font-weight: 700;
    color: #1565c0;
    display: block;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 16px;
    color: #757575;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Feature Cards Enhanced */
.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin: 50px 0;
}

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s;
    border-left: 3px solid #1565c0;
    border-top: none;
}

.feature-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    transform: none;
}

.feature-card-icon {
    font-size: 48px;
    margin-bottom: 20px;
    display: block;
}

.feature-card h3 {
    color: #1565c0;
    font-size: 20px;
    margin-bottom: 15px;
    font-weight: 600;
}

.feature-card p {
    color: #424242;
    line-height: 1.7;
    margin-bottom: 15px;
    font-size: 15px;
}

/* Responsive */
@media (max-width: 768px) {
    article {
        padding: 25px;
    }
    
    article h1 {
        font-size: 28px;
    }
    
    article h2 {
        font-size: 24px;
    }
    
    nav {
        padding: 8px 0;
    }
    
    nav ul {
        justify-content: flex-start;
        gap: 10px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0 2px;
        scrollbar-width: none; /* Firefox */
    }

    nav ul::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }
    
    nav ul li {
        flex: 0 0 auto;
        border-right: none;
        background: transparent;
    }
    
    nav ul li a {
        padding: 10px 12px;
        border-radius: 999px;
        white-space: nowrap;
    }
    
    .nav-text {
        font-size: 13px;
        font-weight: 650;
        letter-spacing: 0.2px;
        line-height: 1.0;
    }
    
    .hero h1 {
        font-size: 28px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-button {
        width: 90%;
        max-width: 300px;
    }
    
    .free-resource-box {
        padding: 30px 20px;
    }
    
    .free-resource-box h2 {
        font-size: 28px;
    }
    
    header h1 {
        font-size: 26px;
    }
    
    header p {
        font-size: 13px;
    }
    
    section[style*="padding: 40px"] {
        padding: 25px 20px !important;
    }
    
    section[style*="padding: 50px"] {
        padding: 30px 20px !important;
    }
}

/* Article List Styles */
.article-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.article-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}

.article-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.article-card h3 {
    color: #1565c0;
    margin-bottom: 10px;
    font-size: 20px;
}

.article-card p {
    color: #757575;
    font-size: 14px;
    margin-bottom: 15px;
}

.article-card .category {
    display: inline-block;
    background: #e3f2fd;
    color: #1565c0;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 10px;
}

/* Access Denied Modal Styles */
.access-denied-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.access-denied-modal {
    background: white;
    border-radius: 12px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    text-align: center;
    animation: slideUp 0.3s ease;
    position: relative;
}

.access-denied-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: #ffebee;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #c62828;
}

.access-denied-modal h3 {
    color: #2c3e50;
    font-size: 24px;
    margin-bottom: 15px;
    font-weight: 600;
}

.access-denied-modal p {
    color: #757575;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 25px;
}

.access-denied-modal .close-btn {
    background: #1565c0;
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s ease;
}

.access-denied-modal .close-btn:hover {
    background: #0d47a1;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .access-denied-modal {
        padding: 30px 20px;
        margin: 20px;
    }
    
    .access-denied-modal h3 {
        font-size: 20px;
    }
    
    .access-denied-modal p {
        font-size: 14px;
    }
}

/* Stock Market Data Styles */
.market-indices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 30px 0;
    padding: 25px;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.index-item {
    padding: 15px;
    border-left: 3px solid #1565c0;
    background: #f8f9fa;
    border-radius: 4px;
}

.index-name {
    display: flex;
    flex-direction: column;
    margin-bottom: 10px;
}

.index-name strong {
    font-size: 18px;
    color: #1565c0;
    font-weight: 700;
}

.index-full-name {
    font-size: 12px;
    color: #757575;
    margin-top: 2px;
}

.index-price {
    font-size: 24px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.index-change {
    font-size: 14px;
    font-weight: 600;
}

.index-change.positive {
    color: #2e7d32;
}

.index-change.negative {
    color: #c62828;
}

/* Stock Ticker */
.stock-ticker-container {
    background: #263238;
    color: white;
    padding: 15px 0;
    overflow: hidden;
    margin: 0 0 20px 0;
    border-radius: 4px;
    position: relative;
}

.ticker-item--clickable {
    border: none;
    background: transparent;
    cursor: pointer;
    text-align: left;
    position: relative;
    padding-right: 28px;
    border-radius: 6px;
}

.ticker-item--clickable:hover {
    background: rgba(255, 255, 255, 0.08);
}

.ticker-item--clickable:active {
    background: rgba(255, 255, 255, 0.12);
}

.ticker-item--clickable:focus-visible {
    outline: 3px solid rgba(66, 165, 245, 0.65);
    outline-offset: 2px;
    border-radius: 6px;
}

.stock-ticker {
    display: flex;
    gap: 30px;
    animation: scroll 40s linear infinite;
    width: fit-content;
}

/* Mobile adjustments for stock ticker - keep animation but ensure it works */
@media (max-width: 768px) {
    .stock-ticker-container {
        overflow: hidden; /* Keep hidden to show animation */
        position: relative;
    }
    
    .stock-ticker-container .container {
        overflow: hidden; /* Keep hidden to show animation */
        position: relative;
    }
    
    .stock-ticker {
        /* Keep animation on mobile - it should work */
        animation: scroll 40s linear infinite;
        will-change: transform; /* Optimize animation performance */
        -webkit-transform: translateZ(0); /* Force hardware acceleration */
        transform: translateZ(0);
    }
    
    .ticker-item {
        padding: 0 12px; /* Slightly reduce padding on mobile */
        font-size: 14px; /* Slightly smaller text on mobile */
    }
    
    .ticker-symbol {
        font-size: 14px;
    }
    
    .ticker-price {
        font-size: 13px;
    }
    
    .ticker-change {
        font-size: 12px;
    }
}

.ticker-item {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    padding: 0 15px;
}

.ticker-symbol {
    font-weight: 700;
    font-size: 16px;
    color: #ffffff;
}

.ticker-price {
    font-size: 15px;
    color: #ffffff;
}

.ticker-change {
    font-size: 14px;
    font-weight: 600;
}

.ticker-change.positive {
    color: #4caf50;
}

.ticker-change.negative {
    color: #f44336;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Ensure ticker container hides overflow properly */
.stock-ticker-container .container {
    overflow: hidden;
    position: relative;
}

/* Top Gainers/Losers */
.gainers-losers {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.gainers-section,
.losers-section {
    background: #ffffff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.gainers-section h3,
.losers-section h3 {
    color: #1565c0;
    font-size: 20px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e0e0e0;
}

.stock-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.stock-item--clickable {
    border: none;
    background: transparent;
    cursor: pointer;
    width: 100%;
    text-align: left;
    position: relative;
    padding-right: 28px;
    border-radius: 8px;
}

.stock-item--clickable:hover {
    background: rgba(21, 101, 192, 0.06);
}

.stock-item--clickable:active {
    background: rgba(21, 101, 192, 0.10);
}

.stock-item--clickable:focus-visible {
    outline: 3px solid rgba(66, 165, 245, 0.65);
    outline-offset: 2px;
    border-radius: 6px;
}

.stock-intent-chevron {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    opacity: 0.55;
    pointer-events: none;
}

.stock-item--clickable:hover .stock-intent-chevron,
.ticker-item--clickable:hover .stock-intent-chevron {
    opacity: 0.85;
}

.stock-click-hint {
    font-size: 12px;
    color: #757575;
    margin: -10px 0 10px 0;
}

/* Urgency micro-animations (safe: not fake scarcity, just next update window) */
.urgency-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4caf50;
    margin-right: 8px;
    box-shadow: 0 0 0 rgba(76, 175, 80, 0.0);
    animation: urgency-pulse 1.2s ease-in-out infinite;
    vertical-align: middle;
}

@keyframes urgency-pulse {
    0%   { opacity: 0.55; box-shadow: 0 0 0 0 rgba(76,175,80,0.0); }
    50%  { opacity: 1;    box-shadow: 0 0 0 6px rgba(76,175,80,0.12); }
    100% { opacity: 0.55; box-shadow: 0 0 0 0 rgba(76,175,80,0.0); }
}

/* Quote card (search -> show quote -> prompt analysis) */
.quote-card {
    margin-top: 14px;
    padding: 14px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.10);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.95);
}

.quote-card__top {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: baseline;
}

.quote-card__symbol {
    font-weight: 900;
    font-size: 18px;
    letter-spacing: 0.4px;
}

.quote-card__name {
    font-size: 12px;
    opacity: 0.9;
    text-align: right;
    max-width: 65%;
}

.quote-card__mid {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
    margin-top: 8px;
}

.quote-card__price {
    font-weight: 900;
    font-size: 26px;
    letter-spacing: -0.3px;
}

.quote-card__change {
    font-weight: 900;
    font-size: 14px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.10);
    border: 1px solid rgba(255,255,255,0.16);
}

.quote-card__change--up {
    color: #b9f6ca;
}

.quote-card__change--down {
    color: #ff8a80;
}

.quote-card__meta {
    margin-top: 8px;
    font-size: 12px;
    opacity: 0.85;
}

.quote-card__actions {
    margin-top: 12px;
    display: flex;
    justify-content: center;
}

.quote-card__analyze-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    font-weight: 900;
    background: white;
    color: #1565c0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.18);
}

.quote-card__analyze-btn--pulse {
    animation: quote-cta-pulse 1.2s ease-in-out infinite;
}

@keyframes quote-cta-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

@media (max-width: 768px) {
    .quote-card__mid {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .quote-card__name {
        max-width: 100%;
        text-align: left;
    }
}

.stock-item:last-child {
    border-bottom: none;
}

.stock-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.stock-info strong {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 700;
}

.stock-name {
    font-size: 12px;
    color: #757575;
    margin-top: 2px;
}

.stock-price {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-right: 15px;
}

.stock-change {
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.stock-change.positive {
    color: #2e7d32;
}

.stock-change.negative {
    color: #c62828;
}

/* Market Summary Section */
.market-summary {
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 40px;
    border-radius: 8px;
    margin: 30px 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.market-summary h2 {
    color: white;
    font-size: 28px;
    margin-bottom: 25px;
    font-weight: 700;
}

/* News Headlines */
.news-headlines {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

/* News list "Load more" (conversion link) */
.news-load-more {
    display: flex;
    justify-content: center;
    margin: 8px 0 0 0;
}

.news-load-more__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #1565c0;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.1px;
    padding: 8px 10px;
    border-radius: 999px;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.news-load-more__link:hover {
    background: rgba(21, 101, 192, 0.08);
    color: #0d47a1;
    transform: translateY(-1px);
}

.news-load-more__link:active {
    transform: translateY(0);
    background: rgba(21, 101, 192, 0.12);
}

.news-load-more__link:focus-visible {
    outline: 3px solid rgba(66, 165, 245, 0.65);
    outline-offset: 2px;
}

/* Live news refresh banner (shown when new headlines arrive) */
.news-refresh-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(21, 101, 192, 0.08);
    border: 1px solid rgba(21, 101, 192, 0.18);
    margin: 10px 0 16px 0;
}

.news-refresh-banner[hidden] {
    display: none !important;
}

.news-refresh-banner__text {
    font-size: 13px;
    font-weight: 700;
    color: #0d47a1;
}

.news-refresh-banner__actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.news-refresh-banner__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 999px;
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    font-weight: 800;
    font-size: 13px;
}

.news-refresh-banner__btn--secondary {
    background: rgba(21, 101, 192, 0.10);
    color: #0d47a1;
    border: 1px solid rgba(21, 101, 192, 0.22);
}

.news-refresh-banner__btn--secondary:hover {
    background: rgba(21, 101, 192, 0.14);
}

/* Primary CTA pill (used in homepage section headers) */
.cta-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 900;
    font-size: 14px;
    letter-spacing: 0.2px;
    transition: transform 0.18s ease, filter 0.18s ease, box-shadow 0.18s ease;
    user-select: none;
}

.cta-pill--primary {
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: #ffffff;
    box-shadow: 0 10px 22px rgba(13, 71, 161, 0.20);
}

.cta-pill--primary:hover {
    transform: translateY(-1px);
    filter: brightness(1.03);
    box-shadow: 0 14px 28px rgba(13, 71, 161, 0.24);
}

.cta-pill--primary:active {
    transform: translateY(0);
    filter: brightness(0.98);
}

.cta-pill--minimal {
    background: transparent;
    color: #0d47a1;
    border: 1px solid rgba(13, 71, 161, 0.28);
    box-shadow: none;
    padding: 8px 12px;
    font-weight: 800;
}

.cta-pill--minimal:hover {
    background: rgba(21, 101, 192, 0.06);
    transform: none;
    filter: none;
    box-shadow: none;
}

.cta-pill--minimal:active {
    background: rgba(21, 101, 192, 0.10);
}

.cta-pill:focus-visible {
    outline: 3px solid rgba(66, 165, 245, 0.65);
    outline-offset: 2px;
}

@media (max-width: 768px) {
    .cta-pill {
        padding: 9px 12px;
        font-size: 13px;
    }
}

.headline-card {
    background: #ffffff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border-left: 4px solid #1565c0;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.headline-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.12);
}

.headline-time {
    font-size: 12px;
    color: #757575;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.headline-title {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
    line-height: 1.4;
}

.headline-title a {
    color: #2c3e50;
    text-decoration: none;
    transition: color 0.2s ease;
}

.headline-title a:hover {
    color: #1565c0;
}

.headline-excerpt {
    font-size: 14px;
    color: #757575;
    line-height: 1.6;
}

/* Market Status Badge */
.market-status {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 15px;
}

.market-status.open {
    background: #4caf50;
    color: white;
}

.market-status.closed {
    background: #757575;
    color: white;
}

.market-status.pre-market {
    background: #ff9800;
    color: white;
}

/* Responsive adjustments for stock data */
@media (max-width: 768px) {
    .market-indices {
        grid-template-columns: 1fr;
        padding: 10px;
        gap: 10px;
        margin: 15px 0;
    }
    
    .index-item {
        padding: 10px;
    }
    
    .index-name {
        margin-bottom: 6px;
    }
    
    .index-name strong {
        font-size: 16px;
    }
    
    .index-full-name {
        font-size: 11px;
    }
    
    .index-price {
        font-size: 20px;
        margin-bottom: 3px;
    }
    
    .index-change {
        font-size: 13px;
    }
    
    .gainers-losers {
        grid-template-columns: 1fr;
        gap: 15px;
        margin: 15px 0;
    }
    
    .stock-ticker {
        gap: 20px;
    }
    
    .ticker-item {
        padding: 0 10px;
    }
    
    .market-summary {
        padding: 12px 15px;
        margin: 12px 0;
    }
    
    .market-summary h2 {
        font-size: 18px;
        margin-bottom: 10px;
    }
    
    .market-summary-header {
        margin-bottom: 10px !important;
    }
    
    .market-summary > div[style*="margin-bottom: 20px"] {
        margin-bottom: 10px !important;
    }
    
    .market-status {
        padding: 4px 10px;
        font-size: 11px;
        margin-bottom: 0;
    }
    
    .news-headlines {
        grid-template-columns: 1fr;
        gap: 15px;
        margin: 20px 0;
    }
}

/* Join Group Widget Styles */
.join-group-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Sticky CTA Bar (site-wide) */
.ws-cta-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
    background: rgba(38, 50, 56, 0.96);
    color: #ffffff;
    border-top: 1px solid rgba(255,255,255,0.12);
    transform: translateY(110%);
    transition: transform 0.28s ease;
    padding: 12px 0;
}

.ws-cta-bar.ws-cta-bar--show {
    transform: translateY(0);
}

.ws-cta-bar__inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.ws-cta-bar__copy {
    min-width: 0;
}

.ws-cta-bar__title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.25;
}

.ws-cta-bar__sub {
    font-size: 12px;
    opacity: 0.85;
    margin-top: 4px;
    line-height: 1.25;
}

.ws-cta-bar__countdown {
    display: inline-flex;
    align-items: center;
    gap: 0;
    margin-left: 10px;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.10);
    border: 1px solid rgba(255, 255, 255, 0.12);
    white-space: nowrap;
}

.ws-cta-bar__countdown #wsCtaCountdown {
    font-weight: 700;
    opacity: 0.95;
}

.join-group-urgency {
    margin: 12px 0 14px 0;
    font-size: 12px;
    color: #546e7a;
    display: flex;
    align-items: center;
}

/* Content gate (unlock after landing click) */
.content-gate {
    position: relative;
}

.content-gate [data-gate-locked][hidden] {
    display: none !important;
}

.content-gate__overlay[hidden] {
    display: none !important;
}

.content-gate__overlay {
    position: relative;
    margin-top: 20px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.10);
    background: linear-gradient(180deg, rgba(255,255,255,0.65) 0%, rgba(245,247,250,0.95) 100%);
}

.content-gate__blur {
    height: 140px;
    background: linear-gradient(180deg, rgba(255,255,255,0.0) 0%, rgba(245,247,250,0.95) 85%);
}

.content-gate__cta {
    padding: 18px 18px 20px 18px;
    text-align: center;
}

.content-gate__title {
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 8px;
}

.content-gate__desc {
    font-size: 14px;
    color: #475569;
    line-height: 1.5;
    margin-bottom: 14px;
}

.content-gate__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    font-weight: 800;
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    box-shadow: 0 10px 25px rgba(21, 101, 192, 0.25);
}

.content-gate__btn:hover {
    filter: brightness(1.05);
}

.ws-cta-bar__actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.ws-cta-bar__btn {
    border: none;
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(21, 101, 192, 0.25);
}

.ws-cta-bar__btn:hover {
    filter: brightness(1.05);
}

.ws-cta-bar__close {
    border: none;
    background: rgba(255,255,255,0.12);
    color: white;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ws-cta-bar__close:hover {
    background: rgba(255,255,255,0.18);
}

/* When CTA bar is visible, lift the floating widget so they don't overlap */
.ws-cta-bar-visible .join-group-widget {
    bottom: 88px;
}

@media (max-width: 768px) {
    .ws-cta-bar__inner {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .ws-cta-bar__actions {
        justify-content: space-between;
    }

    .ws-cta-bar__btn {
        width: 100%;
        justify-content: center;
    }

    .ws-cta-bar-visible .join-group-widget {
        bottom: 92px;
        right: 15px;
    }
}

.join-group-toggle {
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 14px 20px;
    border-radius: 50px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 20px rgba(21, 101, 192, 0.4);
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 15px;
    white-space: nowrap;
    animation: pulse-glow 2s ease-in-out infinite;
}

.join-group-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(21, 101, 192, 0.5);
}

.join-group-icon {
    font-size: 20px;
    display: inline-block;
}

.join-group-text {
    display: inline-block;
}

.join-group-card {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 360px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.join-group-widget.active .join-group-card {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.join-group-card-header {
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 18px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.join-group-card-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
    pointer-events: none;
}

.join-group-card-header h4,
.join-group-card-header button {
    position: relative;
    z-index: 1;
}

.join-group-card-header h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.join-group-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 0;
}

.join-group-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.join-group-card-body {
    padding: 24px 20px;
}

.join-group-description {
    color: #424242;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 20px 0;
}

.join-group-benefits {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.join-group-benefit {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: #546e7a;
}

.benefit-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.join-group-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 14px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.3);
    width: 100%;
    box-sizing: border-box;
}

.join-group-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(21, 101, 192, 0.4);
}

.join-group-note {
    margin: 12px 0 0 0;
    font-size: 11px;
    color: #9e9e9e;
    text-align: center;
    line-height: 1.5;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 4px 20px rgba(21, 101, 192, 0.4);
    }
    50% {
        box-shadow: 0 4px 25px rgba(21, 101, 192, 0.6);
    }
}

/* Additional button style for stock analyzer */
.join-group-analyze-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(21, 101, 192, 0.3);
    width: 100%;
    box-sizing: border-box;
    border: none;
    cursor: pointer;
    margin-top: 12px;
}

.join-group-analyze-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(21, 101, 192, 0.4);
}

/* Responsive adjustments for join group widget */
@media (max-width: 768px) {
    .join-group-widget {
        bottom: 15px;
        right: 15px;
    }
    
    .join-group-toggle {
        padding: 12px 16px;
        font-size: 14px;
    }
    
    .join-group-text {
        display: none;
    }
    
    .join-group-card {
        position: fixed;
        width: 90%;
        max-width: 450px;
        bottom: auto;
        right: auto;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -45%) scale(0.95);
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255, 255, 255, 0.1);
        z-index: 10001;
        max-height: 85vh;
        overflow-y: auto;
        border-radius: 20px;
    }
    
    .join-group-widget.active .join-group-card {
        transform: translate(-50%, -50%) scale(1);
    }
    
    .join-group-toggle:hover {
        transform: none;
    }
    
    /* Add backdrop overlay on mobile when card is active */
    .join-group-widget.active::after {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        z-index: 10000;
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        animation: fadeIn 0.3s ease;
    }
    
    @keyframes fadeIn {
        from {
            opacity: 0;
        }
        to {
            opacity: 1;
        }
    }
    
    /* Ensure card content is scrollable if needed */
    .join-group-card-body {
        max-height: calc(85vh - 120px);
        overflow-y: auto;
    }
}
