/*
WORLD-CLASS ARTICLE DESIGN SYSTEM
Inspired by Apple HIG, Stripe Elements, Notion's Inter font, and premium publications
*/

/* Import Inter font from Google Fonts - Notion's choice for superior readability */
@import url('https://fonts.googleapis.com/css2?family:Inter:wght@300;400;500;600;700;800;900&display=swap');

/* Reset and base typography following Apple HIG principles */
.article-content {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    font-size: 17px; /* Apple's optimal body text size */
    line-height: 1.65; /* Increased for better readability */
    color: #1d1d1f; /* Apple's near-black for optimal contrast */
    max-width: 680px; /* Optimal reading width - 65-75 characters per line */
    margin: 0 auto;
    padding: 0;
    font-feature-settings: 'kern' 1, 'liga' 1, 'calt' 1;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Apple-inspired typography hierarchy */
.article-content h1 {
    font-size: 34px; /* Apple Large Title */
    font-weight: 800;
    line-height: 1.2;
    margin: 48px 0 24px 0;
    color: #1d1d1f;
    letter-spacing: -0.02em;
}

.article-content h2 {
    font-size: 28px; /* Apple Title 1 */
    font-weight: 700;
    line-height: 1.25;
    margin: 40px 0 20px 0;
    color: #1d1d1f;
    letter-spacing: -0.01em;
}

.article-content h3 {
    font-size: 22px; /* Apple Title 2 */
    font-weight: 600;
    line-height: 1.3;
    margin: 32px 0 16px 0;
    color: #1d1d1f;
    letter-spacing: -0.005em;
}

.article-content h4 {
    font-size: 20px; /* Apple Title 3 */
    font-weight: 600;
    line-height: 1.35;
    margin: 28px 0 14px 0;
    color: #1d1d1f;
}

.article-content p {
    font-size: 17px; /* Apple Body */
    font-weight: 400;
    line-height: 1.65;
    margin: 0 0 20px 0;
    color: #1d1d1f;
}

/* Stripe-inspired component cards */
.tool-card {
    background: #ffffff;
    border: 1px solid #e6e6e6;
    border-radius: 12px;
    padding: 32px;
    margin: 32px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 3px rgba(0, 0, 0, 0.06);
    transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
}

.tool-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #007AFF, #34C759, #FF9500);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.tool-card:hover::before {
    opacity: 1;
}

/* Tool pricing badge - Stripe-style */
.pricing-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    background: #f6f9fc;
    border: 1px solid #d1dde6;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #425466;
    margin: 8px 0;
}

.pricing-badge .price {
    color: #0070f3;
    font-weight: 700;
}

/* Premium callout boxes - Apple-inspired design */
.insight-callout {
    background: linear-gradient(135deg, #f6f9fc 0%, #eef4f9 100%);
    border-left: 4px solid #007AFF;
    border-radius: 0 8px 8px 0;
    padding: 24px 28px;
    margin: 28px 0;
    position: relative;
}

.insight-callout::before {
    content: '💡';
    position: absolute;
    top: 20px;
    left: -14px;
    background: #007AFF;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
}

.insight-callout h4 {
    margin: 0 0 12px 0;
    font-size: 18px;
    font-weight: 600;
    color: #1d1d1f;
}

.insight-callout p {
    margin: 0;
    font-size: 16px;
    color: #424242;
}

/* ROI metrics - Notion-style clean design */
.roi-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 32px 0;
}

.metric-item {
    background: #ffffff;
    border: 1px solid #e1e5e9;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    transition: all 0.2s ease;
}

.metric-item:hover {
    border-color: #007AFF;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.15);
}

.metric-value {
    font-size: 24px;
    font-weight: 700;
    color: #34C759;
    margin: 0 0 4px 0;
}

.metric-label {
    font-size: 14px;
    font-weight: 500;
    color: #8e8e93;
    margin: 0;
}

/* Implementation steps - Apple-style progressive disclosure */
.implementation-steps {
    background: #fafafa;
    border-radius: 12px;
    padding: 28px;
    margin: 32px 0;
}

.implementation-steps h4 {
    margin: 0 0 20px 0;
    font-size: 20px;
    font-weight: 600;
    color: #1d1d1f;
}

