/* ============================================================
   TYPOGRAPHY – KRYSTALSPACE
   assets/css/base/typography.css
============================================================ */

/* ------------------------------------------------------------
   1. FONT STACKS
------------------------------------------------------------ */

body {
    font-family: var(--ks-font-main);
    font-size: 16px;
    line-height: 1.65;
    color: var(--ks-navy);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ------------------------------------------------------------
   2. HEADINGS
------------------------------------------------------------ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--ks-font-heading);
    font-weight: 800;
    line-height: 1.2;
    color: var(--ks-navy);
    margin: 0 0 0.8em;
}

h1 { font-size: clamp(2.6rem, 5vw, 3.6rem); }
h2 { font-size: clamp(2.1rem, 4vw, 2.8rem); }
h3 { font-size: 1.6rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.05rem; }
h6 { font-size: 0.9rem; }

/* ------------------------------------------------------------
   3. PARAGRAPHS & TEXT
------------------------------------------------------------ */

p {
    margin: 0 0 1.5em;
    font-size: 1rem;
    color: var(--ks-slate);
}

strong {
    font-weight: 700;
    color: var(--ks-navy);
}

em {
    font-style: italic;
}

/* Lead text (np. hero, intro) */
.lead {
    font-size: 1.15rem;
    line-height: 1.75;
    color: var(--ks-navy);
}

/* Small text */
.small,
.text-small {
    font-size: 0.85rem;
    color: var(--ks-slate);
}

/* ------------------------------------------------------------
   4. LINKS
------------------------------------------------------------ */

a {
    color: var(--ks-blue);
    text-decoration: none;
    transition: color .25s ease;
}

a:hover {
    color: var(--ks-green);
}

/* Link w treści artykułów */
.entry-content a {
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

/* ------------------------------------------------------------
   5. LISTS
------------------------------------------------------------ */

ul, ol {
    margin: 0 0 1.5em 1.5em;
    color: var(--ks-slate);
}

li {
    margin-bottom: 0.6em;
    line-height: 1.6;
}

/* ------------------------------------------------------------
   6. BLOCKQUOTE
------------------------------------------------------------ */

blockquote {
    margin: 2em 0;
    padding: 1.2em 1.6em;
    border-left: 4px solid var(--ks-blue);
    background: var(--ks-bg-light);
    font-style: italic;
    color: var(--ks-navy);
}

blockquote p:last-child {
    margin-bottom: 0;
}

/* ------------------------------------------------------------
   7. CODE & PRE
------------------------------------------------------------ */

code {
    font-family: monospace;
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
}

pre {
    background: #0f172a;
    color: #e5e7eb;
    padding: 20px;
    border-radius: 12px;
    overflow-x: auto;
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ------------------------------------------------------------
   8. TEXT UTILITIES
------------------------------------------------------------ */

.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-left   { text-align: left; }

.text-muted  { color: var(--ks-slate); }
.text-primary { color: var(--ks-blue); }
.text-success { color: var(--ks-green); }
.text-error   { color: var(--ks-error); }

/* ------------------------------------------------------------
   9. ACCESSIBILITY
------------------------------------------------------------ */

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}
