/* server/static/login.css */

body {
    font-family: Arial, sans-serif;
    /*background-image: url('https://www.kanazawa-it.ac.jp/h1s/images/common/page_title/page_title_sotsugyosei_2x.jpg');*/
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-color: #E0FFFF;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    box-sizing: border-box;
}

.login-container {
    background-color: rgba(255, 255, 255, 0.85);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    text-align: center;
    width: 90%;
    max-width: 400px;
    position: relative;
}

.login-container h1 {
    color: #00BFFF;
    margin-top: 0;
    margin-bottom: 25px;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.form-group input {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 40px 10px 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
}

button[type="submit"] {
    background-color: #00BFFF;
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    transition: background-color 0.3s ease;
    width: 100%;
    margin-top: 10px;
}

button[type="submit"]:hover {
    background-color: #009ACD;
}

.message {
    margin-top: 20px;
    font-weight: bold;
    min-height: 1.2em;
}
.message.success { color: green; }
.message.error { color: red; }

.password-wrapper {
    position: relative;
}
.toggle-password-icon {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    cursor: pointer;
    width: 20px;
    height: 20px;
    opacity: 0.7;
}

/* --- Modal styles --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
.modal-content {
    background-color: white;
    padding: 20px 30px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    width: 90%;
    max-width: 700px;
    max-height: 85%;
    position: relative;
    display: flex;
    flex-direction: column;
}
.modal-close-button {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
}
.modal-close-button:hover { color: #333; }
.modal-content h2 {
    text-align: center;
    color: #00BFFF;
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
    flex-shrink: 0;
}
.terms-text-box {
    flex-grow: 1;
    overflow-y: auto;
    text-align: left;
    font-size: 14px;
    line-height: 1.6;
    padding-right: 15px;
    margin-top: 15px;
}
.terms-text-box h4 {
    margin-top: 20px;
    margin-bottom: 5px;
    color: #333;
}
.terms-text-box p, .terms-text-box ol, .terms-text-box ul {
    margin-top: 5px;
    margin-bottom: 10px;
    color: #555;
}
.terms-text-box li { margin-bottom: 5px; }
.modal-agree-button {
    width: 100%;
    padding: 12px;
    margin-top: 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
}
.modal-agree-button:hover { background-color: #0056b3; }


/* --- Styles moved from login.html --- */
.extra-links {
    margin-top: 15px;
    font-size: 14px;
    text-align: center;
}
.extra-links a {
    color: #007bff;
    text-decoration: none;
    margin: 0 10px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
}
.extra-links a:hover { text-decoration: underline; }




/* --- Corrected Cookie Consent Banner Styles --- */
#cookieConsentBanner {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 15px 5%;
    z-index: 3000;
    font-size: 14px;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.2);
    box-sizing: border-box;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
    text-align: center;
}
#cookieConsentBanner p {
     margin: 0;
}
#cookieConsentBanner a {
    color: #00BFFF;
    text-decoration: underline;
    cursor: pointer;
}
#acceptCookieButton {
    background-color: #00BFFF;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    flex-shrink: 0;
    transition: background-color 0.2s ease;
}
#acceptCookieButton:hover {
    background-color: #009ACD;
}

@media (max-width: 768px) {
    #cookieConsentBanner {
        padding: 15px;
    }
     #cookieConsentBanner p {
         width: 100%;
         margin-bottom: 10px;
     }
    #acceptCookieButton {
         width: auto;
         padding: 8px 30px;
    }
}

/* Add padding to the bottom of the body ONLY when the banner is visible */
body:has(#cookieConsentBanner[style*="display: flex"]) {
  /* Increase padding to ensure content isn't hidden by the banner */
  padding-bottom: 150px;
}

/* Adjust for smaller screens where the banner might wrap and become taller */
@media (max-width: 768px) {
  body:has(#cookieConsentBanner[style*="display: flex"]) {
    padding-bottom: 180px;
  }
}
