/*
 * This is the main stylesheet for the EarningsIQ website.
 * It implements the visual design system with a clean, professional aesthetic
 * focused on readability and mobile-first responsive design.
 * 
 * Color Palette:
 * - Background: #FEFCF9
 * - Primary Text: #040F10
 * - Secondary Text: #1F1F1D
 * - Accent/Button: #264A6E
 */

/* Base styles and reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --header-offset: 60px;
    --pin-stripe-height: 15px;
}

body {
    font-family: 'Inter', 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    font-size: 16px;
    background-color: #F2F6FC; /* Match Hero Design 2 background */
    color: #22305A; /* Match Hero Design 2 text color */
    padding-top: 5rem; /* Add padding to account for fixed header */
    margin: 0;
    padding: 0;
}

body.menu-open,
body.modal-open {
    overflow: hidden;
}

.nav-pin-stripe {
    background-color: #22305A;
    height: var(--pin-stripe-height);
    width: 100%;
    margin-top: var(--header-offset);
    position: relative;
    z-index: 99;
}

/* Set paragraph and list item font size on homepage */
p, .what-you-get li {
    font-size: 1.25rem;
}

.container {
    width: 95%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 10px;
}

/* Specific styling for the header container to reduce margins */
header .container {
    width: 96%;
    padding: 0 2px;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.hero.hero-minimal {
    padding: 3rem 0;
    background: #F2F6FC;
    position: relative;
}

.hero-minimal .hero-content {
    max-width: 900px;
    margin: 0 auto;
}

.hero-minimal .hero-text {
    text-align: center;
}

.hero-minimal h1 {
    letter-spacing: -0.04em;
    font-size: 4rem;
    margin-bottom: 2rem;
    background: linear-gradient(90deg, #22305A, #4D71F7);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-minimal p {
    font-size: 1.5rem;
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto 2rem;
    color: #22305A;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #264A6E;
    letter-spacing: -0.02em;
    border-bottom: 2px solid rgba(77, 113, 247, 0.2);
    padding-bottom: 0.5rem;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1.5rem;
}

a {
    color: #264A6E;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #1a3550;
}

ul {
    list-style-position: inside;
    margin-bottom: 1.5rem;
}

li {
    margin-bottom: 0.5rem;
}

/* Header and Navigation */
header {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    background: #ffffff;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(77, 113, 247, 0.08);
    transition: all 0.3s ease;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Left side of navigation (logo and links) */
.nav-left {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    flex: 1;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: #22305A;
    text-decoration: none;
    letter-spacing: -0.03em;
    transition: transform 0.3s ease, opacity 0.3s ease;
    padding: 0.5rem 0;
    display: flex;
    align-items: center;
}

.logo-text {
    color: #22305A;
    letter-spacing: -0.03em;
    font-weight: 700;
    font-size: 1.5rem;
    transition: font-size 0.3s ease;
}

.logo:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Navigation links */
.nav-links {
    display: flex;
    gap: 1.5rem;
}

.nav-link {
    text-decoration: none;
    color: #22305A;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
}

.nav-link:after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: #4D71F7;
    transition: width 0.3s ease;
}

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

.nav-link:hover, .nav-link.active {
    color: #4D71F7;
}

.earnings-list a {
    text-decoration: none;
    color: #22305A;
    font-weight: 500;
    transition: color 0.2s ease;
}

.earnings-list a:hover {
    color: #4D71F7;
    text-decoration: underline;
}

/* Right side of navigation (links and buttons) */
.nav-right {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-left: 0.8rem;
    padding-right: .3rem;
}

/* Spacing for navigation elements is handled by the gap property in .nav-right */

/* Enhanced search bar */
.search-bar {
    position: relative;
    width: 400px !important; /* Wider search bar */
    display: flex;
    margin-right: 0;
}

.search-bar input {
    width: 100%;
    padding: 0 3rem 0 0.6rem;
    border: 1px solid #22305A;
    border-radius: 8px;
    font-size: 1.0rem;
    color: #22305A;
    background-color: rgba(242, 246, 252, 0.5);
    transition: all 0.3s ease;
    height: 48px; /* Slightly reduced height */
    box-sizing: border-box;
    line-height: 46px;
    box-shadow: 0 2px 6px rgba(77, 113, 247, 0.05);
}

.search-bar input:focus {
    outline: none;
    border-color: #22305A;
    background-color: #fff;
    box-shadow: 0 2px 6px rgba(34, 48, 90, 0.1);
}

.search-button {
    position: absolute;
    right: 0.25rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #22305A;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.search-button:hover {
    color: #22305A;
    transform: translateY(-50%) scale(1.1);
}

/* Ticker search dropdown styles */
.search-results-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.search-result-item {
    padding: 10px 15px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
}

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

.search-result-item:hover,
.search-result-item.active {
    background-color: #f5f5f5;
}

.ticker-symbol {
    font-weight: bold;
    margin-right: 5px;
}

.search-result-date {
    font-size: 0.75rem;
    color: #9aa0a6;
    margin-top: 4px;
    line-height: 1.2;
}

.no-results {
    padding: 10px 15px;
    color: #666;
    font-style: italic;
}

/* Sign-in button - styled to match CTA button */
/* Navigation CTA button */
.sign-in-btn {
    display: inline-block;
    background: #3A5CD9;
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: none;
    letter-spacing: 0.01em;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(77, 113, 247, 0.2);
}

.sign-in-btn:hover {
    background: #2F4DB8;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(77, 113, 247, 0.3);
}

/* Hero Section */
.hero {
    padding: 4rem 0;
    background-color: #F2F6FC;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.hero-text {
    max-width: 800px;
    text-align: center;
    padding: 1rem 0;
}

/* Special styling for hero-alt (Hero Design 2) */
.hero-alt .hero-content {
    justify-content: space-between;
    gap: 3rem;
}

.hero-alt .hero-text {
    max-width: 600px;
    text-align: left;
}

.hero h1 {
    font-size: 3.2rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: #22305A;
    letter-spacing: -0.04em;
}

.subhead {
    font-size: 1.5rem;
    color: #1F1F1D;
    max-width: 700px;
    margin: 0 auto 2.5rem;
    line-height: 1.5;
    font-weight: 400;
}

.cta-block {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.cta-block p {
    margin-bottom: 1.5rem;
}

/* Homepage CTA button - larger and more compelling than nav button */
.cta-button {
    display: inline-block;
    background: #3A5CD9;
    color: white;
    padding: 0.75rem 2rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.2rem;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    border: none;
    margin-top: 1.5rem;
    letter-spacing: 0.01em;
    box-shadow: 0 6px 15px rgba(77, 113, 247, 0.25);
}

.cta-button:hover {
    background: #2F4DB8;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(77, 113, 247, 0.3);
}


.learn-more-link:hover {
    color: #3A5CD9;
    transform: translateX(2px);
}

/* Content Sections */
.this-week {
    padding: 1rem 0;
    border-bottom: 1px solid #FFFFFF;
    background: #ffffff;
}

.what-is {
    padding: 4rem 0;
    border-bottom: 1px solid #FFFFFF;
    background: #ffffff;
}

/* Global h2 styling is now applied to this-week */
.what-is h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: #22305A;
    letter-spacing: -0.03em;
}

.this-week, .what-is, .sector-articles {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 992px) {
    .defer-render {
        content-visibility: auto;
        contain-intrinsic-size: 1px 900px;
    }
}

.what-is p {
    max-width: 700px;
}

/* Redesigned Benefits Section (What You Get) */
.benefits-section {
    padding: 5rem 0;
    background: #ffffff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.5rem;
    color: #22305A;
    letter-spacing: -0.04em;
    margin-bottom: 1rem;
    font-weight: 700;
}

.section-divider {
    height: 4px;
    width: 60px;
    background: linear-gradient(90deg, #22305A, #4D71F7);
    margin: 0 auto;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    margin-top: 2rem;
}

.benefit-card {
    background: #ffffff;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
}

.benefit-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: linear-gradient(135deg, #22305A, #4D71F7);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.8rem;
}

.benefit-card h3 {
    font-size: 1.5rem;
    color: #22305A;
    margin-bottom: 1rem;
    letter-spacing: -0.03em;
}

.benefit-card p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #555;
}

/* Redesigned Impact Section (Why It Matters) */
.impact-section {
    padding: 5rem 0;
    background: #F2F6FC;
}

.impact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

/* Centered Impact Section (Why It Matters) */
.impact-wrapper-centered {
    max-width: 800px;
    margin: 0 auto;
}

.impact-content-centered .section-header {
    text-align: center;
}

.impact-content-centered .section-header h2 {
    font-size: 3rem; /* Increased from 2.5rem */
}

.impact-content-centered .section-divider {
    margin: 0 auto;
    margin-bottom: 2.5rem; /* Increased from 2rem */
    height: 5px; /* Increased from 4px */
    width: 80px; /* Increased from 60px */
}

.impact-content-centered .impact-lead {
    text-align: center;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    font-size: 1.7rem; /* Increased from 1.4rem */
    margin-bottom: 3rem; /* Increased from 2.5rem */
}

.impact-content-centered .impact-points {
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    flex-direction: column;
    gap: 2.5rem; /* Increased from 1.5rem */
}

.impact-content-centered .impact-number {
    font-size: 2.2rem; /* Increased from 1.8rem */
}

.impact-content-centered .impact-point p {
    font-size: 1.3rem; /* Increased from 1.1rem */
    line-height: 1.7; /* Increased from 1.6 */
}

.impact-content .section-header {
    text-align: left;
}

.impact-content .section-divider {
    margin: 0;
    margin-bottom: 2rem;
}

.impact-lead {
    font-size: 1.4rem;
    line-height: 1.6;
    color: #22305A;
    margin-bottom: 2.5rem;
    font-weight: 500;
}

.impact-points {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.impact-point {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
}

.impact-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: #4D71F7;
    line-height: 1;
    min-width: 40px;
}

.impact-point p {
    font-size: 1.15rem;
    line-height: 1.6;
    color: #444;
    margin: 0;
}

.impact-image img {
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}





/* Earnings List */
.earnings-list {
    margin-top: 1.5rem;
}

.earnings-list ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.earnings-list li {
    margin-bottom: 1.2rem;
    padding-left: 1.5rem;
    position: relative;
    display: flex;
    flex-wrap: wrap;
}

.earnings-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    top: 0;
    color: #4D71F7;
    font-size: 1.2rem;
    line-height: 1.5;
}

.earnings-list a {
    display: block;
    font-weight: 500;
    color: #264A6E;
    transition: color 0.2s ease;
    padding: 0.1rem 0;
    font-size: 1.35rem;
    line-height: 1.5;
}

.earnings-list a:hover {
    color: #1a3550;
}

.earnings-list .snippet-preview {
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.25rem;
    line-height: 1.4;
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-left: 0.5rem;
    border-left: 2px solid #FFFFFF;
}



.earnings-list .snippet-preview {
    font-size: 0.9rem;
    line-height: 1.4;
    margin-top: 0.3rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.earnings-article, .spotlight, .theme, .company {
    padding: 1.5rem;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 4px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.earnings-article:hover, .spotlight:hover, .theme:hover, .company:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

/* Sector Articles Section */
.sector-articles {
    padding: 2rem 0;
    background-color: #ffffff;
    border-bottom: 1px solid rgba(77, 113, 247, 0.1);
}

/* Global h2 styling is now applied to sector-articles */

.sector-articles .this-week h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #264A6E;
    letter-spacing: -0.02em;
    border-bottom: 2px solid rgba(77, 113, 247, 0.2);
    padding-bottom: 0.5rem;
}





/* Newsletter Section */
.newsletter {
    background-color: #F2F6FC;
    padding: 4rem 0;
    color: #22305A;
    margin-top: 3rem;
    border-top: 1px solid rgba(77, 113, 247, 0.1);
    border-bottom: 1px solid rgba(77, 113, 247, 0.1);
}

/* Newsletter Section with Blue Gradient */
.newsletter-blue-gradient {
    background: linear-gradient(135deg, #264A6E 0%, #3A5CD9 100%);
    padding: 4rem 0;
    color: white;
    margin-top: 3rem;
}

.newsletter-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.newsletter-logo img {
    max-width: 280px;
    height: auto;
}

.newsletter-logo .white-logo {
    max-width: 280px;
    height: auto;
}

.newsletter h2, .newsletter-blue-gradient h2 {
    max-width: 700px;
    margin: 0 auto 1.5rem;
    font-size: 3.5rem;
    line-height: 1.2;
    letter-spacing: -0.04em;
    text-align: center;
    transition: all 0.3s ease;
    color: #FFFFFF;
}

/* Specific style for "Stay Strategically Informed" h2 */
.newsletter h2.stay-informed {
    color: #22305A;
    border-bottom: none;
    padding-bottom: 0;
}

.newsletter .subtitle, .newsletter-blue-gradient .subtitle {
    max-width: 640px;
    margin: 0 auto 2rem;
    font-size: 1.5rem;
    line-height: 1.5;
    text-align: center;
}

.subscribe-form {
    display: flex;
    max-width: 640px;
    margin: 0 auto 1rem;
    width: 100%;
    box-shadow: 0 4px 20px rgba(77, 113, 247, 0.1);
}

.subscribe-form input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid #22305A;
    border-radius: 8px 0 0 8px;
    font-family: inherit;
    font-size: 1.25rem;
    background-color: #FFFFFF;
    color: #22305A;
    width: 100%;
}

.subscribe-form .dispatch-button {
    border-radius: 0 8px 8px 0;
    padding: 1rem 1.5rem;
    background-color: #22305A;
    color: #FFFFFF;
    font-weight: 600;
    font-size: 1.25rem;
    border: 2px solid #22305A;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.newsletter .footnote {
    font-size: 1rem;
    margin-top: 1rem;
    opacity: 0.7;
    text-align: center;
    color: #22305A;
}

.newsletter-blue-gradient .footnote {
    font-size: 1rem;
    margin-top: 1rem;
    opacity: 0.9;
    text-align: center;
    color: white;
}

.subscribe-actions {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

.subscribe-actions .cta-button {
    padding: 0.75rem 2rem;
    font-size: 1.125rem;
}

/* Account Modal Styles */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000; /* Higher than article limit banner */
    overflow-y: auto;
}

.modal-content {
    position: relative;
    background-color: #fff;
    margin: 5% auto;
    max-width: 1000px;
    width: 90%;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    font-weight: bold;
    color: #666;
    cursor: pointer;
    z-index: 10;
}

.modal-container {
    display: flex;
    flex-direction: row;
}

.signup-form, .login-form {
    flex: 1;
    padding: 2rem;
    max-width: 450px;
}

.login-container {
    display: flex;
    justify-content: center;
    width: 100%;
}

.signup-form h2 {
    margin-bottom: 1.5rem;
    font-size: 1.75rem;
}

.social-signup {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.social-btn img {
    width: 18px;
    height: 18px;
    margin-right: 10px;
}

.social-btn:hover {
    background-color: #f5f5f5;
}

.divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.divider::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background-color: #ddd;
}

.divider span {
    position: relative;
    display: inline-block;
    padding: 0 10px;
    background-color: #fff;
    color: #666;
    font-size: 0.9rem;
}

.form-group {
    margin-bottom: 1.25rem;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.toggle-password {
    position: absolute;
    right: 10px;
    top: 65%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
}

.create-account-btn, .login-btn {
    width: 100%;
    padding: 0.75rem;
    background-color: #264A6E;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
}

.login-link, .signup-link {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
}

.forgot-password {
    text-align: right;
    margin-top: 0.5rem;
}

.forgot-password a {
    font-size: 0.9rem;
    color: #264A6E;
}

.terms {
    font-size: 0.8rem;
    color: #666;
    margin-top: 1.5rem;
    line-height: 1.4;
}

.benefits-panel {
    flex: 1;
    padding: 2rem;
    background-color: #f5f5f5;
    display: flex;
    flex-direction: column;
}

.benefits-panel h2 {
    margin-bottom: 0.5rem;
    font-size: 1.75rem;
}

.benefits-subtitle {
    margin-bottom: 2rem;
    color: #333;
}

.benefits-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.benefits-list li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.benefit-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    background-color: #264A6E;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
}

.benefit-text {
    flex: 1;
}



/* Newsletter subscription message styling */
.newsletter-message {
    margin-top: 1rem;
    padding: 0.75rem;
    border-radius: 4px;
    text-align: center;
    font-weight: 500;
    display: none;
}

.newsletter-message.success {
    background-color: rgba(212, 237, 218, 0.9);
    color: #155724;
    border: 1px solid #c3e6cb;
}

.newsletter-message.error {
    background-color: rgba(248, 215, 218, 0.9);
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Footer */
footer {
    background-color: #22305A;
    color: white;
    padding: 3rem 0;
    box-shadow: 0 -10px 30px rgba(0,0,0,0.08);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.03em;
}

/* Hamburger Menu */
.hamburger-menu {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 24px;
    position: relative;
    margin-left: 0;
    z-index: 1001;
}

.hamburger-menu span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #4D71F7;
    margin: 5px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* Improve X icon appearance */
.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
    width: 100%;
}

.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 100%;
}

.mobile-nav {
    display: none;
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: linear-gradient(to bottom right, #ffffff, #f8faff);
    box-shadow: -5px 0 20px rgba(77, 113, 247, 0.1);
    box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: right 0.3s ease;
    padding-top: 2rem;
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    padding: 0.5rem 2rem 2rem;
    gap: 1.0rem;
}

/* Ensure consistent styling for authenticated items */
.mobile-nav-links [data-auth-state="authenticated"] {
    display: flex;
    flex-direction: column;
    gap: 1.0rem;
    margin: 0;
    padding: 0;
}

.mobile-nav-links .nav-link,
.mobile-nav-links .user-greeting {
    font-size: 1.2rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(77, 113, 247, 0.1);
    transition: all 0.3s ease;
}

/* Make user greeting consistent with other nav links */
.mobile-nav-links .user-greeting {
    font-weight: 500;
    margin-bottom: 0;
    color: #22305A;
}

.mobile-nav-links .nav-link:hover {
    padding-left: 0.5rem;
}

/* Mobile CTA button - consistent with nav button styling */
.mobile-nav-links .mobile-cta {
    display: inline-block;
    background: #3A5CD9;
    color: white;
    padding: 0.8rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    margin: 0.8rem 0;
    text-align: center;
    letter-spacing: 0.01em;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.mobile-nav-links .mobile-cta:hover {
    background: #2F4DB8;
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Article Limit Banner Styles */
.article-limit-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #ffffff;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    display: none;
    border-top: 3px solid #4D71F7;
}

.article-limit-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 2.5rem;
    position: relative;
}

.article-limit-message h3 {
    margin-bottom: 0.5rem;
    color: #22305A;
    font-size: 1.5rem;
    font-weight: 700;
}

.article-limit-message p {
    margin-bottom: 0;
    color: #555;
    font-size: 1.2rem;
}

.article-limit-buttons {
    display: flex;
    gap: 1.25rem;
}

.article-limit-signin,
.article-limit-create {
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.article-limit-signin {
    background-color: #ffffff;
    color: #4D71F7;
    border: 1px solid #4D71F7;
}

.article-limit-create {
    background-color: #4D71F7;
    color: #ffffff;
}

.article-limit-signin:hover {
    background-color: #f5f5f5;
}

.article-limit-create:hover {
    background-color: #3A5CD9;
}

/* Responsive styles for Benefits and Impact sections */
@media (max-width: 992px) {
    .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
    
    .impact-wrapper {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .impact-image {
        order: -1;
    }
    
    .impact-wrapper-centered {
        max-width: 90%;
    }
    
    .impact-content-centered .section-header h2 {
        font-size: 2.7rem;
    }
    
    .impact-content-centered .impact-lead {
        font-size: 1.5rem;
    }
    
    .section-header h2 {
        font-size: 2.2rem;
    }
    
    .impact-lead {
        font-size: 1.3rem;
    }
}

@media (max-width: 768px) {
    .benefits-section,
    .impact-section {
        padding: 4rem 0;
    }
    
    .impact-content-centered .section-header h2 {
        font-size: 2.6rem; /* Increased from 2.4rem */
    }
    
    .impact-content-centered .impact-lead {
        font-size: 1.5rem; /* Increased from 1.4rem */
    }
    
    .impact-content-centered .impact-number {
        font-size: 2.2rem; /* Increased from 2rem */
    }
    
    .impact-content-centered .impact-point p {
        font-size: 1.3rem; /* Increased from 1.2rem */
    }
    
    .benefits-grid {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .benefit-card {
        padding: 1.5rem;
    }
    
    .section-header {
        margin-bottom: 2rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .impact-lead {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
    
    .impact-point {
        gap: 1rem;
    }
    
    .impact-number {
        font-size: 1.5rem;
        min-width: 30px;
    }
    
    .impact-point p {
        font-size: 1.05rem;
    }
}

@media (max-width: 480px) {
    .benefits-section,
    .impact-section {
        padding: 3rem 0;
    }
    
    .impact-content-centered .section-header h2 {
        font-size: 2.4rem;
    }
    
    .impact-content-centered .impact-lead {
        font-size: 1.4rem;
    }
    
    .impact-content-centered .impact-points {
        gap: 2rem;
    }
    
    .impact-content-centered .impact-number {
        font-size: 2rem;
    }
    
    .impact-content-centered .impact-point {
        gap: 1.2rem;
    }
    
    .impact-content-centered .impact-point p {
        font-size: 1.2rem;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
    }
    
    .benefit-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .benefit-card h3 {
        font-size: 1.3rem;
    }
    
    .benefit-card p {
        font-size: 1rem;
    }
    
    .impact-lead {
        font-size: 1.1rem;
    }
}

/* Responsive earnings list */
@media (max-width: 768px) {
    .earnings-list ul {
        gap: 0.5rem;
    }
    
    .earnings-list li {
        padding-left: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .earnings-list a {
        width: 100%;
        font-size: 1.15rem;
        line-height: 1.5;
    }
}

@media (max-width: 480px) {
    .earnings-list li {
        padding-left: 1.2rem;
    }
    
    .earnings-list li::before {
        font-size: 1rem;
    }
    
    .earnings-list a {
        font-size: 1.05rem;
        line-height: 1.4;
    }
}

@media (max-width: 768px) {
    /* Global h2 styling is now applied to sector-articles */
    
    .sector-articles .this-week h3 {
        font-size: 1.6rem;
    }
}

/* Responsive Modal */
@media (max-width: 768px) {
    .modal-container {
        flex-direction: column;
    }
    
    .signup-form {
        max-width: 100%;
    }
    
    .benefits-panel {
        display: none; /* Hide benefits panel on mobile */
    }
}

/* Responsive Design */
@media (max-width: 1100px) {
    .nav-left .search-bar {
        width: 300px !important;
    }
}

@media (max-width: 1190px) {
    .nav-right .nav-link:nth-child(-n+3) {
        display: none;
    }
    
    .hamburger-menu {
        display: block;
    }
    
    .mobile-nav {
        display: block;
    }
    
    .nav-left .search-bar {
        width: 400px !important;
    }
}

@media (max-width: 962px) {
    .nav-right .nav-link:nth-child(-n+3) {
        display: none;
    }
    
    .hamburger-menu {
        display: block;
    }
    
    .mobile-nav {
        display: block;
    }
    
    .nav-left .search-bar {
        width: 350px !important;
    }
}

@media (max-width: 1000px) {
    /* Hide the Sign In nav link at this breakpoint */
    .nav-right > .nav-link {
        display: none;
    }
}

@media (max-width: 940px) {
    /* Keep consistent padding for the sign-in button */
    .nav-left .search-bar {
        width: 300px !important;
    }
}


@media (max-width: 810px) {
    
    /* Increase search bar width by 50px when button nestles */
    .nav-left .search-bar {
        width: 300px !important;
    }
    
    /* Remove container margins for full-width on small screens */
    .container {
        width: 100%;
        padding: 0 10px;
    }
}


@media (max-width: 715px) {
    /* Hide the Create Free Account button at this breakpoint */
    .sign-in-btn {
        display: none;
    }
    
    /* Increase search bar width by 50px when button nestles */
    .nav-left .search-bar {
        width: 300px !important;
    }
    
    /* Remove container margins for full-width on small screens */
    .container {
        width: 100%;
        padding: 0 10px;
    }
}

@media (max-width: 576px) {

    .logo-text {
        font-size: 1.4rem;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .subhead {
        font-size: 1.25rem;
    }

}

@media (max-width: 576px) {
    /* Global h2 styling is now applied to sector-articles */
    
    .sector-articles .this-week h3 {
        font-size: 1.4rem;
    }
    
    .sector-articles {
        padding: 2rem 0;
    }
}

@media (max-width: 576px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .hero {
        padding: 2.5rem 0;
    }
    
    .newsletter h2 {
        font-size: 2.5rem;
    }
    
    .newsletter .subtitle {
        font-size: 1.25rem;
    }
    
    .subscribe-form {
        flex-direction: column;
        padding: 0 1rem;
    }
    
    .subscribe-form input {
        border-radius: 8px 8px 0 0;
        width: 100%;
    }
    
    .subscribe-form .dispatch-button {
        border-radius: 0 0 8px 8px;
        width: 100%;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    .hero {
        padding: 3rem 0;
    }
    
    .hero-content {
        flex-direction: column;
    }
    
    .hero-text {
        text-align: center;
        order: 1;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .subhead {
        font-size: 1.35rem;
    }
    
    .cta-block {
        margin: 0 auto;
    }
    
    /* Updated responsive navigation */
    .nav-left {
        gap: 0.7rem;
    }
    
    .nav-right {
        gap: 0.7rem;
    }

    .subscribe-form {
        flex-direction: column;
    }
    
    .subscribe-form input, 
    .subscribe-form .cta-button {
        width: 100%;
        border-radius: 4px;
        margin-bottom: 1rem;
    }
    
    .newsletter h2 {
        font-size: 3rem;
    }
    
    .newsletter .subtitle {
        font-size: 1.35rem;
    }
}

@media (max-width: 640px) {
    /* Keep the nav bar in a single row */
    nav {
        flex-direction: row;
        align-items: center;
    }
    
    /* Adjust spacing for nav elements */
    .nav-left {
        flex: 1;
    }
    
    .nav-right {
        flex: 0 0 auto;
    }
}

@media (max-width: 480px) {
    .newsletter h2 {
        font-size: 2rem;
    }
    
    .newsletter .subtitle {
        font-size: 1rem;
    }
    
    .newsletter {
        padding: 3rem 0;
    }
    
    .subscribe-form {
        padding: 0 0.5rem;
    }
    
    .subscribe-form input,
    .subscribe-form .dispatch-button {
        font-size: 1rem;
        padding: 0.8rem 1rem;
    }
}

@media (max-width: 490px) {
    .container {
        padding: 0 1rem;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    /* Further reduce logo size */
    .logo {
        font-size: 1.3rem;
    }
    
    .logo-text {
        font-size: 1.3rem;
    }
    
    /* Further reduce search bar width */
    .nav-left .search-bar {
        width: 210px !important;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .subhead {
        font-size: 1rem;
    }
    
    section {
        padding: 2.5rem 0;
    }
}

@media (max-width: 400px) {
    .container {
        padding: 0 1rem;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    /* Further reduce logo size */
    .logo {
        font-size: 1.3rem;
    }
    
    .logo-text {
        font-size: 1.3rem;
    }
    
    /* Further reduce search bar width */
    .nav-left .search-bar {
        width: 180px !important;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .subhead {
        font-size: 1rem;
    }
    
    section {
        padding: 2.5rem 0;
    }
}

/* Responsive styles for article limit banner */
@media (max-width: 768px) {
    .article-limit-content {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }
    
    .article-limit-message {
        margin-bottom: 1rem;
    }
    
    .article-limit-buttons {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .article-limit-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .article-limit-signin,
    .article-limit-create {
        width: 100%;
        padding: 0.75rem;
    }
}

/* Calendar Styles */
.calendar-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.calendar-page h1 {
    color: #264A6E;
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
}

.calendar-description {
    text-align: center;
    margin-bottom: 2rem;
    color: #555;
}

.calendar-container {
    margin-bottom: 3rem;
}

.calendar-compact {
    margin-bottom: 2rem;
}

.calendar-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.calendar-table th {
    background-color: #f5f8fc;
    color: #264A6E;
    text-align: left;
    padding: 0.75rem 1rem;
    font-weight: 600;
    border-bottom: 2px solid #e0e8f5;
}

.calendar-table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e0e8f5;
}

.calendar-table .date-cell {
    white-space: nowrap;
    color: #333;
}

.calendar-table .ticker-cell {
    font-weight: 600;
    color: #264A6E;
}

.calendar-table .quarter-cell {
    color: #666;
}

.calendar-table .analysis-cell {
    text-align: center;
}

.calendar-table .analysis-link {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background-color: #3A5CD9;
    color: white;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: background-color 0.2s;
}

.calendar-table .analysis-link:hover {
    background-color: #2F4DB8;
}

.calendar-table .no-analysis {
    color: #667085;
}

.calendar-table .past-event {
    background-color: #f9f9f9;
}

.calendar-table .upcoming-event {
    background-color: #fff;
}

.view-more {
    text-align: center;
    margin-top: 1rem;
}

.view-more .btn-outline {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1px solid #2F57D7;
    color: #2F57D7;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.view-more .btn-outline:hover {
    background-color: #2F57D7;
    color: white;
}