.step {
    display: flex;
    align-items: flex-start;
    margin: 16px 0;
    padding: 16px 0;
    border-bottom: 1px solid #e5e5e7;
}

.step:last-child {
    border-bottom: none;
}

.step-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #007AFF;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    margin-right: 16px;
    flex-shrink: 0;
}

.step-content h5 {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
    color: #1d1d1f;
}

.step-content p {
    margin: 0;
    font-size: 15px;
    color: #6d6d70;
    line-height: 1.5;
}

/* Code blocks - developer-friendly with syntax highlighting inspiration */
.code-block {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 20px;
    margin: 24px 0;
    overflow-x: auto;
    position: relative;
}

.code-block::before {
    content: attr(data-language);
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 12px;
    color: #8e8e93;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.code-block code {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    color: #f8f8f2;
    font-size: 14px;
    line-height: 1.5;
}

/* Success stories - testimonial-style cards */
.success-story {
    background: linear-gradient(135deg, #e8f5e8 0%, #d4eed4 100%);
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
    position: relative;
}

.success-story::before {
    content: '"';
    position: absolute;
    top: -8px;
    left: 20px;
    font-size: 48px;
    color: #34C759;
    font-weight: 700;
    line-height: 1;
}

.success-story-content {
    font-size: 16px;
    font-style: italic;
    color: #1d1d1f;
    margin: 0 0 16px 0;
    padding-left: 20px;
}

.success-story-author {
    font-size: 14px;
    font-weight: 600;
    color: #34C759;
    margin: 0;
    text-align: right;
}

/* Action buttons - Stripe-inspired CTAs */
.action-button {
    display: inline-flex;
    align-items: center;
    padding: 12px 24px;
    background: linear-gradient(135deg, #007AFF 0%, #0051D5 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
}

.action-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 122, 255, 0.4);
    color: white;
    text-decoration: none;
}

.action-button:active {
    transform: translateY(0);
}

/* Quick wins section - Prominent value proposition */
.quick-wins {
    background: linear-gradient(135deg, #fff7ed 0%, #fed7aa 100%);
    border-radius: 12px;
    padding: 28px;
    margin: 32px 0;
    border: 1px solid #fdba74;
}

.quick-wins h3 {
    margin: 0 0 16px 0;
    font-size: 22px;
    font-weight: 700;
    color: #ea580c;
    display: flex;
    align-items: center;
}

.quick-wins h3::before {
    content: '🚀';
    margin-right: 8px;
}

.quick-wins ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.quick-wins li {
    margin: 12px 0;
    padding-left: 24px;
    position: relative;
    font-size: 16px;
    color: #1d1d1f;
}

.quick-wins li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #34C759;
    font-weight: 700;
}

/* Responsive design - mobile-first approach */
@media (max-width: 768px) {
    .article-content {
        font-size: 16px;
        padding: 0 20px;
    }
    
    .article-content h1 {
        font-size: 28px;
        margin: 32px 0 20px 0;
    }
    
    .article-content h2 {
        font-size: 24px;
        margin: 28px 0 16px 0;
    }
    
    .article-content h3 {
        font-size: 20px;
        margin: 24px 0 12px 0;
    }
    
    .tool-card {
        padding: 24px 20px;
        margin: 24px 0;
    }
    
    .roi-metrics {
        grid-template-columns: 1fr;
    }
    
    .step {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .step-number {
        margin-bottom: 12px;
        margin-right: 0;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .article-content {
        color: #f5f5f7;
    }
    
    .article-content h1,
    .article-content h2,
    .article-content h3,
    .article-content h4 {
        color: #f5f5f7;
    }
    
    .tool-card {
        background: #1c1c1e;
        border-color: #38383a;
    }
    
    .pricing-badge {
        background: #2c2c2e;
        border-color: #48484a;
        color: #f5f5f7;
    }
    
    .metric-item {
        background: #1c1c1e;
        border-color: #38383a;
    }
    
    .implementation-steps {
        background: #1c1c1e;
    }
}

/* Print styles */
@media print {
    .article-content {
        font-size: 12pt;
        line-height: 1.4;
        color: #000;
    }
    
    .tool-card,
    .insight-callout,
    .quick-wins {
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .action-button {
        background: #fff;
        color: #000;
        border: 1px solid #000;
    }
}