/* ============================================================
   Дистанция-образование — главная страница
   style.css — стеклянная редакция (единая стилистика с
   style__educate.css и style__lessons.css)
   Nunito + Comfortaa, блобы, парящие декорации, стеклянные карточки.
   ============================================================ */

/* ===== Base ===== */
body {
    margin: 0;
    font-family: 'Nunito', sans-serif;
    line-height: 1.6;
    font-size: 16px;
    color: #4a4a5a;
    background: linear-gradient(180deg, #f5f3fa 0%, #faf5f8 50%, #f0f5fa 100%);
    min-height: 100vh;
}

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

h1, h2, h3, h4, h5, h6 { margin: 0; font-family: 'Comfortaa', cursive; }

a { color: inherit; }

::selection {
    background: rgba(123, 127, 189, 0.25);
    color: #3d3d55;
}

a:focus-visible {
    outline: 3px solid #7b7fbd;
    outline-offset: 2px;
    border-radius: 10px;
}

/* ===== Container ===== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Decorative blobs ===== */
.bg-blobs {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}
.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.35;
}
.blob:nth-child(1) { width: 400px; height: 400px; background: #7b7fbd; top: -100px; left: -100px; }
.blob:nth-child(2) { width: 350px; height: 350px; background: #c98ba8; top: 30%; right: -80px; }
.blob:nth-child(3) { width: 300px; height: 300px; background: #6b9bc4; bottom: 10%; left: -60px; }
.blob:nth-child(4) { width: 280px; height: 280px; background: #6ba89a; bottom: -80px; right: 20%; }

/* ===== Decorative shapes ===== */
.decor {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}
.decor__cloud, .decor__star, .decor__dot { position: absolute; }
.decor__cloud { width: 100px; height: 60px; }
.decor__star  { width: 24px; height: 24px; }
.decor__dot   { width: 40px; height: 40px; }
.decor--1 { top: 8%;  left: 5%;  animation: float 8s ease-in-out infinite; }
.decor--2 { top: 22%; right: 8%; animation: float 10s ease-in-out infinite reverse; }
.decor--3 { top: 40%; left: 3%;  animation: float 7s ease-in-out infinite; }
.decor--4 { top: 60%; right: 4%; animation: float 9s ease-in-out infinite reverse; }
.decor--5 { top: 75%; left: 6%;  animation: float 11s ease-in-out infinite; }
.decor--6 { top: 15%; left: 45%; animation: float 12s ease-in-out infinite reverse; }

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50%      { transform: translateY(-20px) rotate(5deg); }
}

/* ===== Header ===== */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 12px 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 2px 20px rgba(123, 127, 189, 0.12);
    border-bottom: 1px solid rgba(123, 127, 189, 0.1);
}

.header__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: #4a4a5a;
}

.logo__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #7b7fbd, #c98ba8);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(123, 127, 189, 0.3);
}

.logo__contain {
    display: flex;
    flex-direction: column;
}

.logo__text {
    font-size: 16px;
    font-weight: 700;
    color: #4a4a5a;
    line-height: 1.2;
}

.logo__subtitle {
    font-family: 'Nunito', sans-serif;
    font-size: 11px;
    font-weight: 600;
    color: #9da5be;
    line-height: 1.2;
}

/* ===== Nav ===== */
.nav {
    display: flex;
    gap: 8px;
}

.nav__link {
    font-family: 'Nunito', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #4a4a5a;
    text-decoration: none;
    padding: 8px 18px;
    border-radius: 20px;
    transition: all 0.25s ease;
}

.nav__link:hover {
    color: #7b7fbd;
    background: rgba(123, 127, 189, 0.1);
    box-shadow: 0 2px 8px rgba(123, 127, 189, 0.15);
}

/* ===== Intro (герой) ===== */
.intro {
    position: relative;
    z-index: 2;
    padding: 60px 0 80px;
}

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

.tittleContain {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    margin-bottom: 40px;
}

.intro__tittle {
    font-size: 42px;
    font-weight: 700;
    line-height: 1.3;
    max-width: 800px;
    background: linear-gradient(135deg, #5a5e9e 0%, #b05587 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: #5a5e9e;
}

.scientist__logo {
    max-width: 240px;
    height: auto;
    filter: drop-shadow(0 12px 24px rgba(123, 127, 189, 0.3));
    animation: float 8s ease-in-out infinite;
}

/* ===== Блок курсов ===== */

.intro__subinner {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 28px 32px 32px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(123, 127, 189, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.subinner__tittle { margin-bottom: 20px; }

.sub__tittle {
    font-size: 18px;
    font-weight: 700;
    color: #4a4a5a;
    text-align: center;
}

.intro__components {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
}

/* Карточки-компоненты */

.components {
    position: relative;
    flex: 1 1 260px;
    max-width: 420px;
    padding: 28px 30px 30px;
    text-decoration: none;
    color: #4a4a5a;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(123, 127, 189, 0.15);
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(123, 127, 189, 0.1);
    transition: all 0.25s ease;
    overflow: hidden;
}

.components::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    background: linear-gradient(180deg, #7b7fbd 0%, #c98ba8 100%);
}

.components::after {
    content: "→";
    position: absolute;
    right: 24px;
    bottom: 22px;
    font-family: 'Nunito', sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: #7b7fbd;
    transition: all 0.25s ease;
}

.components:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(123, 127, 189, 0.2);
    border-color: rgba(201, 139, 168, 0.35);
}

.components:hover::after {
    color: #c98ba8;
    transform: translateX(4px);
}

.component__tittle {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
    padding-right: 30px;
}

/* ===== Underfooter ===== */
.underfooter {
    position: relative;
    z-index: 2;
    background: rgba(237, 242, 255, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-top: 1px solid rgba(123, 127, 189, 0.1);
    padding: 24px 0 20px;
    margin-top: 40px;
}

.underfooter__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
}

.underfooter__sign {
    text-align: center;
    font-family: 'Nunito', sans-serif;
    font-size: 12px;
    font-weight: 500;
    color: #9da5be;
}

.underfooter__sign p { margin: 0; }

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .intro { padding: 40px 0 60px; }
    .intro__tittle { font-size: 28px; }
    .scientist__logo { max-width: 180px; }
    .intro__subinner { padding: 20px; }
    .components { flex: 1 1 100%; }
    .nav { flex-wrap: wrap; justify-content: center; }
    .nav__link { font-size: 13px; padding: 6px 12px; }
    .logo__text { font-size: 14px; }
    .logo__subtitle { font-size: 10px; }
}

@media (max-width: 480px) {
    .header__inner { flex-direction: column; gap: 10px; }
    .underfooter__inner { flex-direction: column; gap: 12px; }
    .intro__tittle { font-size: 22px; }
}
