
/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: rgb(var(--color-app-bg)); 
}
::-webkit-scrollbar-thumb {
    background: rgb(var(--color-app-border)); 
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgb(var(--color-app-muted)); 
}

/* --- Variables --- */
:root {
    /* Dark Mode (Default) */
    --color-app-contrast: 255 255 255;       /* White */
    --color-app-strong: 0 0 0;       /* Black */
    --color-app-bg: 20 20 20;          /* #1E1E1E */
    --color-app-surface: 27 27 27;     /* #252525 */
    --color-app-sidebar: 43 43 43;     /* #2B2B2B */
    --color-app-highlight: 251 188 4;  /* #FBBC04 */
    --color-app-highlightHover: 232 175 4; /* #E8AF04 */
    --color-app-gradient-to: 255 215 0; /* #FFD700 Gold */
    --color-app-text: 220 220 220;     /* #DCDCDC */
    --color-app-muted: 169 169 169;    /* #A9A9A9 */
    --color-app-border: 68 68 68;      /* #444444 */
}

html.light-mode {
    /* Light Mode */
    --color-app-strong: 255 255 255;       /* White */
    --color-app-contrast: 0 0 0;       /* black */
    --color-app-bg: 255 255 255;       /* White */
    --color-app-surface: 249 250 251;  /* Gray-50 */
    --color-app-sidebar: 243 244 246;  /* Gray-100 */
    --color-app-highlight: 59 130 246;  /* Blue-500 (#3b82f6) */
    --color-app-highlightHover: 37 99 235; /* Blue-600 (#2563eb) */
    --color-app-gradient-to: 96 165 250; /* Blue-400 (#60a5fa) */
    --color-app-text: 17 24 39;        /* Gray-900 */
    --color-app-muted: 75 85 99;       /* Gray-600 */
    --color-app-border: 229 231 235;   /* Gray-200 */
}

/* --- Animations --- */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Typography & Colors --- */
/* Gold Gradient Text */
.text-gold-gradient {
    background: linear-gradient(to right, rgb(var(--color-app-highlight)), rgb(var(--color-app-gradient-to)));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Mockup UI Styles (Index Page) --- */
.app-mockup {
    background: rgb(var(--color-app-bg));
    border: 1px solid rgb(var(--color-app-border));
    border-radius: 0.75rem;
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.7);
    overflow: hidden;
    position: relative;
}
.app-header {
    background: rgb(var(--color-app-bg)); /* Approximating #141414 slightly darker if needed, but using BG for consistency */
    padding: 0.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgb(var(--color-app-border));
}
.skeleton-text { height: 0.75rem; background: rgb(var(--color-app-surface)); border-radius: 0.125rem; margin-bottom: 0.5rem; }
.skeleton-line { width: 100%; }

/* Tag Colors */
.tag-red { background: rgba(239, 68, 68, 0.2); color: #ef4444; border: 1px solid #ef4444; }
.tag-green { background: rgba(34, 197, 94, 0.2); color: #22c55e; border: 1px solid #22c55e; }
.tag-blue { background: rgba(59, 130, 246, 0.2); color: #3b82f6; border: 1px solid #3b82f6; }

/* --- Download Card Styles (Download Page) --- */
.download-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}
.download-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(var(--color-app-highlight), 0.15);
    border-color: rgb(var(--color-app-highlight));
}

/* --- Blog Styles --- */
.blog-readable {
    user-select: text;
}

.blog-content {
    color: rgb(var(--color-app-text));
    line-height: 1.85;
}

.blog-content > * + * {
    margin-top: 1.5rem;
}

.blog-content h1,
.blog-content h2,
.blog-content h3 {
    color: rgb(var(--color-app-text));
    font-family: "Playfair Display", serif;
    font-weight: 700;
    line-height: 1.15;
}

.blog-content h1 {
    font-size: clamp(2rem, 4vw, 3rem);
}

.blog-content h2 {
    font-size: clamp(1.55rem, 3vw, 2.2rem);
}

.blog-content h3 {
    font-size: clamp(1.3rem, 2vw, 1.7rem);
}

.blog-content p,
.blog-content li,
.blog-content blockquote {
    color: rgb(var(--color-app-muted));
    font-size: 1.05rem;
}

.blog-content ul,
.blog-content ol {
    padding-left: 1.5rem;
}

.blog-content ul {
    list-style: disc;
}

.blog-content ol {
    list-style: decimal;
}

.blog-content li + li {
    margin-top: 0.6rem;
}

.blog-content a {
    color: rgb(var(--color-app-highlight));
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.blog-content strong {
    color: rgb(var(--color-app-text));
}

.blog-content code {
    background: rgb(var(--color-app-bg));
    border: 1px solid rgb(var(--color-app-border));
    border-radius: 0.4rem;
    color: rgb(var(--color-app-text));
    font-family: Consolas, monospace;
    font-size: 0.95em;
    padding: 0.15rem 0.4rem;
}

.blog-content pre {
    background: rgb(var(--color-app-bg));
    border: 1px solid rgb(var(--color-app-border));
    border-radius: 1rem;
    color: rgb(var(--color-app-text));
    overflow-x: auto;
    padding: 1rem 1.25rem;
}

.blog-content pre code {
    background: transparent;
    border: 0;
    border-radius: 0;
    display: block;
    padding: 0;
    white-space: pre;
}

.blog-content hr {
    border: 0;
    border-top: 1px solid rgb(var(--color-app-border));
    margin: 2rem 0;
}

.blog-content blockquote {
    border-left: 3px solid rgb(var(--color-app-highlight));
    padding-left: 1rem;
}
