@import url('https://fonts.googleapis.com/css2?family=Golos+Text:wght@400..900&family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap');

:root {
    /* База: 1rem = 16px */
    font-size: 16px;

    --blue: #1A437C;
    --white: #fff;
    --black: #373737;

    /* Все размеры шрифтов переведены в rem */
    --p14: 400 0.875rem/1.2 'Golos Text', sans-serif;   /* 14px */
    --p18: 400 1.125rem/1.2 'Golos Text', sans-serif;   /* 18px */
    --p20: 400 1.25rem/1.2 'Golos Text', sans-serif;    /* 20px */
    --p24: 400 1.5rem/1.2 'Golos Text', sans-serif;     /* 24px */
    --p32: 600 2rem/1.2 'Golos Text', sans-serif;       /* 32px */
}

* {
    margin: 0;
    padding: 0;
    position: relative;
    box-sizing: border-box;
    font-family: 'Golos Text', sans-serif;
}

body {
    min-height: 100vh;
    background-color: #ffffff;
    color: #333;
    font: var(--p18);
}

a {
    text-decoration: none;
    transition: all 0.3s ease;
}

img {
    max-width: 100%;
}

.streem
{
    margin-top: 60px;
}
.streem h3
{
    margin-bottom: 20px;
}
footer
{
    width: 100%;
    display: flex;
    gap:20px;
    justify-content: space-between;
    align-items: center;
    border-top:1px solid #E3EAF5;
    padding: 1rem 3.75rem 1rem 2.5rem;
}
footer .social
{
    display: flex;
    gap:20px;
}
footer .social a>img
{
    width: 40px;
}

/* Шапка */
.site-header {
    display: block;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 33rem;              /* 360px / 16 = 22.5rem */
    background-color: var(--blue);
    color: var(--white);
    padding: 0.75rem 3.75rem 2.25rem;  /* 30px 60px 36px */
    /*border-radius: 0 0 3.75rem 3.75rem; */
    z-index: 2;
}

.site-header a {
    color: var(--white);
}

.header-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.top-header-line {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.header-link:hover {
    text-decoration: underline;
}

.logo-icon {
    display: block;
    margin-bottom: -1.25rem;          /* -20px */
}

.logo-icon img {
    width: 5rem;                       /* 80px */
}

.header-nav {
    display: flex;
    gap: 1.25rem;                      /* 20px */
}

h1 {
    font: 400 1.7rem/2rem "Inter", sans-serif; /* 64px */
    margin: 33% 0 0.625rem;               /* 0 0 10px */
    text-transform: uppercase;
    letter-spacing: 0.2rem;
    max-width: 19rem;
}
.bottom-line
{
    display: flex;
    flex-direction: row;
    justify-content: center;
    gap:7.25rem;
    padding-top: 0.5rem;
    align-items: center;
}
.bottom-line>a>img
{
    height: 7rem;
}

.center-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}


.center-title {
    background: url('/images/imagefon.svg') center center no-repeat;
    background-size: contain;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 44rem;
    height: 23.75rem;        
}

.center-title .desc {
    font: var(--p24);
}

.logo-minprosvet {
    display: block;
    max-width: 16.5625rem;             /* 265px */
}

/* Блок с меню и контентом */
.content-block {
    display: grid;
    grid-template-columns: 22.5rem 1fr; /* 360px */
    margin-top: -3.75rem;               /* -60px */
    z-index: 1;
    min-height: calc(100vh - 18.75rem);
}

.left-menu-container {
    background-color: var(--white);
    padding: 3.5625rem 0 1.25rem;       /* 105px 0 20px */
    border-right: 1px solid #E3EAF5;
}

.left-menu-container .mobile-menu {
    display: none;
}

.sidebar {
    color: #333;
    position: sticky;
    top: 4.375rem;                      /* 70px */
    left: 0;
    overflow-y: auto;
    transition: all 0.3s ease;
    z-index: 90;
}

.menu-item {
    list-style: none;
    margin-bottom: 0.3125rem;           /* 5px */
}

.menu-link {
    display: flex;
    align-items: center;
    padding: 1.25rem 2.5rem;            /* 20px 40px */
    color: #475569;
    text-decoration: none;
    font-size: 1.05rem;                 /* относительная величина, можно оставить в rem (1.05 * 16 = 16.8px) – но лучше задать через переменную */
    transition: all 0.2s ease;
    border-left: 0.25rem solid transparent; /* 4px */
    position: relative;
}

.menu-link:hover {
    background-color: #E7EDF7;
    color: #234286;
    border-left-color: #234286;
}

.menu-link.active {
    background-color: #E7EDF7;
    color: #234286;
    border-left-color: #234286;
    font-weight: 500;
}

.menu-link i {
    margin-right: 0.75rem;               /* 12px */
    font-size: 1.5rem;                   /* 24px */
    width: 1.5rem;
    text-align: center;
    color: var(--black);
}

