/* IASTM Tools - Modern 2025 Website Styles */

:root {
    /* Colors - Navy & Mint Palette */
    --color-primary: #1E3A8A;
    --color-primary-dark: #1e40af;
    --color-primary-light: #3b82f6;
    --color-accent: #10B981;
    --color-accent-dark: #059669;
    --color-background: #EFF6FF;
    --color-surface: #FFFFFF;
    --color-text: #1E293B;
    --color-text-secondary: #64748B;
    --color-text-light: #94A3B8;
    --color-border: #E2E8F0;
    --color-success: #10B981;
    --color-warning: #F59E0B;
    --color-error: #EF4444;
    --gradient-primary: linear-gradient(135deg, #1E3A8A 0%, #1e40af 100%);
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
    --spacing-3xl: 6rem;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-full: 9999px;
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { font-family: var(--font-sans); line-height: 1.6; color: var(--color-text); background: var(--color-background); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color 150ms; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul, ol { list-style: none; }

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 var(--spacing-md); }
@media (min-width: 768px) { .container { padding: 0 var(--spacing-lg); } }

/* Navigation */
.nav { position: sticky; top: 0; z-index: 1020; background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(12px); border-bottom: 1px solid var(--color-border); }
.nav-content { display: flex; align-items: center; justify-content: space-between; padding: var(--spacing-sm) 0; }
.logo { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: 1.25rem; }
.logo-icon { font-size: 2rem; background: var(--gradient-primary); background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.logo-accent { color: var(--color-primary); }
.nav-toggle { display: flex; flex-direction: column; gap: 4px; padding: 0.5rem; }
.nav-toggle span { width: 24px; height: 2px; background: var(--color-text); }
.nav-menu { display: none; align-items: center; gap: var(--spacing-lg); }
.nav-link { font-weight: 500; color: var(--color-text-secondary); }
.nav-link:hover { color: var(--color-primary); }
@media (min-width: 768px) { .nav-toggle { display: none; } .nav-menu { display: flex; } }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.75rem 1.5rem; font-weight: 600; border-radius: var(--radius-md); transition: all var(--transition-base); white-space: nowrap; }
.btn-primary { background: var(--color-primary); color: white; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--color-primary-dark); box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.btn-outline { background: transparent; color: var(--color-primary); border: 2px solid var(--color-primary); }
.btn-outline:hover { background: var(--color-primary); color: white; }
.btn-outline-light { background: transparent; color: white; border: 2px solid white; }
.btn-outline-light:hover { background: white; color: var(--color-primary); }
.btn-sm { padding: 0.5rem 1rem; font-size: 0.875rem; }
.btn-lg { padding: 1rem 2rem; font-size: 1.125rem; }
.btn:hover .btn-icon { transform: translateX(4px); }

.badge { display: inline-flex; padding: 0.25rem 0.75rem; font-size: 0.75rem; font-weight: 600; border-radius: var(--radius-full); text-transform: uppercase; letter-spacing: 0.5px; }
.badge-success { background: var(--color-accent); color: white; }
.badge-outline { background: transparent; border: 1px solid var(--color-border); color: var(--color-text-secondary); }

/* Hero */
.hero { position: relative; padding: var(--spacing-3xl) 0; overflow: hidden; }
.hero-background { position: absolute; inset: 0; background: radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.1) 0%, transparent 50%), radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%); z-index: -1; }
.hero .container { display: grid; gap: var(--spacing-xl); align-items: center; }
@media (min-width: 1024px) { .hero .container { grid-template-columns: 1fr 1fr; } }
.hero-badge { display: flex; gap: var(--spacing-sm); margin-bottom: var(--spacing-md); animation: fadeInUp 0.6s ease-out; }
.hero-title { font-size: 2.5rem; font-weight: 700; line-height: 1.2; margin-bottom: var(--spacing-md); animation: fadeInUp 0.6s ease-out 0.1s backwards; }
@media (min-width: 768px) { .hero-title { font-size: 3rem; } }
.hero-subtitle { font-size: 1.125rem; color: var(--color-text-secondary); margin-bottom: var(--spacing-lg); animation: fadeInUp 0.6s ease-out 0.2s backwards; }
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--spacing-md); margin-bottom: var(--spacing-xl); animation: fadeInUp 0.6s ease-out 0.3s backwards; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--spacing-lg); padding: var(--spacing-lg); background: white; border-radius: var(--radius-xl); box-shadow: var(--shadow-lg); animation: fadeInUp 0.6s ease-out 0.4s backwards; }
.stat { text-align: center; }
.stat-value { font-size: 2rem; font-weight: 700; color: var(--color-primary); }
.stat-label { font-size: 0.875rem; color: var(--color-text-secondary); }

