/* ============================================
   Access Gate — H.E. Shamma Al Mazrui
   Emerald / Teal Premium Glassmorphism
   ============================================ */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #041c1a 0%, #0a2e2a 25%, #0d3d35 50%, #115e4a 75%, #0f7b5f 100%);
  overflow: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 70%, rgba(196, 169, 86, 0.06) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 50%, rgba(6, 95, 70, 0.12) 0%, transparent 60%);
  pointer-events: none;
}

body::after {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.015'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
  opacity: 0.5;
}

/* Animated background orbs */
.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.12;
  animation: floatOrb 22s ease-in-out infinite;
}

.bg-orb-1 {
  width: 550px;
  height: 550px;
  background: radial-gradient(circle, #10b981, #065f46);
  top: -18%;
  left: -12%;
  animation-delay: 0s;
}

.bg-orb-2 {
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, #c4a956, #8b7a32);
  bottom: -12%;
  right: -12%;
  animation-delay: -8s;
}

.bg-orb-3 {
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, #059669, #047857);
  top: 55%;
  left: 55%;
  transform: translate(-50%, -50%);
  animation-delay: -15s;
}

.bg-orb-4 {
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, #34d399, #10b981);
  top: 10%;
  right: 20%;
  animation-delay: -4s;
  opacity: 0.06;
}

@keyframes floatOrb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(35px, -35px) scale(1.06); }
  50% { transform: translate(-25px, 25px) scale(0.94); }
  75% { transform: translate(25px, 15px) scale(1.03); }
}

/* Access card */
.access-card {
  position: relative;
  z-index: 10;
  width: min(460px, 92vw);
  padding: 3.2rem 2.8rem;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(35px) saturate(1.2);
  -webkit-backdrop-filter: blur(35px) saturate(1.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  box-shadow:
    0 35px 90px rgba(0, 0, 0, 0.35),
    0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  text-align: center;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes cardEnter {
  from { opacity: 0; transform: translateY(50px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Shield emblem */
.access-emblem {
  width: 68px;
  height: 68px;
  margin: 0 auto 1.8rem;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(196, 169, 86, 0.2), rgba(16, 185, 129, 0.1));
  border: 1px solid rgba(196, 169, 86, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.2s both;
}

.access-emblem svg {
  width: 30px;
  height: 30px;
  stroke: #c4a956;
  fill: none;
  stroke-width: 1.5;
}

.access-pretitle {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(196, 169, 86, 0.7);
  margin-bottom: 0.6rem;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.25s both;
}

.access-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.4rem;
  letter-spacing: -0.02em;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.3s both;
}

.access-subtitle {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 2.8rem;
  line-height: 1.5;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.4s both;
}

.access-form {
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.5s both;
}

.input-wrapper {
  position: relative;
  margin-bottom: 1.4rem;
}

.input-wrapper svg {
  position: absolute;
  left: 1.1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  stroke: rgba(255, 255, 255, 0.3);
  fill: none;
  stroke-width: 1.5;
  pointer-events: none;
  transition: stroke 0.3s;
}

.access-input {
  width: 100%;
  padding: 1rem 1.1rem 1rem 3rem;
  font-size: 0.95rem;
  font-family: 'Inter', sans-serif;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  color: #ffffff;
  transition: all 0.3s;
}

.access-input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.access-input:focus {
  outline: none;
  border-color: rgba(16, 185, 129, 0.5);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.08);
}

.access-input:focus + svg,
.access-input:focus ~ svg {
  stroke: #10b981;
}

.access-btn {
  width: 100%;
  padding: 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.35s;
  letter-spacing: 0.02em;
  position: relative;
  overflow: hidden;
}

.access-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.access-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 35px rgba(16, 185, 129, 0.3);
}

.access-btn:hover::before { opacity: 1; }

.access-btn:active {
  transform: translateY(0);
}

/* Error message */
.access-error {
  margin-top: 1.2rem;
  padding: 0.75rem 1rem;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.18);
  border-radius: 12px;
  font-size: 0.84rem;
  color: #fca5a5;
  opacity: 0;
  transform: translateY(-8px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.access-error.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Shake */
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
  20%, 40%, 60%, 80% { transform: translateX(5px); }
}

.shake { animation: shake 0.5s ease-in-out; }

.access-footer {
  margin-top: 2.8rem;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.25);
  letter-spacing: 0.03em;
  animation: cardEnter 0.9s cubic-bezier(0.4, 0, 0.2, 1) 0.6s both;
}

/* Responsive */
@media (max-width: 480px) {
  .access-card {
    padding: 2.5rem 1.8rem;
    border-radius: 22px;
  }
  .access-title { font-size: 1.35rem; }
}
