:root {
  --color-text: #121414;
  --color-link: #039350;
  --color-muted: #5c6360;
  --color-border: rgba(0, 0, 0, 0.8);
  --color-border-hover: black;
  --color-shadow: rgb(118 255 195);
  --color-button-ghost-hover: #f1f1f1;
  --color-gradient-start: #37dd8f;
  --color-gradient-end: #eff3ff;
  --color-black: #000000;
}

/* Base styles */
html,
body {
  font-family: "Instrument Sans", "Helvetica Neue", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  font-variation-settings: "wdth" 100;
  color: var(--color-text);
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}

body,
input,
textarea,
select,
button {
  font-synthesis: none;
  -moz-font-feature-settings: "kern";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  direction: ltr;
  text-align: left;
}

a {
  color: var(--color-link);
}

/* Layout */
.container {
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
  padding-left: 20px;
  padding-right: 20px;
}

header {
  flex-shrink: 0;
  padding-top: 4rem;
}

main {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

main.full-body-content {
  align-items: normal;
  justify-content: normal;
  padding-top: 60px;
}

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Typography */
h1 {
  font-size: 2.6rem;
  font-weight: 400;
  margin: 0;
}

.muted {
  color: var(--color-muted);
}

/* Buttons */
.button {
  background: none;
  border: none;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  outline: none;
  padding: 14px 16px;
  border-radius: 100px;
  font-weight: 500;
  transition: 0.2s;
  text-decoration: none;
}

.button.lg {
  font-size: 1.2rem;
  padding: 18px 22px;
}

.button.btn-primary {
  color: var(--color-text);
  border: 2px solid var(--color-muted);
}

.button.btn-primary:hover {
  box-shadow: 0 2px 40px var(--color-shadow);
  border-color: var(--color-border-hover);
}

.button.btn-ghost {
  color: inherit;
}

button.btn-ghost:hover {
  background-color: #f1f1f1;
}

button:hover {
  opacity: 0.9;
}

button:active {
  transform: scale(0.95);
}

/* Footer */
footer {
  padding-top: 50px;
}

.footer-links {
  text-align: right;
  padding: 0 20px 14px;
}

.footer-link {
  color: inherit;
  border-bottom: 2px solid;
  text-decoration: none;
  margin: 0 4px;
  font-size: 0.95em;
  margin-left: 12px;
}

.footer-link:hover {
  border-bottom-width: 4px;
}

.footer-ribbon {
  height: 12px;
  background: linear-gradient(to right, #37dd8f, #eff3ff);
}

.footer-ribbon-thin {
  height: 1px;
  background: #000000;
  margin-bottom: 4px;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeInUp 1s ease-out forwards;
}

.fade-in-2 {
  animation: fadeInUp 1.1s ease-out forwards;
  animation-delay: 1.7s;
  opacity: 0;
}

.fade-in-3 {
  animation: fadeInUp 1s ease-out forwards;
  animation-delay: 2.7s;
  opacity: 0;
}

/* Responsive */
@media (max-width: 1100px) {
  .container {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media (max-width: 860px) {
  h1 {
    font-size: 2rem;
  }
}

@media (max-width: 600px) {
  .container {
    padding-left: 20px;
    padding-right: 20px;
  }

  header {
    padding-top: 1.2rem;
    padding-bottom: 1rem;
  }

  .logo {
    height: 28px;
  }

  h1 {
    font-size: 1.5rem;
  }

  .footer-links {
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
    gap: 0.2em;
    font-size: 0.97em;
    white-space: normal;
  }

  .footer-link {
    margin: 0;
    display: block;
    margin-top: 6px;
    text-align: left;
    font-size: 0.9rem;
  }

  .copyright-copy {
    display: block;
    margin-bottom: 16px;
    text-align: left;
    font-size: 0.9rem;
  }
}

/* Typeform frame */
.iframe-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.iframe-overlay.show {
  opacity: 1;
  visibility: visible;
}

.iframe-container {
  position: relative;
  width: 90%;
  max-width: 800px;
  height: 100vh;
  max-height: 100vh;
  background: white;
  border-radius: 0;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  transform: scale(0.8) translateY(20px);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.iframe-overlay.show .iframe-container {
  transform: scale(1) translateY(0);
}

.iframe-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  font-weight: bold;
  color: #666;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  z-index: 10001;
  transition: all 0.2s ease;
  user-select: none;
}

.iframe-close:hover {
  background: rgba(240, 240, 240, 0.95);
  color: #333;
  transform: scale(1.1);
}

.iframe-close:active {
  transform: scale(0.95);
}

.typeform-iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.iframe-loading {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  color: #666;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e0e0e0;
  border-top: 4px solid #37dd8f;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@media (max-width: 768px) {
  .iframe-container {
    width: 100vw;
    height: 100vh;
    transform: scale(0.9) translateY(30px);
  }

  .iframe-close {
    top: 10px;
    right: 10px;
    width: 35px;
    height: 35px;
    font-size: 18px;
  }
}