.hero-visual { position: relative; animation: fadeInRight 0.8s ease-out 0.2s backwards; }
.hero-image { position: relative; border-radius: var(--radius-xl); }
.placeholder-image { width: 100%; aspect-ratio: 4/3; border-radius: var(--radius-xl); }
.floating-card { position: absolute; background: white; padding: var(--spacing-sm) var(--spacing-md); border-radius: var(--radius-md); box-shadow: var(--shadow-xl); display: flex; align-items: center; gap: 0.5rem; animation: float 3s ease-in-out infinite; }
.floating-card-1 { top: 10%; right: -10%; animation-delay: 0s; }
.floating-card-2 { bottom: 20%; left: -10%; animation-delay: 1s; }
.floating-card-3 { top: 50%; right: 10%; animation-delay: 2s; }
.card-icon { font-size: 1.25rem; }
.card-text { font-weight: 600; font-size: 0.875rem; }

/* Sections */
.value-prop, .educational, .faq { padding: var(--spacing-3xl) 0; background: white; }
.audience, .blog, .final-cta { padding: var(--spacing-3xl) 0; background: var(--color-background); }
.browse-header { padding: var(--spacing-xl) 0; background: white; }
.tool-grid { padding: var(--spacing-xl) 0 var(--spacing-3xl); }

.section-header { margin-bottom: var(--spacing-xl); }
.section-header.centered { text-align: center; }
.section-tag { display: inline-block; padding: 0.25rem 0.75rem; background: rgba(37, 99, 235, 0.1); color: var(--color-primary); font-size: 0.875rem; font-weight: 600; border-radius: var(--radius-full); margin-bottom: var(--spacing-sm); text-transform: uppercase; }
.section-title { font-size: 2rem; font-weight: 700; line-height: 1.2; margin-bottom: var(--spacing-md); }
@media (min-width: 768px) { .section-title { font-size: 2.5rem; } }
.section-description { font-size: 1.125rem; color: var(--color-text-secondary); max-width: 700px; margin: 0 auto; }

/* Value Prop */
.value-prop-text { font-size: 1.125rem; color: var(--color-text-secondary); margin-bottom: var(--spacing-xl); max-width: 800px; }
.value-features { display: grid; gap: var(--spacing-lg); margin-bottom: var(--spacing-xl); }
@media (min-width: 768px) { .value-features { grid-template-columns: repeat(3, 1fr); } }
.feature { text-align: center; padding: var(--spacing-lg); background: var(--color-background); border-radius: var(--radius-lg); transition: all var(--transition-base); }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feature-title { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.5rem; }
.feature-text { color: var(--color-text-secondary); }

/* Audience */
.audience-grid { display: grid; gap: var(--spacing-lg); }
@media (min-width: 768px) { .audience-grid { grid-template-columns: repeat(3, 1fr); } }
.audience-card { position: relative; padding: var(--spacing-xl); background: white; border-radius: var(--radius-xl); box-shadow: var(--shadow-md); transition: all var(--transition-base); }
.audience-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-2xl); }
.audience-card.featured { background: var(--gradient-primary); color: white; transform: scale(1.05); }
.audience-card.featured:hover { transform: scale(1.08) translateY(-8px); }
.audience-card.featured .audience-description, .audience-card.featured .audience-features li::before { color: white; }
.featured-badge { position: absolute; top: -12px; right: var(--spacing-lg); padding: 0.5rem 1rem; background: var(--color-accent); color: white; font-size: 0.75rem; font-weight: 700; border-radius: var(--radius-full); text-transform: uppercase; }
.audience-title { font-size: 1.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.audience-description { color: var(--color-text-secondary); margin-bottom: var(--spacing-md); }
.audience-features { margin: var(--spacing-md) 0; padding-left: var(--spacing-md); }
.audience-features li { position: relative; padding-left: var(--spacing-md); margin-bottom: 0.5rem; color: var(--color-text-secondary); }
.audience-features li::before { content: "✓"; position: absolute; left: 0; color: var(--color-accent); font-weight: 700; }

/* Browse Tabs */
.browse-tabs { display: flex; justify-content: center; gap: var(--spacing-sm); flex-wrap: wrap; margin-top: var(--spacing-lg); }
.tab-btn { padding: 0.75rem 1.5rem; font-weight: 600; color: var(--color-text-secondary); background: var(--color-background); border-radius: var(--radius-md); transition: all 150ms; }
.tab-btn:hover { color: var(--color-primary); background: rgba(37, 99, 235, 0.1); }
.tab-btn.active { color: white; background: var(--color-primary); box-shadow: var(--shadow-md); }

/* Tool Grids */
.tool-grid.tab-content { display: none; }
.tool-grid.tab-content.active { display: block; }
.grid-title { font-size: 2rem; font-weight: 700; margin-bottom: 0.5rem; text-align: center; }
.grid-subtitle { font-size: 1.125rem; color: var(--color-text-secondary); text-align: center; margin-bottom: var(--spacing-xl); }
.tools-container { display: grid; gap: var(--spacing-lg); }
@media (min-width: 640px) { .tools-container { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .tools-container { grid-template-columns: repeat(3, 1fr); } }
.tool-card { background: white; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); transition: all var(--transition-base); }
.tool-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-xl); }
.tool-image { width: 100%; aspect-ratio: 4/3; background: var(--gradient-primary); }
.tool-content { padding: var(--spacing-md); }
.tool-name { font-size: 1.125rem; font-weight: 600; margin-bottom: 0.5rem; }
.tool-description { font-size: 0.875rem; color: var(--color-text-secondary); margin-bottom: var(--spacing-md); }
.tool-link { display: inline-flex; align-items: center; gap: 0.5rem; color: var(--color-primary); font-weight: 600; transition: gap 150ms; }
.tool-link:hover { gap: var(--spacing-sm); }