.menu-link.active i,
.menu-link:hover i {
    color: #234286;
}

.menu-link .arrow {
    margin-left: auto;
    transition: transform 0.3s ease;
    font-size: 1.5rem;                   /* 24px */
    color: var(--black);
}

.menu-link.active .arrow {
    transform: rotate(90deg);
    color: #E7EDF7;
}

.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.submenu.active {
    max-height: 31.25rem;                /* 500px */
}

.submenu-link {
    display: block;
    padding: 0.75rem 3.75rem 0.75rem 5.25rem; /* 12px 60px 12px 84px */
    color: var(--black);
    text-decoration: none;
    transition: all 0.2s ease;
    position: relative;
}

.submenu-link:hover {
    color: #234286;
    background-color: rgba(231, 237, 247, 0.5);
}

.submenu-link.active {
    color: #234286;
    background-color: rgba(231, 237, 247, 0.5);
    font-weight: 500;
}

.submenu-link::before {
    content: '';
    position: absolute;
    left: 3.75rem;                       /* 60px */
    top: 50%;
    width: 0.5rem;                       /* 8px */
    height: 0.5rem;
    background-color: var(--black);
    border-radius: 50%;
    transform: translateY(-50%);
}

.submenu-link:hover::before,
.submenu-link.active::before {
    background-color: #234286;
}

.main-content {
    padding: 6.25rem 3.75rem 5.625rem 3.75rem; /* 100px 60px 90px 60px */
}

.name_conf {
    font: var(--p32);
    margin: 0 0 3rem;                     /* 0 0 48px */
    max-width: 42.5rem;                   /* 680px */
}

.full-info {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;                          /* 24px */
    min-height: 21.5625rem;                /* 345px */
}

.place .title {
    display: block;
    font: var(--p20);
    font-weight: 600;
    margin-bottom: 0.75rem;                /* 12px */
}

.full-info-text {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 2.5rem;                           /* 40px */
}

.files {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;                           /* 24px */
}

.files .file-div {
    display: flex;
    gap: 0.75rem;                          /* 12px */
}

.files .file-div .file-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;                         /* 40px */
    height: 2.75rem;                       /* 44px */
    padding: 0.5rem;                       /* 8px */
    font-size: 1.75rem;                    /* 28px */
    border-radius: 0.5rem;                 /* 8px */
    background-color: #009BE1;
    color: var(--white);
}

.files .file-div .file-icon.pdf {
    background-color: #FB382F;
}

.files .file-div .file-icon.image {
    background-color: #FF9700;
}

.files .file-div .file-icon.ppt {
    background-color: #D24726;
}

.files .file-div .file-icon.xls {
    background-color: #217346;
}

.files .file-div .file-name {
    display: block;
    margin-bottom: 0.25rem;                /* 4px */
    font-weight: 500;
}

.files .file-div .file-info {
    opacity: 0.8;
    font: var(--p14);
}

.address {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;                          /* 4px */
}

.address .address-item:before {
    content: '- ';
}

.type-file-name {
    position: absolute;
    left: 0.75rem;                        /* 14px */
    top: 1.1875rem;                        /* 19px */
    font: 500 0.625rem/1 'Oswald', sans-serif; /* 10px */
    text-transform: uppercase;
}

.file-link-wrapper:hover {
    transform: scale(1.01);
}

.mobile-menu
{
    display: none;
}


@media (min-width: 1040px){
    .main-content .container {
        height: 100%;
        display: flex;
        flex-direction: column;
    }

    .full-info
    {
        flex: 1;
    }
}

/* ========== АДАПТИВНОСТЬ: МЕНЯЕМ БАЗОВЫЙ РАЗМЕР ШРИФТА ========== */

@media (min-width: 1540px)
{
    :root 
    {
        font-size: 17px;  /* 1rem = 15px */
    }
}
@media (min-width: 1680px)
{
    :root 
    {
        font-size: 18px;  /* 1rem = 15px */
    }
}
@media (min-width: 1800px)
{
    :root 
    {
        font-size: 19px;  /* 1rem = 15px */
    }
}
@media (min-width: 1920px)
{
    :root 
    {
        font-size: 20px;  /* 1rem = 15px */
    }
}

/* Планшеты и небольшие ноутбуки */
@media (max-width: 1024px) {
    :root {
        font-size: 15px;  /* 1rem = 15px */
    }
    /* При желании можно скорректировать некоторые крупные блоки,
       но в основном всё подстроится автоматически за счёт rem */
}


