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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #f5f5f5;
  color: #111;
  line-height: 1.5;
  padding: 40px 16px;
}

main {
  max-width: 520px;
  margin: 0 auto;
}

.header-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.logo {
  height: 28px;
  filter: invert(1);
}

.header-sep {
  width: 1px;
  height: 24px;
  background: #ddd;
}

h1 {
  font-size: 20px;
  font-weight: 600;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: flex;
  font-size: 13px;
  font-weight: 500;
  color: #555;
  margin-bottom: 6px;
}

.field input,
.field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  color: #111;
  background: #fff;
  transition: border-color 0.15s;
}

.field input:focus,
.field select:focus {
  outline: none;
  border-color: #111;
}

.field input[disabled] {
  background: #f5f5f5;
  color: #888;
}

.field .hint {
  font-size: 12px;
  color: #999;
  margin-top: 4px;
}

#global-url-field {
  margin-bottom: 24px;
}

#global-url-field input {
  font-size: 15px;
  padding: 12px 14px;
}

.tabs {
  display: flex;
  gap: 2px;
  margin-bottom: 20px;
  background: #e8e8e8;
  border-radius: 8px;
  padding: 3px;
}

.tab {
  flex: 1;
  padding: 8px 12px;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: #666;
  transition: all 0.15s;
}

.tab:hover {
  color: #111;
}

.tab.active {
  background: #fff;
  color: #111;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

.platform-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.platform-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid #ddd;
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  color: #888;
  transition: all 0.15s;
}

.platform-btn svg {
  width: 20px;
  height: 20px;
}

.platform-btn:hover {
  border-color: #999;
  color: #555;
}

.platform-btn.active {
  border-color: #111;
  background: #111;
  color: #fff;
}

.field-checkbox {
  margin-top: 8px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
  color: #111;
  line-height: 1;
}

.checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-width: 16px;
  margin: 0;
  padding: 0;
  cursor: pointer;
  position: relative;
  top: 0;
}

.checkbox-label span {
  line-height: 1;
}

.output {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #e8e8e8;
}

.output-wrapper {
  position: relative;
}

.output-wrapper input {
  width: 100%;
  padding: 10px 70px 10px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 13px;
  font-family: 'SF Mono', 'Fira Code', monospace;
  color: #111;
  background: #fff;
}

.output-wrapper input:focus {
  outline: none;
}

#copy-btn {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  padding: 6px 12px;
  background: #111;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.15s;
}

#copy-btn:hover {
  opacity: 0.8;
}

.copy-feedback {
  font-size: 13px;
  color: #16a34a;
  margin-top: 8px;
  min-height: 20px;
}

@media (max-width: 480px) {
  .tabs {
    flex-wrap: wrap;
  }

  .output-row {
    flex-direction: column;
  }

  #copy-btn {
    width: 100%;
  }
}
