@import url('https://cdn.jsdelivr.net/gh/aaaakshat/cm-web-fonts@latest/font/Serif/cmun-serif.css');

:root {
    /* Colors - Soft Paper & Graphite Scheme */

    /* Light Mode (Default) */
    --color-bg: #F5F2E9;
    /* soft, light paper beige */
    --color-surface: #FFFFFF;
    --color-text: #2E2E2E;
    /* graphite gray */
    --color-text-muted: #6E6E6E;

    --color-primary: #2E2E2E;
    --color-primary-hover: #4A4A4A;
    --color-on-primary: #FFFFFF;

    --color-secondary: #8C8C8C;
    --color-border: #E0DDD5;

    /* CTA Colors */
    --color-cta-bg: #ece4cb;
    --color-cta-text: #2E2E2E;

    /* Spacing */
    --spacing-sm: 0.5rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 3rem;
    --spacing-xl: 6rem;
    --max-width: 1000px;
    /* Narrower for focus */

    /* Typography */
    --font-heading: "Computer Modern Serif", serif;
    --font-body: "Computer Modern Serif", serif;

    /* Shadows */
    --shadow-sm: none;
    --shadow-md: 0 10px 30px rgba(46, 46, 46, 0.05);
}

[data-theme="dark"] {
    /* Dark Mode */
    --color-bg: #2E2E2E;
    --color-surface: #383838;
    --color-text: #6c8ec9;
    /* Logo Blue */
    --color-text-muted: #8faed9;

    --color-primary: #6c8ec9;
    --color-primary-hover: #8fb1e3;
    --color-secondary: #5a76a5;
    --color-border: #454545;

    /* CTA Colors */
    --color-cta-bg: #403949;
    --color-cta-text: #6c8ec9;

    --shadow-sm: none;
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.25);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    margin: 0;
    font-family: var(--font-body);
    color: var(--color-text);
    background-color: var(--color-bg);
    line-height: 1.7;
    font-size: 1.1rem;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    text-align: justify;
    overflow-x: hidden;
}

h1,
h2,
h3 {
    font-family: var(--font-heading);
    color: var(--color-text);
    margin-top: 0;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

h1 {
    font-size: 2rem;
}

@media (min-width: 768px) {
    h1 {
        font-size: 4.5rem;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 1rem;
        line-height: 1.6;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }
}

a {
    color: var(--color-text);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s, color 0.2s;
}

a:hover {
    color: var(--color-primary-hover);
    border-bottom-color: var(--color-primary-hover);
}