/* Educational */
.educational-content { display: grid; gap: var(--spacing-xl); align-items: center; }
@media (min-width: 1024px) { .educational-content { grid-template-columns: 1fr 1fr; } }
.educational-description { font-size: 1.125rem; color: var(--color-text-secondary); margin-bottom: var(--spacing-lg); }
.educational-list { margin-bottom: var(--spacing-xl); }
.educational-list li { display: flex; gap: var(--spacing-md); margin-bottom: var(--spacing-md); }
.list-icon { flex-shrink: 0; width: 24px; height: 24px; display: flex; align-items: center; justify-content: center; background: var(--color-accent); color: white; border-radius: var(--radius-full); font-weight: 700; font-size: 0.75rem; }
.list-content strong { display: block; margin-bottom: 0.25rem; }
.educational-visual { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--spacing-md); }
.edu-card { padding: var(--spacing-lg); background: var(--gradient-primary); color: white; border-radius: var(--radius-lg); text-align: center; }
.edu-card:first-child { grid-column: 1 / -1; }
.edu-stat { font-size: 2.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.edu-label { font-size: 0.875rem; opacity: 0.9; }

/* Articles Landing Page */
.articles-header { padding: var(--spacing-3xl) 0 var(--spacing-xl); background: var(--color-background); }
.articles-header-content { max-width: 900px; margin: 0 auto; text-align: center; }
.articles-header-title { font-size: 2.5rem; font-weight: 700; margin-bottom: var(--spacing-md); }
@media (min-width: 768px) { .articles-header-title { font-size: 3rem; } }
.articles-header-description { font-size: 1.125rem; color: var(--color-text-secondary); margin-bottom: var(--spacing-xl); line-height: 1.6; }

.articles-controls { display: flex; flex-direction: column; gap: var(--spacing-md); margin-top: var(--spacing-xl); }
@media (min-width: 768px) { .articles-controls { flex-direction: row; align-items: center; justify-content: center; } }

.search-box { flex: 1; max-width: 400px; }
.search-input { width: 100%; padding: 0.75rem 1rem; border: 2px solid var(--color-border); border-radius: var(--radius-md); font-size: 1rem; transition: border-color 150ms; }
.search-input:focus { outline: none; border-color: var(--color-primary); }

.filter-buttons { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.filter-btn { padding: 0.5rem 1rem; border: 2px solid var(--color-border); background: white; color: var(--color-text); font-weight: 600; font-size: 0.875rem; border-radius: var(--radius-full); cursor: pointer; transition: all 150ms; }
.filter-btn:hover { border-color: var(--color-primary); color: var(--color-primary); }
.filter-btn.active { background: var(--color-primary); color: white; border-color: var(--color-primary); }

.articles-section { padding: var(--spacing-xl) 0 var(--spacing-3xl); }
.no-results { text-align: center; padding: var(--spacing-3xl); color: var(--color-text-secondary); font-size: 1.125rem; }

.view-all-articles { text-align: center; margin-top: var(--spacing-lg); }

/* Blog */
.blog-grid { display: grid; gap: var(--spacing-lg); }
@media (min-width: 768px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .blog-grid { grid-template-columns: repeat(3, 1fr); } }
.blog-card { background: white; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); transition: all var(--transition-base); }
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-xl); }
.blog-image { width: 100%; aspect-ratio: 16/9; background: var(--gradient-primary); }
.blog-content { padding: var(--spacing-md); }
.blog-category { display: inline-block; padding: 0.25rem 0.75rem; background: rgba(37, 99, 235, 0.1); color: var(--color-primary); font-size: 0.75rem; font-weight: 600; border-radius: var(--radius-full); margin-bottom: 0.5rem; }
.blog-title { font-size: 1.125rem; font-weight: 600; line-height: 1.4; margin-bottom: 0.5rem; }
.blog-excerpt { font-size: 0.875rem; color: var(--color-text-secondary); margin-bottom: 0.5rem; line-height: 1.6; }

