
.navbarcolor {color: rgb(255, 255, 255)!important;background-color: rgb(0, 12, 24); }
.content-text {color: rgb(18, 19, 24);}
.wblue {color: rgb(33, 150, 243);}

/*register ja login sivuille muotoilut*/
.login-frame {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 10px;
    margin-top: 100px;
}

.login-card {
    background: white;
    padding: 60px;
    border-radius: 16px;
    width: 100%;
    max-width: 520px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.login-card h2 {
    text-align: center;
    color: rgb(33, 150, 243);
    margin-bottom: 25px;
    font-size: 28px;
}

.login-input {
    width: 100%;
    padding: 16px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 14px;
}

.login-input:focus {
    border-color: rgb(33, 150, 243);
    outline: none;
    box-shadow: 0 0 5px rgba(33, 150, 243,0.4);
}

.login-button {
    width: 100%;
    padding: 16px;
    background: rgb(33, 150, 243);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    cursor: pointer;
}

.login-button:hover {background: rgb(30, 136, 229);}

.login-success {
    background: rgb(212, 237, 218);
    color: rgb(21, 87, 36);
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 6px;
}

.login-error {
    background: rgb(248, 215, 218);
    color: rgb(114, 28, 36);
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 6px;
}
/*media query puhelimelle kirjautumis sivuille*/ 
@media (max-width: 600px) {

    .login-card {padding: 25px;}

    .login-card h2 {font-size: 22px;}

    .w3-jumbo {font-size: 32px !important;}
}

html, body {height: 100%; margin: 0;}

.page-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.content {flex: 1;}

/*lomake ja chatti muotoilut*/
.chat-form {display: flex; gap: 10px;}
.chat-input {
    flex: 1;
    padding: 12px;
    border-radius: 25px;
    border: 1px solid rgb(200,200,200);
    outline: none;
    font-size: 14px;
}

.chat-input:focus {border-color: rgb(33,150,243);}

.chat-button {
    padding: 12px 18px;
    border-radius: 25px;
    border: none;
    background: rgb(33,150,243);
    color: white;
    cursor: pointer;
    font-weight: bold;
}
.chat-button:hover {background: rgb(25,118,210);}

.chat-box {
    background: rgb(255,255,255);
    max-width: 90%;
    max-width: 1000px;
    margin: auto;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}
.chat-messages {
    height: 60vh;
    overflow-y: auto;
    padding: 10px;
    border-radius: 10px;
    background: rgb(245,245,245);
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.chat-message {
    background: rgb(33,150,243);
    color: rgb(255,255,255);
    padding: 10px 14px;
    border-radius: 12px;
    margin-bottom: 10px;
    max-width: 60%;
    word-wrap: break-word;
}
.chat-message strong {
    display: block;
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 3px;
}
.chat-time {
    font-size: 12px;
    margin-left: 6px;
    opacity: 0.7;
}
.chat-image {
    max-width: 200px;
    margin-top: 8px;
    border-radius: 10px;
}
/*kuvan uploadaus napille muotoilu*/
input[type="file"] {
    display: none;
}
.file-label {
    display: inline-block;
    padding: 12px 18px;
    border-radius: 25px;
    background: rgb(33,150,243);
    color: white;
    cursor: pointer;
    font-weight: bold;
    text-align: center;
}

.file-label:hover {background: rgb(25,118,210);}

/*Chatissa kuvien kanssa tekstin korjaaminen*/
.message-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.message-text {word-wrap: break-word;}
.chat-image {
    max-width: 220px;
    border-radius: 10px;
    display: block;
}
/*Puhelimelle media query ja inputit koko leveiksi*/
@media (max-width: 600px) {

    .chat-box { width: 95%;padding: 10px; }
    .chat-message { max-width: 85%; font-size: 14px;}
    .chat-input {font-size: 14px;}
    .chat-button {width: 100%; margin-top: 5px;
    }
}
.login-input, .chat-input {width: 100%;box-sizing: border-box;}
.chat-form {display: flex; gap: 10px;}

@media (max-width: 600px) {
    .chat-form { flex-direction: column;}
}
/*oman viestin oikealle puolelle laitto*/
.own-message {
    align-self: flex-end;
    background-color: rgb(33, 150, 243);
    color: white;
    text-align: right;
}
/*Toisten käyttäjien viestit vasemmalle*/
.other-message {
    align-self: flex-start;
    background-color: rgb(240, 240, 240);
    color: black;
}
/*Viestin poistoon tehty näppäin adminille*/
.delete-button {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: red;
    cursor: pointer;
    text-decoration: none;
}
.delete-button:hover {text-decoration: underline;}

/*muotoilu kellonajalla perustuvalle tervehdykselle*/
.nav-greeting {
    float: right;
    padding: 12px 20px;
    color: white;
    font-size: 18px;
}