/* ===== 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; }

/* ===== 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;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: calc(100vh - 70px);
    padding: 40px 0;
}

.intro__inner {
    width: 100%;
}

/* ===== Authorization ===== */
.introAutorization {
    display: block;
    position: relative;
    z-index: 101;
    width: 100%;
}

.introAutorization.show {
    display: none;
}

.autorizationLogin {
    display: flex;
    flex-direction: column;
    text-align: center;
    align-items: center;
    margin-top: 40px;
}

/* ===== Authorization form box ===== */
.autorizationBox {
    height: 280px;
    width: 480px;
    max-width: 100%;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 8px 32px rgba(123, 127, 189, 0.15);
    transition: all 0.3s ease;
    padding: 20px;
}

.autorizationBox.show {
    display: none;
}

.autorizationBox:hover {
    box-shadow: 0 12px 40px rgba(123, 127, 189, 0.22);
    transform: translateY(-2px);
}

.tittleAutorization {
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Comfortaa', cursive;
    font-size: 16px;
    font-weight: 600;
    color: #4a4a5a;
    width: 100%;
    height: 70px;
    text-align: center;
}

/* ===== Form inputs ===== */
input[type=name],
input[type=password] {
    font-family: 'Nunito', sans-serif;
    font-size: 15px;
    color: #4a4a5a;
    padding: 12px 16px;
    margin: 8px auto;
    display: block;
    width: 90%;
    max-width: 380px;
    height: 48px;
    border: 2px solid rgba(123, 127, 189, 0.2);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.8);
    box-shadow: inset 0 2px 4px rgba(123, 127, 189, 0.06);
    outline: none;
    transition: all 0.3s ease;
}

input[type=name]::placeholder,
input[type=password]::placeholder {
    color: #9da5be;
    font-weight: 400;
}

input[type=name]:hover,
input[type=password]:hover {
    border-color: rgba(123, 127, 189, 0.35);
    box-shadow: 0 2px 12px rgba(123, 127, 189, 0.1);
}

input[type=name]:focus,
input[type=password]:focus {
    border-color: #7b7fbd;
    box-shadow: 0 2px 16px rgba(123, 127, 189, 0.18);
    background: white;
}

/* ===== Enter authorization blocks ===== */
.enterAutorization {
    display: none;
    color: #4a4a5a;
    padding: 40px 20px;
    text-decoration: none;
    font-family: 'Nunito', sans-serif;
    font-size: 17px;
    font-weight: 600;
    text-align: center;
    transition: all 0.25s ease;
}

.enterAutorization.show {
    display: block;
}

.enterAutorization div:first-child {
    margin-bottom: 16px;
    line-height: 1.5;
}

/* ===== Authorization logo (SVG) ===== */
.logoAutorization {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #7b7fbd, #c98ba8);
    border-radius: 20px;
    box-shadow: 0 4px 16px rgba(123, 127, 189, 0.3);
    transition: all 0.25s ease;
    animation: pulse 2500ms infinite;
}

@keyframes pulse {
    0%   { transform: scale(1);    opacity: 0.85; }
    50%  { transform: scale(1.08); opacity: 1; }
    100% { transform: scale(1);    opacity: 0.85; }
}

.logoAutorization:hover {
    transform: scale(1.12);
    box-shadow: 0 6px 24px rgba(123, 127, 189, 0.4);
    animation: none;
}

/* ===== 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: 20px 0;
    margin-top: 40px;
}

.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) {
    .autorizationBox {
        width: 100%;
        height: auto;
        padding: 16px;
    }

    input[type=name],
    input[type=password] {
        width: 100%;
    }

    .tittleAutorization {
        font-size: 14px;
        height: 50px;
    }

    .nav { flex-wrap: wrap; }
    .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; }
    .enterAutorization { font-size: 15px; padding: 30px 16px; }
}