.blog-extended-wrapper { 
    position: relative; 
    max-height: 0; 
    overflow: hidden; 
    transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1); 
}

.blog-extended-wrapper.expanded { 
    max-height: 500px; 
}

.blog-extended { 
    font-size: 0.875rem; 
    color: var(--color-text-secondary); 
    line-height: 1.6; 
    padding-top: 0.5rem; 
}

.blog-excerpt-container { 
    position: relative; 
}

.blog-excerpt-container.collapsed::after { 
    content: ''; 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    right: 0; 
    height: 3rem; 
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 1) 100%); 
    pointer-events: none; 
}

.read-toggle { 
    color: var(--color-primary); 
    font-weight: 600; 
    font-size: 0.875rem; 
    cursor: pointer; 
    margin: 0.75rem 0 0.5rem; 
    display: inline-block; 
    background: none; 
    border: none; 
    padding: 0; 
    transition: opacity 0.2s ease; 
}

.read-toggle:hover { 
    opacity: 0.8; 
}

.blog-link { 
    display: inline-flex; 
    align-items: center; 
    gap: 0.5rem; 
    color: var(--color-primary); 
    font-weight: 600; 
    font-size: 0.875rem; 
    opacity: 0; 
    max-height: 0; 
    overflow: hidden; 
    transition: opacity 0.4s ease 0.3s, max-height 0.4s ease 0.3s, gap 150ms; 
    margin-top: 0.5rem; 
}

.blog-link.visible { 
    opacity: 1; 
    max-height: 50px; 
}

.blog-link:hover { 
    gap: var(--spacing-sm); 
}

/* FAQ */
.faq-container { max-width: 800px; margin: 0 auto; }
.faq-item { margin-bottom: var(--spacing-md); border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden; }
.faq-question { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: var(--spacing-md); font-size: 1.125rem; font-weight: 600; text-align: left; background: white; transition: background 150ms; }
.faq-question:hover { background: var(--color-background); }
.faq-icon { flex-shrink: 0; transition: transform var(--transition-base); }
.faq-item.active .faq-icon { transform: rotate(180deg); }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height 350ms; }
.faq-item.active .faq-answer { max-height: 500px; }
.faq-answer p { padding: 0 var(--spacing-md) var(--spacing-md); color: var(--color-text-secondary); line-height: 1.8; }

/* Final CTA */
.cta-card { position: relative; padding: var(--spacing-3xl) var(--spacing-xl); background: var(--gradient-primary); border-radius: var(--radius-xl); text-align: center; overflow: hidden; }
.cta-content { position: relative; z-index: 1; }
.cta-title { font-size: 2rem; font-weight: 700; color: white; margin-bottom: var(--spacing-md); }
.cta-text { font-size: 1.125rem; color: rgba(255, 255, 255, 0.9); margin-bottom: var(--spacing-lg); }
.cta-buttons { display: flex; flex-wrap: wrap; gap: var(--spacing-md); justify-content: center; }
.cta-badge { display: inline-flex; align-items: center; gap: var(--spacing-md); padding: var(--spacing-md) var(--spacing-lg); background: rgba(255, 255, 255, 0.2); border-radius: var(--radius-lg); color: white; margin-top: var(--spacing-lg); }
.badge-icon { font-size: 2rem; }
.badge-title { font-weight: 700; font-size: 1.125rem; }
.badge-subtitle { font-size: 0.875rem; opacity: 0.9; }

/* Footer */
.footer { background: var(--color-text); color: white; padding: var(--spacing-2xl) 0 var(--spacing-lg); }
.footer-content { display: grid; gap: var(--spacing-xl); margin-bottom: var(--spacing-xl); }
@media (min-width: 768px) { .footer-content { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-logo { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: 1.25rem; margin-bottom: var(--spacing-sm); }
.footer-description { color: rgba(255, 255, 255, 0.7); font-size: 0.875rem; line-height: 1.6; }
.footer-title { font-weight: 700; margin-bottom: var(--spacing-sm); }
.footer-links { display: flex; flex-direction: column; gap: 0.5rem; }
.footer-links a { color: rgba(255, 255, 255, 0.7); font-size: 0.875rem; transition: color 150ms; }
.footer-links a:hover { color: white; }
.footer-bottom { padding-top: var(--spacing-lg); border-top: 1px solid rgba(255, 255, 255, 0.1); text-align: center; font-size: 0.875rem; color: rgba(255, 255, 255, 0.6); }
.footer-disclaimer { margin-top: 0.5rem; }

/* Animations */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInRight { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: translateX(0); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* Utility */
.hidden { display: none; }
.smooth-scroll { scroll-behavior: smooth; }
