* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  background: #f5f5f5;
  color: #222;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

h1 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}

#ip-info {
  font-size: 13px;
  color: #666;
  margin-bottom: 12px;
  text-align: center;
}

#ip-info.hidden {
  display: none;
}

#ip-address {
  color: #2563eb;
  font-weight: 500;
}

#proxy-form {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

#address {
  flex: 1;
  max-width: 500px;
  padding: 12px;
  background: #ffffff;
  color: #222;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 16px;
  outline: none;
}

#address:focus {
  border-color: #2563eb;
}

#address::placeholder {
  color: #9ca3af;
}

button[type="submit"] {
  padding: 12px 24px;
  background: #2563eb;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
}

button[type="submit"]:hover {
  background: #1d4ed8;
}

button[type="submit"]:active {
  background: #1e40af;
}

#error {
  color: #dc2626;
  font-size: 14px;
  margin-bottom: 8px;
}

#error.hidden {
  display: none;
}

#back-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  padding: 0 12px;
  z-index: 100000;
}

#back-bar.hidden {
  display: none;
}

#back-btn {
  padding: 6px 16px;
  background: #2563eb;
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
}

#back-btn:hover {
  background: #1d4ed8;
}

@media (max-width: 600px) {
  #proxy-form {
    flex-direction: column;
  }

  #address {
    max-width: 100%;
  }

  button[type="submit"] {
    width: 100%;
  }

  .container {
    padding: 16px 12px;
  }

  h1 {
    font-size: 20px;
  }
}