/* Мобильные устройства (вертикальная ориентация) */
@media (max-width: 1040px) {
    :root {
        font-size: 15px;  /* можно оставить 15px или уменьшить до 14px */
    }

    /* Переопределяем структуру, которая не может быть выражена через rem (например, grid-шаблоны) */
    .site-header {
        height: auto;
        min-height: initial;
        padding: 1.25rem 1.25rem 1.875rem; /* 20px 20px 30px при базе 15px */
        border-radius: 0;/* 0 2.5rem 2.5rem;*/
    }

    .site-header.visible
    {
        z-index: initial;
    }

    .header-nav{
        display: none;
    }

    .top-header-line {
        flex-wrap: wrap;
        gap: 0.9375rem;
    }

    .mobile-menu
    {
        display: block;
        position: absolute;
        top: 5px;
        right: 0px;
        color: var(--white);
        font-size: 24px;
    }

    .logo-icon
    {
        margin-bottom: 0;
    }

    

    .header-nav {
        order: 3;
        width: 100%;
        justify-content: space-around;
        gap: 0.625rem;
    }

    .center-header {
        grid-template-columns: 1fr;
        gap: 0.9375rem;
        margin-top: 0.625rem;
    }

    .center-header .left,
    .center-header .right {
        display: none;
    }

    .center-title {
        max-width: 100%;
    }

    h1 {
        font-size: 2.4rem; /* 36px при базе 15px -> 36/15 = 2.4rem */
    }

    .center-title .desc {
        font: 400 1.2rem/1.2 'Golos Text', sans-serif; /* 18px /15 = 1.2rem */
    }

    .content-block {
        grid-template-columns: 1fr;
        margin-top: -1.875rem;
    }

    .left-menu-container {
        display: none;
        padding: 3.75rem 0 0.625rem;
        border-right: none;
        background-color: #fff;
    }

    .left-menu-container .mobile-menu {
        display: block;
        position: absolute;
        right: 15px;
        top: 15px;
        color: var(--blue);
    }


    .left-menu-container.visible {
        display: block;
        position: fixed;
        top: 0px;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        z-index: 100;
    }
    .sidebar {
        position: static;
        top: 0;
    }

    .menu-link {
        padding: 0.9375rem 1.25rem;
        border-left: none;
        border-bottom: 1px solid #E3EAF5;
    }

    .menu-link .arrow {
        font-size: 1.25rem;
    }

    .submenu-link {
        padding: 0.625rem 1.25rem 0.625rem 2.5rem;
    }

    .submenu-link::before {
        left: 1.25rem;
    }

    .main-content {
        padding: 2.5rem 1.25rem 3.125rem;
    }

    .name_conf {
        font: 600 1.6rem/1.2 'Golos Text', sans-serif; /* 24px /15 = 1.6rem */
        margin-bottom: 1.875rem;
    }

    .full-info {
        grid-template-columns: 1fr;
        gap: 1.875rem;
        min-height: auto;
    }

    .full-info-text {
        gap: 1.875rem;
    }

    .files {
        gap: 1.125rem;
    }

    .files .file-div .file-icon {
        width: 2.25rem;
        height: 2.5rem;
        font-size: 1.5rem;
    }

    .type-file-name {
        left: 0.75rem;
        top: 1rem;
        font-size: 0.5rem;
    }

    .map {
        min-height: 18.75rem;
    }
}

/* Очень маленькие телефоны */
@media (max-width: 480px) {
    :root {
        font-size: 14px;  /* 1rem = 14px */
    }

    .site-header {
        padding: 1.0714rem 1.0714rem 1.7857rem; /* 15px 15px 25px в пересчёте */
    }

    h1 {
        /*font-size: 2rem;*/ /* 28px /14 = 2rem */
        font-size: 1.2rem;
        line-height: 130%;
        margin-top: 50%;
    }

    .center-title .desc {
        font-size: 1.1429rem; /* 16px /14 = 1.1429rem */
    }

    .menu-link {
        padding: 0.8571rem 1.0714rem;
    }

    .submenu-link {
        padding: 0.5714rem 1.0714rem 0.5714rem 2.1429rem;
        font-size: 1rem; /* 14px */
    }

    .submenu-link::before {
        left: 1.0714rem;
        width: 0.4286rem;
        height: 0.4286rem;
    }

    .main-content {
        padding: 4.1429rem 1.0714rem 2.8571rem;
    }

    .logo-icon img
    {
        width: 3rem;
    }

    .name_conf {
        font-size: 1.4286rem; /* 20px */
    }

    .files .file-div {
        gap: 0.5714rem;
    }

    .files .file-div .file-icon {
        width: 2.2857rem;   /* 32px */
        height: 2.5714rem;  /* 36px */
        font-size: 1.4286rem;
    }

    .type-file-name {
        left: 0.7143rem;
        top: 0.9286rem;
        font-size: 0.5rem;  /* 7px */
    }

    .file-name {
        font-size: 1rem;    /* 14px */
    }

    .file-info {
        font-size: 0.8571rem; /* 12px */
    }

    .bottom-line {
        flex-wrap: wrap;
        gap: 2rem;
        row-gap: 0.5rem;
    }

    .bottom-line a {
        width: 45%;
        flex: none;
    }
}