/* ===== Reset & Base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

html, body {
  height: 100%;
  width: 100%;
  overflow-x: hidden;
}

/* ===== Background & Overlay ===== */
.background,
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  min-width: 100%;
  min-height: 100%;
}

.background {
  background: url('background.jpg') no-repeat center center;
  background-size: cover;
  filter: blur(8px);
  z-index: -2;
}

.overlay {
  background: rgba(0,0,0,0.5);
  z-index: -1;
}

/* ===== Layout ===== */
.container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100%;
  padding: 20px;
}

/* ===== Card ===== */
.card {
  position: relative;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 80px 20px 40px;
  border-radius: 12px;
  text-align: center;
  color: white;
  max-width: 450px;
  width: 90%;
  box-shadow: 0 8px 30px rgba(0,0,0,0.3);

  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 1s ease forwards;

  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5),
              0 0 20px rgba(255,255,255,0.1);
}

/* ===== Animation ===== */
@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Typography ===== */
.card h1 {
  margin-bottom: 10px;
  font-size: 2rem;
}

.card p {
  margin-bottom: 25px;
  font-size: 1.1rem;
  opacity: 0.9;
}

.subtitle {
  font-size: 1rem;
  opacity: 0.85;
  margin-bottom: 25px;
}

/* ===== Headshot ===== */
.headshot {
  position: absolute;
  top: -60px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(255, 255, 255, 0.9);
  box-shadow: 0 8px 25px rgba(0,0,0,0.5);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.headshot:hover {
  transform: translateX(-50%) scale(1.05);
  box-shadow: 0 12px 35px rgba(0,0,0,0.6);
}

/* ===== Links ===== */
.links {
  display: flex;
  justify-content: center;
  gap: 25px;
  margin-top: 20px;
  padding-top: 15px;
  border-top: 1px solid rgba(255,255,255,0.15);
}

.links a {
  position: relative;
  font-size: 1.8rem;
  color: white;
  text-decoration: none;
  transition: transform 0.25s ease, color 0.25s ease;
}

.links a:hover {
  transform: scale(1.25) translateY(-3px);
}

/* Tooltip */
.links a::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  background: rgba(0, 0, 0, 0.85);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  transition: all 0.25s ease;
}

.links a::before {
  content: "";
  position: absolute;
  bottom: -28px;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  border-width: 6px;
  border-style: solid;
  border-color: transparent transparent rgba(0, 0, 0, 0.85) transparent;
  opacity: 0;
  transition: all 0.25s ease;
}

.links a:hover::after,
.links a:hover::before {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Page-specific link colors */
.home-links a:nth-child(1):hover { color: #0A66C2; }
.home-links a:nth-child(2):hover { color: #ffffff; }
.home-links a:nth-child(3):hover { color: #f87171; }
.home-links a:nth-child(4):hover { color: #34d399; }

.contact-links a:hover {
  color: #60a5fa;
}

/* ===== Form ===== */
form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: 10px;
}

input, textarea {
  padding: 12px 15px;
  border-radius: 8px;
  border: none;
  outline: none;
  font-size: 1rem;
}

input::placeholder,
textarea::placeholder {
  color: rgba(0,0,0,0.5);
}

button {
  padding: 12px 15px;
  border-radius: 8px;
  border: none;
  background: #ffffff33;
  color: white;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

button:hover {
  background: #ffffff55;
  transform: scale(1.05);
}

/* ===== Success Message ===== */
.success-message {
  opacity: 0;
  animation: fadeIn 1s ease forwards;
  font-size: 1.1rem;
  color: #a6ffcb;
  margin-top: 10px;
}

/* ===== Footer ===== */
.footer {
  margin-top: 20px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
  text-align: center;
  pointer-events: none;
}

/* ===== Responsive ===== */
@media (max-width: 600px) {
  .card {
    padding-top: 100px;
  }

  .headshot {
    top: -50px;
    width: 100px;
    height: 100px;
  }
}

@media (max-width: 900px) and (max-height: 500px) {
  .headshot {
    top: max(-20px, -10vh);
    width: 100px;
    height: 100px;
  }

  .card {
    padding-top: 140px;
  }
}