* {
  box-sizing: border-box;
  -webkit-box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: #f7f7f7;
  color: #111;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  padding: 16px;
  width: 100%;
  min-height: 100vh;
  padding-bottom: 80px;
}

h1 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
  margin-top: 24px;
  font-weight: 600;
}

h2 {
  font-size: 1.1rem;
  margin-bottom: 12px;
  font-weight: 600;
  color: #111;
}

.connect-section {
  background: white;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.card-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card {
  background: #f9f9f9;
  border-radius: 8px;
  padding: 12px;
  border: 1px solid #eee;
}

.card b {
  font-size: 1rem;
  font-weight: 600;
  color: #111;
  display: block;
  margin-bottom: 4px;
}

.card .card-where {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 8px;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 8px;
  border-radius: 6px;
  background: #e5e7eb;
  color: #374151;
}

.card-actions {
  margin-top: 12px;
}

.card-actions .btn-primary {
  width: 100%;
  margin-top: 0;
}

/* FAB */
.fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  font-size: 28px;
  font-weight: 300;
  line-height: 1;
  border: none;
  background: #111;
  color: white;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  -webkit-appearance: none;
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.fab:active {
  background: #333;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 1000;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.modal-content {
  position: relative;
  background: white;
  padding: 20px;
  border-radius: 12px;
  width: 100%;
  max-width: 400px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
}

.modal-title {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 16px;
  margin-top: 0;
}

.modal.hidden {
  display: none;
}

/* Form (inside modal) */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: #666;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  border-radius: 8px;
  border: 1px solid #ddd;
  -webkit-appearance: none;
  appearance: none;
  background: #fff;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: #3b82f6;
}

.form-group select {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 35px;
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.modal-actions .btn-primary,
.modal-actions .btn-secondary {
  flex: 1;
}

.btn-primary {
  padding: 12px;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 8px;
  border: none;
  background: #111;
  color: white;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  margin-top: 0;
}

.btn-primary:active {
  background: #333;
}

.btn-secondary {
  padding: 12px;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 8px;
  border: 1px solid #ddd;
  background: #f0f0f0;
  color: #111;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.btn-secondary:active {
  background: #e0e0e0;
}

.empty-state {
  text-align: center;
  padding: 24px 16px;
  color: #999;
  font-size: 0.9rem;
}

@media (min-width: 768px) {
  .container {
    padding: 24px;
    padding-bottom: 88px;
  }

  .fab {
    bottom: 32px;
    right: calc(50% - 300px + 24px);
  }
}
