@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Outfit:wght@500;600;700;800&display=swap');

:root {
    --bg-color: #fafafa;
    --text-primary: #111827;
    --text-secondary: #4b5563;
    --accent: #2563eb;
    --border: #e5e7eb;
}

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.header-nav {
    padding: 30px 20px;
    background: #ffffff;
    border-bottom: 1px solid var(--border);
}

.header-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-content h1 {
    font-family: 'Outfit', sans-serif;
    font-size: 28px;
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.5px;
}

.header-content h1 a {
    text-decoration: none;
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.header-content h1 a:hover {
    color: var(--accent);
}

.header-content nav a {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: var(--text-secondary);
    text-decoration: none;
    margin-left: 20px;
    transition: color 0.2s;
}

.header-content nav a:hover, .header-content nav a.active {
    color: var(--accent);
}

.container {
    max-width: 720px;
    margin: auto;
    padding: 60px 20px;
}

.intro {
    font-size: 22px;
    font-weight: 400;
    color: var(--text-secondary);
    margin-bottom: 60px;
    line-height: 1.7;
}

.section, article {
    margin-bottom: 50px;
}

h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--text-primary);
    letter-spacing: -0.3px;
}

p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.section a, article a {
    color: var(--accent);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}

.section a:hover, article a:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.card {
    background: #ffffff;
    border: 1px solid var(--border);
    padding: 20px;
    border-radius: 12px;
    margin-top: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.card b {
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
}

.frame {
    font-family: 'Menlo', 'Monaco', 'Courier New', monospace;
    background: #f3f4f6;
    color: #1f2937;
    padding: 12px;
    border-radius: 8px;
    margin-top: 10px;
    font-size: 14px;
    overflow-x: auto;
}

.decoded {
    margin-top: 12px;
    line-height: 1.8;
    color: var(--text-secondary);
}

ul {
    color: var(--text-secondary);
    line-height: 1.8;
}

li {
    margin-bottom: 8px;
}

/* Blog specific styles */
.blog-content code {
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Menlo', 'Monaco', 'Courier New', monospace;
    font-size: 0.9em;
    color: #ef4444;
}

.blog-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    font-size: 0.95em;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.blog-content th {
    text-align: left;
    padding: 14px 16px;
    border-bottom: 2px solid var(--border);
    background-color: #f9fafb;
    color: var(--text-primary);
    font-family: 'Outfit', sans-serif;
}

.blog-content td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}

.blog-content tr:last-child td {
    border-bottom: none;
}

.blog-content hr {
    border: 0;
    border-top: 1px solid var(--border);
    margin: 40px 0;
}

/* Site Footer */
.site-footer {
    text-align: center;
    padding: 20px;
    border-top: 1px solid var(--border);
    margin-top: 20px;
}

.matrix-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-family: 'Inter', sans-serif;
    color: #0DBD8B;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s;
}

.matrix-link:hover {
    opacity: 0.75;
}

/* Mobile Optimization */
@media (max-width: 600px) {
    .container {
        padding: 40px 15px;
    }
    
    header {
        padding: 20px 15px;
    }
    
    header h1 {
        font-size: 24px;
    }
    
    .intro {
        font-size: 18px;
        margin-bottom: 40px;
    }
    
    h2 {
        font-size: 22px;
    }
    
    .section, article {
        margin-bottom: 40px;
    }

    .card {
        padding: 15px;
    }

    .frame {
        font-size: 13px;
        white-space: pre-wrap; /* Ensure hex dumps break lines gracefully on small screens */
    }
}