/* CSS Variables for Colors and Fonts */
:root {
    --primary-blue: #3E82FC;
    --primary-pink: #F972E8;
    --primary-purple: #9D7BF0; /* Mid-point color for gradient */
    --primary-blue-light: #6ea0ff;
    --background-main: #FFFFFF;
    --background-secondary: #F6F8FD;
    --text-dark: #1b2333;
    --text-light: #5B6178;
    --border-color: #EAEBF1;
    --tick-color-future: #c5c9d6; /* Darker gray for future ticks */
    --font-main: 'Inter', sans-serif;
}

/* General Body Styles */
body {
    background-color: var(--background-main);
    color: var(--text-dark);
    font-family: var(--font-main);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Gradient Animation Keyframes */
@keyframes gradientAnimation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

.header-container {
     padding: 20px 0;
}

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

.logo img {
    height: 50px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-light);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--text-dark);
}

.header-cta {
     background: var(--text-dark);
     color: white;
     padding: 12px 24px;
     text-decoration: none;
     font-weight: 600;
     border-radius: 8px;
     transition: transform 0.3s, background-color 0.3s;
     display: inline-block;
}

.header-cta:hover {
    transform: scale(1.05);
    background-color: var(--primary-blue-light);
}

.mobile-menu-button {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
}

.mobile-nav-links {
    display: none;
}

/* Hero Section Styles */
.hero-container {
    position: relative;
    padding: 12rem 0 8rem 0;
    text-align: center;
    overflow: hidden;
    background: linear-gradient(-45deg, #e0c3fc, #8ec5fc, #fffac7, #ffd5a4, #f972e8);
    background-size: 600% 600%;
    animation: gradientAnimation 25s ease-in-out infinite;
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-title {
    font-size: clamp(3rem, 7vw, 6rem);
    font-weight: 900;
    margin: 0 0 1rem 0;
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.gradient-text {
    background: linear-gradient(90deg, var(--primary-blue), var(--primary-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto 2.5rem auto;
    color: var(--text-light);
    font-weight: 400;
    line-height: 1.6;
}

/* Sections */
.section {
    padding: 6rem 0;
}

.section-background {
     background-color: var(--background-secondary);
     position: relative;
     overflow: hidden;
}

#roadmap-section-bg {
    background: linear-gradient(45deg, #e0c3fc, #8ec5fc, #fffac7, #ffd5a4, #f972e8);
    background-size: 600% 600%;
    animation: gradientAnimation 35s ease-in-out infinite;
}

.animated-bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.7;
}
.section-background .container {
    position: relative;
    z-index: 1;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 900;
    text-align: center;
    margin: 0 0 1rem 0;
    letter-spacing: -0.03em;
}
.section-subtitle {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 4rem auto;
    color: var(--text-light);
    text-align: center;
}

/* Loading Dots Animation */
.loading-dots::after {
    display: inline-block;
    animation: loading-dots 1.5s infinite;
    content: '';
    width: 2.5ch; 
    text-align: left;
}
@keyframes loading-dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60% { content: '...'; }
    80%, 100% { content: ''; }
}

/* Typing Animation Section Styles */
.intro-animation-container {
    text-align: center;
    padding: 2rem 0;
    min-height: 100px;
}
.typing-animation-text {
    font-size: clamp(2rem, 4.5vw, 3.5rem); 
    font-weight: 900;
    letter-spacing: -0.03em;
    height: 1.2em;
    display: inline;
}
.typing-animation-text .gradient-text {
     background: linear-gradient(90deg, var(--primary-blue), var(--primary-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.cursor {
    display: inline-block;
    background-color: var(--text-dark);
    width: 4px;
    height: 1em;
    margin-left: 8px;
    animation: blink 1s step-end infinite;
}
@keyframes blink {
  from, to { background-color: transparent }
  50% { background-color: var(--text-dark); }
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}
.tweet-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.tweet-card-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}
.tweet-card {
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    overflow: hidden; 
    height: 100%;
}

.image-placeholder {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    background-color: var(--background-secondary);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.loading-animation {
    display: flex;
    gap: 4px;
    align-items: center;
    transition: opacity 0.3s ease-in-out;
}

.loading-animation span {
    width: 6px;
    height: 4px;
    background-color: var(--primary-blue);
    animation: bar-pulse 1.2s infinite ease-in-out;
}

.loading-animation span:nth-child(1) {
    background-color: var(--primary-blue);
    animation-delay: 0s;
}
.loading-animation span:nth-child(2) {
    background-color: var(--primary-purple);
    animation-delay: 0.2s;
}
.loading-animation span:nth-child(3) {
    background-color: var(--primary-pink);
    animation-delay: 0.4s;
}

@keyframes bar-pulse {
    0%, 100% { transform: scaleY(1); opacity: 0.5; }
    50% { transform: scaleY(4); opacity: 1; }
}

.tweet-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.4s ease-in-out;
}

.image-placeholder.is-loaded .loading-animation {
    opacity: 0;
}

.image-placeholder.is-loaded .tweet-image {
    opacity: 1;
}


.tweet-card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.tweet-content {
    flex-grow: 1;
    color: var(--text-light);
    line-height: 1.6;
}
.tweet-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-light);
    font-size: 0.9rem;
}
#more-tweets-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 1s ease-in-out, opacity 0.5s ease-in-out 0.2s;
}
#more-tweets-container.expanded {
    max-height: 2000px; 
    opacity: 1;
    margin-top: 1.5rem;
}
.news-buttons {
    margin-top: 3rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
}
.error-box {
    grid-column: 1 / -1; 
    text-align: center;
    padding: 2rem;
    background-color: #fff4e6;
    border: 1px solid #ffe8cc;
    border-radius: 12px;
    color: #d97706;
}

.feature-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
    gap: 4rem;
}

