/*
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

/* Label/tag denoting the user that shared a connection */
.jdbc-share-tag {

    background: #0095ff;
    padding: 0.25em;

    -moz-border-radius:    0.25em;
    -webkit-border-radius: 0.25em;
    -khtml-border-radius:  0.25em;
    border-radius:         0.25em;

    color: white;
    font-size: 0.75em;
    font-weight: bold;

}
.totp-enroll p,.totp-details{font-size:.8em}.totp-qr-code{text-align:center}.totp-qr-code img{margin:1em;border:1px solid rgba(0,0,0,0.25);box-shadow:1px 1px 2px rgba(0,0,0,0.25);cursor:pointer}h3.totp-details-header{font-size:.8em}h3.totp-details-header::before{content:'▸ '}.totp-details-visible h3.totp-details-header::before{content:'▾ '}.totp-details,.totp-hide-details{display:none}.totp-details-visible .totp-details{display:table}.totp-details-visible .totp-hide-details{display:inline}.totp-details-visible .totp-show-details{display:none}.totp-hide-details,.totp-show-details{color:blue;text-decoration:underline;cursor:pointer;margin:0 .25em;font-weight:normal}.totp-details{margin:0 auto}.totp-details th{padding-right:.25em;text-align:left}.totp-details td{font-family:monospace}.totp-detail{display:inline-block;margin:0 .25em}@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Inter:wght@300;400;500&display=swap');

/* Solo login */
div.login-ui {
  background: #060d0f !important;
  background-image:
    radial-gradient(ellipse 80% 60% at 15% 20%, rgba(34, 197, 94, 0.07) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 85% 80%, rgba(34, 197, 94, 0.05) 0%, transparent 55%) !important;
  min-height: 100vh !important;
  color: #e2e8f0 !important;
}

div.login-ui::before {
  content: '' !important;
  position: fixed !important;
  inset: 0 !important;
  background-image: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 60px,
    rgba(34, 197, 94, 0.03) 60px,
    rgba(34, 197, 94, 0.03) 61px
  ) !important;
  pointer-events: none !important;
  z-index: 0 !important;
}

div.login-ui .login-dialog {
  position: relative !important;
  z-index: 10 !important;
  background: rgba(10, 18, 22, 0.88) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(34, 197, 94, 0.2) !important;
  border-radius: 20px !important;
  box-shadow:
    0 0 0 1px rgba(34, 197, 94, 0.05),
    0 25px 60px rgba(0, 0, 0, 0.6) !important;
  padding: 2.5rem 2rem !important;
  max-width: 400px !important;
  animation: dialogIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) both !important;
}

@keyframes dialogIn {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

div.login-ui .login-dialog .logo {
  display: block !important;
  width: 90px !important;
  height: 90px !important;
  margin: 0 auto 0.5rem auto !important;
  background-image: url("app/ext/pragom-theme/images/logo.png") !important;
  background-size: contain !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  filter: drop-shadow(0 0 20px rgba(34, 197, 94, 0.4)) !important;
}

div.login-ui .version,
div.login-ui .login-dialog .version {
  display: none !important;
}

div.login-ui .login-fields {
  margin-top: 1.5rem !important;
}

div.login-ui .labeled-field {
  margin-bottom: 0.75rem !important;
}

div.login-ui .labeled-field .field-header label {
  color: #94a3b8 !important;
  font-family: 'Inter', sans-serif !important;
  font-size: 0.85rem !important;
}

div.login-ui .labeled-field input,
div.login-ui input[type="text"],
div.login-ui input[type="password"],
div.login-ui input[type="number"] {
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(34, 197, 94, 0.25) !important;
  border-radius: 10px !important;
  color: #e2e8f0 !important;
  -webkit-text-fill-color: #e2e8f0 !important;
  font-family: 'Inter', sans-serif !important;
  font-size: 0.9rem !important;
  padding: 0.75rem 1rem !important;
  width: 100% !important;
  box-sizing: border-box !important;
  caret-color: #22c55e !important;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s !important;
}

div.login-ui input[type="number"] {
  font-size: 1.2rem !important;
  text-align: center !important;
  letter-spacing: 0.3em !important;
}

div.login-ui .labeled-field input:focus,
div.login-ui input[type="text"]:focus,
div.login-ui input[type="password"]:focus,
div.login-ui input[type="number"]:focus {
  outline: none !important;
  border-color: rgba(34, 197, 94, 0.6) !important;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1) !important;
  background: rgba(255, 255, 255, 0.06) !important;
}

div.login-ui .buttons,
div.login-ui .login-dialog .buttons {
  margin-top: 1.25rem !important;
}

div.login-ui .buttons input[type="submit"],
div.login-ui .buttons button,
div.login-ui input[type="submit"] {
  width: 100% !important;
  background: linear-gradient(135deg, #16a34a 0%, #22c55e 100%) !important;
  border: none !important;
  border-radius: 10px !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  font-family: 'Rajdhani', sans-serif !important;
  font-size: 1rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  padding: 0.85rem !important;
  cursor: pointer !important;
  box-shadow: 0 4px 20px rgba(34, 197, 94, 0.3) !important;
  transition: filter 0.2s, transform 0.1s, box-shadow 0.2s !important;
}

div.login-ui .buttons input[type="submit"]:hover,
div.login-ui .buttons button:hover {
  filter: brightness(1.1) !important;
  box-shadow: 0 6px 28px rgba(34, 197, 94, 0.45) !important;
  transform: translateY(-1px) !important;
}

div.login-ui .login-dialog .error {
  background: rgba(239, 68, 68, 0.1) !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
  border-radius: 8px !important;
  color: #fca5a5 !important;
  font-family: 'Inter', sans-serif !important;
  font-size: 0.85rem !important;
  padding: 0.6rem 0.9rem !important;
  margin-bottom: 0.75rem !important;
}

div.login-ui .login-dialog p,
div.login-ui .login-dialog .instructions {
  color: #94a3b8 !important;
  font-family: 'Inter', sans-serif !important;
  font-size: 0.88rem !important;
  text-align: center !important;
  margin-bottom: 1rem !important;
  line-height: 1.5 !important;
}

/* Ocultar labels SOLO en login */
div.login-ui .field-header {
  display: none !important;
}

/* Ajustar spacing al quitarlos */
div.login-ui .labeled-field {
  margin-bottom: 0.9rem !important;
}
