/* === 1. FONTS & RESETS === */
@font-face {
    src: url("/assets/fonts/Terminus.ttf");
    font-family: Terminus;
}

@font-face {
  font-family: Inter;
  src: url("/assets/fonts/Inter-Medium.ttf");
  font-display: block;
}
 
:root {
    --font-mono: Terminus, monospace;
}

html {
    -webkit-text-size-adjust: 100%;
    -webkit-overflow-scrolling: touch;
}

body {
    -webkit-overflow-scrolling: touch;
    background: #101010;
    color: #19AAD8;
    font-family:  'Roboto Mono', 'JetBrains Mono', Inter;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 95vh;
    margin: 0;
    position: relative;
    box-sizing: border-box;
    overflow: hidden;
}

/* === 2. CANVAS BACKGROUND === */
#canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    outline: none;
}

/* === 3. HEADER / LOGO === */
.logo-top {
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 10;
}
.logo-top a {
    font-size: 34px;
    color: #7d7d7d;
    text-decoration: none;
}

/* === 4. MAIN CARD === */
.login-card {
    position: relative;
    z-index: 5;
    width: 90%;
    max-width: 400px;
    padding: 30px 20px; 
    background: rgba(20, 20, 20, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 0 50px #000000;
    text-align: center;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* === 5. PILL TOGGLE === */
.toggle-pill {
    display: flex;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 26px;
    padding: 4px;
    margin-bottom: 25px;
    width: fit-content;
}

.toggle-btn {
    font-family: inherit;
    background: transparent;
    border: none;
    color: #888;
    padding: 8px 24px;
    border-radius: 26px;
    font-size: 14px; 
    cursor: pointer;
    transition: all 0.3s ease;
    width: auto;
    margin-bottom: 0;
}

.toggle-btn:hover {
    color: #fff;
    background: transparent;
}

.toggle-btn.active {
    background: rgba(255, 255, 255, 0.1);
    color: #19AAD8;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* === 6. INPUT STYLES === */
.input-container {
    position: relative;
    width: 100%;
}

input {
    border: none;
    font-family: var(--font-mono);
    border: 1px solid #323232;
    border-radius: 10px;
    background: #0d0d0d;
    color: #A0A0A0;
    width: 100%;
    font-size: 16px;
    margin-bottom: 15px;
    padding: 12px;
    box-sizing: border-box;
    transition: all 0.3s;
}

#login-username, #reg-username, #reg-email {
    text-transform: normal; 
}

input[type="password"] {
    padding-right: 40px; 
}

input:focus {
    outline: none;
    border: 1px solid #19AAD8;
    box-shadow: 0 0 5px rgba(25, 170, 216, 0.4);
}

.input-container i {
    position: absolute;
    right: 15px;
    top: 14px;
    cursor: pointer;
    color: #7d7d7d;
    z-index: 10;
}
.input-container i:hover {
    color: #19AAD8;
}

/* === 7. BUTTONS === */
.action-btn { 
    font-family: inherit;
    background-color: #a0a0a0;
    color: #0f0f0f;
    border: none;
    width: 100%;
    font-size: 16px;
    margin-bottom: 15px;
    padding: 12px;
    box-sizing: border-box;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
    border-radius: 20px;
    margin-top: 10px;
}

.action-btn:hover {
    background-color: #19AAD8;
    color: black;
    box-shadow: 0 0 10px rgba(25, 170, 216, 0.4);
}

/* NEW: DISABLED STATE STYLE */
.action-btn:disabled {
    background-color: #333 !important;
    color: #777 !important;
    cursor: not-allowed;
    box-shadow: none !important;
    opacity: 0.6;
}

/* === 8. TEXT & UTILITIES === */
h2.form-header {
    margin-top: 0;
    margin-bottom: 20px;
    font-weight: normal;
    font-size: 1.2rem;
    color: #a0a0a0;
    width: 100%;
    text-align: left;
    padding-left: 5px;
}

.forgot-container {
    display: flex;
    justify-content: flex-end;
    margin-top: -10px;
    margin-bottom: 15px;
    width: 100%;
}

.forgot-link {
    font-family: inherit;
    background: none;
    border: none;
    color: #7d7d7d;
    font-size: 12px; 
    text-decoration: none;
    cursor: pointer;
    padding: 0;
}

.forgot-link:hover {
    color: #f50000;
}

#message {
    margin-top: 10px;
    font-size: 0.9em;
    text-align: center;
    min-height: 20px; 
}
.ok { color: #19AAD8;  }
.err { color: #f50000;   }

.hidden-section {
    display: none !important;
}

#inapp-warning {
    z-index: 999;
    position: relative;
}

.footer {
    margin-top: 20px; 
    font-size: 0.7rem; 
    color: #444; 
}