
@font-face {
    font-family: 'CustomPixelFont';
    src: url("/fonts/FGC111.ttf") format('truetype');
    font-weight: normal;
    font-style: normal;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'CustomPixelFont','Courier New',  monospace;
    background: #ffffff;
    
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.background-shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.shape { position: absolute; opacity: 0.6; }
.triangle { width: 0; height: 0; border-left: 25px solid transparent; border-right: 25px solid transparent; border-bottom: 50px solid #ff6b35; }
.cross-pink { width: 40px; height: 40px; background-image: linear-gradient(to bottom, #ff69b4, #ff69b4), linear-gradient(to right, #ff69b4, #ff69b4); background-size: 8px 100%, 100% 8px; background-position: center; background-repeat: no-repeat; }
.cross-green { width: 35px; height: 35px; background-image: linear-gradient(to bottom, #90ee90, #90ee90), linear-gradient(to right, #90ee90, #90ee90); background-size: 7px 100%, 100% 7px; background-position: center; background-repeat: no-repeat; }
.circle-blue { width: 45px; height: 45px; border: 8px solid #87ceeb; border-radius: 50%; background: transparent; }

.container {
    max-width: 450px;
    width: 90%;
    padding: 40px 30px;
    position: relative;
    z-index: 1;
    
    background: rgba(255, 255, 255, 0.6);
    border: 4px solid #000;
    backdrop-filter: blur(8px);
    box-shadow: 
        8px 8px 0px #000,
        15px 15px 25px rgba(0, 0, 0, 0.15);
    border-radius: 6px;
}

.main-header {
    display: flex;
    flex-direction: column; 
    align-items: center;   
    gap: 15px;             
    margin-bottom: 35px;   
    text-align: center;
}

.logo {
    width: 90px;
    height: 90px;
}

.title-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.main-title {
    font-family:'Courier New','CustomPixelFont', monospace;
    font-size: 48px;
    color: #000;
    margin: 0;
    line-height: 1;
    font-weight: bold;
}

.sub-title {
    font-family:   'Courier New','CustomPixelFont', monospace;
    font-size: 14px;
    color: #333;
    margin-top: 8px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px; 
}

.pixel-input {
    width: 100%;
    padding: 15px 20px;
    font-size: 18px;
    font-weight: bold;
    border: 4px solid #000;
    background: rgba(255, 255, 255, 0.95);
    font-family:  'CustomPixelFont','Courier New',  monospace;
    border-radius: 4px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.pixel-input:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 4px rgba(255, 107, 53, 0.4);
}

.login-button {
    padding: 15px 20px;
    font-size: 20px;
    font-weight: bold;
    color: #fff;
    background-color: #000;
    border: 4px solid #000;
    font-family:  'CustomPixelFont','Courier New',  monospace;
    cursor: pointer;
    border-radius: 4px;
    margin-top: 10px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.login-button:hover {
    background-color: #ff6b35; 
    transform: translateY(-3px);
}

.login-button:active {
    transform: translateY(1px);
}

.login-button:disabled {
    background-color: #888;
    cursor: not-allowed;
    transform: translateY(0);
}

#message {
    font-family: 'CustomPixelFont','Courier New',  monospace;
    margin-top: 20px;
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    min-height: 20px;
    color: #d9534f; 
}

.transition-message {
    display: inline-flex;
    align-items: baseline;
    color: #5cb85c;
}

.transition-ellipsis {
    display: inline-flex;
    width: 1.45em;
    margin-left: .08em;
}

.transition-ellipsis > span {
    display: inline-block;
    animation: transition-dot-hop .9s ease-in-out infinite;
}

.transition-ellipsis > span:nth-child(2) {
    animation-delay: .12s;
}

.transition-ellipsis > span:nth-child(3) {
    animation-delay: .24s;
}

@keyframes transition-dot-hop {
    0%,
    60%,
    100% {
        opacity: .32;
        transform: translateY(0);
    }
    30% {
        opacity: 1;
        transform: translateY(-.32em);
    }
}

@media (max-width: 480px) {
    .container {
        padding: 30px 20px;
    }
    .main-title {
        font-size: 36px;
    }
    .pixel-input, .login-button {
        font-size: 16px;
        padding: 12px 15px;
    }
}

.input-group {
    position: relative;
    margin-bottom: 15px; 
}

.error-message {
    font-family: 'CustomPixelFont','Courier New',  monospace;
    color: #e74c3c; 
    font-size: 13px;
    font-weight: bold;
    text-align: left;
    margin-top: 6px; 
    height: 15px; 
    opacity: 0; 
    transition: opacity 0.3s ease; 
}

.error-message.visible {
    opacity: 1; 
}

.pixel-input.invalid {
    border-color: #e74c3c; 
    box-shadow: 0 0 0 4px rgba(231, 76, 60, 0.4); 
}

.login-form {
    gap: 5px; 
}
.login-button {
    margin-top: 5px;
}

.password-wrapper {
    position: relative;
    width: 100%;
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.toggle-password:hover {
    opacity: 0.6;
}

.toggle-password::before {
    content: '';
    position: absolute;
    top: 3px;
    left: 2px;
    width: 22px;
    height: 12px;
    border: 2.5px solid #aaa;
    border-radius: 50% 50% 50% 50% / 80% 80% 20% 20%;
    background: transparent;
    transition: all 0.3s ease;
}

.toggle-password::after {
    content: '';
    position: absolute;
    top: 8px;
    left: 9px;
    width: 8px;
    height: 8px;
    background: #aaa;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.toggle-password {
    background: 
        linear-gradient(to top right, 
            transparent calc(50% - 1.5px), 
            #aaa calc(50% - 1.5px), 
            #aaa calc(50% + 1.5px), 
            transparent calc(50% + 1.5px)
        );
}

.toggle-password.show-password {
    background: none;
}

.toggle-password.show-password::before {
    border-color: #333;
}

.toggle-password.show-password::after {
    background: #333;
}
