* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    --font-size: 18px;
    --text-color: #1f2937;
    --background-color-code: rgb(175, 171, 171);
    --background-color-tip: rgb(169, 209, 142);
    --border-radius-block: 16px;
}

body {
    font-family: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    background-color: #ffffff;
    color: var(--text-color);
    line-height: 1.5;
}

.container {
    max-width: 100%;
    padding: 0 20px;
}

.content {
    max-width: 800px;
    margin: 0 auto;           
    width: 100%;
}

h1:not(:first-child)
{
    margin-top: 1em;
}

h2 
{
    margin-left: 50px;
}

nav.menu {
    margin-bottom: 2em;
    font-family: 'Montserrat', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    padding-left: 16px;
}

nav.menu ul li {
    list-style: none;
}

nav.menu ul ul li {
    margin-left: 20px;
}

nav.menu a {
    font-size: var(--font-size);
    font-family: inherit;
    color: #2563eb;
    text-decoration: none;
    line-height: 1.6;
    display: inline-block;
}

nav.menu a:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

.main-text {
    font-size: var(--font-size);          
    text-align: justify;      
    line-height: 1.6;
    margin-bottom: 0;        
    color: var(--text-color);
}

.main-text a {
    color: #2563eb;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.main-text a:hover {
    color: #1d4ed8;
    text-decoration: none;
}

.custom-list {
    font-size: var(--font-size);
    text-align: justify;      
    line-height: 1.6;
    color: var(--text-color);
    margin: 0.5em 0 1em 1.5em;
    padding-left: 0;
}

.custom-list li {
    margin-bottom: 0.25em;
}

.custom-list li:last-child {
    margin-bottom: 0;
}

.quote-block {
    height: 100px;
    width: 100%;
    background-color: var(--background-color-code);  
    border-radius: 16px;                   
    padding: 20px 24px;                     
    margin: 1.5em 0;                        
    text-align: left;                     
}

.quote-block q {
    color: #ffffff;                         
    font-size: 18px;                        
    font-family: inherit;                   
    font-weight: 500;                       
    line-height: 1.5;
}

.custom-figure {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 50px;  
    margin: 50px auto 1.5em auto;   /* 50px сверху, автоматическое центрирование по горизонтали */
}

.custom-figure figcaption,
.custom-figure .fallback-text {
    width: 100%;
    text-align: center;
    font-size: var(--font-size) - 4px;
    font-family: 'Montserrat', system-ui, sans-serif;
    color: #555555;
    margin-top: 12px;
}

.code-block {
    display: flex;
    align-items: center;
    height: 70px;
    background-color: var(--background-color-code);  
    text-align: left;
    font-size: var(--font-size);
    border-radius: 1em;
}

.code-snippet {
    font-family: 'Lucida Console', 'Lucida Sans Typewriter', 'Courier New', monospace;
    color: #ffffff;
    margin: 20px;
}

.tip-section {
    display: flex;
    align-items: center;
    min-height: 70px;
    background-color: var(--background-color-tip);
    text-align: left;
    font-size: var(--font-size);
    border-radius: var(--border-radius-block);     
    margin: 1em 0;
    padding: 16px 20px;
    width: 100%;
}

.tip-mark {
    display: inline-block;
    font-family: inherit;
    font-size: calc(var(--font-size) + 2px);
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 4px;
}

.tip-paragraph {
    margin: 0;
    font-size: var(--font-size);
    line-height: 1.5;
    color: #1f2937;
    width: 100%;
}

.nav-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2em;         
    width: 100%;
    gap: 20px;
}

.link-left {
    text-align: left;
}

.link-left a {
    font-size: 18px;
    font-weight: 500;
    color: #2563eb;
    text-decoration: none;
    border-bottom: 1px dashed #2563eb;
    transition: all 0.2s ease;
    display: inline-block;
}

.link-left a:hover {
    color: #1d4ed8;
    border-bottom-color: #1d4ed8;
    transform: translateX(-2px);    
}

.link-right {
    text-align: right;
}

.link-right a {
    font-size: 18px;
    font-weight: 500;
    color: #2563eb;
    text-decoration: none;
    border-bottom: 1px dashed #2563eb;
    transition: all 0.2s ease;
    display: inline-block;
}

.link-right a:hover {
    color: #1d4ed8;
    border-bottom-color: #1d4ed8;
    transform: translateX(2px);
}

@media (min-width: 1500px) {
    body {
        padding-top: 100px;    
    }
    
    .container {
        padding-top: 0;
    }
}