.feature-content h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.feature-content p {
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.1rem;
}

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

.roadmap-card {
    background: var(--background-main);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
}

.roadmap-card .phase {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.roadmap-card h3 {
    font-size: 1.5rem;
    margin: 0 0 1rem 0;
}

.roadmap-card ul {
    padding-left: 0;
    list-style: none;
    color: var(--text-light);
}

.roadmap-card li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.roadmap-card li::before {
    content: '✓';
    color: var(--primary-blue);
    position: absolute;
    left: 0;
}

.roadmap-card.roadmap-future li::before {
    color: var(--tick-color-future);
}


#deep-dive-form {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

#topic-input {
    width: 50%;
    padding: 1rem;
    font-size: 1rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background-color: var(--background-main);
    color: var(--text-dark);
}

#deep-dive-button {
    background: var(--text-dark);
    color: white;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: transform 0.3s;
}

#deep-dive-button:hover {
     transform: scale(1.05);
}

#gemini-response-container {
    max-width: 800px;
    margin: 2rem auto 0 auto;
    padding: 2rem;
    background-color: var(--background-secondary); 
    border: 1px solid var(--border-color);
    color: var(--text-dark); 
    border-radius: 12px;
    text-align: left;
    line-height: 1.7; 
    font-family: var(--font-main); 
    font-size: 1.1rem; 
    display: none;
}

footer {
    padding: 4rem 0;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.footer-logo {
    margin-bottom: 2rem;
}

.footer-logo img {
    height: 75px;
    width: auto;
}

.footer-socials {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
}
.footer-socials a {
    color: var(--text-light);
    transition: color 0.3s, transform 0.3s;
}
.footer-socials a:hover {
    color: var(--primary-blue);
    transform: translateY(-3px);
}
.footer-socials svg {
    width: 28px;
    height: 28px;
}

@media (max-width: 1024px) {
    .news-grid, #more-tweets-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    .mobile-menu-button {
        display: block;
    }
    .mobile-nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        background: white;
        position: absolute;
        top: 69px; 
        left: 0;
        padding: 1rem 0;
        border-bottom: 1px solid var(--border-color);
    }
    .mobile-nav-links.active {
        display: flex;
    }
    .mobile-nav-links a {
        padding: 1rem 24px;
        color: var(--text-dark);
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .feature-content {
        text-align: center;
    }
     #deep-dive-form {
        flex-direction: column;
    }
    #topic-input {
        width: 100%;
        box-sizing: border-box;
    }
}

@media (max-width: 640px) {
     .news-grid, #more-tweets-container {
        grid-template-columns: 1fr;
    }
}
